/* ==== Estilos específicos para página de Registro con fondo espacial ==== */

/* Fondo espacial con estrellas animadas */
body.register-page {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    background-attachment: fixed;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    position: relative;
    overflow-x: hidden;
}

body.register-page::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(2px 2px at 20px 30px, #eee, transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 90px 40px, #fff, transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 160px 30px, #fff, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: sparkle 20s linear infinite;
    z-index: -2;
}

@keyframes sparkle {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Elementos flotantes espaciales */
body.register-page::after {
    content: '';
    position: fixed;
    top: 10%;
    right: 15%;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(55, 23, 131, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
    z-index: -1;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

/* Estrellas adicionales */
.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    animation: twinkle 3s infinite;
}

.star:nth-child(1) { top: 20%; left: 10%; width: 2px; height: 2px; animation-delay: 0s; }
.star:nth-child(2) { top: 15%; left: 80%; width: 1px; height: 1px; animation-delay: 0.5s; }
.star:nth-child(3) { top: 60%; left: 25%; width: 3px; height: 3px; animation-delay: 1s; }
.star:nth-child(4) { top: 40%; left: 70%; width: 1px; height: 1px; animation-delay: 1.5s; }
.star:nth-child(5) { top: 80%; left: 60%; width: 2px; height: 2px; animation-delay: 2s; }

@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

/* Logo en el formulario */
.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.logo-icon {
    font-size: 1.5rem;
    filter: drop-shadow(0 0 10px rgba(55, 23, 131, 0.5));
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #371783;
    text-shadow: 0 0 20px rgba(139, 90, 150, 0.3);
}

/* Ilustración educativa en el panel derecho */
.hero-illustration {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.illustration-container {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 500px;
    max-height: 600px;
}

/* Libros flotantes */
.education-elements {
    position: relative;
    width: 100%;
    height: 100%;
}

.book {
    position: absolute;
    font-size: 4rem;
    animation: bookFloat 5s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(55, 23, 131, 0.6));
    z-index: 10;
}

.book-1 {
    top: 25%;
    left: 30%;
    animation-delay: 0s;
}

.book-2 {
    top: 55%;
    left: 20%;
    animation-delay: 2s;
}

.book-3 {
    top: 40%;
    right: 25%;
    animation-delay: 4s;
}

@keyframes bookFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(3deg); }
}

/* Utiles escolares */
.school-supplies {
    position: relative;
    width: 100%;
    height: 100%;
}

.pencil {
    position: absolute;
    font-size: 3.5rem;
    animation: pencilFloat 4s ease-in-out infinite;
    filter: drop-shadow(0 0 15px rgba(139, 90, 150, 0.5));
    z-index: 10;
}

.pencil-1 {
    top: 35%;
    left: 35%;
    animation-delay: 1s;
}

.pencil-2 {
    top: 65%;
    right: 30%;
    animation-delay: 3s;
}

.pencil-3 {
    top: 25%;
    right: 15%;
    animation-delay: 5s;
}

@keyframes pencilFloat {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    50% { transform: translateY(-8px) translateX(5px); }
}

/* Elementos de aprendizaje */
.learning-items {
    position: relative;
    width: 100%;
    height: 100%;
}

.item {
    position: absolute;
    font-size: 2.8rem;
    animation: itemRotate 6s ease-in-out infinite;
    filter: drop-shadow(0 0 12px rgba(55, 23, 131, 0.5));
    z-index: 10;
}

.item-1 {
    top: 50%;
    left: 55%;
    animation-delay: 0s;
}

.item-2 {
    top: 70%;
    left: 50%;
    animation-delay: 1.5s;
}

.item-3 {
    top: 35%;
    left: 60%;
    animation-delay: 3s;
}

.item-4 {
    top: 85%;
    right: 50%;
    animation-delay: 4.5s;
}

@keyframes itemRotate {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(5deg) scale(1.1); }
}

/* Elementos de conocimiento */
.knowledge-elements {
    position: relative;
    width: 100%;
    height: 100%;
}

.knowledge {
    position: absolute;
    font-size: 3rem;
    animation: knowledgeGlow 3s ease-in-out infinite;
    z-index: 12;
}

.knowledge-1 {
    top: 45%;
    right: 30%;
    animation-delay: 0s;
}

.knowledge-2 {
    top: 65%;
    right: 50%;
    animation-delay: 1.5s;
}

@keyframes knowledgeGlow {
    0%, 100% {
        opacity: 0.8;
        transform: scale(1);
        filter: drop-shadow(0 0 10px rgba(139, 90, 150, 0.4));
    }
    50% {
        opacity: 1;
        transform: scale(1.15);
        filter: drop-shadow(0 0 20px rgba(139, 90, 150, 0.6));
    }
}

/* Elementos escolares */
.school-elements {
    position: relative;
    width: 100%;
    height: 100%;
}

.school {
    position: absolute;
    font-size: 4.5rem;
    animation: schoolFloat 6s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(55, 23, 131, 0.7));
    z-index: 15;
}

.school-1 {
    top: 15%;
    left: 50%;
    transform: translateX(-50%);
    animation-delay: 0s;
}

@keyframes schoolFloat {
    0%, 100% { transform: translateY(0px) translateX(0px); }
    50% { transform: translateY(-10px) translateX(3px); }
}

/* Estudiantes estudiando */
.students {
    position: absolute;
    font-size: 3rem;
    animation: studentStudy 4s ease-in-out infinite;
    filter: drop-shadow(0 0 15px rgba(139, 90, 150, 0.6));
    z-index: 12;
}

.students-1 {
    top: 45%;
    left: 12%;
    animation-delay: 1s;
}

.students-2 {
    top: 55%;
    right: 12%;
    animation-delay: 3s;
}

@keyframes studentStudy {
    0%, 100% { transform: scale(1) translateY(0px); }
    50% { transform: scale(1.05) translateY(-5px); }
}

/* Colores flotando */
.floating-colors {
    position: relative;
    width: 100%;
    height: 100%;
}

.color {
    position: absolute;
    font-size: 2.5rem;
    animation: colorFloat 5s ease-in-out infinite;
    filter: drop-shadow(0 0 12px rgba(55, 23, 131, 0.5));
    z-index: 8;
}

.color-1 {
    top: 35%;
    left: 65%;
    animation-delay: 0s;
}

.color-2 {
    top: 60%;
    left: 55%;
    animation-delay: 1s;
}

.color-3 {
    top: 75%;
    left: 40%;
    animation-delay: 2s;
}

.color-4 {
    top: 20%;
    right: 40%;
    animation-delay: 3s;
}

.color-5 {
    top: 80%;
    right: 50%;
    animation-delay: 4s;
}

.color-6 {
    top: 50%;
    right: 55%;
    animation-delay: 5s;
}

@keyframes colorFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.9;
    }
    50% {
        transform: translateY(-8px) rotate(5deg);
        opacity: 1;
    }
}

/* Contenedor principal del registro */
.register-container {
    display: flex;
    justify-content: center;
    align-items: stretch;
    min-height: 100vh;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 10;
    gap: 0;
}

/* Panel izquierdo con el formulario */
.register-panel {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

/* Panel derecho con ilustración */
.image-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(55, 23, 131, 0.1) 0%, rgba(139, 90, 150, 0.1) 100%);
    position: relative;
    overflow: visible;
    min-height: 600px;
}

/* Formulario moderno con diseño espacial */
.modern-register-form {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 420px;
    position: relative;
    overflow: hidden;
}

.modern-register-form::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #371783 0%, #8B5A96 50%, #ffd23f 100%);
}

.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.form-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.form-header p {
    color: #7f8c8d;
    font-size: 0.9rem;
    margin: 0;
}

.register-link {
    color: #371783;
    text-decoration: none;
    font-weight: 600;
}

.register-link:hover {
    color: #2a1161;
    text-decoration: underline;
}

/* Campos del formulario modernos */
.form-group-modern {
    margin-bottom: 1.5rem;
}

.form-group-modern label {
    display: block;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-group-modern input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
    box-sizing: border-box;
}

.form-group-modern input:focus {
    outline: none;
    border-color: #371783;
    background: white;
    box-shadow: 0 0 0 3px rgba(55, 23, 131, 0.1);
}

.form-group-modern input::placeholder {
    color: #adb5bd;
}

/* Opciones del formulario */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: #495057;
}

.remember-me input[type="checkbox"] {
    margin-right: 0.5rem;
    width: 16px;
    height: 16px;
    accent-color: #371783;
}

.forgot-password {
    color: #371783;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}

.forgot-password:hover {
    color: #2a1161;
    text-decoration: underline;
}

/* Botón de registro moderno */
.btn-register {
    width: 100%;
    background: linear-gradient(135deg, #371783 0%, #8B5A96 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    box-shadow: 0 4px 15px rgba(55, 23, 131, 0.3);
}

.btn-register:hover {
    background: linear-gradient(135deg, #2a1161 0%, #6d4374 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(55, 23, 131, 0.4);
}

.btn-register:active {
    transform: translateY(0);
}

/* Footer del formulario */
.form-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.form-footer p {
    font-size: 0.8rem;
    color: #6c757d;
    margin: 0.5rem 0;
    line-height: 1.4;
}

.form-footer a {
    color: #371783;
    text-decoration: none;
}

.form-footer a:hover {
    text-decoration: underline;
}

/* Notificación emergente para errores */
.notification-alert {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    min-width: 300px;
    max-width: 400px;
    animation: slideInRight 0.5s ease-out;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: none;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    color: white !important;
}

/* Alerta de error (roja) */
.notification-alert.alert-danger {
    background: rgba(220, 53, 69, 0.95) !important;
}

/* Alerta de éxito (verde) */
.notification-alert.alert-success {
    background: rgba(40, 167, 69, 0.95) !important;
}

.notification-alert .btn-close {
    filter: invert(1);
    opacity: 0.8;
}

.notification-alert .btn-close:hover {
    opacity: 1;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Footer moderno oculto en registro */
.modern-footer {
    display: none;
}

/* Estilos específicos para desktop */
@media (min-width: 1025px) {
    .illustration-container {
        min-height: 600px;
        max-height: 700px;
    }

    .image-panel {
        min-height: 700px;
    }

    /* Asegurar que todos los elementos sean visibles en desktop */
    .book, .pencil, .school, .students, .color, .item, .knowledge {
        opacity: 1;
        visibility: visible;
    }
}

/* Responsividad para tablets */
@media (max-width: 1024px) {
    .register-container {
        flex-direction: column;
        max-width: 100%;
    }

    .register-panel {
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        min-height: 50vh;
    }

    .image-panel {
        min-height: 40vh;
    }

    .illustration-container {
        min-height: 300px;
    }
}

/* Responsividad para móviles */
@media (max-width: 768px) {
    .register-panel {
        padding: 1.5rem 1rem;
    }

    .image-panel {
        padding: 1rem;
    }

    .modern-register-form {
        padding: 2rem 1.5rem;
        max-width: none;
    }

    .form-header h2 {
        font-size: 1.5rem;
    }

    .form-options {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .book {
        font-size: 3.5rem;
    }

    .pencil {
        font-size: 3rem;
    }

    .item {
        font-size: 2.5rem;
    }

    .knowledge {
        font-size: 2.5rem;
    }

    .school {
        font-size: 4rem;
    }

    .students {
        font-size: 2.5rem;
    }

    .color {
        font-size: 2rem;
    }

    .illustration-container {
        min-height: 250px;
    }
}

@media (max-width: 480px) {
    .register-panel {
        padding: 1rem 0.5rem;
    }

    .image-panel {
        padding: 0.5rem;
    }

    .modern-register-form {
        padding: 1.5rem 1rem;
        border-radius: 16px;
    }

    .form-header h2 {
        font-size: 1.3rem;
    }

    .book {
        font-size: 3rem;
    }

    .pencil {
        font-size: 2.5rem;
    }

    .item {
        font-size: 2rem;
    }

    .knowledge {
        font-size: 2.2rem;
    }

    .school {
        font-size: 3.5rem;
    }

    .students {
        font-size: 2.2rem;
    }

    .color {
        font-size: 1.8rem;
    }

    .illustration-container {
        min-height: 200px;
    }

    .logo-text {
        font-size: 1.2rem;
    }
}