/* ==========================================================================
   AdOperator marketing site
   Monochrome black/white/gray shell. One colorful moment: an ambient, blurred,
   drifting light field behind the hero headline. Editorial minimal aesthetic.
   ========================================================================== */

:root {
  /* Palette */
  --bg: #0a0a0a;
  --panel: rgba(18, 22, 28, 0.92);          /* lifted card surface */
  --tab-off: #0e0e0e;        /* recessed inactive tab */
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.6);
  --muted-dim: rgba(255, 255, 255, 0.4);
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.15);

  /* Light-field accents (only used in the hero canvas / static fallback) */
  --violet: #7c3aed;
  --magenta: #d946ef;
  --cyan: #38bdf8;
  --lime: #10b981;
  --brand-start: #10b981;
  --brand-end: #38bdf8;

  /* Type */
  --font-display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --font-body: "Inter", ui-sans-serif, system-ui, -apple-system, sans-serif;

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* Layout */
  --maxw: 1080px;
  --radius: 10px;
  --nav-h: 64px;
}

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

* { margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}

img, svg, canvas { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

button { font-family: inherit; cursor: pointer; background: none; border: none; color: inherit; }

::selection {
  background: rgba(255, 255, 255, 0.85);
  color: #0a0a0a;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* Honeypot: kept in the DOM for bots, unreachable for people. */
.hp {
  position: absolute !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 1px; height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Buttons + plain links
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.01em;
  transition: transform 0.2s var(--ease-out), background-color 0.2s ease, opacity 0.2s ease;
}

.btn--primary {
  background: linear-gradient(135deg, var(--brand-start), var(--brand-end));
  color: #ffffff;
  padding: 0.85em 1.35em;
  font-size: 0.98rem;
  box-shadow: 0 14px 34px -18px rgba(56, 189, 248, 0.9);
}
.btn--primary:hover { opacity: 0.92; }
.btn--primary:active { transform: translateY(1px); }

.btn:focus-visible,
.link-plain:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

/* Secondary actions are plain underlined text links. */
.link-plain {
  font-family: var(--font-body);
  font-size: 1.02rem;
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--line-2);
  transition: text-decoration-color 0.2s ease;
}
.link-plain:hover { text-decoration-color: currentColor; }

/* --------------------------------------------------------------------------
   Fixed top nav
   -------------------------------------------------------------------------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
}
.nav.is-scrolled {
  background: rgba(10, 10, 10, 0.85);
  border-bottom-color: var(--line);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  backdrop-filter: saturate(140%) blur(8px);
}

.nav__inner {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, 2rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.62rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
}
.wordmark__mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background:
    radial-gradient(circle at 34% 28%, rgba(255, 255, 255, 0.82), transparent 16%),
    linear-gradient(135deg, rgba(16, 185, 129, 0.95), rgba(56, 189, 248, 0.95));
  box-shadow: 0 12px 26px -15px rgba(56, 189, 248, 1);
}
.wordmark__brain {
  width: 17px;
  height: 14px;
  border: 1.7px solid rgba(255, 255, 255, 0.9);
  border-radius: 52% 48% 48% 52% / 58% 58% 42% 42%;
  position: relative;
}
.wordmark__brain::before,
.wordmark__brain::after {
  content: "";
  position: absolute;
  inset: 3px auto auto 50%;
  width: 1.5px;
  height: 7px;
  background: rgba(255, 255, 255, 0.82);
  transform: translateX(-50%);
}
.wordmark__brain::after {
  inset: 6px auto auto 4px;
  width: 8px;
  height: 1.5px;
  transform: none;
}

.nav__right {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 2.4vw, 1.6rem);
}

.nav__link {
  font-size: 0.9rem;
  color: var(--muted);
  transition: color 0.2s ease;
}
.nav__link:hover { color: var(--text); }

/* --------------------------------------------------------------------------
   1. HERO
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: calc(var(--nav-h) + clamp(1.4rem, 5vh, 3rem)) clamp(1.1rem, 4vw, 2rem) clamp(5.5rem, 12vh, 7rem);
  overflow: hidden;
}

/* Animated agentic core, contained to the hero only. */
.hero__field {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(72vw, 740px);
  height: min(72vw, 740px);
  transform: translate(-50%, -50%);
  z-index: 0;
  pointer-events: none;
  opacity: 0.72;
  filter: saturate(125%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 0%, #000 56%, transparent 78%);
  mask-image: radial-gradient(circle at 50% 50%, #000 0%, #000 56%, transparent 78%);
}

/* Static painterly fallback (shown under prefers-reduced-motion). */
.hero__field-static {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.85;
  filter: blur(36px) saturate(130%);
  background:
    radial-gradient(38% 40% at 34% 36%, rgba(124, 58, 237, 0.55), transparent 70%),
    radial-gradient(34% 36% at 62% 32%, rgba(217, 70, 239, 0.45), transparent 70%),
    radial-gradient(40% 42% at 52% 58%, rgba(34, 211, 238, 0.4), transparent 72%),
    radial-gradient(30% 34% at 70% 62%, rgba(163, 230, 53, 0.32), transparent 72%);
  -webkit-mask-image: radial-gradient(72% 66% at 50% 40%, #000 0%, #000 42%, transparent 86%);
  mask-image: radial-gradient(72% 66% at 50% 40%, #000 0%, #000 42%, transparent 86%);
}

.hero__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 62rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1rem, 2.8vw, 1.7rem);
}

.hero__eyebrow {
  font-size: clamp(0.92rem, 1.7vw, 1.05rem);
  color: var(--muted);
  letter-spacing: 0.01em;
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.7rem, 8.5vw, 6.4rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  text-wrap: balance;
  text-shadow: 0 2px 40px rgba(10, 10, 10, 0.55);
}
.hero__line { display: block; }
.hero__line--accent { color: var(--lime); }

.hero__previews {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1rem, 3vw, 2rem);
  width: 100%;
  max-width: 54rem;
  margin-top: clamp(0.4rem, 2vw, 1rem);
}

.preview {
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding-top: 0.95rem;
  border-top: 1px solid var(--line);
  transition: border-color 0.25s ease, color 0.25s ease;
}
.preview:hover,
.preview:focus-visible { border-top-color: rgba(255, 255, 255, 0.45); outline: none; }

.preview__label {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.86rem;
  color: var(--muted);
  transition: color 0.25s ease;
}
.preview:hover .preview__label,
.preview:focus-visible .preview__label { color: var(--text); }

.preview__text {
  font-size: clamp(0.95rem, 1.4vw, 1.02rem);
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.5;
}

/* Discover CTA at the bottom of the hero. */
.scrollcue {
  position: absolute;
  bottom: clamp(1.25rem, 3.5vh, 2.4rem);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  min-width: 132px;
  animation: cue-drift 2.2s var(--ease-out) infinite;
}
@keyframes cue-drift {
  0%   { transform: translate(-50%, -2px); }
  50%  { transform: translate(-50%, 4px); }
  100% { transform: translate(-50%, -2px); }
}

/* --------------------------------------------------------------------------
   2. PROVIDER LINE
   -------------------------------------------------------------------------- */
.providers {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(3rem, 9vh, 5.5rem) clamp(1.1rem, 4vw, 2rem);
  text-align: center;
}
.providers__line {
  color: var(--muted);
  font-size: clamp(0.92rem, 1.8vw, 1.05rem);
  text-wrap: balance;
  max-width: 46rem;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   3. TAB PANEL
   -------------------------------------------------------------------------- */
.panel-section {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 clamp(1.1rem, 4vw, 2rem) clamp(4rem, 11vh, 7rem);
}

.tabs { position: relative; }

.tablist {
  display: flex;
  align-items: flex-end;               /* tab bottoms sit flush on the panel edge */
  gap: 6px;
  padding-left: clamp(0.6rem, 3vw, 1.6rem);
  position: relative;
  z-index: 2;
}

.tab {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(0.9rem, 2.4vw, 1.05rem);
  letter-spacing: -0.01em;
  color: var(--muted);
  background: var(--tab-off);          /* recessed, darker fill */
  border: 1px solid var(--line);
  border-radius: 10px 10px 0 0;
  padding: 0.7em 1.25em;
  margin-bottom: -1px;                 /* bottom line coincides with panel border */
  white-space: nowrap;
  transition: color 0.2s ease, background-color 0.2s ease;
}
.tab:hover { color: rgba(255, 255, 255, 0.85); }

.tab[aria-selected="true"] {
  color: var(--text);
  background: var(--panel);            /* same fill as the panel body */
  border-bottom-color: var(--panel);   /* dissolve the seam over the panel border */
  padding-top: calc(0.7em + 3px);      /* slightly taller reads as lifted */
  box-shadow: 0 -6px 18px -10px rgba(0, 0, 0, 0.85);
}

.panel {
  position: relative;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.02)),
    var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.9);
  padding: clamp(1.35rem, 3.4vw, 2.35rem);
}

.tabpanel[hidden] { display: none; }

.tabpanel.is-entering {
  animation: panel-in 0.28s var(--ease-out);
}
@keyframes panel-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}

.tabpanel__grid {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: stretch;
  grid-template-areas:
    "line"
    "feats"
    "price"
    "form";
}
.tabpanel__grid > * { min-width: 0; }
.panel-line { grid-area: line; }
.features   { grid-area: feats; }
.pricing    { grid-area: price; }
.lead-form  { grid-area: form; }

.panel-line {
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  margin-bottom: 1.4rem;
  text-align: center;
}

/* Plain feature list: no icons, hairline dividers between rows. */
.features {
  list-style: none;
  margin-bottom: 1.8rem;
  max-width: 620px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}
.features li {
  font-size: clamp(0.98rem, 1.7vw, 1.08rem);
  line-height: 1.4;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
}
.features li:first-child { border-top: none; padding-top: 0; }

/* Pricing */
.pricing {
  padding-top: 1.6rem;
  margin-top: 0.4rem;
  border-top: 1px solid var(--line);
  text-align: center;
  max-width: 560px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}
.pricing__amount {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.6rem, 7vw, 3.8rem);
  line-height: 1;
  letter-spacing: -0.03em;
}
.pricing__period {
  font-size: 0.42em;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: -0.01em;
}
.pricing__label {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 0.55rem;
}
.pricing__note {
  color: var(--muted);
  font-size: 0.95rem;
  margin-top: 0.35rem;
}
.pricing__note s {
  color: var(--muted-dim);
  text-decoration-thickness: 1px;
}

/* Lead form */
.lead-form {
  margin: 1.8rem auto 0;
  max-width: 560px;
  width: 100%;
  text-align: center;
}
.lead-form__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
}
.lead-form__input {
  flex: 1 1 14rem;
  min-width: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line-2);
  border-radius: 999px;
  padding: 0.85em 1.3em;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.lead-form__input::placeholder { color: var(--muted-dim); }
.lead-form__input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.55);
  background: rgba(255, 255, 255, 0.05);
}
.lead-form__input:user-invalid { border-color: #f87171; }

.lead-form__submit { flex: 0 1 auto; white-space: nowrap; }

.lead-form__hint {
  color: var(--muted-dim);
  font-size: 0.85rem;
  margin-top: 0.7rem;
}
.lead-form__status {
  font-size: 0.92rem;
  min-height: 1.2em;
  margin-top: 0.35rem;
  color: var(--muted);
}
.lead-form__status.is-success { color: var(--lime); }
.lead-form__status.is-error { color: #fca5a5; }

.lead-form.is-pending .lead-form__submit,
.lead-form.is-done .lead-form__submit { opacity: 0.55; pointer-events: none; }
.lead-form.is-pending .lead-form__input { opacity: 0.7; }

/* --------------------------------------------------------------------------
   4. CLOSING
   -------------------------------------------------------------------------- */
.closing {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(4rem, 13vh, 8rem) clamp(1.1rem, 4vw, 2rem);
  text-align: center;
  display: grid;
  gap: 1.6rem;
  justify-items: center;
}
.closing__line {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.9rem, 5.5vw, 3.6rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

/* --------------------------------------------------------------------------
   5. FOOTER
   -------------------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--line);
  padding: clamp(1.8rem, 4vw, 2.6rem) clamp(1.1rem, 4vw, 2rem);
}
.footer__row {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  color: var(--muted-dim);
  font-size: 0.88rem;
}
.footer__brand {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--muted);
}
.footer__link { color: var(--muted-dim); transition: color 0.2s ease; }
.footer__link:hover { color: var(--text); }
.footer__sep { color: rgba(255, 255, 255, 0.25); }

/* --------------------------------------------------------------------------
   RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 780px) {
  .tabpanel__grid {
    grid-template-columns: 1fr;
    grid-template-areas: none;
  }
  .panel-line, .features, .pricing, .lead-form { grid-area: auto; }

  .hero__previews { grid-template-columns: 1fr; max-width: 34rem; }
}

@media (max-width: 640px) {
  /* External links live in the footer too; keep the nav uncluttered. */
  .nav__link { display: none; }
}

@media (max-width: 420px) {
  .lead-form__row { flex-direction: column; align-items: stretch; }
  .lead-form__input { flex: 0 0 auto; width: 100%; }
  .lead-form__submit { width: 100%; }
  .tab { padding-left: 0.9em; padding-right: 0.9em; }
}

/* --------------------------------------------------------------------------
   REDUCED MOTION
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .hero__field { display: none; }
  .hero__field-static { display: block; }
  .scrollcue { animation: none; }
  .tabpanel.is-entering { animation: none; }
}
