/* Vibe BPO · Pantalla de ingreso */
:root {
  --bg: #F6F5FB; --surface: #FFFFFF; --surface-2: #F0EEF8; --ink: #1A1530; --text: #2B2740; --muted: #6B6780;
  --line: #E1DCEE; --primary: #6D3CF0; --primary-ink: #FFFFFF; --accent: #FF6A4D; --danger: #D93A3A;
  --hero-a: #2A1A63; --hero-b: #6D3CF0; --hero-c: #FF6A4D;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #0E0B1A; --surface: #17132A; --surface-2: #201B38; --ink: #F1EFFA; --text: #DCD8EC; --muted: #9C97B4;
    --line: #2F2950; --primary: #9C7DFF; --primary-ink: #120E22; --accent: #FF8A70; --danger: #FF7A7A;
    --hero-a: #140E2E; --hero-b: #3B2391; --hero-c: #B8432E; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0E0B1A; --surface: #17132A; --surface-2: #201B38; --ink: #F1EFFA; --text: #DCD8EC; --muted: #9C97B4;
  --line: #2F2950; --primary: #9C7DFF; --primary-ink: #120E22; --accent: #FF8A70; --danger: #FF7A7A;
  --hero-a: #140E2E; --hero-b: #3B2391; --hero-c: #B8432E; color-scheme: dark;
}

:root[data-theme="grafito"] {
  --bg: #131210; --surface: #1C1B18; --surface-2: #26241F; --ink: #F3EFE7; --text: #DCD6CA; --muted: #A29B8E;
  --line: #3A362E; --primary: #F2A65A; --primary-ink: #1A1610; --accent: #FF8A65; --danger: #FF7A7A;
  --hero-a: #181613; --hero-b: #2C2822; --hero-c: #8E5230; color-scheme: dark;
}
:root[data-theme="grafito"] .go { background: linear-gradient(100deg, #E8913F, #F2A65A 55%, #FF8A65); color: #1A1610; box-shadow: 0 10px 24px -8px rgba(242,166,90,.45); }

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.55 "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--primary) 50%, transparent); outline-offset: 2px; }

.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }

/* ---------- panel de marca */
.brand-panel { position: relative; overflow: hidden; color: #fff; padding: 44px 56px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px;
  background:
    radial-gradient(800px 420px at 100% 0%, color-mix(in srgb, var(--hero-c) 75%, transparent), transparent 60%),
    radial-gradient(700px 500px at 0% 100%, color-mix(in srgb, var(--hero-b) 95%, transparent), transparent 60%),
    linear-gradient(155deg, var(--hero-a), color-mix(in srgb, var(--hero-b) 70%, var(--hero-a))); }
.bp-top { display: flex; align-items: center; gap: 12px; position: relative; z-index: 1; }
.bp-top img { border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.wordmark { font-size: 24px; letter-spacing: -.02em; font-weight: 500; }
.wordmark b { font-weight: 800; }
.bp-copy { position: relative; z-index: 1; max-width: 520px; }
.eyebrow { display: inline-block; margin: 0 0 14px; padding: 5px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22); }
.bp-copy h1 { margin: 0 0 14px; font-size: clamp(32px, 3.6vw, 48px); line-height: 1.08; letter-spacing: -.035em; font-weight: 800; }
.bp-copy p { margin: 0; font-size: 16.5px; opacity: .85; max-width: 440px; }
.bp-feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; position: relative; z-index: 1; }
.bp-feats li { display: flex; align-items: center; gap: 12px; font-size: 14.5px; font-weight: 500; opacity: .92; }
.bp-feats span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.18); font-size: 15px; }
.orb { position: absolute; border-radius: 50%; filter: blur(2px); pointer-events: none; }
.o1 { width: 340px; height: 340px; right: -90px; bottom: 90px; border: 1.5px solid rgba(255,255,255,.14); }
.o2 { width: 200px; height: 200px; right: 30px; bottom: 160px; border: 1.5px solid rgba(255,255,255,.10); }

/* ---------- formulario */
.form-panel { display: grid; place-items: center; padding: 40px 24px; }
.card { width: 100%; max-width: 400px; }
.mobile-brand { display: none; }
.card h2 { margin: 0 0 6px; font-size: 28px; letter-spacing: -.025em; color: var(--ink); font-weight: 800; }
.sub { margin: 0 0 30px; color: var(--muted); }
.lbl { display: block; font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 8px; }
.field { display: flex; align-items: center; gap: 10px; height: 54px; padding: 0 8px 0 14px; border-radius: 12px; background: var(--surface);
  border: 1.5px solid var(--line); transition: border-color .15s, box-shadow .15s; }
.field:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 16%, transparent); }
.field > svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.field input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); font: inherit; font-size: 16px; letter-spacing: .02em; }
.field input::placeholder { color: var(--muted); opacity: .6; }
.eye { width: 38px; height: 38px; border: 0; background: transparent; border-radius: 9px; cursor: pointer; display: grid; place-items: center; color: var(--muted); }
.eye:hover { background: var(--surface-2); color: var(--ink); }
.eye svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; }
.eye[aria-pressed="true"] { color: var(--primary); }
.caps { margin: 8px 0 0; font-size: 12.5px; color: var(--accent); font-weight: 600; }

.check { display: flex; align-items: center; gap: 10px; margin: 18px 0 0; font-size: 13.5px; color: var(--text); cursor: pointer; user-select: none; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check span { width: 20px; height: 20px; flex: none; border-radius: 6px; border: 1.5px solid var(--line); background: var(--surface); display: grid; place-items: center; transition: .15s; }
.check input:checked + span { background: var(--primary); border-color: var(--primary); }
.check input:checked + span::after { content: ""; width: 5px; height: 10px; border: solid var(--primary-ink); border-width: 0 2.5px 2.5px 0; transform: translateY(-1px) rotate(45deg); }
.check input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--primary) 50%, transparent); outline-offset: 2px; }

.err { margin: 18px 0 0; padding: 10px 12px; border-radius: 10px; font-size: 13.5px; font-weight: 600; color: var(--danger);
  background: color-mix(in srgb, var(--danger) 10%, transparent); border: 1px solid color-mix(in srgb, var(--danger) 30%, transparent); }
.bad .field { border-color: var(--danger); }
.bad .field { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

.go { margin-top: 24px; width: 100%; height: 52px; border: 0; border-radius: 12px; cursor: pointer; font: inherit; font-size: 15.5px; font-weight: 700;
  color: #fff; background: linear-gradient(100deg, #6D3CF0, #8B4FE8 55%, #FF6A4D); background-size: 160% 100%; background-position: 0 0;
  box-shadow: 0 10px 24px -8px rgba(109, 60, 240, .6); display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: background-position .4s ease, transform .1s, box-shadow .2s; }
.go:hover { background-position: 100% 0; box-shadow: 0 12px 28px -8px rgba(255, 106, 77, .55); }
.go:active { transform: translateY(1px); }
.go:disabled { cursor: progress; opacity: .85; }
.spin { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; animation: spin .7s linear infinite; }
.busy .spin { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
.foot { margin: 34px 0 0; text-align: center; font-size: 12px; color: var(--muted); }

@media (max-width: 900px) {
  .login { grid-template-columns: 1fr; }
  .brand-panel { display: none; }
  .form-panel { align-items: start; padding-top: 0; padding-left: 0; padding-right: 0; }
  .card { max-width: none; }
  .mobile-brand { display: flex; align-items: center; gap: 10px; color: #fff; margin: 0 0 28px; padding: 36px 16px 46px;
    background:
      radial-gradient(500px 260px at 100% 0%, color-mix(in srgb, var(--hero-c) 70%, transparent), transparent 60%),
      linear-gradient(155deg, var(--hero-a), color-mix(in srgb, var(--hero-b) 75%, var(--hero-a)));
    border-radius: 0 0 28px 28px; }
  .mobile-brand img { border-radius: 11px; }
  .card > :not(.mobile-brand) { margin-left: 16px; margin-right: 16px; }
  .card .go { width: calc(100% - 32px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
