/*
Theme Name: Words Into Waves
Author: Shane
Description: Cinematic literary WordPress theme.
Version: 2.1.6
*/

/* ═══════════════════════════════════════
   TOKENS
═══════════════════════════════════════ */
:root {
  --bg:        #07090e;
  --bg2:       #0f1219;
  --text:      #eef0f4;
  --muted:     #8a95a3;
  --muted2:    #5a6472;
  --cyan:      #4fd1ff;
  --cyan-dim:  rgba(79,209,255,.15);
  --violet:    #7c5cff;
  --violet-dim:rgba(124,92,255,.15);
  --glass:     rgba(255,255,255,.04);
  --glass2:    rgba(255,255,255,.08);
  --border:    rgba(255,255,255,.07);
  --border2:   rgba(255,255,255,.13);
  --max:       1200px;
  --radius:    18px;
  --radius-sm: 10px;
  --shadow:    0 24px 60px rgba(0,0,0,.55);
  --shadow-sm: 0 8px 24px rgba(0,0,0,.35);
  --header-h:  68px;
  --font-body: 'DM Sans', sans-serif;
  --font-disp: 'Cormorant Garamond', serif;
  --ease:      cubic-bezier(.25,.46,.45,.94);
}

/* ═══════════════════════════════════════
   RESET & BASE
═══════════════════════════════════════ */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }

html { scroll-behavior:smooth; font-size:16px; }

body {
  font-family: var(--font-body);
  font-weight: 400;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  line-height: 1.7;
}

/* Grain texture overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("https://www.transparenttextures.com/patterns/asfalt-dark.png");
  opacity: .05;
  pointer-events: none;
  z-index: 0;
}

/* Ambient gradient orbs — fixed, behind everything */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 10% 15%, rgba(79,209,255,.09), transparent),
    radial-gradient(ellipse 55% 45% at 90% 85%, rgba(124,92,255,.10), transparent);
  pointer-events: none;
  z-index: 0;
}

a { color: inherit; text-decoration: none; }
img { max-width:100%; display:block; }
button { cursor:pointer; border:none; background:none; }

.container {
  width: min(92%, var(--max));
  margin: auto;
  position: relative;
  z-index: 1;
}

/* ═══════════════════════════════════════
   READING PROGRESS BAR
═══════════════════════════════════════ */
#reading-progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  width: 0%;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  z-index: 9999;
  transition: width .1s linear;
}

/* ═══════════════════════════════════════
   HEADER
═══════════════════════════════════════ */
.site-header {
  position: fixed;
  top: 0; width: 100%;
  height: var(--header-h);
  z-index: 1000;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  background: rgba(7,9,14,.6);
  border-bottom: 1px solid var(--border);
  transition: background .4s var(--ease), box-shadow .4s var(--ease), height .3s var(--ease);
}

.site-header.scrolled {
  background: rgba(7,9,14,.88);
  box-shadow: 0 4px 40px rgba(0,0,0,.4);
  height: 58px;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

/* Logo */
.logo {
  font-family: var(--font-disp);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: .18rem;
  text-transform: uppercase;
  color: var(--text);
  white-space: nowrap;
  transition: color .3s;
}
.logo:hover { color: var(--cyan); }

/* Nav links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-links ul {
  list-style: none;
  display: flex;
  gap: 3rem;
  margin: 0; padding: 0;
}

.nav-links ul li a {
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .06rem;
  color: var(--muted);
  position: relative;
  padding: .4rem .1rem;
  transition: color .3s;
}

.nav-links ul li a::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0;
  width: 0%; height: 1px;
  background: var(--cyan);
  transition: width .3s var(--ease);
}

.nav-links ul li a:hover,
.nav-links ul li.current-menu-item a {
  color: var(--text);
}
.nav-links ul li a:hover::after,
.nav-links ul li.current-menu-item a::after {
  width: 100%;
}

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

.nav-search {
  display: flex;
  align-items: center;
  gap: .5rem;
}

.nav-search-field {
  width: 11rem;
  min-height: 36px;
  padding: .45rem .75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.04);
  color: var(--text);
  font: inherit;
  font-size: .85rem;
  transition: border-color .3s, background .3s;
}

.nav-search-field:focus {
  outline: none;
  border-color: rgba(79,209,255,.55);
  background: rgba(255,255,255,.07);
}

.nav-search-field::placeholder {
  color: var(--muted2);
}

.nav-search-submit {
  min-height: 36px;
  padding: 0 .85rem;
  border: 1px solid rgba(79,209,255,.35);
  border-radius: var(--radius-sm);
  color: var(--cyan);
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .06rem;
  text-transform: uppercase;
  transition: color .3s, border-color .3s, background .3s;
}

.nav-search-submit:hover,
.nav-search-submit:focus-visible {
  color: var(--text);
  border-color: rgba(79,209,255,.65);
  background: rgba(79,209,255,.08);
}

/* Hamburger */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px; height: 36px;
  padding: 4px;
  z-index: 1001;
}

.nav-burger span {
  display: block;
  height: 1.5px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform .35s var(--ease), opacity .25s, width .3s var(--ease);
  transform-origin: center;
}

.nav-burger.is-open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-burger.is-open span:nth-child(2) { opacity:0; width:0; }
.nav-burger.is-open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ═══════════════════════════════════════
   MAIN CONTENT
═══════════════════════════════════════ */
.site-main {
  padding-top: calc(var(--header-h) + 1rem);
  min-height: 60vh;
}

.section { padding: 0 0 6rem; }

/* ═══════════════════════════════════════
   CARDS GRID
═══════════════════════════════════════ */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.75rem;
  perspective: 1200px;
}

.card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .3s, box-shadow .3s;
  will-change: transform;
  position: relative;
}

.card:hover {
  border-color: var(--border2);
  box-shadow: 0 16px 48px rgba(0,0,0,.5), 0 0 0 1px rgba(79,209,255,.08);
}

.card::before {
  content: "";
  position: absolute;
  top: 0; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(79,209,255,.35), transparent);
  opacity: 0;
  transition: opacity .4s;
}
.card:hover::before { opacity: 1; }

.card-image-link { display: block; }

.card-image {
  height: 200px;
  background-size: cover;
  background-position: center;
  transition: transform .5s var(--ease);
  object-fit: cover;
  width: 100%;
}
.card:hover .card-image { transform: scale(1.04); }

.card-image--placeholder {
  background:
    linear-gradient(135deg, var(--cyan-dim), var(--violet-dim));
}

.card-content {
  padding: 1.5rem 1.5rem 1.75rem;
}

.card-meta {
  font-size: .78rem;
  color: var(--muted2);
  letter-spacing: .05rem;
  text-transform: uppercase;
  margin-bottom: .6rem;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
}

.card-meta a { color: var(--cyan); }

.card-title {
  font-family: var(--font-disp);
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: .75rem;
}

.card-title a { transition: color .3s; }
.card-title a:hover { color: var(--cyan); }

.card-excerpt {
  font-size: .9rem;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.card-excerpt p { margin: 0; }

.card-read-more {
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .08rem;
  color: var(--cyan);
  text-transform: uppercase;
  position: relative;
  transition: letter-spacing .3s var(--ease);
}
.card-read-more:hover { letter-spacing: .14rem; }

/* ═══════════════════════════════════════
   SINGLE POST / PAGE
   Article wrapper has NO max-width so
   Gutenberg blocks (columns, media-text,
   cover, etc.) use the full container.
   Only the prose header and post-nav
   footer are constrained to 720px.
═══════════════════════════════════════ */

/* Article wrappers — full container width */
.wiw-page-content,
.wiw-post-content {
  width: 100%;
}

/* Prose header: centred column, 720px */
.wiw-entry-header {
  max-width: 720px;
  margin: 0 auto 2.5rem;
}

/* Post nav footer: centred column, 720px */
.wiw-entry-footer {
  max-width: 720px;
  margin: 5rem auto 0;
  padding-top: 3rem;
  border-top: 1px solid var(--border);
}

/* Thumbnail spans full container width */
.single-thumbnail {
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 3rem;
}
.single-thumbnail img { width: 100%; height: auto; }

/* Meta line (date · category) */
.single-meta {
  font-size: .8rem;
  color: var(--muted2);
  letter-spacing: .06rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
  display: flex;
  gap: .5rem;
  align-items: center;
  flex-wrap: wrap;
}
.single-meta a { color: var(--cyan); }
.single-meta-sep { color: var(--muted2); }

/* Post / page title */
.single-title {
  font-family: var(--font-disp);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -.01em;
  color: var(--text);
}

/* ═══════════════════════════════════════
   PROSE TYPOGRAPHY
   Applied to wiw-entry-body (single/page
   prose sections) AND the legacy
   .entry-content class for compatibility.
═══════════════════════════════════════ */
.wiw-entry-body,
.entry-content {
  font-size: 1.05rem;
  line-height: 1.9;
  color: #c8d0da;
}

/* Headings inside prose */
.wiw-entry-body h1, .entry-content h1,
.wiw-entry-body h2, .entry-content h2,
.wiw-entry-body h3, .entry-content h3,
.wiw-entry-body h4, .entry-content h4 {
  font-family: var(--font-disp);
  font-weight: 600;
  line-height: 1.25;
  margin-top: 2.5rem;
  margin-bottom: .75rem;
  color: var(--text);
}
.wiw-entry-body h1, .entry-content h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
.wiw-entry-body h2, .entry-content h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); }
.wiw-entry-body h3, .entry-content h3 { font-size: clamp(1.2rem, 2.5vw, 1.7rem); }

.wiw-entry-body p, .entry-content p { margin-bottom: 1.4rem; }

.wiw-entry-body a, .entry-content a {
  color: var(--cyan);
  text-decoration: underline;
  text-decoration-color: rgba(79,209,255,.35);
  text-underline-offset: 3px;
  transition: text-decoration-color .3s;
}
.wiw-entry-body a:hover, .entry-content a:hover { text-decoration-color: var(--cyan); }

.wiw-entry-body blockquote, .entry-content blockquote {
  border-left: 2px solid var(--cyan);
  padding: .75rem 1.5rem;
  margin: 2rem 0;
  color: var(--muted);
  font-family: var(--font-disp);
  font-style: italic;
  font-size: 1.2rem;
  line-height: 1.6;
  background: var(--glass);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.wiw-entry-body img, .entry-content img {
  border-radius: var(--radius-sm);
  margin: 1.5rem 0;
}

.wiw-entry-body ul, .entry-content ul,
.wiw-entry-body ol, .entry-content ol {
  padding-left: 1.4rem;
  margin-bottom: 1.4rem;
}

.wiw-entry-body li, .entry-content li { margin-bottom: .4rem; }

.wiw-entry-body hr, .entry-content hr {
  border: none;
  border-top: 1px solid var(--border2);
  margin: 3rem 0;
}

.wiw-entry-body strong, .entry-content strong { color: var(--text); font-weight: 600; }

.wiw-entry-body code, .entry-content code {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 4px;
  padding: .15em .4em;
  font-size: .88em;
  color: var(--cyan);
}

/* ═══════════════════════════════════════
   WORDPRESS BLOCK STYLES
   (Gutenberg — front-end rendering)
═══════════════════════════════════════ */

/* ── Spacer block ── */
.wp-block-spacer { display: block; }

/* ── Images ── */
.wp-block-image { margin: 1.5rem 0; }
.wp-block-image img { border-radius: var(--radius-sm); }
.wp-block-image figcaption {
  font-size: .82rem;
  color: var(--muted2);
  text-align: center;
  margin-top: .5rem;
  font-style: italic;
}

/* ── Gallery ── */
.wp-block-gallery { margin: 1.5rem 0; }
.wp-block-gallery .wp-block-image img { border-radius: var(--radius-sm); }

/* ── Quote ── */
.wp-block-quote {
  border-left: 2px solid var(--cyan);
  padding: .75rem 1.5rem;
  margin: 2rem 0;
  color: var(--muted);
  font-family: var(--font-disp);
  font-style: italic;
  font-size: 1.2rem;
  line-height: 1.6;
  background: var(--glass);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.wp-block-quote cite,
.wp-block-quote footer {
  display: block;
  font-size: .82rem;
  font-style: normal;
  color: var(--muted2);
  margin-top: .5rem;
}

/* ── Pullquote ── */
.wp-block-pullquote {
  border-top: 2px solid rgba(79,209,255,.3);
  border-bottom: 2px solid rgba(79,209,255,.3);
  padding: 2rem;
  margin: 3rem 0;
  text-align: center;
}
.wp-block-pullquote blockquote {
  border: none;
  background: none;
  padding: 0;
  color: var(--text);
  font-family: var(--font-disp);
  font-size: clamp(1.4rem, 3vw, 2rem);
}
.wp-block-pullquote cite { color: var(--muted2); font-style: normal; font-size: .85rem; }

/* ── Separator ── */
.wp-block-separator,
.entry-content hr,
.wiw-entry-body hr {
  border: none;
  border-top: 1px solid var(--border2);
  margin: 3rem 0;
}
.wp-block-separator.is-style-dots::before {
  content: "···";
  color: var(--muted2);
  letter-spacing: .6rem;
  font-size: .9rem;
}

/* ── Code ── */
.wp-block-code {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  font-size: .9rem;
  color: var(--cyan);
  overflow-x: auto;
  margin: 1.5rem 0;
}
.wp-block-preformatted {
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.25rem 1.5rem;
  font-size: .9rem;
  overflow-x: auto;
  white-space: pre-wrap;
  margin: 1.5rem 0;
}

/* ── Table ── */
.wp-block-table {
  margin: 1.5rem 0;
  width: 100%;
  border-collapse: collapse;
}
.wp-block-table td,
.wp-block-table th {
  border: 1px solid var(--border);
  padding: .65rem 1rem;
  color: #c8d0da;
  text-align: left;
}
.wp-block-table th {
  background: rgba(79,209,255,.06);
  color: var(--text);
  font-weight: 600;
}
.wp-block-table tr:hover td { background: rgba(255,255,255,.02); }

/* ── Buttons ── */
.wp-block-buttons { margin: 1.5rem 0; }
.wp-block-button__link {
  display: inline-block;
  padding: .65rem 1.4rem;
  background: rgba(79,209,255,.1);
  color: var(--cyan) !important;
  border: 1px solid rgba(79,209,255,.35);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 500;
  letter-spacing: .04rem;
  text-decoration: none !important;
  transition: background .3s, border-color .3s, color .3s;
}
.wp-block-button__link:hover {
  background: rgba(79,209,255,.2);
  border-color: rgba(79,209,255,.6);
  color: var(--text) !important;
}
.wp-block-button.is-style-outline .wp-block-button__link {
  background: transparent;
  border: 1px solid rgba(79,209,255,.4);
}

/* ── Cover ── */
.wp-block-cover {
  border-radius: var(--radius);
  overflow: hidden;
  margin: 1.5rem 0;
  min-height: 300px;
}
.wp-block-cover__inner-container { color: var(--text); }

/* ── Columns ── */
.wp-block-column { min-width: 0; }

/* ── Media & Text ── */
.wp-block-media-text__media img { border-radius: var(--radius-sm); }

/* ── Verse ── */
.wp-block-verse {
  font-family: var(--font-disp);
  font-size: 1.1rem;
  font-style: italic;
  line-height: 1.8;
  color: var(--muted);
  white-space: pre-wrap;
  margin: 2rem 0;
  padding: 1rem 1.5rem;
  border-left: 2px solid rgba(124,92,255,.4);
  background: var(--glass);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* ── Audio ── */
.wp-block-audio {
  margin: 1.5rem 0;
}
.wp-block-audio audio {
  width: 100%;
  border-radius: var(--radius-sm);
  background: var(--bg2);
  accent-color: var(--cyan);
}

/* ── Video ── */
.wp-block-video {
  margin: 1.5rem 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.wp-block-video video {
  width: 100%;
  display: block;
  border-radius: var(--radius-sm);
}

/* ═══════════════════════════════════════
   RESPONSIVE EMBEDS
   (YouTube, Vimeo, Spotify, SoundCloud,
    Twitter, Instagram — any oEmbed)
═══════════════════════════════════════ */
.wp-block-embed {
  margin: 2rem 0;
  position: relative;
}

.wp-block-embed__wrapper {
  position: relative;
  width: 100%;
  display: block;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg2);
}

/* 16:9 video embeds — YouTube, Vimeo, etc. */
.wp-block-embed-youtube .wp-block-embed__wrapper,
.wp-block-embed-vimeo .wp-block-embed__wrapper,
.wp-block-embed.is-type-video .wp-block-embed__wrapper,
.wp-has-aspect-ratio .wp-block-embed__wrapper {
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
}

.wp-block-embed-youtube .wp-block-embed__wrapper iframe,
.wp-block-embed-vimeo .wp-block-embed__wrapper iframe,
.wp-block-embed.is-type-video .wp-block-embed__wrapper iframe,
.wp-has-aspect-ratio .wp-block-embed__wrapper iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}

/* Spotify, SoundCloud — fixed height */
.wp-block-embed-spotify .wp-block-embed__wrapper iframe,
.wp-block-embed-soundcloud .wp-block-embed__wrapper iframe {
  width: 100%;
  min-height: 152px;
  border: 0;
}

/* Twitter / X, Instagram — centre them */
.wp-block-embed-twitter,
.wp-block-embed-instagram {
  display: flex;
  justify-content: center;
}
.wp-block-embed-twitter .wp-block-embed__wrapper,
.wp-block-embed-instagram .wp-block-embed__wrapper {
  max-width: 550px;
  width: 100%;
}

/* Generic iframe fallback */
.entry-content iframe,
.wiw-entry-body iframe,
.wp-block-embed__wrapper iframe {
  max-width: 100%;
  border: 0;
  border-radius: var(--radius-sm);
}

/* Embed caption */
.wp-block-embed figcaption {
  font-size: .82rem;
  color: var(--muted2);
  text-align: center;
  margin-top: .5rem;
  font-style: italic;
}

/* ═══════════════════════════════════════
   POST NAVIGATION
═══════════════════════════════════════ */
/* .wiw-entry-footer styles are in the SINGLE POST section above */

.post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.post-nav-link {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: 1.25rem 1.5rem;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: border-color .3s, background .3s;
}
.post-nav-link:hover {
  border-color: var(--border2);
  background: var(--glass2);
}

.post-nav-next { text-align: right; }

.nav-label {
  font-size: .75rem;
  color: var(--cyan);
  text-transform: uppercase;
  letter-spacing: .08rem;
}

.nav-title {
  font-family: var(--font-disp);
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.3;
}

/* ═══════════════════════════════════════
   PAGINATION
═══════════════════════════════════════ */
.pagination {
  margin-top: 4rem;
  display: flex;
  justify-content: center;
  gap: .5rem;
  flex-wrap: wrap;
}

.page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 .75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .875rem;
  color: var(--muted);
  transition: color .3s, border-color .3s, background .3s;
}

.page-numbers:hover,
.page-numbers.current {
  color: var(--cyan);
  border-color: rgba(79,209,255,.4);
  background: rgba(79,209,255,.06);
}

.blog-pagination {
  justify-content: space-between;
}

.blog-pagination-link {
  min-width: 10rem;
}

.blog-pagination-link:empty {
  visibility: hidden;
}

.blog-pagination-link a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 44px;
  padding: .65rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--cyan);
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .08rem;
  text-transform: uppercase;
  transition: color .3s, border-color .3s, background .3s;
}

.blog-pagination-link a:hover {
  color: var(--text);
  border-color: rgba(79,209,255,.45);
  background: rgba(79,209,255,.06);
}

/* ═══════════════════════════════════════
   FOOTER
═══════════════════════════════════════ */
footer {
  padding: 3.5rem 0;
  position: relative;
  border-top: none;
  z-index: 1;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-brand { display: flex; flex-direction: column; gap: .35rem; }

.footer-tagline {
  font-size: .82rem;
  color: var(--muted2);
  font-style: italic;
}

.footer-copy {
  font-size: .8rem;
  color: var(--muted2);
}

/* ═══════════════════════════════════════
   FADE-IN ANIMATION
═══════════════════════════════════════ */
.fade-in {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .75s var(--ease), transform .75s var(--ease);
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.cards .card:nth-child(2) { transition-delay: .08s; }
.cards .card:nth-child(3) { transition-delay: .16s; }
.cards .card:nth-child(4) { transition-delay: .24s; }
.cards .card:nth-child(5) { transition-delay: .32s; }
.cards .card:nth-child(6) { transition-delay: .40s; }

/* ═══════════════════════════════════════
   MISC
═══════════════════════════════════════ */
.no-content {
  text-align: center;
  padding: 2rem 0;
  color: var(--muted);
  font-style: italic;
}

/* ═══════════════════════════════════════
   WRITING TIMELINE
═══════════════════════════════════════ */
.wiw-timeline {
  position: relative;
  z-index: 1;
  padding: 3.5rem 0;
  overflow: hidden;
}

/* Subtle section tint */
.wiw-timeline::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(79,209,255,.03) 0%, rgba(124,92,255,.05) 100%);
  pointer-events: none;
}

/* Top & bottom glow lines */
.wiw-timeline::after {
  content: "";
  position: absolute;
  top: 0; left: 5%; right: 5%;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(79,209,255,.2) 30%,
    rgba(124,92,255,.25) 70%,
    transparent
  );
}

.wiw-timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.75rem;
}

.wiw-timeline-label {
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .22rem;
  text-transform: uppercase;
  color: var(--cyan);
}

.wiw-timeline-scroll-hint {
  font-size: .7rem;
  letter-spacing: .14rem;
  text-transform: uppercase;
  color: var(--muted2);
}

/* Non-scrolling shell — owns the edge fade masks so they
   stay pinned to the viewport instead of scrolling away. */
.wiw-timeline-shell {
  position: relative;
  border-radius: var(--radius-sm);
}

/* Make the era anchor look obviously interactive */
.wiw-timeline-era { cursor: pointer; }
.wiw-timeline-era:focus-visible {
  outline: 1px solid var(--cyan);
  outline-offset: 4px;
  border-radius: 4px;
}

/* Scrollable track */
.wiw-timeline-outer {
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  cursor: grab;
  user-select: none;
  border-radius: var(--radius-sm);
  position: relative;
}
.wiw-timeline-outer::-webkit-scrollbar { display: none; }
.wiw-timeline-outer.is-dragging { cursor: grabbing; }

.wiw-timeline-items {
  display: flex;
  gap: 0;
  padding: 0 3rem 1.25rem;
  min-width: max-content;
  align-items: flex-end;
}

/* Each year/era block */
.wiw-timeline-era {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  min-width: 140px;
  padding: 1rem 1.25rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: inherit;
  transition: border-color .3s, background .3s;
  position: relative;
}

.wiw-timeline-era:hover {
  border-color: var(--border2);
  background: var(--glass);
}

/* Vertical tick mark */
.wiw-timeline-era::before {
  content: "";
  position: absolute;
  bottom: -1.25rem;
  left: 1.5rem;
  width: 1px;
  height: .75rem;
  background: rgba(79,209,255,.35);
}

.wiw-era-year {
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .18rem;
  color: var(--cyan);
  text-transform: uppercase;
}

.wiw-era-name {
  font-family: var(--font-disp);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.2;
}

.wiw-era-count {
  font-size: .73rem;
  color: var(--muted2);
  letter-spacing: .04rem;
}

/* Waveform canvas — JS sets explicit width to match scrollWidth
   so the wave spans the full timeline, not just the viewport. */
.wiw-timeline-wave {
  display: block;
  height: 88px;
  margin-top: .5rem;
  pointer-events: none;
}

/* Footer tagline */
.wiw-timeline-tagline {
  text-align: center;
  font-family: var(--font-disp);
  font-size: 1rem;
  font-style: italic;
  color: var(--muted);
  margin-top: 1.25rem;
  letter-spacing: .04rem;
  opacity: .7;
}

/* ═══════════════════════════════════════
   MOBILE
═══════════════════════════════════════ */
@media (max-width: 860px) {

  .nav-burger { display: flex; }

  .nav-links {
    position: fixed;
    top: 0; right: 0;
    width: min(85vw, 320px);
    height: 100vh;
    background: rgba(7,9,14,.97);
    backdrop-filter: blur(20px);
    border-left: 1px solid var(--border);
    padding: calc(var(--header-h) + 2rem) 2rem 2rem;
    flex-direction: column;
    align-items: flex-start;
    transform: translateX(100%);
    transition: transform .4s var(--ease);
    z-index: 999;
  }

  .nav-links.nav-open { transform: translateX(0); }

  .nav-links ul {
    flex-direction: column;
    gap: 0;
    width: 100%;
  }

  .nav-links ul li a {
    display: block;
    padding: 1rem 0;
    font-size: 1.1rem;
    border-bottom: 1px solid var(--border);
  }

  .nav-search {
    width: 100%;
    margin-top: 1.5rem;
    align-items: stretch;
    flex-direction: column;
  }

  .nav-search-field,
  .nav-search-submit {
    width: 100%;
  }

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

  .blog-pagination {
    margin-top: 2.5rem;
    flex-direction: column;
    align-items: stretch;
    gap: .75rem;
  }

  .blog-pagination-link {
    min-width: 0;
    width: 100%;
  }

  .blog-pagination-link:empty {
    display: none;
  }

  .post-nav { grid-template-columns: 1fr; }
  .post-nav-next { text-align: left; }

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

  .site-main { padding-top: calc(var(--header-h) + .75rem); }

  .section { padding: 0 0 4rem; }

  .wiw-timeline-items { padding: 0 1.5rem 1.25rem; }
  .wiw-timeline-era { min-width: 110px; }
}

@media (max-width: 480px) {
  .single-title { font-size: 2rem; }
  .card-image { height: 180px; }

  .wiw-timeline-era { min-width: 95px; }
}

/* ═══════════════════════════════════════
   FOCUS / ACCESSIBILITY
═══════════════════════════════════════ */
:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ═══════════════════════════════════════
   CUSTOM CURSOR
═══════════════════════════════════════ */
@media (pointer: fine) {
  body { cursor: none; }
  a, button, [role="button"], input, textarea, select, label { cursor: none; }
}

#wiw-cursor {
  position: fixed;
  width: 36px; height: 36px;
  border: 1px solid rgba(79,209,255,.55);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99999;
  top: -18px; left: -18px;
  transition: width .25s var(--ease), height .25s var(--ease),
              border-color .25s, background .25s, opacity .3s;
  mix-blend-mode: screen;
  will-change: transform;
}

#wiw-cursor-dot {
  position: fixed;
  width: 5px; height: 5px;
  background: var(--cyan);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99999;
  top: -2.5px; left: -2.5px;
  will-change: transform;
  transition: opacity .3s;
}

#wiw-cursor.cursor-hover {
  width: 56px; height: 56px;
  top: -28px; left: -28px;
  border-color: rgba(124,92,255,.7);
  background: rgba(124,92,255,.06);
}

#wiw-cursor.cursor-click {
  width: 24px; height: 24px;
  top: -12px; left: -12px;
  background: rgba(79,209,255,.15);
}

/* ═══════════════════════════════════════
   AURORA BACKGROUND
═══════════════════════════════════════ */
#wiw-aurora {
  --ax: 50%;
  --ay: 50%;
  position: fixed;
  inset: -20%;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 70% 55% at var(--ax) var(--ay),
      rgba(79,209,255,.07), transparent 65%),
    radial-gradient(ellipse 60% 50% at calc(100% - var(--ax)) calc(100% - var(--ay)),
      rgba(124,92,255,.08), transparent 65%);
  animation: aurora-drift 18s ease-in-out infinite alternate;
  transition: background .15s linear;
}

@keyframes aurora-drift {
  0%   { opacity: .7; filter: blur(0px); }
  50%  { opacity: 1;  filter: blur(2px); }
  100% { opacity: .75; filter: blur(0px); }
}

/* ═══════════════════════════════════════
   PAGE-LOAD SCANLINE SWEEP
═══════════════════════════════════════ */
#wiw-sweep {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 99998;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(79,209,255,.018) 3px,
    rgba(79,209,255,.018) 4px
  );
  animation: sweep-down 1.1s var(--ease) forwards;
}

@keyframes sweep-down {
  0%   { clip-path: inset(0 0 100% 0); opacity: 1; }
  70%  { clip-path: inset(0 0 0% 0);   opacity: 1; }
  100% { clip-path: inset(0 0 0% 0);   opacity: 0; }
}

/* ═══════════════════════════════════════
   RIPPLE CLICK EFFECT
═══════════════════════════════════════ */
.wiw-ripple {
  position: fixed;
  width: 6px; height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  border: 1px solid rgba(79,209,255,.6);
  pointer-events: none;
  z-index: 9998;
  animation: ripple-out .7s var(--ease) forwards;
}

@keyframes ripple-out {
  from { transform: scale(1);  opacity: .7; }
  to   { transform: scale(22); opacity: 0;  }
}

/* ═══════════════════════════════════════
   LOGO SHIMMER
═══════════════════════════════════════ */
.logo {
  background: linear-gradient(
    105deg,
    var(--text) 0%,
    var(--text) 40%,
    var(--cyan) 50%,
    var(--text) 60%,
    var(--text) 100%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 6s linear infinite;
}

.logo:hover { color: unset; }

@keyframes shimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}

/* ═══════════════════════════════════════
   MAGNETIC NAV — smooth transform
═══════════════════════════════════════ */
.nav-links ul li a {
  transition: color .3s, transform .3s var(--ease);
  display: inline-block;
}

/* ═══════════════════════════════════════
   FOOTER GLOW LINE
═══════════════════════════════════════ */
footer::before {
  content: "";
  display: block;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(79,209,255,.25) 30%,
    rgba(124,92,255,.3)  60%,
    transparent 100%
  );
  position: absolute;
  top: 0; left: 5%; right: 5%;
}

/* ═══════════════════════════════════════
   ARCHIVES
═══════════════════════════════════════ */
.archive-header {
  margin-bottom: 2rem;
}

.archive-title {
  font-family: var(--font-disp);
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 600;
  line-height: 1.05;
  color: var(--text);
}

.post-grid {
  align-items: stretch;
}

.post-grid .card {
  display: flex;
  flex-direction: column;
}

.post-grid .card-content {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.post-grid .card-read-more {
  margin-top: auto;
}

/* ═══════════════════════════════════════
   SELECTION COLOR
═══════════════════════════════════════ */
::selection {
  background: rgba(79,209,255,.22);
  color: #fff;
}

/* ═══════════════════════════════════════
   BLOG LIST — POST TITLES
═══════════════════════════════════════ */
.post-list-header {
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.post-list-title {
  font-family: var(--font-disp);
  font-size: clamp(2.6rem, 5.5vw, 4.5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -.02em;
  margin-bottom: .6rem;
  color: var(--text) !important;
  -webkit-text-fill-color: var(--text) !important;
  background: none !important;
  opacity: 1 !important;
}

.post-list-title a {
  color: var(--text);
  -webkit-text-fill-color: var(--text);
  transition: color .3s, -webkit-text-fill-color .3s;
}

.post-list-title a:hover {
  color: var(--cyan);
  -webkit-text-fill-color: var(--cyan);
}

.post-list-meta {
  font-size: .78rem;
  color: var(--muted2);
  letter-spacing: .05rem;
  text-transform: uppercase;
}

.site-main .section > article + article {
  margin-top: 4rem;
  padding-top: 4rem;
  border-top: 1px solid var(--border);
}

/* ═══════════════════════════════════════
   PARALLAX LAYERS
═══════════════════════════════════════ */
img,
.card-image,
.single-thumbnail img {
  will-change: transform;
}

/* Floating particles canvas */
#wiw-particles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .55;
}

/* ═══════════════════════════════════════
   HAS-ASPECT-RATIO UTILITY
   (WordPress core responsive embed helper)
═══════════════════════════════════════ */
.wp-has-aspect-ratio .wp-block-embed__wrapper::before {
  content: "";
  display: block;
}
.wp-embed-aspect-21-9 .wp-block-embed__wrapper { padding-bottom: 42.86%; }
.wp-embed-aspect-18-9 .wp-block-embed__wrapper { padding-bottom: 50%;    }
.wp-embed-aspect-16-9 .wp-block-embed__wrapper { padding-bottom: 56.25%; }
.wp-embed-aspect-4-3  .wp-block-embed__wrapper { padding-bottom: 75%;    }
.wp-embed-aspect-1-1  .wp-block-embed__wrapper { padding-bottom: 100%;   }
.wp-embed-aspect-9-16 .wp-block-embed__wrapper { padding-bottom: 177.78%; }
