/*
 * File: /public/assets/css/login.css
 * Version: 0.2.0-dev
 * Date: 2026-08-26
 * Project: Nuevo Habitar Residentes
 */

:root {
    --navy: #10243e;
    --navy-2: #183552;
    --gold: #c6a16a;

    --page: #f5f6f8;
    --surface: #ffffff;

    --text: #1c2630;
    --muted: #6d7782;
    --border: #dde2e7;

    --error-bg: #fff4f4;
    --error-border: #f0cccc;
    --error-text: #9c3030;

    --radius: 14px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    color: var(--text);
    background: var(--page);

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    -webkit-font-smoothing: antialiased;
}

button,
input {
    font: inherit;
}

button {
    -webkit-tap-highlight-color: transparent;
}

.page {
    display: grid;
    grid-template-columns:
        minmax(390px, 44%)
        minmax(440px, 56%);

    min-height: 100vh;
}

/* INTRO */

.intro {
    position: relative;

    display: flex;
    flex-direction: column;

    min-height: 100vh;
    padding: 48px 54px;

    color: #fff;

    background:
        radial-gradient(
            circle at 85% 15%,
            rgba(255,255,255,.10),
            transparent 30%
        ),
        linear-gradient(
            145deg,
            var(--navy),
            var(--navy-2)
        );

    overflow: hidden;
}

.intro::after {
    content: "";

    position: absolute;
    right: -180px;
    bottom: -280px;

    width: 520px;
    height: 520px;

    border:
        1px solid
        rgba(255,255,255,.08);

    border-radius: 50%;
}

.brand {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    gap: 14px;
}

.brand-symbol {
    display: grid;
    place-items: center;

    width: 48px;
    height: 48px;

    border:
        1px solid
        rgba(255,255,255,.3);

    border-radius: 12px;

    font-size: 15px;
    font-weight: 700;
    letter-spacing: .08em;
}

.brand-name {
    font-size: 17px;
    font-weight: 600;
}

.brand-caption {
    margin-top: 3px;

    color:
        rgba(255,255,255,.62);

    font-size: 12px;
}

.intro-copy {
    position: relative;
    z-index: 1;

    max-width: 600px;

    margin-top: auto;
    margin-bottom: auto;
}

.eyebrow {
    margin-bottom: 22px;

    color: var(--gold);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: .14em;
    text-transform: uppercase;
}

.intro h1 {
    margin: 0;

    font-size:
        clamp(45px, 5vw, 72px);

    line-height: 1.01;
    font-weight: 500;

    letter-spacing: -.045em;
}

.intro-copy p {
    max-width: 510px;

    margin: 28px 0 0;

    color:
        rgba(255,255,255,.68);

    font-size: 17px;
    line-height: 1.7;
}

.intro-footer {
    position: relative;
    z-index: 1;

    color:
        rgba(255,255,255,.40);

    font-size: 11px;
    letter-spacing: .04em;
}

/* LOGIN */

.access {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 100vh;
    padding: 50px;
}

.access-inner {
    width: 100%;
    max-width: 420px;
}

.mobile-brand {
    display: none;
}

.access-header {
    margin-bottom: 34px;
}

.access-label {
    display: block;

    margin-bottom: 10px;

    color: var(--gold);

    font-size: 11px;
    font-weight: 700;

    letter-spacing: .15em;
    text-transform: uppercase;
}

.access-header h2 {
    margin: 0 0 9px;

    color: var(--navy);

    font-size: 34px;
    font-weight: 600;

    letter-spacing: -.035em;
}

.access-header p {
    margin: 0;

    color: var(--muted);

    font-size: 14px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

label {
    color: #35414d;

    font-size: 13px;
    font-weight: 600;
}

input {
    width: 100%;
    height: 52px;

    padding: 0 15px;

    color: var(--text);

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius: 10px;

    outline: none;

    transition:
        border-color .15s ease,
        box-shadow .15s ease;
}

input::placeholder {
    color: #a1a8af;
}

input:focus {
    border-color: #8093a7;

    box-shadow:
        0 0 0 4px
        rgba(16, 36, 62, .06);
}

.password-field {
    position: relative;
}

.password-field input {
    padding-right: 65px;
}

.password-toggle,
.text-button {
    border: 0;
    padding: 0;

    color: var(--navy-2);
    background: transparent;

    cursor: pointer;

    font-size: 12px;
    font-weight: 600;
}

.password-toggle {
    position: absolute;

    top: 50%;
    right: 14px;

    transform:
        translateY(-50%);
}

.primary-button {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 52px;
    margin-top: 3px;

    color: #fff;
    background: var(--navy);

    border: 0;
    border-radius: 10px;

    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    transition:
        background .15s ease,
        transform .08s ease;
}

.primary-button:hover:not(:disabled) {
    background: var(--navy-2);
}

.primary-button:active {
    transform: translateY(1px);
}

.primary-button:disabled {
    opacity: .65;
    cursor: wait;
}

.form-message {
    padding: 12px 14px;

    color: var(--error-text);
    background: var(--error-bg);

    border:
        1px solid
        var(--error-border);

    border-radius: 9px;

    font-size: 13px;
    line-height: 1.45;
}

.spinner {
    width: 17px;
    height: 17px;

    border:
        2px solid
        rgba(255,255,255,.35);

    border-top-color: #fff;

    border-radius: 50%;

    animation:
        spinner .65s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}

.activation {
    display: flex;
    gap: 12px;

    margin-top: 34px;
    padding-top: 25px;

    border-top:
        1px solid #e7eaed;
}

.activation-icon {
    display: grid;
    place-items: center;

    flex: 0 0 28px;

    width: 28px;
    height: 28px;

    color: var(--navy);

    background: #eef2f5;

    border-radius: 50%;

    font-family: Georgia, serif;
    font-size: 14px;
    font-weight: 700;
}

.activation strong {
    display: block;

    margin-bottom: 3px;

    font-size: 13px;
}

.activation p {
    margin: 0;

    color: var(--muted);

    font-size: 12px;
    line-height: 1.5;
}

.access-footer {
    margin-top: 40px;

    color: #9aa1a8;

    font-size: 11px;
    text-align: center;
}

/* MOBILE */

@media (max-width: 820px) {

    .page {
        display: block;
    }

    .intro {
        display: none;
    }

    .access {
        min-height: 100svh;

        padding:
            32px 22px
            max(
                28px,
                env(safe-area-inset-bottom)
            );
    }

    .access-inner {
        max-width: 460px;
    }

    .mobile-brand {
        display: flex;
        align-items: center;
        gap: 12px;

        margin-bottom: 54px;
    }

    .brand-symbol.small {
        width: 42px;
        height: 42px;

        color: #fff;
        background: var(--navy);

        border: 0;

        font-size: 13px;
    }

    .mobile-brand-name {
        color: var(--navy);

        font-size: 16px;
        font-weight: 650;
    }

    .mobile-brand-caption {
        margin-top: 2px;

        color: var(--muted);

        font-size: 11px;
    }

    .access-header h2 {
        font-size: 30px;
    }
}

@media (max-width: 380px) {

    .access {
        padding-left: 17px;
        padding-right: 17px;
    }

}