/* =========================================================================
   Fourthwall Storefront theme — screen.css
   Lightweight, mobile-first, vanilla CSS. No frameworks.
   Brand color comes from Ghost Admin → Design → Accent color, and fonts from
   Ghost's Typography settings — so the theme adapts to any store's brand.
   ========================================================================= */

/* ---- Design tokens ---------------------------------------------------- */
:root {
    --bg:        #FFFDF9;   /* warm white */
    --surface:   #FFFFFF;
    --ink:       #20232A;   /* near-black, high contrast on --bg */
    --ink-soft:  #5A6472;
    --line:      #EFEAE1;

    /* Brand = Ghost's Accent color (Design & branding), with a friendly default. */
    --brand:     var(--ghost-accent-color, #6C4CE0);
    --brand-700: #4F32B8;   /* hover shade — auto-derived below when supported */

    --pink-50:   #FFE9F3;
    --yellow-50: #FFF6D6;
    --mint-50:   #E0FBF3;
    --sky-50:    #E4F1FF;
    --grape-50:  #F2E9FF;
    --coral-50:  #FFEDE6;

    /* Scheme-aware tokens (flip in dark mode) */
    --tint:      #F2E9FF;                    /* tinted section + media backgrounds */
    --header-bg: rgba(255, 253, 249, 0.92);  /* sticky header */
    --footer-bg: #20232A;                    /* footer stays dark in both schemes */

    --radius:    18px;
    --radius-sm: 12px;
    --radius-pill: 999px;
    --shadow:    0 6px 20px rgba(32, 35, 42, 0.08);
    --shadow-lg: 0 14px 40px rgba(32, 35, 42, 0.14);
    --wrap:      1180px;
    --gap:       clamp(14px, 2.4vw, 28px);

    --font-fallback: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
            "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
}

/* Derive the hover shade from the accent color on modern browsers. */
@supports (color: color-mix(in srgb, red, blue)) {
    :root {
        --brand-700: color-mix(in srgb, var(--brand) 78%, black);
    }
}

/* ---- Dark mode --------------------------------------------------------
   Driven by the "Color scheme" theme setting: Dark forces it, Auto follows
   the visitor's system preference. Applied via a class on <html>. */
html.theme-dark {
    --bg:        #16171B;
    --surface:   #1E2026;
    --ink:       #F1F2F6;
    --ink-soft:  #9BA3B0;
    --line:      #2C2F36;
    --tint:      #1B1D26;
    --header-bg: rgba(22, 23, 27, 0.92);
    --footer-bg: #101114;
}
@media (prefers-color-scheme: dark) {
    html.theme-auto {
        --bg:        #16171B;
        --surface:   #1E2026;
        --ink:       #F1F2F6;
        --ink-soft:  #9BA3B0;
        --line:      #2C2F36;
        --tint:      #1B1D26;
        --header-bg: rgba(22, 23, 27, 0.92);
        --footer-bg: #101114;
    }
}
html.theme-dark { color-scheme: dark; }
html.theme-auto { color-scheme: light dark; }
/* Brighten the accent hover shade for dark backgrounds */
@supports (color: color-mix(in srgb, red, blue)) {
    html.theme-dark { --brand-700: color-mix(in srgb, var(--brand) 80%, white); }
    @media (prefers-color-scheme: dark) {
        html.theme-auto { --brand-700: color-mix(in srgb, var(--brand) 80%, white); }
    }
}

/* ---- Reset-ish -------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    /* Ghost custom fonts (Design → Typography) with a system fallback. */
    font-family: var(--gh-font-body, var(--font-fallback));
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    font-size: 17px;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand-700); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 {
    font-family: var(--gh-font-heading, var(--gh-font-body, var(--font-fallback)));
    line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 0.4em;
}
ul { margin: 0; padding: 0; }
button { font: inherit; cursor: pointer; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px); }
.visually-hidden, .skip-link:not(:focus) {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---- Accessibility: skip link + focus --------------------------------- */
.skip-link {
    position: fixed; top: 10px; left: 10px; z-index: 1000;
    background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: var(--radius-sm);
}
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 4px; }

/* ---- Buttons ---------------------------------------------------------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 46px; padding: 11px 20px;
    border-radius: var(--radius-pill); border: 2px solid transparent;
    font-weight: 700; text-align: center; text-decoration: none;
    transition: transform .12s ease, box-shadow .12s ease, background-color .12s ease, filter .12s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--lg { min-height: 54px; padding: 14px 28px; font-size: 1.05rem; }
.btn--primary { background: var(--brand); color: #fff; box-shadow: var(--shadow); }
.btn--primary:hover { background: var(--brand-700); color: #fff; }
.btn--secondary { background: var(--surface); color: var(--ink); border-color: var(--ink); }
.btn--secondary:hover { background: var(--ink); color: var(--bg); }
.btn--ghost { background: var(--tint); color: var(--brand-700); }
.btn--ghost:hover { background: var(--brand); color: #fff; }

/* ---- Header ----------------------------------------------------------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: var(--header-bg);
    backdrop-filter: saturate(140%) blur(8px);
    border-bottom: 1px solid var(--line);
}
.site-header__inner { display: flex; align-items: center; gap: 16px; min-height: 68px; }
.site-logo { display: inline-flex; align-items: center; }
.site-logo__img { height: 36px; width: auto; }
.site-logo__text { font-weight: 800; font-size: 1.3rem; letter-spacing: -0.03em; color: var(--ink); }
.site-nav { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.site-nav__list { display: flex; align-items: center; gap: 22px; list-style: none; }
.site-nav__link { color: var(--ink); font-weight: 600; }
.site-nav__link:hover { color: var(--brand-700); text-decoration: none; }
.site-nav__cta { margin-left: 4px; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; margin-left: auto;
    background: none; border: 0; padding: 10px; border-radius: var(--radius-sm); }
.nav-toggle__bar { width: 24px; height: 3px; background: var(--ink); border-radius: 3px; transition: .2s; }

@media (max-width: 820px) {
    .nav-toggle { display: flex; }
    .site-nav {
        position: absolute; inset: 68px 0 auto 0; flex-direction: column; align-items: stretch;
        gap: 6px; padding: 16px clamp(16px,4vw,32px) 22px; background: var(--surface);
        border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
        transform: translateY(-12px); opacity: 0; pointer-events: none; transition: .2s;
    }
    .site-nav.is-open { transform: translateY(0); opacity: 1; pointer-events: auto; }
    .site-nav__list { flex-direction: column; align-items: stretch; gap: 4px; }
    .site-nav__link { display: block; padding: 12px 8px; border-radius: var(--radius-sm); }
    .site-nav__link:hover { background: var(--tint); }
    .site-nav__cta { margin-top: 8px; }
}

/* ---- Hero ------------------------------------------------------------- */
.hero { padding: clamp(36px, 7vw, 84px) 0 clamp(28px, 5vw, 56px); overflow: hidden; }
.hero__inner { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: var(--gap); align-items: center; }
.hero__inner--single { grid-template-columns: 1fr; text-align: center; }
.hero__inner--single .hero__cta { justify-content: center; }
.hero__inner--single .hero__sub { margin-inline: auto; }
.hero__eyebrow { font-weight: 800; color: var(--brand-700); letter-spacing: .06em; text-transform: uppercase; font-size: .85rem; margin: 0 0 10px; }
.hero__title { font-size: clamp(2rem, 5.2vw, 3.4rem); font-weight: 800; }
.hero__sub { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: var(--ink-soft); max-width: 40ch; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0 14px; }
.hero__trust { font-size: .9rem; color: var(--ink-soft); }
.hero__art { position: relative; }
.hero__cover {
    width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
    border-radius: var(--radius); box-shadow: var(--shadow-lg);
    transform: rotate(1.5deg);
}
@media (max-width: 820px) {
    .hero__inner { grid-template-columns: 1fr; }
    .hero__art { display: none; }
}

/* ---- Sections --------------------------------------------------------- */
.section { padding: clamp(34px, 6vw, 72px) 0; }
.section--tint { background: var(--tint); }
.section__head { text-align: center; max-width: 60ch; margin: 0 auto clamp(20px, 3vw, 36px); }
.section__title { font-size: clamp(1.6rem, 3.6vw, 2.4rem); font-weight: 800; }
.section__sub { color: var(--ink-soft); font-size: 1.05rem; margin: 0; }
.section__more { text-align: center; margin-top: clamp(20px, 3vw, 34px); }

/* ---- Collection tiles (auto-built from Fourthwall) -------------------- */
.tile-grid { display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); list-style: none; }
.tile {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
    aspect-ratio: 1 / 1; padding: 18px; border-radius: var(--radius); text-align: center;
    color: #20232A; font-weight: 700; box-shadow: var(--shadow);
    transition: transform .14s ease, box-shadow .14s ease;
}
.tile:hover { transform: translateY(-4px) rotate(-1.2deg); box-shadow: var(--shadow-lg); text-decoration: none; }
.tile__monogram {
    display: grid; place-items: center; width: 62px; height: 62px;
    border-radius: 50%; background: #FFFFFF; color: #4F32B8;
    font-size: 1.7rem; font-weight: 800; box-shadow: var(--shadow);
}
.tile__label { font-size: 1rem; }
.tile--pink   { background: var(--pink-50); }
.tile--yellow { background: var(--yellow-50); }
.tile--mint   { background: var(--mint-50); }
.tile--sky    { background: var(--sky-50); }
.tile--grape  { background: var(--grape-50); }
.tile--coral  { background: var(--coral-50); }

/* ---- Product grid + cards -------------------------------------------- */
.product-grid {
    display: grid; gap: var(--gap); list-style: none;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.product-card {
    display: flex; flex-direction: column; background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
    box-shadow: var(--shadow); transition: transform .15s ease, box-shadow .15s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.product-card__media { position: relative; display: block; aspect-ratio: 1 / 1; background: var(--tint); }
.product-card__img { width: 100%; height: 100%; object-fit: cover; }
.product-card__noimg { display: grid; place-items: center; height: 100%; font-size: 42px; color: var(--brand); }
.product-card__badge {
    position: absolute; top: 10px; left: 10px; background: var(--ink); color: var(--bg);
    font-size: .72rem; font-weight: 700; padding: 5px 10px; border-radius: var(--radius-pill);
}
.product-card__body { display: flex; flex-direction: column; gap: 6px; padding: 14px 14px 16px; flex: 1; }
.product-card__category { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--brand-700); }
.product-card__title { font-size: 1.02rem; font-weight: 700; margin: 0; }
.product-card__title a { color: var(--ink); }
.product-card__title a:hover { color: var(--brand-700); text-decoration: none; }
.product-card__price { font-weight: 800; margin: 2px 0 0; color: var(--ink); }
.product-card__price .compare { color: var(--ink-soft); font-weight: 600; text-decoration: line-through; margin-left: 6px; font-size: .9em; }
.product-card__actions { display: flex; gap: 8px; margin-top: auto; padding-top: 12px; }
.product-card__actions .btn { flex: 1; min-height: 42px; padding: 9px 12px; font-size: .92rem; }

/* ---- Skeleton loaders ------------------------------------------------- */
.product-card.is-skeleton { pointer-events: none; }
.skeleton { position: relative; overflow: hidden; background: var(--line); }
.skeleton::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent);
    transform: translateX(-100%); animation: shimmer 1.4s infinite;
}
.skel-line { height: 12px; border-radius: 6px; margin: 8px 14px; }
@keyframes shimmer { 100% { transform: translateX(100%); } }

/* ---- States: setup / empty / error ------------------------------------ */
.fw-state {
    text-align: center; padding: 40px 20px; background: var(--surface);
    border: 1px dashed var(--line); border-radius: var(--radius); color: var(--ink-soft);
}
.fw-state__emoji { font-size: 40px; display: block; margin-bottom: 8px; }
.fw-state .btn { margin-top: 14px; }
.fw-state strong { color: var(--ink); }
.empty-state { text-align: center; color: var(--ink-soft); padding: 30px 0; }

/* ---- Shop controls ---------------------------------------------------- */
.shop__controls { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 16px; }
.shop__search { flex: 1 1 260px; }
.shop__search input, .shop__sort select {
    width: 100%; min-height: 48px; padding: 10px 16px; font-size: 1rem;
    border: 2px solid var(--line); border-radius: var(--radius-pill); background: var(--surface); color: var(--ink);
    font-family: inherit;
}
.shop__sort select { min-width: 190px; }
.shop__chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 18px; }
.chip {
    min-height: 40px; padding: 8px 16px; border-radius: var(--radius-pill);
    border: 2px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600;
}
.chip:hover { border-color: var(--brand); }
.chip[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.shop__status { color: var(--ink-soft); margin: 0 0 14px; min-height: 1.2em; }
.shop__more { text-align: center; margin-top: 26px; }

/* ---- Blog ------------------------------------------------------------- */
.post-grid { display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); list-style: none; }
.post-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.post-card__media { display: block; aspect-ratio: 3 / 2; background: var(--tint); }
.post-card__img { width: 100%; height: 100%; object-fit: cover; }
.post-card__placeholder { display: grid; place-items: center; height: 100%; font-size: 40px; color: var(--brand); }
.post-card__body { padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.post-card__tag { font-size: .72rem; font-weight: 700; text-transform: uppercase; color: var(--brand-700); letter-spacing: .04em; }
.post-card__title { font-size: 1.15rem; margin: 0; }
.post-card__title a { color: var(--ink); }
.post-card__excerpt { color: var(--ink-soft); margin: 0; font-size: .95rem; }
.post-card__date { color: var(--ink-soft); font-size: .82rem; margin-top: auto; }

.pagination { display: flex; justify-content: center; gap: 18px; align-items: center; margin-top: 36px; }

/* ---- Post / page content --------------------------------------------- */
.post, .page { max-width: 760px; padding-top: clamp(28px, 5vw, 56px); padding-bottom: clamp(28px, 5vw, 56px); }
.post__title, .page__title { font-size: clamp(1.8rem, 4.5vw, 2.8rem); font-weight: 800; }
.post__tag { font-weight: 700; color: var(--brand-700); text-transform: uppercase; font-size: .8rem; letter-spacing: .05em; }
.post__meta { color: var(--ink-soft); }
.post__feature { margin: 24px 0; }
.post__feature img, .page__feature { border-radius: var(--radius); width: 100%; }
.gh-content { display: flex; flex-direction: column; align-items: center; }
.gh-content > * { width: 100%; margin: 0 0 1.2em; }
.gh-content h2 { margin-top: 1.6em; }
.gh-content img { border-radius: var(--radius); }

/* ---- Koenig editor content widths (required by Ghost) ----------------- */
.gh-content .kg-width-wide { width: min(85vw, 1100px); }
.gh-content .kg-width-full {
    width: 100vw; max-width: 100vw;
    position: relative; left: 50%; right: 50%;
    margin-left: -50vw; margin-right: -50vw;
}
.kg-width-full img { width: 100%; border-radius: 0; }
.kg-image { margin: 0 auto; }
.kg-card figcaption { text-align: center; color: var(--ink-soft); font-size: .9rem; margin-top: 8px; }

.post__shop-cta {
    margin-top: 40px; padding: 28px; text-align: center; background: var(--tint);
    border-radius: var(--radius);
}
.post__shop-cta p { font-weight: 700; font-size: 1.15rem; margin: 0 0 14px; }

/* ---- About ------------------------------------------------------------ */
.about__inner { text-align: center; max-width: 62ch; margin: 0 auto; }
.about__text { color: var(--ink-soft); font-size: 1.1rem; margin-bottom: 22px; }

/* ---- Footer ----------------------------------------------------------- */
.site-footer { background: var(--footer-bg); color: #E7E9EE; margin-top: 40px; }
.site-footer a { color: #E7E9EE; }
.site-footer a:hover { color: #fff; }
.site-footer__inner { display: grid; gap: var(--gap); grid-template-columns: 1.5fr 1fr 1fr; padding: clamp(34px, 5vw, 56px) clamp(16px,4vw,32px); }
.site-footer .site-logo__text { color: #fff; }
.site-footer__blurb { color: #AEB4C0; max-width: 38ch; }
.site-footer__heading { font-size: .95rem; text-transform: uppercase; letter-spacing: .05em; color: #AEB4C0; }
.site-footer__nav ul { list-style: none; display: grid; gap: 8px; }
.site-footer__nav ul + ul { margin-top: 8px; }
.site-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px;
    border-top: 1px solid rgba(255,255,255,.1); padding: 18px clamp(16px,4vw,32px); font-size: .85rem; color: #AEB4C0; }
@media (max-width: 720px) { .site-footer__inner { grid-template-columns: 1fr 1fr; } }

/* ---- Error page ------------------------------------------------------- */
.error-page__inner { text-align: center; max-width: 50ch; margin: 0 auto; padding: clamp(40px,8vw,90px) 0; }
.error-page__code { font-size: 5rem; font-weight: 800; color: var(--brand); margin: 0; line-height: 1; }
.error-page .hero__cta { justify-content: center; }

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

/* ---- Native search button --------------------------------------------- */
.search-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 42px; height: 42px; border-radius: 50%;
    background: none; border: 2px solid var(--line); color: var(--ink);
}
.search-btn:hover { border-color: var(--brand); color: var(--brand-700); }
@media (max-width: 820px) {
    .search-btn { width: 100%; border-radius: var(--radius-pill); }
}

/* ---- Member link in header -------------------------------------------- */
.site-nav__member { white-space: nowrap; }

/* ---- Newsletter signup (Ghost members) --------------------------------- */
.newsletter { background: var(--tint); }
.newsletter__inner { text-align: center; max-width: 56ch; margin: 0 auto; }
.newsletter-form { margin-top: 18px; }
.newsletter-form__fields { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.newsletter-form__input {
    flex: 1 1 260px; max-width: 380px; min-height: 50px; padding: 10px 18px;
    font-size: 1rem; font-family: inherit;
    border: 2px solid var(--line); border-radius: var(--radius-pill);
    background: var(--surface); color: var(--ink);
}
.newsletter-form__input:focus { border-color: var(--brand); outline: none; }
/* Ghost toggles .loading / .success / .error on the form automatically */
.newsletter-form__success { display: none; font-weight: 700; color: var(--ink); }
.newsletter-form.success .newsletter-form__fields { display: none; }
.newsletter-form.success .newsletter-form__success { display: block; }
.newsletter-form.loading button[type="submit"] { opacity: .6; pointer-events: none; }
.newsletter-form__error { color: #C2263F; font-weight: 600; min-height: 1.2em; margin: 8px 0 0; }
html.theme-dark .newsletter-form__error { color: #FF7A8A; }

/* ---- Post tags + linked chips ------------------------------------------ */
.post__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.chip--link { display: inline-flex; align-items: center; text-decoration: none; color: var(--ink); }
.chip--link:hover { border-color: var(--brand); color: var(--brand-700); text-decoration: none; }

/* ---- Prev / next post navigation ---------------------------------------- */
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); margin-top: 36px; }
.post-nav__link {
    display: flex; flex-direction: column; gap: 4px; padding: 18px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    color: var(--ink); box-shadow: var(--shadow);
}
.post-nav__link:hover { text-decoration: none; border-color: var(--brand); }
.post-nav__link--next { text-align: right; grid-column: 2; }
.post-nav__label { font-size: .8rem; font-weight: 700; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .04em; }
.post-nav__title { font-weight: 700; }
@media (max-width: 600px) {
    .post-nav { grid-template-columns: 1fr; }
    .post-nav__link--next { grid-column: auto; text-align: left; }
}

/* ---- Gated content CTA (members / paid posts) --------------------------- */
.content-cta {
    text-align: center; padding: 36px 24px; margin: 24px 0;
    background: var(--tint); border-radius: var(--radius);
}
.content-cta__title { font-size: 1.4rem; margin-bottom: 8px; }
.content-cta__text { color: var(--ink-soft); margin: 0 0 18px; }
.content-cta__signin { margin: 12px 0 0; font-size: .95rem; color: var(--ink-soft); }

/* ---- Comments ----------------------------------------------------------- */
.post__comments { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); }

/* ---- Tag / author archive headers --------------------------------------- */
.archive-head { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.archive-head__avatar { border-radius: 50%; width: 96px; height: 96px; object-fit: cover; box-shadow: var(--shadow); }
.archive-head__image { border-radius: var(--radius); width: 120px; height: 120px; object-fit: cover; box-shadow: var(--shadow); }
.archive-head__links { display: flex; gap: 16px; font-weight: 600; }

/* ---- Post-card extras (premium badge, meta row) -------------------------- */
.post-card__meta-top { display: flex; align-items: center; gap: 8px; }
.post-card__premium {
    font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em;
    background: var(--brand); color: #fff; padding: 3px 9px; border-radius: var(--radius-pill);
}

/* ---- Footer social ------------------------------------------------------- */
.site-footer__social { display: flex; gap: 14px; margin-top: 14px; }
.site-footer__social a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; border-radius: 50%;
    border: 1px solid rgba(255,255,255,.2); color: #E7E9EE;
}
.site-footer__social a:hover { border-color: #fff; color: #fff; }

/* ---- Navigation: current page + footer secondary list ------------------- */
.site-nav__link--current { color: var(--brand-700); }
.site-nav__link--current::after { content: ""; display: block; height: 3px; border-radius: 3px; background: var(--brand); margin-top: 2px; }
.footer-links { list-style: none; display: grid; gap: 8px; margin-top: 8px; }

/* ---- Topic (tag) tiles — pastel rotation + image/count ------------------- */
.tile-grid--tags li:nth-child(6n+1) .tile { background: var(--pink-50); }
.tile-grid--tags li:nth-child(6n+2) .tile { background: var(--yellow-50); }
.tile-grid--tags li:nth-child(6n+3) .tile { background: var(--mint-50); }
.tile-grid--tags li:nth-child(6n+4) .tile { background: var(--sky-50); }
.tile-grid--tags li:nth-child(6n+5) .tile { background: var(--grape-50); }
.tile-grid--tags li:nth-child(6n+6) .tile { background: var(--coral-50); }
.tile__img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; box-shadow: var(--shadow); }
.tile__count { font-size: .8rem; font-weight: 600; color: #5A6472; }

/* ---- Error page: raw HTTP response block -------------------------------
   Generic for any store, styled like a server response. Works in every
   color scheme; extra fun in Terminal. */
.error-page__response {
    text-align: left; margin: 26px auto 30px; max-width: 46ch;
    background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow);
}
.error-page__response-bar {
    display: flex; gap: 6px; padding: 10px 14px;
    border-bottom: 1px solid var(--line); background: var(--tint);
}
.error-page__response-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.error-page__pre {
    margin: 0; padding: 16px 18px; overflow-x: auto;
    font-family: ui-monospace, "JetBrains Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
    font-size: .88rem; line-height: 1.55; color: var(--ink);
}
.error-page__pre .status { color: var(--brand); font-weight: 700; }
.error-page__pre .key { color: var(--ink-soft); }

/* ---- Terminal preset ----------------------------------------------------
   "Color scheme: Terminal" (Design -> Customize). A dark, monospaced look
   for tech / hacker / gaming brands. default.hbs applies it together with
   .theme-dark, so all dark tokens are inherited and these layer on top.
   Ghost Typography settings still win where set. */
html.theme-terminal {
    --font-mono: ui-monospace, "JetBrains Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

    --bg:        #0B0D10;
    --surface:   #12151A;
    --ink:       #E6EAF0;
    --ink-soft:  #8B95A3;
    --line:      #262B33;
    --tint:      #0F1116;
    --header-bg: rgba(11, 13, 16, 0.92);
    --footer-bg: #08090B;

    /* Sharp corners; flat 1px borders instead of soft shadows */
    --radius:      6px;
    --radius-sm:   4px;
    --radius-pill: 6px;
    --shadow:    0 0 0 1px var(--line);
    --shadow-lg: 0 0 0 1px var(--line), 0 8px 30px rgba(0, 0, 0, .5);
}
@supports (color: color-mix(in srgb, red, blue)) {
    html.theme-terminal {
        --brand-700: color-mix(in srgb, var(--brand) 80%, white);
        --shadow-lg: 0 0 0 1px var(--line), 0 0 24px color-mix(in srgb, var(--brand) 22%, transparent);
    }
}

/* Monospace voice for headings and UI chrome. */
html.theme-terminal h1, html.theme-terminal h2, html.theme-terminal h3,
html.theme-terminal .btn,
html.theme-terminal .chip,
html.theme-terminal .site-logo__text,
html.theme-terminal .site-nav__link,
html.theme-terminal .hero__eyebrow,
html.theme-terminal .product-card__price,
html.theme-terminal .post-card__tag,
html.theme-terminal .site-footer__heading {
    font-family: var(--gh-font-heading, var(--font-mono));
    letter-spacing: 0;
}

/* Section titles get a comment-style prefix in the accent color. */
html.theme-terminal .section__title::before { content: "# "; color: var(--brand); }

/* Hero: prompt-style eyebrow, blinking cursor, faint static scanlines. */
html.theme-terminal .hero__eyebrow { text-transform: lowercase; color: var(--brand); }
html.theme-terminal .hero__title::after {
    content: "_"; margin-left: .08em; color: var(--brand);
    animation: fw-blink 1.1s steps(1) infinite;
}
@keyframes fw-blink { 50% { opacity: 0; } }
html.theme-terminal .hero {
    background: repeating-linear-gradient(0deg, rgba(255, 255, 255, .022) 0 1px, transparent 1px 3px);
}
html.theme-terminal .hero__cover { transform: none; }

/* Flat interactions: no lift/rotate - border highlight + glow instead. */
html.theme-terminal .btn { border-radius: var(--radius-sm); }
html.theme-terminal .btn:hover { transform: none; }
html.theme-terminal .product-card:hover,
html.theme-terminal .tile:hover { transform: none; border-color: var(--brand); }
html.theme-terminal .post-nav__link:hover { border-color: var(--brand); }

/* Pastel tile rotation -> flat dark panels. */
html.theme-terminal .tile { color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
html.theme-terminal .tile--pink, html.theme-terminal .tile--yellow,
html.theme-terminal .tile--mint, html.theme-terminal .tile--sky,
html.theme-terminal .tile--grape, html.theme-terminal .tile--coral,
html.theme-terminal .tile-grid--tags li:nth-child(6n+1) .tile,
html.theme-terminal .tile-grid--tags li:nth-child(6n+2) .tile,
html.theme-terminal .tile-grid--tags li:nth-child(6n+3) .tile,
html.theme-terminal .tile-grid--tags li:nth-child(6n+4) .tile,
html.theme-terminal .tile-grid--tags li:nth-child(6n+5) .tile,
html.theme-terminal .tile-grid--tags li:nth-child(6n+6) .tile { background: var(--surface); }
html.theme-terminal .tile__monogram {
    background: var(--tint); color: var(--brand);
    border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: none;
}
html.theme-terminal .tile__count { color: var(--ink-soft); }

/* Inputs and search: squared corners, mono where you type. */
html.theme-terminal .shop__search input,
html.theme-terminal .shop__sort select,
html.theme-terminal .newsletter-form__input { border-radius: var(--radius-sm); font-family: var(--font-mono); }
html.theme-terminal .search-btn { border-radius: var(--radius-sm); }
; }
