/* ===========================================================================
   SwapRaven theme — dark, authoritative. Self-hosted, no external resources.
   =========================================================================== */

:root {
    --bg:            #0b0d10;
    --bg-elev:       #14171d;
    --bg-elev-2:     #1b1f27;
    --bg-inset:      #0f1216;
    --border:        #272c36;
    --border-strong: #3a414f;

    --text:        #e7e9ec;
    --text-dim:    #9aa3af;
    --text-faint:  #6b7280;

    --gold:        #e3b341;
    --gold-bright: #f3cd6b;
    --gold-dim:    rgba(227, 179, 65, 0.14);

    --ok:    #3fb950;
    --warn:  #d29922;
    --bad:   #e5534b;
    --info:  #58a6ff;

    --radius:    10px;
    --radius-sm: 6px;
    --shadow:    0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);

    --serif: Georgia, "Times New Roman", "Iowan Old Style", serif;
    --sans:  system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --mono:  ui-monospace, "Cascadia Code", "SFMono-Regular", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background:
        radial-gradient(1100px 480px at 78% -8%, rgba(227,179,65,.06), transparent 60%),
        var(--bg);
    color: var(--text);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-bright); text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; }

hr { border: none; border-top: 1px solid var(--border); margin: 1.5rem 0; }

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

.container { width: min(1640px, 100% - 3rem); margin-inline: auto; }
/* Full-width shell (e.g. the directory) — 100% of content width, scrollbar-safe. */
.container-fluid { width: 100%; padding-inline: clamp(1rem, 2.5vw, 3rem); box-sizing: border-box; }
/* Keep reading-heavy pages comfortable on very wide screens. */
.auth-wrap, .form-wrap, .prose { --measure: 1; }

/* --- Header ------------------------------------------------------------- */
.site-header {
    border-bottom: 1px solid var(--border);
    background: rgba(11, 13, 16, 0.82);
    backdrop-filter: blur(8px);
    position: sticky;
    top: 0;
    z-index: 20;
}
.site-header .container,
.site-header .container-fluid {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    height: 64px;
}
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--text); }
.brand:hover { text-decoration: none; color: var(--text); }
.brand-mark { width: 34px; height: 34px; display: block; }
.brand-name {
    font-family: var(--serif);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: .01em;
}
.brand-name b { color: var(--gold); font-weight: 700; }

.main-nav { display: flex; gap: 1.25rem; margin-left: auto; align-items: center; flex-shrink: 0; }
/* Desktop menu items never wrap onto two lines (e.g. "Submit a / listing", "⇄ / Swap"). */
@media (min-width: 761px) {
    .main-nav a, .main-nav .nav-user, .main-nav .link-btn { white-space: nowrap; }
}
@media (min-width: 761px) and (max-width: 1150px) {
    .main-nav { gap: .85rem; }
    .main-nav a { font-size: .9rem; }
}
.nav-toggle { display: none; }
.nav-burger { display: none; }
.main-nav a {
    color: var(--text-dim);
    font-size: .95rem;
    font-weight: 500;
    padding: .25rem 0;
    border-bottom: 2px solid transparent;
}
.main-nav a:hover { color: var(--text); text-decoration: none; border-bottom-color: var(--border-strong); }
.main-nav a.active { color: var(--text); border-bottom-color: var(--gold); }

/* --- Mobile nav: hamburger + dropdown (no JS) --------------------------- */
@media (max-width: 760px) {
    .nav-burger {
        display: inline-flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        margin-left: auto;
        width: 42px;
        height: 38px;
        padding: 9px 8px;
        cursor: pointer;
        border: 1px solid var(--border-strong);
        border-radius: var(--radius-sm);
    }
    .nav-burger span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: opacity .15s; }

    .main-nav {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        margin-left: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: var(--bg-elev);
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow);
        padding: .35rem 0;
    }
    .nav-toggle:checked ~ .main-nav { display: flex; }

    .main-nav a,
    .main-nav .nav-user,
    .main-nav .logout-form {
        width: 100%;
        padding: .8rem clamp(1rem, 2.5vw, 3rem);
        border-bottom: 0;
    }
    .main-nav a.active { background: var(--bg-elev-2); }
    .main-nav .logout-form .link-btn { padding: 0; }
}

/* --- Layout primitives -------------------------------------------------- */
main { padding-block: 1.1rem 4rem; flex: 1 0 auto; }

.page-header { margin-bottom: 1.1rem; }
.page-eyebrow {
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: .72rem;
    color: var(--gold);
    font-weight: 600;
}
.page-title { font-family: var(--serif); font-size: 2.1rem; margin: .25rem 0 .35rem; }
.page-subtitle { color: var(--text-dim); margin: 0; max-width: 60ch; }

.directory-layout {
    display: grid;
    grid-template-columns: 270px 1fr;
    gap: 1.75rem;
    align-items: start;
}
@media (max-width: 820px) {
    .directory-layout { grid-template-columns: 1fr; }
}

/* --- Panels & filters --------------------------------------------------- */
.panel {
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.1rem 1.15rem;
}
.panel-title {
    font-size: .95rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--text-dim);
    margin: 0 0 1rem;
    padding-bottom: .6rem;
    border-bottom: 1px solid var(--border);
}
/* Filter & sort sidebar — visually set apart from the service cards on the right:
   a slightly different surface, a more visible border, and a minimal shadow. */
.filter-panel {
    position: sticky;
    top: 84px;
    background: var(--bg-elev-2);
    border-color: rgba(227, 179, 65, .35);
    box-shadow: 0 0 0 1px rgba(227, 179, 65, .22), 0 12px 34px rgba(0, 0, 0, .55);
}
.filter-panel .panel-title {
    color: var(--gold-bright);
    border-bottom-color: var(--border-strong);
}
.pair-fields { display: flex; align-items: center; gap: .4rem; }
.pair-field { flex: 1 1 0; min-width: 0; position: relative; display: block; }
.pair-field .input { width: 100%; min-width: 0; }
.pair-arrow { color: var(--text-dim); flex: 0 0 auto; }
/* In single-column (mobile) mode the sticky filter clings to the top and feels
   stuck on scroll; let it scroll away normally. Placed after the sticky rule so
   it wins the cascade (media queries don't add specificity). */
@media (max-width: 820px) {
    .filter-panel { position: static; top: auto; }
}
.sidebar-about { margin-top: 1.25rem; }
.sidebar-about-title { font-family: var(--serif); font-size: 1.45rem; margin: .25rem 0 .4rem; }
.sidebar-about-text { color: var(--text-dim); margin: 0; font-size: .92rem; line-height: 1.55; }
.filter-group { margin-bottom: 1rem; }
.filter-group > label {
    display: block;
    font-size: .8rem;
    font-weight: 600;
    color: var(--text-dim);
    margin-bottom: .35rem;
    letter-spacing: .02em;
}

.input, .select {
    width: 100%;
    background: var(--bg-inset);
    border: 1px solid var(--border-strong);
    color: var(--text);
    border-radius: var(--radius-sm);
    padding: .5rem .6rem;
    font: inherit;
    font-size: .9rem;
}
.input:focus, .select:focus { border-color: var(--gold); outline: none; }
.select {
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--text-faint) 50%),
                      linear-gradient(135deg, var(--text-faint) 50%, transparent 50%);
    background-position: calc(100% - 16px) 53%, calc(100% - 11px) 53%;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
    padding-right: 1.8rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    font: inherit;
    font-weight: 600;
    font-size: .9rem;
    border-radius: var(--radius-sm);
    padding: .55rem .9rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background .12s, border-color .12s, color .12s;
}
.btn-primary { background: var(--gold); color: #1a1407; }
.btn-primary:hover { background: var(--gold-bright); text-decoration: none; color: #1a1407; }
.btn-ghost { background: transparent; border-color: var(--border-strong); color: var(--text-dim); }
.btn-ghost:hover { color: var(--text); border-color: var(--text-faint); text-decoration: none; }
.btn-block { width: 100%; }
.filter-actions { display: flex; flex-direction: column; gap: .55rem; margin-top: 1.1rem; }

/* Multi-select filter facets (collapsible checkbox groups) */
.filter-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.filter-clear { font-size: .8rem; color: var(--text-dim); }
.filter-clear:hover { color: var(--text); }
.facet { border-top: 1px solid var(--border); padding: .55rem 0; }
.facet > summary {
    cursor: pointer; list-style: none; user-select: none;
    display: flex; align-items: center; gap: .5rem;
    font-size: .76rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
    color: var(--text-dim); padding: .15rem 0;
}
/* The state pill ("all" / "N of M") is pushed to the right so it lines up
   consistently across every facet, regardless of the label's length. */
.facet > summary .facet-state { margin-left: auto; }
.facet > summary::-webkit-details-marker { display: none; }
.facet > summary::after { content: "\25B8"; color: var(--text-faint); font-size: .7rem; transition: transform .15s ease; }
.facet[open] > summary::after { transform: rotate(90deg); }
.facet > summary:hover { color: var(--text); }
.facet-body { display: flex; flex-direction: column; gap: .42rem; padding: .55rem 0 .2rem; }
.facet-scroll { max-height: 220px; overflow-y: auto; padding-right: .3rem; }
.tag-match { display: flex; align-items: center; gap: .5rem; padding-bottom: .2rem; }
.tag-match .tag-match-label { font-size: .82rem; color: var(--text-dim); }
.seg-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; }
.seg-toggle input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.seg-toggle label { margin: 0; padding: .22rem .7rem; font-size: .8rem; cursor: pointer; color: var(--text-dim); background: var(--bg-elev); user-select: none; }
.seg-toggle label[for="tagMatchAll"] { border-left: 1px solid var(--border); }
.seg-toggle input:checked + label { background: var(--gold); color: #0e1116; font-weight: 600; }

/* --- Exchange speed (3-bar processing-time signal) --------------------- */
.speed { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; color: var(--text-dim); }
.speed-bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.speed-bar { width: 4px; background: var(--border); border-radius: 1px; }
.speed-bar:nth-child(1) { height: 6px; }
.speed-bar:nth-child(2) { height: 10px; }
.speed-bar:nth-child(3) { height: 14px; }
.speed.is-fast   .speed-bar.on { background: #4ec984; }
.speed.is-medium .speed-bar.on { background: #e3b341; }
.speed.is-slow   .speed-bar.on { background: #d25a5a; }
.speed-label { white-space: nowrap; }

/* --- Results ------------------------------------------------------------ */
.results-bar {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    color: var(--text-dim);
    font-size: .9rem;
}
.results-count strong { color: var(--text); }

/* Compact card grid — more listings per screen on the wide layout.
   Rows stretch so cards in a row are equal height. */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: .85rem;
    align-items: stretch;
}
.card-list { display: flex; flex-direction: column; gap: 1rem; } /* used by other pages */

.service-card {
    position: relative; /* anchor for the stretched title link */
    display: flex;
    flex-direction: column;
    gap: .55rem;
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: .85rem .9rem;
    transition: border-color .14s, background-color .14s, box-shadow .14s, transform .14s;
    cursor: pointer;
}
/* Highlight the whole card on hover or keyboard focus — clicking anywhere on it
   (except the Visit button) navigates to the profile page. */
.service-card:hover,
.service-card:focus-within {
    border-color: var(--gold);
    background: var(--bg-inset);
    box-shadow: 0 6px 20px rgba(0,0,0,.28);
    transform: translateY(-2px);
}
/* The title link's ::after covers the card, making the entire box clickable
   without JS. Genuinely separate links (Visit) sit above it via z-index. */
.card-title a.card-stretch::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: var(--radius);
}
.card-title a.card-stretch:focus-visible { outline: none; }
.service-card:focus-within { outline: 2px solid var(--gold); outline-offset: 2px; }

/* Mobile / touch: there's no hover, so highlight the card as it scrolls through
   the middle of the viewport. Pure CSS scroll-driven animation (no JS); browsers
   without scroll-timeline support simply skip it and tapping still works. */
@media (hover: none) and (prefers-reduced-motion: no-preference) {
    @supports (animation-timeline: view()) {
        .service-card {
            animation: card-spotlight linear both;
            animation-timeline: view();
            /* Only animate while the card crosses the centre band of the screen. */
            animation-range: cover 38% cover 62%;
        }

        /* Sponsors keep their persistent gold highlight — the scroll spotlight must
           NOT override it, or the sponsor only looks highlighted mid-scroll (reads as
           the highlight "appearing" a moment after load). It's already server-rendered. */
        .service-card.is-sponsored { animation: none; }

        @keyframes card-spotlight {
            0% {
                border-color: var(--border);
                background: var(--bg-elev);
                box-shadow: none;
                transform: none;
            }
            50% {
                border-color: var(--gold);
                background: var(--bg-inset);
                box-shadow: 0 6px 20px rgba(0,0,0,.28);
                transform: translateY(-2px);
            }
            100% {
                border-color: var(--border);
                background: var(--bg-elev);
                box-shadow: none;
                transform: none;
            }
        }
    }
}
.card-top { display: grid; grid-template-columns: 44px 1fr; gap: .65rem; align-items: center; }
.card-logo {
    width: 44px; height: 44px;
    border-radius: var(--radius-sm);
    background: var(--bg-inset);
    border: 1px solid var(--border);
    display: grid; place-items: center;
    overflow: hidden;
    color: var(--gold);
}
.card-logo img { width: 100%; height: 100%; object-fit: contain; }
.card-logo .monogram { font-family: var(--serif); font-size: 1.2rem; font-weight: 700; }

.card-headings { min-width: 0; }
.card-title { font-size: 1.02rem; margin: 0 0 .2rem; font-family: var(--sans); font-weight: 600; letter-spacing: -.01em; line-height: 1.15; }
.card-title a { color: var(--text); }
.card-title a:hover { color: var(--gold); text-decoration: none; }
.card-badges { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.card-sub { color: var(--text-faint); font-size: .85rem; margin: .15rem 0 .5rem; }
.card-desc {
    color: var(--text-dim); font-size: .85rem; margin: 0;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    /* Reserve two lines so 1-line and 2-line cards stay the same height. */
    min-height: 2.4em;
}
.card-meta { display: flex; flex-wrap: wrap; gap: .3rem .4rem; align-items: center; }
.card-meta .chip { font-size: .72rem; padding: .14rem .42rem; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; padding-top: .2rem; }
.card-link { font-size: .85rem; color: var(--text-dim); }
.card-link:hover { color: var(--text); }
/* The Visit button is the one link that must NOT trigger the card navigation —
   keep it above the stretched overlay. */
.card-foot .btn { position: relative; z-index: 2; }

.load-more-wrap { text-align: center; margin-top: 1.5rem; }
.load-more { min-width: 180px; }

/* --- Badges & chips ----------------------------------------------------- */
.badge {
    display: inline-flex; align-items: center; gap: .3rem;
    font-size: .72rem; font-weight: 700; letter-spacing: .03em;
    text-transform: uppercase;
    padding: .18rem .5rem;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    color: var(--text-dim);
    background: var(--bg-inset);
    white-space: nowrap;
}
.badge-kind { color: var(--info); border-color: rgba(88,166,255,.35); }

.grade {
    display: inline-grid; place-items: center;
    min-width: 1.7rem; height: 1.7rem; padding: 0 .35rem;
    border-radius: var(--radius-sm);
    font-family: var(--serif); font-weight: 700; font-size: 1rem;
    border: 1px solid transparent;
}
.grade-a { color: #0f1a10; background: var(--ok); }
.grade-b { color: #0f1a10; background: #74c365; }
.grade-c { color: #1a1407; background: var(--gold); }
.grade-d { color: #1a1407; background: var(--warn); }
.grade-f { color: #fff; background: var(--bad); }
.grade-ungraded { color: var(--text-faint); background: var(--bg-inset); border-color: var(--border-strong); }

.chip {
    display: inline-flex; align-items: center; gap: .35rem;
    font-size: .78rem; color: var(--text-dim);
    background: var(--bg-inset);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .2rem .5rem;
}
.chip .k { color: var(--text-faint); text-transform: uppercase; font-size: .66rem; letter-spacing: .05em; }
.chip .v { color: var(--text); font-weight: 600; }
.chip-good .v { color: var(--ok); }
.chip-warn .v { color: var(--warn); }
.chip-bad  .v { color: var(--bad); }
/* Neutral slate for indeterminate values (e.g. "Varies by provider") — not a caution. */
.chip-neutral .v { color: var(--text-dim); }

/* Repeatable form rows (submit form contact/link managers) */
.repeat-row { display: flex; gap: .5rem; flex-wrap: wrap; align-items: flex-end; margin-bottom: .55rem; }

/* ---- Sponsor landing page ---- */
.sponsor-layout { display: grid; grid-template-columns: 1fr 320px; gap: 1.25rem; align-items: start; }
@media (max-width: 900px) { .sponsor-layout { grid-template-columns: 1fr; } }
.sponsor-main { display: flex; flex-direction: column; gap: 1.25rem; }
.sponsor-side { display: flex; flex-direction: column; gap: 1.25rem; position: sticky; top: 84px; }

.benefit-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .6rem; }
.benefit-list li { position: relative; padding-left: 1.5rem; color: var(--text); line-height: 1.5; }
.benefit-list li::before { content: "✦"; position: absolute; left: 0; top: 0; color: var(--gold); }
.benefit-list.muted-list li { color: var(--text-dim); }
.benefit-list.muted-list li::before { content: "•"; color: var(--text-faint); }
.benefit-subhead { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-dim); margin: 1.1rem 0 .6rem; }

.slot-status { display: flex; flex-direction: column; gap: .55rem; }
.slot-row { display: flex; align-items: center; gap: .7rem; flex-wrap: wrap; padding: .6rem .8rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg-inset); }
.slot-row.free { border-style: dashed; }
.slot-tag { font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-faint); font-weight: 700; }
.slot-who { font-weight: 600; color: var(--text); }
.slot-who.slot-available { color: var(--ok); font-weight: 600; }
.slot-until { font-size: .82rem; color: var(--text-dim); }
.slot-extend { margin-left: auto; display: inline-flex; gap: .4rem; align-items: center; }
.select-sm { padding: .25rem .45rem; font-size: .8rem; max-width: 170px; }

.dur-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .7rem; }
.dur-card {
    display: flex; flex-direction: column; gap: .15rem; cursor: pointer;
    border: 1px solid var(--border-strong); border-radius: var(--radius); padding: .85rem 1rem;
    background: var(--bg-inset); transition: border-color .12s, background .12s;
}
.dur-card input { position: absolute; opacity: 0; pointer-events: none; }
.dur-card:hover { border-color: var(--text-faint); }
.dur-card:has(input:checked) { border-color: var(--gold); background: var(--gold-dim); box-shadow: 0 0 0 1px var(--gold) inset; }
.dur-days { font-weight: 700; color: var(--text); }
.dur-price { font-size: 1.15rem; font-weight: 800; color: var(--gold); }
.dur-cur { font-size: .8rem; font-weight: 600; color: var(--text-dim); }
.dur-per { font-size: .74rem; color: var(--text-faint); }
.dur-save { font-size: .78rem; font-weight: 700; color: var(--bad); }

.waitlist-card { border-color: color-mix(in srgb, var(--gold) 30%, transparent); }
.price-list, .proof-list { list-style: none; margin: 0; padding: 0; }
.price-list li { display: flex; justify-content: space-between; padding: .4rem 0; border-bottom: 1px solid var(--border); }
.price-list li:last-child { border-bottom: none; }
.proof-list li { display: flex; align-items: center; gap: .5rem; padding: .35rem 0; }
.proof-mark { color: var(--gold); }
.proof-name { font-weight: 600; color: var(--text); }
.proof-when { margin-left: auto; font-size: .78rem; color: var(--text-faint); }

.setup-steps { margin: .4rem 0 0; padding-left: 1.25rem; display: flex; flex-direction: column; gap: .55rem; color: var(--text); line-height: 1.5; }
.setup-steps code { font-size: .82rem; }
.copy-url { margin: .35rem 0 0; padding: .5rem .7rem; background: var(--bg-inset); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow-wrap: anywhere; }
.copy-url code { color: var(--gold-bright); }

/* Admin editorial note on the public profile */
.editorial-note {
    margin: 0 0 1.25rem; padding: .85rem 1.05rem;
    background: var(--gold-dim);
    border: 1px solid color-mix(in srgb, var(--gold) 32%, transparent);
    border-left: 3px solid var(--gold);
    border-radius: var(--radius);
}
.editorial-note-label {
    font-size: .68rem; text-transform: uppercase; letter-spacing: .06em;
    color: var(--gold); font-weight: 700; margin-bottom: .35rem;
}
.editorial-note p { margin: 0 0 .4rem; color: var(--text); }
.editorial-note p:last-child { margin-bottom: 0; }
/* AI overview: a cooler, distinct tint so it reads as machine-generated. */
.editorial-note.ai-overview {
    background: color-mix(in srgb, #5b8def 12%, transparent);
    border-color: color-mix(in srgb, #5b8def 34%, transparent);
    border-left-color: #5b8def;
}
.editorial-note.ai-overview .editorial-note-label { color: #8fb2ff; display: flex; align-items: center; gap: .5rem; }
.ai-badge {
    font-size: .6rem; letter-spacing: .04em; font-weight: 700;
    background: #5b8def; color: #0b1020; padding: .1rem .4rem; border-radius: 999px;
}

.tag-row { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .7rem; }
.tag {
    font-size: .76rem;
    color: var(--gold);
    background: var(--gold-dim);
    border: 1px solid rgba(227,179,65,.28);
    border-radius: 999px;
    padding: .15rem .55rem;
}
.tag:hover { background: rgba(227,179,65,.22); text-decoration: none; }

/* --- Detail page -------------------------------------------------------- */
.detail-layout { display: grid; grid-template-columns: 1fr 320px; gap: 1.75rem; align-items: start; }
@media (max-width: 900px) { .detail-layout { grid-template-columns: 1fr; } }

.detail-hero {
    display: grid; grid-template-columns: 80px 1fr; gap: 1.25rem;
    align-items: center; margin-bottom: 1.75rem;
}
.detail-hero .card-logo { width: 80px; height: 80px; }
.detail-hero .card-logo .monogram { font-size: 2.1rem; }
.detail-title { font-family: var(--serif); font-size: 2rem; margin: 0 0 .35rem; }
.detail-links { display: flex; flex-wrap: wrap; gap: .5rem .9rem; font-size: .9rem; margin-top: .5rem; }
.detail-links a { display: inline-flex; align-items: center; gap: .3rem; }

.stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .7rem; }
.stat {
    background: var(--bg-inset);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .6rem .7rem;
}
.stat .k { font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint); }
.stat .v { font-size: 1rem; font-weight: 600; margin-top: .15rem; }

.dl { margin: 0; }
.dl div { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-bottom: 1px solid var(--border); }
.dl div:last-child { border-bottom: none; }
.dl dt { color: var(--text-dim); }
.dl dd { margin: 0; text-align: right; color: var(--text); word-break: break-word; }

/* Contact methods as compact icon + name chips (inline, wrapping) */
.contact-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0; }
.contact-chip {
    display: inline-flex; align-items: center; gap: .38rem;
    font-size: .8rem; line-height: 1; color: var(--text-dim);
    background: var(--bg-inset);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .36rem .6rem;
    text-decoration: none; max-width: 100%;
}
a.contact-chip:hover { color: var(--text); border-color: var(--text-faint); text-decoration: none; }
.contact-chip.is-static { cursor: default; }
.contact-chip .ci { flex: 0 0 auto; width: 15px; height: 15px; opacity: .82; }
.contact-chip:hover .ci { opacity: 1; }
.contact-chip span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.contact-chip .chip-ext { color: var(--text-faint); font-size: .8em; margin-left: -.15rem; }

/* Per-service change history (audit trail) */
.audit-trail { display: flex; flex-direction: column; gap: .8rem; }
.audit-group {
    background: var(--bg-elev); border: 1px solid var(--border);
    border-radius: var(--radius); padding: .85rem 1rem;
}
.audit-when {
    display: flex; align-items: center; gap: .6rem; flex-wrap: wrap;
    margin-bottom: .5rem;
}
.audit-when time { color: var(--text-dim); font-size: .82rem; font-variant-numeric: tabular-nums; }
.audit-kind {
    font-size: .68rem; text-transform: uppercase; letter-spacing: .05em;
    padding: .12rem .45rem; border-radius: var(--radius-sm);
    background: var(--bg-inset); color: var(--text-dim); border: 1px solid var(--border);
}
.audit-kind-created { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 40%, transparent); }
.audit-kind-snapshot { color: var(--gold); border-color: color-mix(in srgb, var(--gold) 40%, transparent); }
.audit-note { margin: 0; color: var(--text-dim); }
.audit-table { width: 100%; border-collapse: collapse; }
.audit-table th {
    text-align: left; vertical-align: top; font-weight: 600; color: var(--text-dim);
    padding: .28rem .8rem .28rem 0; white-space: nowrap; width: 1%;
}
.audit-table td { padding: .28rem 0; color: var(--text); word-break: break-word; }
.audit-table tr + tr th, .audit-table tr + tr td { border-top: 1px solid var(--border); }
.audit-old { color: var(--text-faint); text-decoration: line-through; }
.audit-arrow { color: var(--text-faint); margin: 0 .35rem; }
.audit-new { color: var(--text); font-weight: 500; }

.section { margin-top: 2rem; }
.section-title {
    font-family: var(--serif); font-size: 1.35rem; margin: 0 0 1rem;
    padding-bottom: .5rem; border-bottom: 1px solid var(--border);
}

.coin-grid { display: flex; flex-wrap: wrap; gap: .5rem; }
.coin-pill {
    display: inline-flex; align-items: center; gap: .4rem;
    background: var(--bg-inset); border: 1px solid var(--border);
    border-radius: 999px; padding: .25rem .65rem; font-size: .85rem;
}
.coin-pill .sym { font-family: var(--mono); color: var(--gold); font-weight: 600; }
.coin-pill .nm { color: var(--text-dim); }

.review { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; margin-bottom: .9rem; }
.review-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.review-author { font-weight: 600; }
.stars { color: var(--gold); letter-spacing: .1em; font-size: .95rem; }
.stars .off { color: var(--border-strong); }

.empty {
    text-align: center; padding: 3rem 1rem; color: var(--text-dim);
    border: 1px dashed var(--border-strong); border-radius: var(--radius);
    background: var(--bg-elev);
}

.notice {
    background: var(--gold-dim);
    border: 1px solid rgba(227,179,65,.3);
    border-radius: var(--radius);
    padding: 1rem 1.15rem;
    color: var(--text);
}

.prose { color: var(--text); max-width: 70ch; }
/* On a listing page the description should span the column, matching the AI overview box width below it. */
.detail-description { max-width: none; }
.prose p { margin: 0 0 1rem; }

/* --- Footer ------------------------------------------------------------- */
.site-footer {
    border-top: 1px solid var(--border);
    color: var(--text-faint);
    font-size: .85rem;
    padding-block: 1.5rem;
    flex-shrink: 0;
}
.site-footer .container { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.site-footer a { color: var(--text-dim); }
.footer-note { color: var(--text-dim); font-size: .82rem; flex-basis: 100%; }
.affiliate-disclosure {
    width: min(1640px, 100% - 3rem); margin: .85rem auto 0;
    font-size: .68rem; line-height: 1.5; color: var(--text-faint); opacity: .8;
}

.muted { color: var(--text-dim); }
.text-faint { color: var(--text-faint); }
.skip-link { position: absolute; left: -999px; }
.skip-link:focus { left: 1rem; top: .5rem; background: var(--gold); color: #1a1407; padding: .5rem .8rem; border-radius: var(--radius-sm); z-index: 50; }

/* --- Account nav + flash ------------------------------------------------ */
.nav-user { color: var(--text); font-weight: 600; font-size: .95rem; }
.logout-form { display: inline; margin: 0; }
.link-btn {
    background: none; border: none; color: var(--text-dim);
    font: inherit; font-size: .95rem; font-weight: 500; cursor: pointer; padding: 0;
}
.link-btn:hover { color: var(--text); text-decoration: underline; }

.flash {
    background: rgba(63,185,80,.12);
    border: 1px solid rgba(63,185,80,.4);
    color: #b9f0c2;
    border-radius: var(--radius);
    padding: .8rem 1rem;
    margin-bottom: 1.5rem;
}

/* --- Forms -------------------------------------------------------------- */
.form-wrap { max-width: 780px; }
.auth-wrap { max-width: 430px; margin-inline: auto; }
.form-card { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem 1.6rem; }

/* Post-registration action hub: equal choices, no assumed intent. */
.welcome-actions { display: grid; gap: 1rem; margin-top: 1rem; }
.welcome-action { display: flex; flex-direction: column; gap: .5rem; }
.welcome-action-title { margin: 0; font-size: 1.05rem; }
.welcome-action-desc { margin: 0; color: var(--text-dim); font-size: .9rem; }
.welcome-action .btn { align-self: flex-start; margin-top: .3rem; }
.field { margin-bottom: 1.1rem; }
.field > label { display: block; font-size: .85rem; font-weight: 600; color: var(--text-dim); margin-bottom: .35rem; }
.field .hint { font-size: .8rem; color: var(--text-faint); margin-top: .3rem; }
textarea.input { min-height: 120px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 620px) { .form-row { grid-template-columns: 1fr; } }
.form-actions { display: flex; gap: .6rem; align-items: center; margin-top: .5rem; }

.check-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .45rem .8rem;
    background: var(--bg-inset); border: 1px solid var(--border); border-radius: var(--radius-sm);
    padding: .8rem; max-height: 230px; overflow: auto;
}
.check { display: flex; align-items: center; gap: .45rem; font-size: .88rem; color: var(--text); }
.check input { accent-color: var(--gold); width: 15px; height: 15px; }

.field-validation-error, .text-danger { color: #ff8a80; font-size: .82rem; display: block; margin-top: .3rem; }
.validation-summary-errors { color: #ff8a80; font-size: .9rem; margin-bottom: 1rem; }
.validation-summary-errors ul { margin: .3rem 0 0; padding-left: 1.1rem; }

.keycode {
    font-family: var(--mono); font-size: 1.5rem; letter-spacing: .08em; color: var(--gold);
    background: var(--bg-inset); border: 1px dashed rgba(227,179,65,.5); border-radius: var(--radius-sm);
    padding: 1rem 1.2rem; text-align: center; margin: 1.1rem 0; user-select: all;
}

/* --- Admin moderation --------------------------------------------------- */
.admin-queue { display: flex; flex-direction: column; gap: 1rem; }
.queue-item { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; }
.queue-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-top: .8rem; }
.inline-form { display: inline; margin: 0; }
.btn-approve { background: var(--ok); color: #0f1a10; }
.btn-approve:hover { background: #5fcf6e; color: #0f1a10; text-decoration: none; }
.btn-reject { background: transparent; border-color: rgba(229,83,75,.5); color: #ff8a80; }
.btn-reject:hover { background: rgba(229,83,75,.12); color: #ff8a80; text-decoration: none; }
.queue-grade { background: var(--bg-inset); border: 1px solid var(--border-strong); color: var(--text); border-radius: var(--radius-sm); padding: .35rem .5rem; font: inherit; font-size: .85rem; }

/* --- Button sizes, CTAs, pager ------------------------------------------ */
.btn-sm { padding: .32rem .65rem; font-size: .8rem; }
.btn-lg { padding: .7rem 1.3rem; font-size: 1rem; }
.detail-cta { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin-top: .7rem; }
.card-cta { margin-left: auto; }
a.coin-pill:hover { border-color: var(--border-strong); background: var(--bg-elev-2); text-decoration: none; }
.pager { display: flex; gap: .5rem; align-items: center; justify-content: center; margin-top: 1.75rem; }
.pager .page-info { color: var(--text-dim); font-size: .9rem; padding: 0 .4rem; }
.btn.is-disabled { opacity: .4; pointer-events: none; }

.captcha { margin: .2rem 0 .5rem; line-height: 0; }
.captcha svg { border: 1px solid var(--border); border-radius: var(--radius-sm); }

/* --- Coin search typeahead (JS enhancement) ----------------------------- */
.typeahead { position: relative; }
.typeahead-list {
    position: absolute;
    left: 0; right: 0;
    top: calc(100% + 4px);
    z-index: 30;
    margin: 0; padding: .25rem;
    list-style: none;
    background: var(--bg-elev-2);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    max-height: 260px;
    overflow: auto;
}
.typeahead-item {
    display: flex; gap: .5rem; align-items: baseline;
    padding: .4rem .55rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: .88rem;
}
.typeahead-item.active, .typeahead-item:hover { background: var(--gold-dim); }
.typeahead-item .ta-sym { font-family: var(--mono); color: var(--gold); font-weight: 600; }
.typeahead-item .ta-name { color: var(--text-dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* --- Blog (public) ------------------------------------------------------ */
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.25rem; }
.blog-card { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: border-color .15s, transform .15s; }
.blog-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.blog-card-link { display: flex; flex-direction: column; height: 100%; color: inherit; text-decoration: none; }
.blog-card-link:hover { text-decoration: none; color: inherit; }
.blog-card-media { aspect-ratio: 16 / 9; overflow: hidden; background: var(--bg-elev-2); }
.blog-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-card-body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; gap: .4rem; flex: 1 1 auto; }
.blog-date { font-size: .78rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: .03em; }
/* Date · reading-time meta row (every blog card + post header). */
.blog-meta { display: flex; align-items: center; flex-wrap: wrap; gap: .4rem; margin: 0; }
.blog-meta .blog-date { margin: 0; }
.blog-readtime, .blog-meta-sep { font-size: .78rem; color: var(--text-dim); text-transform: uppercase; letter-spacing: .03em; }
.blog-card-title { font-size: 1.15rem; margin: 0; line-height: 1.3; }
.blog-card-excerpt { color: var(--text-dim); font-size: .9rem; margin: 0; }
.blog-readmore { color: var(--gold); font-size: .85rem; font-weight: 600; margin-top: auto; }

.blog-post { max-width: 760px; margin: 0 auto; }
.blog-post-head { margin-bottom: 1.25rem; }
.blog-post-title { font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.2; margin: .3rem 0 0; }
.blog-post-hero { border-radius: var(--radius); overflow: hidden; margin-bottom: 1.5rem; border: 1px solid var(--border); }
.blog-post-hero img { width: 100%; height: auto; display: block; }
.blog-post-body { font-size: 1.04rem; line-height: 1.75; }
.blog-post-body img { max-width: 100%; height: auto; border-radius: var(--radius-sm); }

/* --- Blog prev/next nav ------------------------------------------------ */
.blog-post-nav {
    max-width: 760px;
    margin: 2.5rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.blog-post-nav-next { text-align: right; }
.blog-post-nav a {
    display: block;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-elev);
    text-decoration: none;
    height: 100%;
    transition: border-color 0.15s ease;
}
.blog-post-nav a:hover { border-color: var(--border-strong); }
.blog-post-nav-label { display: block; font-size: 0.8rem; color: var(--text-faint); margin-bottom: 0.25rem; }
.blog-post-nav-title { display: block; color: var(--text); font-weight: 600; line-height: 1.35; }
@media (max-width: 560px) {
    .blog-post-nav { grid-template-columns: 1fr; }
    .blog-post-nav-next { text-align: left; }
}

/* --- Blog comments ----------------------------------------------------- */
.blog-comments { max-width: 760px; margin: 2.5rem auto 0; }
.comment-list { list-style: none; margin: 0 0 1.5rem; padding: 0; display: flex; flex-direction: column; gap: 1rem; }
.comment { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem; }
.comment-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: .35rem; }
.comment-author { font-weight: 600; }
.comment-date { color: var(--text-dim); font-size: .85rem; white-space: nowrap; }
.comment-body { margin: 0; line-height: 1.6; white-space: pre-wrap; word-break: break-word; }

/* --- Blog admin: HTML editor ------------------------------------------- */
.html-editor { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.html-toolbar { display: flex; flex-wrap: wrap; gap: .25rem; padding: .4rem; background: var(--bg-elev); border-bottom: 1px solid var(--border); }
.html-toolbar button { background: var(--bg-elev-2); border: 1px solid var(--border); color: var(--text); border-radius: 4px; padding: .25rem .55rem; font-size: .85rem; cursor: pointer; }
.html-toolbar button:hover { border-color: var(--gold); }
.html-toolbar button.active { background: var(--gold-dim); border-color: var(--gold); }
.html-toolbar-spacer { flex: 1; }
.html-wysiwyg { min-height: 340px; padding: 1rem 1.1rem; background: var(--bg); outline: none; overflow-y: auto; }
.html-wysiwyg:empty::before { content: "Write your post…"; color: var(--text-dim); }
.html-wysiwyg[hidden] { display: none; }
.html-source { display: block; width: 100%; border: 0; border-radius: 0; font-family: var(--mono); font-size: .86rem; resize: vertical; }
.html-source[hidden] { display: none; }
.blog-image-current { max-width: 320px; margin: .2rem 0 .5rem; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.blog-image-current img { width: 100%; height: auto; display: block; }
.footer-links a { white-space: nowrap; }
.footer-x {
    display: inline-flex; align-items: center; gap: .4rem;
    padding: .3rem .7rem; border: 1px solid var(--border); border-radius: 999px;
    color: var(--text-dim); font-size: .85rem; font-weight: 600; text-decoration: none;
    transition: border-color .15s, color .15s;
}
.footer-x:hover { border-color: var(--text); color: var(--text); text-decoration: none; }
.footer-x .ci { width: 15px; height: 15px; }

/* --- Thumbs up/down voting ----------------------------------------------- */
.votes { display: inline-flex; align-items: center; gap: .25rem; }
.vote-btn {
    display: inline-flex; align-items: center; gap: .25rem;
    padding: .2rem .5rem; border: 1px solid var(--border); border-radius: 999px;
    background: var(--bg-elev); color: var(--text-dim); font-size: .82rem; line-height: 1;
    cursor: pointer; text-decoration: none; transition: border-color .12s, color .12s, background .12s;
}
.vote-btn:hover { border-color: var(--text-faint); color: var(--text); text-decoration: none; }
.vote-btn .vote-ico { font-size: .78em; }
.vote-up.active { color: var(--good); border-color: var(--good); background: color-mix(in srgb, var(--good) 14%, transparent); }
.vote-down.active { color: var(--bad); border-color: var(--bad); background: color-mix(in srgb, var(--bad) 14%, transparent); }
.vote-net { min-width: 1.4em; text-align: center; font-weight: 700; font-size: .85rem; color: var(--text); }
.votes.is-readonly .vote-btn { cursor: default; }
.votes-lg .vote-btn { padding: .4rem .8rem; font-size: .95rem; }
.votes-lg .vote-net { font-size: 1.05rem; min-width: 1.8em; }
.detail-vote { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.detail-vote-label { font-size: .9rem; color: var(--text-dim); }
.card-foot-actions { display: inline-flex; align-items: center; gap: .5rem; margin-left: auto; }
.review-votes { margin-left: auto; }

/* --- Filter facet state ("all" vs narrowed) ------------------------------- */
.facet-state { font-size: .72rem; font-weight: 600; color: var(--text-dim); margin-left: .25rem; }
.facet-state.is-narrowed { color: #1a1407; background: var(--gold); padding: .05rem .4rem; border-radius: 999px; }
.results-filtered { font-size: .85rem; color: var(--gold); }
.results-filtered a { margin-left: .35rem; }

/* --- Monerica review badge (footer) --------------------------------------- */
.footer-badge { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; font-size: 13px; font-weight: bold; line-height: 1.2; color: #fff; background-color: #1d1d1d; border: 1px solid #ff6600; border-radius: 8px; text-decoration: none; }
.footer-badge:hover { text-decoration: none; filter: brightness(1.12); }
.footer-badge .badge-logo { display: inline-flex; align-items: center; background: #fff; border-radius: 4px; padding: 3px 5px; line-height: 0; }
.footer-badge .badge-logo img { height: 18px; width: auto; display: block; border: 0; }

/* --- Domain verification + official owner --------------------------------- */
.badge-official {
    color: #1a1407; background: var(--gold); border-color: var(--gold);
    font-weight: 700;
}
.owner-cta {
    display: flex; gap: .7rem; align-items: flex-start;
    background: var(--gold-dim); border: 1px solid color-mix(in srgb, var(--gold) 40%, transparent);
    border-radius: var(--radius); padding: .8rem 1rem; margin: 0 0 1.1rem;
    font-size: .92rem;
}
.owner-cta-icon {
    flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%;
    background: var(--gold); color: #1a1407; font-weight: 800;
    display: grid; place-items: center; font-size: .8rem;
}
.owner-cta a { font-weight: 600; white-space: nowrap; }
.review-reply {
    margin: .8rem 0 0 0; padding: .7rem .9rem;
    border-left: 3px solid var(--gold); background: var(--bg-elev);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.reply-form { margin-top: .7rem; }
.reply-form summary { cursor: pointer; color: var(--gold); font-size: .86rem; font-weight: 600; }
.reply-form form { margin-top: .5rem; }
.domain-card.is-verified { border-color: color-mix(in srgb, var(--gold) 45%, transparent); }
.verify-method { margin: .6rem 0; padding: .6rem .8rem; background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.verify-method-title { font-weight: 600; font-size: .9rem; margin-bottom: .2rem; }

/* --- Admin data table (click analytics, etc.) -------------------------- */
.data-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.data-table th, .data-table td { padding: .5rem .65rem; border-bottom: 1px solid var(--border); text-align: left; }
.data-table thead th { font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-dim); white-space: nowrap; }
.data-table tbody tr:hover { background: var(--bg-elev); }
.data-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.data-table th.num { text-align: right; }

/* --- Sponsor strip (omnipresent: sticky under the header) --------------- */
.sponsor-strip {
    background: linear-gradient(180deg, rgba(227,179,65,.10), var(--bg));
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 64px;
    z-index: 18;
}
.sponsor-strip-inner { display: flex; align-items: center; justify-content: center; gap: .85rem; flex-wrap: wrap; padding: .6rem 0; min-height: 48px; }
.sponsor-label {
    text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 700;
    color: var(--gold); border: 1px solid rgba(227,179,65,.4); border-radius: 999px; padding: .14rem .6rem;
}
/* Sponsor = a square-cornered gold box (not a pill), so it reads as different from everything else. */
.sponsor-chip {
    display: inline-flex; align-items: center; gap: .55rem;
    background: linear-gradient(180deg, rgba(227,179,65,.24), rgba(227,179,65,.10));
    border: 2px solid var(--gold);
    border-radius: 4px; padding: .24rem .85rem .24rem .26rem; color: var(--text); font-size: 1rem; font-weight: 700;
    box-shadow: 0 0 0 1px rgba(0,0,0,.35), 0 2px 10px rgba(227,179,65,.18);
    outline: none;
    transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}
.sponsor-chip:hover,
.sponsor-chip:focus-visible,
.sponsor-chip:active {
    border-color: var(--gold-bright);
    background: linear-gradient(180deg, rgba(227,179,65,.38), rgba(227,179,65,.18));
    box-shadow: 0 0 0 1px rgba(0,0,0,.35), 0 2px 14px rgba(227,179,65,.32);
    text-decoration: none; color: var(--text);
}
.sponsor-chip img { width: 30px; height: 30px; object-fit: cover; border-radius: 3px; background: var(--bg-inset); border: 1px solid rgba(227,179,65,.6); }
.sponsor-chip .sponsor-mono { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 3px; background: var(--bg-inset); border: 1px solid rgba(227,179,65,.45); color: var(--gold); font-family: var(--serif); font-size: 1rem; }
.sponsor-cta { margin-left: .4rem; font-size: .9rem; font-weight: 600; }
/* Smaller "Become a sponsor" link + the "N of 3 spots open" availability note. */
.sponsor-cta-sm { font-size: .76rem; margin-left: .35rem; }
.sponsor-avail { font-size: .72rem; color: var(--text-faint); white-space: nowrap; }

/* --- Inline sponsors in the header dead space (desktop) ---------------- */
.header-sponsors { flex: 1 1 auto; min-width: 0; display: flex; justify-content: center; }
.header-sponsors-inner { display: flex; align-items: center; gap: .6rem; min-width: 0; max-width: 100%; }
.header-sponsors-rail { display: flex; align-items: center; gap: .5rem; min-width: 0; overflow: hidden; }
.header-sponsors .sponsor-chip { font-size: .95rem; font-weight: 700; padding: .22rem .8rem .22rem .26rem; white-space: nowrap; }
.header-sponsors .sponsor-chip img,
.header-sponsors .sponsor-chip .sponsor-mono { width: 27px; height: 27px; }
.header-sponsors .sponsor-label,
.header-sponsors .sponsor-cta { white-space: nowrap; }
/* A sponsor box is never squeezed or cut off; as the header gets tighter it sheds extras instead:
   first the "N of 3 spots open" note, then the "Become a sponsor" link, then the names (logos only),
   and below 1150px the sponsors move to their own strip under the header (as on phones). */
.header-sponsors .sponsor-chip { flex-shrink: 0; }
@media (max-width: 1600px) { .header-sponsors .sponsor-avail { display: none; } }
@media (max-width: 1450px) { .header-sponsors .sponsor-cta { display: none; } }
@media (max-width: 1320px) { .header-sponsors .sponsor-chip > span:last-child { display: none; } }
@media (min-width: 1151px) { .sponsor-strip { display: none; } }
@media (max-width: 1150px) { .header-sponsors { display: none; } }

/* --- Sponsored markers -------------------------------------------------- */
.service-card.is-sponsored { border-color: rgba(227,179,65,.55); box-shadow: 0 0 0 1px rgba(227,179,65,.25); }
.badge-sponsored { color: #1a1407; background: var(--gold); border-color: var(--gold); }

/* --- Sponsor wizard ----------------------------------------------------- */
.slot-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .7rem; }
.slot-option {
    display: flex; flex-direction: column; gap: .2rem;
    border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
    padding: .7rem .8rem; cursor: pointer; background: var(--bg-inset);
}
.slot-option:has(input:checked) { border-color: var(--gold); box-shadow: 0 0 0 1px rgba(227,179,65,.3); }
.slot-option.is-taken { opacity: .5; cursor: not-allowed; }
.slot-option input { accent-color: var(--gold); }
.slot-option .slot-name { font-weight: 600; }
.slot-option .slot-state { font-size: .8rem; color: var(--text-dim); }

.pay-option {
    display: grid; grid-template-columns: auto 1fr; gap: .2rem .6rem; align-items: center;
    border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
    padding: .7rem .85rem; margin-bottom: .6rem; cursor: pointer;
}
.pay-option:has(input:checked) { border-color: var(--gold); box-shadow: 0 0 0 1px rgba(227,179,65,.3); }
.pay-option input { accent-color: var(--gold); grid-row: span 2; }
.pay-option .pay-name { font-weight: 600; }
.pay-option .pay-note { grid-column: 2; font-size: .82rem; color: var(--text-dim); }

/* --- Rankings methodology page ------------------------------------------ */
.rank-factors { display: flex; flex-direction: column; gap: .6rem; margin: 1rem 0 1.25rem; }
.rank-factor {
    display: grid; grid-template-columns: 64px 1fr; gap: 1rem; align-items: center;
    background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
    padding: .8rem 1rem;
}
.rank-weight {
    font-family: var(--serif); font-size: 1.5rem; font-weight: 700; color: var(--gold);
    text-align: center;
}
.rank-name { font-weight: 600; }
.grade-legend { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; margin: .75rem 0 1.25rem; color: var(--text-dim); }
.grade-legend .grade { margin-left: .35rem; }
.prose .dl { margin: .5rem 0 1.25rem; }
.prose .dl dt .chip { text-transform: none; }

/* --- Country flags ------------------------------------------------------ */
.badge-flag { font-size: 1rem; line-height: 1; padding: .1rem .35rem; letter-spacing: 0; text-transform: none; }
.flag { font-size: 1.15rem; margin-right: .3rem; vertical-align: -.05em; }

/* --- Admin URL field "Open" link --------------------------------------- */
.url-open {
    display: inline-block;
    margin-top: .3rem;
    font-size: .8rem;
    color: var(--gold);
}
.url-open[hidden] { display: none; }
.url-open:hover { text-decoration: underline; }

/* --- Uptime page -------------------------------------------------------- */
.uptime-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .7rem; margin-bottom: 1.25rem; }
.uptime-chart { background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: .8rem 1rem; }
.uptime-chart svg { width: 100%; height: auto; display: block; }

/* --- Review CTA --------------------------------------------------------- */
.btn-review { background: var(--gold-dim); border-color: var(--gold); color: var(--gold-bright); }
.btn-review:hover { background: var(--gold); color: #1a1407; text-decoration: none; }
#write-review { scroll-margin-top: 84px; }

/* --- Suggest-an-edit CTA (public profile) ------------------------------- */
.suggest-edit-cta {
    display: flex; flex-wrap: wrap; align-items: center; gap: .6rem;
    margin-top: 1.5rem; padding-top: 1.1rem;
    border-top: 1px solid var(--border);
    font-size: .9rem; color: var(--text-dim);
}

/* --- Revision diff table (admin review) --------------------------------- */
.rev-diff { width: 100%; border-collapse: collapse; font-size: .9rem; margin: .2rem 0 .8rem; }
.rev-diff th, .rev-diff td { text-align: left; padding: .5rem .7rem; border-bottom: 1px solid var(--border); vertical-align: top; white-space: pre-line; }
.rev-diff thead th { font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-dim); }
.rev-diff tbody th { width: 9rem; font-weight: 600; color: var(--text-dim); }
.rev-diff td.rev-old { color: var(--text-dim); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--bad) 60%, transparent); }
.rev-diff td.rev-new { color: var(--good); font-weight: 600; }

/* ============================================================================
   /swap — rate aggregator
   ============================================================================ */
/* Make the Swap link a prominent pill so it stands out in the nav. */
.main-nav a.nav-swap {
    color: #14110a;
    font-weight: 700;
    background: var(--gold);
    border: 1px solid var(--gold);
    border-radius: 999px;
    padding: .3rem .85rem;
}
.main-nav a.nav-swap:hover,
.main-nav a.nav-swap.active {
    background: var(--gold-bright);
    border-color: var(--gold-bright);
    color: #14110a;
}
@media (max-width: 760px) {
    /* In the mobile dropdown the gold pill reads like "active". Tone it down to
       gold text on a normal row so it doesn't masquerade as the current page... */
    .main-nav a.nav-swap {
        border-radius: 0;
        background: transparent;
        border: none;
        color: var(--gold-bright);
        padding: .8rem clamp(1rem, 2.5vw, 3rem);
    }
    .main-nav a.nav-swap:hover { background: var(--bg-elev-2); color: var(--gold-bright); }

    /* ...and make the page you're actually on unmistakable: gold left bar + bold. */
    .main-nav a.active,
    .main-nav a.nav-swap.active {
        background: var(--bg-elev-2);
        box-shadow: inset 4px 0 0 var(--gold);
        font-weight: 700;
        color: var(--text);
    }
    .main-nav a.nav-swap.active { color: var(--gold-bright); }
}

.swap-hero { max-width: 920px; margin: 0 auto 1.5rem; text-align: center; }
.swap-title { font-size: 2rem; margin: 0 0 .35rem; }
.swap-sub { color: var(--text-dim); max-width: 620px; margin: 0 auto 1.25rem; }

.swap-form {
    display: flex; flex-wrap: wrap; align-items: end; justify-content: center;
    gap: .6rem; background: var(--bg-elev); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 1rem; text-align: left;
}
.swap-field { display: flex; flex-direction: column; gap: .25rem; position: relative; flex: 1 1 160px; min-width: 130px; }
.swap-field-amount { flex: 0 1 120px; min-width: 90px; }
.swap-field label { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--text-dim); }
.swap-field input {
    background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
    color: var(--text); padding: .55rem .65rem; font-size: 1rem; width: 100%;
}
.swap-field input:focus { outline: none; border-color: var(--gold); }
.swap-reverse {
    align-self: end; flex: 0 0 auto; margin-bottom: 1px;
    width: 38px; height: 40px; cursor: pointer;
    background: var(--bg-elev); color: var(--gold);
    border: 1px solid var(--border-strong); border-radius: 8px;
    font-size: 1.1rem; line-height: 1; transition: background .15s, color .15s;
}
.swap-reverse:hover { background: var(--gold-dim); color: var(--gold-bright); }
.swap-go { flex: 0 0 auto; align-self: stretch; margin-top: auto; }
.swap-field-rate { flex: 0 0 auto; }
.swap-rate-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.swap-rate-opt {
    padding: .55rem .7rem; font-size: .85rem; color: var(--text-dim);
    cursor: pointer; background: var(--bg); white-space: nowrap; user-select: none;
}
.swap-rate-opt + .swap-rate-opt { border-left: 1px solid var(--border); }
.swap-rate-opt.on { background: var(--gold-dim); color: var(--gold-bright); font-weight: 600; }
.swap-rate-opt input { position: absolute; opacity: 0; width: 0; height: 0; }

.swap-clear {
    flex: 0 0 auto; align-self: center;
    font-size: .8rem; color: var(--text-dim);
    text-decoration: underline; text-underline-offset: 2px;
    padding: .25rem .3rem; background: none; border: none;
}
.swap-clear:hover { color: var(--text); }

.swap-disclaimer {
    font-size: .8rem; color: var(--text-dim); max-width: 720px;
    margin: .9rem auto 0; line-height: 1.5;
}
.swap-disclaimer strong { color: var(--text); }

.swap-results-wrap { margin-top: 1.5rem; }
.swap-results-head {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: .6rem; margin-bottom: .7rem;
}
.swap-results-count { color: var(--text-dim); }
.swap-results-count strong { color: var(--text); }

/* ── Loading / "fetching" state ─────────────────────────────────────────── */
.swap-loading {
    display: flex; align-items: center; justify-content: center; gap: .55rem;
    margin: .9rem auto 0; color: var(--text-dim); font-size: .9rem;
}
.swap-spinner {
    width: 16px; height: 16px; border-radius: 50%;
    border: 2px solid var(--border); border-top-color: var(--gold);
    display: inline-block; animation: swap-spin .7s linear infinite;
}
@keyframes swap-spin { to { transform: rotate(360deg); } }
.swap-go.is-loading { opacity: .8; cursor: progress; }
.swap-go.is-loading::before {
    content: ""; display: inline-block; width: 12px; height: 12px;
    margin-right: 6px; vertical-align: -2px; border-radius: 50%;
    border: 2px solid rgba(0,0,0,.35); border-top-color: rgba(0,0,0,.85);
    animation: swap-spin .7s linear infinite;
}
@media (prefers-reduced-motion: reduce) {
    .swap-spinner, .swap-go.is-loading::before { animation: none; }
}

/* ── Results table ──────────────────────────────────────────────────────── */
.swap-table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); }
.swap-table { width: 100%; border-collapse: collapse; font-size: .9rem; min-width: 760px; }
.swap-table th, .swap-table td { padding: .55rem .7rem; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.swap-table th { background: var(--bg-elev); color: var(--text-dim); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; position: sticky; top: 0; }
.swap-table td.num, .swap-table th.num { text-align: right; }
.swap-table tbody tr:hover { background: rgba(255,255,255,.03); }

.swap-table th.sortable { cursor: pointer; user-select: none; }
.swap-table th.sortable:hover { color: var(--text); }
.swap-table th.sortable::after { content: " ⇅"; opacity: .35; font-size: .85em; }
.swap-table th.sort-asc::after { content: " ▲"; opacity: .9; }
.swap-table th.sort-desc::after { content: " ▼"; opacity: .9; }

.swap-get strong { font-weight: 700; }   /* colour set inline (heatmap) */
.swap-rate { color: var(--text-dim); }

.swap-ex { white-space: normal; }
.swap-ex-logo { display: inline-flex; width: 22px; height: 22px; margin-right: .5rem; vertical-align: middle; }
.swap-ex-logo img { width: 22px; height: 22px; object-fit: contain; border-radius: 5px; }
.swap-ex-logo .monogram { width: 22px; height: 22px; font-size: .7rem; display: inline-flex; align-items: center; justify-content: center; border-radius: 5px; background: var(--bg-elev); }
.swap-ex-name { vertical-align: middle; }
.swap-na { color: var(--text-dim); }

.swap-row.is-best { background: rgba(62,207,142,.07); }
.swap-row.is-sponsored { background: rgba(212,175,55,.08); box-shadow: inset 3px 0 0 var(--gold); }
.swap-row.is-sponsored:hover { background: rgba(212,175,55,.12); }

.badge-best { background: rgba(62,207,142,.18); color: var(--ok); font-weight: 700; }

.swap-empty { text-align: center; color: var(--text-dim); padding: 2rem 1rem; }
.swap-empty-sub { font-size: .85rem; }

@media (max-width: 560px) {
    .swap-field, .swap-field-amount { flex-basis: 100%; }
    .swap-reverse { align-self: center; width: 100%; height: 34px; }
    .swap-go { width: 100%; justify-content: center; }
}

/* Text selection: brand yellow background, black text. */
::selection { background: var(--gold); color: #000; }
::-moz-selection { background: var(--gold); color: #000; }

/* Mobile "see prices below" cue — flashes, bounces, then fades. */
.swap-scroll-cue {
    text-align: center; font-size: .9rem; font-weight: 600;
    color: var(--gold-bright); margin: .25rem auto .5rem; opacity: 0;
    animation: swap-cue 2.4s ease-out forwards;
}
.swap-cue-arrow { display: inline-block; }
@keyframes swap-cue {
    0%   { opacity: 0; transform: translateY(-4px); }
    12%  { opacity: 1; }
    28%  { transform: translateY(3px); }
    44%  { transform: translateY(-2px); }
    60%  { transform: translateY(3px); }
    78%  { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(7px); }
}
@media (prefers-reduced-motion: reduce) { .swap-scroll-cue { animation: none; opacity: 1; } }

/* Sponsored swap results: featured block above the table + stronger in-table row. */
.swap-featured {
    margin: 0 0 1rem; padding: .7rem .8rem;
    border: 1px solid var(--gold); border-radius: var(--radius);
    background: var(--gold-dim);
}
.swap-featured-label {
    font-size: .75rem; text-transform: uppercase; letter-spacing: .05em;
    color: var(--gold-bright); font-weight: 700; margin-bottom: .5rem;
}
.swap-featured-cards {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .6rem;
}
.swap-featured-card {
    display: flex; flex-direction: column; gap: .3rem;
    background: var(--bg-elev); border: 1px solid var(--gold);
    border-radius: 8px; padding: .6rem .7rem;
}
.swap-featured-top { display: flex; align-items: center; gap: .45rem; }
.swap-featured-logo { width: 22px; height: 22px; display: inline-flex; flex: 0 0 auto; }
.swap-featured-logo img { width: 22px; height: 22px; object-fit: contain; border-radius: 5px; }
.swap-featured-logo .monogram {
    width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center;
    font-size: .7rem; border-radius: 5px; background: var(--bg-elev-2);
}
.swap-featured-name { font-weight: 600; font-size: .92rem; }
.swap-featured-get { font-size: 1.15rem; font-weight: 700; word-break: break-all; }
.swap-featured-ticker { font-size: .85rem; color: var(--text-dim); font-weight: 600; }
.swap-featured-rate { font-size: .78rem; color: var(--text-dim); }
.swap-featured-card .btn { margin-top: .25rem; align-self: flex-start; }

/* Make the sponsored row in the table clearly stand out. */
.swap-table tbody tr.swap-row.is-sponsored {
    background: rgba(227, 179, 65, .14);
    box-shadow: inset 4px 0 0 var(--gold);
}
.swap-table tbody tr.swap-row.is-sponsored:hover { background: rgba(227, 179, 65, .2); }

/* ---- Mini 7-day uptime sparkline (profile page) ---- */
.uptime-mini { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.uptime-mini-head { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; margin-bottom: .5rem; }
.uptime-mini-head .k { color: var(--text-faint); text-transform: uppercase; font-size: .66rem; letter-spacing: .05em; }
.uptime-mini-head .v { font-weight: 600; font-size: .9rem; }
.uptime-mini-svg { display: block; max-width: 100%; height: auto; }
.uptime-mini-empty { font-size: .85rem; margin: .25rem 0 0; }
.uptime-mini-link { display: inline-block; margin-top: .4rem; font-size: .8rem; color: var(--text-faint); }
.uptime-mini-link:hover { color: var(--text); }

/* --- live swap-quote streaming (results arriving one exchange at a time) --- */
/* Inline (NOT .swap-loading — that class is a centered block used elsewhere) so the
   "fetching more quotes" text sits on the SAME line as the count and its removal on
   completion doesn't shift the results below. */
.swap-stream-loading {
    color: var(--muted, #9a9aa1);
    font-weight: 400;
    white-space: nowrap;
}
.swap-stream-loading::after {
    content: "";
    display: inline-block;
    width: .6em;
    text-align: left;
    animation: swapDots 1.2s steps(4, end) infinite;
}
@keyframes swapDots {
    0% { content: ""; }
    25% { content: "."; }
    50% { content: ".."; }
    75% { content: "..."; }
}
@media (prefers-reduced-motion: reduce) {
    .swap-stream-loading::after { animation: none; content: "…"; }
}
.swap-stream-msg {
    padding: 1rem 0;
    color: var(--muted, #9a9aa1);
}
/* Newly streamed-in rows fade in so their arrival is visible. */
.swap-table tbody tr.swap-row { animation: swapRowIn .25s ease both; }
@keyframes swapRowIn { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
    .swap-table tbody tr.swap-row { animation: none; }
}

/* ===========================================================================
   2026-10 refresh — calmer, kycnot.me-style directory. Same colours; fewer chips,
   icon signals, a grotesk display face, flat hairline panels. No JS.
   =========================================================================== */

@font-face { font-family: "Space Grotesk"; src: url("../fonts/space-grotesk-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("../fonts/space-grotesk-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("../fonts/space-grotesk-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root { --display: "Space Grotesk", var(--sans); }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { background: var(--bg); }

h1, h2, h3, .brand-name, .panel-title, .card-title, .detail-title { font-family: var(--display); letter-spacing: .005em; }
.detail-title { font-weight: 600; }

.icon-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ico { width: 1em; height: 1em; flex: none; vertical-align: -.125em; }
.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; }

.page-eyebrow { font-family: var(--mono); font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--text-faint); }

/* ---- Directory heading (moved out of the sidebar) ---- */
.directory-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem 1rem; margin: 0 0 .5rem; }
.directory-title { font-size: 1.45rem; font-weight: 600; margin: 0; line-height: 1.2; white-space: nowrap; }
.directory-lead { color: var(--text-dim); margin: 0; flex: 1 1 320px; font-size: .9rem; }

/* ---- Filter sidebar: flat panel, accent section headings ---- */
.filter-panel {
    background: var(--bg-elev);
    border-color: var(--border);
    box-shadow: none;
}
.filter-panel .panel-title { color: var(--gold); font-size: 1.15rem; letter-spacing: .01em; text-transform: none; }
.facet { border-top: 1px solid var(--border); }
.facet > summary {
    font-family: var(--display);
    font-size: .98rem; font-weight: 500; letter-spacing: .01em; text-transform: none;
    color: var(--gold);
}
.facet > summary:hover { color: var(--gold-bright); }
.facet > summary .facet-state { font-family: var(--mono); font-size: .68rem; letter-spacing: .04em; text-transform: uppercase; color: var(--text-faint); }
.check { font-size: .9rem; color: var(--text); }

/* ---- Directory cards ---- */
.card-grid { gap: 1rem; }
.service-card {
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: none;
    padding: 1rem 1rem .8rem;
    gap: .75rem;
    transition: border-color .15s ease, background .15s ease;
}
.service-card:hover,
.service-card:focus-within { border-color: var(--border-strong); background: var(--bg-elev-2); box-shadow: none; transform: none; }
.service-card.is-sponsored { border-color: rgba(227, 179, 65, .55); }
.service-card.is-sponsored:hover { border-color: var(--gold); }

.card-top { grid-template-columns: 48px 1fr; gap: .8rem; }
.card-logo { width: 48px; height: 48px; border-radius: 10px; }
.card-title { font-size: 1.14rem; font-weight: 600; margin: 0 0 .15rem; display: flex; align-items: center; gap: .45rem; flex-wrap: wrap; }
.card-title a { color: var(--text); }
.sponsor-tag {
    font-family: var(--mono); font-size: .62rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
    color: var(--gold); border: 1px solid rgba(227, 179, 65, .45); border-radius: 4px; padding: .05rem .35rem;
}
.card-kind { display: flex; align-items: center; gap: .35rem; color: var(--text-dim); font-size: .85rem; }
.card-kind .ico { color: var(--text-faint); width: 15px; height: 15px; }
.card-flag { margin-left: .2rem; font-size: .95rem; line-height: 1; }

.card-desc {
    color: var(--text-dim); font-size: .88rem; line-height: 1.5; margin: 0;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
    min-height: calc(1.5em * 3);
}

.card-signals { display: flex; align-items: center; flex-wrap: wrap; gap: .45rem .5rem; }
.grade-box {
    display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 6px;
    font-family: var(--display); font-weight: 700; font-size: 1.05rem; line-height: 1; border: 1px solid transparent;
}
.kyc-pill {
    display: inline-flex; align-items: center; gap: .3rem; height: 30px; padding: 0 .55rem; border-radius: 6px;
    font-size: .8rem; font-weight: 600; border: 1px solid transparent;
}
.kyc-pill .ico { width: 15px; height: 15px; }
.kyc-good { color: #56d364; background: rgba(63, 185, 80, .12); border-color: rgba(63, 185, 80, .3); }
.kyc-warn { color: #e3b341; background: rgba(210, 153, 34, .12); border-color: rgba(210, 153, 34, .3); }
.kyc-bad { color: #ff7b72; background: rgba(229, 83, 75, .12); border-color: rgba(229, 83, 75, .32); }
.kyc-neutral { color: var(--text-dim); background: var(--bg-inset); border-color: var(--border); }

.sig-row { display: inline-flex; align-items: center; gap: .7rem; margin-left: auto; flex-wrap: wrap; }
.sig { display: inline-flex; align-items: center; gap: .22rem; font-family: var(--mono); font-size: .76rem; color: var(--text-dim); white-space: nowrap; }
.sig .ico { width: 14px; height: 14px; color: var(--text-faint); }
.sig-good, .sig-good .ico { color: var(--ok); }
.sig-bad, .sig-bad .ico { color: var(--bad); }
.sig-dim, .sig-dim .ico { color: var(--text-faint); opacity: .7; }
.sig-star, .sig-star .ico { color: var(--gold); }

.card-foot { border-top: 1px solid var(--border); padding-top: .65rem; margin-top: .1rem; }
.btn-visit {
    display: inline-flex; align-items: center; gap: .35rem;
    background: transparent; color: var(--gold); border: 1px solid rgba(227, 179, 65, .5);
}
.btn-visit:hover { background: var(--gold-dim); color: var(--gold-bright); border-color: var(--gold); text-decoration: none; }
.btn-visit .ico { width: 13px; height: 13px; }

/* ---- Service page: the AI summary is a quiet note, not a feature ---- */
.editorial-note.ai-overview { border-color: var(--border); border-left-color: var(--border-strong); background: var(--bg-elev); }
.editorial-note.ai-overview .editorial-note-label { color: var(--text-faint); }
.ai-badge { background: transparent; color: var(--text-faint); border: 1px solid var(--border-strong); }

@media (max-width: 640px) {
    .sig-row { margin-left: 0; width: 100%; }
}

/* ---- Service page: same grade box / KYC pill as the cards; toned glance values ---- */
.detail-kind { font-size: .9rem; }
.stat .v.chip-good { color: var(--ok); }
.stat .v.chip-warn { color: var(--warn); }
.stat .v.chip-bad { color: var(--bad); }
.stat .v.chip-neutral { color: var(--text-dim); }
.detail-aside .panel-title, aside .panel > .panel-title { font-size: 1.05rem; color: var(--gold); letter-spacing: .01em; text-transform: none; }
.directory-head + .results-bar { margin-top: 0; margin-bottom: .75rem; }

/* service page FAQ */
.service-faq .faq-q { font-size: 1rem; margin: 1rem 0 .3rem; }
.service-faq .faq-a { margin: 0 0 .6rem; color: var(--muted, #9aa4b2); line-height: 1.6; }

/* Service page: "X alternatives" list (internal links to comparable listings). */
.alt-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.alt-list li { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; padding: .5rem .7rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg-inset); }
.alt-list .alt-grade { min-width: 1.4rem; height: 1.4rem; font-size: .85rem; }
.alt-list .muted { font-size: .9rem; }

/* Review count on directory cards: visible text, not just a tooltip. Sits above the
   stretched card link (z-index) so it opens the reviews section directly. */
.card-reviews { position: relative; z-index: 2; display: inline-flex; align-items: center; gap: .3rem;
  font-size: .82rem; color: var(--text); white-space: nowrap; text-decoration: none; }
.card-reviews .ico { color: var(--gold); }
.card-reviews strong { color: var(--gold); font-weight: 700; }
.card-reviews-sep { color: var(--text-faint); }
.card-reviews:hover { text-decoration: underline; color: var(--text); }
.card-reviews.is-empty { color: var(--text-faint); font-size: .78rem; }
.card-reviews.is-empty:hover { color: var(--text-dim); }
