/**
 * Auth premium UI — apenas páginas de autenticação
 * Não afeta dashboard/hub/landing.
 */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@500;600;700;800&family=DM+Sans:wght@400;500;600;700&display=swap');

.auth-page {
  --auth-bg: #050508;
  --auth-panel: #0B0B12;
  --auth-card: rgba(18, 18, 28, 0.72);
  --auth-border: rgba(255, 255, 255, 0.08);
  --auth-purple: #7C3AED;
  --auth-purple-2: #6D28D9;
  --auth-purple-soft: #A78BFA;
  --auth-text: #F4F4F5;
  --auth-muted: #A1A1AA;
  margin: 0;
  min-height: 100vh;
  font-family: 'DM Sans', system-ui, sans-serif;
  color: var(--auth-text);
  background: var(--auth-bg);
}

.auth-page *,
.auth-page *::before,
.auth-page *::after {
  box-sizing: border-box;
}

.auth-split {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
}

/* ---- Left showcase ---- */
.auth-showcase {
  position: relative;
  overflow: hidden;
  padding: 3rem 3.25rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background:
    radial-gradient(ellipse 80% 60% at 10% 20%, rgba(124, 58, 237, 0.22), transparent 55%),
    radial-gradient(ellipse 60% 50% at 90% 90%, rgba(109, 40, 217, 0.12), transparent 50%),
    linear-gradient(160deg, #07070C 0%, #0A0A10 50%, #08060F 100%);
  border-right: 1px solid var(--auth-border);
}

.auth-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
  opacity: 0.55;
  animation: authFloat 9s ease-in-out infinite;
}

.auth-glow-a {
  width: 280px;
  height: 280px;
  background: rgba(124, 58, 237, 0.35);
  top: -60px;
  left: -40px;
}

.auth-glow-b {
  width: 220px;
  height: 220px;
  background: rgba(167, 139, 250, 0.18);
  bottom: 10%;
  right: -40px;
  animation-delay: 1.5s;
}

.auth-showcase-inner {
  position: relative;
  z-index: 1;
  max-width: 560px;
}

.auth-showcase-kicker {
  margin: 0 0 1rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--auth-purple-soft);
  animation: authFadeUp 0.6s ease both;
}

.auth-showcase-title {
  margin: 0;
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
  color: #FAFAFA;
  animation: authFadeUp 0.65s ease 0.05s both;
}

.auth-showcase-text {
  margin: 1.1rem 0 0;
  color: var(--auth-muted);
  font-size: 1.02rem;
  line-height: 1.65;
  max-width: 34rem;
  animation: authFadeUp 0.65s ease 0.1s both;
}

.auth-feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
  margin-top: 1.75rem;
  animation: authFadeUp 0.65s ease 0.15s both;
}

.auth-feature {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 0.9rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px);
  font-size: 0.875rem;
  font-weight: 600;
  color: #E4E4E7;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.auth-feature:hover {
  border-color: rgba(124, 58, 237, 0.35);
  transform: translateY(-1px);
}

.auth-feature-ico {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(124, 58, 237, 0.18);
  color: var(--auth-purple-soft);
  flex-shrink: 0;
}

/* Mock dashboard */
.auth-mock {
  margin-top: 2rem;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(12, 12, 20, 0.75);
  backdrop-filter: blur(16px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(124, 58, 237, 0.08);
  padding: 1rem;
  animation: authFadeUp 0.7s ease 0.2s both;
}

.auth-mock-top {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}

.auth-mock-stat {
  padding: 0.75rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.auth-mock-stat span {
  display: block;
  font-size: 0.68rem;
  color: var(--auth-muted);
  margin-bottom: 0.25rem;
}

.auth-mock-stat strong {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
}

.auth-mock-stat.income strong { color: #34D399; }
.auth-mock-stat.expense strong { color: #F87171; }
.auth-mock-stat.balance strong { color: var(--auth-purple-soft); }

.auth-mock-charts {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}

.auth-mock-panel {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 0.75rem;
  min-height: 110px;
}

.auth-mock-panel h4 {
  margin: 0 0 0.65rem;
  font-size: 0.7rem;
  color: var(--auth-muted);
  font-weight: 600;
}

.auth-bars {
  display: flex;
  align-items: flex-end;
  gap: 0.35rem;
  height: 72px;
}

.auth-bars i {
  display: block;
  flex: 1;
  border-radius: 4px 4px 2px 2px;
  background: linear-gradient(180deg, var(--auth-purple-soft), var(--auth-purple));
  opacity: 0.85;
  animation: authBar 1.2s ease both;
}

.auth-bars i:nth-child(1) { height: 42%; animation-delay: 0.05s; }
.auth-bars i:nth-child(2) { height: 68%; animation-delay: 0.1s; background: linear-gradient(180deg, #34D399, #059669); }
.auth-bars i:nth-child(3) { height: 55%; animation-delay: 0.15s; }
.auth-bars i:nth-child(4) { height: 80%; animation-delay: 0.2s; background: linear-gradient(180deg, #34D399, #059669); }
.auth-bars i:nth-child(5) { height: 48%; animation-delay: 0.25s; }
.auth-bars i:nth-child(6) { height: 72%; animation-delay: 0.3s; background: linear-gradient(180deg, #34D399, #059669); }

.auth-pie {
  width: 78px;
  height: 78px;
  margin: 0.2rem auto 0;
  border-radius: 50%;
  background: conic-gradient(
    #7C3AED 0 38%,
    #A78BFA 38% 58%,
    #34D399 58% 78%,
    #F59E0B 78% 100%
  );
  mask: radial-gradient(circle at center, transparent 42%, #000 43%);
  -webkit-mask: radial-gradient(circle at center, transparent 42%, #000 43%);
}

.auth-mock-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.auth-mock-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
  font-size: 0.75rem;
}

.auth-mock-row span { color: var(--auth-muted); }
.auth-mock-row .up { color: #34D399; font-weight: 700; }
.auth-mock-row .down { color: #F87171; font-weight: 700; }

/* ---- Right form panel ---- */
.auth-form-side {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem 1.5rem;
  background: #06060A;
  position: relative;
}

.auth-form-side::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 50% 40% at 80% 10%, rgba(124, 58, 237, 0.1), transparent 60%);
  pointer-events: none;
}

.auth-glass {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  padding: 2rem 1.75rem;
  border-radius: 24px;
  background: var(--auth-card);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  animation: authFadeUp 0.55s ease both;
}

.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: var(--auth-text);
  margin-bottom: 1.5rem;
}

.auth-brand img {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  object-fit: contain;
  object-position: center;
  background: #0B0B0F;
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.25);
}

.auth-brand strong {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.auth-heading {
  margin: 0;
  font-family: 'Outfit', sans-serif;
  font-size: 1.65rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.auth-sub {
  margin: 0.45rem 0 1.35rem;
  color: var(--auth-muted);
  font-size: 0.925rem;
}

.auth-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #D4D4D8;
  margin-bottom: 0.4rem;
}

.auth-input,
.auth-input-wrap input {
  width: 100%;
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--auth-text);
  font: inherit;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.auth-input:focus,
.auth-input-wrap input:focus {
  outline: none;
  border-color: rgba(124, 58, 237, 0.65);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
  background: rgba(255, 255, 255, 0.055);
}

.auth-input-wrap {
  position: relative;
}

.auth-input-wrap input {
  padding-right: 2.75rem;
}

.auth-eye {
  position: absolute;
  right: 0.55rem;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: var(--auth-muted);
  cursor: pointer;
  padding: 0.35rem;
  border-radius: 8px;
  display: grid;
  place-items: center;
}

.auth-eye:hover { color: var(--auth-text); background: rgba(255, 255, 255, 0.05); }

.auth-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.875rem;
}

.auth-check {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #D4D4D8;
  cursor: pointer;
  user-select: none;
}

.auth-check input {
  accent-color: var(--auth-purple);
  width: 15px;
  height: 15px;
}

.auth-link {
  color: var(--auth-purple-soft);
  text-decoration: none;
  font-weight: 600;
}

.auth-link:hover { text-decoration: underline; }

.auth-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.1rem;
  border: none;
  border-radius: 12px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  background: linear-gradient(135deg, var(--auth-purple), var(--auth-purple-2));
  color: #fff;
  box-shadow: 0 10px 28px rgba(124, 58, 237, 0.35);
  transition: transform 0.2s ease, filter 0.2s ease;
}

.auth-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 1.15rem 0;
  color: #71717A;
  font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
}

.auth-switch {
  text-align: center;
  font-size: 0.9rem;
  color: var(--auth-muted);
  margin: 0;
}

.auth-security {
  margin-top: 1.35rem;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: rgba(124, 58, 237, 0.08);
  border: 1px solid rgba(124, 58, 237, 0.18);
}

.auth-security-title {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #E4E4E7;
  margin-bottom: 0.55rem;
}

.auth-security-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.auth-security-list span {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--auth-muted);
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.auth-footer {
  position: relative;
  z-index: 1;
  max-width: 420px;
  margin: 1.25rem auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem 1.1rem;
  font-size: 0.75rem;
  color: #71717A;
}

.auth-footer a {
  color: #71717A;
  text-decoration: none;
}

.auth-footer a:hover { color: var(--auth-purple-soft); }

.auth-alert {
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  font-size: 0.875rem;
  margin-bottom: 1rem;
  animation: authFadeUp 0.35s ease;
}

.auth-alert-error {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.28);
  color: #FCA5A5;
}

.auth-alert-success {
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.28);
  color: #6EE7B7;
}

.auth-alert-info {
  background: rgba(124, 58, 237, 0.12);
  border: 1px solid rgba(124, 58, 237, 0.28);
  color: var(--auth-purple-soft);
}

.auth-field { margin-bottom: 0.95rem; }

@keyframes authFadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes authFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(12px); }
}

@keyframes authBar {
  from { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
  to { transform: scaleY(1); opacity: 0.85; }
}

@media (max-width: 980px) {
  .auth-split {
    grid-template-columns: 1fr;
  }

  .auth-showcase {
    display: none;
  }

  .auth-form-side {
    min-height: 100vh;
    padding: 1.5rem 1rem 2rem;
  }
}
