/* ==========================================================================
   Login page
   ========================================================================== */

.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
}

/* ------------------------------------------------------------- left panel */

.auth-hero {
  position: relative;
  overflow: hidden;
  padding: 56px 56px 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(1000px 600px at 12% 8%, rgba(124, 124, 248, 0.32), transparent 62%),
    radial-gradient(760px 520px at 88% 92%, rgba(56, 189, 248, 0.24), transparent 60%),
    linear-gradient(150deg, #131a34 0%, #0d1226 100%);
  background-color: #101736;
  color: #eef2ff;
}

html[data-theme="light"] .auth-hero {
  background:
    radial-gradient(900px 560px at 10% 6%, rgba(99, 102, 241, 0.22), transparent 60%),
    radial-gradient(700px 480px at 92% 94%, rgba(14, 165, 233, 0.18), transparent 58%),
    linear-gradient(150deg, #ffffff 0%, #eef2ff 100%);
  color: var(--text);
}

.auth-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 40%, #000 20%, transparent 78%);
  pointer-events: none;
}
html[data-theme="light"] .auth-hero::after {
  background-image: linear-gradient(rgba(15, 23, 42, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, 0.05) 1px, transparent 1px);
}

.auth-hero > * { position: relative; z-index: 1; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: 17px;
}
/*
 * Petak lambang di panel masuk: sedikit lebih besar daripada di sidebar.
 * Rupa petaknya (navy gelap + lambang) datang dari `.brand-mark` di base.css.
 */
.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  padding: 6px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.09), 0 8px 20px rgba(6, 11, 22, 0.35);
}

.auth-hero-body { max-width: 480px; }
.auth-hero-body h1 {
  font-size: clamp(30px, 3.4vw, 44px);
  line-height: 1.1;
  margin-bottom: 16px;
}
.auth-hero-body h1 em {
  font-style: normal;
  background: linear-gradient(100deg, #818cf8, #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
html[data-theme="light"] .auth-hero-body h1 em { background: linear-gradient(100deg, #4f46e5, #0891b2); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.auth-hero-body p { font-size: 15.5px; line-height: 1.7; opacity: 0.82; }

.hero-features { display: flex; flex-direction: column; gap: 12px; margin-top: 30px; }
.hero-feature { display: flex; gap: 12px; align-items: flex-start; font-size: 14.5px; opacity: 0.9; }
.hero-feature .dot {
  flex: 0 0 auto;
  width: 22px; height: 22px;
  border-radius: 7px;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.12);
  font-size: 12px;
}
html[data-theme="light"] .hero-feature .dot { background: var(--accent-soft); color: var(--accent); }

.auth-hero-foot { font-size: 12.5px; opacity: 0.62; }

/* ------------------------------------------------------------ right panel */

.auth-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
  background: var(--bg);
  position: relative;
}

.auth-theme { position: absolute; top: 22px; right: 26px; }

.auth-card {
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  animation: auth-in 0.5s var(--ease) both;
}
@keyframes auth-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.auth-title h2 { font-size: 27px; margin-bottom: 8px; }
.auth-title p { color: var(--text-muted); font-size: 14.5px; }

.auth-form { display: flex; flex-direction: column; gap: 16px; }

.input-wrap { position: relative; display: flex; align-items: center; }
.input-wrap .input { padding-left: 42px; padding-right: 44px; }
.input-wrap .lead {
  position: absolute;
  left: 13px;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  pointer-events: none;
}
.input-wrap .trail {
  position: absolute;
  right: 8px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  padding: 6px 8px;
  border-radius: 6px;
  display: grid;
  place-items: center;
}
.input-wrap .trail:hover { color: var(--text); background: var(--surface-3); }

.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 13.5px; }
.checkbox { display: inline-flex; align-items: center; gap: 8px; color: var(--text-soft); cursor: pointer; user-select: none; }
.checkbox input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }

.form-alert {
  display: none;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  background: var(--danger-soft);
  color: var(--danger);
  border: 1px solid transparent;
  line-height: 1.5;
}
.form-alert.show { display: flex; animation: shake 0.35s var(--ease); }
.form-alert.ok { background: var(--success-soft); color: var(--success); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.btn-spinner {
  width: 16px; height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.auth-demo {
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  padding: 13px 14px;
  background: var(--surface-2);
  font-size: 12.5px;
  color: var(--text-soft);
  line-height: 1.7;
}
.auth-demo strong { color: var(--text); }
.auth-demo code {
  font-family: var(--font-mono);
  font-size: 12px;
  background: var(--surface-3);
  padding: 1px 6px;
  border-radius: 5px;
  border: 1px solid var(--border);
}
.auth-demo .fill {
  cursor: pointer;
  border: 0;
  background: none;
  padding: 0;
  color: var(--accent);
  font: inherit;
  text-decoration: underline;
  text-decoration-style: dotted;
}

.auth-foot { text-align: center; font-size: 12.5px; color: var(--text-muted); }

@media (max-width: 960px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-hero { padding: 36px 28px; gap: 28px; }
  .hero-features { display: none; }
  .auth-hero-foot { display: none; }
  .auth-panel { padding: 46px 22px 40px; }
  .auth-theme { top: 16px; right: 18px; }
}
