:root {
  --bg-main: #0a0e17;
  --bg-card: rgba(21, 29, 46, 0.85);
  --bg-card-border: rgba(255, 255, 255, 0.1);
  --primary-accent: #6366f1;
  --primary-glow: rgba(99, 102, 241, 0.4);
  --secondary-accent: #38bdf8;
  --text-main: #f8fafc;
  --text-sub: #94a3b8;
  --text-muted: #64748b;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --wood-accent: #d97706;
  --belt-color: #ef4444;
  --nav-height: 64px;
  --header-height: 56px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: #030712;
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow-x: hidden;
}

/* Mobile Frame Wrapper */
.mobile-app-wrapper {
  width: 100%;
  max-width: 480px;
  min-height: 100vh;
  background: linear-gradient(180deg, #0b1120 0%, #060913 100%);
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.8);
  padding-bottom: calc(var(--nav-height) + var(--safe-bottom) + 20px);
}

@media (min-width: 481px) {
  body {
    padding: 20px 0;
    background: radial-gradient(circle at top, #1e1b4b 0%, #030712 100%);
  }
  .mobile-app-wrapper {
    min-height: 860px;
    height: 860px;
    border-radius: 40px;
    border: 8px solid #1e293b;
    overflow-y: auto;
    overflow-x: hidden;
  }
}

/* Mobile Header */
.mobile-header {
  height: var(--header-height);
  padding: 0 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(11, 17, 32, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--bg-card-border);
}

.brand-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-logo {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--primary-accent), var(--secondary-accent));
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: 0 4px 12px var(--primary-glow);
}

.brand-text h2 {
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.3px;
  line-height: 1.1;
}

.brand-text span {
  font-size: 0.65rem;
  color: var(--secondary-accent);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 600;
}

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

.db-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 20px;
  font-size: 0.68rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--bg-card-border);
}

.db-status-badge .status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.db-status-badge.online {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.3);
  color: #34d399;
}
.db-status-badge.online .status-dot {
  background: #34d399;
  box-shadow: 0 0 8px #34d399;
}

.db-status-badge.offline {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #f87171;
}
.db-status-badge.offline .status-dot {
  background: #f87171;
}

.btn-header-icon {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--bg-card-border);
  color: var(--text-main);
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.95rem;
}

/* Selector Multicuenta Responsable */
.family-selector-bar {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.15), rgba(56, 189, 248, 0.15));
  border-bottom: 1px solid rgba(99, 102, 241, 0.25);
  padding: 8px 1rem;
}

.family-selector-inner {
  display: flex;
  align-items: center;
  gap: 8px;
}

.family-icon {
  font-size: 1.1rem;
}

.family-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-sub);
  white-space: nowrap;
}

.family-select {
  flex: 1;
  background: rgba(15, 23, 42, 0.85);
  color: var(--text-main);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  padding: 5px 8px;
  font-size: 0.82rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
}

/* Login View Container */
.login-view-container {
  display: none;
  min-height: 100vh;
  flex-direction: column;
  justify-content: center;
  padding: 1rem;
}

.login-view-container.active {
  display: flex !important;
}

/* Views Management */
.view-section {
  display: none;
  padding: 1rem;
  animation: fadeIn 0.25s ease forwards;
}

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

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

.view-header-title {
  margin-bottom: 1rem;
}

.view-header-title h2 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.4px;
}

.view-header-title p {
  font-size: 0.8rem;
  color: var(--text-sub);
}

/* Banners de Alerta */
.alert-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.alert-roturas {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.25), rgba(180, 83, 9, 0.15));
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.alert-examen {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(56, 189, 248, 0.15));
  border: 1px solid rgba(99, 102, 241, 0.4);
}

.alert-banner-icon {
  font-size: 1.6rem;
}

.alert-banner-content {
  flex: 1;
}

.alert-banner-content h4 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.alert-banner-content p {
  font-size: 0.75rem;
  color: var(--text-sub);
  line-height: 1.2;
}

.alert-banner-btn {
  background: var(--text-main);
  color: #0b1120;
  border: none;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

/* Hero Student Card */
.hero-student-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.hero-student-card::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.student-hero-content {
  display: flex;
  align-items: center;
  gap: 14px;
}

.student-avatar-container {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 20px;
  padding: 3px;
  background: linear-gradient(135deg, var(--primary-accent), var(--secondary-accent));
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.4);
}

.student-avatar {
  width: 100%;
  height: 100%;
  border-radius: 17px;
  object-fit: cover;
  background: #0f172a;
}

.belt-indicator-badge {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 24px;
  height: 24px;
  background: #1e293b;
  border: 2px solid #0f172a;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

.student-hero-info h1 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.4px;
  line-height: 1.2;
}

.student-category {
  font-size: 0.75rem;
  color: var(--text-sub);
  margin-bottom: 6px;
}

.belt-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--bg-card-border);
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
}

.belt-color-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--belt-color);
  box-shadow: 0 0 8px var(--belt-color);
}

/* Status Cards Grid */
.status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 1rem;
}

.status-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.status-card:hover {
  transform: translateY(-2px);
}

.status-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.status-icon.green {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
}

.status-icon.blue {
  background: rgba(56, 189, 248, 0.15);
  color: var(--secondary-accent);
}

.status-data label {
  font-size: 0.68rem;
  color: var(--text-sub);
  display: block;
}

.status-data span {
  font-size: 0.85rem;
  font-weight: 700;
}

/* Quick Nav Grid */
.quick-nav-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 1.2rem;
}

.quick-nav-btn {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 12px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.quick-nav-btn:hover {
  border-color: var(--primary-accent);
  transform: translateY(-2px);
}

.quick-nav-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.quick-nav-icon.wood-glow {
  background: rgba(217, 119, 6, 0.2);
  color: #f59e0b;
}

.quick-nav-icon.belt-glow {
  background: rgba(99, 102, 241, 0.2);
  color: #818cf8;
}

.quick-nav-icon.card-glow {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
}

.quick-nav-icon.qr-glow {
  background: rgba(56, 189, 248, 0.2);
  color: #38bdf8;
}

.quick-nav-btn span {
  font-size: 0.68rem;
  font-weight: 600;
  text-align: center;
}

/* Generic Section Block */
.section-block {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-lg);
  padding: 1.1rem;
  margin-bottom: 1rem;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.9rem;
  letter-spacing: -0.2px;
}

.btn-edit-inline {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--bg-card-border);
  color: var(--text-main);
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
}

/* Info List Items */
.info-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.info-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.info-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

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

.info-value {
  font-weight: 600;
  color: var(--text-main);
  text-align: right;
}

.info-value.highlight {
  color: var(--secondary-accent);
}

/* ==================== MÓDULO ROTURAS STYLES ==================== */
.campaign-status-card {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.2), rgba(180, 83, 9, 0.1));
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-lg);
  padding: 1.1rem;
  margin-bottom: 1rem;
}

.campaign-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.campaign-tag {
  background: rgba(245, 158, 11, 0.25);
  color: #fbbf24;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 800;
}

.campaign-date {
  font-size: 0.72rem;
  color: var(--text-sub);
}

.campaign-status-card h3 {
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.campaign-sub {
  font-size: 0.75rem;
  color: var(--text-sub);
}

.permission-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}

.permission-ok {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.permission-blocked {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.perm-icon {
  font-size: 1.3rem;
}

.perm-content h4 {
  font-size: 0.85rem;
  font-weight: 700;
}

.perm-content p {
  font-size: 0.72rem;
  color: var(--text-sub);
}

.itf-recommendation-box {
  background: rgba(56, 189, 248, 0.1);
  border: 1px dashed rgba(56, 189, 248, 0.4);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  margin-bottom: 1rem;
}

.itf-rec-header {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--secondary-accent);
  margin-bottom: 4px;
}

.itf-rec-body {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
}

.roturas-products-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.product-rotura-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.product-rotura-card.recommended {
  border-color: var(--secondary-accent);
  background: rgba(56, 189, 248, 0.05);
}

.prod-info {
  flex: 1;
}

.prod-header {
  display: flex;
  align-items: center;
  gap: 6px;
}

.prod-header strong {
  font-size: 0.88rem;
}

.rec-badge {
  background: rgba(56, 189, 248, 0.2);
  color: var(--secondary-accent);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 800;
}

.prod-desc {
  font-size: 0.72rem;
  color: var(--text-sub);
  margin-top: 2px;
}

.prod-price {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--success);
  margin-top: 4px;
}

.counter-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-counter {
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--bg-card-border);
  color: var(--text-main);
  border-radius: 8px;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.counter-value {
  font-size: 0.95rem;
  font-weight: 800;
  min-width: 20px;
  text-align: center;
}

.order-summary-box {
  background: rgba(15, 23, 42, 0.6);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.order-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-sub);
}

.order-summary-row.total {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 6px;
  margin-top: 4px;
}

.orders-history-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.order-item-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
}

.order-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.order-item-header strong {
  font-size: 0.85rem;
}

.order-badge {
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 800;
}

.order-badge.SOLICITADO {
  background: rgba(245, 158, 11, 0.2);
  color: var(--warning);
}

.order-badge.PAGADO {
  background: rgba(56, 189, 248, 0.2);
  color: var(--secondary-accent);
}

.order-badge.ENTREGADO {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

/* ==================== MÓDULO EXÁMENES STYLES ==================== */
.exam-active-card {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(30, 41, 59, 0.9));
  border: 1px solid rgba(99, 102, 241, 0.4);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  margin-bottom: 1rem;
}

.exam-card-badge {
  display: inline-block;
  background: rgba(99, 102, 241, 0.3);
  color: #818cf8;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.exam-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 12px 0;
}

.exam-detail-item label {
  font-size: 0.68rem;
  color: var(--text-sub);
  display: block;
}

.exam-detail-item span, .exam-detail-item strong {
  font-size: 0.82rem;
}

.exam-status-banner {
  background: rgba(15, 23, 42, 0.7);
  padding: 8px 12px;
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
}

.martial-timeline {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.timeline-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.timeline-item.active {
  background: rgba(99, 102, 241, 0.1);
  border-color: rgba(99, 102, 241, 0.3);
}

/* ==================== MÓDULO CUOTAS STYLES ==================== */
.balance-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  text-align: center;
  margin-bottom: 1rem;
}

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

.balance-amount {
  font-size: 1.8rem;
  font-weight: 900;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}

.balance-pill {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 800;
}

.balance-pill.al-dia {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.balance-pill.deuda {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.bank-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bank-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 6px;
}

.bank-type {
  font-size: 0.68rem;
  color: var(--secondary-accent);
  font-weight: 700;
}

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

.copyable-value {
  font-family: monospace;
  font-weight: 700;
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.3);
  padding: 2px 6px;
  border-radius: 4px;
}

.btn-copy {
  background: rgba(99, 102, 241, 0.2);
  color: #818cf8;
  border: 1px solid rgba(99, 102, 241, 0.3);
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
}

.cuotas-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cuota-card-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ==================== MÓDULO CLASES & ASISTENCIAS ==================== */
.attendance-metric-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-lg);
  padding: 1.1rem;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 1rem;
}

.att-gauge {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: conic-gradient(var(--success) 85%, rgba(255, 255, 255, 0.1) 0);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.3);
}

.att-pct {
  font-size: 0.95rem;
  font-weight: 800;
}

.att-lbl {
  font-size: 0.55rem;
  color: var(--text-sub);
}

.att-details {
  flex: 1;
}

.att-details h4 {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--success);
}

.att-details p {
  font-size: 0.72rem;
  color: var(--text-sub);
  margin: 2px 0 6px;
}

.att-progress-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
}

.att-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--secondary-accent), var(--success));
}

.classes-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.class-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-md);
  padding: 12px;
}

.class-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.class-card-top strong {
  font-size: 0.9rem;
}

.class-cat-badge {
  background: rgba(99, 102, 241, 0.2);
  color: #818cf8;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-weight: 700;
}

.class-time {
  font-size: 0.78rem;
  color: var(--secondary-accent);
  font-weight: 600;
  margin-bottom: 4px;
}

.class-location {
  font-size: 0.72rem;
  color: var(--text-sub);
}

/* ==================== MÓDULO BIBLIOTECA STYLES ==================== */
.library-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.lib-icon {
  width: 40px;
  height: 40px;
  background: rgba(99, 102, 241, 0.15);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.lib-content {
  flex: 1;
}

.lib-content h4 {
  font-size: 0.85rem;
  font-weight: 700;
}

.lib-content p {
  font-size: 0.72rem;
  color: var(--text-sub);
}

/* ==================== CARNET DIGITAL & QR ==================== */
.digital-carnet-card {
  background: linear-gradient(135deg, #1e1b4b 0%, #0f172a 100%);
  border: 2px solid rgba(99, 102, 241, 0.4);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  margin-bottom: 1.2rem;
}

.carnet-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 10px;
  margin-bottom: 12px;
}

.carnet-federation {
  display: flex;
  align-items: center;
  gap: 8px;
}

.carnet-federation-icon {
  font-size: 1.4rem;
}

.carnet-federation-text h3 {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.carnet-federation-text p {
  font-size: 0.55rem;
  color: var(--text-sub);
  letter-spacing: 1px;
}

.carnet-badge-status {
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 0.65rem;
  font-weight: 800;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.carnet-body {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.carnet-avatar {
  width: 68px;
  height: 68px;
  border-radius: 14px;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: #0f172a;
}

.carnet-details h2 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.carnet-details p {
  font-size: 0.72rem;
  color: var(--text-sub);
  margin-bottom: 4px;
}

.carnet-belt-tag {
  display: inline-block;
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.4);
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 800;
}

.carnet-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 8px;
}

.carnet-id-group label {
  font-size: 0.55rem;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  display: block;
}

.carnet-id-group p {
  font-family: monospace;
  font-size: 0.85rem;
  font-weight: 700;
}

.qr-container-card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.qr-code-box {
  width: 190px;
  height: 190px;
  background: #ffffff;
  border-radius: 16px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  margin-bottom: 12px;
}

.qr-caption {
  font-size: 0.8rem;
  color: var(--text-sub);
  font-weight: 600;
}

/* ==================== BOTTOM NAV BAR ==================== */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 480px;
  height: var(--nav-height);
  background: rgba(11, 17, 32, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--bg-card-border);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 4px;
  padding-bottom: var(--safe-bottom);
  z-index: 100;
  overflow-x: auto;
}

.nav-tab {
  background: transparent;
  border: none;
  color: var(--text-sub);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px 6px;
  cursor: pointer;
  border-radius: 10px;
  min-width: 48px;
  transition: all 0.2s ease;
}

.nav-tab-icon {
  font-size: 1.15rem;
}

.nav-tab span:last-child {
  font-size: 0.65rem;
  font-weight: 600;
}

.nav-tab.active {
  color: var(--text-main);
}

.nav-tab.active .nav-tab-icon {
  transform: scale(1.15);
}

.nav-tab.active span:last-child {
  color: var(--secondary-accent);
  font-weight: 700;
}

/* ==================== BUTTONS & FORMS ==================== */
.btn-primary {
  background: linear-gradient(135deg, var(--primary-accent), var(--secondary-accent));
  color: #ffffff;
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px var(--primary-glow);
  transition: all 0.2s ease;
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-primary.btn-block {
  width: 100%;
}

.form-group {
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-sub);
}

.form-input {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid var(--bg-card-border);
  border-radius: 10px;
  padding: 10px 12px;
  color: var(--text-main);
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.form-input:focus {
  border-color: var(--primary-accent);
}

/* ==================== MODAL & TOAST ==================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  display: none;
  align-items: flex-end;
  justify-content: center;
  z-index: 200;
}

.modal-backdrop.active {
  display: flex;
}

.modal-sheet {
  background: #0f172a;
  border: 1px solid var(--bg-card-border);
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  width: 100%;
  max-width: 480px;
  padding: 1.5rem;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
}

.modal-header h3 {
  font-size: 1.1rem;
  font-weight: 800;
}

.btn-close-modal {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: var(--text-main);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
}

.toast-notification {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: rgba(16, 185, 129, 0.95);
  color: #ffffff;
  padding: 10px 18px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  z-index: 300;
  transition: transform 0.3s ease;
  pointer-events: none;
}

.toast-notification.show {
  transform: translateX(-50%) translateY(0);
}

.loading-spinner {
  text-align: center;
  padding: 20px;
  font-size: 0.8rem;
  color: var(--text-sub);
}

.empty-text {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  padding: 10px 0;
}
