/* ================================================================
   AIFOD × ZAAN — Summit Invite Page Styles
   Palette: Deep navy #0B0F2A, Gold #C9A84C, Cream #F5F0E8, White
   Fonts: Playfair Display (headings) / Inter (body)
================================================================ */

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

:root {
    --navy:       #0B0F2A;
    --navy-mid:   #141935;
    --navy-light: #1E2545;
    --gold:       #C9A84C;
    --gold-light: #E0C270;
    --gold-dark:  #A07830;
    --cream:      #F5F0E8;
    --white:      #FFFFFF;
    --text-muted: rgba(245,240,232,0.6);
    --error:      #E05C5C;
    --success:    #3DBD7D;

    --radius-sm:  6px;
    --radius-md:  12px;
    --radius-lg:  20px;

    --transition: 0.2s ease;
}

html { scroll-behavior: smooth; }

body.aifod-invite-body {
    font-family: 'Inter', system-ui, sans-serif;
    background: var(--navy);
    color: var(--cream);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* ================================================================
   HERO
================================================================ */
.aifod-hero {
    position: relative;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6rem 1.5rem 8rem;
    background:
        radial-gradient(ellipse 80% 60% at 50% -10%, rgba(201,168,76,0.18) 0%, transparent 70%),
        radial-gradient(ellipse 60% 80% at 90% 110%, rgba(201,168,76,0.10) 0%, transparent 60%),
        linear-gradient(160deg, var(--navy) 0%, #0D1230 40%, #070A1A 100%);
    text-align: center;
    overflow: hidden;
}

/* Subtle noise texture overlay */
.aifod-hero__noise {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    pointer-events: none;
    opacity: 0.5;
}

.aifod-hero__inner {
    position: relative;
    z-index: 1;
    max-width: 760px;
    width: 100%;
}

/* Badge */
.aifod-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(201,168,76,0.12);
    border: 1px solid rgba(201,168,76,0.3);
    color: var(--gold-light);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 6px 16px;
    border-radius: 100px;
    margin-bottom: 2.5rem;
}

.aifod-hero__badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 6px var(--gold);
    animation: aifod-pulse 2s ease-in-out infinite;
}

@keyframes aifod-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.4; }
}

/* Greeting */
.aifod-hero__greeting {
    font-size: clamp(0.95rem, 2.5vw, 1.15rem);
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.02em;
    margin-bottom: 0.5rem;
}

/* Delegate name */
.aifod-hero__name {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 900;
    font-size: clamp(2.6rem, 8vw, 5.5rem);
    line-height: 1.05;
    color: var(--white);
    margin-bottom: 1.75rem;

    /* Gold shimmer on name */
    background: linear-gradient(135deg, #fff 30%, var(--gold-light) 60%, #fff 80%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.aifod-hero__name--generic {
    font-size: clamp(2rem, 6vw, 4rem);
}

/* Tagline */
.aifod-hero__tagline {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    color: var(--text-muted);
    line-height: 1.7;
    max-width: 540px;
    margin: 0 auto 2.5rem;
}

/* Meta info */
.aifod-hero__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.aifod-hero__meta-item {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--gold-light);
    font-size: 0.9rem;
    font-weight: 500;
}

.aifod-hero__meta-divider {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(201,168,76,0.4);
}

/* CTA Button */
.aifod-hero__cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    color: var(--navy);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-decoration: none;
    padding: 1rem 2.2rem;
    border-radius: 100px;
    transition: transform var(--transition), box-shadow var(--transition), filter var(--transition);
    box-shadow: 0 4px 24px rgba(201,168,76,0.35);
}

.aifod-hero__cta:hover,
.aifod-hero__cta:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(201,168,76,0.5);
    filter: brightness(1.05);
    outline: 3px solid var(--gold-light);
    outline-offset: 3px;
}

.aifod-hero__cta svg { transition: transform var(--transition); }
.aifod-hero__cta:hover svg { transform: translateX(4px); }

/* Scroll hint */
.aifod-hero__scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: var(--text-muted);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    animation: aifod-bounce 2.4s ease-in-out infinite;
}

@keyframes aifod-bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50%       { transform: translateX(-50%) translateY(6px); }
}

/* ================================================================
   FORM SECTION
================================================================ */
.aifod-form-section {
    background: var(--cream);
    padding: 6rem 1.5rem 5rem;
}

.aifod-form-section__inner {
    max-width: 720px;
    margin: 0 auto;
}

.aifod-form-section__header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.aifod-form-section__label {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--gold-dark);
    margin-bottom: 0.75rem;
}

.aifod-form-section__heading {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(2rem, 5vw, 2.8rem);
    font-weight: 700;
    color: var(--navy);
    line-height: 1.15;
    margin-bottom: 0.85rem;
}

.aifod-form-section__sub {
    color: #5A5A72;
    font-size: 0.95rem;
    line-height: 1.65;
}

/* ================================================================
   ALERTS
================================================================ */
.aifod-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 1.5rem;
    animation: aifod-fade-in 0.3s ease;
}

.aifod-alert[hidden] { display: none; }

.aifod-alert--success {
    background: rgba(61,189,125,0.12);
    border: 1px solid rgba(61,189,125,0.4);
    color: #1A6B44;
}

.aifod-alert--error {
    background: rgba(224,92,92,0.10);
    border: 1px solid rgba(224,92,92,0.35);
    color: #8B2020;
}

@keyframes aifod-fade-in {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ================================================================
   FORM GRID & FIELDS
================================================================ */
.aifod-form__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem 1.25rem;
}

.aifod-form__group { display: flex; flex-direction: column; gap: 6px; }
.aifod-form__group--full { grid-column: 1 / -1; }

.aifod-form__label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--navy);
    letter-spacing: 0.01em;
}

.aifod-form__optional {
    font-weight: 400;
    color: #8888A0;
    margin-left: 4px;
}

.aifod-form__input {
    width: 100%;
    padding: 0.8rem 1rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--navy);
    background: var(--white);
    border: 1.5px solid #D4CCE8;
    border-radius: var(--radius-sm);
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition);
    -webkit-appearance: none;
}

.aifod-form__input::placeholder { color: #ADADC4; }

.aifod-form__input:focus {
    border-color: var(--gold-dark);
    box-shadow: 0 0 0 3px rgba(160,120,48,0.18);
}

.aifod-form__input.aifod-input--error {
    border-color: var(--error);
    box-shadow: 0 0 0 3px rgba(224,92,92,0.15);
}

.aifod-form__textarea { resize: vertical; min-height: 110px; }

/* Inline field errors */
.aifod-form__error {
    font-size: 0.8rem;
    color: var(--error);
    font-weight: 500;
    min-height: 1.1em;
    display: block;
}

/* ================================================================
   SUBMIT BUTTON
================================================================ */
.aifod-form__footer {
    margin-top: 2.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.aifod-form__submit {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--navy-mid) 0%, var(--navy) 100%);
    color: var(--gold-light);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    padding: 1rem 3rem;
    border: none;
    border-radius: 100px;
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition), opacity var(--transition);
    box-shadow: 0 4px 20px rgba(11,15,42,0.25);
    min-width: 220px;
}

.aifod-form__submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(11,15,42,0.35);
}

.aifod-form__submit:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

.aifod-form__submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Loading spinner */
.aifod-form__submit-spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(201,168,76,0.3);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: aifod-spin 0.7s linear infinite;
}

.aifod-form__submit.aifod-loading .aifod-form__submit-spinner { display: inline-block; }
.aifod-form__submit.aifod-loading .aifod-form__submit-text { opacity: 0.6; }

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

.aifod-form__privacy {
    font-size: 0.78rem;
    color: #8888A0;
    text-align: center;
    line-height: 1.5;
}

/* ================================================================
   FOOTER
================================================================ */
.aifod-footer {
    background: var(--navy);
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: center;
    padding: 1.5rem;
    letter-spacing: 0.03em;
}

/* ================================================================
   RESPONSIVE
================================================================ */
@media (max-width: 640px) {
    .aifod-form__grid {
        grid-template-columns: 1fr;
    }

    .aifod-form__group--full {
        grid-column: 1;
    }

    .aifod-hero {
        padding: 5rem 1.25rem 7rem;
    }

    .aifod-form-section {
        padding: 4rem 1.25rem 4rem;
    }
}

@media (max-width: 375px) {
    .aifod-hero__meta {
        flex-direction: column;
        gap: 0.5rem;
    }

    .aifod-hero__meta-divider { display: none; }

    .aifod-form__submit {
        width: 100%;
    }
}
