/* AccMate — coming soon */

:root {
  --bg: #F5F4F0;
  --ink: #0F1B33;
  --muted: #6B6C66;
  --accent: #0345A5;
  --line: #DEDCD4;
  --track: #E4E3DE;
  --brand: #0345A5;

  --font: "Figtree", "Helvetica Neue", Arial, sans-serif;
  --gutter: clamp(1.5rem, 5vw, 4rem);
  --mark: clamp(2.75rem, 5.2vw, 5rem);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

p, h1 { margin: 0; }

/* ---------- Intro (2.0s total) ----------
   0.00–0.85s  logo grows (scale 7% → 100%, ease-out) and fades in (0–0.7s)
   0.85–1.20s  hold
   1.20–2.00s  blue overlay and logo fade out, linearly, revealing the site
   2.00s       overlay finished and removed; site fully visible          */

.intro {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: var(--brand);
  pointer-events: none;
  animation: intro-out 2000ms linear both;
}

.intro__mark {
  width: clamp(6.5rem, 24vw, 18.75rem);
  height: auto;
  aspect-ratio: 1250.7 / 1254.9;
  fill: #fff;
  will-change: transform, opacity;
  animation:
    mark-scale 850ms cubic-bezier(0.25, 0.46, 0.45, 0.94) both,
    mark-fade 700ms ease-out both;
}

@keyframes mark-scale {
  from { transform: scale(0.07); }
  to   { transform: scale(1); }
}

@keyframes mark-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes intro-out {
  0%, 60%  { opacity: 1; visibility: visible; }
  100%     { opacity: 0; visibility: hidden; }
}

/* ---------- Corner arcs ---------- */

.arc {
  position: fixed;
  z-index: 0;
  aspect-ratio: 1;
  border: 1px solid rgba(3, 69, 165, 0.42);
  border-radius: 50%;
  pointer-events: none;
}

.arc--tl { width: 95vw; left: -60vw; top: -60vw; }
.arc--br { width: 80vw; right: -46vw; bottom: -46vw; }

@media (min-width: 48rem) {
  .arc--tl { width: 64vw; left: -38vw; top: -47.5vw; }
  .arc--br { width: 54vw; right: -32.5vw; bottom: -34vw; }
}

/* ---------- Layout ---------- */

.page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  width: 100%;
  max-width: 82rem;
  margin: 0 auto;
  padding:
    max(1.5rem, env(safe-area-inset-top))
    max(var(--gutter), env(safe-area-inset-right))
    max(clamp(2rem, 9vh, 4.5rem), env(safe-area-inset-bottom))
    max(var(--gutter), env(safe-area-inset-left));
}

.main {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 5vh, 4rem) 0;
  text-align: center;
}

/* ---------- Content ---------- */

.brand {
  display: flex;
  align-items: center;
  gap: calc(var(--mark) * 0.5);
  margin-bottom: clamp(1.75rem, 4.5vh, 3.25rem);
}

.brand__mark {
  display: block;
  height: var(--mark);
  width: auto;
  aspect-ratio: 1250.7 / 1254.9;
  fill: var(--accent);
}

.brand__rule {
  width: 1.5px;
  height: calc(var(--mark) * 1.15);
  background: var(--ink);
}

.brand__name {
  font-size: calc(var(--mark) * 0.78);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1;
  color: var(--ink);
}

.headline {
  max-width: 20ch;
  font-size: clamp(2.25rem, 8.5vw, 3.5rem);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.lede {
  max-width: 30rem;
  margin-top: 1.25rem;
  font-size: clamp(1rem, 2.4vw, 1.125rem);
  line-height: 1.65;
  color: var(--muted);
}

.status {
  margin-top: clamp(1.75rem, 4vh, 2.5rem);
  padding: 0.8rem 2.25rem;
  border: 1.5px solid var(--accent);
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  line-height: 1.2;
  color: var(--accent);
}

.progress {
  width: min(27rem, 72vw);
  height: 6px;
  margin-top: 1.75rem;
  border-radius: 999px;
  background: var(--track);
  overflow: hidden;
}

.progress__fill {
  display: block;
  width: 48%;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
  transform-origin: left center;
}

.footer {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.5vw, 2rem);
  width: 100%;
  max-width: 79rem;
  margin: 0 auto;
  font-size: 0.8125rem;
  color: var(--muted);
  text-align: center;
}

.footer p { white-space: nowrap; }

.footer__rule {
  flex: 1;
  height: 1px;
  background: var(--line);
}

@media (min-width: 48rem) {
  .headline { font-size: clamp(3rem, 3.6vw, 4.5rem); max-width: none; }
  .footer { font-size: 0.9375rem; }
}

/* ---------- Headline reveal: word by word, finished by 2.00s ----------
   The rest of the page is already in place under the blue overlay.
   word        start    length   end
   Something   1.20s    0.40s    1.60s
   is          1.35s    0.40s    1.75s
   taking      1.50s    0.40s    1.90s
   shape.      1.60s    0.40s    2.00s                                    */

.w {
  display: inline-block;
  animation: word-in 400ms ease-out both;
}

.w:nth-child(1) { animation-delay: 1200ms; }
.w:nth-child(2) { animation-delay: 1350ms; }
.w:nth-child(3) { animation-delay: 1500ms; }
.w:nth-child(4) { animation-delay: 1600ms; }

@keyframes word-in {
  from { opacity: 0; transform: translateY(0.25em); }
  to   { opacity: 1; transform: none; }
}

/* ---------- No intro: repeat visits and reduced motion ---------- */

.intro-skip .intro { display: none; }
.intro-skip .w { animation: none; }

@media (prefers-reduced-motion: reduce) {
  .intro { display: none; }

  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}
