/* =============================================================================
   23TION Tickets — Public Frontend Styles
   ============================================================================= */

/* ── Reset ───────────────────────────────────────────────────────────────── */
.tion-form-wrap *,
.tion-form-wrap *::before,
.tion-form-wrap *::after {
    box-sizing: border-box;
}

/* ── Outer container — full width ─────────────────────────────────────────── */
.tion-form-wrap {
    width: 100%;
    max-width: 100%;
    background-color: #000000;
    color: #ffffff;
    font-family: 'Jaini', system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    padding: 40px 24px;
    box-sizing: border-box;
}

/* Force Jaini on every descendant — labels, inputs, placeholders, buttons, hints */
.tion-form-wrap,
.tion-form-wrap input,
.tion-form-wrap select,
.tion-form-wrap textarea,
.tion-form-wrap button,
.tion-form-wrap label,
.tion-form-wrap span,
.tion-form-wrap p,
.tion-form-wrap h1,
.tion-form-wrap h2,
.tion-form-wrap h3 {
    font-family: 'Jaini', system-ui, sans-serif;
}

.tion-form-wrap input::placeholder,
.tion-form-wrap textarea::placeholder {
    font-family: 'Jaini', system-ui, sans-serif;
}

/* ── Labels ───────────────────────────────────────────────────────────────── */
.tion-label {
    display: block;
    font-family: 'Jaini', serif;
    font-size: 20px;
    color: #ffffff;
    margin-bottom: 8px;
}

.tion-required {
    color: #CC0000;
    margin-left: 2px;
}

.tion-optional {
    font-size: 15px;
    color: #555;
    font-weight: 400;
}

/* ── Inputs ───────────────────────────────────────────────────────────────── */
.tion-input {
    display: block;
    width: 100%;
    height: 52px;
    padding: 14px 18px;
    background: #000;
    color: #fff;
    border: 1px solid #9c9c9c;
    border-radius: 12px;
    font-size: 18px;
    outline: none;
    transition: border-color 0.2s;
    -webkit-appearance: none;
    appearance: none;
}

.tion-input::placeholder {
    color: #555555;
    font-style: italic;
}

.tion-input:focus {
    border-color: #ffffff;
}

.tion-input--error {
    border-color: #CC0000 !important;
}

/* ── Field wrapper ────────────────────────────────────────────────────────── */
.tion-field {
    margin-bottom: 16px;
}

.tion-hint {
    display: block;
    color: #555;
    font-size: 11px;
    margin-top: 4px;
    letter-spacing: 1px;
}

/* Email-specific hint — slightly more prominent so users actually read it */
.tion-hint--email {
    color: #9c9c9c;
    font-size: 13px;
    font-style: italic;
    letter-spacing: 0.3px;
    margin-top: 6px;
    line-height: 1.4;
}

/* ── Error messages ───────────────────────────────────────────────────────── */
.tion-error {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #CC0000;
    min-height: 16px;
}

.tion-error--global {
    text-align: center;
    margin-bottom: 12px;
    font-size: 14px;
}

/* ── Attendee block — single column, every input full width ──────────────── */
.tion-attendee-block {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    border: none;
    border-radius: 0;
    padding: 0;
    margin-bottom: 24px;
}

.tion-attendee-header {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.tion-attendee-title {
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #9c9c9c;
}

/* 2-col rows collapse to one column — every input occupies full width */
.tion-row--2col {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* Single fields (ID/Passport) span full width */
.tion-attendee-block>.tion-field {
    grid-column: 1 / -1;
}

/* ── Add Attendee row ─────────────────────────────────────────────────────── */
.tion-form-add {
    margin-bottom: 20px;
}

/* ── Buttons ──────────────────────────────────────────────────────────────── */
.tion-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    padding: 10px 20px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 400;
    cursor: pointer;
    transition: opacity 0.15s;
    white-space: nowrap;
    -webkit-appearance: none;
    appearance: none;
    text-decoration: none;
}

.tion-btn:disabled,
.tion-btn[aria-disabled="true"] {
    opacity: 0.35;
    cursor: not-allowed;
}

/* Outlined — transparent bg, white border */
.tion-btn--outline {
    background: transparent;
    color: #ffffff;
    border: 1px solid #ffffff;
    border-radius: 12px;
}

.tion-btn--outline:hover:not(:disabled) {
    opacity: 0.75;
}

/* Submit — gradient fill, centered, auto width */
.tion-btn--submit {
    background: linear-gradient(90deg, #CC0000 0%, #FFFF00 50%, #CC0000 100%);
    border: none;
    border-radius: 12px;
    color: #000000;
    font-weight: 400;
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 14px 48px;
    height: auto;
    width: auto;
    display: block;
    margin: 24px auto 0;
    cursor: pointer;
}

.tion-btn--submit:hover:not(:disabled) {
    opacity: 0.88;
}

/* Submit wrap */
.tion-submit-wrap {
    text-align: center;
    padding: 16px 0;
}

/* Remove button */
.tion-btn--remove {
    background: transparent;
    border: 1px solid #CC0000;
    color: #CC0000;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 400;
    padding: 0 12px;
    height: 28px;
}

.tion-btn--remove:hover {
    background: #CC0000;
    color: #ffffff;
}

/* ── Payment proof upload area — dotted card, rounded, centered ────────── */
.tion-field--proof {
    border: 2px dashed #FFD400;
    border-radius: 16px;
    padding: 28px 20px;
    text-align: center;
    background: rgba(255, 212, 0, 0.04);
    margin-top: 24px;
    margin-bottom: 0;
    transition: background .2s, border-color .2s;
}

.tion-field--proof:hover {
    background: rgba(255, 212, 0, 0.08);
    border-color: #ffe74a;
}

/* Hidden file input — still included in FormData */
.tion-proof-input {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    overflow: hidden;
}

/* Label styled as the clickable "button" inside proof area */
.tion-proof-label {
    display: inline-block;
    background: transparent;
    border: none;
    color: #FFD400;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 600;
    padding: 0;
    cursor: pointer;
    height: auto;
    text-decoration: none;
}

.tion-proof-name {
    display: block;
    color: #ffffff;
    font-size: 13px;
    font-style: italic;
    margin-top: 8px;
}

/* ── Thank-you state ──────────────────────────────────────────────────────── */
.tion-thankyou {
    text-align: center;
    padding: 80px 24px;
    color: #ffffff;
    font-family: 'Jaini', system-ui, sans-serif;
}

.tion-form-wrap .tion-thankyou,
.tion-form-wrap .tion-thankyou * {
    color: #ffffff !important;
    font-family: 'Jaini', system-ui, sans-serif !important;
    text-align: center;
}

.tion-thankyou__title {
    font-size: 56px;
    font-weight: 400;
    color: #ffffff;
    margin: 0 0 24px;
    text-transform: uppercase;
    letter-spacing: 6px;
    line-height: 1.1;
}

.tion-thankyou__body {
    font-size: 18px;
    color: #ffffff;
    margin: 0 auto;
    max-width: 600px;
    line-height: 1.8;
}

.tion-thankyou__note {
    font-size: 14px;
    color: #9c9c9c;
    margin: 24px auto 0;
    max-width: 600px;
    line-height: 1.6;
    font-style: italic;
    letter-spacing: 0.5px;
}

/* ── Responsive — 1 column on mobile / tablet ────────────────────────────── */
@media (max-width: 900px) {
    .tion-form-wrap {
        padding: 24px 16px;
    }

    .tion-form-wrap .tion-attendee-block,
    .tion-attendee-block {
        grid-template-columns: 1fr !important;
    }

    .tion-form-wrap .tion-row--2col,
    .tion-row--2col {
        grid-template-columns: 1fr !important;
        display: grid !important;
    }

    .tion-form-wrap .tion-row--2col>.tion-field,
    .tion-row--2col>.tion-field {
        grid-column: 1 / -1 !important;
        width: 100% !important;
    }

    .tion-attendee-block>.tion-field {
        grid-column: 1 / -1;
    }

    .tion-input {
        width: 100% !important;
    }

    .tion-btn--outline {
        width: 100%;
        justify-content: center;
    }

    .tion-btn--submit {
        width: 100%;
        padding: 14px 24px;
    }

    .tion-thankyou {
        padding: 60px 16px;
    }

    .tion-thankyou__title {
        font-size: 40px;
        letter-spacing: 4px;
    }

    .tion-thankyou__body {
        font-size: 16px;
    }

    .tion-thankyou__note {
        font-size: 13px;
        margin-top: 18px;
    }

    /* Restore original (smaller) label & input sizes on mobile / tablet */
    .tion-form-wrap .tion-label {
        font-size: 15px;
        margin-bottom: 6px;
    }

    .tion-form-wrap .tion-optional {
        font-size: 12px;
    }

    .tion-form-wrap .tion-input {
        height: 40px;
        padding: 12px 16px;
        font-size: 14px;
    }
}

/* -- Force full-width on every form element regardless of theme overrides -- */
.tion-form-wrap .tion-form,
.tion-form-wrap #tion-attendees-wrap,
.tion-form-wrap .tion-attendee-block,
.tion-form-wrap .tion-row,
.tion-form-wrap .tion-row--2col,
.tion-form-wrap .tion-field,
.tion-form-wrap .tion-form-add {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

.tion-form-wrap .tion-input,
.tion-form-wrap input.tion-input,
.tion-form-wrap input[type="text"].tion-input,
.tion-form-wrap input[type="email"].tion-input,
.tion-form-wrap input[type="tel"].tion-input,
.tion-form-wrap input[type="number"].tion-input {
    width: 100% !important;
    max-width: 100% !important;
    display: block !important;
    box-sizing: border-box !important;
}

.tion-form-wrap .tion-btn--outline {
    width: 100% !important;
    max-width: 100% !important;
    justify-content: center !important;
}