:root {
  color-scheme: dark;
  --ink: #07131f;
  --ink-soft: #0c1f2d;
  --panel: #102837;
  --panel-2: #153344;
  --line: #2b4656;
  --muted: #9eb1bc;
  --paper: #f7fbfd;
  --white: #ffffff;
  --acid: #b8ff58;
  --acid-dark: #243c17;
  --orange: #ffbd6b;
  --danger: #ff8d8d;
  --shadow: 0 24px 80px rgba(0, 0, 0, .28);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 88% 5%, rgba(184, 255, 88, .10), transparent 28rem),
    var(--ink);
  color: var(--white);
  font-size: 16px;
  line-height: 1.55;
}
button, input, select { font: inherit; }
button, select { cursor: pointer; }
a { color: inherit; }

.site-header {
  width: min(1180px, calc(100% - 40px));
  min-height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid rgba(255,255,255,.10);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; letter-spacing: -.02em; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--acid);
  color: var(--ink);
  font-size: .76rem;
  letter-spacing: -.04em;
  box-shadow: 0 0 0 6px rgba(184,255,88,.08);
}
nav { display: flex; gap: 24px; }
nav a { color: var(--muted); text-decoration: none; font-size: .9rem; font-weight: 650; }
nav a:hover, nav a:focus-visible { color: var(--acid); }

main { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.workspace { padding: 56px 0 34px; }
.workspace-heading { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr); gap: 40px; align-items: end; margin-bottom: 28px; }
.workspace-heading > p { margin: 0 0 5px; color: var(--muted); max-width: 510px; }
.eyebrow { margin: 0 0 8px; color: var(--acid); font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .14em; }
h1, h2, p { margin-top: 0; }
h1 { max-width: 760px; margin-bottom: 0; font-size: clamp(2.15rem, 5vw, 4.75rem); line-height: .98; letter-spacing: -.055em; }
h2 { margin-bottom: 0; font-size: 1.2rem; letter-spacing: -.025em; }

.calculator-shell { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); overflow: hidden; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow); }
.input-panel, .results-panel { padding: clamp(22px, 4vw, 40px); }
.input-panel { background: var(--paper); color: #132531; }
.results-panel { background: linear-gradient(150deg, var(--panel-2), var(--ink-soft)); }
.panel-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 26px; }
.panel-heading > div { display: flex; align-items: center; gap: 12px; }
.step { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 1px solid currentColor; border-radius: 50%; font-size: .72rem; font-weight: 800; opacity: .72; }
.text-button, .icon-button { border: 0; background: transparent; color: inherit; font-size: .82rem; font-weight: 750; }
.text-button { color: #456271; text-decoration: underline; text-underline-offset: 4px; }
.icon-button { padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); }
.text-button:hover, .text-button:focus-visible { color: #0b5a77; }
.icon-button:hover, .icon-button:focus-visible { border-color: var(--acid); color: var(--acid); }

.field { display: grid; gap: 7px; min-width: 0; }
.field > span { color: #496270; font-size: .78rem; font-weight: 750; }
.field small, .field em { color: #78909d; font-size: .7rem; font-style: normal; font-weight: 650; }
.field input, .field select {
  width: 100%;
  min-height: 48px;
  border: 1px solid #c5d3db;
  border-radius: 10px;
  outline: none;
  background: #fff;
  color: #10212c;
  padding: 10px 12px;
  font-weight: 750;
}
.field input:focus, .field select:focus { border-color: #2a6f8d; box-shadow: 0 0 0 3px rgba(42,111,141,.14); }
.field input[aria-invalid="true"] { border-color: #b33232; box-shadow: 0 0 0 3px rgba(179,50,50,.12); }
.field-wide { margin-bottom: 18px; }
.dimension-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 16px; }
.money-input { position: relative; display: block; }
.money-input b { position: absolute; z-index: 1; left: 13px; top: 50%; transform: translateY(-50%); color: #78909d; }
.money-input input { padding-left: 29px; }
.form-error { min-height: 1.4em; margin: 12px 0 0; color: #9b2929; font-size: .8rem; font-weight: 650; }

.package-visual { height: 164px; margin: 14px 0 2px; overflow: hidden; }
.package-visual svg { display: block; width: 100%; height: 100%; }
.box-face { stroke: #3a6378; stroke-width: 2; }
.box-top { fill: #dff4f9; }
.box-left { fill: #c5e4ec; }
.box-right { fill: #add3df; }
.box-line { fill: none; stroke: #698795; stroke-width: 1.5; stroke-dasharray: 4 4; }
.package-visual text { fill: #42606f; font-size: 13px; font-weight: 750; text-anchor: middle; }

.result-lead { padding: 19px 20px; border: 1px solid var(--line); border-radius: 15px; background: rgba(5,15,23,.38); }
.result-lead p { margin-bottom: 3px; color: var(--muted); font-size: .78rem; }
.result-lead strong { display: block; font-size: clamp(1.7rem, 4vw, 2.6rem); line-height: 1.05; letter-spacing: -.04em; }
.result-lead span { color: var(--muted); font-size: .78rem; }
.profile-list { display: grid; gap: 10px; margin: 15px 0; }
.profile-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; padding: 15px 17px; border: 1px solid var(--line); border-radius: 13px; }
.profile-card.best { border-color: rgba(184,255,88,.62); background: rgba(184,255,88,.06); }
.profile-name { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.profile-name strong { font-size: .94rem; }
.profile-name span { color: var(--muted); font-size: .72rem; }
.best-badge { padding: 2px 7px; border-radius: 99px; background: var(--acid); color: var(--ink) !important; font-size: .63rem !important; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.profile-math { margin-top: 3px; color: var(--muted); font-size: .76rem; }
.profile-result { text-align: right; }
.profile-result strong { display: block; font-size: 1.28rem; letter-spacing: -.03em; }
.profile-result span { color: var(--muted); font-size: .72rem; }
.profile-cost { color: var(--orange) !important; }

.insight-card { padding: 17px 18px; border-radius: 14px; background: var(--acid); color: var(--ink); }
.insight-label { display: block; margin-bottom: 4px; font-size: .66rem; font-weight: 850; text-transform: uppercase; letter-spacing: .1em; }
.insight-card strong { display: block; font-size: 1rem; }
.insight-card p { margin: 5px 0 0; font-size: .78rem; line-height: 1.45; }
.summary-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 13px; }
.summary-row > div { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; }
.summary-row span { display: block; color: var(--muted); font-size: .7rem; }
.summary-row strong { font-size: 1rem; }

.ad-reserve { min-height: 112px; margin: 30px 0 80px; display: grid; place-items: center; align-content: center; border: 1px dashed #365160; border-radius: 14px; color: #718995; text-align: center; }
.ad-reserve span { font-size: .65rem; text-transform: uppercase; letter-spacing: .18em; }
.ad-reserve p { margin: 5px 0 0; font-size: .75rem; }

.method-section { display: grid; grid-template-columns: .55fr .9fr 1.15fr; gap: 24px; padding: 72px 0; border-top: 1px solid var(--line); }
.method-section h2, .faq-section h2 { font-size: clamp(1.8rem, 3vw, 2.8rem); line-height: 1.05; }
.formula-card { align-self: start; padding: 20px; border-radius: 15px; background: var(--paper); color: #132531; }
.formula-card p { margin: 0; }
.formula-card p + p { margin-top: 18px; padding-top: 18px; border-top: 1px solid #d7e2e8; }
.formula-card span { display: block; color: #667f8d; font-size: .72rem; font-weight: 750; }
.formula-card strong { font-size: .94rem; }
.method-copy { color: var(--muted); }
.method-copy p:last-child { margin-bottom: 0; }

.faq-section { padding: 72px 0 88px; border-top: 1px solid var(--line); }
.faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 28px; }
details { border: 1px solid var(--line); border-radius: 14px; background: var(--ink-soft); padding: 17px 18px; }
summary { cursor: pointer; font-weight: 750; }
details p { margin: 12px 0 0; color: var(--muted); font-size: .9rem; }

footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 38px; display: flex; justify-content: space-between; gap: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
footer strong { color: var(--white); }
footer p { margin: 3px 0 0; }
.footer-links { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 18px; }
.footer-links a { color: var(--muted); }
.footer-links a:hover, .footer-links a:focus-visible { color: var(--acid); }

@media (max-width: 880px) {
  .workspace-heading, .calculator-shell, .method-section { grid-template-columns: 1fr; }
  .workspace-heading { gap: 16px; }
  .calculator-shell { border-radius: 18px; }
  .method-section { gap: 18px; }
}

@media (max-width: 620px) {
  .site-header, main, footer { width: min(100% - 24px, 1180px); }
  .site-header { min-height: 64px; }
  nav { gap: 14px; }
  nav a { font-size: .8rem; }
  nav a:nth-child(2) { display: none; }
  .workspace { padding-top: 38px; }
  h1 { font-size: clamp(2.2rem, 13vw, 3.6rem); }
  .input-panel, .results-panel { padding: 22px 17px; }
  .dimension-grid, .two-column, .summary-row, .faq-grid { grid-template-columns: 1fr; }
  .package-visual { height: 145px; }
  .profile-card { gap: 8px; }
  .method-section, .faq-section { padding: 54px 0; }
  footer { flex-direction: column; }
  .footer-links { justify-content: flex-start; }
}

@media print {
  :root { color-scheme: light; }
  body { background: #fff; color: #111; }
  .site-header, .workspace-heading, .input-panel, .ad-reserve, .method-section, .faq-section, footer, .icon-button { display: none !important; }
  main { width: 100%; }
  .workspace { padding: 0; }
  .calculator-shell { display: block; border: 0; box-shadow: none; }
  .results-panel { background: #fff; color: #111; padding: 0; }
  .profile-card, .result-lead, .summary-row > div { border-color: #bbb; }
  .result-lead span, .result-lead p, .profile-name span, .profile-math, .profile-result span, .summary-row span { color: #555; }
}
