/* ---------------------------------------------------------------------------
   O.I.I public site - shared stylesheet (Phase 7)

   Palette is sampled directly from logos/oii_3_badge.png rather than eyeballed,
   so the site and the badge are literally the same greens:

     #0A0F0D  outer background   (53% of the badge's pixels)
     #0D1A14  badge interior     - used here as the surface/panel colour
     #00FF9C  primary accent     - the O.I.I glyph
     #00ED8D  border stroke
     #00BD64  the deep end of the glyph's gradient
     #EAFFF6  the sparkline      - used here as body text

   NO BUILD STEP. public-site/netlify.toml publishes `public/` as plain files
   with no bundler, which is deliberate: the marketing site should never be able
   to break a deploy that the Discord interactions functions also ride on.
   Plain CSS, one stylesheet, no framework.
--------------------------------------------------------------------------- */

:root {
  --ground: #0a0f0d;
  --surface: #0d1a14;
  --surface-2: #112319;
  --border: #1d3a2b;
  --border-bright: #00ed8d;

  --accent: #00ff9c;
  --accent-deep: #00bd64;
  --accent-dim: rgba(0, 255, 156, 0.12);

  /* Added 8c (2026-07-27). Green previously meant brand, accent, bullet,
     interactive AND a bearish call in the worked example readout — a
     trading-clarity bug, not just a design one. --bull reuses the brand
     green (an up move is the "good/go" colour anyway); --bear is a distinct
     warm red so a bearish direction is never rendered in the same colour as
     "this qualifies" or "click here." */
  --bull: #00ff9c;
  --bear: #ff5c5c;

  --text: #eafff6;
  --muted: #8aa79a;
  /* Lightened 2026-07-27 from #5d7268, which computed to 3.75:1 on --ground at
     13.9px and failed WCAG AA. --faint is the footer colour, so that ratio was
     carrying the liability disclaimer: the most legally consequential text on
     the site, set in its least readable style. #7a9086 is 5.67:1. */
  --faint: #7a9086;

  /* Heading typeface, added 8c (2026-07-27). A technical grotesk with
     distinctive numerals — the product is numbers, and the previous system-
     stack-everywhere look is the default fintech-SaaS dark mode shared with
     roughly two hundred other trading tools. Space Grotesk (Google Fonts,
     OFL-licensed, free) rather than a purchased face: same differentiation
     goal without a real transaction, and it's swappable later with zero
     structural cost since it's isolated to one variable. Body copy stays on
     the system stack per the roadmap (performance), so only --font-head is
     new here. */
  --font-head: 'Space Grotesk', ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial,
    sans-serif;

  --radius: 14px;
  --maxw: 1080px;

  color-scheme: dark;
}

/* --- reset ---------------------------------------------------------------- */

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font: 16px/1.65 ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  font-family: var(--font-head);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 0.6rem;
}

/* Skip-to-content link, 8e accessibility. Every page opens with a 6-link
   sticky header to tab through; this lets keyboard/screen-reader users jump
   straight to <main>. Visually hidden until focused. */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 100;
  background: var(--accent);
  color: #04140c;
  padding: 0.6rem 1rem;
  border-radius: 0 0 8px 0;
  font-weight: 600;
  font-size: 0.9rem;
}
.skip-link:focus {
  left: 0;
}

/* Focus styles, 8e accessibility. styles.css previously had no :focus or
   :focus-visible rule anywhere on the site. */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

h1 {
  font-size: clamp(2.1rem, 5vw, 3.4rem);
}
h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}
h3 {
  font-size: 1.12rem;
}

p {
  margin: 0 0 1rem;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.1em 0.4em;
}

/* --- layout --------------------------------------------------------------- */

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1.25rem;
}

section {
  padding: 4.5rem 0;
  border-top: 1px solid var(--border);
}
section:first-of-type {
  border-top: 0;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 0.75rem;
}

.lede {
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 60ch;
}

/* --- header / nav --------------------------------------------------------- */

header.site {
  position: sticky;
  top: 0;
  z-index: 10;
  /* 0.85 -> 0.94, 8e visual fix: at 0.85 plus the blur, scrolled text ghosts
     visibly behind the logo/nav and reads as a rendering bug rather than an
     intentional glass effect. */
  background: rgba(10, 15, 13, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

header.site .wrap {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  height: 62px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}
.brand:hover {
  text-decoration: none;
}
.brand img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: block;
}

nav.site {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 1.35rem;
  font-size: 0.93rem;
}
nav.site a {
  color: var(--muted);
  /* 8e: nav.site a had no padding, well under the 44x44 tap-target minimum. */
  padding: 0.5rem 0.1rem;
  display: inline-block;
}
nav.site a:hover,
nav.site a[aria-current='page'] {
  color: var(--text);
  text-decoration: none;
}

/* --- buttons -------------------------------------------------------------- */

.btn {
  display: inline-block;
  padding: 0.72rem 1.35rem;
  border-radius: 10px;
  /* 650 -> 600, 8e fix: non-standard weights (650/750) round to 700 on system
     fonts, silently losing the intent. 600/700 are the two real weights. */
  font-weight: 600;
  font-size: 0.97rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: #04140c;
  box-shadow: 0 6px 22px rgba(0, 255, 156, 0.18);
}
.btn-primary:hover {
  box-shadow: 0 10px 28px rgba(0, 255, 156, 0.26);
}

.btn-ghost {
  border-color: var(--border);
  color: var(--text);
  background: var(--surface);
}
.btn-ghost:hover {
  border-color: var(--border-bright);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

/* --- hero ----------------------------------------------------------------- */

.hero {
  padding: 5.5rem 0 4rem;
  background:
    radial-gradient(70rem 30rem at 50% -12rem, rgba(0, 255, 156, 0.09), transparent 70%),
    var(--ground);
  border-top: 0;
}

.hero .badge-mark {
  width: 76px;
  height: 76px;
  border-radius: 18px;
  margin-bottom: 1.5rem;
  display: block;
}

/* 8d: two-column hero above 900px (BRAND-GUIDE.md rule 14). Single column,
   screenshot below the copy, on narrower viewports. */
.hero-grid {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 1.1fr 1fr;
  }
}
.hero-shot img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.32rem 0.8rem;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 1.25rem;
}
.pill .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}

/* --- cards ---------------------------------------------------------------- */

.grid {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
}
.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
  /* 8e fix: default stretch made short cards match the tallest in the row,
     leaving ~90px of empty card. */
  align-items: start;
}
.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  align-items: start;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
}
.card h3 {
  margin-bottom: 0.4rem;
}
.card p:last-child {
  margin-bottom: 0;
}
.card .num {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 0.6rem;
}

.muted {
  color: var(--muted);
}
.small {
  font-size: 0.9rem;
}

/* --- worked example ------------------------------------------------------- */

.example {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 2rem;
}
.example-head {
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
  font-size: 0.85rem;
  color: var(--muted);
}
.example-body {
  padding: 1.4rem;
}

.step {
  display: grid;
  grid-template-columns: 2rem 1fr;
  gap: 1rem;
  padding: 1.05rem 0;
  border-bottom: 1px dashed var(--border);
}
.step:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.step-n {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--accent-dim);
  border: 1px solid var(--border-bright);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
}
.step h3 {
  margin-bottom: 0.25rem;
}
.step p {
  margin: 0;
  color: var(--muted);
}

.readout {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.87rem;
  background: var(--ground);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0.85rem 1rem;
  margin-top: 0.7rem;
  color: var(--text);
  white-space: pre-wrap;
  line-height: 1.55;
}
.readout .g {
  color: var(--accent);
}
.readout .m {
  color: var(--muted);
}
/* 8c trading-clarity fix: a bearish call must never render in the same green
   as "this qualifies" / the brand accent. Use these two on direction-bearing
   values instead of .g. */
.readout .bull {
  color: var(--bull);
}
.readout .bear {
  color: var(--bear);
}

/* --- pricing -------------------------------------------------------------- */

.tiers {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(265px, 1fr));
  margin-top: 2.25rem;
  align-items: start;
}

.tier {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem 1.4rem;
  position: relative;
}
.tier.featured {
  border-color: var(--border-bright);
  box-shadow: 0 0 0 1px rgba(0, 255, 156, 0.15), 0 12px 40px rgba(0, 255, 156, 0.07);
}
.tier-tag {
  position: absolute;
  top: -0.7rem;
  left: 1.4rem;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: #04140c;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.22rem 0.6rem;
  border-radius: 999px;
}
.tier h3 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 0.9rem;
}
.price {
  font-family: var(--font-head);
  font-size: 2.3rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
}
.price span {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0;
}
.price-alt {
  font-size: 0.88rem;
  color: var(--muted);
  margin-top: 0.4rem;
}

.tier ul {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 0;
  font-size: 0.94rem;
}
.tier li {
  padding: 0.4rem 0 0.4rem 1.5rem;
  position: relative;
  color: var(--muted);
}
.tier li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.95em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.55;
}
/* Cancellation terms under every price (Phase 8a item 5). The word "cancel"
   did not appear anywhere on the site before this, which for a recurring
   subscription is a trust problem, not an omission. */
.tier-note {
  margin: 1.1rem 0 0;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--muted);
}
.tier-note a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.tier-note a:hover {
  color: var(--accent);
}

.tier li strong {
  color: var(--text);
  font-weight: 600;
}

/* --- FAQ ------------------------------------------------------------------ */

details.faq {
  border: 1px solid var(--border);
  border-radius: 11px;
  background: var(--surface);
  padding: 0 1.15rem;
  margin-bottom: 0.7rem;
}
details.faq summary {
  cursor: pointer;
  padding: 1.05rem 0;
  font-weight: 600;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
details.faq summary::-webkit-details-marker {
  display: none;
}
/* 8e: <summary> text wrapped in <h3> for screen-reader structure (previously
   plain text with no heading semantics). Reset so it still reads as the
   summary line, not a distinct heading-sized block. */
details.faq summary h3 {
  margin: 0;
  font: inherit;
  font-weight: 600;
}
details.faq summary::before {
  content: '+';
  color: var(--accent);
  font-weight: 700;
  width: 1rem;
  flex: none;
}
details.faq[open] summary::before {
  content: '–';
}
details.faq .answer {
  padding: 0 0 1.1rem 1.75rem;
  color: var(--muted);
}
details.faq .answer p:last-child {
  margin-bottom: 0;
}

/* --- about / team --------------------------------------------------------- */

.tile-head {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.avatar {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 1.05rem;
  background: var(--accent-dim);
  border: 1px solid var(--border-bright);
  color: var(--accent);
}
.avatar.mission {
  font-size: 1.3rem;
}

.tile-name {
  font-weight: 650;
  font-size: 1.02rem;
}
.tile-role {
  font-size: 0.87rem;
  color: var(--muted);
}

.tile-links {
  display: flex;
  gap: 1.1rem;
  margin-top: 1.1rem;
  font-size: 0.92rem;
  flex-wrap: wrap;
}

/* --- callouts ------------------------------------------------------------- */

.notice {
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  background: var(--surface);
  border-radius: 0 11px 11px 0;
  padding: 1.1rem 1.25rem;
  color: var(--muted);
  font-size: 0.95rem;
}
.notice strong {
  color: var(--text);
}
.notice p:last-child {
  margin-bottom: 0;
}

/* --- footer --------------------------------------------------------------- */

footer.site {
  border-top: 1px solid var(--border);
  padding: 2.75rem 0 3.5rem;
  color: var(--faint);
  font-size: 0.87rem;
}
footer.site .foot-top {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  align-items: center;
  margin-bottom: 1.5rem;
}
footer.site nav {
  margin-left: auto;
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
}
footer.site nav a {
  color: var(--muted);
}

/* Legal and contact columns (Phase 8a). Every page carries these: three legal
   pages plus a contact route. Their absence was the cheapest trust failure on
   the site, and Phase 9 generates support questions that need somewhere to go. */
footer.site .foot-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.75rem 2.5rem;
  border-top: 1px solid var(--border);
  padding-top: 1.75rem;
  margin-bottom: 1.75rem;
}
footer.site .foot-cols h4 {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--muted);
  margin: 0 0 0.7rem;
}
footer.site .foot-cols a {
  display: block;
  color: var(--muted);
  margin-bottom: 0.45rem;
  text-decoration: none;
}
footer.site .foot-cols a:hover {
  color: var(--accent);
  text-decoration: underline;
}
footer.site .foot-cols p {
  margin: 0.55rem 0 0;
  max-width: 34ch;
}

/* The liability disclaimer. Required on every page per the roadmap's
   Liability Disclaimers section - placeholder language pending legal review,
   NOT vetted, and must be reviewed before any money changes hands. */
.disclaimer {
  border-top: 1px solid var(--border);
  padding-top: 1.35rem;
  line-height: 1.6;
  max-width: 78ch;
}

/* --- legal pages ---------------------------------------------------------- */
/* Long-form prose for terms / privacy / refunds. Narrower measure than the rest
   of the site because these are read, not scanned, and body colour rather than
   --muted because legal text a reader has to squint at is a liability, not a
   design choice. */

.legal {
  max-width: 68ch;
}
.legal h2 {
  font-size: 1.22rem;
  margin: 2.75rem 0 0.9rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}
.legal h2:first-of-type {
  margin-top: 1rem;
}
.legal h3 {
  font-size: 1rem;
  margin: 1.6rem 0 0.5rem;
}
.legal p,
.legal li {
  color: var(--text);
  line-height: 1.7;
}
.legal ul {
  padding-left: 1.15rem;
  margin: 0.75rem 0;
}
.legal li {
  margin-bottom: 0.5rem;
}
.legal .updated {
  color: var(--muted);
  font-size: 0.9rem;
}

/* --- section alternation, 8c ----------------------------------------------
   "Alternate section backgrounds between --ground and --surface and drop
   most of the fifteen consecutive identical hairline borders." Applied by
   hand-adding class="alt" to alternating <section> elements rather than an
   nth-of-type rule, since page structures (hero present or not, section
   count) differ enough that a single CSS-only rule would land inconsistently
   across pages. */
section.alt {
  background: var(--surface);
  border-top: 0;
}

/* --- hero motif, 8c ---------------------------------------------------------
   "Build a visual motif from the badge sparkline." The badge itself only
   appears at 28px/76px and nowhere else. This is a lightweight decorative
   echo of that sparkline shape, not a crop of the source asset -- a lo-fi
   jagged upward line, very low opacity, sitting behind the hero copy. */
.hero {
  position: relative;
  overflow: hidden;
}
/* Repositioned top-left and dimmed further once the hero gained a real
   screenshot in the right column (8d) -- it now sits behind the copy only,
   not competing with the product visual. */
.hero::after {
  content: '';
  position: absolute;
  left: -8%;
  top: -10%;
  width: 34rem;
  height: 13rem;
  opacity: 0.07;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 140'%3E%3Cpolyline points='0,110 40,95 70,100 100,60 140,75 175,35 210,55 245,20 280,40 320,10 360,28 400,5' fill='none' stroke='%2300ff9c' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}
.hero .wrap {
  position: relative;
  z-index: 1;
}

/* --- mobile sticky CTA bar, 8d --------------------------------------------
   Standard for this audience, absent before. Markup: a hidden-by-default bar
   added near the end of <body> on pages with a signup CTA; shown only under
   the same breakpoint the rest of the mobile nav collapses at. */
.sticky-cta {
  display: none;
}
@media (max-width: 620px) {
  .sticky-cta {
    display: block;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 20;
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
    background: rgba(10, 15, 13, 0.96);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--border);
  }
  .sticky-cta .btn {
    display: block;
    width: 100%;
    text-align: center;
  }
  /* Existing bottom padding on <body> so the fixed bar never covers the
     final CTA section's own button. */
  body {
    padding-bottom: 4.5rem;
  }
}

/* --- responsive ----------------------------------------------------------- */

/* 8e: one breakpoint at 620px jumped straight from 3-column to 1-column with
   nothing between, so a tablet-width viewport got the cramped desktop grid. */
@media (max-width: 900px) {
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 620px) {
  section {
    padding: 3.25rem 0;
  }
  .hero {
    padding: 3.5rem 0 2.75rem;
  }
  .hero::after {
    opacity: 0.06;
  }
  nav.site {
    gap: 1rem;
    font-size: 0.87rem;
  }
  nav.site .hide-sm {
    display: none;
  }
  .grid-3 {
    grid-template-columns: 1fr;
  }
  /* 8e: .step stayed 2-column on mobile, so the number circle ate ~8% of a
     390px screen on every step. */
  .step {
    grid-template-columns: 1fr;
  }
  .step-n {
    margin-bottom: 0.25rem;
  }
  /* 8e: pre-wrap monospace at ~76 characters wide broke mid-value against
     ~350px of available width, destroying the alignment that makes it
     readable. Let it scroll horizontally instead of wrapping. */
  .readout {
    white-space: pre;
    overflow-x: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn:hover {
    transform: none;
  }
}
