/* TubeMe Base Styles */
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  padding-top: calc(var(--header-h) + var(--safe-top));
  /* Bottom nav float qiladi (bottom: safe + 12px), uning balandligi nav-h.
     Shadow + buffer uchun qo'shimcha bo'sh joy qoldiramiz, aks holda
     kontentning oxirgi qatori nav tagida qolib ketadi. */
  padding-bottom: calc(var(--nav-h) + var(--safe-bottom) + 48px);
  min-height: 100vh;
  overflow-x: hidden;
  background-image:
    radial-gradient(1200px 600px at 50% -10%, rgba(123, 97, 255, 0.08), transparent 60%),
    radial-gradient(800px 400px at 100% 100%, rgba(0, 212, 255, 0.05), transparent 60%);
  background-attachment: fixed;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', 'Inter', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

h1 { font-size: 28px; }
h2 { font-size: 22px; }
h3 { font-size: 18px; }
h4 { font-size: 16px; }

p { color: var(--text-2); }

/* App container */
#app {
  position: relative;
  width: 100%;
  min-height: 100vh;
  isolation: isolate;
}

/* Header */
.app-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: calc(var(--header-h) + var(--safe-top));
  padding: var(--safe-top) var(--s-4) 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: var(--z-header);
  background: linear-gradient(180deg, rgba(5,5,5,0.92) 0%, rgba(5,5,5,0.7) 80%, transparent 100%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border);
  transition: transform 0.3s var(--ease-out);
}

.app-header.hidden { transform: translateY(-100%); }

.header-left, .header-right {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

.logo-svg {
  width: 32px;
  height: 32px;
  filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.6));
  animation: logoPulse 3s ease-in-out infinite;
}

@keyframes logoPulse {
  0%, 100% { filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.6)); }
  50% { filter: drop-shadow(0 0 16px rgba(123, 97, 255, 0.8)); }
}

.logo-text {
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: 18px;
  letter-spacing: -0.02em;
  background: var(--neon-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.icon-btn {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: var(--r-full);
  position: relative;
  transition: all 0.2s var(--ease-out);
  color: var(--text);
}

.icon-btn svg {
  width: 22px;
  height: 22px;
}

.icon-btn:active { transform: scale(0.92); background: rgba(255, 255, 255, 0.06); }

.notif-dot {
  position: absolute;
  top: 8px; right: 8px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--neon-pink);
  box-shadow: 0 0 8px var(--neon-pink);
  opacity: 0;
  transition: opacity 0.2s;
}
.notif-dot.active { opacity: 1; animation: dotPulse 1.4s infinite; }

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

.avatar-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--neon-gradient);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 14px;
  color: #000;
  box-shadow: 0 0 12px rgba(0, 212, 255, 0.3);
  transition: transform 0.2s var(--ease-spring);
}
.avatar-btn:active { transform: scale(0.9); }

/* Main view */
.main-view {
  position: relative;
  width: 100%;
  min-height: calc(100vh - var(--header-h) - var(--nav-h));
  padding: 0 0 var(--s-6);
}

/* Bottom Nav */
.bottom-nav {
  position: fixed;
  bottom: calc(var(--safe-bottom) + 12px);
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 480px;
  height: var(--nav-h);
  background: rgba(15, 15, 15, 0.75);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  backdrop-filter: blur(28px) saturate(200%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--r-xl);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 var(--s-2);
  z-index: var(--z-nav);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.6);
}

.nav-item {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: var(--text-2);
  font-size: 10px;
  font-weight: 500;
  transition: all 0.25s var(--ease-out);
  position: relative;
}

.nav-item svg {
  width: 22px;
  height: 22px;
  transition: transform 0.25s var(--ease-spring);
}

.nav-item.active {
  color: var(--neon-blue);
}

.nav-item.active svg {
  transform: translateY(-2px) scale(1.1);
  filter: drop-shadow(0 0 8px var(--neon-blue));
}

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

.nav-indicator {
  position: absolute;
  top: 6px;
  width: 24px;
  height: 3px;
  background: var(--neon-gradient);
  border-radius: var(--r-full);
  box-shadow: 0 0 12px var(--neon-blue);
  transition: left 0.35s var(--ease-spring);
}

/* Watermark */
.watermark {
  position: fixed;
  bottom: 90px;
  right: 12px;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.05);
  pointer-events: none;
  z-index: 999;
  font-weight: 700;
  letter-spacing: 0.2em;
}

/* Splash */
.splash {
  position: fixed;
  inset: 0;
  background: #050505;
  display: grid;
  place-items: center;
  z-index: var(--z-splash);
  transition: opacity 0.5s, visibility 0.5s;
}

.splash.hidden {
  opacity: 0;
  visibility: hidden;
}

.splash-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-4);
}

.splash-svg {
  width: 80px;
  height: 80px;
  animation: splashPulse 1.6s ease-in-out infinite;
  filter: drop-shadow(0 0 24px var(--neon-blue));
}

@keyframes splashPulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 16px var(--neon-blue)); }
  50% { transform: scale(1.08); filter: drop-shadow(0 0 32px var(--neon-purple)); }
}

.splash-text {
  font-family: 'Poppins', sans-serif;
  font-size: 28px;
  font-weight: 800;
  background: var(--neon-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.02em;
}

.splash-loader {
  width: 100px;
  height: 3px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--r-full);
  overflow: hidden;
  position: relative;
}

.splash-loader span {
  position: absolute;
  inset: 0;
  width: 40%;
  background: var(--neon-gradient);
  border-radius: var(--r-full);
  animation: loaderSlide 1.2s ease-in-out infinite;
  box-shadow: 0 0 12px var(--neon-blue);
}

@keyframes loaderSlide {
  0% { left: -40%; }
  100% { left: 100%; }
}

/* Offline banner */
.offline-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  transform: translateY(-100%);
  background: rgba(255, 59, 92, 0.95);
  color: #fff;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  z-index: 10001;
  transition: transform 0.3s ease-in-out;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.offline-banner.show {
  transform: translateY(0);
}

/* DevTools blur */
.devtools-blur {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  -webkit-backdrop-filter: blur(40px);
  backdrop-filter: blur(40px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--s-6);
}
.devtools-blur.active { display: flex; }
.dt-content h2 { color: var(--danger); margin-bottom: var(--s-3); }
.dt-content p { color: var(--text-2); }

/* Install popup - pastda yashirin holatda */
.install-popup {
  position: fixed;
  bottom: -100px;  /* Oddiy holatda butunlay pastda yashirin */
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 24px);
  max-width: 460px;
  background: rgba(20, 20, 20, 0.92);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  padding: var(--s-4);
  z-index: 999;
  box-shadow: var(--shadow-lg);
  transition: bottom 0.4s var(--ease-spring), opacity 0.3s ease;
  opacity: 0;
  visibility: hidden;
}

/* Taklif kelganda (show holati) - nav bardan yuqoriga chiqadi */
.install-popup.show {
  bottom: calc(var(--nav-h) + var(--safe-bottom) + 16px);
  opacity: 1;
  visibility: visible;
}

.install-content {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex-wrap: wrap;
}

.install-icon {
  width: 48px;
  height: 48px;
  background: var(--neon-gradient);
  border-radius: var(--r-md);
  display: grid;
  place-items: center;
  padding: 8px;
}

.install-text { flex: 1; min-width: 120px; }
.install-text h4 { font-size: 14px; }
.install-text p { font-size: 11px; color: var(--text-2); }

.install-actions {
  display: flex;
  gap: var(--s-2);
}

.btn-primary, .btn-ghost {
  padding: 8px 16px;
  border-radius: var(--r-full);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.2s var(--ease-out);
  cursor: pointer;
}

.btn-primary {
  background: var(--neon-gradient);
  color: #000;
  box-shadow: 0 4px 12px rgba(0, 212, 255, 0.3);
}
.btn-primary:active { transform: scale(0.94); }

.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}
.btn-ghost:active { background: rgba(255, 255, 255, 0.12); }

.avatar-btn.has-image {
  background-color: rgba(255, 255, 255, 0.08);
  color: transparent;
}

.auth-gate-open {
  overflow: hidden;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.auth-gate.hidden {
  display: none;
}

.auth-gate-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(20px);
}

.auth-gate-card {
  position: relative;
  width: min(100%, 420px);
  background: linear-gradient(180deg, rgba(15, 15, 15, 0.98), rgba(15, 15, 15, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  padding: 28px 22px;
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.45);
  text-align: center;
  overflow: hidden;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
}

/* KOMPAKT REJIM: ortiqcha bo'shliqlarni qisqartiramiz, ekranga sig'ishi uchun */
.auth-gate-card.compact {
  padding: 20px 18px 18px;
  border-radius: 22px;
  width: min(100%, 360px);
}
.auth-gate-card.compact .auth-gate-logo-wrap { margin-bottom: 10px; gap: 4px; }
.auth-gate-card.compact .auth-gate-logo-svg { width: 44px; height: 44px; }
.auth-gate-card.compact .auth-gate-brand { font-size: 18px; padding: 2px 6px; }
.auth-gate-card.compact h2 { font-size: 19px; line-height: 1.25; margin-bottom: 6px; }
.auth-gate-card.compact .auth-gate-sub-compact {
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.45;
  margin-bottom: 14px;
}
.auth-gate-card.compact .telegram-widget-wrap { gap: 10px; }
.auth-gate-card.compact .telegram-switch-btn {
  min-width: 0;
  width: 100%;
  padding: 10px 14px;
}
.auth-gate-card.compact .telegram-switch-btn .tswitch-label { font-size: 13px; }
.auth-gate-card.compact .telegram-switch-btn .tswitch-hint { font-size: 10.5px; }

.auth-gate-card.premium {
  border: 1px solid rgba(123, 97, 255, 0.22);
  background:
    radial-gradient(120% 80% at 50% -10%, rgba(0,212,255,0.18), transparent 60%),
    radial-gradient(120% 80% at 50% 110%, rgba(123,97,255,0.22), transparent 60%),
    linear-gradient(180deg, rgba(15, 15, 15, 0.98), rgba(10, 10, 12, 0.96));
  animation: gateFadeUp 480ms cubic-bezier(.2,.8,.2,1);
}

@keyframes gateFadeUp {
  from { opacity: 0; transform: translateY(18px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.auth-gate-glow {
  position: absolute;
  top: -60px; left: 50%;
  width: 240px; height: 240px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(0,212,255,0.25), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  animation: gateGlowPulse 4s ease-in-out infinite;
}

@keyframes gateGlowPulse {
  0%, 100% { opacity: .55; }
  50% { opacity: 1; }
}

.auth-gate-logo-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.auth-gate-logo-svg {
  width: 56px;
  height: 56px;
  filter: drop-shadow(0 6px 18px rgba(0,212,255,0.45));
}

.auth-gate-brand {
  font-family: 'Poppins', 'Inter', sans-serif;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.06em;
  background: linear-gradient(90deg, #00D4FF, #7B61FF);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
  padding: 4px 8px;
}

.auth-gate-logo {
  display: inline-flex;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(0, 212, 255, 0.08);
  color: var(--neon-blue);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.auth-gate-card h2 {
  font-size: 28px;
  line-height: 1.15;
  margin-bottom: 10px;
}

.auth-gate-card p {
  color: var(--text-2);
  line-height: 1.6;
}

.auth-benefits {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 20px 0 22px;
}

.auth-benefits span {
  display: block;
  padding: 13px 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 13px;
  text-align: left;
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

.auth-benefits span:hover {
  border-color: rgba(0, 212, 255, 0.25);
  background: linear-gradient(180deg, rgba(0,212,255,0.06), rgba(123,97,255,0.04));
  transform: translateY(-1px);
}

.telegram-widget-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  justify-content: center;
}

.telegram-widget-host {
  min-height: 50px;
}

.telegram-fallback-btn {
  min-width: 220px;
  text-align: center;
}

/* ===== Telegram widget yuklanishi skeleton + animatsiyasi =====
   Foydalanuvchi dastur ochilishi bilan "Telegram bilan kirish" tugmasini
   darhol ko'rishi uchun, skeleton paydo bo'lib turadi. Telegram script
   iframe'ni inject qilishi bilan skeleton avtomatik o'chadi.
   Skeleton aynan Telegram tugmasiga o'xshash ko'rinishda — foydalanuvchi tugma
   "hozir paydo bo'lyapti" deb tushunishi uchun. */
.tg-widget-skeleton {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 56px;
  padding: 4px 0 2px;
  animation: tgSkelFadeIn .35s ease-out, tgSkelPulse 2.4s ease-in-out infinite;
  transition: opacity .3s ease, transform .3s ease;
}
.tg-widget-skeleton.hidden {
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
}

.tg-skel-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
  max-width: 100%;
  padding: 12px 22px 12px 18px;
  border-radius: 999px;
  background: linear-gradient(90deg, #229ED9, #1E88C9);
  color: #fff;
  box-shadow: 0 10px 28px rgba(34, 158, 217, 0.32);
  overflow: hidden;
  isolation: isolate;
}
.tg-skel-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.22) 50%, transparent 100%);
  transform: translateX(-100%);
  animation: tgSkelShimmer 1.5s linear infinite;
  pointer-events: none;
  z-index: 1;
}
.tg-skel-btn > * { position: relative; z-index: 2; }

.tg-skel-spinner {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: #fff;
  animation: tgSkelSpin 0.9s linear infinite;
  flex-shrink: 0;
}

.tg-skel-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.tg-skel-title { display: inline-block; }

.tg-skel-dots {
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  margin-left: 2px;
}
.tg-skel-dots i {
  display: block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #fff;
  opacity: 0.4;
  animation: tgSkelDot 1.2s ease-in-out infinite;
}
.tg-skel-dots i:nth-child(2) { animation-delay: 0.2s; }
.tg-skel-dots i:nth-child(3) { animation-delay: 0.4s; }

.tg-skel-hint {
  font-size: 11.5px;
  color: var(--text-3);
  letter-spacing: 0.01em;
  opacity: 0.9;
}

@keyframes tgSkelFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes tgSkelShimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
@keyframes tgSkelSpin {
  to { transform: rotate(360deg); }
}
@keyframes tgSkelDot {
  0%, 80%, 100% { opacity: 0.35; transform: translateY(0); }
  40%           { opacity: 1;    transform: translateY(-3px); }
}
@keyframes tgSkelPulse {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(34,158,217,0)); }
  50%      { filter: drop-shadow(0 0 8px rgba(34,158,217,.5)); }
}

.telegram-switch-btn {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  justify-content: center;
  min-width: 240px;
  margin-top: 6px;
  padding: 12px 18px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px dashed rgba(255,255,255,0.16);
  color: var(--text);
  cursor: pointer;
  transition: all .2s ease;
}

.telegram-switch-btn:hover {
  background: rgba(0, 212, 255, 0.08);
  border-color: rgba(0, 212, 255, 0.35);
}

.telegram-switch-btn .tswitch-label {
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
}

.telegram-switch-btn .tswitch-hint {
  font-size: 11px;
  color: var(--text-3);
  line-height: 1.4;
  text-align: center;
  max-width: 260px;
}

.telegram-config-warning {
  width: 100%;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255, 166, 0, 0.08);
  border: 1px solid rgba(255, 166, 0, 0.16);
}

/* ===== Telegram Reset Panel (chiqishdan keyingi kutish oynasi) ===== */
.telegram-reset-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px 0 0;
  width: 100%;
}
.tg-reset-title {
  font-size: 16px;
  font-weight: 800;
  line-height: 1.3;
  color: var(--text);
}
.tg-reset-sub {
  color: var(--text-2);
  line-height: 1.55;
  font-size: 12.5px;
}
/* tg-reset-timer (3 daqiqalik countdown) foydalanuvchi so'roviga ko'ra olib tashlandi.
   Stillarini saqlab turamiz, lekin DOM'da bu element render qilinmaydi. */
.tg-reset-timer {
  display: none !important;
}
.tg-reset-open-btn {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  background: linear-gradient(135deg, #229ED9, #1E88C9);
  color: #fff;
  font-weight: 700;
  border: 0;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(34, 158, 217, 0.32);
  transition: transform .15s ease, box-shadow .2s ease;
}
.tg-reset-open-btn:hover { transform: translateY(-1px); box-shadow: 0 14px 28px rgba(34, 158, 217, 0.4); }
.tg-reset-open-btn:active { transform: translateY(0); }
.tg-reset-open-title { font-size: 14px; }
.tg-reset-open-hint {
  font-size: 11px;
  font-weight: 500;
  opacity: 0.92;
  line-height: 1.35;
  max-width: 280px;
  text-align: center;
}

.telegram-config-warning p {
  margin-top: 8px;
  font-size: 12px;
}

/* ===== Logout chooser modal (Profil > Chiqish) ===== */
.logout-chooser-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 8px 16px 20px;
  gap: 10px;
}
.logout-chooser-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(255,77,109,.18), rgba(255,77,109,.06));
  color: #ff8ba0;
  margin-bottom: 4px;
  box-shadow: 0 8px 24px rgba(255,77,109,.18) inset;
}
.logout-chooser-title {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -.01em;
  color: var(--text);
}
.logout-chooser-sub {
  margin: 0 0 6px;
  color: var(--text-2);
  font-size: 12.5px;
  line-height: 1.55;
  max-width: 320px;
}

.logout-end-session-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  border-radius: 14px;
  background: linear-gradient(135deg, #229ED9, #1E88C9);
  color: #fff;
  border: 0;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(34,158,217,.35);
  text-align: left;
  transition: transform .15s ease, box-shadow .2s ease;
}
.logout-end-session-btn:hover { transform: translateY(-1px); box-shadow: 0 16px 32px rgba(34,158,217,.42); }
.logout-end-session-btn:active { transform: translateY(0); }
.logout-end-session-btn .les-icon {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,.18);
  display: flex;
  align-items: center;
  justify-content: center;
}
.logout-end-session-btn .les-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}
.logout-end-session-btn .les-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.005em;
}
.logout-end-session-btn .les-hint {
  font-size: 11.5px;
  opacity: .9;
  line-height: 1.4;
  font-weight: 500;
}

.logout-soft-btn {
  background: transparent;
  border: 0;
  margin-top: 2px;
  padding: 10px 14px;
  color: var(--text-3);
  font-size: 12px;        /* kichik harflar — ikkinchi darajali action */
  font-weight: 500;
  letter-spacing: .01em;
  text-transform: none;
  cursor: pointer;
  border-radius: 10px;
  transition: color .15s ease, background .15s ease;
}
.logout-soft-btn:hover {
  color: #ff8ba0;
  background: rgba(255,77,109,.06);
}
.logout-soft-btn:active { transform: scale(.97); }

/* ===== Gate ostidagi "Seansni yakunlash" yordamchi bloki ===== */
.gate-end-session-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  margin-top: 14px;
  padding-top: 14px;
}
.ges-divider {
  position: relative;
  text-align: center;
  margin: 4px 0 2px;
}
.ges-divider::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 50%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.14), transparent);
}
.ges-divider span {
  position: relative;
  display: inline-block;
  padding: 0 10px;
  /* Gate kartasi ichida ham, modal'da ham yaxshi ko'rinishi uchun shaffof yarim qora fon */
  background: rgba(15, 15, 15, 0.98);
  color: var(--text-3);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.gate-end-session-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  color: var(--text);
  cursor: pointer;
  text-align: left;
  transition: all .2s ease;
}
.gate-end-session-btn:hover {
  background: rgba(34,158,217,.08);
  border-color: rgba(34,158,217,.3);
}
.gate-end-session-btn:active { transform: scale(.99); }
.gate-end-session-btn .ges-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(34,158,217,.14);
  color: #4FB8E8;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gate-end-session-btn .ges-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}
.gate-end-session-btn .ges-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.gate-end-session-btn .ges-hint {
  font-size: 11px;
  color: var(--text-3);
  line-height: 1.4;
}
.ges-warn {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 4px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255,180,0,.08);
  border: 1px solid rgba(255,180,0,.18);
  font-size: 11.5px;
  color: #ffcf6b;
  line-height: 1.5;
}
.ges-warn-icon { flex-shrink: 0; font-size: 13px; line-height: 1.2; }

/* Kompakt gate'da bo'shliqlarni biroz qisqaroq qilamiz */
.auth-gate-card.compact .gate-end-session-block { margin-top: 10px; padding-top: 8px; }
.auth-gate-card.compact .ges-warn { font-size: 11px; padding: 8px 10px; }


.btn-danger {
  padding: 8px 16px;
  border-radius: var(--r-full);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.2s var(--ease-out);
  cursor: pointer;
  background: rgba(255, 77, 109, 0.14);
  color: #ff8ba0;
  border: 1px solid rgba(255, 77, 109, 0.28);
}

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