/* ==========================================================================
   AI Status Check — single-page marketing site
   Dark, minimal, one accent color. Mobile-first.
   ========================================================================== */

:root {
  --bg: #0a0a0a;            /* near-black page background */
  --bg-alt: #0f1110;        /* slightly lifted panel background */
  --text: #f2f2f0;          /* off-white body text */
  --text-dim: #9a9a96;      /* muted secondary text */
  --accent: #2ee6a0;        /* clinical monitor green — the only accent */
  --accent-dim: rgba(46, 230, 160, 0.14);
  --line: rgba(255, 255, 255, 0.10);  /* hairline borders */
  --font: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.container {
  width: min(100% - 3rem, 68rem);
  margin-inline: auto;
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   Type
   -------------------------------------------------------------------------- */

.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.hero-headline {
  font-size: clamp(2.5rem, 8vw, 5.5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  max-width: 16ch;
}

.section-headline {
  font-size: clamp(1.75rem, 4.5vw, 3rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin-bottom: 1.5rem;
  max-width: 20ch;
}

.copy-subhead {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.9rem;
}

.section-copy p {
  max-width: 46ch;
  color: var(--text-dim);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
}

.section-copy p + p { margin-top: 1.1em; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding-block: 6rem;
}

.hero-subhead {
  margin-top: 1.75rem;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  color: var(--text-dim);
  max-width: 40ch;
}

/* --------------------------------------------------------------------------
   PULSE WAVEFORM — the EKG line behind the hero
   --------------------------------------------------------------------------
   How it works (tweak here):

   • .pulse-base  is the full trace, always visible but dim. It sets the
     "resting monitor" mood on load.
   • .pulse-live  is the SAME path, bright + glowing. JS sets its
     stroke-dasharray/-offset so it draws in from left to right, synced
     to scroll progress through the hero (see script.js → updatePulse).
   • .pulse-dot   is the glowing tip that rides the end of the drawn line.

   Tuning knobs:
   - Trace shape:        edit the `d` attribute on both paths in index.html
                         (keep them identical).
   - Glow strength:      the drop-shadow blur radii below.
   - Line weight:        stroke-width on the two paths.
   - Vertical position:  .pulse-wrap { top }.
   - Scroll feel:        PULSE constants at the top of script.js.
   -------------------------------------------------------------------------- */

.pulse-wrap {
  position: absolute;
  inset-inline: 0;
  top: 58%;               /* waveform sits just below the headline */
  height: 240px;
  pointer-events: none;
}

.pulse-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.pulse-base {
  fill: none;
  stroke: rgba(255, 255, 255, 0.08);   /* faint resting trace */
  stroke-width: 1.5;
}

.pulse-live {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  /* Soft monitor glow around the bright trace */
  filter: drop-shadow(0 0 6px rgba(46, 230, 160, 0.55))
          drop-shadow(0 0 18px rgba(46, 230, 160, 0.25));
}

.pulse-dot {
  fill: var(--accent);
  filter: drop-shadow(0 0 8px rgba(46, 230, 160, 0.9));
  /* Calm, steady breathing on the tip — diagnostic, not alarming */
  animation: dot-breathe 2.4s ease-in-out infinite;
}

@keyframes dot-breathe {
  0%, 100% { opacity: 0.7; }
  50%      { opacity: 1; }
}

/* Short viewports (landscape phones, small panes): the centered hero text
   would collide with the waveform, so pin it low and quiet it down. */
@media (max-height: 640px) {
  .pulse-wrap {
    top: auto;
    bottom: 0;
    height: 150px;
    opacity: 0.75;
  }
}

/* Reduced motion: show the finished trace, no drawing, no breathing */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pulse-dot { animation: none; }
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* --------------------------------------------------------------------------
   Scroll cue
   -------------------------------------------------------------------------- */

.scroll-cue {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--text-dim);
  z-index: 1;
}

.scroll-cue-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.scroll-cue-line {
  width: 1px;
  height: 2.75rem;
  background: linear-gradient(var(--text-dim), transparent);
  animation: cue-drop 2s ease-in-out infinite;
  transform-origin: top;
}

@keyframes cue-drop {
  0%   { transform: scaleY(0); opacity: 0; }
  40%  { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; }
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section {
  padding-block: clamp(6rem, 14vh, 10rem);
}

.section-alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--line);
}

/* Two-column editorial split: headline block left, running copy right.
   Collapses to a single column below 900px. */
.split {
  display: grid;
  gap: 2rem;
  align-items: start;
}

.split .section-headline { margin-bottom: 0; }

@media (min-width: 900px) {
  .split { grid-template-columns: 5fr 6fr; gap: 4rem; }
}

/* Scroll reveal (IntersectionObserver adds .is-visible) */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   Function grid
   -------------------------------------------------------------------------- */

.function-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  margin-top: 3rem;
}

/* Hairline cell borders via outline so a ragged last row leaves no
   stray background showing through empty grid cells. */
.function-grid li {
  outline: 1px solid var(--line);
  padding: 1.75rem 1.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: color 0.25s ease, background 0.25s ease;
}

.function-grid li:hover {
  color: var(--accent);
  background: var(--accent-dim);
}

@media (min-width: 640px) {
  .function-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 960px) {
  .function-grid { grid-template-columns: repeat(5, 1fr); }
}

/* --------------------------------------------------------------------------
   Contact form
   -------------------------------------------------------------------------- */

.contact-lede {
  margin-bottom: 3rem;
  color: var(--text-dim);
  max-width: 46ch;
  font-size: clamp(1rem, 1.5vw, 1.2rem);
}

.contact-form {
  max-width: 26rem;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.field { display: flex; flex-direction: column; gap: 0.5rem; }

.field label {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.field input {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 0.6rem 0;
  font: inherit;
  font-size: 1.05rem;
  color: var(--text);
  border-radius: 0;
  transition: border-color 0.25s ease;
}

.field input:focus {
  outline: none;
  border-bottom-color: var(--accent);
}

/* Keep browser autofill from flashing a light background on the dark theme */
.field input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px var(--bg) inset;
  -webkit-text-fill-color: var(--text);
  caret-color: var(--text);
  transition: background-color 9999s ease-out;
}

.btn-submit {
  margin-top: 0.75rem;
  align-self: flex-start;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--bg);
  background: var(--accent);
  border: 1px solid var(--accent);
  padding: 0.9rem 2rem;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}

.btn-submit:hover,
.btn-submit:focus-visible {
  background: transparent;
  color: var(--accent);
}

.form-note {
  font-size: 0.9rem;
  color: var(--accent);
  min-height: 1.4em;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.footer {
  border-top: 1px solid var(--line);
  padding-block: 2rem;
}

.footer .container {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}
