/* ===========================
   ESTILO GENERAL
=========================== */
body {
    margin: 0;
    padding: 0;
    font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, Arial;
    background: #f1f5f9; /* gris claro suave */
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

/* ===========================
   CARD PRINCIPAL
=========================== */
.wrapper {
    width: 100%;
    max-width: 550px;
    padding: 20px;
}

.card {
    background: white;
    padding: 40px 35px;
    border-radius: 16px;
    box-shadow: 0px 8px 32px rgba(0,0,0,0.08);
    border: 1px solid #e2e8f0;
}

.logo {
    font-size: 22px;
    font-weight: 700;
    color: #334155;
    margin-bottom: 15px;
}

h1 {
    margin: 0;
    font-size: 26px;
    color: #1e293b;
    margin-bottom: 10px;
}

.intro {
    color: #64748b;
    font-size: 15px;
    margin-bottom: 25px;
}

/* ===========================
   FORMULARIO
=========================== */
form div {
    margin-bottom: 18px;
}

label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 6px;
}

input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1.5px solid #cbd5e1;
    font-size: 15px;
    outline: none;
    transition: all 0.2s ease;
    background: #f8fafc;
}

input:focus {
    border-color: #6366f1;
    background: #fff;
    box-shadow: 0px 0px 0px 3px rgba(99,102,241,0.2);
}

hr {
    margin: 25px 0;
    border: none;
    border-top: 1px solid #e2e8f0;
}

/* ===========================
   VALIDACIONES / ERRORES
=========================== */
.error-msg {
    display: block;
    margin-top: 5px;
    font-size: 13px;
    color: #dc2626; /* rojo */
    font-weight: 500;
}

/* Alerta superior (cuando llega desde servidor) */
.alert {
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 18px;
    font-size: 14px;
}

.alert.success {
    background: #ecfdf5;
    color: #15803d;
    border: 1px solid #a7f3d0;
}

.alert.error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

/* ===========================
   FORTALEZA DE CONTRASEÑA
=========================== */
#password-strength {
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 8px;
    margin-top: 6px;
    overflow: hidden;
}

#password-bar {
    height: 100%;
    width: 0%;
    background: #ef4444;
    transition: width 0.25s ease, background 0.25s ease;
}

/* ===========================
   BOTÓN
=========================== */
button[type="submit"] {
    width: 100%;
    padding: 14px;
    margin-top: 10px;
    background: #4f46e5;
    color: white;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.25s ease;
}

button[type="submit"]:hover {
    background: #4338ca;
}

button[type="submit"]:active {
    transform: scale(0.98);
}

/* ===========================
   FOOTER
=========================== */
.footer {
    margin-top: 25px;
    text-align: center;
    font-size: 14px;
    color: #475569;
}

.footer a {
    color: #4f46e5;
    font-weight: 600;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}
