/* ══════════════════════════════════════════════
   QUALIFY.CSS — Wine Tour Qualification Wizard
   Self-contained: includes base vars + nav styles
   ══════════════════════════════════════════════ */

/* ─── Self-hosted Fonts ─── */
@font-face {
    font-family: 'Bebas Neue';
    src: url('../fonts/BebasNeue-Regular.ttf') format('truetype');
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: 'Fraunces';
    src: url('../fonts/Fraunces-Variable.ttf') format('truetype');
    font-weight: 100 900;
    font-display: swap;
}

@font-face {
    font-family: 'Fraunces';
    src: url('../fonts/Fraunces-Italic-Variable.ttf') format('truetype');
    font-weight: 100 900;
    font-style: italic;
    font-display: swap;
}

/* ─── Design Tokens ─── */
:root {
    --wine: #5B2333;
    --wine-90: rgba(91, 35, 51, 0.9);
    --plum: #7B3F52;
    --plum-light: #9B5F72;
    --gold: #C9A84C;
    --gold-light: #d4b96a;
    --gold-glow: rgba(201, 168, 76, 0.25);
    --cream: #F9F5EE;
    --cream-dark: #EDE5D8;
    --white: #ffffff;
    --off-white: #fafaf8;
    --text: #2c2c2c;
    --text-light: #6b6b6b;
    --text-muted: #999;
    --danger: #c0392b;

    --font-display: 'Bebas Neue', 'Impact', sans-serif;
    --font-body: 'Fraunces', 'Georgia', serif;

    --radius: 12px;
    --radius-sm: 8px;
    --radius-xs: 6px;

    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ─── Reset ─── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--text);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
}

/* ─── Navigation ─── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 0.85rem 0;
    background: var(--wine);
    transition: background 0.3s, box-shadow 0.3s;
    box-shadow: 0 1px 8px rgba(91, 35, 51, 0.15);
}

.nav__inner {
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 3vw, 2rem);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav__logo {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    text-decoration: none;
    color: var(--white);
}

.nav__logo-mark {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.4rem;
    width: 2.4rem;
    height: 2.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--gold);
    border-radius: 6px;
    color: var(--gold);
    letter-spacing: 0.04em;
}

.nav__logo-text {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
}

.nav__right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav__phone {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: color 0.2s;
}

.nav__phone:hover {
    color: var(--white);
}

/* ─── Hero / Header Section ─── */
.qualify-hero {
    background: var(--wine);
    padding: 3rem 0 2rem;
    text-align: center;
    color: var(--white);
}

.qualify-hero__inner {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 3vw, 2rem);
}

.qualify-hero__eyebrow {
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gold);
    margin-bottom: 0.75rem;
}

.qualify-hero__title {
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 4vw, 2.2rem);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 0.75rem;
}

.qualify-hero__desc {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.6;
    max-width: 480px;
    margin: 0 auto;
}

/* ─── Wizard Container ─── */
.qualify {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--cream);
    padding-top: 80px;
}

.qualify__inner {
    max-width: 640px;
    margin: 0 auto;
    padding: clamp(1.5rem, 4vw, 3rem) clamp(1rem, 3vw, 2rem);
}

/* ─── Progress Bar ─── */
.qualify__progress {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--cream-dark);
    z-index: 99;
}

.qualify__progress-fill {
    height: 100%;
    background: var(--gold);
    transition: width 0.4s var(--ease-out);
    border-radius: 0 2px 2px 0;
}

/* ─── Step Indicator ─── */
.qualify__step-indicator {
    text-align: center;
    margin-bottom: 1.5rem;
}

.qualify__step-label {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
}

/* ─── Screen Panels ─── */
.qualify__screen {
    display: none;
    opacity: 0;
    transform: translateX(30px);
    transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out);
}

.qualify__screen.active {
    display: block;
}

.qualify__screen.visible {
    opacity: 1;
    transform: translateX(0);
}

.qualify__screen-title {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3.5vw, 2rem);
    font-weight: 600;
    color: var(--wine);
    margin-bottom: 0.5rem;
}

.qualify__screen-desc {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* ─── Question Group ─── */
.qualify__question {
    margin-bottom: 2rem;
}

.qualify__question-label {
    display: block;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--wine);
    margin-bottom: 0.75rem;
}

/* ─── Option Cards (Radio) ─── */
.qualify__options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.qualify__options--cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.qualify__option {
    position: relative;
}

.qualify__option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.qualify__option-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem 0.75rem;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    background: var(--white);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: all 0.25s var(--ease-out);
    text-align: center;
    min-height: 68px;
}

.qualify__option-card:hover {
    border-color: var(--gold-light);
    box-shadow: 0 2px 8px rgba(201, 168, 76, 0.15);
}

.qualify__option input:checked + .qualify__option-card {
    border-color: var(--gold);
    background: rgba(201, 168, 76, 0.08);
    box-shadow: 0 2px 12px var(--gold-glow);
}

.qualify__option-icon {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
    line-height: 1;
}

.qualify__option-text {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text);
    line-height: 1.3;
}

/* ─── Text Input ─── */
.qualify__input {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 2px solid var(--cream-dark);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text);
    background: var(--white);
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.qualify__input:focus {
    outline: none;
    border-color: var(--gold);
}

.qualify__input.invalid {
    border-color: var(--danger);
}

/* ─── GDPR ─── */
.qualify__gdpr {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin: 1.5rem 0;
    padding: 1rem;
    border-radius: var(--radius-sm);
    background: rgba(91, 35, 51, 0.03);
}

.qualify__gdpr input[type="checkbox"] {
    margin-top: 3px;
    width: 18px;
    height: 18px;
    accent-color: var(--gold);
    flex-shrink: 0;
}

.qualify__gdpr-text {
    font-size: 0.8rem;
    color: var(--text-light);
    line-height: 1.5;
}

.qualify__gdpr-text a {
    color: var(--plum);
    text-decoration: underline;
}

/* ─── Navigation Buttons ─── */
.qualify__nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2rem;
    gap: 1rem;
}

.qualify__btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.85rem 1.75rem;
    border-radius: 100px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.25s var(--ease-out);
}

.qualify__btn--next {
    background: var(--wine);
    color: var(--white);
    margin-left: auto;
}

.qualify__btn--next:hover {
    background: var(--plum);
    transform: translateY(-1px);
}

.qualify__btn--next:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.qualify__btn--back {
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--cream-dark);
}

.qualify__btn--back:hover {
    background: var(--white);
    color: var(--text);
}

.qualify__btn--submit {
    background: var(--gold);
    color: var(--wine);
    width: 100%;
    justify-content: center;
    padding: 1rem;
    font-size: 1rem;
}

.qualify__btn--submit:hover {
    background: var(--gold-light);
    transform: translateY(-1px);
}

.qualify__btn--submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ─── Error Message ─── */
.qualify__error {
    display: none;
    padding: 0.85rem 1rem;
    border-radius: var(--radius-sm);
    background: rgba(192, 57, 43, 0.08);
    border: 1px solid rgba(192, 57, 43, 0.2);
    color: var(--danger);
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.qualify__error.active {
    display: block;
}

/* ─── Success Screen ─── */
.qualify__success {
    text-align: center;
    padding: 2rem 0;
}

.qualify__success-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(46, 204, 113, 0.12);
    border: 2px solid #2ecc71;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    animation: qualify-check 0.6s var(--ease-spring);
}

@keyframes qualify-check {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

.qualify__success-title {
    font-family: var(--font-display);
    font-size: clamp(1.4rem, 3vw, 1.8rem);
    font-weight: 600;
    color: var(--wine);
    margin-bottom: 0.75rem;
}

.qualify__success-text {
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.qualify__success-redirect {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.qualify__success-redirect a {
    color: var(--gold);
    font-weight: 600;
    text-decoration: none;
}

.qualify__success-redirect a:hover {
    text-decoration: underline;
}

/* ─── Footer ─── */
.qualify-footer {
    text-align: center;
    padding: 2rem clamp(1rem, 3vw, 2rem);
    border-top: 1px solid var(--cream-dark);
    background: var(--cream);
}

.qualify-footer__text {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.qualify-footer__text a {
    color: var(--plum);
    text-decoration: none;
}

.qualify-footer__text a:hover {
    text-decoration: underline;
}

/* ─── Responsive ─── */
@media (max-width: 480px) {
    .qualify__options {
        grid-template-columns: 1fr;
    }

    .qualify__options--cols-3 {
        grid-template-columns: 1fr;
    }

    .qualify__option-card {
        flex-direction: row;
        gap: 0.75rem;
        text-align: left;
        min-height: auto;
        padding: 0.85rem 1rem;
    }

    .qualify__option-icon {
        margin-bottom: 0;
        font-size: 1.25rem;
    }

    .qualify__nav {
        flex-direction: column-reverse;
    }

    .qualify__btn--next {
        width: 100%;
        justify-content: center;
        margin-left: 0;
    }

    .qualify__btn--back {
        width: 100%;
        justify-content: center;
    }

    .nav__phone { display: none; }
    .nav__logo-text { display: none; }
}
