/* ==========================================================================
   Área de cuenta — se apoya en styles.css y solo agrega lo propio
   ========================================================================== */

.auth {
  min-height: calc(100vh - var(--header-h) - 90px);
  display: flex;
  align-items: center;
  padding-block: clamp(32px, 6vw, 64px);
  background: var(--surface);
}

.auth__card {
  width: 100%;
  max-width: 480px;
  margin-inline: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: clamp(26px, 5vw, 40px);
}
.auth__card--ancha { max-width: 620px; }

.auth__head { text-align: center; margin-bottom: 26px; }
.auth__mark {
  width: 52px; height: 52px; margin: 0 auto 16px;
  display: grid; place-items: center;
  background: var(--brand-soft); color: var(--brand);
  border-radius: 50%;
}
.auth__title { font-size: clamp(1.35rem, 3vw, 1.65rem); margin-bottom: .35em; }
.auth__sub { color: var(--muted); font-size: .95rem; margin: 0; }

.auth__form { display: grid; gap: 18px; }
.auth__form .field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }

.auth__foot {
  margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line-soft);
  text-align: center; font-size: .93rem; color: var(--muted);
}
.auth__foot a { font-weight: 600; }

/* Enlace "olvidé mi contraseña" alineado con la etiqueta */
.label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.label-row a { font-size: .85rem; }

/* Campo de contraseña con botón de mostrar/ocultar */
.password-wrap { position: relative; }
.password-wrap input { padding-right: 48px; }
.password-toggle {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; display: grid; place-items: center;
  background: none; border: 0; color: var(--muted); border-radius: var(--radius);
}
.password-toggle:hover { color: var(--brand); background: var(--surface); }

/* Medidor de fortaleza */
.medidor { display: grid; gap: 6px; }
.medidor__barras { display: flex; gap: 5px; }
.medidor__barra {
  flex: 1; height: 4px; border-radius: 2px; background: var(--line);
  transition: background .25s var(--ease);
}
.medidor__texto { font-size: .82rem; color: var(--muted-soft); min-height: 1.2em; }
.medidor[data-nivel="1"] .medidor__barra:nth-child(-n+1) { background: #d1434b; }
.medidor[data-nivel="2"] .medidor__barra:nth-child(-n+2) { background: #e08a2e; }
.medidor[data-nivel="3"] .medidor__barra:nth-child(-n+3) { background: #d3b427; }
.medidor[data-nivel="4"] .medidor__barra { background: #2f9e44; }
.medidor[data-nivel="1"] .medidor__texto { color: #b4232a; }
.medidor[data-nivel="4"] .medidor__texto { color: #2f9e44; }

/* Requisitos de la contraseña */
.requisitos { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 5px; font-size: .85rem; color: var(--muted); }
.requisitos li { display: flex; align-items: center; gap: 8px; margin: 0; }
.requisitos li::before {
  content: ""; width: 14px; height: 14px; flex: none; border-radius: 50%;
  border: 1.5px solid var(--line); transition: background .2s var(--ease), border-color .2s var(--ease);
}
.requisitos li.ok { color: #2f7a3d; }
.requisitos li.ok::before {
  background: #2f9e44 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 13 4 4L19 7'/%3E%3C/svg%3E") center/9px no-repeat;
  border-color: #2f9e44;
}

/* Alertas */
.alerta {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 13px 16px; margin-bottom: 20px;
  border-radius: var(--radius); font-size: .93rem; line-height: 1.5;
  border: 1px solid transparent;
}
.alerta svg { flex: none; margin-top: 2px; }
.alerta--error { background: #fdf2f2; border-color: #f3c9cb; color: #8d191f; }
.alerta--ok    { background: #edf7ee; border-color: #c6e5c9; color: #1e6b2b; }
.alerta--aviso { background: #fff8e8; border-color: #f0dcae; color: #7a5a13; }

/* ---------------------------------------------------------------- panel ---- */
.panel-head {
  background: var(--navy-deep); color: #fff;
  padding-block: clamp(30px, 5vw, 48px);
}
.panel-head__inner { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; justify-content: space-between; }
.panel-head h1 { color: #fff; font-size: clamp(1.5rem, 3.4vw, 2.1rem); margin-bottom: .2em; }
.panel-head p { color: rgba(255,255,255,.8); margin: 0; }
.avatar {
  width: 60px; height: 60px; flex: none; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand); color: #fff;
  font-size: 1.4rem; font-weight: 700; letter-spacing: .02em;
}
.panel-head__id { display: flex; align-items: center; gap: 18px; min-width: 0; }

.panel-grid { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 34px; align-items: start; }

.panel-menu {
  border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden;
  position: sticky; top: calc(var(--header-h) + 20px);
}
.panel-menu a {
  display: flex; align-items: center; gap: 11px;
  padding: 13px 18px; font-size: .95rem; font-weight: 600; color: var(--ink);
  border-bottom: 1px solid var(--line-soft);
}
.panel-menu a:last-child { border-bottom: 0; }
.panel-menu a:hover { background: var(--surface); color: var(--brand); }
.panel-menu a.is-current {
  background: var(--brand-soft); color: var(--brand);
  box-shadow: inset 3px 0 0 var(--brand);
}
.panel-menu svg { flex: none; }

.dato-lista { display: grid; gap: 0; }
.dato-lista__fila {
  display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 16px;
  padding: 14px 0; border-bottom: 1px solid var(--line-soft);
}
.dato-lista__fila:last-child { border-bottom: 0; }
.dato-lista dt { font-weight: 600; color: var(--muted); font-size: .92rem; margin: 0; }
.dato-lista dd { margin: 0; color: var(--ink-strong); word-break: break-word; }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px; border-radius: 100px;
  font-size: .78rem; font-weight: 700; letter-spacing: .04em;
}
.badge--ok    { background: #edf7ee; color: #1e6b2b; }
.badge--aviso { background: #fff8e8; color: #7a5a13; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1024px) {
  .panel-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .panel-menu { position: static; display: flex; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .panel-menu a { border-bottom: 0; border-right: 1px solid var(--line-soft); white-space: nowrap; }
  .panel-menu a.is-current { box-shadow: inset 0 -3px 0 var(--brand); }
}

@media (max-width: 640px) {
  .auth { background: #fff; padding-block: 26px; }
  .auth__card { border: 0; box-shadow: none; padding: 0; max-width: 100%; }
  .auth__form .field-row { grid-template-columns: minmax(0, 1fr); }
  .auth__form .btn { width: 100%; }
  .dato-lista__fila { grid-template-columns: minmax(0, 1fr); gap: 3px; padding: 12px 0; }
  .panel-head__id { gap: 14px; }
  .avatar { width: 50px; height: 50px; font-size: 1.2rem; }
}
