* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Poppins', sans-serif;
    color: #0a1940;
}

.login-page {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

/* ==============================
   Panel Izquierdo: Video
   ============================== */
.login-video-panel {
    position: relative;
    flex: 0 0 48%;
    max-width: 48%;
    overflow: hidden;
    background: #0a1c2e;
    display: flex;
    align-items: flex-end;
}

.video-wrapper {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.video-wrapper .bg-gif {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    display: block;
    background: #0a1c2e;
}

.video-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(165deg, rgba(13, 33, 55, 0.55) 0%, rgba(10, 28, 46, 0.85) 100%);
}

.brand-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 48px;
    color: #fff;
}

.brand-card {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.94);
    border-radius: 14px;
    padding: 12px 20px;
    margin-bottom: 32px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.brand-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.brand-subtitle {
    font-size: 13px;
    font-weight: 600;
    color: #0d2137;
    letter-spacing: 0.3px;
}

.brand-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.25;
    max-width: 480px;
    margin-bottom: 14px;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.brand-text {
    font-size: 15px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.85);
    max-width: 420px;
}

/* ==============================
   Panel Derecho: Formulario
   ============================== */
.login-form-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    padding: 40px 24px;
}

.login-form-inner {
    width: 100%;
    max-width: 400px;
    animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.welcome-title {
    font-size: 30px;
    font-weight: 700;
    color: #0a1940;
    margin-bottom: 6px;
}

.welcome-subtitle {
    font-size: 14px;
    color: #5a6a8a;
    margin-bottom: 28px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #0a1940;
    font-weight: 500;
    font-size: 14px;
}

.input-wrapper {
    position: relative;
}

.input-wrapper i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #163d68;
    font-size: 16px;
}

.form-control {
    width: 100%;
    padding: 14px 18px 14px 50px;
    border: 2px solid #dce4f5;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #f4f7ff;
    color: #0a1940;
    font-family: 'Poppins', sans-serif;
}

.form-control:focus {
    outline: none;
    border-color: #163d68;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(22, 61, 104, 0.12);
}

.form-control::placeholder {
    color: #9aaacb;
}

#password.form-control,
#password_confirmation.form-control {
    padding-right: 46px;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9aaacb;
    cursor: pointer;
    font-size: 15px;
    padding: 4px;
}

.toggle-password:hover {
    color: #163d68;
}

.remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    font-size: 14px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #5a6a8a;
    cursor: pointer;
}

.remember-me input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #0d2137;
}

.forgot-link {
    color: #0d2137;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.forgot-link:hover {
    color: #0a1940;
    text-decoration: underline;
}

.btn-login {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #163d68 0%, #0a1c2e 100%);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 4px 15px rgba(13, 33, 55, 0.35);
    letter-spacing: 0.3px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 33, 55, 0.45);
}

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

.register-text {
    text-align: center;
    margin-top: 22px;
    font-size: 14px;
    color: #5a6a8a;
}

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

.register-link:hover {
    text-decoration: underline;
}

.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
}

.alert-danger {
    background-color: #eef2ff;
    border-left: 4px solid #0d2137;
    color: #0a1940;
}

.divider {
    text-align: center;
    margin: 22px 0;
    position: relative;
}

.divider::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #dce4f5;
}

.divider span {
    background: #fff;
    padding: 0 15px;
    color: #9aaacb;
    font-size: 13px;
    position: relative;
    z-index: 1;
}

.footer-text {
    text-align: center;
    margin-top: 24px;
    color: #9aaacb;
    font-size: 12px;
}

.oauth-buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 4px;
}

.btn-oauth {
    width: 100%;
    padding: 12px 24px;
    border: 1px solid #dce4f5;
    border-radius: 10px;
    color: #0a1940;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fff;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-family: 'Poppins', sans-serif;
    letter-spacing: 0.25px;
}

.btn-oauth:hover {
    background: #f4f7ff;
    border-color: #163d68;
    box-shadow: 0 2px 8px rgba(13, 33, 55, 0.12);
}

.btn-oauth-google i {
    background: linear-gradient(135deg, #4285f4 0%, #4285f4 25%, #ea4335 25%, #ea4335 50%, #fbbc04 50%, #fbbc04 75%, #34a853 75%, #34a853 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 900;
}

/* ==============================
   Responsive
   ============================== */
@media (max-width: 900px) {
    .login-video-panel {
        display: none;
    }

    .login-form-panel {
        flex: 1 1 100%;
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .welcome-title {
        font-size: 24px;
    }

    .btn-oauth {
        font-size: 14px;
        padding: 12px;
    }
}
