:root {
    --tf-primary: #6857f5;
    --tf-primary-dark: #4435c9;
    --tf-accent: #18b98a;
    --tf-danger: #ef4444;
    --tf-warning: #f59e0b;
    --tf-text: #172033;
    --tf-muted: #657085;
    --tf-border: #e8ebf2;
    --tf-surface: #ffffff;
    --tf-background: #f5f7fb;
    --tf-shadow: 0 28px 70px rgba(25, 35, 66, 0.14);
}

body.tf-registration-open {
    overflow: hidden;
}

.tf-event-page {
    position: relative;
    min-height: 100vh;
    padding: 48px 20px 80px;
    background:
        radial-gradient(
            circle at 5% 10%,
            rgba(104, 87, 245, 0.13),
            transparent 32%
        ),
        radial-gradient(
            circle at 95% 90%,
            rgba(24, 185, 138, 0.12),
            transparent 32%
        ),
        var(--tf-background);
    color: var(--tf-text);
    font-family:
        Inter,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}

.tf-event-container {
    width: min(1180px, 100%);
    margin: 0 auto;
}

.tf-event-navigation {
    margin-bottom: 18px;
}

.tf-back-link {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--tf-muted);
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
}

.tf-back-link:hover {
    color: var(--tf-primary);
}

.tf-event-card {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 30px;
    background: var(--tf-surface);
    box-shadow: var(--tf-shadow);
}

.tf-event-hero {
    position: relative;
    min-height: 460px;
    overflow: hidden;
    background: #171a29;
}

.tf-event-featured-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tf-event-placeholder {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background:
        linear-gradient(
            135deg,
            #2f2465,
            #6857f5 55%,
            #19b98a
        );
    color: #fff;
    font-size: clamp(34px, 6vw, 70px);
    font-weight: 800;
}

.tf-event-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            90deg,
            rgba(10, 15, 30, 0.88),
            rgba(10, 15, 30, 0.44) 55%,
            rgba(10, 15, 30, 0.2)
        ),
        linear-gradient(
            0deg,
            rgba(10, 15, 30, 0.65),
            transparent 55%
        );
}

.tf-event-hero-content {
    position: absolute;
    z-index: 2;
    left: 0;
    bottom: 0;
    width: min(780px, 100%);
    padding: clamp(30px, 6vw, 70px);
    color: #fff;
}

.tf-event-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 22px;
}

.tf-type-badge,
.tf-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 31px;
    padding: 6px 13px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.tf-type-badge {
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(12px);
}

.tf-status-upcoming {
    background: #fff2cc;
    color: #8b5d00;
}

.tf-status-live {
    background: #fee2e2;
    color: #b91c1c;
    animation: tf-live-pulse 1.8s infinite;
}

.tf-status-past {
    background: #e8ebf0;
    color: #4d5668;
}

@keyframes tf-live-pulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.35);
    }

    50% {
        box-shadow: 0 0 0 9px rgba(239, 68, 68, 0);
    }
}

.tf-event-title {
    max-width: 800px;
    margin: 0 0 17px;
    color: #fff;
    font-size: clamp(36px, 5.8vw, 72px);
    line-height: 1.04;
    letter-spacing: -0.045em;
}

.tf-event-host-line {
    font-size: 17px;
    color: rgba(255, 255, 255, 0.82);
}

.tf-event-host-line strong {
    color: #fff;
}

.tf-event-body {
    display: grid;
    grid-template-columns:
        minmax(0, 1.65fr)
        minmax(290px, 0.75fr);
    gap: 38px;
    padding: clamp(28px, 5vw, 58px);
}

.tf-live-section {
    margin-bottom: 42px;
}

.tf-video-wrapper {
    position: relative;
    overflow: hidden;
    padding-bottom: 56.25%;
    border-radius: 23px;
    background: #080b12;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
}

.tf-video-wrapper iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.tf-video-state {
    display: grid;
    min-height: 300px;
    place-items: center;
    align-content: center;
    padding: 40px;
    border: 1px solid var(--tf-border);
    border-radius: 23px;
    background:
        linear-gradient(
            135deg,
            rgba(104, 87, 245, 0.08),
            rgba(24, 185, 138, 0.08)
        ),
        #fff;
    text-align: center;
}

.tf-countdown-icon {
    display: grid;
    width: 62px;
    height: 62px;
    margin-bottom: 16px;
    place-items: center;
    border-radius: 20px;
    background: var(--tf-primary);
    color: #fff;
    font-size: 30px;
}

.tf-eyebrow,
.tf-section-label {
    margin: 0 0 9px;
    color: var(--tf-primary);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.tf-countdown {
    color: var(--tf-text);
    font-size: clamp(25px, 4vw, 43px);
    font-weight: 800;
    letter-spacing: -0.03em;
}

.tf-content-section {
    padding: 4px 2px;
}

.tf-content-section h2 {
    color: var(--tf-text);
}

.tf-description {
    color: var(--tf-muted);
    font-size: 17px;
    line-height: 1.85;
}

.tf-description p:first-child {
    margin-top: 0;
}

.tf-event-sidebar {
    position: relative;
}

.tf-info-card {
    position: sticky;
    top: 30px;
    padding: 28px;
    border: 1px solid var(--tf-border);
    border-radius: 23px;
    background: #fff;
    box-shadow: 0 15px 38px rgba(27, 36, 64, 0.08);
}

.tf-info-card h2 {
    margin: 0 0 25px;
    color: var(--tf-text);
    font-size: 22px;
}

.tf-info-row {
    display: grid;
    grid-template-columns: 45px 1fr;
    gap: 14px;
    align-items: center;
    padding: 17px 0;
    border-bottom: 1px solid var(--tf-border);
}

.tf-info-icon {
    display: grid;
    width: 45px;
    height: 45px;
    place-items: center;
    border-radius: 14px;
    background: #f0efff;
    font-size: 18px;
}

.tf-info-label {
    display: block;
    margin-bottom: 4px;
    color: var(--tf-muted);
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.tf-info-row strong {
    display: block;
    color: var(--tf-text);
    font-size: 14px;
    line-height: 1.45;
}

.tf-price-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 25px;
    padding: 20px;
    border-radius: 17px;
    background:
        linear-gradient(
            135deg,
            var(--tf-primary),
            var(--tf-primary-dark)
        );
    color: #fff;
}

.tf-price-box span {
    color: rgba(255, 255, 255, 0.76);
    font-size: 13px;
}

.tf-price-box strong {
    font-size: 23px;
}

.tf-timezone-note {
    margin-top: 16px;
    color: var(--tf-muted);
    font-size: 12px;
    text-align: center;
}

/*
 * Registration gate
 */
.tf-event-content {
    transition:
        filter 0.35s ease,
        transform 0.35s ease;
}

.tf-event-content-locked {
    pointer-events: none;
    user-select: none;
    filter: blur(10px);
    transform: scale(0.992);
}

.tf-registration-overlay {
    position: fixed;
    z-index: 999999;
    inset: 0;
    display: grid;
    overflow-y: auto;
    place-items: center;
    padding: 24px;
    background: rgba(11, 16, 30, 0.72);
    backdrop-filter: blur(14px);
    opacity: 1;
    transition:
        opacity 0.35s ease,
        visibility 0.35s ease;
}

.tf-registration-overlay-hidden {
    visibility: hidden;
    opacity: 0;
}

.tf-registration-modal {
    position: relative;
    width: min(510px, 100%);
    overflow: hidden;
    padding: clamp(28px, 5vw, 45px);
    border: 1px solid rgba(255, 255, 255, 0.65);
    border-radius: 29px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 38px 100px rgba(0, 0, 0, 0.35);
    animation: tf-modal-enter 0.4s ease;
}

@keyframes tf-modal-enter {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.97);
    }

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

.tf-modal-decoration {
    position: absolute;
    top: -115px;
    right: -95px;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background:
        linear-gradient(
            135deg,
            rgba(104, 87, 245, 0.25),
            rgba(24, 185, 138, 0.18)
        );
}

.tf-modal-header {
    position: relative;
    margin-bottom: 28px;
}

.tf-modal-label {
    display: inline-flex;
    margin-bottom: 12px;
    padding: 7px 11px;
    border-radius: 999px;
    background: #eeecff;
    color: var(--tf-primary);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.tf-modal-header h2 {
    margin: 0 0 10px;
    color: var(--tf-text);
    font-size: clamp(27px, 5vw, 36px);
    line-height: 1.14;
    letter-spacing: -0.035em;
}

.tf-modal-header p {
    margin: 0;
    color: var(--tf-muted);
    font-size: 15px;
    line-height: 1.65;
}

.tf-form-field {
    margin-bottom: 18px;
}

.tf-form-field label {
    display: block;
    margin-bottom: 8px;
    color: var(--tf-text);
    font-size: 13px;
    font-weight: 700;
}

.tf-form-field input {
    width: 100%;
    min-height: 52px;
    box-sizing: border-box;
    padding: 12px 15px;
    border: 1px solid #dce0e9;
    border-radius: 13px;
    outline: none;
    background: #fafbfe;
    color: var(--tf-text);
    font-size: 15px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.tf-form-field input:focus {
    border-color: var(--tf-primary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(104, 87, 245, 0.12);
}

.tf-form-field-invalid input {
    border-color: var(--tf-danger);
}

.tf-field-error {
    display: block;
    min-height: 18px;
    margin-top: 5px;
    color: var(--tf-danger);
    font-size: 12px;
}

.tf-paid-notice {
    margin-bottom: 18px;
    padding: 13px 15px;
    border: 1px solid #fde6a8;
    border-radius: 12px;
    background: #fff8e5;
    color: #7b5700;
    font-size: 13px;
    line-height: 1.5;
}

.tf-form-message {
    min-height: 20px;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 600;
}

.tf-form-message-success {
    color: var(--tf-accent);
}

.tf-form-message-error {
    color: var(--tf-danger);
}

.tf-submit-button {
    display: flex;
    width: 100%;
    min-height: 54px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 14px;
    background:
        linear-gradient(
            135deg,
            var(--tf-primary),
            var(--tf-primary-dark)
        );
    box-shadow: 0 13px 28px rgba(104, 87, 245, 0.28);
    color: #fff;
    cursor: pointer;
    font-size: 15px;
    font-weight: 800;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.tf-submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 17px 34px rgba(104, 87, 245, 0.33);
}

.tf-submit-button:disabled {
    cursor: not-allowed;
    opacity: 0.75;
    transform: none;
}

.tf-button-loader {
    width: 17px;
    height: 17px;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-top-color: #fff;
    border-radius: 50%;
    animation: tf-spin 0.75s linear infinite;
}

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

.tf-privacy-note {
    margin: 15px 0 0;
    color: #8991a1;
    font-size: 11px;
    line-height: 1.5;
    text-align: center;
}

@media (max-width: 900px) {
    .tf-event-body {
        grid-template-columns: 1fr;
    }

    .tf-info-card {
        position: static;
    }
}

@media (max-width: 640px) {
    .tf-event-page {
        padding: 20px 12px 50px;
    }

    .tf-event-card {
        border-radius: 22px;
    }

    .tf-event-hero {
        min-height: 400px;
    }

    .tf-event-overlay {
        background:
            linear-gradient(
                0deg,
                rgba(10, 15, 30, 0.9),
                rgba(10, 15, 30, 0.25)
            );
    }

    .tf-event-hero-content {
        padding: 27px 23px;
    }

    .tf-event-title {
        font-size: 37px;
    }

    .tf-event-body {
        gap: 27px;
        padding: 23px 18px 30px;
    }

    .tf-registration-overlay {
        align-items: start;
        padding: 15px;
    }

    .tf-registration-modal {
        margin: 20px 0;
        padding: 28px 20px;
        border-radius: 22px;
    }
}