/*
 * Commercial-Grade Accessible Stylesheet
 * Matching the PDF Accessibility Workbench editorial design system.
 * Fully compliant with WCAG 2.1 & 2.2 Level AAA (Contrast >= 7:1, Touch Targets >= 44px, Focus Indicators).
 */

:root {
    --bg-canvas: #faf8f5;
    --card-bg: #ffffff;
    --border-subtle: #e2e8f0;
    --border-card: #e5e7eb;
    --text-headline: #0f172a;
    --text-body: #334155;
    --text-muted: #64748b;

    /* Teal brand accent */
    --teal-brand: #2D5403;
    --teal-brand-dark: #203c02;
    --teal-surface: #f0fdfa;
    --teal-dashed: #5eead4;
    --teal-pill-bg: #ccfbf1;
    --teal-pill-text: #2D5403;

    /* Amber / Auditor's note */
    --amber-surface: #fff7ed;
    --amber-border: #ea580c;
    --amber-text-title: #7c2d12;
    --amber-text-body: #431407;

    /* Severity badges (AAA contrast on white / light) */
    --critical-bg: #fee2e2;
    --critical-text: #991b1b;
    --critical-border: #f87171;

    --serious-bg: #fef3c7;
    --serious-text: #92400e;
    --serious-border: #fcd34d;

    --moderate-bg: #e0e7ff;
    --moderate-text: #3730a3;
    --moderate-border: #a5b4fc;

    --success-bg: #dcfce7;
    --success-text: #166534;
    --success-border: #86efac;

    --focus-ring: 3px solid #2D5403;
    --font-stack: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    max-width: 100%;
    overflow-x: hidden;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-canvas);
    color: var(--text-body);
    font-family: var(--font-stack);
    line-height: 1.6;
    font-size: 1.05rem;
    -webkit-font-smoothing: antialiased;
}

/* Skip link for keyboard users (WCAG 2.4.1) */
.skip-link {
    position: absolute;
    top: -60px;
    left: 20px;
    background: #0f172a;
    color: #ffffff;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 6px;
    z-index: 9999;
    text-decoration: none;
    transition: top 0.15s ease-in-out;
}

.skip-link:focus {
    top: 15px;
    outline: var(--focus-ring);
    outline-offset: 3px;
}

/* Screen-Reader Only Accessible Utility (WCAG 1.3.1 / 4.1.2) */
.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* High-visibility focus indicators (WCAG 2.4.7 / 2.4.11) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
    outline: var(--focus-ring) !important;
    outline-offset: 3px !important;
}

/* Fluid Executive Header & Accessible Navigation */
.site-header,
.site-header-fluid {
    width: 100%;
    box-sizing: border-box;
    background: rgba(250, 248, 245, 0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-subtle);
    padding: clamp(0.75rem, 1.1vw, 1rem) clamp(1.25rem, 3.5vw, 3rem);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.2s ease-in-out;
}

.header-inner,
.header-inner-fluid {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: clamp(1rem, 2vw, 2rem);
    position: relative;
}

/* Brand Section */
.brand-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.brand-link {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: opacity 0.15s ease;
}

.brand-link:hover {
    opacity: 0.88;
}

.brand-logo-img {
    height: 82px;
    width: auto;
    max-height: 82px;
    display: block;
    object-fit: contain;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.brand-link:hover .brand-logo-img {
    opacity: 0.95;
    transform: scale(1.015);
}

@media (max-width: 640px) {
    .brand-logo-img {
        height: 36px;
    }
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.brand-text {
    font-weight: 850;
    font-size: 1.25rem;
    color: #0f172a;
    letter-spacing: -0.025em;
    line-height: 1;
}

.brand-highlight {
    color: var(--teal-brand);
}

.site-tagline {
    border-left: 1.5px solid #cbd5e1;
    padding-left: 0.75rem;
    margin-left: 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    white-space: nowrap;
}

/* Desktop Navigation */
.site-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 1;
    gap: 1.25rem;
}

.nav-links-group {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.nav-actions-group {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.nav-link {
    color: #334155;
    font-weight: 650;
    font-size: 0.92rem;
    text-decoration: none;
    padding: 0.45rem 0.75rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.15s ease-in-out;
    white-space: nowrap;
    border: 1px solid transparent;
}

.nav-link:hover {
    text-decoration: none;
    background: rgba(45, 84, 3, 0.08);
    color: var(--teal-brand);
}

.nav-link.active {
    color: var(--teal-brand);
    background: #e6f4f1;
    font-weight: 750;
    border-color: rgba(45, 84, 3, 0.2);
}

.nav-link-admin {
    color: #7e22ce;
}

.nav-link-admin:hover {
    color: #6b21a8;
    background: rgba(126, 34, 206, 0.08);
}

.nav-link-admin.active {
    color: #6b21a8;
    background: #f3e8ff;
    border-color: #d8b4fe;
}

.nav-link-muted {
    color: #64748b;
    font-weight: 550;
}

.nav-link-muted:hover {
    color: #0f172a;
    background: #f1f5f9;
}

.nav-account-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 9999px;
    padding: 0.35rem 0.75rem;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 650;
    color: #1e293b;
    transition: all 0.15s ease-in-out;
}

.nav-account-pill:hover {
    border-color: var(--teal-brand);
    box-shadow: 0 2px 6px rgba(45, 84, 3, 0.12);
}

.nav-account-pill.active {
    border-color: var(--teal-brand);
    background: #f0fdfa;
}

.nav-account-pill .credit-badge {
    background: #ccfbf1;
    color: #2D5403;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 0.15rem 0.55rem;
    border-radius: 9999px;
    letter-spacing: -0.01em;
}

.nav-cta-btn {
    font-size: 0.88rem;
    font-weight: 700;
    padding: 0.45rem 1rem;
    text-decoration: none;
    border-radius: 6px;
    white-space: nowrap;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
}

/* Mobile Hamburger Toggle Button */
.mobile-nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 8px;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.mobile-nav-toggle:hover {
    border-color: var(--teal-brand);
    background: #f8fafc;
}

.mobile-nav-toggle .hamburger-bar {
    display: block;
    width: 22px;
    height: 2.5px;
    background-color: #1e293b;
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(2) {
    opacity: 0;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-bar:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

@keyframes navDrawerSlide {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Mobile Navigation Drawer */
@media (max-width: 900px) {
    .site-header,
    .site-header-fluid {
        padding: 0.75rem 1.25rem;
    }

    .header-inner,
    .header-inner-fluid {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        position: relative;
    }

    .site-tagline {
        display: none;
    }

    .mobile-nav-toggle {
        display: flex;
    }

    .site-nav {
        display: none;
        width: 100%;
        position: absolute;
        top: calc(100% + 0.75rem);
        left: 0;
        right: 0;
        background: #ffffff;
        border: 1.5px solid #e2e8f0;
        border-radius: 12px;
        box-shadow: 0 16px 36px rgba(15, 23, 42, 0.14);
        padding: 1.25rem;
        flex-direction: column;
        align-items: stretch;
        gap: 1.25rem;
        z-index: 1000;
        animation: navDrawerSlide 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .site-nav.is-open {
        display: flex;
    }

    .nav-links-group {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 0.4rem;
    }

    .nav-actions-group {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 0.75rem;
        border-top: 1px solid #e2e8f0;
        padding-top: 1rem;
    }

    .nav-link {
        width: 100%;
        padding: 0.75rem 1rem;
        font-size: 1rem;
        min-height: 44px;
        border-radius: 8px;
    }

    .nav-account-pill {
        width: 100%;
        justify-content: space-between;
        padding: 0.65rem 1rem;
        font-size: 0.95rem;
        border-radius: 8px;
    }

    .nav-cta-btn {
        width: 100%;
        justify-content: center;
        text-align: center;
        min-height: 46px;
        font-size: 0.95rem;
    }
}

/* Main Container */
.main-content,
.content-container,
#main-content,
main {
    box-sizing: border-box;
    width: 100%;
    max-width: 1400px;
    margin: 1.5rem auto 4rem auto;
    padding-left: clamp(1.25rem, 3.5vw, 3rem);
    padding-right: clamp(1.25rem, 3.5vw, 3rem);
}

@media (max-width: 720px) {
    .main-content,
    .content-container,
    #main-content,
    main {
        padding-left: 1rem;
        padding-right: 1rem;
        margin-top: 1rem;
    }
}

/* Hero Typography */
.kicker {
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--teal-brand);
    margin-bottom: 0.75rem;
}

.hero-title {
    font-size: clamp(1.85rem, 5.5vw, 3.25rem);
    font-weight: 850;
    letter-spacing: -0.035em;
    line-height: 1.1;
    color: var(--text-headline);
    margin-top: 0;
    margin-bottom: 1.25rem;
    overflow-wrap: break-word;
    word-break: break-word;
}

.hero-lead {
    font-size: 1.15rem;
    line-height: 1.55;
    color: var(--text-body);
    max-width: 720px;
    margin-bottom: 2.25rem;
}

/* White Workbench Cards */
.card-workbench {
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04);
}

.card-heading {
    font-size: 1.35rem;
    font-weight: 750;
    letter-spacing: -0.02em;
    color: var(--text-headline);
    margin-top: 0;
    margin-bottom: 1.25rem;
}

/* Step 1: Document Ingestion Panel & Interactive Dropzone */
.ingestion-panel {
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 16px;
    padding: clamp(1.5rem, 2.5vw, 2.5rem);
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.05);
    position: relative;
    overflow: hidden;
}

.ingestion-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--teal-brand) 0%, #0d9488 50%, #14b8a6 100%);
}

.ingestion-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-bottom: 1.75rem;
}

.ingestion-title-group {
    flex: 1;
    min-width: 280px;
}

.ingestion-trust-badges {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.trust-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #475569;
    font-size: 0.8rem;
    font-weight: 650;
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    letter-spacing: -0.01em;
}

.trust-badge-pill svg {
    color: var(--teal-brand);
}

/* Interactive Dropzone */
.drop-zone,
.dropzone-container {
    border: 2px dashed #94a3b8;
    background: linear-gradient(180deg, #fbfcfe 0%, #f1f5f9 100%);
    border-radius: 14px;
    padding: clamp(2.25rem, 3.5vw, 3.25rem) 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
    position: relative;
    user-select: none;
}

.drop-zone:hover,
.dropzone-container:hover {
    border-color: var(--teal-brand);
    background: #f0fdfa;
    box-shadow: 0 0 0 4px rgba(45, 84, 3, 0.08);
}

.drop-zone:focus-visible,
.dropzone-container:focus-visible {
    outline: var(--focus-ring) !important;
    outline-offset: 3px !important;
    border-color: var(--teal-brand);
}

.drop-zone.dragover,
.dropzone-container.dragover {
    border-color: var(--teal-brand);
    background: #ccfbf1;
    border-style: solid;
    transform: scale(1.008);
    box-shadow: 0 12px 28px -6px rgba(45, 84, 3, 0.2);
}

.drop-zone-icon-badge {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.25rem auto;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.drop-zone:hover .drop-zone-icon-badge,
.drop-zone.dragover .drop-zone-icon-badge,
.dropzone-container:hover .drop-zone-icon-badge {
    transform: translateY(-2px);
    border-color: var(--teal-brand);
    background: #f0fdfa;
}

.drop-zone-prompt {
    font-size: 1.2rem;
    font-weight: 750;
    color: #0f172a;
    margin-bottom: 0.5rem;
    letter-spacing: -0.015em;
}

.drop-zone-cta-link {
    color: var(--teal-brand);
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 800;
}

.drop-zone-sub {
    font-size: 0.92rem;
    color: #64748b;
    margin-bottom: 1.5rem;
    line-height: 1.5;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.drop-zone-features {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.drop-feature-tag {
    font-size: 0.78rem;
    font-weight: 650;
    padding: 0.25rem 0.65rem;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    color: #334155;
    box-shadow: 0 1px 2px rgba(0,0,0,0.02);
}

/* File Selected State Chip */
.file-info-chip-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #ffffff;
    border: 1.5px solid var(--teal-brand);
    border-radius: 12px;
    padding: 1rem 1.35rem;
    margin-top: 1.25rem;
    box-shadow: 0 6px 18px rgba(45, 84, 3, 0.1);
    animation: fadeInChip 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    gap: 1rem;
    flex-wrap: wrap;
}

@keyframes fadeInChip {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.file-chip-meta {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-align: left;
}

.file-chip-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    border-radius: 8px;
    color: var(--teal-brand);
    flex-shrink: 0;
}

.file-chip-title {
    font-weight: 750;
    font-size: 1rem;
    color: #0f172a;
    word-break: break-all;
}

.file-chip-size {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 550;
}

.file-chip-badge {
    background: #dcfce7;
    color: #166534;
    font-size: 0.8rem;
    font-weight: 750;
    padding: 0.25rem 0.65rem;
    border-radius: 9999px;
    border: 1px solid #86efac;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.file-chip-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.file-chip-change-btn {
    background: transparent;
    border: 1px solid #cbd5e1;
    color: #475569;
    font-size: 0.82rem;
    font-weight: 650;
    padding: 0.35rem 0.75rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
}

.file-chip-change-btn:hover {
    background: #f1f5f9;
    color: #0f172a;
    border-color: #94a3b8;
}

#submit-container {
    animation: fadeInChip 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.submit-triage-btn {
    width: 100%;
    min-height: 52px;
    font-size: 1.08rem;
    font-weight: 750;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 14px rgba(45, 84, 3, 0.25);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease-in-out;
}

.submit-triage-btn:hover {
    box-shadow: 0 6px 20px rgba(45, 84, 3, 0.35);
    transform: translateY(-1px);
}

@keyframes btnPulseReveal {
    0% {
        transform: scale(0.99);
        box-shadow: 0 0 0 0 rgba(45, 84, 3, 0.45);
    }
    50% {
        transform: scale(1.01);
        box-shadow: 0 0 0 10px rgba(45, 84, 3, 0.1);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 4px 14px rgba(45, 84, 3, 0.25);
    }
}

.submit-triage-btn.btn-revealed-pulse {
    animation: btnPulseReveal 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Ease-of-Use 3-Step Workflow Stepper */
.workflow-stepper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.85rem;
    margin-bottom: 1.75rem;
}

@media (max-width: 768px) {
    .workflow-stepper {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
}

.workflow-step-card {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.85rem 1.15rem;
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    transition: all 0.2s ease;
}

.workflow-step-card.active {
    border-color: var(--teal-brand);
    background: #f0fdfa;
    box-shadow: 0 4px 12px rgba(45, 84, 3, 0.08);
}

.workflow-step-card.completed {
    border-color: #cbd5e1;
    background: #f8fafc;
}

.workflow-step-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
    background: #e2e8f0;
    color: #475569;
}

.workflow-step-card.active .workflow-step-badge {
    background: var(--teal-brand);
    color: #ffffff;
    box-shadow: 0 2px 6px rgba(45, 84, 3, 0.3);
}

.workflow-step-card.completed .workflow-step-badge {
    background: #dcfce7;
    color: #15803d;
}

.workflow-step-info {
    text-align: left;
    min-width: 0;
}

.workflow-step-title {
    font-size: 0.9rem;
    font-weight: 750;
    color: var(--text-headline);
    line-height: 1.25;
}

.workflow-step-subtitle {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.35;
    margin-top: 0.15rem;
}

/* Enterprise Scalability & Asynchronous Architecture Section */
.architecture-section {
    margin-top: 4rem;
    margin-bottom: 4rem;
    background: #090d16;
    border-radius: 18px;
    padding: clamp(2rem, 4vw, 3.5rem) clamp(1.5rem, 3.5vw, 3rem);
    color: #f8fafc;
    box-shadow: 0 20px 40px -15px rgba(15, 23, 42, 0.4);
    border: 1px solid #1e293b;
    position: relative;
    overflow: hidden;
}

.architecture-section::before {
    content: "";
    position: absolute;
    top: -50px;
    right: -50px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(45, 84, 3, 0.22) 0%, rgba(9, 13, 22, 0) 70%);
    pointer-events: none;
}

.arch-header-wrap {
    max-width: 820px;
    margin-bottom: 2.5rem;
    position: relative;
    z-index: 1;
}

.arch-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(20, 184, 166, 0.15);
    border: 1px solid rgba(20, 184, 166, 0.35);
    color: #2dd4bf;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.85rem;
}

.arch-title {
    font-size: clamp(1.85rem, 3vw, 2.4rem);
    font-weight: 850;
    letter-spacing: -0.025em;
    color: #ffffff;
    margin: 0 0 0.85rem 0;
    line-height: 1.25;
}

.arch-lead {
    font-size: 1.05rem;
    color: #94a3b8;
    line-height: 1.65;
    margin: 0;
}

.arch-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .arch-grid {
        grid-template-columns: 1fr;
    }
}

.arch-card {
    background: rgba(19, 26, 42, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.arch-card:hover {
    transform: translateY(-3px);
    border-color: rgba(45, 212, 191, 0.45);
    box-shadow: 0 10px 25px -5px rgba(45, 84, 3, 0.2);
}

.arch-card-top {
    margin-bottom: 1.25rem;
}

.arch-badge-pill {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    background: rgba(45, 84, 3, 0.35);
    color: #5eead4;
    border: 1px solid rgba(45, 212, 191, 0.3);
    margin-bottom: 0.85rem;
}

.arch-card-title {
    font-size: 1.22rem;
    font-weight: 750;
    color: #ffffff;
    margin: 0 0 0.65rem 0;
    line-height: 1.35;
}

.arch-card-desc {
    font-size: 0.92rem;
    color: #cbd5e1;
    line-height: 1.6;
    margin: 0;
}

.arch-card-footer {
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    font-size: 0.82rem;
    color: #94a3b8;
}

.arch-metric-val {
    font-weight: 750;
    color: #2dd4bf;
    font-family: ui-monospace, monospace;
}

/* Auditor's Note Callout Card */
.auditor-callout {
    background-color: var(--amber-surface);
    border-left: 4px solid var(--amber-border);
    border-radius: 4px 8px 8px 4px;
    padding: 1.15rem 1.5rem;
    margin-top: 2rem;
    margin-bottom: 2.5rem;
    font-size: 0.95rem;
    line-height: 1.55;
    color: var(--amber-text-body);
}

.auditor-callout strong {
    color: var(--amber-text-title);
    font-weight: 750;
}

/* Buttons */
.btn-workbench {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px; /* 44px+ touch target */
    padding: 0.75rem 1.75rem;
    font-size: 1.05rem;
    font-weight: 700;
    border-radius: 8px;
    text-decoration: none;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background 0.15s ease-in-out, transform 0.1s ease-in-out;
}

.btn-teal {
    background-color: #2D5403;
    color: #ffffff;
    border: 1.5px solid #203c02;
    font-weight: 800;
}

.btn-teal:hover {
    background-color: #203c02;
    color: #ffffff;
    border-color: #162a01;
}

.btn-secondary-wb {
    background-color: #ffffff;
    color: var(--text-headline);
    border: 1px solid var(--border-subtle);
}

.btn-secondary-wb:hover {
    background-color: #f8fafc;
}

/* Scorecards & Metrics */
.metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 2rem;
}

.metric-card {
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.25rem;
}

.metric-label {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.35rem;
}

.metric-value {
    font-size: 2rem;
    font-weight: 850;
    color: var(--text-headline);
    line-height: 1.1;
}

/* Badges */
.badge-pill {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 750;
    padding: 0.25rem 0.65rem;
    border-radius: 9999px;
    letter-spacing: 0.02em;
}

.badge-pill-critical {
    background-color: var(--critical-bg);
    color: var(--critical-text);
    border: 1px solid var(--critical-border);
}

.badge-pill-serious {
    background-color: var(--serious-bg);
    color: var(--serious-text);
    border: 1px solid var(--serious-border);
}

.badge-pill-moderate {
    background-color: var(--moderate-bg);
    color: var(--moderate-text);
    border: 1px solid var(--moderate-border);
}

.badge-pill-success {
    background-color: var(--success-bg);
    color: var(--success-text);
    border: 1px solid var(--success-border);
}

/* Tables & Findings Container */
.findings-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.filter-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.filter-btn {
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    color: var(--text-body);
    padding: 0.35rem 0.85rem;
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.15s ease-in-out;
}

.filter-btn:hover {
    border-color: var(--teal-brand);
    color: var(--teal-brand);
}

.filter-btn.active {
    background: #ccfbf1;
    border-color: #2D5403;
    color: #2D5403;
    font-weight: 800;
}

.search-filter-input {
    min-height: 38px;
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #ffffff;
    color: var(--text-headline);
    width: 240px;
}

.search-filter-input:focus {
    border-color: var(--teal-brand);
    outline: var(--focus-ring);
    outline-offset: 1px;
}

.findings-scroll-container {
    max-height: 480px;
    overflow-y: auto;
    overflow-x: auto;
    border: 1px solid var(--border-subtle);
    border-radius: 10px;
    background: #ffffff;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.03);
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f8fafc;
}

.findings-scroll-container:focus-visible {
    outline: var(--focus-ring);
    outline-offset: -2px;
}

.table-editorial {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #ffffff;
}

.table-editorial th {
    position: sticky;
    top: 0;
    z-index: 5;
    background: #f8fafc;
    color: var(--text-headline);
    font-size: 0.85rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.85rem 1rem;
    border-bottom: 2px solid var(--border-subtle);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    text-align: left;
}

.table-editorial td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    font-size: 0.95rem;
    vertical-align: top;
}

.table-editorial tbody tr:last-child td {
    border-bottom: none;
}

.table-editorial tbody tr:hover {
    background-color: #fafbfc;
}

/* Scrollable Table Containers with Maximum Height */
.table-scroll-container,
.table-scroll-max,
.findings-scroll-container {
    max-height: 480px;
    overflow-y: auto;
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
    -webkit-overflow-scrolling: touch;
}

.table-scroll-container::-webkit-scrollbar,
.table-scroll-max::-webkit-scrollbar,
.findings-scroll-container::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.table-scroll-container::-webkit-scrollbar-track,
.table-scroll-max::-webkit-scrollbar-track,
.findings-scroll-container::-webkit-scrollbar-track {
    background: transparent;
}

.table-scroll-container::-webkit-scrollbar-thumb,
.table-scroll-max::-webkit-scrollbar-thumb,
.findings-scroll-container::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 9999px;
}

.table-scroll-container::-webkit-scrollbar-thumb:hover,
.table-scroll-max::-webkit-scrollbar-thumb:hover,
.findings-scroll-container::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Ensure sticky thead stays pinned above rows during scroll */
.table-scroll-container thead,
.table-scroll-max thead,
.findings-scroll-container thead {
    position: sticky;
    top: 0;
    z-index: 10;
}

.table-scroll-container thead th,
.table-scroll-max thead th,
.findings-scroll-container thead th {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #f8fafc;
}

/* Accessible Forms */
.form-label {
    display: block;
    font-size: 0.95rem;
    font-weight: 750;
    color: var(--text-headline);
    margin-bottom: 0.35rem;
}

.form-subhint {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.form-input-wb,
.form-select-wb {
    width: 100%;
    min-height: 48px;
    padding: 0.65rem 0.9rem;
    font-size: 1rem;
    font-family: inherit;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #ffffff;
    color: var(--text-headline);
    margin-bottom: 1.25rem;
}

.form-input-wb:focus,
.form-select-wb:focus {
    border-color: var(--teal-brand);
}

/* Custom Checkbox Row */
.checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    margin-bottom: 0.9rem;
    cursor: pointer;
    font-size: 0.95rem;
    color: var(--text-headline);
}

.checkbox-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 0.15rem;
    accent-color: var(--teal-brand);
    cursor: pointer;
}

/* Virtual Buffer Terminal Box */
.terminal-card {
    background-color: #0f172a;
    color: #e2e8f0;
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    max-height: 300px;
    overflow-y: auto;
}

/* ==========================================================================
   Interactive PDF Compare Studio & Visual Fidelity Preservation
   ========================================================================== */
.fidelity-panel {
    background: #ffffff;
    border: 1px solid var(--border-card);
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    margin-top: 1.5rem;
    margin-bottom: 3rem;
}

.compare-studio-card {
    background: #ffffff;
    border: 1px solid var(--border-card);
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    margin-top: 1.5rem;
    margin-bottom: 2.5rem;
}

.mb-10 {
    margin-bottom: 2.5rem !important;
}

.compare-studio-header {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.85rem 1.35rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.compare-studio-header-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: #2D5403;
    color: #ffffff;
    font-size: 0.95rem;
    flex-shrink: 0;
}

.fidelity-banner {
    background: radial-gradient(circle at 90% 20%, rgba(16, 185, 129, 0.18), transparent 45%), linear-gradient(135deg, #022c22 0%, #064e3b 50%, #2D5403 100%);
    color: #ffffff;
    padding: 1.35rem 1.65rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    position: relative;
    overflow: hidden;
}

.fidelity-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(52, 211, 153, 0.4), transparent);
}

.fidelity-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(16, 185, 129, 0.2);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(52, 211, 153, 0.35);
    color: #a7f3d0;
    padding: 0.3rem 0.8rem;
    border-radius: 9999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.fidelity-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid var(--border-card);
}

.fidelity-metrics-grid .fidelity-metric-box {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    padding: 1.15rem 1.25rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.fidelity-metrics-grid .fidelity-metric-box:hover {
    transform: translateY(-2px);
    border-color: #94a3b8;
    box-shadow: 0 8px 16px -4px rgba(45, 84, 3, 0.12), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.fidelity-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.65rem;
}

.fidelity-icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: #ecfdf5;
    color: #064e3b;
    border: 1px solid #a7f3d0;
}

.fidelity-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.72rem;
    font-weight: 800;
    color: #064e3b;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    border-radius: 9999px;
    padding: 3px 9px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #059669;
    box-shadow: 0 0 0 2px rgba(5, 150, 105, 0.3);
}

.fidelity-metric-box .label {
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #1e293b;
    letter-spacing: 0.05em;
    display: block;
    margin-top: 0.35rem;
    margin-bottom: 0.25rem;
}

.fidelity-metric-box .val {
    font-size: 1.5rem;
    font-weight: 850;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    color: #0f172a;
    line-height: 1.2;
    display: block;
}

.fidelity-metric-box .subtext {
    font-size: 0.78rem;
    color: #334155;
    margin-top: 0.35rem;
    line-height: 1.4;
    font-weight: 600;
}

/* Compare Control Toolbar */
.compare-toolbar {
    background: #f1f5f9;
    border-bottom: 1px solid #cbd5e1;
    padding: 0.75rem 1.25rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    font-size: 0.9rem;
}

.compare-btn-group {
    display: inline-flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    overflow: hidden;
}

.compare-btn-group button {
    background: #ffffff;
    border: none;
    border-right: 1px solid #cbd5e1;
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 38px;
}

.compare-btn-group button:last-child {
    border-right: none;
}

.compare-btn-group button:hover {
    background: #f8fafc;
    color: #0f172a;
}

.compare-btn-group button.active {
    background: #ccfbf1;
    color: #042f2e;
    font-weight: 800;
}

.zoom-badge {
    padding: 0.45rem 0.75rem;
    font-size: 0.85rem;
    font-weight: 700;
    font-family: ui-monospace, SFMono-Regular, monospace;
    color: #0f172a;
    min-width: 58px;
    text-align: center;
    background: #f8fafc;
}

/* Enhanced Page Navigation Control */
.compare-page-nav {
    display: inline-flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    height: 38px;
}

.compare-page-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0 0.85rem;
    height: 100%;
    background: #ffffff;
    border: none;
    color: #334155;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    user-select: none;
}

.compare-page-btn:hover:not(:disabled) {
    background: #f1f5f9;
    color: #0f172a;
}

.compare-page-btn:active:not(:disabled) {
    background: #e2e8f0;
}

.compare-page-btn:disabled {
    opacity: 0.42;
    cursor: not-allowed;
    background: #f8fafc;
}

.compare-page-btn svg {
    flex-shrink: 0;
    transition: transform 0.15s ease;
}

.compare-page-btn.prev:hover:not(:disabled) svg {
    transform: translateX(-2px);
}

.compare-page-btn.next:hover:not(:disabled) svg {
    transform: translateX(2px);
}

.compare-page-counter {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0 0.85rem;
    height: 100%;
    background: #f8fafc;
    border-left: 1px solid #e2e8f0;
    border-right: 1px solid #e2e8f0;
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    white-space: nowrap;
}

.compare-page-counter .num {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-weight: 750;
    color: #0f172a;
}

/* Compact Instruction Bar */
.compare-instruction-bar {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.35rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    font-size: 0.72rem;
    line-height: 1.4;
    color: #64748b;
}

.compare-instruction-items {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.instruction-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.instruction-tag {
    background: #e2e8f0;
    color: #334155;
    font-size: 0.68rem;
    font-weight: 750;
    padding: 1px 5px;
    border-radius: 4px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}


/* Main Viewport Stage */
.compare-viewport {
    position: relative;
    width: 100%;
    height: clamp(560px, 72vh, 860px);
    background: #0f172a;
    overflow: hidden;
    cursor: grab;
    user-select: none;
    border-radius: 0 0 12px 12px;
}

.compare-viewport.panning {
    cursor: grabbing;
}

.compare-stage {
    position: absolute;
    top: 50%;
    left: 50%;
    transform-origin: center center;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
}

.compare-viewport.is-dragging .compare-stage {
    transition: none !important;
}

/* Curtain Slider Mode */
.curtain-container {
    position: relative;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    background: #ffffff;
    overflow: hidden;
    line-height: 0;
    border-radius: 4px;
}

.curtain-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    will-change: clip-path;
}

.curtain-layer img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: fill;
    pointer-events: none;
}

.curtain-divider {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 4px;
    background: #2D5403;
    cursor: ew-resize;
    z-index: 25;
    transform: translateX(-50%);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
}

.curtain-divider::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: -20px;
    width: 44px;
    cursor: ew-resize;
}

.curtain-handle-knob {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 42px;
    height: 42px;
    background: #2D5403;
    color: #ffffff;
    border: 3px solid #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
    font-size: 15px;
    font-weight: 800;
    cursor: ew-resize;
    transition: transform 0.15s ease, background 0.15s ease;
}

.curtain-divider:hover .curtain-handle-knob,
.curtain-handle-knob:hover {
    transform: translate(-50%, -50%) scale(1.1);
    background: #0d9488;
}

/* Floating Viewport HUD Badges (Anchored to Viewport Corners, never covering document content) */
.viewport-hud-tag,
.curtain-tag-left,
.curtain-tag-right {
    position: absolute;
    top: 14px;
    padding: 0.35rem 0.85rem;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: 9999px;
    z-index: 35;
    pointer-events: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    backdrop-filter: blur(8px);
}

.viewport-hud-tag.left,
.curtain-tag-left {
    left: 18px;
    background: rgba(15, 23, 42, 0.88);
    color: #f1f5f9;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.viewport-hud-tag.right,
.curtain-tag-right {
    right: 18px;
    background: rgba(45, 84, 3, 0.88);
    color: #ffffff;
    border: 1px solid rgba(20, 184, 166, 0.4);
}

.viewport-hud-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.viewport-hud-dot.before {
    background: #94a3b8;
}

.viewport-hud-dot.after {
    background: #34d399;
}

.compare-viewport.is-sliding,
.compare-viewport.is-sliding * {
    cursor: ew-resize !important;
}

@media (max-width: 640px) {
    .compare-viewport {
        height: clamp(380px, 60vh, 520px);
    }
    .compare-toolbar {
        padding: 0.5rem 0.65rem;
        gap: 0.4rem;
    }
    .compare-btn-group button {
        padding: 0.35rem 0.55rem;
        font-size: 0.75rem;
        min-height: 34px;
    }
    .compare-page-nav {
        height: 34px;
    }
    .compare-page-btn {
        padding: 0 0.5rem;
        font-size: 0.75rem;
    }
    .compare-page-counter {
        padding: 0 0.5rem;
        font-size: 0.72rem;
    }
    .zoom-badge {
        padding: 0.35rem 0.5rem;
        font-size: 0.75rem;
        min-width: 46px;
    }
    .compare-toggle-btn {
        font-size: 0.72rem;
        padding: 0.3rem 0.55rem;
    }
    .viewport-hud-tag,
    .curtain-tag-left,
    .curtain-tag-right {
        top: 8px;
        padding: 0.2rem 0.5rem;
        font-size: 0.65rem;
    }
    .viewport-hud-tag.left,
    .curtain-tag-left {
        left: 8px;
    }
    .viewport-hud-tag.right,
    .curtain-tag-right {
        right: 8px;
    }
}

/* Feature Toggle Buttons in Toolbar */
.compare-toggle-btn {
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.75rem;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: all 0.15s ease;
}

.compare-toggle-btn:hover {
    background: #e2e8f0;
    color: #0f172a;
}

.compare-toggle-btn.active {
    background: #ccfbf1;
    color: #042f2e;
    border-color: #2D5403;
    font-weight: 800;
    box-shadow: 0 1px 3px rgba(45, 84, 3, 0.2);
}

/* Semantic Structure Tree & Reading Order Overlay */
.accessibility-overlay-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 18;
    transition: opacity 0.2s ease;
}

.accessibility-overlay-layer.hidden-overlay {
    display: none !important;
}

.structure-box {
    position: absolute;
    border: 2px dashed rgba(16, 185, 129, 0.8);
    background: rgba(16, 185, 129, 0.12);
    border-radius: 4px;
    box-sizing: border-box;
}

.structure-box.heading {
    border-color: rgba(14, 165, 233, 0.9);
    background: rgba(14, 165, 233, 0.14);
}

.structure-box.table-block {
    border-color: rgba(245, 158, 11, 0.9);
    background: rgba(245, 158, 11, 0.14);
}

.structure-box.figure-block {
    border-color: rgba(168, 85, 247, 0.9);
    background: rgba(168, 85, 247, 0.14);
}

.structure-badge {
    position: absolute;
    top: -11px;
    left: 8px;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: 4px;
    color: #ffffff;
    letter-spacing: 0.02em;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
    white-space: nowrap;
}

.structure-badge.heading {
    background: #0284c7;
}

.structure-badge.para {
    background: #059669;
}

.structure-badge.table-block {
    background: #d97706;
}

.structure-badge.figure-block {
    background: #9333ea;
}

.reading-order-bubble {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #0f172a;
    color: #38bdf8;
    border: 1.5px solid #38bdf8;
    font-size: 0.65rem;
    font-weight: 850;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Bit-Exact Diff Verification Mask Overlay */
.diff-mask-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 22;
    background: rgba(15, 23, 42, 0.88);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    transition: opacity 0.2s ease;
}

.diff-mask-card {
    background: #1e293b;
    border: 1.5px solid #10b981;
    border-radius: 12px;
    padding: 1.25rem 1.75rem;
    text-align: center;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
    max-width: 380px;
    line-height: 1.4;
}

/* Side-by-Side Mode */
.side-by-side-container {
    display: flex;
    gap: 1.5rem;
}

.side-by-side-pane {
    position: relative;
    background: #ffffff;
    overflow: hidden;
    line-height: 0;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    border-radius: 4px;
}

.side-by-side-pane img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: fill;
    pointer-events: none;
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--border-subtle);
    padding: 2.5rem 1.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    text-align: center;
}

/* Screen Reader Virtual Buffer Terminal */
.terminal-card {
    background: #0f172a;
    color: #f1f5f9;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 0.88rem;
    line-height: 1.65;
    padding: 1.25rem 1.5rem;
    border-radius: 10px;
    border: 1px solid #334155;
    max-height: 360px;
    overflow-y: auto;
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4);
}

.terminal-card::-webkit-scrollbar {
    width: 8px;
}

.terminal-card::-webkit-scrollbar-track {
    background: #1e293b;
    border-radius: 4px;
}

.terminal-card::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 4px;
}

.terminal-card::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* ==========================================================================
   Visual Fidelity Verification Audit Card & Matrix
   ========================================================================== */
.fidelity-audit-card {
    background: #ffffff;
    border: 1px solid var(--border-card);
    border-top: 4px solid #059669;
    border-radius: 16px;
    padding: 1.75rem 2rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.fidelity-audit-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid #f1f5f9;
}

.fidelity-audit-title-group {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.fidelity-audit-icon-seal {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 1px solid #a7f3d0;
    color: #047857;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 4px rgba(5, 150, 105, 0.1);
}

.fidelity-audit-seal-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.fidelity-audit-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    text-align: left;
    font-size: 0.875rem;
}

.fidelity-audit-table th {
    background: #f8fafc;
    color: #475569;
    font-size: 0.72rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}

.fidelity-audit-table th:first-child {
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
    border-left: 1px solid #e2e8f0;
}

.fidelity-audit-table th:last-child {
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
    border-right: 1px solid #e2e8f0;
}

.fidelity-audit-table td {
    padding: 1rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.fidelity-audit-table tbody tr:last-child td {
    border-bottom: none;
}

.fidelity-audit-table tbody tr:hover td {
    background: #f8fafc;
}

.fidelity-prop-title {
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.fidelity-prop-sub {
    font-size: 0.75rem;
    color: #64748b;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
    margin-top: 0.2rem;
}

.fidelity-badge-exact {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
    padding: 0.3rem 0.75rem;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 750;
    white-space: nowrap;
}

.fidelity-badge-safe {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #f0fdfa;
    color: #2D5403;
    border: 1px solid #99f6e4;
    padding: 0.3rem 0.75rem;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 750;
    white-space: nowrap;
}

.fidelity-attestation-box {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #e2e8f0;
    border-left: 4px solid #059669;
    border-radius: 10px;
    padding: 1rem 1.35rem;
    margin-top: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    font-size: 0.82rem;
    color: #334155;
    line-height: 1.55;
}

/* ==========================================================================
   Commercial Pricing & Pay-As-You-Go Showcase
   ========================================================================== */
.pricing-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1rem;
    margin-bottom: 2rem;
}

.pricing-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #334155;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.82rem;
    font-weight: 700;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.pricing-toggle-shell {
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    padding: 6px;
    border-radius: 9999px;
    display: inline-flex;
    gap: 6px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
}

.pricing-toggle-btn {
    border-radius: 9999px;
    padding: 0.65rem 1.65rem;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #475569;
    background: transparent;
}

.pricing-toggle-btn.active {
    background: #ccfbf1;
    color: #042f2e;
    border-color: #2D5403;
    box-shadow: 0 4px 10px rgba(45, 84, 3, 0.15);
}

.pricing-toggle-btn:not(.active):hover {
    color: #0f172a;
    background: rgba(255, 255, 255, 0.6);
}

.pricing-subtag {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.pricing-toggle-btn.active .pricing-subtag {
    background: #99f6e4;
    color: #042f2e;
    border: 1px solid #2D5403;
}

.pricing-toggle-btn:not(.active) .pricing-subtag {
    background: #e2e8f0;
    color: #64748b;
}

.pricing-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1.25rem;
    align-items: stretch;
}

.pricing-pack-card {
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 1.85rem 1.65rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    box-shadow: 0 4px 12px -2px rgba(15, 23, 42, 0.05);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.pricing-pack-card:hover {
    transform: translateY(-4px);
    border-color: #cbd5e1;
    box-shadow: 0 16px 32px -6px rgba(15, 23, 42, 0.08);
}

.pricing-pack-card.featured {
    border: 2px solid #2D5403;
    box-shadow: 0 12px 30px -4px rgba(45, 84, 3, 0.18);
    position: relative;
}

.pricing-pack-card.bulk-surge {
    border: 2px solid #0284c7;
    background: linear-gradient(180deg, #ffffff 0%, #f0f9ff 100%);
    box-shadow: 0 12px 30px -4px rgba(2, 132, 199, 0.18);
    position: relative;
}

.pricing-pack-card.bulk-surge:hover {
    transform: translateY(-4px);
    border-color: #0369a1;
    box-shadow: 0 18px 36px -6px rgba(2, 132, 199, 0.28);
}

.pricing-featured-ribbon {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #2D5403 0%, #047857 100%);
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 850;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 3px 14px;
    border-radius: 9999px;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(45, 84, 3, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.pricing-surge-ribbon {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    font-size: 0.70rem;
    font-weight: 850;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 3px 12px;
    border-radius: 9999px;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.pricing-pack-card.bulk-surge .pricing-credits-banner {
    background: #e0f2fe;
    border-color: #bae6fd;
    color: #0369a1;
}

/* Pricing Hero Assurance Badges */
.pricing-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: center;
    margin: 1.25rem auto 2.25rem auto;
    max-width: 900px;
}

.pricing-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.80rem;
    font-weight: 650;
    color: #334155;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.pricing-pill-badge:hover {
    border-color: #cbd5e1;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.06);
}

/* Modern SaaS Tier Badge Pills */
.pricing-tier-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.70rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.25rem 0.60rem;
    border-radius: 9999px;
    white-space: nowrap;
    line-height: 1.2;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
}

.pricing-tier-pill-teal {
    background: #f0fdfa;
    color: #2D5403;
    border: 1px solid #99f6e4;
}

.pricing-tier-pill-blue {
    background: #f0f9ff;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

.pricing-tier-pill-amber {
    background: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
}

.pricing-tier-pill-purple {
    background: #faf5ff;
    color: #7e22ce;
    border: 1px solid #e9d5ff;
}

.pricing-tier-pill-indigo {
    background: #eef2ff;
    color: #4338ca;
    border: 1px solid #c7d2fe;
}

.pricing-tier-pill-current {
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

.pricing-card-top {
    margin-bottom: 1.25rem;
}

.pricing-pack-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-headline);
    margin: 0 0 0.4rem 0;
    letter-spacing: -0.02em;
}

.pricing-price-wrapper {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    margin: 1rem 0 0.5rem 0;
    flex-wrap: wrap;
}

.pricing-main-price {
    font-size: 2.75rem;
    font-weight: 850;
    color: var(--text-headline);
    line-height: 1;
    font-family: var(--font-stack);
    letter-spacing: -0.03em;
}

.pricing-unit-pill {
    display: inline-flex;
    align-items: center;
    font-size: 0.78rem;
    font-weight: 750;
    color: #2D5403;
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    padding: 3px 8px;
    border-radius: 6px;
    font-family: ui-monospace, SFMono-Regular, monospace;
    letter-spacing: -0.01em;
}

.pricing-pack-card.bulk-surge .pricing-unit-pill {
    color: #0284c7;
    background: #f0f9ff;
    border-color: #bae6fd;
}

.pricing-credits-banner {
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    border-radius: 8px;
    padding: 0.6rem 0.85rem;
    margin: 0.85rem 0 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #115e59;
    font-weight: 750;
    font-size: 0.95rem;
}

.pricing-credits-icon {
    font-size: 1.15rem;
    line-height: 1;
}

.pricing-description {
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.5;
    min-height: 42px;
    margin-bottom: 1.25rem;
}

.pricing-feature-list {
    list-style: none;
    padding: 0;
    margin: 1.25rem 0 1.75rem 0;
    font-size: 0.88rem;
    line-height: 1.7;
    color: #334155;
    border-top: 1px solid #f1f5f9;
    padding-top: 1.25rem;
}

.pricing-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    margin-bottom: 0.45rem;
}

.pricing-check-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ecfdf5;
    color: #059669;
    border: 1px solid #a7f3d0;
    font-size: 0.72rem;
    font-weight: 850;
    flex-shrink: 0;
    margin-top: 2px;
}

.pricing-trust-matrix {
    margin-top: 3.5rem;
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 2.25rem 2rem;
    box-shadow: 0 4px 16px -2px rgba(15, 23, 42, 0.04);
}

.pricing-trust-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.75rem;
    margin-top: 1.5rem;
}

.pricing-trust-item {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
}

.pricing-trust-icon-box {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #f0fdfa;
    border: 1px solid #ccfbf1;
    color: #2D5403;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.pricing-trust-title {
    font-size: 0.95rem;
    font-weight: 750;
    color: var(--text-headline);
    margin: 0 0 0.25rem 0;
}

.pricing-trust-desc {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.45;
    margin: 0;
}

.pricing-faq-section {
    margin-top: 3.5rem;
    margin-bottom: 2.5rem;
}

.pricing-faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.pricing-faq-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.25rem 1.45rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.pricing-faq-q {
    font-size: 0.98rem;
    font-weight: 750;
    color: var(--text-headline);
    margin: 0 0 0.4rem 0;
}

.pricing-faq-a {
    font-size: 0.88rem;
    color: #475569;
    line-height: 1.55;
    margin: 0;
}

/* ==========================================================================
   Admin Sales & Executive Intelligence Styles
   ========================================================================== */
.space-y-8 > :not([hidden]) ~ :not([hidden]) {
    margin-top: 2rem;
}

.grid {
    display: grid;
}

.grid-cols-1 {
    grid-template-columns: repeat(1, minmax(0, 1fr));
}

@media (min-width: 640px) {
    .sm\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .sm\:text-4xl {
        font-size: 2.25rem;
        line-height: 2.5rem;
    }
}

@media (min-width: 768px) {
    .md\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .md\:flex-row {
        flex-direction: row;
    }
    .md\:items-center {
        align-items: center;
    }
    .md\:justify-between {
        justify-content: space-between;
    }
}

@media (min-width: 1024px) {
    .lg\:grid-cols-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
    .lg\:grid-cols-4 {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    .lg\:col-span-2 {
        grid-column: span 2 / span 2;
    }
}

.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-5 { gap: 1.25rem; }
.gap-6 { gap: 1.5rem; }

.bg-white { background-color: #ffffff; }
.bg-stone-50 { background-color: #fafaf9; }
.bg-stone-50\/50 { background-color: rgba(250, 250, 249, 0.5); }
.bg-stone-50\/75 { background-color: rgba(250, 250, 249, 0.75); }
.bg-stone-100 { background-color: #f5f5f4; }
.bg-stone-200 { background-color: #e7e5e4; }
.bg-stone-800 { background-color: #292524; }
.bg-stone-900 { background-color: #1c1917; }
.bg-teal-50 { background-color: #f0fdfa; }
.bg-teal-50\/30 { background-color: rgba(240, 253, 250, 0.3); }
.bg-teal-50\/50 { background-color: rgba(240, 253, 250, 0.5); }
.bg-teal-100 { background-color: #ccfbf1; }
.bg-teal-600 { background-color: #0d9488; }
.bg-emerald-50 { background-color: #ecfdf5; }
.bg-emerald-100 { background-color: #d1fae5; }
.bg-blue-50 { background-color: #eff6ff; }
.bg-purple-50 { background-color: #faf5ff; }
.bg-amber-100 { background-color: #fef3c7; }

.text-white { color: #ffffff; }
.text-stone-900 { color: #1c1917; }
.text-stone-800 { color: #292524; }
.text-stone-700 { color: #44403c; }
.text-stone-600 { color: #57534e; }
.text-stone-500 { color: #78716c; }
.text-stone-400 { color: #a8a29e; }
.text-teal-900 { color: #134e4a; }
.text-teal-800 { color: #115e59; }
.text-teal-700 { color: #2D5403; }
.text-teal-600 { color: #0d9488; }
.text-emerald-800 { color: #065f46; }
.text-emerald-700 { color: #047857; }
.text-blue-700 { color: #1d4ed8; }
.text-purple-700 { color: #7e22ce; }
.text-amber-800 { color: #92400e; }
.text-red-700 { color: #b91c1c; }

.border-stone-100 { border-color: #f5f5f4; }
.border-stone-200 { border-color: #e7e5e4; }
.border-teal-200 { border-color: #99f6e4; }
.border-emerald-200 { border-color: #a7f3d0; }
.border-amber-200 { border-color: #fde68a; }

.rounded { border-radius: 0.25rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }

.p-3 { padding: 0.75rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-12 { padding: 3rem; }

.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-2\.5 { padding-left: 0.625rem; padding-right: 0.625rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }

.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-3\.5 { padding-top: 0.875rem; padding-bottom: 0.875rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.pb-2 { padding-bottom: 0.5rem; }
.pb-4 { padding-bottom: 1rem; }
.pb-6 { padding-bottom: 1.5rem; }
.pt-4 { padding-top: 1rem; }

.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-\[11px\] { font-size: 11px; }

.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }
.font-serif { font-family: Georgia, Cambria, "Times New Roman", Times, serif; }

.shadow-sm { box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); }
.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }
.w-full { width: 100%; }
.whitespace-nowrap { white-space: nowrap; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-center { text-align: center; }

.divide-y > :not([hidden]) ~ :not([hidden]) {
    border-top-width: 1px;
    border-top-style: solid;
}
.divide-stone-100 > :not([hidden]) ~ :not([hidden]) {
    border-top-color: #f5f5f4;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: .5; }
}
.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* ==========================================================================
   How It Works & Landing Page Workflow Styles
   ========================================================================== */
.how-it-works-shell {
    margin-top: 3.5rem;
    margin-bottom: 3.5rem;
}

.workflow-grid-4 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-top: 1.75rem;
}

.step-card-editorial {
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 14px;
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.step-card-editorial:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.step-header-wrap {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1rem;
}

.step-badge-num {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #2D5403;
    color: #ffffff;
    font-weight: 850;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.step-title-editorial {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-headline);
    margin: 0;
    line-height: 1.3;
}

.step-desc-editorial {
    font-size: 0.95rem;
    color: var(--text-body);
    line-height: 1.55;
    margin: 0 0 1rem 0;
    flex-grow: 1;
}

.step-meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.3rem 0.65rem;
    border-radius: 6px;
    background: #f1f5f9;
    color: #334155;
    align-self: flex-start;
}

/* Channels Grid (Web, Watcher, API, CLI) */
.channels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.channel-card-editorial {
    background: #ffffff;
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.channel-card-icon {
    font-size: 1.75rem;
    margin-bottom: 0.75rem;
}

.channel-card-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--text-headline);
    margin: 0 0 0.4rem 0;
}

.channel-card-desc {
    font-size: 0.9rem;
    color: var(--text-body);
    line-height: 1.5;
    margin: 0;
}

/* Fidelity Guarantee Banner Card */
.fidelity-banner-card {
    background: linear-gradient(135deg, #022c22 0%, #064e3b 55%, #042f2e 100%);
    color: #ffffff;
    border: 1px solid rgba(110, 231, 183, 0.25);
    border-radius: 16px;
    padding: 2.25rem 2rem;
    margin-top: 2.5rem;
    box-shadow: 0 10px 25px -5px rgba(2, 44, 34, 0.4);
}

.fidelity-banner-card .fidelity-metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
    margin-top: 1.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 1.75rem;
}

.fidelity-banner-card .fidelity-metric-box {
    background: rgba(2, 44, 34, 0.6);
    border: 1px solid rgba(110, 231, 183, 0.3);
    border-radius: 12px;
    padding: 1.25rem;
    box-shadow: none;
    display: flex;
    flex-direction: column;
}

.fidelity-banner-card .fidelity-metric-val {
    font-size: 1.85rem;
    font-weight: 850;
    color: #a7f3d0;
    letter-spacing: -0.02em;
    line-height: 1.1;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.fidelity-banner-card .fidelity-metric-lbl {
    font-size: 0.85rem;
    color: #ffffff;
    margin-top: 0.45rem;
    font-weight: 700;
    line-height: 1.4;
}

/* Government Mandates Badge Strip */
.mandates-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.mandate-badge {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 0.5rem 0.85rem;
    font-size: 0.85rem;
    font-weight: 750;
    color: #1e293b;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.mandate-badge-seal {
    color: #2D5403;
    font-weight: 850;
}

/* Layout & Container Utilities for Compare View & Results */
.space-y-6 > * + * {
    margin-top: 1.5rem;
}

.overflow-x-auto {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
}

.compare-page-header {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 1rem;
}

@media (min-width: 640px) {
    .compare-page-header {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

/* ==========================================
   Accessible Modal & Waiting State Animations
   ========================================== */

/* Modal Backdrop */
.modal-backdrop-wb {
    position: fixed;
    inset: 0;
    background-color: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-backdrop-wb.active {
    opacity: 1;
    pointer-events: auto;
}

/* Modal Window */
.modal-card-wb {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25), 0 0 0 1px rgba(15, 23, 42, 0.08);
    max-width: 540px;
    width: 100%;
    overflow: hidden;
    transform: translateY(12px) scale(0.98);
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    border-top: 4px solid var(--teal-brand);
}

.modal-backdrop-wb.active .modal-card-wb {
    transform: translateY(0) scale(1);
}

.modal-header-wb {
    padding: 1.5rem 1.75rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.modal-title-wb {
    font-size: 1.35rem;
    font-weight: 850;
    color: var(--text-headline);
    letter-spacing: -0.02em;
    margin: 0;
}

.modal-close-btn {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    transition: all 0.15s ease;
}

.modal-close-btn:hover, .modal-close-btn:focus {
    color: var(--text-headline);
    background: #f1f5f9;
}

.modal-body-wb {
    padding: 1.5rem 1.75rem;
}

.modal-footer-wb {
    padding: 1.25rem 1.75rem;
    background: #f8fafc;
    border-top: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.85rem;
}

/* Balance Breakdown Table / Card in Modal */
.unlock-summary-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
}

.unlock-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    font-size: 0.95rem;
}

.unlock-summary-row:not(:last-child) {
    border-bottom: 1px dashed #cbd5e1;
}

.unlock-summary-row.highlight-deduction {
    color: #2D5403;
    font-weight: 750;
    font-size: 1.05rem;
}

.unlock-balance-calc {
    background: #f0fdfa;
    border: 1px solid #99f6e4;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    margin-top: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.92rem;
    color: #2D5403;
    font-weight: 650;
}

/* Processing Overlay (For large files) */
.processing-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    animation: fadeInOverlay 0.25s ease-out;
}

.processing-overlay.active {
    display: flex;
}

.processing-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.3);
    max-width: 520px;
    width: 100%;
    padding: 2.25rem 2rem;
    text-align: center;
    border-top: 5px solid var(--teal-brand);
}

.processing-spinner-ring {
    display: inline-block;
    width: 64px;
    height: 64px;
    border: 5px solid #ccfbf1;
    border-radius: 50%;
    border-top-color: var(--teal-brand);
    animation: spinRing 0.9s cubic-bezier(0.55, 0.15, 0.45, 0.85) infinite;
    margin-bottom: 1.25rem;
}

.processing-heading {
    font-size: 1.4rem;
    font-weight: 850;
    color: var(--text-headline);
    margin: 0 0 0.5rem;
    letter-spacing: -0.02em;
}

.processing-subtext {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin: 0 0 1.5rem;
    line-height: 1.5;
}

/* Animated Progress Bar */
.animated-progress-track {
    background: #e2e8f0;
    border-radius: 9999px;
    height: 8px;
    overflow: hidden;
    position: relative;
    margin-bottom: 1.5rem;
}

.animated-progress-bar {
    position: absolute;
    height: 100%;
    width: 45%;
    background: linear-gradient(90deg, #0d9488, #14b8a6, #2dd4bf);
    border-radius: 9999px;
    animation: indeterminateProgress 1.8s infinite ease-in-out;
}

.animated-progress-bar.determinate {
    animation: none;
    left: 0;
    transition: width 0.15s ease-out;
}

/* Stepper Checklist in Processing Overlay */
.processing-steps-list {
    text-align: left;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0.85rem 1.15rem;
    margin: 0 0 1.25rem;
    list-style: none;
}

.processing-step-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.88rem;
    padding: 0.35rem 0;
    color: #64748b;
    transition: color 0.3s ease;
}

.processing-step-item.active {
    color: #2D5403;
    font-weight: 700;
}

.processing-step-item.done {
    color: #166534;
}

.processing-step-bullet {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 750;
    background: #e2e8f0;
    color: #64748b;
    flex-shrink: 0;
}

.processing-step-item.active .processing-step-bullet {
    background: #ccfbf1;
    color: #2D5403;
    animation: pulseBullet 1.2s infinite;
}

.processing-step-item.done .processing-step-bullet {
    background: #dcfce7;
    color: #166534;
}

.processing-large-file-hint {
    background: #fffbeb;
    border: 1px solid #fef3c7;
    border-radius: 8px;
    padding: 0.65rem 0.85rem;
    font-size: 0.82rem;
    color: #92400e;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-align: left;
}

@keyframes spinRing {
    to { transform: rotate(360deg); }
}

@keyframes indeterminateProgress {
    0% { left: -45%; width: 45%; }
    50% { left: 25%; width: 60%; }
    100% { left: 100%; width: 45%; }
}

@keyframes pulseBullet {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

@keyframes fadeInOverlay {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ==========================================================================
   Bootstrap-Style Form Controls & Input Padding (Editorial ADA Design)
   ========================================================================== */
.form-control {
    display: block;
    width: 100%;
    padding: 0.55rem 0.85rem;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.5;
    color: #1c1917;
    background-color: #ffffff;
    background-clip: padding-box;
    border: 1px solid #d6d3d1;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    border-radius: 0.5rem;
    box-sizing: border-box;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, background-color 0.15s ease-in-out;
}

.form-control:focus {
    color: #1c1917;
    background-color: #ffffff;
    border-color: #2D5403;
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(45, 84, 3, 0.18);
}

.form-control::placeholder {
    color: #a8a29e;
    opacity: 1;
}

.form-control:disabled,
.form-control[readonly] {
    background-color: #f5f5f4;
    color: #78716c;
    border-color: #e7e5e4;
    opacity: 1;
    cursor: default;
}

.form-control.font-mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.82rem;
}

.form-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #44403c;
    margin-bottom: 0.375rem;
}

.p-2\.5 { padding: 0.625rem; }
.px-3\.5 { padding-left: 0.875rem; padding-right: 0.875rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }

/* ==========================================================================
   Cookie & Privacy Consent Banner (WCAG 2.2 AAA & GDPR / ePrivacy Compliant)
   ========================================================================== */
.cookie-consent-banner {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 3rem);
    max-width: 1040px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.16), 0 4px 12px rgba(15, 23, 42, 0.08);
    z-index: 99999;
    padding: 1.25rem 1.75rem;
    animation: consentSlideUpFade 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes consentSlideUpFade {
    from {
        opacity: 0;
        transform: translate(-50%, 20px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.cookie-consent-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.75rem;
    flex-wrap: wrap;
}

.cookie-consent-content {
    flex: 1 1 540px;
}

.cookie-consent-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}

.cookie-consent-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
}

.cookie-consent-text {
    font-size: 0.88rem;
    line-height: 1.55;
    color: #334155;
    margin: 0;
}

.cookie-consent-link {
    color: var(--teal-brand, #0d9488);
    text-decoration: underline;
    font-weight: 600;
}

.cookie-consent-link:hover,
.cookie-consent-link:focus-visible {
    color: var(--teal-dark, #2D5403);
}

.cookie-consent-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.cookie-btn {
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    min-height: 44px;
    padding: 0.6rem 1.25rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.cookie-btn:focus-visible {
    outline: 3px solid #0284c7;
    outline-offset: 2px;
}

.cookie-btn-primary {
    background: #0f172a;
    color: #ffffff;
    border: 1px solid #0f172a;
}

.cookie-btn-primary:hover {
    background: #1e293b;
    border-color: #1e293b;
}

.cookie-btn-secondary {
    background: #f8fafc;
    color: #334155;
    border: 1px solid #cbd5e1;
}

.cookie-btn-secondary:hover {
    background: #f1f5f9;
    color: #0f172a;
    border-color: #94a3b8;
}

@media (max-width: 768px) {
    .cookie-consent-banner {
        bottom: 1rem;
        left: 1rem;
        transform: none;
        width: calc(100% - 2rem);
        padding: 1rem;
    }

    @keyframes consentSlideUpFade {
        from {
            opacity: 0;
            transform: translateY(20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .cookie-consent-inner {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .cookie-consent-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .cookie-btn {
        flex: 1;
        text-align: center;
    }
}

