.req-page {
    width: 100%;
    margin: 0 auto;
    padding: 0 0 68px;
}

.req-hero {
    padding-bottom: 28px;
}

.req-hero .page-lead {
    max-width: 480px;
}

.req-shell,
.result-card {
    width: min(820px, calc(100vw - 36px));
    max-width: none;
    margin: 0 auto;
    min-width: 0;
}

.req-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 14px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.req-steps span {
    min-width: 0;
    min-height: 38px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, .78);
    padding: 0 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.req-steps span.active {
    border-color: rgba(7, 25, 35, .16);
    background: var(--ink);
    color: #fff;
    box-shadow: var(--shadow-button);
}

.req-panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .94);
    padding: 24px;
    box-shadow: 0 18px 48px rgba(7, 25, 35, .08);
}

.req-panel[hidden],
.req-step[hidden] {
    display: none;
}

.req-section-head {
    display: grid;
    gap: 8px;
    margin-bottom: 20px;
}

.req-section-head.compact {
    margin-bottom: 14px;
}

.req-section-head h2 {
    margin: 0;
    color: var(--ink);
    font-size: clamp(25px, 4vw, 34px);
    line-height: 1.18;
    font-weight: 760;
}

.req-section-head p:not(.section-kicker) {
    max-width: 560px;
    margin: 0;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.72;
}

.req-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.req-field,
.req-fieldset {
    display: grid;
    gap: 7px;
}

.req-field span,
.req-fieldset legend {
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

.req-field input,
.req-field select {
    width: 100%;
    min-height: 46px;
    border: 1px solid #d2dcdf;
    border-radius: 8px;
    padding: 0 12px;
    background: #fff;
    color: var(--ink);
    outline: none;
}

.req-field input:focus,
.req-field select:focus {
    border-color: rgba(7, 25, 35, .46);
    box-shadow: 0 0 0 3px rgba(7, 25, 35, .08);
}

.req-fieldset {
    margin: 18px 0 0;
    padding: 0;
    border: 0;
}

.check-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.check-grid label {
    position: relative;
    min-width: 0;
    color: var(--ink);
    font-size: 14px;
    line-height: 1.45;
    font-weight: 800;
}

.check-grid input {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
}

.check-grid span {
    min-height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 8px 10px;
    background: var(--soft);
    color: var(--ink);
    text-align: center;
    transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.check-grid input:checked + span {
    border-color: var(--ink);
    background: var(--ink);
    color: #fff;
    box-shadow: var(--shadow-button);
}

.check-grid label:focus-within span {
    outline: 2px solid rgba(7, 25, 35, .2);
    outline-offset: 3px;
}

.consent {
    min-height: 42px;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 10px;
    background: var(--soft);
    color: var(--ink);
    font-size: 14px;
    line-height: 1.45;
}

.consent input {
    width: 16px;
    height: 16px;
    accent-color: var(--ink);
}

.req-actions,
.test-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 22px;
}

.req-actions .text-button {
    grid-column: 1 / -1;
}

.button.text-button {
    border-color: transparent;
    background: transparent;
    color: var(--muted);
    box-shadow: none;
}

.button:disabled {
    opacity: .42;
    cursor: not-allowed;
    transform: none;
}

.req-error {
    margin-bottom: 14px;
    border: 1px solid #f2c7c0;
    border-radius: 8px;
    padding: 11px 12px;
    background: #fff7f5;
    color: #a24939;
    font-size: 14px;
    line-height: 1.6;
}

.card-progress {
    display: grid;
    gap: 8px;
}

.progress-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: var(--ink-soft);
    font-size: 13px;
    font-weight: 800;
}

.progress-track {
    height: 8px;
    overflow: hidden;
    border-radius: 8px;
    background: #e5ecee;
}

.progress-fill {
    height: 100%;
    width: 0;
    border-radius: 8px;
    background: var(--ink);
    transition: width .22s ease;
}

.swipe-stage {
    position: relative;
    height: min(60vh, 480px);
    min-height: 410px;
    display: grid;
    place-items: center;
    overflow: hidden;
}

.swipe-card,
.next-card {
    width: min(100%, 440px);
    height: min(100%, 430px);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.next-card {
    position: absolute;
    inset: 30px 14px auto;
    margin: 0 auto;
    transform: scale(.96);
    opacity: .45;
    background: #f8fbfa;
}

.swipe-card {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 16px;
    padding: 18px;
    touch-action: pan-y;
    user-select: none;
    cursor: grab;
    will-change: transform;
    transition: transform .22s ease, opacity .22s ease;
}

.swipe-card.dragging {
    cursor: grabbing;
    transition: none;
}

.card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.card-category {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 9px;
    border: 1px solid #dfe8ea;
    border-radius: 999px;
    background: var(--soft);
    color: var(--green);
    font-size: 12px;
    font-weight: 900;
}

.card-number {
    color: var(--muted);
    font-size: 12px;
    font-weight: 850;
}

.card-body {
    display: grid;
    align-content: center;
    gap: 14px;
    min-height: 0;
}

.card-text {
    margin: 0;
    color: var(--ink);
    font-size: clamp(25px, 5vw, 33px);
    line-height: 1.28;
    font-weight: 850;
}

.card-hint {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mini-tag {
    min-height: 28px;
    padding: 6px 9px;
    border-radius: 999px;
    background: #f4f7f7;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.swipe-badge {
    position: absolute;
    top: 80px;
    min-width: 88px;
    padding: 8px 10px;
    border: 2px solid currentColor;
    border-radius: 8px;
    background: rgba(255, 255, 255, .84);
    font-size: 16px;
    font-weight: 950;
    text-align: center;
    opacity: 0;
    pointer-events: none;
}

.swipe-badge.left {
    left: 20px;
    color: #a24939;
    transform: rotate(-9deg);
}

.swipe-badge.right {
    right: 20px;
    color: var(--green);
    transform: rotate(9deg);
}

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

.choice {
    min-height: 50px;
    border-radius: 8px;
    font-size: 15px;
}

.choice.left {
    border-color: #efd0c8;
    background: #fff7f5;
    color: #a24939;
}

.choice.right {
    border-color: #d3e2dd;
    background: #f3f8f6;
    color: var(--green);
}

.slider-list {
    display: grid;
    gap: 12px;
}

.slider-list label {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    color: var(--ink);
    font-size: 14px;
    font-weight: 800;
}

.slider-list input {
    width: 100%;
    accent-color: var(--ink);
}

.summary-preview {
    margin-top: 20px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 18px 0;
}

.summary-preview h3,
.result-card h2 {
    margin: 0 0 10px;
    color: var(--ink);
    font-size: 22px;
    line-height: 1.25;
}

.summary-preview p,
.result-card p {
    margin: 0;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.78;
}

.summary-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.summary-list span {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0 10px;
    background: #fff;
    color: var(--ink-soft);
    font-size: 13px;
    font-weight: 800;
}

.consent {
    margin-top: 18px;
}

.result-card {
    margin-top: 18px;
}

.result-card .button {
    width: min(100%, 260px);
    margin-top: 16px;
}

@media (max-width: 700px) {
    .req-page {
        padding-bottom: 46px;
    }

    .req-hero {
        padding-top: 42px;
    }

    .req-hero .page-lead {
        max-width: 300px;
    }

    .req-shell,
    .result-card {
        width: calc(100vw - 28px);
    }

    .req-steps {
        gap: 6px;
        font-size: 11px;
    }

    .req-steps span {
        min-height: 34px;
    }

    .req-panel {
        padding: 18px;
    }

    .req-grid,
    .check-grid,
    .req-actions,
    .test-actions {
        grid-template-columns: 1fr;
    }

    .swipe-stage {
        height: min(58vh, 430px);
        min-height: 374px;
    }

    .swipe-card,
    .next-card {
        height: min(100%, 386px);
    }

    .card-text {
        font-size: 26px;
    }

    .slider-list label {
        grid-template-columns: 82px minmax(0, 1fr);
        gap: 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .swipe-card,
    .progress-fill {
        transition: none;
    }
}
