/* Design language: the founder-chosen template aesthetic (Wix Studio "AI Tech
   Company") rebuilt in rich Canadian reds. Full-bleed sections, huge regular-
   weight headlines, pill nav/buttons, tilted overlapping cards on a gradient
   band, grey lined "means" section, red showcase band, numbers section.
   Scroll-DRIVEN (scrubbed) motion matching the template's real mechanism. */
:root {
  --bg: #ffffff;
  --ink: #0a0a0a;
  --muted: #57575e;
  --red: #c8102e;
  --red-deep: #8a0c20;
  --red-ink: #ffffff;
  --red-soft: #fdeef0;
  --panel: #f5f5f7;
  --grey-band: #efeff1;
  --line: #e7e7ec;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  font-size: 1.0625rem;
}

/* ---------- hero ---------- */
.hero { max-width: 62rem; margin: 0 auto; padding: 3rem 1.5rem 2rem; }
.hero-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap; margin-bottom: 4rem;
}
.wordmark { font-weight: 700; font-size: 1.05rem; letter-spacing: -0.01em; display: inline-flex; align-items: center; gap: 0.5rem; }
.logo-mark { flex: none; }
.hero-nav { display: flex; gap: 0.25rem; background: var(--panel); border-radius: 999px; padding: 0.35rem; }
.hero-nav a {
  color: var(--ink); text-decoration: none; font-weight: 500; font-size: 0.95rem;
  padding: 0.5rem 1.15rem; border-radius: 999px;
}
.hero-nav a:hover, .hero-nav a:focus-visible { background: var(--bg); }

.hero h1 {
  font-size: clamp(2.8rem, 9vw, 5.5rem);
  font-weight: 400; letter-spacing: -0.03em; line-height: 1.02;
  margin: 0 0 0.5rem;
}
.hero .tagline {
  font-size: clamp(2rem, 6.5vw, 3.6rem);
  font-weight: 400; letter-spacing: -0.025em; line-height: 1.08;
  color: var(--red); margin: 0 0 2rem; max-width: 18ch;
}
.hero .sub { color: var(--muted); font-size: 1.15rem; max-width: 46rem; margin: 0 0 1.1rem; }
.hero p.sub:last-of-type { margin-bottom: 2.6rem; }
.hero-art { height: 300px; border-radius: 28px; overflow: hidden; margin-top: 1rem; }
.hero-art svg { display: block; }

/* ---------- sections: full-bleed bands, constrained content ---------- */
main { max-width: none; margin: 0; padding: 0; }
section { padding: 4.5rem 1.5rem 3.5rem; }
section > * { max-width: 62rem; margin-left: auto; margin-right: auto; }
h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 400; letter-spacing: -0.025em; line-height: 1.1;
  margin: 0 0 1.6rem;
}
h3 { font-size: 1.25rem; font-weight: 650; margin: 2.2rem auto 0.6rem; letter-spacing: -0.01em; }
p, ul { margin: 0 auto 1rem; }
ul { padding-left: 1.3rem; }
li { margin-bottom: 0.55rem; }
a { color: var(--red); }
section > p { max-width: 44rem; margin-left: 0; }
#parents > p, #parents > h3 { max-width: 62rem; }

/* ---------- gradient band with tilted overlapping cards ---------- */
.band {
  max-width: none;
  margin: 2.5rem calc(50% - 50vw);
  padding: 5rem max(1.5rem, calc(50vw - 31rem));
  background: linear-gradient(115deg, #5c0a18 0%, #a30f26 38%, #d3542f 72%, #eda45c 100%);
  border-radius: 0;
  display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: center;
  gap: 1.4rem;
}
.card {
  background: #f7f6f4;
  border-radius: 18px;
  padding: 1.5rem 1.5rem 1.6rem;
  box-shadow: 0 18px 40px rgba(40, 6, 12, 0.35);
  width: min(18.5rem, 100%);
  position: relative;
}
.card h3 { margin: 0 0 0.9rem; font-size: 1.15rem; }
.card p { font-size: 0.92rem; line-height: 1.55; color: #2c2c31; margin: 0; }
.card-icon { display: block; margin-bottom: 0.9rem; }
.eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 0.2rem;
}
.tilt-l { --tilt: rotate(-4deg); z-index: 1; }
.tilt-c { --tilt: rotate(1.5deg) translateY(14px); z-index: 2; margin-left: -2rem; }
.tilt-r { --tilt: rotate(5deg); z-index: 3; margin-left: -2rem; }
.card { transform: var(--tilt, none); transition: transform 0.35s ease, box-shadow 0.35s ease; }
.card:hover { transform: rotate(0deg) translateY(-8px); box-shadow: 0 26px 54px rgba(40, 6, 12, 0.45); z-index: 4; }
.band .tilt-l::after, .band .tilt-c::after {
  content: "→";
  position: absolute;
  right: -2.55rem;
  top: 44%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.9rem;
  height: 1.9rem;
  border: 2px solid #ffffff;
  border-radius: 50%;
  color: #ffffff;
  font-size: 1.05rem;
  z-index: 6;
  pointer-events: none;
}
@media (max-width: 720px) {
  .tilt-l { --tilt: rotate(-1.5deg); }
  .tilt-c { --tilt: rotate(1.5deg); margin-left: 0; }
  .tilt-r { --tilt: rotate(-1deg); margin-left: 0; }
  .band .tilt-l::after, .band .tilt-c::after {
    right: auto; left: 50%; top: auto; bottom: -2.6rem;
    transform: translateX(-50%) rotate(90deg);
  }
}

/* ---------- "means" section: grey band, heading, dot cluster, lined list ---------- */
.means {
  max-width: none;
  margin: 3rem calc(50% - 50vw) 1rem;
  padding: 4rem max(1.5rem, calc(50vw - 31rem)) 4.5rem;
  background: var(--grey-band);
  display: grid;
  grid-template-columns: minmax(10rem, 1fr) minmax(0, 1.6fr);
  grid-template-areas: "title title" "deco list" "note note" "cta cta";
  column-gap: 3rem;
}
.means-note { grid-area: note; color: var(--muted); margin: 2.2rem 0 0; }
.means-title { grid-area: title; font-size: clamp(1.9rem, 4.5vw, 2.7rem); font-weight: 400; letter-spacing: -0.02em; margin: 0 0 2.5rem; }
.means-deco { grid-area: deco; position: relative; min-height: 10rem; }
.means-deco span { position: absolute; border-radius: 50%; }
.means-deco span:nth-child(1) { width: 3.4rem; height: 3.4rem; background: #a30f26; left: 0; top: 0.4rem; }
.means-deco span:nth-child(2) { width: 3.4rem; height: 3.4rem; background: #c8102e; opacity: 0.75; left: 2.2rem; top: 0.4rem; }
.means-deco span:nth-child(3) { width: 3.4rem; height: 3.4rem; background: #e57a8b; opacity: 0.8; left: 4.4rem; top: 0.4rem; }
.means-deco span:nth-child(4) { width: 3rem; height: 3rem; background: #f2b9c2; opacity: 0.9; left: 6.5rem; top: 1.8rem; }
.means-deco span:nth-child(5) { width: 2.6rem; height: 2.6rem; background: #e5a5af; opacity: 0.7; left: 3rem; top: 8rem; }
.means-list { grid-area: list; list-style: none; margin: 0; padding: 0; }
.means-list li {
  border-top: 1px solid #d9d9de;
  padding: 3.2rem 0.1rem;
  margin: 0;
  font-size: 1.05rem;
}
.means-list li:last-child { border-bottom: 1px solid #d9d9de; }
.means-cta { grid-area: cta; text-align: right; align-self: center; margin: 1.8rem 0 0; }
@media (max-width: 720px) {
  .means { grid-template-columns: 1fr; }
  .means-deco { min-height: 5rem; }
  .means-deco span:nth-child(5) { display: none; }
}

.ask-title {
  font-size: clamp(1.9rem, 4.5vw, 2.7rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  margin: 3.5rem auto 0.3rem;
}
.ask-sub {
  font-size: clamp(1.25rem, 3vw, 1.7rem);
  font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--red);
  margin: 0 0 1.4rem;
}

/* ---------- composer ---------- */
.composer {
  background: var(--panel);
  border-radius: 24px;
  padding: 1.8rem;
  margin: 1.6rem auto;
  max-width: 44rem;
  margin-left: 0;
}
.field { margin-bottom: 1.15rem; position: relative; }
label { display: block; font-weight: 600; margin-bottom: 0.4rem; }
.hint-inline { font-weight: 400; color: var(--muted); font-size: 0.9rem; }
input[type="text"], input[type="email"], select {
  width: 100%; font: inherit; color: var(--ink); background: var(--bg);
  border: 1px solid var(--line); border-radius: 14px; padding: 0.8rem 1rem;
}
select { appearance: auto; cursor: pointer; }
input:focus-visible { outline: 2px solid var(--red); outline-offset: 1px; }

#school-results {
  list-style: none; margin: 0.35rem 0 0; padding: 0.3rem;
  border: 1px solid var(--line); border-radius: 14px; background: var(--bg);
  max-height: 16rem; overflow-y: auto; position: absolute; width: 100%; z-index: 10;
  box-shadow: 0 12px 32px rgba(10, 10, 10, 0.10);
}
#school-results li { margin: 0; }
#school-results button {
  display: block; width: 100%; text-align: left; font: inherit;
  background: none; border: 0; border-radius: 10px; padding: 0.55rem 0.7rem;
  cursor: pointer; color: var(--ink);
}
#school-results button:hover, #school-results button:focus-visible { background: var(--red-soft); }
#school-results .meta { display: block; color: var(--muted); font-size: 0.85rem; }

.chosen { background: var(--red-soft); border-radius: 14px; padding: 1rem 1.15rem; margin-bottom: 1.15rem; }
.chosen p { margin: 0 0 0.4rem; }
#chosen-meta { color: var(--muted); font-size: 0.9rem; }
.linklike {
  background: none; border: 0; padding: 0; color: var(--red);
  font: inherit; font-size: 0.9rem; text-decoration: underline; cursor: pointer;
}

.btn {
  display: inline-block; background: var(--red); color: var(--red-ink);
  font-weight: 600; font-size: 1.05rem; text-decoration: none;
  padding: 0.95rem 1.9rem; border-radius: 999px; margin-top: 0.3rem;
  transition: transform 0.25s ease, filter 0.2s ease;
}
.btn:hover { filter: brightness(1.12); transform: translateY(-2px); }
.btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.btn-invert { background: #ffffff; color: var(--red-deep); padding: 0.55rem 1.15rem; }
.btn-small { padding: 0.65rem 1.3rem; font-size: 0.95rem; }
/* the template's signature circled-arrow glyph */
.btn-icon::before {
  content: "→";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.3em;
  height: 1.3em;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  margin-right: 0.55em;
  font-size: 0.82em;
  line-height: 1;
  vertical-align: -0.18em;
}
.micro { color: var(--muted); font-size: 0.85rem; margin-top: 0.7rem; }

.trust {
  background: var(--red-soft);
  border-radius: 24px;
  padding: 1.3rem 1.5rem;
  margin: 2.2rem auto 0;
  margin-left: 0;
  max-width: 44rem;
  font-size: 0.92rem;
}
.trust p { margin: 0; }

/* ---------- schools & boards: the red showcase band ---------- */
#schools {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #6d0a1d 0%, #a30f26 45%, #c2536a 100%);
  color: #ffffff;
  padding-top: 6rem;
  padding-bottom: 5rem;
}
#schools::before, #schools::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
#schools::before { width: 34rem; height: 34rem; background: rgba(60, 4, 14, 0.25); top: -8rem; right: -10rem; }
#schools::after { width: 22rem; height: 22rem; background: rgba(255, 255, 255, 0.07); bottom: -6rem; left: -6rem; }
/* concentric rings behind the heading, per the template's showcase section */
.rings {
  position: absolute;
  left: 50%;
  top: 3rem;
  transform: translateX(-50%);
  width: 26rem;
  height: 26rem;
  max-width: none;
  border-radius: 50%;
  background: rgba(50, 3, 10, 0.16);
  pointer-events: none;
  z-index: 0;
}
.rings::before, .rings::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}
.rings::before { inset: 16%; background: rgba(50, 3, 10, 0.20); }
.rings::after { inset: 34%; background: rgba(30, 2, 8, 0.26); }
#schools h2 {
  text-align: center;
  font-size: clamp(2.2rem, 5.5vw, 3.4rem);
  margin-bottom: 2.5rem;
  position: relative; z-index: 1;
}
#schools > p { color: #f6e3e6; position: relative; z-index: 1; }
#schools .contact-line { color: #ffffff; margin: 1.4rem auto 1.2rem; margin-left: 0; }
#schools .contact-line a:not(.btn) { color: #ffd9df; }
.contact-sub { display: block; font-weight: 400; margin-top: 1.1rem; }
#schools h3 { color: #ffffff; position: relative; z-index: 1; margin-top: 2.8rem; }
#schools details {
  background: #ffffff;
  color: var(--ink);
  border: 0;
  border-radius: 14px;
  padding: 1rem 1.2rem;
  margin: 0 auto 0.7rem;
  position: relative; z-index: 1;
}
#schools details p { color: var(--muted); }
#schools details ul { color: var(--muted); margin: 0 0 0.8rem; padding-left: 1.2rem; }
#schools details li { margin-bottom: 0.5rem; }
#schools summary::marker { color: var(--red); }
details { border-bottom: 1px solid var(--line); padding: 1.1rem 0.2rem; max-width: 62rem; }
summary { font-weight: 600; font-size: 1.1rem; cursor: pointer; }
details[open] summary { margin-bottom: 0.6rem; }
details p { margin: 0; }

/* ---------- the breach in numbers ---------- */
#numbers { position: relative; padding-top: 6rem; padding-bottom: 5rem; text-align: center; }
#numbers > p { margin-left: auto; margin-right: auto; }
.ghost {
  position: sticky;
  top: 38vh;
  text-align: center;
  font-size: clamp(2.2rem, 6vw, 3.6rem);
  color: #b9b9c0;
  z-index: 0;
  margin: 0 auto 1rem;
}
.stats { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 1.8rem; margin: 2.2rem auto 2.8rem; }
.stat-card {
  background: var(--panel);
  border-radius: 16px;
  padding: 0.8rem 0.8rem 1rem;
  width: 14.5rem;
  box-shadow: 0 14px 34px rgba(10, 10, 10, 0.12);
  text-align: left;
}
.stat-card:nth-child(1) { transform: translateX(-3.5rem) rotate(-1deg); }
.stat-card:nth-child(2) { transform: translateX(3rem) rotate(1deg); }
.stat-card:nth-child(3) { transform: translateX(-1.5rem); }
.stat-tile {
  border-radius: 12px;
  height: 13rem;
  display: flex; align-items: flex-end; padding: 0.9rem;
  font-size: 2.6rem; letter-spacing: -0.02em; color: var(--ink);
}
.tile-a { background: linear-gradient(135deg, #f6ccd3, #fdeee2); }
.tile-b { background: linear-gradient(135deg, #f2dfe0, #fce8d9); }
.tile-c { background: linear-gradient(135deg, #fbe3e6, #f6d5c4); }
.stat-card .label { color: var(--muted); font-size: 0.95rem; padding: 0.7rem 0.3rem 0; margin: 0; }
.stat-note { color: var(--muted); font-size: 0.78rem; max-width: 34rem; margin: 0 auto 2.2rem; }
.numbers-cta { font-size: clamp(1.3rem, 3vw, 1.8rem); font-weight: 600; letter-spacing: -0.01em; margin: 0 auto 1.4rem; }
@media (max-width: 720px) {
  .stat-card:nth-child(1), .stat-card:nth-child(2), .stat-card:nth-child(3) { transform: none; }
  .ghost { position: static; transform: none; margin-bottom: 1rem; color: #9d9da5; }
}

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line); text-align: center; padding: 2.5rem 1.5rem 3.5rem; color: var(--muted); }
footer p { margin: 0 0 0.4rem; }

/* ---------- motion: scroll-DRIVEN (scrubbed) animations ---------- */
@keyframes pol-in-left  { from { opacity: 0; transform: translateX(-340px) rotate(0deg); } to { opacity: 1; transform: var(--tilt, none); } }
@keyframes pol-in-right { from { opacity: 0; transform: translateX(340px) rotate(0deg); }  to { opacity: 1; transform: var(--tilt, none); } }
@keyframes pol-in-up    { from { opacity: 0; transform: translateY(300px) rotate(0deg); }  to { opacity: 1; transform: var(--tilt, none); } }
@keyframes pol-rise     { from { opacity: 0; transform: translateY(130px); } to { opacity: 1; transform: none; } }
@keyframes pol-rise-l   { from { opacity: 0; transform: translateX(-3.5rem) translateY(130px); } to { opacity: 1; transform: translateX(-3.5rem) rotate(-1deg); } }
@keyframes pol-rise-r   { from { opacity: 0; transform: translateX(3rem) translateY(130px); } to { opacity: 1; transform: translateX(3rem) rotate(1deg); } }
@keyframes pol-hero-exit { to { opacity: 0; transform: translateY(140px); } }
@keyframes pol-breathe { 0%, 100% { transform: scale(1); } 40% { transform: scale(0.93); } }
@keyframes pol-dot { from { opacity: 0; transform: scale(0.2); } to { opacity: 1; transform: scale(1); } }

@supports (animation-timeline: view()) {
  .band .card.reveal, .means.reveal, .composer.reveal, .trust.reveal, details.reveal,
  section h2.reveal, section > h3.reveal, section > p.reveal, .contact-line.reveal,
  .stat-card.reveal, .stats.reveal, .numbers-cta.reveal, .stat-note.reveal {
    opacity: 1;
    transform: var(--tilt, none);
    transition: none;
  }
  .band .card, .means, .composer, .trust, details, section h2, section > h3, section > p,
  .contact-line, .stats, .numbers-cta, .stat-note {
    animation: pol-rise linear;
    animation-timeline: view();
    animation-range: entry 0% entry 85%;
    animation-fill-mode: backwards;
  }
  .stat-card { animation: none; }
  .band .tilt-l { animation-name: pol-in-left; }
  .band .tilt-c { animation-name: pol-in-up; }
  .band .tilt-r { animation-name: pol-in-right; }
  .hero h1, .hero .tagline, .hero .sub, .hero-art {
    animation: pol-hero-exit linear;
    animation-timeline: view();
    animation-range: exit 0% exit 75%;
    animation-fill-mode: none;
  }
  /* means rows + dots are JS-driven (app.js) so the sync works in every browser */
  /* dot-row sync is JS-driven (app.js) so it works in every browser */
}
@media (prefers-reduced-motion: reduce) {
  .band .card, .means, .composer, .trust, details, section h2, section > h3, section > p,
  .contact-line, .stats, .stat-card, .numbers-cta, .stat-note,
  .hero h1, .hero .tagline, .hero .sub, .hero-art, .means-deco span { animation: none !important; }
}

/* ---------- motion fallback: scroll reveals + load-in ---------- */
.reveal {
  opacity: 0;
  transform: translateY(42px);
  transition: opacity 0.7s cubic-bezier(0.22, 0.61, 0.36, 1), transform 0.7s cubic-bezier(0.22, 0.61, 0.36, 1);
  transition-delay: var(--d, 0ms);
  will-change: opacity, transform;
}
.reveal.in { opacity: 1; transform: none; }
.card.reveal { transform: translateY(42px) rotate(0deg); }
.card.reveal.in { transform: var(--tilt, none); }
.card.reveal.in:hover { transform: rotate(0deg) translateY(-8px); }
.stat-card.reveal.in { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .card.reveal, .card.reveal.in { opacity: 1; transform: var(--tilt, none); transition: none; }
  html { scroll-behavior: auto; }
}
