:root {
    --verde: #2f6b3f;
    --verde-oscuro: #255533;
    --tinta: #1f2a23;
    --texto: #5b665f;
    --linea: #d9dedb;
    --fondo: #f2f4f3;
}

* { box-sizing: border-box; }

body.gate {
    margin: 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: var(--fondo);
    color: var(--tinta);
    font-family: Arial, Helvetica, sans-serif;
}

.gate-card {
    width: min(380px, 100%);
    background: #fff;
    border: 1px solid var(--linea);
    border-top: 4px solid var(--verde);
    border-radius: 4px;
    padding: 1.75rem 1.75rem 1.5rem;
}

.gate-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.gate-logo {
    width: 44px;
    height: 44px;
    object-fit: contain;
}

.gate-brand strong {
    display: block;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
}

.gate-brand span {
    display: block;
    color: var(--texto);
    font-size: 0.82rem;
    margin-top: 0.1rem;
}

.gate-card h2 {
    margin: 0 0 1rem;
    font-size: 1.1rem;
    font-weight: bold;
}

.gate-lead {
    margin: -0.6rem 0 1rem;
    color: var(--texto);
    font-size: 0.88rem;
}

.gate-form { display: grid; gap: 0.3rem; }

.gate-form label {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    font-weight: bold;
}

.gate-form input {
    width: 100%;
    border: 1px solid #c4cbc6;
    background: #fff;
    border-radius: 3px;
    padding: 0.65rem 0.7rem;
    font: inherit;
    font-size: 0.95rem;
    color: var(--tinta);
}

.gate-form input:focus {
    outline: 2px solid rgba(47, 107, 63, 0.25);
    border-color: var(--verde);
}

.pass-wrap { position: relative; }
.pass-wrap input { padding-right: 2.5rem; }

.pass-toggle {
    position: absolute;
    right: 0.25rem;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: var(--texto);
    cursor: pointer;
    padding: 0.4rem 0.5rem;
}

.gate-form button[type="submit"] {
    margin-top: 1.1rem;
    border: 0;
    border-radius: 3px;
    background: var(--verde);
    color: #fff;
    font: inherit;
    font-size: 0.95rem;
    font-weight: bold;
    padding: 0.7rem 1rem;
    cursor: pointer;
}

.gate-form button[type="submit"]:hover { background: var(--verde-oscuro); }

.gate-alert {
    background: #fbeaea;
    border: 1px solid #e6c1c1;
    color: #8a2b2b;
    border-radius: 3px;
    padding: 0.6rem 0.7rem;
    margin-bottom: 0.5rem;
    font-size: 0.88rem;
}

.gate-modules { display: grid; gap: 0.5rem; }

.gate-module {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    text-decoration: none;
    color: var(--tinta);
    border: 1px solid var(--linea);
    border-radius: 3px;
    padding: 0.75rem 0.8rem;
    background: #fff;
}

.gate-module i {
    width: 1.25rem;
    text-align: center;
    color: var(--verde);
}

.gate-module strong { display: block; font-size: 0.95rem; }
.gate-module small { display: block; color: var(--texto); font-size: 0.8rem; margin-top: 0.1rem; }
.gate-module:hover { border-color: var(--verde); background: #f7f9f8; }

.gate-logout {
    display: inline-block;
    margin-top: 1rem;
    color: var(--verde);
    font-size: 0.85rem;
}

.gate-pie {
    margin-top: 1.25rem;
    padding-top: 0.9rem;
    border-top: 1px solid var(--linea);
    color: var(--texto);
    font-size: 0.75rem;
    text-align: center;
}
