/* Extracted from original HTML <style> */

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

:root {
  --bg-primary: #0f0f23;
  --bg-secondary: #1a1a2e;
  --bg-tertiary: #16213e;
  --text-primary: #e2e8f0;
  --text-secondary: #94a3b8;
  --accent-blue: #78dbff;
  --accent-purple: #a855f7;
  --card-bg: rgba(30, 41, 59, 0.8);
  --border-color: rgba(120, 219, 255, 0.2);
}

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #e2e8f0;
  --bg-tertiary: #cbd5e1;
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --accent-blue: #0ea5e9;
  --accent-purple: #8b5cf6;
  --card-bg: rgba(255, 255, 255, 0.9);
  --border-color: rgba(14, 165, 233, 0.2);
}

body {
  box-sizing: border-box;
  background: linear-gradient(
    135deg,
    var(--bg-primary) 0%,
    var(--bg-secondary) 50%,
    var(--bg-tertiary) 100%
  );
  min-height: 100%;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text-primary);
  position: relative;
  overflow-x: hidden;
  transition: all 0.3s ease;
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--dynamic-wallpaper);
  pointer-events: none;
  z-index: -1;
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  animation: wallpaperGlow 8s ease-in-out infinite;
  opacity: 1;
}

@keyframes wallpaperGlow {
  0%,
  100% {
    opacity: 1;
    filter: blur(0px) brightness(1.2);
  }
  50% {
    opacity: 1;
    filter: blur(1px) brightness(1.4);
  }
}

.wallpaper-programming {
  --dynamic-wallpaper: radial-gradient(
      ellipse at 25% 75%,
      rgba(34, 197, 94, 0.7) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 75% 25%,
      rgba(59, 130, 246, 0.6) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 50% 50%,
      rgba(168, 85, 247, 0.5) 0%,
      transparent 60%
    ),
    linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.85) 0%,
      rgba(30, 41, 59, 0.8) 100%
    ),
    url("data:image/svg+xml,%3Csvg width='120' height='120' viewBox='0 0 120 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cfilter id='glow'%3E%3CfeGaussianBlur stdDeviation='3' result='coloredBlur'/%3E%3CfeMerge%3E%3CfeMergeNode in='coloredBlur'/%3E%3CfeMergeNode in='SourceGraphic'/%3E%3C/feMerge%3E%3C/filter%3E%3C/defs%3E%3Cg fill='%2322c55e' fill-opacity='0.08' filter='url(%23glow)'%3E%3Cpath d='M20 20h10v10h-10zm15 0h10v10h-10zm15 0h10v10h-10zm-30 15h10v10h-10zm15 0h10v10h-10zm15 0h10v10h-10z'/%3E%3Ctext x='70' y='35' font-family='monospace' font-size='12' fill='%233b82f6' fill-opacity='0.1'%3E%7B%7D%3C/text%3E%3Ctext x='70' y='55' font-family='monospace' font-size='10' fill='%23a855f7' fill-opacity='0.1'%3Efunction()%3C/text%3E%3Cpath d='M80 70l5-5-5-5m10 0l5 5-5 5' stroke='%2322c55e' stroke-width='2' fill='none' opacity='0.1'/%3E%3C/g%3E%3C/svg%3E");
}

.wallpaper-language {
  --dynamic-wallpaper: radial-gradient(
      ellipse at 30% 70%,
      rgba(239, 68, 68, 0.7) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 70% 30%,
      rgba(245, 158, 11, 0.6) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 50% 50%,
      rgba(34, 197, 94, 0.5) 0%,
      transparent 60%
    ),
    linear-gradient(
      135deg,
      rgba(127, 29, 29, 0.85) 0%,
      rgba(154, 52, 18, 0.8) 100%
    ),
    url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cfilter id='bookGlow'%3E%3CfeGaussianBlur stdDeviation='2' result='coloredBlur'/%3E%3CfeMerge%3E%3CfeMergeNode in='coloredBlur'/%3E%3CfeMergeNode in='SourceGraphic'/%3E%3C/feMerge%3E%3C/filter%3E%3C/defs%3E%3Cg filter='url(%23bookGlow)'%3E%3Crect x='20' y='25' width='25' height='35' fill='%23ef4444' fill-opacity='0.1' rx='2'/%3E%3Crect x='22' y='27' width='21' height='2' fill='%23f59e0b' fill-opacity='0.15'/%3E%3Crect x='22' y='31' width='18' height='1' fill='%23f59e0b' fill-opacity='0.1'/%3E%3Crect x='22' y='34' width='20' height='1' fill='%23f59e0b' fill-opacity='0.1'/%3E%3Ctext x='55' y='35' font-family='serif' font-size='8' fill='%2322c55e' fill-opacity='0.12'%3EEspañol%3C/text%3E%3Ctext x='55' y='45' font-family='serif' font-size='6' fill='%23ef4444' fill-opacity='0.1'%3EHola mundo%3C/text%3E%3Ccircle cx='75' cy='55' r='8' fill='none' stroke='%23f59e0b' stroke-width='1' opacity='0.08'/%3E%3Cpath d='M70 55h10m-5-5v10' stroke='%2322c55e' stroke-width='1' opacity='0.1'/%3E%3C/g%3E%3C/svg%3E");
}

.wallpaper-trading {
  --dynamic-wallpaper: radial-gradient(
      ellipse at 20% 80%,
      rgba(34, 197, 94, 0.8) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 80% 20%,
      rgba(239, 68, 68, 0.7) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 50% 50%,
      rgba(245, 158, 11, 0.6) 0%,
      transparent 60%
    ),
    linear-gradient(
      135deg,
      rgba(20, 83, 45, 0.85) 0%,
      rgba(127, 29, 29, 0.8) 100%
    ),
    url("data:image/svg+xml,%3Csvg width='140' height='140' viewBox='0 0 140 140' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cfilter id='tradingGlow'%3E%3CfeGaussianBlur stdDeviation='2' result='coloredBlur'/%3E%3CfeMerge%3E%3CfeMergeNode in='coloredBlur'/%3E%3CfeMergeNode in='SourceGraphic'/%3E%3C/feMerge%3E%3C/filter%3E%3C/defs%3E%3Cg filter='url(%23tradingGlow)'%3E%3Cpath d='M20 60l10-15 10 8 10-12 10 5 10-10' stroke='%2322c55e' stroke-width='2' fill='none' opacity='0.15'/%3E%3Cpath d='M20 80l10 10 10-5 10 8 10-3 10 7' stroke='%23ef4444' stroke-width='2' fill='none' opacity='0.12'/%3E%3Crect x='85' y='25' width='8' height='15' fill='%2322c55e' fill-opacity='0.1'/%3E%3Crect x='95' y='30' width='8' height='10' fill='%23ef4444' fill-opacity='0.1'/%3E%3Crect x='105' y='20' width='8' height='20' fill='%2322c55e' fill-opacity='0.1'/%3E%3Ctext x='25' y='100' font-family='monospace' font-size='8' fill='%23f59e0b' fill-opacity='0.12'%3E₿ BTC%3C/text%3E%3Ctext x='60' y='100' font-family='monospace' font-size='6' fill='%2322c55e' fill-opacity='0.1'%3E+12.5%%3C/text%3E%3Ccircle cx='110' cy='70' r='12' fill='none' stroke='%23f59e0b' stroke-width='1' opacity='0.08'/%3E%3Ctext x='105' y='75' font-family='monospace' font-size='8' fill='%23f59e0b' fill-opacity='0.15'%3E$%3C/text%3E%3C/g%3E%3C/svg%3E");
}

.wallpaper-geography {
  --dynamic-wallpaper: radial-gradient(
      ellipse at 25% 75%,
      rgba(14, 165, 233, 0.7) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 75% 25%,
      rgba(34, 197, 94, 0.6) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 50% 50%,
      rgba(168, 85, 247, 0.5) 0%,
      transparent 60%
    ),
    linear-gradient(
      135deg,
      rgba(12, 74, 110, 0.85) 0%,
      rgba(20, 83, 45, 0.8) 100%
    ),
    url("data:image/svg+xml,%3Csvg width='120' height='120' viewBox='0 0 120 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cfilter id='geoGlow'%3E%3CfeGaussianBlur stdDeviation='2' result='coloredBlur'/%3E%3CfeMerge%3E%3CfeMergeNode in='coloredBlur'/%3E%3CfeMergeNode in='SourceGraphic'/%3E%3C/feMerge%3E%3C/filter%3E%3C/defs%3E%3Cg filter='url(%23geoGlow)'%3E%3Ccircle cx='40' cy='40' r='20' fill='none' stroke='%230ea5e9' stroke-width='1' opacity='0.1'/%3E%3Cpath d='M30 40h20m-10-10v20' stroke='%230ea5e9' stroke-width='1' opacity='0.08'/%3E%3Cpath d='M25 35c0-8 7-15 15-15s15 7 15 15c0 8-15 25-15 25s-15-17-15-25z' fill='%2322c55e' fill-opacity='0.1'/%3E%3Ccircle cx='40' cy='35' r='3' fill='%23ef4444' fill-opacity='0.15'/%3E%3Ctext x='70' y='30' font-family='serif' font-size='8' fill='%230ea5e9' fill-opacity='0.12'%3EWorld%3C/text%3E%3Ctext x='70' y='42' font-family='serif' font-size='6' fill='%2322c55e' fill-opacity='0.1'%3ECapitals%3C/text%3E%3Cpath d='M80 60l8-4-8-4v3h-15v2h15v3z' fill='%23a855f7' fill-opacity='0.1'/%3E%3Cpolygon points='90,70 95,75 90,80 85,75' fill='%230ea5e9' fill-opacity='0.08'/%3E%3C/g%3E%3C/svg%3E");
}

.wallpaper-default {
  --dynamic-wallpaper: radial-gradient(
      ellipse at 25% 75%,
      rgba(120, 219, 255, 0.6) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 75% 25%,
      rgba(168, 85, 247, 0.5) 0%,
      transparent 50%
    ),
    radial-gradient(
      ellipse at 50% 50%,
      rgba(34, 197, 94, 0.4) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse at 80% 80%,
      rgba(239, 68, 68, 0.3) 0%,
      transparent 50%
    ),
    linear-gradient(
      135deg,
      rgba(15, 15, 35, 0.9) 0%,
      rgba(26, 26, 46, 0.85) 100%
    ),
    url("data:image/svg+xml,%3Csvg width='150' height='150' viewBox='0 0 150 150' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cfilter id='mainGlow'%3E%3CfeGaussianBlur stdDeviation='3' result='coloredBlur'/%3E%3CfeMerge%3E%3CfeMergeNode in='coloredBlur'/%3E%3CfeMergeNode in='SourceGraphic'/%3E%3C/feMerge%3E%3C/filter%3E%3C/defs%3E%3Cg filter='url(%23mainGlow)'%3E%3Crect x='20' y='25' width='20' height='25' fill='none' stroke='%2378dbff' stroke-width='2' opacity='0.15' rx='3'/%3E%3Crect x='22' y='27' width='16' height='2' fill='%2378dbff' opacity='0.1'/%3E%3Crect x='22' y='31' width='14' height='1' fill='%2378dbff' opacity='0.08'/%3E%3Crect x='22' y='34' width='16' height='1' fill='%2378dbff' opacity='0.08'/%3E%3Ccircle cx='60' cy='40' r='12' fill='none' stroke='%23a855f7' stroke-width='2' opacity='0.12'/%3E%3Cpath d='M55 40h10m-5-5v10' stroke='%23a855f7' stroke-width='1' opacity='0.1'/%3E%3Cpolygon points='90,30 100,35 90,40 85,35' fill='%2322c55e' opacity='0.1'/%3E%3Cpath d='M25 70l8-4 8 6 8-8 8 3' stroke='%23ef4444' stroke-width='2' fill='none' opacity='0.12'/%3E%3Crect x='80' y='65' width='6' height='12' fill='%2322c55e' opacity='0.08'/%3E%3Crect x='88' y='70' width='6' height='7' fill='%23ef4444' opacity='0.08'/%3E%3Crect x='96' y='60' width='6' height='17' fill='%2378dbff' opacity='0.08'/%3E%3Ctext x='110' y='45' font-family='monospace' font-size='10' fill='%23a855f7' opacity='0.1'%3E%7B%7D%3C/text%3E%3Ctext x='110' y='60' font-family='serif' font-size='8' fill='%2322c55e' opacity='0.08'%3EAbc%3C/text%3E%3Ctext x='110' y='75' font-family='monospace' font-size='6' fill='%23ef4444' opacity='0.08'%3E₿$€%3C/text%3E%3Ccircle cx='30' cy='100' r='3' fill='%2378dbff' opacity='0.1'/%3E%3Ccircle cx='70' cy='110' r='4' fill='%23a855f7' opacity='0.08'/%3E%3Ccircle cx='110' cy='100' r='2' fill='%2322c55e' opacity='0.1'/%3E%3Cpath d='M20 120c20-10 40 10 60-5s40 8 50-3' stroke='%2378dbff' stroke-width='1' fill='none' opacity='0.06'/%3E%3C/g%3E%3C/svg%3E");
}

html,
body {
  height: 100%;
}

/* 3D Loader Styles */
.loader-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  overflow: hidden;
}

.loader-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(
      circle at 20% 80%,
      rgba(120, 219, 255, 0.4) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(255, 119, 198, 0.2) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 40% 40%,
      rgba(120, 219, 255, 0.15) 0%,
      transparent 50%
    );
  animation: backgroundPulse 4s ease-in-out infinite;
}

@keyframes backgroundPulse {
  0%,
  100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

.loader-content {
  text-align: center;
  position: relative;
  z-index: 2;
}

.logo-3d {
  position: relative;
  margin-bottom: 2rem;
  perspective: 1000px;
}

.logo-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  transform-style: preserve-3d;
  animation: logoFloat 3s ease-in-out infinite;
}

.logo-icon {
  font-size: 4rem;
  filter: drop-shadow(0 0 20px rgba(120, 219, 255, 0.8));
  animation: iconSpin 4s linear infinite;
}

.logo-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: #78dbff;
  text-shadow: 0 0 10px rgba(120, 219, 255, 0.8),
    0 0 20px rgba(120, 219, 255, 0.6), 0 0 30px rgba(120, 219, 255, 0.4);
  letter-spacing: 2px;
  animation: textGlow 2s ease-in-out infinite alternate;
}

@keyframes logoFloat {
  0%,
  100% {
    transform: translateY(0px) rotateX(0deg);
  }
  50% {
    transform: translateY(-10px) rotateX(5deg);
  }
}

@keyframes iconSpin {
  0% {
    transform: rotateY(0deg);
  }
  100% {
    transform: rotateY(360deg);
  }
}

@keyframes textGlow {
  0% {
    text-shadow: 0 0 10px rgba(120, 219, 255, 0.8),
      0 0 20px rgba(120, 219, 255, 0.6), 0 0 30px rgba(120, 219, 255, 0.4);
  }
  100% {
    text-shadow: 0 0 20px rgba(120, 219, 255, 1),
      0 0 30px rgba(120, 219, 255, 0.8), 0 0 40px rgba(120, 219, 255, 0.6);
  }
}

.glow-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: 2px solid transparent;
  border-radius: 50%;
  background: linear-gradient(
    45deg,
    transparent,
    rgba(120, 219, 255, 0.8),
    transparent
  );
  animation: ringRotate 3s linear infinite;
}

.glow-ring:nth-child(2) {
  width: 200px;
  height: 200px;
  animation-duration: 3s;
  animation-delay: 0s;
}

.ring-2 {
  width: 250px;
  height: 250px;
  animation-duration: 4s;
  animation-delay: -1s;
  border-width: 1px;
}

.ring-3 {
  width: 300px;
  height: 300px;
  animation-duration: 5s;
  animation-delay: -2s;
  border-width: 1px;
  opacity: 0.6;
}

@keyframes ringRotate {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.loading-text {
  color: rgba(226, 232, 240, 0.9);
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  animation: textFade 2s ease-in-out infinite;
}

@keyframes textFade {
  0%,
  100% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

.loading-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.loading-dots span {
  width: 8px;
  height: 8px;
  background: #78dbff;
  border-radius: 50%;
  animation: dotBounce 1.4s ease-in-out infinite both;
  box-shadow: 0 0 10px rgba(120, 219, 255, 0.8);
}

.loading-dots span:nth-child(1) {
  animation-delay: -0.32s;
}
.loading-dots span:nth-child(2) {
  animation-delay: -0.16s;
}
.loading-dots span:nth-child(3) {
  animation-delay: 0s;
}

@keyframes dotBounce {
  0%,
  80%,
  100% {
    transform: scale(0);
    opacity: 0.5;
  }
  40% {
    transform: scale(1);
    opacity: 1;
  }
}

.loader-fade-out {
  animation: loaderFadeOut 1s ease-out forwards;
}

@keyframes loaderFadeOut {
  0% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(1.1);
  }
}

.main-container {
  min-height: 100%;
  background: rgba(15, 15, 35, 0.8);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.main-container.fade-in {
  animation: mainFadeIn 1s ease-out forwards;
}

@keyframes mainFadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.navbar {
  background: var(--card-bg) !important;
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transform: translateZ(0);
}

.navbar-brand {
  font-weight: 700;
  color: var(--accent-blue) !important;
  font-size: 1.6rem;
  text-shadow: 0 0 20px rgba(120, 219, 255, 0.5);
  transition: all 0.3s ease;
  transform: translateZ(10px);
}

.navbar-brand:hover {
  transform: translateZ(15px) scale(1.05);
  text-shadow: 0 0 30px var(--accent-blue);
}

.theme-toggle {
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  color: var(--text-primary);
  border-radius: 50px;
  padding: 0.5rem 1rem;
  transition: all 0.3s ease;
  transform: translateZ(5px);
}

.theme-toggle:hover {
  transform: translateZ(10px) scale(1.05);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  border-color: var(--accent-blue);
}

.nav-link {
  color: rgba(226, 232, 240, 0.9) !important;
  font-weight: 500;
  transition: all 0.3s ease;
  border-radius: 8px;
  margin: 0 4px;
}

.nav-link:hover,
.nav-link.active {
  color: #78dbff !important;
  background: rgba(120, 219, 255, 0.1);
  box-shadow: 0 0 15px rgba(120, 219, 255, 0.3);
  transform: translateY(-1px);
}

.content-area {
  padding: 2rem 0;
  min-height: calc(100vh - 76px);
}

.capsule-card {
  background: var(--card-bg);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid var(--border-color);
  overflow: hidden;
  backdrop-filter: blur(10px);
  transform: translateZ(0) perspective(1000px);
  position: relative;
}

.capsule-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    45deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  transform: translateX(-100%);
  transition: transform 0.6s;
}

.capsule-card:hover::before {
  transform: translateX(100%);
}

.capsule-card:hover {
  transform: translateY(-12px) translateZ(20px) rotateX(5deg);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4), 0 0 40px var(--accent-blue);
  border-color: var(--accent-blue);
}

.capsule-header {
  background: linear-gradient(135deg, #1e293b, #334155);
  color: #e2e8f0;
  padding: 1.5rem;
  border-bottom: 1px solid rgba(120, 219, 255, 0.2);
}

.capsule-title {
  font-size: 1.3rem;
  font-weight: bold;
  margin: 0;
}

.capsule-meta {
  font-size: 0.9rem;
  opacity: 0.9;
  margin-top: 0.5rem;
}

.capsule-body {
  padding: 1.5rem;
}

.capsule-stats {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.stat-item {
  text-align: center;
  flex: 1;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: bold;
  color: #667eea;
}

.stat-label {
  font-size: 0.8rem;
  color: #666;
  text-transform: uppercase;
}

.btn-primary {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border: none;
  border-radius: 12px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  transition: all 0.3s ease;
  color: white;
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4),
    0 0 20px rgba(59, 130, 246, 0.3);
  background: linear-gradient(135deg, #2563eb, #1e40af);
}

.btn-outline-primary {
  border: 2px solid #78dbff;
  color: #78dbff;
  border-radius: 12px;
  font-weight: 600;
  background: transparent;
  transition: all 0.3s ease;
}

.btn-outline-primary:hover {
  background: rgba(120, 219, 255, 0.1);
  border-color: #78dbff;
  color: #78dbff;
  box-shadow: 0 0 20px rgba(120, 219, 255, 0.3);
  transform: translateY(-1px);
}

.flashcard {
  background: rgba(30, 41, 59, 0.9);
  border-radius: 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  min-height: 320px;
  cursor: pointer;
  transition: all 0.6s ease;
  transform-style: preserve-3d;
  position: relative;
  border: 1px solid rgba(120, 219, 255, 0.3);
}

.flashcard.flipped {
  transform: rotateY(180deg);
}

.flashcard:hover {
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(120, 219, 255, 0.2);
}

.flashcard-face {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  border-radius: 20px;
  color: #e2e8f0;
}

.flashcard-back {
  transform: rotateY(180deg);
  background: linear-gradient(135deg, #1e293b, #334155);
  color: #78dbff;
  border: 1px solid rgba(120, 219, 255, 0.4);
}

.quiz-question {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  padding: 2rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  margin-bottom: 2rem;
  color: var(--text-primary);
  backdrop-filter: blur(10px);
}

.quiz-question h4 {
  color: var(--text-primary);
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.quiz-option {
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 1.2rem;
  margin: 0.8rem 0;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  color: var(--text-primary);
  font-weight: 500;
  transform: translateZ(0);
  position: relative;
  overflow: hidden;
}

.quiz-option::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  transition: left 0.5s;
}

.quiz-option:hover::before {
  left: 100%;
}

.quiz-option:hover {
  border-color: var(--accent-blue);
  background: rgba(120, 219, 255, 0.1);
  transform: translateY(-2px) translateZ(5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.quiz-option.selected {
  border-color: var(--accent-blue);
  background: rgba(120, 219, 255, 0.2);
  color: var(--accent-blue);
  font-weight: 600;
}

.quiz-option.correct {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
  font-weight: 600;
}

.quiz-option.incorrect {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  font-weight: 600;
}

.progress-custom {
  height: 8px;
  border-radius: 10px;
  background: #e9ecef;
  overflow: hidden;
}

.progress-bar-custom {
  background: linear-gradient(135deg, #667eea, #764ba2);
  height: 100%;
  border-radius: 10px;
  transition: width 0.3s ease;
}

.form-control,
.form-select {
  border-radius: 10px;
  border: 2px solid #e9ecef;
  padding: 0.75rem 1rem;
  transition: all 0.3s ease;
}

.form-control:focus,
.form-select:focus {
  border-color: #667eea;
  box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.level-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
}

.level-beginner {
  background: rgba(40, 167, 69, 0.2);
  color: #28a745;
}

.level-intermediate {
  background: rgba(255, 193, 7, 0.2);
  color: #ffc107;
}

.level-advanced {
  background: rgba(220, 53, 69, 0.2);
  color: #dc3545;
}

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: #666;
}

.empty-state i {
  font-size: 4rem;
  color: #ccc;
  margin-bottom: 1rem;
}

.search-box {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 15px;
  padding: 1rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.keyboard-shortcut {
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(120, 219, 255, 0.3);
  border-radius: 6px;
  padding: 0.3rem 0.6rem;
  font-size: 0.8rem;
  font-family: "JetBrains Mono", monospace;
  color: #78dbff;
}

.progress-ring-container {
  display: flex;
  justify-content: center;
  align-items: center;
}

.progress-ring {
  position: relative;
  display: inline-block;
}

.progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.8rem;
  font-weight: 600;
  color: #78dbff;
}

@media (max-width: 768px) {
  .capsule-stats {
    flex-direction: column;
    gap: 1rem;
  }

  .stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .flashcard {
    min-height: 250px;
  }
}

.fade-in {
  animation: fadeIn 0.5s ease-in;
}

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

.slide-in {
  animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(0);
  }
}

/* === Universal Responsive System === */

@media (max-width: 1200px) {
  .content-area {
    padding: 1.5rem 1rem;
  }
  .navbar-brand {
    font-size: 1.3rem;
  }
  .btn,
  .form-control,
  .form-select {
    font-size: 0.95rem;
  }
}

@media (max-width: 992px) {
  body {
    padding: 0.5rem;
    overflow-x: hidden;
  }
  .content-area {
    padding: 1rem 0.5rem;
  }

  /* --- Navbar --- */
  .navbar {
    flex-wrap: wrap;
    text-align: center;
    justify-content: center;
    gap: 0.5rem;
  }

  .nav-link {
    padding: 0.4rem 0.8rem;
    font-size: 0.9rem;
  }

  /* --- Learn Mode Header --- */
  .learn-header,
  .capsule-header,
  .author-header,
  .library-header {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 0.6rem;
  }

  .learn-header select,
  .capsule-header select {
    width: 100%;
  }

  .learn-header .btn-group,
  .capsule-header .btn-group,
  .author-header .btn-group {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .learn-header .btn,
  .capsule-header .btn,
  .author-header .btn {
    flex: 1 1 45%;
    min-width: 120px;
  }

  /* --- Buttons in modals, forms, etc --- */
  .modal-footer,
  .d-flex.gap-2,
  .author-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
  }

  .modal-footer button,
  .author-actions button {
    flex: 1 1 45%;
    min-width: 120px;
  }

  /* --- Capsules & Cards --- */
  .capsule-card {
    margin-bottom: 1.2rem;
  }

  .capsule-stats {
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
  }

  /* --- Flashcards --- */
  .flashcard {
    min-height: 240px;
    font-size: 0.95rem;
  }

  /* --- Quiz --- */
  .quiz-question {
    padding: 1rem;
  }

  .quiz-option {
    font-size: 0.9rem;
    padding: 0.8rem 1rem;
  }

  /* --- Search boxes --- */
  .search-box,
  .search-container {
    width: 100%;
    margin: 0.5rem 0;
  }

  /* --- Text and heading tweaks --- */
  h1,
  h2,
  h3 {
    font-size: 1.4rem;
  }

  h4,
  h5 {
    font-size: 1.1rem;
  }

  /* --- Prevent overflow --- */
  * {
    word-wrap: break-word;
  }
}

@media (max-width: 768px) {
  /* --- Global scaling --- */
  html,
  body {
    font-size: 15px;
  }

  /* --- Navbar --- */
  .navbar-brand {
    font-size: 1.2rem;
  }

  /* --- Buttons --- */
  .btn {
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
  }

  /* --- Tabs (Notes / Flashcards / Quiz) --- */
  .nav-tabs {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .nav-tabs .nav-link {
    flex: 1 1 30%;
    text-align: center;
  }

  /* --- Flashcards smaller --- */
  .flashcard {
    min-height: 220px;
    padding: 1rem;
  }

  /* --- Quiz --- */
  .quiz-question h4 {
    font-size: 1rem;
  }

  /* --- Notes list --- */
  .notes-list .note-item {
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
  }

  /* --- Adjust headers --- */
  .capsule-header h3,
  .learn-header h3 {
    font-size: 1.2rem;
  }

  .learn-header .btn-group {
    flex-direction: row;
    justify-content: space-around;
  }

  /* --- Reduce card padding --- */
  .capsule-body,
  .author-section,
  .library-section {
    padding: 1rem;
  }

  /* --- Footer & small elements --- */
  .keyboard-shortcut {
    font-size: 0.75rem;
  }
}

@media (max-width: 576px) {
  /* --- Font Scaling --- */
  html,
  body {
    font-size: 14px;
  }

  /* --- General Layout --- */
  .content-area {
    padding: 0.75rem;
  }

  /* --- Buttons --- */
  .btn {
    padding: 0.5rem 0.8rem;
    font-size: 0.85rem;
  }

  .btn-group {
    flex-direction: column;
    align-items: center;
  }

  .btn-group .btn {
    width: 100%;
  }

  /* --- Input fields --- */
  .form-control,
  .form-select {
    font-size: 0.9rem;
    width: 100%;
  }

  /* --- Headings --- */
  .navbar-brand {
    font-size: 1rem;
  }

  h1,
  h2,
  h3 {
    font-size: 1.2rem;
  }

  /* --- Cards --- */
  .capsule-card {
    border-radius: 15px;
    margin: 0.8rem 0;
  }

  /* --- Flashcards --- */
  .flashcard {
    font-size: 0.85rem;
  }

  /* --- Quiz --- */
  .quiz-option {
    font-size: 0.85rem;
    padding: 0.7rem 0.9rem;
  }

  /* --- Loader --- */
  .loading-text {
    font-size: 0.9rem;
  }

  /* --- Center small icons --- */
  i,
  svg {
    transform: scale(0.9);
  }
}

/* ===  Navbar Toggle Icon (Hamburger Menu) Visible in Dark Mode === */

.navbar-toggler {
  border: none !important;
  outline: none !important;
}

.navbar-toggler-icon {
  background-image: none !important;
  position: relative;
  width: 1.6rem;
  height: 1.4rem;
  display: inline-block;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after,
.navbar-toggler-icon span {
  content: "";
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  margin: 4px 0;
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Light theme adjustment (just in case) */
[data-theme="light"] .navbar-toggler-icon::before,
[data-theme="light"] .navbar-toggler-icon::after,
[data-theme="light"] .navbar-toggler-icon span {
  background-color: #1e293b;
}

/* Dark theme adjustment */
[data-theme="dark"] .navbar-toggler-icon::before,
[data-theme="dark"] .navbar-toggler-icon::after,
[data-theme="dark"] .navbar-toggler-icon span {
  background-color: #e2e8f0;
}

/* Optional: a subtle glow for visibility */
[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon::before,
[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon::after,
[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon span {
  background-color: #78dbff;
  box-shadow: 0 0 6px rgba(120, 219, 255, 0.6);
}

.navbar-nav {
  display: flex !important;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  flex-wrap: nowrap !important;
}

.navbar-nav .nav-link {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 10px;
  color: var(--text-primary) !important;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
  background: rgba(120, 219, 255, 0.15);
  color: #78dbff !important;
  box-shadow: 0 0 10px rgba(120, 219, 255, 0.2);
}

.nav-tabs {
  display: flex !important;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.6rem;
  visibility: visible !important;
  opacity: 1 !important;
  z-index: 5;
}

.nav-tabs .nav-link {
  flex: 1 1 auto;
  text-align: center;
  padding: 0.7rem 1.1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(120, 219, 255, 0.15);
  color: var(--text-primary);
  font-weight: 500;
  transition: all 0.3s ease;
}

.nav-tabs .nav-link.active {
  background: rgba(120, 219, 255, 0.2);
  color: #78dbff !important;
  border-color: rgba(120, 219, 255, 0.5);
}

.nav-tabs .nav-link:hover {
  transform: translateY(-2px);
  color: #78dbff !important;
}

.learn-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.learn-header select {
  flex: 1 1 auto;
  min-width: 160px;
}

.learn-header .btn-group {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: nowrap;
}

.learn-header .btn {
  flex: 0 1 auto;
  min-width: 110px;
}

.library-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.6rem;
}

.library-header h3 {
  flex: 1;
  text-align: left;
}

.library-header .btn-group {
  display: flex;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 0.5rem;
}

.library-header .btn {
  flex: 0 1 auto;
  min-width: 110px;
}

.capsule-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.6rem;
}

.capsule-header .btn-group {
  display: flex;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 0.5rem;
}

.capsule-header .btn {
  flex: 0 1 auto;
  min-width: 110px;
}

@media (max-width: 768px) {
  .nav-tabs {
    flex-wrap: wrap;
  }

  .nav-tabs .nav-link {
    flex: 1 1 30%;
    font-size: 0.95rem;
  }

  .library-header,
  .learn-header,
  .capsule-header {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
  }

  .library-header .btn-group,
  .learn-header .btn-group,
  .capsule-header .btn-group {
    flex-wrap: wrap;
    justify-content: center;
  }

  .library-header .btn,
  .learn-header .btn,
  .capsule-header .btn {
    flex: 1 1 45%;
    min-width: 130px;
  }
}

@media (max-width: 576px) {
  .nav-tabs .nav-link {
    flex: 1 1 45%;
    font-size: 0.9rem;
    padding: 0.5rem 0.8rem;
  }

  .library-header .btn,
  .learn-header .btn,
  .capsule-header .btn {
    width: 100%;
  }
}

.navbar-toggler {
  border: none !important;
  outline: none !important;
}

.navbar-toggler-icon {
  background-image: none !important;
  position: relative;
  width: 1.6rem;
  height: 1.4rem;
  display: inline-block;
}

.navbar-toggler-icon::before,
.navbar-toggler-icon::after,
.navbar-toggler-icon span {
  content: "";
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  margin: 4px 0;
  border-radius: 2px;
  transition: all 0.3s ease;
}

[data-theme="light"] .navbar-toggler-icon::before,
[data-theme="light"] .navbar-toggler-icon::after,
[data-theme="light"] .navbar-toggler-icon span {
  background-color: #1e293b;
}

[data-theme="dark"] .navbar-toggler-icon::before,
[data-theme="dark"] .navbar-toggler-icon::after,
[data-theme="dark"] .navbar-toggler-icon span {
  background-color: #e2e8f0;
}

[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon::before,
[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon::after,
[data-theme="dark"] .navbar-toggler:hover .navbar-toggler-icon span {
  background-color: #78dbff;
  box-shadow: 0 0 6px rgba(120, 219, 255, 0.6);
}

/* Navbar Tabs (Library / Author / Learn) fixed horizontally */
.navbar-nav {
  display: flex !important;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  flex-wrap: nowrap !important;
}

.navbar-nav .nav-link {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1rem;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary) !important;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link.active,
.navbar-nav .nav-link:hover {
  background: rgba(120, 219, 255, 0.15);
  color: #78dbff !important;
  box-shadow: 0 0 10px rgba(120, 219, 255, 0.25);
}

/* Keep Learn buttons in one line */
.learn-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.6rem;
}

.learn-header select {
  flex: 1 1 auto;
  min-width: 160px;
}

.learn-header .btn-group {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.5rem;
}

.learn-header .btn {
  flex: 0 1 auto;
  min-width: 120px;
}

/* Responsive: for smaller devices but still horizontal */
@media (max-width: 768px) {
  .navbar-nav {
    gap: 0.7rem;
    flex-wrap: wrap;
  }

  .learn-header {
    flex-wrap: wrap;
    justify-content: center;
  }

  .learn-header .btn,
  .learn-header select {
    flex: 1 1 45%;
    min-width: 120px;
  }
}

/* Label next to theme toggle */
.theme-toggle {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.theme-label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.3s ease;
}

.learn-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.learn-header select,
.learn-header .btn {
  font-size: 0.95rem;
  padding: 0.45rem 0.9rem;
  border-radius: 8px;
}

.learn-header .btn-group {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 0.5rem;
}

@media (max-width: 768px) {
  .learn-header {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.6rem;
  }

  .learn-header select,
  .learn-header .btn {
    flex: 0 1 auto;
    width: auto;
    font-size: 0.9rem;
  }

  .learn-header .btn-group {
    flex-wrap: nowrap;
    justify-content: center;
  }
}

.learn-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.learn-header select {
  flex: 1 1 180px;
  max-width: 250px;
  font-size: 0.95rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
}

.learn-header .btn {
  flex: 0 0 auto;
  white-space: nowrap;
  font-size: 0.9rem;
  padding: 0.55rem 1.1rem;
  border-radius: 10px;
  text-align: center;
}

@media (max-width: 768px) {
  .learn-header {
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
  }

  .learn-header select {
    flex: 1 1 45%;
    min-width: 140px;
  }

  .learn-header .btn {
    flex: 1 1 45%;
    min-width: 120px;
  }
}

/* 📚 Library Section */
#library-view .d-flex.justify-content-between.align-items-center {
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

#library-view .d-flex.justify-content-between.align-items-center > div {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.6rem;
}

/* 📘 Learn Section */
#learn-view .d-flex.justify-content-between.align-items-center {
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

#learn-view .d-flex.justify-content-between.align-items-center > div {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.6rem;
}

#learn-view select {
  flex: 0 0 auto;
  min-width: 160px;
  max-width: 220px;
  white-space: nowrap;
}

#learn-view .btn {
  flex: 0 0 auto;
  min-width: 110px;
  white-space: nowrap;
  text-align: center;
}

@media (max-width: 768px) {
  #library-view .d-flex.justify-content-between.align-items-center,
  #learn-view .d-flex.justify-content-between.align-items-center {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
    gap: 0.5rem;
  }

  #library-view h2,
  #learn-view h2 {
    width: 100%;
    text-align: center;
    margin-bottom: 0.5rem;
  }

  #library-view .btn,
  #learn-view .btn,
  #learn-view select {
    flex: 0 1 45%;
    min-width: 120px;
  }
}

/* Prevent buttons overflow on small screens */
@media (max-width: 768px) {
  #library-view .d-flex.justify-content-between.align-items-center,
  #learn-view .d-flex.justify-content-between.align-items-center {
    flex-wrap: wrap !important;
    justify-content: center !important;
    text-align: center !important;
    gap: 0.6rem !important;
  }

  #library-view h2,
  #learn-view h2 {
    width: 100%;
    text-align: center;
  }

  #library-view .btn,
  #learn-view .btn,
  #learn-view select {
    flex: 1 1 45% !important;
    min-width: 120px !important;
    max-width: 180px !important;
    white-space: nowrap;
  }
}
/* Fix: Make Select a capsule dropdown wider */
#learn-view select {
  min-width: 220px !important;
  max-width: 280px !important;
  width: auto !important;

} /* FIX: Center Library buttons on mobile (stack vertically) */
@media (max-width: 768px) {
  #library-view .d-flex.justify-content-between.align-items-center {
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 10px !important;
    text-align: center !important;
  }

  #library-view h2 {
    text-align: center !important;
    margin-bottom: 0.5rem !important;
  }

  #library-view .d-flex.justify-content-between.align-items-center > div {
    display: flex;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100%;
  }

  #library-view .btn.btn-primary {
    order: 1; /* New Capsule */
  }
  #library-view .btn.btn-outline-primary {
    order: 2; /* Import JSON */
  }
  #library-view .btn.btn-outline-success {
    order: 3; /* Export All */
  }

  #library-view .btn {
    width: 80% !important;
    max-width: 300px !important;
  }
}
@media (max-width: 768px) {
  #learn-view #export-btn {
    display: none !important;
  }
}
.nav-tabs {
  padding-bottom: 15px; 
  border-bottom: 1px solid #dee2e6;
}
