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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #e8f8f5 0%, #d4f1e8 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-container {
    width: 100%;
    max-width: 480px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    overflow: hidden;
}

a.volver {
    display: inline-block;
    margin: 15px 0 0 15px;
    color: #5cb85c;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}
/* Header con logo y título */
.login-header {
    background: linear-gradient(135deg, #5cb85c 0%, #4cae4c 100%);
    padding: 3rem 2rem;
    text-align: center;
    color: white;
}

.login-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.login-header p {
    font-size: 1rem;
    opacity: 0.95;
}

/* Contenedor del formulario */
.login-body {
    padding: 3rem 2.5rem;
}

.form-container {
    display: none;
}

.form-container.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.form-container h2 {
    color: #2d3e50;
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.form-subtitle {
    color: #6c757d;
    margin-bottom: 2rem;
    text-align: center;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: #2d3e50;
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e8f5f1;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8fdf9;
}

.form-group input:focus {
    outline: none;
    border-color: #5cb85c;
    background: white;
    box-shadow: 0 0 0 3px rgba(92, 184, 92, 0.1);
}

.password-input {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 5px;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.toggle-password:hover {
    opacity: 1;
}

.error-message {
    display: block;
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 0.3rem;
    min-height: 18px;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

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

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

.link {
    color: #5cb85c;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.link:hover {
    color: #4cae4c;
    text-decoration: underline;
}

.btn-submit {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #5cb85c 0%, #4cae4c 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(92, 184, 92, 0.3);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(92, 184, 92, 0.4);
}

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

.form-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: #6c757d;
    font-size: 0.95rem;
}

/* Mensaje de éxito */
.success-message {
    background: #d4edda;
    color: #155724;
    padding: 14px;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    border: 1px solid #c3e6cb;
    display: none;
    text-align: center;
    font-size: 0.95rem;
}

.success-message.show {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 15px;
    }

    .login-container {
        max-width: 100%;
    }

    .login-header {
        padding: 2rem 1.5rem;
    }

    .login-header h1 {
        font-size: 2rem;
    }

    .login-body {
        padding: 2rem 1.5rem;
    }

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

@media (max-width: 480px) {
    .login-header {
        padding: 1.5rem 1rem;
    }

    .login-header h1 {
        font-size: 1.8rem;
    }

    .login-body {
        padding: 1.5rem 1rem;
    }

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

    .btn-submit {
        padding: 14px;
        font-size: 1rem;
    }
}