/* ==========================================================================
   Umbaba's World: Ghost theme
   Purple + walnut + black on warm cream. Leopard is trim, never a surface.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
    --bg: #F6F1E7;
    --surface: #FCFAF4;
    --ink: #1A1814;
    --ink-2: #4A443A;
    --muted: #756D5E;
    --line: #1A1814;
    --line-soft: rgba(26, 24, 20, 0.16);

    --purple: #5B2A86;
    --purple-ink: #FFFFFF;
    --purple-tint: #EBE1F4;

    --brown: #8B6240;
    --brown-ink: #FFFFFF;
    --brown-tint: #EFE3D2;

    --font-display: var(--gh-font-heading, "Fraunces", Georgia, "Times New Roman", serif);
    --font-ui: var(--gh-font-body, "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);

    --gutter: clamp(16px, 4vw, 32px);
    --wide: 1100px;
    --narrow: 700px;
    --radius: 14px;

    --leopard: url("../images/leopard.svg");
    --leopard-purple: url("../images/leopard-purple.svg");
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #151210;
        --surface: #1E1A17;
        --ink: #F1EADB;
        --ink-2: #CFC6B3;
        --muted: #9A917F;
        --line: #F1EADB;
        --line-soft: rgba(241, 234, 219, 0.18);

        --purple: #B692E3;
        --purple-ink: #1A1024;
        --purple-tint: #2A1D3A;

        --brown: #C9A06C;
        --brown-ink: #1E1408;
        --brown-tint: #2C241B;
    }
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font-ui);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: clip;
    -webkit-font-smoothing: antialiased;
}

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

a { color: var(--purple); text-underline-offset: 3px; }
a:hover { color: var(--ink); }

h1, h2, h3, h4 {
    font-family: var(--font-display);
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 0.5em;
}

p { margin: 0 0 1em; }

code {
    font-size: 0.88em;
    background: var(--purple-tint);
    color: var(--purple);
    padding: 2px 6px;
    border-radius: 6px;
}

:focus-visible {
    outline: 3px solid var(--purple);
    outline-offset: 3px;
    border-radius: 4px;
}

.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;
}

.wrap { width: 100%; max-width: calc(var(--wide) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.wrap-narrow { width: 100%; max-width: calc(var(--narrow) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }

.site-main { min-height: 60vh; padding-bottom: 72px; }

.eyebrow {
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--purple);
    margin: 0 0 12px;
}

.empty { color: var(--muted); font-style: italic; grid-column: 1 / -1; }

/* ---------- 3. Leopard trim ---------- */
.leopard-rule {
    height: 14px;
    background-color: #D8B070;
    background-image: var(--leopard);
    background-size: 150px 150px;
    background-repeat: repeat-x;
    background-position: center;
    border-block: 1.5px solid var(--line);
}

/* ---------- 4. Header ---------- */
.site-header { background: var(--bg); position: relative; z-index: 20; }

.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-block: 16px;
}

.site-brand { text-decoration: none; color: var(--ink); display: inline-flex; align-items: center; }
.site-title { font-family: var(--font-display); font-weight: 700; font-size: 1.45rem; letter-spacing: -0.02em; }
.site-logo { max-height: 36px; width: auto; }

.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 0; padding: 0; }
.site-nav a {
    color: var(--ink-2);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--ink); border-bottom-color: var(--purple); }
.site-nav .is-current a { color: var(--purple); border-bottom-color: var(--purple); }

.nav-toggle {
    display: none;
    width: 42px; height: 42px;
    background: transparent;
    border: 1.5px solid var(--line);
    border-radius: 10px;
    cursor: pointer;
    padding: 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}
.nav-toggle span { display: block; width: 18px; height: 2px; background: var(--ink); transition: transform 0.2s, opacity 0.2s; }
.site-header.is-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.site-header.is-open .nav-toggle span:nth-child(2) { opacity: 0; }
.site-header.is-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
    .site-header-inner { flex-wrap: wrap; }
    .nav-toggle { display: inline-flex; }
    .site-nav { display: none; width: 100%; padding-bottom: 8px; }
    .site-header.is-open .site-nav { display: block; }
    .site-nav ul { flex-direction: column; gap: 0; }
    .site-nav a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line-soft); font-size: 16px; }
}

/* ---------- 5. Buttons and forms ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-ui);
    font-size: 15px;
    font-weight: 600;
    background: var(--purple);
    color: var(--purple-ink);
    border: 1.5px solid var(--line);
    border-radius: 999px;
    padding: 12px 22px;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 3px 3px 0 var(--line);
    transition: transform 0.12s, box-shadow 0.12s;
}
.btn:hover { color: var(--purple-ink); transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--line); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--line); }

.subscribe-form { display: flex; flex-wrap: wrap; gap: 12px; max-width: 520px; }
.subscribe-input {
    flex: 1 1 220px;
    min-width: 0;
    font-family: var(--font-ui);
    font-size: 16px;
    color: var(--ink);
    background: var(--surface);
    border: 1.5px solid var(--line);
    border-radius: 999px;
    padding: 12px 18px;
}
.subscribe-input::placeholder { color: var(--muted); }
.btn-loading { display: none; }
.subscribe-form.loading .btn-default { display: none; }
.subscribe-form.loading .btn-loading { display: inline; }
.subscribe-msg { display: none; flex-basis: 100%; margin: 0; font-size: 14px; }
.subscribe-form.success .subscribe-msg--ok { display: block; color: var(--purple); font-weight: 600; }
.subscribe-form.error .subscribe-msg--err { display: block; color: #B3261E; font-weight: 600; }

/* ---------- 6. Hero ---------- */
.hero { position: relative; padding: clamp(48px, 9vw, 104px) 0 clamp(40px, 7vw, 72px); }
.hero-inner { position: relative; z-index: 1; }
.hero-title {
    font-size: clamp(2.8rem, 8vw, 5.6rem);
    font-weight: 700;
    line-height: 1.02;
    letter-spacing: -0.035em;
    max-width: 14ch;
    margin-bottom: 20px;
}
.hero-text { font-family: var(--font-display); font-size: clamp(1.1rem, 2.4vw, 1.4rem); color: var(--ink-2); max-width: 36em; margin-bottom: 28px; }
.hero-subscribe { margin-top: 8px; }

.hero::after {
    content: "";
    position: absolute;
    right: max(var(--gutter), calc((100vw - var(--wide)) / 2));
    top: clamp(36px, 7vw, 88px);
    width: clamp(110px, 18vw, 220px);
    aspect-ratio: 1;
    border-radius: 50%;
    background: var(--leopard-purple);
    background-size: 160px 160px;
    border: 1.5px solid var(--line);
    box-shadow: 6px 6px 0 var(--line);
}
@media (max-width: 700px) { .hero::after { display: none; } }

/* ---------- 7. Sections and cards ---------- */
.section-row { padding-top: 56px; }
.section-row-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 20px; border-bottom: 1.5px solid var(--line); padding-bottom: 10px; }
.section-row-title { font-size: clamp(1.4rem, 3vw, 1.9rem); margin: 0; }
.section-row-more { font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.section-row-more:hover { text-decoration: underline; }

.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }

.post-card {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1.5px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.15s;
}
.post-card:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--purple); }
.post-card-image-link { display: block; border-bottom: 1.5px solid var(--line); }
.post-card-image { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.post-card-body { padding: 18px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.post-card-title { font-size: 1.3rem; margin: 12px 0 8px; }
.post-card-title a { color: var(--ink); text-decoration: none; }
.post-card-title a:hover { color: var(--purple); }
.post-card-excerpt { color: var(--ink-2); font-size: 15px; flex: 1; }
.post-card-meta { color: var(--muted); font-size: 13px; margin: 0; }

/* Tag pills: one voice per section */
.tag-pill {
    align-self: flex-start;
    display: inline-block;
    font-family: var(--font-ui);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    padding: 4px 11px;
    border-radius: 6px;
    border: 1.5px solid var(--line);
    background: var(--surface);
    color: var(--ink);
}
.tag-pill:hover { color: inherit; filter: brightness(1.08); }
.tag-pill--journal { background: var(--purple); color: var(--purple-ink); }
.tag-pill--interviews { background: var(--brown); color: var(--brown-ink); }
.tag-pill--random-thoughts { background: var(--ink); color: var(--bg); }
.tag-pill--bringing-blogs-to-life {
    border: 3px solid transparent;
    background:
        linear-gradient(var(--surface), var(--surface)) padding-box,
        var(--leopard-purple) border-box;
    background-size: auto, 90px 90px;
    padding: 2px 9px;
}

/* ---------- 8. Random thoughts (home preview) ---------- */
.thought-list { display: grid; gap: 0; border-top: 1.5px solid var(--line); }
.thought { display: grid; grid-template-columns: 76px 1fr; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line-soft); }
.thought-date { font-size: 13px; font-weight: 600; color: var(--purple); text-transform: uppercase; letter-spacing: 0.06em; padding-top: 4px; }
.thought-title { font-size: 1.1rem; margin: 0 0 4px; }
.thought-title a { color: var(--ink); text-decoration: none; }
.thought-title a:hover { color: var(--purple); }
.thought-body p { margin: 0; color: var(--ink-2); }

/* ---------- 9. Archive pages ---------- */
.archive-head { padding-top: clamp(40px, 7vw, 80px); padding-bottom: 28px; }
.archive-title { font-size: clamp(2.4rem, 6vw, 4rem); letter-spacing: -0.03em; margin-bottom: 10px; }
.archive-desc { font-family: var(--font-display); font-size: 1.2rem; color: var(--ink-2); max-width: 36em; }

/* Interviews list */
.interview-list { display: grid; gap: 28px; }
.interview-card {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    background: var(--surface);
    border: 1.5px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.15s;
}
.interview-card:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--brown); }
.interview-card-media { position: relative; display: block; background: var(--brown-tint); border-right: 1.5px solid var(--line); min-height: 220px; }
.interview-card-media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 16 / 10; }
.play-badge {
    position: absolute; left: 50%; top: 50%; width: 64px; height: 64px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: var(--purple);
    border: 1.5px solid var(--line);
    box-shadow: 3px 3px 0 var(--line);
}
.play-badge::after {
    content: ""; position: absolute; left: 27px; top: 19px;
    border-left: 18px solid var(--purple-ink);
    border-top: 13px solid transparent; border-bottom: 13px solid transparent;
}
.interview-card-body { padding: 26px 28px; display: flex; flex-direction: column; justify-content: center; }
.interview-card-title { font-size: clamp(1.4rem, 3vw, 1.9rem); margin: 14px 0 10px; }
.interview-card-title a { color: var(--ink); text-decoration: none; }
.interview-card-title a:hover { color: var(--brown); }
.interview-card-excerpt { color: var(--ink-2); }
@media (max-width: 760px) {
    .interview-card { grid-template-columns: 1fr; }
    .interview-card-media { border-right: 0; border-bottom: 1.5px solid var(--line); }
}

/* Random thoughts stream */
.thought-stream { border-top: 1.5px solid var(--line); }
.thought-full { padding: 28px 0; border-bottom: 1px solid var(--line-soft); }
.thought-full-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--purple); }
.thought-permalink { color: var(--muted); text-decoration: none; font-size: 18px; }
.thought-permalink:hover { color: var(--purple); }
.thought-full-title { font-size: 1.3rem; margin-bottom: 8px; }
.thought-full-title a { color: var(--ink); text-decoration: none; }
.thought-full-body { font-size: 1.05rem; }
.thought-full-body > *:last-child { margin-bottom: 0; }

/* Pagination (Ghost's default {{pagination}} markup) */
.pagination { display: flex; justify-content: space-between; align-items: center; margin-top: 44px; padding-top: 16px; border-top: 1.5px solid var(--line); font-size: 14px; font-weight: 600; }
.pagination a { text-decoration: none; }
.pagination .page-number { color: var(--muted); font-weight: 500; }

/* ---------- 10. Entry (single post / page) ---------- */
.entry-head { padding-top: clamp(40px, 7vw, 80px); padding-bottom: 28px; }
.entry-head .tag-pill { margin-bottom: 18px; }
.entry-title { font-size: clamp(2.2rem, 6vw, 3.8rem); letter-spacing: -0.03em; line-height: 1.05; margin-bottom: 16px; }
.entry-lede { font-family: var(--font-display); font-size: clamp(1.15rem, 2.5vw, 1.45rem); color: var(--ink-2); line-height: 1.4; margin-bottom: 18px; }
.entry-meta { font-size: 14px; color: var(--muted); margin: 0; }

.entry-head-spacer { height: clamp(32px, 6vw, 64px); }
.entry-feature { margin-block: 8px 40px; }
.entry-feature img { width: 100%; border: 1.5px solid var(--line); border-radius: var(--radius); box-shadow: 6px 6px 0 var(--purple); }
.entry-feature figcaption, .gh-content figcaption { font-size: 13px; color: var(--muted); text-align: center; margin-top: 12px; }
.entry-portrait { margin-bottom: 32px; }
.entry-portrait img { width: 100%; max-width: 420px; margin-inline: auto; border: 1.5px solid var(--line); border-radius: var(--radius); box-shadow: 6px 6px 0 var(--purple); }

.entry-cta { margin-top: 56px; padding-block: 32px; border-top: 1.5px solid var(--line); }
.entry-cta h2 { font-size: 1.6rem; }
.entry-cta p { color: var(--ink-2); }

.more-from { margin-top: 24px; }

/* Long-form body */
.gh-content { font-family: var(--font-display); font-size: 1.15rem; line-height: 1.75; color: var(--ink); }
.gh-content > * + * { margin-top: 1.5em; margin-bottom: 0; }
.gh-content h2 { font-size: 1.9rem; margin-top: 2.2em; }
.gh-content h3 { font-size: 1.45rem; margin-top: 1.8em; }
.gh-content a { color: var(--purple); font-weight: 500; }
.gh-content a:hover { color: var(--ink); }
.gh-content img { border-radius: 10px; }
.gh-content ul, .gh-content ol { padding-left: 1.4em; }
.gh-content li + li { margin-top: 0.4em; }
.gh-content hr { border: 0; height: 14px; background-color: #D8B070; background-image: var(--leopard); background-size: 140px 140px; background-position: center; border-block: 1.5px solid var(--line); margin-block: 2.5em; }
.gh-content blockquote:not([class]) { margin-inline: 0; padding: 4px 0 4px 22px; border-left: 4px solid var(--purple); font-style: italic; font-size: 1.3rem; line-height: 1.5; color: var(--ink-2); }
.gh-content pre { background: var(--ink); color: var(--bg); padding: 18px 20px; border-radius: 10px; overflow-x: auto; font-size: 0.9rem; line-height: 1.55; }
.gh-content :not(pre) > code { font-size: 0.85em; }

/* Koenig editor card widths (required by Ghost) */
.kg-width-wide {
    position: relative;
    width: min(1040px, calc(100vw - 2 * var(--gutter)));
    left: 50%;
    transform: translateX(-50%);
}
.kg-width-full {
    position: relative;
    width: 100vw;
    left: 50%;
    transform: translateX(-50%);
}
.kg-width-full img { border-radius: 0; }

.kg-card { margin-block: 2em; }
.kg-image-card img, .kg-gallery-image img { width: 100%; }
.kg-gallery-container { display: flex; flex-direction: column; gap: 10px; }
.kg-gallery-row { display: flex; gap: 10px; }
.kg-gallery-image { flex: 1 1 0; min-width: 0; }
.kg-gallery-image img { height: 100%; object-fit: cover; cursor: zoom-in; }

/* Video and embeds (Cloudflare Stream, YouTube, etc.) */
.kg-embed-card { display: flex; flex-direction: column; align-items: center; }
.kg-embed-card iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 1.5px solid var(--line); border-radius: var(--radius); }
.kg-video-card video { width: 100%; border-radius: var(--radius); border: 1.5px solid var(--line); }

/* Bookmark card */
.kg-bookmark-card { position: relative; }
.kg-bookmark-container { display: flex; min-height: 120px; color: var(--ink); text-decoration: none; background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--radius); overflow: hidden; font-family: var(--font-ui); }
.kg-bookmark-container:hover { color: var(--ink); box-shadow: 4px 4px 0 var(--purple); }
.kg-bookmark-content { flex: 1; padding: 18px 20px; min-width: 0; }
.kg-bookmark-title { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; line-height: 1.25; }
.kg-bookmark-description { font-size: 14px; color: var(--ink-2); margin-top: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kg-bookmark-metadata { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.kg-bookmark-icon { width: 20px; height: 20px; border-radius: 4px; }
.kg-bookmark-thumbnail { flex: 0 0 32%; position: relative; border-left: 1.5px solid var(--line); }
.kg-bookmark-thumbnail img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 0; }

.kg-callout-card { display: flex; gap: 12px; padding: 18px 20px; border-radius: var(--radius); background: var(--purple-tint); font-family: var(--font-ui); font-size: 1rem; }

/* ---------- 11. Interview layout ---------- */
.wrap.interview-body { max-width: calc(var(--narrow) + 2 * var(--gutter)); }
.interview-body > :is(.kg-embed-card, .kg-video-card, .kg-html-card):first-child {
    position: relative;
    width: min(1040px, calc(100vw - 2 * var(--gutter)));
    left: 50%;
    transform: translateX(-50%);
    margin-top: 0;
    margin-bottom: 2.4em;
}
.interview-body > :is(.kg-embed-card, .kg-video-card, .kg-html-card):first-child :is(iframe, video) { box-shadow: 6px 6px 0 var(--brown); }
.kg-html-card iframe { max-width: 100%; }
.kg-html-card > div[style*="padding-top"] { border-radius: var(--radius); overflow: hidden; }

/* ---------- 12. Bringing blogs to life layout ---------- */
.entry--blogs .gh-content { counter-reset: step; }

/* The first bookmark card becomes the "Inspired by" callout */
.entry--blogs .gh-content > .kg-bookmark-card:first-child::before {
    content: "Inspired by";
    display: inline-block;
    font-family: var(--font-ui);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--purple-ink);
    background: var(--purple);
    border: 1.5px solid var(--line);
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
    padding: 4px 12px;
    margin-left: 18px;
}
.entry--blogs .gh-content > .kg-bookmark-card:first-child .kg-bookmark-container { border-radius: var(--radius); border-left: 6px solid var(--purple); }

/* H2s become numbered steps: What they said / What I tried / What I learned */
.entry--blogs .gh-content > h2 { counter-increment: step; position: relative; padding-left: 64px; }
.entry--blogs .gh-content > h2::before {
    content: counter(step);
    position: absolute;
    left: 0; top: 0.05em;
    width: 44px; height: 44px;
    display: grid; place-items: center;
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--purple-ink);
    background: var(--purple);
    border: 1.5px solid var(--line);
    border-radius: 50%;
    box-shadow: 3px 3px 0 var(--line);
}
@media (max-width: 520px) { .entry--blogs .gh-content > h2 { padding-left: 54px; } .entry--blogs .gh-content > h2::before { width: 38px; height: 38px; } }

/* ---------- 13. Gallery ---------- */
.gallery-intro:empty { display: none; }
.gallery-intro > * { max-width: var(--narrow); margin-inline: auto; }
.gallery-intro > :is(.kg-width-wide, .kg-width-full, .kg-gallery-card, .kg-image-card) { max-width: none; }
.gallery-intro > .kg-gallery-card { width: 100%; left: 0; transform: none; }

.gallery-section { padding-top: 32px; }
.gallery-grid { column-width: 260px; column-gap: 16px; }
.gallery-tile {
    position: relative;
    display: block;
    break-inside: avoid;
    margin: 0 0 16px;
    border: 1.5px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
    text-decoration: none;
    color: var(--ink);
    transition: transform 0.15s, box-shadow 0.15s;
}
.gallery-tile:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--purple); color: var(--ink); }
.gallery-tile img { width: 100%; }
.gallery-caption { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px 12px; font-size: 13px; color: var(--muted); border-top: 1.5px solid var(--line); }
.gallery-caption-title { font-family: var(--font-display); font-size: 1rem; font-weight: 600; color: var(--ink); line-height: 1.25; }
.gallery-tile--video::after {
    content: ""; position: absolute; right: 12px; top: 12px; width: 38px; height: 38px;
    border-radius: 50%; background: var(--purple); border: 1.5px solid var(--line);
}
.gallery-tile--video::before {
    content: ""; position: absolute; right: 22px; top: 21px; z-index: 1;
    border-left: 11px solid var(--purple-ink);
    border-top: 8px solid transparent; border-bottom: 8px solid transparent;
}
.gallery-grid .empty { column-span: all; }

/* Lightbox (created by main.js) */
.lightbox {
    position: fixed; inset: 0; z-index: 100;
    display: none; align-items: center; justify-content: center;
    background: rgba(12, 10, 8, 0.92); padding: 24px; cursor: zoom-out;
}
.lightbox.is-open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; width: auto; border-radius: 8px; }

/* ---------- 14. Subscribe page ---------- */
.subscribe-panel { padding-bottom: 12px; }
.subscribe-already { font-family: var(--font-display); font-size: 1.2rem; color: var(--purple); font-weight: 600; }

/* ---------- 15. Error page ---------- */
.error-page { padding-top: clamp(56px, 10vw, 120px); text-align: left; }
.error-code { font-family: var(--font-display); font-size: clamp(5rem, 20vw, 10rem); font-weight: 700; line-height: 0.9; color: var(--purple); margin: 0 0 12px; letter-spacing: -0.04em; }

/* ---------- 16. Footer ---------- */
.site-footer { margin-top: 24px; background: var(--bg); }
.site-footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; padding-block: 32px 12px; }
.footer-title { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; margin: 0 0 4px; }
.footer-note { color: var(--ink-2); margin: 0; }
.footer-right { display: flex; flex-wrap: wrap; gap: 8px 24px; align-items: flex-start; }
.footer-link { font-weight: 600; font-size: 14px; text-decoration: none; }
.footer-link:hover { text-decoration: underline; }
.footer-copy { font-size: 13px; color: var(--muted); padding-bottom: 32px; margin: 0 auto; }

/* ---------- 18. Carousel posts (Instagram style) ---------- */
.carousel {
    position: relative;
    margin: 32px auto;
    width: min(100%, 560px);
    outline: none;
}
.carousel-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    border: 1.5px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 6px 6px 0 var(--purple);
    background: var(--ink);
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-slide {
    flex: 0 0 100%;
    scroll-snap-align: center;
    scroll-snap-stop: always;
    aspect-ratio: var(--carousel-ratio, 0.8);
    max-height: 80vh;
}
.carousel-slide img { width: 100%; height: 100%; object-fit: contain; display: block; margin: 0; border-radius: 0; }
.carousel:focus-visible .carousel-track { outline: 3px solid var(--purple); outline-offset: 3px; }

.carousel-count {
    position: absolute; top: 12px; right: 12px;
    padding: 3px 10px; border-radius: 999px;
    background: rgba(26, 24, 20, 0.78); color: #fff;
    font-size: 12px; font-weight: 600; letter-spacing: 0.02em;
    pointer-events: none;
}
.carousel-count:empty { display: none; }

.carousel-arrow {
    position: absolute; top: calc(50% - 22px);
    width: 40px; height: 40px; border-radius: 50%;
    display: grid; place-items: center;
    border: 1.5px solid var(--line);
    background: var(--bg); color: var(--ink);
    cursor: pointer; padding: 0;
    transition: background 0.15s, opacity 0.15s;
}
.carousel-arrow:hover { background: var(--purple); color: var(--purple-ink); }
.carousel-arrow:disabled { opacity: 0; pointer-events: none; }
.carousel-arrow--prev { left: 10px; }
.carousel-arrow--next { right: 10px; }
@media (hover: none) { .carousel-arrow { display: none; } }

.carousel-dots { display: flex; justify-content: center; gap: 7px; margin-top: 18px; }
.carousel-dot {
    width: 9px; height: 9px; padding: 0; border-radius: 50%;
    border: 1.5px solid var(--line); background: transparent; cursor: pointer;
    transition: background 0.15s, transform 0.15s;
}
.carousel-dot.is-active { background: var(--purple); border-color: var(--purple); transform: scale(1.25); }
.carousel-caption { margin-top: 12px; text-align: center; font-size: 14px; color: var(--muted); }
.carousel--single .carousel-track { box-shadow: 6px 6px 0 var(--brown); }

/* Without JavaScript the gallery cards simply stay as Ghost's normal grid */

/* ---------- 19. Floating music button + credit line ---------- */
.music-note {
    display: flex; align-items: flex-start; gap: 8px;
    margin-top: 28px; margin-bottom: 0;
    font-size: 13px; line-height: 1.5; color: var(--muted);
}
.music-note[hidden] { display: none; }
.music-note svg { flex: 0 0 auto; margin-top: 2px; color: var(--purple); }

.music-fab {
    position: fixed;
    right: max(18px, env(safe-area-inset-right));
    bottom: max(18px, env(safe-area-inset-bottom));
    z-index: 60;
    width: 58px; height: 58px; border-radius: 50%;
    display: grid; place-items: center;
    border: 1.5px solid var(--line);
    background: var(--purple); color: var(--purple-ink);
    box-shadow: 4px 4px 0 var(--line);
    cursor: pointer; padding: 0;
    opacity: 0; transform: translateY(16px) scale(0.9); pointer-events: none;
    transition: opacity 0.2s, transform 0.2s, box-shadow 0.15s;
}
.music-fab.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.music-fab:hover { box-shadow: 6px 6px 0 var(--line); transform: translate(-1px, -1px); }
.music-fab:focus-visible { outline: 3px solid var(--brown); outline-offset: 3px; }
.music-fab > * { grid-area: 1 / 1; }
.music-fab-pause, .music-fab-bars { display: none; }
.music-fab.is-playing .music-fab-play { display: none; }
.music-fab.is-playing .music-fab-bars { display: flex; }
.music-fab.is-playing:hover .music-fab-bars { display: none; }
.music-fab.is-playing:hover .music-fab-pause { display: block; }
.music-fab-bars { align-items: flex-end; gap: 3px; height: 20px; }
.music-fab-bars i { display: block; width: 4px; background: currentColor; border-radius: 2px; animation: music-bar 0.9s ease-in-out infinite; }
.music-fab-bars i:nth-child(1) { height: 40%; animation-delay: 0s; }
.music-fab-bars i:nth-child(2) { height: 100%; animation-delay: 0.2s; }
.music-fab-bars i:nth-child(3) { height: 60%; animation-delay: 0.4s; }
@keyframes music-bar { 0%, 100% { transform: scaleY(0.35); } 50% { transform: scaleY(1); } }
.music-fab-bars i { transform-origin: bottom; }
@media (prefers-reduced-motion: reduce) { .music-fab-bars i { animation: none !important; } }

/* ---------- 17. Motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- 20. Phone signup form ---------- */
.phone-form { display: flex; flex-direction: column; gap: 12px; max-width: 520px; margin-top: 28px; padding-top: 24px; border-top: 1.5px dashed var(--line-soft); }
.phone-title { margin: 0; font-size: 1.15rem; }
.phone-row { display: flex; flex-wrap: wrap; gap: 12px; }
.phone-row .subscribe-input { flex: 1 1 200px; min-width: 0; }
.phone-consent { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; line-height: 1.5; color: var(--ink-2); cursor: pointer; }
.phone-consent input { margin-top: 3px; accent-color: var(--purple); width: 16px; height: 16px; flex: 0 0 auto; }
.phone-form .btn { align-self: flex-start; }
.phone-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.phone-form.loading .btn-default { display: none; }
.phone-form.loading .btn-loading { display: inline; }
.phone-form.success .subscribe-msg--ok { display: block; color: var(--purple); font-weight: 600; }
.phone-form.error .subscribe-msg--err { display: block; color: #B3261E; font-weight: 600; }

.phone-photo { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.phone-photo-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.phone-photo-btn {
    display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
    padding: 10px 16px; border: 1.5px solid var(--line); border-radius: 999px;
    background: var(--surface); color: var(--ink); font-weight: 600; font-size: 14px;
    transition: background 0.15s, color 0.15s;
}
.phone-photo-btn:hover { background: var(--purple-tint); }
.phone-photo-btn:focus-within { outline: 3px solid var(--purple); outline-offset: 2px; }
.phone-photo-preview { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; border: 1.5px solid var(--line); }
.phone-photo-preview[hidden], .phone-photo-clear[hidden] { display: none; }
.phone-photo-clear { background: none; border: 0; padding: 4px; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 13px; }

.hero-subscribe .phone-form { margin-top: 24px; }
