@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&display=swap');

:root {
  color-scheme: light;
  --teal: #176b67;
  --teal-dark: #104c49;
  --teal-ink: #143d3a;
  --mint: #e5efea;
  --sand: #e8cfa8;
  --paper: #fbfaf6;
  --canvas: #f2f4ef;
  --ink: #172c2b;
  --muted: #74827c;
  --line: #e2e7df;
  --white: #fffefa;
  --mono: 'DM Mono', 'Courier New', monospace;
  font-family: 'Nunito Sans', 'Segoe UI', sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--canvas); color: var(--ink); }
button, input { font: inherit; }
button { color: inherit; }
.page-shell { width: min(1160px, calc(100% - 64px)); margin: 0 auto; }
.topbar { height: 88px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgba(23, 61, 58, .1); }
.brand { display: inline-flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; }
.brand-mark { width: 40px; height: 40px; color: var(--teal); display: inline-flex; }
.brand-mark svg { width: 100%; height: 100%; }
.brand-copy { display: grid; line-height: 1.15; gap: 4px; }
.brand-copy strong { font-size: 16px; font-weight: 900; letter-spacing: -.03em; }
.brand-copy small { color: var(--muted); font: 500 9px/1 var(--mono); letter-spacing: .12em; }
.topbar-note { display: inline-flex; align-items: center; gap: 8px; color: #667872; font: 500 10px/1 var(--mono); letter-spacing: .08em; }
.status-dot, .live-badge span { width: 7px; height: 7px; border-radius: 100%; background: #7aa996; box-shadow: 0 0 0 3px rgba(122, 169, 150, .16); }
.intro { min-height: 246px; display: flex; justify-content: space-between; align-items: center; padding: 32px 8px 28px; }
.intro-copy { max-width: 660px; }
.eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 13px; color: var(--teal); font: 500 10px/1 var(--mono); letter-spacing: .1em; }
.eyebrow-line { width: 20px; height: 1px; background: var(--sand); }
h1 { margin: 0; color: var(--teal-ink); font-size: clamp(36px, 5.1vw, 54px); font-weight: 900; line-height: 1.04; letter-spacing: -.055em; }
h1 em { color: var(--teal); font-style: normal; }
.intro-text { max-width: 520px; margin: 14px 0 0; color: #65746e; font-size: 14px; line-height: 1.55; }
.intro-stamp { display: flex; align-items: center; gap: 11px; padding: 13px 16px 13px 12px; margin: 22px 0 0 24px; border: 1px solid #dfe6db; border-radius: 13px; background: rgba(255, 254, 250, .55); transform: rotate(1deg); }
.stamp-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: #e3eee8; color: var(--teal); }
.stamp-icon svg { width: 27px; height: 27px; }
.intro-stamp strong, .intro-stamp small { display: block; }
.intro-stamp strong { color: var(--teal-ink); font-size: 16px; font-weight: 900; letter-spacing: -.03em; }
.intro-stamp small { margin-top: 2px; color: #718079; font-size: 10px; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr); align-items: stretch; border: 1px solid #e1e6de; border-radius: 20px; background: var(--white); box-shadow: 0 18px 54px rgba(38, 64, 53, .07); overflow: hidden; }
.form-panel { padding: 32px 34px 30px; }
.panel-heading { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 26px; }
.step-label { margin: 0; color: #7d8983; font: 500 9px/1.4 var(--mono); letter-spacing: .105em; }
.step-label span { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-right: 6px; border-radius: 6px; background: var(--mint); color: var(--teal); font-size: 9px; letter-spacing: 0; }
.panel-heading h2, .result-panel h2 { margin: 10px 0 0; color: var(--teal-ink); font-size: 22px; font-weight: 900; letter-spacing: -.045em; }
.heading-mark { color: #c0d2c6; font-size: 20px; line-height: 1; }
.vehicle-fieldset { margin: 0; padding: 0; border: 0; }
.vehicle-fieldset legend, .field-label { color: #334744; font-size: 12px; font-weight: 800; }
.vehicle-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 9px; }
.vehicle-choice { position: relative; display: flex; min-width: 0; align-items: center; gap: 10px; padding: 13px 12px; text-align: left; border: 1px solid #e2e7df; border-radius: 12px; background: #fff; cursor: pointer; transition: border-color .18s ease, background .18s ease, transform .18s ease, box-shadow .18s ease; }
.vehicle-choice:hover { border-color: #a6c2b3; transform: translateY(-1px); }
.vehicle-choice:focus-visible, input:focus-visible, .copy-button:focus-visible { outline: 3px solid rgba(23, 107, 103, .28); outline-offset: 2px; }
.vehicle-choice.is-selected { border-color: var(--teal); background: #f1f7f3; box-shadow: inset 0 0 0 1px var(--teal); }
.vehicle-icon { flex: 0 0 auto; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: #edf3ee; color: var(--teal); }
.vehicle-icon svg { width: 32px; height: 24px; }
.vehicle-icon.van-icon { background: #f5f0e7; color: #94714a; }
.vehicle-text { min-width: 0; display: grid; gap: 2px; }
.vehicle-text strong { color: var(--teal-ink); font-size: 13px; line-height: 1.2; font-weight: 900; }
.vehicle-text small { color: #73817b; font-size: 10px; line-height: 1.25; white-space: nowrap; }
.choice-check { position: absolute; top: 7px; right: 8px; display: grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; color: transparent; background: transparent; font-size: 10px; }
.is-selected .choice-check { color: white; background: var(--teal); }
.input-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 17px 13px; margin-top: 24px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field-wide { grid-column: 1 / -1; }
.field-label { display: flex; justify-content: space-between; align-items: baseline; font-size: 11px; }
.field-hint { color: #96a099; font-size: 10px; font-weight: 600; }
.input-wrap { display: flex; align-items: center; height: 48px; border: 1px solid #e1e6df; border-radius: 10px; background: #fff; transition: border-color .18s ease, box-shadow .18s ease; }
.input-wrap:focus-within { border-color: #70a095; box-shadow: 0 0 0 3px rgba(23, 107, 103, .09); }
.input-wrap input { width: 100%; min-width: 0; height: 100%; padding: 0 13px; border: 0; outline: 0; background: transparent; color: var(--teal-ink); font-family: var(--mono); font-size: 17px; font-weight: 500; }
.input-wrap input::-webkit-inner-spin-button, .input-wrap input::-webkit-outer-spin-button { margin: 0; appearance: none; }
.input-wrap input[type=number] { appearance: textfield; }
.input-unit { flex: 0 0 auto; padding: 0 13px; color: #91a099; font-size: 11px; font-weight: 700; }
.rule-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 23px; padding: 12px 13px; border-radius: 10px; background: #f4f6f0; }
.rule-icon { flex: 0 0 auto; color: var(--teal); }
.rule-icon svg { display: block; width: 18px; height: 18px; }
.rule-note p { margin: 0; color: #65746d; font-size: 10px; line-height: 1.55; }
.rule-note strong { color: #3d6257; font-weight: 900; }
.result-panel { position: relative; display: flex; flex-direction: column; padding: 32px 30px 24px; background: var(--teal); color: #f7faf6; overflow: hidden; }
.result-panel::before { position: absolute; top: -90px; right: -75px; width: 220px; height: 220px; border: 1px solid rgba(255,255,255,.09); border-radius: 50%; content: ''; }
.result-panel::after { position: absolute; top: -54px; right: -40px; width: 150px; height: 150px; border: 1px solid rgba(255,255,255,.08); border-radius: 50%; content: ''; }
.result-panel > * { position: relative; z-index: 1; }
.result-topline { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.step-label-light { color: rgba(242, 250, 244, .62); }
.step-label-light span { color: var(--teal-dark); background: #dce9de; }
.live-badge { display: flex; align-items: center; gap: 7px; color: rgba(237, 247, 241, .7); font: 400 8px/1 var(--mono); letter-spacing: .055em; white-space: nowrap; }
.live-badge span { width: 6px; height: 6px; background: #b8d69a; box-shadow: 0 0 0 3px rgba(184, 214, 154, .13); }
.result-panel h2 { margin-top: 25px; color: rgba(246, 250, 247, .78); font-size: 13px; font-weight: 700; letter-spacing: .01em; }
.total-amount { display: flex; align-items: baseline; gap: 7px; margin-top: 3px; color: #fffdf4; font-family: var(--mono); font-size: clamp(32px, 4vw, 43px); font-weight: 500; letter-spacing: -.08em; white-space: nowrap; }
.total-amount .currency { color: #e8cfa8; font-size: 22px; letter-spacing: -.03em; }
.result-context { margin: 7px 0 22px; color: rgba(237, 247, 241, .7); font-size: 10px; }
.result-context span { padding: 0 4px; color: #d5bf9a; }
.breakdown { display: grid; gap: 0; border-top: 1px solid rgba(255,255,255,.18); }
.breakdown-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 48px; border-bottom: 1px solid rgba(255,255,255,.14); }
.breakdown-row > span { color: #f6f8f3; font-size: 11px; font-weight: 800; }
.breakdown-row strong { color: #fffdf5; font-family: var(--mono); font-size: 11px; font-weight: 500; white-space: nowrap; }
.assignment-price-row { margin: 0 -8px; padding: 0 8px; background: rgba(232, 207, 168, .12); }
.assignment-price-row > span, .assignment-price-row strong { color: #f2d9ae; font-weight: 900; }
.reference-price-row { min-height: 48px; margin: 10px 0 0; padding: 0 12px; border: 1px solid rgba(255, 255, 255, .15); border-radius: 10px; background: rgba(255, 255, 255, .055); }
.reference-price-row > span { color: #dce9de; }
.reference-price-row strong { max-width: 65%; color: #f2d9ae; font-weight: 900; text-align: right; white-space: normal; }
.reference-estimate-panel { margin: 16px 0 0; padding: 14px; border: 1px solid rgba(238, 246, 240, .2); border-radius: 13px; background: rgba(4, 47, 43, .22); }
.reference-estimate-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.reference-estimate-kicker { margin: 0 0 3px; color: #d5bf9a; font: 500 8px/1.3 var(--mono); letter-spacing: .1em; }
.reference-estimate-heading h3 { margin: 0; color: #f8faf5; font-size: 13px; font-weight: 900; }
.reference-estimate-badge { flex: 0 0 auto; padding: 5px 7px; border: 1px solid rgba(232, 207, 168, .35); border-radius: 6px; color: #f2d9ae; font: 500 7px/1.2 var(--mono); letter-spacing: .035em; }
.reference-estimate-panel .reference-price-row { margin: 11px 0 0; }
.reference-estimate-details { margin-top: 7px; }
.reference-estimate-details .breakdown-row { min-height: 38px; border-bottom-color: rgba(255,255,255,.1); }
.reference-estimate-details .breakdown-row[hidden] { display: none; }
.reference-estimate-details .breakdown-row > span { color: rgba(246, 248, 243, .78); font-size: 10px; }
.reference-estimate-details .breakdown-row strong { text-align: right; white-space: normal; }
.reference-estimate-panel .estimate-disclaimer { margin: 10px 0 0; padding: 0; color: rgba(238, 246, 240, .64); font-size: 8px; line-height: 1.55; }
.reference-estimate-panel .estimate-disclaimer a { color: #f2d9ae; }
.reference-estimate-panel .estimate-disclaimer strong { color: #f8faf5; }
.formula { min-height: 40px; display: flex; align-items: center; margin: 14px 0 15px; padding: 9px 11px; border: 1px solid rgba(255,255,255,.13); border-radius: 8px; background: rgba(4, 47, 43, .18); color: #dce9de; font: 400 9px/1.55 var(--mono); }
.copy-button { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 43px; padding: 0 14px; border: 0; border-radius: 9px; background: var(--sand); color: #344b41; cursor: pointer; font-size: 11px; font-weight: 900; transition: background .18s ease, transform .18s ease; }
.copy-button:hover { background: #f1ddb9; transform: translateY(-1px); }
.copy-button svg { width: 17px; height: 17px; }
.copy-status { min-height: 16px; margin: 6px 0 0; color: #e7d8b8; font-size: 9px; }
.estimate-disclaimer { margin: auto 0 0; padding-top: 5px; color: rgba(238, 246, 240, .5); font-size: 9px; }
.page-footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 7px 28px; color: #7e8d86; font: 400 8px/1.5 var(--mono); letter-spacing: .055em; }
.footer-dot { padding: 0 5px; color: #c19862; }
.footer-rule { color: #929e97; letter-spacing: 0; text-align: right; }

@media (max-width: 820px) {
  .page-shell { width: min(680px, calc(100% - 36px)); }
  .intro { min-height: 220px; padding-top: 30px; }
  .workspace { grid-template-columns: 1fr; }
  .result-panel { min-height: 0; }
  .total-amount { font-size: 40px; }
  .estimate-disclaimer { margin-top: 4px; }
}
@media (max-width: 520px) {
  .page-shell { width: calc(100% - 28px); }
  .topbar { height: 72px; }
  .topbar-note { font-size: 8px; letter-spacing: .04em; }
  .intro { min-height: 0; gap: 10px; align-items: flex-end; padding: 29px 2px 24px; }
  .eyebrow { font-size: 8px; margin-bottom: 11px; }
  h1 { font-size: clamp(34px, 10vw, 43px); }
  .intro-text { max-width: 310px; margin-top: 11px; font-size: 12px; }
  .intro-stamp { flex: 0 0 auto; display: grid; gap: 5px; padding: 9px 10px; margin: 0 0 1px 0; border-radius: 11px; }
  .stamp-icon { width: 30px; height: 30px; }
  .stamp-icon svg { width: 22px; height: 22px; }
  .intro-stamp strong { font-size: 13px; }
  .intro-stamp small { max-width: 76px; font-size: 8px; }
  .workspace { border-radius: 16px; }
  .form-panel { padding: 23px 18px 21px; }
  .panel-heading { margin-bottom: 21px; }
  .panel-heading h2 { font-size: 20px; }
  .vehicle-options { gap: 8px; }
  .vehicle-choice { gap: 8px; padding: 12px 9px; }
  .vehicle-icon { width: 29px; height: 31px; }
  .vehicle-icon svg { width: 29px; }
  .vehicle-text strong { font-size: 12px; }
  .vehicle-text small { font-size: 9px; }
  .input-grid { gap: 14px 10px; margin-top: 22px; }
  .input-wrap { height: 46px; }
  .input-wrap input { padding-left: 11px; font-size: 16px; }
  .input-unit { padding: 0 10px; font-size: 10px; }
  .rule-note { margin-top: 18px; padding: 11px; }
  .result-panel { padding: 23px 19px 18px; }
  .result-topline { flex-wrap: wrap; }
  .result-panel h2 { margin-top: 23px; }
  .total-amount { font-size: clamp(32px, 9vw, 39px); }
  .page-footer { align-items: flex-start; flex-direction: column; gap: 5px; padding: 16px 3px 22px; font-size: 7px; }
  .footer-rule { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Google Maps route inputs and live route preview */
.route-fields { position: relative; display: grid; gap: 15px; margin-top: 24px; }
.location-field { position: relative; display: grid; gap: 8px; }
.location-field > .field-label { margin-bottom: 1px; color: var(--teal-ink); font-size: 13px; }
.location-input-wrap { display: flex; align-items: center; min-height: 64px; border: 1px solid #dce5dc; border-radius: 12px; background: #fff; transition: border-color .18s ease, box-shadow .18s ease, background .18s ease; }
.location-input-wrap:focus-within { border-color: #70a095; box-shadow: 0 0 0 3px rgba(23, 107, 103, .09); }
.location-marker { position: relative; flex: 0 0 auto; width: 15px; height: 15px; margin: 0 12px 0 14px; border: 2px solid var(--teal); border-radius: 50%; }
.location-marker::after { position: absolute; inset: 3px; border-radius: 50%; background: var(--teal); content: ''; }
.destination-marker { border-color: #b27a43; border-radius: 4px; transform: rotate(45deg) scale(.84); }
.destination-marker::after { background: #b27a43; }
.location-input-wrap input { width: 100%; min-width: 0; height: 62px; padding: 0 14px 0 0; border: 0; outline: 0; background: transparent; color: var(--teal-ink); font-size: 15px; font-weight: 700; }
.location-input-wrap input::placeholder { color: #98a59e; font-size: 13px; font-weight: 500; }
.selected-address { display: block; margin: 0 2px; padding: 9px 12px; border-left: 3px solid #a8c5b5; border-radius: 0 9px 9px 0; background: #f3f7f2; color: #5f7168; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.selected-address[hidden] { display: none; }
.route-button { display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%; min-height: 43px; border: 1px solid #b8d0c3; border-radius: 9px; background: #edf5ef; color: var(--teal); cursor: pointer; font-size: 11px; font-weight: 900; transition: background .18s ease, border-color .18s ease, transform .18s ease; }
.route-button:hover:not(:disabled) { border-color: var(--teal); background: #e4f0e8; transform: translateY(-1px); }
.route-button:focus-visible { outline: 3px solid rgba(23, 107, 103, .28); outline-offset: 2px; }
.route-button:disabled { cursor: progress; opacity: .72; }
.route-button svg { width: 18px; height: 18px; }
.route-status { min-height: 16px; margin: 7px 0 0; color: #7a8982; font-size: 9px; line-height: 1.5; }
.route-status.is-error { color: #a94c3d; }
.route-status.is-success { color: var(--teal); }
.trip-input-grid { grid-template-columns: minmax(0, 1fr); margin-top: 20px; }
/* Trip direction selector */
.trip-direction { margin-top: 17px; }
.trip-direction > .field-label { margin: 0 0 8px; }
.direction-options { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.direction-choice { position: relative; display: flex; min-width: 0; align-items: center; gap: 9px; padding: 11px 10px; text-align: left; border: 1px solid #e2e7df; border-radius: 11px; background: #fff; cursor: pointer; transition: border-color .18s ease, background .18s ease, transform .18s ease, box-shadow .18s ease; }
.direction-choice:hover { border-color: #a6c2b3; transform: translateY(-1px); }
.direction-choice:focus-visible { outline: 3px solid rgba(23, 107, 103, .28); outline-offset: 2px; }
.direction-choice.is-selected { border-color: var(--teal); background: #f1f7f3; box-shadow: inset 0 0 0 1px var(--teal); }
.direction-symbol { flex: 0 0 auto; display: grid; place-items: center; width: 29px; height: 29px; border-radius: 8px; background: #edf3ee; color: var(--teal); font: 800 18px/1 'Nunito Sans', sans-serif; }
.round-trip-symbol { background: #f5f0e7; color: #94714a; font-size: 17px; }
.direction-text { min-width: 0; }
.direction-text strong { color: var(--teal-ink); font-size: 11px; line-height: 1.2; font-weight: 900; }
.copy-button:disabled { cursor: not-allowed; opacity: .55; transform: none; }
@media (max-width: 520px) {
  .route-fields { gap: 13px; margin-top: 21px; }
  .location-field { gap: 7px; }
  .location-field > .field-label { font-size: 12px; }
  .location-input-wrap { min-height: 58px; }
  .location-input-wrap input { height: 56px; font-size: 14px; }
  .location-input-wrap input::placeholder { font-size: 12px; }
  .selected-address { padding: 8px 10px; font-size: 12px; }
  .direction-options { gap: 7px; }
  .direction-choice { gap: 7px; padding: 10px 8px; }
  .direction-symbol { width: 26px; height: 26px; }
  .direction-text strong { font-size: 10px; }
}
