/*
Theme Name: The Verticals
Theme URI: https://thefifth.us
Author: The Fifth Consulting
Author URI: https://thefifth.us
Description: Editorial theme for The Verticals Magazine, an international trade publication covering vertical-format storytelling (Series, Social, Ads) and the Verticals Awards. Built to be run and edited entirely from wp-admin: posts and categories drive every section, and the masthead ticker, hero, and data band are wired to real content.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: verticals
*/

/* ==========================================================
   DESIGN TOKENS
   ========================================================== */
:root {
  --ink: #14141c;
  --ink-soft: #1c1c26;
  --ink-line: rgba(242, 241, 234, 0.14);
  --paper: #ECEAE0;
  --paper-card: #FAFAF6;
  --paper-line: rgba(20, 20, 28, 0.12);
  --ink-text: #14141c;
  --muted: #6f6d63;
  --muted-on-ink: #9d9c9a;
  --magenta: #FF2A6D;
  --cyan: #1FCFC0;
  --amber: #FFB238;
  --accent: var(--magenta);
  /* sane fallback when a post/category isn't Series, Social or Ads */
  --display: "Big Shoulders Display", sans-serif;
  --serif: "Newsreader", serif;
  --mono: "IBM Plex Mono", monospace;
}

/* ==========================================================
   GLOBAL RESETS
   ========================================================== */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink-text);
  font-family: var(--serif);
  -webkit-font-smoothing: antialiased;
}

img, svg {
  display: block;
  max-width: 100%;
}

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

.wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- utility ticker ---------- */
.ticker-bar {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  overflow: hidden;
  border-bottom: 1px solid var(--ink-line);
}

.ticker-row {
  display: flex;
  align-items: center;
  height: 36px;
}

.ticker-tag {
  flex: 0 0 auto;
  background: var(--magenta);
  color: var(--ink);
  font-weight: 600;
  padding: 0 12px;
  height: 100%;
  display: flex;
  align-items: center;
  letter-spacing: 0.08em;
}

.ticker-track-mask {
  overflow: hidden;
  flex: 1;
}

.ticker-track {
  display: flex;
  white-space: nowrap;
  width: max-content;
  animation: scroll-left 34s linear infinite;
  padding-left: 16px;
}

.ticker-track span {
  margin-right: 48px;
  color: var(--muted-on-ink);
}

.ticker-track span b {
  color: var(--paper);
  font-weight: 500;
}

@keyframes scroll-left {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ticker-track {
    animation: none;
  }
}

/* ---------- masthead ---------- */
.masthead {
  background: var(--paper);
  padding: 30px 0 0;
  border-bottom: 1px solid var(--paper-line);
}

.masthead-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding-bottom: 18px;
  flex-wrap: wrap;
  gap: 14px;
}

.masthead-edition {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  text-transform: uppercase;
}

.wordmark {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  line-height: 0.78;
  letter-spacing: -0.01em;
  font-size: clamp(48px, 8vw, 108px);
  margin: 6px 0 0;
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
}

.wordmark .full {
  color: var(--ink-text);
  transition: text-shadow .25s ease;
}

.wordmark:hover .full {
  text-shadow: 2px 0 0 var(--magenta), -2px 0 0 var(--cyan);
}

.wordmark .sub {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(14px, 1.6vw, 20px);
  color: var(--muted);
  letter-spacing: 0;
}

.masthead-tagline {
  max-width: 320px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--muted);
  text-align: right;
  line-height: 1.4;
}

.masthead-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--paper-line);
  padding: 12px 0;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
}

.nav-links a {
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
  transition: border-color .15s ease, color .15s ease;
}

.nav-links a:hover {
  border-color: var(--ink-text);
}

.nav-links a.tag-series:hover {
  border-color: var(--magenta);
  color: var(--magenta);
}

.nav-links a.tag-social:hover {
  border-color: var(--cyan);
  color: #0e9f92;
}

.nav-links a.tag-ads:hover {
  border-color: var(--amber);
  color: #9c6c00;
}

.nav-links a.active {
  border-color: var(--accent, var(--ink-text));
  color: var(--accent, var(--ink-text));
  font-weight: 600;
}

.nav-search {
  color: var(--muted);
}

/* ---------- section labels ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}

.dot-series {
  background: var(--magenta);
}

.dot-social {
  background: var(--cyan);
}

.dot-ads {
  background: var(--amber);
}

.dot-accent {
  background: var(--accent);
}

/* ---------- hero (home + category featured) ---------- */
.hero {
  padding: 44px 0 56px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 40px;
  align-items: start;
}

.lead-frame {
  aspect-ratio: 9/16;
  max-height: 560px;
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(155deg, #1a1a24 0%, #262638 46%, #14141c 100%);
  isolation: isolate;
}

.lead-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 42, 109, 0.35), transparent 45%),
    radial-gradient(circle at 75% 80%, rgba(31, 207, 192, 0.30), transparent 50%);
  mix-blend-mode: screen;
}

.lead-frame .frame-chrome {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px;
}

.frame-top {
  display: flex;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 11px;
  color: rgba(242, 241, 234, 0.75);
}

.frame-top .rec {
  display: flex;
  align-items: center;
  gap: 6px;
}

.frame-top .rec .dot {
  background: var(--magenta);
}

.frame-bottom .frame-cat {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--paper);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(20, 20, 28, 0.55);
  display: inline-block;
  padding: 4px 8px;
  margin-bottom: 10px;
}

.frame-headline {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  color: var(--paper);
  font-size: clamp(22px, 2.6vw, 32px);
  line-height: 0.92;
}

.lead-copy {
  padding-top: 2px;
  min-width: 700px;
}

.lead-copy .eyebrow {
  color: var(--magenta);
  margin-bottom: 14px;
}

.lead-headline {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(30px, 3.6vw, 46px);
  line-height: 0.94;
  margin: 0 0 16px;
  letter-spacing: -0.01em;
}

.lead-dek {
  font-size: 18px;
  line-height: 1.55;
  color: #3a392f;
  max-width: 46ch;
  margin: 0 0 18px;
}

.lead-byline {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-top: 1px solid var(--paper-line);
  padding-top: 12px;
}

/* latest / related rail */
.latest-rail-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 14px;
}

.latest-rail-head h3 {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0;
  color: var(--muted);
}

.rail {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: thin;
}

.rail-card {
  flex: 0 0 128px;
  aspect-ratio: 9/16;
  min-height: 227px;
  background: var(--ink);
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.rail-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.85) 100%);
}

.rail-card .rc-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  padding: 3px 6px;
  text-transform: uppercase;
  color: var(--ink);
}

.rc-series {
  background: var(--magenta);
  color: var(--ink);
}

.rc-social {
  background: var(--cyan);
  color: var(--ink);
}

.rc-ads {
  background: var(--amber);
  color: var(--ink);
}

.rail-card .rc-time {
  position: absolute;
  bottom: 8px;
  right: 8px;
  z-index: 2;
  font-family: var(--mono);
  font-size: 9px;
  color: rgba(242, 241, 234, 0.7);
}

.rail-card .rc-title {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 26px;
  z-index: 2;
  font-family: var(--display);
  font-weight: 700;
  color: var(--paper);
  font-size: 13px;
  line-height: 1.05;
  text-transform: uppercase;
}

.rail-card:hover .rc-title {
  color: var(--cyan);
}

/* ---------- three desks (home) ---------- */
.desks {
  background: var(--paper-card);
  border-top: 1px solid var(--paper-line);
  border-bottom: 1px solid var(--paper-line);
  padding: 56px 0 60px;
}

.desks-head {
  margin-bottom: 38px;
}

.desks-head .eyebrow {
  color: var(--muted);
  margin-bottom: 10px;
}

.desks-head h2 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(28px, 3.4vw, 40px);
  margin: 0;
  letter-spacing: -0.01em;
}

.desks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.desk {
  padding: 0 26px;
  border-left: 1px solid var(--paper-line);
}

.desk:first-child {
  border-left: none;
  padding-left: 0;
}

.desk:last-child {
  padding-right: 0;
}

.desk-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--ink-text);
}

.desk-head h3 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 22px;
  margin: 0;
  letter-spacing: 0.01em;
}

.desk.series .desk-head {
  border-bottom-color: var(--magenta);
}

.desk.social .desk-head {
  border-bottom-color: var(--cyan);
}

.desk.ads .desk-head {
  border-bottom-color: var(--amber);
}

.story {
  padding: 16px 0;
  border-bottom: 1px solid var(--paper-line);
}

.story:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.story:first-child {
  padding-top: 0;
}

.story h4 {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 17px;
  line-height: 1.12;
  margin: 0 0 8px;
  letter-spacing: 0;
}

.story a:hover h4 {
  color: var(--muted);
}

.story p {
  font-size: 14.5px;
  line-height: 1.5;
  color: #4a4938;
  margin: 0 0 8px;
}

.story .meta {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ---------- data band (home) ---------- */
.data-band {
  background: var(--ink);
  color: var(--paper);
  padding: 64px 0;
}

.data-band .eyebrow {
  color: var(--muted-on-ink);
  margin-bottom: 8px;
}

.data-band h2 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(24px, 2.8vw, 32px);
  margin: 0 0 40px;
  max-width: 20ch;
  line-height: 1.05;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.stat {
  border-top: 1px solid var(--ink-line);
  padding-top: 18px;
}

.stat .num {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(40px, 5.4vw, 64px);
  line-height: 0.9;
  margin: 0 0 10px;
}

.stat:nth-child(1) .num {
  color: var(--magenta);
}

.stat:nth-child(2) .num {
  color: var(--cyan);
}

.stat:nth-child(3) .num {
  color: var(--amber);
}

.stat p {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted-on-ink);
  line-height: 1.5;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

/* ---------- awards teaser (home) ---------- */
.awards {
  background: var(--paper);
  padding: 70px 0;
  border-bottom: 1px solid var(--paper-line);
}

.awards-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  border-top: 1px solid var(--ink-text);
  border-bottom: 1px solid var(--ink-text);
  padding: 34px 0;
}

.awards-mark {
  font-family: var(--display);
  font-weight: 900;
  text-transform: uppercase;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 0.88;
  letter-spacing: -0.01em;
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.awards-mark em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(14px, 1.6vw, 18px);
  color: var(--muted);
}

.awards-copy {
  max-width: 34ch;
  font-size: 15px;
  color: #4a4938;
  line-height: 1.55;
}

.awards-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.btn {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--ink);
  color: var(--paper);
  padding: 13px 22px;
  border: 1px solid var(--ink);
  display: inline-block;
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}

.btn:hover {
  background: transparent;
  color: var(--ink-text);
}

.awards-status {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

/* ---------- newsletter ---------- */
.newsletter {
  padding: 52px 0;
}

.newsletter-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.newsletter-copy h3 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 24px;
  margin: 0 0 6px;
}

.newsletter-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  max-width: 42ch;
}

.newsletter-form {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
  min-width: 320px;
  flex: 1;
  max-width: 440px;
}

.newsletter-form input {
  flex: 1;
  font-family: var(--mono);
  font-size: 13px;
  padding: 13px 14px;
  border: 1px solid var(--ink-text);
  border-right: none;
  background: var(--paper-card);
  color: var(--ink-text);
  min-width: 180px;
}

.newsletter-form input:focus {
  outline: 2px solid var(--cyan);
  outline-offset: -2px;
}

.newsletter-form button {
  border: 1px solid var(--ink-text);
}

/* ---------- footer ---------- */
footer {
  background: var(--ink);
  color: var(--paper);
  padding: 56px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 32px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--ink-line);
}

.footer-brand .wordmark {
  font-size: 34px;
  gap: 8px;
}

.footer-brand .wordmark .full {
  color: var(--paper);
}

.footer-brand .wordmark:hover .full {
  text-shadow: 2px 0 0 var(--magenta), -2px 0 0 var(--cyan);
}

.footer-brand p {
  font-size: 13px;
  color: var(--muted-on-ink);
  max-width: 32ch;
  line-height: 1.5;
  margin-top: 10px;
}

.footer-col h5 {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-on-ink);
  margin: 0 0 14px;
}

.footer-col a {
  display: block;
  font-size: 13.5px;
  padding: 6px 0;
  color: var(--paper);
  border-bottom: 1px solid transparent;
}

.footer-col a:hover {
  color: var(--cyan);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  flex-wrap: wrap;
  gap: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted-on-ink);
  letter-spacing: 0.04em;
}

/* ==========================================================
   ARTICLE PAGE
   ========================================================== */
.article-top {
  padding: 44px 0 0;
  max-width: 760px;
  margin: 0 auto;
}

.article-eyebrow {
  color: var(--accent);
  margin-bottom: 16px;
}

.article-headline {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 0.96;
  margin: 0 0 20px;
  letter-spacing: -0.01em;
}

.article-dek {
  font-size: 19px;
  line-height: 1.55;
  color: #3a392f;
  margin: 0 0 24px;
  font-style: italic;
  font-family: var(--serif);
  max-width: 60ch;
}

.article-meta-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 16px 0;
  border-top: 1px solid var(--paper-line);
  border-bottom: 1px solid var(--paper-line);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
}

.article-meta-bar .share-links a {
  margin-left: 14px;
  color: var(--muted);
}

.article-meta-bar .share-links a:hover {
  color: var(--ink-text);
}

.article-hero-wrap {
  max-width: 400px;
  margin: 40px auto 8px;
}

.article-hero-frame {
  aspect-ratio: 9/16;
  max-height: 620px;
}

.frame-caption {
  max-width: 400px;
  margin: 10px auto 0;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-align: center;
}

.article-body-wrap {
  max-width: 680px;
  margin: 44px auto 0;
  padding: 0 28px;
}

.article-body p {
  font-size: 18px;
  line-height: 1.72;
  color: #26251d;
  margin: 0 0 24px;
}

.article-body p.lead-para {
  font-size: 21px;
  line-height: 1.6;
}

.article-body h2 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 28px;
  margin: 44px 0 18px;
  letter-spacing: -0.005em;
}

.pullquote {
  margin: 36px 0;
  padding: 2px 0 2px 22px;
  border-left: 3px solid var(--magenta);
}

.pullquote p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 24px;
  line-height: 1.45;
  color: var(--ink-text);
  margin: 0 0 10px;
  text-shadow: 1px 0 0 rgba(255, 42, 109, .35), -1px 0 0 rgba(31, 207, 192, .35);
}

.pullquote cite {
  font-family: var(--mono);
  font-size: 11px;
  font-style: normal;
  color: var(--muted);
  text-transform: uppercase;
}

.related-insert {
  margin: 40px 0;
  padding: 24px;
  background: var(--paper-card);
  border: 1px solid var(--paper-line);
}

.related-insert>.eyebrow {
  margin-bottom: 16px;
  color: var(--muted);
}

.related-cards {
  display: flex;
  gap: 14px;
}

.related-cards .rail-card {
  flex: 0 0 100px;
}

.related-cards .rc-title {
  font-size: 11.5px;
}

.article-tags {
  max-width: 680px;
  margin: 0 auto;
  padding: 24px 28px 0;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.tag-pill {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 6px 12px;
  border: 1px solid var(--paper-line);
  color: var(--muted);
}

.author-block {
  max-width: 680px;
  margin: 32px auto 0;
  padding: 24px 28px;
  border-top: 1px solid var(--paper-line);
  display: flex;
  gap: 16px;
  align-items: center;
}

.author-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ink);
  flex: 0 0 44px;
}

.author-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  text-transform: uppercase;
}

.author-role {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
}

.more-from-desk {
  background: var(--paper-card);
  border-top: 1px solid var(--paper-line);
  padding: 56px 0;
  margin-top: 48px;
}

.more-from-desk .desks-head {
  margin-bottom: 28px;
}

.more-from-desk .desk {
  border-left: none;
  padding: 0;
  max-width: 680px;
  margin: 0 auto;
}

.more-from-desk .desk-head {
  border-bottom-color: var(--accent);
}

/* ==========================================================
   CATEGORY PAGE
   ========================================================== */
.category-hero {
  padding: 50px 0 30px;
  border-bottom: 1px solid var(--paper-line);
}

.category-title {
  font-family: var(--display);
  font-weight: 900;
  text-transform: uppercase;
  font-size: clamp(46px, 7vw, 86px);
  line-height: 0.85;
  margin: 12px 0 18px;
  letter-spacing: -0.01em;
  padding-bottom: 14px;
  border-bottom: 6px solid var(--accent);
  display: inline-block;
}

.category-desc {
  font-size: 16px;
  line-height: 1.55;
  color: #3a392f;
  max-width: 60ch;
  margin: 0 0 10px;
}

.category-meta {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .05em;
}

.category-featured {
  padding: 44px 0 12px;
}

.featured-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 40px;
  align-items: center;
}

.featured-grid .lead-copy .eyebrow {
  color: var(--accent);
}

.filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 28px 0 8px;
}

.filter-pill {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 8px 14px;
  border: 1px solid var(--paper-line);
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  transition: all .15s ease;
}

.filter-pill:hover {
  border-color: var(--ink-text);
  color: var(--ink-text);
}

.filter-pill.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--ink);
}

.category-grid-section {
  padding: 24px 0 56px;
}

.category-grid {
  max-width: 820px;
}

.grid-story {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 22px 0;
  border-bottom: 1px solid var(--paper-line);
}

.grid-story:first-child {
  padding-top: 0;
}

.grid-thumb {
  flex: 0 0 92px;
  aspect-ratio: 9/16;
  background: var(--ink);
  position: relative;
  overflow: hidden;
}

.grid-thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0, 0, 0, .8) 100%);
}

.grid-thumb .gt-tag {
  position: absolute;
  top: 6px;
  left: 6px;
  font-family: var(--mono);
  font-size: 8px;
  padding: 2px 5px;
  text-transform: uppercase;
  background: var(--accent);
  color: var(--ink);
}

.grid-content {
  flex: 1;
}

.grid-content h4 {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 19px;
  line-height: 1.15;
  margin: 0 0 8px;
}

.grid-story:hover .grid-content h4 {
  color: var(--muted);
}

.grid-content p {
  font-size: 14.5px;
  color: #4a4938;
  line-height: 1.5;
  margin: 0 0 8px;
  max-width: 60ch;
}

.grid-content .meta {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .05em;
}

.load-more-wrap {
  text-align: center;
  padding-top: 36px;
}

/* inline-style replacements */
.rail-spacer { height: 36px; }
.view-all-link { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.empty-state { font-family: var(--mono); color: var(--muted); padding: 40px 0; font-size: 12px; }
.unstyled-link { border: none; text-decoration: none; color: inherit; display: block; }
.page-no-bottom-pad { padding-bottom: 0; }
.ticker-row-flush { padding: 0; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .lead-frame {
    max-height: 420px;
  }

  .desks-grid {
    grid-template-columns: 1fr;
  }

  .desk {
    border-left: none;
    padding: 28px 0 0;
    border-top: 1px solid var(--paper-line);
  }

  .desk:first-child {
    border-top: none;
    padding-top: 0;
  }

  .stat-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }

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

  .masthead-tagline {
    text-align: left;
    max-width: 100%;
  }

  .featured-grid {
    grid-template-columns: 1fr;
  }

  /* article page */
  .article-hero-wrap {
    max-width: 100%;
    padding: 0 28px;
  }

  .related-cards {
    flex-wrap: wrap;
  }

  .related-cards .rail-card {
    flex: 0 0 calc(50% - 7px);
  }

  .more-from-desk .desk {
    max-width: 100%;
  }

  /* category page */
  .category-grid {
    max-width: 100%;
  }
}

@media (max-width: 560px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .awards-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .newsletter-form {
    max-width: 100%;
  }

  .grid-story {
    flex-direction: column;
  }

  .grid-thumb {
    width: 120px;
  }

  /* article page */
  .article-top {
    padding: 28px 0 0;
  }

  .article-headline {
    font-size: clamp(26px, 8vw, 40px);
  }

  .article-dek {
    font-size: 16px;
  }

  .article-body-wrap {
    padding: 0 16px;
  }

  .article-body p {
    font-size: 16px;
  }

  .article-hero-wrap {
    padding: 0 16px;
  }

  .article-meta-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  .article-meta-bar .share-links {
    margin-top: 8px;
  }

  .article-meta-bar .share-links a {
    margin-left: 0;
    margin-right: 14px;
  }

  .related-cards {
    flex-direction: column;
  }

  .related-cards .rail-card {
    flex: 0 0 140px;
    width: 140px;
  }

  .author-block {
    flex-direction: column;
    text-align: center;
  }

  .more-from-desk .desk {
    padding: 0;
  }

  /* category page */
  .category-hero {
    padding: 32px 0 20px;
  }

  .category-title {
    font-size: clamp(32px, 10vw, 56px);
  }

  .category-featured {
    padding: 28px 0 12px;
  }

  .filter-row {
    padding: 16px 0 8px;
  }

  .filter-pill {
    padding: 6px 10px;
    font-size: 10.5px;
  }

  .category-grid-section {
    padding: 16px 0 36px;
  }

  /* masthead */
  .masthead-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .masthead-nav {
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
  }

  .nav-links {
    gap: 16px;
  }

  /* ticker */
  .ticker-tag {
    padding: 0 8px;
    font-size: 10px;
  }

  /* newsletter */
  .newsletter-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .newsletter-copy p {
    max-width: 100%;
  }

  /* data band */
  .data-band {
    padding: 40px 0;
  }

  .data-band h2 {
    max-width: 100%;
  }

  /* awards */
  .awards {
    padding: 40px 0;
  }
}

:focus-visible {
  outline: 2px solid var(--magenta);
  outline-offset: 2px;
}


/* ==========================================================
   WORDPRESS-SPECIFIC ADDITIONS
   ========================================================== */

/* native Gutenberg Quote block inside article body -> same signature pullquote look */
.article-body blockquote {
  margin: 36px 0;
  padding: 2px 0 2px 22px;
  border-left: 3px solid var(--magenta);
}

.article-body blockquote p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 24px;
  line-height: 1.45;
  color: var(--ink-text);
  margin: 0 0 10px;
  text-shadow: 1px 0 0 rgba(255, 42, 109, .35), -1px 0 0 rgba(31, 207, 192, .35);
}

.article-body blockquote cite {
  font-family: var(--mono);
  font-size: 11px;
  font-style: normal;
  color: var(--muted);
  text-transform: uppercase;
}

.article-body figure {
  margin: 36px 0;
}

.article-body img {
  width: 100%;
  height: auto;
}

.article-body figcaption {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  margin-top: 8px;
}

.article-body ul,
.article-body ol {
  font-size: 18px;
  line-height: 1.7;
  color: #26251d;
  padding-left: 22px;
  margin: 0 0 24px;
}

.article-body a {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--paper-line);
}

.article-body a:hover {
  text-decoration-color: var(--accent);
}

/* tags rendered via the_tags() */
.article-tags a {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 6px 12px;
  border: 1px solid var(--paper-line);
  color: var(--muted);
  display: inline-block;
}

.article-tags a:hover {
  border-color: var(--accent);
  color: var(--ink-text);
}

/* filter pills as real links (category.php) */
a.filter-pill {
  display: inline-block;
}

/* category term description can contain basic markup */
.category-desc p {
  margin: 0 0 10px;
}

/* WordPress core pagination, styled to match the masthead system */
.pagination {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  padding-top: 36px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.pagination .page-numbers {
  padding: 9px 14px;
  border: 1px solid var(--paper-line);
  color: var(--muted);
}

.pagination .page-numbers.current {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

.pagination .page-numbers:hover {
  border-color: var(--ink-text);
  color: var(--ink-text);
}

/* rail-card built from a real featured image */
.rail-card img,
.grid-thumb img,
.lead-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* generic entry content on page.php (About, Awards, etc.) */
.entry-content {
  max-width: 680px;
  margin: 44px auto 0;
  padding: 0 28px;
}

.entry-content p {
  font-size: 18px;
  line-height: 1.72;
  color: #26251d;
  margin: 0 0 24px;
}

.entry-content h2 {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  font-size: 28px;
  margin: 44px 0 18px;
}

/* skip link for keyboard users */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 12px 18px;
  font-family: var(--mono);
  font-size: 12px;
  z-index: 999;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
}
