:root {
  color-scheme: light;
  font-family: "DM Sans", "Segoe UI", sans-serif;
  color: #18181a;
  background: #f6f5f4;
  --dark: #1c1d20;
  --accent: #c51d2a;
  --accent-light: #ff9299;
  --accent-track: #f1e7e7;
  --muted: #626269;
  --line: #e5e3e2;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select, textarea { font: inherit; }
button, a, select { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: wait; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid #ad2731; outline-offset: 3px; }
h1, h2, h3, p, dl, dd { margin: 0; }
h1 { font-size: clamp(2rem, 4vw, 2.75rem); letter-spacing: -.06em; line-height: 1.1; }
h2 { font-size: 1.13rem; letter-spacing: -.025em; }
small { display: block; }
.icon { width: 1.23rem; height: 1.23rem; flex: none; vertical-align: middle; }
.shell { min-height: 100vh; display: grid; grid-template-columns: 245px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; gap: 26px; padding: 28px 18px 20px; background: var(--dark); color: #f7f6f6; }
.brand { display: flex; gap: 10px; align-items: center; font-size: 1.12rem; letter-spacing: .065em; white-space: nowrap; }
.brand-mark { display: block; flex: none; width: 38px; height: 38px; object-fit: contain; border-radius: 50%; }
.project-picker > label { display: block; margin: 0 0 8px 2px; color: #c0bfc5; font-size: .66rem; font-weight: 700; letter-spacing: .14em; }
.project-select { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 7px; background: #26272c; border: 1px solid #45464c; border-radius: 10px; }
.project-select select { color: #f7f6f6; background: #26272c; border: 0; min-width: 0; flex: 1; padding: 4px 0; font-size: .83rem; font-weight: 650; }
.project-select select:disabled { opacity: 1; appearance: none; }
.project-icon, .avatar { display: grid; place-items: center; width: 31px; height: 31px; flex: none; border-radius: 7px; background: #e6e3e6; color: #34343a; font-size: .72rem; font-weight: 800; }
.project-icon img { width: 100%; height: 100%; object-fit: contain; }
nav { display: grid; gap: 5px; }
nav a { display: flex; align-items: center; gap: 11px; padding: 11px 12px; min-height: 43px; border-radius: 8px; color: #d0cfd3; font-size: .88rem; font-weight: 600; }
nav a:hover { background: #26272c; }
nav a[aria-current] { background: #35262d; color: #fff; box-shadow: inset 3px 0 var(--accent-light); }
.account { display: flex; align-items: center; gap: 9px; border-top: 1px solid #3d3e43; padding-top: 17px; margin-top: auto; }
.account strong { font-size: .83rem; }
.account small { color: #c0bfc5; font-size: .72rem; }
.account button { margin-left: auto; display: grid; place-items: center; width: 36px; height: 36px; background: transparent; color: #e8e6e8; border: 0; border-radius: 8px; }
.account button:hover { background: #35262d; }
.workspace { min-width: 0; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 14px; min-height: 74px; padding: 12px clamp(18px, 4vw, 56px); background: #ffffff; border-bottom: 1px solid var(--line); }
.topbar strong { font-size: .96rem; }
.topbar small { color: var(--muted); margin-top: 3px; font-size: .78rem; }
.demo { display: inline-flex; gap: 7px; align-items: center; width: fit-content; padding: 7px 10px; border-radius: 6px; background: #edf2df; color: #3e522a; font-size: .66rem; letter-spacing: .075em; font-weight: 800; }
.demo i, .badge i { width: 6px; height: 6px; border-radius: 100%; background: currentColor; flex: none; }
.content { max-width: 1260px; margin: auto; padding: 32px clamp(18px, 4vw, 56px) 48px; }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.page-heading p { color: var(--muted); margin-top: 8px; line-height: 1.5; font-size: .93rem; }
.dashboard-grid { display: grid; grid-template-columns: 1.17fr 1fr; gap: 16px; }
.card { min-width: 0; padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.card-label { display: flex; align-items: center; gap: 7px; font-size: .72rem; font-weight: 750; letter-spacing: .095em; }
.card-label .icon { width: 17px; height: 17px; }
.sales-card { background: #26272c; color: #f9f8f8; border-color: #26272c; }
.sales-card .card-label, .sales-card .text-link { color: var(--accent-light); }
.sales-number { font-size: clamp(2.8rem, 5.3vw, 4.25rem); letter-spacing: -.075em; font-weight: 750; line-height: 1.14; margin: 14px 0 13px; }
.sales-number span { font-size: .94rem; color: #dbd8dc; letter-spacing: 0; font-weight: 500; }
.progress-label, .sales-footer, .next-footer { display: flex; justify-content: space-between; align-items: center; gap: 9px; flex-wrap: wrap; font-size: .79rem; }
.progress-label span, .sales-footer > span { color: #dbd8dc; }
progress { display: block; width: 100%; height: 8px; appearance: none; border: 0; border-radius: 20px; margin-top: 8px; background: #484950; color: var(--accent); overflow: hidden; }
progress::-webkit-progress-bar { background: #484950; }
progress::-webkit-progress-value { border-radius: 20px; background: var(--accent); }
progress::-moz-progress-bar { border-radius: 20px; background: var(--accent); }
.sales-footer { margin-top: 17px; }
.next-card { display: flex; flex-direction: column; }
.next-card .card-label { color: #525259; }
.milestone { display: flex; align-items: center; gap: 14px; flex: 1; padding: 18px 0; }
.milestone h3 { font-size: 1.17rem; letter-spacing: -.03em; }
.milestone p { color: var(--muted); font-size: .82rem; margin-top: 5px; }
.date-tile { flex: none; display: grid; place-content: center; text-align: center; width: 54px; height: 60px; background: #f4eded; color: #63252b; border-radius: 9px; }
.date-tile strong { font-size: 1.44rem; line-height: 1.05; }
.date-tile span { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.next-footer { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.badge { display: inline-flex; align-items: center; gap: 6px; width: fit-content; white-space: nowrap; border-radius: 5px; padding: 5px 8px; font-size: .72rem; font-weight: 650; }
.badge.amber { color: #774d12; background: #fbefd5; }
.badge.green { color: #365629; background: #e9f2e1; }
.badge.neutral { color: #4f554e; background: #eeefec; }
.text-link { display: inline-flex; align-items: center; gap: 5px; width: fit-content; color: #95252e; font-size: .82rem; font-weight: 700; white-space: nowrap; }
.text-link:hover { text-decoration: underline; }
.text-link .icon { width: 15px; height: 15px; }
.task-card { margin-top: 16px; padding-bottom: 7px; }
.section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.section-header p, .muted { color: var(--muted); font-size: .83rem; }
.section-header p { margin-top: 4px; }
.list-row { min-width: 0; display: flex; align-items: center; gap: 11px; padding: 13px 0; border-top: 1px solid var(--line); }
.list-card .list-row:first-child { border-top: 0; }
.list-card { padding-block: 5px; }
.row-icon { width: 35px; height: 35px; display: grid; place-items: center; flex: none; background: #f4eded; color: #6a3b40; border-radius: 8px; }
.row-icon .icon { width: 17px; height: 17px; }
.row-main { flex: 1; min-width: 0; }
.row-main strong, .recent strong { font-size: .87rem; overflow-wrap: anywhere; }
.row-main small, .recent small, .history-item small { margin-top: 3px; color: var(--muted); font-size: .77rem; }
.recent { display: flex; align-items: center; gap: 11px; margin: 18px 2px 0; }
.recent > div { flex: 1; }
.stack { display: grid; gap: 13px; }
.notice { padding: 13px 16px; margin-bottom: 14px; border-radius: 8px; background: #f5eeee; color: #50373a; font-size: .86rem; }
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; padding: 13px 0; border-top: 1px solid var(--line); }
.metrics dt { color: var(--muted); font-size: .76rem; }
.ad-context { margin: 5px 0 12px; }
.meta-campaign { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; }
.meta-campaign summary, .meta-manual summary { cursor: pointer; overflow-wrap: anywhere; }
.meta-campaign summary span { display: block; margin-top: 4px; color: var(--muted); font-size: .82rem; }
.meta-campaign[open] summary { margin-bottom: 10px; }
.metrics dd { margin-top: 4px; font-weight: 750; overflow-wrap: anywhere; }
.history-item { display: flex; gap: 12px; }
.history-item h2, .history-detail { overflow-wrap: anywhere; }
.history-detail { white-space: pre-wrap; margin: 7px 0 10px; font-size: .89rem; line-height: 1.55; }
.empty { padding: 16px 0; }
.primary, .secondary, .quiet { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 39px; padding: 8px 13px; border: 1px solid transparent; border-radius: 8px; font-size: .86rem; font-weight: 700; }
.primary { background: var(--accent); color: #ffffff; }
.primary:hover { background: #a81623; }
.secondary { background: #fff; border-color: #dfdddd; color: #3f3c40; }
.secondary:hover, .quiet:hover { background: #f6eeee; }
.quiet { background: transparent; color: #49454b; }
dialog { width: min(460px, calc(100% - 26px)); max-height: calc(100dvh - 26px); border: 1px solid var(--line); border-radius: 16px; padding: 24px; color: inherit; }
dialog::backdrop { background: #171b15a8; }
form { display: grid; gap: 13px; }
form h2 { font-size: 1.55rem; }
form label { display: grid; gap: 5px; font-size: .86rem; font-weight: 650; }
form input, form textarea, form select { width: 100%; padding: 9px 10px; border: 1px solid #d9d6d6; border-radius: 8px; background: #fff; color: #201f22; }
.error { color: #a1251a; font-size: .85rem; }
.error:empty { display: none; }
.dialog-actions { display: flex; justify-content: end; gap: 8px; margin-top: 3px; }
.loading, .unavailable { padding: clamp(24px, 6vw, 72px); }
.unavailable h1 { margin: 30px 0 8px; }
.unavailable p { margin-bottom: 16px; }
.login-layout { min-height: 100dvh; display: grid; grid-template-columns: 1.05fr 1fr; }
.login-art { position: relative; min-width: 0; min-height: 0; overflow: hidden; background: #191a1d; }
.login-show { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 82%; }
.login-main { display: grid; align-items: center; padding: 32px 26px; background: #fff; }
.login-main h1 { font-size: clamp(1.65rem, 3vw, 2rem); letter-spacing: -.045em; }
.login-main p { margin-top: 7px; }
.login-main form { width: min(100%, 340px); margin: 0 auto; }
.login-main input { padding: 12px; }
.login-main .remember-session { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.login-main .remember-session input { width: 16px; margin: 0; padding: 0; }
.sales-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.sales-stats > div { min-width: 0; padding: 4px 12px; border-inline-start: 1px solid var(--line); }
.sales-stats > div:first-child { padding-inline-start: 0; border-inline-start: 0; }
.sales-stats dt { font-size: .85rem; font-weight: 650; color: var(--muted); }
.sales-stats dd { margin-top: 5px; font-size: clamp(1.12rem, 2.1vw, 1.65rem); font-weight: 750; letter-spacing: -.04em; overflow-wrap: anywhere; }
.sales-stats .sales-caption { color: var(--muted); font-size: .75rem; font-weight: 400; letter-spacing: normal; }
.sales-target { margin-top: 16px; padding: 12px 14px; border-radius: 8px; background: #f5eeee; color: #50373a; }
.sales-target .progress-label span { color: #665155; }
.sales-detail { margin-top: 16px; }
.lot-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 12px; }
.lot-grid article { padding: 14px; border: 1px solid var(--line); border-radius: 9px; }
.lot-progress .section-header { margin-bottom: 8px; }
.lot-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; margin: 8px 0; font-size: .83rem; color: var(--muted); }
.sales-groups, .sales-entries { margin: 0; padding: 0; list-style: none; }
.sales-groups li { margin-top: 15px; }
.sales-groups li div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; font-size: .86rem; overflow-wrap: anywhere; }
.sales-groups li span { color: var(--muted); }
.sales-groups progress, .sales-target progress { background: var(--accent-track); }
.sales-groups progress::-webkit-progress-bar, .sales-target progress::-webkit-progress-bar { background: var(--accent-track); }
.sales-groups progress::-webkit-progress-value, .sales-target progress::-webkit-progress-value { background: var(--accent); }
.sales-groups progress::-moz-progress-bar, .sales-target progress::-moz-progress-bar { background: var(--accent); }
.sales-entries > li > strong { font-size: .87rem; }
.sales-editor { width: min(660px, calc(100% - 26px)); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; min-width: 0; }
.form-grid[hidden] { display: none; }
fieldset.form-grid { margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 9px; }
.form-grid legend { padding-inline: 5px; font-size: .85rem; font-weight: 700; }
.sales-editor .section-header { margin: 2px 0 0; flex-wrap: wrap; }
.sales-editor h3 { font-size: 1rem; }
.task-overview { display: flex; align-items: center; gap: 15px; flex-wrap: wrap; }
.task-overview progress { flex: 1; min-width: 100px; margin: 0; }
.task-filters { display: flex; flex-wrap: wrap; align-items: end; margin: 17px 0 12px; }
.task-filters select { min-width: min(165px, 100%); }
.task-filters label { min-width: 0; max-width: 100%; }
.task-filters .task-checkbox { display: flex; align-items: center; gap: 7px; min-height: 39px; }
.task-checkbox input { width: 16px; accent-color: var(--accent); }
.task-count { margin-bottom: 10px; }
.task-board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.task-column { background: #eeefe8; border: 1px solid var(--line); border-top: 3px solid #858c7d; border-radius: 10px; padding: 10px; min-width: 0; }
.task-column.working { border-top-color: #af7d32; }
.task-column.blocked { border-top-color: #ad5145; }
.task-column.done { border-top-color: #67884c; }
.task-column h2 { display: flex; justify-content: space-between; align-items: baseline; gap: 7px; margin-bottom: 10px; font-size: .94rem; }
.task-column h2 small, .task-empty { color: var(--muted); font-size: .8rem; }
.task-empty { padding: 12px 0; }
.task-ticket { display: grid; gap: 7px; padding: 11px; margin-bottom: 8px; overflow-wrap: anywhere; }
.task-ticket h3 { font-size: .94rem; }
.task-ticket p, .task-area { font-size: .78rem; color: var(--muted); }
.task-area { font-weight: 700; }
.task-ticket .quiet { justify-self: start; }
.task-late { width: fit-content; padding: 3px 6px; border-radius: 5px; background: #fbe9e4; color: #8b3529; font-size: .75rem; }
.agenda-header { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.agenda-header h2 { overflow-wrap: anywhere; }
.agenda-deliveries { margin-top: 14px; padding: 12px 14px 0; background: #f6f5f4; border-radius: 8px; }
.agenda-deliveries h3 { font-size: .9rem; }
.agenda-deliveries .section-header { flex-wrap: wrap; padding-bottom: 10px; margin-bottom: 0; }
.agenda-deliveries .list-row { flex-wrap: wrap; }
.admin-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; background: var(--dark); color: #f7f6f6; padding: 16px clamp(16px, 4vw, 48px); }
.admin-bar > div { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.admin-bar a { color: var(--accent-light); font-weight: 650; }
.admin-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.admin-panel h2 { margin-bottom: 15px; }
.company-events + .company-events { margin-top: 26px; }
.company-event-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); gap: 14px; padding: 0; list-style: none; }
.company-event { display: grid; align-content: space-between; gap: 16px; }
.company-event-count { display: block; margin: 3px 0 8px; font-size: 1.8rem; font-variant-numeric: tabular-nums; }
.company-event-footer { display: flex; gap: 10px; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.account-password { width: 100%; }
.account-password details { margin-top: 6px; }
.sales-curve-filters { display: flex; flex-wrap: wrap; gap: 12px; margin: 14px 0 6px; }
#sales-curve canvas { display: block; width: 100%; height: auto; aspect-ratio: 840 / 290; }
.sales-chart-plot { position: relative; }
.sales-chart-tooltip {
  position: absolute;
  transform: translateX(-50%);
  pointer-events: none;
  white-space: nowrap;
  padding: 6px 9px;
  border-radius: 6px;
  background: #26272c;
  color: #fff;
  font-size: .78rem;
  font-variant-numeric: tabular-nums;
}
.sales-curve-note, .sales-curve-data { margin-top: 10px; }
.meta-trend { padding: 10px 0; border-top: 1px solid var(--line); }
.meta-trend-rows { display: grid; gap: 9px; padding: 0; list-style: none; }
.meta-trend-rows li { display: grid; grid-template-columns: 3.5rem minmax(0, 1fr) minmax(5.5rem, auto); gap: 10px; align-items: center; }
.meta-trend-rows strong { text-align: right; font-variant-numeric: tabular-nums; }
.meta-trend-rows progress { margin: 0; background: var(--accent-track); }
.meta-trend-rows progress::-webkit-progress-bar { background: var(--accent-track); }
.meta-trend-rows progress::-webkit-progress-value { background: var(--accent); }
.meta-trend-rows progress::-moz-progress-bar { background: var(--accent); }
.sales-curve-data > div { max-height: 18rem; overflow: auto; }
.sales-curve-data table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.sales-curve-data th, .sales-curve-data td { padding: 7px 8px; text-align: right; border-bottom: 1px solid var(--line); }
.sales-curve-data th:first-child, .sales-curve-data td:first-child { text-align: left; }
.account-password summary {
  display: block;
  width: fit-content;
  padding: 4px 0;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 500;
  cursor: pointer;
}
.account-password summary::-webkit-details-marker { display: none; }
.account-password summary:hover,
.account-password summary:focus-visible { text-decoration: underline; }
.admin-panel .task-checkbox { display: flex; align-items: center; }
.meta-catalog { max-height: 16rem; overflow: auto; display: grid; gap: 8px; min-width: 0; }
.meta-catalog input { flex: 0 0 16px; }
.admin-list { list-style: none; padding: 0; margin: 14px 0 0; }
.admin-list li { border-top: 1px solid var(--line); padding: 10px 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; overflow-wrap: anywhere; }
.admin-list li small { color: var(--muted); margin-top: 3px; }
.admin-feedback { color: #365629; margin-bottom: 14px; }
.admin-feedback:empty { margin: 0; }
@media (max-width: 680px) { .admin-grid { grid-template-columns: 1fr; } }
@media (max-width: 1100px) { .task-board { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .task-board { grid-template-columns: 1fr; } }
@media (max-width: 950px) {
  .shell { grid-template-columns: 200px minmax(0, 1fr); }
  .sidebar { padding-inline: 13px; }
  .content, .topbar { padding-inline: 20px; }
  .card { padding-inline: 16px; }
}
@media (max-width: 730px) {
  .shell { display: block; }
  .sidebar { display: grid; position: static; height: auto; grid-template-columns: 1fr auto; gap: 12px; padding: 12px 14px 8px; }
  .project-picker { grid-row: 2; grid-column: 1 / -1; }
  .project-picker > label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .account { grid-row: 1; grid-column: 2; margin: 0; padding: 0; border: 0; }
  .account .avatar { display: none; }
  nav { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
  nav a { flex-direction: column; gap: 4px; justify-content: center; padding: 6px 1px; font-size: clamp(.59rem, 2vw, .76rem); }
  nav .icon { width: 17px; height: 17px; }
  .topbar { min-height: 60px; padding: 9px 14px; }
  .content { padding: 23px 14px 30px; }
  .page-heading { align-items: start; }
  .dashboard-grid { grid-template-columns: 1fr; gap: 12px; }
  .task-card { margin-top: 12px; }
  .demo { max-width: 145px; font-size: .59rem; }
  .login-layout { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .login-art { min-height: clamp(245px, 77vw, 340px); }
  .login-main { padding-block: 28px; }
}
@media (max-width: 450px) {
  .page-heading { flex-direction: column; gap: 11px; margin-bottom: 16px; }
  .card { padding-inline: 12px; }
  .list-row { gap: 7px; flex-wrap: wrap; }
  .row-main { min-width: 115px; }
  .badge { padding-inline: 6px; font-size: .66rem; }
  .recent { flex-wrap: wrap; }
  .sales-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .sales-stats > div:nth-child(odd) { padding-inline-start: 0; border-inline-start: 0; }
  .form-grid { grid-template-columns: 1fr; }
}
