@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root {
  --banner-bg: #3f4cff;
  --banner-text-muted: rgba(255, 255, 255, 0.7);
  --banner-border-light: rgba(255, 255, 255, 0.15);
  --primary: #4f46e5;
  --primary-light: #6366f1;
  --primary-glow: rgba(79, 70, 229, 0.15);
  --surface: #ffffff;
  --surface-elevated: #f8fafc;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --border: rgba(0, 0, 0, 0.06);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 20px;
  --radius-xl: 24px;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.08);
  --shadow-glow: 0 0 30px rgba(79, 70, 229, 0.12);
}

html {
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

body {
  background: var(--surface-elevated);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text-primary);
  line-height: 1.6;
  padding-top: 88px;
  transition: background 0.4s ease, color 0.4s ease;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.dark-mode {
  --surface: #1e293b;
  --surface-elevated: #0f172a;
  --text-primary: #f1f5f9;
  --text-secondary: #cbd5e1;
  /* #64748b juda to'q edi — to'q fon ustida ko'rinmasdi.
     #94a3b8 ga ko'tarildi (WCAG AA kontrast). */
  --text-muted: #94a3b8;
  --border: rgba(255, 255, 255, 0.06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.3);
  background: var(--surface-elevated);
  color: var(--text-primary);
}

.glass-header {
  /* SPONSORED kartadek: bir xil fon, blur va chegara */
  background: rgba(255, 255, 255, 0.42);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.04);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 64px;
  z-index: 1000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 5%;
  transition: all 0.3s ease;
}

body.dark-mode .glass-header {
  /* SPONSORED kartadek (tun rejim) */
  background: rgba(30, 41, 59, 0.72);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  backdrop-filter: blur(16px) saturate(1.3);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
}

.logo a {
  text-decoration: none;
  display: flex;
  align-items: center;
}

.logo h1 {
  font-size: 1.8rem;
  font-weight: 800;
  /* "Lingofy" va welcome banner bir xil ko'k-binafsha.
     --banner-bg o'zgaruvchisidan foydalaniladi — shuning uchun
     banner rangini o'zgartirsangiz, logo ham bir xil bo'ladi. */
  background: linear-gradient(135deg, #4f52ff 0%, var(--banner-bg) 50%, #3636e8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
  margin: 0;
  padding: 0;
  line-height: 1;
}

/* Dark mode: banner foniga mos, biroz yorqinroq */
body.dark-mode .logo h1 {
  background: linear-gradient(135deg, #6b6dff 0%, #5b5cff 50%, #4f4fff 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
  margin: 0;
  padding: 0;
  align-items: center;
}

.nav-links a {
  text-decoration: none;
  color: #1e293b;
  font-weight: 500;
  font-size: 1.05rem;
  position: relative;
  padding-bottom: 4px;
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

body.dark-mode .nav-links a {
  color: #f1f5f9;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 100%;
  height: 2.5px;
  background: #4f46e5;
  border-radius: 4px;
  transition: transform 0.25s ease;
}

.nav-links a:hover {
  color: #4f46e5;
}

body.dark-mode .nav-links a:hover {
  color: #818cf8;
}

.nav-links a:hover::after {
  transform: translateX(-50%) scaleX(1);
}

.nav-icon {
  width: 18px;
  height: 18px;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(15%) sepia(8%) saturate(0%) hue-rotate(0deg) brightness(95%) contrast(85%);
  transition: filter 0.2s;
}

body.dark-mode .nav-icon {
  filter: brightness(0) saturate(100%) invert(95%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(100%) contrast(90%);
}

.nav-links a:hover .nav-icon {
  filter: brightness(0) saturate(100%) invert(30%) sepia(80%) saturate(2000%) hue-rotate(220deg) brightness(95%) contrast(90%);
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  width: 260px;
  background: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  padding: 8px;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  z-index: 100;
}

body.dark-mode .dropdown-menu {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.dropdown.active .dropdown-menu {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  color: #1e293b;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 10px;
  transition: background 0.15s, color 0.15s;
}

body.dark-mode .dropdown-item {
  color: #f1f5f9;
}

.dropdown-item:hover {
  background: rgba(79, 70, 229, 0.08);
  color: #4f46e5;
}

.part-badge {
  background: #1e3a8a;
  color: #fff;
  font-size: 0.65rem;
  font-weight: bold;
  padding: 3px 8px;
  border-radius: 5px;
  text-transform: uppercase;
  min-width: 42px;
  text-align: center;
}

.part-badge.mock {
  background: #ea580c;
}

.dropdown-item.mock-item:hover {
  background: rgba(234, 88, 12, 0.08);
  color: #ea580c;
}

.dropdown-divider {
  height: 1px;
  background: rgba(0, 0, 0, 0.06);
  margin: 6px 4px;
}

body.dark-mode .dropdown-divider {
  background: rgba(255, 255, 255, 0.06);
}

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

.language-switcher {
  display: flex;
  gap: 2px;
  background: rgba(0, 0, 0, 0.04);
  border-radius: 10px;
  padding: 3px;
}

body.dark-mode .language-switcher {
  background: rgba(255, 255, 255, 0.06);
}

.lang-btn {
  padding: 4px 12px;
  border: none;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  color: #64748b;
  transition: all 0.3s ease;
}

body.dark-mode .lang-btn {
  color: #cbd5e1;
}

.lang-btn.active {
  background: #4f46e5;
  color: white;
}

.lang-btn:hover:not(.active) {
  background: rgba(0, 0, 0, 0.04);
}

body.dark-mode .lang-btn:hover:not(.active) {
  background: rgba(255, 255, 255, 0.06);
}

.theme-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
}

.toggle-switch-small {
  position: relative;
  width: 36px;
  height: 20px;
  cursor: pointer;
}

.toggle-switch-small input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider-small {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #cbd5e1;
  border-radius: 20px;
  transition: all 0.3s ease;
}

body.dark-mode .toggle-slider-small {
  background: #475569;
}

.toggle-slider-small::before {
  content: '';
  position: absolute;
  height: 16px;
  width: 16px;
  left: 2px;
  bottom: 2px;
  background: white;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.toggle-switch-small input:checked + .toggle-slider-small {
  background: #4f46e5;
}

.toggle-switch-small input:checked + .toggle-slider-small::before {
  transform: translateX(16px);
}

.theme-icon {
  font-size: 0.85rem;
  color: #64748b;
}

body.dark-mode .theme-icon {
  color: #94a3b8;
}

.profile-container {
  position: relative;
  cursor: pointer;
}

.profile-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 1.1rem;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 2px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 2px 10px rgba(79, 70, 229, 0.2);
}

.profile-avatar:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 20px rgba(79, 70, 229, 0.3);
}

.profile-avatar.active {
  transform: scale(1.05);
  box-shadow: 0 4px 20px rgba(79, 70, 229, 0.3);
}

.profile-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  width: 260px;
  background: rgba(255, 255, 255, 0.98);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  padding: 12px;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transform: translateY(-10px) scale(0.95);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  z-index: 100;
}

body.dark-mode .profile-dropdown {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.profile-dropdown.open {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.profile-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  margin-bottom: 8px;
}

body.dark-mode .profile-info {
  border-color: rgba(255, 255, 255, 0.06);
}

.profile-info-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 1rem;
}

.profile-info-text {
  flex: 1;
}

.profile-info-text .name {
  font-weight: 600;
  font-size: 0.95rem;
  color: #1e293b;
}

body.dark-mode .profile-info-text .name {
  color: #f1f5f9;
}

.profile-info-text .email {
  font-size: 0.8rem;
  color: #64748b;
}

body.dark-mode .profile-info-text .email {
  color: #cbd5e1;
}

.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  color: #1e293b;
  text-decoration: none;
  font-size: 0.9rem;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}

body.dark-mode .profile-menu-item {
  color: #f1f5f9;
}

.profile-menu-item:hover {
  background: rgba(79, 70, 229, 0.08);
  color: #4f46e5;
}

.profile-menu-item .icon {
  font-size: 1.1rem;
  width: 24px;
}

.profile-divider {
  height: 1px;
  background: rgba(0, 0, 0, 0.06);
  margin: 6px 4px;
}

body.dark-mode .profile-divider {
  background: rgba(255, 255, 255, 0.06);
}

.main-content {
  max-width: 1200px;
  margin: 0 auto 40px auto;
  padding: 0 20px;
}


.welcome-banner {
  background: var(--banner-bg);
  color: #ffffff;
  border-radius: 20px;
  /* Tashqariga chiqib qoladigan belgilar (> va h.k.) kirmasin */
  overflow: hidden;
  position: relative;
  padding: 32px 36px;
  display: flex;
  align-items: stretch;
  gap: 36px;
  box-shadow: 0 10px 25px rgba(27, 54, 93, 0.2);
  margin-top: 10px;
  margin-bottom: 30px;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.banner-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.banner-divider {
  width: 1px;
  background-color: var(--banner-border-light);
  margin: 4px 0;
}

.banner-label {
  overflow: hidden;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: var(--banner-text-muted);
  text-transform: uppercase;
  margin-bottom: 14px;
  display: block;
}

.banner-media-item {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.banner-icon-box {
  width: 52px;
  height: 52px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #ffffff;
  flex-shrink: 0;
}

.banner-info h4 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 4px 0;
}

.banner-info p {
  font-size: 0.82rem;
  color: var(--banner-text-muted);
  margin: 0;
  line-height: 1.35;
}

.banner-progress-section {
  margin-bottom: 20px;
}

.banner-progress-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--banner-text-muted);
  margin-bottom: 8px;
}

.banner-progress-val {
  font-weight: 700;
  color: #ffffff;
}

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

.banner-progress-bar div {
  height: 100%;
  background: #ffffff;
  border-radius: 10px;
}

.banner-action-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 6px 0;
}

.banner-action-desc {
  font-size: 0.85rem;
  color: var(--banner-text-muted);
  margin-bottom: 24px;
  max-width: 90%;
  line-height: 1.4;
}

.banner-action-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.banner-time {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
}

.banner-time i {
  font-size: 1.2rem;
  opacity: 0.9;
}

.time-label {
  display: block;
  font-size: 0.65rem;
  color: var(--banner-text-muted);
}

.time-val {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
}

.banner-btn {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  padding: 10px 22px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  text-decoration: none !important;
  color: #ffffff !important;

  /* Suyuq shisha (Liquid glass) uslubi */
  background: rgba(74, 78, 86, 0.42);
  border: 1.5px solid rgba(255, 255, 255, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -1px 0 rgba(255, 255, 255, 0.12),
    inset 0 0 22px rgba(255, 255, 255, 0.10),
    0 12px 30px rgba(0, 0, 0, 0.32);
  -webkit-backdrop-filter: blur(14px) saturate(1.25) brightness(0.92);
  backdrop-filter: blur(14px) saturate(1.25) brightness(0.92);
  transition: transform 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
  user-select: none;
  -webkit-user-select: none;
}

/* Yuza bo'ylab oquvchi yorug'lik nuri (Specular sheen) */
.banner-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.20) 0%, rgba(255, 255, 255, 0) 35%, rgba(255, 255, 255, 0) 70%, rgba(255, 255, 255, 0.08) 100%);
}

.banner-btn:hover {
  background: rgba(255, 255, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.70),
    inset 0 -1px 0 rgba(255, 255, 255, 0.20),
    inset 0 0 24px rgba(255, 255, 255, 0.18),
    0 14px 34px rgba(0, 0, 0, 0.36);
  transform: translateY(-1px);
  color: #ffffff !important;
}

.banner-btn:active {
  transform: scale(0.97);
  background: rgba(255, 255, 255, 0.28);
}

/* Refraksiya (shisha effekti).
   ESKI: url(#glass) — SVG feTurbulence + feDisplacementMap butun
   sahifa maydonida hisoblanardi va Chrome'da sahifani QOTIRIB
   qoldirardi. Endi faqat arzon blur — kórinish saqlanadi,
   render tez. */
.banner-btn.refract {
  -webkit-backdrop-filter: blur(4px) saturate(1.35) brightness(.95);
  backdrop-filter: blur(4px) saturate(1.35) brightness(.95);
}
/* Qurilma qóllamasa — oddiy blur */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .banner-btn.refract { background: rgba(255, 255, 255, .22); }
}

/* Natijani ko'rish / Testni Boshlash (Oq shaffof suyuq shisha) */
.banner-btn.white {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.38);
  color: #ffffff !important;
}

.banner-btn.white:hover {
  background: rgba(255, 255, 255, 0.26);
  color: #ffffff !important;
}

/* Start Mock Test (Moviy/Indigoli suyuq shisha) */
.banner-btn.primary {
  background: rgba(59, 130, 246, 0.32);
  border-color: rgba(147, 197, 253, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    inset 0 -1px 0 rgba(255, 255, 255, 0.15),
    inset 0 0 22px rgba(59, 130, 246, 0.25),
    0 12px 30px rgba(0, 0, 0, 0.32);
  color: #ffffff !important;
}

.banner-btn.primary:hover {
  background: rgba(59, 130, 246, 0.44);
  color: #ffffff !important;
}

@media (max-width: 820px) {
  .welcome-banner {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    gap: 8px !important;
    padding: 12px 10px !important;
    border-radius: 16px !important;
    margin: 6px 0 14px 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
  
  .banner-divider {
    display: block !important;
    width: 1px !important;
    min-width: 1px !important;
    max-width: 1px !important;
    height: auto !important;
    align-self: stretch !important;
    margin: 0 !important;
    background: rgba(255, 255, 255, 0.18) !important;
    flex-shrink: 0 !important;
  }
}

.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 20px;
  animation: fadeInUp 0.6s ease;
}

body.dark-mode .section-title {
  color: #f1f5f9;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(168px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
  animation: fadeInUp 0.5s ease;
}

.flip-card {
  background-color: transparent;
  height: 248px;          /* biroz uzaytirildi (200px edi) */
  perspective: 1000px;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--border);
  background: var(--surface);
}

body.dark-mode .flip-card-front,
body.dark-mode .flip-card-back {
  background: #1e293b;
  border-color: rgba(255, 255, 255, 0.08);
}

.flip-card-front {
  background-color: var(--surface);
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transform: rotateY(0deg);
}

body.dark-mode .flip-card-front {
  color: #f1f5f9;
}

.card-icon-container {
  width: 58px;
  height: 58px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-glow);
  color: var(--primary);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.skill-ico {
  font-size: 1.5rem;
  color: var(--primary);
}

.flip-card:hover .card-icon-container {
  transform: scale(1.08);
  background: rgba(79, 70, 229, 0.16);
}

.card-icon {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.flip-card-front h4 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.flip-card-front p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

body.dark-mode .flip-card-front p {
  color: #94a3b8;
}

.card-action {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary);
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.progress-bar {
  background: #f1f5f9;
  height: 6px;
  width: 100%;
  border-radius: 3px;
  overflow: hidden;
}

body.dark-mode .progress-bar {
  background: #334155;
}

.progress {
  background: #4f46e5;
  height: 100%;
  transition: width 1s ease;
}

.flip-card-back {
  background: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(15px);
  backdrop-filter: blur(15px);
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

body.dark-mode .flip-card-back {
  background: rgba(30, 41, 59, 0.95);
}

.flip-card-back h5 {
  font-size: 1rem;
  color: #1e293b;
  margin-bottom: 15px;
  font-weight: 600;
}

body.dark-mode .flip-card-back h5 {
  color: #f1f5f9;
}

.back-buttons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-height: 190px;
  overflow-y: auto;
  padding: 4px;
}

.back-buttons::-webkit-scrollbar {
  width: 4px;
}
.back-buttons::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 4px;
}

body.dark-mode .back-buttons::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
}

.back-btn {
  display: block;
  text-decoration: none;
  background: #1e3a8a;
  color: white;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  transition: background 0.2s, transform 0.15s;
  text-align: center;
}

.back-btn:hover {
  background: #4f46e5;
  transform: scale(1.02);
}

.back-btn.mock {
  background: #ea580c;
}

.back-btn.mock:hover {
  background: #f97316;
}

.ai-assistant-section {
  margin-top: 30px;
  width: 100%;
}

.ai-assistant-card {
  background: #eff2fe; /* Rasmdagi yengil ko'k-binafsha fon */
  border-radius: 18px;
  padding: 14px 28px; /* Ixcham balandlik (Height mini) */
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid rgba(108, 92, 231, 0.12);
  position: relative;
  overflow: hidden;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Chap kontent (Robot + Yozuv) */
.ai-assistant-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Robot rasmi sig'adigan joy */
.ai-robot-wrapper {
  width: 75px;
  height: 65px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ai-robot-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Matnlar */
.ai-info h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 4px 0;
}

.ai-info p {
  font-size: 0.82rem;
  color: #64748b;
  margin: 0;
  line-height: 1.3;
}

/* O'ng tarafdagi Outlined Tugma */
.ai-chat-btn {
  background: #ffffff;
  color: #4f46e5;
  border: 1.5px solid #6366f1;
  padding: 10px 22px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.ai-chat-btn i {
  font-size: 1rem;
}

.ai-chat-btn:hover {
  background: #4f46e5;
  color: #ffffff;
  border-color: #4f46e5;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.15);
}

/* Dark Mode Moslashuvi */
body.dark-mode .ai-assistant-card {
  background: #1e293b;
  border-color: rgba(255, 255, 255, 0.08);
}

body.dark-mode .ai-info h3 {
  color: #f8fafc;
}

body.dark-mode .ai-info p {
  color: #94a3b8;
}

body.dark-mode .ai-chat-btn {
  background: #0f172a;
  color: #818cf8;
  border-color: #6366f1;
}

body.dark-mode .ai-chat-btn:hover {
  background: #6366f1;
  color: #ffffff;
}

/* Mobil qurilmalar uchun */
@media (max-width: 650px) {
  .ai-assistant-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 18px 20px;
  }

  .ai-chat-btn {
    width: 100%;
    justify-content: center;
  }
}
.tests-section {
  max-width: 1200px;
  margin: 40px auto;
  /* glass.md: yon bo'shlig'i yuqoridagi skill kartalariga
     moslashishi kerak. Avval 20px edi — chiziq mos kelmasdi. */
  padding: 0;
}

.tests-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

.tests-grid {
  display: grid;
  /* qator-qator joylashish — 1fr emas, kenglik avtomatik */
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
}

.test-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px 22px 22px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-sm);
}

body.dark-mode .test-card {
  background: rgba(30, 41, 59, 0.7);
  border-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.test-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.08);
  border-color: rgba(79, 70, 229, 0.25);
}

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

.test-date {
  font-size: 0.8rem;
  font-weight: 600;
  color: #1e293b;
}

body.dark-mode .test-date {
  color: #f1f5f9;
}

.test-badge {
  font-size: 0.6rem;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.test-badge.academic {
  background: rgba(79, 70, 229, 0.1);
  color: #4f46e5;
}

body.dark-mode .test-badge.academic {
  background: rgba(79, 70, 229, 0.2);
}

.test-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 10px 0;
}

body.dark-mode .test-title {
  color: #f1f5f9;
}

.test-meta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: #94a3b8;
  margin-bottom: 12px;
}

body.dark-mode .test-meta {
  color: #94a3b8;
}

.test-meta i {
  margin-right: 2px;
}

.test-status {
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 10px;
  font-size: 0.7rem;
}

.test-status.completed {
  background: rgba(34, 197, 94, 0.1);
  color: #22c55e;
}

.test-status.in-progress {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
}

.test-status.pending {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
}

.test-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.test-progress-bar {
  flex: 1;
  height: 4px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

body.dark-mode .test-progress-bar {
  background: #334155;
}

.test-progress-bar div {
  height: 100%;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  border-radius: 4px;
  transition: width 1s ease;
}

.test-progress-text {
  font-size: 0.75rem;
  font-weight: 700;
  color: #4f46e5;
  min-width: 32px;
  text-align: right;
}

.test-btn {
  width: 100%;
  padding: 10px 0;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(79, 70, 229, 0.08);
  color: #4f46e5;
}

body.dark-mode .test-btn {
  background: rgba(79, 70, 229, 0.15);
}

.test-btn:hover {
  background: #4f46e5;
  color: white;
  transform: scale(1.01);
}

.test-btn:active {
  transform: scale(0.97);
}
footer {
  max-width: 1200px;
  margin: 40px auto 0 auto;
  padding: 0 20px 30px 20px;
}

.ads {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 40px;
}

.ads-card1,
.ads-card2 {
  background: rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 24px;
  padding: 28px 30px;
  min-height: 180px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

body.dark-mode .ads-card1,
body.dark-mode .ads-card2 {
  background: rgba(30, 41, 59, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.ads-card1::before,
.ads-card2::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.4) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.ads-card1:hover::before,
.ads-card2:hover::before {
  opacity: 1;
}

.ads-card1::after,
.ads-card2::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  transform: skewX(-25deg);
  animation: shimmer 4s ease-in-out infinite;
  pointer-events: none;
}

body.dark-mode .ads-card1 {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.1), rgba(251, 191, 36, 0.02));
  border-color: rgba(251, 191, 36, 0.1);
}

.ads-card2 {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.25), rgba(96, 165, 250, 0.08));
  border-color: rgba(96, 165, 250, 0.2);
}

body.dark-mode .ads-card2 {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.1), rgba(96, 165, 250, 0.02));
  border-color: rgba(96, 165, 250, 0.1);
}

.ads-card1:hover,
.ads-card2:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
  border-color: rgba(255, 255, 255, 0.5);
}

.ads-card1 .ad-content,
.ads-card2 .ad-content {
  position: relative;
  z-index: 1;
}

.ads-card1 .ad-badge,
.ads-card2 .ad-badge {
  display: inline-block;
  font-size: 0.6rem;
  font-weight: 700;
  color: #64748b;
  background: rgba(255, 255, 255, 0.5);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 3px 14px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

body.dark-mode .ads-card1 .ad-badge,
body.dark-mode .ads-card2 .ad-badge {
  color: #94a3b8;
  background: rgba(30, 41, 59, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
}

.ads-card1 .ad-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 10px 0 6px 0;
  color: #92400e;
}

body.dark-mode .ads-card1 .ad-title {
  color: #fbbf24;
}

.ads-card2 .ad-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 10px 0 6px 0;
  color: #1e40af;
}

body.dark-mode .ads-card2 .ad-title {
  color: #60a5fa;
}

.ads-card1 .ad-desc,
.ads-card2 .ad-desc {
  font-size: 0.88rem;
  color: #475569;
  line-height: 1.6;
  margin-bottom: 14px;
  min-height: 50px;
  font-weight: 450;
}

body.dark-mode .ads-card1 .ad-desc,
body.dark-mode .ads-card2 .ad-desc {
  color: #94a3b8;
}

.ad-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.ads-card1 .ad-discount {
  font-size: 0.9rem;
  font-weight: 700;
  color: #92400e;
  background: rgba(255, 255, 255, 0.4);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 4px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

body.dark-mode .ads-card1 .ad-discount {
  color: #fbbf24;
  background: rgba(30, 41, 59, 0.4);
  border-color: rgba(255, 255, 255, 0.05);
}

.ads-card2 .ad-discount {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1e40af;
  background: rgba(255, 255, 255, 0.4);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 4px 16px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

body.dark-mode .ads-card2 .ad-discount {
  color: #60a5fa;
  background: rgba(30, 41, 59, 0.4);
  border-color: rgba(255, 255, 255, 0.05);
}

.ad-btn {
  padding: 8px 22px;
  border-radius: 14px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.ads-card1 .ad-btn {
  background: rgba(146, 64, 14, 0.15);
  color: #92400e;
}

body.dark-mode .ads-card1 .ad-btn {
  background: rgba(251, 191, 36, 0.15);
  color: #fbbf24;
}

.ads-card1 .ad-btn:hover {
  background: rgba(146, 64, 14, 0.25);
  transform: scale(1.05);
}

.ads-card2 .ad-btn {
  background: rgba(30, 64, 175, 0.15);
  color: #1e40af;
}

body.dark-mode .ads-card2 .ad-btn {
  background: rgba(96, 165, 250, 0.15);
  color: #60a5fa;
}

.ads-card2 .ad-btn:hover {
  background: rgba(30, 64, 175, 0.25);
  transform: scale(1.05);
}

.news {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 30px;
}

.news1,
.news2 {
  background: rgba(255, 255, 255, 0.42);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 24px;
  padding: 24px 28px;
  min-height: 160px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.04);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  gap: 16px;
  align-items: flex-start;
  position: relative;
  overflow: hidden;
}

body.dark-mode .news1,
body.dark-mode .news2 {
  background: rgba(30, 41, 59, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.news1::before,
.news2::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.3) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.news1:hover::before,
.news2:hover::before {
  opacity: 1;
}

.news1::after,
.news2::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 40%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: skewX(-25deg);
  animation: shimmerNews 5s ease-in-out infinite;
  pointer-events: none;
}

.news2::after {
  animation-delay: 2.5s;
}

.news1:hover,
.news2:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.06);
  border-color: rgba(255, 255, 255, 0.4);
}

.news1 {
  background: linear-gradient(135deg, rgba(79, 70, 229, 0.12), rgba(79, 70, 229, 0.04));
  border-color: rgba(79, 70, 229, 0.15);
}

body.dark-mode .news1 {
  background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(79, 70, 229, 0.02));
  border-color: rgba(79, 70, 229, 0.1);
}

.news2 {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.12), rgba(34, 197, 94, 0.04));
  border-color: rgba(34, 197, 94, 0.15);
}

body.dark-mode .news2 {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.1), rgba(34, 197, 94, 0.02));
  border-color: rgba(34, 197, 94, 0.1);
}

.news-icon {
  font-size: 1.8rem;
  min-width: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.2);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-radius: 16px;
  padding: 8px;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #1e293b;
}

body.dark-mode .news-icon {
  color: #f1f5f9;
  background: rgba(30, 41, 59, 0.3);
  border-color: rgba(255, 255, 255, 0.05);
}

.news-content {
  flex: 1;
}

.news-title {
  font-weight: 700;
  font-size: 1rem;
  color: #1e293b;
  margin-bottom: 4px;
}

body.dark-mode .news-title {
  color: #f1f5f9;
}

.news-desc {
  font-size: 0.85rem;
  color: #475569;
  line-height: 1.6;
  margin-bottom: 10px;
  min-height: 40px;
}

body.dark-mode .news-desc {
  color: #94a3b8;
}

.news-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.news-date {
  font-size: 0.7rem;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.2);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 2px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .news-date {
  color: #94a3b8;
  background: rgba(30, 41, 59, 0.3);
  border-color: rgba(255, 255, 255, 0.05);
}

.read-more {
  font-size: 0.8rem;
  font-weight: 600;
  color: #4f46e5;
  text-decoration: none;
  transition: color 0.3s ease;
  background: rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 3px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .read-more {
  color: #818cf8;
  background: rgba(30, 41, 59, 0.3);
  border-color: rgba(255, 255, 255, 0.05);
}

.read-more:hover {
  color: #1e293b;
  background: rgba(255, 255, 255, 0.25);
}

body.dark-mode .read-more:hover {
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.1);
}

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

body.dark-mode .footer-bottom {
  border-color: rgba(255, 255, 255, 0.05);
}

.footer-bottom p {
  font-size: 0.85rem;
  color: #94a3b8;
}

.footer-bottom .footer-links {
  display: flex;
  gap: 20px;
}

.footer-bottom .footer-links a {
  text-decoration: none;
  color: #94a3b8;
  font-size: 0.85rem;
  transition: color 0.3s ease;
  background: rgba(255, 255, 255, 0.05);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  padding: 4px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

body.dark-mode .footer-bottom .footer-links a {
  background: rgba(30, 41, 59, 0.3);
  border-color: rgba(255, 255, 255, 0.05);
}

.footer-bottom .footer-links a:hover {
  color: #4f46e5;
  background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .footer-bottom .footer-links a:hover {
  color: #818cf8;
  background: rgba(255, 255, 255, 0.05);
}

.video-lessons-section {
  max-width: 1200px;
  margin: 60px auto;
  padding: 0 20px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 40px;
}

.section-badge {
  display: inline-block;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: white;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
}

.section-title {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  margin: 6px 0 4px 0;
}

body.dark-mode .section-title {
  color: #f1f5f9;
}

.section-subtitle {
  color: #64748b;
  font-size: 0.95rem;
  margin: 0;
}

body.dark-mode .section-subtitle {
  color: #94a3b8;
}

.video-header-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  width: 100%;
}

.video-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.v-tab {
  padding: 8px 18px;
  border-radius: 30px;
  border: 1px solid #e2e8f0;
  background: transparent;
  font-size: 0.85rem;
  font-weight: 500;
  color: #64748b;
  cursor: pointer;
  transition: all 0.3s ease;
}

body.dark-mode .v-tab {
  border-color: #334155;
  color: #94a3b8;
}

.v-tab:hover {
  background: #f1f5f9;
  color: #0f172a;
}

body.dark-mode .v-tab:hover {
  background: #1e293b;
  color: #f1f5f9;
}

.v-tab.active {
  background: #4f46e5;
  color: white;
  border-color: #4f46e5;
}

.video-action-buttons {
  display: flex;
  align-items: center;
  gap: 10px;
}

.video-nav-arrows {
  display: flex;
  gap: 6px;
}

.video-arrow-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid #e2e8f0;
  background: white;
  color: #475569;
  font-size: 0.85rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

body.dark-mode .video-arrow-btn {
  background: #1e293b;
  border-color: #334155;
  color: #cbd5e1;
}

.video-arrow-btn:hover {
  background: #4f46e5;
  border-color: #4f46e5;
  color: white;
  transform: scale(1.05);
}

.btn-toggle-video-view {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 30px;
  border: 1px solid rgba(79, 70, 229, 0.35);
  background: rgba(79, 70, 229, 0.08);
  color: #4f46e5;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
}

body.dark-mode .btn-toggle-video-view {
  background: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.35);
  color: #a5b4fc;
}

.btn-toggle-video-view:hover,
.btn-toggle-video-view.active {
  background: #4f46e5;
  color: white;
  border-color: #4f46e5;
  box-shadow: 0 4px 15px rgba(79, 70, 229, 0.25);
}

.video-slider-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 4px 0 16px;
}

/* 1. Slide Bar Mode (Default Horizontal Scrolling Carousel) */
.video-grid.video-slide-mode {
  display: flex !important;
  flex-direction: row;
  gap: 22px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  padding-bottom: 14px;
  padding-top: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(79, 70, 229, 0.3) transparent;
}

.video-grid.video-slide-mode::-webkit-scrollbar {
  height: 6px;
}
.video-grid.video-slide-mode::-webkit-scrollbar-track {
  background: transparent;
}
.video-grid.video-slide-mode::-webkit-scrollbar-thumb {
  background: rgba(79, 70, 229, 0.25);
  border-radius: 10px;
}
body.dark-mode .video-grid.video-slide-mode::-webkit-scrollbar-thumb {
  background: rgba(99, 102, 241, 0.35);
}

.video-grid.video-slide-mode .video-card {
  flex: 0 0 320px;
  width: 320px;
  max-width: 320px;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

/* 2. Grid Mode ("Hammasini ko'rish" / Blok rejim) */
.video-grid.video-grid-mode {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  overflow-x: visible;
  padding-bottom: 12px;
}

.video-grid.video-grid-mode .video-card {
  width: 100%;
  max-width: 100%;
}

.video-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  width: 100%;
}

body.dark-mode .video-card {
  background: rgba(30, 41, 59, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.video-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
  border-color: rgba(79, 70, 229, 0.3);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  height: 200px;
  min-height: 200px;
  background: #0f172a;
  overflow: hidden;
  flex-shrink: 0;
}

.video-thumb-img,
.movie-thumb-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  z-index: 1;
}

.video-card:hover .video-thumb-img,
.movie-slide:hover .movie-thumb-img {
  transform: scale(1.06);
}

.video-thumbnail::after,
.movie-slide-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05) 0%, rgba(15, 23, 42, 0.65) 100%);
  z-index: 1;
  pointer-events: none;
}

.thumb-gradient {
  display: none !important;
}

.badge-level {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(0, 0, 0, 0.7);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: white;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  z-index: 2;
}

.video-duration {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0, 0, 0, 0.8);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: white;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 0.75rem;
  z-index: 2;
}

.play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: none;
  cursor: pointer;
  z-index: 3;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

body.dark-mode .play-btn {
  background: rgba(30, 41, 59, 0.9);
}

.play-btn svg {
  width: 30px;
  height: 30px;
  margin-left: 4px;
  color: #4f46e5;
}

body.dark-mode .play-btn svg {
  color: #818cf8;
}

.play-btn:hover {
  transform: translate(-50%, -50%) scale(1.1);
  background: white;
  box-shadow: 0 10px 30px rgba(79, 70, 229, 0.3);
}

body.dark-mode .play-btn:hover {
  background: #1e293b;
}

.video-card-body {
  padding: 20px 22px 22px;
}

.video-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.v-category {
  font-size: 0.75rem;
  font-weight: 600;
  color: #4f46e5;
  background: rgba(79, 70, 229, 0.1);
  padding: 4px 12px;
  border-radius: 12px;
}

body.dark-mode .v-category {
  color: #818cf8;
  background: rgba(79, 70, 229, 0.15);
}

.video-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 6px 0;
  line-height: 1.3;
}

body.dark-mode .video-card-title {
  color: #f1f5f9;
}

.video-card-desc {
  font-size: 0.85rem;
  color: #64748b;
  line-height: 1.5;
  margin: 0 0 14px 0;
}

body.dark-mode .video-card-desc {
  color: #94a3b8;
}

.video-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

body.dark-mode .video-card-footer {
  border-color: rgba(255, 255, 255, 0.04);
}

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

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
}

.instructor span {
  font-size: 0.8rem;
  color: #475569;
}

body.dark-mode .instructor span {
  color: #94a3b8;
}

.btn-watch {
  background: #4f46e5;
  color: white;
  border: none;
  padding: 6px 16px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-watch:hover {
  background: #6366f1;
  transform: scale(1.05);
}

.vp-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 99999;
  justify-content: center;
  align-items: center;
}

.vp-modal.active {
  display: flex !important;
}

.vp-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.85);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(12px);
}

.vp-container {
  position: relative;
  width: 95%;
  max-width: 1400px;
  max-height: 90vh;
  background: #ffffff;
  border-radius: 24px;
  overflow-y: auto;
  z-index: 2;
  padding: 30px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  animation: modalSlideUp 0.4s ease;
}

body.dark-mode .vp-container {
  background: #1e293b;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.vp-close-btn {
  position: absolute;
  top: 15px;
  right: 25px;
  font-size: 36px;
  background: none;
  border: none;
  cursor: pointer;
  color: #94a3b8;
  z-index: 10;
  transition: all 0.3s ease;
}

.vp-close-btn:hover {
  color: #1e293b;
  transform: rotate(90deg);
}

body.dark-mode .vp-close-btn:hover {
  color: #f1f5f9;
}

.vp-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 30px;
  margin-top: 10px;
}

.vp-player-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.vp-player-wrapper video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000;
}

.vp-player-wrapper video::-webkit-media-controls {
  background: rgba(0, 0, 0, 0.5);
}

.vp-video-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: #0f172a;
  margin: 18px 0 12px 0;
}

body.dark-mode .vp-video-title {
  color: #f1f5f9;
}

.vp-author-bar {
  padding-bottom: 15px;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 15px;
}

body.dark-mode .vp-author-bar {
  border-color: #334155;
}

.vp-author-bar .instructor .avatar {
  width: 40px;
  height: 40px;
  font-size: 0.85rem;
}

.vp-author-bar h4 { margin: 0; font-size: 0.95rem; }
.vp-author-bar span { font-size: 0.8rem; color: #64748b; }

body.dark-mode .vp-author-bar span {
  color: #94a3b8;
}

.vp-description-box {
  background: #f8fafc;
  padding: 16px 20px;
  border-radius: 12px;
  margin-bottom: 25px;
}

body.dark-mode .vp-description-box {
  background: #0f172a;
}

.vp-description-box h5 {
  margin: 0 0 6px 0;
  font-size: 0.9rem;
  color: #334155;
}

body.dark-mode .vp-description-box h5 {
  color: #94a3b8;
}

.vp-description-box p {
  margin: 0;
  font-size: 0.88rem;
  color: #475569;
  line-height: 1.6;
}

body.dark-mode .vp-description-box p {
  color: #94a3b8;
}

.vp-comments-section h3 {
  font-size: 1.1rem;
  margin-bottom: 15px;
}

.vp-comment-input {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.vp-comment-input input {
  flex: 1;
  padding: 10px 16px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  outline: none;
  font-size: 0.9rem;
}

body.dark-mode .vp-comment-input input {
  background: #0f172a;
  border-color: #334155;
  color: #f1f5f9;
}

.vp-comment-input input:focus {
  border-color: #4f46e5;
}

.vp-comment-input button {
  background: #4f46e5;
  color: white;
  border: none;
  padding: 0 24px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
}

.vp-comment-input button:hover {
  background: #6366f1;
}

.vp-comments-list {
  max-height: 200px;
  overflow-y: auto;
}

.vp-comment-item {
  background: #f1f5f9;
  padding: 10px 16px;
  border-radius: 12px;
  margin-bottom: 8px;
}

body.dark-mode .vp-comment-item {
  background: #0f172a;
}

.vp-comment-item strong {
  color: #0f172a;
  font-size: 0.85rem;
}

body.dark-mode .vp-comment-item strong {
  color: #f1f5f9;
}

.vp-comment-item p {
  margin: 4px 0 0 0;
  color: #475569;
  font-size: 0.85rem;
}

body.dark-mode .vp-comment-item p {
  color: #94a3b8;
}

.vp-sidebar {
  max-height: 80vh;
  overflow-y: auto;
}

.vp-sidebar h3 {
  font-size: 1.1rem;
  margin-bottom: 15px;
  color: #0f172a;
}

body.dark-mode .vp-sidebar h3 {
  color: #f1f5f9;
}

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

.vp-sidebar-item {
  display: flex;
  gap: 14px;
  background: #f8fafc;
  padding: 10px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

body.dark-mode .vp-sidebar-item {
  background: #0f172a;
}

.vp-sidebar-item:hover {
  background: #e0e7ff;
  border-color: #4f46e5;
}

body.dark-mode .vp-sidebar-item:hover {
  background: #1e293b;
  border-color: #818cf8;
}

.vp-sidebar-thumb {
  width: 120px;
  height: 68px;
  border-radius: 10px;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  flex-shrink: 0;
}

.vp-sidebar-info h5 {
  margin: 0 0 4px 0;
  font-size: 0.85rem;
  color: #1e293b;
  line-height: 1.3;
}

body.dark-mode .vp-sidebar-info h5 {
  color: #f1f5f9;
}

.vp-sidebar-info span {
  font-size: 0.75rem;
  color: #64748b;
}

body.dark-mode .vp-sidebar-info span {
  color: #94a3b8;
}

.video-card {
  animation: fadeInUp 0.6s ease forwards;
}

.video-card:nth-child(1) { animation-delay: 0.1s; }
.video-card:nth-child(2) { animation-delay: 0.2s; }
.video-card:nth-child(3) { animation-delay: 0.3s; }

.movies-carousel-section {
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 20px;
}

.carousel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.carousel-controls {
  display: flex;
  gap: 8px;
}

.carousel-prev,
.carousel-next {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid #e2e8f0;
  background: white;
  font-size: 1.4rem;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1e293b;
}

body.dark-mode .carousel-prev,
body.dark-mode .carousel-next {
  background: #1e293b;
  border-color: #334155;
  color: #f1f5f9;
}

.carousel-prev:hover,
.carousel-next:hover {
  background: #4f46e5;
  color: white;
  border-color: #4f46e5;
}

.movies-carousel-wrapper {
  overflow: hidden;
  border-radius: 20px;
  position: relative;
}

.movies-carousel {
  display: flex;
  gap: 20px;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 4px 0;
}

.movie-slide {
  min-width: calc(25% - 15px);
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.42);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 18px;
  overflow: hidden;
  transition: all 0.4s ease;
  cursor: pointer;
}

body.dark-mode .movie-slide {
  background: rgba(30, 41, 59, 0.5);
  border-color: rgba(255, 255, 255, 0.05);
}

.movie-slide:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
  border-color: rgba(79, 70, 229, 0.3);
}

.movie-slide-thumb {
  position: relative;
  padding-bottom: 56.25%;
  background: #0f172a;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.slide-emoji,
.slide-icon {
  display: none;
}

.slide-level {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(0,0,0,0.7);
  color: white;
  padding: 3px 10px;
  border-radius: 10px;
  font-size: 0.65rem;
  font-weight: 600;
  z-index: 2;
}

.slide-duration {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0,0,0,0.8);
  color: white;
  padding: 3px 10px;
  border-radius: 10px;
  font-size: 0.7rem;
  z-index: 2;
}

.slide-subtitle {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background: rgba(79, 70, 229, 0.9);
  color: white;
  padding: 3px 10px;
  border-radius: 10px;
  font-size: 0.6rem;
  font-weight: 600;
  z-index: 2;
}

.slide-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 3;
  transition: all 0.3s ease;
  color: #4f46e5;
}

body.dark-mode .slide-play-btn {
  background: rgba(30, 41, 59, 0.9);
  color: #818cf8;
}

.slide-play-btn:hover {
  transform: translate(-50%, -50%) scale(1.1);
  background: white;
  box-shadow: 0 8px 25px rgba(79,70,229,0.3);
}

body.dark-mode .slide-play-btn:hover {
  background: #1e293b;
}

.movie-slide-info {
  padding: 14px 16px 16px;
}

.movie-slide-info h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 6px 0;
  color: #0f172a;
}

body.dark-mode .movie-slide-info h4 {
  color: #f1f5f9;
}

.slide-meta {
  display: flex;
  gap: 10px;
  font-size: 0.75rem;
  color: #94a3b8;
  flex-wrap: wrap;
}

body.dark-mode .slide-meta {
  color: #94a3b8;
}

.slide-category {
  color: #4f46e5;
  font-weight: 600;
  background: rgba(79,70,229,0.08);
  padding: 0 10px;
  border-radius: 10px;
}

body.dark-mode .slide-category {
  color: #818cf8;
  background: rgba(79,70,229,0.15);
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #cbd5e1;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

body.dark-mode .carousel-dot {
  background: #475569;
}

.carousel-dot.active {
  background: #4f46e5;
  width: 24px;
  border-radius: 4px;
}

.mp-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 99999;
  justify-content: center;
  align-items: center;
}

.mp-modal.active {
  display: flex !important;
}

.mp-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15,23,42,0.85);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.mp-container {
  position: relative;
  width: 95%;
  max-width: 1100px;
  max-height: 90vh;
  background: white;
  border-radius: 24px;
  overflow: hidden;
  z-index: 2;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.25);
  animation: modalSlideUp 0.4s ease;
}

body.dark-mode .mp-container {
  background: #1e293b;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
}

.mp-close-btn {
  position: absolute;
  top: 12px;
  right: 18px;
  font-size: 30px;
  background: none;
  border: none;
  cursor: pointer;
  color: white;
  z-index: 10;
  transition: all 0.3s ease;
  text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.mp-close-btn:hover {
  transform: rotate(90deg);
}

.mp-player-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  background: #000;
}

.mp-player-wrapper iframe,
.mp-player-wrapper video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.mp-info {
  padding: 20px 24px 24px;
}

.mp-info h2 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 0 6px 0;
}

body.dark-mode .mp-info h2 {
  color: #f1f5f9;
}

.mp-info p {
  font-size: 0.9rem;
  color: #64748b;
  margin: 0 0 12px 0;
}

body.dark-mode .mp-info p {
  color: #94a3b8;
}

.mp-words {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.word-tag {
  background: rgba(79,70,229,0.08);
  color: #4f46e5;
  padding: 3px 12px;
  border-radius: 14px;
  font-size: 0.75rem;
  font-weight: 600;
}

body.dark-mode .word-tag {
  background: rgba(79,70,229,0.15);
  color: #818cf8;
}

.faq-section {
  padding: 80px 20px;
  background: linear-gradient(180deg, #f8fafc, #ffffff);
}

body.dark-mode .faq-section {
  background: linear-gradient(180deg, #0f172a, #1e293b);
}

.faq-wrapper {
  max-width: 850px;
  margin: 0 auto;
}

.faq-header {
  text-align: center;
  margin-bottom: 40px;
}

.faq-title {
  font-size: 2rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 10px;
}

body.dark-mode .faq-title {
  color: #f1f5f9;
}

.faq-subtitle {
  font-size: 1rem;
  color: #64748b;
}

body.dark-mode .faq-subtitle {
  color: #94a3b8;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.25s ease;
  box-shadow: 0 4px 14px rgba(0,0,0,0.04);
}

body.dark-mode .faq-item {
  background: #1e293b;
  border-color: #334155;
  box-shadow: 0 4px 14px rgba(0,0,0,0.2);
}

.faq-item:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

body.dark-mode .faq-item:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.faq-question {
  width: 100%;
  padding: 18px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  color: #0f172a;
  text-align: left;
  transition: all 0.25s ease;
}

body.dark-mode .faq-question {
  color: #f1f5f9;
}

.faq-question:hover {
  color: #4f46e5;
}

.faq-icon {
  width: 20px;
  height: 20px;
  position: relative;
  flex-shrink: 0;
}

.faq-icon::before,
.faq-icon::after {
  content: "";
  position: absolute;
  background: #94a3b8;
  transition: all 0.3s ease;
}

body.dark-mode .faq-icon::before,
body.dark-mode .faq-icon::after {
  background: #64748b;
}

.faq-icon::before {
  width: 100%;
  height: 2px;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}

.faq-icon::after {
  width: 2px;
  height: 100%;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: all 0.35s ease;
  padding: 0 22px;
}

.faq-answer p {
  margin: 0;
  padding: 0 0 20px 0;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #64748b;
}

body.dark-mode .faq-answer p {
  color: #94a3b8;
}

.faq-item.active {
  border-color: #4f46e5;
  box-shadow: 0 8px 30px rgba(79,70,229,0.08);
}

.faq-item.active .faq-question {
  color: #4f46e5;
}

.faq-item.active .faq-answer {
  max-height: 300px;
  padding: 0 22px 18px;
}

.faq-item.active .faq-icon::after {
  height: 0;
}

.hash3 {
  margin-bottom: 20px;
  font-size: 1.2rem;
}

body.dark-mode .hash3 {
  color: #f1f5f9;
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

@keyframes shimmer {
  0% { left: -100%; }
  50% { left: 150%; }
  100% { left: 150%; }
}

@keyframes shimmerNews {
  0% { left: -100%; }
  50% { left: 150%; }
  100% { left: 150%; }
}

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

@media (max-width: 1024px) {
  .ads-card1 .ad-desc,
  .ads-card2 .ad-desc { min-height: 40px; }
  .vp-layout { grid-template-columns: 1fr; }
  .vp-sidebar { max-height: 300px; }
  .vp-sidebar-list { flex-direction: row; flex-wrap: wrap; }
  .vp-sidebar-item { flex: 1; min-width: 200px; }
  .movie-slide { min-width: calc(33.33% - 14px); }
  .banner-cards { grid-template-columns: 1fr 1fr; }
}

/* ===== MOBILE PART SELECTION BOTTOM SHEET MODAL ===== */
.parts-sheet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.parts-sheet-overlay.active {
  opacity: 1;
  visibility: visible;
}

.parts-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  max-height: 82vh;
  max-height: 82dvh;
  background: var(--surface);
  border-radius: 24px 24px 0 0;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
  z-index: 2001;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.dark-mode .parts-sheet {
  background: #1e293b;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.parts-sheet.open {
  transform: translateY(0);
}

.parts-sheet-drag {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 10px 0 4px;
}

.sheet-pill {
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.15);
}

body.dark-mode .sheet-pill {
  background: rgba(255, 255, 255, 0.2);
}

.parts-sheet-header {
  padding: 12px 20px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
}

.parts-sheet-info {
  display: flex;
  align-items: center;
  gap: 14px;
}

.parts-sheet-badge-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--primary-glow);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.parts-sheet-info h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0;
  color: var(--text-primary);
}

.parts-sheet-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 2px 0 0;
}

.parts-sheet-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
}

body.dark-mode .parts-sheet-close-btn {
  background: #0f172a;
}

.parts-sheet-close-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
}

.parts-sheet-list {
  flex: 1;
  overflow-y: auto;
  padding: 14px 16px 30px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  -webkit-overflow-scrolling: touch;
}

.sheet-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid var(--border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--text-primary);
  transition: all 0.2s ease;
}

body.dark-mode .sheet-item {
  background: rgba(255, 255, 255, 0.03);
}

.sheet-item:hover,
.sheet-item:active {
  background: var(--primary-glow);
  border-color: rgba(79, 70, 229, 0.3);
  transform: translateX(3px);
}

.sheet-item-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sheet-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 8px;
  background: var(--primary);
  color: white;
  min-width: 44px;
  text-align: center;
}

.sheet-badge.badge-mock {
  background: #ea580c;
}

.sheet-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(79, 70, 229, 0.1);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.sheet-item.danger .sheet-icon-wrap {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.sheet-item-text {
  display: flex;
  flex-direction: column;
}

.sheet-item-title {
  font-size: 0.95rem;
  font-weight: 600;
}

.sheet-item-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.sheet-item-arrow {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.sheet-item.special {
  border-color: rgba(79, 70, 229, 0.35);
  background: rgba(79, 70, 229, 0.04);
}

/* ===== NATIVE MOBILE BOTTOM NAVIGATION BAR ===== */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 62px;
  background: rgba(255, 255, 255, 0.88);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  z-index: 1050;
  justify-content: space-around;
  align-items: center;
  padding: 4px 8px env(safe-area-inset-bottom, 6px);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.05);
}

body.dark-mode .mobile-bottom-nav {
  background: rgba(15, 23, 42, 0.88);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
}

.mob-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  font-family: inherit;
  color: var(--text-muted);
  padding: 4px 0;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.mob-nav-item .mob-nav-icon {
  font-size: 1.15rem;
  margin-bottom: 3px;
  transition: transform 0.2s ease;
}

.mob-nav-item span {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: -0.2px;
}

.mob-nav-item.active {
  color: var(--primary);
}

.mob-nav-item.active .mob-nav-icon {
  transform: translateY(-2px);
}

.mob-nav-item.active::after {
  content: '';
  position: absolute;
  top: 0;
  width: 20px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

@media (max-width: 768px) {
  body {
    padding-top: 64px !important;
    padding-bottom: 74px !important;
    max-width: 100vw;
    overflow-x: hidden;
  }
  
  .glass-header {
    height: 58px;
    padding: 0 16px;
    justify-content: space-between;
    flex-wrap: nowrap;
    gap: 0;
  }
  
  .logo h1 {
    font-size: 1.45rem;
  }
  
  .nav-links {
    display: none !important;
  }
  
  .mobile-bottom-nav {
    display: flex !important;
  }
  
  .header-actions {
    gap: 10px;
  }
  
  .language-switcher {
    padding: 2px 4px;
    font-size: 0.75rem;
  }
  
  .profile-container {
    display: flex !important;
  }

  .profile-avatar {
    width: 36px;
    height: 36px;
    font-size: 0.95rem;
  }

  .main-content {
    padding: 8px 12px;
    max-width: 100%;
    overflow-x: hidden;
  }

  /* Welcome Banner Compact Single Row ("Bir qator") */
  .welcome-banner {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    gap: 8px !important;
    padding: 12px 10px !important;
    border-radius: 16px !important;
    margin: 6px 0 14px 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .banner-col {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    gap: 6px !important;
  }

  .banner-divider {
    display: block !important;
    width: 1px !important;
    min-width: 1px !important;
    max-width: 1px !important;
    height: auto !important;
    align-self: stretch !important;
    margin: 0 !important;
    background: rgba(255, 255, 255, 0.18) !important;
    flex-shrink: 0 !important;
  }

  .banner-label {
    font-size: 0.55rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px !important;
    margin-bottom: 2px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    opacity: 0.85 !important;
  }

  .banner-media-item {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin-bottom: 2px !important;
  }

  .banner-icon-box {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    border-radius: 8px !important;
    font-size: 0.95rem !important;
    flex-shrink: 0 !important;
    background: rgba(255, 255, 255, 0.14) !important;
  }

  .banner-info {
    min-width: 0 !important;
    flex: 1 !important;
  }

  .banner-info h4,
  .banner-action-title {
    font-size: 0.78rem !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    margin: 0 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    color: #ffffff !important;
  }

  .banner-info p,
  .banner-action-desc {
    font-size: 0.64rem !important;
    line-height: 1.25 !important;
    margin: 2px 0 0 0 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    opacity: 0.82 !important;
  }

  .banner-progress-section {
    margin: 2px 0 4px 0 !important;
  }

  .banner-progress-labels {
    font-size: 0.60rem !important;
    margin-bottom: 2px !important;
    display: flex !important;
    justify-content: space-between !important;
  }

  .banner-progress-bar {
    height: 4px !important;
    border-radius: 4px !important;
    background: rgba(255, 255, 255, 0.15) !important;
  }

  .banner-action-footer {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    margin-top: auto !important;
  }

  .banner-time {
    display: none !important;
  }

  .banner-btn {
    width: 100% !important;
    padding: 7px 8px !important;
    font-size: 0.72rem !important;
    font-weight: 600 !important;
    border-radius: 9px !important;
    white-space: nowrap !important;
    text-align: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
  }

  .banner-cards {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .banner-search-box {
    width: 100%;
  }

  /* Skills Grid Mobile Fix - Crisp Cards, No Scrambling */
  .skills-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
    margin: 12px 0 20px 0;
  }

  .flip-card {
    height: auto !important;
    min-height: 195px !important;
    perspective: none !important;
    cursor: pointer;
  }

  .flip-card-inner {
    transform: none !important;
    height: auto !important;
    position: static !important;
  }

  .flip-card:hover .flip-card-inner {
    transform: none !important;
  }

  .flip-card-back {
    display: none !important;
  }

  .flip-card-front {
    position: relative !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 195px !important;
    padding: 16px 14px !important;
    border-radius: 18px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    /* MARKAZGA TEKISHLANDI (chapdan emas) */
    align-items: center !important;
    text-align: center !important;
    background: var(--surface) !important;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid var(--border) !important;
    transform: none !important;
  }

  body.dark-mode .flip-card-front {
    background: #1e293b !important;
  }

  .card-icon-container {
    width: 44px !important;
    height: 44px !important;
    border-radius: 12px !important;
    margin:0 auto 8px !important;      /* ikonkа markazda */
    flex-shrink: 0 !important;
    background: var(--primary-glow) !important;
    color: var(--primary) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .card-icon-container .skill-ico {
    font-size: 1.25rem !important;
    color: var(--primary) !important;
  }

  .flip-card-front h4 {
    font-size: 1rem !important;
    font-weight: 700 !important;
    margin: 0 0 4px 0 !important;
    color: var(--text-primary) !important;
    text-align: center !important;   /* markazda */
  }

  .flip-card-front p {
    font-size: 0.74rem !important;
    line-height: 1.35 !important;
    color: var(--text-secondary) !important;
    margin: 0 0 10px 0 !important;
    text-align: center !important;   /* markazda */
  }

  .progress-bar {
    width: 100% !important;
    height: 4px !important;
    margin-bottom: 10px !important;
  }

  .card-action {
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    color: var(--primary) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    margin-top: auto !important;
    padding: 5px 12px !important;
    background: var(--primary-glow) !important;
    border-radius: 14px !important;
    width: fit-content !important;
  }

  /* Ads and News */
  .ads, .news {
    grid-template-columns: 1fr !important;
    gap: 12px;
    margin: 14px 0;
  }

  .ads-card1, .ads-card2 {
    min-height: auto;
    padding: 16px 18px;
    border-radius: 18px;
  }

  .ads-card1 .ad-title, .ads-card2 .ad-title {
    font-size: 1.05rem;
  }

  .news1, .news2 {
    min-height: auto;
    padding: 16px 18px;
    border-radius: 18px;
    flex-direction: row;
    align-items: center;
    gap: 14px;
  }

  /* Video Section Responsive Controls */
  .video-header-controls {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    width: 100%;
  }

  .video-action-buttons {
    width: 100%;
    justify-content: space-between;
  }

  .btn-toggle-video-view {
    flex: 1;
    justify-content: center;
    font-size: 0.78rem;
    padding: 7px 14px;
  }

  .video-tabs {
    width: 100%;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
    scrollbar-width: none;
  }
  .video-tabs::-webkit-scrollbar {
    display: none;
  }

  .v-tab {
    flex-shrink: 0;
    font-size: 0.8rem;
    padding: 7px 14px;
  }

  /* Video Grid: 1. Slide Mode on Mobile (Horizontal swipe) */
  .video-grid.video-slide-mode {
    gap: 14px !important;
    padding-right: 16px;
    scroll-padding-left: 8px;
  }

  .video-grid.video-slide-mode .video-card {
    flex: 0 0 250px !important;
    width: 250px !important;
    max-width: 250px !important;
    border-radius: 16px;
  }

  .video-grid.video-slide-mode .video-thumbnail {
    height: 140px !important;
    min-height: 140px !important;
  }

  .video-grid.video-slide-mode .video-card-body {
    padding: 12px 14px 14px !important;
  }

  .video-grid.video-slide-mode .video-card-title {
    font-size: 0.9rem !important;
    line-height: 1.3;
  }

  .video-grid.video-slide-mode .video-card-desc {
    font-size: 0.78rem !important;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* Video Grid: 2. "Hammasini ko'rish" Compact 2-Column Grid on Mobile */
  .video-grid.video-grid-mode {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .video-grid.video-grid-mode .video-card {
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 14px !important;
  }

  .video-grid.video-grid-mode .video-thumbnail {
    height: 96px !important;
    min-height: 96px !important;
  }

  .video-grid.video-grid-mode .play-btn {
    width: 32px !important;
    height: 32px !important;
  }

  .video-grid.video-grid-mode .play-btn svg {
    width: 16px !important;
    height: 16px !important;
  }

  .video-grid.video-grid-mode .badge-level {
    top: 6px !important;
    left: 6px !important;
    padding: 2px 6px !important;
    font-size: 0.6rem !important;
    border-radius: 6px !important;
  }

  .video-grid.video-grid-mode .video-duration {
    bottom: 6px !important;
    right: 6px !important;
    padding: 2px 6px !important;
    font-size: 0.6rem !important;
    border-radius: 6px !important;
  }

  .video-grid.video-grid-mode .video-card-body {
    padding: 8px 10px 10px !important;
  }

  .video-grid.video-grid-mode .video-meta {
    margin-bottom: 4px !important;
  }

  .video-grid.video-grid-mode .v-category {
    font-size: 0.62rem !important;
    padding: 2px 6px !important;
    border-radius: 6px !important;
  }

  .video-grid.video-grid-mode .v-rating {
    font-size: 0.65rem !important;
  }

  .video-grid.video-grid-mode .video-card-title {
    font-size: 0.78rem !important;
    line-height: 1.25 !important;
    margin: 0 0 4px 0 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .video-grid.video-grid-mode .video-card-desc {
    display: none !important; /* Hide description in compact grid mode on mobile to show more videos */
  }

  .video-grid.video-grid-mode .video-card-footer {
    padding-top: 6px !important;
  }

  .video-grid.video-grid-mode .avatar {
    width: 20px !important;
    height: 20px !important;
    font-size: 0.6rem !important;
  }

  .video-grid.video-grid-mode .instructor span {
    font-size: 0.65rem !important;
    max-width: 55px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .video-grid.video-grid-mode .btn-watch {
    font-size: 0.65rem !important;
    padding: 3px 7px !important;
    border-radius: 6px !important;
  }

  /* Movies Carousel */
  .movies-carousel-section {
    padding: 16px 0;
    overflow-x: hidden;
  }

  .movies-carousel-wrapper {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 6px 4px 12px;
  }

  .movies-carousel {
    display: flex;
    gap: 14px;
  }

  .movie-slide {
    min-width: 82% !important;
    scroll-snap-align: center;
    border-radius: 16px;
  }

  .carousel-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 0 4px;
  }

  .carousel-controls {
    display: none;
  }

  /* Daily Challenge Tests — skills kartalaridek 2 qator */
  .tests-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  /* 2 ustunga sig'sin — kichraytirilgan */
  .test-card {
    padding: 12px 10px;
    border-radius: 14px;
  }

  .test-card h3,
  .test-card .test-title {
    font-size: 0.82rem !important;
    line-height: 1.3;
  }

  .test-card .test-badge {
    font-size: 0.6rem !important;
    padding: 3px 7px;
  }

  .test-card .test-meta,
  .test-card .test-date {
    font-size: 0.7rem !important;
  }

  /* Toast Notification */
  #toast-container {
    bottom: 74px !important;
    left: 14px !important;
    right: 14px !important;
    max-width: calc(100% - 28px) !important;
  }

  /* Modals */
  .vp-container, .mp-container {
    width: 100% !important;
    height: 94vh !important;
    max-height: 94vh !important;
    border-radius: 20px 20px 0 0 !important;
    margin-top: auto !important;
    padding: 16px !important;
  }

  .vp-layout {
    grid-template-columns: 1fr !important;
  }

  /* Site Footer */
  .site-footer {
    margin-top: 30px;
    padding-bottom: 20px;
  }

  .site-footer .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .skills-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
    margin: 10px 0 16px 0 !important;
  }
  
  .flip-card {
    height: auto !important;
    min-height: 180px !important;
  }

  .flip-card-front {
    min-height: 180px !important;
    padding: 12px 10px !important;
  }

  .card-icon-container {
    width: 38px !important;
    height: 38px !important;
    margin-bottom: 6px !important;
  }

  .card-icon-container .skill-ico {
    font-size: 1.1rem !important;
  }

  .flip-card-front h4 {
    font-size: 0.88rem !important;
    margin-bottom: 2px !important;
  }

  .flip-card-front p {
    font-size: 0.7rem !important;
    line-height: 1.3 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    margin-bottom: 6px !important;
  }

  .card-action {
    font-size: 0.7rem !important;
    padding: 4px 10px !important;
  }
}

/* ===== SITE FOOTER ===== */
.site-footer {
  margin-top: 60px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.site-footer .footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1340px;
  margin: 0 auto;
  padding: 24px 5%;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.site-footer .footer-links {
  display: flex;
  gap: 6px;
}

.site-footer .footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  padding: 4px 12px;
  border-radius: 8px;
  transition: all 0.25s ease;
  font-size: 0.85rem;
}

.site-footer .footer-links a:hover {
  color: var(--primary);
  background: var(--primary-glow);
}

@media (max-width: 768px) {
  .site-footer .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
  .site-footer .footer-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* ===== SECTION TITLE WRAPPER ===== */
.section-title-wrapper {
  text-align: center;
  margin: 40px 0 10px;
  /* glass.md: sarlavha ham kartalar bilan bir chiziqda */
  padding: 0;
}

.section-title-wrapper .section-title {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--primary);
  position: relative;
  display: inline-block;
}

.section-title-wrapper .section-title::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
  margin: 10px auto 0;
}

/* ===== MICRO ANIMATIONS ===== */
@keyframes gentlePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}

.flip-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.test-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(79, 70, 229, 0.2);
}

.ads-card1:hover,
.ads-card2:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.news1:hover,
.news2:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* ===== SELECTION STYLE ===== */
::selection {
  background: rgba(79, 70, 229, 0.2);
  color: var(--text-primary);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

body.dark-mode ::-webkit-scrollbar-thumb {
  background: #334155;
}

/* ==========================================================================
   PROFILE DROPDOWN & 6-DIGIT SECURITY ID BADGE
   ========================================================================== */
.profile-container {
  position: relative;
  display: inline-block;
}

.profile-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(79, 70, 229, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.3);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.profile-avatar:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.5);
  border-color: #6366f1;
}

.profile-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 275px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.18);
  padding: 16px 14px;
  z-index: 9999;
  flex-direction: column;
  gap: 6px;
  animation: dropdownFade 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes dropdownFade {
  from { opacity: 0; transform: translateY(-10px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.profile-dropdown.show {
  display: flex;
}

body.dark-mode .profile-dropdown {
  background: #111827;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  color: #f9fafb;
}

.profile-dropdown-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px 10px;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.25);
  margin-bottom: 6px;
}

.security-label {
  font-size: 0.72rem;
  color: #64748b;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

body.dark-mode .security-label {
  color: #cbd5e1;
}

.profile-security-id-badge {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(217, 119, 6, 0.2));
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #d97706;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 800;
  font-family: monospace;
  letter-spacing: 0.6px;
}

body.dark-mode .profile-security-id-badge {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.5);
}

.profile-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 6px 8px;
}

.profile-info-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  overflow: hidden;
  flex-shrink: 0;
}

.profile-info-text {
  overflow: hidden;
}

.profile-info-text .name {
  font-size: 0.95rem;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: inherit;
}

.profile-info-text .email {
  font-size: 0.76rem;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.dark-mode .profile-info-text .email {
  color: #94a3b8;
}

.profile-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 12px;
  text-decoration: none;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

body.dark-mode .profile-menu-item {
  color: #cbd5e1;
}

.profile-menu-item:hover {
  background: rgba(99, 102, 241, 0.12);
  color: #4f46e5;
  transform: translateX(3px);
}

body.dark-mode .profile-menu-item:hover {
  color: #818cf8;
}

.profile-menu-item .icon {
  width: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-divider {
  height: 1px;
  background: rgba(148, 163, 184, 0.2);
  margin: 6px 0;
}

/* ==========================================================================
   VIDEO PLATFORM MODAL & COMMENTS (SHARP AI AESTHETIC)
   ========================================================================== */
.vp-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, backdrop-filter 0.25s ease;
}

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

.vp-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.78);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.vp-container {
  position: relative;
  z-index: 2;
  width: 95%;
  max-width: 1260px;
  max-height: 92vh;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 0px !important; /* Sharp aesthetic */
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.45);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

body.dark-mode .vp-container {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.75);
}

.vp-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  width: 38px;
  height: 38px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 0px !important; /* Sharp */
  color: #334155;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.vp-close-btn:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
  transform: rotate(90deg);
}

body.dark-mode .vp-close-btn {
  background: #1e293b;
  border-color: #334155;
  color: #e2e8f0;
}

body.dark-mode .vp-close-btn:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #ffffff;
}

.vp-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
  padding: 28px;
}

@media (max-width: 1024px) {
  .vp-layout {
    grid-template-columns: 1fr;
    padding: 20px;
  }
}

.vp-main-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.vp-player-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
  border-radius: 0px !important; /* Sharp */
  overflow: hidden;
  border: 1px solid #1e293b;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.vp-player-wrapper iframe,
.vp-player-wrapper video {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 0px !important;
  display: block;
}

.vp-video-title {
  font-size: 1.45rem;
  font-weight: 800; /* Bold title as requested */
  color: #0f172a;
  margin: 18px 0 10px 0;
  line-height: 1.35;
  letter-spacing: -0.3px;
}

body.dark-mode .vp-video-title {
  color: #f8fafc;
}

.vp-author-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 16px;
}

body.dark-mode .vp-author-bar {
  border-color: #334155;
}

.vp-author-bar .instructor {
  display: flex;
  align-items: center;
  gap: 12px;
}

.vp-author-bar .avatar {
  width: 46px;
  height: 46px;
  border-radius: 0px !important; /* Sharp avatar */
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #ffffff;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.vp-author-bar .avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0px !important;
}

.vp-author-bar h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
  color: #1e293b;
}

body.dark-mode .vp-author-bar h4 {
  color: #f1f5f9;
}

.vp-author-bar span {
  font-size: 0.8rem;
  color: #64748b;
  font-weight: 500;
}

body.dark-mode .vp-author-bar span {
  color: #94a3b8;
}

.vp-meta-badges {
  display: flex;
  align-items: center;
  gap: 8px;
}

.vp-meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 0px !important;
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
}

body.dark-mode .vp-meta-badge {
  background: #1e293b;
  color: #cbd5e1;
  border-color: #334155;
}

.vp-description-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 3px solid #4f46e5;
  border-radius: 0px !important; /* Sharp */
  padding: 14px 18px;
  margin-bottom: 24px;
}

body.dark-mode .vp-description-box {
  background: #1e293b;
  border-color: #334155;
  border-left-color: #6366f1;
}

.vp-description-box h5 {
  font-size: 0.82rem;
  font-weight: 700;
  color: #4f46e5;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 6px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

body.dark-mode .vp-description-box h5 {
  color: #818cf8;
}

.vp-description-box p {
  font-weight: 400 !important; /* Non-bold regular font as requested */
  font-size: 0.94rem;
  color: #475569;
  line-height: 1.6;
  margin: 0;
}

body.dark-mode .vp-description-box p {
  color: #94a3b8;
}

/* Comments Section */
.vp-comments-section {
  border-top: 1px solid #e2e8f0;
  padding-top: 20px;
}

body.dark-mode .vp-comments-section {
  border-color: #334155;
}

.vp-comments-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.vp-comments-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #0f172a;
}

body.dark-mode .vp-comments-header h3 {
  color: #f8fafc;
}

.vp-comment-input {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.vp-comment-input input,
.vp-comment-input textarea {
  flex: 1;
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 0px !important; /* Sharp */
  font-size: 0.92rem;
  font-family: inherit;
  background: #ffffff;
  color: #0f172a;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.vp-comment-input input:focus,
.vp-comment-input textarea:focus {
  border-color: #4f46e5;
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.15);
}

body.dark-mode .vp-comment-input input,
body.dark-mode .vp-comment-input textarea {
  background: #1e293b;
  border-color: #334155;
  color: #f8fafc;
}

.vp-comment-input button {
  padding: 0 20px;
  background: #4f46e5;
  color: #ffffff;
  border: 1px solid #4f46e5;
  border-radius: 0px !important; /* Sharp */
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.vp-comment-input button:hover {
  background: #4338ca;
  border-color: #4338ca;
}

.vp-comments-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 400px;
  overflow-y: auto;
  padding-right: 6px;
}

/* Base comment card */
.vp-comment-item {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0px !important; /* Sharp */
  padding: 14px 16px;
  transition: background 0.2s ease;
}

body.dark-mode .vp-comment-item {
  background: #1e293b;
  border-color: #334155;
}

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

.vp-comment-author {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 0.92rem;
  color: #1e293b;
}

body.dark-mode .vp-comment-author {
  color: #f1f5f9;
}

.vp-comment-avatar {
  width: 28px;
  height: 28px;
  border-radius: 0px !important; /* Sharp */
  background: #4f46e5;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vp-comment-time {
  font-size: 0.75rem;
  color: #94a3b8;
  font-weight: 500;
}

.vp-comment-text {
  font-size: 0.92rem;
  font-weight: 400;
  color: #334155;
  line-height: 1.55;
  margin: 6px 0 8px 0;
  word-break: break-word;
}

body.dark-mode .vp-comment-text {
  color: #cbd5e1;
}

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

.vp-btn-reply {
  background: none;
  border: none;
  color: #4f46e5;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 6px;
  border-radius: 0px !important;
  transition: color 0.2s ease, background 0.2s ease;
}

.vp-btn-reply:hover {
  color: #3730a3;
  background: rgba(79, 70, 229, 0.08);
}

body.dark-mode .vp-btn-reply {
  color: #818cf8;
}

body.dark-mode .vp-btn-reply:hover {
  color: #a5b4fc;
  background: rgba(129, 140, 248, 0.12);
}

/* ==========================================================================
   REPLY INDENTATION: 4 ABZAS (4 TABS / INDENTATION LEVELS = ~48px)
   "reply qilsa 4 abzas qoldirib yozilsin"
   ========================================================================== */
.vp-reply-item {
  margin-left: 48px !important; /* 4 abzas visual indentation */
  border-left: 3px solid #6366f1 !important; /* Distinct visual indentation guide */
  background: rgba(99, 102, 241, 0.04);
  border-top: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
  border-radius: 0px !important;
  padding: 12px 14px;
  margin-top: 8px;
  position: relative;
}

body.dark-mode .vp-reply-item {
  background: rgba(99, 102, 241, 0.08);
  border-top-color: #334155;
  border-right-color: #334155;
  border-bottom-color: #334155;
  border-left-color: #818cf8 !important;
}

.vp-reply-item::before {
  content: '↳';
  position: absolute;
  left: -28px;
  top: 12px;
  color: #6366f1;
  font-size: 1.1rem;
  font-weight: 800;
}

/* Inline reply box */
.vp-inline-reply-box {
  margin-left: 48px;
  margin-top: 8px;
  margin-bottom: 8px;
  display: flex;
  gap: 8px;
  padding: 8px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 0px !important;
}

body.dark-mode .vp-inline-reply-box {
  background: #1e293b;
  border-color: #475569;
}

.vp-inline-reply-box input {
  flex: 1;
  padding: 8px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 0px !important;
  font-size: 0.85rem;
  background: #ffffff;
  color: #0f172a;
}

body.dark-mode .vp-inline-reply-box input {
  background: #0f172a;
  border-color: #334155;
  color: #f8fafc;
}

.vp-inline-reply-box button {
  padding: 0 14px;
  background: #4f46e5;
  color: #ffffff;
  border: none;
  border-radius: 0px !important;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

/* Right Sidebar: Recommendations */
.vp-sidebar {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0px !important; /* Sharp */
  padding: 18px;
  display: flex;
  flex-direction: column;
}

body.dark-mode .vp-sidebar {
  background: #1e293b;
  border-color: #334155;
}

.vp-sidebar h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 14px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #0f172a;
}

body.dark-mode .vp-sidebar h3 {
  color: #f8fafc;
}

.vp-sidebar-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  max-height: 650px;
}

.vp-sidebar-item {
  display: flex;
  gap: 10px;
  padding: 8px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0px !important; /* Sharp */
  cursor: pointer;
  transition: all 0.2s ease;
}

body.dark-mode .vp-sidebar-item {
  background: #0f172a;
  border-color: #334155;
}

.vp-sidebar-item:hover {
  border-color: #4f46e5;
  transform: translateX(4px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.1);
}

.vp-sidebar-thumb {
  width: 90px;
  height: 56px;
  flex-shrink: 0;
  position: relative;
  background: #000;
  overflow: hidden;
  border-radius: 0px !important;
}

.vp-sidebar-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0px !important;
}

.vp-sidebar-thumb .s-duration {
  position: absolute;
  bottom: 2px;
  right: 2px;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 4px;
  border-radius: 0px;
}

.vp-sidebar-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.vp-sidebar-info h5 {
  font-size: 0.85rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 4px 0;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

body.dark-mode .vp-sidebar-info h5 {
  color: #f1f5f9;
}

.vp-sidebar-info span {
  font-size: 0.75rem;
  color: #64748b;
}

body.dark-mode .vp-sidebar-info span {
  color: #94a3b8;
}


/* ═══════════════════════════════════════════════════════════════
   MOBIL NAVBAR — DESKTOPDA YASHIRISH
   .mob-glass-* markup'i faqat @media (max-width:768px) ichida
   uslublangan. Desktopda (>=769px) u uslubsiz qolib, sahifa
   oxirida xom HTML matn sifatida ko'rinardi. Mobil dizayn
   tegilmaydi — faqat desktopda yashiriladi.
   ═══════════════════════════════════════════════════════════════ */
@media (min-width: 769px) {
  .mob-glass-backdrop,
  .mob-glass-nav-wrapper,
  .mob-parts-popup,
  .mob-glass-menu-wrapper {
    display: none !important;
  }
}

/* ── Fullscreen tugmasi (bosh sahifa) ── */
.fullscreen-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
  flex-shrink: 0;
}
.fullscreen-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.25);
}
.fullscreen-btn i { font-size: 15px; }
body:not(.dark-mode) .fullscreen-btn {
  color: #374151;
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.10);
}
body:not(.dark-mode) .fullscreen-btn:hover { background: rgba(0, 0, 0, 0.08); }

@media (max-width: 768px) {
  .fullscreen-btn { display: none; }
}

═══════════════════════════════════════════════
   DICTATIONS (Diktant) — INGICHKA iOS RO'YXATI
   Bitta qatorda ikonka + nom; o'ng burchakda daraja.

   Eski retro CD-pleyer (conic-gradient plastina, 9s aylanma
   animatsiya, drop-shadow) OLIB TASHLANDI: animatsiya har kadrda
   repaint qilardi va sahifani qotib qolishiga olib kelardi.
   Endi faqat transform/box-shadow — GPU uchun eng arzon yo'l.
   ═══════════════════════════════════════════════ */
.dictation-section{
  max-width:1200px;
  margin:24px auto 34px;
  padding:0 20px;
}

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

/* ── ingichka karta ── */
.dict-row{
  display:flex;
  align-items:center;
  gap:12px;
  padding:9px 12px 9px 10px;
  background:var(--surface,#ffffff);
  border:1px solid rgba(15,23,42,.13);
  border-radius:13px;
  box-shadow:0 1px 3px rgba(15,23,42,.06);
  text-decoration:none;
  cursor:pointer;
  -webkit-tap-highlight-color:transparent;
  transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease;
}
.dict-row:hover{
  transform:translateY(-1px);
  border-color:var(--primary);
  box-shadow:0 4px 14px rgba(15,23,42,.10);
}
.dict-row:active{ transform:translateY(0) scale(.995); }
.dict-row:focus-visible{
  outline:none;
  border-color:var(--primary);
  box-shadow:0 0 0 3px rgba(79,70,229,.22);
}

/* ── iOS Diktafon (Voice Memos) ikonkasi — rangli gradient ── */
.dict-ico{
  flex:none;
  display:grid;
  place-items:center;
  width:34px;
  height:34px;
  border-radius:10px;
  background:linear-gradient(160deg,#ff5f57 0%,#ff2d55 52%,#d70063 100%);
  box-shadow:0 2px 6px rgba(255,45,85,.30), inset 0 1px 0 rgba(255,255,255,.34);
}
.dict-ico svg{ width:19px; height:19px; display:block; }

/* ── matn ── */
.dict-body{
  flex:1 1 auto;
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px;
}
.dict-kicker{
  font-size:.58rem;
  font-weight:800;
  line-height:1;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--primary,#4f46e5);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.dict-name{
  font-size:.95rem;
  font-weight:700;
  line-height:1.25;
  color:var(--text-primary,#1e293b);
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

/* ── mitti sariq daraja belgisi (o'ng burchak) ── */
.dict-lvl{
  flex:none;
  margin-left:auto;
  font-size:.6rem;
  font-weight:800;
  line-height:1;
  letter-spacing:.04em;
  padding:4px 7px;
  border-radius:7px;
  background:#facc15;
  color:#422006;
  box-shadow:inset 0 0 0 1px rgba(120,80,0,.16);
}

/* ── bo'sh holat (kinolar bo'limi ham ishlatadi) ── */
.carousel-empty{
  display:flex;flex-direction:column;align-items:center;gap:9px;
  padding:34px 18px;color:#94a3b8;text-align:center;
}
.carousel-empty i{font-size:1.9rem;opacity:.5}
/* `hidden` atributi class qoidasi bilan bekor bo'lmasligi uchun. */
.carousel-empty[hidden]{display:none !important}
.carousel-empty p{font-size:.92rem;font-weight:600}

/* ── to'q rejim ── */
body.dark-mode .dict-row{
  background:var(--surface,#1e293b);
  border-color:rgba(255,255,255,.15);
  box-shadow:0 1px 4px rgba(0,0,0,.34);
}
body.dark-mode .dict-kicker{ color:#a5b4fc; }
body.dark-mode .dict-name{ color:#ffffff; }
body.dark-mode .dict-ico{
  box-shadow:0 2px 7px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.26);
}

/* ── telefon ── */
@media (max-width:560px){
  .dictation-section{ padding:0 14px; }
  .dict-list{ gap:7px; }
  .dict-row{ padding:8px 11px 8px 9px; gap:11px; border-radius:12px; }
  .dict-ico{ width:32px; height:32px; border-radius:9px; }
  .dict-ico svg{ width:18px; height:18px; }
  .dict-kicker{ font-size:.55rem; }
  .dict-name{ font-size:.9rem; }
}

/* ── harakatni kamaytirish ── */
@media (prefers-reduced-motion:reduce){
  .dict-row{ transition:none; }
  .dict-row:hover{ transform:none; }
}

/* =========================================================
   MINI TEST KARTA — faqat sana + sarlavha (2 ustun grid)
   ========================================================= */
.test-card--mini {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.test-card--mini .test-date {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.test-card--mini .test-title {
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text-primary);
  margin: 0;
}

.test-card--mini .test-btn--mini {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 2px;
  padding: 5px 11px;
  border-radius: 10px;
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
  background: var(--primary);
  color: #fff;
  transition: background 0.2s ease, transform 0.2s ease;
}

.test-card--mini .test-btn--mini:hover {
  background: var(--primary-light);
  transform: translateY(-1px);
}

.test-card--mini:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

body.dark-mode .test-card--mini {
  background: var(--surface);
  border-color: var(--border);
}

body.dark-mode .test-card--mini .test-date {
  color: var(--text-muted);
}

/* =========================================================
   KUN REJIMI (Light mode) — header matnlari
   Lingofy + til tugmalari to'q ko'k, faol tugma TESKARI
   ========================================================= */
body:not(.dark-mode) .logo h1 {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 50%, #3730a3 100%);
  -webkit-background-fill-color: transparent;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  -webkit-background-clip: text;
}

/* Kun rejimida mobil glass header ustida ham to'q ko'k */
body:not(.dark-mode) .glass-header .logo h1 {
  background: linear-gradient(135deg, #1e40af 0%, #1d4ed8 50%, #3730a3 100%);
  -webkit-text-fill-color: transparent;
  color: transparent;
  background-clip: text;
  -webkit-background-clip: text;
  text-shadow: none;
}

/* ── Til tugmalari: o'chirmaganlari to'q ko'k ── */
body:not(.dark-mode) .lang-btn {
  color: #1e40af !important;
  background: transparent;
  text-shadow: none;
}

/* ── Faol tugma: OQ fon + to'q ko'k text (teskari) ── */
body:not(.dark-mode) .lang-btn.active {
  color: #1e3a8a !important;
  background: #ffffff !important;
  border: 1px solid rgba(30, 64, 175, 0.35);
  box-shadow:
    0 2px 8px rgba(30, 64, 175, 0.16),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.9);
}

body:not(.dark-mode) .lang-btn:hover:not(.active) {
  color: #1e3a8a !important;
  background: rgba(30, 64, 175, 0.07) !important;
}

/* Switch foni kun rejimida to'q ko'k bo'lsin */
body:not(.dark-mode) .language-switcher {
  background: rgba(30, 64, 175, 0.07) !important;
  border: 1px solid rgba(30, 64, 175, 0.22) !important;
}

/* =========================================================
   KONTENT BO'LIMLARI — bo'sh bo'lsa butunlay yashiriladi
   (sarlavhasi bilan birga). JS: setSectionVisible()
   ========================================================= */
[data-content-section].is-empty {
    display: none !important;
}

/* Bo'sh tavsif maydoni joyni olmasin */
.video-card-desc:empty,
.slide-subtitle:empty { display: none; }

/* ═══════════════════════════════════════════════════════════
   SKILL KARTA — kichraytirilgan (200px)
   CEFR exam kartalari bilan bir xil ixchak ko'rinishi uchun
   ichki matnlar ham kichraytirilgan.
   ═══════════════════════════════════════════════════════════ */
@media (min-width:769px){
  .flip-card .flip-card-front h3,
  .flip-card .skill-title{ font-size:1.02rem !important; }
  .flip-card .flip-card-front p,
  .flip-card .skill-desc{ font-size:.8rem !important; line-height:1.4; }
  .flip-card .skill-icon,
  .flip-card .flip-card-front .icon{ width:52px !important; height:52px !important; font-size:1.3rem !important; }
  .flip-card .flip-card-front{ padding:20px 16px !important; }
  .flip-card .flip-card-back{ padding:20px 16px !important; }
}
/* Mobil uchun balandlik QOIDASI YO'Q — saytning o'z mobil
   qoidasi ishlaydi: .flip-card{ height:auto; min-height:195px }
   Undan kelib chiqib, mobil hech qanday o'zgartirilmaydi. */

/* ═══════════════════════════════════════════════════════════
   "Last CEFR Reading exam" SARLAVHASI
   1.5rem da 2 qatorga bo'linib ketayotdi — biroz kichraytirildi
   va bir qatorga majburlanadi.
   ═══════════════════════════════════════════════════════════ */
.tests-header .section-title{
  font-size:1.15rem !important;
  line-height:1.25;
  white-space:nowrap;
  margin-bottom:0 !important;
}
.tests-header{ display:flex; align-items:center; flex-wrap:wrap; gap:10px; }
@media (max-width:480px){
  .tests-header .section-title{ font-size:1rem !important; }
}

/* ═══════════════════════════════════════════════════════════
   SKILL KARTA (200px) — ikonka va tugma to'g'rilandi
   Eslatma: ikonka konteyneri .card-icon-container (58px edi),
   ichidagi belgi .skill-ico (1.5rem edi).
   ═══════════════════════════════════════════════════════════ */
@media (min-width:769px){
  .flip-card .card-icon-container{
    width:48px !important;
    height:48px !important;
    border-radius:13px !important;
    margin-bottom:12px !important;
  }
  .flip-card .card-icon-container .skill-ico{
    font-size:1.2rem !important;
  }
  .flip-card .card-action{
    font-size:.8rem !important;
    margin-top:10px !important;
    padding:6px 12px !important;
    border-radius:8px !important;
  }
  .flip-card .flip-card-front h4{ font-size:1.05rem !important; margin:0 0 5px !important; }
  .flip-card .flip-card-front p{ font-size:.78rem !important; line-height:1.4; margin:0 0 10px; }
  .flip-card .progress-bar{ height:6px !important; }
}

/* ═══════════════════════════════════════════════════════════
   "Last CEFR Reading exam" KARTALARI
   4 burchak (radius 5px) va balandlik kichraytirilgan —
   uzun cho'zilgan karta bo'lib qolmasligi uchun.
   ═══════════════════════════════════════════════════════════ */
@media (min-width:769px){
  .tests-grid .test-card--mini{
    border-radius:5px !important;
    padding:12px 14px !important;
    min-height:0 !important;
    height:auto !important;
    display:flex;flex-direction:column;align-items:flex-start;gap:6px;
  }
  .tests-grid .test-card--mini .test-title{
    font-size:.9rem !important;
    line-height:1.32 !important;
  }
  .tests-grid .test-card--mini .test-date{
    font-size:.68rem !important;
  }
  .tests-grid .test-card--mini .test-btn--mini{
    margin-top:2px !important;
    padding:5px 11px !important;
    border-radius:6px !important;
    font-size:.7rem !important;
  }
}

/* ═══════════════════════════════════════
   KUUCHLI QURILMA HIMOYASI
   57 ta backdrop-filter + shimmer animatsiyalari kuchsiz
   qurilmada main threadni band qiladi. Bu holda ular
   o'chiriladi — dizayn saqlanadi, tezlik ortadi.
   ═══════════════════════════════════════ */
.low-power *,
.low-power *::before,
.low-power *::after {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
/* shimmer kabi doimiy animatsiyalar ham to'xtaydi */
.low-power .ads-card1::after,
.low-power .ads-card2::after,
.low-power .news1::after,
.low-power .news2::after {
  animation: none !important;
  display: none !important;
}
/* maxsus effektlar \u2014 telefon kamerasi aylanish va shunga o\u0301xshash */
.low-power .glass-mobile-only,
.low-power [data-glass-only] {
  display: none !important;
}

/* ══════════════════════════════════════════════════════════════
   1) SAYIT FONI — Uiverse grid pattern
      Och rejim: kennyotsu-monochromia / spotty-cheetah-65
      Tun rejim: adamgiebl / curvy-earwig-79
   ══════════════════════════════════════════════════════════════ */

/* ── OCH REJIM ─────────────────────────────────────────── */
body.lf-grid-bg {
  background-color: #F3F3F3;
  background-image:
    linear-gradient(0deg,  transparent 24%, #E1E1E1 25%, #E1E1E1 26%, transparent 27%, transparent 74%, #E1E1E1 75%, #E1E1E1 76%, transparent 77%, transparent),
    linear-gradient(90deg, transparent 24%, #E1E1E1 25%, #E1E1E1 26%, transparent 27%, transparent 74%, #E1E1E1 75%, #E1E1E1 76%, transparent 77%, transparent);
  background-size: 55px 55px;
  background-attachment: fixed;
}

/* ── TUN REJIM ─────────────────────────────────────────── */
body.lf-grid-bg.dark-mode {
  background-color: #191a1a;
  background-image:
    linear-gradient(0deg,  transparent 24%, rgba(114,114,114,.30) 25%, rgba(114,114,114,.30) 26%, transparent 27%, transparent 74%, rgba(114,114,114,.30) 75%, rgba(114,114,114,.30) 76%, transparent 77%, transparent),
    linear-gradient(90deg, transparent 24%, rgba(114,114,114,.30) 25%, rgba(114,114,114,.30) 26%, transparent 27%, transparent 74%, rgba(114,114,114,.30) 75%, rgba(114,114,114,.30) 76%, transparent 77%, transparent);
  background-size: 55px 55px;
  background-attachment: fixed;
}

/* To'sqinlik qatlami va `body > * { position:relative }` OLIB TASHLANDI.

   SABAB: `body.lf-grid-bg > *` specificity (0,1,1) bo'lgani uchun
   `.glass-header`, `.parts-sheet-overlay`, `.mob-glass-nav-wrapper`
   (barchasi (0,1,0) — `position:fixed`) ni BUZDI:
     • header normal oqimga tushib qoldi (pastga silindi)
     • "Reading sections" overlay va mobil nav pastda ko'rindi

   Naqsh o'zi juda nozik (oq rejim 1.18:1, tun rejim 3.63:1),
   to'sqinliksiz ham matn o'qilishi to'g'ri qoladi. */

@media (prefers-reduced-motion:reduce){
  body.lf-grid-bg{background-attachment:scroll}
}

/* ══════════════════════════════════════════════════════════════
   2) REKLAMA BANNERLARI — iOS yumaloq to'rtburchak
      Orqa fon OLIB TASHLANDI (shaffof), oq fon QO'SHILMADI.
   ══════════════════════════════════════════════════════════════ */
.ads-card1,
.ads-card2{
  /* News va kinolar kabi frosted iOS (glass morphism emas) */
  background:rgba(255,255,255,.42) !important;
  -webkit-backdrop-filter:blur(16px) saturate(1.4) !important;
  backdrop-filter:blur(16px) saturate(1.4) !important;
  border:1px solid rgba(255,255,255,.4) !important;
  border-radius:26px !important;
  box-shadow:
    0 1px 2px rgba(0,0,0,.03),
    0 10px 30px rgba(0,0,0,.05) !important;
  transition:transform .22s cubic-bezier(.34,1.3,.64,1),
             box-shadow .22s ease,
             border-color .22s ease !important;
  overflow:hidden;
}
.ads-card2{background:rgba(255,255,255,.42) !important}

body.dark-mode .ads-card1,
body.dark-mode .ads-card2{
  background:rgba(30,41,59,.72) !important;
  -webkit-backdrop-filter:blur(16px) saturate(1.3) !important;
  backdrop-filter:blur(16px) saturate(1.3) !important;
  border-color:rgba(255,255,255,.14) !important;
  box-shadow:0 1px 2px rgba(0,0,0,.2),0 10px 30px rgba(0,0,0,.28) !important;
}

/* Hover — kichik ko'tarilish (iOS) */
.ads-card1:hover,
.ads-card2:hover{
  transform:translateY(-4px);
  box-shadow:0 2px 4px rgba(0,0,0,.04),0 18px 44px rgba(0,0,0,.09) !important;
}
body.dark-mode .ads-card1:hover,
body.dark-mode .ads-card2:hover{
  box-shadow:0 2px 4px rgba(0,0,0,.25),0 18px 44px rgba(0,0,0,.38) !important;
}

/* Yon chiziqcha — iOS "accent" hissi (rangi reklamadan keladi).

   DIQQAT: main.css:1393 dagi eski `::after` shimmer hali ham
   `height:100%`, `transform:skewX(-25deg)` va
   `animation:shimmer 4s infinite` beradi. @keyframes shimmer
   `left:-100% → 150%` qilib yuritadi — natijada 4px chiziqcha
   egilib kartochka bo'ylab SURIB yurardi (ko'rinuvchi "fon").
   Shu uchun uchala xususiyat ham to'liq nolga tushiriladi. */
.ads-card1::after,
.ads-card2::after{
  content:"";
  position:absolute;
  left:0;top:22px;bottom:22px;width:4px;height:auto;
  border-radius:0 4px 4px 0;
  background:var(--ad-accent,#fbbf24);
  opacity:.9;
  animation:none !important;
  transform:none !important;
  pointer-events:none;
}

/* ── Ichki elementlar ─────────────────────────────────── */
.ad-content{position:relative;z-index:2}

.ad-badge{
  display:inline-flex;align-items:center;gap:6px;
  background:var(--ad-accent,#fbbf24) !important;
  color:#1d1d1f !important;
  font-size:10.5px !important;font-weight:700 !important;
  letter-spacing:.07em;
  padding:5px 12px !important;border-radius:100px !important;
  border:none !important;
}
.ad-title{
  font-size:21px !important;font-weight:700 !important;
  letter-spacing:-.02em;margin:12px 0 7px !important;
}
.ad-desc{
  font-size:14.5px !important;line-height:1.5 !important;
  margin:0 0 18px !important;opacity:.82;
}
.ad-footer{
  display:flex;align-items:center;justify-content:space-between;
  gap:12px;flex-wrap:wrap;
}
.ad-discount{
  font-size:13px;font-weight:600;
  padding:5px 11px;border-radius:100px;
  background:rgba(0,0,0,.05);
}
body.dark-mode .ad-discount{background:rgba(255,255,255,.08)}

.ad-btn{
  display:inline-flex;align-items:center;gap:7px;
  padding:11px 20px !important;border-radius:100px !important;
  background:var(--ad-accent,#fbbf24) !important;
  color:#1d1d1f !important;
  font-size:14px !important;font-weight:600 !important;
  text-decoration:none !important;
  box-shadow:0 3px 10px rgba(0,0,0,.10);
  transition:transform .14s ease,filter .18s ease;
}
.ad-btn:hover{filter:brightness(1.07);text-decoration:none !important}
.ad-btn:active{transform:scale(.95)}

/* Eski shimmer/hover effektlari o'chiriladi (fon yo'q endi) */
.ads-card1::before,
.ads-card2::before{display:none !important}

@media (max-width:640px){
  .ads-card1,.ads-card2{
    border-radius:22px !important;padding:24px 22px !important;
    min-height:0 !important;
  }
  .ad-title{font-size:19px !important}
  .ad-footer{flex-direction:column;align-items:flex-start;gap:11px}
  .ad-btn{width:100%;justify-content:center}
}

/* ══════════════════════════════════════════════════════════════
   SAYT OXIRIDAGI TARTIB — uch blok ALOHIDA
     [yangiliklar] → [reklama] → [copyright]
   Copyright en OXIRIDA va YAKKA.

   AVVALGI MUAMMO: `.news`, `.ads` va `.footer-bottom` hammasi
   `<footer class="site-footer">` ICHIDA edi. Footer'da esa
   `background: var(--surface)` = #ffffff bor — shuning uchun
   reklama banneri orqasida oq fon ko'rinardi va copyright
   reklama bilan yopishib qolgandi.
   ══════════════════════════════════════════════════════════════ */

.news-section,
.ads-section{
  background:transparent !important;
  max-width:1200px;
  margin-left:auto;margin-right:auto;
  padding:0 20px;
}
.news-section{margin-top:34px}
.ads-section{margin-top:22px}

.news-section .news,
.ads-section .ads{margin-bottom:0 !important;gap:20px}

/* ── Copyright: faqat oq tasma, eng oxirida ── */
.site-footer{
  margin-top:26px !important;
  border-top:1px solid var(--border);
  background:var(--surface);
  max-width:1200px;
  padding:0 20px;
}
.site-footer .footer-bottom{
  margin:0 !important;
  padding:20px 0 !important;
  border-top:none !important;
}
/* Footer ichida endi faqat copyright bor */
.site-footer .news,
.site-footer .ads,
.site-footer .news-section,
.site-footer .ads-section{display:none !important}

@media (max-width:900px){
  .news-section .news,
  .ads-section .ads{grid-template-columns:1fr}
}
@media (max-width:640px){
  .news-section{margin-top:24px;padding:0 14px}
  .ads-section{margin-top:16px;padding:0 14px}
  .news-section .news,
  .ads-section .ads{gap:14px}
  .site-footer{margin-top:20px !important;padding:0 14px}
}

/* ══════════════════════════════════════════════════════════════
   PERF — animatsiyani to'xtatish (perf-guard.js)
   Ekrandan chiqqan kartalarda `backdrop-filter` qayta
   hisoblanmasligi uchun animatsiya to'xtaydi. Ko'rinish
   o'zgarmaydi — faqat tezlik.
   ══════════════════════════════════════════════════════════════ */
.anim-paused,
.anim-paused *,
.anim-paused *::before,
.anim-paused *::after{
  animation-play-state:paused !important;
}

/* Diktant kartasi — CD diski va LED doimiy ishlaydi.
   Bu kartada blur(20px) bilan birga 2 ta animatsiya bor edi:
   cdSpin 9s + ledPulse 2.6s. Har kadrda fon qayta xiralanardi.
   Vizual o'zgarishsiz to'xtatamiz. */
/* ── prefers-reduced-motion: hammasini to'xtat ──────────────── */
@media (prefers-reduced-motion:reduce){
  .news1::after,.news2::after,
  .ads-card1::after,.ads-card2::after{
    animation:none !important;
  }
}

/* ── Kuchsiz qurilma: animatsiya umuman yo'q ─────────────────── */
.low-power .news1::after,
.low-power .news2::after,
.low-power .ads-card1::after,
.low-power .ads-card2::after{
  animation:none !important;
}

/* ══════════════════════════════════════════════════════════════
   NEWS — shimmer faqat HOVER da, doimiy emas
   `.news1/.news2` `backdrop-filter: blur(20px)` bilan
   `shimmerNews 5s infinite` ishlardi — har kadrda fon qayta
   xiralanardi. Endi faqat hover paytida.
   ══════════════════════════════════════════════════════════════ */
.news1::after,
.news2::after{
  animation:none !important;
}
.news1:hover::after,
.news2:hover::after{
  animation:shimmerNews 5s ease-in-out infinite !important;
}

/* ═══════════════════════════════════════════════════════════════
   DICTATION — SARLAVHA va "YANA KO'RSATISH"
   ───────────────────────────────────────────────────────────────
   500+ diktant bo'lsa ham sahifa "to'lib" ketmasligi uchun:
     • sarlavha — foydalanuvchi bo'lim nima ekanini darhol tushunadi
     • ro'yxat bosqichma-bosqich ochiladi (main.js: DICT_PAGE = 10)
   ═══════════════════════════════════════════════════════════════ */

/* ── Sarlavha ── */
.dict-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:14px;
  margin:0 0 12px;
  padding:0 2px;
}
.dict-head-text{ min-width:0; }

.dict-head-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:.63rem;
  font-weight:800;
  letter-spacing:.1em;
  text-transform:uppercase;
  color:var(--primary,#4f46e5);
  background:rgba(79,70,229,.1);
  border-radius:7px;
  padding:3px 8px;
  margin-bottom:6px;
}
.dict-head-badge i{ font-size:.66rem; }

.dict-head-title{
  margin:0;
  font-size:1.6rem;
  font-weight:800;
  line-height:1.1;
  letter-spacing:-.01em;
  color:var(--text-primary,#1e293b);
}
.dict-head-sub{
  margin:4px 0 0;
  font-size:.82rem;
  font-weight:500;
  color:var(--text-secondary,#64748b);
}

/* ── umumiy soni ── */
.dict-head-count{
  flex:none;
  font-size:.66rem;
  font-weight:800;
  letter-spacing:.03em;
  color:#475569;
  background:#f1f5f9;
  border:1px solid rgba(15,23,42,.08);
  border-radius:8px;
  padding:5px 9px;
  white-space:nowrap;
}

/* ── "See more / See less" — IKKIGA BO'LINGAN tugma ──
   Chap yarmi ro'yxatni ochadi, o'ng yarmi qisqartiradi.
   Ikkalasi bitta kapsula ichida, o'rtada ingichka ajratgich. */
.dict-more{
  display:flex;
  align-items:stretch;
  width:100%;
  margin-top:10px;
  border:1px dashed rgba(79,70,229,.42);
  border-radius:12px;
  overflow:hidden;
  background:transparent;
  transition:border-color .18s ease;
}
.dict-more[hidden]{ display:none !important; }
.dict-more:hover{ border-color:var(--primary,#4f46e5); }

/* ── har bir yarim ── */
.dict-more-half{
  flex:1 1 50%;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:42px;
  padding:11px 12px;
  font-family:inherit;
  font-size:.84rem;
  font-weight:700;
  color:var(--primary,#4f46e5);
  background:transparent;
  border:0;
  cursor:pointer;
  -webkit-tap-highlight-color:transparent;
  transition:background .18s ease,color .18s ease;
}
.dict-more-half:hover:not(:disabled){ background:rgba(79,70,229,.07); }
.dict-more-half:active:not(:disabled){ background:rgba(79,70,229,.13); }
.dict-more-half:focus-visible{
  outline:none;
  box-shadow:inset 0 0 0 3px rgba(79,70,229,.28);
}
/* o'chirilgan yarim — bosilmaydi va xira ko'rinadi */
.dict-more-half:disabled{
  opacity:.38;
  cursor:not-allowed;
}
/* o'rtadagi ajratgich */
.dict-more-more{ border-right:1px dashed rgba(79,70,229,.30); }

.dict-more-half i{ font-size:.72rem; opacity:.8; }

/* Tugmadagi asosiy yozuv — "See more" / "See less" */
.dict-more-label{
  font-size:.84rem;
  font-weight:800;
  letter-spacing:.01em;
  line-height:1;
}

.dict-more-count{
  font-size:.68rem;
  font-weight:800;
  color:#475569;
  background:#e2e8f0;
  border-radius:6px;
  padding:2px 6px;
}
.dict-more-count:empty{ display:none; }

/* ── to'q rejim ── */
body.dark-mode .dict-head-title{ color:#ffffff; }
body.dark-mode .dict-head-sub{ color:#94a3b8; }
body.dark-mode .dict-head-badge{
  color:#a5b4fc;
  background:rgba(99,102,241,.18);
}
body.dark-mode .dict-more{ border-color:rgba(129,140,248,.45); }
body.dark-mode .dict-more:hover{ border-color:rgba(165,180,252,.7); }
body.dark-mode .dict-more-half{ color:#a5b4fc; }
body.dark-mode .dict-more-half:hover:not(:disabled){ background:rgba(129,140,248,.14); }
body.dark-mode .dict-more-half:active:not(:disabled){ background:rgba(129,140,248,.22); }
body.dark-mode .dict-more-more{ border-right-color:rgba(165,180,252,.30); }
body.dark-mode .dict-more-count{
  color:#cbd5e1;
  background:rgba(255,255,255,.10);
}
body.dark-mode .dict-head-count{
  color:#cbd5e1;
  background:rgba(255,255,255,.08);
  border-color:rgba(255,255,255,.12);
}

/* ── telefon ── */
@media (max-width:560px){
  .dict-head{ align-items:flex-start; flex-direction:column; gap:8px; margin-bottom:10px; }
  .dict-head-count{ align-self:flex-start; }
  .dict-head-title{ font-size:1.34rem; }
  .dict-head-sub{ font-size:.78rem; }
  .dict-more-half{ font-size:.8rem; padding:10px 8px; gap:6px; }
  .dict-more-label{ font-size:.8rem; }
}

/* ── harakatni kamaytirish ── */
@media (prefers-reduced-motion:reduce){
  .dict-more, .dict-more-half{ transition:none; }
}
