﻿/* Variables CSS */
:root {
    --primary-color: #242B57; /* Pantone 103-16 C */
    --secondary-color: #007EAD; /* Pantone 112-6 C */
    --accent-color: #EAB93E; /* Pantone 14-7 C */
    --gray-color: #949494; /* Pantone 178-9 C */
    --white: #ffffff;
    --light-gray: #f8f9fa;
    --shadow: 0 4px 6px rgba(36, 43, 87, 0.1);
    --shadow-lg: 0 10px 25px rgba(36, 43, 87, 0.15);
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    position: relative;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

.wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.content {
    flex: 1 0 auto; /* Permite que el contenido crezca y se contraiga, pero nunca menor a auto */
}

.login-container {
    min-height: calc(100vh - 120px);
    display: flex;
    padding: 2rem 1rem 1rem 1rem;
    justify-content: center;
    align-items: center;
}

.icon {
    color: var(--primary-color);
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(36, 43, 87, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    max-width: 1000px;
    width: 100%;
    margin: 0 auto;
    /* -max-height: calc(100vh - 140px);  Limita la altura máxima */
    margin-bottom: 1rem;
}

.login-left {
    background: white;
    padding: 2rem;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-right {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    min-height: 500px;
}

    .login-right::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-size: cover;
        background-position: center;
        opacity: 0.1;
        z-index: 0;
    }

    .login-right > * {
        position: relative;
        z-index: 1;
    }

.main-logo {
    width: 100px;
    height: 100px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(36, 43, 87, 0.15);
    transition: transform 0.3s ease;
}

    .main-logo:hover {
        transform: scale(1.05);
    }

    .main-logo img {
        width: 70px;
        height: 70px;
        object-fit: contain;
    }

.brand-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.brand-subtitle {
    color: var(--gray-color);
    font-size: 1rem;
    font-weight: 400;
}

.input-container {
    position: relative;
}

    .input-container .form-control {
        background: rgba(248, 249, 250, 0.9);
        border: 2px solid #e9ecef;
        border-radius: 12px;
        padding: 0.75rem 1rem 0.75rem 3.5rem;
        font-size: 1rem;
        transition: all 0.3s ease;
        font-family: 'Inter', sans-serif;
        min-height: 3rem;
    }

        .input-container .form-control:focus {
            background: white;
            border-color: var(--secondary-color);
            box-shadow: 0 0 0 0.2rem rgba(0, 126, 173, 0.25);
        }

    .input-container:focus-within i {
        color: var(--secondary-color);
    }

.btn-login {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    border: none;
    border-radius: 12px;
    padding: 0.75rem 2rem;
    font-size: 1.1rem;
    font-weight: 500;
    color: white;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 126, 173, 0.4);
    width: 100%;
}

    .btn-login:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(0, 126, 173, 0.5);
        color: white;
    }

.btn-action {
    border-radius: 10px;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    width: 100%;
    text-align: center;
}

.btn-outline-success {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

    .btn-outline-success:hover {
        background: var(--accent-color);
        border-color: var(--accent-color);
        color: white;
    }

.btn-outline-danger {
    border-color: var(--gray-color);
    color: var(--gray-color);
}

    .btn-outline-danger:hover {
        background: var(--gray-color);
        border-color: var(--gray-color);
        color: white;
    }

.btn-outline-info:hover {
    background: var(--secondary-color);
    border-color: var(--secondary-color);
}

.validation-summary-errors {
    background: #ffe6e6;
    border: 1px solid #ff6b6b;
    border-radius: 10px;
    padding: 1rem;
}

.text-danger {
    color: #ff6b6b !important;
    font-size: 0.85rem;
}

.welcome-content h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.8rem;
    font-weight: 600;
}

.welcome-content p {
    font-size: 1rem;
    opacity: 0.9;
    line-height: 1.6;
}

.languages-illustration {
    width: 80px;
}

.feature-item {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    transition: transform 0.3s ease;
}

    .feature-item:hover {
        transform: translateY(-5px);
    }

.feature-icon {
    font-size: 1.5rem;
    margin-right: 0.75rem;
    color: var(--accent-color);
}

.decorative-shape {
    position: absolute;
    opacity: 0.1;
}

.shape-1 {
    top: 10%;
    right: 10%;
    width: 80px;
    height: 80px;
    background: white;
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.shape-2 {
    bottom: 15%;
    left: 15%;
    width: 60px;
    height: 60px;
    background: white;
    transform: rotate(45deg);
    animation: float 6s ease-in-out infinite 2s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

.footer {
    flex-shrink: 0;
    background: var(--primary-color);
    color: white;
    border-top: 3px solid var(--accent-color);
    position: relative;
    padding: 15px 0;
    overflow: hidden;
    margin-top: auto;
}

    .footer .container {
        position: relative;
        z-index: 1;
        width: 100%;
        padding-left: 15px;
        padding-right: 15px;
    }

    .footer p {
        word-wrap: break-word;
        line-height: 1.4;
        margin-bottom: 8px;
        font-size: 14px;
    }

    .footer small {
        word-wrap: break-word;
        line-height: 1.3;
    }

/* Elementos animados de fondo */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0.1;
    z-index: -1;
}

.animated-bg-element {
    position: fixed;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
    pointer-events: none;
}

    .animated-bg-element:nth-child(1) {
        width: 200px;
        height: 200px;
        top: 10%;
        left: 10%;
        animation-delay: 0s;
    }

    .animated-bg-element:nth-child(2) {
        width: 150px;
        height: 150px;
        top: 60%;
        right: 20%;
        animation-delay: 2s;
    }

    .animated-bg-element:nth-child(3) {
        width: 100px;
        height: 100px;
        bottom: 20%;
        left: 30%;
        animation-delay: 4s;
    }

.footer {
    transition: all 0.3s ease;
}

.toast-success {
    background-color: var(--secondary-color);
}

.toast-info {
    background-color: var(--primary-color);
}

.toast-warning {
    background-color: var(--accent-color);
}

.swal2-popup {
    border-radius: 16px;
    border: 2px solid var(--accent-color);
}

.swal2-confirm {
    background-color: var(--secondary-color) !important;
    border-radius: 8px;
}

.swal2-cancel {
    background-color: var(--gray-color) !important;
    border-radius: 8px;
}

.temporary-banner {
    background: linear-gradient(135deg, var(--accent-color), #f4c63d);
    color: var(--primary-color);
    padding: 12px 0;
    position: relative;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.banner-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    position: relative;
    max-width: 100%;
}

.banner-icon {
    font-size: 1.2rem;
    color: var(--primary-color);
    flex-shrink: 0;
}

.banner-text {
    text-align: center;
    font-size: 14px;
    line-height: 1.4;
    flex-grow: 1;
}

.banner-close {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 16px;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: all 0.3s ease;
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
}

    .banner-close:hover {
        background: rgba(36, 43, 87, 0.1);
        transform: translateY(-50%) scale(1.1);
    }

.password-container {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-color);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
}

    .password-toggle:hover {
        color: var(--primary-color);
        background: rgba(36, 43, 87, 0.1);
    }

    .password-toggle:focus {
        outline: none;
        color: var(--secondary-color);
        background: rgba(0, 126, 173, 0.1);
    }

.password-container .form-control {
    padding-right: 4rem;
}

/* Media queries para responsive */
@media (max-width: 768px) {
    .login-container {
        padding: 1rem 0.5rem;
        min-height: calc(100vh - 100px);
    }

    .login-card {
        max-height: none;
    }

    .footer {
        padding: 10px 0;
        text-align: center;
    }

        .footer .container {
            padding-left: 10px;
            padding-right: 10px;
        }

        .footer p {
            font-size: 12px;
            line-height: 1.3;
            margin-bottom: 5px;
        }

        .footer small {
            font-size: 11px;
        }

        .footer, .footer * {
            box-sizing: border-box;
            max-width: 100%;
        }

    .temporary-banner {
        padding: 10px 0;
    }

    .banner-content {
        flex-direction: column;
        gap: 8px;
        padding: 0 40px;
    }

    .banner-text {
        font-size: 13px;
    }

    .banner-close {
        top: 8px;
        right: 8px;
        transform: none;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 8px 0;
    }

        .footer .container {
            padding-left: 8px;
            padding-right: 8px;
        }

        .footer p {
            font-size: 11px;
        }

        .footer small {
            font-size: 10px;
        }

        .footer p {
            white-space: normal;
        }
}
