@import url('https://fonts.googleapis.com/css2?family=Kaushan+Script&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

@font-face {
    font-family: Conthrax-bold;
    src: url(Conthrax-Font/Conthrax\ Bold.otf);
}

@font-face {
    font-family: Conthrax-light;
    src: url(Conthrax-Font/Conthrax\ Light.otf);
}

html,
body {
    height: auto !important;
    min-height: 100vh !important;
    overflow-x: hidden;
    overflow-y: auto !important;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

* {
    box-sizing: border-box;
}

:root {
    /* Theme: Light Indian Heritage x Innovation */
    --body-color: #F9FAFB;
    --prim-color: #FF9933;
    --sec-color: #138808;
    --accent-blue: #000080;

    /* Gradients */
    --gradient-color: linear-gradient(90deg, #FF9933 0%, #FFFFFF 50%, #138808 100%);
    --text-gradient: linear-gradient(90deg, #FF9933 0%, #000080 50%, #138808 100%);
    --btn-gradient: linear-gradient(135deg, #FF9933 0%, #FF7B02 100%);

    --white-color: #ffffff;
    --black-color: #000000;
    --light-border: rgba(0, 0, 128, 0.1);
    --light-text: #4B5563;

    --Conthrax-bold: Conthrax-bold;
    --Conthrax-light: Conthrax-light;

    --transition: .3s;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    background-color: var(--body-color);
    position: relative;
    padding: 0;
}

/* Background Shapes */
.bg_shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    z-index: -1;
}

.bg_shape1 {
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: var(--prim-color);
}

.bg_shape2 {
    bottom: -10%;
    left: -5%;
    width: 600px;
    height: 600px;
    background: var(--sec-color);
}

/* Registration Box */
.box {
    position: relative;
    width: 90%;
    max-width: 700px;
    border-radius: 20px;
    padding: 4px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    /* Removed overflow: hidden to prevent clipping popovers like Datepicker */
    background: transparent;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    margin: auto;
    margin-top: 20px;
    margin-bottom: 20px;
    z-index: 5;
}

/* Background Layer to contain the rotating border */
.box-border-glow {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    overflow: hidden;
    /* Clips the rotating gradient */
    z-index: 1;
}

/* Rotating Gradient Border */
.box-border-glow::before {
    content: '';
    position: absolute;
    left: -50%;
    top: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(transparent, transparent, transparent, var(--prim-color), var(--white-color), var(--sec-color));
    animation: rotateBorder 4s linear infinite;
    z-index: 0;
}

/* Card Background (Inset) */
.box::after {
    content: '';
    position: absolute;
    inset: 4px;
    /* Matches padding */
    background: rgba(255, 255, 255, 0.9);
    border-radius: 16px;
    /* slightly smaller than box radius */
    z-index: 2;
    backdrop-filter: blur(12px);
}

.box form {
    width: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 10;
    /* Sit above the background and after pseudo */
    padding: 40px;
}

@keyframes rotateBorder {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Section visibility — hide all sections except the first by default.
   This prevents a flash of all forms before JS can run .hide(). */
#section-2,
#section-events,
#section-3 {
    display: none;
}

.form-step {
    width: 100%;
}

.box h2 {
    color: var(--accent-blue);
    font-family: var(--Conthrax-bold);
    font-size: 2rem;
    margin-bottom: 25px;
    text-align: center;
    background: var(--text-gradient);
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Container for side-by-side inputs */
.input-container {
    display: flex;
    gap: 20px;
    width: 100%;
    margin-bottom: 5px;
    flex-wrap: wrap;
}

.inputBox {
    position: relative;
    width: 100%;
    margin-bottom: 25px;
    flex: 1;
    /* For flex children */
}

.inputBox input,
.inputBox select {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid #e1e1e1;
    border-radius: 10px;
    outline: none;
    color: var(--black-color);
    font-size: 0.95rem;
    transition: var(--transition);
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    box-sizing: border-box;
}

.inputBox select {
    cursor: pointer;
    padding-right: 40px;
    background-color: rgba(255, 255, 255, 0.5);
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234B5563' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
    min-height: 46px;
}

.inputBox select option {
    padding: 10px;
    font-size: 0.95rem;
    color: var(--black-color);
}

.inputBox input:focus,
.inputBox input:valid,
.inputBox select:focus,
.inputBox select:valid {
    border-color: var(--prim-color);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(255, 153, 51, 0.1);
}

.inputBox label {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--light-text);
    font-size: 0.95rem;
    pointer-events: none;
    transition: var(--transition);
    background: transparent;
    padding: 0 5px;
}

/* Move label up on focus or valid content */
/* Move label up on focus, valid content, or for date inputs */
.inputBox input:focus~label,
.inputBox input:valid~label,
.inputBox select:focus~label,
.inputBox select:valid~label,
.inputBox input[type="date"]~label,
.dob-label,
.inputBox input:focus~.label,
.inputBox input:valid~.label,
.inputBox input[type="date"]~.dob-label {
    top: 0;
    font-size: 0.8rem;
    color: var(--prim-color);
    background: #fff;
    font-weight: 500;
}

/* Gender Group */
.gender-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    margin-bottom: 25px;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid #e1e1e1;
    border-radius: 10px;
    padding: 10px 15px;
}

.gender-field {
    display: flex;
    align-items: center;
    gap: 15px;
}

.gender-field div {
    font-size: 0.95rem;
    color: var(--light-text);
    font-weight: 500;
}

.gender-field label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.95rem;
    color: var(--black-color);
    cursor: pointer;
}

.gender-field input[type="radio"] {
    accent-color: var(--prim-color);
    width: 16px;
    height: 16px;
}

/* Eye Icon */
.eye-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--light-text) !important;
    background: transparent !important;
    z-index: 10;
}

.eye-icon i {
    font-size: 1.1rem !important;
}

.eye-icon:hover i {
    color: var(--prim-color) !important;
}

/* Button */
button,
.button-43 {
    width: 100%;
    height: 45px;
    border-radius: 50px;
    background: var(--btn-gradient);
    background-size: 200% 200%;
    color: var(--white-color);
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: var(--Conthrax-light);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    margin-top: 10px;
}

button:hover,
.button-43:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 123, 2, 0.4);
}

/* Below text / Back links */
.below_text {
    text-align: center;
    margin-top: 15px;
}

.below_text p {
    color: var(--light-text) !important;
    font-size: 0.85rem !important;
}

.below_text a,
.form-step a {
    color: var(--accent-blue) !important;
    font-weight: 500;
    text-decoration: none;
    transition: var(--transition);
}

.below_text a:hover,
.form-step a:hover {
    text-decoration: underline;
    color: var(--prim-color) !important;
}

/* Error messages */
.error {
    color: #dc2626;
    font-size: 0.75rem;
    margin-top: 4px;
    display: block;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .input-container {
        flex-direction: column;
        gap: 0;
    }

    .box {
        padding: 3px;
    }

    .box form {
        padding: 25px 20px;
    }

    .box h2 {
        font-size: 1.8rem;
    }

    .gender-group {
        margin-bottom: 25px;
    }

    .inputBox input,
    .inputBox select {
        font-size: 0.9rem;
    }
}

/* New classes to replace inline styles */
.info-text {
    text-align: center;
    font-size: 0.85rem;
    color: var(--light-text);
}

.otp-sent-text {
    text-align: center;
    color: var(--black-color);
    margin-bottom: 20px;
    font-weight: 500;
}

.back-link-container {
    text-align: center;
    margin-top: 10px;
}

.back-link {
    color: var(--accent-blue);
    text-decoration: underline;
    font-size: 0.85rem;
    transition: var(--transition);
}

.back-link:hover {
    color: var(--prim-color);
}

/* ══════════════════════════════════════════════════ */
/* Event Selection Cards (legacy)                     */
/* ══════════════════════════════════════════════════ */

.event-select-card {
    border: 2px solid #e1e1e1;
    border-radius: 12px;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    overflow: hidden;
}

.event-select-card:hover {
    border-color: rgba(255, 153, 51, 0.4);
    box-shadow: 0 4px 15px rgba(255, 153, 51, 0.1);
}

.event-select-card.selected {
    border-color: var(--prim-color);
    background: linear-gradient(135deg, rgba(255, 153, 51, 0.05) 0%, rgba(19, 136, 8, 0.05) 100%);
    box-shadow: 0 4px 20px rgba(255, 153, 51, 0.15);
}

.event-select-header {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    cursor: pointer;
    gap: 12px;
}

/* Custom checkbox */
.event-checkbox-label {
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
    flex-shrink: 0;
}

.event-checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.event-checkbox-custom {
    width: 22px;
    height: 22px;
    border: 2px solid #ccc;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: white;
    flex-shrink: 0;
}

.event-checkbox-label input:checked+.event-checkbox-custom {
    background: var(--btn-gradient);
    border-color: var(--prim-color);
}

.event-checkbox-label input:checked+.event-checkbox-custom::after {
    content: '✓';
    color: white;
    font-size: 14px;
    font-weight: 700;
}

.event-select-info {
    flex: 1;
    min-width: 0;
}

.event-select-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--black-color);
    margin: 0;
    line-height: 1.3;
}

.event-select-tagline {
    font-size: 0.78rem;
    color: var(--light-text);
    margin: 2px 0 0;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.event-select-fee {
    font-weight: 700;
    font-size: 1rem;
    color: var(--prim-color);
    white-space: nowrap;
    flex-shrink: 0;
}

.event-expand-btn {
    width: auto !important;
    height: auto !important;
    background: none !important;
    border: none !important;
    color: var(--light-text) !important;
    cursor: pointer;
    padding: 4px 8px !important;
    margin: 0 !important;
    font-size: 0.85rem;
    transition: transform 0.2s ease;
    box-shadow: none !important;
    flex-shrink: 0;
}

.event-expand-btn:hover {
    color: var(--prim-color) !important;
    transform: none !important;
    box-shadow: none !important;
}

/* Sub-event panel */
.event-sub-panel {
    border-top: 1px solid #eee;
    padding: 10px 15px 10px 52px;
    background: rgba(249, 250, 251, 0.8);
}

.sub-event-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
    cursor: pointer;
    font-size: 0.88rem;
    color: var(--black-color);
}

.sub-event-item input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.sub-event-checkbox-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #ccc;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: white;
    flex-shrink: 0;
}

.sub-event-item input:checked+.sub-event-checkbox-custom {
    background: var(--sec-color);
    border-color: var(--sec-color);
}

.sub-event-item input:checked+.sub-event-checkbox-custom::after {
    content: '✓';
    color: white;
    font-size: 11px;
    font-weight: 700;
}

.sub-event-name {
    font-weight: 500;
}

.sub-event-desc {
    font-size: 0.78rem;
    color: var(--light-text);
    margin-left: auto;
}

/* ══════════════════════════════════════════════════ */
/* Category Dropdown Selection (New)                  */
/* ══════════════════════════════════════════════════ */

#main-event-select {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid #e1e1e1;
    border-radius: 10px;
    outline: none;
    color: var(--black-color);
    font-size: 0.95rem;
    transition: var(--transition);
    cursor: pointer;
    padding-right: 40px;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234B5563' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

#main-event-select:focus {
    border-color: var(--prim-color);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(255, 153, 51, 0.1);
}

/* Selected Category Card */
.selected-category-card {
    border: 2px solid var(--prim-color);
    border-radius: 12px;
    margin-bottom: 12px;
    background: linear-gradient(135deg, rgba(255, 153, 51, 0.05) 0%, rgba(19, 136, 8, 0.05) 100%);
    overflow: hidden;
    animation: fadeInCard 0.3s ease;
}

@keyframes fadeInCard {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.selected-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 15px;
    background: linear-gradient(135deg, rgba(255, 153, 51, 0.1) 0%, rgba(19, 136, 8, 0.08) 100%);
    border-bottom: 1px solid rgba(255, 153, 51, 0.15);
}

.selected-category-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.selected-category-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--black-color);
}

.selected-category-price {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--prim-color);
    background: rgba(255, 153, 51, 0.1);
    padding: 2px 10px;
    border-radius: 20px;
}

.remove-category-btn {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px;
    background: rgba(220, 38, 38, 0.08) !important;
    border: 1px solid rgba(220, 38, 38, 0.2) !important;
    border-radius: 50% !important;
    color: #dc2626 !important;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    flex-shrink: 0;
}

.remove-category-btn:hover {
    background: rgba(220, 38, 38, 0.15) !important;
    border-color: #dc2626 !important;
    transform: none !important;
    box-shadow: none !important;
}

/* Sub-events panel within category card */
.sub-events-panel {
    padding: 10px 15px 12px;
    background: rgba(255, 255, 255, 0.6);
}

.sub-events-title {
    font-size: 0.78rem;
    color: var(--light-text);
    font-weight: 500;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sub-event radio items */
.sub-event-radio-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
    cursor: pointer;
    font-size: 0.88rem;
    color: var(--black-color);
}

.sub-event-radio-item input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.sub-event-radio-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #ccc;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: white;
    flex-shrink: 0;
}

.sub-event-radio-item input:checked+.sub-event-radio-custom {
    background: white;
    border-color: var(--sec-color);
    border-width: 5px;
}

.sub-event-radio-name {
    font-weight: 500;
}

/* Scrollbar for selected events list */
#selected-events-list::-webkit-scrollbar {
    width: 5px;
}

#selected-events-list::-webkit-scrollbar-track {
    background: transparent;
}

#selected-events-list::-webkit-scrollbar-thumb {
    background: rgba(255, 153, 51, 0.3);
    border-radius: 3px;
}

#selected-events-list::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 153, 51, 0.5);
}

/* Datepicker Overrides (Fix DOB clipping/scrolling) */
.datepicker {
    width: 280px !important;
    border-radius: 12px !important;
    border: 1px solid var(--light-border) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
    z-index: 9999 !important;
}

.datepicker--content {
    padding: 10px !important;
}

/* Year Selection: Make it a scrollable list */
.datepicker--cells-years {
    height: 220px !important;
    overflow-y: auto !important;
    display: block !important;
    padding-right: 5px;
}

.datepicker--cells-years::-webkit-scrollbar {
    width: 4px;
}

.datepicker--cells-years::-webkit-scrollbar-thumb {
    background: var(--prim-color);
    border-radius: 10px;
}

.datepicker--cell-year {
    width: 50% !important;
    height: 45px !important;
    display: inline-flex !important;
    font-size: 0.95rem !important;
}

/* Date and Month Selection: Expand to show all, no internal scrolling */
.datepicker--cells-months,
.datepicker--cells-days {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
}

.datepicker--cells-months {
    display: flex !important;
    flex-wrap: wrap !important;
}

.datepicker--cell-month {
    height: 55px !important;
}

.datepicker--nav {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    padding: 8px !important;
}

.datepicker--nav-title {
    font-weight: 600 !important;
    color: var(--accent-blue) !important;
}