/**
 * nunu auth split layout — login / register
 * Brand panel left, form card right. Minimalist nunu palette.
 */

html.nunu-auth-split.nunu-auth-page {
  --nunu-auth-bg: #fbf9f9;
  --nunu-auth-panel: #f6f3f2;
  --nunu-auth-card: #ffffff;
  --nunu-auth-muted: #6b7280;
  --nunu-auth-border: #e8e4e2;
  --nunu-auth-accent: #d85a04;
}

html.nunu-auth-split.nunu-auth-page,
html.nunu-auth-split.nunu-auth-page body,
html.nunu-auth-split.nunu-auth-page #root {
  background: var(--nunu-auth-bg) !important;
  min-height: 100vh;
}

/* Hide default top logo strip — brand lives in left panel */
html.nunu-auth-split.nunu-auth-page .animate-logo-blink,
html.nunu-auth-split.nunu-auth-page .mt-6.h-10.w-full.bg-cover {
  display: none !important;
}

/* Shell → horizontal split */
html.nunu-auth-split.nunu-auth-page .relative.flex.min-h-screen.flex-col.bg-surface-primary {
  flex-direction: row !important;
  align-items: stretch !important;
  min-height: 100vh !important;
  background: var(--nunu-auth-bg) !important;
}

/* Injected brand panel */
html.nunu-auth-split .nunu-auth-split-brand {
  display: none;
}

html.nunu-auth-split.nunu-auth-page .nunu-auth-split-brand {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  flex: 1 1 50%;
  max-width: 52%;
  padding: 3rem clamp(2rem, 5vw, 4rem);
  background:
    radial-gradient(circle at 20% 20%, rgba(216, 90, 4, 0.06), transparent 42%),
    radial-gradient(circle at 80% 70%, rgba(216, 90, 4, 0.04), transparent 38%),
    var(--nunu-auth-panel);
  border-right: 1px solid var(--nunu-auth-border);
  position: relative;
  overflow: hidden;
}

html.nunu-auth-split.nunu-auth-page .nunu-auth-split-brand::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(107, 114, 128, 0.14) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.35;
  pointer-events: none;
}

html.nunu-auth-split .nunu-auth-split-brand-inner {
  position: relative;
  z-index: 1;
  max-width: 28rem;
}

html.nunu-auth-split .nunu-auth-split-logo {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #111827;
  margin: 0 0 0.75rem;
  line-height: 1.1;
}

html.nunu-auth-split .nunu-auth-split-tagline {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.45;
  color: #374151;
  margin: 0;
  font-weight: 500;
}

html.nunu-auth-split .nunu-auth-split-foot {
  position: absolute;
  bottom: 3rem;
  left: clamp(2rem, 5vw, 4rem);
  z-index: 1;
  font-size: 0.8125rem;
  color: var(--nunu-auth-muted);
}

html.nunu-auth-split .nunu-auth-split-foot a {
  color: var(--nunu-auth-accent);
  text-decoration: none;
}

html.nunu-auth-split .nunu-auth-split-foot a:hover {
  text-decoration: underline;
}

/* Right column — form */
html.nunu-auth-split.nunu-auth-page main {
  flex: 1 1 50% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 2rem clamp(1rem, 4vw, 2rem) !important;
  min-height: 100vh !important;
}

html.nunu-auth-split.nunu-auth-page main > div {
  width: 100% !important;
  max-width: 24rem !important;
  background: var(--nunu-auth-card) !important;
  border: 1px solid var(--nunu-auth-border) !important;
  border-radius: 12px !important;
  box-shadow:
    0 1px 2px rgba(17, 24, 39, 0.04),
    0 8px 24px rgba(17, 24, 39, 0.06) !important;
  padding: 2rem 1.75rem !important;
}

html.nunu-auth-split.nunu-auth-page main h1.text-3xl::before {
  content: none !important;
  display: none !important;
}

html.nunu-auth-split.nunu-auth-page main h1.text-3xl {
  font-size: 1.5rem !important;
  font-weight: 600 !important;
  margin-bottom: 1.25rem !important;
  text-align: left !important;
}

html.nunu-auth-split.nunu-auth-page .align-end.m-4.flex.justify-center {
  position: absolute;
  bottom: 0;
  right: 0;
  left: 50%;
  margin: 0 !important;
  padding: 1rem !important;
  justify-content: center !important;
}

/* Error banner above card */
html.nunu-auth-split.nunu-auth-page .mx-auto.sm\:max-w-sm {
  position: absolute;
  top: 1rem;
  right: 1rem;
  left: 50%;
  max-width: 24rem;
  margin-left: auto !important;
  margin-right: auto !important;
  z-index: 2;
}

@media (max-width: 900px) {
  html.nunu-auth-split.nunu-auth-page .relative.flex.min-h-screen.flex-col.bg-surface-primary {
    flex-direction: column !important;
  }

  html.nunu-auth-split.nunu-auth-page .nunu-auth-split-brand {
    max-width: none;
    flex: 0 0 auto;
    padding: 2rem 1.5rem 1.5rem;
    border-right: none;
    border-bottom: 1px solid var(--nunu-auth-border);
  }

  html.nunu-auth-split.nunu-auth-page main {
    min-height: auto !important;
    padding-top: 1.5rem !important;
  }

  html.nunu-auth-split.nunu-auth-page .align-end.m-4.flex.justify-center {
    position: static;
    left: auto;
  }
}
