/* ==========================================================================
   STRESSLESS DESIGN SYSTEM
   Style: Playful Minimalism + Controlled Chaos + Modern Tactile UI
   ========================================================================== */

:root {
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Colors */
  --bg-primary: #0d111a;
  --bg-surface-1: #151b27;
  --bg-surface-2: #1e2638;
  --bg-surface-hover: #263147;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(255, 255, 255, 0.16);

  --accent-red: #ff4757;
  --accent-orange: #ff6b35;
  --accent-yellow: #ffd166;
  --accent-green: #06d6a0;
  --accent-blue: #118ab2;
  --accent-purple: #8338ec;
  --accent-pink: #ff70a6;

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-sub: #cbd5e1;

  /* Shadows */
  --shadow-btn: 0 12px 28px -6px rgba(255, 71, 87, 0.45), 0 8px 16px -4px rgba(0, 0, 0, 0.3);
  --shadow-card: 0 16px 36px -8px rgba(0, 0, 0, 0.45), 0 0 0 1px var(--border-subtle);
  --shadow-glow: 0 0 35px -5px rgba(131, 56, 236, 0.35);

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-full: 9999px;

  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
  background-image: 
    radial-gradient(circle at 15% 20%, rgba(255, 75, 75, 0.07) 0%, transparent 40%),
    radial-gradient(circle at 85% 65%, rgba(131, 56, 236, 0.08) 0%, transparent 45%),
    radial-gradient(circle at 50% 90%, rgba(6, 214, 160, 0.05) 0%, transparent 50%);
  background-attachment: fixed;
}

/* Typography Helpers */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  letter-spacing: -0.02em;
  font-weight: 800;
  color: var(--text-main);
}

.highlight-underline {
  position: relative;
  display: inline-block;
  color: var(--accent-yellow);
}

.highlight-underline::after {
  content: "";
  position: absolute;
  bottom: 4px;
  left: 0;
  width: 100%;
  height: 6px;
  background-color: rgba(255, 209, 102, 0.35);
  border-radius: 4px;
  z-index: -1;
}

.highlight-green {
  color: var(--accent-green) !important;
}

.highlight-yellow {
  color: var(--accent-yellow) !important;
}

/* Main Layout */
.app-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

.main-content {
  flex: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px 80px;
  width: 100%;
}

/* ==========================================================================
   SITE HEADER & NAV
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(13, 17, 26, 0.78);
  border-bottom: 1px solid var(--border-subtle);
  padding: 14px 20px;
}

.nav-container {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
  transition: transform var(--transition-spring);
}

.logo-group:active {
  transform: scale(0.92) rotate(-3deg);
}

.logo-icon {
  font-size: 1.6rem;
  filter: drop-shadow(0 2px 6px rgba(255, 209, 102, 0.4));
}

.logo-text {
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}

.logo-dot {
  color: var(--accent-red);
}

.logo-badge {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  background: rgba(255, 71, 87, 0.16);
  color: var(--accent-red);
  padding: 3px 8px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 71, 87, 0.3);
}

.quick-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface-1);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.nav-pill {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
}

.nav-pill:hover {
  color: var(--text-main);
  background: var(--bg-surface-2);
}

.icon-toggle-btn {
  background: var(--bg-surface-1);
  color: var(--text-sub);
  border: 1px solid var(--border-subtle);
  padding: 7px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all var(--transition-fast);
}

.icon-toggle-btn:hover {
  background: var(--bg-surface-2);
  color: #fff;
  border-color: var(--border-highlight);
}

.icon-toggle-btn.is-muted {
  color: var(--accent-red);
  border-color: rgba(255, 71, 87, 0.4);
}

/* ==========================================================================
   HERO & PANIC BUTTON SECTION (Main Focus)
   ========================================================================== */
.hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 48px 0 60px;
  position: relative;
}

.hero-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent-orange);
  background: rgba(255, 107, 53, 0.12);
  border: 1px solid rgba(255, 107, 53, 0.28);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  margin-bottom: 20px;
  text-transform: uppercase;
}

.pulse-indicator {
  width: 8px;
  height: 8px;
  background-color: var(--accent-red);
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.7);
  animation: pulse-ring 1.8s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 10px rgba(255, 71, 87, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 71, 87, 0); }
}

.hero-title {
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  line-height: 1.15;
  margin-bottom: 12px;
}

.hero-subtext {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--text-sub);
  margin-bottom: 34px;
}

.hero-subtext strong {
  color: var(--accent-yellow);
}

/* Giant Panic Button */
.panic-button-wrapper {
  position: relative;
  display: inline-block;
  margin: 15px 0 25px;
  perspective: 600px;
}

.button-shadow-ring {
  position: absolute;
  inset: -12px;
  border-radius: var(--radius-full);
  background: radial-gradient(circle, rgba(255, 71, 87, 0.28) 0%, transparent 70%);
  z-index: 0;
  animation: breath-glow 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes breath-glow {
  0%, 100% { transform: scale(0.96); opacity: 0.6; }
  50% { transform: scale(1.06); opacity: 1; }
}

.panic-btn {
  position: relative;
  z-index: 1;
  background: linear-gradient(180deg, #ff5765 0%, #eb2f40 70%, #c41829 100%);
  border: 4px solid #ff7b88;
  border-radius: var(--radius-full);
  padding: 32px 58px;
  cursor: pointer;
  outline: none;
  user-select: none;
  box-shadow: 
    0 16px 36px -6px rgba(255, 71, 87, 0.6),
    0 6px 0 0 #9f101f,
    inset 0 2px 4px rgba(255, 255, 255, 0.45);
  transition: transform 0.12s cubic-bezier(0.17, 0.89, 0.32, 1.28), box-shadow 0.12s ease;
  min-width: 280px;
}

.panic-btn:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 
    0 22px 42px -6px rgba(255, 71, 87, 0.7),
    0 9px 0 0 #9f101f,
    inset 0 3px 6px rgba(255, 255, 255, 0.55);
}

.panic-btn:active,
.panic-btn.btn-pressed {
  transform: translateY(6px) scale(0.97);
  box-shadow: 
    0 6px 18px -4px rgba(255, 71, 87, 0.4),
    0 1px 0 0 #9f101f,
    inset 0 1px 2px rgba(0, 0, 0, 0.3);
}

.panic-btn-surface {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.btn-inner-text {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 900;
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  letter-spacing: -0.01em;
  display: block;
}

.btn-subtext-hint {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
}

.panic-disclaimer {
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 440px;
  line-height: 1.5;
  margin-bottom: 24px;
}

.panic-disclaimer em {
  color: var(--accent-yellow);
  font-style: normal;
  font-weight: 700;
}

/* Combo Badge */
.combo-badge {
  background: linear-gradient(135deg, #ff4757, #ff6b35);
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 1.15rem;
  padding: 8px 24px;
  border-radius: var(--radius-full);
  margin-bottom: 15px;
  box-shadow: 0 0 25px rgba(255, 107, 53, 0.6);
  animation: combo-bounce 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: inline-block;
  user-select: none;
}

@keyframes combo-bounce {
  0% { transform: scale(0.6) rotate(-8deg); }
  50% { transform: scale(1.18) rotate(4deg); }
  100% { transform: scale(1) rotate(0deg); }
}

/* Stats Card (Visual Joke Counter) */
.stats-card {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 22px 28px;
  max-width: 520px;
  width: 100%;
  box-shadow: var(--shadow-card);
  margin-bottom: 24px;
}

.stats-grid {
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-bottom: 12px;
}

.stat-col {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.stat-value-group {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--text-main);
  line-height: 1;
}

.stat-unit {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.stat-divider {
  width: 1px;
  height: 42px;
  background-color: var(--border-subtle);
}

.stat-milestone {
  font-size: 0.92rem;
  color: var(--accent-yellow);
  font-weight: 600;
  border-top: 1px dashed var(--border-subtle);
  padding-top: 12px;
  margin-top: 6px;
}

/* Random Ridiculous Excuse Box */
.excuse-card {
  background: var(--bg-surface-2);
  border: 1px solid rgba(255, 209, 102, 0.2);
  border-radius: var(--radius-md);
  padding: 18px 24px;
  max-width: 620px;
  width: 100%;
  position: relative;
  text-align: left;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.excuse-card.box-pop {
  animation: excuse-pop 0.3s ease;
}

@keyframes excuse-pop {
  0% { transform: scale(0.98); }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); }
}

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

.excuse-tag {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--accent-yellow);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.excuse-tip {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.excuse-content {
  font-size: 1.05rem;
  font-style: italic;
  color: var(--text-main);
  line-height: 1.5;
}

/* ==========================================================================
   FEATURE SECTIONS SHARED STYLES
   ========================================================================== */
.feature-section {
  padding: 60px 0;
  border-top: 1px solid var(--border-subtle);
  position: relative;
}

.section-heading {
  text-align: center;
  margin-bottom: 38px;
}

.section-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 5px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
  text-transform: uppercase;
  background: rgba(131, 56, 236, 0.15);
  color: #a78bfa;
  border: 1px solid rgba(131, 56, 236, 0.3);
}

.section-title {
  font-size: clamp(1.8rem, 3.8vw, 2.5rem);
  margin-bottom: 10px;
}

.section-subtitle {
  font-size: clamp(0.95rem, 1.8vw, 1.15rem);
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* Shared Buttons */
.btn-primary {
  background: linear-gradient(135deg, var(--accent-red), var(--accent-orange));
  color: #ffffff;
  border: none;
  border-radius: var(--radius-full);
  padding: 14px 30px;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.05rem;
  cursor: pointer;
  box-shadow: 0 8px 20px -4px rgba(255, 71, 87, 0.4);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px -4px rgba(255, 71, 87, 0.55);
}

.btn-primary:active {
  transform: translateY(1px);
}

.btn-secondary {
  background: var(--bg-surface-2);
  color: var(--text-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 12px 24px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-secondary:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-highlight);
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.85rem;
}

/* ==========================================================================
   FEATURE 2: FORTUNE / TAROT MACHINE
   ========================================================================== */
.fortune-interactive-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
}

.tarot-card-container {
  width: 290px;
  height: 420px;
  perspective: 1200px;
  cursor: pointer;
}

.tarot-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
  transform-style: preserve-3d;
  transition: transform 0.65s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: var(--shadow-card);
}

.tarot-card-inner.is-flipped {
  transform: rotateY(180deg);
}

.tarot-card-inner.card-charging {
  animation: card-vibrate 0.1s linear infinite;
}

@keyframes card-vibrate {
  0% { transform: translate(1px, 1px) rotate(0deg); }
  25% { transform: translate(-2px, -1px) rotate(-1deg); }
  50% { transform: translate(2px, 0px) rotate(1deg); }
  70% { transform: translate(-1px, 2px) rotate(0deg); }
  100% { transform: translate(1px, -1px) rotate(-1deg); }
}

.tarot-card-face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

/* Mặt sau lá bài */
.tarot-card-back {
  background: linear-gradient(145deg, #1a162b, #2b1f47);
  border: 2px solid rgba(131, 56, 236, 0.4);
}

.tarot-card-border {
  width: 100%;
  height: 100%;
  border: 1px dashed rgba(255, 255, 255, 0.25);
  border-radius: calc(var(--radius-lg) - 6px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  background: radial-gradient(circle at center, rgba(131, 56, 236, 0.15) 0%, transparent 70%);
}

.tarot-mystic-symbol {
  font-size: 4rem;
  margin-bottom: 16px;
  filter: drop-shadow(0 0 16px rgba(131, 56, 236, 0.8));
  animation: float-slow 3s ease-in-out infinite;
}

@keyframes float-slow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.tarot-back-title {
  font-size: 1.25rem;
  color: #d8b4fe;
  margin-bottom: 8px;
}

.tarot-back-sub {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.tarot-sparkles {
  margin-top: 24px;
  font-size: 1rem;
  letter-spacing: 0.3em;
}

/* Mặt trước lá bài (Kết quả) */
.tarot-card-front {
  background: linear-gradient(145deg, #182030, #131722);
  border: 2px solid rgba(255, 209, 102, 0.45);
  transform: rotateY(180deg);
}

.front-border {
  border-color: rgba(255, 209, 102, 0.25);
  justify-content: space-between;
  padding: 24px 16px;
}

.fortune-type-badge {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
}

.badge-great { background: rgba(6, 214, 160, 0.2); color: #06d6a0; border: 1px solid #06d6a0; }
.badge-good { background: rgba(17, 138, 178, 0.2); color: #38bdf8; border: 1px solid #38bdf8; }
.badge-neutral { background: rgba(255, 209, 102, 0.2); color: #ffd166; border: 1px solid #ffd166; }
.badge-bad { background: rgba(255, 71, 87, 0.2); color: #ff4757; border: 1px solid #ff4757; }
.badge-absurd { background: rgba(255, 112, 166, 0.2); color: #ff70a6; border: 1px solid #ff70a6; }

.fortune-large-emoji {
  font-size: 3.5rem;
  margin: 10px 0;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
}

.fortune-card-title {
  font-size: 1.15rem;
  margin-bottom: 8px;
  color: var(--accent-yellow);
}

.fortune-card-msg {
  font-size: 0.95rem;
  color: var(--text-sub);
  line-height: 1.5;
  margin-bottom: 12px;
}

.fortune-card-advice {
  font-size: 0.82rem;
  background: rgba(255, 255, 255, 0.05);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: #cbd5e1;
  text-align: left;
  width: 100%;
}

.fortune-action-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.fortune-note {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ==========================================================================
   FEATURE 3: SMASH STRESS MINI-GAME
   ========================================================================== */
.game-dashboard {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.game-stats-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.badge-status {
  background: rgba(255, 71, 87, 0.15);
  color: var(--accent-red);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 5px 14px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 71, 87, 0.25);
}

.game-ee-banner {
  background: linear-gradient(135deg, rgba(255, 209, 102, 0.15), rgba(255, 107, 53, 0.15));
  border: 1px solid rgba(255, 209, 102, 0.4);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  margin-bottom: 16px;
  animation: fadeIn 0.3s ease;
}

.badge-egg {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent-yellow);
}

.game-arena {
  width: 100%;
  height: 380px;
  background: #0f1420;
  border: 2px dashed rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
  touch-action: manipulation;
  /* Custom Hammer Cursor on Desktop */
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='36' height='36' viewBox='0 0 36 36'%3E%3Ctext y='28' font-size='28'%3E🔨%3C/text%3E%3C/svg%3E") 6 6, crosshair;
}

.stress-target-item {
  position: absolute;
  background: var(--bg-surface-2);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: inherit;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  user-select: none;
  outline: none;
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.stress-target-item:hover {
  transform: scale(1.1) rotate(0deg) !important;
  border-color: var(--accent-red);
  box-shadow: 0 12px 24px rgba(255, 71, 87, 0.35);
}

.stress-target-item.smashed {
  transform: scale(0.2) rotate(45deg) !important;
  opacity: 0;
  pointer-events: none;
  transition: all 0.28s ease-out;
}

.target-icon {
  font-size: 2.2rem;
  line-height: 1;
}

.target-name {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-sub);
  max-width: 100px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-footer-tip {
  margin-top: 14px;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

/* Win Overlay */
.game-win-overlay {
  position: absolute;
  inset: 0;
  background: rgba(13, 17, 26, 0.92);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 50;
  opacity: 0;
  visibility: hidden;
  transition: all 0.35s ease;
}

.game-win-overlay.active {
  opacity: 1;
  visibility: visible;
}

.win-card {
  background: var(--bg-surface-1);
  border: 2px solid var(--accent-yellow);
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: 0 0 50px rgba(255, 209, 102, 0.25);
  animation: win-pop 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes win-pop {
  0% { transform: scale(0.85); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.win-emoji {
  font-size: 3.5rem;
  display: block;
  margin-bottom: 12px;
}

.win-title {
  font-size: 2rem;
  color: var(--accent-yellow);
  margin-bottom: 8px;
}

.win-subtext {
  font-size: 0.95rem;
  color: var(--text-muted);
}

.win-highlight {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--accent-green);
  margin: 12px 0;
  letter-spacing: -0.01em;
}

.win-praise {
  font-size: 0.95rem;
  color: var(--text-sub);
  margin-bottom: 24px;
  line-height: 1.5;
}

.win-btn {
  width: 100%;
}

/* ==========================================================================
   FEATURE 4: SOUNDBOARD
   ========================================================================== */
.soundboard-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.soundboard-pad {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  user-select: none;
  outline: none;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
  transition: transform var(--transition-fast), border-color var(--transition-fast), background var(--transition-fast);
}

.soundboard-pad:hover {
  background: var(--bg-surface-2);
  border-color: var(--border-highlight);
  transform: translateY(-2px);
}

.soundboard-pad:active,
.soundboard-pad.pad-active {
  transform: translateY(2px) scale(0.98);
  border-color: var(--accent-purple);
  box-shadow: 0 0 20px rgba(131, 56, 236, 0.4);
}

.pad-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--border-subtle);
  transition: transform var(--transition-spring);
}

.pad-active .pad-icon-wrap {
  transform: scale(1.18) rotate(8deg);
}

.pad-icon {
  font-size: 1.8rem;
}

.pad-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.pad-tag {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--accent-purple);
  letter-spacing: 0.04em;
}

.pad-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pad-subtitle {
  font-size: 0.78rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Sound Ripple */
.pad-ripple {
  position: absolute;
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, rgba(131, 56, 236, 0.45) 0%, transparent 70%);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0);
  animation: ripple-spread 0.45s ease-out forwards;
  pointer-events: none;
}

@keyframes ripple-spread {
  to { transform: translate(-50%, -50%) scale(2.2); opacity: 0; }
}

/* ==========================================================================
   FLOATING ELEMENTS, PARTICLES, POPUPS & TOASTS
   ========================================================================== */
#particles-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  overflow: hidden;
}

.floating-text {
  position: fixed;
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 900;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
  pointer-events: none;
  z-index: 1000;
  animation: float-up-fade 0.95s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes float-up-fade {
  0% { transform: translateY(0) scale(0.8); opacity: 1; }
  100% { transform: translateY(-75px) scale(1.15); opacity: 0; }
}

/* Fallback Confetti Particle */
.fallback-particle {
  position: fixed;
  border-radius: 2px;
  pointer-events: none;
  z-index: 998;
  animation: particle-fly 1s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes particle-fly {
  0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  100% { transform: translate(var(--dest-x), var(--dest-y)) rotate(var(--rot)); opacity: 0; }
}

/* Reward Emojis from Mini-game */
.reward-particle {
  position: fixed;
  font-size: 1.6rem;
  pointer-events: none;
  z-index: 1000;
  animation: reward-scatter 0.65s cubic-bezier(0.1, 0.9, 0.2, 1) forwards;
}

@keyframes reward-scatter {
  0% { transform: translate(0, 0) scale(0.6); opacity: 1; }
  100% { transform: translate(var(--vx), var(--vy)) scale(1.2); opacity: 0; }
}

/* Screen Shakes */
.shake-light {
  animation: shake-light-anim 0.25s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

.shake-heavy {
  animation: shake-heavy-anim 0.4s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes shake-light-anim {
  10%, 90% { transform: translate3d(-1px, 0, 0); }
  20%, 80% { transform: translate3d(2px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-3px, 0, 0); }
  40%, 60% { transform: translate3d(3px, 0, 0); }
}

@keyframes shake-heavy-anim {
  10%, 90% { transform: translate3d(-3px, 1px, 0) rotate(-0.5deg); }
  20%, 80% { transform: translate3d(4px, -2px, 0) rotate(0.5deg); }
  30%, 50%, 70% { transform: translate3d(-5px, 2px, 0) rotate(-1deg); }
  40%, 60% { transform: translate3d(5px, -1px, 0) rotate(1deg); }
}

/* Floating Meme Card Popups */
#meme-popup-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column-reverse;
  gap: 14px;
  z-index: 200;
  pointer-events: none;
}

.floating-meme-card {
  pointer-events: auto;
  width: 280px;
  background: var(--bg-surface-1);
  border: 2px solid var(--accent-yellow);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.65);
  overflow: hidden;
  animation: meme-slide-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.floating-meme-card.disappear {
  opacity: 0;
  transform: translateY(20px) scale(0.9);
}

@keyframes meme-slide-in {
  0% { transform: translateY(80px) scale(0.85); opacity: 0; }
  100% { opacity: 1; }
}

.meme-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid var(--border-subtle);
}

.meme-badge {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--accent-yellow);
}

.meme-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  line-height: 1;
  padding: 0 4px;
}

.meme-close-btn:hover {
  color: #fff;
}

.meme-media-wrapper {
  width: 100%;
  min-height: 130px;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.meme-img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  display: block;
}

.meme-svg-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.meme-body {
  padding: 10px 14px;
}

.meme-title {
  font-size: 0.95rem;
  color: var(--text-main);
  margin-bottom: 3px;
}

.meme-caption {
  font-size: 0.8rem;
  color: var(--text-sub);
}

.spin-slow {
  transform-origin: center;
  animation: rotate-inf 8s linear infinite;
}

@keyframes rotate-inf {
  100% { transform: rotate(360deg); }
}

/* Modals & Backdrops */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(13, 17, 26, 0.85);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.25s ease;
}

.modal-backdrop.hidden {
  display: none !important;
}

.modal-card {
  background: var(--bg-surface-1);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6);
  animation: win-pop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-emoji {
  font-size: 3.2rem;
  display: block;
  margin-bottom: 12px;
}

.modal-title {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.modal-desc {
  font-size: 0.95rem;
  color: var(--text-sub);
  line-height: 1.5;
  margin-bottom: 24px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
}

/* Secret Easter Toast */
.secret-easter-toast {
  position: fixed;
  top: 75px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #8338ec, #ff4757);
  color: #fff;
  border-radius: var(--radius-full);
  padding: 12px 28px;
  box-shadow: 0 12px 28px rgba(131, 56, 236, 0.5);
  z-index: 1100;
  text-align: center;
  font-size: 0.92rem;
  font-weight: 700;
  animation: toast-down 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.secret-easter-toast span {
  display: block;
  font-family: var(--font-heading);
  font-size: 1rem;
}

.secret-easter-toast p {
  font-size: 0.8rem;
  font-weight: 500;
  opacity: 0.95;
}

@keyframes toast-down {
  0% { transform: translate(-50%, -40px); opacity: 0; }
  100% { transform: translate(-50%, 0); opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 40px 20px 50px;
  text-align: center;
  background: rgba(10, 13, 20, 0.8);
}

.footer-content {
  max-width: 650px;
  margin: 0 auto;
}

.footer-quote {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
}

.footer-subquote {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 18px;
}

.footer-bottom {
  font-size: 0.78rem;
  color: rgba(148, 163, 184, 0.7);
  border-top: 1px solid var(--border-subtle);
  padding-top: 18px;
}

/* ==========================================================================
   RESPONSIVE DESIGN (Desktop, Tablet & Mobile)
   ========================================================================== */
@media (max-width: 900px) {
  .soundboard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 680px) {
  .site-header {
    padding: 10px 14px;
  }

  .nav-container {
    flex-wrap: wrap;
    justify-content: center;
  }

  .quick-nav {
    order: 3;
    width: 100%;
    justify-content: center;
    overflow-x: auto;
    padding: 3px;
  }

  .nav-pill {
    padding: 5px 10px;
    font-size: 0.78rem;
    white-space: nowrap;
  }

  .hero-section {
    padding: 32px 0 45px;
  }

  .panic-btn {
    padding: 24px 38px;
    min-width: 240px;
  }

  .btn-inner-text {
    font-size: 1.8rem;
  }

  .soundboard-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .soundboard-pad {
    padding: 12px;
    gap: 8px;
  }

  .pad-icon-wrap {
    width: 40px;
    height: 40px;
  }

  .pad-icon {
    font-size: 1.4rem;
  }

  .pad-title {
    font-size: 0.85rem;
  }

  .pad-subtitle {
    font-size: 0.7rem;
  }

  .game-arena {
    height: 320px;
  }

  .stress-target-item {
    padding: 8px 10px;
  }

  .target-icon {
    font-size: 1.8rem;
  }

  .target-name {
    font-size: 0.68rem;
  }

  #meme-popup-container {
    right: 12px;
    bottom: 12px;
    left: 12px;
  }

  .floating-meme-card {
    width: 100%;
  }
}

/* Prefers-reduced-motion for Accessibility */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .shake-light,
  .shake-heavy,
  .button-shadow-ring {
    animation: none !important;
  }
}
