/* ══════════════════════════════════════════
   TOKENS — idénticos al dashboard
══════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --g0: #fdf8ee;
  --g1: #f5e9c4;
  --g2: #e8cc82;
  --g3: #c6a344;
  --g4: #a8872e;
  --g5: #7a6120;
  --g6: #4e3d10;

  --s-bg:  #0d1017;
  --s-bg2: #131820;
  --s-bg3: #1a2232;
  --s-fg:  #7e8fa8;
  --s-fg2: #a8b8cc;
  --s-line: rgba(255,255,255,.055);

  --bg:      #eeeae1;
  --surface: #ffffff;

  --tx1: #14120a;
  --tx2: #4a4235;
  --tx3: #8a7f6e;

  --bd:  rgba(198,163,68,.18);
  --bd2: rgba(198,163,68,.32);

  --red:    #a33030;
  --red-bg: #fbeaea;
  --green:  #2d7d46;

  --r1: 8px;
  --r2: 14px;
  --r3: 20px;
  --r4: 28px;

  --sh1: 0 2px 8px  rgba(0,0,0,.07);
  --sh2: 0 8px 32px rgba(0,0,0,.12);
  --sh3: 0 20px 60px rgba(0,0,0,.18);
  --shg: 0 8px 28px rgba(198,163,68,.30);

  --ease: cubic-bezier(.4,0,.2,1);
  --spring: cubic-bezier(.34,1.56,.64,1);
}

html, body {
  font-family: 'Ubuntu', sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  /* overflow: hidden; */
}

/* ══════════════════════════════════════════
   FULL-SCREEN SPLIT LAYOUT
══════════════════════════════════════════ */
.login-root {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

/* ══════════════════════════════════════════
   LEFT PANEL — dark hero (same as sidebar)
══════════════════════════════════════════ */
.hero {
  flex: 0 0 48%;
  background: var(--s-bg);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 44px 48px;
}

/* Animated shimmer line top */
.hero::before {
  content: '';
  position: absolute;
  top: 0; left: -200%; right: 0;
  height: 2px;
  background: linear-gradient(90deg,
    transparent,
    var(--g3) 30%, var(--g2) 50%, var(--g3) 70%,
    transparent);
  animation: shimmer 3s ease-in-out infinite;
  z-index: 5;
}
@keyframes shimmer {
  0%   { left: -200%; }
  100% { left: 200%; }
}

/* Radial ambient glow */
.hero-glow {
  position: absolute;
  top: -120px; left: -120px;
  width: 480px; height: 480px;
  background: radial-gradient(circle, rgba(198,163,68,.12) 0%, transparent 68%);
  border-radius: 50%;
  pointer-events: none;
  animation: pulse-glow 5s ease-in-out infinite;
}
.hero-glow2 {
  position: absolute;
  bottom: -100px; right: -80px;
  width: 360px; height: 360px;
  background: radial-gradient(circle, rgba(198,163,68,.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  animation: pulse-glow 5s ease-in-out 2.5s infinite;
}
@keyframes pulse-glow {
  0%, 100% { opacity: .6; transform: scale(1); }
  50%       { opacity: 1;  transform: scale(1.12); }
}

/* Decorative grid pattern */
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(198,163,68,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(198,163,68,.05) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

/* Floating orbs */
.orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  animation: float linear infinite;
}
.orb1 { width: 6px;  height: 6px;  background: var(--g3); opacity: .45; top: 22%; left: 18%; animation-duration: 8s;  animation-delay: 0s; }
.orb2 { width: 4px;  height: 4px;  background: var(--g2); opacity: .35; top: 55%; left: 72%; animation-duration: 11s; animation-delay: 2s; }
.orb3 { width: 8px;  height: 8px;  background: var(--g4); opacity: .25; top: 78%; left: 30%; animation-duration: 9s;  animation-delay: 1s; }
.orb4 { width: 5px;  height: 5px;  background: var(--g2); opacity: .40; top: 35%; left: 60%; animation-duration: 13s; animation-delay: 3s; }
.orb5 { width: 3px;  height: 3px;  background: var(--g3); opacity: .50; top: 65%; left: 15%; animation-duration: 7s;  animation-delay: .5s; }

@keyframes float {
  0%   { transform: translateY(0)   rotate(0deg); }
  33%  { transform: translateY(-18px) rotate(120deg); }
  66%  { transform: translateY(10px)  rotate(240deg); }
  100% { transform: translateY(0)   rotate(360deg); }
}

/* Hero top — brand */
.hero-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  position: relative;
  z-index: 2;
  opacity: 0;
  transform: translateY(-16px);
  animation: slide-down .7s var(--ease) .1s forwards;
}
@keyframes slide-down {
  to { opacity: 1; transform: translateY(0); }
}

.hero-logo {
  width: 48px; height: 48px;
  border-radius: var(--r2);
  background: linear-gradient(145deg, var(--g3) 0%, var(--g2) 60%, var(--g4) 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: var(--s-bg);
  box-shadow: var(--shg), inset 0 1px 0 rgba(255,255,255,.28);
  transition: transform .3s var(--spring);
}
.hero-logo:hover { transform: rotate(-8deg) scale(1.1); }

.hero-brand-name { font-size: 22px; font-weight: 700; color: #fff; letter-spacing: -.3px; }
.hero-brand-sub  { font-size: 10px; font-weight: 500; color: var(--g3); text-transform: uppercase; letter-spacing: 2px; }

/* Hero center — headline */
.hero-center {
  position: relative;
  z-index: 2;
  opacity: 0;
  transform: translateY(20px);
  animation: slide-up .8s var(--ease) .3s forwards;
}
@keyframes slide-up {
  to { opacity: 1; transform: translateY(0); }
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(198,163,68,.12);
  border: 1px solid rgba(198,163,68,.22);
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 11px;
  font-weight: 500;
  color: var(--g2);
  text-transform: uppercase;
  letter-spacing: 1.4px;
  margin-bottom: 20px;
}
.hero-eyebrow .fa { font-size: 10px; }

.hero-h1 {
  font-size: 38px;
  font-weight: 700;
  color: #fff;
  line-height: 1.15;
  letter-spacing: -.5px;
  margin-bottom: 16px;
}

.hero-h1 .gold-word {
  background: linear-gradient(135deg, var(--g2), var(--g3));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-desc {
  font-size: 15px;
  font-weight: 300;
  color: var(--s-fg2);
  line-height: 1.7;
  max-width: 360px;
  margin-bottom: 36px;
}

/* Feature chips */
.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.09);
  border-radius: var(--r2);
  padding: 8px 14px;
  font-size: 12.5px;
  color: var(--s-fg2);
  transition: background .2s, border-color .2s;
}
.chip:hover { background: rgba(198,163,68,.1); border-color: rgba(198,163,68,.25); color: var(--g1); }
.chip .fa { font-size: 12px; color: var(--g3); }

/* Hero bottom — testimonial */
.hero-testimonial {
  position: relative;
  z-index: 2;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: var(--r3);
  padding: 18px 20px;
  opacity: 0;
  transform: translateY(16px);
  animation: slide-up .8s var(--ease) .55s forwards;
}

.testi-stars { color: var(--g3); font-size: 12px; margin-bottom: 8px; letter-spacing: 2px; }
.testi-quote {
  font-size: 13.5px;
  font-weight: 300;
  color: var(--s-fg2);
  line-height: 1.6;
  margin-bottom: 14px;
  font-style: italic;
}
.testi-author {
  display: flex;
  align-items: center;
  gap: 10px;
}
.testi-avatar {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--g3), var(--g2));
  color: var(--s-bg);
  font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid rgba(198,163,68,.35);
}
.testi-name { font-size: 13px; font-weight: 500; color: #fff; line-height: 1.1; }
.testi-role { font-size: 11px; color: var(--s-fg); }

/* ══════════════════════════════════════════
   RIGHT PANEL — login form
══════════════════════════════════════════ */
.form-panel {
  flex: 1;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  position: relative;
  overflow: hidden;
}

/* Subtle warm texture */
.form-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 80% 10%, rgba(198,163,68,.07) 0%, transparent 55%),
    radial-gradient(ellipse at 20% 90%, rgba(198,163,68,.05) 0%, transparent 50%);
  pointer-events: none;
}

.form-box {
  width: 100%;
  max-width: 420px;
  position: relative;
  z-index: 1;
  opacity: 0;
  transform: translateX(28px);
  animation: slide-in .75s var(--ease) .4s forwards;
}
@keyframes slide-in {
  to { opacity: 1; transform: translateX(0); }
}

/* Welcome heading */
.form-welcome {
  margin-bottom: 32px;
}

.form-welcome h2 {
  font-size: 26px;
  font-weight: 700;
  color: var(--tx1);
  letter-spacing: -.3px;
  margin-bottom: 5px;
  line-height: 1.2;
}

.form-welcome p {
  font-size: 14px;
  color: var(--tx3);
  font-weight: 300;
}

/* Card wrapper */
.form-card {
  background: var(--surface);
  border-radius: var(--r3);
  border: 1.5px solid var(--bd);
  padding: 32px 30px;
  box-shadow: var(--sh2);
  position: relative;
  overflow: hidden;
}

/* Gold top accent line */
.form-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--g5), var(--g3), var(--g2), var(--g3));
}

/* Social login buttons */
.social-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 24px;
}

.social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--surface);
  border: 1.5px solid var(--bd2);
  border-radius: var(--r2);
  padding: 10px 14px;
  font-family: 'Ubuntu', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--tx2);
  cursor: pointer;
  transition: background .2s, border-color .2s, box-shadow .2s, transform .18s var(--ease);
  text-decoration: none;
}
.social-btn:hover {
  background: var(--g0);
  border-color: var(--g3);
  box-shadow: var(--shg);
  transform: translateY(-1px);
  text-decoration: none;
  color: var(--tx1);
}
.social-btn .fa { font-size: 15px; }
.social-btn .fa-google { color: #db4437; }
.social-btn .fa-microsoft { color: #00a4ef; }

/* Divider */
.or-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}
.or-line { flex: 1; height: 1px; background: var(--bd); }
.or-text  { font-size: 12px; color: var(--tx3); font-weight: 400; white-space: nowrap; }

/* Form fields */
.field { margin-bottom: 18px; }

.field label {
  display: block;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--tx2);
  margin-bottom: 7px;
  letter-spacing: .2px;
}

.input-wrap {
  position: relative;
}

.input-wrap .fa {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--tx3);
  pointer-events: none;
  transition: color .2s;
  z-index: 2;
}

.field-input {
  width: 100%;
  height: 46px;
  background: var(--bg);
  border: 1.5px solid var(--bd2);
  border-radius: var(--r2);
  padding: 0 44px 0 42px;
  font-family: 'Ubuntu', sans-serif;
  font-size: 14px;
  color: var(--tx1);
  outline: none;
  transition: border-color .22s, box-shadow .22s, background .22s;
  -webkit-appearance: none;
}
.field-input::placeholder { color: var(--tx3); font-weight: 300; }

.field-input:focus {
  border-color: var(--g3);
  background: var(--surface);
  box-shadow: 0 0 0 4px rgba(198,163,68,.13);
}
.field-input:focus + .fa,
.input-wrap:focus-within .fa {
  color: var(--g4);
}

/* Floating label animation */
.input-wrap .fa { transition: color .2s; }

/* Password toggle */
.pwd-toggle {
  position: absolute;
  right: 13px;
  top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  color: var(--tx3); font-size: 14px;
  cursor: pointer; padding: 4px;
  border-radius: var(--r1);
  transition: color .2s;
  z-index: 2;
}
.pwd-toggle:hover { color: var(--g4); }

/* Field meta row */
.field-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}
.field-meta label { margin: 0; }
.field-forgot {
  font-size: 12px;
  color: var(--g4);
  font-weight: 500;
  text-decoration: none;
  transition: color .2s;
}
.field-forgot:hover { color: var(--g5); text-decoration: underline; }

/* Remember me */
.remember-row {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 24px;
}

.custom-cb {
  width: 18px; height: 18px;
  border-radius: 5px;
  border: 1.5px solid var(--bd2);
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s, border-color .2s;
  position: relative;
}
.custom-cb input { position: absolute; opacity: 0; width: 0; height: 0; }
.custom-cb.checked { background: var(--g3); border-color: var(--g3); }
.custom-cb .fa-check { font-size: 10px; color: #fff; display: none; }
.custom-cb.checked .fa-check { display: block; }
.remember-label { font-size: 13px; color: var(--tx2); cursor: pointer; user-select: none; }

/* Submit button */
.btn-submit {
  width: 100%;
  height: 48px;
  background: var(--g3);
  color: #fff;
  border: none;
  border-radius: var(--r2);
  font-family: 'Ubuntu', sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 9px;
  box-shadow: 0 4px 18px rgba(198,163,68,.40);
  transition: background .2s, box-shadow .2s, transform .18s var(--ease);
  position: relative;
  overflow: hidden;
  letter-spacing: .2px;
}

/* Ripple shimmer on button */
.btn-submit::after {
  content: '';
  position: absolute;
  top: 0; left: -100%; bottom: 0;
  width: 60%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.18), transparent);
  transition: left .5s;
}
.btn-submit:hover::after { left: 160%; }

.btn-submit:hover {
  background: var(--g4);
  box-shadow: var(--shg);
  transform: translateY(-1px);
}
.btn-submit:active { transform: translateY(0); box-shadow: none; }

/* Loading state */
.btn-submit .spinner {
  display: none;
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.btn-submit.loading .btn-label { display: none; }
.btn-submit.loading .spinner    { display: block; }

/* Error message */
.field-error {
  display: none;
  align-items: center;
  gap: 6px;
  background: var(--red-bg);
  border: 1px solid rgba(163,48,48,.2);
  border-radius: var(--r1);
  padding: 10px 14px;
  font-size: 12.5px;
  color: var(--red);
  margin-top: 4px;
  animation: shake .4s var(--ease);
}
.field-error.show { display: flex; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%       { transform: translateX(-6px); }
  40%       { transform: translateX(6px); }
  60%       { transform: translateX(-4px); }
  80%       { transform: translateX(4px); }
}

/* Success overlay */
.success-overlay {
  position: absolute; inset: 0;
  background: var(--surface);
  border-radius: var(--r3);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s;
  z-index: 10;
}
.success-overlay.show { opacity: 1; pointer-events: all; }

.success-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--green-bg, #e8f5ed);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  color: var(--green);
  animation: pop-in .5s var(--spring);
}
@keyframes pop-in {
  from { transform: scale(.5); opacity: 0; }
  to   { transform: scale(1);  opacity: 1; }
}
.success-title { font-size: 18px; font-weight: 700; color: var(--tx1); }
.success-sub   { font-size: 13px; color: var(--tx3); font-weight: 300; }

/* Sign up row */
.signup-row {
  text-align: center;
  margin-top: 22px;
  font-size: 13px;
  color: var(--tx3);
}
.signup-row a {
  color: var(--g4);
  font-weight: 500;
  text-decoration: none;
  transition: color .2s;
}
.signup-row a:hover { color: var(--g5); text-decoration: underline; }

/* Password strength */
.pwd-strength {
  margin-top: 8px;
  display: none;
}
.pwd-strength.show { display: block; }
.pwd-strength-bars {
  display: flex; gap: 4px; margin-bottom: 5px;
}
.psb {
  flex: 1; height: 4px; border-radius: 4px;
  background: var(--g1);
  transition: background .3s;
}
.psb.weak   { background: var(--red); }
.psb.medium { background: var(--g3); }
.psb.strong { background: var(--green); }
.pwd-strength-label { font-size: 11px; color: var(--tx3); }

/* ══════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════ */
@media (max-width: 900px) {
  .hero { display: none; }
  .form-panel { background: var(--s-bg); }
  .form-panel::before {
    background:
      radial-gradient(ellipse at 50% 0%, rgba(198,163,68,.1) 0%, transparent 60%);
  }
  .form-box { max-width: 400px; }
  .form-welcome h2 { color: #fff; }
  .form-welcome p  { color: var(--s-fg2); }
  .form-card {
    background: var(--s-bg2);
    border-color: rgba(255,255,255,.08);
    box-shadow: 0 20px 60px rgba(0,0,0,.4);
  }
  .field-input {
    background: var(--s-bg3);
    border-color: rgba(255,255,255,.12);
    color: #fff;
  }
  .field-input::placeholder { color: var(--s-fg); }
  .field-input:focus { border-color: var(--g3); background: rgba(255,255,255,.05); }
  .field label { color: var(--s-fg2); }
  .or-line  { background: rgba(255,255,255,.08); }
  .or-text  { color: var(--s-fg); }
  .social-btn {
    background: var(--s-bg3);
    border-color: rgba(255,255,255,.1);
    color: var(--s-fg2);
  }
  .social-btn:hover { background: rgba(198,163,68,.1); border-color: rgba(198,163,68,.3); color: #fff; }
  .remember-label { color: var(--s-fg2); }
  .custom-cb { background: var(--s-bg3); border-color: rgba(255,255,255,.15); }
  .signup-row { color: var(--s-fg); }
  .success-overlay { background: var(--s-bg2); }
  .success-title { color: #fff; }
}

@media (max-width: 480px) {
  .form-card { padding: 24px 20px; }
  .social-row { grid-template-columns: 1fr; }
  .form-box { animation-delay: .15s; }
}