/* ── PuntoFarmaceuta · Login — Brand Identity v2.0 ── */

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

:root {
    --azul: #283376;
    --azul-deep: #1e2860;
    --azul-marino: #161a3a;
    --azul-brillante: #3f51b5;
    --azul-brillante-hover: #303f9f;
    --verde: #31975c;
    --verde-claro: #9bd5b3;
    --blanco: #ffffff;
    --gris-claro: #f3f5fa;
    --gris: #444444;
    --texto-muted: #5b6478;
    --error: #ed3c0d;
    --exito: #18d26e;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Open Sans', 'Segoe UI', sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, var(--azul-marino) 0%, var(--azul-deep) 40%, var(--azul) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* ── Animated background ── */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at 25% 75%, rgba(71,178,228,0.1) 0%, transparent 55%),
        radial-gradient(ellipse at 75% 25%, rgba(97,167,84,0.07) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* ── Decorative dots ── */
body::after {
    content: '';
    position: fixed;
    top: 2rem;
    right: 2.5rem;
    width: 60px;
    height: 60px;
    background-image:
        radial-gradient(circle, rgba(255,255,255,0.1) 1.5px, transparent 1.5px);
    background-size: 12px 12px;
    pointer-events: none;
    z-index: 0;
}

/* ── Login container ── */
.login-wrapper {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    padding: 1.5rem;
}

/* ── Card ── */
.login-card {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 2.5rem 2rem 2rem;
    box-shadow:
        0 20px 60px rgba(20,30,80,0.25),
        0 4px 14px rgba(20,30,80,0.1);
    text-align: center;
}

/* ── Logo ── */
.login-logo-link {
    display: inline-block;
    margin-bottom: 1.5rem;
    text-decoration: none;
}

.login-logo {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--blanco);
    box-shadow: 0 6px 20px rgba(55,81,126,0.18);
    transition: transform 0.3s ease;
}

.login-logo:hover {
    transform: scale(1.06);
}

/* ── Title ── */
.login-title {
    font-family: 'Jost', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--azul);
    margin-bottom: 0.2rem;
}

.login-subtitle {
    font-family: 'Poppins', sans-serif;
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--verde);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 1.75rem;
}

/* ── Alerts ── */
.login-card .alert {
    border: none;
    border-radius: 12px;
    padding: 0.75rem 1rem;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    text-align: left;
}

.login-card .alert-danger {
    background: rgba(237,60,13,0.08);
    color: var(--error);
}

.login-card .alert-success {
    background: rgba(24,210,110,0.08);
    color: #15803d;
}

/* ── Form ── */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.login-input {
    width: 100%;
    height: 48px;
    padding: 0 1rem 0 2.75rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    color: var(--gris);
    background: var(--blanco);
    transition: all 0.25s ease;
    outline: none;
}

.login-input:focus {
    border-color: var(--azul-brillante);
    box-shadow: 0 0 0 3px rgba(71,178,228,0.12);
}

.login-input::placeholder {
    color: #a0aec0;
}

/* ── Input group with icon ── */
.input-group {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #94a3b8;
    pointer-events: none;
    transition: color 0.25s ease;
}

.input-group:focus-within .input-icon {
    color: var(--azul-brillante);
}

/* ── Submit button ── */
.login-btn {
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--azul) 0%, var(--azul-deep) 100%);
    color: var(--blanco);
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.login-btn:hover {
    background: linear-gradient(135deg, var(--azul-brillante) 0%, var(--azul) 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(71,178,228,0.3);
}

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

/* ── Brand footer ── */
.login-brand {
    margin-top: 1.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid #eef2f7;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    color: var(--texto-muted);
}

.login-brand a {
    color: var(--azul-brillante);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease;
}

.login-brand a:hover {
    color: var(--azul);
}

/* ── Back link ── */
.login-back {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 1.25rem;
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    font-family: 'Poppins', sans-serif;
    font-size: 0.78rem;
    font-weight: 400;
    transition: color 0.3s ease;
}

.login-back:hover {
    color: rgba(255,255,255,0.8);
}

.login-back svg {
    width: 14px;
    height: 14px;
}

/* ── Responsive ── */
@media (max-width: 480px) {
    .login-wrapper {
        padding: 1rem;
    }

    .login-card {
        padding: 2rem 1.5rem 1.75rem;
        border-radius: 20px;
    }

    .login-logo {
        width: 72px;
        height: 72px;
    }

    .login-title {
        font-size: 1.3rem;
    }
}

/* ── Bootstrap compat ── */
.profile-name-card,
.reauth-email { display: none; }
