/* GeoQuote directory pages + the search box on the home page. Uses the colour variables from genre_site.html. */
    /* ================= directory pages: reading layout on the site's dark glass ================= */
    .visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    .dir { padding-top: 6px; }
    .crumbs { display: flex; flex-wrap: wrap; gap: 4px 8px; margin: 0 0 14px; padding: 0; list-style: none; font-size: .85rem; color: var(--muted); }
    .crumbs li + li::before { content: '/'; margin-right: 8px; opacity: .5; }
    .crumbs a { color: var(--muted); text-decoration: none; }
    .crumbs a:hover { color: var(--gold); }
    .dir h1 { margin: 0 0 14px; font: 900 clamp(1.75rem, 5vw, 2.7rem)/1.12 var(--mono); letter-spacing: .5px; text-shadow: 0 0 22px rgba(255, 204, 0, .3); }
    .dir h2 { margin: 0 0 12px; font: 900 1.25rem/1.25 var(--mono); letter-spacing: .5px; }
    .dir h2 small { color: var(--muted); font: 700 .85rem system-ui, sans-serif; letter-spacing: 0; }
    .dir p { max-width: 68ch; color: #cbd5e1; }
    .dir .lede { font-size: 1.12rem; color: #e2e8f0; margin: 0 0 18px; max-width: none; }
    .dir a.link { color: var(--cyan); text-decoration-thickness: 1px; text-underline-offset: 3px; }
    .dir-sec { margin-top: 38px; }

    /* the answer: the one loud element on a title page */
    .answer { position: relative; padding: 20px 22px 18px 26px; border-left: 4px solid var(--gold); }
    .answer-places { display: flex; flex-direction: column; gap: 10px; margin: 0 0 14px; padding: 0; list-style: none; }
    .answer-places li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
    .answer-place { font: 900 clamp(1.35rem, 4.2vw, 2rem)/1.15 var(--mono); color: var(--gold); text-decoration: none; }
    a.answer-place:hover { text-decoration: underline; text-underline-offset: 4px; }
    .answer-coord { font-size: .82rem; color: var(--muted); }
    .answer-coord a { color: var(--muted); }
    .answer p { margin: 0; font-size: 1.05rem; color: #e2e8f0; }
    .answer p + p { margin-top: 8px; }
    .set-tag { display: inline-block; margin-right: 6px; padding: 0 8px; border-radius: 999px; font-size: .74rem; font-weight: 800; border: 1px solid; }
    .set-tag.filmed { color: var(--gold); border-color: var(--gold-soft); }
    .set-tag.set { color: var(--cyan); border-color: rgba(56, 189, 248, .45); }

    /* facts */
    .facts { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 0; }
    .facts dt { color: var(--muted); font-size: .9rem; padding-top: 2px; }
    .facts dd { margin: 0; color: #e2e8f0; }
    .chips { display: flex; flex-wrap: wrap; gap: 6px 8px; }
    .chip { display: inline-block; padding: 3px 12px; border-radius: 999px; border: 1px solid var(--gold-soft); color: #e2e8f0; text-decoration: none; font-size: .9rem; }
    a.chip:hover, a.chip:focus-visible { background: var(--gold); color: #000; }
    span.chip { border-style: dashed; color: var(--muted); }

    /* lists of titles */
    /* each film or show is a button: the whole row is the link, and it turns gold on hover like the other buttons */
    .rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
    .trow { display: grid; grid-template-columns: 1fr auto; gap: 2px 14px; height: 100%; padding: 11px 16px; border-radius: 12px;
        border: 1px solid var(--gold-soft); border-left: 3px solid var(--gold); background: rgba(255, 255, 255, .04);
        color: #fff; text-decoration: none; transition: background .15s ease, color .15s ease, box-shadow .15s ease; }
    .trow-title { font-weight: 700; }
    .trow-meta { color: var(--muted); font: 700 .85rem var(--mono); text-align: right; }
    .trow-where { grid-column: 1 / -1; color: var(--muted); font-size: .9rem; }
    .trow-where i { color: var(--gold); opacity: .8; margin-right: 2px; }
    .trow-extra { color: #cbd5e1; }
    .trow:hover, .trow:focus-visible, .trow[aria-current="true"] { background: var(--gold); color: #000; box-shadow: 0 0 18px rgba(255, 204, 0, .45); }
    .trow:hover .trow-meta, .trow:hover .trow-where, .trow:hover .trow-where i, .trow:hover .trow-extra,
    .trow:focus-visible .trow-meta, .trow:focus-visible .trow-where, .trow:focus-visible .trow-where i, .trow:focus-visible .trow-extra,
    .trow[aria-current="true"] .trow-meta, .trow[aria-current="true"] .trow-where, .trow[aria-current="true"] .trow-where i { color: #000; opacity: 1; }
    .cols-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 34px; }
    .rows.cols-2 { gap: 10px; }
    .cols-2 > :only-child { grid-column: 1 / -1; }

    /* index pages: name + count, in columns */
    .entries { list-style: none; margin: 0; padding: 0; columns: 3 220px; column-gap: 30px; }
    .entries li { break-inside: avoid; display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid rgba(255, 255, 255, .06); }
    .entries a { color: #e2e8f0; text-decoration: none; }
    .entries a:hover { color: var(--gold); text-decoration: underline; }
    .entries span { color: var(--muted); font: 700 .8rem var(--mono); }

    .letters { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
    .letters a, .letters span { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 8px; border-radius: 10px; border: 1px solid var(--gold-soft); color: #fff; text-decoration: none; font: 900 .95rem var(--mono); text-transform: uppercase; }
    .letters a:hover, .letters a[aria-current] { background: var(--gold); color: #000; }
    .letters span { opacity: .35; }

    /* quotes */
    .quotes { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
    .quotes blockquote { margin: 0; padding: 4px 0 4px 18px; border-left: 2px solid var(--gold-soft); font-size: 1.08rem; color: #f1f5f9; }
    .quotes cite { display: block; margin-top: 4px; font-style: normal; color: var(--muted); font-size: .88rem; }
    .quotes cite a { color: var(--cyan); }

    /* map */
    .dir-map-fig { margin: 18px 0 0; }
    .dir-map { position: relative; width: 100%; height: clamp(280px, 48vw, 440px); border-radius: 14px; overflow: hidden; border: 1px solid var(--gold-soft); background: radial-gradient(400px 200px at 50% 50%, #1d2142, #0b0d17); }
    .dir-map-load { position: absolute; inset: 0; margin: auto; width: max-content; height: max-content; padding: 10px 20px; border-radius: 999px; border: 1px solid var(--gold-soft); background: rgba(8, 10, 18, .85); color: #fff; font: 800 .85rem var(--mono); cursor: pointer; }
    .dir-map.is-live .dir-map-load { display: none; }
    .dir-map figcaption, .dir-map-fig figcaption { margin-top: 8px; font-size: .85rem; color: var(--muted); }
    /* the game's answer pins and tooltips (same as genre_game.js) */
    .gq-marker { pointer-events: none; }
    .gq-answer { pointer-events: auto; cursor: pointer; outline: none; }
    .gq-answer:hover, .gq-answer:focus, .gq-answer:focus-visible { z-index: 5; }
    .gq-answer[data-tip]::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 10px); left: 50%;
        transform: translateX(-50%) translateY(4px); width: max-content; max-width: 260px; padding: 7px 11px; border-radius: 10px;
        background: rgba(8, 10, 18, 0.96); border: 1px solid rgba(255, 204, 0, 0.55); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
        color: #fff; font-family: 'Courier New', monospace; font-weight: 700; font-size: 0.78rem; line-height: 1.35;
        text-align: center; white-space: normal; pointer-events: none; opacity: 0;
        transition: opacity 0.12s ease, transform 0.12s ease; z-index: 10; }
    .gq-answer.tip-below[data-tip]::after { bottom: auto; top: calc(100% + 10px); transform: translateX(-50%) translateY(-4px); }
    .gq-answer:focus::after, .gq-answer:focus-visible::after { opacity: 1; transform: translateX(-50%) translateY(0); }
    @media (hover: hover) { .gq-answer:hover::after { opacity: 1; transform: translateX(-50%) translateY(0); } }
    .gq-pin { position: relative; transform-origin: 50% 100%; filter: drop-shadow(0 3px 3px rgba(0,0,0,.35)); }
    .gq-pin svg { display: block; width: 100%; height: 100%; overflow: visible; }
    .gq-answer .gq-pin { width: 38px; height: 49px; }
    .gq-badge { position: absolute; top: -7px; right: -9px; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 11px;
        background: #e11d48; color: #fff; border: 2px solid #fff; font: 800 11px/18px system-ui, sans-serif; text-align: center;
        box-shadow: 0 1px 3px rgba(0,0,0,.4); }
    .gq-cluster { display: flex; align-items: center; justify-content: center; border-radius: 50%; background: #e11d48;
        border: 3px solid #fff; box-shadow: 0 0 0 5px rgba(225, 29, 72, .3), 0 3px 6px rgba(0,0,0,.4); color: #fff;
        font: 800 13px/1 system-ui, sans-serif; }
    .gq-cluster:hover, .gq-cluster:focus-visible { box-shadow: 0 0 0 7px rgba(225, 29, 72, .4), 0 3px 6px rgba(0,0,0,.4); }

    /* play panel */
    .play-cta { display: grid; grid-template-columns: 1fr auto; gap: 18px 28px; align-items: center; margin-top: 38px; padding: 22px 24px; }
    .play-cta h2 { margin: 0 0 4px; }
    .play-cta p { margin: 0; }
    .play-cta-actions { display: flex; flex-direction: column; align-items: stretch; gap: 10px; }
    .ghost-btn { display: inline-flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--gold-soft); color: #e2e8f0; text-decoration: none; font-weight: 700; font-size: .92rem; }
    .ghost-btn small { color: var(--muted); font: 800 .68rem var(--mono); }
    .ghost-btn:hover { border-color: var(--gold); color: var(--gold); }

    .play-bare { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; }
    .play-bare .ghost-btn { padding: 12px 22px; }
    /* jump buttons on the maps, as in the game: 1-4 continents, GQ to the game's results */
    .region-btns { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); z-index: 5; display: flex; flex-direction: column;
        border-radius: 999px; overflow: hidden; background: rgba(0, 0, 0, 0.6); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35); }
    .region-btn { width: 36px; height: 36px; border: 0; padding: 0; background: transparent; color: #fff; cursor: pointer; text-decoration: none;
        font: 900 0.95rem 'Courier New', monospace; display: flex; align-items: center; justify-content: center; }
    .region-btn + .region-btn { border-top: 1px solid rgba(255, 255, 255, 0.15); }
    .region-btn:hover { background: rgba(0, 0, 0, 0.85); color: #ffcc00; }
    .region-btn:focus-visible { outline: 2px solid #fff; outline-offset: -2px; }
    .region-btn.region-gq { font-size: 0.78rem; color: #fff; letter-spacing: 0.5px; }
    .dir-map { background: #0b0d17; }
    .page-title { margin: 0 0 14px; font: 900 clamp(1.6rem, 4.5vw, 2.4rem)/1.12 var(--mono); letter-spacing: .5px; text-shadow: 0 0 22px rgba(255, 204, 0, .3); }
    .inline-panel { margin-top: 46px; padding-top: 30px; border-top: 1px solid var(--gold-soft); scroll-margin-top: 12px; }
    .inline-panel[aria-busy="true"] { opacity: .5; }
    .inline-panel h2:focus { outline: none; }
    .genre-picks { display: flex; flex-wrap: wrap; gap: 10px; }
    .genre-picks .pk-btn { white-space: normal; }
    .genre-picks .pk-btn[hidden] { display: none; }
    .quotes:has(.quote-pick) { gap: 10px; }
    .quote-pick { display: block; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--gold-soft); border-left: 3px solid var(--gold);
        background: rgba(255, 255, 255, .04); color: #fff; text-decoration: none; transition: background .15s ease, color .15s ease, box-shadow .15s ease; }
    .quote-pick blockquote { padding: 0; border: 0; color: inherit; }
    .quote-pick:hover, .quote-pick:focus-visible, .quote-pick[aria-current="true"] { background: var(--gold); color: #000; box-shadow: 0 0 18px rgba(255, 204, 0, .45); }
    .quote-pick:hover cite, .quote-pick:focus-visible cite, .quote-pick[aria-current="true"] cite { color: #000; }
    /* back-to-top: the same round button as the game's results screen */
    .to-top { position: fixed; bottom: 30px; right: 30px; z-index: 1050; width: 50px; height: 50px; border-radius: 50%;
        display: flex; align-items: center; justify-content: center; font-size: 1.2rem; cursor: pointer;
        background: rgba(8, 10, 18, 0.85); border: 1px solid rgba(255, 204, 0, 0.5); color: #ffcc00;
        box-shadow: 0 4px 12px rgba(0,0,0,0.5); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
        opacity: 0; visibility: hidden; transform: translateY(20px); transition: all 0.3s ease; }
    .to-top.is-on { opacity: 1; visibility: visible; transform: translateY(0); }
    .to-top:hover, .to-top:focus-visible { background: #ffcc00; color: #000; box-shadow: 0 0 16px rgba(255, 204, 0, 0.6); }
    @media (prefers-reduced-motion: reduce) { .to-top { transition: none; } }
    .sec-hint { margin: -6px 0 12px; font-size: .82rem; color: var(--muted); }

    /* actors / directors explorer */
    /* search box for genres / actors / directors: the same as the game's Play by Theme search */
    .gv-input { width: 100%; padding: 12px 14px; background: #0b0d17; color: #fff; border: 1px solid rgba(255, 204, 0, 0.4);
        border-radius: 8px; font-family: 'Courier New', monospace; font-size: 1rem; outline: none;
        transition: border-color 0.15s ease, box-shadow 0.15s ease; }
    .gv-input::placeholder { color: #64748b; }
    .gv-input:focus { border-color: #ffcc00; box-shadow: 0 0 0 3px rgba(255, 204, 0, 0.2), 0 0 16px rgba(255, 204, 0, 0.25); }
    /* search picker: the game's Play by Theme row of cards */
    .picker { margin: 0 0 6px; }
    .pk-search { margin-bottom: 10px; }
    .pk-scroller { display: flex; gap: 10px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity;
        padding: 2px 2px 8px; scrollbar-width: thin; scrollbar-color: rgba(255, 204, 0, 0.5) transparent; }
    .pk-theme { flex: 0 0 auto; min-width: 140px; max-width: 240px; scroll-snap-align: start; display: flex; flex-direction: column;
        align-items: flex-start; gap: 3px; text-align: left; padding: 10px 12px; color: #fff; cursor: pointer; text-decoration: none;
        background: rgba(255, 255, 255, 0.04); border: 1px solid rgba(255, 204, 0, 0.3); border-left: 3px solid #ffcc00; border-radius: 8px;
        font-family: 'Courier New', monospace; transition: background 0.15s ease, box-shadow 0.15s ease; }
    .pk-theme[hidden] { display: none; }
    .pk-theme .gv-theme-name { font-weight: 800; font-size: 0.9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
    .pk-theme .gv-theme-count { color: #94a3b8; font-size: 0.7rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
    .pk-theme:hover { background: rgba(255, 204, 0, 0.1); }
    .pk-theme.is-on { background: rgba(255, 204, 0, 0.16); border-color: #ffcc00; box-shadow: 0 0 0 2px #ffcc00 inset, 0 0 16px rgba(255, 204, 0, 0.35); }
    .pk-theme:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
    .pk-scroller .gv-empty { flex: 1 0 100%; text-align: center; color: #94a3b8; padding: 22px 0; font-family: 'Courier New', monospace; }
    .picker + .sec-hint { margin: 4px 0 0; }
    .pk-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--gold-soft); border-left: 3px solid var(--gold); background: rgba(255, 255, 255, .04); color: #fff; font: 800 .88rem var(--mono); text-decoration: none; white-space: nowrap; scroll-snap-align: start; }
    .pk-btn[hidden] { display: none; }
    .pk-btn small { color: var(--muted); font-weight: 700; }
    .pk-btn:hover, .pk-btn:focus-visible, .pk-btn[aria-current="true"] { background: var(--gold); color: #000; }
    .pk-btn:hover small, .pk-btn:focus-visible small, .pk-btn[aria-current="true"] small { color: #000; }
    .pk-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 22px; }


    /* ads: space is held so the page does not jump when an ad fills in */
    .ad-slot { margin: 30px 0; min-height: 120px; text-align: center; }
    .ad-label { display: block; margin-bottom: 4px; color: #64748b; font-size: .7rem; }
    .ad-slot.is-preview { display: flex; align-items: center; justify-content: center; border: 2px dashed rgba(148, 163, 184, .35); border-radius: 12px; }

    .pager { display: flex; justify-content: center; align-items: center; gap: 18px; margin: 22px 0 0; color: var(--muted); font-size: .9rem; }
    .pager a { color: var(--gold); text-decoration: none; font-weight: 800; }
    .source-note { margin-top: 10px; font-size: .82rem; color: var(--muted); }
    .source-note a { color: var(--muted); }

    @media (max-width: 760px) {
        .cols-2 { grid-template-columns: 1fr; }
        .play-cta { grid-template-columns: 1fr; }
        .facts { grid-template-columns: 1fr; gap: 2px; }
        .facts dd { margin-bottom: 10px; }
    }
