
/* ============================================================
   PandaCo Design System v4 — Comprehensive Global Tokens
   ============================================================ */

:root {
  /* Colors */
  --bg: #050505;
  --bg-elevated: #0a0a0a;
  --bg-glass: rgba(10,10,10,0.8);
  --border: rgba(255,255,255,0.06);
  --border-hover: rgba(255,255,255,0.12);
  --text: #fafafa;
  --text-secondary: #71717a;
  --text-muted: #52525b;
  
  /* Accents */
  --accent: #818cf8;
  --accent-glow: rgba(129,140,248,0.15);
  --accent-subtle: rgba(129,140,248,0.08);
  --success: #34d399;
  --warning: #fbbf24;
  --error: #f87171;
  
  /* Spacing */
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px;
  --space-5: 20px; --space-6: 24px; --space-8: 32px; --space-10: 40px;
  --space-12: 48px; --space-16: 64px; --space-20: 80px;
  
  /* Typography */
  --font-sans: 'Inter', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Noto Serif SC', 'STSong', 'Georgia', serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
  --text-xs: 0.75rem; --text-sm: 0.875rem; --text-base: 1rem;
  --text-lg: 1.125rem; --text-xl: 1.25rem; --text-2xl: 1.5rem;
  --text-3xl: 1.875rem; --text-4xl: 2.25rem;
  
  /* Layout */
  --nav-height: 56px;
  --container: 1120px; --container-sm: 720px; --container-xs: 480px;
  
  /* Radius */
  --radius-xs: 6px; --radius-sm: 8px; --radius: 12px;
  --radius-lg: 16px; --radius-xl: 20px; --radius-full: 9999px;
  
  /* Transitions */
  --transition: 0.2s ease;
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.5);
}

/* Base Reset & Global Styles */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; outline: none; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-rendering: optimizeLegibility; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  max-width: 100vw;
}

/* Global Selection */
::selection { background: rgba(129,140,248,0.3); color: #fff; }

/* Global Scrollbar */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--border-hover); }

/* Typography */
h1, h2, h3, h4, h5, h6 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
p { margin-bottom: 1rem; }
a { color: inherit; text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent); }

/* Form Elements */
input, textarea, select { font: inherit; }
input::placeholder, textarea::placeholder { color: var(--text-muted); }

/* Buttons */
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; transition: all var(--transition); }
button:hover, button:active { transform: translateY(-1px); }
button:active { transform: translateY(0); }

/* Loading Skeleton */
@keyframes pulse { 0%, 100% { opacity: 0.4; } 50% { opacity: 0.8; } }
.skeleton { height: 20px; background: rgba(255,255,255,0.05); border-radius: var(--radius-sm); animation: pulse 1.5s infinite; margin-bottom: var(--space-2); }

/* Focus States for Accessibility */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Page Load Fade-In */
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
body { animation: fadeIn 0.4s ease-out; }

/* Print Styles */
@media print {
  nav, footer, .pc-search, .breadcrumb, button:not(.print-show), .hero-search-wrap { display: none !important; }
  body { background: #fff; color: #000; }
  a[href]:after { content: " (" attr(href) ")"; font-size: 0.8em; }
}

/* Dark Mode Auto-Detect */
@media (prefers-color-scheme: dark) {
  :root { --bg: #050505; --text: #fafafa; }
}
