/* =========================================
   MODAL REGISTRATION - CLEAN COMPACT DESIGN
   Based on React Component Example
   ========================================= */

/* Modal Overlay - Glassmorphism Backdrop */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
    animation: fadeIn 0.3s ease-out;
}

/* Modal Container - Glassmorphism with Zoom Animation */
.modal-content {
    background: linear-gradient(145deg,
            rgba(26, 26, 46, 0.95) 0%,
            rgba(15, 23, 42, 0.98) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 24px;
    max-width: 420px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow:
        0 25px 50px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    animation: zoomIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: center center;
}

/* Tabs - Compact */
.modal-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    padding: 4px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.mtab {
    flex: 1;
    padding: 10px 12px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mtab.active {
    background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Step Progress - ABSOLUTE HORIZONTAL FORCE */
.steps-progress-mini {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    /* Changed from center to align top */
    width: 100% !important;
    margin-bottom: 24px;
    padding: 0 10px;
    position: relative;
    box-sizing: border-box;
}

/* Horizontal Line Background */
.steps-progress-mini::before {
    content: '';
    position: absolute;
    top: 14px;
    /* Center with 28px circle */
    left: 40px;
    right: 40px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 0;
}

/* Individual Step Item */
.step-dot {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    position: relative;
    z-index: 1;
    flex: 1;
    min-width: 0;
    /* Fix flex overflow */
}

/* Step Circle */
.step-dot>span {
    width: 32px;
    /* Slightly larger */
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    margin-bottom: 8px;
    /* Space between circle and text */
}

/* Active Step Circle - Rich Gradient */
.step-dot.active>span {
    background: linear-gradient(135deg, #34d399 0%, #059669 100%);
    /* Brighter Green Gradient */
    border: none;
    color: #fff;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.6), inset 0 0 10px rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Completed Step Circle */
.step-dot.completed>span {
    background: linear-gradient(135deg, #10b981 0%, #064e3b 100%);
    border: none;
    color: #fff;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

/* Step Label */
.step-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
    opacity: 0.7;
    transition: all 0.3s;
}

.step-dot.active .step-label {
    color: #34d399;
    font-weight: 700;
    opacity: 1;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

/* Form Step Container - Clean No Border */
.reg-step {
    padding: 0;
    background: transparent;
    border: none;
    margin-bottom: 0;
}

.step-title-mini {
    font-size: 1.125rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Form Labels & Inputs */
.mlabel {
    display: block;
    margin-bottom: 8px;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

.minput,
select.minput {
    width: 100%;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(138, 43, 226, 0.3);
    border-radius: 8px;
    color: #fff;
    font-size: 0.9375rem;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.minput:focus,
select.minput:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.minput::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

/* ✅ FIX: Dropdown options visibility */
select.minput option {
    background: #1a1a2e;
    color: #ffffff;
    padding: 12px;
}

select.minput option:hover,
select.minput option:checked {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #ffffff;
}

/* Buttons - Clean & Modern */
.step-buttons {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    padding: 0;
    background: transparent;
    border: none;
}

.step-buttons[hidden] {
    display: none !important;
}

.mbtn {
    width: 100%;
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.mbtn.primary {
    background: linear-gradient(135deg, #34d399 0%, #10b981 50%, #059669 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    border: none;
}

.mbtn.primary:hover {
    background: linear-gradient(135deg, #10b981 0%, #059669 50%, #047857 100%);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.6);
    transform: translateY(-2px);
}

.mbtn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.mbtn.secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Close Button */
.mclose {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.mclose:hover {
    background: rgba(255, 0, 0, 0.2);
    color: #ff4444;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.85);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes zoomOut {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.85);
    }
}

/* Modal closing animation */
.modal.closing .modal-content {
    animation: zoomOut 0.25s ease-in forwards;
}

/* Scrollbar */
.modal-content::-webkit-scrollbar {
    width: 6px;
}

.modal-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: rgba(16, 185, 129, 0.5);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(16, 185, 129, 0.7);
}