:root{
  /* ✅ Paleta alineada a dashboard.css */
  --bg0:#0a0b0e;    /* dashboard --bg2 */
  --bg1:#0b0c0f;    /* dashboard --bg  */
  --bg2:#0b0c0f;

  --text:#f5f5f7;   /* dashboard style */
  --muted:#a1a1a6;  /* dashboard --muted */
  --muted2:#c7c7cc; /* dashboard --muted2 */

  /* superficies glass como dashboard */
  --panel: rgba(18, 18, 20, .62);        /* dashboard --panel */
  --panel-strong: rgba(18, 18, 20, .78); /* dashboard --panel-strong */
  --border: rgba(255,255,255,.10);       /* dashboard --border */
  --border2: rgba(255,255,255,.14);      /* dashboard --border2 */
  --shadow: 0 26px 90px rgba(0,0,0,.55); /* dashboard --shadow */
  --shadow2: 0 12px 40px rgba(0,0,0,.40);

  --radius: 18px;
  --radius2: 26px;
  --blur: 18px;

  /* hover/focus como dashboard */
  --hover: rgba(255,255,255,.06);
  --hover2: rgba(255,255,255,.10);
  --ring: 0 0 0 4px rgba(255,255,255,.08); /* dashboard inputs focus ring */
}

*{ box-sizing:border-box; }
html,body{ height:100%; margin:0; }

body{
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", system-ui, Segoe UI, Roboto, Arial;
  color: var(--text);
  overflow-x:hidden;

  /* ✅ Fondo igual al dashboard (radiales + gradiente) */
  background:
    radial-gradient(1200px 640px at 18% 0%, rgba(255,255,255,.06), transparent),
    radial-gradient(900px 520px at 82% 12%, rgba(255,255,255,.04), transparent),
    linear-gradient(180deg, var(--bg0), var(--bg1));
}

.auth-noise{
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .08;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
}

.auth-shell{
  min-height:100%;
  display:grid;
  place-items:center;
  padding: 26px 16px;
}

.auth-frame{
  width: min(980px, 96vw);
  border-radius: var(--radius2);
  border: 1px solid rgba(255,255,255,.08);

  /* ✅ Card glass como dashboard */
  background: var(--panel);
  backdrop-filter: blur(26px);
  -webkit-backdrop-filter: blur(26px);

  box-shadow: var(--shadow);
  overflow:hidden;
  display:grid;
  grid-template-columns: 1.05fr .95fr;
  min-height: 560px;
  transform: translateY(14px);
  opacity: 0;
  animation: authIn .65s cubic-bezier(.2,.85,.2,1) forwards;
}

@keyframes authIn{
  to{ transform: translateY(0); opacity: 1; }
}

@media (max-width: 900px){
  .auth-frame{
    grid-template-columns: 1fr;
    min-height: unset;
  }
}

/* =========================
   IZQUIERDA (BRAND)
   ========================= */
.brand{
  position: relative;
  padding: 26px 26px 22px;
  border-right: 1px solid rgba(255,255,255,.08);
  overflow: hidden;

  /* ✅ glass + radiales suaves como dashboard */
  background:
    radial-gradient(1200px 640px at 18% 0%, rgba(255,255,255,.06), transparent),
    radial-gradient(900px 520px at 82% 12%, rgba(255,255,255,.04), transparent),
    rgba(18,18,20,.24);
}

@media (max-width: 900px){
  .brand{ border-right:0; border-bottom: 1px solid rgba(255,255,255,.08); }
}

/* Overlay SOLO para el fondo */
.brand::before{
  content:"";
  position:absolute;
  inset:0;
  /* ✅ oscurecido igual al dashboard */
  background: linear-gradient(
    180deg,
    rgba(10,11,14,.78) 0%,
    rgba(11,12,15,.88) 55%,
    rgba(11,12,15,.94) 100%
  );
  pointer-events:none;
  z-index: 0;
}

/* contenido arriba */
.brand > *{
  position: relative;
  z-index: 1;
}

.brand-stack{
  height: 100%;
  min-height: 560px;
  display:flex;
  flex-direction: column;
}

/* LOGO */
.brand-hero{
  padding-top: -50px;
  display:flex;
  justify-content:center;
  align-items:flex-start;
}

.brand-hero img{
  width: min(300px, 88%);
  max-width: 300px;
  height: auto;
  display:block;

  filter: none !important;
  transform: none !important;

  filter: drop-shadow(0 28px 70px rgba(0,0,0,.55));
}

/* TEXTO ABAJO */
.brand-copy{
  margin-top: auto;
  padding-top: 18px;
  transform: translateY(-100px);
}

.brand-copy h1{
  margin: 0;
  font-size: 30px;
  letter-spacing: -0.02em;
  line-height: 1.08;
}

.brand-copy p{
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.4;
  max-width: 55ch;
}

.brand-badges{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top: 18px;
}

.badge{
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.05);
  color: var(--muted2);
  font-size: 12px;
  font-weight: 700;
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}

/* =========================
   DERECHA (FORM)
   ========================= */
.formpane{
  padding: 26px;
  background: rgba(18,18,20,.26);

  display: flex;
  flex-direction: column;
  justify-content: center;
}

.formhead{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:10px;
  margin-bottom: 14px;
}

.formhead h2{
  margin:0;
  font-size: 18px;
  letter-spacing: .2px;
}

.formhead .small{
  color: var(--muted);
  font-size: 12px;
}

/* alerta (manteniendo tu estructura) */
.auth-alert{
  margin: 10px 0 14px;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(239,68,68,.35);
  background: rgba(239,68,68,.12);
  color: rgba(254,226,226,.95);
  font-size: 13px;
}

.auth-form{
  display:flex;
  flex-direction:column;
  gap: 12px;
}

.field label{
  display:block;
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 7px;
}

.control{
  display:flex;
  align-items:center;
  gap:10px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.06);
  padding: 0 10px;
  transition: box-shadow .2s ease, border-color .2s ease, background .15s ease;
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}

.control:hover{
  background: var(--hover2);
  border-color: rgba(255,255,255,.18);
}

.control:focus-within{
  border-color: rgba(255,255,255,.22);
  box-shadow: var(--ring);
}

.control input{
  width:100%;
  border:0;
  outline:none;
  background: transparent;
  padding: 14px 6px;
  color: var(--text);
  font-size: 14px;
}

.iconbtn{
  border:0;
  background: transparent;
  cursor:pointer;
  padding: 8px;
  border-radius: 12px;
  opacity: .72;
  transition: background .15s ease, opacity .15s ease, transform .15s ease;
  display:grid;
  place-items:center;
}
.iconbtn:hover{
  background: rgba(255,255,255,.08);
  opacity: .95;
  transform: translateY(-1px);
}
.iconbtn svg{ width:18px; height:18px; fill: rgba(245,245,247,.85); }

.hint{
  margin-top: 6px;
  color: rgba(245,245,247,.55);
  font-size: 12px;
}

.actions{
  margin-top: 6px;
  display:flex;
  gap: 10px;
  flex-wrap:wrap;
}

.btn{
  border: 1px solid var(--border);
  cursor:pointer;
  border-radius: 16px;
  padding: 13px 14px;
  font-weight: 800;
  font-size: 14px;
  color: var(--text);
  background: rgba(255,255,255,.06);
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}
.btn:hover{
  background: rgba(255,255,255,.10);
  border-color: rgba(255,255,255,.18);
  transform: translateY(-1px);
}
.btn:active{ transform: translateY(0); }

.btn-primary{
  flex: 1;
  min-width: 180px;

  /* ✅ estilo botón del dashboard (glass + contraste) */
  background: rgba(255,255,255,.12);
  border-color: rgba(255,255,255,.22);
  color: var(--text);

  box-shadow: var(--shadow2);
}
.btn-primary:hover{
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.28);
}

.btn-ghost{
  color: rgba(245,245,247,.88);
  background: rgba(255,255,255,.06);
  border: 1px solid var(--border);
}

.footer{
  margin-top: 14px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  flex-wrap:wrap;
}

.link{
  color: rgba(245,245,247,.88);
  text-decoration:none;
  font-weight: 700;
  opacity: .9;
}
.link:hover{ opacity: 1; text-decoration: underline; }

.link-accent{
  color: rgba(245,245,247,.92);
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,.22);
}

.hidden{ display:none; }