/*
 * vulnops-assessment.css
 * Scoped styles for the VulnOps Maturity Assessment tool.
 * Prefixed "va-" to avoid collisions with style.css.
 * Color palette matches the existing site:
 *   Primary:   #4f46e5 / #7c3aed  (indigo/purple)
 *   Green:     #4ade80
 *   Navy:      #0f0f23 / #1e293b / #0f172a
 *   Muted:     #94a3b8 / #64748b / #cbd5e1
 */

/* ─── HERO ─── */
.va-hero {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a3e 50%, #2a2a5e 100%);
    overflow: hidden;
    padding: 5rem 0 4rem;
}

.va-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.07)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.4;
}

.va-hero-inner {
    max-width: 680px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 2;
}

.va-eyebrow {
    display: inline-block;
    margin-bottom: 1.25rem;
    padding: 0.35rem 1rem;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.15);
    border: 1px solid rgba(79, 70, 229, 0.3);
    font-size: 0.75rem;
    font-weight: 600;
    color: #a5b4fc;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.va-hero-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    color: #ffffff;
    margin-bottom: 1.25rem;
}

.va-gradient-text {
    font-style: normal;
    background: linear-gradient(135deg, #ffffff 0%, #a5b4fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.va-hero-sub {
    font-size: 1.1rem;
    color: #cbd5e1;
    max-width: 560px;
    margin: 0 auto 1rem;
    line-height: 1.7;
}

.va-hero-note {
    font-size: 0.82rem;
    color: #64748b;
    font-style: italic;
    margin-bottom: 2rem;
}

.va-hero-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.va-meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    color: #94a3b8;
}

.va-meta-icon {
    font-size: 1rem;
}

/* ─── ASSESSMENT CONTAINER ─── */
.va-container {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ─── PROGRESS BAR ─── */
.va-progress-wrap {
    padding: 2rem 0 0;
}

.va-progress-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
}

.va-progress-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
    overflow: hidden;
}

.va-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4f46e5, #7c3aed);
    border-radius: 2px;
    transition: width 0.4s ease;
}

/* ─── QUESTION CARDS ─── */
.va-question-section {
    padding: 2.5rem 0 4rem;
}

.va-question-dim {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #a5b4fc;
    margin-bottom: 0.6rem;
}

.va-question-text {
    font-size: clamp(1.25rem, 2.5vw, 1.6rem);
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 2rem;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.va-options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.va-option {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    width: 100%;
}

.va-option:hover {
    border-color: rgba(79, 70, 229, 0.5);
    background: rgba(79, 70, 229, 0.08);
    transform: translateY(-1px);
}

.va-option.va-selected {
    border-color: #4f46e5;
    background: rgba(79, 70, 229, 0.12);
}

.va-option-radio {
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.25);
    margin-top: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.va-option.va-selected .va-option-radio {
    border-color: #4f46e5;
    background: #4f46e5;
}

.va-option.va-selected .va-option-radio::after {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ffffff;
}

.va-option-content {
    flex: 1;
}

.va-option-level {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.3rem;
}

.va-option.va-selected .va-option-level {
    color: #a5b4fc;
}

.va-option-text {
    font-size: 0.92rem;
    color: #cbd5e1;
    line-height: 1.6;
}

.va-option.va-selected .va-option-text {
    color: #e2e8f0;
}

/* ─── NAVIGATION ─── */
.va-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.va-nav-back {
    background: none;
    border: none;
    color: #64748b;
    font-size: 0.88rem;
    cursor: pointer;
    padding: 0.5rem 0;
    font-family: 'Inter', sans-serif;
    transition: color 0.2s;
}

.va-nav-back:hover {
    color: #cbd5e1;
}

.va-nav-back:disabled {
    opacity: 0;
    pointer-events: none;
}

/* ─── RESULTS ─── */
.va-results {
    padding: 3rem 0 5rem;
}

.va-results-header {
    text-align: center;
    margin-bottom: 3rem;
}

.va-maturity-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    border-radius: 999px;
    margin-bottom: 1.25rem;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.va-maturity-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.va-results-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.va-results-subtitle {
    font-size: 0.92rem;
    color: #64748b;
}

/* ─── RESULTS GRID ─── */
.va-results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.va-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 1.75rem;
}

.va-card-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 1.25rem;
}

/* ─── RADAR CHART ─── */
.va-radar-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
}

.va-radar-wrap svg {
    max-width: 300px;
    width: 100%;
}

/* ─── DIMENSION BARS ─── */
.va-dim-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.va-dim-row {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.va-dim-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.va-dim-name {
    font-size: 0.82rem;
    color: #e2e8f0;
    font-weight: 500;
}

.va-dim-tag {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
}

.va-dim-tag-weak {
    color: #f87171;
    background: rgba(239, 68, 68, 0.15);
}

.va-dim-tag-strong {
    color: #4ade80;
    background: rgba(74, 222, 128, 0.15);
}

.va-dim-score {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 500;
}

.va-dim-track {
    height: 5px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    overflow: hidden;
}

.va-dim-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.8s ease;
}

.va-dim-fill-default {
    background: linear-gradient(90deg, #4f46e5, #7c3aed);
}

.va-dim-fill-weak {
    background: linear-gradient(90deg, #ef4444, #f87171);
}

.va-dim-fill-strong {
    background: linear-gradient(90deg, #22c55e, #4ade80);
}

/* ─── FULL WIDTH CARDS ─── */
.va-card-full {
    grid-column: 1 / -1;
}

.va-summary-text {
    font-size: 1rem;
    color: #cbd5e1;
    line-height: 1.75;
}

/* ─── RECOMMENDATIONS ─── */
.va-recs {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.va-rec-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.va-rec-num {
    min-width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(79, 70, 229, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #a5b4fc;
    flex-shrink: 0;
}

.va-rec-text {
    font-size: 0.92rem;
    color: #cbd5e1;
    line-height: 1.65;
}

/* ─── PRIORITY GAP ─── */
.va-gap-card {
    background: rgba(239, 68, 68, 0.06);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.va-gap-card .va-card-label {
    color: #f87171;
}

.va-gap-title {
    font-size: 0.92rem;
    color: #e2e8f0;
    line-height: 1.65;
    margin-bottom: 1rem;
}

.va-gap-next {
    font-size: 0.88rem;
    color: #94a3b8;
    line-height: 1.6;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border-left: 3px solid rgba(239, 68, 68, 0.4);
}

.va-gap-next strong {
    color: #e2e8f0;
    font-weight: 600;
}

/* ─── FOOTER ATTRIBUTION ─── */
.va-attribution {
    text-align: center;
    padding: 2.5rem 0 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    margin-top: 1rem;
}

.va-attr-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.va-attr-text {
    font-size: 0.82rem;
    color: #94a3b8;
}

.va-attr-link {
    font-size: 0.82rem;
    color: #a5b4fc;
    text-decoration: none;
    margin-top: 0.5rem;
    display: inline-block;
}

.va-attr-link:hover {
    color: #c7d2fe;
}

/* ─── START BUTTON ─── */
.va-start-btn {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 1rem 2.5rem;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.3);
}

.va-start-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(79, 70, 229, 0.4);
}

/* ─── RESET BUTTON ─── */
.va-reset-btn {
    background: rgba(255, 255, 255, 0.06);
    color: #94a3b8;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.5rem 1.25rem;
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.va-reset-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
}

/* ─── ANIMATION ─── */
.va-fade-in {
    animation: vaFadeIn 0.3s ease forwards;
}

@keyframes vaFadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
    .va-results-grid {
        grid-template-columns: 1fr;
    }

    .va-hero {
        padding: 3rem 0 2.5rem;
    }

    .va-hero-meta {
        flex-direction: column;
        gap: 0.5rem;
    }

    .va-option {
        padding: 1rem 1.25rem;
    }
}

/* ─── CTA CARD ─── */
.va-cta-card {
    margin-top: 1.5rem;
    padding: 2rem 2.25rem;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.12) 0%, rgba(124, 58, 237, 0.08) 100%);
    border: 1px solid rgba(79, 70, 229, 0.25);
    border-left: 4px solid #4f46e5;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.va-cta-text {
    flex: 1;
    min-width: 260px;
    font-size: 0.9rem;
    color: #cbd5e1;
    line-height: 1.65;
    margin: 0;
}

.va-cta-btn {
    display: inline-block;
    flex-shrink: 0;
    padding: 0.65rem 1.4rem;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 8px;
    text-decoration: none;
    white-space: nowrap;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.va-cta-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* ─── PRINT BUTTON ─── */
.va-results-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.va-print-btn {
    background: rgba(79, 70, 229, 0.15);
    color: #a5b4fc;
    border: 1px solid rgba(79, 70, 229, 0.4);
    border-radius: 8px;
    padding: 0.5rem 1.25rem;
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.va-print-btn:hover {
    background: rgba(79, 70, 229, 0.3);
    color: #c7d2fe;
}

/* ─── PRINT / PDF ─── */
@media print {
    /* Hide everything except the results */
    .site-nav,
    .site-footer,
    .va-hero,
    #va-progress,
    #va-question-area,
    .va-results-actions,
    .va-reset-btn,
    .va-print-btn {
        display: none !important;
    }

    /* Page setup */
    @page {
        margin: 1cm 1.2cm;
        size: A4 portrait;
    }

    /* Preserve dark theme */
    html, body {
        background: #0f0f23 !important;
        color: #e2e8f0 !important;
        font-family: 'Inter', Arial, sans-serif;
        font-size: 10pt;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    section {
        background: linear-gradient(135deg, #0f0f23 0%, #1a1a3e 100%) !important;
        min-height: 0 !important;
    }

    /* Results container */
    #va-results-area {
        display: block !important;
    }

    .va-results {
        padding: 0;
    }

    /* Results header */
    .va-results-header {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        padding-bottom: 0.75rem;
        margin-bottom: 1rem;
        text-align: center;
    }

    .va-results-title {
        font-size: 16pt;
        color: #f1f5f9 !important;
        margin: 0.4rem 0 0.2rem;
        font-weight: 800;
    }

    .va-results-subtitle {
        font-size: 9pt;
        color: #94a3b8 !important;
    }

    /* Maturity badge — keep color */
    .va-maturity-badge {
        display: inline-flex;
        align-items: center;
        gap: 0.4rem;
        padding: 0.25rem 0.75rem;
        border-radius: 999px;
        font-size: 8pt;
        font-weight: 600;
    }

    /* Grid — 2-column for radar + scores, full-width for the rest */
    .va-results-grid {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 0.6rem;
    }

    /* Cards */
    .va-card {
        background: rgba(255, 255, 255, 0.04) !important;
        border: 1px solid rgba(255, 255, 255, 0.08) !important;
        border-radius: 8px;
        padding: 0.85rem 1rem;
        margin-bottom: 0;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .va-card-full {
        grid-column: 1 / -1;
    }

    .va-card-label {
        font-size: 6.5pt;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        color: #64748b !important;
        font-weight: 700;
        margin-bottom: 0.5rem;
    }

    /* Radar — keep SVG colors, size to fit column */
    .va-radar-wrap svg {
        max-width: 200px;
        width: 100%;
        display: block;
        margin: 0 auto;
    }

    /* Dimension score bars */
    .va-dim-list {
        gap: 0.4rem;
    }

    .va-dim-row {
        margin-bottom: 0.35rem;
    }

    .va-dim-name {
        font-size: 8pt;
        color: #e2e8f0 !important;
    }

    .va-dim-score {
        font-size: 8pt;
        color: #64748b !important;
    }

    .va-dim-track {
        background: rgba(255, 255, 255, 0.08) !important;
        border-radius: 3px;
        height: 5px;
        margin-top: 3px;
    }

    .va-dim-fill {
        height: 5px;
        border-radius: 3px;
    }

    .va-dim-fill-default { background: linear-gradient(90deg, #4f46e5, #7c3aed) !important; }
    .va-dim-fill-weak    { background: linear-gradient(90deg, #ef4444, #f87171) !important; }
    .va-dim-fill-strong  { background: linear-gradient(90deg, #22c55e, #4ade80) !important; }

    .va-dim-tag {
        font-size: 6.5pt;
        padding: 0.1rem 0.35rem;
        border-radius: 4px;
    }

    .va-dim-tag-weak   { background: rgba(239, 68, 68, 0.15) !important; color: #f87171 !important; }
    .va-dim-tag-strong { background: rgba(74, 222, 128, 0.15) !important; color: #4ade80 !important; }

    /* Summary and recs */
    .va-summary-text {
        font-size: 9pt;
        color: #cbd5e1 !important;
        line-height: 1.55;
        margin: 0;
    }

    .va-recs {
        display: flex;
        flex-direction: column;
        gap: 0.45rem;
    }

    .va-rec-item {
        display: flex;
        gap: 0.6rem;
        align-items: flex-start;
    }

    .va-rec-num {
        background: #4f46e5 !important;
        color: #fff !important;
        min-width: 18px;
        height: 18px;
        border-radius: 50%;
        font-size: 7.5pt;
        font-weight: 700;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
    }

    .va-rec-text {
        font-size: 9pt;
        color: #cbd5e1 !important;
        line-height: 1.5;
        margin: 0;
    }

    /* Gap card */
    .va-gap-card {
        border-left: 3px solid #ef4444 !important;
    }

    .va-gap-card .va-card-label {
        color: #f87171 !important;
    }

    .va-gap-title {
        font-size: 9pt;
        color: #cbd5e1 !important;
        margin: 0 0 0.5rem;
    }

    .va-gap-next {
        font-size: 8.5pt;
        color: #94a3b8 !important;
        margin-top: 0.4rem;
        padding: 0.5rem 0.75rem;
        background: rgba(239, 68, 68, 0.06) !important;
        border-left: 2px solid rgba(239, 68, 68, 0.3);
        border-radius: 0 6px 6px 0;
    }

    /* CTA card */
    .va-cta-card {
        margin-top: 0.75rem;
        padding: 1rem 1.25rem;
        background: rgba(79, 70, 229, 0.08) !important;
        border: 1px solid rgba(79, 70, 229, 0.2) !important;
        border-left: 3px solid #4f46e5 !important;
        border-radius: 8px;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .va-cta-text {
        font-size: 8.5pt;
        color: #94a3b8 !important;
        min-width: 0;
    }

    .va-cta-btn {
        font-size: 8pt;
        padding: 0.4rem 0.9rem;
        background: #4f46e5 !important;
        color: #fff !important;
        border-radius: 6px;
    }

    /* Attribution */
    .va-attribution {
        margin-top: 1rem;
        padding-top: 0.6rem;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        text-align: center;
    }

    .va-attr-label {
        font-size: 7.5pt;
        font-weight: 700;
        color: #475569 !important;
        text-transform: uppercase;
        letter-spacing: 0.06em;
    }

    .va-attr-text {
        font-size: 7.5pt;
        color: #475569 !important;
    }

    .va-attr-link {
        font-size: 7.5pt;
        color: #7c3aed !important;
    }
}

