/* ==========================================================================
   TRÁMITES DIGITALES JD | SISTEMA DE DISEÑO ULTRA-PREMIUM (GREEN & GOLD LUXURY)
   ========================================================================== */

:root {
  --bg-base: #040806;
  --bg-surface: #0a110c;
  --bg-surface-elevated: #101a13;
  --bg-surface-card: rgba(16, 26, 19, 0.75);
  --bg-glass: rgba(10, 17, 12, 0.88);
  
  --border-subtle: rgba(212, 175, 55, 0.12);
  --border-medium: rgba(212, 175, 55, 0.25);
  --border-focus: #d4af37;

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-inverse: #020617;

  /* Luxury Green & Gold Theme */
  --primary-500: #10b981;
  --primary-600: #059669;
  --primary-glow: rgba(16, 185, 129, 0.25);

  --gold-300: #fde047;
  --gold-400: #fbbf24;
  --gold-500: #d4af37;
  --gold-600: #b48c1e;
  --gold-glow: rgba(212, 175, 55, 0.35);

  --accent-blue: #3b82f6;
  --accent-purple: #8b5cf6;
  --accent-red: #ef4444;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.6);
  --shadow-gold: 0 0 30px rgba(212, 175, 55, 0.2);

  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base Setup */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Ambient glow background */
body::before {
  content: '';
  position: fixed;
  top: -150px;
  left: 20%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.09) 0%, rgba(212, 175, 55, 0.05) 40%, transparent 75%);
  z-index: -1;
  pointer-events: none;
}

/* Typography Utilities */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Space Grotesk', 'Plus Jakarta Sans', sans-serif;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.gold-text {
  color: var(--gold-400);
  background: linear-gradient(135deg, #fef08a 0%, #d4af37 50%, #b48c1e 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gold-highlight {
  color: #fbbf24;
  font-weight: 800;
}

.text-gold {
  color: var(--gold-400) !important;
}

.font-mono {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
}

a {
  color: var(--gold-400);
  text-decoration: none;
}

/* ==========================================================================
   PANTALLA DE LOGIN / AUTH WRAPPER
   ========================================================================== */
.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  background: radial-gradient(ellipse at center, #07150c 0%, #030604 100%);
  overflow: hidden;
}

.auth-glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}

.auth-glow-orb.orb-1 {
  width: 450px;
  height: 450px;
  background: rgba(212, 175, 55, 0.12);
  top: -100px;
  right: -50px;
}

.auth-glow-orb.orb-2 {
  width: 500px;
  height: 500px;
  background: rgba(16, 185, 129, 0.14);
  bottom: -100px;
  left: -50px;
}

.auth-card {
  width: 100%;
  max-width: 480px;
  background: rgba(12, 20, 15, 0.85);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: var(--radius-xl);
  padding: 40px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), var(--shadow-gold);
  position: relative;
  z-index: 10;
  animation: fadeInAuth 0.5s ease-out;
}

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

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

.auth-logo-img {
  width: 110px;
  height: 110px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid rgba(212, 175, 55, 0.6);
  box-shadow: 0 0 30px rgba(212, 175, 55, 0.35);
  margin-bottom: 16px;
  animation: floatLogo 4s ease-in-out infinite;
}

@keyframes floatLogo {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.auth-title {
  font-family: 'Cinzel', 'Space Grotesk', serif;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #ffffff;
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
}

/* Demo Credentials Box */
.demo-credentials-box {
  background: rgba(212, 175, 55, 0.06);
  border: 1px dashed rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 20px;
}

.demo-title {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.demo-btn-group {
  display: flex;
  gap: 8px;
}

.btn-demo-pill {
  flex: 1;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all var(--transition-fast);
}

.btn-demo-pill.client:hover {
  background: rgba(16, 185, 129, 0.2);
  border-color: #10b981;
  color: #34d399;
}

.btn-demo-pill.admin:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: #d4af37;
  color: #fde047;
}

.label-with-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.forgot-pass-link {
  font-size: 11px;
  color: var(--gold-400);
}

.forgot-pass-link:hover {
  text-decoration: underline;
}

.auth-remember-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
  font-size: 12px;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text-secondary);
}

.secure-badge {
  color: #34d399;
  font-size: 11px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.auth-footer {
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 24px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 16px;
}

/* ==========================================================================
   APP HEADER
   ========================================================================== */
.app-header {
  height: 76px;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.app-header-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid rgba(212, 175, 55, 0.6);
  box-shadow: 0 0 14px rgba(212, 175, 55, 0.4);
}

.brand-name {
  font-family: 'Cinzel', 'Space Grotesk', serif;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: #ffffff;
}

.brand-tag {
  font-size: 10px;
  font-weight: 700;
  background: rgba(212, 175, 55, 0.15);
  color: var(--gold-400);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 6px;
  border: 1px solid rgba(212, 175, 55, 0.3);
}

.system-status {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.03);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  font-size: 12px;
  color: var(--text-secondary);
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #64748b;
}

.status-indicator.live {
  background-color: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Role Selector Pill */
.role-selector-pill {
  background: var(--bg-surface-elevated);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-medium);
  display: flex;
  gap: 4px;
}

.role-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all var(--transition-fast);
}

.role-btn:hover {
  color: var(--text-primary);
}

.role-btn.active {
  background: linear-gradient(135deg, #fde047 0%, #d4af37 100%);
  color: #1a1303;
  box-shadow: 0 2px 12px rgba(212, 175, 55, 0.4);
}

.role-btn.active .admin-badge {
  background: #1a1303;
  color: #fde047;
}

.admin-badge {
  font-size: 10px;
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
}

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

/* Wallet Pill Widget */
.wallet-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.12) 0%, rgba(16, 185, 129, 0.15) 100%);
  border: 1px solid rgba(212, 175, 55, 0.4);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.wallet-pill:hover {
  border-color: var(--gold-400);
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
  transform: translateY(-1px);
}

.wallet-icon {
  color: var(--gold-400);
  font-size: 16px;
}

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

.wallet-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
}

.wallet-amount {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: #fde047;
}

.btn-quick-recharge {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--gold-500);
  color: #1a1303;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: bold;
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-profile-badge .avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d4af37 0%, #b48c1e 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
  color: #1a1303;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

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

.user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.user-role-label {
  font-size: 11px;
  color: var(--text-muted);
}

.btn-logout {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #fca5a5;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-logout:hover {
  background: rgba(239, 68, 68, 0.25);
  color: #fff;
  border-color: #ef4444;
}

/* ==========================================================================
   APP CONTAINER & SIDEBAR
   ========================================================================== */
.app-container {
  display: flex;
  min-height: calc(100vh - 76px);
}

.app-sidebar {
  width: 280px;
  background: var(--bg-surface);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px 16px;
  position: sticky;
  top: 76px;
  height: calc(100vh - 76px);
  overflow-y: auto;
}

.sidebar-section {
  margin-bottom: 24px;
}

.section-title {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--gold-400);
  padding: 0 12px 10px 12px;
}

.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all var(--transition-fast);
  position: relative;
}

.nav-item i {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(212, 175, 55, 0.12);
  color: #fde047;
  border-color: rgba(212, 175, 55, 0.3);
  font-weight: 600;
}

.badge-counter {
  margin-left: auto;
  font-size: 11px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  color: var(--text-primary);
}

.badge-counter.warning {
  background: rgba(245, 158, 11, 0.2);
  color: var(--gold-400);
}

.badge-status-pulse {
  margin-left: auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.sidebar-footer {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

.support-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.support-text strong {
  display: block;
  font-size: 12px;
  color: var(--text-primary);
}

.support-text small {
  font-size: 11px;
  color: var(--text-muted);
}

.version-info {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
}

/* ==========================================================================
   MAIN CONTENT AREA & VIEWS
   ========================================================================== */
.app-main-content {
  flex: 1;
  padding: 32px;
  max-width: 1400px;
  margin: 0 auto;
  width: calc(100% - 280px);
}

.content-view {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.content-view.active {
  display: block;
}

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

.view-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 20px;
}

.view-title {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 6px;
}

.view-subtitle {
  color: var(--text-secondary);
  font-size: 14px;
}

.admin-top-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: #fde047;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.3);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* ==========================================================================
   BUTTONS & CONTROLS
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.btn-gold {
  background: linear-gradient(135deg, #fde047 0%, #d4af37 100%);
  color: #1a1303;
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.35);
}

.btn-gold:hover {
  background: linear-gradient(135deg, #fef08a 0%, #eab308 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
}

.btn-emerald {
  background: var(--primary-500);
  color: #022c22;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.35);
}

.btn-emerald:hover {
  background: #059669;
  color: #fff;
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent-blue);
  color: #fff;
}

.btn-outline {
  background: transparent;
  border-color: var(--border-medium);
  color: var(--text-primary);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--gold-400);
}

.btn-secondary {
  background: var(--bg-surface-elevated);
  border-color: var(--border-subtle);
  color: var(--text-secondary);
}

.btn-secondary:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.08);
}

.btn-link {
  background: none;
  border: none;
  color: var(--gold-400);
  padding: 0;
  cursor: pointer;
}

.btn-link:hover {
  text-decoration: underline;
}

.btn-sm {
  padding: 6px 14px;
  font-size: 12px;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
  border-radius: var(--radius-lg);
}

.btn-block {
  width: 100%;
}

.btn-micro {
  padding: 3px 8px;
  font-size: 11px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #fff;
  cursor: pointer;
}

/* ==========================================================================
   HERO BANNER & STATS CARDS
   ========================================================================== */
.hero-balance-banner {
  background: linear-gradient(135deg, #091f13 0%, #15291b 50%, #0d1711 100%);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), var(--shadow-gold);
  position: relative;
  overflow: hidden;
}

.hero-balance-banner::after {
  content: '';
  position: absolute;
  right: -50px;
  top: -50px;
  width: 260px;
  height: 260px;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #fde047;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.hero-balance-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.hero-balance-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 44px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.hero-currency {
  font-size: 18px;
  font-weight: 700;
  color: #fde047;
}

.hero-desc {
  color: var(--text-secondary);
  font-size: 13px;
  max-width: 520px;
  margin-top: 6px;
}

.hero-balance-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
}

.quick-spei-box {
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--border-medium);
  padding: 8px 16px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 12px;
}

.spei-tag {
  font-size: 10px;
  font-weight: 800;
  color: #fde047;
  background: rgba(212, 175, 55, 0.15);
  padding: 2px 6px;
  border-radius: 4px;
}

.spei-clabe {
  font-family: monospace;
  font-size: 14px;
  font-weight: 700;
  color: #f8fafc;
}

.btn-copy-clabe {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn-copy-clabe:hover {
  color: var(--gold-400);
}

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

.stat-card {
  background: var(--bg-surface-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--transition-fast);
}

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

.stat-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 14px;
}

.stat-icon.emerald { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.stat-icon.blue { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.stat-icon.purple { background: rgba(139, 92, 246, 0.15); color: #a78bfa; }
.stat-icon.amber { background: rgba(212, 175, 55, 0.15); color: #fde047; }

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

.stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
}

.stat-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.stat-trend {
  font-size: 11px;
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.stat-trend.positive { color: #34d399; }
.stat-trend.neutral { color: var(--text-muted); }

/* ==========================================================================
   SECTIONS & TABLES
   ========================================================================== */
.section-container {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 28px;
}

.section-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.section-heading {
  font-size: 18px;
  font-weight: 700;
}

.section-subtext {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* Quick Services Grid on Dashboard */
.quick-services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.quick-service-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.quick-service-card:hover {
  border-color: var(--gold-400);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.15);
  transform: translateY(-2px);
}

.card-top-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
}

.service-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
}

.service-badge.imss { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.service-badge.sat { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.service-badge.renapo { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.service-badge.infonavit { background: rgba(236, 72, 153, 0.15); color: #f472b6; }
.service-badge.otros { background: rgba(139, 92, 246, 0.15); color: #c084fc; }

.service-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.service-desc-snippet {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-bottom: 16px;
}

.card-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}

.service-price-tag {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #fde047;
}

.service-delivery-time {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Custom Tables */
.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.custom-table th {
  background: rgba(255, 255, 255, 0.02);
  color: var(--gold-400);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-medium);
}

.custom-table td {
  padding: 14px 16px;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
}

.custom-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-primary);
}

.folio-tag {
  font-family: monospace;
  font-weight: 700;
  color: #fde047;
  background: rgba(212, 175, 55, 0.12);
  padding: 3px 6px;
  border-radius: 4px;
  border: 1px solid rgba(212, 175, 55, 0.25);
}

/* Status Badges */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.status-pill.completed {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-pill.processing {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.status-pill.failed {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-pill.manual {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* ==========================================================================
   CATALOG GRID VIEW
   ========================================================================== */
.header-filters {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.search-input-box {
  position: relative;
  width: 100%;
  max-width: 450px;
}

.search-input-box i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.search-input-box input {
  width: 100%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  padding: 10px 14px 10px 38px;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
}

.search-input-box input:focus {
  outline: none;
  border-color: var(--gold-400);
}

.category-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.cat-pill {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.cat-pill:hover {
  color: var(--text-primary);
  border-color: var(--border-medium);
}

.cat-pill.active {
  background: rgba(212, 175, 55, 0.15);
  color: #fde047;
  border-color: rgba(212, 175, 55, 0.4);
}

.catalog-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

.catalog-card {
  background: var(--bg-surface-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--transition-smooth);
}

.catalog-card:hover {
  border-color: rgba(212, 175, 55, 0.4);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4), 0 0 20px rgba(212, 175, 55, 0.15);
  transform: translateY(-3px);
}

.catalog-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.catalog-service-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: rgba(212, 175, 55, 0.12);
  color: var(--gold-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.catalog-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.catalog-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 18px;
}

.catalog-req-list {
  background: rgba(0, 0, 0, 0.35);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 18px;
}

.catalog-req-list span {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--gold-400);
  text-transform: uppercase;
  margin-bottom: 4px;
}

.catalog-req-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.req-badge {
  font-size: 11px;
  background: rgba(255, 255, 255, 0.07);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--text-primary);
}

.catalog-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

.catalog-price-box {
  display: flex;
  flex-direction: column;
}

.price-sub {
  font-size: 11px;
  color: var(--text-muted);
}

.price-main {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 800;
  color: #fde047;
}

/* ==========================================================================
   WALLET & ORDERS TABS
   ========================================================================== */
.orders-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
  flex-wrap: wrap;
}

.filter-group {
  display: flex;
  gap: 8px;
}

.filter-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 6px 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.filter-btn.active {
  background: var(--gold-500);
  color: #1a1303;
}

.wallet-overview-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 32px;
}

.wallet-card-main {
  background: linear-gradient(135deg, #091f13 0%, #172c1c 100%);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: var(--radius-xl);
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5), var(--shadow-gold);
}

.card-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 800;
  color: #fde047;
  letter-spacing: 0.08em;
}

.card-balance-section .label {
  font-size: 12px;
  color: var(--text-secondary);
}

.card-balance-section .amount {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 38px;
  font-weight: 800;
  color: #fff;
}

.badge-mxn {
  font-size: 16px;
  color: #fde047;
  font-weight: 700;
}

.card-footer-details {
  display: flex;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.card-footer-details .small-label {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.card-footer-details .val {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.wallet-methods-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.method-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  padding: 12px;
  border-radius: var(--radius-md);
}

.method-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 12px;
}

.method-icon.spei { background: #1e3a8a; color: #93c5fd; }
.method-icon.card { background: #064e3b; color: #6ee7b7; font-size: 18px; }
.method-icon.oxxo { background: #7c2d12; color: #fdba74; }

.clabe-copy-box {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.clabe-copy-box code {
  font-family: monospace;
  font-weight: 700;
  background: rgba(0, 0, 0, 0.3);
  padding: 2px 6px;
  border-radius: 4px;
  color: #fde047;
}

/* ==========================================================================
   ADMIN PANEL STYLES
   ========================================================================== */
.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.kpi-card {
  background: var(--bg-surface-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

.kpi-card.highlight-emerald {
  border-color: rgba(16, 185, 129, 0.3);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, var(--bg-surface-card) 100%);
}

.kpi-card.highlight-blue {
  border-color: rgba(59, 130, 246, 0.3);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, var(--bg-surface-card) 100%);
}

.kpi-card.highlight-gold {
  border-color: rgba(212, 175, 55, 0.4);
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.1) 0%, var(--bg-surface-card) 100%);
}

.kpi-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-secondary);
  font-size: 13px;
  margin-bottom: 8px;
}

.kpi-val {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 30px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.kpi-sub {
  font-size: 12px;
  color: var(--text-muted);
}

.admin-split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 28px;
}

.admin-panel-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.box-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.demand-bars {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.demand-item-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.demand-meta {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
}

.demand-progress-bg {
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.demand-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #d4af37 0%, #10b981 100%);
  border-radius: var(--radius-full);
}

.api-health-summary {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.health-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 13px;
}

.badge-tag {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
}

.badge-tag.success { background: rgba(16, 185, 129, 0.15); color: #34d399; }

/* API Config Grid */
.api-config-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.api-form-card, .api-tester-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
}

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

.badge-live-tag {
  font-size: 10px;
  font-weight: 800;
  color: #fde047;
  background: rgba(212, 175, 55, 0.15);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid rgba(212, 175, 55, 0.3);
}

.tester-action-row {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.terminal-screen {
  background: #040805;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 18px;
}

.terminal-bar {
  background: #09120c;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid var(--border-subtle);
}

.terminal-bar .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

.term-title {
  font-size: 11px;
  font-family: monospace;
  color: var(--text-muted);
  margin-left: 8px;
}

.terminal-code {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 12px;
  color: #fde047;
  padding: 14px;
  white-space: pre-wrap;
  max-height: 260px;
  overflow-y: auto;
  line-height: 1.4;
}

.api-credentials-tips {
  background: rgba(212, 175, 55, 0.06);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: var(--radius-md);
  padding: 14px;
}

.api-credentials-tips h4 {
  font-size: 13px;
  color: #fde047;
  margin-bottom: 8px;
}

.api-credentials-tips ul {
  padding-left: 18px;
  font-size: 12px;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* ==========================================================================
   FORMS & INPUTS
   ========================================================================== */
.form-group {
  margin-bottom: 18px;
}

.form-row {
  display: flex;
  gap: 16px;
}

.form-group.col {
  flex: 1;
}

label, .form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.required {
  color: var(--accent-red);
}

.form-control {
  width: 100%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  transition: all var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--gold-400);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.form-control-lg {
  font-size: 18px;
  font-weight: 700;
  padding: 12px 18px;
}

.form-hint {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

.password-input-wrap, .currency-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.btn-toggle-pass {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
}

.currency-symbol {
  position: absolute;
  left: 14px;
  font-size: 16px;
  font-weight: 700;
  color: #fde047;
}

.currency-code {
  position: absolute;
  right: 14px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.currency-input-wrap input {
  padding-left: 28px;
  padding-right: 52px;
}

.radio-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
}

.custom-radio {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
}

/* Dynamic Checkbox Grid for Admin Service Editor */
.checkbox-tag-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.tag-checkbox {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.tag-checkbox:hover {
  border-color: var(--border-medium);
}

.tag-checkbox input:checked + span {
  color: #fde047;
  font-weight: 600;
}

/* ==========================================================================
   MODALS SYSTEM
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: all var(--transition-smooth);
  padding: 20px;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-dialog {
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  transform: scale(0.95);
  transition: transform var(--transition-smooth);
}

.modal-overlay.active .modal-dialog {
  transform: scale(1);
}

.modal-dialog.modal-lg { max-width: 720px; }
.modal-dialog.modal-xl { max-width: 900px; }

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-icon-badge {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: rgba(212, 175, 55, 0.15);
  color: var(--gold-400);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

.modal-title {
  font-size: 18px;
  font-weight: 700;
}

.modal-subtitle {
  font-size: 12px;
  color: var(--text-muted);
}

.modal-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  transition: color var(--transition-fast);
}

.modal-close-btn:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 24px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

/* Balance Check Card in Request Modal */
.balance-check-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.check-item .label {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}

.check-item .value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
}

.check-divider {
  width: 1px;
  height: 28px;
  background: var(--border-medium);
}

.insufficient-funds-alert {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  padding: 14px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  color: #fca5a5;
}

.insufficient-funds-alert i {
  font-size: 24px;
}

.insufficient-funds-alert strong {
  display: block;
  font-size: 13px;
  color: #fff;
}

.insufficient-funds-alert p {
  font-size: 12px;
}

.form-disclaimer {
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 16px;
}

/* Recharge Modal Elements */
.preset-amounts {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.preset-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  padding: 10px 0;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.preset-btn.active, .preset-btn:hover {
  background: var(--gold-500);
  color: #1a1303;
  border-color: var(--gold-500);
}

.payment-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
}

.pay-tab {
  flex: 1;
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 10px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pay-tab.active {
  background: rgba(212, 175, 55, 0.15);
  color: #fde047;
  border-color: rgba(212, 175, 55, 0.3);
}

.pay-tab-content {
  display: none;
}

.pay-tab-content.active {
  display: block;
}

.clabe-highlight-box {
  background: #040805;
  border: 1px dashed rgba(212, 175, 55, 0.4);
  border-radius: var(--radius-md);
  padding: 14px;
  margin: 14px 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.clabe-digits {
  font-family: monospace;
  font-size: 20px;
  font-weight: 800;
  color: #fde047;
  letter-spacing: 0.05em;
}

.clabe-bank, .clabe-owner {
  font-size: 12px;
  color: var(--text-secondary);
}

.spei-badge-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #34d399;
  margin-bottom: 6px;
}

.oxxo-ticket {
  background: #0a110c;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 20px;
  text-align: center;
}

.barcode-simulator {
  margin: 16px 0;
}

.barcode-lines {
  height: 40px;
  background: repeating-linear-gradient(90deg, #fff 0px, #fff 3px, #000 3px, #000 6px);
  margin-bottom: 6px;
}

/* Upload Dropzone */
.upload-dropzone {
  border: 2px dashed rgba(212, 175, 55, 0.4);
  background: rgba(212, 175, 55, 0.05);
  border-radius: var(--radius-lg);
  padding: 30px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.upload-dropzone:hover {
  background: rgba(212, 175, 55, 0.1);
  border-color: var(--gold-400);
}

.upload-dropzone i {
  font-size: 36px;
  color: var(--gold-400);
  margin-bottom: 10px;
}

.selected-file-label {
  display: block;
  font-size: 12px;
  color: #34d399;
  margin-top: 10px;
  font-weight: 600;
}

/* ==========================================================================
   OFFICIAL DOCUMENT GENERATOR & RENDERER (MEXICO IMSS / SAT STYLE)
   ========================================================================== */
.modal-viewer-body {
  background: #1c261e;
  padding: 30px;
  display: flex;
  justify-content: center;
}

.official-doc-sheet {
  background: #ffffff;
  color: #1e293b;
  width: 100%;
  max-width: 780px;
  padding: 40px;
  border-radius: 4px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
  font-family: 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.4;
  position: relative;
}

.doc-gov-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid #000;
  padding-bottom: 16px;
  margin-bottom: 24px;
}

.doc-gov-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0c3320;
}

.doc-gov-right {
  text-align: right;
  font-size: 11px;
  color: #64748b;
}

.doc-title-banner {
  text-align: center;
  margin-bottom: 24px;
}

.doc-title-banner h2 {
  font-size: 18px;
  color: #0f172a;
  text-transform: uppercase;
  font-weight: 800;
}

.doc-title-banner span {
  font-size: 12px;
  color: #475569;
}

.doc-table-data {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 24px;
}

.doc-table-data td {
  padding: 8px 10px;
  border: 1px solid #cbd5e1;
  font-size: 12px;
}

.doc-table-data .lbl {
  background: #f1f5f9;
  font-weight: bold;
  width: 35%;
  color: #334155;
}

.doc-table-data .val {
  font-weight: 600;
  color: #0f172a;
}

.doc-seal-box {
  margin-top: 30px;
  padding-top: 16px;
  border-top: 1px dashed #94a3b8;
  display: flex;
  gap: 20px;
  align-items: center;
}

.doc-qr {
  width: 90px;
  height: 90px;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 10px;
  font-family: monospace;
  text-align: center;
  padding: 4px;
}

.doc-digital-chain {
  font-family: monospace;
  font-size: 9px;
  color: #64748b;
  word-break: break-all;
}

/* ==========================================================================
   TOAST NOTIFICATIONS
   ========================================================================== */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: #0d1711;
  border: 1px solid var(--border-medium);
  border-left: 4px solid var(--gold-400);
  padding: 14px 18px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 320px;
  color: #fff;
  font-size: 13px;
  animation: slideInRight 0.3s ease;
}

.toast.error { border-left-color: var(--accent-red); }
.toast.warning { border-left-color: var(--accent-gold); }

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ==========================================================================
   RESPONSIVE QUERIES
   ========================================================================== */
@media (max-width: 1024px) {
  .app-sidebar {
    width: 240px;
  }
  .app-main-content {
    width: calc(100% - 240px);
    padding: 20px;
  }
  .admin-split-grid, .api-config-grid, .wallet-overview-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .app-header {
    flex-direction: column;
    height: auto;
    padding: 14px;
    gap: 12px;
  }
  .app-container {
    flex-direction: column;
  }
  .app-sidebar {
    width: 100%;
    height: auto;
    position: static;
  }
  .app-main-content {
    width: 100%;
    padding: 14px;
  }
  .hero-balance-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .hero-balance-actions {
    align-items: flex-start;
    width: 100%;
  }
}
