/**
 * VerifyHuman Design System v2 — Authenticated Shell (Phase 1A/1B)
 *
 * Scope: ONLY applies inside `body.vh-auth-shell`. The marketing site,
 * hosted pages, widgets, and unauthenticated flows are deliberately
 * untouched. Existing selectors in custom.css are preserved.
 *
 * Goals:
 *   - Dark sidebar on the left, clean topbar.
 *   - Standardized cards / tables / badges / buttons / forms / alerts
 *     / page headers / chart containers / code blocks.
 *   - Mobile hamburger drawer, no horizontal overflow.
 *   - System fonts only — no Google Fonts.
 *   - No layout redesign of individual pages yet.
 */

/* ========================================
   DESIGN TOKENS (additive — do not clobber custom.css)
   ======================================== */
:root {
    --vh-system-font: -apple-system, BlinkMacSystemFont, "Segoe UI",
        Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif,
        "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
        "Noto Color Emoji";

    --vh-sidebar-width: 248px;
    --vh-sidebar-collapsed: 72px;
    --vh-topbar-height: 64px;

    --vh-sidebar-bg: #0f172a;
    --vh-sidebar-bg-2: #111c33;
    --vh-sidebar-border: rgba(255, 255, 255, 0.08);
    --vh-sidebar-text: #cbd5e1;
    --vh-sidebar-text-muted: #94a3b8;
    --vh-sidebar-text-active: #ffffff;
    --vh-sidebar-active-bg: rgba(0, 121, 242, 0.18);
    --vh-sidebar-hover-bg: rgba(255, 255, 255, 0.06);
    --vh-sidebar-section-label: #64748b;

    --vh-surface: #ffffff;
    --vh-surface-muted: #f8fafc;
    --vh-surface-canvas: #f5f7fb;
    --vh-border: #e5e7eb;
    --vh-border-soft: #eef0f4;
    --vh-text: #111827;
    --vh-text-muted: #6b7280;
}

/* ========================================
   SYSTEM-FONT BASELINE
   ======================================== */
body.vh-auth-shell,
body.vh-auth-shell .navbar,
body.vh-auth-shell .dropdown-menu,
body.vh-auth-shell .card,
body.vh-auth-shell .table,
body.vh-auth-shell .form-control,
body.vh-auth-shell .form-select,
body.vh-auth-shell .btn {
    font-family: var(--vh-system-font);
}

/* ========================================
   HIDE MARKETING CHROME ON AUTH PAGES
   ========================================
   Authenticated app shell hides:
   - Marketing footer (Quick Links / Support / copyright)
   - Sticky marketing CTA bar
   - Old marketing top-nav items (Home, Docs, product dropdowns, Results, Admin link)
     The sidebar is now primary nav. Keep only the brand, the sidebar hamburger,
     and the right-side user menu inside the top navbar.
   - Bootstrap mobile navbar-toggler (would open an empty collapse on auth pages
     since the left-nav items are hidden) — leaves only the new .vh-sidebar-toggle.
*/
body.vh-auth-shell footer.bg-light,
body.vh-auth-shell footer.bg-light.border-top {
    display: none !important;
}

body.vh-auth-shell .sticky-cta {
    display: none !important;
}

body.vh-auth-shell nav.navbar .navbar-nav.me-auto {
    display: none !important;
}

body.vh-auth-shell nav.navbar .navbar-toggler {
    display: none !important;
}

/* ========================================
   AUTHENTICATED LAYOUT — sidebar + content offset
   ======================================== */
body.vh-auth-shell {
    background-color: var(--vh-surface-canvas);
    overflow-x: hidden;
}

@media (min-width: 992px) {
    body.vh-auth-shell {
        padding-left: var(--vh-sidebar-width);
    }
}

/* ========================================
   SIDEBAR
   ======================================== */
.vh-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--vh-sidebar-width);
    background: linear-gradient(180deg, var(--vh-sidebar-bg) 0%, var(--vh-sidebar-bg-2) 100%);
    color: var(--vh-sidebar-text);
    z-index: 1040;
    display: flex;
    flex-direction: column;
    box-shadow: 1px 0 0 var(--vh-sidebar-border);
    transform: translateX(-100%);
    transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    overscroll-behavior: contain;
}

@media (min-width: 992px) {
    .vh-sidebar {
        transform: translateX(0);
    }
}

.vh-sidebar.is-open {
    transform: translateX(0);
}

.vh-sidebar__header {
    height: var(--vh-topbar-height);
    display: flex;
    align-items: center;
    padding: 0 1rem;
    border-bottom: 1px solid var(--vh-sidebar-border);
    flex-shrink: 0;
}

.vh-sidebar__brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--vh-sidebar-text-active);
    text-decoration: none;
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: -0.01em;
}

.vh-sidebar__brand:hover,
.vh-sidebar__brand:focus {
    color: var(--vh-sidebar-text-active);
    text-decoration: none;
}

.vh-sidebar__brand-mark {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, #0079f2 0%, #00a3ff 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 800;
    flex-shrink: 0;
}

.vh-sidebar__brand-logo {
    height: 26px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: 0.92;
    flex-shrink: 0;
}

.vh-sidebar__nav {
    list-style: none;
    margin: 0;
    padding: 0.75rem 0;
    flex: 1 1 auto;
}

.vh-sidebar__section {
    padding: 0.75rem 1.25rem 0.25rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--vh-sidebar-section-label);
}

.vh-sidebar__nav li {
    list-style: none;
}

.vh-sidebar__link {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.55rem 1.25rem;
    color: var(--vh-sidebar-text);
    text-decoration: none;
    font-size: 0.9rem;
    line-height: 1.3;
    border-left: 3px solid transparent;
    transition: background-color 0.12s ease, color 0.12s ease, border-color 0.12s ease;
}

.vh-sidebar__link:hover,
.vh-sidebar__link:focus {
    color: var(--vh-sidebar-text-active);
    background-color: var(--vh-sidebar-hover-bg);
    text-decoration: none;
}

.vh-sidebar__link.is-active {
    color: var(--vh-sidebar-text-active);
    background-color: var(--vh-sidebar-active-bg);
    border-left-color: #0079f2;
    font-weight: 600;
}

.vh-sidebar__link i {
    width: 18px;
    text-align: center;
    color: var(--vh-sidebar-text-muted);
    font-size: 0.95rem;
    flex-shrink: 0;
}

.vh-sidebar__link.is-active i,
.vh-sidebar__link:hover i {
    color: #ffffff;
}

.vh-sidebar__sublink {
    display: block;
    padding: 0.3rem 1.25rem 0.3rem 3.05rem;
    color: var(--vh-sidebar-text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    line-height: 1.3;
    transition: color 0.12s ease, background-color 0.12s ease;
}

.vh-sidebar__sublink:hover,
.vh-sidebar__sublink:focus {
    color: var(--vh-sidebar-text-active);
    background-color: var(--vh-sidebar-hover-bg);
    text-decoration: none;
}

.vh-sidebar__footer {
    padding: 0.75rem 1.25rem 1rem;
    border-top: 1px solid var(--vh-sidebar-border);
    font-size: 0.75rem;
    color: var(--vh-sidebar-text-muted);
    flex-shrink: 0;
}

/* Sidebar mobile backdrop */
.vh-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 1039;
}

.vh-sidebar-backdrop.is-visible {
    display: block;
}

@media (min-width: 992px) {
    .vh-sidebar-backdrop {
        display: none !important;
    }
}

/* ========================================
   TOPBAR (refinements only — existing .navbar preserved)
   ======================================== */
body.vh-auth-shell > nav.navbar {
    background-color: var(--vh-surface) !important;
    border-bottom: 1px solid var(--vh-border-soft) !important;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04) !important;
    min-height: var(--vh-topbar-height);
}

body.vh-auth-shell > nav.navbar .container {
    max-width: none;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

/* On desktop, hide the marketing-style brand image inside the topbar —
   the sidebar already shows the brand. Keeps the topbar clean. */
@media (min-width: 992px) {
    body.vh-auth-shell > nav.navbar .navbar-brand {
        display: none;
    }
}

/* Mobile hamburger button — visible only when sidebar is hidden */
.vh-sidebar-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--vh-border);
    background: var(--vh-surface);
    border-radius: 8px;
    color: var(--vh-text);
    cursor: pointer;
    margin-right: 0.5rem;
}

.vh-sidebar-toggle:hover,
.vh-sidebar-toggle:focus {
    background: var(--vh-surface-muted);
}

@media (min-width: 992px) {
    .vh-sidebar-toggle {
        display: none;
    }
}

/* ========================================
   PAGE HEADERS
   ======================================== */
body.vh-auth-shell .vh-page-header {
    margin: 0 0 1.25rem 0;
    padding: 0.25rem 0 1rem;
    border-bottom: 1px solid var(--vh-border-soft);
}

body.vh-auth-shell .vh-page-header h1,
body.vh-auth-shell .vh-page-header .vh-page-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--vh-text);
    margin: 0;
    letter-spacing: -0.01em;
}

body.vh-auth-shell .vh-page-header .vh-page-subtitle {
    color: var(--vh-text-muted);
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
}

/* ========================================
   CARDS
   ======================================== */
body.vh-auth-shell .card {
    background: var(--vh-surface);
    border: 1px solid var(--vh-border-soft);
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

body.vh-auth-shell .card-header {
    background: transparent;
    border-bottom: 1px solid var(--vh-border-soft);
    padding: 0.9rem 1.1rem;
    font-weight: 600;
    color: var(--vh-text);
}

body.vh-auth-shell .card-body {
    padding: 1.1rem;
}

body.vh-auth-shell .card-footer {
    background: var(--vh-surface-muted);
    border-top: 1px solid var(--vh-border-soft);
}

/* ========================================
   TABLES
   ======================================== */
body.vh-auth-shell .table {
    --bs-table-bg: transparent;
    color: var(--vh-text);
    margin-bottom: 0;
}

body.vh-auth-shell .table > :not(caption) > * > * {
    padding: 0.75rem 0.9rem;
    border-bottom-color: var(--vh-border-soft);
}

body.vh-auth-shell .table thead th {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--vh-text-muted);
    font-weight: 600;
    background: var(--vh-surface-muted);
    border-bottom: 1px solid var(--vh-border);
}

body.vh-auth-shell .table-hover > tbody > tr:hover > * {
    background-color: rgba(0, 121, 242, 0.035);
}

body.vh-auth-shell .table-responsive {
    border-radius: 10px;
    overflow-x: auto;
}

/* ========================================
   BADGES
   ======================================== */
body.vh-auth-shell .badge {
    font-weight: 600;
    font-size: 0.72rem;
    padding: 0.32em 0.6em;
    border-radius: 999px;
    letter-spacing: 0.01em;
}

body.vh-auth-shell .badge.bg-success { background-color: #d1fae5 !important; color: #065f46 !important; }
body.vh-auth-shell .badge.bg-danger  { background-color: #fee2e2 !important; color: #991b1b !important; }
body.vh-auth-shell .badge.bg-warning { background-color: #fef3c7 !important; color: #92400e !important; }
body.vh-auth-shell .badge.bg-info    { background-color: #dbeafe !important; color: #1e40af !important; }
body.vh-auth-shell .badge.bg-primary { background-color: #dbeafe !important; color: #1e40af !important; }
body.vh-auth-shell .badge.bg-secondary { background-color: #e5e7eb !important; color: #374151 !important; }
body.vh-auth-shell .badge.bg-light   { background-color: #f3f4f6 !important; color: #374151 !important; }
body.vh-auth-shell .badge.bg-dark    { background-color: #1f2937 !important; color: #f9fafb !important; }

/* ========================================
   BUTTONS (light refinements only — Bootstrap colors preserved)
   ======================================== */
body.vh-auth-shell .btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.45rem 0.95rem;
    transition: filter 0.12s ease, box-shadow 0.12s ease, transform 0.06s ease;
}

body.vh-auth-shell .btn-sm {
    padding: 0.28rem 0.65rem;
    border-radius: 6px;
    font-size: 0.82rem;
}

body.vh-auth-shell .btn-primary {
    background-color: #0079f2;
    border-color: #0079f2;
}

body.vh-auth-shell .btn-primary:hover {
    background-color: #0066cc;
    border-color: #0066cc;
}

body.vh-auth-shell .btn:focus-visible {
    box-shadow: 0 0 0 3px rgba(0, 121, 242, 0.25);
}

/* ========================================
   FORMS
   ======================================== */
body.vh-auth-shell .form-control,
body.vh-auth-shell .form-select {
    border-radius: 8px;
    border-color: var(--vh-border);
    padding: 0.5rem 0.75rem;
    font-size: 0.92rem;
    background-color: var(--vh-surface);
    color: var(--vh-text);
    transition: border-color 0.12s ease, box-shadow 0.12s ease;
}

body.vh-auth-shell .form-control:focus,
body.vh-auth-shell .form-select:focus {
    border-color: #0079f2;
    box-shadow: 0 0 0 3px rgba(0, 121, 242, 0.15);
}

body.vh-auth-shell .form-label {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--vh-text);
    margin-bottom: 0.35rem;
}

body.vh-auth-shell .form-text {
    color: var(--vh-text-muted);
    font-size: 0.78rem;
}

body.vh-auth-shell .input-group-text {
    background: var(--vh-surface-muted);
    border-color: var(--vh-border);
    color: var(--vh-text-muted);
    font-size: 0.88rem;
}

/* ========================================
   ALERTS
   ======================================== */
body.vh-auth-shell .alert {
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 0.85rem 1rem;
    font-size: 0.9rem;
}

body.vh-auth-shell .alert-success { background-color: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
body.vh-auth-shell .alert-danger  { background-color: #fef2f2; border-color: #fecaca; color: #991b1b; }
body.vh-auth-shell .alert-warning { background-color: #fffbeb; border-color: #fde68a; color: #92400e; }
body.vh-auth-shell .alert-info,
body.vh-auth-shell .alert-primary { background-color: #eff6ff; border-color: #bfdbfe; color: #1e40af; }

/* ========================================
   CHART CONTAINERS
   ======================================== */
body.vh-auth-shell .vh-chart,
body.vh-auth-shell .chart-container {
    background: var(--vh-surface);
    border: 1px solid var(--vh-border-soft);
    border-radius: 12px;
    padding: 1rem;
    position: relative;
    min-height: 240px;
}

/* ========================================
   CODE BLOCKS
   ======================================== */
body.vh-auth-shell code,
body.vh-auth-shell .vh-code {
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
        "Liberation Mono", monospace;
    font-size: 0.85em;
    background: #f1f5f9;
    color: #0f172a;
    padding: 0.12em 0.4em;
    border-radius: 5px;
    border: 1px solid #e2e8f0;
}

body.vh-auth-shell pre {
    background: #0f172a;
    color: #e2e8f0;
    border-radius: 10px;
    padding: 1rem 1.1rem;
    font-size: 0.85rem;
    overflow-x: auto;
    line-height: 1.55;
    border: 1px solid #1e293b;
}

body.vh-auth-shell pre code {
    background: transparent;
    color: inherit;
    border: 0;
    padding: 0;
    font-size: inherit;
}

/* ========================================
   MAIN CONTENT WRAPPER
   ======================================== */
body.vh-auth-shell main {
    min-height: calc(100vh - var(--vh-topbar-height));
}

body.vh-auth-shell main > .container,
body.vh-auth-shell main > .container-fluid {
    padding-top: 1.25rem;
    padding-bottom: 2rem;
}

/* Prevent any wide content from forcing horizontal scroll */
body.vh-auth-shell main img,
body.vh-auth-shell main video,
body.vh-auth-shell main iframe {
    max-width: 100%;
    height: auto;
}

/* ========================================
   ADMIN PARITY (admin_base uses its own sidebar — keep tokens consistent)
   ======================================== */
body.vh-admin-shell {
    font-family: var(--vh-system-font);
}

/* ========================================
   PHASE 2 — CUSTOMER-FACING POLISH LAYER
   ========================================
   Reusable components for the VerifyFlow + Developer Console pages.
   Scoped under body.vh-auth-shell so admin/marketing pages are untouched.
   Behavior, routes, and JS hooks must stay identical.
   ======================================== */

/* Page hero — gradient band, eyebrow + title + tagline + actions */
body.vh-auth-shell .vh-hero {
    position: relative;
    background:
        radial-gradient(120% 180% at 100% 0%, rgba(99, 102, 241, 0.18) 0%, rgba(99, 102, 241, 0) 55%),
        linear-gradient(135deg, #0f172a 0%, #1e293b 60%, #1f2c4a 100%);
    color: #f8fafc;
    border-radius: 16px;
    padding: 1.4rem 1.6rem;
    margin-bottom: 1.5rem;
    overflow: hidden;
}
body.vh-auth-shell .vh-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.12) 100%);
    pointer-events: none;
}
body.vh-auth-shell .vh-hero__body {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
}
body.vh-auth-shell .vh-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #93c5fd;
    margin-bottom: 0.5rem;
}
body.vh-auth-shell .vh-hero__eyebrow .vh-hero__dot {
    width: 6px; height: 6px; border-radius: 999px;
    background: #38bdf8;
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.18);
}
body.vh-auth-shell .vh-hero__title {
    font-size: 1.65rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.015em;
    margin: 0 0 0.4rem 0;
    color: #ffffff;
}
body.vh-auth-shell .vh-hero__lede {
    color: #cbd5e1;
    font-size: 0.98rem;
    margin: 0;
    max-width: 60ch;
}
body.vh-auth-shell .vh-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
body.vh-auth-shell .vh-hero__actions .btn {
    border-radius: 8px;
}
body.vh-auth-shell .vh-hero__actions .btn-light {
    background: #ffffff;
    border-color: #ffffff;
    color: #0f172a;
    font-weight: 600;
}
body.vh-auth-shell .vh-hero__actions .btn-light:hover {
    background: #e2e8f0;
    border-color: #e2e8f0;
    color: #0f172a;
}
body.vh-auth-shell .vh-hero__actions .btn-outline-light {
    color: #f8fafc;
    border-color: rgba(248, 250, 252, 0.45);
}
body.vh-auth-shell .vh-hero__actions .btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #f8fafc;
    color: #ffffff;
}
body.vh-auth-shell .vh-hero--compact {
    padding: 1.1rem 1.3rem;
    margin-bottom: 1.1rem;
}

/* Stat grid — clean KPI cards */
body.vh-auth-shell .vh-stat {
    background: var(--vh-surface);
    border: 1px solid var(--vh-border-soft);
    border-radius: 14px;
    padding: 1.1rem 1.15rem;
    height: 100%;
    transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    position: relative;
}
body.vh-auth-shell a.vh-stat,
body.vh-auth-shell .vh-stat[role="button"] {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}
body.vh-auth-shell a.vh-stat:hover,
body.vh-auth-shell .vh-stat[role="button"]:hover {
    border-color: #bfdbfe;
    box-shadow: 0 6px 18px -10px rgba(15, 23, 42, 0.18);
    transform: translateY(-1px);
}
body.vh-auth-shell .vh-stat__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}
body.vh-auth-shell .vh-stat__label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--vh-text-muted);
}
body.vh-auth-shell .vh-stat__icon {
    width: 36px; height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    background: #eff6ff;
    color: #1d4ed8;
    flex-shrink: 0;
}
body.vh-auth-shell .vh-stat__icon--success { background: #ecfdf5; color: #047857; }
body.vh-auth-shell .vh-stat__icon--danger  { background: #fef2f2; color: #b91c1c; }
body.vh-auth-shell .vh-stat__icon--warning { background: #fffbeb; color: #b45309; }
body.vh-auth-shell .vh-stat__icon--info    { background: #ecfeff; color: #0e7490; }
body.vh-auth-shell .vh-stat__icon--violet  { background: #f5f3ff; color: #6d28d9; }
body.vh-auth-shell .vh-stat__icon--slate   { background: #f1f5f9; color: #334155; }
body.vh-auth-shell .vh-stat__value {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.015em;
    color: var(--vh-text);
    margin-top: 0.15rem;
}
body.vh-auth-shell .vh-stat__value--success { color: #047857; }
body.vh-auth-shell .vh-stat__value--danger  { color: #b91c1c; }
body.vh-auth-shell .vh-stat__value--warning { color: #b45309; }
body.vh-auth-shell .vh-stat__value--info    { color: #0e7490; }
body.vh-auth-shell .vh-stat__foot {
    font-size: 0.8rem;
    color: var(--vh-text-muted);
    margin-top: 0.15rem;
}
body.vh-auth-shell .vh-stat__link {
    font-size: 0.8rem;
    color: #1d4ed8;
    text-decoration: none;
    font-weight: 500;
}
body.vh-auth-shell .vh-stat__link:hover { text-decoration: underline; }

/* Section header inside cards */
body.vh-auth-shell .vh-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border-bottom: 1px solid var(--vh-border-soft);
}
body.vh-auth-shell .vh-section-head__title {
    font-size: 0.98rem;
    font-weight: 600;
    margin: 0;
    color: var(--vh-text);
}
body.vh-auth-shell .vh-section-head__sub {
    font-size: 0.8rem;
    color: var(--vh-text-muted);
    font-weight: 400;
    margin-left: 0.4rem;
}

/* Filter toolbar */
body.vh-auth-shell .vh-toolbar {
    background: var(--vh-surface);
    border: 1px solid var(--vh-border-soft);
    border-radius: 12px;
    padding: 0.75rem 0.9rem;
    margin-bottom: 1rem;
}
body.vh-auth-shell .vh-toolbar__label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--vh-text-muted);
    margin-right: 0.5rem;
    align-self: center;
}
body.vh-auth-shell .vh-toolbar .btn-outline-secondary {
    border-color: var(--vh-border);
    color: var(--vh-text);
    background: var(--vh-surface);
}
body.vh-auth-shell .vh-toolbar .btn-outline-secondary:hover {
    background: var(--vh-surface-muted);
    border-color: #cbd5e1;
    color: var(--vh-text);
}

/* Empty state */
body.vh-auth-shell .vh-empty {
    text-align: center;
    padding: 3rem 1.5rem;
}
body.vh-auth-shell .vh-empty__icon {
    width: 56px; height: 56px;
    border-radius: 14px;
    background: #eff6ff;
    color: #1d4ed8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 1rem;
}
body.vh-auth-shell .vh-empty__title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--vh-text);
    margin: 0 0 0.35rem 0;
}
body.vh-auth-shell .vh-empty__text {
    color: var(--vh-text-muted);
    font-size: 0.9rem;
    margin: 0 auto 1.1rem;
    max-width: 50ch;
}

/* Template card */
body.vh-auth-shell .vh-tpl-card {
    border: 1px solid var(--vh-border-soft);
    border-radius: 14px;
    background: var(--vh-surface);
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
}
body.vh-auth-shell .vh-tpl-card:hover {
    border-color: #bfdbfe;
    box-shadow: 0 10px 24px -16px rgba(15, 23, 42, 0.18);
    transform: translateY(-2px);
}
body.vh-auth-shell .vh-tpl-card__body {
    padding: 1.15rem;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}
body.vh-auth-shell .vh-tpl-card__title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--vh-text);
    margin: 0;
}
body.vh-auth-shell .vh-tpl-card__desc {
    color: var(--vh-text-muted);
    font-size: 0.86rem;
    margin: 0.4rem 0 0.8rem;
    flex: 1 1 auto;
}
body.vh-auth-shell .vh-tpl-card__meta {
    font-size: 0.78rem;
    color: var(--vh-text-muted);
    margin-bottom: 0.75rem;
}
body.vh-auth-shell .vh-tpl-card__tags .badge {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border: 1px solid #e2e8f0;
    margin-right: 0.25rem;
    margin-bottom: 0.25rem;
}

/* Plan card (billing) */
body.vh-auth-shell .vh-plan-card {
    border: 1px solid var(--vh-border-soft);
    border-radius: 16px;
    background: var(--vh-surface);
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
}
body.vh-auth-shell .vh-plan-card:hover {
    border-color: #bfdbfe;
    box-shadow: 0 14px 28px -18px rgba(15, 23, 42, 0.22);
    transform: translateY(-2px);
}
body.vh-auth-shell .vh-plan-card.is-recommended {
    border-color: #16a34a;
    box-shadow: 0 0 0 1px #16a34a;
}
body.vh-auth-shell .vh-plan-card__ribbon {
    position: absolute;
    top: 14px; right: -36px;
    transform: rotate(35deg);
    background: #16a34a;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.25rem 2.5rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* API key card row */
body.vh-auth-shell .vh-key-callout {
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border: 1px solid #fed7aa;
    color: #7c2d12;
    border-radius: 12px;
    padding: 1rem 1.1rem;
}
body.vh-auth-shell .vh-key-callout .vh-key-callout__title {
    font-weight: 700;
    color: #7c2d12;
    margin: 0 0 0.4rem 0;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
body.vh-auth-shell .vh-key-callout ul {
    margin: 0;
    padding-left: 1.2rem;
    font-size: 0.86rem;
    color: #7c2d12;
}

/* Status pill with leading dot */
body.vh-auth-shell .vh-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.3em 0.7em;
    border-radius: 999px;
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #e2e8f0;
}
body.vh-auth-shell .vh-status-pill::before {
    content: "";
    width: 6px; height: 6px;
    border-radius: 999px;
    background: currentColor;
    opacity: 0.85;
}
body.vh-auth-shell .vh-status-pill--pass    { background: #ecfdf5; color: #047857; border-color: #a7f3d0; }
body.vh-auth-shell .vh-status-pill--fail    { background: #fef2f2; color: #b91c1c; border-color: #fecaca; }
body.vh-auth-shell .vh-status-pill--warn    { background: #fffbeb; color: #b45309; border-color: #fde68a; }
body.vh-auth-shell .vh-status-pill--info    { background: #eff6ff; color: #1d4ed8; border-color: #bfdbfe; }

/* Product tag (replaces colorful badges with subtle, consistent style) */
body.vh-auth-shell .vh-product-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.74rem;
    font-weight: 600;
    padding: 0.3em 0.65em;
    border-radius: 8px;
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #e2e8f0;
}
body.vh-auth-shell .vh-product-tag i { font-size: 0.78em; opacity: 0.85; }
body.vh-auth-shell .vh-product-tag--human    { background: #eef2ff; color: #4338ca; border-color: #c7d2fe; }
body.vh-auth-shell .vh-product-tag--age      { background: #fffbeb; color: #a16207; border-color: #fde68a; }
body.vh-auth-shell .vh-product-tag--identity { background: #ecfdf5; color: #047857; border-color: #a7f3d0; }
body.vh-auth-shell .vh-product-tag--kyc      { background: #ecfdf5; color: #047857; border-color: #a7f3d0; }
body.vh-auth-shell .vh-product-tag--trust    { background: #ecfeff; color: #0e7490; border-color: #a5f3fc; }

/* Table polish — verifications */
body.vh-auth-shell .vh-data-table tbody tr td code {
    background: #f1f5f9;
    color: #1e293b;
    border: 1px solid #e2e8f0;
    padding: 0.18em 0.45em;
    border-radius: 5px;
    font-size: 0.78em;
}

/* ========================================
   PHASE 2.1 — DASHBOARD REFINEMENT LAYER
   ======================================== */

/* Equal-height KPI tiles — relies on existing .vh-stat { height: 100% } + Bootstrap row;
   no bare .vh-stat override here, to avoid leaking into Billing / Results / Business panel. */

/* Compact chart card */
body.vh-auth-shell .vh-chart-card { border: 1px solid var(--vh-border-soft); border-radius: 14px; background: var(--vh-surface); }
body.vh-auth-shell .vh-chart-card__head { display: flex; align-items: center; justify-content: space-between; padding: 0.9rem 1.1rem; border-bottom: 1px solid var(--vh-border-soft); }
body.vh-auth-shell .vh-chart-card__title { margin: 0; font-size: 0.95rem; font-weight: 600; color: var(--vh-text); }
body.vh-auth-shell .vh-chart-card__title .vh-chart-card__sub { color: var(--vh-text-muted); font-weight: 400; font-size: 0.82rem; margin-left: 0.4rem; }
body.vh-auth-shell .vh-chart-card__body { padding: 0.9rem 1.1rem; }
body.vh-auth-shell .vh-chart-canvas { max-height: 220px !important; height: 220px !important; }

/* Inline confidence bar */
body.vh-auth-shell .vh-confidence { display: inline-flex; align-items: center; gap: 0.5rem; min-width: 120px; }
body.vh-auth-shell .vh-confidence__track { flex: 1; height: 6px; border-radius: 999px; background: #e2e8f0; overflow: hidden; min-width: 60px; }
body.vh-auth-shell .vh-confidence__fill { height: 100%; border-radius: 999px; background: #16a34a; transition: width 0.3s ease; }
body.vh-auth-shell .vh-confidence__fill--mid { background: #f59e0b; }
body.vh-auth-shell .vh-confidence__fill--low { background: #ef4444; }
body.vh-auth-shell .vh-confidence__value { font-weight: 600; font-size: 0.82rem; color: var(--vh-text); min-width: 40px; text-align: right; }

/* Recent table — left status border accent */
body.vh-auth-shell .vh-recent-row td { border-top-color: var(--vh-border-soft); }
body.vh-auth-shell .vh-recent-row td:first-child { border-left: 3px solid transparent; }
body.vh-auth-shell .vh-recent-row--pass td:first-child { border-left-color: #16a34a; }
body.vh-auth-shell .vh-recent-row--fail td:first-child { border-left-color: #f59e0b; }
body.vh-auth-shell .vh-recent-row--error td:first-child { border-left-color: #ef4444; }
body.vh-auth-shell .vh-recent-row--pending td:first-child { border-left-color: #cbd5e1; }

/* Action card with recommended eyebrow */
body.vh-auth-shell .vh-action-card { border: 1px solid var(--vh-border-soft); border-radius: 14px; background: var(--vh-surface); padding: 1.1rem; }
body.vh-auth-shell .vh-action-card__eyebrow { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: #1d4ed8; margin-bottom: 0.7rem; }
body.vh-auth-shell .vh-action-card__eyebrow::before { content: ""; width: 6px; height: 6px; border-radius: 999px; background: #1d4ed8; }
body.vh-auth-shell .vh-action-card .btn { border-radius: 8px; text-align: left; padding-left: 0.95rem; padding-right: 0.95rem; }

/* Attention / status card */
body.vh-auth-shell .vh-attn { border: 1px solid var(--vh-border-soft); border-radius: 14px; background: var(--vh-surface); padding: 0.9rem 1.1rem; display: flex; align-items: center; gap: 0.85rem; }
body.vh-auth-shell .vh-attn--ok { border-left: 4px solid #16a34a; }
body.vh-auth-shell .vh-attn--warn { border-left: 4px solid #f59e0b; background: #fffbeb; }
body.vh-auth-shell .vh-attn__icon { width: 36px; height: 36px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
body.vh-auth-shell .vh-attn--ok .vh-attn__icon { background: #ecfdf5; color: #047857; }
body.vh-auth-shell .vh-attn--warn .vh-attn__icon { background: #fef3c7; color: #b45309; }
body.vh-auth-shell .vh-attn__body { flex: 1; min-width: 0; }
body.vh-auth-shell .vh-attn__title { margin: 0; font-weight: 600; font-size: 0.92rem; color: var(--vh-text); }
body.vh-auth-shell .vh-attn__text { margin: 0; font-size: 0.82rem; color: var(--vh-text-muted); }

/* Override Bootstrap card metric-card so old breakdown text is compact */
body.vh-auth-shell .vh-stat__breakdown { display: flex; flex-wrap: wrap; gap: 0.4rem 0.7rem; margin-top: 0.4rem; font-size: 0.74rem; color: var(--vh-text-muted); }
body.vh-auth-shell .vh-stat__breakdown span { white-space: nowrap; display: inline-flex; align-items: center; gap: 0.25rem; }
body.vh-auth-shell .vh-stat__breakdown i { font-size: 0.8em; opacity: 0.85; }

/* KPI hierarchy — large/small variants for VerifyFlow */
body.vh-auth-shell .vh-stat--lg .vh-stat__value { font-size: 2.1rem; }
body.vh-auth-shell .vh-stat--sm { min-height: 110px; padding: 0.85rem 0.95rem; }
body.vh-auth-shell .vh-stat--sm .vh-stat__value { font-size: 1.5rem; }
body.vh-auth-shell .vh-stat--sm .vh-stat__icon { width: 30px; height: 30px; font-size: 0.85rem; }

/* ========================================
   PHASE 2.2 — PREMIUM ANALYTICS LAYER
   ======================================== */

/* Chart-card summary strip (compact mini-stats row above the canvas) */
body.vh-auth-shell .vh-chart-summary { display: flex; flex-wrap: wrap; gap: 0.5rem; padding: 0.6rem 1.1rem; border-bottom: 1px solid var(--vh-border-soft); background: linear-gradient(180deg, #fafbfc, var(--vh-surface)); }
body.vh-auth-shell .vh-chart-summary__item { flex: 1 1 0; min-width: 110px; padding: 0.35rem 0.5rem; border-radius: 8px; }
body.vh-auth-shell .vh-chart-summary__label { display: block; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--vh-text-muted); margin-bottom: 0.15rem; }
body.vh-auth-shell .vh-chart-summary__value { display: block; font-size: 1.15rem; font-weight: 700; color: var(--vh-text); line-height: 1.1; }
body.vh-auth-shell .vh-chart-summary__value--success { color: #047857; }
body.vh-auth-shell .vh-chart-summary__value--warn { color: #b45309; }
body.vh-auth-shell .vh-chart-summary__value--muted { color: var(--vh-text-muted); font-size: 1rem; font-weight: 600; }
body.vh-auth-shell .vh-chart-summary__hint { display: block; font-size: 0.68rem; color: var(--vh-text-muted); margin-top: 0.1rem; }

/* Flow summary strip — used in VerifyFlow dashboard chart card */
body.vh-auth-shell .vh-flow-strip { display: flex; flex-wrap: wrap; gap: 0.5rem; padding: 0.6rem 1.1rem; border-bottom: 1px solid var(--vh-border-soft); background: linear-gradient(180deg, #fafbfc, var(--vh-surface)); }
body.vh-auth-shell .vh-flow-strip__item { flex: 1 1 0; min-width: 140px; padding: 0.35rem 0.6rem; border-radius: 8px; border-left: 3px solid #cbd5e1; }
body.vh-auth-shell .vh-flow-strip__item--pass { border-left-color: #16a34a; }
body.vh-auth-shell .vh-flow-strip__item--warn { border-left-color: #f59e0b; }
body.vh-auth-shell .vh-flow-strip__item--top { border-left-color: #2563eb; }
body.vh-auth-shell .vh-flow-strip__label { display: block; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--vh-text-muted); margin-bottom: 0.15rem; }
body.vh-auth-shell .vh-flow-strip__value { display: block; font-size: 0.92rem; font-weight: 600; color: var(--vh-text); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
body.vh-auth-shell .vh-flow-strip__hint { display: block; font-size: 0.7rem; color: var(--vh-text-muted); margin-top: 0.1rem; }

/* Chart canvas: keep ~240px so it doesn't overflow on mobile */
body.vh-auth-shell .vh-chart-card .vh-chart-card__body { position: relative; min-height: 240px; }
body.vh-auth-shell .vh-chart-canvas { max-height: 240px !important; height: 240px !important; width: 100% !important; }

@media (max-width: 575.98px) {
  body.vh-auth-shell .vh-chart-summary__item,
  body.vh-auth-shell .vh-flow-strip__item { flex: 1 1 45%; }
}

/* ========================================
   PHASE 2.3 — PREMIUM ANALYTICS MODULES
   ======================================== */

/* Premium analytics module — two-column body for mix + activity */
body.vh-auth-shell .vh-module { background: var(--vh-surface); border: 1px solid var(--vh-border-soft); border-radius: 14px; box-shadow: 0 1px 2px rgba(15,23,42,0.04); overflow: hidden; margin-bottom: 1.25rem; }
body.vh-auth-shell .vh-module__split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 0; }
body.vh-auth-shell .vh-module__col { padding: 1rem 1.1rem 1.1rem; }
body.vh-auth-shell .vh-module__col + .vh-module__col { border-left: 1px solid var(--vh-border-soft); }
body.vh-auth-shell .vh-module__sub-title { font-size: 0.74rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--vh-text-muted); margin: 0 0 0.75rem; }

@media (max-width: 767.98px) {
  body.vh-auth-shell .vh-module__split { grid-template-columns: 1fr; }
  body.vh-auth-shell .vh-module__col + .vh-module__col { border-left: 0; border-top: 1px solid var(--vh-border-soft); }
}

/* Product mix horizontal bars */
body.vh-auth-shell .vh-mix-list { display: flex; flex-direction: column; gap: 0.55rem; }
body.vh-auth-shell .vh-mix-row { display: grid; grid-template-columns: 1fr auto; row-gap: 0.2rem; column-gap: 0.6rem; align-items: center; }
body.vh-auth-shell .vh-mix-row__label { font-size: 0.82rem; font-weight: 600; color: var(--vh-text); display: flex; align-items: center; gap: 0.4rem; }
body.vh-auth-shell .vh-mix-row__dot { width: 9px; height: 9px; border-radius: 2px; display: inline-block; flex: none; }
body.vh-auth-shell .vh-mix-row__count { font-size: 0.78rem; color: var(--vh-text-muted); font-variant-numeric: tabular-nums; }
body.vh-auth-shell .vh-mix-row__track { grid-column: 1 / -1; height: 6px; background: #f1f5f9; border-radius: 999px; overflow: hidden; }
body.vh-auth-shell .vh-mix-row__fill { height: 100%; border-radius: 999px; transition: width 250ms ease; min-width: 2px; }
body.vh-auth-shell .vh-mix-empty { padding: 1.25rem 0.5rem; text-align: center; color: var(--vh-text-muted); font-size: 0.85rem; }

/* Top flows list (VerifyFlow dashboard) */
body.vh-auth-shell .vh-top-flows { display: flex; flex-direction: column; gap: 0.45rem; }
body.vh-auth-shell .vh-top-flow { display: flex; align-items: center; gap: 0.65rem; padding: 0.6rem 0.7rem; border: 1px solid var(--vh-border-soft); border-radius: 10px; background: #fff; transition: border-color 150ms ease, transform 150ms ease; text-decoration: none; color: inherit; }
body.vh-auth-shell .vh-top-flow:hover { border-color: #94a3b8; transform: translateY(-1px); }
body.vh-auth-shell .vh-top-flow__rank { width: 24px; height: 24px; flex: none; border-radius: 999px; background: #eef2ff; color: #4338ca; font-size: 0.72rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
body.vh-auth-shell .vh-top-flow__body { min-width: 0; flex: 1 1 auto; }
body.vh-auth-shell .vh-top-flow__name { display: block; font-size: 0.88rem; font-weight: 600; color: var(--vh-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
body.vh-auth-shell .vh-top-flow__meta { display: block; font-size: 0.72rem; color: var(--vh-text-muted); margin-top: 0.1rem; }
body.vh-auth-shell .vh-top-flow__count { font-size: 0.78rem; font-weight: 600; color: var(--vh-text-muted); font-variant-numeric: tabular-nums; flex: none; }
body.vh-auth-shell .vh-top-flows-empty { padding: 1.25rem 0.5rem; text-align: center; color: var(--vh-text-muted); font-size: 0.85rem; }

/* Topbar right-cluster — explicit grouping for help / notif / user / credits / env toggle */
body.vh-auth-shell .vh-topbar-right { display: flex; align-items: center; gap: 0.5rem; margin-left: auto; }

/* ========================================
   PHASE 2.3.1 — POLISH (chart-left, mix-right; vertical flow highlights)
   ======================================== */

/* Chart gets the larger column on the left, side panel on the right */
body.vh-auth-shell .vh-module__split { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
@media (max-width: 767.98px) {
  body.vh-auth-shell .vh-module__split { grid-template-columns: 1fr; }
}

/* Vertical Flow Highlights panel (replaces horizontal flow_strip when nested in split) */
body.vh-auth-shell .vh-flow-highlights { display: flex; flex-direction: column; gap: 0.55rem; margin-bottom: 0.9rem; }
body.vh-auth-shell .vh-flow-highlight { display: flex; flex-direction: column; padding: 0.55rem 0.7rem; border-radius: 10px; background: #f8fafc; border: 1px solid var(--vh-border-soft); }
body.vh-auth-shell .vh-flow-highlight--top { background: #eef2ff; border-color: #c7d2fe; }
body.vh-auth-shell .vh-flow-highlight--pass { background: #ecfdf5; border-color: #a7f3d0; }
body.vh-auth-shell .vh-flow-highlight--warn { background: #fffbeb; border-color: #fde68a; }
body.vh-auth-shell .vh-flow-highlight__label { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--vh-text-muted); }
body.vh-auth-shell .vh-flow-highlight__value { font-size: 0.92rem; font-weight: 600; color: var(--vh-text); margin-top: 0.1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
body.vh-auth-shell .vh-flow-highlight__hint { font-size: 0.72rem; color: var(--vh-text-muted); margin-top: 0.1rem; }

/* Subtle divider between Flow Highlights and Top Flows */
body.vh-auth-shell .vh-section-divider { height: 1px; background: linear-gradient(to right, transparent, var(--vh-border-soft) 20%, var(--vh-border-soft) 80%, transparent); margin: 0.4rem 0 0.85rem; border: 0; }

/* Hero CTA tertiary — subtle link-style on dark hero */
body.vh-auth-shell .vh-hero__cta-tertiary { background: transparent !important; border: 1px solid rgba(255,255,255,0.28) !important; color: rgba(255,255,255,0.78) !important; font-weight: 400 !important; }
body.vh-auth-shell .vh-hero__cta-tertiary:hover { background: rgba(255,255,255,0.08) !important; color: #fff !important; border-color: rgba(255,255,255,0.45) !important; }

/* ---------------------------------------------------------------------------
   Phase 2.4 — Verifications / API Keys / Billing polish tokens
   --------------------------------------------------------------------------- */

/* Hero count chip (next to page title) */
body.vh-auth-shell .vh-hero__count-chip {
  display: inline-flex;
  align-items: center;
  margin-left: 0.6rem;
  padding: 0.18rem 0.65rem;
  font-size: 0.62em;
  font-weight: 600;
  line-height: 1.2;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  letter-spacing: 0.01em;
  vertical-align: middle;
}
body.vh-auth-shell .vh-hero__count-chip--plan {
  font-size: 0.78rem;
  padding: 0.35rem 0.85rem;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

/* Toolbar — filters variant */
body.vh-auth-shell .vh-toolbar--filters {
  padding: 1rem 1.1rem;
  background: #fff;
  border: 1px solid var(--vh-border-soft, #e5e7eb);
  border-radius: 12px;
}
body.vh-auth-shell .vh-toolbar__clear {
  display: inline-flex;
  align-items: center;
  font-size: 0.82rem;
  color: var(--vh-text-muted, #64748b);
  text-decoration: none;
}
body.vh-auth-shell .vh-toolbar__clear:hover { color: #b91c1c; text-decoration: underline; }

/* Soft card variant (used by tables) */
body.vh-auth-shell .vh-card-soft {
  background: #fff;
  border: 1px solid var(--vh-border-soft, #e5e7eb) !important;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 1px 0 rgba(15, 23, 42, 0.02) inset;
}
body.vh-auth-shell .vh-card-soft > .card-header {
  border-bottom: 1px solid var(--vh-border-soft, #e5e7eb);
  padding: 0.85rem 1.15rem;
  border-radius: 12px 12px 0 0;
}
body.vh-auth-shell .vh-row-counter {
  font-size: 0.78rem;
  color: var(--vh-text-muted, #64748b);
}
body.vh-auth-shell .vh-row-counter strong { color: #0f172a; font-weight: 600; }

/* Clean table */
body.vh-auth-shell .vh-table-clean thead th {
  background: #f8fafc;
  color: #475569;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-bottom: 1px solid #e5e7eb;
  border-top: 0;
  padding: 0.7rem 0.85rem;
}
body.vh-auth-shell .vh-table-clean tbody td {
  font-size: 0.86rem;
  padding: 0.8rem 0.85rem;
  border-bottom: 1px solid #f1f5f9;
  color: #1e293b;
}
body.vh-auth-shell .vh-table-clean tbody tr:last-child td { border-bottom: 0; }
body.vh-auth-shell .vh-table-clean tbody tr:hover td { background: #f9fafb; }

/* Verification ID chip */
body.vh-auth-shell .vh-id-chip {
  display: inline-block;
  padding: 0.18rem 0.5rem;
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.78rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Product pills (per-product accent) */
body.vh-auth-shell .vh-product-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.22rem 0.6rem;
  font-size: 0.74rem;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid transparent;
  line-height: 1.2;
}
body.vh-auth-shell .vh-product-pill i { font-size: 0.78em; opacity: 0.92; }
body.vh-auth-shell .vh-product-pill--vh      { background: #eff6ff; color: #1d4ed8; border-color: #bfdbfe; }
body.vh-auth-shell .vh-product-pill--va      { background: #fffbeb; color: #b45309; border-color: #fde68a; }
body.vh-auth-shell .vh-product-pill--vi      { background: #ecfdf5; color: #047857; border-color: #a7f3d0; }
body.vh-auth-shell .vh-product-pill--vt      { background: #ecfeff; color: #0e7490; border-color: #a5f3fc; }
body.vh-auth-shell .vh-product-pill--neutral { background: #f1f5f9; color: #334155; border-color: #e2e8f0; }

/* Confidence display (bar + value) — renamed to vh-confmeter to avoid
   colliding with the legacy .vh-confidence (track/fill) used on the
   developer dashboard's recent-verifications widget. */
body.vh-auth-shell .vh-confmeter {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 130px;
}
body.vh-auth-shell .vh-confmeter__bar {
  flex: 1;
  height: 6px;
  background: #e5e7eb;
  border-radius: 3px;
  overflow: hidden;
  min-width: 60px;
}
body.vh-auth-shell .vh-confmeter__bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #10b981, #059669);
  border-radius: 3px;
}
body.vh-auth-shell .vh-confmeter__value {
  font-weight: 600;
  font-size: 0.82rem;
  color: #0f172a;
  font-variant-numeric: tabular-nums;
  min-width: 44px;
  text-align: right;
}

/* API Keys — scope pill, masked-key display, domain pill */
body.vh-auth-shell .vh-scope-pill {
  display: inline-block;
  margin: 0 0.25rem 0.25rem 0;
  padding: 0.18rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: #334155;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
body.vh-auth-shell .vh-domain-pill {
  display: inline-block;
  margin: 0 0.25rem 0.25rem 0;
  padding: 0.18rem 0.55rem;
  font-size: 0.72rem;
  font-weight: 500;
  color: #0e7490;
  background: #ecfeff;
  border: 1px solid #a5f3fc;
  border-radius: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
body.vh-auth-shell .vh-key-display {
  display: inline-flex;
  align-items: center;
  gap: 0;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  overflow: hidden;
  /* flex + min-width:0 allows the value to truncate rather than stretch */
  min-width: 0;
  max-width: 100%;
}
body.vh-auth-shell .vh-key-display__badge {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  padding: 0.28rem 0.55rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #1d4ed8;
  background: #eff6ff;
  border-right: 1px solid #e2e8f0;
  white-space: nowrap;
}
body.vh-auth-shell .vh-key-display__value {
  padding: 0.28rem 0.6rem;
  font-size: 0.78rem;
  color: #0f172a;
  background: transparent;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  /* Prevent character-per-line wrap on compressed widths */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

/* Mobile card view — each API key rendered as a stacked card */
body.vh-auth-shell .vh-key-card {
  padding: 1rem 1.1rem;
  border-bottom: 1px solid #f1f5f9;
  background: #fff;
}
body.vh-auth-shell .vh-key-card:last-child { border-bottom: 0; }
body.vh-auth-shell .vh-key-card__label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 0.25rem;
}
/* Within a card the key-display stretches full width */
body.vh-auth-shell .vh-key-card .vh-key-display {
  width: 100%;
}
body.vh-auth-shell .vh-key-card .vh-key-display__value {
  flex: 1;
  min-width: 0;
}

/* Security callout — enhanced variant */
body.vh-auth-shell .vh-key-callout--enhanced {
  background: linear-gradient(135deg, #f0f9ff 0%, #f8fafc 100%);
  border-left-width: 4px;
}

/* Billing — featured plan card (Most Popular ribbon). Class renamed to
   vh-plan-ribbon to avoid collision with the legacy diagonal-corner
   .vh-plan-card__ribbon defined earlier in this file (see ~line 920),
   which is used by a different plan-card system. */
body.vh-auth-shell .vh-plan-card--featured {
  border-color: #10b981 !important;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.14), 0 0 0 1px #10b981;
  transform: translateY(-4px);
}
body.vh-auth-shell .vh-plan-ribbon {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 0.25rem 0.85rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(90deg, #10b981, #059669);
  border-radius: 999px;
  box-shadow: 0 4px 10px rgba(16, 185, 129, 0.3);
  z-index: 2;
  white-space: nowrap;
}

/* ============================================================
   PHASE 2.5 — TRUST SURFACE POLISH
   Scope:  body.vh-auth-shell .vh-trust-page (opt-in per template)
   Pages:  Security, Webhooks, Secure Delivery, Profile, Team
   Policy: pure visual polish — no structural / behavioural change
   Hard constraint: must not bleed into dashboards, verifyflow,
   wizards, admin, billing, api_keys, verifications, auth pages
   (none of which carry the .vh-trust-page hook).
   ============================================================ */

body.vh-auth-shell .vh-trust-page {
    --vh-trust-ink: #0b1d33;
    --vh-trust-ink-muted: #5b6b81;
    --vh-trust-line: #e7ecf3;
    --vh-trust-line-soft: #eef1f6;
    --vh-trust-tint: #f5f9ff;
    --vh-trust-accent: #0079F2;
    --vh-trust-accent-dark: #005bb8;
    padding-top: 0.25rem;
}

/* ---------- Cards: softer enterprise chrome ---------- */
body.vh-auth-shell .vh-trust-page .card,
body.vh-auth-shell .vh-trust-page .card.shadow-sm,
body.vh-auth-shell .vh-trust-page .card.shadow-lg {
    border: 1px solid var(--vh-trust-line);
    border-radius: 14px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04),
                0 4px 12px rgba(15, 23, 42, 0.025);
    overflow: hidden;
}

body.vh-auth-shell .vh-trust-page .card-header.bg-primary {
    background: linear-gradient(135deg,
        var(--vh-trust-accent) 0%,
        var(--vh-trust-accent-dark) 100%) !important;
    border-bottom: 0;
    padding: 1.15rem 1.5rem;
}
body.vh-auth-shell .vh-trust-page .card-header.bg-primary h3,
body.vh-auth-shell .vh-trust-page .card-header.bg-primary h5 {
    font-weight: 700;
    letter-spacing: -0.005em;
    margin-bottom: 0;
}

body.vh-auth-shell .vh-trust-page .card-header.bg-white {
    background: #fbfcfe !important;
    border-bottom: 1px solid var(--vh-trust-line) !important;
    padding: 0.95rem 1.25rem;
}
body.vh-auth-shell .vh-trust-page .card-footer.bg-light {
    background: #fbfcfe !important;
    border-top: 1px solid var(--vh-trust-line);
    padding: 0.85rem 1.25rem;
}

/* ---------- Section headers inside cards ---------- */
body.vh-auth-shell .vh-trust-page .card-body h5 {
    font-weight: 700;
    color: var(--vh-trust-ink);
    font-size: 1.02rem;
    letter-spacing: -0.005em;
    margin-bottom: 0.4rem;
}
body.vh-auth-shell .vh-trust-page .card-body > .mb-4 > p.text-muted,
body.vh-auth-shell .vh-trust-page .card-body > div > p.text-muted {
    color: var(--vh-trust-ink-muted) !important;
    font-size: 0.92rem;
}
body.vh-auth-shell .vh-trust-page .card-body > hr,
body.vh-auth-shell .vh-trust-page hr.my-4 {
    border: 0;
    border-top: 1px solid var(--vh-trust-line-soft);
    opacity: 1;
    margin: 1.5rem 0;
}

/* ---------- Alerts: softer, more trust-grade ---------- */
body.vh-auth-shell .vh-trust-page .alert {
    border-radius: 12px;
    padding: 1rem 1.15rem;
    margin-bottom: 1.25rem;
}
body.vh-auth-shell .vh-trust-page .alert-success {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #065f46;
}
body.vh-auth-shell .vh-trust-page .alert-warning {
    background: #fffbeb;
    border-color: #fde68a;
    color: #92400e;
}
body.vh-auth-shell .vh-trust-page .alert-info {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1e40af;
}
body.vh-auth-shell .vh-trust-page .alert-danger {
    background: #fef2f2;
    border-color: #fecaca;
    color: #991b1b;
}

/* ---------- Buttons ---------- */
body.vh-auth-shell .vh-trust-page .btn {
    border-radius: 10px;
    font-weight: 600;
    padding: 0.5rem 1rem;
}
body.vh-auth-shell .vh-trust-page .btn-sm {
    border-radius: 8px;
    padding: 0.3rem 0.7rem;
}
body.vh-auth-shell .vh-trust-page .btn-danger {
    box-shadow: 0 1px 2px rgba(239, 68, 68, 0.18);
}
body.vh-auth-shell .vh-trust-page .btn-warning {
    box-shadow: 0 1px 2px rgba(245, 158, 11, 0.18);
}

/* ---------- Forms ---------- */
body.vh-auth-shell .vh-trust-page .form-label {
    font-weight: 600;
    color: var(--vh-trust-ink);
    font-size: 0.88rem;
    margin-bottom: 0.4rem;
}
body.vh-auth-shell .vh-trust-page .form-control,
body.vh-auth-shell .vh-trust-page .form-select {
    border-radius: 9px;
    border-color: #d9e0ea;
    padding: 0.55rem 0.8rem;
}
body.vh-auth-shell .vh-trust-page .form-control:focus,
body.vh-auth-shell .vh-trust-page .form-select:focus {
    border-color: var(--vh-trust-accent);
    box-shadow: 0 0 0 3px rgba(0, 121, 242, 0.12);
}
body.vh-auth-shell .vh-trust-page .form-text {
    color: var(--vh-trust-ink-muted);
}

/* ---------- Tables ---------- */
body.vh-auth-shell .vh-trust-page .table {
    margin-bottom: 0;
}
body.vh-auth-shell .vh-trust-page .table > thead,
body.vh-auth-shell .vh-trust-page .table > thead.table-light {
    background: #f7faff;
}
body.vh-auth-shell .vh-trust-page .table > thead > tr > th {
    font-weight: 600;
    font-size: 0.74rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--vh-trust-ink-muted);
    border-bottom: 1px solid var(--vh-trust-line);
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}
body.vh-auth-shell .vh-trust-page .table > tbody > tr > td {
    vertical-align: middle;
    border-color: var(--vh-trust-line-soft);
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}
body.vh-auth-shell .vh-trust-page .table.table-hover > tbody > tr:hover {
    background-color: #f7faff;
}

/* ---------- Badges ---------- */
body.vh-auth-shell .vh-trust-page .badge {
    font-weight: 600;
    padding: 0.42em 0.65em;
    letter-spacing: 0.01em;
    border-radius: 6px;
}

/* ---------- Method cards (Secure Delivery options, Dashboard View) ---------- */
body.vh-auth-shell .vh-trust-page .row.g-4 > [class*="col-"] > .card,
body.vh-auth-shell .vh-trust-page .row.g-3 > [class*="col-"] > .card {
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
body.vh-auth-shell .vh-trust-page .row.g-4 > [class*="col-"] > .card:hover,
body.vh-auth-shell .vh-trust-page .row.g-3 > [class*="col-"] > .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(0, 121, 242, 0.08),
                0 1px 2px rgba(15, 23, 42, 0.04);
    border-color: #cfe1fa;
}

/* ---------- Empty states ---------- */
body.vh-auth-shell .vh-trust-page .card-body.text-center.py-5 {
    padding-top: 3.25rem !important;
    padding-bottom: 3.25rem !important;
}
body.vh-auth-shell .vh-trust-page .card-body.text-center.py-5 .fa-3x,
body.vh-auth-shell .vh-trust-page .card-body.text-center.py-5 .fa-2x {
    color: #cbd5e1 !important;
    margin-bottom: 1rem;
}
body.vh-auth-shell .vh-trust-page .card-body.text-center.py-5 h5 {
    color: var(--vh-trust-ink);
    margin-bottom: 0.5rem;
}

/* ---------- Trust page heading bar (Webhooks / Secure Delivery use d-flex header) ---------- */
body.vh-auth-shell .vh-trust-page > .container-fluid > .d-flex.justify-content-between,
body.vh-auth-shell .vh-trust-page > .d-flex.justify-content-between.align-items-center.mb-4 {
    background: linear-gradient(135deg, #ffffff 0%, var(--vh-trust-tint) 100%);
    border: 1px solid var(--vh-trust-line);
    border-left: 4px solid var(--vh-trust-accent);
    border-radius: 14px;
    padding: 1.2rem 1.5rem;
    margin-bottom: 1.5rem !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
body.vh-auth-shell .vh-trust-page > .container-fluid > .d-flex.justify-content-between h3,
body.vh-auth-shell .vh-trust-page .d-flex.justify-content-between.align-items-center.mb-4 h3 {
    color: var(--vh-trust-ink);
    letter-spacing: -0.01em;
}
body.vh-auth-shell .vh-trust-page > .container-fluid > .d-flex.justify-content-between p.text-muted,
body.vh-auth-shell .vh-trust-page .d-flex.justify-content-between.align-items-center.mb-4 p.text-muted {
    color: var(--vh-trust-ink-muted) !important;
}

/* ---------- "How it works" steps (Webhooks empty state) ---------- */
body.vh-auth-shell .vh-trust-page .rounded-circle[style*="background-color: #E8F4FD"] {
    box-shadow: 0 2px 6px rgba(0, 121, 242, 0.12);
}

/* ---------- Member "you" highlight ---------- */
body.vh-auth-shell .vh-trust-page .table > tbody > tr.table-active {
    background-color: #eef6ff;
}

/* ---------- Code chips inside trust pages ---------- */
body.vh-auth-shell .vh-trust-page code {
    background: #f5f7fb;
    color: #0b1d33;
    padding: 0.12rem 0.4rem;
    border-radius: 5px;
    font-size: 0.85em;
}

/* =================================================================
   Phase 3 — VerifyFlow product polish (opt-in via body.vh-auth-shell .vh-vf-page)
   Applies only to VerifyFlow product pages: flows_list, templates_browser, results.
   No structural changes; CSS-only. Preserves all forms/buttons/handlers.
================================================================= */

/* ---------- Page rhythm ---------- */
body.vh-auth-shell .vh-vf-page {
    color: var(--vh-text);
}
body.vh-auth-shell .vh-vf-page h1 {
    letter-spacing: -0.01em;
}
body.vh-auth-shell .vh-vf-page .text-muted {
    color: #5b6b80 !important;
}

/* ---------- Summary stat cards (flows_list) ---------- */
body.vh-auth-shell .vh-vf-page .row.g-3.mb-4 > [class*="col-"] > .card {
    border: 1px solid var(--vh-border-soft) !important;
    border-radius: 14px !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04) !important;
    transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
    position: relative;
    overflow: hidden;
}
body.vh-auth-shell .vh-vf-page .row.g-3.mb-4 > [class*="col-"] > .card::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #6366f1, #8b5cf6);
    opacity: 0.85;
}
body.vh-auth-shell .vh-vf-page .row.g-3.mb-4 > [class*="col-"] > .card:hover {
    border-color: #c7d2fe !important;
    box-shadow: 0 8px 20px -14px rgba(15, 23, 42, 0.18) !important;
    transform: translateY(-1px);
}
body.vh-auth-shell .vh-vf-page .row.g-3.mb-4 .card-body {
    padding: 1rem 1.1rem;
}
body.vh-auth-shell .vh-vf-page .row.g-3.mb-4 .text-uppercase {
    letter-spacing: 0.06em;
    font-size: 0.7rem;
    color: #64748b !important;
}

/* ---------- Search / filter bar (flows_list) ---------- */
body.vh-auth-shell .vh-vf-page .card.shadow-sm.mb-3 {
    border: 1px solid var(--vh-border-soft) !important;
    border-radius: 12px !important;
}
body.vh-auth-shell .vh-vf-page .input-group-text {
    background: #ffffff;
    border-color: #dbe3ee;
}
body.vh-auth-shell .vh-vf-page input[type="search"].form-control {
    border-color: #dbe3ee;
    box-shadow: none;
}
body.vh-auth-shell .vh-vf-page input[type="search"].form-control:focus {
    border-color: #818cf8;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

/* ---------- Tables (flows_list, results) ---------- */
body.vh-auth-shell .vh-vf-page .card.shadow-sm > .table-responsive,
body.vh-auth-shell .vh-vf-page .card.shadow-sm > .card-body > .table-responsive {
    border-radius: 14px;
    overflow: hidden;
}
body.vh-auth-shell .vh-vf-page .table > thead th {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #475569 !important;
    background: #f8fafc !important;
    border-bottom: 1px solid #e2e8f0 !important;
    font-weight: 600;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}
body.vh-auth-shell .vh-vf-page .table tbody tr {
    transition: background 0.12s ease;
}
body.vh-auth-shell .vh-vf-page .table tbody tr:hover {
    background: #f8faff !important;
}
body.vh-auth-shell .vh-vf-page .table tbody td {
    border-color: #eef2f7 !important;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}
body.vh-auth-shell .vh-vf-page .table tbody tr.collapse:hover,
body.vh-auth-shell .vh-vf-page .table tbody tr.collapse.show:hover {
    background: transparent !important;
}

/* ---------- Status & output pills (flows_list, results) ---------- */
body.vh-auth-shell .vh-vf-page .badge {
    font-weight: 600;
    font-size: 0.72rem;
    padding: 0.35em 0.65em;
    border-radius: 999px;
    letter-spacing: 0.01em;
}
body.vh-auth-shell .vh-vf-page .badge.bg-light.text-dark.border {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-color: #e2e8f0 !important;
}

/* ---------- Action button cluster (flows_list rows) ---------- */
body.vh-auth-shell .vh-vf-page .table .btn-sm {
    border-radius: 8px;
    font-weight: 500;
}
body.vh-auth-shell .vh-vf-page .table .btn-outline-secondary {
    border-color: #d6deea;
    color: #344256;
}
body.vh-auth-shell .vh-vf-page .table .btn-outline-secondary:hover {
    background: #f1f5fb;
    border-color: #b6c4d8;
    color: #0f172a;
}
body.vh-auth-shell .vh-vf-page .table .dropdown-menu {
    border-color: #e2e8f0;
    border-radius: 10px;
    padding: 0.35rem;
}
body.vh-auth-shell .vh-vf-page .table .dropdown-item {
    border-radius: 6px;
    padding: 0.45rem 0.6rem;
}

/* ---------- Empty state ---------- */
body.vh-auth-shell .vh-vf-page .card.shadow-sm .card-body.text-center.py-5 {
    padding-top: 3.5rem !important;
    padding-bottom: 3.5rem !important;
}
body.vh-auth-shell .vh-vf-page .card.shadow-sm .card-body.text-center.py-5 .fa-3x,
body.vh-auth-shell .vh-vf-page .card.shadow-sm .card-body.text-center.py-5 .fa-inbox {
    color: #94a3b8 !important;
    opacity: 0.85;
}
body.vh-auth-shell .vh-vf-page [data-vf8="empty-state"] {
    padding: 3.5rem 1rem !important;
}
body.vh-auth-shell .vh-vf-page [data-vf8="empty-state"] h5 {
    color: var(--vh-text);
    font-weight: 600;
}

/* ---------- Templates browser (templates_browser) ---------- */
body.vh-auth-shell .vh-vf-page .vh-tpl-card {
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card:hover {
    border-color: #c7d2fe;
    box-shadow: 0 12px 28px -18px rgba(99, 102, 241, 0.28);
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card__body {
    padding: 1.25rem 1.25rem 1.15rem;
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card__title {
    font-size: 1.02rem;
    letter-spacing: -0.005em;
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card__desc {
    font-size: 0.875rem;
    line-height: 1.5;
    color: #5b6b80;
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card__meta {
    font-size: 0.78rem;
    color: #475569;
    padding: 0.4rem 0.6rem;
    background: #f8fafc;
    border-radius: 8px;
    display: inline-block;
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card__tags .badge {
    background: #eef2ff !important;
    color: #4338ca !important;
    font-weight: 500;
    text-transform: lowercase;
}
body.vh-auth-shell .vh-vf-page .vh-tpl-card .btn-primary {
    align-self: flex-start;
}

/* ---------- Results page polish ---------- */
body.vh-auth-shell .vh-vf-page [data-vf8="results-table"] tbody tr.result-row td {
    border-bottom: 1px solid #eef2f7 !important;
}
body.vh-auth-shell .vh-vf-page [data-vf8="results-table"] tbody tr.collapse td {
    border-top: none !important;
    border-bottom: 1px solid #e2e8f0 !important;
}
body.vh-auth-shell .vh-vf-page [data-vf8="results-table"] code {
    background: #f1f5f9;
    color: #1e293b;
    padding: 0.15rem 0.45rem;
    border-radius: 6px;
    font-size: 0.82em;
}
body.vh-auth-shell .vh-vf-page [data-vf8="summary-tiles"] .vh-stat {
    transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
}
body.vh-auth-shell .vh-vf-page [data-vf8="summary-tiles"] .vh-stat:hover {
    border-color: #c7d2fe;
    box-shadow: 0 8px 20px -14px rgba(15, 23, 42, 0.18);
    transform: translateY(-1px);
}

/* ---------- Toolbar filters (results) ---------- */
body.vh-auth-shell .vh-vf-page .vh-toolbar .btn-primary {
    box-shadow: 0 4px 10px -6px rgba(99, 102, 241, 0.55);
}

/* ---------- View archived link ---------- */
body.vh-auth-shell .vh-vf-page .text-center.mt-3 a.small {
    color: #64748b;
    border-bottom: 1px dashed transparent;
    padding-bottom: 1px;
}
body.vh-auth-shell .vh-vf-page .text-center.mt-3 a.small:hover {
    color: #4338ca;
    border-bottom-color: #c7d2fe;
}
