/* =============================================================================
   MONOGRAM v2 — Green theme for artists
   Warm pale paper, three shades of green (forest, moss, chartreuse),
   big display type, tile grid that pulls from your tags.
   ============================================================================= */

:root {
    --paper:     #f1efe4;     /* warm pale sage paper */
    --paper-2:   #e6e3d2;     /* deeper paper for hover/depth */
    --ink:       #1a2418;     /* deep forest near-black */
    --ink-soft:  #4a5c45;
    --ink-mute:  #7d8c78;
    --hairline:  #c7ccb8;

    --green-1:   #2d5d3a;     /* deep forest green */
    --green-2:   #6b9b5a;     /* fresh moss */
    --green-3:   #c8dc7e;     /* soft chartreuse highlight */

    /* Aliases used throughout the theme */
    --red:       var(--green-1);   /* primary accent (was red)    */
    --blue:      var(--ink);       /* secondary deep accent       */
    --yellow:    var(--green-3);   /* highlight / hover accent    */

    --display:   'Bricolage Grotesque', sans-serif;
    --sans:      'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --mono:      'IBM Plex Mono', 'JetBrains Mono', ui-monospace, monospace;

    --measure:   38rem;
    --page:      1180px;
}

/* -----------------------------------------------------------------------------
   Reset
   ----------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
img, video, iframe { max-width: 100%; height: auto; }
html { scroll-behavior: smooth; }
::selection { background: var(--yellow); color: var(--ink); }

body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    font-optical-sizing: auto;
    position: relative;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Subtle paper grain overlay — gives a screen-printed texture */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 100;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.1  0 0 0 0 0.09  0 0 0 0 0.08  0 0 0 0.5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='0.5'/></svg>");
    opacity: 0.18;
    mix-blend-mode: multiply;
}

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

a { color: inherit; }

/* -----------------------------------------------------------------------------
   Page frame
   ----------------------------------------------------------------------------- */
.page {
    max-width: var(--page);
    margin: 0 auto;
    padding: 0 32px 64px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}
.site-main { flex: 1; }

/* -----------------------------------------------------------------------------
   Newsletter strip — top of homepage only
   ----------------------------------------------------------------------------- */
.signup-strip {
    background: var(--ink);
    color: var(--paper);
    padding: 14px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    border-bottom: 2px solid var(--ink);
    position: relative;
}

.signup-pitch {
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.01em;
    margin: 0;
    flex: 1;
    min-width: 0;
}
.signup-arrow {
    color: var(--yellow);
    margin-right: 8px;
    font-weight: 700;
    display: inline-block;
    animation: nudge 2s ease-in-out infinite;
}
@keyframes nudge {
    0%, 100% { transform: translateX(0); }
    50%      { transform: translateX(4px); }
}

.signup-form {
    display: flex;
    gap: 0;
    align-items: stretch;
    flex-shrink: 0;
}
.signup-form input[type="email"] {
    background: var(--paper);
    color: var(--ink);
    border: 0;
    padding: 8px 14px;
    font-family: var(--mono);
    font-size: 13px;
    width: 240px;
    outline: none;
    transition: background 0.2s ease;
}
.signup-form input[type="email"]::placeholder { color: var(--ink-mute); }
.signup-form input[type="email"]:focus { background: var(--yellow); }

.signup-form button {
    background: var(--red);
    color: var(--paper);
    border: 0;
    padding: 8px 18px;
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: background 0.2s ease;
}
.signup-form button:hover { background: var(--yellow); color: var(--ink); }

.signup-success {
    display: none;
    font-family: var(--mono);
    font-size: 13px;
    color: var(--yellow);
    margin: 0;
    width: 100%;
}
.signup-strip.success .signup-form,
.signup-strip.success .signup-pitch { display: none; }
.signup-strip.success .signup-success { display: block; }

/* -----------------------------------------------------------------------------
   Site header (shown on every page EXCEPT home)
   ----------------------------------------------------------------------------- */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin: 16px 0 32px;
    padding-bottom: 18px;
    border-bottom: 2px solid var(--ink);
    gap: 24px;
    flex-wrap: wrap;
}

.site-mark {
    font-family: var(--display);
    font-weight: 700;
    font-size: 22px;
    letter-spacing: -0.02em;
    text-decoration: none;
    color: var(--ink);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.site-mark-dot {
    display: inline-block;
    width: 14px; height: 14px;
    background: var(--green-1);
    border-radius: 50%;
    box-shadow: 4px 4px 0 var(--green-3);
    transform: translateY(-2px);
}

.site-nav ul {
    list-style: none;
    display: flex;
    gap: 22px;
    flex-wrap: wrap;
}
.site-nav a {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    padding-bottom: 2px;
    transition: border-color 0.2s ease, color 0.2s ease;
}
.site-nav a:hover { border-bottom-color: var(--red); }

/* On the homepage, hide the top header — the page IS the navigation. */
.home-template .site-header { display: none; }

/* -----------------------------------------------------------------------------
   Hero
   ----------------------------------------------------------------------------- */
.hero {
    padding: 80px 0 64px;
    text-align: center;
    position: relative;
}
.home-template .hero { padding-top: 96px; }

.hero-name {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(72px, 13vw, 200px);
    line-height: 0.92;
    letter-spacing: -0.04em;
    color: var(--ink);
    margin-bottom: 60px;
    display: inline-block;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}
.hero-name-mark {
    color: var(--red);
    font-size: 0.5em;
    vertical-align: 0.4em;
    margin-left: 0.05em;
    display: inline-block;
}

/* Hero-name play button — replaces the static dot. Triggers the most
   recent podcast in the persistent player. Uses the same square-with-
   offset-shadow language as the homepage tiles. */
.hero-name-play {
    /* Use position: relative so the absolutely-positioned label can
       hang underneath without being affected by the hero name's tight
       letter-spacing. */
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: clamp(56px, 9vw, 120px);
    height: clamp(56px, 9vw, 120px);
    margin-left: clamp(12px, 1.5vw, 28px);
    vertical-align: middle;
    background: var(--green-3);
    color: var(--ink);
    border: 3px solid var(--ink);
    cursor: pointer;
    padding: 0;
    transition:
        transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
        box-shadow 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
        background 0.2s ease;
    box-shadow: 5px 5px 0 var(--ink);
}
.hero-name-play:hover,
.hero-name-play:focus-visible {
    background: var(--paper);
    transform: translate(-4px, -4px);
    box-shadow: 11px 11px 0 var(--ink);
    outline: none;
}
.hero-name-play:active {
    transform: translate(0, 0);
    box-shadow: 2px 2px 0 var(--ink);
}
.hero-name-play svg {
    width: 42%;
    height: 42%;
    display: block;
    transform: translateX(6%);
}
.hero-name-play.is-playing {
    background: var(--green-1);
    color: var(--green-3);
}

/* The "Listen now" label sits below the button so it doesn't get
   crushed by the giant hero typography. Mono caps for that hand-set
   indicator-label feel. */
.hero-name-play-label {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink);
    white-space: nowrap;
    pointer-events: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    /* Solid background so it stays readable over any home content */
    background: var(--green-3);
    border: 2px solid var(--ink);
    padding: 5px 10px;
    box-shadow: 2px 2px 0 var(--ink);
    transition: background 0.2s ease, transform 0.2s ease;
}
.hero-name-play:hover .hero-name-play-label,
.hero-name-play:focus-visible .hero-name-play-label {
    background: var(--paper);
}
.hero-name-play-arrow {
    font-size: 12px;
    line-height: 1;
}

@media (max-width: 640px) {
    .hero-name-play-label {
        font-size: 10px;
        padding: 4px 8px;
        letter-spacing: 0.08em;
    }
}

.hero-tagline {
    font-family: var(--display);
    font-weight: 400;
    font-size: clamp(18px, 1.8vw, 22px);
    color: var(--ink-soft);
    max-width: 540px;
    margin: 0 auto;
    line-height: 1.4;
}

.hero-list { padding: 56px 0 40px; }
.hero-list .hero-name { font-size: clamp(48px, 8vw, 110px); }

.kicker {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--red);
    margin-bottom: 14px;
}

/* -----------------------------------------------------------------------------
   Tile grid (homepage)
   ----------------------------------------------------------------------------- */
.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 96px;
}

.tile {
    aspect-ratio: 1 / 1;
    display: block;
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: var(--ink);
    border: 2px solid var(--ink);
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
                box-shadow 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.tile:hover { transform: translate(-4px, -4px); box-shadow: 8px 8px 0 var(--ink); }

/* Color block (no image) variants */
.tile-red    { background: var(--green-1); color: var(--paper); }   /* deep forest */
.tile-blue   { background: var(--green-2); color: var(--paper); }   /* moss        */
.tile-yellow { background: var(--green-3); color: var(--paper); }   /* chartreuse  */

.tile-icon {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 38%;
    max-width: 110px;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.tile-icon svg { width: 100%; height: 100%; stroke-width: 1.5; }
.tile:hover .tile-icon { transform: translate(-50%, calc(-50% - 6px)); }

/* Image tile variants */
.tile-image {
    background-size: cover;
    background-position: center;
    color: var(--paper);
}
.tile-image .tile-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(26,24,21,0.75) 0%,
        rgba(26,24,21,0.15) 60%,
        rgba(26,24,21,0) 100%
    );
    transition: background 0.3s ease;
    mix-blend-mode: multiply;
}

/* Each color tints its image differently — overprint feel */
.tile-image.tile-red .tile-overlay {
    background:
        linear-gradient(to top, rgba(45,93,58,0.85) 0%, rgba(45,93,58,0.25) 70%, rgba(45,93,58,0) 100%);
    mix-blend-mode: multiply;
}
.tile-image.tile-blue .tile-overlay {
    background:
        linear-gradient(to top, rgba(107,155,90,0.85) 0%, rgba(107,155,90,0.25) 70%, rgba(107,155,90,0) 100%);
    mix-blend-mode: multiply;
}
.tile-image.tile-yellow .tile-overlay {
    background:
        linear-gradient(to top, rgba(200,220,126,0.85) 0%, rgba(200,220,126,0.25) 70%, rgba(200,220,126,0) 100%);
    mix-blend-mode: multiply;
}

.tile:hover .tile-overlay { mix-blend-mode: normal; }

/* Tile label — bottom of every tile */
.tile-label {
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 16px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
    z-index: 2;
}
.tile-label-text {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(22px, 2.4vw, 34px);
    letter-spacing: -0.02em;
    line-height: 0.95;
    text-transform: uppercase;
}
.tile-arrow {
    font-family: var(--display);
    font-size: 22px;
    flex-shrink: 0;
    transform: translateY(-2px);
    transition: transform 0.25s ease;
}
.tile:hover .tile-arrow { transform: translate(3px, -5px); }

/* -----------------------------------------------------------------------------
   Photo wall — bottom of homepage
   ----------------------------------------------------------------------------- */
.photo-wall { margin-bottom: 80px; }

.photo-wall-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 24px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--ink);
    gap: 16px;
    flex-wrap: wrap;
}
.photo-wall-head h2 {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(36px, 4.8vw, 64px);
    letter-spacing: -0.03em;
    line-height: 0.95;
    color: var(--ink);
}
.photo-wall-head h2 .dot { color: var(--red); }

.photo-wall-more {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    border-bottom: 2px solid var(--ink);
    padding-bottom: 2px;
    transition: color 0.2s ease, border-color 0.2s ease;
}
.photo-wall-more:hover { color: var(--red); border-color: var(--red); }

/* Asymmetric grid — each card lands on a deliberately different shape */
.photo-wall-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}
.photo-wall-grid .photo-card { aspect-ratio: 1 / 1; }

.photo-card {
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: var(--paper);
    border: 2px solid var(--ink);
    background: var(--paper-2);
    transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.photo-card:hover { transform: translate(-3px, -3px); box-shadow: 6px 6px 0 var(--ink); z-index: 2; }

.photo-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), filter 0.4s ease;
    filter: contrast(1.05) saturate(1.05);
}
.photo-card:hover img { transform: scale(1.04); filter: contrast(1.1) saturate(1.15); }

/* Empty card state — used when a podcast post has no feature image. */
.photo-card-empty {
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(
            45deg,
            var(--green-1) 0,
            var(--green-1) 10px,
            var(--green-2) 10px,
            var(--green-2) 20px
        );
}

.photo-card-meta {
    position: absolute;
    inset: 0;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 4px;
    background: linear-gradient(
        to top,
        rgba(26,24,21,0.85) 0%,
        rgba(26,24,21,0.2) 50%,
        rgba(26,24,21,0) 80%
    );
    transition: background 0.3s ease;
}
.photo-card:hover .photo-card-meta {
    background: linear-gradient(to top, rgba(26,24,21,0.9) 0%, rgba(26,24,21,0.5) 100%);
}

.photo-card-tag {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--yellow);
}
.photo-card-title {
    font-family: var(--display);
    font-weight: 600;
    font-size: 18px;
    line-height: 1.15;
    letter-spacing: -0.01em;
    color: var(--paper);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Symmetrical grid — every card is the same square size. */

/* -----------------------------------------------------------------------------
   Post list (used on /blog/, tag, author)
   ----------------------------------------------------------------------------- */
.post-list {
    margin-bottom: 56px;
    border-top: 2px solid var(--ink);
}

.post-row {
    display: grid;
    grid-template-columns: 100px 160px 1fr 32px;
    gap: 24px;
    align-items: center;
    padding: 18px 8px;
    border-bottom: 1px solid var(--hairline);
    text-decoration: none;
    color: var(--ink);
    transition: padding-left 0.25s ease, background 0.25s ease;
    min-width: 0;
    max-width: 100%;
}
.post-row:hover { padding-left: 20px; background: var(--paper-2); }
.post-row:hover .post-row-arrow { transform: translateX(4px); color: var(--red); }

.post-row-thumb {
    width: 100px;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: var(--paper-2);
    border: 1.5px solid var(--ink);
}
.post-row-thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-row-thumb-empty {
    background:
        repeating-linear-gradient(
            45deg,
            var(--paper-2) 0,
            var(--paper-2) 6px,
            var(--paper) 6px,
            var(--paper) 12px
        );
}

.post-row-meta {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-family: var(--mono);
    font-size: 11px;
}
.post-row-tag {
    color: var(--red);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.post-row-date {
    color: var(--ink-mute);
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.post-row-title {
    font-family: var(--display);
    font-weight: 500;
    font-size: clamp(20px, 2vw, 26px);
    line-height: 1.2;
    letter-spacing: -0.01em;
    color: var(--ink);
    overflow-wrap: anywhere;
    word-break: break-word;
}

.post-row-arrow {
    text-align: right;
    font-family: var(--display);
    font-size: 18px;
    color: var(--ink-mute);
    transition: transform 0.25s ease, color 0.25s ease;
}

/* -----------------------------------------------------------------------------
   Tag-page list — wider thumb, title + excerpt instead of date
   ----------------------------------------------------------------------------- */
.post-list-tag .post-row {
    grid-template-columns: 140px 1fr 32px;
    gap: 28px;
    align-items: start;
    padding: 22px 8px;
}
.post-list-tag .post-row-thumb {
    width: 140px;
    aspect-ratio: 4/3;
}
.post-row-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}
.post-row-excerpt {
    font-family: var(--sans);
    font-size: 14px;
    line-height: 1.55;
    color: var(--ink-soft);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
    word-break: break-word;
}
.post-list-tag .post-row-arrow {
    margin-top: 6px;
}

/* -----------------------------------------------------------------------------
   Pagination
   ----------------------------------------------------------------------------- */
.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 28px 0;
    margin-bottom: 48px;
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.pagination a {
    color: var(--ink);
    text-decoration: none;
    border-bottom: 2px solid var(--red);
    padding-bottom: 2px;
}
.pagination a:hover { color: var(--red); }
.pagination .nav-next { margin-left: auto; }
.pagination .page-number { color: var(--ink-mute); }

/* -----------------------------------------------------------------------------
   Single post / page
   ----------------------------------------------------------------------------- */
.post {
    max-width: var(--measure);
    margin: 0 auto 80px;
    padding: 0 4px;
}

.post-header { margin-bottom: 28px; text-align: left; max-width: 100%; }

.post-tag-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    background: var(--yellow);
    padding: 6px 12px 6px 10px;
    border: 1.5px solid var(--ink);
    margin-bottom: 24px;
    transition: background 0.2s ease;
}
.post-tag-pill:hover { background: var(--red); color: var(--paper); }
.post-tag-pill .dot {
    width: 8px; height: 8px;
    background: var(--ink);
    border-radius: 50%;
    display: inline-block;
}
.post-tag-pill:hover .dot { background: var(--paper); }

.post-title {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(24px, 3.5vw, 42px);
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--ink);
    margin-bottom: 16px;
}

.post-deck {
    font-family: var(--display);
    font-style: italic;
    font-weight: 400;
    font-size: clamp(16px, 1.8vw, 19px);
    color: var(--ink-soft);
    line-height: 1.4;
    max-width: 48rem;
    margin: 0 0 22px;
}

.post-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-mute);
}
.post-meta a { color: var(--ink-mute); text-decoration: none; }
.post-meta a:hover { color: var(--red); }
.post-meta .sep { opacity: 0.5; }

.post-feature {
    margin: 48px auto 56px;
    max-width: 1100px;
    width: calc(100% + 64px);
    margin-left: -32px;
    margin-right: -32px;
}
.post-feature img {
    width: 100%;
    border: 2px solid var(--ink);
}
.post-feature figcaption {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink-soft);
    text-align: center;
    margin-top: 12px;
    line-height: 1.5;
}

/* -----------------------------------------------------------------------------
   Post body
   ----------------------------------------------------------------------------- */
.post-body {
    font-family: var(--sans);
    font-size: 18px;
    line-height: 1.65;
    color: var(--ink);
}
.post-body > * + * { margin-top: 1.4em; }

.post-body h2,
.post-body h3,
.post-body h4 {
    font-family: var(--display);
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--ink);
    margin-top: 2.2em;
}
.post-body h2 { font-size: 1.7em; }
.post-body h3 { font-size: 1.35em; }
.post-body h4 { font-size: 1.1em; }

.post-body a {
    color: var(--ink);
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
    text-decoration-color: var(--red);
    transition: background 0.2s, color 0.2s;
    padding: 0 2px;
}
.post-body a:hover { background: var(--yellow); }

.post-body em { font-style: italic; }
.post-body strong { font-weight: 600; }

.post-body ul,
.post-body ol { padding-left: 1.5em; }
.post-body li + li { margin-top: 0.5em; }

.post-body blockquote {
    border-left: 4px solid var(--red);
    padding: 4px 0 4px 24px;
    margin-left: 0;
    margin-right: 0;
    font-family: var(--display);
    font-style: italic;
    font-size: 1.15em;
    color: var(--ink);
}

.post-body hr {
    border: 0;
    border-top: 2px dashed var(--ink);
    margin: 3em auto;
    width: 80px;
}

.post-body figure { margin: 2em 0; }
.post-body figure img { width: 100%; border: 2px solid var(--ink); }
.post-body figcaption {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink-soft);
    text-align: center;
    margin-top: 10px;
    line-height: 1.5;
}

.post-body code {
    font-family: var(--mono);
    font-size: 0.85em;
    background: var(--paper-2);
    padding: 2px 6px;
    border: 1px solid var(--hairline);
}
.post-body pre {
    background: var(--ink);
    color: var(--paper);
    padding: 18px 20px;
    overflow-x: auto;
    font-size: 14px;
    line-height: 1.5;
    font-family: var(--mono);
    border: 2px solid var(--ink);
}
.post-body pre code {
    background: none;
    border: 0;
    padding: 0;
    color: inherit;
}

.post-body table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--sans);
    font-size: 14px;
    margin: 1.5em 0;
    border: 2px solid var(--ink);
}
.post-body th,
.post-body td {
    text-align: left;
    padding: 10px 14px;
    border-bottom: 1px solid var(--hairline);
}
.post-body th {
    font-family: var(--mono);
    font-weight: 600;
    background: var(--yellow);
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.08em;
    border-bottom-color: var(--ink);
}

/* Ghost content cards */
.kg-card { margin: 2em 0; }
.kg-image-card,
.kg-gallery-card,
.kg-embed-card,
.kg-bookmark-card,
.kg-video-card,
.kg-audio-card { margin: 2em 0; }

.kg-width-wide   { max-width: calc(var(--measure) * 1.4); margin-left: auto; margin-right: auto; }
.kg-width-full   { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); width: 100vw; }
.kg-width-full img { width: 100%; max-width: none; }

.kg-bookmark-card a {
    display: flex;
    text-decoration: none;
    color: var(--ink);
    border: 2px solid var(--ink);
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}
.kg-bookmark-card a:hover { transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--ink); }
.kg-bookmark-content { flex: 1; padding: 18px 22px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.kg-bookmark-title { font-family: var(--display); font-weight: 600; font-size: 18px; line-height: 1.25; }
.kg-bookmark-description { font-size: 13px; color: var(--ink-soft); line-height: 1.5; }
.kg-bookmark-metadata { font-family: var(--mono); font-size: 11px; color: var(--ink-mute); margin-top: auto; }
.kg-bookmark-thumbnail { flex-shrink: 0; width: 30%; max-width: 200px; }
.kg-bookmark-thumbnail img { width: 100%; height: 100%; object-fit: cover; }

.kg-callout-card {
    border: 2px solid var(--ink);
    background: var(--yellow);
    padding: 18px 22px;
    display: flex;
    gap: 16px;
}
.kg-callout-card.kg-callout-card-blue   { background: var(--blue); color: var(--paper); }
.kg-callout-card.kg-callout-card-red    { background: var(--red); color: var(--paper); }
.kg-callout-card.kg-callout-card-yellow { background: var(--yellow); }
.kg-callout-emoji { flex-shrink: 0; font-size: 22px; }
.kg-callout-text { font-family: var(--display); font-size: 17px; line-height: 1.4; }

/* Post tags footer */
.post-tags {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 2px dashed var(--ink);
    text-align: center;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 14px;
}
.post-tags a {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    border: 1.5px solid var(--ink);
    padding: 5px 12px;
    transition: background 0.2s, color 0.2s;
}
.post-tags a:hover { background: var(--red); color: var(--paper); border-color: var(--red); }

/* -----------------------------------------------------------------------------
   Tag page feature image
   ----------------------------------------------------------------------------- */
.tag-feature {
    margin: 0 -32px 56px;
    border-top: 2px solid var(--ink);
    border-bottom: 2px solid var(--ink);
}
.tag-feature img {
    width: 100%;
    max-height: 360px;
    object-fit: cover;
}

/* -----------------------------------------------------------------------------
   Floating prev/next arrows on post pages — fixed to viewport edges,
   vertically centered. Hidden on narrow screens where they'd cover the
   text (the bottom .post-nav cards still serve those visitors).
   ----------------------------------------------------------------------------- */
.post-floater {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    z-index: 50;
    width: 56px;
    height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--paper);
    border: 2.5px solid var(--ink);
    color: var(--ink);
    text-decoration: none;
    box-shadow: 4px 4px 0 var(--ink);
    transition:
        transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
        box-shadow 0.25s cubic-bezier(0.2, 0.8, 0.2, 1),
        background 0.2s ease,
        opacity 0.2s ease;
    opacity: 0.85;
}
.post-floater:hover,
.post-floater:focus-visible {
    background: var(--green-3);
    opacity: 1;
    outline: none;
}
.post-floater:active {
    transform: translateY(-50%) translate(0, 0);
    box-shadow: 1px 1px 0 var(--ink);
}
.post-floater svg {
    width: 24px;
    height: 24px;
}

/* Position: prev on left edge, next on right edge */
.post-floater-prev { left: 18px; }
.post-floater-next { right: 18px; }

/* Hover lift in the right direction depending on which side */
.post-floater-prev:hover,
.post-floater-prev:focus-visible {
    transform: translateY(-50%) translate(-3px, -3px);
    box-shadow: 7px 7px 0 var(--ink);
}
.post-floater-next:hover,
.post-floater-next:focus-visible {
    transform: translateY(-50%) translate(-3px, -3px);
    box-shadow: 7px 7px 0 var(--ink);
}

/* When the persistent player is up, lift the floaters above it */
body.has-player .post-floater { margin-top: -32px; }

/* Hide on narrow screens — they would cover the post text. Visitors on
   small screens use the bottom .post-nav cards instead. */
@media (max-width: 1180px) {
    .post-floater { display: none; }
}

/* -----------------------------------------------------------------------------
   Post nav — prev/next links between posts within the same collection
   ----------------------------------------------------------------------------- */
.post-nav {
    max-width: var(--page);
    margin: 64px auto 24px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.post-nav-link {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px 20px;
    background: var(--paper-2);
    border: 2px solid var(--ink);
    color: var(--ink);
    text-decoration: none;
    transition:
        transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
        box-shadow 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
        background 0.2s ease;
    box-shadow: 3px 3px 0 var(--ink);
    min-height: 92px;
}
.post-nav-link:hover {
    background: var(--green-3);
    transform: translate(-3px, -3px);
    box-shadow: 7px 7px 0 var(--ink);
}
.post-nav-prev { text-align: left; }
.post-nav-next { text-align: right; align-items: flex-end; }

.post-nav-direction {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-soft);
}
.post-nav-title {
    font-family: var(--display);
    font-weight: 600;
    font-size: 18px;
    letter-spacing: -0.01em;
    line-height: 1.2;
    color: var(--ink);
    /* Clamp to 2 lines so a long title can't blow out the layout */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Empty state (no prev or no next) — muted, non-interactive */
.post-nav-empty {
    background: transparent;
    border: 2px dashed var(--hairline);
    box-shadow: none;
    color: var(--ink-mute);
    cursor: default;
}
.post-nav-empty:hover {
    background: transparent;
    transform: none;
    box-shadow: none;
}
.post-nav-empty .post-nav-direction { color: var(--ink-mute); }

@media (max-width: 720px) {
    .post-nav {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .post-nav-next {
        text-align: left;
        align-items: flex-start;
    }
    .post-nav-link { min-height: 0; }
}

/* -----------------------------------------------------------------------------
   Related posts (under single post)
   ----------------------------------------------------------------------------- */
.related {
    max-width: var(--page);
    margin: 80px auto;
}
.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.related-card {
    text-decoration: none;
    color: var(--ink);
    border: 2px solid var(--ink);
    overflow: hidden;
    background: var(--paper-2);
    aspect-ratio: 4/5;
    position: relative;
    transition: transform 0.25s, box-shadow 0.25s;
}
.related-card:hover { transform: translate(-3px, -3px); box-shadow: 6px 6px 0 var(--ink); }
.related-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.related-meta {
    position: absolute;
    inset: 0;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 6px;
    background: linear-gradient(to top, rgba(26,24,21,0.9) 0%, rgba(26,24,21,0.1) 50%, rgba(26,24,21,0) 80%);
    color: var(--paper);
}
.related-tag {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--yellow);
}
.related-title {
    font-family: var(--display);
    font-weight: 600;
    font-size: 18px;
    line-height: 1.2;
    letter-spacing: -0.01em;
}

/* -----------------------------------------------------------------------------
   Empty / error states
   ----------------------------------------------------------------------------- */
.empty {
    font-family: var(--display);
    font-style: italic;
    font-size: 18px;
    color: var(--ink-soft);
    text-align: center;
    padding: 48px 0;
}
.error-cta {
    margin-top: 32px;
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.error-cta a {
    color: var(--ink);
    text-decoration: none;
    border-bottom: 2px solid var(--red);
    padding-bottom: 2px;
}
.error-cta a:hover { color: var(--red); }

/* -----------------------------------------------------------------------------
   Theme tweaks editor — only visible when ?edit=tweaks is in the URL.
   Self-contained styling that doesn't depend on theme variables, so the
   editor itself looks consistent regardless of how the user is editing
   the theme below it.
   ----------------------------------------------------------------------------- */
.theme-tweaks {
    position: fixed;
    top: 16px; right: 16px;
    z-index: 1000;
    width: 340px;
    max-height: calc(100vh - 32px);
    background: #ffffff;
    border: 2px solid #1a2418;
    box-shadow: 6px 6px 0 #1a2418;
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    color: #1a2418;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.theme-tweaks[hidden] { display: none; }

.theme-tweaks-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #1a2418;
    color: #f1efe4;
    border-bottom: 2px solid #1a2418;
}
.theme-tweaks-head h2 {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
    color: inherit;
}
.theme-tweaks-close {
    background: transparent;
    border: 0;
    color: #f1efe4;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
}
.theme-tweaks-close:hover { color: #c8dc7e; }

.theme-tweaks-body {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

.theme-tweaks-pitch {
    font-size: 12px;
    line-height: 1.5;
    margin: 0 0 18px;
    color: #4a5c45;
}
.theme-tweaks-pitch code {
    background: #f1efe4;
    padding: 1px 5px;
    border: 1px solid #c7ccb8;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
}
.theme-tweaks-pitch strong { color: #1a2418; }

.theme-tweaks-section { margin-bottom: 20px; }
.theme-tweaks-section h3 {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin: 0 0 12px;
    padding-bottom: 6px;
    border-bottom: 1.5px solid #1a2418;
    color: #1a2418;
}

.theme-tweaks-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.theme-tweaks-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.theme-tweaks label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 11px;
    color: #4a5c45;
    font-weight: 500;
}
.theme-tweaks input[type="color"] {
    width: 100%;
    height: 36px;
    padding: 2px;
    border: 1.5px solid #1a2418;
    background: #ffffff;
    cursor: pointer;
}
.theme-tweaks select {
    width: 100%;
    padding: 8px 28px 8px 10px;
    border: 1.5px solid #1a2418;
    background: #ffffff;
    font-family: 'IBM Plex Sans', system-ui, sans-serif;
    font-size: 13px;
    color: #1a2418;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, #1a2418 50%),
        linear-gradient(135deg, #1a2418 50%, transparent 50%);
    background-position:
        calc(100% - 14px) 50%,
        calc(100% - 9px)  50%;
    background-size: 5px 5px;
    background-repeat: no-repeat;
}

.theme-tweaks-foot {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    border-top: 2px solid #1a2418;
    background: #f1efe4;
}
.theme-tweaks-btn {
    flex: 1;
    padding: 10px 14px;
    border: 1.5px solid #1a2418;
    background: #ffffff;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.theme-tweaks-btn:hover {
    background: #c8dc7e;
    transform: translate(-1px, -1px);
    box-shadow: 2px 2px 0 #1a2418;
}
.theme-tweaks-copy {
    background: #1a2418;
    color: #f1efe4;
}
.theme-tweaks-copy:hover {
    background: #2d5d3a;
    color: #f1efe4;
}

.theme-tweaks-toast {
    position: absolute;
    bottom: 60px;
    left: 16px; right: 16px;
    background: #2d5d3a;
    color: #f1efe4;
    padding: 8px 14px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    border: 1.5px solid #1a2418;
    box-shadow: 3px 3px 0 #1a2418;
    z-index: 1001;
    text-align: center;
    line-height: 1.4;
}
.theme-tweaks-toast[hidden] { display: none; }

@media (max-width: 480px) {
    .theme-tweaks {
        top: 0; right: 0; left: 0;
        width: auto;
        max-height: 70vh;
        box-shadow: 0 6px 0 #1a2418;
    }
}

/* -----------------------------------------------------------------------------
   Faircamp embed card — wrapper for {{> "faircamp-embed"}} partial
   ----------------------------------------------------------------------------- */
.faircamp-card {
    border: 2px solid var(--ink);
    background: var(--paper-2);
    box-shadow: 4px 4px 0 var(--ink);
    margin: 28px 0;
    overflow: hidden;
}
.faircamp-card-meta {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-soft);
    padding: 10px 14px;
    border-bottom: 1.5px solid var(--ink);
    background: var(--paper);
    margin: 0;
}
.faircamp-embed {
    width: 100%;
    height: 360px;
    border: 0;
    display: block;
    background: var(--paper);
}

@media (max-width: 640px) {
    .faircamp-card { margin: 20px 0; box-shadow: 3px 3px 0 var(--ink); }
    .faircamp-embed { height: 320px; }
}

/* -----------------------------------------------------------------------------
   Persistent audio player — sticky bottom bar (localStorage-backed)
   Layout: full-width scrubber on top, controls + meta + close on a row below
   ----------------------------------------------------------------------------- */
.player {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 200;
    background: var(--ink);
    color: var(--paper);
    border-top: 2px solid var(--ink);
    box-shadow: 0 -4px 24px rgba(26, 36, 24, 0.25);
    display: flex;
    flex-direction: column;
    font-family: var(--mono);
}
.player[hidden] { display: none; }

/* Scrubber sits at the very top of the bar, spanning full width. */
.player > .player-progress {
    width: 100%;
    height: 6px;
    background: rgba(241, 239, 228, 0.18);
    cursor: pointer;
    position: relative;
    outline: none;
    transition: height 0.15s ease, background 0.2s ease;
}
.player > .player-progress:hover,
.player > .player-progress:focus {
    height: 12px;
    background: rgba(241, 239, 228, 0.28);
}
.player > .player-progress .player-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--green-3);
    transition: width 0.1s linear;
}

/* Controls row — under the scrubber */
.player-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 12px 20px;
}

/* Push site footer up so it isn't covered by the player. */
body.has-player .site-footer { margin-bottom: 92px; }

.player-btn {
    background: transparent;
    border: 1.5px solid var(--paper);
    color: var(--paper);
    width: 40px; height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease;
    flex-shrink: 0;
}
.player-btn:hover {
    background: var(--green-3);
    color: var(--ink);
    border-color: var(--green-3);
}
.player-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}
.player-btn:disabled:hover {
    background: transparent;
    color: var(--paper);
    border-color: var(--paper);
}
.player-icon { width: 16px; height: 16px; }
.player-play .player-icon { width: 14px; height: 14px; }

/* Cluster of prev / play / next controls */
.player-controls {
    display: flex;
    gap: 6px;
    align-items: center;
}
.player-controls .player-btn { width: 36px; height: 36px; }
.player-controls .player-play { width: 44px; height: 44px; }
.player-controls .player-prev svg,
.player-controls .player-next svg { width: 14px; height: 14px; }

.player-meta {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
}
.player-title {
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--paper);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.player-time {
    font-size: 11px;
    color: var(--green-3);
    letter-spacing: 0.04em;
    display: inline-flex;
    gap: 4px;
}
.player-sep { opacity: 0.5; }

.player-close { border-color: rgba(241, 239, 228, 0.4); }

/* In-post audio player — fully replaces Ghost's native audio card.
   Synced to the persistent player at the bottom of every page; both
   are views of the same underlying audio element. */
.audio-handoff {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
    background: var(--paper-2);
    border: 2px solid var(--ink);
    width: 100%;
    color: var(--ink);
    font-family: var(--sans);
    margin: 24px 0;
    box-shadow: 3px 3px 0 var(--ink);
    transition: background 0.2s ease;
}
.audio-handoff.is-loaded { background: var(--paper); }
.audio-handoff.is-playing { background: var(--paper); border-color: var(--green-1); box-shadow: 3px 3px 0 var(--green-1); }

.audio-handoff-play {
    width: 52px; height: 52px;
    background: var(--ink);
    color: var(--green-3);
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
                box-shadow 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
                background 0.2s ease;
    box-shadow: 2px 2px 0 var(--green-1);
}
.audio-handoff-play:hover,
.audio-handoff-play:focus-visible {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0 var(--green-1);
    background: var(--green-1);
    color: var(--green-3);
    outline: none;
}
.audio-handoff-play:active {
    transform: translate(0, 0);
    box-shadow: 1px 1px 0 var(--green-1);
}
.audio-handoff-play svg { width: 18px; height: 18px; }
.audio-handoff.is-playing .audio-handoff-play { background: var(--green-1); color: var(--paper); }

.audio-handoff-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    flex: 1;
}
.audio-handoff-title {
    font-family: var(--display);
    font-weight: 600;
    font-size: 18px;
    letter-spacing: -0.01em;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--ink);
}

/* Scrubber — visible at all times, but only the click handler activates
   when the audio is loaded. Idle state is a flat hairline; loaded state
   shows the green progress fill. */
.audio-handoff-progress {
    height: 6px;
    background: var(--hairline);
    cursor: pointer;
    position: relative;
    outline: none;
    transition: height 0.15s ease, background 0.2s ease;
}
.audio-handoff-progress:hover,
.audio-handoff-progress:focus { height: 10px; }
.audio-handoff-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--green-2);
    transition: width 0.1s linear, background 0.2s ease;
}
.audio-handoff.is-playing .audio-handoff-progress-fill { background: var(--green-1); }

.audio-handoff-time {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    color: var(--ink-mute);
    display: inline-flex;
    gap: 4px;
}
.audio-handoff.is-loaded .audio-handoff-time { color: var(--ink-soft); }
.audio-handoff-sep { opacity: 0.5; }

/* Mobile: stack play button on top so the scrubber has full width */
@media (max-width: 540px) {
    .audio-handoff {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
        padding: 14px;
    }
    .audio-handoff-play {
        width: 100%;
        height: 48px;
    }
}

/* -----------------------------------------------------------------------------
   Store embed — full-width iframe of an external site (e.g. Cargo.site)
   that fills the viewport between header and footer. Bleeds beyond the
   .page horizontal padding so the embedded site has maximum room.
   ----------------------------------------------------------------------------- */
.store-embed {
    /* Bleed past the .page 32px horizontal padding for full-width feel */
    margin: 16px -32px 32px;
    border: 2px solid var(--ink);
    background: var(--paper-2);
    box-shadow: 4px 4px 0 var(--ink);
    overflow: hidden;
    /* Reserve a nice tall area; ~80vh leaves room for header+footer
       within most viewport heights without forcing inner scrolling */
    height: 82vh;
    min-height: 600px;
}
.store-embed-frame {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: var(--paper);
}

/* When the persistent player bar is up, leave room so it doesn't cover
   the bottom edge of the iframe */
body.has-player .store-embed { margin-bottom: 96px; }

@media (max-width: 900px) {
    .store-embed {
        margin: 12px -16px 24px;
        height: 78vh;
        min-height: 500px;
        box-shadow: 3px 3px 0 var(--ink);
    }
}
@media (max-width: 640px) {
    .store-embed {
        margin: 8px -16px 20px;
        height: 75vh;
        min-height: 480px;
    }
}

/* -----------------------------------------------------------------------------
   Contact form — styled wrapper for the Web3Forms-backed contact page
   ----------------------------------------------------------------------------- */
.contact-wrap {
    max-width: 640px;
    margin: 24px auto 96px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.contact-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.contact-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.contact-label {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-soft);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.5;
    color: var(--ink);
    background: var(--paper);
    border: 2px solid var(--ink);
    padding: 12px 14px;
    width: 100%;
    box-shadow: 3px 3px 0 var(--ink);
    transition: box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
    border-radius: 0;
    -webkit-appearance: none;
    appearance: none;
}
.contact-form textarea {
    resize: vertical;
    min-height: 160px;
    font-family: var(--sans);
}
.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--ink-mute);
    font-style: italic;
}
.contact-form input:hover,
.contact-form textarea:hover {
    background: var(--paper-2);
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    background: var(--paper);
    box-shadow: 5px 5px 0 var(--green-1);
    transform: translate(-1px, -1px);
    border-color: var(--green-1);
}

.contact-form input:invalid:not(:placeholder-shown),
.contact-form textarea:invalid:not(:placeholder-shown) {
    border-color: var(--green-1);
}

.contact-actions {
    display: flex;
    justify-content: flex-start;
    margin-top: 4px;
}

.contact-submit {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    font-family: var(--display);
    font-weight: 600;
    font-size: 18px;
    letter-spacing: -0.01em;
    color: var(--paper);
    background: var(--ink);
    border: 2px solid var(--ink);
    padding: 14px 22px;
    cursor: pointer;
    box-shadow: 4px 4px 0 var(--green-1);
    transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
                box-shadow 0.2s cubic-bezier(0.2, 0.8, 0.2, 1),
                background 0.2s ease,
                color 0.2s ease;
}
.contact-submit:hover,
.contact-submit:focus-visible {
    background: var(--green-1);
    color: var(--green-3);
    transform: translate(-3px, -3px);
    box-shadow: 7px 7px 0 var(--green-1);
    outline: none;
}
.contact-submit:active {
    transform: translate(0, 0);
    box-shadow: 1px 1px 0 var(--green-1);
}
.contact-submit:disabled {
    opacity: 0.6;
    cursor: wait;
    transform: none;
    box-shadow: 4px 4px 0 var(--green-1);
}
.contact-submit-arrow {
    font-family: var(--display);
    font-size: 22px;
    line-height: 1;
}

.contact-status {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink-soft);
    min-height: 1em;
}
.contact-status.is-error { color: var(--green-1); font-weight: 600; }

/* Success state — replaces the form on successful submit */
.contact-success {
    text-align: center;
    padding: 48px 24px;
    background: var(--paper-2);
    border: 2px solid var(--ink);
    box-shadow: 4px 4px 0 var(--green-1);
}
.contact-success[hidden] { display: none; }
.contact-success h2 {
    font-family: var(--display);
    font-size: clamp(36px, 6vw, 56px);
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--ink);
    margin-bottom: 12px;
}
.contact-success p {
    font-family: var(--sans);
    font-size: 17px;
    color: var(--ink-soft);
    max-width: 380px;
    margin: 0 auto 28px;
}
.contact-success-again {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink);
    background: transparent;
    border: 2px solid var(--ink);
    padding: 10px 18px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.contact-success-again:hover {
    background: var(--ink);
    color: var(--green-3);
}

@media (max-width: 640px) {
    .contact-wrap { margin: 16px auto 64px; }
    .contact-form input[type="text"],
    .contact-form input[type="email"],
    .contact-form textarea {
        font-size: 16px; /* keep at 16px so iOS doesn't zoom on focus */
        padding: 10px 12px;
        box-shadow: 2px 2px 0 var(--ink);
    }
    .contact-submit {
        width: 100%;
        justify-content: center;
        font-size: 17px;
        padding: 12px 18px;
        box-shadow: 3px 3px 0 var(--green-1);
    }
}

/* -----------------------------------------------------------------------------
   Footer
   ----------------------------------------------------------------------------- */
.site-footer {
    margin-top: 64px;
    padding-top: 32px;
    border-top: 2px solid var(--ink);
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 24px;
}
.site-footer-left {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.site-footer-mark {
    font-family: var(--display);
    font-weight: 700;
    font-size: clamp(24px, 4vw, 48px);
    letter-spacing: -0.04em;
    line-height: 0.9;
    color: var(--ink);
}
.site-footer-mark .dot { color: var(--red); }
.site-footer-meta {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-mute);
    display: flex;
    gap: 12px;
    align-items: center;
}
.site-footer-meta .sep { opacity: 0.5; }

/* Footer nav — mirrors the top header nav on the right side */
.site-footer-nav ul {
    list-style: none;
    display: flex;
    gap: 22px;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.site-footer-nav a {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    padding-bottom: 2px;
    transition: border-color 0.2s ease, color 0.2s ease;
}
.site-footer-nav a:hover { border-bottom-color: var(--red); }

/* -----------------------------------------------------------------------------
   Responsive
   ----------------------------------------------------------------------------- */
@media (max-width: 900px) {
    .grid { grid-template-columns: repeat(2, 1fr); }
    .photo-wall-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .related-grid { grid-template-columns: repeat(2, 1fr); }

    .post-row {
        grid-template-columns: 80px 1fr 24px;
        gap: 16px;
        padding: 14px 8px;
    }
    .post-row-thumb { width: 80px; }
    .post-row-meta {
        grid-column: 2;
        grid-row: 1;
        flex-direction: row;
        gap: 10px;
        align-items: center;
    }
    .post-row-title { grid-column: 2; grid-row: 2; font-size: 18px; }
    .post-row-arrow { grid-row: 1 / 3; align-self: center; }
    .post-row:hover { padding-left: 14px; }

    /* Tag-list rows on tablet: thumb left, title+excerpt stacked right */
    .post-list-tag .post-row {
        grid-template-columns: 100px 1fr 24px;
        gap: 18px;
        padding: 18px 8px;
    }
    .post-list-tag .post-row-thumb { width: 100px; }
    .post-row-body {
        grid-column: 2;
        grid-row: 1 / 3;
    }
    .post-list-tag .post-row-title { font-size: 19px; }
    .post-list-tag .post-row-arrow { margin-top: 0; }
}

@media (max-width: 640px) {
    .page { padding: 0 16px 48px; }
    .signup-strip { padding: 12px 16px; }
    .signup-form { width: 100%; }
    .signup-form input[type="email"] { flex: 1; width: auto; }

    .home-template .hero { padding-top: 56px; }
    .hero { padding: 48px 0 36px; }

    .grid { gap: 10px; }
    .tile-label { left: 12px; right: 12px; bottom: 12px; }
    .tile-arrow { font-size: 18px; }

    .photo-wall-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

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

    .post-feature { width: calc(100% + 32px); margin-left: -16px; margin-right: -16px; }
    .post-body { font-size: 17px; }

    /* On phones the excerpt becomes too cramped; let the title carry the row.
       Explicitly re-define the grid to make sure the thumbnail stays on the
       left and the title sits to its right (avoiding inheritance ambiguity). */
    .post-list-tag .post-row {
        grid-template-columns: 80px 1fr;
        gap: 14px;
        padding: 14px 4px;
        align-items: center;
    }
    .post-list-tag .post-row-thumb {
        width: 80px;
        grid-column: 1;
        grid-row: 1;
    }
    .post-list-tag .post-row-body {
        grid-column: 2;
        grid-row: 1;
        gap: 4px;
    }
    .post-list-tag .post-row-arrow { display: none; }
    .post-list-tag .post-row-excerpt { display: none; }
    .post-list-tag .post-row-title { font-size: 16px; }

    .site-footer { flex-direction: column; align-items: flex-start; }
    .site-footer-nav ul { justify-content: flex-start; }
    .tag-feature { margin: 0 -16px 40px; }

    /* Mobile player: tighter padding */
    .player-row {
        gap: 10px;
        padding: 10px 12px;
    }
    .player > .player-progress { height: 5px; }
    .player > .player-progress:hover,
    .player > .player-progress:focus { height: 9px; }
    .player-btn { width: 36px; height: 36px; }
    .player-controls { gap: 4px; }
    .player-controls .player-btn { width: 32px; height: 32px; }
    .player-controls .player-play { width: 40px; height: 40px; }
    body.has-player .site-footer { margin-bottom: 80px; }
}

/* =============================================================================
   Subscribe popup
   ============================================================================= */
.sub-popup {
    position: fixed;
    inset: 0;
    z-index: 9000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.sub-popup[hidden] { display: none; }

.sub-popup-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 14, 10, 0.72);
    backdrop-filter: blur(3px);
    cursor: pointer;
}

.sub-popup-box {
    position: relative;
    background: var(--paper);
    border: 2px solid var(--ink);
    box-shadow: 6px 6px 0 var(--green-1);
    padding: 40px 36px 32px;
    max-width: 420px;
    width: 100%;
    animation: popup-in 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes popup-in {
    from { opacity: 0; transform: translateY(20px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.sub-popup-close {
    position: absolute;
    top: 12px; right: 14px;
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    color: var(--ink);
    opacity: 0.5;
    padding: 4px 8px;
    line-height: 1;
    transition: opacity 0.15s;
}
.sub-popup-close:hover { opacity: 1; }

.sub-popup-kicker {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--green-2);
    margin: 0 0 10px;
}

.sub-popup-heading {
    font-family: 'Fraunces', serif;
    font-size: clamp(26px, 5vw, 34px);
    font-weight: 700;
    line-height: 1.1;
    margin: 0 0 24px;
    color: var(--ink);
}

.sub-popup-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sub-popup-form input[type="email"] {
    width: 100%;
    padding: 11px 14px;
    border: 2px solid var(--ink);
    background: var(--paper);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 14px;
    color: var(--ink);
    box-shadow: 3px 3px 0 var(--ink);
    outline: none;
    transition: box-shadow 0.15s;
    box-sizing: border-box;
}
.sub-popup-form input[type="email"]:focus {
    box-shadow: 3px 3px 0 var(--green-1);
}

.sub-popup-form button[type="submit"] {
    padding: 12px 20px;
    background: var(--ink);
    color: var(--paper);
    border: 2px solid var(--ink);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 3px 3px 0 var(--green-1);
    transition: transform 0.15s, box-shadow 0.15s;
}
.sub-popup-form button[type="submit"]:hover {
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0 var(--green-1);
}

.sub-popup-success {
    display: none;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 14px;
    color: var(--green-2);
    margin: 16px 0 0;
    font-weight: 600;
}
.sub-popup.is-success .sub-popup-form { display: none; }
.sub-popup.is-success .sub-popup-success { display: block; }
.sub-popup.is-success .sub-popup-skip { display: none; }

.sub-popup-skip {
    margin: 14px 0 0;
    text-align: center;
}
.sub-popup-skip-btn {
    background: none;
    border: none;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    color: var(--ink);
    opacity: 0.45;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
    transition: opacity 0.15s;
}
.sub-popup-skip-btn:hover { opacity: 0.8; }

@media (max-width: 480px) {
    .sub-popup-box { padding: 32px 20px 24px; }
}

/* =============================================================================
   Releases grid
   ============================================================================= */
.releases-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 28px;
    padding: 32px 0 64px;
}

.release-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--ink);
    border: 2px solid var(--ink);
    box-shadow: 4px 4px 0 var(--green-1);
    transition: transform 0.18s cubic-bezier(0.2,0.8,0.2,1),
                box-shadow 0.18s cubic-bezier(0.2,0.8,0.2,1);
    background: var(--paper);
    overflow: hidden;
}
.release-card:hover {
    transform: translate(-3px, -3px);
    box-shadow: 7px 7px 0 var(--green-1);
}

.release-card-img {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--green-3);
}
.release-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}
.release-card:hover .release-card-img img {
    transform: scale(1.04);
}
.release-card-img-empty {
    background: repeating-linear-gradient(
        45deg,
        var(--green-3),
        var(--green-3) 4px,
        var(--paper) 4px,
        var(--paper) 16px
    );
}

.release-card-body {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.release-card-title {
    font-family: 'Fraunces', serif;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.2;
}

.release-card-date {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1em;
    color: var(--green-2);
    text-transform: uppercase;
}

@media (max-width: 640px) {
    .releases-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
    .release-card-title { font-size: 15px; }
}

/* =============================================================================
   Section nav — site-wide page links at the bottom of posts/pages
   ============================================================================= */
.section-nav {
    margin: 64px 0 40px;
    padding: 28px 0;
    border-top: 2px solid var(--ink);
    border-bottom: 2px solid var(--ink);
    display: flex;
    align-items: center;
    gap: 32px;
    flex-wrap: wrap;
}

.section-nav-label {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--green-2);
    white-space: nowrap;
}

.section-nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 4px;
}

.section-nav-links li a {
    display: inline-block;
    padding: 7px 16px;
    border: 2px solid var(--ink);
    background: var(--paper);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--ink);
    box-shadow: 3px 3px 0 var(--green-1);
    transition: transform 0.15s cubic-bezier(0.2,0.8,0.2,1),
                box-shadow 0.15s cubic-bezier(0.2,0.8,0.2,1),
                background 0.15s ease;
}

.section-nav-links li a:hover {
    background: var(--ink);
    color: var(--paper);
    transform: translate(-2px, -2px);
    box-shadow: 5px 5px 0 var(--green-1);
}

@media (max-width: 640px) {
    .section-nav { gap: 16px; }
    .section-nav-links li a { font-size: 11px; padding: 6px 12px; }
}
