/* AP Brainery company site: colors taken from the AP brain logo */
:root {
  --bg: #F5F5F7;
  --surface: #FFFFFF;
  --ink: #1B1B1F;
  --ink-soft: #55565C;
  --line: #E2E2E6;
  --red: #BE0000;        /* logo red */
  --red-ink: #9E0000;    /* darker red for small text, passes contrast */
  --radius: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.65 "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}
a { color: var(--red-ink); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }

/* ---------- Intro overlay ---------- */
#intro {
  position: fixed; inset: 0; z-index: 100;
  background: #000;
  display: flex; align-items: center; justify-content: center;
  transition: opacity .8s ease;
}
#intro.fade { opacity: 0; pointer-events: none; }
#intro video { width: 100%; height: 100%; object-fit: contain; background: #000; }
#skip {
  position: absolute; right: 20px; bottom: 24px;
  font: 500 14px/1 "Inter", system-ui, sans-serif;
  color: #fff; background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.35); border-radius: 999px;
  padding: 10px 16px; cursor: pointer;
}
#skip:hover { background: rgba(255,255,255,.22); }

/* Page waits behind the intro, then fades in */
.page { transition: opacity .9s ease .15s; }
.intro-on body { overflow: hidden; }
.intro-on .page { opacity: 0; }

/* ---------- Header ---------- */
.site-header {
  max-width: 1080px; margin: 0 auto; padding: 20px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand span { font: 600 20px/1 "Source Serif 4", Georgia, serif; letter-spacing: .2px; }
nav { display: flex; gap: 20px; }
nav a { color: var(--ink-soft); text-decoration: none; font-weight: 500; font-size: 15px; }
nav a:hover { color: var(--red-ink); }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate;
  max-width: 1080px; margin: 0 auto; padding: 72px 16px 64px;
}
/* Neural-network art sits on the right and fades out before it reaches the text */
.hero::before {
  content: ""; position: absolute; z-index: -1;
  top: 0; bottom: 0; right: 0; left: 40%;
  background: url("media/network.png") right center / cover no-repeat;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 45%);
          mask-image: linear-gradient(to right, transparent 0%, #000 45%);
}
.eyebrow { margin: 0 0 12px; color: var(--red-ink); font-weight: 600; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; }
h1 {
  margin: 0; max-width: 16ch;
  font: 600 clamp(36px, 6vw, 60px)/1.1 "Source Serif 4", Georgia, serif;
}
.lede { max-width: 60ch; margin: 24px 0 0; color: var(--ink-soft); font-size: 18px; }
.status {
  display: inline-flex; align-items: center; gap: 10px;
  margin: 28px 0 0; padding: 10px 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px;
  font-size: 15px; font-weight: 500;
}
.dot { flex-shrink: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--red); }

/* ---------- Principle cards (rounded panels with red accent, like the app) ---------- */
.principles {
  max-width: 1080px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.card {
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--line); border-top: 4px solid var(--red);
  padding: 24px;
}
.card h2 { margin: 0 0 8px; font: 600 21px/1.3 "Source Serif 4", Georgia, serif; }
.card p { margin: 0; color: var(--ink-soft); font-size: 16px; }

/* ---------- Content blocks ---------- */
.block { max-width: 1080px; margin: 0 auto; padding: 72px 16px 0; }
.block h2 { margin: 0 0 16px; font: 600 30px/1.2 "Source Serif 4", Georgia, serif; }
.block p { max-width: 65ch; }
.contacts { margin: 0; display: grid; gap: 10px; }
.contacts div { display: flex; gap: 16px; }
.contacts dt { width: 80px; color: var(--ink-soft); font-weight: 500; }
.contacts dd { margin: 0; }
.muted { color: var(--ink-soft); }

/* ---------- Footer ---------- */
.site-footer {
  max-width: 1080px; margin: 96px auto 0; padding: 24px 16px 40px;
  border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 14px;
}

/* ---------- Privacy page ---------- */
.legal { max-width: 760px; margin: 0 auto; padding: 48px 16px 0; }
.legal h1 { font-size: clamp(32px, 5vw, 44px); max-width: none; }
.legal h2 { font: 600 22px/1.3 "Source Serif 4", Georgia, serif; margin: 36px 0 8px; }

/* ---------- Phone layout ---------- */
@media (max-width: 760px) {
  .principles { grid-template-columns: 1fr; }
  .hero { padding: 48px 16px 40px; }
  .hero::before { left: 0; bottom: auto; height: 160px; opacity: .6;
    -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent);
            mask-image: linear-gradient(to bottom, #000 30%, transparent); }
  nav { gap: 14px; }
  .brand span { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .page, #intro { transition: none; }
}
