.apply-body {
    overflow-x: hidden;
}

.progress {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.08);
    z-index: 20;
}

.progress-bar {
    height: 100%;
    width: 0;
    background: var(--accent);
    transition: width 0.4s ease;
}

.apply-logo {
    position: fixed;
    top: 22px;
    left: 28px;
    z-index: 20;
    display: inline-flex;
    opacity: 0.9;
    transition: opacity 0.18s ease;
}

.apply-logo:hover {
    opacity: 1;
}

.apply-logo img {
    width: 64px;
    height: auto;
}

.apply {
    min-height: 100vh;
    min-height: 100dvh;
    position: relative;
}

.step {
    display: none;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 100px 24px 60px;
    align-items: center;
    justify-content: center;
}

.step.active {
    display: flex;
    animation: stepIn 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes stepIn {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}

.step-inner {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.q-num {
    color: var(--accent);
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.q-title {
    font-size: 28px;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 8px;
}

.q-sub {
    display: block;
    font-size: 16px;
    font-weight: 400;
    color: var(--muted);
    margin-top: 6px;
}

.q-help {
    color: var(--muted);
    font-size: 15px;
    margin-bottom: 22px;
}

.req {
    color: var(--accent);
}

.step input[type="text"],
.step input[type="email"],
.step input[type="date"] {
    width: 100%;
    max-width: 460px;
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--border);
    color: var(--fg);
    font-family: inherit;
    font-size: 24px;
    font-weight: 500;
    text-align: center;
    padding: 8px 2px;
    margin: 12px auto 0;
    outline: none;
    transition: border-color 0.18s ease;
}

.step input::placeholder {
    color: rgba(255, 255, 255, 0.28);
    font-weight: 400;
}

.step input:focus {
    border-bottom-color: var(--accent);
}

.step input[type="date"] {
    color-scheme: dark;
    max-width: 280px;
}

.field-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    max-width: 540px;
    margin: 10px auto 0;
}

.field-grid input {
    margin-top: 0;
    max-width: none;
}

.consent {
    font-size: 14px;
    line-height: 1.6;
    color: var(--muted);
    margin: 26px auto 0;
    max-width: 500px;
}

.consent a {
    color: var(--fg);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.options {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-top: 24px;
}

.option {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: 460px;
    text-align: left;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--fg);
    font-family: inherit;
    font-size: 17px;
    font-weight: 500;
    padding: 16px 18px;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, transform 0.06s ease;
}

.option:hover {
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.06);
}

.option:active {
    transform: scale(0.99);
}

.option .key {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    border: 1px solid var(--border);
    font-size: 13px;
    font-weight: 600;
    flex-shrink: 0;
}

.option.selected {
    border-color: var(--accent);
    background: rgba(232, 52, 28, 0.14);
}

.option.selected .key {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.method-link {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
}

.method-link.visible {
    max-height: 120px;
    opacity: 1;
    margin-top: 8px;
}

.step-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 14px;
    margin-top: 32px;
}

.button:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.hint {
    font-size: 13px;
    color: var(--muted);
}

.hint strong {
    color: var(--fg);
    font-weight: 600;
}

.submit-error {
    flex-basis: 100%;
    margin: 0;
    color: var(--accent-hover);
    font-size: 14px;
    line-height: 1.5;
}

.back {
    flex-basis: 100%;
    text-align: center;
    background: transparent;
    border: none;
    color: var(--muted);
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: color 0.15s ease;
}

.back:hover {
    color: var(--fg);
}


.shake {
    animation: shake 0.3s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-6px); }
    75% { transform: translateX(6px); }
}


.thanks {
    text-align: center;
    max-width: 620px;
}

.thanks-title {
    font-size: 30px;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 22px;
}

.thanks-text {
    font-size: 16px;
    line-height: 1.7;
    color: var(--muted);
    margin-bottom: 16px;
}

.thanks-text a {
    color: var(--fg);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.thanks-sign {
    font-size: 16px;
    margin: 28px 0 32px;
}

@media (max-width: 600px) {
    .q-title {
        font-size: 23px;
    }

    .step input[type="text"],
    .step input[type="email"],
    .step input[type="date"] {
        font-size: 20px;
    }

    .field-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .apply-logo img {
        width: 52px;
    }

    .step {
        padding: 84px 16px 48px;
    }

    .apply-logo {
        top: 14px;
        left: 16px;
    }

    .option {
        font-size: 16px;
        padding: 14px 16px;
    }

    .thanks-title {
        font-size: 25px;
    }
}

@media (max-height: 520px) and (orientation: landscape) {
    .step {
        align-items: flex-start;
        padding: 68px 16px 32px;
    }

    .q-title {
        font-size: 20px;
    }

    .options {
        margin-top: 16px;
        gap: 8px;
    }

    .step-footer {
        margin-top: 20px;
    }
}
