:root {
    --bg: #0f1117;
    --card: #171a23;
    --card-soft: #1f2430;
    --text: #f4f4f5;
    --muted: #b7bbc8;
    --border: #2d3343;
    --accent: #e63946;
    --accent-dark: #b92b36;
    --ok: #2ecc71;
    --warning: #f1c40f;
    --bad: #e74c3c;
    --info: #3498db;
    --radius: 18px;
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(230, 57, 70, 0.16), transparent 34rem),
        linear-gradient(180deg, #0f1117 0%, #11151d 100%);
    color: var(--text);
    line-height: 1.6;
}

.page {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 40px 0 70px;
}

.hero {
    padding: 38px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.18), rgba(31, 36, 48, 0.9));
    box-shadow: var(--shadow);
    margin-bottom: 24px;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

h1,
h2,
h3 {
    line-height: 1.2;
}

h1 {
    margin: 0 0 14px;
    font-size: clamp(2rem, 4vw, 3.4rem);
}

h2 {
    margin: 0 0 16px;
    font-size: 1.45rem;
}

h3 {
    margin: 0 0 12px;
    font-size: 1.1rem;
}

.subtitle {
    max-width: 820px;
    margin: 0;
    color: var(--muted);
    font-size: 1.08rem;
}

.card {
    background: rgba(23, 26, 35, 0.94);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    margin-bottom: 24px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.card p:last-child {
    margin-bottom: 0;
}

.instructions {
    padding-left: 1.3rem;
    margin-bottom: 18px;
}

.note {
    border-left: 4px solid var(--accent);
    padding: 14px 16px;
    background: rgba(230, 57, 70, 0.08);
    border-radius: 12px;
    color: var(--text);
}

.findings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    margin-bottom: 28px;
}

.finding {
    background: rgba(23, 26, 35, 0.96);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
}

.finding-header {
    padding: 20px;
    background: var(--card-soft);
    border-bottom: 1px solid var(--border);
}

.finding-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.finding-title h3 {
    margin: 0;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 4px 10px;
    font-weight: 700;
    font-size: 0.82rem;
    white-space: nowrap;
}

.badge.critical {
    background: rgba(231, 76, 60, 0.16);
    color: #ff7b72;
    border: 1px solid rgba(231, 76, 60, 0.42);
}

.badge.high {
    background: rgba(241, 196, 15, 0.14);
    color: #f7d774;
    border: 1px solid rgba(241, 196, 15, 0.38);
}

.badge.medium {
    background: rgba(52, 152, 219, 0.14);
    color: #83c9ff;
    border: 1px solid rgba(52, 152, 219, 0.38);
}

.finding-body {
    padding: 20px;
}

.meta-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 18px 0;
}

.meta {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px;
}

.meta-label {
    display: block;
    color: var(--muted);
    font-size: 0.78rem;
    margin-bottom: 2px;
}

.meta-value {
    font-weight: 700;
}

.form-block {
    margin-top: 16px;
}

label {
    display: block;
    margin-bottom: 6px;
    font-weight: 700;
}

select,
textarea {
    width: 100%;
    background: #0f1117;
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 11px 12px;
    font: inherit;
}

textarea {
    min-height: 90px;
    resize: vertical;
}

select:focus,
textarea:focus {
    outline: 2px solid rgba(230, 57, 70, 0.45);
    border-color: var(--accent);
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 28px 0;
}

.button {
    border: 0;
    border-radius: 14px;
    padding: 13px 18px;
    font-weight: 800;
    cursor: pointer;
    font-size: 0.98rem;
}

.button.primary {
    color: white;
    background: var(--accent);
}

.button.primary:hover {
    background: var(--accent-dark);
}

.button.secondary {
    color: var(--text);
    background: var(--card-soft);
    border: 1px solid var(--border);
}

.button.ghost {
    color: var(--muted);
    background: transparent;
    border: 1px solid var(--border);
}

.hidden {
    display: none;
}

.feedback-box {
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 12px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
}

.feedback-box.good {
    border-color: rgba(46, 204, 113, 0.45);
}

.feedback-box.warn {
    border-color: rgba(241, 196, 15, 0.45);
}

.feedback-box.bad {
    border-color: rgba(231, 76, 60, 0.45);
}

.feedback-box strong {
    display: block;
    margin-bottom: 4px;
}

.solution-table-wrapper {
    overflow-x: auto;
}

.solution-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 18px;
}

.solution-table th,
.solution-table td {
    border: 1px solid var(--border);
    padding: 12px;
    vertical-align: top;
    text-align: left;
}

.solution-table th {
    background: var(--card-soft);
}

.solution-table tr:nth-child(even) td {
    background: rgba(255, 255, 255, 0.03);
}

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

    .hero {
        padding: 26px;
    }

    .card {
        padding: 22px;
    }
}

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

    .actions {
        flex-direction: column;
    }

    .button {
        width: 100%;
    }
}