/* ============================================
   HYPERFORZA PRE-DIAGNOSIS SURVEY – STYLES
   Requires: global.css loaded first
   ============================================ */

:root {
    --red: #fe0000;
    --red-dark: #cc0000;
    --red-glow: rgba(254, 0, 0, 0.25);
    --red-subtle: rgba(254, 0, 0, 0.08);
    --bg: #0a0a0a;
    --bg-card: #111111;
    --bg-card-hover: #1a1a1a;
    --bg-option: #151515;
    --bg-option-hover: #1e1e1e;
    --bg-option-selected: rgba(254, 0, 0, 0.1);
    --border: #222222;
    --border-hover: #333333;
    --border-selected: var(--red);
    --text: #ffffff;
    --text-secondary: #999999;
    --text-muted: #666666;
    --radius: 16px;
    --radius-sm: 12px;
    --radius-xs: 8px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
    --shadow-hover: 0 8px 32px rgba(0, 0, 0, 0.5);
}

body {
    min-height: 100vh;
    line-height: 1.6;
}

/* Background pattern */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(254, 0, 0, 0.06) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 100%, rgba(254, 0, 0, 0.04) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

/* ---- PARTICLES ---- */
.particles-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.particles-bg .particle {
    position: absolute;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: rgba(254, 0, 0, 0.35);
    animation: floatParticle linear infinite;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        transform: translateY(-10vh) rotate(720deg);
        opacity: 0;
    }
}

/* ---- SURVEY CONTAINER ---- */
.survey-container {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

/* ---- SCREEN / STEP ---- */
.screen {
    display: none;
    width: 100%;
    max-width: 640px;
    animation: fadeSlideIn 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

.screen.active {
    display: block;
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeSlideOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }

    to {
        opacity: 0;
        transform: translateY(-20px);
    }
}

/* ---- CARD ---- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 48px 40px;
    width: 100%;
    box-shadow: var(--shadow);
}

/* ---- WELCOME SCREEN ---- */
.welcome-card {
    text-align: center;
    padding: 60px 40px;
}

.brand-icon {
    font-size: 3rem;
    margin-bottom: 24px;
    display: block;
    animation: pulse 3s ease infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }
}

.logo-container {
    margin-bottom: 28px;
}

.logo {
    width: 180px;
    height: auto;
    filter: drop-shadow(0 0 30px var(--red-glow));
    animation: pulse 3s ease infinite;
}

.welcome-brand {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--red);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.welcome-brand-sub {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 32px;
}

.welcome-text {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.5;
    margin-bottom: 8px;
}

.welcome-subtext {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 32px;
}

.time-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: var(--red-subtle);
    border: 1px solid rgba(254, 0, 0, 0.2);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 36px;
}

.time-badge span {
    font-size: 1rem;
}

/* ---- STEP COUNTER ---- */
.step-counter {
    display: inline-block;
    padding: 6px 14px;
    background: var(--red-subtle);
    border: 1px solid rgba(254, 0, 0, 0.2);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--red);
    letter-spacing: 0.02em;
    margin-bottom: 24px;
    text-transform: uppercase;
}

/* ---- QUESTION ---- */
.question-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 32px;
    letter-spacing: -0.01em;
    line-height: 1.3;
}

/* ---- CHOICE GRID (2-column for gender/age) ---- */
.choice-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 8px;
}

.choice-card {
    position: relative;
    cursor: pointer;
    padding: 40px 24px;
    background: var(--bg-option);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    text-align: center;
    transition: all var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.choice-card:hover {
    background: var(--bg-option-hover);
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.choice-card:active {
    transform: translateY(-2px) scale(0.98);
}

.choice-card.selected {
    background: var(--bg-option-selected);
    border-color: var(--red);
    box-shadow: 0 0 0 1px var(--red), 0 4px 20px var(--red-glow), 0 0 60px rgba(254, 0, 0, 0.08);
}

.choice-card.selected .choice-label {
    color: var(--red);
}

.choice-icon {
    font-size: 2.8rem;
    line-height: 1;
}

.choice-label {
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    transition: color var(--transition);
}

/* ---- SITUATION LIST (single column) ---- */
.situation-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.situation-card {
    position: relative;
    cursor: pointer;
    padding: 20px 24px;
    background: var(--bg-option);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    transition: all var(--transition);
    display: flex;
    align-items: center;
    gap: 16px;
}

.situation-card:hover {
    background: var(--bg-option-hover);
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.situation-card:active {
    transform: translateY(0) scale(0.99);
}

.situation-card.selected {
    background: var(--bg-option-selected);
    border-color: var(--red);
    box-shadow: 0 0 0 1px var(--red), 0 4px 16px var(--red-glow);
}

.situation-card.selected .situation-letter {
    background: var(--red);
    border-color: var(--red);
    color: #fff;
}

.situation-card.selected .situation-text {
    color: var(--text);
}

.situation-letter {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1.5px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.85rem;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: all var(--transition);
}

.situation-text {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    line-height: 1.4;
    transition: color var(--transition);
}

/* ---- BUTTONS ---- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 16px 36px;
    border: none;
    border-radius: 60px;
    font-family: inherit;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
    letter-spacing: 0.02em;
}

.btn svg {
    width: 20px;
    height: 20px;
}

.btn-primary {
    background: var(--red);
    color: white;
    box-shadow: 0 4px 20px var(--red-glow);
}

.btn-primary:hover {
    background: var(--red-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 32px var(--red-glow);
}

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

/* ---- REDIRECTING OVERLAY ---- */
.redirecting-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 10, 10, 0.92);
    backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.redirecting-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.redirecting-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border);
    border-top: 4px solid var(--red);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 24px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.redirecting-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.redirecting-subtext {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 8px;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 600px) {
    .card {
        padding: 36px 24px;
    }

    .welcome-card {
        padding: 48px 24px;
    }

    .choice-grid {
        gap: 12px;
    }

    .choice-card {
        padding: 32px 16px;
    }

    .choice-icon {
        font-size: 2.2rem;
    }

    .choice-label {
        font-size: 1rem;
    }

    .question-title {
        font-size: 1.25rem;
    }

    .welcome-text {
        font-size: 1.1rem;
    }

    .welcome-subtext {
        font-size: 0.95rem;
    }

    .logo {
        width: 140px;
    }
}

@media (max-width: 400px) {
    .card {
        padding: 28px 18px;
    }

    .choice-card {
        padding: 24px 12px;
    }

    .situation-card {
        padding: 16px 18px;
    }
}