/* ========================================================
   BUXORIYLAR MAKTABI - NEXT-GEN LIQUID GLASSMORPHISM 2.0
   Apple macOS & iOS Inspired Translucent Glass & Crisp Typography
   Optimized for 60-120 FPS Smooth Performance & AWS Network
   ======================================================== */

/* Font is preloaded asynchronously in HTML for 0ms render-blocking */

:root {
  --primary-deep: #0F172A;
  --primary-navy: #1E1B4B;
  --primary-indigo: #4338CA;
  --primary-vibrant: #6366F1;
  --accent-pink: #EC4899;
  --accent-violet: #8B5CF6;
  --accent-sky: #0EA5E9;
  --accent-emerald: #10B981;
  --accent-rose: #F43F5E;
  --accent-amber: #F59E0B;

  /* Glassmorphism System Colors */
  --glass-bg: rgba(255, 255, 255, 0.76);
  --glass-bg-hover: rgba(255, 255, 255, 0.92);
  --glass-border: rgba(255, 255, 255, 0.88);
  --glass-border-subtle: rgba(255, 255, 255, 0.55);
  --glass-shadow: 0 12px 36px -4px rgba(30, 27, 75, 0.05), 
                  0 2px 6px rgba(30, 27, 75, 0.02),
                  inset 0 1px 1px rgba(255, 255, 255, 0.95);
}

/* ================= BASE & CRISP TYPOGRAPHY ================= */
* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  box-sizing: border-box;
}

body {
  touch-action: manipulation;
  background-color: #F8FAFC;
  background-image: 
    radial-gradient(circle at 12% 5%, rgba(99, 102, 241, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 88% 8%, rgba(59, 130, 246, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 50% 95%, rgba(99, 102, 241, 0.03) 0%, transparent 50%);
  background-attachment: fixed;
  color: #0F172A;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  margin: 0;
  padding: 0;
}

/* Shriftlar bo'yicha aniq ierarxiya (Crisp Modern Typography) */
h1, h2, h3, h4, h5, h6 {
  letter-spacing: -0.025em;
  font-weight: 800;
  color: var(--primary-deep);
}

p, span, label, input, button {
  letter-spacing: -0.01em;
}

.tabular-nums, .font-mono {
  font-family: 'JetBrains Mono', monospace;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

/* ================= 1. GLASSMORPHISM CARDS ================= */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: 24px;
  position: relative;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
  contain: layout style;
}

.glass-card:hover {
  border-color: rgba(255, 255, 255, 1);
}

.glass-card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px -8px rgba(99, 102, 241, 0.13), 
              0 2px 6px rgba(30, 27, 75, 0.03),
              inset 0 1px 2px rgba(255, 255, 255, 1);
  border-color: rgba(255, 255, 255, 1);
}

/* CRM Stat Card */
.crm-stat-card {
  background: rgba(255, 255, 255, 0.84);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 24px -4px rgba(30, 27, 75, 0.04), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 20px;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.crm-stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -4px rgba(67, 56, 202, 0.10), inset 0 1px 1px rgba(255, 255, 255, 1);
}

/* ================= 2. TOP FLOATING GLASS HEADER & NAV ================= */
.glass-bar {
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 4px 20px -2px rgba(30, 27, 75, 0.03);
}

.liquid-nav-container {
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 20px -2px rgba(30, 27, 75, 0.05), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 9999px;
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 4px;
}

/* Old legacy liquid-nav-pill replaced by SavdoStat liquid sliding pill below */

.liquid-nav-btn {
  position: relative;
  z-index: 2;
  cursor: pointer;
  user-select: none;
  outline: none;
  transition: color 0.2s ease, transform 0.1s ease;
  white-space: nowrap;
}

.liquid-nav-btn:active {
  transform: scale(0.96);
}

.liquid-nav-btn.active {
  color: #ffffff !important;
}

.liquid-nav-btn:not(.active) {
  color: rgba(30, 27, 75, 0.65);
}

.liquid-nav-btn:not(.active):hover {
  color: #1E1B4B;
}

/* ================= 3. GLASS BUTTONS & MICRO-INTERACTIONS ================= */
/* Asosiy tugma (Vibrant Indigo Liquid Glow) */
.btn-liquid-primary {
  background: linear-gradient(135deg, #4338CA 0%, #6366F1 100%);
  color: #ffffff;
  box-shadow: 0 6px 18px -3px rgba(67, 56, 202, 0.36), inset 0 1px 1px rgba(255, 255, 255, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  user-select: none;
  transition: transform 0.12s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.12s cubic-bezier(0.16, 1, 0.3, 1), background 0.15s ease;
  will-change: transform;
}

.btn-liquid-primary:hover {
  background: linear-gradient(135deg, #3730A3 0%, #4F46E5 100%);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px -3px rgba(67, 56, 202, 0.45);
}

.btn-liquid-primary:active {
  transform: scale(0.96) !important;
  box-shadow: 0 2px 8px rgba(67, 56, 202, 0.3) !important;
}

/* Ikkilamchi tugma (Frosted Glass Button) */
.btn-liquid-secondary {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  color: #1E1B4B;
  box-shadow: 0 3px 10px rgba(30, 27, 75, 0.03), inset 0 1px 1px rgba(255, 255, 255, 1);
  cursor: pointer;
  user-select: none;
  transition: transform 0.12s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  will-change: transform;
}

.btn-liquid-secondary:hover {
  background: #ffffff;
  color: #4338CA;
  border-color: #C7D2FE;
  transform: translateY(-1px);
}

.btn-liquid-secondary:active {
  transform: scale(0.96) !important;
}

/* ================= 4. GRADE & CLASS PILL CHIPS ================= */
.grade-chip, .class-chip {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  color: #1E1B4B;
  box-shadow: 0 2px 6px rgba(30, 27, 75, 0.02);
  transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  user-select: none;
  font-weight: 700;
}

.grade-chip:hover, .class-chip:hover {
  background: #ffffff;
  border-color: #C7D2FE;
  transform: translateY(-1px);
}

.grade-chip:active, .class-chip:active {
  transform: scale(0.96);
}

.grade-chip.active {
  background: #1E1B4B !important;
  color: #ffffff !important;
  border-color: transparent !important;
  box-shadow: 0 6px 16px -2px rgba(30, 27, 75, 0.3);
}

.class-chip.active {
  background: linear-gradient(135deg, #4338CA 0%, #6366F1 100%) !important;
  color: #ffffff !important;
  border-color: transparent !important;
  box-shadow: 0 6px 18px -2px rgba(67, 56, 202, 0.38);
}

/* ================= 5. DAVOMAT MATRITSA KARTALARI (STUDENT MATRIX) ================= */
.student-matrix-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 1);
  box-shadow: 0 4px 14px -3px rgba(30, 27, 75, 0.04), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 16px;
  contain: content;
  content-visibility: auto;
  contain-intrinsic-size: 115px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  will-change: transform;
}

.student-matrix-card:hover {
  transform: translateY(-2px);
  border-color: #C7D2FE;
  box-shadow: 0 8px 22px -4px rgba(99, 102, 241, 0.14);
}

/* Davomat 3 ta tugmasi mikro-reaksiya */
.att-btn-bor, .att-btn-yoq, .att-btn-sabab {
  transition: transform 0.1s cubic-bezier(0.2, 0.8, 0.2, 1), background-color 0.12s ease, box-shadow 0.12s ease !important;
  will-change: transform;
}

.att-btn-bor:active, .att-btn-yoq:active, .att-btn-sabab:active {
  transform: scale(0.92) !important;
}

/* ================= 6. GLASS INPUTS & FORM FIELDS ================= */
input[type="text"],
input[type="date"],
input[type="month"],
input[type="number"],
input[type="password"],
input[type="email"],
select,
textarea {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(226, 232, 240, 0.9);
  color: #1E1B4B;
  font-family: inherit;
  font-weight: 600;
  border-radius: 14px;
  transition: all 0.18s ease;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  background: #ffffff;
  border-color: #6366F1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18);
}

/* ================= 7. GLASS MODAL DIALOGS ================= */
.glass-modal-backdrop {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.glass-modal-content {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 25px 60px -15px rgba(30, 27, 75, 0.2), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 28px;
}

/* ================= 8. IOS DYNAMIC ISLAND NOTIFICATION TOAST (KOMPAKT & NAZOKATLI) ================= */
.ios-toast {
  background: linear-gradient(135deg, rgba(30, 27, 75, 0.96) 0%, rgba(67, 56, 202, 0.94) 100%) !important;
  backdrop-filter: blur(20px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 10px 24px -4px rgba(15, 23, 42, 0.22), 
              0 1px 1px rgba(255, 255, 255, 0.2) inset !important;
  border-radius: 16px !important;
  color: #FFFFFF !important;
  min-width: 220px;
  max-width: 340px;
  pointer-events: auto !important;
  transform-origin: top right;
  will-change: transform, opacity;
  animation: iosSpringEntrance 0.32s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes iosSpringEntrance {
  0% {
    opacity: 0;
    transform: translateY(-25px) scale(0.9);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.ios-toast.ios-toast-leave {
  animation: iosSpringExit 0.24s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes iosSpringExit {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(-20px) scale(0.9);
  }
}

/* ================= ATTENDANCE CLICKABLE FILTER CHIPS ================= */
.att-filter-chip {
  padding: 4px 11px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #475569;
  cursor: pointer;
  transition: all 0.16s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  user-select: none;
}

.att-filter-chip:hover {
  background: #F1F5F9;
  color: #0F172A;
  border-color: #CBD5E1;
}

.att-filter-chip.active-all {
  background: #0F172A !important;
  color: #FFFFFF !important;
  border-color: #0F172A !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.2);
}

.att-filter-chip.active-bor {
  background: #059669 !important;
  color: #FFFFFF !important;
  border-color: #059669 !important;
  box-shadow: 0 1px 4px rgba(5, 150, 105, 0.25);
}

.att-filter-chip.active-yoq {
  background: #E11D48 !important;
  color: #FFFFFF !important;
  border-color: #E11D48 !important;
  box-shadow: 0 1px 4px rgba(225, 29, 72, 0.25);
}

.att-filter-chip.active-sabab {
  background: #D97706 !important;
  color: #FFFFFF !important;
  border-color: #D97706 !important;
  box-shadow: 0 1px 4px rgba(217, 119, 6, 0.25);
}

.att-filter-chip.active-unmarked {
  background: #475569 !important;
  color: #FFFFFF !important;
  border-color: #475569 !important;
  box-shadow: 0 1px 4px rgba(71, 85, 105, 0.25);
}

/* ================= 9. SECTION TRANSITIONS (0ms Lag Smooth Fade-in) ================= */
.section-enter-active {
  animation: sectionFluidEntrance 0.12s ease-out forwards;
  will-change: opacity;
}

@keyframes sectionFluidEntrance {
  0% {
    opacity: 0.88;
  }
  100% {
    opacity: 1;
  }
}

/* ================= 10. SCROLLBAR & UTILITIES ================= */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* ========================================================
   SAVDOSTAT.UZ MODERN AESTHETIC COMPATIBILITY LAYER
   ======================================================== */

.savdostat-nav-container {
  position: relative;
  background: rgba(241, 245, 249, 0.92) !important;
  backdrop-filter: blur(24px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
  border: 1px solid rgba(203, 213, 225, 0.88) !important;
  box-shadow: inset 0 1px 2.5px rgba(15, 23, 42, 0.06), 0 4px 18px -2px rgba(15, 23, 42, 0.04) !important;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap;
  padding: 4px;
  gap: 2px;
}

#liquid-nav-pill,
.savdostat-sliding-pill {
  position: absolute;
  top: 4px;
  left: 4px;
  height: calc(100% - 8px);
  background: linear-gradient(180deg, #FFFFFF 0%, #EFF6FF 100%) !important;
  border: 1px solid rgba(147, 197, 253, 0.85) !important;
  border-radius: 9999px;
  box-shadow: inset 0 1.5px 0.5px rgba(255, 255, 255, 1), 0 2px 8px -1px rgba(37, 99, 235, 0.14) !important;
  transition: left 0.38s cubic-bezier(0.22, 1, 0.36, 1), width 0.38s cubic-bezier(0.22, 1, 0.36, 1), top 0.38s cubic-bezier(0.22, 1, 0.36, 1), height 0.38s cubic-bezier(0.22, 1, 0.36, 1), transform 0.26s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease !important;
  pointer-events: none;
  z-index: 1;
  will-change: left, width, transform;
}

#liquid-nav-pill.pill-gliding {
  transform: scaleX(1.04) scaleY(0.94);
}

.savdostat-nav-btn {
  position: relative;
  z-index: 2;
  padding: 7px 18px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #64748B;
  cursor: pointer;
  transition: color 0.22s cubic-bezier(0.4, 0, 0.2, 1), transform 0.16s cubic-bezier(0.34, 1.56, 0.64, 1);
  user-select: none;
  white-space: nowrap;
  border: none;
  background: transparent !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.savdostat-nav-btn:hover {
  color: #2563EB;
}

.savdostat-nav-btn:active {
  transform: scale(0.95);
}

.savdostat-nav-btn.active {
  color: #2563EB !important;
  font-weight: 800 !important;
}

/* SavdoStat Segmented Mode Switcher ([Kunlik | Oylik]) */
.savdostat-mode-sliding-pill {
  position: absolute;
  top: 4px;
  left: 4px;
  height: calc(100% - 8px);
  width: 66px;
  background: linear-gradient(180deg, #FFFFFF 0%, #E2E8F0 100%);
  border: 1px solid rgba(148, 163, 184, 0.5);
  border-radius: 9999px;
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 1), 0 2px 5px rgba(15, 23, 42, 0.08);
  transition: left 0.34s cubic-bezier(0.22, 1, 0.36, 1), width 0.34s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
  z-index: 1;
}

.savdostat-mode-btn {
  color: #64748B;
  cursor: pointer;
  user-select: none;
}

.savdostat-mode-btn.active {
  color: #0F172A;
  font-weight: 800;
}

/* SavdoStat Bar Chart Columns (0 dan boshlab animatsiya) */
.savdostat-bar-col {
  background: linear-gradient(180deg, #3B82F6 0%, #1D4ED8 100%);
  border-top: 1px solid rgba(147, 197, 253, 0.75);
  box-shadow: 0 4px 12px -2px rgba(37, 99, 235, 0.22);
  transition: height 0.95s cubic-bezier(0.22, 1, 0.36, 1), background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  will-change: height;
}

.savdostat-bar-col:hover,
.savdostat-bar-col.active-bar {
  background: linear-gradient(180deg, #60A5FA 0%, #2563EB 100%);
  box-shadow: 0 6px 18px -2px rgba(37, 99, 235, 0.45);
  transform: scaleX(1.06);
}

.savdostat-nav-btn i {
  color: #64748B;
  transition: color 0.2s ease;
}

.savdostat-nav-btn.active i {
  color: #2563EB !important;
}

.savdostat-dock {
  position: fixed;
  left: 12px;
  top: 86px;
  width: 48px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 30px -4px rgba(30, 27, 75, 0.05), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 28px;
  z-index: 35;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0;
  transition: all 0.2s ease;
}

/* Pastki chap burchakdagi ixcham sozlamalar va chiqish bloki (Corner Dock) */
.savdostat-corner-dock {
  position: fixed;
  left: 12px;
  bottom: 16px;
  width: 48px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 8px 24px -4px rgba(30, 27, 75, 0.06), inset 0 1px 1px rgba(255, 255, 255, 1);
  border-radius: 26px;
  z-index: 35;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 0;
  gap: 8px;
  transition: all 0.2s ease;
}

/* Chap dockdagi suzuvchi aktiv doira (SavdoStat Floating Sliding Dock Pill) */
.savdostat-dock-sliding-pill {
  position: absolute;
  left: 6px;
  top: 10px;
  width: 36px;
  height: 36px;
  background: #E2E8F0 !important;
  border-radius: 9999px;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.95), 0 2px 6px -1px rgba(15, 23, 42, 0.08) !important;
  transition: all 0.28s cubic-bezier(0.2, 0.9, 0.25, 1) !important;
  pointer-events: none;
  z-index: 1;
}

@media (max-width: 1024px) {
  .savdostat-dock,
  .savdostat-corner-dock {
    display: none;
  }
}

.savdostat-dock-btn {
  position: relative;
  z-index: 2;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #475569;
  transition: color 0.2s ease;
  cursor: pointer;
  border: none;
  background: transparent !important;
}

.savdostat-dock-btn:hover {
  color: #0F172A;
}

.savdostat-dock-btn.active {
  color: #2563EB !important;
  background: transparent !important;
}

.savdostat-circle-btn {
  width: 42px;
  height: 42px;
  min-width: 42px;
  min-height: 42px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(226, 232, 240, 0.9);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  transition: all 0.15s ease;
  cursor: pointer;
  flex-shrink: 0;
}

/* Accessible touch targets & contrast standards (WCAG 2.1 AA) */
button[onclick^="closeModal"] {
  min-width: 40px;
  min-height: 40px;
}

::placeholder {
  color: #64748B !important;
  opacity: 1 !important;
}

.savdostat-circle-btn:hover {
  background: #ffffff;
  color: #0F172A;
  border-color: #CBD5E1;
  transform: translateY(-1px);
}

.savdostat-pill-input {
  border-radius: 9999px !important;
  background: rgba(241, 245, 249, 0.85) !important;
  border: 1px solid rgba(226, 232, 240, 0.8) !important;
  font-size: 12.5px !important;
  font-weight: 500 !important;
  color: #1E293B !important;
  padding-left: 36px !important;
  padding-right: 16px !important;
  padding-top: 8px !important;
  padding-bottom: 8px !important;
  transition: all 0.16s ease !important;
}

.savdostat-pill-input:focus {
  background: #ffffff !important;
  border-color: #6366F1 !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15) !important;
}

.savdostat-pill-select {
  border-radius: 9999px !important;
  background: rgba(241, 245, 249, 0.85) !important;
  border: 1px solid rgba(226, 232, 240, 0.8) !important;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  color: #1E293B !important;
  padding-left: 16px !important;
  padding-right: 28px !important;
  padding-top: 8px !important;
  padding-bottom: 8px !important;
  cursor: pointer !important;
}

.savdostat-pill-btn-primary {
  border-radius: 9999px !important;
  background: linear-gradient(135deg, #4338CA 0%, #6366F1 100%) !important;
  color: #ffffff !important;
  font-size: 12.5px !important;
  font-weight: 700 !important;
  padding: 8px 20px !important;
  box-shadow: 0 4px 14px -2px rgba(67, 56, 202, 0.35) !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
}

.savdostat-pill-btn-primary:hover {
  background: linear-gradient(135deg, #3730A3 0%, #4F46E5 100%) !important;
  transform: translateY(-1px);
}

.savdostat-pill-btn-primary:active {
  transform: scale(0.96) !important;
}

.savdostat-pill-btn-secondary {
  border-radius: 9999px !important;
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(226, 232, 240, 0.9) !important;
  color: #334155 !important;
  font-size: 12.5px !important;
  font-weight: 600 !important;
  padding: 8px 18px !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
}

.savdostat-pill-btn-secondary:hover {
  background: #ffffff !important;
  border-color: #CBD5E1 !important;
  color: #0F172A !important;
}

.savdostat-table-card {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: 0 10px 30px -5px rgba(30, 27, 75, 0.04);
  border-radius: 28px;
  overflow: hidden;
}

.savdostat-thead {
  background: rgba(255, 255, 255, 0.6);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.savdostat-th {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #64748B;
  padding: 14px 20px;
}

.savdostat-tr {
  border-bottom: 1px solid rgba(241, 245, 249, 0.9);
  transition: background-color 0.12s ease;
}

.savdostat-tr:hover {
  background-color: rgba(248, 250, 252, 0.75);
}

/* ========================================================
   MOBILE OPTIMIZATIONS & AUTO-ZOOM PREVENTION (HUDDI ILOVADEK)
   ======================================================== */

* {
  -webkit-tap-highlight-color: transparent !important;
  touch-action: manipulation;
}

/* Telefon va planshetlarda maydonlarni bosganda o'z-o'zidan yaqinlashib ketishini (auto-zoom) 100% yo'q qilish */
@media (max-width: 1024px) {
  input, select, textarea, .savdostat-pill-input, .savdostat-pill-select {
    font-size: 16px !important; /* iOS va Android 16px da hech qachon auto-zoom qilmaydi */
    touch-action: manipulation !important;
  }

  html, body {
    touch-action: manipulation !important;
    -webkit-text-size-adjust: 100% !important;
    text-size-adjust: 100% !important;
    overscroll-behavior-y: none !important;
    user-select: none;
    -webkit-user-select: none;
  }

  input, textarea {
    user-select: text !important;
    -webkit-user-select: text !important;
  }

  .glass-modal-content {
    max-height: 90vh;
    overflow-y: auto;
  }
}

/* Telefon uchun suzuvchi pastki navigatsiya (Faqat mobil ekranlarda ko'rinadi, notebook/desktop/macbookda MUTLAQO ko'rinmaydi) */
#mobile-bottom-nav {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

@media (min-width: 769px) {
  #mobile-bottom-nav {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
    opacity: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
  }
}

@media (max-width: 768px) {
  #mobile-bottom-nav {
    position: fixed;
    bottom: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    left: 12px;
    right: 12px;
    max-width: 440px;
    margin: 0 auto;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 10px 30px -4px rgba(15, 23, 42, 0.12), inset 0 1px 1px rgba(255, 255, 255, 1);
    padding: 6px 4px;
    z-index: 50;
    display: flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
    justify-content: space-around;
    align-items: center;
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.22s ease;
    transform: translateZ(0);
    will-change: transform, opacity;
  }

  #mobile-bottom-nav.nav-hidden {
    transform: translateY(130%) translateZ(0) !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  /* Mobil sensor tezkorligi (300ms kechikishni va qotishni yo'qotish) */
  button, a, input, select, [onclick] {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  /* GPU apparat tezlatgichi (Smooth 60fps scrolling) */
  .group-matrix-card, .savdostat-circle-btn {
    transform: translateZ(0);
  }
}

.mobile-nav-btn {
  color: #64748B;
  transition: all 0.2s cubic-bezier(0.2, 0.9, 0.25, 1);
  cursor: pointer;
  border: none;
  background: transparent;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5px 3px;
  border-radius: 20px;
  user-select: none;
  outline: none;
  position: relative;
}

.mobile-nav-btn.active {
  color: #2563EB !important;
}

.mobile-nav-btn.active i {
  color: #2563EB !important;
  transform: translateY(-1.5px) scale(1.1);
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.mobile-nav-btn.active span {
  font-weight: 800 !important;
  color: #2563EB !important;
}

.mobile-nav-btn:active {
  transform: scale(0.92);
}

/* ================= MOBILE IOS GROUPED SETTINGS (IMAGE 0 REFERENCE) ================= */
.mobile-settings-section-title {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94A3B8;
  margin-bottom: 6px;
  padding-left: 6px;
}

.mobile-settings-group {
  background: #FFFFFF;
  border-radius: 20px;
  border: 1px solid #E2E8F0;
  box-shadow: 0 2px 10px -2px rgba(15, 23, 42, 0.04);
  overflow: hidden;
  margin-bottom: 16px;
}

.mobile-settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 15px;
  cursor: pointer;
  transition: background-color 0.15s ease;
  user-select: none;
  border-bottom: 1px solid #F1F5F9;
}

.mobile-settings-row:last-child {
  border-bottom: none;
}

.mobile-settings-row:active {
  background-color: #F8FAFC;
}

.mobile-settings-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  margin-right: 12px;
  flex-shrink: 0;
}

/* Telegram WebApp Specific Enhancements */
body.telegram-webapp {
  padding-top: env(safe-area-inset-top);
  padding-bottom: max(75px, calc(env(safe-area-inset-bottom) + 65px));
}

body.telegram-webapp header.glass-bar {
  padding-top: max(8px, env(safe-area-inset-top));
}

/* ================= ANIMATED CHART & NUMBERS ================= */
.chart-animated-path {
  stroke-dasharray: 700;
  stroke-dashoffset: 700;
  animation: drawChartPath 1.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.chart-animated-area {
  opacity: 0;
  animation: fadeInChartArea 1.2s ease 0.3s forwards;
}

.chart-animated-dot {
  opacity: 0;
  transform: scale(0);
  transform-box: fill-box;
  transform-origin: center;
  animation: popInDot 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes drawChartPath {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes fadeInChartArea {
  to {
    opacity: 1;
  }
}

@keyframes popInDot {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.stat-number-animated {
  font-variant-numeric: tabular-nums;
  display: inline-block;
  will-change: contents;
}

/* ========================================================
   PROFILE & NOTIFICATIONS POPOVER STYLES
   ======================================================== */

.profile-popover {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(28px) saturate(190%);
  -webkit-backdrop-filter: blur(28px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, 0.98);
  box-shadow: 0 20px 48px -10px rgba(30, 27, 75, 0.16), 0 4px 12px rgba(30, 27, 75, 0.04);
  border-radius: 26px;
  animation: popoverDrop 0.16s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transform-origin: top right;
  z-index: 60;
}

@keyframes popoverDrop {
  0% {
    opacity: 0;
    transform: scale(0.93) translateY(-8px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.profile-menu-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 16px;
  color: #334155;
  font-weight: 700;
  font-size: 12.5px;
  transition: all 0.14s ease;
  cursor: pointer;
  width: 100%;
  border: none;
  background: transparent;
  text-align: left;
  user-select: none;
}

.profile-menu-row:hover {
  background: rgba(241, 245, 249, 0.95);
  color: #0F172A;
  transform: translateX(2px);
}

.profile-menu-row.danger {
  color: #E11D48;
}

.profile-menu-row.danger:hover {
  background: rgba(254, 242, 242, 0.95);
  color: #BE123C;
}

/* ========================================================
   REFINED CLEAN DESIGN SYSTEM (DASHBOARD, ATTENDANCE & PAYMENTS)
   ======================================================== */

/* 1. KPI Panel Cards (Ixcham & Qimmatbaho) */
.kpi-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 10px 14px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03), 0 4px 12px -2px rgba(15, 23, 42, 0.02);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px -4px rgba(67, 56, 202, 0.08);
  border-color: #CBD5E1;
}

/* 2. Unified Financial & Chart Card */
.unified-finance-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 26px;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 10px 25px -5px rgba(15, 23, 42, 0.03);
}

/* 3. Davomat Jadvali Segmented Tugmalari */
.att-btn-pill {
  padding: 5px 10px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  user-select: none;
}

.att-btn-pill:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.att-btn-pill.active-bor {
  background: #059669 !important;
  color: #FFFFFF !important;
  border-color: #059669 !important;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.25);
}

.att-btn-pill.active-yoq {
  background: #E11D48 !important;
  color: #FFFFFF !important;
  border-color: #E11D48 !important;
  box-shadow: 0 2px 8px rgba(225, 29, 72, 0.25);
}

.att-btn-pill.active-sabab {
  background: #D97706 !important;
  color: #FFFFFF !important;
  border-color: #D97706 !important;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.25);
}

/* 4. To'lovlar Tezkor Filtr Chiplari */
.pay-filter-chip {
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 11.5px;
  font-weight: 700;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #64748B;
  cursor: pointer;
  transition: all 0.16s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.pay-filter-chip:hover {
  border-color: #CBD5E1;
  color: #0F172A;
  background: #F8FAFC;
}

.pay-filter-chip.active {
  background: #0F172A;
  color: #FFFFFF;
  border-color: #0F172A;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.18);
}

.pay-filter-chip.active-qarzdor {
  background: #E11D48 !important;
  color: #FFFFFF !important;
  border-color: #E11D48 !important;
  box-shadow: 0 2px 8px rgba(225, 29, 72, 0.25);
}

.pay-filter-chip.active-qisman {
  background: #D97706 !important;
  color: #FFFFFF !important;
  border-color: #D97706 !important;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.25);
}

.pay-filter-chip.active-tolandi {
  background: #059669 !important;
  color: #FFFFFF !important;
  border-color: #059669 !important;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.25);
}

/* 5. Dashboard List Items */
.dashboard-clean-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: 16px;
  background: #F8FAFC;
  border: 1px solid #F1F5F9;
  transition: all 0.15s ease;
}

.dashboard-clean-row:hover {
  background: #F1F5F9;
  border-color: #E2E8F0;
}

/* ========================================================
   GURUHLAR MATRITSASI CONTAINER VA SAHIFALASH PANELI
   Chap dockdagi Chiqish tugmasidan sal balandda (bottom: 22px) qat'iy fiksirlanadi
   ======================================================== */
.sticky-groups-pagination {
  position: fixed;
  bottom: 18px;
  left: 76px;
  right: 24px;
  max-width: 1720px;
  margin: 0 auto;
  z-index: 30;
}

@media (max-width: 1024px) {
  .sticky-groups-pagination {
    left: 16px;
    right: 16px;
    bottom: 80px; /* Mobil pastki nav menyudan balandda */
  }
}

.has-sticky-pagination {
  padding-bottom: 74px !important;
}

.att-matrix-wrapper {
  padding-bottom: 74px;
}

/* 6. Guruhlar Matritsasi Kartochkalari (Groups Matrix Card - 6 ta sig'adigan ultra-ixcham) */
.group-matrix-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 15px;
  padding: 8px 10px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 4px 12px -2px rgba(15, 23, 42, 0.02);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  min-height: 98px;
}

.group-matrix-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--group-accent, #4338CA);
  border-radius: 22px 22px 0 0;
  opacity: 0.85;
  transition: height 0.2s ease;
}

.group-matrix-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px -6px rgba(67, 56, 202, 0.12), 0 2px 6px rgba(15, 23, 42, 0.04);
  border-color: #CBD5E1;
}

.group-matrix-card:hover::before {
  height: 6px;
}

.group-matrix-card:active {
  transform: scale(0.985);
}

/* Davomat to'liq qilingan guruhlar: cheti yashil va nafis nurlar */
.group-matrix-card.att-done {
  border: 1.5px solid #10B981 !important; /* Yashil ramka cheti */
  background: linear-gradient(180deg, #FFFFFF 0%, rgba(240, 253, 244, 0.45) 100%) !important;
  box-shadow: 0 4px 16px -2px rgba(16, 185, 129, 0.16), 0 1px 3px rgba(16, 185, 129, 0.08) !important;
}

.group-matrix-card.att-done::before {
  background: #10B981 !important;
  height: 4px;
}

.group-matrix-card.att-done:hover {
  border-color: #059669 !important;
  box-shadow: 0 14px 28px -6px rgba(16, 185, 129, 0.22) !important;
}

/* Agar hamma o'quvchi "Yo'q" (kelmagan) bo'lsa: qizil ramka */
.group-matrix-card.att-all-absent {
  border: 1.5px solid #F43F5E !important; /* Qizil ramka cheti */
  background: linear-gradient(180deg, #FFFFFF 0%, rgba(255, 241, 242, 0.5) 100%) !important;
  box-shadow: 0 4px 16px -2px rgba(244, 63, 94, 0.18), 0 1px 3px rgba(244, 63, 94, 0.1) !important;
}

.group-matrix-card.att-all-absent::before {
  background: #F43F5E !important;
  height: 4px;
}

.group-matrix-card.att-all-absent:hover {
  border-color: #E11D48 !important;
  box-shadow: 0 14px 28px -6px rgba(244, 63, 94, 0.25) !important;
}

/* Guruhda kelmaganlar (yo'qlar) ko'p yoki bor bo'lsa: ogohlantiruvchi qizg'ish chet */
.group-matrix-card.att-has-absent {
  border: 1.5px solid #FB7185 !important;
  background: linear-gradient(180deg, #FFFFFF 0%, rgba(255, 241, 242, 0.35) 100%) !important;
  box-shadow: 0 4px 14px -2px rgba(244, 63, 94, 0.14) !important;
}

.group-matrix-card.att-has-absent::before {
  background: #F43F5E !important;
}

/* Davomat qisman boshlangan guruhlar: sarg'ish-olovrang chet */
.group-matrix-card.att-partial {
  border: 1.5px solid #F59E0B !important;
  background: linear-gradient(180deg, #FFFFFF 0%, rgba(254, 243, 199, 0.35) 100%) !important;
  box-shadow: 0 4px 14px -2px rgba(245, 158, 11, 0.12) !important;
}

.group-matrix-card.att-partial::before {
  background: #F59E0B !important;
}

/* =====================================================
   SAVDOSTAT AUTHENTIC LIQUID CANVAS & MINIMAL SPINNER
   ===================================================== */
.savdostat-auth-screen {
  background: radial-gradient(135% 100% at 50% -10%, #D8E5F8 0%, #EDF2F8 45%, #FAF8F5 100%) !important;
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

/* Mobile App-like styling & Aura for Auth screen */
@media (max-width: 768px) {
  .savdostat-auth-screen {
    padding: 1rem;
    background: radial-gradient(circle at 10% 15%, rgba(99, 102, 241, 0.15) 0%, transparent 45%),
                radial-gradient(circle at 90% 85%, rgba(59, 130, 246, 0.15) 0%, transparent 45%),
                linear-gradient(180deg, #F8FAFC 0%, #EEF2F6 100%) !important;
  }
  
  /* App-like typography & touch targets */
  .auth-mobile-card {
    border-radius: 28px !important;
    padding: 1.75rem 1.25rem !important;
    box-shadow: 0 15px 40px -10px rgba(15, 23, 42, 0.08), 0 0 1px rgba(15, 23, 42, 0.12) !important;
  }

  /* Prevent zoom on iOS when tapping inputs */
  .savdostat-auth-screen input {
    font-size: 16px !important;
  }
}

/* Mobile general app-like font smoothing & text wrap fixes */
html, body {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* UI Scale Preset Tugmalari */
.ui-scale-preset-btn {
  cursor: pointer;
  border-width: 1.5px;
  transition: all 0.15s ease-in-out;
}
.ui-scale-preset-btn:hover {
  transform: translateY(-1px);
}
.ui-scale-preset-btn.active {
  border-color: #2563EB !important;
  background-color: #EFF6FF !important;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
}

/* Shaffof yuqori panel (Glass Header) doimiy fiksirlangan / sticky */
.glass-bar {
  position: sticky !important;
  top: 0 !important;
  z-index: 40 !important;
}

/* ========================================================
   APPLE PAY ANIMATED CHECKMARK (OVOZGA MOS AYLANIB CHIQISH)
   ======================================================== */
.apple-pay-svg {
  transform: rotate(-90deg);
}

.apple-pay-circle {
  stroke-dasharray: 202;
  stroke-dashoffset: 202;
  animation: applePayDrawCircle 0.55s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.apple-pay-check {
  transform: rotate(90deg);
  transform-origin: 36px 36px;
  stroke-dasharray: 45;
  stroke-dashoffset: 45;
  animation: applePayDrawCheck 0.35s cubic-bezier(0.65, 0, 0.45, 1) 0.35s forwards;
}

.apple-pay-bounce {
  opacity: 0;
  animation: applePayFadeUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
}

@keyframes applePayDrawCircle {
  0% { stroke-dashoffset: 202; }
  100% { stroke-dashoffset: 0; }
}

@keyframes applePayDrawCheck {
  0% { stroke-dashoffset: 45; }
  100% { stroke-dashoffset: 0; }
}

@keyframes applePayFadeUp {
  0% {
    opacity: 0;
    transform: translateY(8px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Harflar bo'linib, xunuk chiqib qolmasligi uchun */
.no-word-break, .crm-title, h1, h2, h3 {
  word-break: normal;
  overflow-wrap: break-word;
  hyphens: manual;
}

/* ========================================================
   FUTURE DATE LOCKED OVERLAY & VIBRATION (KELAJAK SANA QULFI)
   ======================================================== */
@keyframes shakeLock {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px) rotate(-1deg); }
  40% { transform: translateX(6px) rotate(1deg); }
  60% { transform: translateX(-4px) rotate(-0.5deg); }
  80% { transform: translateX(4px) rotate(0.5deg); }
}

.shake-locked {
  animation: shakeLock 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97) both !important;
}

#att-future-lock-overlay {
  transition: opacity 0.25s ease, backdrop-filter 0.25s ease;
}
#global-request-spinner {
  transition: opacity 0.1s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.1s ease;
  will-change: opacity, transform;
}

#global-request-spinner.active {
  opacity: 1 !important;
  pointer-events: auto !important;
  visibility: visible !important;
  cursor: wait !important;
}

#global-request-spinner.hidden-spinner {
  opacity: 0 !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

/* ========================================================
   MATRITSA VA RO'YXATLAR UCHUN NAFIS TIZILISH ANIMATSIYASI (0.3s - 0.4s STAGGER)
   ======================================================== */
@keyframes cardMatrixPopIn {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.matrix-stagger-card {
  opacity: 0;
  animation: cardMatrixPopIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  will-change: transform, opacity;
}

/* Guruh matritsalari uchun yengil kechikish (staggered delay) */
.matrix-stagger-card:nth-child(1)  { animation-delay: 0.02s; }
.matrix-stagger-card:nth-child(2)  { animation-delay: 0.04s; }
.matrix-stagger-card:nth-child(3)  { animation-delay: 0.06s; }
.matrix-stagger-card:nth-child(4)  { animation-delay: 0.08s; }
.matrix-stagger-card:nth-child(5)  { animation-delay: 0.10s; }
.matrix-stagger-card:nth-child(6)  { animation-delay: 0.12s; }
.matrix-stagger-card:nth-child(7)  { animation-delay: 0.14s; }
.matrix-stagger-card:nth-child(8)  { animation-delay: 0.16s; }
.matrix-stagger-card:nth-child(9)  { animation-delay: 0.18s; }
.matrix-stagger-card:nth-child(10) { animation-delay: 0.20s; }
.matrix-stagger-card:nth-child(11) { animation-delay: 0.22s; }
.matrix-stagger-card:nth-child(12) { animation-delay: 0.24s; }
.matrix-stagger-card:nth-child(13) { animation-delay: 0.26s; }
.matrix-stagger-card:nth-child(14) { animation-delay: 0.28s; }
.matrix-stagger-card:nth-child(15) { animation-delay: 0.30s; }
.matrix-stagger-card:nth-child(16) { animation-delay: 0.32s; }
.matrix-stagger-card:nth-child(17) { animation-delay: 0.34s; }
.matrix-stagger-card:nth-child(18) { animation-delay: 0.36s; }
.matrix-stagger-card:nth-child(n+19) { animation-delay: 0.38s; }

/* 8. Bugungi Davomat Glowing Aura (Bosh Sahifa) */
.glow-card-red {
  border: 1.5px solid #F43F5E !important;
  box-shadow: 0 0 18px rgba(244, 63, 94, 0.35), 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

.glow-card-yellow {
  border: 1.5px solid #F59E0B !important;
  box-shadow: 0 0 18px rgba(245, 158, 11, 0.35), 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

.glow-card-green {
  border: 1.5px solid #10B981 !important;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.22), 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

.glow-card-neutral {
  border: 1px solid #E2E8F0 !important;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04) !important;
}

/* ================= 9. APPLE NATIVE PUSH NOTIFICATION BANNER ================= */
.ios-push-banner {
  background: rgba(255, 255, 255, 0.96) !important;
  backdrop-filter: blur(28px) saturate(190%) !important;
  -webkit-backdrop-filter: blur(28px) saturate(190%) !important;
  border: 1px solid rgba(226, 232, 240, 0.95) !important;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.16),
              0 2px 4px rgba(15, 23, 42, 0.04),
              inset 0 1px 1px rgba(255, 255, 255, 1) !important;
  border-radius: 16px !important;
  animation: iosPushSlideDown 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.22s ease !important;
}

.ios-push-banner.ios-push-banner-leave {
  animation: iosPushSlideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards !important;
}

@keyframes iosPushSlideDown {
  0% {
    opacity: 0;
    transform: translateY(-35px) scale(0.94);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes iosPushSlideUp {
  0% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateY(-35px) scale(0.94);
  }
}

/* ================= 10. NOTIFICATIONS SECTION STYLES ================= */
.notif-filter-chip {
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 11.5px;
  font-weight: 700;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #475569;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  user-select: none;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.notif-filter-chip:hover {
  border-color: #cbd5e1;
  color: #0f172a;
  background: #f8fafc;
}

.notif-filter-chip.active {
  background: #1e1b4b !important;
  border-color: #1e1b4b !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(30, 27, 75, 0.18) !important;
}

.notif-card-solid {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 18px !important;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.02) !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.notif-card-solid:hover {
  border-color: #c7d2fe !important;
  box-shadow: 0 4px 14px rgba(67, 56, 202, 0.08) !important;
  transform: translateY(-1px);
}

/* Custom Slim Scrollbar for Internal Feeds */
.custom-scrollbar::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 9999px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}
.custom-scrollbar {
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 transparent;
}

/* =========================================================
   LOGIN 2-SONIYALI SAKRAB VA AYLANUVCHI LOGO ANIMATSIYASI
   (Balandga sakraydi, aylanadi, nomi chiqadi, keyin yana aylanadi - 2 soniya)
   ========================================================= */
@keyframes logoJumpAndDoubleSpin {
  0% {
    transform: translateY(24px) scale(0.7) rotate(0deg);
    opacity: 0;
  }
  18% {
    /* 1-sakrash: balandga sakrab 180 daraja aylanadi */
    transform: translateY(-38px) scale(1.18) rotate(180deg);
    opacity: 1;
  }
  38% {
    /* Birinchi to'liq 360 aylanish va yumshoq tushish */
    transform: translateY(0px) scale(1.0) rotate(360deg);
  }
  50% {
    /* Kichik qolgan rebound */
    transform: translateY(-8px) scale(1.04) rotate(360deg);
  }
  62% {
    transform: translateY(0px) scale(1.0) rotate(360deg);
  }
  78% {
    /* 2-marta aylanib sakrash: yana yuqoriga va 720 daraja */
    transform: translateY(-22px) scale(1.12) rotate(540deg);
  }
  92% {
    /* Ikkinchi to'liq 720 aylanish bilan joyiga tushadi */
    transform: translateY(0px) scale(1.0) rotate(720deg);
  }
  100% {
    transform: translateY(0px) scale(1.0) rotate(720deg);
    opacity: 1;
  }
}

@keyframes logoTitleReveal {
  0% {
    opacity: 0;
    transform: translateY(12px) scale(0.94);
  }
  38% {
    opacity: 0;
    transform: translateY(12px) scale(0.94);
  }
  60% {
    opacity: 1;
    transform: translateY(-2px) scale(1.02);
  }
  100% {
    opacity: 1;
    transform: translateY(0px) scale(1.0);
  }
}

.splash-logo-animated {
  animation: logoJumpAndDoubleSpin 2.0s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

.splash-title-animated {
  animation: logoTitleReveal 2.0s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

/* Profil rasmi va qulf kartasi sakrab chiqib ketishi */
@keyframes illuCardSpringOut {
  0% {
    transform: scale(1) translateY(0) rotate(0deg);
    opacity: 1;
  }
  45% {
    transform: scale(1.1) translateY(-28px) rotate(180deg);
    opacity: 0.8;
  }
  100% {
    transform: scale(0.6) translateY(-40px) rotate(360deg);
    opacity: 0;
  }
}

.illu-card-spring-out {
  animation: illuCardSpringOut 0.4s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

/* Login kartasida qulf va qalqonning nafis suzuvchan harakati */
@keyframes subtleFloatLock {
  0%, 100% {
    transform: translate(180px, 140px);
  }
  50% {
    transform: translate(180px, 134px);
  }
}

@keyframes subtleFloatShield {
  0%, 100% {
    transform: translate(42px, 110px);
  }
  50% {
    transform: translate(42px, 116px);
  }
}

#auth-lock-elem {
  animation: subtleFloatLock 3.5s ease-in-out infinite;
}

#auth-shield-elem {
  animation: subtleFloatShield 4s ease-in-out infinite;
}








/* ===== Guruh dars kunlari chiplari ===== */
.group-day-chip {
  padding: 9px 0;
  border-radius: 12px;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #64748B;
  font-size: 11.5px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.16s ease;
}
.group-day-chip:hover { border-color: #93C5FD; color: #1E40AF; }
.group-day-chip:active { transform: scale(0.94); }
.group-day-chip.selected {
  background: #2563EB;
  border-color: #2563EB;
  color: #FFFFFF;
  box-shadow: 0 4px 10px -3px rgba(37, 99, 235, 0.45);
}
.lesson-day-pill {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; padding: 1px 5px; border-radius: 6px;
  font-size: 9.5px; font-weight: 800;
  background: #F1F5F9; color: #94A3B8; border: 1px solid #E2E8F0;
}
.lesson-day-pill.on { background: #EFF6FF; color: #2563EB; border-color: #BFDBFE; }
.lesson-day-pill.today { background: #2563EB; color: #fff; border-color: #2563EB; }

/* ===== Modal ochiq bo'lganda orqa fon scroll bo'lmaydi ===== */
html.modal-scroll-locked,
html.modal-scroll-locked body {
  overflow: hidden !important;
  overscroll-behavior: none;
}
.glass-modal-backdrop {
  overscroll-behavior: contain;
  overflow-y: auto;
}

/* ===== Chap Dock tugmasiga mishka olib borilganda dumaloq so'z yorlig'i (Pill Tooltip) ===== */
.savdostat-dock-btn .dock-hover-pill {
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%) translateX(-6px) scale(0.92);
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;
  padding: 5px 14px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: #0F172A;
  border: 1px solid rgba(203, 213, 225, 0.95);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: -0.01em;
  box-shadow: 0 8px 22px -4px rgba(15, 23, 42, 0.14), 0 2px 6px rgba(37, 99, 235, 0.08);
  transition: opacity 0.18s cubic-bezier(0.22, 1, 0.36, 1), transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 120;
}

.savdostat-dock-btn.active .dock-hover-pill {
  color: #2563EB;
  border-color: rgba(147, 197, 253, 0.95);
}

.savdostat-dock-btn:hover .dock-hover-pill {
  opacity: 1;
  transform: translateY(-50%) translateX(0) scale(1);
}

/* ===== O'zlashtirish (10 ballik tizim) 0..3 baho tugmalari ===== */
.mastery-score-btn {
  min-width: 24px;
  height: 24px;
  border-radius: 7px;
  font-size: 11px;
  font-weight: 800;
  border: 1px solid #E2E8F0;
  background: #F8FAFC;
  color: #64748B;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.14s ease;
  user-select: none;
}
.mastery-score-btn:hover {
  border-color: #93C5FD;
  color: #2563EB;
  background: #EFF6FF;
}
.mastery-score-btn:active {
  transform: scale(0.92);
}
.mastery-score-btn.active-0 {
  background: #FEE2E2;
  border-color: #FCA5A5;
  color: #E11D48;
}
.mastery-score-btn.active-1 {
  background: #FEF3C7;
  border-color: #FCD34D;
  color: #D97706;
}
.mastery-score-btn.active-2 {
  background: #DBEAFE;
  border-color: #93C5FD;
  color: #2563EB;
}
.mastery-score-btn.active-3 {
  background: #10B981;
  border-color: #059669;
  color: #FFFFFF;
  box-shadow: 0 3px 8px -2px rgba(16, 185, 129, 0.45);
}


