/*
Theme Name: GWill Tech Blog
Theme URI: https://tech.gwillchijioke.com
Author: G-will Chijioke
Author URI: https://gwillchijioke.com
Description: Tech blog theme for Android, Web-Dev, and Software guides. Built from wireframe with forced dark mode.
Version:      1.15.5
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: gwill-tech
Tags: custom, blog, dark-mode
*/

/* ==========================================================================
   CSS VARIABLES — Forced Dark Mode (Wireframe Source of Truth)
   ========================================================================== */
:root {
  color-scheme: dark;
  --bg: #0d0d0d;
  --surface: #111318;
  --surface-2: #181c24;
  --border: #1e2028;
  --border-2: #252836;
  --text: #e2e8f0;
  --mid: #8896aa;
  --dim: #7586a0;
  --dim2: #7788a3;
  --green: #00ff91;
  --green-hover: #33ffa8;
  --green-dim: rgba(0, 255, 145, .06);
  --green-glow: rgba(0, 255, 145, .14);
  --green-border: rgba(0, 255, 145, .22);
  --purple: #7c3aed;
  --cat-android: #00ff91;
  --cat-android-dim: rgba(0, 255, 145, .10);
  --cat-android-border: rgba(0, 255, 145, .22);
  --cat-webdev: #9f7aea;
  --cat-webdev-dim: rgba(124, 58, 237, .10);
  --cat-webdev-border: rgba(124, 58, 237, .22);
  --cat-software: #22d3ee;
  --cat-software-dim: rgba(34, 211, 238, .10);
  --cat-software-border: rgba(34, 211, 238, .22);
  --font-mono: 'JetBrains Mono', monospace;
  --font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --sp-4: 16px;
  --sp-2: 8px;
  --sp-5: 20px;
  --sp-6: 24px;
  --sp-8: 32px;
  --sp-10: 40px;
  --sp-12: 48px;
  --sp-16: 64px;
  --sp-20: 80px;
  --sp-24: 96px;
  --sp-32: 128px;
  --r-sm: 4px;
  --r: 8px;
  --r-lg: 12px;
  --r-pill: 100px;
  --ease-out: cubic-bezier(.23, 1, .32, 1);
  --content-w: 1180px;
  --sidebar-w: 300px;
  --btm-tab-h: 56px;
  --z-sticky: 200;
  --z-btm-tab: 200;
  --z-cookie: 400;
  --z-mob-nav: 500;
}

/* ── Accessibility: skip link + screen-reader-only helper ──────────── */
.skip-link, .screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px,1px,1px,1px); clip-path: inset(50%); white-space: nowrap;
}
.skip-link:focus {
  position: fixed; top: 8px; left: 8px; z-index: 9999; width: auto; height: auto;
  clip: auto; clip-path: none; white-space: normal;
  background: var(--green); color: #0d0d0d;
  padding: 10px 16px; border-radius: var(--r-sm);
  font-family: var(--font-mono); font-size: 12px; font-weight: 700;
  box-shadow: 0 0 0 3px rgba(0,255,145,.3), 0 6px 24px rgba(0,0,0,.5);
}

/* ==========================================================================
  BRANDED SCROLLBAR — dark terminal aesthetic (webkit + Firefox)
   --------------------------------------------------------------------------
   NOTE: NOT gated behind (hover: hover). Android Chrome applies
   ::-webkit-scrollbar on touch devices when scrolling; Firefox Android
   honors scrollbar-width/scrollbar-color. iOS Safari does not support
   styling native scrollbars at all (OS-level overlay scrollbar) — that
   is a platform limitation, not a theme bug.
   ========================================================================== */
/* ── Firefox (desktop + Android) ── */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--green-border) var(--surface);
}
/* ── WebKit / Chromium (desktop + Android) ── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--surface);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb {
  background: var(--green-border);
  border-radius: 3px;
  transition: background .2s;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--green);
}
::-webkit-scrollbar-corner {
  background: transparent;
}

/* ==========================================================================
   RESET & BASE
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0 }
html { font-size: 16px; scroll-behavior: smooth; overflow-x: clip }
html body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
  overflow-x: clip;
}
/* Brand text selection — terminal green highlight */
::selection { background: rgba(0, 255, 145, .28); color: var(--text) }
::-moz-selection { background: rgba(0, 255, 145, .28); color: var(--text) }
img, svg, video { display: block; max-width: 100%; height: auto }
body a { color: inherit; text-decoration: none }
button { cursor: pointer; font-family: inherit }
input, textarea, select { font-family: inherit }
ul, ol { list-style: none }
body h1, body h2, body h3, body h4, body h5, body h6 { font-family: var(--font-mono); font-weight: 800; line-height: 1.15; color: var(--text) }

/* Subtle noise texture */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: .025;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Focus visible */
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 3px }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ==========================================================================
   TYPOGRAPHY SCALE
   ========================================================================== */
.h1 { font-size: clamp(30px, 5vw, 52px); font-weight: 800; line-height: 1.1; letter-spacing: -.03em }
.h2 { font-size: clamp(22px, 3vw, 34px); font-weight: 700; line-height: 1.2 }
.h3 { font-size: clamp(17px, 2vw, 22px); font-weight: 700 }
.body { font-size: 18px; line-height: 1.8 }
.body-sm { font-size: 16px; line-height: 1.75 }
.label { font-size: 12px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--dim); font-family: var(--font-mono) }
.label-green { color: var(--green) }

/* Section headers (homepage) */
.sec-head { margin-bottom: 20px }
.sec-head-link { transition: color .15s }
.cat-android-link { color: var(--cat-android) }
.cat-webdev-link { color: var(--cat-webdev) }
.cat-software-link { color: var(--cat-software) }
.sec-head-label-webdev { color: var(--cat-webdev) }
.sec-head-label-software { color: var(--cat-software) }
.sec-grid-bottom { margin-bottom: 24px }
.filter-pills { gap: 8px; flex-wrap: wrap }

/* Prose styles for article content */
.prose { max-width: 68ch; min-width: 0; width: 100% }
.prose p { margin-bottom: 1.2em; font-size: 17px; line-height: 1.8 }
.prose h2 { font-size: 24px; font-weight: 800; margin: 2.8em 0 .8em }
.prose h3 { font-size: 18px; font-weight: 700; margin: 2em 0 .6em }
.prose ul, .prose ol { margin: 0 0 1.4em; padding-left: 0; list-style: none }
/* Branded markers ONLY on plain content lists — Gutenberg wp-block-list or
   classic editor lists with no class. Widget/utility lists (categories,
   archives, social links, latest comments) keep their own dedicated rules. */
.prose ul.wp-block-list > li,
.prose ol.wp-block-list > li,
.prose ul:not([class]) > li,
.prose ol:not([class]) > li {
  margin-bottom: .5em;
  line-height: 1.75;
  padding-left: 1.6em;
  position: relative;
}
.prose ul.wp-block-list > li::before,
.prose ul:not([class]) > li::before {
  content: '\003E\005F';
  position: absolute;
  left: 0;
  font-family: var(--font-mono);
  color: var(--green);
  font-weight: 700;
}
.prose ol.wp-block-list, .prose ol:not([class]) { counter-reset: gwill-step }
.prose ol.wp-block-list > li, .prose ol:not([class]) > li { counter-increment: gwill-step }
.prose ol.wp-block-list > li::before,
.prose ol:not([class]) > li::before {
  content: counter(gwill-step, decimal-leading-zero);
  position: absolute;
  left: 0;
  font-family: var(--font-mono);
  color: var(--green);
  font-weight: 700;
  font-size: .85em;
}
.prose blockquote { border-left: 3px solid var(--green); padding: .2em 0 .2em 20px; margin: 1.6em 0; color: var(--mid); font-style: italic }
.prose a { color: var(--green); text-decoration: underline; text-underline-offset: 3px }
.prose .btn { text-decoration: none }
.prose .badge { text-decoration: none }
.prose pre { background: #08090b; border: 1px solid var(--border); border-radius: var(--r); padding: 20px; overflow-x: auto; font-size: 13px; line-height: 1.7; margin: 1.4em 0; position: relative; max-width: 100% }
.prose pre code { color: #c9d1d9; font-family: var(--font-mono); word-break: break-all }
.prose .code-lang { position: absolute; top: 10px; right: 52px; font-size: 10px; color: var(--dim2); text-transform: uppercase }
.prose .copy-btn { position: absolute; top: 8px; right: 8px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 5px 10px; font-size: 10px; font-weight: 600; color: var(--mid); cursor: pointer }
.prose .copy-btn:hover { color: var(--text); border-color: var(--border-2) }
.prose code:not(pre code) { background: var(--surface-2); padding: 2px 6px; border-radius: 4px; font-size: .9em; color: var(--green); font-family: var(--font-mono) }

/* ── Post tags ─────────────────────────────────────────────────────────── */
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: var(--sp-6) 0 }
.post-tag { display: inline-flex; padding: 4px 12px; border-radius: var(--r-pill); border: 1px solid var(--border); font-size: 11px; font-weight: 600; color: var(--mid); font-family: var(--font-mono); text-decoration: none; transition: border-color .15s, color .15s, background .15s }
.post-tag:hover { border-color: var(--green-border); color: var(--green); background: var(--green-dim) }

/* ── Images in prose ───────────────────────────────────────────────────── */
.prose img { cursor: zoom-in; transition: opacity .2s }
.prose img:hover { opacity: .92 }

/* Image captions — terminal comment style: mono, muted, # prefix.
   Without this, figcaption inherits body text styles and reads as
   paragraph content. The # marks it as metadata, not prose. */
.prose figcaption,
.wp-element-caption,
.wp-caption-text {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--mid);
  line-height: 1.6;
  text-align: center;
  margin: 10px auto 0;
  max-width: 92%;
}
.prose figcaption::before,
.wp-element-caption::before,
.wp-caption-text::before { content: '# '; color: var(--green); font-weight: 700 }
.prose figcaption a,
.wp-element-caption a,
.wp-caption-text a { color: var(--green); text-decoration: underline; text-underline-offset: 2px }

/* Image figures need bottom breathing room — the universal reset
   (* { margin: 0 }) kills Gutenberg's default figure margins, so
   stacked images used to touch the next element with zero gap. */
.prose figure { margin: 0 0 var(--sp-6) }
.prose figure:last-child { margin-bottom: 0 }

/* ── About page ────────────────────────────────────────────────────────── */
.about-hero { margin-bottom: var(--sp-8); position: relative }
.about-hero::before { content: ""; position: absolute; inset: -10% -20%; width: 140%; height: 140%; background: radial-gradient(ellipse at 30% 50%, rgba(0, 255, 145, 0.06), transparent 65%); pointer-events: none }
.about-intro { display: grid; grid-template-columns: 1fr auto; gap: var(--sp-10); align-items: center; position: relative; z-index: 2 }
.about-text { min-width: 0 }
#search-results.has-results { border-top: 1px solid var(--border); padding-top: var(--sp-4) }
/* Disable reveal animation on search results page cards */
.search .card.reveal { animation: none }
.about-avatar {
  width: 180px; height: 180px; border-radius: var(--r-lg);
  background: linear-gradient(160deg, #0a1f22, var(--surface) 75%);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 56px; font-weight: 800; color: var(--green);
  font-family: var(--font-mono); flex-shrink: 0;
  text-shadow: 0 0 20px rgba(0,255,145,.3);
  overflow: hidden;
}
.about-avatar img,
.about-avatar .author-gravatar {
  width: 100%; height: 100%; object-fit: cover;
  border-radius: var(--r-lg);
}
.about-stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-5);
  padding: var(--sp-6); background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--r);
  margin-bottom: var(--sp-8);
}
.about-stat { font-size: 13px; color: var(--mid); font-family: var(--font-mono); text-align: center; border-right: 1px solid var(--border); padding: 0 var(--sp-4) }
.about-stat:last-child { border-right: none }
.about-stat strong { display: block; font-size: 24px; font-weight: 800; color: var(--green); margin-bottom: 4px }
.about-cta { text-align: center; padding: var(--sp-10) 0 }
.about-cta p { font-size: 17px; color: var(--mid); margin-bottom: var(--sp-5); line-height: 1.7 }
@media (max-width: 1023px) { .about-avatar { margin: 0 auto } .about-stats { grid-template-columns: repeat(2, 1fr); gap: var(--sp-4) } .about-stat:nth-child(2n) { border-right: none } .about-stat { padding: var(--sp-3) 0 } }
@media (max-width: 767px) { .about-intro { grid-template-columns: 1fr; text-align: left } .about-avatar { width: 120px; height: 120px; font-size: 36px } .about-stats { grid-template-columns: repeat(2, 1fr) } .about-stat strong { font-size: 20px } }

/* ── About Content (word-break safety) ──────────────────────────── */
.about-content { max-width: 66ch; margin: 0 auto var(--sp-8); padding: 0 var(--sp-4) }
.start-here-content { max-width: 100% }
.start-here-grid { margin-top: var(--sp-8) }
.start-here-grid .card-body { display: flex; flex-direction: column; flex: 1 }
.resources-page-content { max-width: 100% }
.disclaimer-content { max-width: 100% }
.privacy-content { max-width: 100% }
.about-hero h1 { overflow-wrap: break-word; word-break: break-word }
/* Archive/category description links — brand green + underline so users see
   there's a link (the description <p> inherits gray var(--mid) otherwise). */
.about-hero .about-text p a { color: var(--green); text-decoration: underline; text-underline-offset: 3px }
.about-hero .about-text p a:hover { color: var(--green); text-decoration: none; opacity: .85 }
@media (max-width: 767px) { .about-content { max-width: 100%; padding: 0 var(--sp-5) } }

/* ── Lightbox ──────────────────────────────────────────────────────────── */
.gl-overlay {
  position: fixed; inset: 0; z-index: 99999;
  background: rgba(0, 0, 0, .92);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity .25s ease;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.gl-overlay.gl-open { opacity: 1; pointer-events: auto }
.gl-image-wrap { display: flex; align-items: center; justify-content: center; max-width: 90vw; max-height: 80vh }
.gl-image { max-width: 100%; max-height: 80vh; object-fit: contain; border-radius: 4px; box-shadow: 0 8px 40px rgba(0,0,0,.5) }
.gl-close {
  position: absolute; top: 16px; right: 16px;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12);
  color: #fff; font-size: 24px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s; z-index: 2;
  font-family: var(--font-mono);
}
.gl-close:hover { background: rgba(255,255,255,.16) }
.gl-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 48px; height: 48px; border-radius: 50%;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12);
  color: #fff; font-size: 28px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s; z-index: 2;
  font-family: var(--font-mono);
}
.gl-nav:hover { background: rgba(255,255,255,.16) }
.gl-prev { left: 16px }
.gl-next { right: 16px }
.gl-caption {
  position: absolute; bottom: 0; left: 0; right: 0;
  text-align: center; padding: 20px;
  color: rgba(255,255,255,.7); font-size: 14px;
  background: linear-gradient(transparent, rgba(0,0,0,.6));
}
.gl-counter {
  position: absolute; top: 20px; left: 50%; transform: translateX(-50%);
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px; font-weight: 600;
  color: rgba(255,255,255,.6);
  background: rgba(0,0,0,.4);
  padding: 4px 14px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,.1);
  pointer-events: none;
  z-index: 2;
}
@media (max-width: 767px) {
  .gl-nav { width: 36px; height: 36px; font-size: 20px }
  .gl-prev { left: 8px }
  .gl-next { right: 8px }
  .gl-image { max-height: 70vh }
}

/* Tables in prose — override WP block defaults */
.prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: 14px; line-height: 1.6 }
.prose th, .prose td { border: 1px solid var(--border); padding: 12px 14px; text-align: left }
.prose th { background: var(--surface-2); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--mid); font-family: var(--font-mono) }
.prose td { background: var(--surface) }
.prose tr:nth-child(even) td { background: rgba(255,255,255,.02) }
.prose tbody tr:hover td { background: var(--green-dim) }
.prose thead { border-bottom: none } /* Kill WP's 3px white-ish thead border */
.prose .wp-block-table thead { border-bottom: 1px solid var(--border) } /* Our thin border instead */
@media (max-width: 767px) { .prose table { font-size: 12px } .prose th, .prose td { padding: 8px 10px } }

/* Figure wrapper for WP block tables */
.prose figure.wp-block-table { margin: 1.4em 0; overflow-x: auto; max-width: 100% }

/* WP Separator */
.prose hr, .prose .wp-block-separator { border: none; border-top: 1px solid var(--border); margin: 3em 0; height: 1px }

/* WP Gallery block */
.prose .wp-block-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 1.4em 0; list-style: none; padding: 0 }
.prose .wp-block-gallery .wp-block-image { margin: 0; width: 100% !important }
.prose .wp-block-gallery img { width: 100%; height: 200px; object-fit: cover; border-radius: var(--r); cursor: zoom-in }
@media (max-width: 1023px) { .prose .wp-block-gallery { grid-template-columns: repeat(2, 1fr) } }
@media (max-width: 767px) { .prose .wp-block-gallery { grid-template-columns: 1fr } .prose .wp-block-gallery img { height: 180px } }

/* WP Code block */
.prose .wp-block-code { margin: 1.4em 0 }
.prose .wp-block-code code { display: block; font-family: var(--font-mono); font-size: 13px; line-height: 1.7; color: #c9d1d9; overflow-x: auto }

/* WP Blockquote */
.prose .wp-block-quote { border-left: 3px solid var(--green); padding: .2em 0 .2em 20px; margin: 1.6em 0; color: var(--mid); font-style: italic }
.prose .wp-block-quote cite { display: block; margin-top: 8px; font-size: 13px; font-style: normal; color: var(--dim); font-family: var(--font-mono) }

/* ==========================================================================
   GUTENBERG BLOCK STYLES (v1.6.0) — every block gets a design
   ========================================================================== */

/* -- Embed blocks (YouTube, Vimeo, Spotify, SoundCloud, X, TikTok…) -- */
.prose .wp-block-embed { margin: 1.6em 0; max-width: 100% }
.prose .wp-block-embed__wrapper { max-width: 100% }
.prose .wp-block-embed__wrapper > iframe { display: block; max-width: 100% }
/* Video embeds hold 16:9; rich embeds (Spotify/SoundCloud) keep provider height */
.prose .wp-block-embed.is-type-video .wp-block-embed__wrapper { aspect-ratio: 16/9 }
.prose .wp-block-embed.is-type-video .wp-block-embed__wrapper > iframe { width: 100%; height: 100%; border: 1px solid var(--border); border-radius: var(--r) }
.prose .wp-block-embed:not(.is-type-video) .wp-block-embed__wrapper > iframe { border: 1px solid var(--border); border-radius: var(--r) }
/* Spotify — the player's natural height is 152px (per Spotify's own oEmbed).
   Do NOT override the height: forcing 200px stretched the iframe box and
   left white space under the player. Also drop the theme border — the
   player has its own 12px radius; a wrapping border shows as corner gaps.
   The generic .prose figure bottom margin (--sp-6) stacks with the embed's
   own 1.6em margin → double space under short embeds (Spotify especially);
   kill it for embed figures so spacing is uniform. */
.prose .wp-block-embed.is-provider-spotify .wp-block-embed__wrapper > iframe { height: 152px; border: none }
.prose figure.wp-block-embed { margin-bottom: 1.6em }

/* X / Twitter embeds — blockquote shell styled as a terminal card; the
   widgets.js script replaces the inner content with the live tweet. */
.prose .wp-block-embed.is-provider-twitter .wp-block-embed__wrapper,
.prose .wp-block-embed.is-provider-x .wp-block-embed__wrapper { min-height: 120px }
.prose .wp-block-embed.is-provider-twitter blockquote.twitter-tweet,
.prose .wp-block-embed.is-provider-x blockquote.twitter-tweet { border: 1px solid var(--border); border-radius: var(--r); background: var(--surface); padding: var(--sp-5); margin: 0; color: var(--text); font-size: 14px; line-height: 1.6 }

/* -- Video block (locally uploaded video) -- */
.prose .wp-block-video { margin: 1.6em 0 }
.prose .wp-block-video video { width: 100%; display: block; background: #000; border: 1px solid var(--border); border-radius: var(--r) }
.prose .wp-block-video figcaption { margin-top: 10px }

/* -- Audio block -- */
.prose .wp-block-audio { margin: 1.6em 0 }
.prose .wp-block-audio audio { width: 100%; display: block; color-scheme: dark }
.prose .wp-block-audio figcaption { margin-top: 10px }

/* -- Cover block -- */
.prose .wp-block-cover { position: relative; min-height: 260px; margin: 1.6em 0; display: flex; align-items: center; justify-content: center; overflow: hidden; border: 1px solid var(--border); border-radius: var(--r) }
/* Background image/video must fill the cover absolutely — without these
   rules the image stays in normal flow (a flex item beside the text)
   instead of behind it. Mirrors core's cover styles, which the theme
   strips (no wp-block-library CSS shipped). */
.prose .wp-block-cover .wp-block-cover__image-background,
.prose .wp-block-cover video.wp-block-cover__video-background { position: absolute; top: 0; left: 0; right: 0; bottom: 0; width: 100%; height: 100%; object-fit: cover; border: none; margin: 0; padding: 0; max-width: none; max-height: none; outline: none; box-shadow: none }
.prose .wp-block-cover .wp-block-cover__background,
.prose .wp-block-cover .wp-block-cover__gradient-background { position: absolute; top: 0; left: 0; right: 0; bottom: 0; opacity: .5 }
/* Dim levels — mirror core's has-background-dim-* scale (theme ships no
   wp-block-library CSS, so these must exist here or dimming silently
   falls back to the .5 default above). */
.prose .wp-block-cover .has-background-dim-10 { opacity: .1 }
.prose .wp-block-cover .has-background-dim-20 { opacity: .2 }
.prose .wp-block-cover .has-background-dim-30 { opacity: .3 }
.prose .wp-block-cover .has-background-dim-40 { opacity: .4 }
.prose .wp-block-cover .has-background-dim-50 { opacity: .5 }
.prose .wp-block-cover .has-background-dim-60 { opacity: .6 }
.prose .wp-block-cover .has-background-dim-70 { opacity: .7 }
.prose .wp-block-cover .has-background-dim-80 { opacity: .8 }
.prose .wp-block-cover .has-background-dim-90 { opacity: .9 }
.prose .wp-block-cover .has-background-dim-100 { opacity: 1 }
.prose .wp-block-cover__inner-container { position: relative; z-index: 1; width: 100%; max-width: 640px; padding: 32px 24px }
.prose .wp-block-cover__inner-container > :first-child { margin-top: 0 }
.prose .wp-block-cover__inner-container > :last-child { margin-bottom: 0 }

/* -- File block -- */
.prose .wp-block-file { margin: 1.6em 0; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 16px 20px }
.prose .wp-block-file a:first-child { color: var(--text); text-decoration: none }
.prose .wp-block-file a:first-child::before { content: '📎 '; font-size: 13px }
.prose .wp-block-file a:first-child:hover { color: var(--green) }
.prose .wp-block-file__button { display: inline-flex; align-items: center; background: var(--green); color: #08160f; font-family: var(--font-mono); font-size: 12px; font-weight: 700; padding: 8px 14px; border-radius: var(--r-sm); text-decoration: none; border: 1px solid transparent }
.prose .wp-block-file__button:hover { filter: brightness(1.08); color: #08160f }

/* -- Pullquote -- */
.prose .wp-block-pullquote { border: 1px solid var(--border); border-left: 3px solid var(--green); background: var(--surface); border-radius: var(--r); padding: 24px; margin: 1.6em 0 }
.prose .wp-block-pullquote blockquote { margin: 0; padding: 0; border: none; color: var(--text); font-style: normal; font-size: 18px; line-height: 1.6 }
.prose .wp-block-pullquote cite { display: block; margin-top: 12px; font-size: 12px; font-style: normal; color: var(--mid); font-family: var(--font-mono) }

/* -- Columns -- */
.prose .wp-block-columns { display: flex; gap: 24px; margin: 1.6em 0 }
.prose .wp-block-column { flex: 1; min-width: 0 }
@media (max-width: 781px) { .prose .wp-block-columns:not(.is-not-stacked-on-mobile) { flex-direction: column; gap: 16px } }

/* -- Media + text -- */
.prose .wp-block-media-text { display: grid; grid-template-columns: 50% 1fr; gap: 24px; margin: 1.6em 0; align-items: center }
.prose .wp-block-media-text.has-media-on-the-right { grid-template-columns: 1fr 50% }
.prose .wp-block-media-text__media { margin: 0 }
.prose .wp-block-media-text__media img, .prose .wp-block-media-text__media video { width: 100%; height: auto; display: block; border: 1px solid var(--border); border-radius: var(--r) }
@media (max-width: 781px) { .prose .wp-block-media-text, .prose .wp-block-media-text.has-media-on-the-right { grid-template-columns: 1fr } }

/* -- Buttons -- */
.prose .wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.6em 0 }
.prose .wp-block-button__link { display: inline-flex; align-items: center; background: var(--green); color: #08160f; font-family: var(--font-mono); font-size: 13px; font-weight: 700; padding: 12px 22px; border-radius: var(--r-sm); text-decoration: none; border: 1px solid transparent; transition: filter .15s }
.prose .wp-block-button.is-style-outline .wp-block-button__link { background: transparent; color: var(--green); border-color: var(--green) }
.prose .wp-block-button__link:hover { filter: brightness(1.08) }
.prose .wp-block-button.is-style-outline .wp-block-button__link:hover { background: rgba(0,255,145,.08) }

/* -- Group -- */
.prose .wp-block-group { margin: 1.6em 0 }
.prose .wp-block-group.has-background { padding: 20px; border-radius: var(--r) }

/* -- Details / summary -- */
.prose .wp-block-details { margin: 1.6em 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r) }
.prose .wp-block-details summary { cursor: pointer; user-select: none; font-family: var(--font-mono); font-size: 13px; font-weight: 600; color: var(--green); padding: 14px 20px; list-style: none }
.prose .wp-block-details summary::-webkit-details-marker { display: none }
.prose .wp-block-details summary::before { content: '>_ ' }
.prose .wp-block-details[open] summary { border-bottom: 1px solid var(--border) }
.prose .wp-block-details > :not(summary) { margin: 14px 20px }

/* -- Preformatted -- */
.prose .wp-block-preformatted { background: #08090b; border: 1px solid var(--border); border-radius: var(--r); padding: 20px; overflow-x: auto; font-family: var(--font-mono); font-size: 13px; line-height: 1.7; margin: 1.4em 0; color: #c9d1d9; white-space: pre-wrap }

/* -- Latest posts (widget block inside content) -- */
.prose .wp-block-latest-posts { list-style: none; padding: 0; margin: 1.4em 0 }
.prose .wp-block-latest-posts li { margin-bottom: 10px }
.prose .wp-block-latest-posts a { color: var(--text); text-decoration: none }
.prose .wp-block-latest-posts a:hover { color: var(--green) }
.prose .wp-block-latest-posts__post-date { display: block; font-size: 12px; color: var(--dim2); font-family: var(--font-mono) }

/* ==========================================================================
   GUTENBERG BLOCK STYLES — widget/utility blocks (v1.6.2)
   ========================================================================== */

/* -- Search block -- */
.prose .wp-block-search { margin: 1.6em 0 }
.prose .wp-block-search__label { display: block; font-family: var(--font-mono); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--mid); margin-bottom: 8px }
.prose .wp-block-search__inside-wrapper { display: flex; gap: 8px }
.prose .wp-block-search__input { flex: 1; min-width: 0; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-sm); color: var(--text); padding: 10px 14px; font-size: 14px; font-family: inherit }
.prose .wp-block-search__input:focus { outline: none; border-color: var(--green) }
.prose .wp-block-search__button { background: var(--green); color: #08160f; border: none; font-family: var(--font-mono); font-weight: 700; font-size: 13px; padding: 10px 18px; border-radius: var(--r-sm); cursor: pointer }
.prose .wp-block-search__button:hover { filter: brightness(1.08) }

/* -- Categories / archives / RSS lists -- */
.prose .wp-block-categories, .prose .wp-block-archives, .prose .wp-block-rss { list-style: none; padding: 0; margin: 1.4em 0 }
.prose .wp-block-categories li, .prose .wp-block-archives li, .prose .wp-block-rss li { margin-bottom: 8px }
.prose .wp-block-categories a, .prose .wp-block-archives a, .prose .wp-block-rss a { color: var(--text); text-decoration: none }
.prose .wp-block-categories a:hover, .prose .wp-block-archives a:hover, .prose .wp-block-rss a:hover { color: var(--green) }
.prose .wp-block-categories .wp-block-categories__list { margin-top: 8px; padding-left: 16px; border-left: 1px solid var(--border) }
.prose .wp-block-categories .wp-block-categories__list li { margin-bottom: 6px }
.prose .wp-block-categories-list .current-cat > a { color: var(--green) }

/* -- Tag cloud -- */
.prose .wp-block-tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; margin: 1.4em 0 }
.prose .wp-block-tag-cloud a { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: var(--r-pill); border: 1px solid var(--border); font-family: var(--font-mono); font-size: 12px !important; color: var(--mid); text-decoration: none; transition: border-color .15s, color .15s }
.prose .wp-block-tag-cloud a:hover { border-color: var(--green); color: var(--green) }

/* -- Social links -- */
.prose .wp-block-social-links { display: flex; flex-wrap: wrap; gap: 10px; padding: 0; margin: 1.4em 0; list-style: none }
.prose .wp-block-social-links .wp-social-link { display: inline-flex }
.prose .wp-block-social-links .wp-social-link a { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--border); transition: border-color .15s, transform .15s }
.prose .wp-block-social-links .wp-social-link a:hover { border-color: var(--green); transform: translateY(-2px) }
.prose .wp-block-social-links .wp-social-link svg { fill: var(--text); width: 20px; height: 20px }

/* -- Latest comments -- */
.prose .wp-block-latest-comments { list-style: none; padding: 0; margin: 1.4em 0 }
.prose .wp-block-latest-comments li { margin-bottom: 14px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r) }
.prose .wp-block-latest-comments__comment-author, .prose .wp-block-latest-comments__comment-link { color: var(--green); text-decoration: none; font-weight: 600 }
.prose .wp-block-latest-comments__comment-meta { font-size: 12px; color: var(--dim2); font-family: var(--font-mono); margin-bottom: 6px }
.prose .wp-block-latest-comments__comment-excerpt p { font-size: 14px; color: var(--mid); margin: 0 }

/* -- Verse -- */
.prose .wp-block-verse { background: #08090b; border: 1px solid var(--border); border-left: 3px solid var(--green); border-radius: var(--r); padding: 20px; font-family: var(--font-mono); font-size: 14px; line-height: 1.9; color: #c9d1d9; margin: 1.4em 0; white-space: pre-wrap }

/* -- Footnotes -- */
.prose .wp-block-footnotes { margin: 2em 0 0; padding-top: 1.4em; border-top: 1px solid var(--border); font-size: 13px; color: var(--mid) }
.prose .wp-block-footnotes li { margin-bottom: 6px }
.prose .wp-block-footnotes a { color: var(--mid); text-decoration: none }
.prose .wp-block-footnotes a:hover { color: var(--green) }
.prose sup a { color: var(--green); text-decoration: none }

/* -- Calendar -- */
.prose .wp-block-calendar { margin: 1.4em 0; font-size: 13px }
.prose .wp-block-calendar table { margin: 0 }
.prose .wp-block-calendar caption { font-family: var(--font-mono); color: var(--mid); padding-bottom: 10px; caption-side: top }
.prose .wp-block-calendar a { color: var(--green); text-decoration: none; font-weight: 700 }
.prose .wp-block-calendar td, .prose .wp-block-calendar th { text-align: center; padding: 8px 6px }
.prose .wp-block-calendar tbody td { background: var(--surface) }

/* -- Accordion (WP 7 block) — behavior theme-owned since v1.7.3 (no WP
      interactivity runtime; main.js drives open/close/autoclose) -- */
.prose .wp-block-accordion { margin: 1.6em 0 }
.prose .wp-block-accordion-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); margin-bottom: 10px; overflow: hidden }
.prose .wp-block-accordion-heading { margin: 0 }
.prose .wp-block-accordion-heading__toggle { cursor: pointer; width: 100%; text-align: left; background: none; border: none; font-family: var(--font-mono); font-size: 13px; font-weight: 600; color: var(--green); padding: 14px 20px }
.prose .wp-block-accordion-heading__toggle::before { content: '>_ ' }
.prose .wp-block-accordion-panel { border-top: 1px solid var(--border); padding: 14px 20px; display: none }
.prose .wp-block-accordion-item.is-open .wp-block-accordion-panel { display: block }
.prose .wp-block-accordion-panel > :first-child { margin-top: 0 }
.prose .wp-block-accordion-panel > :last-child { margin-bottom: 0 }

/* -- Widget group / page break / math -- */
.prose .wp-block-widget-group { margin: 1.4em 0 }
.prose .wp-block-nextpage { display: block; text-align: center; margin: 2em 0; color: var(--dim2); font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .1em }
.prose .wp-block-math { font-family: var(--font-mono); font-size: 14px }

/* ==========================================================================
   GUTENBERG UTILITY CLASSES (v1.7.1) — these lived in the wp-block-library
   stylesheet we removed; without them blocks render visibly broken:
   screen-reader labels show as text, centered/large text is inert.
   ========================================================================== */

/* Visually hidden but accessible — the standard sr-only pattern. Social
   link labels (GitHub/X/LinkedIn), search labels etc. depend on it. */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); border: 0; white-space: nowrap; word-wrap: normal }

/* Text alignment utilities */
.has-text-align-left { text-align: left }
.has-text-align-center { text-align: center }
.has-text-align-right { text-align: right }

/* Font-size utilities (prose body is 17px) */
.has-small-font-size { font-size: 13px }
.has-medium-font-size { font-size: 16px }
.has-large-font-size { font-size: 20px }
.has-x-large-font-size { font-size: 24px }
.has-xx-large-font-size { font-size: 32px }

/* Palette utilities — theme.json slugs (green/bg/surface/surface-2/text/muted).
   !important matches how core generates these. */
.has-green-color { color: #00ff91 !important }
.has-bg-color { color: #0d0d0d !important }
.has-surface-color { color: #111318 !important }
.has-surface-2-color { color: #181c24 !important }
.has-text-color { color: #e2e8f0 !important }
.has-muted-color { color: #8896aa !important }
.has-green-background-color { background-color: #00ff91 !important }
.has-bg-background-color { background-color: #0d0d0d !important }
.has-surface-background-color { background-color: #111318 !important }
.has-surface-2-background-color { background-color: #181c24 !important }
.has-text-background-color { background-color: #e2e8f0 !important }
.has-muted-background-color { background-color: #8896aa !important }

/* Align-wide — expand figures/covers beyond the 68ch prose column */
.prose .alignwide { margin-left: -64px; margin-right: -64px; max-width: calc(100% + 128px) }
@media (max-width: 767px) { .prose .alignwide { margin-left: -16px; margin-right: -16px; max-width: calc(100% + 32px) } }

/* Inline code in paragraphs */
/* handled by .prose code:not(pre code) above */

/* ==========================================================================
   LAYOUT UTILITIES
   ========================================================================== */
.wrap { max-width: var(--content-w); margin: 0 auto; padding: 0 var(--sp-8); position: relative; z-index: 2 }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-6) var(--sp-6); min-width: 0 }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-6) var(--sp-5); min-width: 0 }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-6) var(--sp-5); min-width: 0 }
.flex { display: flex }
.flex-col { display: flex; flex-direction: column }
.items-center { align-items: center }
.justify-between { justify-content: space-between }
.section { padding: var(--sp-20) 0 }
.section-sm { padding: var(--sp-12) 0 }

@media (max-width: 1023px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr) }
  .wrap { padding: 0 var(--sp-5) }
}
@media (max-width: 767px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr }
  .wrap { padding: 0 var(--sp-4) }
  .section { padding: var(--sp-16) 0 }
  .section-sm { padding: var(--sp-8) 0 }
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */
.btn { font-family: var(--font-mono); font-size: 13px; font-weight: 700; padding: 12px 22px; border-radius: var(--r-sm); display: inline-flex; align-items: center; gap: 8px; border: 1px solid transparent; transition: transform .12s, background .15s, border-color .15s; text-decoration: none }
.btn:active { transform: scale(.97) }
body .btn-primary { background: var(--green); color: #08160f; text-decoration: none }
body .btn-primary:hover { background: var(--green-hover); text-decoration: none }
body .btn-secondary { background: transparent; border-color: var(--green); color: var(--green); text-decoration: none }
body .btn-secondary:hover { background: var(--green-dim); text-decoration: none }
body .btn-ghost { background: transparent; color: var(--mid); border-color: var(--border); text-decoration: none }
body .btn-ghost:hover { color: var(--text); border-color: var(--border-2); text-decoration: none }
.btn-sm { padding: 8px 16px; font-size: 12px }

/* ==========================================================================
   CARDS
   ========================================================================== */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; transition: border-color .2s, transform .2s; display: flex; flex-direction: column; width: 100%; min-width: 0; position: relative }
@media (hover: hover) { .card:hover { border-color: var(--green-border); transform: translateY(-3px) } }
@media (hover: none) { .card:hover { transform: none } }
.card-link { display: block; text-decoration: none; color: inherit }
.card-link:hover { color: inherit }
.card h3 a::after { content: ''; position: absolute; inset: 0; z-index: 1 }
.card h3 a:focus-visible::after { outline: 2px solid var(--green); outline-offset: -4px; border-radius: var(--r) }
.card-media { aspect-ratio: 16/9; display: flex; align-items: center; justify-content: center; font-size: 38px; overflow: hidden; position: relative }
.card-media.cat-android { background: linear-gradient(160deg, #0a1f22, var(--surface) 75%) }
.card-media.cat-webdev { background: linear-gradient(160deg, #0f1730, var(--surface) 75%) }
.card-media.cat-software { background: linear-gradient(160deg, #001a2a, var(--surface) 75%) }
.card-media-relative { position: relative }
.card-body { padding: var(--sp-5); min-width: 0; overflow-wrap: break-word }
.card h3 { font-size: 16px; font-weight: 700; line-height: 1.4; margin: 10px 0; overflow-wrap: break-word }
body .card h3 a:hover { color: var(--green) }
.card-meta { font-size: 11px; color: var(--mid); display: flex; gap: 10px; align-items: center; margin-bottom: 4px }
.card-excerpt { font-size: 13px; color: var(--mid); line-height: 1.65; margin-bottom: 16px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden }
.card-lead { display: grid; grid-template-columns: 1.1fr 1fr; margin-bottom: var(--sp-6) }
.card-lead .card-media { aspect-ratio: auto; height: 100% }
.card-lead .card-body { padding: var(--sp-8); display: flex; flex-direction: column; justify-content: center }
.card-lead h3 { font-size: 24px }
.resource-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: var(--sp-5); transition: border-color .2s; display: flex; flex-direction: column }
.resource-card:hover { border-color: var(--border-2) }
.resource-card .flex { justify-content: space-between; align-items: flex-start; gap: 10px }
.resource-card .body-sm { flex: 1 }
/* Categories index (/category/) — category cards */
.category-card .cat-head { display: flex; align-items: center; gap: 10px }
.category-card .cat-head h3 a:hover { color: var(--green) }
.category-card[data-cat="android"] { border-color: var(--cat-android-border) }
.category-card[data-cat="webdev"] { border-color: var(--cat-webdev-border) }
.category-card[data-cat="software"] { border-color: var(--cat-software-border) }
.cat-child-chip { font-size: 11px; font-weight: 600; color: var(--mid); border: 1px solid var(--border); border-radius: 999px; padding: 4px 10px; text-decoration: none; transition: color .15s, border-color .15s }
.cat-child-chip:hover { color: var(--green); border-color: var(--green-border) }

/* Resource section headers with colored dot */
.resources-section-header { font-size: 22px; font-weight: 800 }
.dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0 }
.dot-android { background: var(--cat-android); box-shadow: 0 0 8px var(--cat-android) }
.dot-webdev { background: var(--cat-webdev); box-shadow: 0 0 8px var(--cat-webdev) }
.dot-software { background: var(--cat-software); box-shadow: 0 0 8px var(--cat-software) }

@media (max-width: 767px) {
  .card-lead { grid-template-columns: 1fr }
  .card-lead .card-media { aspect-ratio: 16/9 }
  .card-lead h3 { font-size: 19px }
  .resources-section-header { font-size: 19px }
}

/* ==========================================================================
   BADGES & PILLS
   ========================================================================== */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: var(--r-sm); font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border: 1px solid transparent; position: relative; z-index: 2 }
.badge a { color: inherit }
.badge-android { background: var(--cat-android-dim); border-color: var(--cat-android-border); color: var(--cat-android) }
.badge-webdev { background: var(--cat-webdev-dim); border-color: var(--cat-webdev-border); color: var(--cat-webdev) }
.badge-software { background: var(--cat-software-dim); border-color: var(--cat-software-border); color: var(--cat-software) }
.badge-featured { position: absolute; top: 10px; left: 10px; background: rgba(0, 255, 145, .16); border: 1px solid var(--green); color: var(--green); z-index: 2 }
.badge-tag { background: var(--green-dim) !important; border-color: var(--green-border) !important; color: var(--green) !important }
.filter-pills { gap: 8px; flex-wrap: wrap; display: flex; align-items: center }

/* Pill filter buttons */
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; border-radius: var(--r-pill); border: 1px solid var(--border); font-size: 13px; font-weight: 600; color: var(--mid); background: var(--surface); transition: all .2s; cursor: pointer; white-space: nowrap; font-family: var(--font-mono) }
.pill:hover { border-color: var(--border-2); color: var(--text); background: var(--surface-2) }
.pill.on { background: var(--green-dim); border-color: var(--green-border); color: var(--green); box-shadow: 0 0 12px var(--green-glow); cursor: default }

/* Category-colored dots for filter pills */
.pill[data-filter="android"]::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cat-android); flex-shrink: 0 }
.pill[data-filter="webdev"]::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cat-webdev); flex-shrink: 0 }
.pill[data-filter="software"]::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cat-software); flex-shrink: 0 }
.pill.on::before { box-shadow: 0 0 6px currentColor }

/* Scrollable on mobile */
@media (max-width: 767px) {
  .filter-pills { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 8px; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch }
  .filter-pills::-webkit-scrollbar { display: none }
  .pill { scroll-snap-align: start; flex-shrink: 0 }
}

/* ==========================================================================
   FORM INPUTS
   ========================================================================== */
.input { width: 100%; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 12px 14px; font-size: 14px; color: var(--text); transition: border-color .15s, box-shadow .15s }
.input::placeholder { color: var(--dim2) }
.input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-glow) }
.newsletter-row { display: flex; gap: 10px }
.newsletter-row .input { flex: 1 }
@media (max-width: 640px) { .newsletter-row { flex-direction: column } }

/* ==========================================================================
   HEADER — Brand Spec: .prompt (green glow), .gap, .name, .cursor
   ========================================================================== */
.site-header { position: sticky; top: 0; z-index: var(--z-sticky); background: var(--bg); border-bottom: 1px solid var(--border) }
.header-row { display: flex; align-items: center; height: 48px; padding: 0 var(--sp-8); max-width: var(--content-w); margin: 0 auto; border-bottom: 1px solid var(--border) }
.header-row-2 { display: flex; align-items: center; height: 44px; padding: 0 var(--sp-8); max-width: var(--content-w); margin: 0 auto; background: var(--surface) }
.header-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; position: relative }

/* Logo — Brand Spec */
.logo { display: flex; align-items: center; font-family: var(--font-mono); font-weight: 800; font-size: 17px; text-decoration: none }
.logo .prompt { color: var(--green); text-shadow: 0 0 12px rgba(0, 255, 145, 0.5), 0 0 32px rgba(0, 255, 145, 0.2); transition: text-shadow 0.15s }
.logo:hover .prompt { text-shadow: 0 0 16px rgba(0, 255, 145, 0.7), 0 0 40px rgba(0, 255, 145, 0.3) }
.logo .gap { display: inline-block; width: 0.4em; }
.logo .name { color: var(--text); letter-spacing: -0.02em; }
.logo .cursor { display: inline-block; width: 0.55em; height: 1em; background: var(--green); margin-left: 3px; vertical-align: middle; position: relative; top: -0.05em; box-shadow: 0 0 10px rgba(0, 255, 145, 0.7); animation: blink 1.1s step-end infinite; }
@keyframes blink { 0%, 100% { opacity: 1 } 50% { opacity: 0 } }
.logo-sm { font-size: 14px }
.logo-sm .cursor { width: 0.45em; height: 0.85em; }

.site-nav { display: flex; gap: 30px }
.site-nav-list { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0 }
.site-nav-list > li { position: relative }
.site-nav a, .site-nav-list a { font-size: 13px; font-weight: 500; color: var(--mid); transition: color .15s; text-decoration: none; display: inline-flex; align-items: center; gap: 4px }
.site-nav a:hover, .site-nav a.active, .site-nav-list a:hover, .site-nav-list a.active { color: var(--green) }
/* Desktop dropdowns — hover to open (no click needed, pointer-only) */
.site-nav-list .sub-menu { display: none; position: absolute; top: 100%; left: -12px; min-width: 200px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 6px; list-style: none; margin: 0; z-index: 100; box-shadow: 0 12px 32px rgba(0, 0, 0, .45) }
.site-nav-list > li:hover > .sub-menu, .site-nav-list > li:focus-within > .sub-menu { display: block }
.site-nav-list .sub-menu a { display: flex; width: 100%; padding: 8px 12px; font-size: 12px; border-radius: var(--r-sm); color: var(--mid) }
.site-nav-list .sub-menu a:hover { background: var(--surface-2); color: var(--green) }
.site-nav-list .sub-menu--nested { left: 100%; top: 0 }
.site-nav-list .nav-caret { opacity: .6; transition: transform .15s }
.site-nav-list > li:hover > a .nav-caret { transform: rotate(180deg) }
/* Mobile accordion (inside .mno overlay) */
.mno-list { list-style: none; margin: 0; padding: 0 }
.mno-list > li > a, .mno-list .sub-menu a, .mno-items > .nav-link { display: flex; align-items: center; padding: var(--sp-4) var(--sp-5); font-size: 15px; font-weight: 600; color: var(--text); border-radius: var(--r-sm); transition: background .15s, color .15s; text-decoration: none }
.mno-list > li > a:hover, .mno-list .sub-menu a:hover, .mno-items > .nav-link:hover { background: var(--surface); color: var(--green) }
.mno-list > li > a.active, .mno-list .sub-menu a.active, .mno-items > .nav-link.active { color: var(--green); background: var(--green-dim) }
.mno-list .sub-menu { display: none; list-style: none; margin: 2px 0 8px var(--sp-5); padding: var(--sp-2) 0 var(--sp-2) var(--sp-4); border-left: 2px solid var(--green-border); position: relative; background: rgba(17,19,24,.5); border-radius: 0 var(--r-sm) var(--r-sm) 0 }
.mno-list li.open > .sub-menu { display: block }
.mno-list .sub-menu a { font-size: 14px; font-weight: 500; padding: var(--sp-2) var(--sp-4); color: var(--mid); border-radius: var(--r-sm) }
.mno-list .sub-menu a:hover { background: var(--surface); color: var(--green) }
.mno-list .sub-menu a.active { color: var(--green); background: var(--green-dim) }
.mno-list .sub-menu .sub-menu { margin-left: 0 }
/* Split-tap affordance: the .mno-caret is a distinct 30px square CHIP on the
   right of the row. Tap IT to expand/collapse the sub-menu; tap the category
   TEXT (left) to navigate. The square chip STAYS FIXED when opened — only the
   inner .nav-caret chevron rotates 180° to indicate open/close. */
.mno-list li.has-submenu > a { position: relative; padding-right: var(--sp-12) }
.mno-list .mno-caret {
  position: absolute; right: var(--sp-5); top: 50%;
  transform: translateY(-50%);
  width: 30px; height: 30px;            /* square chip; stays put */
  display: flex; align-items: center; justify-content: center;
  margin-left: auto;
  border: 1px solid var(--green-border); /* visible square */
  border-radius: var(--r-sm);
  background: var(--surface);
  color: var(--green); opacity: .9;
  transition: border-color .15s, background .15s;
  z-index: 3;                          /* above the anchor text */
  pointer-events: auto;                /* clickable! */
}
/* the inner chevron svg — THIS rotates, the square does not */
.mno-list .mno-caret .nav-caret {
  width: 12px; height: 12px;
  transition: transform .15s;
  flex-shrink: 0;
}
.mno-list li.open > a .mno-caret .nav-caret { transform: rotate(180deg) }
.mno-list li.has-submenu > a:hover .mno-caret,
.mno-list li.has-submenu > a .mno-caret:hover { border-color: var(--green-border); background: var(--green-dim) }
/* when a parent is open, give its row breathing room below (bottom padding) */
.mno-list li.open > a { margin-bottom: var(--sp-2) }
.icon-btn { width: 36px; height: 36px; border-radius: var(--r-sm); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--mid); background: transparent; transition: all .15s }
.icon-btn:hover { border-color: var(--green-border); color: var(--green) }
.icon-btn svg { width: 16px; height: 16px }
.hamburger { display: none; width: 36px; height: 36px; border-radius: var(--r-sm); border: 1px solid var(--border); background: transparent; align-items: center; justify-content: center; flex-direction: column; gap: 4px }
.hamburger span { display: block; width: 16px; height: 2px; background: var(--text) }
@media (max-width: 1023px) {
  .header-row { height: 56px; border-bottom: none }
  .header-row-2, .site-nav { display: none }
  .hamburger { display: flex }
  .logo { font-size: 15px }
}
/* Tablet: 768–1023px — show full nav, keep desktop layout */
@media (min-width: 768px) and (max-width: 1023px) {
  .header-row { height: 48px; border-bottom: 1px solid var(--border) }
  .header-row-2, .site-nav { display: flex }
  .site-nav { gap: 24px }
  .site-nav a { font-size: 12px }
  .hamburger { display: none }
}

/* ==========================================================================
   SEARCH DROPDOWN
   ========================================================================== */
.search-dropdown { position: fixed; top: 72px; left: 50%; transform: translateX(-50%); z-index: 10000; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; box-shadow: 0 20px 40px rgba(0, 0, 0, .4); width: min(480px, calc(100% - 32px)) }
.search-dropdown[hidden] { display: none }
.search-dropdown-inner { padding: var(--sp-5) }
#search-results { max-height: 300px; overflow-y: auto }
.search-dropdown-form { display: flex; gap: 8px; margin-bottom: var(--sp-4) }
.search-dropdown-icon { width: 18px; height: 18px; flex-shrink: 0; color: var(--mid); margin-top: 4px }
.search-dropdown-input { flex: 1; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 10px 12px; font-size: 14px; color: var(--text); outline: none }
.search-dropdown-input:focus { border-color: var(--green); box-shadow: 0 0 0 3px var(--green-glow) }
.search-dropdown-close { width: 36px; height: 36px; border-radius: var(--r-sm); border: 1px solid var(--border); background: transparent; display: flex; align-items: center; justify-content: center; color: var(--mid); flex-shrink: 0 }
.search-dropdown-close:hover { border-color: var(--green-border); color: var(--green) }
#search-results { max-height: 300px; overflow-y: auto }
.search-results.has-results { border-top: 1px solid var(--border); padding-top: var(--sp-4) }
.search-result-item { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); text-decoration: none; color: inherit }
.search-result-item:last-child { border-bottom: none }
.search-result-item.highlighted { background: var(--green-dim) }
.search-result-badge { flex-shrink: 0 }
.search-result-content { flex: 1; min-width: 0 }
.sr-title { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
.sr-meta { font-size: 12px; color: var(--mid); margin-top: 2px }
.search-loading, .search-empty { padding: var(--sp-6); text-align: center; color: var(--mid); font-size: 13px }
.search-dropdown-footer { padding-top: var(--sp-4); border-top: 1px solid var(--border); font-size: 11px; color: var(--dim2); text-align: center; font-family: var(--font-mono) }
.search-dropdown-footer kbd { background: var(--surface-2); padding: 2px 6px; border-radius: 3px; font-family: var(--font-mono); font-size: 10px; margin: 0 4px }

/* ==========================================================================
   COOKIE BAR
   ========================================================================== */
#cookie {
  position: fixed; bottom: 16px; left: 50%; right: auto;
  z-index: 400; background: var(--surface);
  border: 1px solid var(--border-2); border-radius: var(--r-lg);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
  width: min(720px, calc(100vw - 32px));
  padding: var(--sp-4) var(--sp-5);
  display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
  /* v1.15.5: opacity/visibility guard — the widget is FULLY invisible
     until .show adds it, so no flash can appear before the popup
     (transform-only hiding could glitch visible for a frame on slow
     loads / late style application). */
  opacity: 0; visibility: hidden;
  transform: translateX(-50%) translateY(calc(100% + 24px));
  transition: transform .3s var(--ease-out), opacity .3s var(--ease-out), visibility .3s var(--ease-out);
}
#cookie.show {
  opacity: 1; visibility: visible;
  transform: translateX(-50%) translateY(0);
}
#cookie p { font-size: 13px; color: var(--mid); max-width: 60ch; flex: 1 1 auto; min-width: 0; margin: 0 }
#cookie .cookie-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0 }
/* Card language shared by ALL breakpoints (v1.15.4) — same border/radius/
   shadow/button hierarchy as the mobile card: floating centered card on
   PC + tablet, stacked card on phones. */
#cookie .btn { min-height: 40px; justify-content: center }
#cookie .btn[data-gwill-cookie-accept] { background: var(--green); border-color: var(--green); color: #08160f }
#cookie .btn[data-gwill-cookie-accept]:hover { background: var(--green-hover) }
#cookie .btn[data-gwill-cookie-decline] { border-color: var(--border-2); color: var(--mid) }
#cookie .btn:focus-visible { outline: 2px solid var(--green); outline-offset: 2px }
/* Tablet/mini-tab (641–767px): the bottom tab bar is visible, so the card
   floats ABOVE it; still roomy enough for the row layout. */
@media (max-width: 767px) and (min-width: 641px) {
  #cookie { bottom: calc(var(--btm-tab-h) + 12px) }
}
@media (max-width: 640px) {
  /* Mobile: stacked + centered card above the bottom tab bar (v1.15.2). */
  #cookie {
    left: 12px; right: 12px; width: auto;
    bottom: calc(var(--btm-tab-h) + 10px);
    padding: var(--sp-5);
    transform: translateX(0) translateY(calc(100% + 24px));
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    gap: var(--sp-4);
  }
  #cookie.show { transform: translateX(0) translateY(0) }
  #cookie p { max-width: 40ch; font-size: 13px; margin-bottom: 0 }
  #cookie .cookie-actions { width: 100%; max-width: 320px; gap: 10px }
  #cookie .btn { flex: 1 1 0; padding: 8px 12px; font-size: 13px }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer { background: var(--surface); border-top: 1px solid var(--border) }

/* Newsletter CTA */
.footer-cta { padding: var(--sp-24) 0; text-align: center; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border) }
.f-cta-title { margin-bottom: 8px }
.f-cta-desc { margin-bottom: 20px; max-width: 44ch; margin-left: auto; margin-right: auto }
.f-cta-form { max-width: 400px; margin: 0 auto }

/* Grid — Desktop: 4 columns */
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr; gap: var(--sp-12) var(--sp-12); padding: var(--sp-20) 0 }

/* Link columns */
.footer-col { min-width: 0; padding: 0 var(--sp-2) }
.footer-col h2 { font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--dim2); margin-bottom: 16px }
.footer-col a { display: block; font-size: 13px; color: var(--mid); padding: 8px 0 8px 4px; transition: color .15s, padding .15s; border-left: 2px solid transparent }
@media (hover: hover) {
  .footer-col a:hover { color: var(--green); border-left-color: var(--green); padding-left: 14px }
}

/* Brand column */
.footer-brand { padding: 0 var(--sp-4) }
.footer-brand p { font-size: 13px; color: var(--mid); margin-top: 12px; max-width: 40ch; line-height: 1.7 }
.footer-social { display: flex; gap: 12px; margin-top: 20px }
.footer-social .icon-btn { width: 40px; height: 40px; border-radius: var(--r); transition: all .2s }
.footer-social .icon-btn svg { width: 18px; height: 18px }
@media (hover: hover) {
  .footer-social .icon-btn:hover { background: var(--green-dim); border-color: var(--green-border); color: var(--green); transform: translateY(-2px) }
}

/* Bottom bar */
.footer-bottom { border-top: 1px solid var(--border); padding: 20px var(--sp-4); display: flex; justify-content: space-between; font-size: 12px; color: var(--dim2); flex-wrap: wrap; gap: 10px }
.footer-bottom a { color: var(--dim2); transition: color .15s }
@media (hover: hover) {
  .footer-bottom a:hover { color: var(--green) }
}

/* ── Small tablet / foldable: 600–767px ──────────────────────────────── */
@media (min-width: 600px) and (max-width: 767px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); gap: var(--sp-4) }
  .wrap { padding: 0 var(--sp-6) }
  .page-hero { padding: var(--sp-12) 0 var(--sp-8) }
  .section { padding: var(--sp-16) 0 }
  .section-sm { padding: var(--sp-10) 0 }
  .about-stats { grid-template-columns: repeat(4, 1fr) }
  .about-stat strong { font-size: 20px }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--sp-5); padding: var(--sp-6) var(--sp-6) var(--sp-10) }
  .footer-col { padding: var(--sp-4) var(--sp-5); margin-top: var(--sp-4) }
  .footer-cta { padding: var(--sp-12) var(--sp-4) }
  .footer-bottom { padding: 20px var(--sp-4) }
  .header-row { height: 56px; border-bottom: none }
  .header-row-2, .site-nav { display: none }
  .hamburger { display: flex }
  .logo { font-size: 14px }
}

/* ── Standard tablet portrait: 768–1023px ──────────────────────────────── */
@media (min-width: 768px) and (max-width: 1023px) {
  .wrap { padding: 0 var(--sp-6) }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; gap: var(--sp-6) var(--sp-8); padding: var(--sp-10) var(--sp-6) var(--sp-12) }
  .footer-brand { grid-column: 1 / -1; padding: 0 0 var(--sp-6); border-bottom: 1px solid var(--border); margin-bottom: var(--sp-6) }
  .footer-brand p { max-width: 50ch }
  .footer-col { padding-top: var(--sp-2) }
  .footer-col a { padding-left: 0 }
  .footer-col h4 { font-size: 11px }
  .footer-col a::after { content: "→"; margin-left: 4px; font-size: 10px; color: var(--dim2); font-family: var(--font-mono) }
  .footer-social .icon-btn { width: 32px; height: 32px }
  .footer-cta { padding: var(--sp-16) 0 }
  .footer-bottom { padding: 24px var(--sp-4) }
}

/* ── Mobile: ≤767px ──────────────────────────────────────────────────── */
@media (max-width: 767px) {
  .site-footer { padding-bottom: calc(var(--btm-tab-h) + 20px) }

  /* Newsletter CTA */
  .footer-cta { padding: var(--sp-12) var(--sp-4) }
  .f-cta-title { font-size: clamp(18px, 5vw, 22px) }

  /* Grid — single column with card-like sections */
  .footer-grid { grid-template-columns: 1fr; gap: 0; padding: var(--sp-4) var(--sp-4) var(--sp-8) }

  /* Brand section — top of footer grid */
  .footer-brand {
    padding: var(--sp-6) var(--sp-5);
    border-bottom: 1px solid var(--border);
    margin-bottom: 0;
  }
  .footer-brand p { max-width: 100%; font-size: 14px; margin-top: 14px; line-height: 1.7 }
  .footer-brand .logo { margin-bottom: 4px }

  /* Link columns — card-like blocks */
  .footer-col {
    padding: var(--sp-4) var(--sp-5);
    border: 1px solid var(--border);
    margin-top: var(--sp-4);
    background: var(--surface-2);
    border-radius: var(--r);
  }
  .footer-col h4 {
    margin: 0 0 var(--sp-2);
    padding: 0;
    font-size: 11px;
    color: var(--green);
    font-family: var(--font-mono);
    background: none;
    border-bottom: none;
  }
  .footer-col a {
    padding: 14px 0;
    font-size: 14px;
    border-left: none;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .footer-col a:last-child { border-bottom: none }
  .footer-col a::after {
    content: "→";
    color: var(--dim2);
    font-family: var(--font-mono);
    font-size: 12px;
    transition: color .15s;
  }
  @media (hover: hover) {
    .footer-col a:hover::after { color: var(--green) }
    .footer-col a:hover {
      color: var(--green);
      border-left: none;
      padding-left: var(--sp-5);
      background: var(--green-dim);
    }
  }

  /* Social icons */
  .footer-social { gap: 16px; margin-top: 24px }

  /* Bottom bar */
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 20px var(--sp-4) }
  .footer-bottom span { font-size: 12px }
  @media (hover: hover) {
    .footer-bottom a:hover { border-color: var(--green-border); color: var(--green) }
  }
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero { position: relative; padding: var(--sp-32) 0 var(--sp-24); overflow: hidden }
.hero::before { content: ""; position: absolute; top: -20%; right: -10%; width: 600px; height: 600px; background: radial-gradient(circle, var(--green-glow), transparent 65%); pointer-events: none }
.hero-inner { position: relative; z-index: 2; max-width: 760px }
.hero .h1 { margin-bottom: 22px }
.hero .h1 .accent { color: var(--green) }
.hero-sub { font-size: 18px; color: var(--mid); line-height: 1.7; max-width: 56ch; margin-bottom: 36px }
.hero-cta { display: flex; gap: 14px; margin-bottom: 56px; flex-wrap: wrap }
.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--border); padding-top: 32px }
.stat-strip .stat { border-right: 1px solid var(--border); padding-right: 24px }
.stat-strip .stat:last-child { border-right: none }
.stat-num { font-size: 26px; font-weight: 800 }
.stat-label { font-size: 11px; color: var(--dim); text-transform: uppercase; letter-spacing: .06em; margin-top: 6px }
@media (max-width: 767px) {
  .hero { padding: var(--sp-16) 0 var(--sp-12) }
  .hero::before { width: 340px; height: 340px; top: -15%; right: -20% }
  .hero-sub { font-size: 16px }
  .stat-strip { grid-template-columns: repeat(2, 1fr); row-gap: 20px }
  .stat-strip .stat:nth-child(2n) { border-right: none }
  .hero-cta { flex-direction: column }
  .hero-cta .btn { width: 100%; justify-content: center }
}

/* ==========================================================================
   HERO BOOT ANIMATION
   ========================================================================== */
.hero-boot { opacity: 0; transform: translateY(20px); transition: opacity .6s var(--ease-out), transform .6s var(--ease-out) }
.hero-boot.visible { opacity: 1; transform: translateY(0) }
.boot-terminal { font-family: var(--font-mono); font-size: 14px; color: var(--green); margin-bottom: var(--sp-6); min-height: 120px; line-height: 1.8 }
.boot-line { opacity: 0; transform: translateY(10px); transition: opacity .3s var(--ease-out), transform .3s var(--ease-out) }
.boot-line.visible { opacity: 1; transform: translateY(0) }
.boot-buttons { opacity: 0; transition: opacity .4s var(--ease-out) }
.boot-buttons.visible { opacity: 1 }
.hero-static { opacity: 0; transition: opacity .5s var(--ease-out) }
.hero-static[style*="block"] { opacity: 1 }

/* ==========================================================================
   FEATURED POST (replaces old hero)
   ========================================================================== */
.featured-section { padding: var(--sp-8) 0 var(--sp-6); position: relative }
.featured-card { display: grid; grid-template-columns: 1.5fr 1fr; gap: var(--sp-6); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; position: relative; transition: border-color .2s ease, box-shadow .2s ease }
.featured-card:hover { border-color: rgba(0, 255, 145, .35); box-shadow: 0 0 28px rgba(0, 255, 145, .07) }
.featured-link { display: block; text-decoration: none; color: inherit }
.featured-link:hover { color: inherit }
.featured-title a::after { content: ''; position: absolute; inset: 0; z-index: 1 }
.featured-title a:focus-visible::after { outline: 2px solid var(--green); outline-offset: -4px; border-radius: var(--r-lg) }
.featured-media { aspect-ratio: 16/9; display: flex; align-items: center; justify-content: center; font-size: 56px; overflow: hidden; min-height: 220px; position: relative }
.featured-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(13,13,13,0) 55%, rgba(13,13,13,.38)); pointer-events: none; z-index: 1 }
.featured-media .featured-img { width: 100%; height: 100%; object-fit: cover }
.featured-media .featured-emoji { font-size: 64px }
.featured-media .badge { z-index: 2 }
.card-img { width: 100%; height: 100%; object-fit: cover }
.featured-body { padding: var(--sp-6) var(--sp-6) var(--sp-6) 0; display: flex; flex-direction: column; justify-content: center }
.featured-body .badge { margin-bottom: 14px; align-self: flex-start }
.featured-title { font-size: clamp(20px, 2.4vw, 28px); font-weight: 800; line-height: 1.25; margin-bottom: 12px; letter-spacing: -.01em }
.featured-title a { color: var(--text) }
.featured-title a:hover { color: var(--green) }
.featured-excerpt { font-size: 15px; color: var(--mid); line-height: 1.65; margin-bottom: 16px }
.featured-meta { font-size: 12px; color: var(--mid); display: flex; gap: 10px; align-items: center; margin-bottom: 20px }
.featured-body .btn { align-self: flex-start }

@media (max-width: 1023px) {
  .featured-card { grid-template-columns: 1fr; gap: 0 }
  .featured-media { min-height: 200px }
  .featured-body { padding: var(--sp-6) }
}
@media (max-width: 767px) {
  .featured-section { padding: var(--sp-6) 0 var(--sp-4) }
  .featured-media { min-height: 170px; font-size: 44px }
  .featured-body { padding: var(--sp-5) }
  .featured-title { font-size: clamp(18px, 4.6vw, 22px) }
  .featured-excerpt { font-size: 14px }
}

/* ==========================================================================
   TOC (TABLE OF CONTENTS) — Terminal branded
   ========================================================================== */
.toc-dropdown { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden }
.toc-summary { cursor: pointer; display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; font-size: 12px; font-weight: 600; color: var(--green); user-select: none; font-family: var(--font-mono); background: var(--surface-2); border-bottom: 1px solid var(--border); transition: background .15s }
.toc-summary:hover { background: var(--green-dim) }
.toc-summary::after { content: '▼'; font-size: 8px; transition: transform .2s; margin-left: 8px; color: var(--dim) }
.toc-dropdown[open] .toc-summary::after { transform: rotate(180deg) }
.toc-list { padding: 8px 0; max-height: 360px; overflow-y: auto }
.toc-list a { display: block; font-size: 13px; color: var(--mid); padding: 8px 16px 8px 36px; transition: color .15s, background .15s, padding .15s; font-family: var(--font-mono); border-left: 2px solid transparent; position: relative }
.toc-list a::before { content: '>_'; color: var(--dim2); font-size: 10px; position: absolute; left: 10px; top: 8px; transition: color .15s }
.toc-list a:hover { color: var(--green); background: var(--green-dim); border-left-color: var(--green); padding-left: 42px }
.toc-list a:hover::before { color: var(--green) }
.toc-sidebar .toc-list { padding: 0; max-height: 400px }
.toc-sidebar .toc-list a { padding-left: 26px }
.toc-sidebar .toc-list a::before { left: 8px }

/* TOC heading spacing — gap after >_ prefix */
.sidebar-widget h3, .sidebar-widget h4 { word-spacing: 8px }
.toc-summary { word-spacing: 4px }
.hero-static { opacity: 0; transition: opacity .5s var(--ease-out) }
.hero-static[style*="block"] { opacity: 1 }

/* ==========================================================================
   PAGE HERO & BREADCRUMB
   ========================================================================== */
.page-hero { padding: var(--sp-16) 0 var(--sp-10); border-bottom: 1px solid var(--border) }
.page-hero .h1 { margin-bottom: 14px }
.page-hero p { font-size: 16px; color: var(--mid); max-width: 62ch }
.page-hero p a { color: var(--green); text-decoration: underline; text-underline-offset: 3px }
.page-hero p a:hover { color: var(--green-hover) }
.breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--dim2); margin-bottom: 20px; font-family: var(--font-mono) }
.breadcrumb a:hover { color: var(--green) }
.breadcrumb .breadcrumb-page { display: inline-flex; align-items: center; padding: 2px 8px; font-size: 11px; font-weight: 700; line-height: 1.6; color: var(--green); background: rgba(0,255,145,.08); border: 1px solid var(--green-border); border-radius: 999px; text-transform: uppercase; letter-spacing: .04em }

/* Blog stats row */
.blog-stats { display: flex; gap: 24px; margin-top: 20px }
.blog-stat { font-size: 13px; color: var(--mid); font-family: var(--font-mono) }
.blog-stat strong { color: var(--green); font-weight: 700 }
/* Author archive — socials centered on mobile */
.author-socials { flex-wrap: wrap }
@media (max-width: 767px) {
  .author-socials { justify-content: center }
}

/* TOC mobile — phone only (≤767px). PC + tablet use the sticky sidebar TOC. */
.toc-mobile { display: none; margin-bottom: var(--sp-6) }
@media (max-width: 767px) { .toc-mobile { display: block } }

/* TOC anchor jumps must clear the sticky header (v1.6.3) — otherwise the
   jumped-to H2 lands hidden behind it. Phone header = 56px single row;
   tablet/desktop = 92px two rows. scroll-padding-top on html covers every
   anchor jump; scroll-margin-top on headings is the per-element belt. */
html { scroll-padding-top: 68px }
.prose h2[id], .prose h3[id] { scroll-margin-top: 68px }
@media (min-width: 768px) {
  html { scroll-padding-top: 108px }
  .prose h2[id], .prose h3[id] { scroll-margin-top: 108px }
}

/* ==========================================================================
   READING PROGRESS BAR
   ========================================================================== */
.reading-progress { position: fixed; top: 0; left: 0; height: 3px; background: var(--green); z-index: 10000; width: 0; box-shadow: 0 0 8px var(--green-glow); pointer-events: none }

/* ==========================================================================
   ARTICLE LAYOUT (Single Post)
   ========================================================================== */
.article-layout { display: grid; grid-template-columns: 1fr var(--sidebar-w); gap: var(--sp-12); align-items: start; min-width: 0 }
.article-layout article, .article-layout > div { min-width: 0 }
.article-header { margin-bottom: var(--sp-6) }
.article-header .badge { margin-bottom: 16px }
.article-header h1 { font-size: clamp(26px, 4vw, 40px); font-weight: 800; line-height: 1.15; margin-bottom: 18px }
.article-meta { display: flex; align-items: center; gap: 14px; font-size: 13px; color: var(--mid) }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--surface-2); border: 1px solid var(--border); flex-shrink: 0; object-fit: cover }
.avatar--initial { display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: var(--green) }
.article-cover { aspect-ratio: 16/8; border-radius: var(--r); overflow: hidden; margin: var(--sp-6) 0 var(--sp-8); background: linear-gradient(160deg, #0a1f22, var(--surface) 75%); display: flex; align-items: center; justify-content: center; font-size: 52px; width: 100%; max-width: 100%; min-width: 0 }
.article-cover--placeholder { min-height: 200px }
.article-cover--placeholder.cat-android { background: linear-gradient(160deg, #0a1f22, var(--surface) 75%) }
.article-cover--placeholder.cat-webdev { background: linear-gradient(160deg, #0f1730, var(--surface) 75%) }
.article-cover--placeholder.cat-software { background: linear-gradient(160deg, #001a2a, var(--surface) 75%) }

/* "Updated" label — shown in article meta when a post was revised after publish */
.meta-updated { color: var(--green); font-family: var(--font-mono); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; margin-right: 3px }

/* Featured-image caption — terminal comment vibe, matches .prose figcaption (v1.4.7) */
.article-cover-caption { margin: -22px 0 var(--sp-8); font-family: var(--font-mono); font-size: 12px; color: var(--mid); text-align: center }
.article-cover-caption::before { content: '# '; color: var(--green) }
/* When a caption follows the cover, tighten the cover's bottom margin so the caption sits right under the image */
.article-cover:has(+ .article-cover-caption) { margin-bottom: 10px }

/* Video cover — YouTube embed fills the same hero slot as the image */
.article-cover--video { aspect-ratio: 16/9; padding: 0; background: var(--bg) }
.article-cover--video iframe { width: 100%; height: 100%; border: 0; display: block }

/* Media fallback — faint terminal logo SVG (no featured image) */
.media-fallback { width: 62%; max-width: 220px; height: auto }
.card-media .media-fallback { width: 70%; max-width: 200px }
.article-cover .media-fallback { width: 42%; max-width: 320px }
.media-fallback-cursor { animation: blink 1.1s step-end infinite }
.sidebar-widget { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: var(--sp-5); margin-bottom: var(--sp-5) }
.sidebar-widget h4 { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); margin-bottom: 16px; font-family: var(--font-mono) }
.sidebar-sticky { position: sticky; top: 100px }
.sidebar-author { display: flex; align-items: center; gap: 12px }
.sidebar-author .avatar { width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0; background: var(--surface-2); border: 1px solid var(--border) }
/* Hide sidebar TOC on mobile — toc-mobile handles it instead */
@media (max-width: 1023px) { .toc-sidebar { display: none } }
@media (max-width: 1023px) { .article-layout { grid-template-columns: 1fr } .sidebar-sticky { position: static } }
/* Sidebar is a tablet/desktop-only component — on phones the ad + widgets
   would dump into the single-column flow skin-to-skin below the article.
   Remove the whole sidebar on mobile; tablet re-enables it below. */
@media (max-width: 767px) { .sidebar-sticky { display: none } }
/* Tablet: keep sidebar visible */
@media (min-width: 768px) and (max-width: 1023px) {
  .article-layout { grid-template-columns: 1fr 280px; gap: var(--sp-8) }
  .sidebar-sticky { position: sticky; top: 100px }
  .toc-sidebar { display: block }
}

/* ==========================================================================
   SHARE ROW
   ========================================================================== */
.share-row { display: flex; gap: 10px; padding: var(--sp-6) 0; border-top: 1px solid var(--border); margin: var(--sp-8) 0; flex-wrap: wrap; align-items: center }
.share-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); font-family: var(--font-mono); white-space: nowrap }
.share-buttons { display: flex; gap: 8px; flex-wrap: wrap }
.share-row .btn { flex-shrink: 0 }
.share-row .btn svg { vertical-align: middle; margin-right: 4px; flex-shrink: 0 }

/* ==========================================================================
   AUTHOR BOX
   ========================================================================== */
.author-box {
  display: flex;
  gap: var(--sp-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: var(--sp-6);
  margin: var(--sp-8) 0;
  align-items: flex-start;
}
.author-box__avatar { flex-shrink: 0 }
.author-box__avatar img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; border: 1px solid var(--border) }
.author-box__info { flex: 1; min-width: 0 }
.author-box__label { font-size: 10px; text-transform: uppercase; letter-spacing: .09em; color: var(--dim2); font-family: var(--font-mono); margin-bottom: 4px }
.author-box__name { font-size: 18px; font-weight: 700; margin-bottom: 8px }
.author-box__bio { font-size: 14px; color: var(--mid); line-height: 1.7; margin-bottom: 12px }
.author-box__link { font-size: 13px; color: var(--green); font-weight: 600; font-family: var(--font-mono); display: inline-flex; align-items: center; gap: 6px }
.author-box__link:hover { color: var(--green-hover) }
.author-box__socials { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap }
.author-box__social-link { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: var(--r-sm); border: 1px solid var(--border); color: var(--mid); transition: border-color .15s, color .15s, background .15s }
.author-box__social-link:hover { border-color: var(--green-border); color: var(--green); background: var(--green-dim) }
.author-box__social-link svg { width: 16px; height: 16px }
@media (max-width: 767px) { .author-box { flex-direction: column; align-items: center; text-align: center } .author-box__socials { justify-content: center } }

/* ==========================================================================
   AUTHOR BIO
   ========================================================================== */
.author-bio { display: flex; gap: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: var(--sp-5); margin-bottom: var(--sp-8) }
.author-bio .avatar { width: 52px; height: 52px; font-size: 18px }

/* ==========================================================================
   POST NAVIGATION
   ========================================================================== */
.post-nav { display: flex; justify-content: space-between; padding: var(--sp-6) 0; margin-top: var(--sp-6); gap: var(--sp-4) }
.post-nav a { font-size: 13px; font-weight: 600; color: var(--mid); flex: 1; display: flex; flex-direction: column; gap: 6px; padding: var(--sp-4); border: 1px solid var(--border); border-radius: var(--r); transition: border-color .2s }
.post-nav a:hover { border-color: var(--border-2) }
.post-nav-next { text-align: right; align-items: flex-end }
.post-nav-prev { align-items: flex-start }
.post-nav-label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--dim2); font-family: var(--font-mono); transition: color .15s }
.post-nav a:hover .post-nav-label { color: var(--green); text-shadow: 0 0 8px rgba(0, 255, 145, 0.4) }
.post-nav-title { font-size: 14px; color: var(--text); line-height: 1.4; transition: color .15s }
.post-nav a:hover .post-nav-title { color: var(--green); text-shadow: 0 0 10px rgba(0, 255, 145, 0.5) }
.post-nav .badge { align-self: flex-start }
.post-nav-next .badge { align-self: flex-end }

/* ==========================================================================
   RELATED POSTS
   ========================================================================== */
.related-posts { padding: var(--sp-8) 0; border-top: 1px solid var(--border); margin-top: var(--sp-8) }
.related-posts__heading { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); margin-bottom: var(--sp-6); font-family: var(--font-mono) }
.related-posts__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-5) }
.related-posts__card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; transition: border-color .2s, transform .2s }
@media (hover: hover) { .related-posts__card:hover { border-color: var(--green-border); transform: translateY(-2px) } }
.related-posts__thumb { aspect-ratio: 16/9; overflow: hidden; background: linear-gradient(160deg, #0a1f22, var(--surface) 75%); display: flex; align-items: center; justify-content: center }
.related-posts__thumb img { width: 100%; height: 100%; object-fit: cover }
.related-posts__title { font-size: 14px; font-weight: 700; line-height: 1.4; padding: var(--sp-4); margin: 0 }
.related-posts__link { color: inherit; text-decoration: none; display: block }
.related-posts__link:hover .related-posts__title { color: var(--green) }
@media (max-width: 1023px) { .related-posts__grid { grid-template-columns: repeat(2, 1fr) } }
@media (max-width: 767px) { .related-posts__grid { grid-template-columns: 1fr } }

/* ==========================================================================
   COMMENTS
   ========================================================================== */
.comments-area { padding: var(--sp-8) 0; border-top: 1px solid var(--border); margin-top: var(--sp-8) }
.comments-title { font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); margin-bottom: var(--sp-6); font-family: var(--font-mono) }
.comment-list { list-style: none; margin-bottom: var(--sp-8) }
.comment-list .children { list-style: none; margin-left: var(--sp-8); border-left: 1px solid var(--border); padding-left: var(--sp-5) }
.comment { padding: var(--sp-5) 0; border-bottom: 1px solid var(--border) }
.comment:last-child { border-bottom: none }
.comment-body { display: flex; gap: 14px }
.comment-meta { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--mid); margin-bottom: 8px; flex-wrap: wrap }
.comment-meta .fn { font-weight: 600; color: var(--text); font-style: normal }
.comment-meta a { color: var(--mid) }
.comment-meta a:hover { color: var(--green) }
.comment-content { font-size: 15px; line-height: 1.7; color: var(--text) }
.comment-content p { margin-bottom: 10px }
.reply { font-size: 12px }
.reply a { color: var(--green); font-weight: 600 }
.reply a:hover { text-decoration: underline }
.comment-respond { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: var(--sp-6) }
.comment-reply-title { font-size: 14px; font-weight: 700; margin-bottom: var(--sp-5); font-family: var(--font-mono) }
.comment-reply-title small { font-weight: 400; margin-left: 8px; font-family: var(--font-body) }
.comment-reply-title small a { color: var(--green); font-size: 12px }
.comment-form { display: flex; flex-direction: column; gap: var(--sp-4) }
.comment-form textarea,
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"] { width: 100%; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 12px 14px; font-size: 14px; color: var(--text); transition: border-color .15s, box-shadow .15s }
.comment-form textarea:focus,
.comment-form input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-glow) }
.comment-form .form-submit { margin-top: var(--sp-2) }
.comment-form .form-submit input[type="submit"] { font-family: var(--font-mono); font-size: 13px; font-weight: 700; padding: 12px 22px; border-radius: var(--r-sm); border: none; background: var(--green); color: #08160f; cursor: pointer; transition: background .15s }
.comment-form .form-submit input[type="submit"]:hover { background: var(--green-hover) }
.comment-notes { font-size: 13px; color: var(--mid) }
.no-comments { text-align: center; padding: var(--sp-8); color: var(--mid); font-size: 14px }
.comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--mid) }
.comment-form-cookies-consent input[type="checkbox"] { accent-color: var(--green); width: 16px; height: 16px }

/* ==========================================================================
   CONTACT FORM (gwill-form)
   ========================================================================== */
.gwill-form { display: flex; flex-direction: column; gap: var(--sp-4) }
.gwill-form__field { display: flex; flex-direction: column; gap: 6px }
.gwill-form__field label { font-size: 13px; font-weight: 600; color: var(--text) }
.gwill-form__required { color: var(--green) }
.gwill-form__field input,
.gwill-form__field textarea,
.gwill-form__field select { width: 100%; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 12px 14px; font-size: 14px; color: var(--text); transition: border-color .15s, box-shadow .15s; font-family: var(--font-body) }
.gwill-form__field input:focus,
.gwill-form__field textarea:focus,
.gwill-form__field select:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-glow) }
.gwill-form__field textarea { resize: vertical; min-height: 120px }
.gwill-form__field select { cursor: pointer; appearance: auto }
.gwill-form__row--2col { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4) }
.gwill-form__actions { margin-top: var(--sp-2) }
.gwill-form__submit { font-family: var(--font-mono); font-size: 13px; font-weight: 700; padding: 12px 22px; border-radius: var(--r-sm); border: none; background: var(--green); color: #08160f; cursor: pointer; transition: background .15s; width: auto }
.gwill-form__submit:hover { background: var(--green-hover) }
.gwill-form__submit-loading { display: none }
.gwill-form__submit.is-sending .gwill-form__submit-text { display: none }
.gwill-form__submit.is-sending .gwill-form__submit-loading { display: inline }
.gwill-form__status { font-size: 14px; padding: 10px 14px; border-radius: var(--r-sm); display: none }
.gwill-form__status.is-visible { display: block }
.gwill-form__status.is-error { background: rgba(255,69,69,.1); border: 1px solid rgba(255,69,69,.3); color: #ff4545 }
.gwill-form__status.is-success { background: var(--green-dim); border: 1px solid var(--green-border); color: var(--green) }
.gwill-honey { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden }
.gwill-form--routed .gwill-form__field:first-child { margin-bottom: var(--sp-2) }

/* Contact page layout */
.contact-card p strong { color: var(--text); font-weight: 700 }
.contact-card ul a { color: var(--text); text-decoration: underline; text-decoration-color: var(--border); text-underline-offset: 3px }
.disclaimer-content p strong, .privacy-content p strong { color: var(--text); font-weight: 700 }

/* ═══════════════════════════════════════════════════════════
   LEGAL PAGES — card-grouped layout with sidebar ToC
   ═══════════════════════════════════════════════════════════ */
.legal-hero { padding-bottom: var(--sp-8) }
.legal-section-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--green);
  margin: 0 0 var(--sp-3);
  letter-spacing: -.01em;
}
.legal-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--green-dim);
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}
.legal-section-body {
  color: var(--mid);
  line-height: 1.85;
  font-size: 15px;
}
.legal-section-body a {
  color: var(--green);
  text-decoration: underline;
  text-decoration-color: var(--green-border);
  text-underline-offset: 3px;
  transition: color .15s;
}
.legal-section-body a:hover { color: var(--green-hover) }
/* Sidebar sticky ToC card */
.legal-sidebar { position: sticky; top: calc(70px + var(--sp-8)) }
.legal-card {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: var(--sp-5);
}
.legal-toc-heading {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--dim);
  margin: 0 0 12px;
}
.legal-toc {
  list-style: none;
  padding: 0;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 2;
}
.legal-toc li a {
  color: var(--mid);
  text-decoration: none;
  display: block;
  padding: 4px 0;
  transition: color .15s, padding-left .15s;
}
.legal-toc-num { color: var(--green); margin-right: 6px }
.legal-sidebar .legal-card a:hover {
  color: var(--green) !important;
  padding-left: 6px;
}
/* Content section cards (shared by privacy + disclaimer) */
.section-card,
.legal-group {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: var(--sp-6);
}
.section-card { margin-bottom: var(--sp-6) }
.section-card + .section-card { margin-top: 0 }
.legal-group .legal-section + .legal-section,
.section-card .legal-section + .legal-section {
  margin-top: var(--sp-8);
  padding-top: var(--sp-6);
  border-top: 1px solid var(--border);
}
/* Legal hero → TOC breathing room */
.legal-page .about-hero { margin-bottom: var(--sp-4) }
.legal-grid { margin-top: var(--sp-8) }
/* Mobile: single column, sidebar becomes inline accordion */
@media (max-width: 768px) {
  .legal-grid { grid-template-columns: 1fr !important; margin-top: var(--sp-8) }
  .legal-sidebar { position: static !important; margin-bottom: var(--sp-8) }
  .legal-sidebar .legal-card { padding: var(--sp-4) }
  .legal-sidebar ol { display: flex; flex-wrap: wrap; gap: 6px }
  .legal-sidebar ol li { display: inline }
  .legal-sidebar ol li a { padding: 4px 8px !important; border-radius: var(--r-sm); font-size: 11px }
}

@media (max-width: 1023px) {
  .contact-layout { grid-template-columns: 1fr !important }
  .contact-form-col { order: 1 }
  .contact-info-col { order: 2 }
}
@media (max-width: 767px) {
  .gwill-form__row--2col { grid-template-columns: 1fr }
}

/* ==========================================================================
   VIBE COMMENTS — theme-level overrides
   ========================================================================== */
.vibe-comments-section { padding-top: var(--sp-6) }
.vibe-comments-title { font-family: var(--font-mono); font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); border-bottom-color: var(--border); margin-bottom: var(--sp-6) }
#vibe-comments-trigger { text-align: center; padding: var(--sp-8) 0 }
.vibe-btn-load-comments { font-family: var(--font-mono); font-size: 13px; font-weight: 700; padding: 12px 22px; border-radius: var(--r-sm); background: var(--green); color: #08160f; border: 1px solid var(--green); transition: background .15s; cursor: pointer }
.vibe-btn-load-comments:hover { background: var(--green-hover) }

/* ==========================================================================
   AD SLOT
   ========================================================================== */
.ad-slot { background: linear-gradient(135deg, var(--surface-2), var(--surface)); border: 1px solid var(--border); border-radius: var(--r); display: flex; align-items: center; justify-content: center; color: var(--dim2); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; min-height: 90px; position: relative; overflow: hidden }
.ad-slot::before { content: 'Advertisement'; position: absolute; top: 8px; right: 10px; background: none; padding: 0; font-size: 9px; color: var(--dim2); text-transform: uppercase; letter-spacing: .06em; z-index: 3 }
.ad-slot--filled::before { display: none }
.ad-slot--leaderboard { width: 100%; max-width: var(--content-w); margin: var(--sp-6) auto; min-height: 90px }
.ad-slot--content, .ad-slot--in-content { width: 100%; max-width: var(--content-w); margin: var(--sp-6) auto var(--sp-8); min-height: 100px }
.ad-slot--sidebar { min-height: 250px; max-width: 300px; width: 100%; margin-bottom: var(--sp-5) }
/* Sidebar slot sizing is content-driven when filled: the relative-position
   content lets the box grow to fit whatever ad fills it (300×250 now,
   300×600 half-page later) with zero dead space. */

/* Ad loading spinner — shows until the pasted ad code fills the slot.
   Also the honest state for adblock users: the network script never runs,
   the container never fills, and the spinner keeps spinning. */
.ad-slot__spinner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: absolute;
  inset: 0;
  color: var(--green);
  opacity: .55;
  pointer-events: none;
}
.ad-slot__spinner-text {
  font-size: 9px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--dim2);
}
.ad-spinner { animation: gwill-spin 1s linear infinite }

/* Filled slots: drop the spinner entirely (the ad covers it) */
.ad-slot--filled .ad-slot__spinner { display: none }

/* Banner ads (image/iframe code pasted from Customizer) — centered,
   contained, never blow out the slot or the layout. */
.gwill-ad-banner,
.ad-slot__content > * {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
}
.ad-slot__content img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--r-sm);
  box-shadow: 0 2px 12px rgba(0, 0, 0, .25);
}
.ad-slot--leaderboard .ad-slot__content img { max-height: 90px; width: auto }
.ad-slot--content .ad-slot__content img,
.ad-slot--in-content .ad-slot__content img { max-height: 280px; width: auto }
.ad-slot--sidebar .ad-slot__content img { max-height: 250px; width: auto }
.ad-slot--sticky .ad-slot__content img,
.ad-slot--menu .ad-slot__content img { max-height: 100px; width: auto }
@keyframes gwill-spin { to { transform: rotate(360deg) } }
.ad-slot__content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
/* Filled slots: take the content out of absolute positioning so the
   slot grows to fit the actual ad — no clipping, no collapsed boxes. */
.ad-slot--filled .ad-slot__content {
  position: relative;
  inset: auto;
  padding: 6px;
}
.ad-slot__content > * { max-width: 100%; max-height: 100% }
.ad-slot__content iframe, .ad-slot__content ins { display: block; margin: 0 auto }

/* ── Sticky footer ad (all devices; dismissible on phones only) ──────── */
.ad-sticky {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 12px; /* tablet + desktop: no tab bar to clear */
  z-index: 350; /* above tab bar (200), below cookie (400) + mob nav (500) */
  display: none; /* JS reveals via body.ad-sticky-visible (waits for consent) */
  justify-content: center;
  padding: 0 12px;
  pointer-events: none; /* let clicks pass through the empty bar area */
}
.ad-sticky-inner {
  position: relative;
  width: 100%;
  max-width: 728px;
  pointer-events: auto;
}
.ad-sticky-media--mobile { display: block }
.ad-sticky-media--desktop { display: none }
.ad-sticky .ad-slot--sticky {
  margin: 0 auto;
  max-width: 320px;
  min-height: 50px;
  aspect-ratio: 320/100; /* 320×100 Large Mobile Banner — bigger, earns more
                            than the 320×50 (AdSense best mobile anchor size) */
  width: 100%;
  box-shadow: 0 8px 32px rgba(0, 0, 0, .55);
  border-color: rgba(0, 255, 145, .18);
}
.ad-sticky .ad-slot--leaderboard {
  margin: 0;
  min-height: 90px;
  aspect-ratio: 728/90;
  width: 100%;
  box-shadow: 0 8px 32px rgba(0, 0, 0, .55);
  border-color: rgba(0, 255, 145, .18);
}
.ad-sticky .ad-slot::before { display: none } /* label too cramped on sticky bars */
.ad-sticky .ad-slot__spinner { gap: 4px }
.ad-sticky .ad-spinner { width: 18px; height: 18px }
.ad-sticky .ad-slot__spinner-text { display: none }
.ad-sticky-x {
  position: absolute;
  top: 50%;
  right: -10px; /* half-outside the ad's right edge — always visible */
  transform: translateY(-50%);
  z-index: 2; /* paint above the .ad-slot surface (later in DOM, position:relative) */
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--mid);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
  box-shadow: 0 0 0 3px rgba(13, 13, 13, .9), 0 2px 8px rgba(0, 0, 0, .5);
  transition: color .15s, border-color .15s, box-shadow .15s;
}
.ad-sticky-x:hover { color: var(--green); border-color: var(--green); box-shadow: 0 0 10px rgba(0, 255, 145, .3) }
/* Dismissible on ALL devices — phone, small tablet, tablet, PC. */
/* Phone + small tablet (≤767px): 320×50 above the bottom tab bar */
@media (max-width: 767px) {
  body.ad-sticky-visible .ad-sticky { display: flex }
  .ad-sticky { bottom: calc(var(--btm-tab-h) + 8px) }
  .ad-sticky-media--desktop { display: none }
  .ad-sticky-media--mobile { display: block }
  body.ad-sticky-visible #vp { padding-bottom: calc(var(--btm-tab-h) + 78px) }
  body.ad-sticky-visible .site-footer { padding-bottom: calc(var(--btm-tab-h) + 88px) }
}
/* Tablet + desktop (≥768px): 728×90 leaderboard at the viewport bottom */
@media (min-width: 768px) {
  body.ad-sticky-visible .ad-sticky { display: flex }
  .ad-sticky-media--mobile { display: none }
  .ad-sticky-media--desktop { display: block }
  body.ad-sticky-visible .site-footer { padding-bottom: 130px }
}

/* ==========================================================================
   FILTER BAR (Home/Archive)
   ========================================================================== */
.filter-bar { display: flex; gap: 10px; flex-wrap: wrap; padding: var(--sp-6) 0; margin-bottom: var(--sp-8) }
@media (max-width: 767px) { .filter-bar { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 10px } .filter-bar::-webkit-scrollbar { display: none } }

/*** ==========================================================================
   PAGINATION (Dark theme)
   ========================================================================== */
.pagination { margin: var(--sp-8) 0 0; display: flex; justify-content: center; gap: 6px }
.pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px; font-size: 13px; font-weight: 600; color: var(--mid); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); transition: all .15s; font-family: var(--font-mono); text-decoration: none; flex-shrink: 0 }
.pagination .page-numbers:hover { border-color: var(--green-border); color: var(--green) }
.pagination .page-numbers.current { background: var(--green-dim); border-color: var(--green-border); color: var(--green) }
.pagination .page-numbers.dots { border: none; background: none; color: var(--dim2); min-width: auto; padding: 0 2px }

/* Long pagination stays on ONE row everywhere — never wraps into a messy
   multi-row blob. Desktop/tablet: centered, and over-long lists scroll
   horizontally with an edge fade + snap. Mobile: same, tighter touch targets. */
.pagination { flex-wrap: nowrap; max-width: 100%; overflow-x: auto; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; scrollbar-width: none; padding: 2px }
.pagination::-webkit-scrollbar { display: none }
.pagination .page-numbers { scroll-snap-align: center }

@media (max-width: 767px) {
  .pagination { justify-content: flex-start; gap: 5px }
  .pagination .page-numbers { min-width: 36px; height: 36px; font-size: 12px }
}

/* ==========================================================================
   EMPTY STATE / 404
   ========================================================================== */
.empty-state { text-align: center; padding: var(--sp-32) 0 }
.empty-state .icon-wrap { width: 64px; height: 64px; border-radius: 50%; background: var(--surface); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; margin: 0 auto 24px; color: var(--mid) }
.error-code { font-size: clamp(70px, 12vw, 130px); font-weight: 800; color: var(--surface-2); line-height: 1; letter-spacing: -.04em }
.suggest-list { display: flex; flex-direction: column; gap: 10px; max-width: 420px; margin: 32px auto 0 }
.suggest-list a { display: flex; justify-content: space-between; padding: 14px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); font-size: 13px; color: var(--text); transition: border-color .15s }
.suggest-list a:hover { border-color: var(--green-border); color: var(--green) }

/* ==========================================================================
   REVEAL ANIMATIONS
   ========================================================================== */
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px) } to { opacity: 1; transform: translateY(0) } }
.reveal { animation: fadeUp .5s var(--ease-out) both }
.reveal-d1 { animation-delay: .05s }
.reveal-d2 { animation-delay: .1s }
.reveal-d3 { animation-delay: .15s }
.reveal-d4 { animation-delay: .2s }
.reveal-d5 { animation-delay: .25s }
.reveal-d6 { animation-delay: .3s }

/* ==========================================================================
   MOBILE BOTTOM TAB BAR
   ========================================================================== */
.mob-btm { position: fixed; bottom: 0; left: 0; right: 0; z-index: var(--z-btm-tab); background: rgba(13, 13, 13, .96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 1px solid var(--border); height: var(--btm-tab-h); display: none }
.mtb-i { display: flex; align-items: center; justify-content: space-around; height: 100%; max-width: 500px; margin: 0 auto; width: 100% }
.mtb-t { background: transparent; border: none; color: var(--dim); font-size: 10px; font-weight: 600; padding: 6px 10px; border-radius: 6px; transition: color .15s; display: flex; flex-direction: column; align-items: center; gap: 2px; font-family: var(--font-body) }
.mtb-t .ti { width: 20px; height: 20px; display: block; margin: 0 auto 2px }
.mtb-t.on { color: var(--green) }
#vp { max-width: 100vw; min-height: 100vh }
@media (max-width: 767px) { .mob-btm { display: block } #vp { padding-bottom: 56px } }
@media (min-width: 768px) { .mob-btm { display: none !important } }

/* Tablet-specific padding optimizations */
@media (min-width: 768px) and (max-width: 1023px) {
  .page-hero { padding: var(--sp-10) 0 var(--sp-8) }
  .section { padding: var(--sp-16) 0 }
  .section-sm { padding: var(--sp-10) 0 }
  .grid-3 { gap: var(--sp-4) }
  .grid-2 { gap: var(--sp-4) }
  .about-stats { gap: var(--sp-3) }
  .about-stat strong { font-size: 22px }
  .related-posts__grid { gap: var(--sp-4) }
  .footer-grid { gap: var(--sp-8) }
  .footer-cta { padding: var(--sp-16) 0 }
  .footer-bottom { padding: 16px var(--sp-4) }
}

/* ==========================================================================
   MOBILE NAV OVERLAY
   ========================================================================== */
.mno { position: fixed; inset: 0; z-index: var(--z-mob-nav); background: rgba(5, 5, 5, .98); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .3s var(--ease-out); overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--green-border) var(--surface); -ms-overflow-style: auto }
.mno::-webkit-scrollbar { width: 6px }
.mno::-webkit-scrollbar-track { background: var(--surface); border-radius: 3px }
.mno::-webkit-scrollbar-thumb { background: var(--green-border); border-radius: 3px }
/* Overlay-style scrollbar: visible when the menu opens AND while scrolling,
   fades out ~700ms after the scroll gesture ends. Any new scroll brings it
   back. JS toggles .mno--idle (hide) on a scroll-end debounce. */
.mno--idle { scrollbar-width: none; -ms-overflow-style: none }
.mno--idle::-webkit-scrollbar { display: none; width: 0; height: 0 }
.mno.open { transform: translateX(0) }
.mno-top { display: flex; justify-content: space-between; align-items: center; padding: var(--sp-4) var(--sp-5); border-bottom: 1px solid var(--border); height: 56px; flex-shrink: 0 }
.mno-x { width: 36px; height: 36px; border-radius: var(--r-sm); border: 1px solid var(--border); background: transparent; display: flex; align-items: center; justify-content: center; color: var(--mid); cursor: pointer }
.mno-x:hover { border-color: var(--green-border); color: var(--green) }
.mno-logo { font-size: 15px }
.mno-items { flex: 1; display: flex; flex-direction: column; padding: var(--sp-4); overflow-y: auto; gap: 2px }
/* Mobile nav rows — hairline separators so the list reads as distinct rows,
   not a flat wall of text on the near-black overlay. */
.mno-list > li:not(:last-child) { border-bottom: 1px solid var(--border) }
.mni { display: flex; align-items: center; padding: var(--sp-4) var(--sp-5); font-size: 15px; font-weight: 600; color: var(--text); border-radius: var(--r-sm); transition: background .15s, color .15s }
.mni:hover { background: var(--surface); color: var(--green) }
.mni.active { color: var(--green); background: var(--green-dim) }
.mno-bot { padding: var(--sp-4) var(--sp-5); border-top: 1px solid var(--border); flex-shrink: 0; display: flex; flex-direction: column; gap: var(--sp-4) }
/* Mobile-menu ad: sized as a compact banner (320×100), with clear breathing
   room so it never joins the nav list above or the Start-here CTA below.
   aspect-ratio fixed = CLS-safe; max-width keeps it from stretching full-bleed. */
.mno-bot .ad-slot--menu { width: 100%; max-width: 320px; margin: 0 auto; aspect-ratio: 320/100; border-radius: var(--r-sm) }
.mno-bot .ad-slot--in-content { margin: 0 0 var(--sp-4); aspect-ratio: auto; max-height: 120px }
.mno-cta { width: 100%; padding: 14px; background: var(--green); color: #08160f; border: none; border-radius: var(--r-sm); font-size: 14px; font-weight: 700; font-family: var(--font-mono); display: flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer }
.mno-cta:hover { background: var(--green-hover) }
.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 }