/* Clasa home.
 *
 * One claim: school messaging where the teacher's phone number is never in the
 * room. Everything here states that claim, proves it, or asks for the download.
 *
 * COLOUR — the fix
 * The first pass carried five: green, a green wash, a red for the "bad"
 * column, black and grey. Five colours on a page with one idea is not a
 * palette, it is noise — and the red did the argument active harm. A product
 * that has to paint its rival red is not a product that is confident.
 *
 * The correction after that was an overcorrection: green got demoted to a
 * four-letter label and the one button on the page became a solid black brick
 * with no brand on it anywhere. A messenger whose accent is #01DA51 should not
 * ask for the download in black.
 *
 * So the rule is about ROLE, not quantity. Green means "this is the action, or
 * this is the number that matters": the button, the struck-out rival, the zero,
 * the tap. Ink is type, grey is support, and nothing else gets a colour — the
 * contrast column is still weight and opacity, never red.
 *
 * TYPE, AND NO PICTURE
 * The mockup is gone. It was a stock phone standing in for an argument, and it
 * made the hero fight itself for attention. With no illustration the sentence
 * has to carry the page — which is the right pressure to be under, because the
 * sentence is the product.
 *
 * MOTION — and why there is no library
 * The reference (cofee.life) runs GSAP + ScrollTrigger + Lenis + Swiper. Lenis
 * is the part that feels expensive, and it earns that by replacing native
 * scrolling with a JavaScript loop: ~100KB of vendor to make a page about being
 * the calm option stutter on the cheap Android phones this audience holds.
 * Reveals are IntersectionObserver, the pinned card is position:sticky, the
 * rest are CSS transitions.
 */

:root {
  --ink: #0A0A0B;
  --ink-2: #5B6068;
  /* 4.83:1 on white. The previous value was #9096A0 at 2.98:1 — it failed AA
     and it was carrying real body text: the eyebrows, the fine print, and the
     whole WhatsApp column of the comparison. Grey is not licence to be
     unreadable. */
  --ink-3: #6B7280;
  --paper: #FFFFFF;
  --wash: #F6F7F8;
  --line: rgba(10, 10, 11, 0.10);
  --accent: #01DA51;
  /* Green is bright — luminance is high enough that near-black type on it beats
     white by a wide margin, so the button reads as brand rather than as a dark
     slab wearing a tint. */
  --on-accent: #062B14;
  --accent-deep: #00B944;
  /* #01DA51 is a FILL colour: on white it is 1.88:1, so the green "0" was
     close to invisible — the one number the page is built around. This is the
     same hue taken down to 4.95:1 for use as type on light. */
  --accent-type: #038233;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --slow: 0.85s;

  --h1: clamp(2.4rem, 12vw, 8rem);
  --h2: clamp(1.8rem, 7vw, 3.6rem);
  --lead: clamp(1.02rem, 4vw, 1.45rem);
}

.clasa-home-2 {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  /* Safari on iPhone grows body text when the phone is turned sideways, which
     silently breaks every size decision above. */
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

/* Long words in a huge heading are the one thing that can force a sideways
   scroll on a 320px screen, and text-wrap:balance keeps two-line headings from
   leaving one orphaned word. */
.clasa-home-2 h1,
.clasa-home-2 h2 { overflow-wrap: break-word; text-wrap: balance; }

.wrap-2 { width: min(1080px, 100% - 2.5rem); margin-inline: auto; }

/* ── Reveal ───────────────────────────────────────────────────────────────
   One mechanism for the page. JS adds .is-in; a visitor whose script never
   runs still sees everything (.no-js, at the bottom). */
.rise {
  opacity: 0;
  transform: translate3d(0, 22px, 0);
  transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease);
  transition-delay: calc(var(--i, 0) * 80ms);
}
.rise.is-in { opacity: 1; transform: none; }

/* ── Hero ─────────────────────────────────────────────────────────────────
   No illustration. The claim is the hero. */
.hero-2 { padding: clamp(4rem, 11vw, 9rem) 0 clamp(3rem, 6vw, 5rem); }

.kicker {
  display: inline-flex;
  align-items: baseline;
  gap: 0.55rem;
  font-size: 0.9rem;
  font-weight: 560;
  letter-spacing: -0.012em;
  color: var(--ink-2);
  text-decoration: none;
  /* It is a link to the card section, and at 0.9rem it was a ~20px tap target.
     The negative margin keeps the padding from shifting the layout. */
  min-height: 44px;
  padding: 0.6rem 0;
  margin: -0.6rem 0;
}
/* The only green on this screen, and it is four letters wide. */
.kicker b {
  color: var(--accent-type);
  font-weight: 780;
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.kicker:hover { color: var(--ink); }

.hero-2 h1 {
  margin: 1.5rem 0 0;
  font-size: var(--h1);
  line-height: 0.9;
  letter-spacing: -0.05em;
  font-weight: 800;
  max-width: 13ch;
}
/* The incumbent, crossed out. Drawn on arrival, so it reads as an action
   rather than a decoration that was always there. */
.strike { position: relative; white-space: nowrap; }
.strike::after {
  content: "";
  position: absolute;
  left: -0.01em; right: -0.01em;
  top: 55%;
  height: 0.07em;
  background: var(--accent);
  border-radius: 999px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.7s var(--ease) 0.4s;
}
.is-in .strike::after { transform: scaleX(1); }

.hero-lead {
  margin: 2rem 0 0;
  max-width: 40ch;
  font-size: var(--lead);
  line-height: 1.45;
  letter-spacing: -0.014em;
  color: var(--ink-2);
}
.hero-lead strong { color: var(--ink); font-weight: 640; }

.badge-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.65rem; margin-top: 2.5rem; }
.badge-row a { display: inline-flex; transition: transform 0.2s var(--ease); }
.badge-row a:hover { transform: translateY(-2px); }
.badge-row img { display: block; height: 50px; width: auto; }

/* ── Section furniture ────────────────────────────────────────────────────── */
.band { padding: clamp(4.5rem, 10vw, 8.5rem) 0; }
.band-wash { background: var(--wash); }
.eyebrow-2 {
  margin: 0 0 1.1rem;
  font-size: 0.76rem;
  font-weight: 750;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.band h2 {
  margin: 0;
  font-size: var(--h2);
  line-height: 1;
  letter-spacing: -0.045em;
  font-weight: 800;
  max-width: 17ch;
}
.band .sub {
  margin: 1.4rem 0 0;
  max-width: 50ch;
  font-size: var(--lead);
  line-height: 1.5;
  letter-spacing: -0.012em;
  color: var(--ink-2);
}

/* ── The contrast ─────────────────────────────────────────────────────────
   Two lists, separated by a rule. The difference is weight, not hue. */
.versus {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  border-top: 1px solid var(--line);
}
.vcard { padding: 2rem 0; }
@media (min-width: 620px) {
  .vcard { padding-right: 2.5rem; }
  .vcard + .vcard { padding-left: 2.5rem; border-left: 1px solid var(--line); }
}
.vcard h3 {
  margin: 0 0 1.4rem;
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink-3);
}
.vcard.good h3 { color: var(--ink); }
.vcard ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 1rem; }
.vcard li { font-size: 1.02rem; line-height: 1.45; letter-spacing: -0.012em; color: var(--ink-3); }
.vcard.good li { color: var(--ink); font-weight: 520; }

/* ── Capabilities. Messaging leads by size, not decoration. ──────────────── */
.caps {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  border-top: 1px solid var(--line);
}
.cap { padding: 2rem 0; }
@media (min-width: 760px) {
  .cap { padding-right: 2rem; }
  .cap + .cap { padding-left: 2rem; border-left: 1px solid var(--line); }
}
.cap.lead {
  grid-column: 1 / -1;
  padding-left: 0;
  border-left: 0;
  border-bottom: 1px solid var(--line);
}
.cap.lead h3 { margin-bottom: 0.9rem; font-size: clamp(1.9rem, 4vw, 2.8rem); letter-spacing: -0.04em; }
.cap.lead p { font-size: var(--lead); max-width: 46ch; }
.cap h3 { margin: 0 0 0.5rem; font-size: 1.08rem; font-weight: 700; letter-spacing: -0.02em; }
.cap p { margin: 0; font-size: 0.98rem; line-height: 1.5; color: var(--ink-2); }
.soon {
  display: block;
  margin-bottom: 0.7rem;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-type);
}

/* ── The Card ─────────────────────────────────────────────────────────────
   The one pinned moment, and the only looping animation on the page. */
.card-band { background: var(--ink); color: var(--paper); }
.card-band h2 { color: var(--paper); }
.card-band .sub { color: rgba(255, 255, 255, 0.6); }
.card-band .eyebrow-2 { color: var(--accent); }

.card-stage { display: grid; gap: clamp(2.5rem, 6vw, 5rem); align-items: start; }
@media (min-width: 900px) {
  .card-stage { grid-template-columns: 0.9fr 1.1fr; }
  .card-pin { position: sticky; top: 22vh; }
}

.rfid {
  position: relative;
  aspect-ratio: 1.586;
  max-width: 380px;
  border-radius: 18px;
  background: #17191C;
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transform: perspective(1200px) rotateY(-12deg);
  transition: transform 1.1s var(--ease);
}
.is-in .rfid { transform: perspective(1200px) rotateY(-4deg); }
.rfid-name { margin: 0; font-size: 1.05rem; font-weight: 680; letter-spacing: -0.02em; }
.rfid-sub { margin: 0.2rem 0 0; font-size: 0.79rem; color: rgba(255, 255, 255, 0.45); }
.rfid-brand { display: flex; align-items: center; gap: 0.5rem; font-size: 0.86rem; font-weight: 700; letter-spacing: -0.01em; }
.rfid-brand i { width: 7px; height: 7px; border-radius: 999px; background: var(--accent); }

.wave { position: absolute; right: 1.4rem; bottom: 1.4rem; width: 42px; height: 42px; }
.wave span {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 1.5px solid var(--accent);
  opacity: 0;
  animation: ping 2.8s var(--ease) infinite;
}
.wave span:nth-child(2) { animation-delay: 0.9s; }
@keyframes ping {
  0%   { transform: scale(0.3); opacity: 0.85; }
  70%  { opacity: 0; }
  100% { transform: scale(1.7); opacity: 0; }
}

.card-steps { margin: clamp(2rem, 4vw, 3rem) 0 0; padding: 0; list-style: none; display: grid; gap: 1.5rem; }
.card-steps li { display: flex; gap: 1.1rem; align-items: baseline; }
.card-steps b {
  flex: none;
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.card-steps p { margin: 0; font-size: 1.02rem; line-height: 1.5; color: rgba(255, 255, 255, 0.66); }
.card-steps strong { color: var(--paper); font-weight: 620; }
.card-preorder { margin-top: 2rem; }

/* ── Price and close, one section ─────────────────────────────────────────
   They used to be two, and the second only repeated the first's buttons. */
.free-2 { text-align: center; }
.free-2 .close-mark { display: block; margin: 0 auto 2rem; border-radius: 16px; }
.free-2 .zero {
  margin: 0;
  font-size: clamp(4rem, 30vw, 17rem);
  line-height: 0.78;
  font-weight: 800;
  letter-spacing: -0.07em;
}
.free-2 h2 { margin: 1.75rem auto 0; max-width: 18ch; }
.free-2 .sub { margin-inline: auto; }
.free-2 .badge-row { justify-content: center; }

/* One button on the page, and it is the last thing on it. Everything above
   asks for attention; this asks for the download. */
.close-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin: 2.5rem 0 0;
}
.btn-2 {
  display: inline-flex;
  align-items: center;
  min-height: 54px;
  padding: 0 1.9rem;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-size: 1.02rem;
  font-weight: 700;
  letter-spacing: -0.014em;
  text-decoration: none;
  transition: transform 0.2s var(--ease), background 0.2s, box-shadow 0.2s var(--ease);
}
.btn-2:hover {
  transform: translateY(-2px);
  background: var(--accent-deep);
  box-shadow: 0 14px 30px rgba(1, 218, 81, 0.34);
}

@media (prefers-reduced-motion: reduce) {
  .rise { opacity: 1; transform: none; transition: none; }
  .strike::after { transform: scaleX(1); transition: none; }
  .rfid { transform: none; transition: none; }
  .wave span { animation: none; opacity: 0.3; }
  .badge-row a, .btn-2 { transition: none; }
}

.no-js .rise { opacity: 1; transform: none; }

/* ── Hero action ───────────────────────────────────────────────────────────
   The button leads; the badges follow as platform detail rather than as the
   decision itself. Their row tightens up here so the two do not read as two
   competing calls to action. */
.hero-actions { margin: 2.5rem 0 0; }
.hero-actions + .badge-row { margin-top: 1.5rem; }
.hero-actions + .badge-row img { height: 44px; }

/* ── Phones ────────────────────────────────────────────────────────────────
   Not a separate design — the same one, measured at the size most of this
   audience will actually see it. */
@media (max-width: 560px) {
  /* At 50px each these wrapped to three stacked rows and pushed the first
     section off the screen; at 40px two sit side by side. */
  .badge-row img,
  .hero-actions + .badge-row img { height: 40px; }
  .badge-row { gap: 0.5rem; }

  /* A full-width button is easier to hit with a thumb than a centred pill. */
  .btn-2 { width: 100%; justify-content: center; }
  .close-actions { display: block; }

  /* The card is the one thing that must not be cropped on a narrow screen. */
  .rfid { max-width: 100%; padding: 1.25rem; }
  .rfid-name { font-size: 1rem; }

  .card-steps { gap: 1.25rem; }
  .versus, .caps { margin-top: 2rem; }
}
