/* ============================================================
   ERLINK Portal - Design System 2.0 (Modern & Ultra Practical)
   Aesthetic: Deep Space Dark Mode, Glassmorphism, Neon Glow & Fintech Polish
   ============================================================ */

/* ---------- CSS Reset & Box Sizing ---------- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Core Backgrounds */
  --bg-deep: #060913;
  --bg-surface: #0c1222;
  --bg-card: rgba(18, 26, 47, 0.7);
  --bg-card-hover: rgba(24, 34, 60, 0.85);
  --bg-glass: rgba(255, 255, 255, 0.04);
  --bg-glass-strong: rgba(255, 255, 255, 0.08);

  /* Brand Accents & Gradients */
  --indigo: #6366f1;
  --cyan: #06b6d4;
  --emerald: #10b981;
  --rose: #f43f5e;
  --amber: #f59e0b;
  --pix: #00cec9;

  --grad-primary: linear-gradient(135deg, #6366f1 0%, #06b6d4 100%);
  --grad-pix: linear-gradient(135deg, #00b894 0%, #00cec9 100%);
  --grad-card-hero: linear-gradient(145deg, rgba(99, 102, 241, 0.12) 0%, rgba(6, 182, 212, 0.04) 50%, rgba(18, 26, 47, 0.85) 100%);
  --grad-glow: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, rgba(6, 182, 212, 0) 70%);

  /* Typography Colors */
  --text-main: #f8fafc;
  --text-sub: #94a3b8;
  --text-dim: #64748b;
  --text-white: #ffffff;

  /* Borders & Highlights */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(255, 255, 255, 0.16);
  --border-focus: rgba(99, 102, 241, 0.6);

  /* Shadows */
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-card: 0 12px 32px -8px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.06);
  --shadow-hero: 0 20px 48px -12px rgba(99, 102, 241, 0.25), 0 0 0 1px rgba(99, 102, 241, 0.2);
  --shadow-btn: 0 8px 24px -4px rgba(99, 102, 241, 0.4);
  --shadow-pix: 0 8px 24px -4px rgba(0, 206, 201, 0.4);

  /* Radii */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  /* Fonts */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-deep);
  color: var(--text-main);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  line-height: 1.5;
}

.hidden { display: none !important; }

/* ---------- Ambient Glow Background Orbs ---------- */
.ambient-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.45;
  transition: all 1s ease;
}
.glow-1 {
  width: 500px;
  height: 500px;
  top: -150px;
  left: 20%;
  background: radial-gradient(circle, #4f46e5 0%, rgba(79, 70, 229, 0) 70%);
}
.glow-2 {
  width: 450px;
  height: 450px;
  bottom: 5%;
  right: 10%;
  background: radial-gradient(circle, #06b6d4 0%, rgba(6, 182, 212, 0) 70%);
}

/* ---------- Screens Container ---------- */
.screen {
  display: none;
  position: relative;
  z-index: 1;
  min-height: 100vh;
}
.screen.active {
  display: flex;
}

/* ============================================================
   TELA DE LOGIN
   ============================================================ */
#login-screen {
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.login-container {
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  animation: modalEnter 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.login-card {
  background: var(--bg-card);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  box-shadow: var(--shadow-card), 0 0 60px rgba(99, 102, 241, 0.1);
  position: relative;
  overflow: hidden;
}

.login-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--grad-primary);
}

.login-header-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-bottom: 28px;
  width: 100%;
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.28);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #a5b4fc;
  margin: 0 auto 18px auto;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
  animation: pulseGlow 2s infinite;
}

.brand-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  margin: 0 auto;
}

.brand-logo-img {
  display: block;
  max-width: 260px;
  width: 100%;
  height: auto;
  object-fit: contain;
  margin: 0 auto 14px auto;
  filter: drop-shadow(0 6px 20px rgba(0, 206, 201, 0.28));
  transition: transform 0.25s ease;
}

.brand-logo-img:hover {
  transform: scale(1.02);
}

.brand-desc {
  color: var(--text-sub);
  font-size: 0.92rem;
  line-height: 1.55;
  max-width: 320px;
  margin: 0 auto;
  text-align: center;
}

/* Form Styles */
.form-group {
  margin-bottom: 24px;
}

.input-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 8px;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  background: rgba(10, 15, 30, 0.8);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all 0.25s ease;
}

.input-wrapper:focus-within {
  border-color: var(--indigo);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
  background: rgba(10, 15, 30, 0.95);
}

.input-wrapper.valid {
  border-color: var(--emerald);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}

.input-prefix-icon {
  display: flex;
  align-items: center;
  padding-left: 16px;
  color: var(--text-dim);
}

.input-wrapper input {
  width: 100%;
  padding: 16px 14px;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.input-wrapper input::placeholder {
  color: var(--text-dim);
  font-weight: 400;
  letter-spacing: normal;
}

.input-suffix-check {
  display: flex;
  align-items: center;
  padding-right: 16px;
  animation: scalePop 0.3s ease;
}

.input-hint {
  display: block;
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 6px;
}

/* Button with Glow */
.btn-primary-glow {
  width: 100%;
  padding: 16px 24px;
  background: var(--grad-primary);
  color: var(--text-white);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-btn);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.btn-primary-glow *,
.btn-logout * {
  pointer-events: none;
}

.btn-primary-glow:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px -4px rgba(99, 102, 241, 0.6);
  filter: brightness(1.06);
}

.btn-primary-glow:active {
  transform: translateY(1px) scale(0.99);
}

.btn-primary-glow .btn-text {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.spinner-circle {
  width: 20px;
  height: 20px;
  border: 2.5px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.login-trust-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  color: var(--text-dim);
  font-size: 0.82rem;
}

.copyright-note {
  text-align: center;
  color: var(--text-dim);
  font-size: 0.82rem;
  margin-top: 20px;
}

/* ============================================================
   TOP NAVBAR (Área do Cliente)
   ============================================================ */
#dashboard-screen {
  flex-direction: column;
}

.top-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(6, 9, 19, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
}

.nav-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-logo-img {
  height: 38px;
  max-width: 170px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(6, 182, 212, 0.25));
}

.nav-user-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 12px 5px 6px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
}

.user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--grad-primary);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.4);
}

.user-details {
  display: flex;
  flex-direction: column;
}

.user-fullname {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  max-width: 140px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-status-tag {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  color: var(--emerald);
  font-weight: 500;
}

.status-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 6px var(--emerald);
}

.btn-logout {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-sub);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-logout:hover {
  background: rgba(244, 63, 94, 0.15);
  border-color: rgba(244, 63, 94, 0.3);
  color: #fb7185;
}

/* ============================================================
   CONTEÚDO PRINCIPAL (DASHBOARD)
   ============================================================ */
.main-content {
  flex: 1;
  padding: 32px 20px 60px;
}

.content-container {
  max-width: 1080px;
  margin: 0 auto;
}

/* Welcome Header */
.welcome-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 16px;
}

.welcome-title {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 4px;
}

.welcome-subtitle {
  font-size: 0.95rem;
  color: var(--text-sub);
}

.btn-refresh {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-sub);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-refresh:hover {
  background: var(--bg-glass-strong);
  color: var(--text-main);
}

.btn-refresh.spinning svg {
  animation: spin 0.8s linear infinite;
}

/* Quick Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-highlight);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-icon-cyan {
  background: rgba(6, 182, 212, 0.12);
  color: var(--cyan);
  border: 1px solid rgba(6, 182, 212, 0.25);
}

.stat-icon-emerald {
  background: rgba(16, 185, 129, 0.12);
  color: var(--emerald);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.stat-icon-indigo {
  background: rgba(99, 102, 241, 0.12);
  color: var(--indigo);
  border: 1px solid rgba(99, 102, 241, 0.25);
}

.stat-info {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-dim);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
}

/* ============================================================
   HERO INVOICE CARD (CARD DESTAQUE DA FATURA ABERTA)
   ============================================================ */
.hero-invoice-wrapper {
  margin-bottom: 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  animation: fadeInUp 0.4s ease forwards;
}

.multiple-invoices-notice {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-lg);
  padding: 16px 22px;
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text-main);
  font-size: 0.95rem;
  line-height: 1.5;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.notice-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.multiple-invoices-notice strong {
  color: #fbbf24;
}

.hero-invoice-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 32px;
}

.hero-invoice-card {
  background: var(--grad-card-hero);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1.5px solid rgba(99, 102, 241, 0.35);
  border-radius: var(--radius-xl);
  padding: 36px;
  box-shadow: var(--shadow-hero);
  position: relative;
  overflow: hidden;
}

.hero-invoice-card::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(0, 206, 201, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-top-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.hero-tag-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hero-tag-badge.status-aberto {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.hero-tag-badge.status-atrasado {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fb7185;
}

.hero-tag-badge.status-carnet {
  background: rgba(6, 182, 212, 0.15);
  border: 1px solid rgba(6, 182, 212, 0.4);
  color: #38bdf8;
}

.hero-invoice-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--text-sub);
  font-size: 0.88rem;
}

.hero-middle-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border-subtle);
}

.hero-price-block {
  display: flex;
  flex-direction: column;
}

.hero-price-label {
  font-size: 0.9rem;
  color: var(--text-sub);
  margin-bottom: 4px;
}

.hero-price-value {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #ffffff;
  line-height: 1;
}

.hero-due-block {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
}

.hero-due-block strong {
  color: var(--text-white);
  font-family: var(--font-heading);
  font-size: 1.1rem;
}

/* 1-Click Action Buttons */
.hero-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}

@media (max-width: 768px) {
  .hero-middle-body {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .hero-actions-grid {
    grid-template-columns: 1fr;
  }
}

.btn-hero-pix {
  padding: 16px 20px;
  background: var(--grad-pix);
  color: #032b2b;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: var(--shadow-pix);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-hero-pix:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 12px 30px rgba(0, 206, 201, 0.5);
}

.btn-hero-pix:active {
  transform: translateY(1px) scale(0.99);
}

.btn-hero-copy {
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: 0.98rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-hero-copy:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.btn-hero-copy.copied {
  background: rgba(16, 185, 129, 0.25);
  border-color: var(--emerald);
  color: var(--emerald);
}

.btn-hero-unlock {
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(234, 88, 12, 0.25) 100%);
  border: 1.5px solid rgba(245, 158, 11, 0.6);
  border-radius: var(--radius-md);
  color: #fbbf24;
  font-family: var(--font-heading);
  font-size: 0.98rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 15px rgba(245, 158, 11, 0.15);
}

.btn-hero-unlock:hover:not(:disabled) {
  background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
  border-color: #f59e0b;
  color: #0c1427;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
}

.btn-hero-unlock:active:not(:disabled) {
  transform: translateY(1px) scale(0.99);
}

.btn-hero-unlock.already-unlocked {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.4);
  color: var(--emerald);
  cursor: default;
  opacity: 0.9;
  box-shadow: none;
}

/* Barra Separada de Desbloqueio (Discreta e sem confundir com os botões de PIX) */
.hero-unlock-separated-bar {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.hero-unlock-separated-text {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-sub);
  font-size: 0.84rem;
  font-weight: 500;
}

.hero-unlock-separated-text svg {
  color: #f59e0b;
  flex-shrink: 0;
}

.btn-unlock-compact {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-full);
  color: #f59e0b;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-unlock-compact:hover {
  background: rgba(245, 158, 11, 0.22);
  border-color: #f59e0b;
  transform: translateY(-1px);
}

.badge-unlock-compact.done {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-full);
  color: #10b981;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Unlock Modal Specifics */
.unlock-modal-dialog {
  max-width: 480px;
}

.unlock-icon-badge {
  width: 68px;
  height: 68px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.12);
  border: 1.5px solid rgba(245, 158, 11, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #f59e0b;
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

.unlock-modal-title {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-white);
  margin-bottom: 12px;
}

.unlock-modal-desc {
  color: var(--text-sub);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

.unlock-modal-desc strong {
  color: #fbbf24;
}

.unlock-info-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

.unlock-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.92rem;
}

.unlock-info-label {
  color: var(--text-dim);
}

.unlock-info-val {
  font-weight: 700;
  color: var(--text-main);
}

.unlock-info-val.highlight {
  color: #10b981;
  font-size: 0.88rem;
  background: rgba(16, 185, 129, 0.12);
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.unlock-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-confirm-unlock {
  width: 100%;
  padding: 15px 20px;
  background: linear-gradient(135deg, #f59e0b 0%, #10b981 100%);
  color: #0b1f1c;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 6px 20px rgba(245, 158, 11, 0.3);
  transition: all 0.25s ease;
}

.btn-confirm-unlock:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 10px 25px rgba(245, 158, 11, 0.45);
}

.btn-confirm-unlock:active {
  transform: translateY(1px);
}

.btn-cancel-unlock {
  width: 100%;
  padding: 12px;
  background: transparent;
  color: var(--text-sub);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-cancel-unlock:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

.btn-hero-boleto {
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-sub);
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-hero-boleto:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-main);
  border-color: var(--border-highlight);
  transform: translateY(-2px);
}

/* ============================================================
   EXTRATO DE FATURAS PAGAS (FINTECH STATEMENT)
   ============================================================ */
.extrato-section {
  margin-top: 10px;
}

.extrato-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.extrato-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.extrato-icon-badge {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.extrato-title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.extrato-subtitle {
  font-size: 0.88rem;
  color: var(--text-sub);
}

.extrato-tabs-container {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.04);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.tab-pill-btn {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-pill-btn:hover {
  color: var(--text-main);
}

.tab-pill-btn.active {
  background: linear-gradient(135deg, #6366f1, #06b6d4);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(99, 102, 241, 0.35);
}

.extrato-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.extrato-item {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  animation: fadeInUp 0.35s ease forwards;
}

.extrato-item:hover {
  transform: translateY(-2px);
  background: var(--bg-card-hover);
  border-color: var(--border-highlight);
  box-shadow: var(--shadow-card);
}

.extrato-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.extrato-icon-circle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.circle-pago {
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald);
}

.circle-aberto {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

.circle-atrasado {
  background: rgba(244, 63, 94, 0.15);
  color: #f43f5e;
}

.circle-carnet {
  background: rgba(6, 182, 212, 0.15);
  color: #38bdf8;
}

.extrato-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.extrato-name {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
}

.extrato-dates {
  font-size: 0.84rem;
  color: var(--text-sub);
}

.extrato-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.extrato-price-tag {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.extrato-amount {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
}

.extrato-amount.amount-pago {
  color: #10b981;
}

.extrato-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.extrato-status-pill.pill-pago { color: var(--emerald); }
.extrato-status-pill.pill-aberto { color: #fbbf24; }
.extrato-status-pill.pill-atrasado { color: #fb7185; }
.extrato-status-pill.pill-carnet { color: #38bdf8; }

.extrato-actions-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-extrato-pix-copy {
  padding: 8px 14px;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.18) 0%, rgba(99, 102, 241, 0.22) 100%);
  border: 1px solid rgba(6, 182, 212, 0.45);
  border-radius: var(--radius-sm);
  color: #38bdf8;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-extrato-pix-copy:hover {
  background: linear-gradient(135deg, #06b6d4, #6366f1);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.35);
}

.btn-extrato-qr {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-extrato-qr:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--border-highlight);
  color: #fff;
}

.btn-extrato-boleto {
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-sub);
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-extrato-boleto:hover {
  background: rgba(255, 255, 255, 0.09);
  color: var(--text-main);
  border-color: var(--border-highlight);
}

.btn-extrato-recibo {
  padding: 8px 16px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-sm);
  color: var(--emerald);
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-extrato-recibo:hover {
  background: var(--emerald);
  color: #0c1427;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-extrato-recibo:hover {
  background: rgba(99, 102, 241, 0.2);
  border-color: rgba(99, 102, 241, 0.4);
  color: #fff;
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  .extrato-item {
    flex-direction: column;
    align-items: flex-start;
    padding: 16px;
  }
  .extrato-right {
    width: 100%;
    justify-content: space-between;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-subtle);
  }
  .extrato-price-tag {
    align-items: flex-start;
  }
}

/* Invoices Grid */
.invoices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 18px;
}

.invoice-item-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  animation: fadeInUp 0.35s ease forwards;
}

.invoice-item-card:hover {
  transform: translateY(-3px);
  background: var(--bg-card-hover);
  border-color: var(--border-highlight);
  box-shadow: var(--shadow-card);
}

.item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}

.item-amount {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
}

.item-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
}

.item-badge.status-pago {
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.item-badge.status-aberto {
  background: rgba(245, 158, 11, 0.15);
  color: var(--amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.item-badge.status-atrasado {
  background: rgba(244, 63, 94, 0.15);
  color: var(--rose);
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.item-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
  font-size: 0.88rem;
  color: var(--text-sub);
}

.detail-line {
  display: flex;
  align-items: center;
  gap: 8px;
}

.detail-line svg {
  color: var(--text-dim);
  flex-shrink: 0;
}

.item-actions {
  display: flex;
  gap: 10px;
}

.btn-card-action {
  flex: 1;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-card-pix {
  background: var(--grad-pix);
  color: #032b2b;
  border: none;
  box-shadow: 0 4px 14px rgba(0, 206, 201, 0.3);
}

.btn-card-pix:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.btn-card-secondary {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  color: var(--text-sub);
}

.btn-card-secondary:hover {
  background: var(--bg-glass-strong);
  color: var(--text-main);
  border-color: var(--border-highlight);
}

/* ============================================================
   ESTADOS (LOADING & EMPTY)
   ============================================================ */
.state-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
}

.spinner-large {
  width: 44px;
  height: 44px;
  border: 3.5px solid rgba(99, 102, 241, 0.2);
  border-top-color: var(--indigo);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-bottom: 18px;
}

.empty-icon-circle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.state-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.state-subtitle {
  font-size: 0.92rem;
  color: var(--text-sub);
  max-width: 360px;
}

/* ============================================================
   MODAL PIX DE ALTA QUALIDADE
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 7, 15, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: fadeIn 0.25s ease forwards;
}

.modal-dialog {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  margin: auto;
  overflow-y: auto;
  overflow-x: hidden;
  box-sizing: border-box;
  background: #0d1424;
  border: 1.5px solid rgba(0, 206, 201, 0.35);
  border-radius: var(--radius-xl);
  padding: 32px 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(0, 206, 201, 0.15);
  animation: modalEnter 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.modal-dialog::-webkit-scrollbar {
  width: 6px;
}

.modal-dialog::-webkit-scrollbar-track {
  background: transparent;
}

.modal-dialog::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 8px;
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: var(--text-sub);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--text-main);
  transform: rotate(90deg);
}

.pix-modal-header {
  text-align: center;
  margin-bottom: 24px;
}

.pix-badge-icon {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: rgba(0, 206, 201, 0.12);
  border: 1px solid rgba(0, 206, 201, 0.3);
  border-radius: var(--radius-full);
  color: var(--pix);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.pix-modal-title {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}

.pix-amount-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 6px 16px;
  margin-bottom: 6px;
}

.pill-label {
  font-size: 0.85rem;
  color: var(--text-sub);
}

.pill-value {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--emerald);
}

.pix-due-text {
  display: block;
  font-size: 0.82rem;
  color: var(--text-dim);
}

/* QR Code Card - Padrão Grandes Operadoras (100% Centralizado) */
.qr-presentation-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0 auto 24px auto;
  text-align: center;
}

.qr-frame-outer {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  padding: 10px;
  background: rgba(0, 206, 201, 0.08);
  border: 1.5px dashed rgba(0, 206, 201, 0.4);
  border-radius: 24px;
  box-shadow: 0 0 35px rgba(0, 206, 201, 0.15);
  box-sizing: border-box;
}

.qr-frame {
  box-sizing: border-box;
  padding: 12px;
  background: #ffffff;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.65), 0 0 20px rgba(0, 206, 201, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  line-height: 0;
  width: 224px;
  height: 224px;
}

.qr-img-element {
  width: 200px;
  height: 200px;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  display: block;
  margin: 0 auto;
  object-fit: contain;
  border-radius: 4px;
  animation: fadeIn 0.25s ease;
}

.qr-scan-instruction {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 14px auto 0 auto;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-sub);
  text-align: center;
  width: 100%;
}

/* PIX String Box & Button */
.pix-copy-wrapper {
  margin-bottom: 24px;
}

.copy-box-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.copy-box-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-sub);
}

.copy-box-tag {
  font-size: 0.72rem;
  color: var(--cyan);
  font-weight: 600;
  background: rgba(6, 182, 212, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.pix-string-box {
  background: #080c16;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 12px;
  overflow: hidden;
}

.pix-string-text {
  display: block;
  font-family: monospace;
  font-size: 0.82rem;
  color: #cbd5e1;
  word-break: break-all;
  white-space: pre-wrap;
  max-height: 55px;
  overflow-y: auto;
}

.btn-copy-pix {
  width: 100%;
  padding: 16px 20px;
  background: var(--grad-pix);
  color: #032b2b;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: var(--shadow-pix);
  transition: all 0.25s ease;
}

.btn-copy-pix:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 206, 201, 0.5);
}

.btn-copy-pix.copied {
  background: #10b981;
  color: #ffffff;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.5);
}

/* Steps Guide */
.steps-guide {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  margin-bottom: 24px;
}

.step-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--text-sub);
}

.step-number {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0, 206, 201, 0.15);
  color: var(--pix);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Boleto Accordion */
.alternative-payment-accordion {
  padding-top: 8px;
}

.accordion-divider {
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}

.accordion-divider::before,
.accordion-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border-subtle);
}

.accordion-divider span {
  padding: 0 12px;
}

.boleto-number-box {
  background: #080c16;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 12px;
}

.boleto-number-label {
  display: block;
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-bottom: 2px;
}

.boleto-number-text {
  display: block;
  font-family: monospace;
  font-size: 0.82rem;
  color: var(--text-main);
  word-break: break-all;
}

.boleto-buttons-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.btn-secondary-action {
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary-action:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--border-highlight);
}

.btn-secondary-action.copied {
  background: rgba(16, 185, 129, 0.2);
  border-color: var(--emerald);
  color: var(--emerald);
}

.btn-secondary-primary {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.35);
  color: #a5b4fc;
}

.btn-secondary-primary:hover {
  background: rgba(99, 102, 241, 0.25);
  border-color: rgba(99, 102, 241, 0.5);
  color: #ffffff;
}

/* ============================================================
   TOAST NOTIFICATIONS (ESTILO SONNER / VERCEL)
   ============================================================ */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5);
  animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  min-width: 280px;
  max-width: 380px;
}

.toast.toast-success {
  border-left: 4px solid var(--emerald);
}

.toast.toast-error {
  border-left: 4px solid var(--rose);
}

.toast.toast-info {
  border-left: 4px solid var(--indigo);
}

.toast.hiding {
  animation: toastSlideOut 0.25s ease forwards;
}

.toast-icon {
  display: flex;
  align-items: center;
}

.toast-success .toast-icon { color: var(--emerald); }
.toast-error .toast-icon { color: var(--rose); }
.toast-info .toast-icon { color: var(--indigo); }

/* ============================================================
   KEYFRAMES & ANIMAÇÕES
   ============================================================ */
@keyframes modalEnter {
  from { opacity: 0; transform: scale(0.92) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes toastSlideIn {
  from { opacity: 0; transform: translateX(40px) scale(0.95); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes toastSlideOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(40px); }
}

@keyframes pulseGlow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(1.3); }
}

@keyframes scalePop {
  0% { transform: scale(0); }
  70% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Responsividade Mobile Avançada - Padrão Grandes Operadoras (Vivo / Claro / Nubank) */
@media (max-width: 640px) {
  .top-nav {
    padding: 10px 14px;
  }
  .nav-logo-img {
    height: 30px;
    max-width: 140px;
  }
  .main-content {
    padding: 10px 0 24px 0;
  }
  .content-container {
    padding: 0 10px;
  }

  /* Hero Card Compacto - "De Cara na Tela" */
  .hero-invoice-card {
    padding: 16px 14px;
    border-radius: var(--radius-lg);
    margin-bottom: 18px;
  }
  .hero-top-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
  }
  .hero-tag-badge {
    font-size: 0.72rem;
    padding: 4px 10px;
    letter-spacing: 0.03em;
  }
  .hero-invoice-meta {
    font-size: 0.78rem;
    gap: 6px;
  }
  .hero-middle-body {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-subtle);
  }
  .hero-price-block {
    display: flex;
    flex-direction: column;
  }
  .hero-price-label {
    font-size: 0.75rem;
    margin-bottom: 2px;
  }
  .hero-price-value {
    font-size: 1.95rem;
    line-height: 1.1;
  }
  .hero-due-block {
    width: auto;
    padding: 6px 12px;
    font-size: 0.8rem;
    gap: 6px;
    margin: 0;
    border-radius: var(--radius-sm);
  }
  .hero-due-block strong {
    font-size: 0.95rem;
  }

  /* Botões em 2 Colunas para caber na primeira dobra da tela */
  .hero-actions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .btn-hero-pix {
    grid-column: 1 / 2;
    padding: 12px 8px;
    font-size: 0.88rem;
    font-weight: 700;
    justify-content: center;
    gap: 6px;
  }
  .btn-hero-pix svg {
    width: 18px;
    height: 18px;
  }
  .btn-hero-copy {
    grid-column: 2 / 3;
    padding: 12px 8px;
    font-size: 0.88rem;
    font-weight: 700;
    justify-content: center;
    gap: 6px;
  }
  .btn-hero-copy svg {
    width: 17px;
    height: 17px;
  }
  .btn-hero-boleto {
    grid-column: 1 / -1;
    padding: 9px 12px;
    font-size: 0.85rem;
    justify-content: center;
  }
  .hero-unlock-separated-bar {
    margin-top: 10px;
    padding-top: 10px;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  .hero-unlock-separated-text {
    font-size: 0.76rem;
  }
  .btn-unlock-compact {
    padding: 5px 12px;
    font-size: 0.75rem;
  }

  .toast-container {
    top: 12px;
    right: 12px;
    left: 12px;
  }
  .toast {
    min-width: 0;
    max-width: none;
    font-size: 0.86rem;
    padding: 12px 16px;
  }
  .user-fullname {
    max-width: 100px;
    font-size: 0.85rem;
  }
  .btn-logout span {
    display: none;
  }
  .modal-dialog {
    width: 95%;
    max-height: 92vh;
    padding: 20px 16px;
  }
  .qr-frame-outer {
    padding: 6px;
    border-radius: 20px;
    margin: 0 auto;
  }
  .qr-frame {
    width: 204px;
    height: 204px;
    padding: 12px;
    box-sizing: border-box;
    border-radius: 16px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .qr-img-element {
    width: 180px;
    height: 180px;
    max-width: 100%;
    margin: 0 auto;
    display: block;
  }
  .qr-scan-instruction {
    font-size: 0.82rem;
    margin-top: 10px;
  }
  .extrato-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .extrato-right {
    width: 100%;
    justify-content: space-between;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-subtle);
  }
  .btn-extrato-recibo {
    width: auto;
    padding: 8px 14px;
    font-size: 0.82rem;
  }
}
