/* EssayAce landing v3: the approved campaign look. Loud type, flat colour bands, red-pen marks, tilted paper cards. */
:root {
  --ink: #0b1b3a;
  --yellow: #f1ee4d;
  --red: #ef5445;
  --mint: #7bdabf;
  --violet: #6039cd;
  --tangerine: #eb8b33;
  --teal: #196f6e;
  --blue: #315def;
  --white: #ffffff;
  --paper: #fffdf2;
  --display: "Anton", "Impact", "Arial Narrow", sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --hand: "Playpen Sans", "Comic Sans MS", cursive;
  --wrap: 1180px;
  --hard: 0 6px 0 var(--ink);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img, video, svg { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.band-dark :focus-visible, .band-violet :focus-visible, .band-teal :focus-visible { outline-color: var(--yellow); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--yellow); padding: 10px 16px; z-index: 100; border-radius: 8px; font-weight: 700; }
.skip:focus { left: 8px; }

.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }

/* Display type */
.display {
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  line-height: 0.95;
  letter-spacing: 0.005em;
  margin: 0;
  text-wrap: balance;
}
.h-xl { font-size: clamp(3rem, 8.4vw, 6.9rem); }
.h-lg { font-size: clamp(2.5rem, 6.4vw, 5rem); }
.h-md { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
.lede { font-size: clamp(1.1rem, 1.7vw, 1.3rem); max-width: 34em; }

/* Buttons: flat, outlined, a hard shadow that presses down */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--body);
  font-weight: 800;
  font-size: 1.05rem;
  text-decoration: none;
  padding: 14px 26px;
  border: 3px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--yellow);
  box-shadow: var(--hard);
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 0 var(--ink); }
.btn:active { transform: translateY(5px); box-shadow: 0 1px 0 var(--ink); }
.btn-light { background: var(--white); color: var(--ink); }
.btn-yellow { background: var(--yellow); color: var(--ink); }
.btn-row { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }

/* Navigation */
.nav { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 3px solid var(--ink); }
.nav-in { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 1.35rem; letter-spacing: -0.01em; }
.brand img { width: 42px; height: 42px; }
.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; font-weight: 700; }
.nav-links a:not(.btn):hover { text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; text-decoration-color: var(--red); }
.nav-links .btn { padding: 9px 20px; font-size: 0.98rem; box-shadow: 0 4px 0 var(--ink); }
.nav-toggle { display: none; background: var(--yellow); border: 3px solid var(--ink); border-radius: 12px; padding: 8px 14px; font: inherit; font-weight: 800; cursor: pointer; box-shadow: 0 3px 0 var(--ink); }
@media (max-width: 860px) {
  .nav-toggle { display: inline-block; }
  .nav-links { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--white); flex-direction: column; align-items: stretch; gap: 0; border-bottom: 3px solid var(--ink); padding: 8px 20px 20px; }
  .nav-links.open { display: flex; }
  .nav-links li { border-bottom: 2px solid #e6e8ee; }
  .nav-links li:last-child { border: 0; padding-top: 14px; }
  .nav-links a { display: block; padding: 14px 0; }
  .nav-links .btn { display: inline-flex; padding: 12px 22px; }
}

/* Bands */
.band { padding: clamp(60px, 9vw, 120px) 0; position: relative; overflow: hidden; }
.band-yellow { background: var(--yellow); }
.band-red { background: var(--red); }
.band-mint { background: var(--mint); }
.band-violet { background: var(--violet); color: var(--white); }
.band-dark { background: var(--ink); color: var(--white); }
.band-teal { background: var(--teal); color: var(--white); }
.band-white { background: var(--white); }

section[id] { scroll-margin-top: 76px; }

/* Hero */
.hero { padding-top: clamp(44px, 7vw, 96px); padding-bottom: clamp(64px, 9vw, 120px); }
.hero-grid { display: grid; gap: clamp(32px, 5vw, 64px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 980px) { .hero-grid { grid-template-columns: 1.5fr 1fr; } }
.hero h1 { margin-bottom: 24px; }
.hero h1 .slash { position: relative; display: inline-block; }
.hero h1 .slash::after {
  content: "";
  position: absolute;
  left: -2%;
  right: -2%;
  bottom: -0.02em;
  height: 0.09em;
  background: var(--red);
  transform: rotate(-1.6deg);
  border-radius: 4px;
}
.hero .lede { margin: 0 0 30px; font-weight: 500; }
.hero-note { margin-top: 22px; font-size: 0.98rem; font-weight: 600; }

/* The red-pen demo */
.pen-card {
  position: relative;
  background: var(--white);
  border: 3px solid var(--ink);
  border-radius: 24px;
  box-shadow: 8px 8px 0 var(--ink);
  padding: 26px 26px 22px;
  transform: rotate(-2deg);
  max-width: 470px;
  margin-inline: auto;
}
.pen-tag { display: inline-block; background: var(--ink); color: var(--yellow); font-weight: 800; font-size: 0.82rem; padding: 4px 12px; border-radius: 999px; margin-bottom: 18px; }
.pen-line { font-family: var(--display); text-transform: uppercase; font-size: clamp(1.7rem, 3.4vw, 2.4rem); line-height: 1.12; margin: 0; }
.pen-old { position: relative; display: inline; background: linear-gradient(var(--red), var(--red)) no-repeat 0 55% / 0% 0.11em; animation: pen-strike 0.7s 0.9s ease-out forwards; }
.pen-new { display: block; margin-top: 14px; color: var(--blue); opacity: 0; transform: translateY(8px) rotate(-1deg); animation: pen-write 0.6s 1.7s ease-out forwards; }
.pen-note { font-family: var(--hand); font-size: 0.98rem; color: var(--red); margin: 18px 0 0; transform: rotate(-1.5deg); opacity: 0; animation: pen-write 0.6s 2.3s ease-out forwards; }
.pen-small { margin: 10px 0 0; font-size: 0.88rem; font-weight: 600; opacity: 0.8; }
.pen-replay { margin-top: 14px; background: none; border: 0; padding: 0; font: inherit; font-weight: 800; font-size: 0.9rem; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
@keyframes pen-strike { to { background-size: 100% 0.11em; } }
@keyframes pen-write { to { opacity: 1; transform: none; } }
.pen-card.is-replaying .pen-old, .pen-card.is-replaying .pen-new, .pen-card.is-replaying .pen-note { animation: none; }

/* Marquee */
.marquee { background: var(--ink); color: var(--yellow); border-block: 3px solid var(--ink); overflow: hidden; white-space: nowrap; }
.marquee-track { display: inline-flex; animation: marquee 28s linear infinite; }
.marquee span { font-family: var(--display); text-transform: uppercase; font-size: clamp(1.5rem, 3vw, 2.2rem); padding: 14px 28px; display: inline-flex; align-items: center; gap: 56px; }
.marquee span::after { content: "\2605"; color: var(--red); font-size: 0.8em; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Section headings */
.sec-head { max-width: 58rem; margin-bottom: clamp(32px, 5vw, 56px); }
.sec-head p { max-width: 40rem; }
.sec-head p { margin: 18px 0 0; font-size: 1.15rem; }

/* Steps: a real sequence, so the numerals mean something */
.steps { display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step {
  background: var(--paper);
  border: 3px solid var(--ink);
  border-radius: 22px;
  padding: 26px 26px 30px;
  box-shadow: var(--hard);
  color: var(--ink);
}
.step:nth-child(1) { transform: rotate(-1.4deg); }
.step:nth-child(2) { transform: rotate(1deg) translateY(10px); }
.step:nth-child(3) { transform: rotate(-0.8deg); }
.step .num { font-family: var(--display); font-size: 4.2rem; line-height: 1; color: var(--red); -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; }
.step h3 { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: 2rem; margin: 6px 0 10px; line-height: 1; }
.step p { margin: 0; }
@media (max-width: 899px) { .step:nth-child(n) { transform: none; } }

/* Product videos */
.demo-grid { display: grid; gap: 36px; grid-template-columns: 1fr; }
@media (min-width: 820px) { .demo-grid { grid-template-columns: 1fr 1fr; } }
.demo { margin: 0; }
.demo-frame { border: 3px solid var(--ink); border-radius: 26px; overflow: hidden; background: var(--ink); box-shadow: 8px 8px 0 var(--ink); max-width: 420px; margin-inline: auto; }
.demo-frame video { width: 100%; height: auto; background: var(--ink); }
.demo figcaption { max-width: 420px; margin: 20px auto 0; }
.demo figcaption strong { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: 1.9rem; display: block; line-height: 1.05; margin-bottom: 6px; }

/* Practice chips */
.chips { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.chip {
  background: var(--white);
  color: var(--ink);
  border: 3px solid var(--ink);
  border-radius: 20px;
  box-shadow: 0 5px 0 var(--ink);
  padding: 14px 10px 14px;
  text-align: center;
  font-weight: 800;
  line-height: 1.2;
}
.chip img { width: 60px; height: 60px; margin: 0 auto 8px; }
.chip small { display: block; font-weight: 500; font-size: 0.82rem; margin-top: 4px; }
.split { display: grid; gap: clamp(32px, 5vw, 64px); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 980px) { .split { grid-template-columns: 0.85fr 1.15fr; } }
.practice-copy p { font-size: 1.15rem; margin: 18px 0 0; }
.practice-copy ul { margin: 22px 0 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.practice-copy li { display: flex; gap: 12px; align-items: flex-start; font-weight: 600; }
.practice-copy li img { width: 38px; height: 38px; flex: none; }

/* Workshop: three openings, one setting */
.tabs { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 24px; }
.tab {
  font: inherit;
  font-weight: 800;
  background: var(--white);
  color: var(--ink);
  border: 3px solid var(--ink);
  border-radius: 999px;
  padding: 10px 22px;
  cursor: pointer;
  box-shadow: 0 4px 0 var(--ink);
}
.tab[aria-selected="true"] { background: var(--ink); color: var(--yellow); }
.panel {
  border: 3px solid var(--ink);
  border-radius: 28px;
  box-shadow: 8px 8px 0 var(--ink);
  padding: clamp(26px, 5vw, 56px);
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  transition: background-color 0.25s ease;
}
.panel[data-tone="mint"] { background: var(--mint); }
.panel[data-tone="tangerine"] { background: var(--tangerine); }
.panel[data-tone="yellow"] { background: var(--yellow); }
.panel blockquote { margin: 0; font-family: var(--display); text-transform: uppercase; font-size: clamp(2rem, 5vw, 3.8rem); line-height: 1.02; }
.panel .ask { font-weight: 800; font-size: 1.15rem; }
.panel .ask span { font-family: var(--hand); color: var(--red); font-weight: 500; display: inline-block; transform: rotate(-1.5deg); }
.fine { font-size: 0.92rem; font-weight: 600; margin-top: 18px; }

/* Audiences */
.aud-grid { display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 980px) { .aud-grid { grid-template-columns: repeat(3, 1fr); } }
.aud { border: 3px solid var(--ink); border-radius: 26px; padding: 30px 28px 34px; box-shadow: 8px 8px 0 var(--ink); }
.aud h3 { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: clamp(2rem, 3.2vw, 2.7rem); line-height: 1; margin: 0 0 14px; }
.aud p { margin: 0 0 12px; }
.aud ol, .aud ul { margin: 14px 0 0; padding-left: 1.25em; display: grid; gap: 10px; font-weight: 600; }
.aud-parents { background: var(--tangerine); }
.aud-tutors { background: var(--ink); color: var(--white); }
.aud-learners { background: var(--mint); }
.aud-tutors { box-shadow: 8px 8px 0 var(--red); }

/* Story / community */
.story-grid { display: grid; gap: clamp(28px, 5vw, 64px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 900px) { .story-grid { grid-template-columns: 1.1fr 1fr; } }
.story-grid p { font-size: 1.15rem; margin: 18px 0 0; }
.photo-stack { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.photo { border: 3px solid var(--ink); border-radius: 20px; overflow: hidden; box-shadow: 6px 6px 0 var(--ink); background: var(--white); }
.photo img { width: 100%; height: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 50% 30%; }
.photo:nth-child(odd) { transform: rotate(-1.5deg); }
.photo:nth-child(even) { transform: rotate(1.2deg) translateY(12px); }
.link-arrow { display: inline-block; margin-top: 22px; font-weight: 800; text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 6px; text-decoration-color: var(--yellow); }
.band-teal .link-arrow { text-decoration-color: var(--yellow); }

/* Instagram */
.ig-grid { display: grid; gap: 16px; grid-template-columns: repeat(3, 1fr); align-items: center; }
.ig-tile { display: block; border: 3px solid var(--ink); border-radius: 18px; overflow: hidden; box-shadow: 6px 6px 0 var(--ink); background: var(--ink); transition: transform 0.15s ease; }
.ig-tile img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.ig-tile:nth-child(1) { transform: rotate(-2deg); }
.ig-tile:nth-child(2) { transform: translateY(14px) rotate(1deg); }
.ig-tile:nth-child(3) { transform: rotate(2deg); }
.ig-tile:hover { transform: translateY(-4px) rotate(0deg); }
.ig-icon { flex: none; }
@media (max-width: 560px) { .ig-grid { gap: 10px; } .ig-tile { border-radius: 12px; box-shadow: 4px 4px 0 var(--ink); } }
@media (prefers-reduced-motion: reduce) { .ig-tile { transition: none; } }

/* Final call */
.final h2 { max-width: 14ch; }
.final .btn-row { margin-top: 32px; }
.contact-line { margin-top: 34px; font-weight: 700; }
.contact-line a { text-decoration-thickness: 3px; text-underline-offset: 5px; }

/* Footer */
.footer { background: var(--ink); color: var(--white); padding: 44px 0 36px; }
.footer-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 28px; align-items: flex-start; }
.footer .brand { color: var(--white); }
.footer p { margin: 10px 0 0; max-width: 24em; opacity: 0.85; }
.footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 26px; }
.footer a { font-weight: 700; text-decoration: none; }
.footer a:hover { text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 3px; text-underline-offset: 5px; }
.legal { width: min(var(--wrap), 100% - 40px); margin: 30px auto 0; padding-top: 20px; border-top: 2px solid rgba(255, 255, 255, 0.2); font-size: 0.9rem; opacity: 0.8; }

/* Inner pages */
.page-hero { padding: clamp(56px, 8vw, 110px) 0 clamp(44px, 6vw, 80px); }
.prose { max-width: 44rem; }
.prose p { font-size: 1.15rem; }
.prose h2 { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: clamp(2rem, 4vw, 3rem); line-height: 1; margin: 48px 0 12px; }
.person-grid { display: grid; gap: 28px; grid-template-columns: 1fr; margin-top: 36px; }
@media (min-width: 720px) { .person-grid { grid-template-columns: 1fr 1fr; } }
.person { display: flex; gap: 18px; align-items: center; background: var(--white); border: 3px solid var(--ink); border-radius: 22px; padding: 16px; box-shadow: var(--hard); color: var(--ink); }
.person img { width: 92px; height: 92px; border-radius: 50%; object-fit: cover; object-position: 50% 30%; border: 3px solid var(--ink); flex: none; }
.person strong { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: 1.5rem; display: block; line-height: 1.05; }
.partner { background: var(--white); color: var(--ink); border: 3px solid var(--ink); border-radius: 26px; box-shadow: 8px 8px 0 var(--ink); padding: clamp(22px, 4vw, 38px); margin-bottom: 40px; }
.partner h2 { font-family: var(--display); text-transform: uppercase; font-weight: 400; font-size: clamp(1.9rem, 3.6vw, 2.8rem); line-height: 1; margin: 0 0 6px; }
.partner .when { font-weight: 800; color: var(--violet); margin: 0 0 14px; }
.partner .photos { display: grid; gap: 14px; grid-template-columns: repeat(3, 1fr); margin-top: 22px; }
.partner .photos img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border: 3px solid var(--ink); border-radius: 14px; }
@media (max-width: 560px) { .partner .photos { grid-template-columns: 1fr; } }
.fourofour { min-height: 70vh; display: grid; place-items: center; text-align: center; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pen-old { animation: none; background-size: 100% 0.11em; }
  .pen-new, .pen-note { animation: none; opacity: 1; transform: none; }
  .marquee-track { animation: none; }
  .btn, .panel { transition: none; }
}
