/* ============================================================
   Theme Index1 v2: "Clean Elevated" — Premium Light Glassmorphism
   Full game-changer upgrade — Bootstrap 5 + CSS Animations
   ============================================================ */

/* --- CSS Custom Properties --- */
:root {
    --idx1-primary: #4361ee;
    --idx1-primary-rgb: 67, 97, 238;
    --idx1-primary-light: #6c85f7;
    --idx1-primary-dark: #3a50c2;
    --idx1-accent: #7209b7;
    --idx1-accent-rgb: 114, 9, 183;
    --idx1-accent-light: #9d4edd;
    --idx1-secondary: #f72585;
    --idx1-secondary-rgb: 247, 37, 133;
    --idx1-success: #06d6a0;
    --idx1-bg-start: #eef2ff;
    --idx1-bg-mid: #fdf2f8;
    --idx1-bg-end: #ede9fe;
    --idx1-card-bg: rgba(255, 255, 255, 0.72);
    --idx1-card-bg-solid: #ffffff;
    --idx1-text: #1e293b;
    --idx1-text-muted: #64748b;
    --idx1-text-light: #94a3b8;
    --idx1-border: rgba(255, 255, 255, 0.6);
    --idx1-border-subtle: rgba(0, 0, 0, 0.06);
    --idx1-input-bg: rgba(255, 255, 255, 0.7);
    --idx1-input-border: rgba(203, 213, 225, 0.6);
    --idx1-input-focus: var(--idx1-primary);

    /* Shared component aliases */
    --aff-primary: var(--idx1-primary);
    --aff-primary-rgb: var(--idx1-primary-rgb);
    --aff-primary-dark: var(--idx1-primary-dark);
    --aff-primary-light: var(--idx1-primary-light);
    --aff-text: var(--idx1-text);
    --aff-text-muted: var(--idx1-text-muted);
    --aff-radius: 0.75rem;
    --aff-input-bg: #f8fafc;
    --aff-input-border: #cbd5e1;
    --idx1-radius: 1.5rem;
    --idx1-radius-sm: 0.875rem;
    --idx1-shadow: 0 8px 32px rgba(67, 97, 238, 0.08), 0 2px 16px rgba(0, 0, 0, 0.04);
    --idx1-shadow-hover: 0 20px 60px rgba(67, 97, 238, 0.14), 0 8px 24px rgba(0, 0, 0, 0.06);
    --idx1-shadow-glow: 0 0 40px rgba(67, 97, 238, 0.12), 0 0 80px rgba(114, 9, 183, 0.06);
}

/* --- Base & Background --- */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

body {
    background-color: var(--idx1-bg-start);
    background-image: url('../img/bg-01.svg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--idx1-text);
    min-height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* Floating shapes - hidden (kept for compatibility) */
.idx1-shapes-container {
    display: none;
}

/* --- Navbar: Frosted Glass --- */
.idx1-navbar {
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.5);
    padding: 0.75rem 0;
    z-index: 1050;
    transition: all 0.3s ease;
}

.idx1-navbar .navbar-brand img {
    max-width: 200px;
    max-height: 45px;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.idx1-navbar .navbar-brand img:hover {
    transform: scale(1.04);
}

.idx1-navbar .navbar-brand img.customLogoClass {
    max-width: none;
    max-height: none;
}

/* Language dropdown */
.language-changer {
    position: relative;
    color: var(--idx1-text);
}

.language-changer > a {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    color: var(--idx1-text);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    padding: 0.45rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.language-changer > a:hover,
.language-changer > a:focus {
    background: linear-gradient(135deg, var(--idx1-primary), var(--idx1-accent));
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(var(--idx1-primary-rgb), 0.3);
}

.selected-language {
    width: 24px;
    margin-right: 8px;
}

.country-wrap .dropdown-item img {
    width: 20px;
    margin-right: 8px;
}

.dropdown-menu.country-wrap,
.country-wrap.dropdown-menu {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: var(--idx1-radius-sm);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 0.5rem 0;
    overflow: hidden;
}

.country-wrap .dropdown-item {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    border-radius: 0;
}

.country-wrap .dropdown-item:hover {
    background: linear-gradient(135deg, rgba(var(--idx1-primary-rgb), 0.08), rgba(var(--idx1-accent-rgb), 0.05));
}

/* --- Page Wrapper --- */
.idx1-page-wrapper {
    padding-top: 100px;
    padding-bottom: 40px;
    position: relative;
    z-index: 1;
    flex: 1 0 auto;
}

/* --- Card: Light Glassmorphism --- */
.idx1-card {
    background: var(--idx1-card-bg);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--idx1-border);
    border-radius: var(--idx1-radius);
    box-shadow: var(--idx1-shadow);
    padding: 2.5rem 2rem 2rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.idx1-card:hover {
    box-shadow: var(--idx1-shadow-hover), var(--idx1-shadow-glow);
    transform: translateY(-2px);
}

/* Animated gradient top border (thicker, more visible) */
.idx1-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg,
        var(--idx1-primary),
        var(--idx1-accent),
        var(--idx1-secondary),
        var(--idx1-accent),
        var(--idx1-primary));
    background-size: 300% 100%;
    animation: shimmerBorder 4s linear infinite;
}

/* Subtle inner glow */
.idx1-card::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(180deg, rgba(var(--idx1-primary-rgb), 0.03), transparent);
    pointer-events: none;
    z-index: 0;
}

.idx1-card > * {
    position: relative;
    z-index: 1;
}

@keyframes shimmerBorder {
    0% { background-position: 300% 0; }
    100% { background-position: -300% 0; }
}

/* --- Card Header Icon (Animated) --- */
.idx1-header-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--idx1-primary), var(--idx1-accent));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow:
        0 8px 25px rgba(var(--idx1-primary-rgb), 0.3),
        0 0 0 6px rgba(var(--idx1-primary-rgb), 0.08),
        0 0 0 12px rgba(var(--idx1-primary-rgb), 0.04);
    animation: iconPulse 3s ease-in-out infinite;
    position: relative;
}

.idx1-header-icon i {
    font-size: 1.6rem;
    color: #fff;
}

@keyframes iconPulse {
    0%, 100% {
        box-shadow:
            0 8px 25px rgba(var(--idx1-primary-rgb), 0.3),
            0 0 0 6px rgba(var(--idx1-primary-rgb), 0.08),
            0 0 0 12px rgba(var(--idx1-primary-rgb), 0.04);
    }
    50% {
        box-shadow:
            0 8px 30px rgba(var(--idx1-primary-rgb), 0.4),
            0 0 0 8px rgba(var(--idx1-primary-rgb), 0.12),
            0 0 0 16px rgba(var(--idx1-primary-rgb), 0.06);
    }
}

.idx1-card-title {
    color: var(--idx1-text);
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
    letter-spacing: -0.01em;
}

.idx1-card-subtitle {
    color: var(--idx1-text-muted);
    font-size: 0.9rem;
    font-weight: 400;
}

/* --- Nav Pills: Glass Style --- */
.idx1-nav-pills {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
    border-radius: var(--idx1-radius-sm);
    padding: 0.3rem;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.03);
}

.idx1-nav-pills .nav-link {
    color: var(--idx1-text-muted);
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 0.65rem;
    padding: 0.65rem 1rem;
    transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    text-align: center;
    border: none;
    position: relative;
    overflow: hidden;
}

.idx1-nav-pills .nav-link:hover {
    color: var(--idx1-primary);
    background: rgba(var(--idx1-primary-rgb), 0.06);
}

.idx1-nav-pills .nav-link.active {
    color: #fff;
    background: linear-gradient(135deg, var(--idx1-primary), var(--idx1-accent));
    box-shadow: 0 4px 15px rgba(var(--idx1-primary-rgb), 0.35);
    transform: scale(1.02);
}

/* --- Floating Label Inputs: Glass --- */
.idx1-input-group {
    position: relative;
}

.idx1-input {
    background: var(--idx1-input-bg) !important;
    backdrop-filter: blur(8px);
    border: 1.5px solid var(--idx1-input-border) !important;
    border-radius: var(--idx1-radius-sm) !important;
    color: var(--idx1-text) !important;
    height: 58px;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    padding-right: 3rem;
}

.idx1-input::placeholder {
    color: transparent;
}

.idx1-input:focus {
    background: rgba(255, 255, 255, 0.9) !important;
    border-color: var(--idx1-primary) !important;
    box-shadow:
        0 0 0 3px rgba(var(--idx1-primary-rgb), 0.12),
        0 4px 20px rgba(var(--idx1-primary-rgb), 0.08) !important;
    transform: translateY(-1px);
}

.idx1-input-group label {
    color: var(--idx1-text-muted);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.idx1-input-group .form-control:focus ~ label,
.idx1-input-group .form-control:not(:placeholder-shown) ~ label {
    color: var(--idx1-primary);
}

/* Password toggle */
.idx1-input-group .toggle-password {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    z-index: 5;
    color: var(--idx1-text-light);
    background: transparent;
    border: none;
    padding: 0.25rem 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 50%;
}

.idx1-input-group .toggle-password:hover {
    color: var(--idx1-primary);
    background: rgba(var(--idx1-primary-rgb), 0.08);
}

/* --- Info Banner: Glass --- */
.idx1-info-banner {
    background: linear-gradient(135deg,
        rgba(var(--idx1-primary-rgb), 0.06),
        rgba(var(--idx1-accent-rgb), 0.04));
    backdrop-filter: blur(8px);
    border: 1px solid rgba(var(--idx1-primary-rgb), 0.1);
    border-radius: var(--idx1-radius-sm);
    padding: 1.1rem 1.25rem;
    color: var(--idx1-text);
    position: relative;
    overflow: hidden;
}

.idx1-info-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, var(--idx1-primary), var(--idx1-accent));
    border-radius: 3px;
}

.idx1-info-banner i {
    color: var(--idx1-primary);
}

.idx1-info-banner h6 {
    color: var(--idx1-text);
    font-size: 0.9rem;
    font-weight: 700;
}

.idx1-info-banner p {
    color: var(--idx1-text-muted);
    font-size: 0.84rem;
    line-height: 1.5;
}

/* --- Buttons: Gradient with Shine --- */
.idx1-btn-primary {
    background: linear-gradient(135deg, var(--idx1-primary), var(--idx1-accent));
    background-size: 200% 200%;
    border: none;
    color: #fff;
    border-radius: var(--idx1-radius-sm);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 6px 20px rgba(var(--idx1-primary-rgb), 0.3);
    animation: btnGradient 6s ease infinite;
}

@keyframes btnGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.idx1-btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent);
    transition: left 0.6s ease;
}

.idx1-btn-primary:hover {
    transform: translateY(-3px);
    box-shadow:
        0 10px 30px rgba(var(--idx1-primary-rgb), 0.4),
        0 0 20px rgba(var(--idx1-accent-rgb), 0.15);
    color: #fff;
}

.idx1-btn-primary:hover::before {
    left: 100%;
}

.idx1-btn-primary:active {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(var(--idx1-primary-rgb), 0.25);
}

.idx1-btn-outline {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(8px);
    border: 1.5px solid var(--idx1-border-subtle);
    color: var(--idx1-text-muted);
    border-radius: var(--idx1-radius-sm);
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.35s ease;
}

.idx1-btn-outline:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: var(--idx1-primary);
    color: var(--idx1-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(var(--idx1-primary-rgb), 0.1);
}

/* --- Links --- */
.idx1-link {
    color: var(--idx1-text-muted);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    position: relative;
    padding-bottom: 2px;
}

.idx1-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--idx1-primary), var(--idx1-accent));
    transition: width 0.3s ease;
    border-radius: 1px;
}

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

.idx1-link:hover::after {
    width: 100%;
}

/* --- Divider --- */
.idx1-divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.idx1-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--idx1-border-subtle), transparent);
}

.idx1-divider span {
    background: var(--idx1-card-bg-solid);
    padding: 0 1rem;
    color: var(--idx1-text-light);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    position: relative;
}

/* --- Card Footer / Trust Badge --- */
.idx1-card-footer {
    padding-top: 1.25rem;
    border-top: 1px solid rgba(0, 0, 0, 0.04);
    color: var(--idx1-text-light);
    font-size: 0.82rem;
}

.idx1-card-footer i {
    color: var(--idx1-success);
}

/* --- Form Text --- */
.idx1-form-text {
    color: var(--idx1-text-light);
    font-size: 0.8rem;
}

/* --- Status Message --- */
#login-status-msg {
    color: #dc3545;
    font-size: 0.875rem;
    font-weight: 500;
    min-height: 1.2rem;
}

/* --- Footer: Dark Glass --- */
.idx1-footer {
    background: #0f172a;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding: 0.6rem 0;
    flex-shrink: 0;
    z-index: 1040;
}

.idx1-footer .nav-link {
    color: rgba(255, 255, 255, 0.55) !important;
    font-size: 0.82rem;
    font-weight: 500;
    padding: 0.4rem 0.85rem;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.idx1-footer .nav-link:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.08);
}

.idx1-footer .navbar-toggler-icon {
    filter: invert(1);
}

.idx1-footer-text {
    color: rgba(255, 255, 255, 0.35);
    font-size: 0.78rem;
}

/* --- Registration Form Container Overrides --- */
.registration-form-container .form-control,
.registration-form-container .form-select {
    background: var(--idx1-input-bg);
    backdrop-filter: blur(8px);
    border: 1.5px solid var(--idx1-input-border);
    border-radius: var(--idx1-radius-sm);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    color: var(--idx1-text);
}

.registration-form-container .form-control:focus,
.registration-form-container .form-select:focus {
    background: rgba(255, 255, 255, 0.9);
    border-color: var(--idx1-primary);
    box-shadow:
        0 0 0 3px rgba(var(--idx1-primary-rgb), 0.12),
        0 4px 20px rgba(var(--idx1-primary-rgb), 0.08);
    transform: translateY(-1px);
}

.registration-form-container label {
    color: var(--idx1-text-muted);
    font-size: 0.875rem;
    margin-bottom: 0.35rem;
    font-weight: 500;
}

.registration-form-container .btn-primary {
    background: linear-gradient(135deg, var(--idx1-primary), var(--idx1-accent));
    border: none;
    border-radius: var(--idx1-radius-sm);
    box-shadow: 0 6px 20px rgba(var(--idx1-primary-rgb), 0.3);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    font-weight: 700;
}

.registration-form-container .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow:
        0 10px 30px rgba(var(--idx1-primary-rgb), 0.4),
        0 0 20px rgba(var(--idx1-accent-rgb), 0.15);
}

.registration-form-container .form-check-input:checked {
    background-color: var(--idx1-primary);
    border-color: var(--idx1-primary);
}

.registration-form-container a {
    color: var(--idx1-primary);
    font-weight: 600;
}

.registration-form-container .text-danger {
    color: #dc3545 !important;
}

/* --- Animations --- */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

/* Staggered animations for card children */
.idx1-card .idx1-stagger-1 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.1s both; }
.idx1-card .idx1-stagger-2 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.2s both; }
.idx1-card .idx1-stagger-3 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.3s both; }
.idx1-card .idx1-stagger-4 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.4s both; }
.idx1-card .idx1-stagger-5 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.5s both; }
.idx1-card .idx1-stagger-6 { animation: fadeInUp 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.6s both; }

/* --- reCAPTCHA --- */
.grecaptcha-badge {
    z-index: 9999 !important;
}

/* --- Responsive --- */
@media (max-width: 991.98px) {
    .idx1-page-wrapper {
        padding-top: 90px;
        padding-bottom: 90px;
    }

    .idx1-shape-1 { width: 250px; height: 250px; }
    .idx1-shape-2 { width: 200px; height: 200px; }
    .idx1-shape-3 { width: 150px; height: 150px; }
    .idx1-shape-4 { display: none; }
    .idx1-shape-5 { display: none; }
}

@media (max-width: 575.98px) {
    .idx1-card {
        padding: 2rem 1.5rem 1.5rem;
        border-radius: 1.25rem;
    }

    .idx1-card-title {
        font-size: 1.25rem;
    }

    .idx1-header-icon {
        width: 56px;
        height: 56px;
    }

    .idx1-header-icon i {
        font-size: 1.4rem;
    }

    .idx1-nav-pills .nav-link {
        font-size: 0.8rem;
        padding: 0.55rem 0.75rem;
    }

    .idx1-page-wrapper {
        padding-bottom: 20px;
    }

    .idx1-shape-1 { width: 180px; height: 180px; }
    .idx1-shape-2 { width: 140px; height: 140px; }
    .idx1-shape-3 { display: none; }
}

@media (min-width: 1200px) {
    .idx1-card {
        padding: 2.75rem 2.5rem 2rem;
    }
}

/* --- Scrollbar: Themed --- */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(var(--idx1-primary-rgb), 0.15);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(var(--idx1-primary-rgb), 0.3);
}

/* ============================================================
   DARK MODE
   ============================================================ */
[data-bs-theme="dark"] {
    --idx1-text: #e2e8f0;
    --idx1-text-muted: #94a3b8;
    --idx1-text-light: #64748b;
    --idx1-border: rgba(255,255,255,0.08);
    --idx1-border-subtle: rgba(255,255,255,0.06);
    --idx1-input-bg: #161926;
    --idx1-input-border: rgba(255,255,255,0.1);
    --idx1-card-bg: rgba(26,29,46,0.85);
    --idx1-card-bg-solid: #1a1d2e;
    --idx1-bg-start: #0f1117;
    --idx1-bg-mid: #131520;
    --idx1-bg-end: #10121c;
    --aff-text: #e2e8f0;
    --aff-text-muted: #94a3b8;
    --aff-input-bg: #161926;
    --aff-input-border: rgba(255,255,255,0.1);
    --aff-card-bg: #1a1d2e;
}
[data-bs-theme="dark"] body {
    background: #0f1117 !important;
    color: #e2e8f0 !important;
}
[data-bs-theme="dark"] .forny-container,
[data-bs-theme="dark"] .forny-form {
    color: #e2e8f0 !important;
}
[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .forny-container .card {
    background: #1a1d2e !important;
    border-color: rgba(255,255,255,0.08) !important;
}
[data-bs-theme="dark"] h1, [data-bs-theme="dark"] h2,
[data-bs-theme="dark"] h3, [data-bs-theme="dark"] h4,
[data-bs-theme="dark"] h5, [data-bs-theme="dark"] h6 {
    color: #f1f5f9 !important;
}
[data-bs-theme="dark"] .form-control {
    background: #161926 !important;
    color: #e2e8f0 !important;
    border-color: rgba(255,255,255,0.1) !important;
}
[data-bs-theme="dark"] label:not(.form-floating > label) {
    color: #cbd5e1 !important;
}
[data-bs-theme="dark"] .form-floating > label {
    color: #94a3b8 !important;
}
[data-bs-theme="dark"] .form-control:focus ~ label,
[data-bs-theme="dark"] .form-control:not(:placeholder-shown) ~ label {
    color: var(--aff-primary, #4361ee) !important;
    opacity: 1 !important;
}
[data-bs-theme="dark"] .text-muted {
    color: #94a3b8 !important;
}
[data-bs-theme="dark"] a:not(.btn) {
    color: #93c5fd;
}

/* Dark mode: Navbar glass */
[data-bs-theme="dark"] .idx1-navbar {
    background: rgba(15,17,23,0.75);
    border-bottom-color: rgba(255,255,255,0.06);
}
/* Dark mode: Nav pills */
[data-bs-theme="dark"] .idx1-nav-pills {
    background: rgba(255,255,255,0.04);
    border-color: rgba(255,255,255,0.08);
}
/* Dark mode: Input focus */
[data-bs-theme="dark"] .idx1-input:focus {
    background: #1e2235 !important;
}
/* Dark mode: Language dropdown */
[data-bs-theme="dark"] .language-changer > a {
    background: rgba(255,255,255,0.06);
    color: #e2e8f0;
    border-color: rgba(255,255,255,0.1);
}
[data-bs-theme="dark"] .dropdown-menu.country-wrap,
[data-bs-theme="dark"] .country-wrap.dropdown-menu {
    background: #1a1d2e;
    border-color: rgba(255,255,255,0.1);
}
[data-bs-theme="dark"] .country-wrap .dropdown-item {
    color: #e2e8f0;
}
[data-bs-theme="dark"] .country-wrap .dropdown-item:hover {
    background: rgba(var(--idx1-primary-rgb),0.15);
}
/* Dark mode: Button outlines */
[data-bs-theme="dark"] .idx1-btn-outline {
    background: rgba(255,255,255,0.04);
    border-color: rgba(255,255,255,0.12);
    color: #cbd5e1;
}
[data-bs-theme="dark"] .idx1-btn-outline:hover {
    background: rgba(255,255,255,0.08);
}
/* Dark mode: Divider */
[data-bs-theme="dark"] .idx1-divider span {
    background: #1a1d2e;
}
/* Dark mode: Registration form overrides */
[data-bs-theme="dark"] .registration-form-container .form-control,
[data-bs-theme="dark"] .registration-form-container .form-select {
    background: #161926 !important;
    border-color: rgba(255,255,255,0.1) !important;
    color: #e2e8f0 !important;
}
[data-bs-theme="dark"] .registration-form-container .form-control:focus,
[data-bs-theme="dark"] .registration-form-container .form-select:focus {
    background: #1e2235 !important;
}
