/* =========================================================
   Keep Me Posted — landing page
   Direction: Swiss × Lenny — warm editorial
   warm sheet · cream beds · coral accent · grotesk + grid
   Swiss bones (grid, scale, structural rules, mono labels)
   warmed with Lenny's coral, cream feature beds, soft edges.
   Single-family grotesk (Archivo) does display + body;
   Space Mono carries only the micro-metadata labels.
   ========================================================= */

:root {
  --paper: #ffffff; /* Lenny white sheet */
  --paper-2: #f7f1ea; /* subtle warm panel */
  --cream: #fbe6d4; /* Lenny peach feature bed */
  --ink: #363737; /* Lenny text — neutral dark */
  --ink-70: #5f6061;
  --ink-45: #8c8d8d;
  --red: #f47c55; /* Lenny coral (fills, large display, LIVE) */
  --red-deep: #be5234; /* darker coral for small-text links / status — legible on white */
  --hair: rgba(54, 55, 55, 0.14);
  --rule: var(--ink); /* thick structural rules use Lenny ink */

  --grotesk: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Space Mono", "SFMono-Regular", ui-monospace, monospace;

  --radius: 9px; /* cards, form, panels */
  --radius-sm: 6px; /* buttons, pills, mark */
  --shadow: 0 1px 2px rgba(54, 55, 55, 0.06), 0 10px 30px -16px rgba(54, 55, 55, 0.28);
  --btn-inset: inset 0 1px 0 rgba(255, 255, 255, 0.22), inset 0 -1px 0 rgba(0, 0, 0, 0.12);

  --maxw: 1240px;
  --gutter: clamp(1.25rem, 4vw, 4.5rem);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--grotesk);
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.12rem);
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3 {
  font-family: var(--grotesk);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.03em;
  margin: 0;
  text-wrap: balance;
}

a {
  color: inherit;
}

::selection {
  background: var(--red);
  color: var(--paper);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 1rem;
  z-index: 100;
  font-family: var(--mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

:focus-visible {
  outline: 2.5px solid var(--red);
  outline-offset: 3px;
}

/* shared micro-label (mono, uppercase) */
.kicker,
.section-rule,
.masthead-nav,
.chyron-list li,
.card-no,
.join-fine,
.join-status,
.footer-meta,
.closer-sub {
  font-family: var(--mono);
}

/* ===== Chyron ticker (squared off) ===== */
.chyron {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: stretch;
  background: var(--ink);
  color: var(--paper);
  height: 36px;
  overflow: hidden;
}

.chyron-live {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: none;
  background: var(--red);
  color: var(--paper);
  padding: 0 1.1rem;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  z-index: 2;
}
.chyron-live .dot {
  width: 7px;
  height: 7px;
  background: var(--paper);
  border-radius: 50%;
  animation: blink 1.6s steps(1) infinite;
}
@keyframes blink {
  50% {
    opacity: 0.2;
  }
}

.chyron-track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: ticker 40s linear infinite;
}
.chyron:hover .chyron-track {
  animation-play-state: paused;
}
.chyron-list {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}
.chyron-list li {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0 1.4rem;
}
.chyron-list li::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--red);
  margin-right: 1.4rem;
  vertical-align: middle;
}
@keyframes ticker {
  to {
    transform: translateX(-50%);
  }
}

/* ===== Masthead ===== */
.masthead {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.5rem var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 2px solid var(--rule);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  font-family: var(--grotesk);
  font-weight: 800;
  font-size: 1.12rem;
  letter-spacing: -0.02em;
}
.brand-glyph {
  width: 15px;
  height: 15px;
  background: var(--red);
  border-radius: 2px;
  flex: none;
}

.masthead-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.5vw, 2.2rem);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.masthead-nav a {
  text-decoration: none;
  color: var(--ink-70);
  transition: color 0.15s;
}
.masthead-nav a:hover {
  color: var(--ink);
}
.masthead-nav .nav-cta {
  color: #fff;
  background: var(--red);
  padding: 0.55rem 1rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--btn-inset);
}
.masthead-nav .nav-cta:hover {
  background: var(--red-deep);
  color: #fff;
}
@media (max-width: 720px) {
  .masthead-nav a:not(.nav-cta) {
    display: none;
  }
}

/* ===== Hero ===== */
.hero {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(2.5rem, 6vw, 5rem) var(--gutter) clamp(2.5rem, 5vw, 4.5rem);
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-70);
  margin: 0 0 1.6rem;
}
.kicker-bar {
  width: 30px;
  height: 9px;
  background: var(--red);
  display: inline-block;
}

.hero-title {
  font-size: clamp(2.9rem, 1.1rem + 8.4vw, 8.5rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 0.92;
  margin: 0 0 0;
  max-width: 15ch;
}
.hero-title span {
  display: block;
}
.hero-title .accent {
  color: var(--red);
}

/* thick rule under the headline, then a two-column band */
.hero-band {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: start;
  margin-top: clamp(2rem, 4vw, 3.2rem);
  padding-top: 1.8rem;
  border-top: 2px solid var(--rule);
}
.hero-lede {
  font-size: clamp(1.1rem, 1rem + 0.6vw, 1.4rem);
  line-height: 1.45;
  color: var(--ink-70);
  max-width: 42ch;
  margin: 0;
  font-weight: 400;
}
/* Lenny-style "subscribe on cream" focal card */
.hero-form-col {
  display: flex;
  flex-direction: column;
  background: var(--cream);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 3vw, 2rem);
}
@media (max-width: 820px) {
  .hero-band {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* ===== Join form (squared, no shadow) ===== */
.join {
  display: flex;
  align-items: stretch;
  gap: 0;
  width: 100%;
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.join:focus-within {
  border-color: var(--red);
}
.join-prompt {
  display: flex;
  align-items: center;
  flex: none;
  width: 10px;
  background: var(--red);
  font-size: 0; /* hide the legacy glyph; the red bar carries it */
}
.join input {
  flex: 1;
  border: 0;
  background: transparent;
  font-family: var(--mono);
  font-size: 0.95rem;
  color: var(--ink);
  padding: 1rem 1rem;
  min-width: 0;
}
.join input::placeholder {
  color: var(--ink-45);
}
.join input:focus {
  outline: none;
}
.join button {
  flex: none;
  border: 0;
  border-left: 2px solid var(--ink);
  background: var(--ink);
  color: #fff;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.76rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1rem 1.5rem;
  cursor: pointer;
  box-shadow: var(--btn-inset);
  transition: background 0.15s ease, border-color 0.15s ease;
}
.join button:hover {
  background: var(--red);
  border-left-color: var(--red);
}
.join button:disabled {
  cursor: default;
  opacity: 0.7;
}
.join.is-sent {
  border-color: var(--red);
}

.join-status {
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  margin: 0.9rem 0 0;
  min-height: 1.2em;
  color: var(--red-deep);
  text-transform: uppercase;
}
.join-status.ok {
  color: var(--ink);
}

.join-fine {
  font-size: 0.72rem;
  color: var(--ink-45);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin: 0.8rem 0 0;
}

@media (max-width: 460px) {
  .join {
    flex-wrap: wrap;
  }
  .join input {
    width: 100%;
  }
  .join button {
    width: 100%;
    border-left: 0;
    border-top: 2px solid var(--ink);
  }
}

/* ===== Sections ===== */
.section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(3rem, 6vw, 5.5rem) var(--gutter);
  border-top: 2px solid var(--rule);
}

.section-rule {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-70);
  margin-bottom: 2.6rem;
}
.section-rule .no {
  color: var(--red);
  font-weight: 700;
}
/* trailing hairline that runs to the margin — the Swiss grid tell */
.section-rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hair);
}

.section-title {
  font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 0.98;
  max-width: 18ch;
  margin-bottom: 2.8rem;
}

/* Beat */
.beat {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(1.5rem, 5vw, 4.5rem);
  align-items: start;
}
.beat-head {
  font-size: clamp(1.9rem, 1.2rem + 2.8vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 0.98;
}
.beat-body p {
  margin: 0 0 1.1rem;
  font-size: 1.08rem;
  line-height: 1.55;
  color: var(--ink-70);
}
.beat-body em {
  font-style: normal;
  font-weight: 700;
  color: var(--ink);
}
@media (max-width: 800px) {
  .beat {
    grid-template-columns: 1fr;
  }
}

/* Cards / box score — white tiles on a Lenny cream bed */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(0.9rem, 2vw, 1.4rem);
  background: var(--cream);
  border-radius: var(--radius);
  padding: clamp(0.9rem, 2vw, 1.4rem);
}
.card {
  padding: clamp(1.5rem, 2.5vw, 2.2rem);
  background: #fffdf8;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgba(42, 37, 32, 0.07), 0 16px 36px -16px rgba(42, 37, 32, 0.34);
}
.card-no {
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--red);
  letter-spacing: 0.12em;
}
.card h3 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 1rem 0 0.7rem;
}
.card p {
  margin: 0;
  color: var(--ink-70);
  font-size: 1rem;
  line-height: 1.5;
}
@media (max-width: 760px) {
  .cards {
    grid-template-columns: 1fr;
  }
}

/* Loop */
.loop {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.4rem, 4vw, 3rem);
}
.loop li {
  border-top: 8px solid var(--ink);
  padding-top: 1.1rem;
}
.loop li:nth-child(2) {
  border-top-color: var(--red);
}
.loop-step {
  font-family: var(--grotesk);
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: -0.02em;
  display: block;
  margin-bottom: 0.4rem;
}
.loop p {
  margin: 0;
  color: var(--ink-70);
  font-size: 1.02rem;
  line-height: 1.5;
}
@media (max-width: 700px) {
  .loop {
    grid-template-columns: 1fr;
  }
}

/* ===== Closer ===== */
.closer {
  background: var(--ink);
  color: var(--paper);
  padding: clamp(3.5rem, 8vw, 7rem) var(--gutter);
  margin-top: 0;
}
.closer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
}
.closer-head {
  font-size: clamp(2.3rem, 1.4rem + 4.4vw, 5.5rem);
  font-weight: 800;
  color: var(--paper);
  letter-spacing: -0.035em;
  line-height: 0.94;
  max-width: 14ch;
  margin: 0 0 1.4rem;
}
.closer-sub {
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(251, 251, 248, 0.65);
  margin: 0 0 2.4rem;
  max-width: 44ch;
}
.closer-btn {
  display: inline-block;
  background: var(--red);
  color: #fff;
  text-decoration: none;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 1.05rem 2.4rem;
  border: 2px solid var(--red);
  border-radius: var(--radius-sm);
  box-shadow: var(--btn-inset);
  transition: background 0.15s ease, color 0.15s ease;
}
.closer-btn:hover {
  background: transparent;
  color: #fff;
  box-shadow: none;
}

/* ===== Footer ===== */
.footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 2.8rem var(--gutter) 3.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--grotesk);
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.footer-tag {
  font-size: 1rem;
  color: var(--ink-70);
  margin: 0;
  max-width: 40ch;
}
.footer-meta {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-45);
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0.4rem 0 0;
}
.footer-meta a {
  color: var(--red-deep);
  text-decoration: none;
}
.footer-meta a:hover {
  text-decoration: underline;
}

/* ===== Reveal on load (snappy, Swiss-restrained) ===== */
.reveal {
  opacity: 0;
  transform: translateY(10px);
  animation: rise 0.55s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  animation-delay: calc(var(--d) * 70ms + 80ms);
}
@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .chyron-track {
    animation: none;
    transform: none;
  }
  .chyron-live .dot {
    animation: none;
  }
  .reveal {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
