@font-face {
  font-family: "Archivo";
  src: url("assets/fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --paper: #F2F2EF;
  --white: #FFFFFF;
  --ink: #16181B;
  --muted: #5C6066;
  --line: #D8D8D2;
  --hivis: #FF5B1F;
  --hivis-ink: #C93E0B;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: "Archivo", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; font-weight: 500; }
h1, h2 {
  font-stretch: 112%;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 0.98;
}
h2 { font-size: clamp(32px, 4.6vw, 54px); }
h3 { font-size: 19px; font-weight: 600; line-height: 1.25; }
p { margin: 0; }

a { color: inherit; }
:focus-visible { outline: 2px solid var(--hivis); outline-offset: 3px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.section-sub { color: var(--muted); max-width: 52ch; margin-top: 14px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 24px;
  background: var(--ink); color: var(--white);
  font-weight: 600; font-size: 15px; text-decoration: none;
  border: 1px solid var(--ink);
  transition: background .15s, color .15s;
}
.btn:hover { background: var(--hivis); border-color: var(--hivis); color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); border-color: var(--ink); color: var(--white); }
.btn-small { min-height: 38px; padding: 0 16px; font-size: 14px; }
.btn-light { background: var(--hivis); border-color: var(--hivis); color: var(--ink); }
.btn-light:hover { background: var(--white); border-color: var(--white); }

/* Nav */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(242,242,239,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.logo { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 20px; text-decoration: none; font-stretch: 112%; letter-spacing: -0.01em; }
.logo-mark { width: 16px; height: 16px; background: var(--hivis); clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 100%, 50% 50%, 0 50%); }
.nav-links { display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--muted); }
.nav-links a { text-decoration: none; }
.nav-links a:hover { color: var(--ink); }
.nav-links span { color: var(--line); }

/* Hero */
.hero { position: relative; background: var(--paper); overflow: hidden; border-bottom: 1px solid var(--line); }
.hero-grid { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(4, 1fr); max-width: var(--wrap); margin: 0 auto; pointer-events: none; }
.hero-grid i { border-left: 1px solid var(--line); }
.hero-grid i:last-child { border-right: 1px solid var(--line); }
.hero-rings { position: absolute; left: 50%; bottom: 0; width: 1200px; transform: translateX(-50%); color: #CFCFC8; pointer-events: none; }
.hero-inner { position: relative; text-align: center; padding-top: clamp(80px, 13vw, 150px); padding-bottom: clamp(90px, 14vw, 170px); }
.hero h1 { font-size: clamp(54px, 10.5vw, 132px); }
.hero-sub { max-width: 54ch; margin: 28px auto 0; color: var(--muted); font-size: 18px; }
.hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 36px; }

/* About */
.about { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(32px, 6vw, 80px); align-items: center; padding-top: clamp(72px, 10vw, 120px); padding-bottom: clamp(72px, 10vw, 120px); }
.about-copy p { color: var(--muted); max-width: 46ch; margin-top: 18px; }
.about-copy p:first-of-type { margin-top: 28px; color: var(--ink); }
.about-video { margin: 0; }
.about-video video { display: block; width: 100%; aspect-ratio: 16 / 9; background: var(--paper); border: 1px solid var(--line); }
.about-video figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; }

/* How */
.how { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: clamp(72px, 10vw, 110px) 0; }
.steps { list-style: none; padding: 0; margin: 56px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ink); }
.steps li { padding: 22px 28px 0 0; }
.steps li + li { padding-left: 28px; border-left: 1px solid var(--line); }
.step-no { display: block; color: var(--hivis-ink); font-size: 13px; font-weight: 600; margin-bottom: 18px; }
.steps p { color: var(--muted); margin-top: 10px; max-width: 34ch; }

/* Sample call */
.call { padding-top: clamp(72px, 10vw, 120px); padding-bottom: clamp(72px, 10vw, 120px); }
.call-panel { margin-top: 44px; border: 1px solid var(--ink); background: var(--white); }
.player { display: grid; grid-template-columns: auto auto 1fr; align-items: center; gap: 18px; padding: 18px 22px; border-bottom: 1px solid var(--ink); }
.play { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--hivis); color: var(--ink); cursor: pointer; display: grid; place-items: center; }
.play svg { width: 22px; height: 22px; fill: currentColor; }
.play .i-pause, .play[aria-pressed="true"] .i-play { display: none; }
.play[aria-pressed="true"] .i-pause { display: block; }
.player-meta { display: flex; flex-direction: column; line-height: 1.3; }
.player-meta strong { font-weight: 600; }
.player-meta span { color: var(--muted); font-size: 14px; }
.scrub { display: flex; align-items: center; gap: 14px; justify-content: flex-end; }
.scrub input { flex: 1; max-width: 420px; }
.time { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }

.call-body { display: grid; grid-template-columns: 1fr 340px; }
.transcript { position: relative; list-style: none; margin: 0; padding: 22px; height: 460px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; scroll-behavior: smooth; }
.transcript li { max-width: 80%; padding: 10px 14px; font-size: 15px; line-height: 1.45; color: #9A9DA2; background: var(--paper); cursor: pointer; transition: color .2s, background .2s; }
.transcript li .who { display: block; font-size: 12px; font-weight: 600; margin-bottom: 2px; }
.transcript li.caller { align-self: flex-end; background: transparent; border: 1px solid var(--line); }
.transcript li.spoken { color: var(--ink); }
.transcript li.agent.spoken .who { color: var(--hivis-ink); }
.transcript li.now { background: #FFE9DF; }
.transcript li.caller.now { background: transparent; border-color: var(--ink); }

.ticket { border-left: 1px solid var(--ink); padding: 22px; background: var(--paper); }
.ticket-note { font-size: 13px; color: var(--muted); margin-top: 4px; }
.ticket dl { margin: 18px 0 0; }
.ticket dl div { padding: 12px 0; border-top: 1px dashed #BDBDB6; }
.ticket dt { font-size: 12px; color: var(--muted); }
.ticket dd { margin: 2px 0 0; font-weight: 600; min-height: 1.4em; }
.ticket dl div:not(.filled) dd { color: transparent; background: linear-gradient(#E3E3DE, #E3E3DE) left center / 70% 10px no-repeat; }
.ticket dl div.filled dd { animation: stamp .35s ease-out; }
@keyframes stamp { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .ticket dl div.filled dd { animation: none; } }

/* Calculator */
.calc { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: clamp(72px, 10vw, 120px) 0; }
.calc-inner { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.calc-form { margin-top: 40px; display: grid; gap: 26px; }
.field { display: block; }
.field-top { display: flex; justify-content: space-between; gap: 16px; font-size: 15px; margin-bottom: 8px; }
.field-top output { font-weight: 700; font-variant-numeric: tabular-nums; }

input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 22px; background: transparent; cursor: pointer; }
input[type="range"]::-webkit-slider-runnable-track { height: 2px; background: linear-gradient(var(--ink), var(--ink)) 0 / var(--fill, 0%) 100% no-repeat, #C9C9C2; }
input[type="range"]::-moz-range-track { height: 2px; background: #C9C9C2; }
input[type="range"]::-moz-range-progress { height: 2px; background: var(--ink); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; margin-top: -8px; border-radius: 50%; background: var(--hivis); border: 2px solid var(--ink); }
input[type="range"]::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: var(--hivis); border: 2px solid var(--ink); }

.calc-result { background: var(--ink); color: var(--white); padding: clamp(24px, 4vw, 40px); }
.result-label { color: #B9BCC1; font-size: 15px; }
.result-big { font-size: clamp(48px, 7vw, 84px); font-weight: 600; font-stretch: 112%; letter-spacing: -0.03em; line-height: 1; margin-top: 10px; color: var(--hivis); font-variant-numeric: tabular-nums; }
.result-big small { display: block; font-size: 15px; font-weight: 400; letter-spacing: 0; color: #B9BCC1; margin-top: 8px; font-stretch: 100%; }
.result-rows { margin: 28px 0 0; }
.result-rows div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid #34383D; }
.result-rows dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.result-foot { margin-top: 22px; font-weight: 600; }
.result-fine { margin-top: 12px; font-size: 13px; color: #9A9EA4; }

/* Handles */
.handles { padding-top: clamp(72px, 10vw, 120px); padding-bottom: clamp(72px, 10vw, 120px); }
.handle-list { list-style: none; padding: 0; margin: 48px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ink); }
.handle-list li { padding: 24px 28px 28px 0; border-bottom: 1px solid var(--line); }
.handle-list li:not(:nth-child(3n+1)) { padding-left: 28px; border-left: 1px solid var(--line); }
.handle-list h3::before { content: ""; display: inline-block; width: 8px; height: 8px; background: var(--hivis); margin-right: 10px; vertical-align: 2px; }
.handle-list p { color: var(--muted); margin-top: 8px; max-width: 34ch; }

/* Demo CTA */
.demo { background: var(--ink); color: var(--white); padding: clamp(80px, 11vw, 130px) 0; }
.demo-inner { text-align: center; }
.demo h2 { font-size: clamp(36px, 6vw, 72px); }
.demo p { color: #B9BCC1; margin: 20px auto 32px; max-width: 48ch; }

/* Footer */
.foot { border-top: 1px solid #2A2D31; background: var(--ink); color: #9A9EA4; font-size: 14px; }
.foot-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 28px; padding-bottom: 28px; flex-wrap: wrap; }
.foot .logo { color: var(--white); font-size: 18px; }

/* Responsive */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .about, .calc-inner { grid-template-columns: 1fr; }
  .call-body { grid-template-columns: 1fr; }
  .ticket { border-left: 0; border-top: 1px solid var(--ink); }
  .handle-list { grid-template-columns: 1fr 1fr; }
  .handle-list li:not(:nth-child(3n+1)) { padding-left: 0; border-left: 0; }
  .handle-list li:nth-child(even) { padding-left: 24px; border-left: 1px solid var(--line); }
}
@media (max-width: 640px) {
  .hero-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .steps li, .steps li + li { padding: 22px 0; border-left: 0; border-bottom: 1px solid var(--line); }
  .player { grid-template-columns: auto 1fr; }
  .scrub { grid-column: 1 / -1; justify-content: stretch; }
  .scrub input { max-width: none; }
  .transcript { height: 380px; padding: 16px; }
  .transcript li { max-width: 92%; }
  .handle-list { grid-template-columns: 1fr; }
  .handle-list li:nth-child(even) { padding-left: 0; border-left: 0; }
  .foot-inner { flex-direction: column; align-items: flex-start; }
}
