/* ============================================================
   THE NATIONAL SATIRER — page layout & section styles
   Load AFTER tokens.css and styles.css.
   Scope: page-level layout, section composition, responsive.
   ============================================================ */

/* ---------- Page shell ---------- */
.ns-page {
  min-height: 100vh;
  background: var(--sat-backdrop);
  background-image: repeating-linear-gradient(45deg,
      var(--sat-backdrop-alt) 0 22px,
      var(--sat-backdrop) 22px 44px);
  padding: 30px 16px;
  box-sizing: border-box;
  font-family: var(--sat-font-body);
  overflow-x: hidden;
}

/* floating background confetti */
.ns-confetti-ring {
  position: fixed;
  top: 8%;
  left: 4%;
  width: 60px;
  height: 60px;
  background: conic-gradient(from 0deg,
      var(--sat-yellow) 0 90deg,
      var(--sat-red)    90deg 180deg,
      var(--sat-cyan)  180deg 270deg,
      var(--sat-purple) 270deg 360deg);
  border-radius: 50%;
  animation: sat-spin 6s linear infinite;
  opacity: .5;
  z-index: 0;
  pointer-events: none;
}
.ns-confetti-star {
  position: fixed;
  bottom: 10%;
  right: 5%;
  width: 44px;
  height: 44px;
  background: var(--sat-yellow);
  clip-path: polygon(50% 0,61% 35%,98% 35%,68% 57%,79% 91%,50% 70%,21% 91%,32% 57%,2% 35%,39% 35%);
  animation: sat-spin 5s linear infinite reverse;
  opacity: .6;
  z-index: 0;
  pointer-events: none;
}

/* canvas sits above confetti */
.ns-canvas {
  position: relative;
  z-index: 1;
}

/* ---------- 1. Breaking-news marquee ---------- */
.ns-marquee {
  background: var(--sat-ink);
  overflow: hidden;
  white-space: nowrap;
  border-bottom: 4px solid var(--sat-red);
}
.ns-marquee-track {
  display: inline-block;
  animation: sat-marquee 22s linear infinite;
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: .1em;
  font-size: 14px;
  padding: 7px 0;
  color: var(--sat-yellow);
}
.ns-marquee-track span { padding: 0 26px; }
.ns-marquee-track .m-cyan   { color: var(--sat-cyan); }
.ns-marquee-track .m-red    { color: var(--sat-red); }
.ns-marquee-track .m-paper  { color: var(--sat-paper); }
.ns-marquee-track .m-purple { color: var(--sat-purple); background: var(--sat-paper); }

/* ---------- 2. Tagline bar ---------- */
.ns-tagline {
  background: var(--sat-red);
  color: var(--sat-paper);
  padding: 5px 0;
  text-align: center;
  font-family: var(--sat-font-ui);
  font-weight: 700;
  letter-spacing: var(--sat-tracking-wide);
  font-size: 12px;
  text-transform: uppercase;
  animation: sat-flash-bg 4s steps(1) infinite;
}

/* ---------- 3. Masthead ---------- */
.ns-masthead {
  padding: 20px 40px 12px;
  border-bottom: var(--sat-border);
  background: radial-gradient(circle at 50% 120%, #ffe60033, transparent 60%);
}
.ns-masthead-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}
.ns-masthead-vol {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-size: 11px;
  line-height: 1.5;
  text-align: left;
  letter-spacing: .05em;
  min-width: 120px;
}
.ns-masthead-vol .chip {
  font-weight: 700;
  color: var(--sat-paper);
  background: var(--sat-purple);
  display: inline-block;
  padding: 2px 7px;
  animation: sat-blink 1.1s steps(1) infinite;
}
.ns-masthead-vol .meta { color: var(--sat-ink); margin-top: 4px; }

.ns-title {
  font-family: var(--sat-font-display);
  font-weight: 400;
  font-size: 88px;
  line-height: .85;
  letter-spacing: var(--sat-tracking-tight);
  margin: 0;
  text-align: center;
  text-transform: uppercase;
  flex: 1;
  color: var(--sat-ink);
  text-shadow: var(--sat-shadow-title);
}

.ns-masthead-price {
  min-width: 120px;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.ns-price {
  font-family: var(--sat-font-display);
  font-size: 34px;
  line-height: 1;
  animation: sat-slide-color 3s linear infinite;
}
.ns-price .cents { font-size: 16px; }
.ns-barcode {
  width: 90px;
  height: 34px;
  background: repeating-linear-gradient(90deg,
      var(--sat-ink) 0 2px, transparent 2px 4px,
      var(--sat-ink) 4px 5px, transparent 5px 9px);
}
.ns-barcode-code {
  font-family: var(--sat-font-ui);
  font-size: 9px;
  letter-spacing: .15em;
  color: var(--sat-ink);
}

/* ---------- 4. Teaser strip ---------- */
.ns-teaser {
  display: flex;
  border-bottom: var(--sat-border);
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
}
.ns-teaser-cell {
  flex: 1;
  padding: 9px 12px;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
}

/* ---------- 5. Lead story ---------- */
.ns-lead {
  padding: 30px 40px 24px;
  border-bottom: var(--sat-border);
  position: relative;
}
.ns-starburst {
  position: absolute;
  top: 14px;
  right: 30px;
  width: 132px;
  height: 132px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--sat-ink);
  font-family: var(--sat-font-display);
  text-transform: uppercase;
  line-height: .9;
  background: conic-gradient(from 0deg,
      var(--sat-yellow) 0 15deg,
      var(--sat-red)    15deg 18deg,
      var(--sat-yellow) 18deg 33deg,
      var(--sat-red)    33deg 36deg);
  clip-path: polygon(50% 0,61% 18%,79% 8%,79% 30%,100% 30%,84% 50%,100% 70%,79% 70%,79% 92%,61% 82%,50% 100%,39% 82%,21% 92%,21% 70%,0 70%,16% 50%,0 30%,21% 30%,21% 8%,39% 18%);
  animation: sat-pulse 1.6s ease-in-out infinite;
}
.ns-starburst span {
  font-size: 26px;
  transform: rotate(-8deg);
  animation: sat-hue 5s linear infinite;
}

.ns-lead-chip {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  letter-spacing: var(--sat-tracking-ui);
  font-weight: 700;
  color: var(--sat-paper);
  background: var(--sat-red);
  display: inline-block;
  padding: 5px 14px;
  font-size: 15px;
  animation: sat-shake 3s ease-in-out infinite;
}

.ns-lead-headline {
  font-family: var(--sat-font-display);
  font-weight: 400;
  text-transform: uppercase;
  font-size: 76px;
  line-height: .86;
  letter-spacing: -.015em;
  margin: 14px 0 6px;
  color: var(--sat-ink);
  max-width: 900px;
}
.ns-lead-headline .cycle {
  display: inline-block;
  animation: sat-slide-color 2.5s linear infinite, sat-wobble 3s ease-in-out infinite;
}

.ns-lead-deck {
  font-family: var(--sat-font-body);
  font-style: italic;
  font-size: 21px;
  line-height: 1.35;
  margin: 0 0 20px;
  color: var(--sat-ink-soft);
  max-width: 820px;
}
.ns-lead-deck strong {
  background: var(--sat-yellow);
  padding: 0 4px;
}

.ns-lead-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 24px;
  align-items: start;
}

/* photo placeholder + decorations */
.ns-photo {
  position: relative;
  aspect-ratio: 4/3;
  background: repeating-linear-gradient(45deg,
      var(--sat-photo-a) 0 12px,
      var(--sat-photo-b) 12px 24px);
  border: var(--sat-border);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: sat-flashborder 1.4s ease-in-out infinite;
}
.ns-photo--beard { aspect-ratio: 3/4; animation: sat-wobble 4s ease-in-out infinite; }

/* real <img> dropped into a photo placeholder: covers the hatch, decorations stay on top */
.ns-photo-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.ns-photo-label {
  font-family: var(--sat-font-ui);
  font-size: 13px;
  letter-spacing: .1em;
  color: var(--sat-caption);
  text-transform: uppercase;
  text-align: center;
}
.ns-photo-label small { font-size: 11px; display: block; }
.ns-photo--beard .ns-photo-label { font-size: 11px; }
.ns-photo--beard .ns-photo-label small { font-size: 10px; }

.ns-shame {
  position: absolute;
  width: 46%;
  height: 60%;
  border: 5px solid var(--sat-red);
  border-radius: 50%;
  top: 20%;
  left: 12%;
  transform: rotate(-6deg);
  animation: sat-pulse 1.3s ease-in-out infinite;
}
.ns-evidence {
  position: absolute;
  top: 12%;
  left: 60%;
  font-family: var(--sat-font-ui);
  color: var(--sat-purple);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 15px;
  transform: rotate(-4deg);
  animation: sat-bounce 1s ease-in-out infinite;
}
.ns-tape {
  position: absolute;
  top: -14px;
  left: 20px;
  background: var(--sat-yellow);
  color: var(--sat-ink);
  font-family: var(--sat-font-ui);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  padding: 3px 10px;
  transform: rotate(-4deg);
  animation: sat-tape 2s ease-in-out infinite;
}
.ns-caption {
  font-family: var(--sat-font-ui);
  font-size: 12px;
  text-transform: uppercase;
  color: var(--sat-caption);
  padding: 6px 2px;
  letter-spacing: .05em;
}

.ns-lead-body {
  font-family: var(--sat-font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--sat-ink);
}
.ns-lead-body p { margin: 0 0 12px; }
.ns-lead-body p:last-child { margin: 0; }
.ns-dropcap {
  font-family: var(--sat-font-display);
  font-size: 46px;
  float: left;
  line-height: .72;
  margin: 4px 8px 0 0;
  animation: sat-slide-color 3s linear infinite;
}

/* ---------- 6. Three-column spread ---------- */
.ns-spread {
  display: grid;
  grid-template-columns: 250px 1fr 290px;
  border-bottom: var(--sat-border);
}

/* shared section bar */
.ns-bar {
  background: var(--sat-ink);
  color: var(--sat-yellow);
  font-family: var(--sat-font-display);
  text-transform: uppercase;
  text-align: center;
  padding: 8px;
  animation: sat-hue 6s linear infinite;
}
.ns-bar--hot   { font-size: 26px; letter-spacing: .02em; }
.ns-bar--stars { font-size: 24px; margin-bottom: 12px; animation-duration: 7s; }

/* LEFT: hot sheet */
.ns-hot {
  border-right: var(--sat-border-col);
  padding: 20px 20px 24px;
  background: var(--sat-cyan);
}
.ns-hot-sub {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  text-align: center;
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--sat-ink);
  font-weight: 700;
  margin: 6px 0 14px;
}
.ns-hot-item {
  border-bottom: var(--sat-border-dash);
  padding-bottom: 12px;
  margin-bottom: 12px;
}
.ns-hot-item:last-child { border-bottom: 0; margin-bottom: 0; }
.ns-hot-kicker {
  font-family: var(--sat-font-ui);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: .08em;
}
.ns-hot-kicker--purple { color: var(--sat-purple); }
.ns-hot-kicker--red    { color: var(--sat-red); }
.ns-hot-kicker--blink  { animation: sat-blink 1.6s steps(1) infinite; }
.ns-hot-item p {
  margin: 3px 0 0;
  font-size: 14px;
  line-height: 1.4;
  color: var(--sat-ink);
}

/* CENTER: beard story + bakery box */
.ns-center {
  border-right: var(--sat-border-col);
  padding: 22px 26px;
  background: var(--sat-paper);
}
.ns-chip-ink {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  letter-spacing: var(--sat-tracking-ui);
  font-weight: 700;
  color: var(--sat-yellow);
  background: var(--sat-ink);
  display: inline-block;
  padding: 4px 12px;
  font-size: 12px;
}
.ns-beard-head {
  font-family: var(--sat-font-display);
  font-weight: 400;
  text-transform: uppercase;
  font-size: 45px;
  line-height: .9;
  letter-spacing: -.01em;
  margin: 10px 0 8px;
  color: var(--sat-ink);
}
.ns-beard-head .cycle {
  display: inline-block;
  animation: sat-slide-color 2.2s linear infinite;
}
.ns-beard-deck {
  font-family: var(--sat-font-body);
  font-style: italic;
  font-size: 18px;
  margin: 0 0 14px;
  color: var(--sat-ink-soft);
}
.ns-beard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: start;
  margin-bottom: 6px;
}
.ns-beard-body {
  font-family: var(--sat-font-body);
  font-size: 15px;
  line-height: 1.55;
  color: var(--sat-ink);
}
.ns-beard-body p { margin: 0 0 10px; }
.ns-beard-body p:last-child { margin: 0; }

/* bakery box */
.ns-bakery {
  border: 4px solid var(--sat-red);
  margin-top: 18px;
  padding: 16px 18px;
  background: var(--sat-paper-pure);
  position: relative;
  animation: sat-flashborder 1.8s ease-in-out infinite;
}
.ns-bakery-tab {
  position: absolute;
  top: -14px;
  left: 16px;
  background: var(--sat-red);
  color: var(--sat-paper);
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .1em;
  padding: 3px 12px;
  animation: sat-bounce 1.4s ease-in-out infinite;
}
.ns-bakery-head {
  font-family: var(--sat-font-display);
  font-weight: 400;
  text-transform: uppercase;
  font-size: 34px;
  line-height: .9;
  margin: 8px 0 6px;
  color: var(--sat-ink);
}
.ns-bakery-head .cycle {
  display: inline-block;
  animation: sat-slide-color 2.6s linear infinite;
}
.ns-bakery-body {
  font-family: var(--sat-font-body);
  font-size: 15px;
  line-height: 1.5;
  margin: 0 0 8px;
  color: var(--sat-ink);
}
.ns-bakery-link {
  font-family: var(--sat-font-ui);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: .06em;
}

/* RIGHT: ad + horoscopes */
.ns-right {
  padding: 20px 20px 24px;
  background: var(--sat-purple);
}

/* miracle ad */
.ns-ad {
  border: 4px double var(--sat-ink);
  padding: 14px;
  text-align: center;
  background: var(--sat-yellow);
  margin-bottom: 20px;
  animation: sat-wobble 5s ease-in-out infinite;
}
.ns-ad-tag {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: .15em;
  color: var(--sat-red);
  animation: sat-blink 1s steps(1) infinite;
}
.ns-ad-head {
  font-family: var(--sat-font-display);
  text-transform: uppercase;
  font-size: 30px;
  line-height: .9;
  color: var(--sat-ink);
  margin: 6px 0;
}
.ns-ad-sub {
  font-family: var(--sat-font-body);
  font-style: italic;
  font-size: 13px;
  line-height: 1.4;
  margin: 4px 0 8px;
  color: var(--sat-ink);
}
.ns-ad-disclaimer {
  background: var(--sat-red);
  color: var(--sat-paper);
  font-family: var(--sat-font-ui);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 14px;
  padding: 8px;
  letter-spacing: .05em;
  animation: sat-flash-bg 3s steps(1) infinite;
}

/* horoscopes */
.ns-horoscopes {
  font-family: var(--sat-font-body);
  font-size: 13px;
  line-height: 1.45;
  color: var(--sat-paper);
}
.ns-horoscopes p { margin: 0 0 10px; }
.ns-horoscopes p:last-child { margin: 0; }
.ns-horoscopes strong {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
}
.ns-h-zod-yellow { color: var(--sat-yellow); }
.ns-h-zod-cyan   { color: var(--sat-cyan); }

/* ---------- 7. Poll + reader mail ---------- */
.ns-bottom {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: var(--sat-border);
}

/* poll */
.ns-poll {
  border-right: var(--sat-border-col);
  padding: 22px 26px;
  background: var(--sat-yellow);
}
.ns-poll-kicker {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--sat-red);
  font-size: 13px;
  animation: sat-blink 1.3s steps(1) infinite;
}
.ns-poll-head {
  font-family: var(--sat-font-display);
  font-weight: 400;
  text-transform: uppercase;
  font-size: 35px;
  line-height: .9;
  margin: 6px 0 16px;
  color: var(--sat-ink);
}
.ns-poll-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ns-vote-btn {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .05em;
  padding: 14px;
  border: var(--sat-border);
  background: var(--sat-paper);
  color: var(--sat-ink);
  cursor: pointer;
  transition: transform .1s, background .1s, color .1s;
}
.ns-vote-btn:hover {
  background: var(--sat-red);
  color: var(--sat-paper);
  transform: scale(1.04) rotate(-1deg);
}
.ns-vote-btn--father:hover {
  background: var(--sat-purple);
  transform: scale(1.04) rotate(1deg);
}
.ns-poll-results { display: flex; flex-direction: column; gap: 14px; }
.ns-result-row { display: block; }
.ns-result-head {
  display: flex;
  justify-content: space-between;
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 4px;
  color: var(--sat-ink);
}
.ns-result-track {
  height: 24px;
  background: var(--sat-paper);
  border: 3px solid var(--sat-ink);
}
.ns-result-fill {
  height: 100%;
  background: var(--sat-red);
}
.ns-result-fill--dad    { width: 71%; animation: sat-hue 4s linear infinite; }
.ns-result-fill--father { width: 29%; background: var(--sat-purple); }
.ns-poll-disclaimer {
  font-family: var(--sat-font-body);
  font-style: italic;
  font-size: 13px;
  color: var(--sat-caption);
  margin: 2px 0 0;
}

/* reader mail */
.ns-mail {
  padding: 22px 26px;
  background: var(--sat-green);
}
.ns-mail-head {
  font-family: var(--sat-font-display);
  text-transform: uppercase;
  font-size: 30px;
  color: var(--sat-paper);
  margin-bottom: 4px;
}
.ns-mail-sub {
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: .15em;
  color: var(--sat-yellow);
  font-weight: 700;
  margin-bottom: 14px;
}
.ns-mail-body {
  font-family: var(--sat-font-body);
  font-size: 14px;
  line-height: 1.5;
  color: var(--sat-paper);
}
.ns-mail-body p { margin: 0 0 12px; }
.ns-mail-body p:last-child { margin: 0; }
.ns-mail-body em { color: #d7f5ec; }

/* ---------- 8. Footer ---------- */
.ns-footer {
  padding: 16px 40px 26px;
  text-align: center;
  font-family: var(--sat-font-ui);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--sat-caption);
  line-height: 1.7;
  background: var(--sat-paper);
}

/* ============================================================
   Responsive — collapse grids and shrink display type on mobile
   ============================================================ */
@media (max-width: 900px) {
  .ns-spread   { grid-template-columns: 1fr; }
  .ns-bottom   { grid-template-columns: 1fr; }
  .ns-hot,
  .ns-center   { border-right: 0; border-bottom: var(--sat-border); }
  .ns-poll     { border-right: 0; border-bottom: var(--sat-border); }
  .ns-lead-grid     { grid-template-columns: 1fr; }
  .ns-beard-grid    { grid-template-columns: 1fr; }
  .ns-starburst     { width: 96px; height: 96px; }
  .ns-starburst span { font-size: 18px; }
}

@media (max-width: 600px) {
  .ns-page { padding: 12px 6px; }
  .ns-title        { font-size: 48px; }
  .ns-lead-headline { font-size: 40px; }
  .ns-beard-head   { font-size: 34px; }
  .ns-bakery-head  { font-size: 26px; }
  .ns-lead         { padding: 22px 18px 18px; }
  .ns-masthead     { padding: 16px 18px 10px; }
  .ns-center,
  .ns-hot,
  .ns-right,
  .ns-poll,
  .ns-mail         { padding: 18px 18px 20px; }
  .ns-footer       { padding: 14px 18px 22px; }
  /* stack masthead columns */
  .ns-masthead-row { flex-direction: column; align-items: center; text-align: center; }
  .ns-masthead-vol,
  .ns-masthead-price { min-width: 0; text-align: center; align-items: center; }
  .ns-masthead-vol   { display: flex; flex-direction: column; align-items: center; }
  /* keep teaser strip legible */
  .ns-teaser-cell  { font-size: 11px; padding: 9px 6px; }
}
