/* ============================================================ */
/* [1] VARIABLES PREMIUM - NO MODIFICAR                      */
/* ============================================================ */
:root {
    --primary: #f97316;
    --primary-dark: #ea580c;
    --primary-light: #ffedd5;
    --secondary: #06b6d4;
    --secondary-dark: #0891b2;
    --accent: #8b5cf6;

    --dark-deep: #0a0f1c;
    --dark-mid: #111827;
    --glass-white: rgba(255, 255, 255, 0.98);
    --glass-muted: rgba(255, 255, 255, 0.95);

    --text-main: #0f172a;
    --text-muted: #475569;
    --text-soft: #64748b;
    --border-light: #e2e8f0;

    --shadow-card: 0 35px 68px rgba(0, 0, 0, 0.18), 0 15px 25px rgba(0, 0, 0, 0.08);

    --neumorph-bg: #e0e5ec;
    --neumorph-dark: #b8c0cb;
    --neumorph-light: #ffffff;

    --pattern-s: 170px;
    --pattern-c1: #0a1628;
    --pattern-c2: #1a3a5c;
    --pattern-c3: #0f2a45;
    --pattern-thickness: 15px;
}

/* ============================================================ */
/* [2] RESET Y BODY - FUENTE POR DEFECTO Inter                */
/* ============================================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    background: linear-gradient(145deg, #0a0f1c 0%, #111827 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow-x: hidden;
    padding: 20px;
}

/* ============================================================ */
/* [3] OLAS - ROTACIÓN CIRCULAR             */
/* ============================================================ */
.ocean-waves {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.wave-circle {
    position: absolute;
    width: 150%;
    height: 150%;
    top: -25%;
    left: -25%;
    border-radius: 40%;
    opacity: 0.5;
    animation: waveRotate 20s infinite linear;
}

.wave-1 {
    background: linear-gradient(744deg, rgba(6, 182, 212, 0.25), rgba(6, 182, 212, 0.1), rgba(6, 182, 212, 0.05));
    animation-duration: 20s;
}

.wave-2 {
    background: linear-gradient(744deg, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.08), rgba(59, 130, 246, 0.03));
    animation-duration: 25s;
    animation-direction: reverse;
    opacity: 0.4;
}

.wave-3 {
    background: linear-gradient(744deg, rgba(139, 92, 246, 0.18), rgba(139, 92, 246, 0.06), rgba(139, 92, 246, 0.02));
    animation-duration: 30s;
    opacity: 0.3;
}

@keyframes waveRotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ============================================================ */
/* [4] BURBUJAS FLOTANTES                                     */
/* ============================================================ */
.bubbles {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
    pointer-events: none;
}

.bubble {
    position: absolute;
    bottom: -100px;
    background: radial-gradient(circle at 30% 30%, rgba(59, 130, 246, 0.2), rgba(59, 130, 246, 0.03));
    border-radius: 50%;
    animation: bubbleRise 12s ease-in infinite;
}

.bubble:nth-child(1) {
    width: 30px;
    height: 30px;
    left: 5%;
    animation-duration: 8s;
    animation-delay: 0s;
}

.bubble:nth-child(2) {
    width: 20px;
    height: 20px;
    left: 15%;
    animation-duration: 10s;
    animation-delay: 2s;
}

.bubble:nth-child(3) {
    width: 45px;
    height: 45px;
    left: 28%;
    animation-duration: 12s;
    animation-delay: 1s;
}

.bubble:nth-child(4) {
    width: 25px;
    height: 25px;
    left: 42%;
    animation-duration: 7s;
    animation-delay: 3s;
}

.bubble:nth-child(5) {
    width: 50px;
    height: 50px;
    left: 55%;
    animation-duration: 14s;
    animation-delay: 0.5s;
}

.bubble:nth-child(6) {
    width: 18px;
    height: 18px;
    left: 68%;
    animation-duration: 9s;
    animation-delay: 4s;
}

.bubble:nth-child(7) {
    width: 38px;
    height: 38px;
    left: 80%;
    animation-duration: 11s;
    animation-delay: 2.5s;
}

.bubble:nth-child(8) {
    width: 28px;
    height: 28px;
    left: 92%;
    animation-duration: 8.5s;
    animation-delay: 1.5s;
}

.bubble:nth-child(9) {
    width: 22px;
    height: 22px;
    left: 10%;
    animation-duration: 13s;
    animation-delay: 5s;
}

.bubble:nth-child(10) {
    width: 35px;
    height: 35px;
    left: 48%;
    animation-duration: 9.5s;
    animation-delay: 3.5s;
}

.bubble:nth-child(11) {
    width: 42px;
    height: 42px;
    left: 72%;
    animation-duration: 10.5s;
    animation-delay: 4.5s;
}

.bubble:nth-child(12) {
    width: 26px;
    height: 26px;
    left: 88%;
    animation-duration: 7.5s;
    animation-delay: 5.5s;
}

@keyframes bubbleRise {
    0% {
        bottom: -100px;
        opacity: 0;
        transform: translateX(0) scale(0.8);
    }

    15% {
        opacity: 0.5;
    }

    85% {
        opacity: 0.3;
    }

    100% {
        bottom: 100%;
        opacity: 0;
        transform: translateX(25px) scale(1.3);
    }
}

/* ============================================================ */
/* [5] CONTENEDOR PRINCIPAL                                   */
/* ============================================================ */
.container {
    width: 1180px;
    max-width: 100%;
    position: relative;
    z-index: 10;
    margin: 0 auto;
}

.split-card {
    display: flex;
    background: var(--glass-white);
    border-radius: 56px;
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

/* ============================================================ */
/* [6] LADO IZQUIERDO - FONDO Y PATRÓN                        */
/* ============================================================ */
.card-left {
    flex: 1;
    background: linear-gradient(135deg, #0f1222 0%, #181e2f 100%);
    padding: 40px 32px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.geometric-pattern-left {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    opacity: 0.3;
    background-color: var(--pattern-c1);
    background-image:
        repeating-linear-gradient(45deg, var(--pattern-c2) 0 var(--pattern-thickness), transparent var(--pattern-thickness) calc(var(--pattern-thickness) * 2)),
        repeating-linear-gradient(-45deg, var(--pattern-c3) 0 var(--pattern-thickness), transparent var(--pattern-thickness) calc(var(--pattern-thickness) * 2));
    background-size: var(--pattern-s) var(--pattern-s);
    animation: patternShift 25s linear infinite;
}

@keyframes patternShift {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: var(--pattern-s) var(--pattern-s);
    }
}

.card-left::before {
    content: '';
    position: absolute;
    top: -30%;
    left: -30%;
    width: 160%;
    height: 160%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.08), transparent 70%);
    animation: slowRotate 25s linear infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes slowRotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.left-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
}

.logo-left {
    position: relative;
    width: 120px;
    height: auto;
}

.logo-left img {
    width: 100%;
    height: auto;
    opacity: 0.95;
    display: block;
}

.cert-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--neumorph-bg);
    padding: 8px 16px;
    border-radius: 40px;
    font-size: 11px;
    font-weight: 800;
    color: var(--primary);
    box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.2), -5px -5px 10px rgba(255, 255, 255, 0.1);
}

.cert-badge i {
    color: var(--primary);
}

.left-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 280px;
    position: relative;
    z-index: 2;
}

/* ============================================================ */
/* [7] TÍTULO PRINCIPAL - FUENTE: Bungee */
/* ============================================================ */

.main-title {
    font-size: 60px;
    font-weight: bold;
    font-family: 'Bungee', cursive;
    color: #FFFFFF;
    letter-spacing: 4px;
    margin-bottom: 5px;
    animation: textShine 4s linear infinite;
}

@keyframes textShine {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.9;
        text-shadow: 0 0 5px rgba(249, 115, 22, 0.5);
    }

    100% {
        opacity: 1;
    }
}

.titlecolor {
    color: #f97316;
}

/* ============================================================ */
/* [8] SUBTÍTULO - FUENTE: Poppins                            */
/* ============================================================ */
.main-subtitle {
    font-size: 22px;
    font-family: 'Poppins', sans-serif;
    color: #E3DEDE;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: 2px;
    padding-top: 10px;
    border-top: 5px solid rgba(249, 115, 22);
}

/* ============================================================ */
/* [9] ESTADÍSTICAS/NÚMEROS - FUENTE: Orbitron                */
/* ============================================================ */
.stats-footer {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin-top: 50px;
    padding-top: 32px;
    border-top: 5px solid rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 2;
}

.stat-block {
    text-align: center;
}

.stat-number {
    font-size: 32px;
    font-weight: 800;
    font-family: 'Orbitron', monospace;
    background: linear-gradient(135deg, #f97316, #fbbf24);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.2;
}

.stat-number span {
    font-size: 24px;
}

.stat-label {
    font-size: 11px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 6px;
    letter-spacing: 0.5px;
}

.stat-divider {
    width: 5px;
    height: 50px;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.3), transparent);
}

/* ============================================================ */
/* [10] LADO DERECHO - NEUMORPHISM Y TEXTOS GENERALES (Inter) */
/* ============================================================ */
.card-right {
    flex: 1;
    background: var(--neumorph-bg);
    padding: 48px 40px;
    position: relative;
}

.info-floating {
    position: absolute;
    top: 28px;
    right: 32px;
    width: 42px;
    height: 42px;
    background: var(--neumorph-bg);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    color: var(--primary);
    font-size: 20px;
    transition: all 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    box-shadow: 8px 8px 16px var(--neumorph-dark), -8px -8px 16px var(--neumorph-light);
}

.info-floating:hover {
    background: var(--primary);
    color: white;
    box-shadow: inset 4px 4px 8px rgba(0, 0, 0, 0.1), inset -4px -4px 8px rgba(255, 255, 255, 0.4);
}

.right-content {
    max-width: 380px;
    margin: 0 auto;
}

.form-header {
    text-align: center;
    margin-bottom: 36px;
}

.form-header h2 {
    font-size: 30px;
    font-weight: 800;
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    margin-bottom: 8px;
}

.form-header p {
    font-family: 'Inter', sans-serif;
    color: var(--text-muted);
    font-size: 15px;
    font-weight: 500;
}

.form-icon-pulse {
    position: relative;
    width: 95px;
    height: 95px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f97316, #ea580c);
    border-radius: 50%;
    cursor: default;
    pointer-events: none;
}

.form-icon-pulse i {
    font-size: 50px;
    color: white;
    position: relative;
    z-index: 2;
}

.pulse-ring {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(249, 115, 22, 0.4);
    animation: widePulse 2s ease-out infinite;
    pointer-events: none;
}

@keyframes widePulse {
    0% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.3);
        opacity: 0.2;
    }

    100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

/* ============================================================ */
/* [11] INPUTS Y BOTONES - FUENTE: Inter                      */
/* ============================================================ */
.input-group-neumorph {
    position: relative;
    margin-bottom: 28px;
    background: var(--neumorph-bg);
    border-radius: 32px;
    box-shadow: inset 2px 2px 5px var(--neumorph-dark), inset -2px -2px 5px var(--neumorph-light);
    transition: all 0.3s ease;
}

.input-group-neumorph:focus-within {
    box-shadow: inset 3px 3px 6px var(--neumorph-dark), inset -3px -3px 6px var(--neumorph-light);
}

.input-group-neumorph i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    color: var(--text-soft);
    transition: all 0.25s ease;
    z-index: 2;
    pointer-events: none;
}

.input-group-neumorph input {
    width: 100%;
    padding: 16px 18px 16px 52px;
    font-size: 15px;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    border: none;
    border-radius: 32px;
    background: transparent;
    color: var(--text-main);
    outline: none;
}

.input-group-neumorph input:focus~i {
    color: var(--primary);
    transform: translateY(-50%) scale(1.05);
}

.input-group-neumorph label {
    position: absolute;
    left: 52px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--neumorph-bg);
    padding: 0 6px;
    color: var(--text-soft);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    pointer-events: none;
    border-radius: 20px;
    font-weight: 500;
}

.input-group-neumorph input:focus~label,
.input-group-neumorph input:valid~label {
    top: -6px;
    left: 44px;
    font-size: 11px;
    font-weight: 600;
    background: var(--neumorph-bg);
    color: var(--primary);
    box-shadow: 2px 2px 4px var(--neumorph-dark), -2px -2px 4px var(--neumorph-light);
    padding: 0 8px;
}

.password-group {
    position: relative;
}

.password-toggle-icon {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-soft);
    font-size: 18px;
    transition: all 0.2s ease;
    z-index: 10;
    padding: 0;
    width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.password-toggle-icon:hover {
    color: var(--primary);
}

.password-toggle-icon i {
    position: static;
    transform: none;
    font-size: 18px;
}

.password-group input {
    padding-right: 48px;
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px 0 32px;
}

.remember-check {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    font-family: 'Inter', sans-serif;
    color: var(--text-muted);
}

.remember-check input {
    display: none;
}

.check-custom {
    width: 18px;
    height: 18px;
    border: 2px solid var(--border-light);
    border-radius: 5px;
    display: inline-block;
    position: relative;
    transition: all 0.2s ease;
    background: var(--neumorph-bg);
    box-shadow: inset 1px 1px 2px var(--neumorph-dark), inset -1px -1px 2px var(--neumorph-light);
}

.remember-check input:checked+.check-custom {
    background: var(--primary);
    border-color: var(--primary);
}

.remember-check input:checked+.check-custom::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 10px;
}

.forgot-link {
    font-family: 'Inter', sans-serif;
    color: var(--primary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: color 0.2s ease;
}

.forgot-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

.btn-login {
    width: 100%;
    padding: 16px;
    background: var(--neumorph-bg);
    border: none;
    border-radius: 44px;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 15px;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    box-shadow: 8px 8px 16px var(--neumorph-dark), -8px -8px 16px var(--neumorph-light);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 12px 12px 20px var(--neumorph-dark), -12px -12px 20px var(--neumorph-light);
}

.btn-login:active {
    transform: translateY(2px);
    box-shadow: inset 6px 6px 12px var(--neumorph-dark), inset -6px -6px 12px var(--neumorph-light);
}

.btn-login:hover i {
    transform: translateX(5px);
}

.btn-login i {
    transition: transform 0.25s ease;
    color: var(--primary);
}

.footer-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    background: var(--neumorph-bg);
    padding: 8px 16px;
    border-radius: 40px;
    color: var(--primary);
    box-shadow: 5px 5px 10px var(--neumorph-dark), -5px -5px 10px var(--neumorph-light);
}

.meta-item i {
    color: var(--primary);
    font-size: 13px;
}

.meta-dot {
    width: 8px;
    height: 8px;
    background: var(--text-soft);
    border-radius: 50%;
    opacity: 0.5;
}

/* ============================================================ */
/* [12] RESPONSIVE                                            */
/* ============================================================ */
@media (max-width: 992px) {
    body {
        padding: 16px;
    }

    .card-left {
        display: none;
    }

    .split-card {
        border-radius: 40px;
        max-width: 500px;
        margin: 0 auto;
    }

    .card-right {
        border-radius: 40px;
        padding: 40px 28px;
    }

    .right-content {
        max-width: 100%;
    }

    .container {
        max-width: 500px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .card-right {
        padding: 32px 20px;
    }

    .form-header h2 {
        font-size: 24px;
    }

    .btn-login {
        padding: 14px;
        font-size: 14px;
    }

    .form-actions {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }

    .footer-meta {
        margin-top: 32px;
        flex-wrap: wrap;
        gap: 12px;
    }
}

@media (min-width: 993px) {
    .card-left {
        display: flex;
    }

    .card-right {
        border-radius: 0;
    }
}

/* ============================================================ */
/* [13] ALERTAS NEUMORPHISM                                   */
/* ============================================================ */
.alert-system {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 360px;
    pointer-events: none;
}

.alert-modern {
    background: var(--neumorph-bg);
    border-radius: 28px;
    padding: 12px 18px;
    display: flex;
    align-items: center;
    gap: 14px;
    transform: translateX(120%);
    opacity: 0;
    animation: slideInAlert 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1) forwards;
    border-left: 4px solid;
    pointer-events: auto;
    cursor: pointer;
}

@keyframes slideInAlert {
    0% {
        transform: translateX(120%);
        opacity: 0;
    }

    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutAlert {
    0% {
        transform: translateX(0);
        opacity: 1;
    }

    100% {
        transform: translateX(120%);
        opacity: 0;
    }
}

/* ============================================================ */
/* [14] MODAL 2FA NEUMORPHISM                                 */
/* ============================================================ */
.overlay-2fa {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
}

.overlay-2fa.active {
    display: flex;
}

.modal-2fa {
    background: var(--neumorph-bg);
    border-radius: 44px;
    width: 420px;
    max-width: 90%;
    animation: modalFadeIn 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    position: relative;
    box-shadow: 20px 20px 40px rgba(0, 0, 0, 0.2), -20px -20px 40px rgba(255, 255, 255, 0.6);
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.96);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.modal-body {
    padding: 32px 28px;
}

.close-modal {
    position: absolute;
    top: 18px;
    right: 18px;
    background: var(--neumorph-bg);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 4px 4px 8px var(--neumorph-dark), -4px -4px 8px var(--neumorph-light);
}

.close-modal:hover {
    background: #fee2e2;
    color: #ef4444;
    transform: rotate(90deg);
}

.code-input {
    background: var(--neumorph-bg) !important;
    box-shadow: inset 2px 2px 5px var(--neumorph-dark), inset -2px -2px 5px var(--neumorph-light) !important;
    border: none !important;
}

.code-input:focus {
    box-shadow: inset 3px 3px 6px var(--neumorph-dark), inset -3px -3px 6px var(--neumorph-light) !important;
}