* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --background: #f8fafc;
    --card-background: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: radial-gradient(circle at 20% -10%, #e0f2ff, #f8fafc 45%, #eef2ff 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: clamp(16px, 3vw, 36px);
}

.incident-layout {
    display: grid;
    grid-template-columns: minmax(0, 520px) minmax(0, 1fr);
    gap: 28px;
    align-items: flex-start;
    margin-top: 40px;
}

@media (max-width: 1200px) {
    .incident-layout {
        grid-template-columns: 1fr;
    }
}

.panel {
    background: rgba(255, 255, 255, 0.92);
    border-radius: 28px;
    padding: 32px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    box-shadow: 0 25px 60px -40px rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(8px);
}

form.form-panel {
    display: flex;
    flex-direction: column;
    gap: 24px;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    backdrop-filter: none;
}

.results-panel {
    position: sticky;
    top: 32px;
    align-self: start;
    transition: box-shadow 0.3s ease;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    backdrop-filter: none;
}

@media (max-width: 1024px) {
    .results-panel {
        position: relative;
        top: auto;
    }
}

/* Navigation tabs */
.nav-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border-color);
}

.nav-tab {
    padding: 12px 24px;
    text-decoration: none;
    color: var(--text-secondary);
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
    font-weight: 500;
}

.nav-tab:hover {
    color: var(--primary-color);
    background-color: rgba(37, 99, 235, 0.05);
}

.nav-tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

header, .header {
    text-align: center;
    padding: 48px 32px;
    background: linear-gradient(135deg, #1d4ed8, #0f172a);
    color: white;
    border-radius: 28px;
    margin-bottom: 30px;
    box-shadow: 0 30px 70px -40px rgba(15, 23, 42, 0.8);
    position: relative;
    overflow: hidden;
}

header h1, .header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
}

.hero-metrics {
    margin-top: 28px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 18px;
}

.hero-metric {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 18px;
    padding: 18px;
    text-align: left;
}

.hero-icon {
    font-size: 1.4rem;
    display: block;
    margin-bottom: 6px;
}

.hero-label {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.85;
}

.hero-value {
    display: block;
    font-size: 1.8rem;
    font-weight: 800;
    margin: 6px 0;
}

.hero-metric small {
    font-size: 0.8rem;
    opacity: 0.8;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 30px;
}

@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
}

.form-section, .results-section {
    background: var(--card-background);
    padding: 30px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.card {
    background: rgba(248, 250, 252, 0.98);
    border-radius: 22px;
    padding: 26px;
    border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 0 20px 45px -35px rgba(15, 23, 42, 0.6);
    margin-bottom: 20px;
}

.card h2 {
    font-size: 1.3rem;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card.highlight {
    background: linear-gradient(135deg, #0f172a, #1d4ed8);
    color: white;
    border: none;
    box-shadow: 0 30px 60px -40px rgba(15, 23, 42, 0.7);
}

.privacy-card {
    position: relative;
    overflow: hidden;
}

.privacy-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px;
    border: 1px dashed rgba(37, 99, 235, 0.4);
    border-radius: 16px;
    margin-bottom: 18px;
    background: rgba(37, 99, 235, 0.05);
}

.privacy-label {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 56px;
    height: 30px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5f5;
    transition: .3s;
    border-radius: 999px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 24px;
    width: 24px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(15, 23, 42, 0.2);
}

.switch input:checked + .slider {
    background-color: var(--primary-color);
}

.switch input:checked + .slider:before {
    transform: translateX(26px);
}

.rgpd-impact-section {
    border: 1px solid rgba(148, 163, 184, 0.4);
    border-radius: 18px;
    padding: 18px;
    transition: opacity 0.2s ease;
}

.rgpd-impact-section.disabled {
    opacity: 0.4;
    pointer-events: none;
}

.impact-help {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.rgpd-impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.impact-option input {
    display: none;
}

.impact-option {
    display: block;
}

.impact-card {
    border: 2px solid rgba(148, 163, 184, 0.6);
    border-radius: 16px;
    padding: 16px;
    background: white;
    min-height: 90px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: all 0.2s ease;
}

.impact-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.impact-card small {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.impact-option input:checked + .impact-card {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(59, 130, 246, 0.15));
    box-shadow: 0 8px 20px -12px rgba(37, 99, 235, 0.7);
}

.privacy-alert {
    margin-top: 16px;
    padding: 18px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 16px;
    background: rgba(219, 234, 254, 0.5);
}

.privacy-alert h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 1rem;
}

.privacy-alert ul {
    list-style: none;
    padding-left: 0;
    margin: 8px 0 0;
}

.privacy-alert li {
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding: 4px 0;
}

.interruption-section {
    margin-bottom: 25px;
}

/* Service interruption matrix */
.service-matrix {
    display: flex;
    flex-direction: column;
    gap: 12px;
    overflow-x: auto;
}

.matrix-row.standalone {
    grid-template-columns: 1fr;
}

.matrix-row.standalone .matrix-cell {
    justify-content: center;
    text-align: center;
}

.matrix-row {
    display: grid;
    grid-template-columns: 170px repeat(4, minmax(140px, 1fr));
    gap: 10px;
}

.matrix-header .matrix-cell {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    cursor: default;
    box-shadow: none;
    min-height: auto;
}

.matrix-label {
    background: rgba(148, 163, 184, 0.1);
    border-radius: 14px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.matrix-label small {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.matrix-cell {
    border: 2px solid rgba(148, 163, 184, 0.4);
    border-radius: 16px;
    padding: 14px 16px;
    background: white;
    text-align: left;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: all 0.2s ease;
    font-weight: 600;
    min-height: 90px;
}

.matrix-cell small {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
}

.matrix-cell:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px -12px rgba(15, 23, 42, 0.4);
}

.matrix-cell.active {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(59, 130, 246, 0.2));
    box-shadow: 0 10px 25px -20px rgba(15, 23, 42, 0.65);
}

@media (max-width: 720px) {
    .matrix-row {
        grid-template-columns: 150px repeat(4, minmax(120px, 1fr));
    }
}

.methodology-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.methodology-item {
    background: var(--background);
    border-radius: 14px;
    padding: 16px;
    border-left: 4px solid var(--primary-color);
    box-shadow: var(--shadow);
}

.methodology-item h4 {
    margin-bottom: 8px;
    font-size: 1rem;
}

.methodology-item p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.sources-list h4 {
    margin-bottom: 10px;
    font-size: 1rem;
}

.sources-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sources-list li {
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding-left: 18px;
    position: relative;
}

.sources-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

.form-section h2, .results-section h2 {
    margin-bottom: 25px;
    color: var(--text-primary);
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.section-label {
    font-size: 1rem;
    margin-bottom: 12px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    padding: 10px;
    background: var(--background);
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s;
}

.checkbox-label:hover {
    background: #e2e8f0;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
    cursor: pointer;
}

/* ANSSI control categories */
.controls-category {
    margin-bottom: 20px;
    background: white;
    border-radius: 8px;
    padding: 15px;
    border-left: 4px solid var(--primary-color);
}

.category-header {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--border-color);
}

.checkbox-label.priority-critical {
    background: #fee2e2;
    border-left: 3px solid #dc2626;
}

.checkbox-label.priority-high {
    background: #fef3c7;
    border-left: 3px solid #f59e0b;
}

.checkbox-label.priority-medium {
    background: #dbeafe;
    border-left: 3px solid #3b82f6;
}

.checkbox-label.priority-low {
    background: #f3f4f6;
    border-left: 3px solid #9ca3af;
}

.btn-primary {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 18px 30px -18px rgba(37, 99, 235, 0.7);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 20px 40px -18px rgba(59, 130, 246, 0.8);
}

.btn-primary:active {
    transform: translateY(0);
}

.risk-score-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 25px;
}

.score-label {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 10px;
}

.score-value {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.score-level {
    font-size: 1.2rem;
    font-weight: 600;
}

.anssi-badge {
    margin-top: 15px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

@media (max-width: 768px) {
    .metrics-grid {
        grid-template-columns: 1fr;
    }
}

.metric-card {
    background: var(--background);
    padding: 20px;
    border-radius: 10px;
    border-left: 4px solid var(--primary-color);
}

.metric-card.highlight {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-left-color: var(--warning-color);
}

.metric-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-weight: 600;
}

.metric-value {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.metric-value.positive {
    color: var(--secondary-color);
}

.metric-detail {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.chart-container {
    background: var(--background);
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 25px;
}

.chart-container h3 {
    margin-bottom: 20px;
    color: var(--text-primary);
}

.recommendations {
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
    padding: 25px;
    border-radius: 10px;
    border-left: 4px solid var(--primary-color);
}

.recommendations h3 {
    margin-bottom: 15px;
    color: var(--text-primary);
}

.recommendations ul {
    list-style: none;
    padding: 0;
}

.recommendations li {
    padding: 10px;
    margin-bottom: 8px;
    background: white;
    border-radius: 6px;
    box-shadow: var(--shadow);
}

.recommendations li::before {
    content: "✓ ";
    color: var(--secondary-color);
    font-weight: bold;
    margin-right: 8px;
}

footer {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 40px;
}

/* Loading state */
.btn-primary.loading {
    background: var(--text-secondary);
    cursor: not-allowed;
}

.btn-primary.loading::after {
    content: " ...";
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: " ."; }
    40% { content: " .."; }
    60%, 100% { content: " ..."; }
}

/* ========================================
   INCIDENT IMPACT CALCULATOR STYLES
   ======================================== */

/* Severity selector */
.severity-selector {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.severity-option input[type="radio"] {
    display: none;
}

.severity-card {
    padding: 20px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
}

.severity-option input[type="radio"]:checked + .severity-card {
    border-width: 3px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.severity-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.severity-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.severity-icon {
    font-size: 1.5rem;
}

.severity-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.severity-description {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.severity-examples {
    list-style: none;
    padding: 0;
    margin: 10px 0;
    font-size: 0.85rem;
}

.severity-examples li {
    padding: 5px 0;
    padding-left: 20px;
    position: relative;
}

.severity-examples li::before {
    content: "•";
    position: absolute;
    left: 5px;
}

.severity-stats {
    display: flex;
    gap: 15px;
    font-size: 0.75rem;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
}

/* Severity colors */
.severity-low {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border-color: #10b981;
}

.severity-option input[type="radio"]:checked + .severity-low {
    border-color: #059669;
}

.severity-medium {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #f59e0b;
}

.severity-option input[type="radio"]:checked + .severity-medium {
    border-color: #d97706;
}

.severity-high {
    background: linear-gradient(135deg, #fed7aa, #fdba74);
    border-color: #f97316;
}

.severity-option input[type="radio"]:checked + .severity-high {
    border-color: #ea580c;
}

.severity-extreme {
    background: linear-gradient(135deg, #fecaca, #fca5a5);
    border-color: #ef4444;
}

.severity-option input[type="radio"]:checked + .severity-extreme {
    border-color: #dc2626;
}

/* Comparison grid */
.comparison-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: center;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .comparison-grid {
        grid-template-columns: 1fr;
    }

    .comparison-arrow {
        transform: rotate(90deg);
    }
}

.comparison-box {
    padding: 30px;
    border-radius: 12px;
    text-align: center;
}

.comparison-box.without-plan {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    border: 2px solid #ef4444;
}

.comparison-box.with-plan {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border: 2px solid #10b981;
}

.comparison-box h3 {
    font-size: 1rem;
    margin-bottom: 15px;
    color: var(--text-secondary);
}

.big-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.comparison-box .label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.comparison-arrow {
    text-align: center;
    padding: 20px;
}

.arrow {
    font-size: 3rem;
    color: var(--secondary-color);
    font-weight: bold;
}

.savings-badge {
    margin-top: 10px;
    padding: 12px 20px;
    background: var(--secondary-color);
    color: white;
    border-radius: 20px;
    font-weight: 700;
}

.savings-badge small {
    display: block;
    font-size: 0.85rem;
    margin-top: 5px;
}

/* Info grid */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.info-box {
    padding: 15px;
    background: var(--background);
    border-radius: 8px;
    text-align: center;
}

.info-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.info-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.severity-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 1rem;
}

.severity-badge.severity-low {
    background: #10b981;
    color: white;
}

.severity-badge.severity-medium {
    background: #f59e0b;
    color: white;
}

.severity-badge.severity-high {
    background: #f97316;
    color: white;
}

.severity-badge.severity-extreme {
    background: #ef4444;
    color: white;
}

.examples-section {
    margin-top: 20px;
    padding: 20px;
    background: var(--background);
    border-radius: 8px;
}

.examples-section h3 {
    font-size: 1rem;
    margin-bottom: 10px;
}

.examples-section ul {
    list-style: none;
    padding: 0;
}

.examples-section li {
    padding: 8px 0;
    padding-left: 25px;
    position: relative;
}

.examples-section li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

/* Cost table */
.cost-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.cost-table th,
.cost-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.cost-table th {
    background: var(--background);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.cost-table tbody tr:hover {
    background: var(--background);
}

.cost-cell {
    text-align: right;
    font-weight: 600;
}

.savings-cell {
    text-align: right;
    color: var(--secondary-color);
    font-weight: 700;
}

.savings-cell small {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
}

.total-row {
    background: var(--background);
    font-size: 1.1rem;
}

.total-row td {
    padding: 15px 12px;
    border-top: 2px solid var(--border-color);
}

/* Response time */
.response-time-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.time-box {
    padding: 20px;
    background: var(--background);
    border-radius: 10px;
    text-align: center;
    border-left: 4px solid var(--primary-color);
}

.time-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.time-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.time-box small {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.time-note {
    padding: 15px;
    background: var(--background);
    border-radius: 8px;
    border-left: 4px solid var(--warning-color);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* New option-based input styles */
.input-section {
    margin-bottom: 25px;
}

.input-label {
    display: block;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.option-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
}

.option-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 10px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    min-height: 70px;
}

.option-btn:hover {
    border-color: var(--primary-color);
    background: #f8fafc;
    transform: translateY(-2px);
}

.option-btn.active {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.option-btn .option-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.option-btn.active .option-value {
    color: var(--primary-color);
}

.option-btn .option-desc {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.option-btn.custom-option {
    background: #f8fafc;
}

.option-btn.custom-option .custom-input {
    width: 80px;
    padding: 6px 8px;
    margin-top: 6px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.9rem;
    text-align: center;
}

.option-btn.custom-option .custom-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Team grid styles */
.team-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

@media (max-width: 600px) {
    .team-grid {
        grid-template-columns: 1fr;
    }
}

.team-box {
    padding: 20px;
    border-radius: 12px;
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border: 2px solid #86efac;
}

.team-box.external {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #fbbf24;
}

.team-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
}

.team-icon {
    font-size: 1.3rem;
}

.team-title {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
}

.team-selector {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.team-btn {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(0,0,0,0.1);
    border-radius: 10px;
    background: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.team-btn:hover {
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.team-box .team-btn.active {
    background: #22c55e;
    border-color: #22c55e;
    color: white;
}

.team-box.external .team-btn.active {
    background: #f59e0b;
    border-color: #f59e0b;
}

.team-rate {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-align: center;
}

.team-total {
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    border-radius: 12px;
    padding: 15px 20px;
    border: 2px solid var(--primary-color);
}

.total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 0.95rem;
}

.total-row.highlight {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
    border-top: 1px solid var(--border-color);
    margin-top: 5px;
    padding-top: 12px;
}

/* Computed severity display */
.severity-card-computed {
    background: linear-gradient(135deg, #fafafa, #f5f5f5);
}

.severity-display {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
}

.severity-gauge {
    flex: 1;
    height: 20px;
    background: #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.gauge-fill {
    height: 100%;
    width: 45%;
    background: linear-gradient(90deg, #22c55e, #eab308, #f97316, #ef4444);
    background-size: 200% 100%;
    border-radius: 10px;
    transition: width 0.5s ease, background-position 0.5s ease;
}

.severity-info {
    text-align: right;
    min-width: 120px;
}

.severity-level {
    display: block;
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
}

.severity-score {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.severity-explanation {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    padding: 12px 15px;
    background: white;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}
