/* ============================================
   SAMBHRAM UNIVERSITY · PRO STYLES v2.0
   © 2026 · Bento Modern + Advanced Effects
   ============================================ */

:root {
  --bg-primary: #0a0a0b;
  --bg-secondary: #111113;
  --bg-card: #18181b;
  --bg-card-hover: #1f1f23;
  --bg-elevated: #27272a;
  --bg-overlay: rgba(0, 0, 0, 0.7);
  --border: rgba(255, 255, 255, 0.06);
  --border-strong: rgba(255, 255, 255, 0.12);
  --text-primary: #fafafa;
  --text-secondary: #a1a1aa;
  --text-tertiary: #71717a;
  --text-muted: #52525b;
  --accent: #3b5998;
  --accent-hover: #4c6db5;
  --accent-glow: rgba(59, 89, 152, 0.18);
  --accent-soft: rgba(59, 89, 152, 0.12);
  --accent-border: rgba(59, 89, 152, 0.35);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.6);

  --status-online: #22c55e;
  --status-warning: #fb923c;
  --status-offline: #ef4444;

  --c-buxgalteriya: #60a5fa;
  --c-buxgalteriya-bg: rgba(96, 165, 250, 0.12);
  --c-buxgalteriya-border: rgba(96, 165, 250, 0.3);
  --c-yotoqxona: #c084fc;
  --c-yotoqxona-bg: rgba(168, 85, 247, 0.12);
  --c-yotoqxona-border: rgba(168, 85, 247, 0.3);
  --c-hodimlar: #22d3ee;
  --c-hodimlar-bg: rgba(34, 211, 238, 0.12);
  --c-hodimlar-border: rgba(34, 211, 238, 0.3);
  --c-kutubxona: #fb923c;
  --c-kutubxona-bg: rgba(251, 146, 60, 0.12);
  --c-kutubxona-border: rgba(251, 146, 60, 0.3);
  --c-yoqlama: #f472b6;
  --c-yoqlama-bg: rgba(236, 72, 153, 0.12);
  --c-yoqlama-border: rgba(236, 72, 153, 0.3);

  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
}

[data-theme="light"] {
  --bg-primary: #fafafa;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f8f8f8;
  --bg-elevated: #f4f4f5;
  --bg-overlay: rgba(0, 0, 0, 0.4);
  --border: rgba(0, 0, 0, 0.06);
  --border-strong: rgba(0, 0, 0, 0.12);
  --text-primary: #18181b;
  --text-secondary: #52525b;
  --text-tertiary: #71717a;
  --text-muted: #a1a1aa;
  --accent: #1e3a8a;
  --accent-hover: #1e40af;
  --accent-glow: rgba(30, 58, 138, 0.12);
  --accent-soft: rgba(30, 58, 138, 0.08);
  --accent-border: rgba(30, 58, 138, 0.25);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.1);
  --c-buxgalteriya: #1e40af;
  --c-buxgalteriya-bg: rgba(30, 64, 175, 0.1);
  --c-yotoqxona: #9333ea;
  --c-yotoqxona-bg: rgba(147, 51, 234, 0.08);
  --c-hodimlar: #0891b2;
  --c-hodimlar-bg: rgba(8, 145, 178, 0.08);
  --c-kutubxona: #ea580c;
  --c-kutubxona-bg: rgba(234, 88, 12, 0.08);
  --c-yoqlama: #db2777;
  --c-yoqlama-bg: rgba(219, 39, 119, 0.08);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  min-height: 100dvh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
  overscroll-behavior-y: none;
  padding: var(--safe-top) var(--safe-right) var(--safe-bottom) var(--safe-left);
}

/* ============ AMBIENT + SPOTLIGHT ============ */
.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.ambient::before, .ambient::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
}

.ambient::before {
  top: -200px;
  right: -200px;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  animation: floatAmbient 20s ease-in-out infinite;
}

.ambient::after {
  bottom: -200px;
  left: -200px;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.08), transparent 70%);
  animation: floatAmbient 25s ease-in-out infinite reverse;
}

@keyframes floatAmbient {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(40px, -40px); }
}

.spotlight {
  position: fixed;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-glow), transparent 60%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
}

@media (hover: hover) and (pointer: fine) {
  body:hover .spotlight { opacity: 0.5; }
}

/* ============ CONTAINER ============ */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px 32px 64px;
  position: relative;
  z-index: 1;
}

/* ============ NAVBAR ============ */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  margin-bottom: 32px;
  border-bottom: 0.5px solid var(--border);
  gap: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.brand-logo {
  width: 44px;
  height: 44px;
  background: #f5efe0;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 0 0.5px var(--border);
}

.brand-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand-logo:hover {
  transform: scale(1.05) rotate(-3deg);
}

.brand-logo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 30%, rgba(255,255,255,0.2) 50%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.brand-logo:hover::after { opacity: 1; }

.brand-text {
  min-width: 0;
}

.brand-text h1 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
  letter-spacing: -0.3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-text p {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

/* ============ SEARCH BUTTON ============ */
.search-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px 0 14px;
  height: 40px;
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 10px;
  color: var(--text-tertiary);
  font-size: 13px;
  font-weight: 400;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  min-width: 220px;
}

.search-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
  color: var(--text-secondary);
}

.search-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.search-btn span { flex: 1; text-align: left; }

.search-btn kbd {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--text-tertiary);
}

/* ============ ICON BUTTONS ============ */
.icon-btn {
  width: 40px;
  height: 40px;
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--text-secondary);
  touch-action: manipulation;
  position: relative;
}

.icon-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
  color: var(--text-primary);
}

.icon-btn:active { transform: scale(0.94); }
.icon-btn svg { width: 18px; height: 18px; }

.notif-btn .notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--accent);
  color: var(--bg-primary);
  border-radius: 9px;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-primary);
}

/* ============ LANGUAGE ============ */
.lang-selector { position: relative; }

.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 14px;
  height: 40px;
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 10px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  touch-action: manipulation;
}

.lang-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
  color: var(--text-primary);
}

.lang-btn:active { transform: scale(0.96); }
.lang-btn svg { width: 14px; height: 14px; }

.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--bg-card);
  border: 0.5px solid var(--border-strong);
  border-radius: 12px;
  padding: 6px;
  min-width: 160px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: all 0.15s ease;
  z-index: 100;
}

.lang-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-secondary);
  transition: all 0.15s ease;
  min-height: 40px;
  touch-action: manipulation;
}

.lang-option:hover, .lang-option:active {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.lang-option.active {
  background: var(--accent-soft);
  color: var(--accent);
}

.lang-option .check { opacity: 0; width: 14px; height: 14px; }
.lang-option.active .check { opacity: 1; }

/* ============ HERO ============ */
.hero {
  margin-bottom: 28px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  background: var(--accent-soft);
  border: 0.5px solid var(--accent-border);
  border-radius: 100px;
  font-size: 11px;
  color: var(--accent);
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent);
  animation: pulse 2s ease infinite;
}

.greeting {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1px;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.greeting .user-name {
  background: linear-gradient(135deg, var(--accent), #22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  font-size: 15px;
  color: var(--text-secondary);
  max-width: 580px;
  line-height: 1.6;
}

/* ============ STATS BAR ============ */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

.stat {
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 12px;
  padding: 16px 18px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
  perspective: 1000px;
  will-change: transform;
}

.stat:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-strong);
}

.stat-label {
  font-size: 11px;
  color: var(--text-tertiary);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 6px;
}

.stat-value {
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.5px;
  font-family: 'JetBrains Mono', monospace;
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.stat-value.status-online {
  color: var(--accent);
  font-size: 16px;
  padding-top: 4px;
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 8px;
}

.stat-value .live-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--accent);
  animation: livePulse 1.5s ease infinite;
}

.stat-value .unit {
  font-size: 13px;
  color: var(--text-tertiary);
  font-weight: 500;
  margin-left: 4px;
}

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

/* ============ BENTO GRID ============ */
.bento {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  grid-template-rows: 240px 240px;
  gap: 14px;
  margin-bottom: 32px;
}

.card {
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 16px;
  padding: 22px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              background-color 0.25s ease,
              border-color 0.25s ease,
              box-shadow 0.25s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  touch-action: manipulation;
  transform-style: preserve-3d;
  perspective: 1000px;
  will-change: transform;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, var(--card-color, var(--accent-glow)), transparent 70%);
  opacity: 0.4;
  transform: translate(40px, -40px);
  transition: all 0.4s ease;
  pointer-events: none;
}

@media (hover: hover) {
  .card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
  }
  .card:hover::before {
    opacity: 0.7;
    transform: translate(20px, -20px) scale(1.2);
  }
  .card:hover .card-arrow {
    background: var(--accent);
    color: var(--bg-primary);
    transform: rotate(-45deg);
    border-color: var(--accent);
  }
  .card:hover .card-icon {
    transform: scale(1.1) rotate(-5deg);
  }
  .card:hover .card-shortcut {
    opacity: 1;
  }
}

.card:active {
  transform: scale(0.98);
}

.card-status {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 0.5px solid var(--border);
  border-radius: 100px;
  font-size: 10px;
  color: var(--text-secondary);
  font-weight: 500;
  z-index: 2;
}

[data-theme="light"] .card-status {
  background: rgba(255, 255, 255, 0.7);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  position: relative;
}

.status-dot.online {
  background: var(--status-online);
  box-shadow: 0 0 8px var(--status-online);
}

.status-dot.online::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: var(--status-online);
  opacity: 0.4;
  animation: ping 2s ease-out infinite;
}

.status-dot.warning {
  background: var(--status-warning);
  box-shadow: 0 0 8px var(--status-warning);
}

.status-dot.offline {
  background: var(--status-offline);
}

.status-text {
  font-size: 10px;
}

@keyframes ping {
  0% { transform: scale(1); opacity: 0.4; }
  100% { transform: scale(2.5); opacity: 0; }
}

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  position: relative;
  margin-bottom: auto;
}

.card-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-icon svg {
  width: 20px;
  height: 20px;
  transition: stroke-dashoffset 0.4s ease;
}

.card-arrow {
  position: absolute;
  top: 0;
  right: 0;
  width: 32px;
  height: 32px;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  color: var(--text-tertiary);
}

.card:hover .card-status { display: none; }

.card-arrow svg { width: 14px; height: 14px; }

.card-content {
  position: relative;
  margin-top: auto;
}

.card-tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: var(--card-tag-bg, var(--accent-soft));
  border: 0.5px solid var(--card-tag-border, var(--accent-border));
  border-radius: 6px;
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--card-color-text, var(--accent));
  font-weight: 600;
  margin-bottom: 12px;
}

.card h3 {
  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
  letter-spacing: -0.3px;
  line-height: 1.3;
}

.card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 12px;
}

.card-stats {
  display: flex;
  gap: 16px;
  padding-top: 12px;
  border-top: 0.5px solid var(--border);
  margin-top: 8px;
}

.card-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.card-mini-stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 8px;
  border-top: 0.5px solid var(--border);
  margin-top: 8px;
}

.card-stat-value {
  font-size: 18px;
  font-weight: 600;
  color: var(--card-color-text, var(--text-primary));
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: -0.3px;
}

.card-stat-label {
  font-size: 10px;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

.card-shortcut {
  position: absolute;
  bottom: 16px;
  right: 16px;
  width: 22px;
  height: 22px;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-tertiary);
  font-family: 'JetBrains Mono', monospace;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.card.featured {
  grid-column: 1;
  grid-row: 1 / 3;
  padding: 28px;
}

.card.featured::before {
  width: 280px;
  height: 280px;
  transform: translate(80px, -80px);
  opacity: 0.6;
}

.card.featured h3 {
  font-size: 24px;
  margin-bottom: 10px;
}

.card.featured p {
  font-size: 14px;
  max-width: 90%;
}

.card.featured .card-icon {
  width: 52px;
  height: 52px;
}

.card.featured .card-icon svg {
  width: 24px;
  height: 24px;
}

.card.card-wide { grid-column: 2 / 5; }

/* Card colors */
.card[data-color="buxgalteriya"] {
  --card-color: var(--c-buxgalteriya-bg);
  --card-color-text: var(--c-buxgalteriya);
  --card-tag-bg: var(--c-buxgalteriya-bg);
  --card-tag-border: var(--c-buxgalteriya-border);
}
.card[data-color="buxgalteriya"] .card-icon {
  background: var(--c-buxgalteriya-bg);
  color: var(--c-buxgalteriya);
}

.card[data-color="yotoqxona"] {
  --card-color: var(--c-yotoqxona-bg);
  --card-color-text: var(--c-yotoqxona);
  --card-tag-bg: var(--c-yotoqxona-bg);
  --card-tag-border: var(--c-yotoqxona-border);
}
.card[data-color="yotoqxona"] .card-icon {
  background: var(--c-yotoqxona-bg);
  color: var(--c-yotoqxona);
}

.card[data-color="hodimlar"] {
  --card-color: var(--c-hodimlar-bg);
  --card-color-text: var(--c-hodimlar);
  --card-tag-bg: var(--c-hodimlar-bg);
  --card-tag-border: var(--c-hodimlar-border);
}
.card[data-color="hodimlar"] .card-icon {
  background: var(--c-hodimlar-bg);
  color: var(--c-hodimlar);
}

.card[data-color="kutubxona"] {
  --card-color: var(--c-kutubxona-bg);
  --card-color-text: var(--c-kutubxona);
  --card-tag-bg: var(--c-kutubxona-bg);
  --card-tag-border: var(--c-kutubxona-border);
}
.card[data-color="kutubxona"] .card-icon {
  background: var(--c-kutubxona-bg);
  color: var(--c-kutubxona);
}

.card[data-color="yoqlama"] {
  --card-color: var(--c-yoqlama-bg);
  --card-color-text: var(--c-yoqlama);
  --card-tag-bg: var(--c-yoqlama-bg);
  --card-tag-border: var(--c-yoqlama-border);
}
.card[data-color="yoqlama"] .card-icon {
  background: var(--c-yoqlama-bg);
  color: var(--c-yoqlama);
}

/* ============ ACTIVITY ============ */
.activity {
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  border-radius: 16px;
  padding: 20px 24px;
  margin-bottom: 32px;
}

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

.activity-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.2px;
}

.activity-clear {
  font-size: 12px;
  color: var(--text-tertiary);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  font-family: inherit;
  transition: all 0.15s ease;
}

.activity-clear:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.activity-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.activity-empty {
  text-align: center;
  padding: 20px;
  font-size: 13px;
  color: var(--text-tertiary);
}

.activity-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s ease;
}

.activity-item:hover {
  background: var(--bg-elevated);
}

.activity-icon {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.activity-icon svg {
  width: 14px;
  height: 14px;
}

.activity-text {
  flex: 1;
  font-size: 13px;
  color: var(--text-secondary);
}

.activity-text strong {
  color: var(--text-primary);
  font-weight: 500;
}

.activity-time {
  font-size: 11px;
  color: var(--text-muted);
  font-family: 'JetBrains Mono', monospace;
}

/* ============ FOOTER ============ */
.footer {
  padding-top: 24px;
  border-top: 0.5px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

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

.footer-meta {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--text-tertiary);
  flex-wrap: wrap;
  align-items: center;
}

.footer-meta .live {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-weight: 500;
}

.footer-meta .live::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse 2s ease infinite;
}

.kbd-hint {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s ease;
}

.kbd-hint:hover { background: var(--bg-elevated); }

kbd {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ============ COMMAND PALETTE ============ */
.cmdk-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-overlay);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 15vh;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
}

.cmdk-overlay.open {
  opacity: 1;
  visibility: visible;
}

.cmdk {
  width: 100%;
  max-width: 600px;
  background: var(--bg-card);
  border: 0.5px solid var(--border-strong);
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  margin: 0 16px;
  transform: scale(0.95) translateY(-10px);
  transition: transform 0.2s ease;
}

.cmdk-overlay.open .cmdk {
  transform: scale(1) translateY(0);
}

.cmdk-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 0.5px solid var(--border);
}

.cmdk-header svg {
  width: 18px;
  height: 18px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.cmdk-header input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 15px;
  font-family: inherit;
}

.cmdk-header input::placeholder { color: var(--text-tertiary); }
.cmdk-header kbd { font-size: 10px; }

.cmdk-results {
  max-height: 360px;
  overflow-y: auto;
  padding: 8px;
}

.cmdk-empty {
  padding: 32px 20px;
  text-align: center;
  color: var(--text-tertiary);
  font-size: 13px;
}

.cmdk-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.1s ease;
}

.cmdk-item:hover, .cmdk-item.active {
  background: var(--bg-elevated);
}

.cmdk-item-icon {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cmdk-item-icon svg { width: 16px; height: 16px; }

.cmdk-item-content { flex: 1; min-width: 0; }

.cmdk-item-title {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 2px;
}

.cmdk-item-desc {
  font-size: 12px;
  color: var(--text-tertiary);
}

.cmdk-item-shortcut {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-tertiary);
  background: var(--bg-card);
  border: 0.5px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
}

.cmdk-footer {
  display: flex;
  gap: 16px;
  padding: 10px 18px;
  border-top: 0.5px solid var(--border);
  background: var(--bg-secondary);
  font-size: 11px;
  color: var(--text-tertiary);
}

.cmdk-footer span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============ NOTIFICATIONS PANEL ============ */
.notif-panel {
  position: fixed;
  top: 70px;
  right: 32px;
  width: 360px;
  max-height: 480px;
  background: var(--bg-card);
  border: 0.5px solid var(--border-strong);
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s ease;
  overflow: hidden;
}

.notif-panel.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.notif-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 0.5px solid var(--border);
}

.notif-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.notif-clear {
  font-size: 12px;
  color: var(--accent);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.notif-list {
  overflow-y: auto;
  max-height: 400px;
}

.notif-item {
  display: flex;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 0.5px solid var(--border);
  cursor: pointer;
  transition: background 0.15s ease;
  position: relative;
}

.notif-item:hover { background: var(--bg-card-hover); }
.notif-item:last-child { border-bottom: none; }

.notif-item.unread::before {
  content: '';
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
}

.notif-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.notif-icon svg { width: 16px; height: 16px; }

.notif-content { flex: 1; min-width: 0; }

.notif-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 2px;
}

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

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

/* ============ SHORTCUTS HELP ============ */
.shortcuts-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-overlay);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
}

.shortcuts-overlay.open {
  opacity: 1;
  visibility: visible;
}

.shortcuts {
  width: 100%;
  max-width: 440px;
  background: var(--bg-card);
  border: 0.5px solid var(--border-strong);
  border-radius: 14px;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  transform: scale(0.95);
  transition: transform 0.2s ease;
}

.shortcuts-overlay.open .shortcuts { transform: scale(1); }

.shortcuts-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 0.5px solid var(--border);
}

.shortcuts-header h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.shortcuts-close {
  width: 28px;
  height: 28px;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-tertiary);
  transition: all 0.15s ease;
}

.shortcuts-close:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.shortcuts-close svg { width: 16px; height: 16px; }

.shortcuts-list {
  padding: 12px;
}

.shortcut-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

.shortcut-item:hover { background: var(--bg-elevated); }
.shortcut-item span:first-child { color: var(--text-primary); }
.shortcut-item span:last-child { display: flex; gap: 4px; align-items: center; }

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

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 0.5px solid var(--border-strong);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  min-width: 280px;
  max-width: 380px;
  pointer-events: auto;
  transform: translateX(120%);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.hide {
  transform: translateX(120%);
  opacity: 0;
}

.toast-icon {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.toast-icon svg { width: 14px; height: 14px; }

.toast.success .toast-icon {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

.toast.info .toast-icon {
  background: rgba(34, 211, 238, 0.15);
  color: #22d3ee;
}

.toast.warning .toast-icon {
  background: rgba(251, 146, 60, 0.15);
  color: #fb923c;
}

.toast-content { flex: 1; }

.toast-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

.toast-desc {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* ============ ANIMATIONS ============ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.9); }
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 968px) {
  .container { padding: 20px 24px 48px; }
  .greeting { font-size: 30px; letter-spacing: -0.8px; }
  .hero p { font-size: 14px; }
  .stats-bar { grid-template-columns: repeat(2, 1fr); }
  .bento {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 240px 200px 200px;
    gap: 12px;
  }
  .card.featured { grid-column: 1 / 3; grid-row: 1; }
  .card.card-wide { grid-column: 1 / 3; }
  .search-btn { min-width: auto; }
  .search-btn span, .search-btn kbd { display: none; }
  .search-btn { width: 40px; padding: 0; justify-content: center; }
  .notif-panel { width: calc(100vw - 32px); right: 16px; left: 16px; }
}

@media (max-width: 640px) {
  .container { padding: 14px 16px 32px; }
  .navbar { padding: 12px 0; margin-bottom: 24px; flex-wrap: wrap; }
  .brand-logo { width: 38px; height: 38px; border-radius: 9px; }
  .brand-text h1 { font-size: 14px; }
  .brand-text p { font-size: 11px; }
  .nav-actions { gap: 6px; }
  .icon-btn { width: 38px; height: 38px; border-radius: 9px; }
  .icon-btn svg { width: 16px; height: 16px; }
  .lang-btn { height: 38px; padding: 0 10px; border-radius: 9px; }
  .lang-btn span { font-size: 12px; font-weight: 600; }
  .lang-btn svg { display: none; }
  .search-btn { height: 38px; width: 38px; border-radius: 9px; }
  .hero { margin-bottom: 20px; }
  .hero-badge { font-size: 9px; padding: 5px 10px; margin-bottom: 12px; letter-spacing: 0.8px; }
  .hero-badge .dot { width: 5px; height: 5px; }
  .greeting { font-size: 24px; line-height: 1.15; letter-spacing: -0.6px; margin-bottom: 6px; }
  .hero p { font-size: 13px; line-height: 1.55; }
  .stats-bar { grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 16px; }
  .stat { padding: 12px 14px; border-radius: 10px; }
  .stat-label { font-size: 9px; margin-bottom: 4px; }
  .stat-value { font-size: 18px; }
  .stat-value .unit { font-size: 11px; }
  .bento { grid-template-columns: 1fr 1fr; grid-template-rows: auto auto auto; gap: 8px; }
  .card { padding: 16px; border-radius: 14px; min-height: 140px; }
  .card.featured { grid-column: 1 / 3; grid-row: 1; padding: 20px; min-height: 220px; }
  .card.featured h3 { font-size: 19px; letter-spacing: -0.4px; margin-bottom: 6px; }
  .card.featured p { font-size: 13px; max-width: 100%; line-height: 1.5; }
  .card.featured .card-icon { width: 44px; height: 44px; }
  .card.featured .card-icon svg { width: 20px; height: 20px; }
  .card.card-wide { grid-column: 1 / 3; grid-row: 4; min-height: 150px; }
  .card-icon { width: 36px; height: 36px; border-radius: 9px; }
  .card-icon svg { width: 17px; height: 17px; }
  .card-arrow { width: 28px; height: 28px; border-radius: 7px; }
  .card-arrow svg { width: 12px; height: 12px; }
  .card-tag { font-size: 9px; padding: 2px 8px; margin-bottom: 8px; letter-spacing: 0.8px; }
  .card h3 { font-size: 14px; margin-bottom: 4px; letter-spacing: -0.2px; }
  .card p { font-size: 11px; line-height: 1.45; margin-bottom: 8px; }
  .card-stats { gap: 12px; padding-top: 8px; }
  .card-stat-value { font-size: 14px; }
  .card-stat-label { font-size: 9px; }
  .card-status { top: 12px; right: 12px; padding: 3px 8px; }
  .card-status .status-text { display: none; }
  .ambient::before { width: 350px; height: 350px; top: -150px; right: -150px; }
  .ambient::after { width: 300px; height: 300px; }
  .activity { padding: 16px; }
  .footer { margin-top: 24px; padding-top: 16px; flex-direction: column; align-items: flex-start; gap: 8px; }
  .footer-text { font-size: 11px; }
  .footer-meta { font-size: 11px; gap: 12px; }
  .toast-container { bottom: 16px; right: 16px; left: 16px; }
  .toast { min-width: auto; max-width: none; }
  .cmdk-overlay { padding-top: 10vh; }
  .notif-panel { top: 100px; }
}

@media (max-width: 380px) {
  .container { padding: 12px 12px 24px; }
  .brand-text p { display: none; }
  .lang-btn { padding: 0 8px; }
  .nav-actions { gap: 4px; }
  .greeting { font-size: 22px; }
  .hero p { font-size: 12px; }
  .card { padding: 14px; }
  .card.featured { padding: 18px; min-height: 200px; }
  .card.featured h3 { font-size: 17px; }
  .card.featured p { font-size: 12px; }
  .card h3 { font-size: 13px; }
  .card p { font-size: 10.5px; }
}

::selection {
  background: var(--accent);
  color: var(--bg-primary);
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--bg-elevated); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }
