:root {
  color-scheme: light;
  --ink: #17212b;
  --muted: #5d6b7b;
  --paper: #f7f4ec;
  --surface: #fffdf7;
  --line: #ded6c5;
  --teal: #087e8b;
  --teal-dark: #065f68;
  --coral: #e45b46;
  --gold: #f2b84b;
  --green: #1c7c54;
  --shadow: 0 24px 70px rgba(23, 33, 43, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(rgba(222, 214, 197, 0.25) 1px, transparent 1px),
    linear-gradient(90deg, rgba(222, 214, 197, 0.25) 1px, transparent 1px),
    var(--paper);
  background-size: 32px 32px;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 70px);
  background: rgba(247, 244, 236, 0.86);
  border-bottom: 1px solid rgba(222, 214, 197, 0.8);
  backdrop-filter: blur(14px);
}

.brand,
.nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  color: #fff;
  background: var(--teal);
  border-radius: 8px;
  font-size: 24px;
}

.nav {
  gap: 22px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
}

.nav a:hover {
  color: var(--teal-dark);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  align-items: center;
  gap: clamp(32px, 6vw, 86px);
  min-height: calc(100vh - 74px);
  padding: clamp(44px, 7vw, 88px) clamp(20px, 5vw, 70px);
}

.hero-copy {
  max-width: 720px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--coral);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 22px;
  font-size: clamp(42px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 18px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.05;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 20px;
}

p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.65;
}

.hero-text {
  max-width: 620px;
  font-size: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 13px 20px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 800;
}

.button.primary {
  color: #fff;
  background: var(--teal);
  box-shadow: 0 14px 26px rgba(8, 126, 139, 0.23);
}

.button.primary:hover {
  background: var(--teal-dark);
}

.button.secondary {
  color: var(--teal-dark);
  background: var(--surface);
  border-color: var(--line);
}

.math-board {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  padding: 28px;
  color: #e9fff9;
  background:
    radial-gradient(circle at 18% 16%, rgba(242, 184, 75, 0.16), transparent 28%),
    linear-gradient(135deg, #0c3c3f, #092c33 58%, #12253a);
  border: 10px solid #c99854;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.math-board::before {
  content: "";
  position: absolute;
  inset: 20px;
  background:
    linear-gradient(rgba(233, 255, 249, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(233, 255, 249, 0.08) 1px, transparent 1px);
  background-size: 34px 34px;
  pointer-events: none;
}

.board-row {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  color: rgba(233, 255, 249, 0.86);
  font-size: clamp(18px, 2.4vw, 28px);
  font-weight: 700;
}

.board-main {
  position: relative;
  z-index: 1;
  height: 320px;
  margin: 42px 10px;
}

.axis {
  position: absolute;
  background: rgba(233, 255, 249, 0.68);
}

.axis.x {
  right: 0;
  bottom: 40%;
  left: 0;
  height: 2px;
}

.axis.y {
  top: 0;
  bottom: 0;
  left: 42%;
  width: 2px;
}

.curve {
  position: absolute;
  inset: 22px 32px 40px;
  border-bottom: 7px solid var(--gold);
  border-left: 7px solid transparent;
  border-radius: 50%;
  transform: rotate(-13deg);
}

.point {
  position: absolute;
  width: 18px;
  height: 18px;
  background: var(--coral);
  border: 3px solid #fff7e0;
  border-radius: 50%;
}

.point.one {
  top: 38%;
  left: 34%;
}

.point.two {
  top: 24%;
  right: 23%;
}

.section {
  padding: clamp(54px, 7vw, 96px) clamp(20px, 5vw, 70px);
}

.intro {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  padding-top: 0;
}

.intro > div {
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.stat {
  display: block;
  margin-bottom: 10px;
  color: var(--green);
  font-size: 34px;
  font-weight: 800;
}

.intro p {
  margin: 0;
}

.split,
.modality {
  display: grid;
  grid-template-columns: minmax(260px, 0.75fr) minmax(0, 1.25fr);
  gap: clamp(28px, 6vw, 78px);
  align-items: start;
}

.topic-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.topic-card {
  min-height: 190px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.topic-card h3 {
  color: var(--teal-dark);
}

.topic-card p {
  margin-bottom: 0;
}

.modality {
  background: #eaf5f3;
}

.steps {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.steps li {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 4px 18px;
  padding: 22px;
  background: #fff;
  border: 1px solid rgba(8, 126, 139, 0.18);
  border-radius: 8px;
}

.steps span {
  grid-row: span 2;
  color: var(--coral);
  font-size: 22px;
  font-weight: 800;
}

.steps strong {
  font-size: 19px;
}

.steps p {
  margin: 0;
}

.faq {
  display: grid;
  grid-template-columns: minmax(260px, 0.7fr) minmax(0, 1.3fr);
  gap: clamp(28px, 6vw, 78px);
  align-items: start;
}

.faq-heading {
  position: sticky;
  top: 104px;
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-list details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(23, 33, 43, 0.06);
}

.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
  color: var(--ink);
  cursor: pointer;
  font-size: 18px;
  font-weight: 800;
  list-style: none;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  display: grid;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  place-items: center;
  color: #fff;
  background: var(--teal);
  border-radius: 8px;
  font-size: 20px;
  line-height: 1;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list details p {
  margin: 0;
  padding: 0 22px 22px;
}

.contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: clamp(22px, 5vw, 70px);
  padding: clamp(30px, 5vw, 56px);
  color: #fff;
  background: var(--ink);
  border-radius: 8px;
}

.contact h2,
.contact p {
  max-width: 780px;
}

.contact p {
  color: rgba(255, 255, 255, 0.76);
  margin-bottom: 0;
}

.local-hero {
  min-height: auto;
  padding-bottom: clamp(36px, 6vw, 70px);
}

.local-panel {
  display: grid;
  gap: 16px;
  padding: clamp(24px, 4vw, 36px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.local-panel h2 {
  margin-bottom: 0;
  font-size: clamp(26px, 3vw, 38px);
}

.local-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.local-list li {
  padding-left: 26px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
  background:
    radial-gradient(circle at 8px 12px, var(--teal) 0 4px, transparent 5px);
}

.seo-copy {
  max-width: 1120px;
}

.seo-copy p {
  max-width: 940px;
}

.site-footer {
  padding: clamp(34px, 5vw, 58px) clamp(20px, 5vw, 70px);
  background: #101820;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(260px, 0.75fr) minmax(0, 1.25fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: start;
}

.footer-brand {
  color: #fff;
  margin-bottom: 14px;
}

.site-footer p {
  max-width: 520px;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.68);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.footer-links a {
  display: block;
  padding: 12px 14px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  font-size: 15px;
  font-weight: 700;
}

.footer-links a:hover {
  color: #fff;
  background: rgba(8, 126, 139, 0.55);
}

@media (max-width: 860px) {
  .site-header,
  .hero,
  .split,
  .modality,
  .faq,
  .intro,
  .contact,
  .footer-inner {
    display: block;
  }

  .site-header {
    position: static;
  }

  .nav {
    margin-top: 16px;
    flex-wrap: wrap;
  }

  .hero {
    min-height: auto;
  }

  .math-board {
    min-height: 430px;
    margin-top: 42px;
  }

  .intro {
    padding-top: 20px;
  }

  .topic-grid {
    grid-template-columns: 1fr;
    margin-top: 26px;
  }

  .steps {
    margin-top: 26px;
  }

  .faq-heading {
    position: static;
  }

  .faq-list {
    margin-top: 26px;
  }

  .contact .button {
    width: 100%;
    margin-top: 24px;
  }

  .footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 26px;
  }
}

@media (max-width: 520px) {
  .site-header {
    padding: 16px;
  }

  .brand {
    align-items: flex-start;
  }

  .nav {
    gap: 14px;
  }

  .hero,
  .section {
    padding-right: 16px;
    padding-left: 16px;
  }

  h1 {
    font-size: 40px;
  }

  .hero-text,
  p {
    font-size: 16px;
  }

  .button {
    width: 100%;
  }

  .math-board {
    min-height: 360px;
    padding: 18px;
    border-width: 7px;
  }

  .board-main {
    height: 230px;
    margin: 28px 0;
  }

  .board-row {
    display: grid;
    font-size: 17px;
  }

  .contact {
    margin: 16px;
  }

  .footer-links {
    grid-template-columns: 1fr;
  }
}
