:root {
  --ink: #18221d;
  --muted: #6f756f;
  --paper: #f5f2eb;
  --panel: #fcfaf5;
  --line: #d8d5cd;
  --accent: #d8ff48;
  --accent-dark: #9abc22;
  --forest: #1e3027;
  --error: #a1372a;
  --radius: 5px;
  --shadow: 0 28px 80px rgba(22, 31, 26, 0.1);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(rgba(24, 34, 29, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(24, 34, 29, 0.035) 1px, transparent 1px),
    var(--paper);
  background-size: 40px 40px;
  font-family: "Manrope", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input, select { font: inherit; }
button, select { cursor: pointer; }
.skip-link { position: fixed; top: -80px; left: 16px; z-index: 20; padding: 10px 14px; color: white; background: var(--forest); }
.skip-link:focus { top: 16px; }

.site-header {
  width: min(1240px, calc(100% - 48px));
  height: 86px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; font-size: 21px; font-weight: 800; letter-spacing: -0.05em; }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: var(--accent); background: var(--forest); }
.brand-mark svg { width: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.header-meta { display: flex; align-items: center; gap: 9px; color: var(--muted); font: 500 11px "DM Mono", monospace; letter-spacing: 0.03em; text-transform: uppercase; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-dark); box-shadow: 0 0 0 4px rgba(154, 188, 34, 0.13); }

main { width: min(1240px, calc(100% - 48px)); margin: 0 auto; }
.hero { padding: 88px 0 78px; position: relative; }
.eyebrow { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; font: 500 11px "DM Mono", monospace; letter-spacing: 0.12em; text-transform: uppercase; }
.eyebrow span, .step-number { color: var(--muted); }
.eyebrow::after { width: 48px; height: 1px; content: ""; background: var(--ink); }
.hero h1 { max-width: 920px; margin: 0; font-size: clamp(54px, 7.1vw, 102px); font-weight: 600; line-height: 0.98; letter-spacing: -0.075em; }
.hero h1 em { font-family: Georgia, serif; font-weight: 400; letter-spacing: -0.055em; }
.hero-copy { width: min(490px, 100%); margin: 34px 0 0 51%; color: var(--muted); font-size: 16px; line-height: 1.75; }
.hero-stats { margin-top: 64px; padding-top: 28px; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.hero-stats div { display: flex; flex-direction: column; gap: 4px; padding-left: 24px; border-left: 1px solid var(--line); }
.hero-stats div:first-child { padding-left: 0; border-left: 0; }
.hero-stats strong { font-size: 25px; letter-spacing: -0.05em; }
.hero-stats span { color: var(--muted); font-size: 12px; }

.workspace { display: grid; grid-template-columns: minmax(0, 1.38fr) minmax(330px, 0.78fr); align-items: start; background: var(--panel); border: 1px solid var(--line); box-shadow: var(--shadow); }
.form-panel { padding: 48px 52px 52px; }
.section-heading { display: flex; justify-content: space-between; align-items: end; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.section-heading > div { display: flex; align-items: baseline; gap: 14px; }
.step-number { font: 500 11px "DM Mono", monospace; }
.section-heading h2 { margin: 0; font-size: 27px; letter-spacing: -0.045em; }
.section-heading p { margin: 0; color: var(--muted); font-size: 12px; }
.alert { margin-top: 22px; padding: 13px 15px; border-left: 3px solid var(--error); color: var(--error); background: #fff0ed; font-size: 13px; }

fieldset { margin: 0; padding: 32px 0 35px; border: 0; border-bottom: 1px solid var(--line); }
legend { margin-bottom: 20px; padding: 0; font: 500 11px "DM Mono", monospace; letter-spacing: 0.1em; text-transform: uppercase; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 21px 18px; }
.wide-field { grid-column: span 2; }
label { min-width: 0; display: flex; flex-direction: column; gap: 8px; }
label.has-open-select { position: relative; z-index: 50; }
label > span { font-size: 12px; font-weight: 700; }
input, select { width: 100%; height: 48px; padding: 0 13px; color: var(--ink); background-color: white; border: 1px solid #cfccc4; border-radius: var(--radius); outline: none; transition: border-color 160ms, box-shadow 160ms; }
input:focus, select:focus { border-color: var(--forest); box-shadow: 0 0 0 3px rgba(30, 48, 39, 0.09); }
.modern-select { position: relative; }
.modern-select.is-open { z-index: 50; }
.modern-select__native { width: 1px; height: 1px; position: absolute; inset: 24px auto auto 10px; opacity: 0; pointer-events: none; }
.modern-select__button { width: 100%; height: 48px; padding: 0 13px; display: flex; align-items: center; justify-content: space-between; color: var(--ink); background: white; border: 1px solid #cfccc4; border-radius: var(--radius); text-align: left; outline: none; transition: border-color 160ms, box-shadow 160ms, background 160ms; }
.modern-select__button:hover:not(:disabled) { border-color: #979d96; background: #fff; }
.modern-select__button:focus-visible, .modern-select.is-open .modern-select__button { border-color: var(--forest); box-shadow: 0 0 0 3px rgba(30, 48, 39, 0.09); }
.modern-select__button.is-placeholder { color: #767b76; }
.modern-select__button:disabled { cursor: not-allowed; color: #a2a29e; background: #eeece7; }
.modern-select__button > svg { width: 19px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.5; transition: transform 180ms; }
.modern-select.is-open .modern-select__button > svg { transform: rotate(180deg); }
.modern-select__menu { width: 100%; min-width: 220px; margin-top: 7px; padding: 7px; position: absolute; z-index: 20; top: 100%; left: 0; background: #fffefa; border: 1px solid #c8c7c0; border-radius: 9px; box-shadow: 0 18px 45px rgba(20, 32, 25, .17), 0 3px 10px rgba(20, 32, 25, .08); transform-origin: top center; animation: dropdown-in 150ms ease-out; }
@keyframes dropdown-in { from { opacity: 0; transform: translateY(-5px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
.modern-select__search { height: 42px; margin-bottom: 6px; position: relative; border-bottom: 1px solid #e1dfd8; }
.modern-select__search svg { width: 17px; position: absolute; left: 10px; top: 11px; fill: none; stroke: #7b817c; stroke-width: 1.5; }
.modern-select__search input { height: 36px; padding: 0 9px 0 34px; border: 0; background: transparent; font-size: 12px; box-shadow: none; }
.modern-select__search input:focus { box-shadow: none; }
.modern-select__list { max-height: 248px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #bdc2bc transparent; }
.modern-select__option { width: 100%; min-height: 39px; padding: 8px 10px; display: flex; align-items: center; justify-content: space-between; color: #334039; background: transparent; border: 0; border-radius: 5px; font-size: 12px; text-align: left; transition: background 120ms, color 120ms; }
.modern-select__option:hover, .modern-select__option:focus-visible { color: var(--ink); background: #eff1e8; outline: none; }
.modern-select__option[aria-selected="true"] { color: var(--forest); background: #eff8c9; font-weight: 700; }
.modern-select__option svg { width: 16px; flex: 0 0 auto; fill: none; stroke: var(--accent-dark); stroke-width: 2; opacity: 0; }
.modern-select__option[aria-selected="true"] svg { opacity: 1; }
.input-with-unit { position: relative; }
.input-with-unit input { padding-right: 54px; }
.input-with-unit > span { position: absolute; top: 50%; right: 13px; transform: translateY(-50%); color: var(--muted); font: 500 10px "DM Mono", monospace; }
.primary-button { width: 100%; height: 58px; margin-top: 30px; padding: 0 22px; display: flex; align-items: center; justify-content: space-between; color: white; background: var(--forest); border: 0; border-radius: var(--radius); font-weight: 700; transition: transform 160ms, background 160ms; }
.primary-button:hover { background: #294034; transform: translateY(-1px); }
.primary-button:disabled { cursor: wait; opacity: 0.7; transform: none; }
.primary-button svg { width: 21px; fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.result-panel { min-height: 690px; position: sticky; top: 20px; color: white; background: var(--forest); overflow: hidden; }
.result-panel::before { content: ""; position: absolute; width: 420px; height: 420px; top: -190px; right: -190px; border: 1px solid rgba(255,255,255,.11); border-radius: 50%; box-shadow: 0 0 0 70px rgba(255,255,255,.025), 0 0 0 140px rgba(255,255,255,.018); }
.result-empty, .result-content { min-height: 690px; position: relative; z-index: 1; padding: 54px 44px; }
.result-empty { display: flex; flex-direction: column; justify-content: flex-end; }
.radar { width: 116px; height: 116px; margin-bottom: auto; position: relative; display: grid; place-items: center; }
.radar span { position: absolute; border: 1px solid rgba(216,255,72,.22); border-radius: 50%; }
.radar span:nth-child(1) { inset: 0; }.radar span:nth-child(2) { inset: 20px; }.radar span:nth-child(3) { inset: 40px; }
.radar i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 18px var(--accent); }
.radar::after { width: 50%; height: 1px; position: absolute; left: 50%; content: ""; background: linear-gradient(90deg, var(--accent), transparent); transform-origin: left; animation: scan 3s linear infinite; }
@keyframes scan { to { transform: rotate(360deg); } }
.mono-label { margin: 0 0 15px; color: var(--accent); font: 500 10px "DM Mono", monospace; letter-spacing: 0.12em; }
.result-empty h2 { margin: 0 0 17px; font-size: 34px; line-height: 1.14; letter-spacing: -0.05em; }
.result-empty > p:last-child { margin: 0; color: #aeb9b3; font-size: 13px; line-height: 1.7; }
.result-content { display: flex; flex-direction: column; }
.result-topline { display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.success-badge { display: flex; gap: 8px; align-items: center; color: var(--accent); font: 500 10px "DM Mono", monospace; letter-spacing: .08em; text-transform: uppercase; }
.success-badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.result-vehicle { max-width: 170px; color: #b8c0bc; font-size: 11px; text-align: right; }
.price-block { padding: 80px 0 45px; border-bottom: 1px solid rgba(255,255,255,.13); }
.price-block > span { color: #aeb9b3; font-size: 11px; }
.price-block strong { margin: 10px 0 7px; display: block; color: var(--accent); font-size: clamp(35px, 4vw, 52px); letter-spacing: -.07em; }
.price-block p { margin: 0; color: #ccd2ce; font-size: 12px; }
.comparison-card { margin: 28px 0; padding: 20px; display: flex; justify-content: space-between; align-items: center; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); }
.comparison-card div { display: flex; flex-direction: column; gap: 6px; }
.comparison-card span { color: #aeb9b3; font-size: 10px; }
.comparison-card strong { font-size: 17px; }
.difference-badge { padding: 6px 8px; color: var(--ink) !important; background: var(--accent); font: 600 10px "DM Mono", monospace !important; }
.detail-list { border-top: 1px solid rgba(255,255,255,.13); }
.detail-list div { padding: 14px 0; display: flex; justify-content: space-between; border-bottom: 1px solid rgba(255,255,255,.1); }
.detail-list span { color: #aeb9b3; font-size: 11px; }
.detail-list strong { font: 500 11px "DM Mono", monospace; }
.result-note { margin: auto 0 0; padding-top: 28px; color: #8f9d96; font-size: 10px; line-height: 1.6; }

footer { width: min(1240px, calc(100% - 48px)); margin: 54px auto 0; padding: 26px 0 42px; display: flex; justify-content: space-between; color: var(--muted); border-top: 1px solid var(--line); font: 500 10px "DM Mono", monospace; text-transform: uppercase; }

@media (max-width: 900px) {
  .hero-copy { margin-left: 35%; }
  .workspace { grid-template-columns: 1fr; }
  .result-panel { min-height: 560px; position: relative; top: auto; }
  .result-empty, .result-content { min-height: 560px; }
}
@media (max-width: 640px) {
  .site-header, main, footer { width: min(100% - 28px, 1240px); }
  .header-meta { display: none; }
  .site-header { height: 72px; }
  .hero { padding: 60px 0 54px; }
  .hero h1 { font-size: 51px; }
  .hero-copy { margin: 27px 0 0; }
  .hero-stats { grid-template-columns: 1fr; gap: 18px; margin-top: 44px; }
  .hero-stats div, .hero-stats div:first-child { padding: 0 0 18px; border-left: 0; border-bottom: 1px solid var(--line); }
  .form-panel { padding: 32px 20px 28px; }
  .section-heading { align-items: flex-start; }
  .section-heading p { display: none; }
  .form-grid, .technical-grid { grid-template-columns: 1fr; }
  .wide-field { grid-column: auto; }
  .result-empty, .result-content { padding: 38px 27px; }
  .price-block { padding-top: 62px; }
  footer { flex-direction: column; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; }
}
