/* ============================================================
   index.css — Estilos de la página de acceso (login / registro).
   ============================================================ */

/* ── Reset y body centrado ──────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: "Work Sans", Arial, sans-serif;
    background: #f0eeeb;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px 16px;
}

/* ── Contenedor principal ────────────────────────────────────── */
.wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    width: 100%;
    max-width: 400px;
}

/* ── Logotipo / marca ───────────────────────────────────────── */
.brand h1 {
    font-family: "Playfair Display", serif;
    font-size: 2rem;
    font-weight: 600;
    color: #1a1a1a;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
}
.brand p {
    font-size: 0.75rem;
    color: #aaa;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-weight: 500;
    text-align: center;
    margin-top: 4px;
}

/* ── Tarjeta ─────────────────────────────────────────────────── */
.card {
    width: 100%;
    background: #e8e6e3;
    border-radius: 24px;
    padding: 32px 28px 28px;
    box-shadow: 10px 10px 30px #c9c7c4, -10px -10px 30px #ffffff;
}

/* ── Tabs registro / login ───────────────────────────────────── */
.tabs {
    display: flex;
    background: #d8d6d3;
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 28px;
    box-shadow: inset 2px 2px 5px #c0bebb, inset -2px -2px 5px #f0eeeb;
}
.tab {
    flex: 1;
    padding: 9px;
    border: none;
    border-radius: 9px;
    background: transparent;
    font-family: inherit;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #999;
    cursor: pointer;
    transition: all .2s;
}
.tab.active {
    background: #e8e6e3;
    color: #1a1a1a;
    box-shadow: 3px 3px 8px #c9c7c4, -3px -3px 8px #ffffff;
}

/* ── Paneles (registro / login) ─────────────────────────────── */
.panel        { display: none; }
.panel.active { display: block; }

/* ── Campos de formulario ────────────────────────────────────── */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #888;
}
.field input {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid rgba(0,0,0,.1);
    border-radius: 10px;
    background: #f0eeeb;
    font-family: inherit;
    font-size: 0.9rem;
    color: #1a1a1a;
    outline: none;
    transition: border-color .2s;
    box-shadow: inset 3px 3px 6px #d1cfcc, inset -3px -3px 6px #fff;
}
.field input:focus       { border-color: #1a1a1a; }
.field input::placeholder { color: #bbb; }

/* ── Botón principal ─────────────────────────────────────────── */
.btn-primary {
    width: 100%;
    padding: 13px;
    background: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 12px;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background .2s;
    margin-top: 6px;
}
.btn-primary:hover    { background: #333; }
.btn-primary:disabled { opacity: .45; cursor: not-allowed; }

/* ── Divisor "o" ─────────────────────────────────────────────── */
.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
}
.divider::before, .divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(0,0,0,.1);
}
.divider span {
    font-size: 0.68rem;
    color: #bbb;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* ── Botón Google ────────────────────────────────────────────── */
.btn-google {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 20px;
    background: #f0eeeb;
    border: 1.5px solid rgba(0,0,0,.1);
    border-radius: 12px;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #1a1a1a;
    transition: background .2s, border-color .2s;
    box-shadow: inset 3px 3px 6px #d1cfcc, inset -3px -3px 6px #fff;
}
.btn-google:hover    { background: #e8e6e3; border-color: rgba(0,0,0,.2); }
.btn-google:disabled { opacity: .5; cursor: not-allowed; }

.btn-google-wrap { position: relative; }
.g-btn-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    overflow: hidden;
    border-radius: 12px;
    opacity: 0.01;  /* invisible pero recibe clicks */
    cursor: pointer;
}

/* ── Checklist de requisitos de contraseña ───────────────────── */
.pwd-rules {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 8px;
    margin-bottom: 4px;
}
.pwd-rule {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 0.72rem;
    color: #bbb;
    transition: color .2s;
}
.pwd-rule.ok { color: #27ae60; }
.pwd-rule .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ccc;
    flex-shrink: 0;
    transition: background .2s;
}
.pwd-rule.ok .dot { background: #27ae60; }

/* ── Mensaje de error ────────────────────────────────────────── */
.msg-error {
    font-size: 0.78rem;
    color: #c0392b;
    background: #fdecea;
    border-left: 3px solid #c0392b;
    padding: 10px 12px;
    border-radius: 6px;
    margin-bottom: 14px;
    display: none;
}
.msg-error.visible { display: block; }

/* ── Pie de página ───────────────────────────────────────────── */
.footer {
    font-size: 0.7rem;
    color: #ccc;
    letter-spacing: 0.04em;
}

/* ── Ocultar elementos de Google Identity Services ───────────── */
#g_id_onload, #g_id_signin { display: none; }
