*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    height: 100%;
    font-family: 'Helvetica Neue', Arial, sans-serif;
    background: #fff;
    overflow: hidden;
}


.login-wrapper {
    display: flex;
    height: 100vh;
    width: 100vw;
}

/* ════════════ PANEL IZQUIERDO ════════════ */
.panel-left {
    position: relative;
    flex: 1 1 70%;
    overflow: hidden;
    background: #111;
}

/* Imagen — reemplaza /images/login-bg.jpg con tu ruta */
.panel-left__img {
    position: absolute;
    inset: 0;
    background-image: url('/Files/img/Login/bg-1.webp');
    background-size: cover;
    background-position: right center;
    filter: grayscale(100%) brightness(0.6);
}

.panel-left__gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.30) 0%,
        rgba(0,0,0,0.08) 55%,
        rgba(0,0,0,0.65) 100%
    );
}

.panel-left__body {
    position: relative;
    z-index: 5;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    padding: 2.2rem 2.8rem;
}

/* Logo */
.brand { display: flex; align-items: flex-start; gap: 0.65rem; }
.brand__icon {
    width: 42px; height: 42px;
    background: #16213F;
    border-radius: 3px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.brand__icon svg { width: 24px; height: 24px; fill: #fff; }
.brand__text { line-height: 1.25; }
.brand__name {
    display: block; color: #fff;
    font-size: 0.95rem; font-weight: 700; letter-spacing: 0.03em;
}
.brand__tagline {
    display: block; color: rgba(255,255,255,0.60);
    font-size: 0.72rem; font-style: italic;
}

.brand__icon {
    width: 300px;
    height: auto;
    background: transparent; /* opcional */
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.brand__img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Título grande bottom-left — igual que "3M Window Films" */
.panel-hero__title {
    font-size: clamp(2rem, 3.6vw, 3.4rem);
    font-weight: 700;
    color: #ffffff;
    line-height: 1.08;
    letter-spacing: -0.01em;
}

/* ════════════ PANEL DERECHO ════════════ */
.panel-right {
    flex: 0 0 360px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem 3rem 2rem;
    position: relative;
}

.form-title {
    font-size: 1.5rem;
    font-weight: 400;
    color: #222;
    margin-bottom: 2.6rem;
    letter-spacing: 0.005em;
}

/* Inputs de línea */
.field { position: relative; margin-bottom: 2rem; }

.field__input {
    width: 100%;
    border: none;
    border-bottom: 1px solid #bbb;
    padding: 0.55rem 1.6rem 0.4rem 0;
    font-size: 0.88rem;
    color: #222;
    background: transparent;
    outline: none;
    transition: border-color 0.2s;
}
.field__input:focus        { border-color: #333; }
.field__input.is-invalid-field { border-color: #16213F; }
.field__input::placeholder { color: #aaa; font-size: 0.85rem; }

/* Toggle contraseña */
.field__toggle {
    position: absolute; right: 0; bottom: 0.45rem;
    background: none; border: none; padding: 0;
    cursor: pointer; color: #aaa; line-height: 1;
}
.field__toggle:focus { outline: none; }
.field__toggle svg { width: 17px; height: 17px; fill: currentColor; display: block; }
.field__toggle:hover { color: #555; }

/* Error inline */
.field__error {
    font-size: 0.7rem;
    color: #a80000;
    margin-top: 0.3rem;
    display: block;
}

/* Alerta general */
.alert-login {
    font-size: 0.76rem;
    color: #a80000;
    margin-bottom: 1rem;
    padding: 0.45rem 0.7rem;
    border-left: 3px solid #a80000;
    background: rgba(204,0,0,0.04);
}

/* Botón rojo */
.btn-login {
    display: block;
    width: 100%;
    padding: 0.78rem 1rem;
    background: #16213F;
    color: #fff;
    border: none;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    cursor: pointer;
    margin-top: 0.4rem;
    transition: background 0.2s;
}
.btn-login:hover:not(:disabled) { background: #000000; }
.btn-login:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-login .spinner-border {
    width: 0.82rem; height: 0.82rem;
    border-width: 2px; margin-right: 0.4rem;
    vertical-align: middle;
}

/* Links rojos */
.form-links {
    margin-top: 1.6rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
}
.form-link {
    font-size: 0.8rem;
    color: #16213F;
    text-decoration: none;
}
.form-link:hover { color: #000000; text-decoration: none; }

/* Pie del panel */
.panel-right__footer {
    position: absolute;
    bottom: 1.2rem;
    left: 0; right: 0;
    text-align: center;
}
.panel-right__footer a {
    font-size: 0.67rem; color: #999;
    text-decoration: none; display: block; margin-bottom: 0.15rem;
}
.panel-right__footer a:hover { color: #555; }
.panel-right__footer p {
    font-size: 0.63rem; color: #bbb; margin: 0;
}

/* ════════════ RESPONSIVE ════════════ */
@media (max-width: 768px) {
    html, body { overflow: auto; }
    .login-wrapper { flex-direction: column; height: auto; min-height: 100vh; }
    .panel-left { flex: 0 0 210px; height: 210px; }
    .panel-right { flex: 1; padding: 2rem 1.75rem 4rem; }
    .panel-right__footer { position: static; margin-top: 2rem; }
}
