:root {
  --page: #f3f1f8;
  --surface: #ffffff;
  --surface-soft: #f7f6fa;
  --ink: #181525;
  --muted: #77718c;
  --border: #e4e0eb;
  --brand: #5440d6;
  --brand-soft: #eeeaff;
  --navy: #100b2d;
  --blue: #2563eb;
  --blue-soft: #e8f1ff;
  --green: #08775b;
  --green-soft: #dcf8eb;
  --amber: #9b6500;
  --amber-soft: #fff5d9;
  --red: #b42318;
  --red-soft: #fff0ee;
  --shadow: 0 24px 70px rgba(22, 16, 52, 0.18);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--page);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 720px; background: var(--page); }
button, select, input { font: inherit; }
button, select { color: inherit; }
button { cursor: pointer; }
button:focus-visible, select:focus-visible, input:focus-visible { outline: 3px solid rgba(84, 64, 214, 0.3); outline-offset: 2px; }

.review-toolbar {
  position: sticky; top: 0; z-index: 50; min-height: 68px; display: flex; align-items: center;
  justify-content: space-between; gap: 20px; padding: 11px 22px; border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.96); backdrop-filter: blur(18px);
}
.review-brand { display: grid; gap: 2px; }
.review-brand strong { font-size: 15px; }
.review-kicker { color: var(--brand); font-size: 9px; font-weight: 900; letter-spacing: 0.12em; text-transform: uppercase; }
.review-controls { display: flex; align-items: end; gap: 9px; }
.review-controls label { display: grid; gap: 3px; color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; }
.review-controls select, .quiet-button { min-height: 34px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); padding: 0 12px; }
.notes-toggle { grid-auto-flow: column; align-items: center; min-height: 34px; border: 1px solid var(--border); border-radius: 999px; padding: 0 11px; }
.notes-toggle input { accent-color: var(--brand); }

.state-pills { display: flex; gap: 7px; overflow-x: auto; padding: 11px 22px 0; }
.state-pill { white-space: nowrap; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); padding: 7px 11px; font-size: 11px; font-weight: 750; }
.state-pill.active { border-color: var(--navy); background: var(--navy); color: white; }
.prototype-layout { display: grid; grid-template-columns: minmax(820px, 1fr) 350px; gap: 16px; align-items: start; padding: 16px 22px 46px; }
.prototype-stage { min-width: 0; }

.odia-app-frame { display: grid; grid-template-columns: 168px 1fr; min-height: 800px; overflow: hidden; border: 1px solid #d8d4e2; border-radius: 26px; background: var(--surface); box-shadow: var(--shadow); }
.app-sidebar { display: flex; flex-direction: column; padding: 17px 12px 12px; background: #f0edf7; border-right: 1px solid var(--border); }
.sidebar-brand { display: flex; align-items: center; gap: 9px; padding: 0 7px 19px; font-size: 12px; letter-spacing: 0.08em; }
.sidebar-brand span { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 9px; background: var(--navy); color: white; font-weight: 900; }
.app-sidebar nav { display: grid; gap: 4px; }
.app-sidebar nav button { display: grid; grid-template-columns: 19px 1fr auto; align-items: center; border: 0; border-radius: 11px; background: transparent; padding: 9px 10px; color: #625c75; text-align: left; font-size: 11px; }
.app-sidebar nav button.active { background: var(--surface); color: var(--ink); box-shadow: 0 5px 15px rgba(31, 24, 58, 0.06); font-weight: 750; }
.app-sidebar nav button b { display: grid; min-width: 17px; height: 17px; place-items: center; border-radius: 999px; background: var(--brand); color: white; font-size: 8px; }
.sidebar-account { display: flex; align-items: center; gap: 8px; margin-top: auto; border-top: 1px solid var(--border); padding: 13px 5px 2px; }
.sidebar-account i { display: grid; width: 29px; height: 29px; place-items: center; border-radius: 50%; background: var(--brand-soft); color: var(--brand); font-size: 9px; font-style: normal; font-weight: 900; }
.sidebar-account span { display: grid; min-width: 0; }
.sidebar-account strong { font-size: 10px; }
.sidebar-account small { overflow: hidden; color: var(--muted); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }

.app-main { min-width: 0; background: var(--surface); }
.site-header { height: 51px; display: grid; grid-template-columns: 30px minmax(180px, 380px) 1fr; align-items: center; gap: 14px; padding: 0 17px; border-bottom: 1px solid var(--border); }
.site-header > button, .site-actions button { border: 0; background: transparent; color: var(--muted); }
.global-search { border-radius: 999px; background: #f4f2f7; padding: 8px 12px; color: var(--muted); font-size: 10px; }
.site-actions { justify-self: end; display: flex; align-items: center; gap: 5px; }
.site-actions b { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 50%; background: var(--navy); color: white; font-size: 8px; }
.journey-page { min-width: 0; }
.journey-header { display: flex; align-items: end; justify-content: space-between; gap: 15px; padding: 17px 19px 12px; }
.breadcrumb { color: var(--muted); font-size: 9px; }
.journey-title { display: flex; align-items: center; gap: 8px; margin-top: 5px; }
.journey-title h1 { margin: 0; font-size: 19px; letter-spacing: -0.025em; }
.journey-title span { border-radius: 999px; background: var(--amber-soft); padding: 4px 7px; color: var(--amber); font-size: 8px; font-weight: 800; }
.journey-header p { margin: 4px 0 0; color: var(--muted); font-size: 9px; }
.journey-actions { display: flex; gap: 6px; }
.journey-actions button { border: 1px solid var(--border); border-radius: 999px; background: white; padding: 7px 10px; font-size: 9px; font-weight: 750; }
.journey-actions button.dark { border-color: var(--navy); background: var(--navy); color: white; }
.journey-tabs { display: flex; gap: 17px; padding: 0 19px; border-bottom: 1px solid var(--border); }
.journey-tabs button { border: 0; border-bottom: 2px solid transparent; background: transparent; padding: 10px 0 8px; color: var(--muted); font-size: 9px; font-weight: 700; }
.journey-tabs button.active { border-color: var(--brand); color: var(--ink); }
.journey-board { position: relative; min-height: 680px; overflow: hidden; background: #f8f7fa; }
.board-toolbar { display: flex; justify-content: space-between; padding: 12px 17px 7px; color: var(--muted); font-size: 8px; }
.day-grid { display: grid; grid-template-columns: repeat(3, minmax(150px, 1fr)); gap: 9px; padding: 0 13px; }
.day-grid article { min-height: 225px; border: 1px solid var(--border); border-radius: 13px; background: rgba(255,255,255,0.86); padding: 10px; }
.day-grid article > header { color: var(--muted); font-size: 8px; font-weight: 800; }
.service-card { display: grid; gap: 4px; margin-top: 9px; border: 1px solid #dfd8f2; border-radius: 11px; background: white; padding: 10px; }
.service-card span { color: var(--brand); font-size: 7px; font-weight: 800; text-transform: uppercase; }
.service-card strong { font-size: 10px; }
.service-card small { color: var(--muted); font-size: 8px; }
.service-card b { margin-top: 3px; font-size: 10px; }
.service-card.muted { opacity: 0.58; }
.empty-day { display: grid; height: 115px; margin-top: 9px; place-items: center; border: 1px dashed var(--border); border-radius: 11px; color: var(--muted); font-size: 8px; }
.screen-root { position: absolute; inset: 0; }

.dialog-backdrop { position: absolute; inset: 0; display: grid; place-items: start center; overflow: auto; padding: 22px 15px 35px; background: rgba(16, 11, 45, 0.34); }
.pricing-dialog { width: min(1120px, calc(100% - 10px)); overflow: hidden; border: 1px solid rgba(255,255,255,0.7); border-radius: 22px; background: white; box-shadow: 0 26px 80px rgba(15, 10, 40, 0.25); }
.pricing-dialog.narrow { width: min(790px, calc(100% - 10px)); }
.dialog-header { display: flex; align-items: start; justify-content: space-between; padding: 16px 18px 13px; border-bottom: 1px solid var(--border); }
.dialog-title { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.dialog-title h2 { margin: 0 3px 0 0; font-size: 14px; }
.dialog-title > span { border-radius: 999px; background: #f2f0f7; padding: 4px 7px; color: var(--muted); font-size: 8px; font-weight: 700; }
.dialog-title .dialog-status.amber { background: var(--amber-soft); color: var(--amber); }
.dialog-title .dialog-status.green { background: var(--green-soft); color: var(--green); }
.dialog-header p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }
.close-button { display: grid; width: 26px; height: 26px; place-items: center; border: 1px solid var(--border); border-radius: 50%; background: white; color: var(--muted); }
.mode-picker { display: flex; width: max-content; gap: 2px; margin: 11px auto 6px; border-radius: 999px; background: #f5f3f8; padding: 3px; }
.mode-picker button { border: 0; border-radius: 999px; background: transparent; padding: 6px 11px; color: var(--muted); font-size: 8px; }
.mode-picker button.active { background: white; color: var(--ink); box-shadow: 0 1px 4px rgba(20, 15, 42, 0.13); font-weight: 800; }
.mode-guidance { margin: 5px 18px 9px; border-radius: 10px; background: var(--brand-soft); padding: 7px 9px; color: #4d4279; font-size: 8px; text-align: center; }

.dialog-grid { display: grid; grid-template-columns: minmax(245px, 0.9fr) minmax(350px, 1.18fr) minmax(280px, 0.96fr); border-top: 1px solid var(--border); }
.dialog-grid.compact { grid-template-columns: minmax(310px, 1fr) minmax(260px, 0.86fr); margin-top: 8px; }
.basket-column, .pricing-column, .recap-column { min-width: 0; padding: 13px 14px; }
.basket-column, .pricing-column { border-right: 1px solid var(--border); }
.basket-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.basket-heading span { color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.basket-heading button { display: grid; width: 22px; height: 22px; place-items: center; border: 0; border-radius: 50%; background: transparent; color: var(--muted); }
.column-title { display: flex; align-items: start; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.column-title > div { display: grid; gap: 2px; }
.column-title span, .recap-kicker { color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.column-title strong { font-size: 10px; }
.column-title i, .column-title em { border-radius: 999px; background: var(--brand-soft); padding: 4px 6px; color: var(--brand); font-size: 7px; font-style: normal; font-weight: 800; }
.supplier-tabs { border-bottom: 1px solid var(--border); }
.supplier-tabs button { border: 0; border-bottom: 2px solid var(--ink); background: transparent; padding: 4px 0 6px; font-size: 8px; font-weight: 750; }
.supplier-list { display: grid; gap: 2px; margin-top: 6px; }
.supplier-price { display: grid; grid-template-columns: 17px minmax(0,1fr) auto; align-items: center; gap: 7px; border: 0; border-radius: 10px; background: transparent; padding: 8px 6px; text-align: left; }
.supplier-price.selected { background: #f1edff; }
.supplier-price .check { display: grid; width: 15px; height: 15px; place-items: center; border: 1px solid #c8c1d9; border-radius: 5px; background: white; color: var(--brand); font-size: 8px; }
.supplier-price.selected .check { border-color: var(--brand); }
.supplier-price > span:nth-child(2) { display: grid; min-width: 0; gap: 2px; }
.supplier-price strong { overflow: hidden; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.supplier-price small { color: var(--muted); font-size: 7px; }
.supplier-price b { font-size: 8px; }
.basket-total { display: flex; justify-content: space-between; margin: 10px 0 0; border-top: 1px solid var(--border); padding-top: 9px; font-size: 8px; }

.field-row { display: flex; min-height: 37px; align-items: center; justify-content: space-between; gap: 10px; }
.field-row > div:first-child { display: grid; gap: 2px; }
.field-row label { font-size: 8px; font-weight: 700; }
.field-row small { color: var(--muted); font-size: 7px; }
.amount-control, .select-control { display: flex; min-width: 120px; height: 26px; align-items: center; justify-content: space-between; gap: 8px; border: 1px solid #d9d2e8; border-radius: 999px; background: white; padding: 0 8px 0 11px; font-size: 8px; }
.amount-control span { margin-left: auto; font-variant-numeric: tabular-nums; }
.amount-control b, .select-control b { color: var(--ink); font-size: 7px; font-weight: 650; }
.amount-control i { color: var(--muted); font-size: 7px; font-style: normal; }
.amount-control.disabled { background: #f6f4f8; }
.select-control { min-width: 140px; }
.segmented { display: flex; border-radius: 999px; background: #f2f0f5; padding: 2px; }
.segmented button { border: 0; border-radius: 999px; background: transparent; padding: 5px 8px; color: var(--muted); font-size: 7px; }
.segmented button.active { background: white; color: var(--ink); box-shadow: 0 1px 3px rgba(20, 15, 42, 0.12); font-weight: 800; }
.segmented.small button { padding-inline: 7px; }
.adjustment-row { display: flex; min-height: 37px; align-items: center; justify-content: space-between; gap: 10px; }
.adjustment-row > div:first-child { display: flex; align-items: center; gap: 5px; }
.adjustment-row label { font-size: 8px; font-weight: 700; }
.adjustment-row > div:first-child button { display: grid; width: 14px; height: 14px; place-items: center; border: 1px solid var(--border); border-radius: 50%; background: white; color: var(--muted); padding: 0; font-size: 7px; }
.selling-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; }
.formula-details { display: grid; gap: 3px; margin: 7px 0 3px; }
.formula-title { color: var(--muted); font-size: 8px; font-weight: 700; }
.formula-details > div { display: grid; min-height: 24px; grid-template-columns: max-content 1fr max-content; align-items: center; gap: 6px; font-size: 8px; }
.formula-details small { color: var(--muted); font-size: 7px; }
.formula-details b { font-weight: 700; }
.concept { border-radius: 999px; padding: 3px 6px; font-size: 7px; font-weight: 750; }
.concept.cost { background: #dcecff; color: #245b90; }
.concept.markup { background: var(--brand-soft); color: var(--brand); }
.commission-divider { display: flex; align-items: center; gap: 8px; margin: 11px 0 2px; border-top: 1px solid var(--border); padding-top: 11px; }
.commission-divider span { color: var(--ink); font-size: 9px; font-weight: 800; }
.commission-divider b { margin-left: auto; border-radius: 999px; background: var(--green-soft); padding: 4px 7px; color: var(--green); font-size: 7px; }
.commission-helper { margin: 0 0 3px; color: var(--muted); font-size: 7px; line-height: 1.4; }
.formula-line { display: flex; align-items: center; gap: 6px; margin: 6px 0 4px; border-radius: 9px; background: #f5f3f9; padding: 7px 8px; font-size: 7px; }
.formula-line b { color: var(--brand); }
.formula-line strong { margin-left: auto; }
.section-divider { display: flex; align-items: center; gap: 8px; margin: 10px 0 3px; color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.section-divider::after { height: 1px; flex: 1; background: var(--border); content: ''; }
.inline-rate { display: flex !important; grid-auto-flow: column; align-items: center; gap: 4px; }
.inline-rate .amount-control { min-width: 74px; }
.inline-rate > button { border: 0; background: transparent; color: var(--brand); font-size: 7px; }
.commission-preview { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; margin-top: 7px; border-radius: 10px; background: var(--amber-soft); padding: 8px 9px; color: #6f4d0d; font-size: 8px; }
.commission-preview small { grid-column: 1 / -1; color: #8b6b29; font-size: 7px; }
.commission-preview.green { background: var(--green-soft); color: var(--green); }
.notes-link { margin-top: 7px; border: 0; background: transparent; color: var(--muted); padding: 3px 0; font-size: 7px; }
.error-banner { display: grid; gap: 2px; margin-top: 8px; border: 1px solid #f4b6af; border-radius: 10px; background: var(--red-soft); padding: 8px 9px; color: var(--red); font-size: 8px; }
.error-banner span { font-size: 7px; }
.netted-note { margin-bottom: 7px; border-radius: 10px; background: var(--blue-soft); padding: 8px 9px; color: #31558e; font-size: 7px; line-height: 1.4; }

.recap-column { background: #faf9fc; }
.recap-headline { display: flex; align-items: center; gap: 6px; margin: 4px 0 11px; }
.recap-headline strong { color: var(--blue); font-size: 19px; }
.recap-headline i { border-radius: 999px; background: var(--blue-soft); padding: 3px 5px; color: var(--blue); font-size: 7px; font-style: normal; font-weight: 800; }
.calculation { display: grid; gap: 2px; border-radius: 10px; background: white; padding: 9px; }
.calculation-title { margin-bottom: 3px; color: var(--muted); font-size: 7px; font-weight: 850; letter-spacing: 0.08em; }
.calc-row { display: flex; min-height: 23px; align-items: center; justify-content: space-between; gap: 8px; font-size: 8px; }
.calc-row span { display: flex; align-items: center; gap: 4px; }
.calc-row span.plain { background: transparent; color: var(--ink); padding: 0; }
.calc-row span::before { border-radius: 999px; background: #eeebf3; padding: 3px 5px; content: attr(data-label); }
.calc-row small { color: var(--muted); font-size: 6px; }
.calc-row.cost span, .calc-row.margin span, .calc-row.commission span { border-radius: 999px; padding: 3px 5px; }
.calc-row.cost span { background: #dcecff; color: #245b90; }
.calc-row.margin span { background: var(--brand-soft); color: var(--brand); }
.calc-row.commission span { background: var(--green-soft); color: var(--green); }
.calc-row.collected { margin-top: 4px; border-top: 1px solid var(--border); padding-top: 6px; }
.calc-row.total { margin-top: 2px; border-top: 1px solid var(--border); padding-top: 6px; font-size: 10px; font-weight: 850; }
.revenue-line { display: flex; justify-content: space-between; margin-top: 10px; color: var(--muted); font-size: 7px; }
.status-line { display: flex; align-items: start; gap: 5px; margin-top: 7px; color: #8a651f; font-size: 7px; line-height: 1.35; }
.status-line i { width: 5px; height: 5px; margin-top: 2px; flex: 0 0 auto; border-radius: 50%; background: #f0a81a; }
.status-line.green { color: var(--green); }
.status-line.green i { background: #2bc995; }
.status-line.blue { color: var(--blue); }
.status-line.blue i { background: var(--blue); }
.variance-line { display: flex; justify-content: space-between; margin-top: 7px; border-top: 1px solid var(--border); padding-top: 7px; color: var(--muted); font-size: 7px; }
.dialog-footer { display: flex; min-height: 49px; align-items: center; justify-content: flex-end; gap: 8px; border-top: 1px solid var(--border); padding: 9px 14px; }
.save-button { border: 0; border-radius: 999px; background: var(--navy); color: white; padding: 8px 13px; font-size: 8px; font-weight: 800; }
.link-button { border: 0; background: transparent; color: var(--muted); font-size: 8px; }
.save-confirmation { margin-right: auto; color: var(--green); font-size: 8px; font-weight: 750; }
.app-toast { position: absolute; top: 14px; right: 14px; z-index: 8; display: grid; min-width: 250px; gap: 2px; border: 1px solid var(--border); border-radius: 12px; background: white; padding: 10px 12px; box-shadow: 0 15px 35px rgba(20, 15, 42, 0.18); font-size: 9px; }
.app-toast span { color: var(--muted); font-size: 8px; }
.app-toast.error { border-color: #f4b6af; color: var(--red); }
.app-toast.success { border-color: #a9e3ce; color: var(--green); }
.saved-surface { position: absolute; inset: 0; pointer-events: none; }

.review-notes { position: sticky; top: 84px; display: grid; gap: 13px; max-height: calc(100vh - 102px); overflow-y: auto; border: 1px solid var(--border); border-radius: 22px; background: var(--surface); padding: 18px; box-shadow: var(--shadow); }
.review-notes[hidden] { display: none; }
.note-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.note-group, .score-target { border-radius: 999px; padding: 4px 7px; font-size: 8px; font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; }
.note-group { background: var(--brand-soft); color: var(--brand); }
.score-target { background: var(--green-soft); color: var(--green); }
.review-notes h2 { margin: 0; font-size: 19px; }
.review-notes section { border-top: 1px solid var(--border); padding-top: 11px; }
.review-notes h3 { margin: 0 0 5px; font-size: 9px; letter-spacing: 0.06em; text-transform: uppercase; }
.review-notes p, .review-notes li { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.review-notes ul { display: grid; gap: 4px; margin: 0; padding-left: 16px; }
.question-card { border: 0 !important; border-radius: 14px; background: var(--navy); padding: 12px !important; }
.question-card h3, .question-card p { color: white; }

@media (max-width: 1180px) {
  .review-toolbar { align-items: flex-start; flex-direction: column; }
  .prototype-layout { grid-template-columns: 1fr; }
  .review-notes { position: static; max-height: none; }
}
@media (max-width: 920px) {
  .odia-app-frame { grid-template-columns: 130px 1fr; min-height: 1540px; }
  .app-sidebar nav button { grid-template-columns: 17px 1fr auto; padding-inline: 7px; }
  .dialog-grid { grid-template-columns: 1fr; }
  .dialog-grid.compact { grid-template-columns: 1fr; }
  .basket-column, .pricing-column { border-right: 0; border-bottom: 1px solid var(--border); }
  .pricing-dialog { width: min(620px, calc(100% - 8px)); }
  .journey-board { min-height: 1390px; }
  .day-grid { grid-template-columns: 1fr 1fr; }
  .day-grid article:last-child { display: none; }
}
@media (prefers-reduced-motion: no-preference) {
  button, .state-pill { transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease; }
}
