:root {
    --score-excellent: #28a745;
    --score-good:      #17a2b8;
    --score-caution:   #ffc107;
    --score-risky:     #fd7e14;
    --score-danger:    #dc3545;
}

/* Score ring */
#trustScoreChart { display: block; margin: 0 auto; }

/* ── Section scroll layout ────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }
.section-block { scroll-margin-top: 52px; }
.section-block + .section-block {
    border-top: 1px solid #dee2e6;
    padding-top: 1.5rem;
    margin-top: .25rem;
}
#sectionNav { scrollbar-width: none; -ms-overflow-style: none; }
#sectionNav::-webkit-scrollbar { display: none; }
#sectionNav .nav-link { white-space: nowrap; }

/* Scrollable nav on mobile */
@media (max-width: 768px) {
    #sectionNav .nav-link { padding: .4rem .7rem; font-size: .8rem; }
}

/* Card hover */
.card { transition: box-shadow .15s ease; }
.card:hover { box-shadow: 0 .5rem 1rem rgba(0,0,0,.1) !important; }

/* Skeleton loader */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 400% 100%;
    animation: skeleton-loading 1.2s ease infinite;
    border-radius: 4px; min-height: 1rem;
}
@keyframes skeleton-loading {
    0%   { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* Star rating */
.star-icon { cursor: pointer; font-size: 1.6rem; transition: color .1s; }
.star-icon:hover, .star-icon.selected { color: #ffc107 !important; }

/* Monospace for DNS/SSL values */
.font-monospace { font-family: SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: .85em; }

/* Subdomain list items */
.subdomain-item { font-size: .8rem; font-family: monospace; padding: .2rem 0; border-bottom: 1px solid #f0f0f0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Site screenshot thumbnail */
.site-screenshot { max-height: 80px; width: auto; border-radius: 6px; border: 1px solid #dee2e6; transition: transform .2s; }
.site-screenshot:hover { transform: scale(1.05); }

/* Trust score card */
.trust-score-card { text-align: center; padding: 1.5rem 1rem; }
.trust-ring-wrapper { position: relative; display: inline-block; }
.trust-ring-center {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-bottom: 18px; /* compensate for bottom gap of 270° arc */
    pointer-events: none;
}
.trust-score-number { font-size: 2.6rem; font-weight: 900; line-height: 1; }
.trust-score-sublabel { font-size: .7rem; color: #6c757d; margin-top: 1px; }
.trust-grade-pill { display: inline-block; padding: .35rem 1rem; border-radius: 999px; font-size: .8rem; font-weight: 600; color: #fff; margin-top: .5rem; }
.breakdown-label { font-size: .78rem; color: #495057; }
.breakdown-points { font-size: .78rem; font-weight: 600; }

/* Table cell vertical align */
.table-sm td, .table-sm th { padding: .3rem .5rem; vertical-align: middle; }

/* ── Domain Hero Header (Crunchbase-style) ──────────────────────────────── */

/* Stats scrollable bar — no wrapping, horizontal scroll on small screens */
.stat-bar-scroll {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    background: rgba(255,255,255,0.04);
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.09);
}
.stat-bar-scroll::-webkit-scrollbar { display: none; }

.stat-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-right: 1px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
    white-space: nowrap;
}
.stat-pill:last-child { border-right: none; }

.stat-pill-icon {
    width: 28px; height: 28px;
    border-radius: 7px;
    display: flex; align-items: center; justify-content: center;
    font-size: .8rem;
    flex-shrink: 0;
}
.stat-pill-val {
    font-size: .88rem;
    font-weight: 700;
    color: #f1f5f9;
    line-height: 1.2;
    white-space: nowrap;
}
.stat-pill-lbl {
    font-size: .68rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-top: 2px;
    white-space: nowrap;
}

/* Domain hero top text colors */
.hero-domain-name   { color: #f8fafc; }
.hero-site-title    { color: #cbd5e1; }
.hero-meta-desc     { color: #94a3b8; }
.hero-cache-text    { color: #94a3b8; }
.hero-refresh-link  { color: #38bdf8; text-decoration: none; }
.hero-refresh-link:hover { color: #7dd3fc; text-decoration: underline; }
.hero-fresh-text    { color: #4ade80; }

.domain-hero-screenshot-bar {
    background: rgba(255,255,255,0.06);
    padding: 5px 10px;
    font-size: .67rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}
.domain-hero-dot {
    width: 7px; height: 7px; border-radius: 50%; display: inline-block;
}


/* ── Footer ─────────────────────────────────────────────────────────────── */
.footer-main {
    background: linear-gradient(135deg, #1a1f2e 0%, #0f1420 100%);
    border-top: 3px solid #28a745;
}
.footer-logo-icon {
    width: 38px; height: 38px;
    background: linear-gradient(135deg, #28a745, #20c997);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 1.1rem;
}
.footer-desc { color: #9aa3b0; font-size: .88rem; line-height: 1.6; margin: 0; }
.footer-badge {
    display: inline-flex; align-items: center;
    background: rgba(255,255,255,.08);
    color: #c8d0db;
    font-size: .75rem; font-weight: 500;
    padding: .25rem .65rem; border-radius: 999px;
    border: 1px solid rgba(255,255,255,.1);
}
.footer-heading {
    color: #ffffff;
    font-size: .8rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: .08em;
    margin-bottom: .9rem;
}
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: .5rem; }
.footer-links a {
    color: #9aa3b0; font-size: .875rem; text-decoration: none;
    transition: color .15s;
}
.footer-links a:hover { color: #28a745; }
.footer-source-badge {
    background: rgba(255,255,255,.07);
    color: #c8d0db;
    font-size: .72rem; padding: .2rem .55rem;
    border-radius: 4px; border: 1px solid rgba(255,255,255,.1);
}
.footer-divider { border-color: rgba(255,255,255,.1); margin: 2rem 0 1.2rem; }
.footer-copy { color: #6c7585; font-size: .8rem; }

/* ── Print Styles ───────────────────────────────────────────────────────── */
@media print {
    /* Hide non-essential UI */
    .navbar,
    .footer-main,
    footer,
    #sectionNavWrap,
    #sectionNav,
    .social-share-bar,
    .vote-btn,
    #review-form,
    #reportModal,
    [data-bs-toggle="modal"],
    .btn-outline-danger,
    .ts-needle-g,
    button[onclick*="window.print"],
    .card:has(#main-search-form) {
        display: none !important;
    }

    /* Page setup */
    * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
    body { background: #fff !important; font-size: 11pt; color: #000; }

    /* Remove sticky positioning */
    .sticky-top, [style*="position:sticky"], [style*="position: sticky"] {
        position: static !important;
    }

    /* Full width layout — collapse grid */
    .col-lg-4, .col-lg-8, .col-lg-6, .col-md-4, .col-md-6 {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100% !important;
    }

    /* Trust score card: dark bg → white */
    [style*="background:#16233a"],
    [style*="background: #16233a"] {
        background: #f8f9fa !important;
        color: #000 !important;
        border: 1px solid #dee2e6 !important;
        box-shadow: none !important;
    }

    /* Domain hero card: dark bg → white */
    [style*="background:linear-gradient(135deg,#0f172a"],
    [style*="background: linear-gradient(135deg, #0f172a"] {
        background: #f8f9fa !important;
        color: #000 !important;
        border: 1px solid #dee2e6 !important;
    }

    /* Force all text in dark sections to be readable */
    [style*="color:#f1f5f9"], [style*="color: #f1f5f9"],
    [style*="color:#cbd5e1"], [style*="color: #cbd5e1"],
    [style*="color:#94a3b8"], [style*="color: #94a3b8"],
    [style*="color:#9ca3af"], [style*="color: #9ca3af"],
    .stat-pill-val, .stat-pill-lbl, .hero-domain-name,
    .hero-site-title, .hero-meta-desc, .hero-cache-text {
        color: #333 !important;
    }

    /* Cards: remove shadow */
    .card { box-shadow: none !important; border: 1px solid #dee2e6 !important; }

    /* Section blocks: no border-based scroll margin */
    .section-block { scroll-margin-top: 0 !important; page-break-inside: avoid; }
    .section-block + .section-block { border-top: 1px solid #dee2e6; padding-top: 1rem; }

    /* Progress bars: keep visible */
    .progress-bar { -webkit-print-color-adjust: exact !important; }

    /* Tables */
    .table-sm td, .table-sm th { padding: .2rem .4rem; font-size: 9pt; }

    /* SVG gauge: keep colors */
    svg path, svg line, svg circle { -webkit-print-color-adjust: exact !important; }

    /* Page break helpers */
    h6.fw-bold { page-break-after: avoid; }
    table { page-break-inside: avoid; }

    /* Score number: keep color */
    [style*="font-size:58px"] { font-size: 36pt !important; }

    /* Badges */
    .badge { border: 1px solid #ccc !important; }

    /* Accordion: expand all for print */
    .accordion-collapse { display: block !important; height: auto !important; }
    .accordion-button::after { display: none; }
    .accordion-button { font-weight: 600; background: #f8f9fa !important; color: #000 !important; }

    /* Share bar: hidden via class + inline approach */
    .card:first-of-type { /* noop fallback */ }
}

/* ── Static page (about/privacy/terms/contact) ──────────────────────────── */
.static-page-hero {
    background: linear-gradient(135deg, #1a1f2e 0%, #0d1117 100%);
    color: #fff; padding: 3rem 0 2.5rem;
    margin: -1.5rem -12px 2rem;
    border-radius: 0 0 16px 16px;
}
.static-page-hero h1 { font-size: 2rem; font-weight: 800; }
.static-page-hero p  { color: #9aa3b0; max-width: 560px; margin: .5rem auto 0; }
