:root {
  /* Motion & Typography Tokens */
  --ease-butter: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-heading: 'Bricolage Grotesque', var(--font-sans);
  --font-mono: 'JetBrains Mono', monospace;

  /* Fluid Spacing Scale */
  --space-xs: clamp(0.5rem, 1vw, 0.75rem);
  --space-sm: clamp(0.75rem, 1.5vw, 1.25rem);
  --space-md: clamp(1.25rem, 3vw, 2.5rem);
  --space-lg: clamp(2.5rem, 6vw, 4.5rem);
}

/* ==========================================================================
   THEME SYSTEM — 10 Themes (5 dark + 5 light, alternating on click)
   Every theme fully defines the entire color schema: backgrounds, cards,
   surfaces, borders, text inks, accents (p1-p3), semantic colors, shadows,
   the ambient aura glows, and the mobile drawer background. Switching
   `data-theme` recolors 100% of the site — buttons, chips, glows, cards,
   drawer — via CSS custom props.
   Dark themes deliberately vary in brightness (black, navy, forest, violet,
   cement grey) so each one reads as its own shade.
   ========================================================================== */

/* Theme 1/10 — dark (default) · deep indigo black */
:root,
:root[data-theme="dark"] {
  --background: #121426;
  --nav-bg: rgba(18, 20, 38, 0.88);
  --menu-bg: rgba(18, 20, 38, 0.92);
  --card: rgba(24, 32, 53, 0.78);
  --card-solid: #15192c;
  --card-hover: rgba(38, 48, 75, 0.85);
  --surface-1: rgba(99, 102, 241, 0.15);
  --surface-2: rgba(16, 185, 129, 0.15);
  --surface-3: rgba(245, 158, 11, 0.15);
  --surface-4: rgba(236, 72, 153, 0.15);
  --border: rgba(99, 102, 241, 0.22);
  --border-strong: rgba(139, 92, 246, 0.45);
  --bd2: #334155;

  --aura-1: rgba(129, 140, 248, 0.3);
  --aura-2: rgba(167, 139, 250, 0.22);
  --aura-3: rgba(240, 171, 252, 0.14);
  --aura-opacity: 0.5;

  --foreground: #f8fafc;
  --ink-1: #ffffff;
  --ink-2: #cbd5e1;
  --ink-3: #94a3b8;
  --ink-4: #64748b;

  --p1: #818cf8;
  --p2: #a78bfa;
  --p3: #f0abfc;
  --g1: #10b981;
  --g2: #22d3ee;
  --o1: #fbbf24;
  --o2: #f97316;
  --r1: #f472b6;
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --card-hover-shadow: 0 16px 45px rgba(99, 102, 241, 0.25);
  color-scheme: dark;
}

/* Theme 2/10 — light · paper indigo */
:root[data-theme="light"] {
  --background: #f4f5fa;
  --nav-bg: rgba(244, 245, 250, 0.88);
  --menu-bg: rgba(244, 245, 250, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #ffffff;
  --surface-1: #f5f4ff;
  --surface-2: #f0fdf4;
  --surface-3: #fffbeb;
  --surface-4: #fdf2f8;
  --border: rgba(99, 102, 241, 0.12);
  --border-strong: rgba(99, 102, 241, 0.25);
  --bd2: #d6d9e6;

  --aura-1: rgba(99, 102, 241, 0.12);
  --aura-2: rgba(139, 92, 246, 0.09);
  --aura-3: rgba(217, 70, 239, 0.05);
  --aura-opacity: 0.5;

  --foreground: #0b0c16;
  --ink-1: #111322;
  --ink-2: #282f48;
  --ink-3: #5a6078;
  --ink-4: #989cb3;

  --p1: #6366f1;
  --p2: #8b5cf6;
  --p3: #d946ef;
  --g1: #059669;
  --g2: #06b6d4;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #ec4899;
  --card-shadow: 0 8px 30px rgba(15, 23, 42, 0.05);
  --card-hover-shadow: 0 16px 45px rgba(99, 102, 241, 0.16);
  color-scheme: light;
}

/* Theme 3/10 — ocean · dark navy blue (not black) */
:root[data-theme="ocean"] {
  --background: #14233a;
  --nav-bg: rgba(20, 35, 58, 0.88);
  --menu-bg: rgba(20, 35, 58, 0.92);
  --card: rgba(22, 38, 62, 0.82);
  --card-solid: #1a2c47;
  --card-hover: rgba(30, 52, 84, 0.85);
  --surface-1: rgba(56, 189, 248, 0.15);
  --surface-2: rgba(99, 102, 241, 0.15);
  --surface-3: rgba(14, 165, 233, 0.15);
  --surface-4: rgba(45, 212, 191, 0.15);
  --border: rgba(56, 189, 248, 0.22);
  --border-strong: rgba(99, 102, 241, 0.45);
  --bd2: #2a4266;

  --aura-1: rgba(56, 189, 248, 0.3);
  --aura-2: rgba(99, 102, 241, 0.22);
  --aura-3: rgba(45, 212, 191, 0.14);
  --aura-opacity: 0.5;

  --foreground: #f0f9ff;
  --ink-1: #ffffff;
  --ink-2: #cfe3f5;
  --ink-3: #8fb3d4;
  --ink-4: #5d84a8;

  --p1: #38bdf8;
  --p2: #818cf8;
  --p3: #22d3ee;
  --g1: #2dd4bf;
  --g2: #38bdf8;
  --o1: #fbbf24;
  --o2: #fb923c;
  --r1: #f472b6;
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --card-hover-shadow: 0 16px 45px rgba(56, 189, 248, 0.25);
  color-scheme: dark;
}

/* Theme 4/10 — sunrise · warm cream / amber */
:root[data-theme="sunrise"] {
  --background: #fff9ef;
  --nav-bg: rgba(255, 249, 239, 0.88);
  --menu-bg: rgba(255, 249, 239, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #fffdf8;
  --surface-1: #fff4e0;
  --surface-2: #fef3e2;
  --surface-3: #fff3c9;
  --surface-4: #ffe9d6;
  --border: rgba(249, 115, 22, 0.14);
  --border-strong: rgba(217, 119, 6, 0.35);
  --bd2: #e8dcc8;

  --aura-1: rgba(249, 115, 22, 0.13);
  --aura-2: rgba(234, 179, 8, 0.09);
  --aura-3: rgba(251, 146, 60, 0.06);
  --aura-opacity: 0.5;

  --foreground: #2a1c08;
  --ink-1: #38280f;
  --ink-2: #6b4f26;
  --ink-3: #96784a;
  --ink-4: #b49a72;

  --p1: #f97316;
  --p2: #d97706;
  --p3: #fb923c;
  --g1: #16a34a;
  --g2: #0891b2;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #db2777;
  --card-shadow: 0 8px 30px rgba(120, 72, 20, 0.08);
  --card-hover-shadow: 0 16px 45px rgba(249, 115, 22, 0.18);
  color-scheme: light;
}

/* Theme 5/10 — lavender · luminous lilac / lavender cloud */
:root[data-theme="lavender"] {
  --background: #f7f5ff;
  --nav-bg: rgba(247, 245, 255, 0.88);
  --menu-bg: rgba(247, 245, 255, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #faf8ff;
  --surface-1: #f1edff;
  --surface-2: #faf5ff;
  --surface-3: #fdf4ff;
  --surface-4: #eef2ff;
  --border: rgba(124, 58, 237, 0.14);
  --border-strong: rgba(124, 58, 237, 0.32);
  --bd2: #ded7f5;

  --aura-1: rgba(124, 58, 237, 0.14);
  --aura-2: rgba(168, 85, 247, 0.1);
  --aura-3: rgba(236, 72, 153, 0.06);
  --aura-opacity: 0.5;

  --foreground: #140b2a;
  --ink-1: #1a0f35;
  --ink-2: #48386b;
  --ink-3: #756396;
  --ink-4: #a497be;

  --p1: #7c3aed;
  --p2: #a855f7;
  --p3: #ec4899;
  --g1: #059669;
  --g2: #06b6d4;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #db2777;
  --card-shadow: 0 8px 30px rgba(60, 20, 110, 0.06);
  --card-hover-shadow: 0 16px 45px rgba(124, 58, 237, 0.18);
  color-scheme: light;
}

/* Theme 6/10 — bloom · soft pink / violet */
:root[data-theme="bloom"] {
  --background: #fdf4f8;
  --nav-bg: rgba(253, 244, 248, 0.88);
  --menu-bg: rgba(253, 244, 248, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #fffafc;
  --surface-1: #fdeff6;
  --surface-2: #fdf2f8;
  --surface-3: #fef3f2;
  --surface-4: #f5f0ff;
  --border: rgba(236, 72, 153, 0.14);
  --border-strong: rgba(168, 85, 247, 0.35);
  --bd2: #ecd9e2;

  --aura-1: rgba(236, 72, 153, 0.13);
  --aura-2: rgba(168, 85, 247, 0.09);
  --aura-3: rgba(244, 114, 182, 0.06);
  --aura-opacity: 0.5;

  --foreground: #2b0a1c;
  --ink-1: #3c1228;
  --ink-2: #7a3a5b;
  --ink-3: #a56a87;
  --ink-4: #bd90a6;

  --p1: #ec4899;
  --p2: #a855f7;
  --p3: #f472b6;
  --g1: #10b981;
  --g2: #06b6d4;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #ec4899;
  --card-shadow: 0 8px 30px rgba(150, 40, 90, 0.08);
  --card-hover-shadow: 0 16px 45px rgba(236, 72, 153, 0.18);
  color-scheme: light;
}

/* Theme 7/10 — forge · dark violet */
:root[data-theme="forge"] {
  --background: #221735;
  --nav-bg: rgba(34, 23, 53, 0.88);
  --menu-bg: rgba(34, 23, 53, 0.92);
  --card: rgba(38, 25, 60, 0.82);
  --card-solid: #2b1c44;
  --card-hover: rgba(50, 34, 76, 0.85);
  --surface-1: rgba(167, 139, 250, 0.15);
  --surface-2: rgba(244, 114, 182, 0.15);
  --surface-3: rgba(251, 191, 36, 0.15);
  --surface-4: rgba(56, 189, 248, 0.15);
  --border: rgba(167, 139, 250, 0.24);
  --border-strong: rgba(244, 114, 182, 0.45);
  --bd2: #453062;

  --aura-1: rgba(167, 139, 250, 0.3);
  --aura-2: rgba(244, 114, 182, 0.22);
  --aura-3: rgba(56, 189, 248, 0.12);
  --aura-opacity: 0.5;

  --foreground: #faf5ff;
  --ink-1: #ffffff;
  --ink-2: #e3d5f5;
  --ink-3: #b39acb;
  --ink-4: #7d6694;

  --p1: #a78bfa;
  --p2: #f472b6;
  --p3: #f0abfc;
  --g1: #2dd4bf;
  --g2: #22d3ee;
  --o1: #fbbf24;
  --o2: #fb923c;
  --r1: #f472b6;
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --card-hover-shadow: 0 16px 45px rgba(167, 139, 250, 0.25);
  color-scheme: dark;
}

/* Theme 8/10 — breeze · ice blue */
:root[data-theme="breeze"] {
  --background: #f0f7fd;
  --nav-bg: rgba(240, 247, 253, 0.88);
  --menu-bg: rgba(240, 247, 253, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #f7fbff;
  --surface-1: #e8f4fe;
  --surface-2: #eff8ff;
  --surface-3: #f4faff;
  --surface-4: #eef2ff;
  --border: rgba(14, 165, 233, 0.14);
  --border-strong: rgba(99, 102, 241, 0.3);
  --bd2: #d3e0ec;

  --aura-1: rgba(14, 165, 233, 0.13);
  --aura-2: rgba(99, 102, 241, 0.09);
  --aura-3: rgba(34, 211, 238, 0.06);
  --aura-opacity: 0.5;

  --foreground: #081a2c;
  --ink-1: #0d2540;
  --ink-2: #35607f;
  --ink-3: #6d8ea9;
  --ink-4: #93abc1;

  --p1: #0ea5e9;
  --p2: #6366f1;
  --p3: #22d3ee;
  --g1: #059669;
  --g2: #06b6d4;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #db2777;
  --card-shadow: 0 8px 30px rgba(15, 60, 100, 0.07);
  --card-hover-shadow: 0 16px 45px rgba(14, 165, 233, 0.18);
  color-scheme: light;
}

/* Theme 9/10 — slate · cement grey (dark without being black) */
:root[data-theme="slate"] {
  --background: #2b2f37;
  --nav-bg: rgba(43, 47, 55, 0.88);
  --menu-bg: rgba(43, 47, 55, 0.92);
  --card: rgba(45, 50, 60, 0.85);
  --card-solid: #353a44;
  --card-hover: rgba(56, 62, 74, 0.9);
  --surface-1: rgba(148, 163, 184, 0.14);
  --surface-2: rgba(203, 213, 225, 0.1);
  --surface-3: rgba(148, 163, 184, 0.1);
  --surface-4: rgba(100, 116, 139, 0.14);
  --border: rgba(148, 163, 184, 0.22);
  --border-strong: rgba(203, 213, 225, 0.4);
  --bd2: #3f4550;

  --aura-1: rgba(148, 163, 184, 0.24);
  --aura-2: rgba(203, 213, 225, 0.14);
  --aura-3: rgba(100, 116, 139, 0.12);
  --aura-opacity: 0.5;

  --foreground: #f1f5f9;
  --ink-1: #ffffff;
  --ink-2: #cbd5e1;
  --ink-3: #94a3b8;
  --ink-4: #64748b;

  --p1: #94a3b8;
  --p2: #cbd5e1;
  --p3: #e2e8f0;
  --g1: #a3e635;
  --g2: #38bdf8;
  --o1: #fbbf24;
  --o2: #fb923c;
  --r1: #f472b6;
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.28);
  --card-hover-shadow: 0 16px 45px rgba(148, 163, 184, 0.25);
  color-scheme: dark;
}

/* Theme 10/10 — meadow · fresh green */
:root[data-theme="meadow"] {
  --background: #f2faf3;
  --nav-bg: rgba(242, 250, 243, 0.88);
  --menu-bg: rgba(242, 250, 243, 0.92);
  --card: #ffffff;
  --card-solid: #ffffff;
  --card-hover: #f8fdf9;
  --surface-1: #e8f7ea;
  --surface-2: #f0fdf4;
  --surface-3: #f6fcf3;
  --surface-4: #f0faf8;
  --border: rgba(22, 163, 74, 0.14);
  --border-strong: rgba(13, 148, 136, 0.35);
  --bd2: #d4e6d5;

  --aura-1: rgba(22, 163, 74, 0.13);
  --aura-2: rgba(13, 148, 136, 0.09);
  --aura-3: rgba(74, 222, 128, 0.06);
  --aura-opacity: 0.5;

  --foreground: #0a2012;
  --ink-1: #0f2c18;
  --ink-2: #2f6b3f;
  --ink-3: #64936e;
  --ink-4: #8db096;

  --p1: #16a34a;
  --p2: #0d9488;
  --p3: #4ade80;
  --g1: #16a34a;
  --g2: #14b8a6;
  --o1: #f59e0b;
  --o2: #ea580c;
  --r1: #db2777;
  --card-shadow: 0 8px 30px rgba(30, 100, 50, 0.07);
  --card-hover-shadow: 0 16px 45px rgba(22, 163, 74, 0.18);
  color-scheme: light;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

/* Smooth cross-theme color morphing */
html.theme-transition *,
html.theme-transition *::before,
html.theme-transition *::after {
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease, fill 0.4s ease, box-shadow 0.4s ease !important;
}

body {
  background-color: transparent;
  color: var(--foreground);
  font-family: var(--font-sans);
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.modal-open {
  position: fixed;
  width: 100%;
}

/* Accessibility Focus Ring & Skip Link */
.skip-to-content {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 9999;
  background: var(--p1);
  color: #ffffff;
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.85rem;
  transition: top 0.25s var(--ease-butter);
  text-decoration: none;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--p1) 40%, transparent);
}

.skip-to-content:focus {
  top: 1rem;
  outline: 3px solid #ffffff;
}

:focus-visible {
  outline: 2px solid var(--p1);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Interactive Plexus Particle Background Canvas - Strictly behind all UI content */
#plexusCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  z-index: 0;
  pointer-events: none;
  background: transparent;
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

main#main-content {
  position: relative;
  z-index: 1;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--background);
}
::-webkit-scrollbar-thumb {
  background: var(--border-strong);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--p1);
}
* {
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

/* Touch & Tap Responsiveness */
button, a, .btn-primary, .btn-secondary, .tab-btn, .segmented-btn, .footer-social-btn, .mobile-toggle-btn, .theme-toggle-btn {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

/* Subtle background noise texture */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
  opacity: 0.02;
  will-change: opacity;
  transform: translateZ(0);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Ambient theme aura — fixed, static, GPU-composited once per theme.
   Each theme's --aura-* tokens tint the page corners so the whole
   background visibly glows in the theme's hue (emerald glows green,
   ocean glows blue, slate glows cool grey, etc.). */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: var(--aura-opacity, 0.5);
  background:
    radial-gradient(ellipse 85% 60% at 12% -12%, var(--aura-1) 0%, transparent 62%),
    radial-gradient(ellipse 70% 55% at 105% 25%, var(--aura-2) 0%, transparent 58%),
    radial-gradient(ellipse 95% 65% at 50% 115%, var(--aura-3) 0%, transparent 66%);
}

/* Typography & Gradient Utilities */
.font-heading {
  font-family: var(--font-heading);
}

.font-mono {
  font-family: var(--font-mono);
}

.gradient-text {
  background: linear-gradient(135deg, var(--p1) 0%, var(--p2) 50%, var(--p3) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-text-alt {
  background: linear-gradient(135deg, var(--p2) 0%, var(--r1) 50%, var(--p3) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ============================================================
   MAGICAL SCROLL REVEAL ENGINE (DigiColibri-Style)
   The magic comes from SUBTLETY — not heavy effects.
   - Clean 32px translateY + opacity fade
   - Smooth 700ms ease-in-out (no spring/bounce)
   - Gentle 100ms stagger intervals
   - NO blur, NO scale, NO rotation — just pure elegance
   ============================================================ */

/* Base: Elements start invisible & slightly below */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 700ms cubic-bezier(0.4, 0, 0.2, 1),
    transform 700ms cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity, transform;
}

/* Revealed: Element smoothly glides into place */
.reveal-on-scroll.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Directional Variants */
.reveal-on-scroll.reveal-left {
  transform: translateX(-40px) translateY(8px);
}

.reveal-on-scroll.reveal-left.revealed {
  transform: translateX(0) translateY(0);
}

.reveal-on-scroll.reveal-right {
  transform: translateX(40px) translateY(8px);
}

.reveal-on-scroll.reveal-right.revealed {
  transform: translateX(0) translateY(0);
}

.reveal-on-scroll.reveal-scale {
  transform: scale(0.95);
  opacity: 0;
}

.reveal-on-scroll.reveal-scale.revealed {
  transform: scale(1);
  opacity: 1;
}

/* Stagger delays — 100ms intervals matching DigiColibri */
.delay-1 {
  transition-delay: 100ms;
}

.delay-2 {
  transition-delay: 200ms;
}

.delay-3 {
  transition-delay: 300ms;
}

.delay-4 {
  transition-delay: 400ms;
}

.delay-5 {
  transition-delay: 500ms;
}

.delay-6 {
  transition-delay: 600ms;
}

/* Staggered children — auto-cascade with 100ms step */
.stagger-children>* {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 700ms cubic-bezier(0.4, 0, 0.2, 1),
    transform 700ms cubic-bezier(0.4, 0, 0.2, 1);
}

.stagger-children.revealed>*:nth-child(1) {
  transition-delay: 0ms;
}

.stagger-children.revealed>*:nth-child(2) {
  transition-delay: 100ms;
}

.stagger-children.revealed>*:nth-child(3) {
  transition-delay: 200ms;
}

.stagger-children.revealed>*:nth-child(4) {
  transition-delay: 300ms;
}

.stagger-children.revealed>*:nth-child(5) {
  transition-delay: 400ms;
}

.stagger-children.revealed>*:nth-child(6) {
  transition-delay: 500ms;
}

.stagger-children.revealed>*:nth-child(7) {
  transition-delay: 600ms;
}

.stagger-children.revealed>*:nth-child(8) {
  transition-delay: 700ms;
}

.stagger-children.revealed>* {
  opacity: 1;
  transform: translateY(0);
}

/* Section text cascade — chip → title → description */
.section-chip {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 700ms cubic-bezier(0.4, 0, 0.2, 1),
    transform 700ms cubic-bezier(0.4, 0, 0.2, 1);
}

.revealed .section-chip,
.reveal-on-scroll.revealed .section-chip {
  opacity: 1;
  transform: translateY(0);
}

.section-title {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 700ms cubic-bezier(0.4, 0, 0.2, 1) 100ms,
    transform 700ms cubic-bezier(0.4, 0, 0.2, 1) 100ms;
}

.revealed .section-title,
.reveal-on-scroll.revealed .section-title {
  opacity: 1;
  transform: translateY(0);
}

.section-desc {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 700ms cubic-bezier(0.4, 0, 0.2, 1) 200ms,
    transform 700ms cubic-bezier(0.4, 0, 0.2, 1) 200ms;
}

.revealed .section-desc,
.reveal-on-scroll.revealed .section-desc {
  opacity: 1;
  transform: translateY(0);
}

/* Accessibility: Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {

  .reveal-on-scroll,
  .stagger-children>*,
  .section-chip,
  .section-title,
  .section-desc {
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
    transition-delay: 0ms !important;
  }
}

/* Floating animation */
@keyframes floatSlow {

  0%,
  100% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-8px);
  }
}

.animate-float {
  animation: floatSlow 4s infinite ease-in-out;
}

/* Pulse animation */
@keyframes pulseDot {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.4;
    transform: scale(0.85);
  }
}

.animate-pulse-dot {
  animation: pulseDot 2s infinite ease-in-out;
}

@keyframes ticker {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

.animate-ticker {
  display: flex;
  width: max-content;
  animation: ticker 35s linear infinite;
}

.animate-ticker:hover {
  animation-play-state: paused;
}

/* Sticky Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 900;
  height: 64px;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--nav-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: all 0.25s var(--ease-butter);
}

.theme-toggle-btn {
  background: var(--surface-1);
  border: 1px solid var(--border-strong);
  color: var(--foreground);
  width: auto;
  height: 38px;
  padding: 0 0.8rem;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  cursor: pointer;
  transition: all 0.3s var(--ease-butter);
}

.theme-toggle-btn .theme-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--p1), var(--p2));
  box-shadow: 0 0 0 2px var(--card-solid), 0 2px 8px color-mix(in srgb, var(--p1) 40%, transparent);
  transition: transform 0.4s var(--ease-spring);
}

.theme-toggle-btn:hover {
  transform: translateY(-2px) scale(1.05);
  border-color: var(--p1);
  color: var(--p1);
  box-shadow: 0 4px 14px color-mix(in srgb, var(--p1) 30%, transparent);
}

.theme-toggle-btn:hover .theme-swatch {
  transform: rotate(180deg) scale(1.15);
}

.theme-toggle-btn:active {
  transform: scale(0.94);
}

/* Theme switch celebration — radial color wave sweeping from the button,
   wearing the NEW theme's colors (data-theme is applied before it starts). */
.theme-wave {
  position: fixed;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  left: var(--wave-x, 50vw);
  top: var(--wave-y, 50vh);
  transform: translate(-50%, -50%) scale(0);
  pointer-events: none;
  z-index: 9998;
  opacity: 0;
  background: radial-gradient(circle, color-mix(in srgb, var(--p1) 32%, transparent) 0%, color-mix(in srgb, var(--p2) 18%, transparent) 45%, transparent 70%);
  will-change: transform, opacity;
}

.theme-wave.anim {
  animation: theme-wave-sweep 0.65s var(--ease-butter) forwards;
}

@keyframes theme-wave-sweep {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(0); }
  12%  { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(85); }
}

/* Theme name pill — pops in center, teaches the 10 themes */
.theme-badge {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.85);
  z-index: 9999;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 1.4rem;
  border-radius: 9999px;
  background: var(--card-solid);
  border: 1.5px solid var(--border-strong);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
  opacity: 0;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ink-1);
  white-space: nowrap;
}

.theme-badge.anim {
  animation: theme-badge-pop 1.5s var(--ease-butter) forwards;
}

.theme-badge-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--p1), var(--p2));
  box-shadow: 0 0 0 2px var(--card-solid), 0 2px 8px color-mix(in srgb, var(--p1) 40%, transparent);
}

@keyframes theme-badge-pop {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.85); }
  10%  { opacity: 1; transform: translate(-50%, -50%) scale(1.05); }
  18%  { transform: translate(-50%, -50%) scale(1); }
  78%  { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(0.92); }
}

@media (prefers-reduced-motion: reduce) {
  .theme-wave,
  .theme-badge {
    display: none;
  }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link-btn {
  background: transparent;
  border: none;
  color: var(--ink-2);
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.5rem 0.9rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s var(--ease-butter);
}

.nav-link-btn:hover {
  color: var(--p1);
  background: var(--surface-1);
}

.btn-primary {
  background: linear-gradient(135deg, var(--p1) 0%, var(--p2) 100%);
  color: #fff;
  border: none;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.75rem 1.6rem;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 6px 20px color-mix(in srgb, var(--p1) 30%, transparent);
  transition: all 0.25s var(--ease-butter);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  transform: translateY(-2.5px) scale(1.02);
  box-shadow: 0 10px 28px color-mix(in srgb, var(--p1) 45%, transparent);
}

.btn-primary:active {
  transform: scale(0.97);
}

.btn-secondary {
  background: var(--card);
  color: var(--ink-2);
  border: 1.5px solid var(--border-strong);
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.7rem 1.4rem;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.25s var(--ease-butter);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.btn-secondary:hover {
  border-color: var(--p1);
  color: var(--p1);
  background: var(--surface-1);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px color-mix(in srgb, var(--p1) 15%, transparent);
}

/* Mobile Nav Drawer — Animated Hamburger + Spring Drawer */
.mobile-toggle-btn {
  display: none;
  background: var(--surface-1);
  border: 1px solid var(--border-strong);
  color: var(--foreground);
  cursor: pointer;
  padding: 0;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  transition: border-color 0.25s var(--ease-butter), box-shadow 0.25s var(--ease-butter), transform 0.25s var(--ease-spring);
}

.mobile-toggle-btn:hover {
  border-color: var(--p1);
  box-shadow: 0 4px 14px color-mix(in srgb, var(--p1) 30%, transparent);
}

.mobile-toggle-btn:active {
  transform: scale(0.92);
}

.mobile-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.32s var(--ease-spring), opacity 0.25s ease;
  transform-origin: center;
}

.mobile-toggle-btn.open .mobile-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.mobile-toggle-btn.open .mobile-toggle-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.mobile-toggle-btn.open .mobile-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu-overlay {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 899;
  background: var(--menu-bg);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  padding: 1.25rem 1.5rem 2rem;
  flex-direction: column;
  gap: 0.5rem;
  opacity: 0;
  transform: translateY(-16px) scale(0.985);
  transform-origin: top center;
  pointer-events: none;
  transition: opacity 0.35s var(--ease-butter), transform 0.5s var(--ease-spring);
  overflow-y: auto;
}

.mobile-menu-overlay.active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.mobile-menu-item {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.35s var(--ease-butter), transform 0.45s var(--ease-spring);
}

.mobile-menu-overlay.active .mobile-menu-item {
  opacity: 1;
  transform: translateY(0);
}

.mobile-menu-overlay.active .mobile-menu-item:nth-child(1) { transition-delay: 0.06s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(3) { transition-delay: 0.14s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(4) { transition-delay: 0.18s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(5) { transition-delay: 0.22s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(6) { transition-delay: 0.26s; }
.mobile-menu-overlay.active .mobile-menu-item:nth-child(8) { transition-delay: 0.32s; }

.mobile-menu-item.mobile-menu-cta {
  margin-top: 0.75rem;
}

.mobile-menu-divider {
  height: 1px;
  background: var(--border-strong);
  opacity: 0.35;
  margin: 0.35rem 0.25rem;
}

.mobile-menu-overlay .btn-secondary,
.mobile-menu-overlay .btn-primary {
  width: 100%;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 0.9rem 1.25rem;
  border-radius: 14px;
  text-align: left;
}

.mobile-menu-overlay .btn-secondary {
  background: var(--card);
  color: var(--ink-1);
  border: 1.5px solid var(--border-strong);
  box-shadow: none;
}

.mobile-menu-overlay .btn-secondary:hover {
  color: var(--p1);
  background: var(--surface-1);
  border-color: var(--p1);
  transform: translateX(6px);
}

.mobile-menu-overlay .btn-primary {
  justify-content: center;
  text-align: center;
}

/* Section Header */
.section-header {
  margin-bottom: 2.5rem;
}

.section-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.38rem 0.9rem;
  border-radius: 9999px;
  background: var(--surface-1);
  border: 1px solid color-mix(in srgb, var(--p1) 20%, transparent);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--p1);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
  box-shadow: 0 2px 10px color-mix(in srgb, var(--p1) 8%, transparent);
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--foreground);
}

.section-desc {
  color: var(--ink-3);
  font-size: 0.95rem;
  margin-top: 0.75rem;
  max-width: 540px;
}

/* Layout Containers & Stacking Architecture */
main,
section,
.container,
.hero-section {
  position: relative;
  z-index: 1;
}

.hero-photo-wrapper,
.hero-photo-card {
  position: relative;
  z-index: 2;
}

.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 4.5rem 1.5rem;
}

/* Glassmorphism Cards & Interactive Components */
.glass-card {
  background: var(--card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-strong);
  border-radius: 24px;
  padding: 1.75rem;
  box-shadow: var(--card-shadow);
  transition: all 0.3s var(--ease-butter);
  position: relative;
  z-index: 2;
}

.glass-card:hover {
  background: var(--card-hover);
  border-color: var(--p1);
  box-shadow: var(--card-hover-shadow);
  transform: translateY(-4px) scale(1.01);
}

/* Filter Tabs & Skill Pills */
.filter-tabs {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
  scrollbar-width: none;
}

.filter-tabs::-webkit-scrollbar {
  display: none;
}

.tab-btn {
  background: var(--surface-1);
  border: 1px solid color-mix(in srgb, var(--p1) 16%, transparent);
  color: var(--ink-1);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.55rem 1.1rem;
  border-radius: 9999px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s var(--ease-butter);
}

.tab-btn.active,
.tab-btn:hover {
  background: linear-gradient(135deg, var(--p1) 0%, var(--p2) 100%);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--p1) 30%, transparent);
}

/* Segmented Control Switch (Certificates vs Badges) */
.segmented-control {
  display: inline-flex;
  align-items: center;
  background: var(--card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 6px;
  border-radius: 9999px;
  border: 1px solid var(--border-strong);
  box-shadow: var(--card-shadow);
  gap: 6px;
}

.segmented-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.65rem 1.6rem;
  border-radius: 9999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-3);
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s var(--ease-butter);
  user-select: none;
}

.segmented-btn:hover {
  color: var(--foreground);
  background: var(--surface-1);
}

.segmented-btn.active {
  background: linear-gradient(135deg, var(--p1) 0%, var(--p2) 100%);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 4px 18px color-mix(in srgb, var(--p1) 40%, transparent);
}

.segmented-btn svg {
  transition: transform 0.3s var(--ease-spring);
}

.segmented-btn.active svg {
  transform: scale(1.1);
}

/* Badges View Grid & Card Architecture */
.badges-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.badge-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

/* Search Bar */
.search-box {
  position: relative;
  width: 100%;
  max-width: 380px;
  margin-bottom: 1.5rem;
}

.search-input {
  width: 100%;
  background: var(--card);
  border: 1.5px solid var(--border-strong);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  padding: 0.7rem 1rem 0.7rem 2.6rem;
  border-radius: 12px;
  outline: none;
  transition: all 0.25s var(--ease-butter);
}

.search-input:focus {
  border-color: var(--p1);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--p1) 18%, transparent);
}

.search-icon {
  position: absolute;
  left: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-4);
  pointer-events: none;
}

/* Full Screen Overlay Views (Certifications & Projects) */
.fullscreen-view {
  position: fixed;
  inset: 0;
  width: 100vw;
  max-width: 100vw;
  z-index: 1000;
  background: var(--background);
  overflow-y: auto;
  overflow-x: hidden !important;
  box-sizing: border-box;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease-butter), transform 0.35s var(--ease-butter);
  transform: translateY(24px) scale(0.98);
}

.fullscreen-view .container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .fullscreen-view .container {
    padding: 1.75rem 0.85rem !important;
    max-width: 100vw !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
}

.fullscreen-view.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

/* Accordion Smooth Expansion — silky spring-like ease, one block open at a time */
.accordion-content {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0;
  transition: max-height 0.55s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.4s cubic-bezier(0.22, 1, 0.36, 1), padding 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.accordion-content.open {
  max-height: 1000px;
  opacity: 1;
  padding: 0 1.25rem 1.25rem 1.25rem;
}

.glass-card.open[data-accordion-block] {
  border-color: color-mix(in srgb, var(--p1) 45%, transparent);
  box-shadow: 0 8px 24px color-mix(in srgb, var(--p1) 12%, transparent);
}

/* Animated Footer Social Buttons */
.footer-social-btn {
  width: 76px;
  height: 86px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--surface-1);
  border: 1px solid var(--border);
  color: var(--ink-2);
  text-decoration: none;
  transition: all 0.3s var(--ease-butter);
  position: relative;
  overflow: hidden;
}

.footer-btn-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
  transition: color 0.3s var(--ease-butter);
}

.footer-social-btn:hover {
  color: #fff;
  transform: translateY(-4px) scale(1.06);
  background: linear-gradient(135deg, var(--p1), var(--p2));
  border-color: transparent;
  box-shadow: 0 12px 26px color-mix(in srgb, var(--p1) 38%, transparent);
}

.footer-social-btn:hover .footer-btn-label {
  color: #fff;
}

.footer-social-btn-cv:hover {
  background: linear-gradient(135deg, var(--g2), var(--p1));
  box-shadow: 0 12px 26px color-mix(in srgb, var(--g2) 38%, transparent);
}

/* Back to Top Floating Button */
.back-to-top-btn {
  position: fixed !important;
  right: 1.5rem !important;
  bottom: 1.5rem !important;
  z-index: 9999 !important;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--p1), var(--p2));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 8px 24px color-mix(in srgb, var(--p1) 40%, transparent);
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition: opacity 0.35s var(--ease-butter), transform 0.35s var(--ease-butter), box-shadow 0.35s var(--ease-butter);
}

.back-to-top-btn.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.back-to-top-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 32px color-mix(in srgb, var(--p1) 55%, transparent);
}

/* Modals */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s var(--ease-butter);
}

.modal-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-box {
  background: var(--card);
  border: 1px solid var(--border-strong);
  border-radius: 28px;
  max-width: 640px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 2.25rem;
  position: relative;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.2);
  transform: scale(0.94);
  transition: transform 0.3s var(--ease-butter);
}

.modal-backdrop.active .modal-box {
  transform: scale(1);
}

.modal-close-btn {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: var(--surface-1);
  border: 1px solid var(--border);
  color: var(--ink-2);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s var(--ease-butter);
}

.modal-close-btn:hover {
  color: var(--foreground);
  background: var(--border);
  transform: rotate(90deg);
}

/* Grid Layout Architecture */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

/* Responsive Mobile Engine Upgrade (Preserves Desktop 100%, Optimizes Mobile) */
@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }

  .hero-photo-wrapper {
    margin-top: 1.5rem;
    justify-content: center;
  }

  .contact-grid {
    grid-template-columns: 1fr !important;
    gap: 2.5rem !important;
  }
}

@media (max-width: 768px) {

  .nav-links,
  .nav-desktop-btn {
    display: none !important;
  }

  .mobile-toggle-btn {
    display: flex !important;
  }

  .navbar {
    justify-content: flex-start;
  }

  .navbar > div:last-of-type {
    margin-left: auto;
  }

  .theme-toggle-btn {
    height: 44px;
    padding: 0 0.95rem;
    border-radius: 12px;
    border: 1.5px solid var(--border-strong);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
  }

  .theme-toggle-btn svg {
    width: 20px;
    height: 20px;
  }

  .theme-toggle-btn .theme-swatch {
    width: 16px;
    height: 16px;
  }

  .mobile-menu-overlay {
    display: flex;
  }

  .container {
    padding: 2.75rem 1rem !important;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  .hero-photo-card {
    max-width: 280px;
    margin: 0 auto;
  }

  .section-header {
    margin-bottom: 1.75rem !important;
  }

  .section-title {
    font-size: clamp(1.8rem, 6.5vw, 2.4rem) !important;
  }

  /* Hero stats on mobile: compact 3-column inline row */
  .hero-stats-wrapper {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0.5rem !important;
  }

  .hero-stats-wrapper .glass-card {
    padding: 0.65rem 0.5rem !important;
    gap: 0.4rem !important;
    flex-direction: column !important;
    text-align: center !important;
    align-items: center !important;
    border-radius: 14px !important;
  }

  .hero-stats-wrapper .glass-card>div:first-child {
    width: 28px !important;
    height: 28px !important;
  }

  .hero-stats-wrapper .glass-card svg {
    width: 14px !important;
    height: 14px !important;
  }

  .hero-stats-wrapper .glass-card div[data-counter],
  .hero-stats-wrapper .glass-card div[style*="font-weight: 800"] {
    font-size: 0.95rem !important;
  }

  .hero-stats-wrapper .glass-card div[style*="text-transform: uppercase"] {
    font-size: 0.52rem !important;
  }

  /* Certifications right stat cards on mobile: 2x2 grid cuts vertical scroll in half */
  .cert-stats-wrapper {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0.65rem !important;
  }

  .cert-stats-wrapper .glass-card {
    padding: 0.75rem 0.85rem !important;
    gap: 0.6rem !important;
    border-radius: 14px !important;
  }

  .education-row {
    display: flex !important;
    flex-direction: column !important;
    padding: 1.35rem 1.15rem !important;
    gap: 0.5rem !important;
  }

  .education-row>div:first-child {
    border-right: none !important;
    border-bottom: none !important;
    padding: 0 0 0.5rem 0 !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
  }

  .education-row>div:first-child div[style*="font-size: 0.9rem"] {
    font-size: 0.85rem !important;
    font-weight: 800 !important;
    color: var(--foreground) !important;
  }

  .education-row>div:last-child {
    padding: 0 !important;
  }

  .education-row h3 {
    font-size: 1.05rem !important;
    line-height: 1.3 !important;
    margin-bottom: 0.2rem !important;
  }

  .education-row div[style*="font-weight: 700"] {
    font-size: 0.8rem !important;
    margin-bottom: 0.4rem !important;
  }

  .education-row p {
    font-size: 0.8rem !important;
    line-height: 1.6 !important;
  }

  /* Compact glass card padding on mobile */
  .glass-card {
    padding: 1.25rem !important;
    border-radius: 18px !important;
  }

  /* Modal responsiveness on mobile */
  .modal-backdrop {
    padding: 0.75rem !important;
  }

  .modal-box {
    padding: 1.5rem 1.25rem !important;
    max-height: 90vh !important;
    border-radius: 22px !important;
  }
}

/* Certificates Layout Grid System (Desktop Base) */
.cert-layout-grid {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2rem;
  align-items: start;
}

.cert-sidebar {
  position: sticky;
  top: 1.5rem;
  height: fit-content;
  align-self: start;
}

/* Certificates Section Mobile Responsive Overrides */
@media (max-width: 768px) {
  .cert-layout-grid {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }

  .cert-sidebar {
    position: relative !important;
    top: 0 !important;
    width: 100% !important;
    margin-bottom: 1.25rem !important;
  }
}

/* Mobile Reference Design Scoped Rules for All Projects & Badges Views */
.mobile-ref-view-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  padding-top: 0.5rem;
}

.mobile-ref-title-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.mobile-ref-folder-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--surface-1);
  border: 1px solid var(--border-strong);
  color: var(--p1);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--p1) 15%, transparent);
}

.mobile-ref-title {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--foreground);
  line-height: 1.1;
  margin: 0;
}

.mobile-ref-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1rem;
  border-radius: 9999px;
  background: var(--card);
  border: 1px solid var(--border-strong);
  color: var(--foreground);
  font-size: 0.82rem;
  font-weight: 600;
  backdrop-filter: blur(12px);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--card-shadow);
}

/* Filter Tabs Horizontal Bar */
.mobile-ref-filter-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  overflow-x: auto;
  padding-bottom: 0.85rem;
  margin-bottom: 1.5rem;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.mobile-ref-filter-row::-webkit-scrollbar {
  display: none;
}

.mobile-ref-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.15rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--ink-3);
  flex-shrink: 0;
  box-shadow: var(--card-shadow);
}

.mobile-ref-filter-btn.active {
  background: linear-gradient(135deg, var(--p1), var(--p2));
  color: #FFFFFF;
  border-color: transparent;
  box-shadow: 0 4px 16px color-mix(in srgb, var(--p1) 35%, transparent);
  font-weight: 700;
}

/* Mobile Reference Cards Layout */
.mobile-ref-cards-container {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.mobile-ref-card {
  background: var(--card);
  border: 1.5px solid var(--border);
  border-radius: 20px;
  padding: 1.25rem;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.mobile-ref-card-body {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
}

.mobile-ref-card-thumb {
  width: 105px;
  height: 105px;
  flex-shrink: 0;
  border-radius: 14px;
  background: var(--surface-1);
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.mobile-ref-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mobile-ref-card-thumb-badge img {
  object-fit: contain;
  transform: scale(1.4);
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.15));
}

.mobile-ref-card-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* Category Badges */
.mobile-ref-cat-badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.6rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 0.22rem 0.6rem;
  border-radius: 6px;
  margin-bottom: 0.45rem;
  width: fit-content;
}

.mobile-ref-cat-academic {
  background: var(--surface-1);
  color: var(--p1);
  border: 1px solid var(--border-strong);
}

.mobile-ref-cat-innovation {
  background: var(--surface-2);
  color: var(--g1);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.mobile-ref-cat-research {
  background: var(--surface-4);
  color: var(--r1);
  border: 1px solid rgba(236, 72, 153, 0.3);
}

.mobile-ref-cat-personal {
  background: var(--surface-3);
  color: var(--o1);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.mobile-ref-cat-verified {
  background: var(--surface-2);
  color: var(--g1);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.mobile-ref-card-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--foreground);
  line-height: 1.25;
  margin-bottom: 0.35rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mobile-ref-card-desc {
  font-size: 0.78rem;
  color: var(--ink-2);
  line-height: 1.45;
  margin-bottom: 0.55rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Skill Tags */
.mobile-ref-skills-row {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.mobile-ref-skill-tag {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 8px;
  background: var(--surface-1);
  color: var(--ink-2);
  border: 1px solid var(--border);
}

/* Card Meta Footer Bar */
.mobile-ref-card-footer {
  margin-top: 0.9rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.76rem;
  color: #94A3B8;
}

.mobile-ref-meta-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.mobile-ref-meta-rating {
  color: #60A5FA;
  font-weight: 700;
}

.mobile-ref-action-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #F8FAFC;
  margin-left: 0.4rem;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.mobile-ref-action-btn:active {
  transform: scale(0.92);
  background: #3B82F6;
}
}

@media (max-width: 480px) {
  .container {
    padding: 2.25rem 0.85rem !important;
  }

  .btn-primary,
  .btn-secondary {
    padding: 0.7rem 1.1rem !important;
    font-size: 0.8rem !important;
  }

  .section-chip {
    font-size: 0.65rem !important;
    padding: 0.3rem 0.75rem !important;
  }
}

/* Floating & Glowing Animations for CTA Buttons */
@keyframes floatGlowLg {

  0%,
  100% {
    transform: translateY(0px) scale(1);
    box-shadow: 0 6px 24px rgba(124, 58, 237, 0.45), 0 0 45px rgba(217, 70, 239, 0.3);
  }

  50% {
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 14px 38px rgba(124, 58, 237, 0.75), 0 0 65px rgba(217, 70, 239, 0.55);
  }
}

@keyframes floatGlowLinkedIn {

  0%,
  100% {
    transform: translateY(0px);
    box-shadow: 0 4px 20px color-mix(in srgb, var(--p1) 45%, transparent), 0 0 35px color-mix(in srgb, var(--p2) 30%, transparent);
  }

  50% {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px color-mix(in srgb, var(--p1) 75%, transparent), 0 0 55px color-mix(in srgb, var(--p2) 55%, transparent);
  }
}

.floating-glowing-btn-lg {
  animation: floatGlowLg 3.5s ease-in-out infinite !important;
}

.floating-glowing-btn-linkedin {
  animation: floatGlowLinkedIn 3.2s ease-in-out infinite !important;
}

/* ==========================================================================
   MOBILE-ONLY UNIQUE CARD SWIPE ENGINE (Max-Width: 768px Only)
   1. Featured Projects: 3D Orbital Arc Stack Deck
   2. Skills & Expertise: Tinder Velocity Tilt-Swipe Deck
   3. Key Strengths: Vertical Rolodex Reel
   ========================================================================== */

/* Viewports Visibility Switches */
.mobile-only-view {
  display: none !important;
}

.desktop-only-view {
  display: grid;
}

@media (max-width: 768px) {
  .mobile-only-view {
    display: block !important;
  }

  .desktop-only-view {
    display: none !important;
  }

  /* ------------------------------------------------------------------------
     SECTION 1: FEATURED PROJECTS — 3D ORBITAL ARC DECK
     ------------------------------------------------------------------------ */
  .mobile-projects-wrapper {
    margin-top: 1.5rem;
    position: relative;
    user-select: none;
    touch-action: pan-y;
  }

  .arc-deck-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
  }

  .arc-deck-badge {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.3rem 0.75rem;
    border-radius: 9999px;
    background: color-mix(in srgb, var(--p1) 12%, transparent);
    color: var(--p1);
    border: 1px solid color-mix(in srgb, var(--p1) 25%, transparent);
  }

  .arc-counter-pill {
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--foreground);
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    background: var(--card);
    border: 1px solid var(--border-strong);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 0.4rem;
  }

  .arc-counter-pill .arr {
    color: var(--p1);
    transition: transform 0.3s ease;
  }

  .arc-deck-stage {
    position: relative;
    width: 100%;
    height: 340px;
    perspective: 1200px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
  }

  .mobile-arc-deck {
    position: relative;
    width: 100%;
    max-width: 380px;
    height: 100%;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-arc-card {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 310px;
    background-color: var(--card-solid) !important;
    background: var(--card-solid) !important;
    border: 1px solid var(--border-strong);
    border-radius: 24px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45);
    transition: transform 0.25s var(--ease-butter), opacity 0.2s ease;
    will-change: transform, opacity;
    cursor: grab;
    backdrop-filter: none;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform-style: preserve-3d;
    contain: layout style;
    opacity: 1 !important;
  }

  .mobile-arc-card:active {
    cursor: grabbing;
  }

  .mobile-arc-card:not([data-depth="0"]) {
    pointer-events: none;
  }

  /* Non-top cards content visibility management */
  .mobile-arc-card:not([data-depth="0"]) * {
    opacity: 0 !important;
    visibility: hidden !important;
  }

  .mobile-arc-card[data-depth="0"] * {
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* Arc Deck Layer Stacking Mechanics (2D Stacking for 100% Reliable Z-Index Order & No Opacity Bleed) */
  .mobile-arc-card[data-depth="0"] {
    transform: translateY(0px) scale(1);
    z-index: 10 !important;
    opacity: 1 !important;
    filter: blur(0px);
  }

  .mobile-arc-card[data-depth="1"] {
    transform: translateY(16px) scale(0.94);
    z-index: 8 !important;
    opacity: 1 !important;
    filter: blur(0px);
  }

  .mobile-arc-card[data-depth="2"] {
    transform: translateY(30px) scale(0.88);
    z-index: 6 !important;
    opacity: 1 !important;
    filter: blur(0px);
  }

  .mobile-arc-card[data-depth="3"] {
    transform: translateY(42px) scale(0.82);
    z-index: 4 !important;
    opacity: 1 !important;
    filter: blur(0px);
  }

  .arc-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .arc-card-tag {
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.05em;
  }

  .arc-card-status {
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--g1);
    background: rgba(5, 150, 105, 0.1);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
  }

  .arc-card-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--foreground);
    margin-top: 0.4rem;
    margin-bottom: 0.15rem;
  }

  .arc-card-sub {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--p1);
    margin-bottom: 0.6rem;
  }

  .arc-card-desc {
    font-size: 0.78rem;
    color: var(--ink-3);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .arc-card-actions {
    display: flex;
    gap: 0.6rem;
    margin-top: 0.8rem;
  }

  .arc-drag-hint {
    font-size: 0.65rem;
    font-style: italic;
    color: var(--ink-3);
    text-align: center;
    margin-top: 0.4rem;
  }

  .arc-controls-bar {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    margin-top: 0.5rem;
  }

  .arc-btn {
    flex: 1;
    padding: 0.7rem 1rem;
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--border-strong);
    color: var(--foreground);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--card-shadow);
    transition: all 0.2s ease;
  }

  .arc-btn:active {
    transform: scale(0.96);
    background: var(--border);
  }

  /* ------------------------------------------------------------------------
     SECTION 2: SKILLS & EXPERTISE — TINDER VELOCITY TILT-SWIPE
     ------------------------------------------------------------------------ */
  .mobile-skills-wrapper {
    margin-top: 1.5rem;
    position: relative;
    user-select: none;
    touch-action: pan-y;
  }

  .swipe-guide-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
  }

  .swipe-badge {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.3rem 0.75rem;
    border-radius: 9999px;
    background: rgba(168, 85, 247, 0.12);
    color: var(--p2);
    border: 1px solid rgba(168, 85, 247, 0.25);
  }

  .swipe-direction-hints {
    display: flex;
    gap: 0.5rem;
  }

  .glow-hint {
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    opacity: 0.4;
    transition: opacity 0.2s ease, transform 0.2s ease;
  }

  .glow-hint.left {
    color: var(--r1);
    background: rgba(236, 72, 153, 0.1);
  }

  .glow-hint.right {
    color: var(--g1);
    background: rgba(5, 150, 105, 0.1);
  }

  .glow-hint.active {
    opacity: 1;
    transform: scale(1.1);
  }

  .mobile-tilt-deck {
    position: relative;
    width: 100%;
    height: 340px;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-tilt-card {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 320px;
    background: var(--card-solid);
    border: 1px solid var(--border-strong);
    border-radius: 24px;
    padding: 1.5rem;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
    will-change: transform, opacity;
    cursor: grab;
    backdrop-filter: none;
  }

  .mobile-tilt-card:active {
    cursor: grabbing;
  }

  .mobile-tilt-card:not(.active) {
    transform: scale(0.92) translateY(14px);
    opacity: 0;
    pointer-events: none;
  }

  .card-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .card-chip-tag {
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.25rem 0.65rem;
    border-radius: 8px;
    text-transform: uppercase;
  }

  .card-swipe-hint {
    font-size: 0.65rem;
    color: var(--ink-3);
    font-style: italic;
  }

  .card-main-title {
    font-family: var(--font-heading);
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--foreground);
    margin-top: 0.5rem;
    margin-bottom: 0.2rem;
  }

  .card-subtext {
    font-size: 0.8rem;
    color: var(--ink-3);
    line-height: 1.5;
    margin-bottom: 0.8rem;
  }

  .card-tags-container {
    display: flex;
    gap: 0.45rem;
    flex-wrap: wrap;
  }

  .skill-tag-pill {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.4rem 0.85rem;
    border-radius: 9999px;
    background: var(--surface-1);
    color: var(--foreground);
    border: 1px solid var(--border);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  }

  .mobile-skill-tabs {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
    justify-content: center;
  }

  .skill-tab-pill {
    flex: 1;
    padding: 0.6rem 0.5rem;
    border-radius: 12px;
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--ink-3);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
  }

  .skill-tab-pill.active {
    background: linear-gradient(135deg, var(--p1), var(--p2));
    color: #FFFFFF;
    border-color: transparent;
    box-shadow: 0 4px 14px color-mix(in srgb, var(--p1) 35%, transparent);
  }

  /* ------------------------------------------------------------------------
     SECTION 3: KEY STRENGTHS — VERTICAL ROLODEX REEL
     ------------------------------------------------------------------------ */
  .mobile-strengths-wrapper {
    margin-top: 1.5rem;
    position: relative;
    user-select: none;
    touch-action: pan-y;
  }

  .reel-guide-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
  }

  .reel-badge {
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.3rem 0.75rem;
    border-radius: 9999px;
    background: rgba(245, 158, 11, 0.12);
    color: var(--o1);
    border: 1px solid rgba(245, 158, 11, 0.25);
  }

  .reel-counter-badge {
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--foreground);
    padding: 0.3rem 0.75rem;
    border-radius: 9999px;
    background: var(--card);
    border: 1px solid var(--border-strong);
  }

  .reel-viewport-container {
    position: relative;
    width: 100%;
    height: 250px;
    perspective: 1000px;
    overflow: hidden;
    border-radius: 24px;
  }

  .mobile-rolodex-deck {
    position: relative;
    width: 100%;
    height: 100%;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-reel-card {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--card-solid);
    border: 1.5px solid var(--border-strong);
    border-radius: 24px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.4);
    transition: transform 0.5s var(--ease-butter), opacity 0.4s ease;
    will-change: transform, opacity;
    cursor: grab;
    transform-origin: center bottom;
    backdrop-filter: none;
  }

  .mobile-reel-card:active {
    cursor: grabbing;
  }

  .mobile-reel-card.active {
    transform: translateY(0px) rotateX(0deg) scale(1);
    z-index: 10;
    opacity: 1;
  }

  .mobile-reel-card.prev-card {
    transform: translateY(-120%) rotateX(-30deg) scale(0.9);
    z-index: 12;
    opacity: 0;
  }

  .mobile-reel-card.next-card {
    transform: translateY(20px) rotateX(15deg) scale(0.92);
    z-index: 8;
    opacity: 0.6;
  }

  .mobile-reel-card.hidden-card {
    transform: translateY(40px) rotateX(30deg) scale(0.84);
    z-index: 5;
    opacity: 0;
  }

  .reel-card-icon {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .reel-card-content {
    flex: 1;
  }

  .reel-card-num {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: var(--ink-3);
  }

  .reel-card-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--foreground);
    margin-top: 0.2rem;
    margin-bottom: 0.3rem;
  }

  .reel-card-desc {
    font-size: 0.8rem;
    color: var(--ink-3);
    line-height: 1.5;
  }

  .reel-swipe-hint {
    position: absolute;
    bottom: 0.6rem;
    right: 1rem;
    font-size: 0.6rem;
    font-style: italic;
    color: var(--ink-3);
    opacity: 0.6;
  }

  .reel-controls-bar {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-top: 0.85rem;
  }

  .reel-arrow-btn {
    padding: 0.65rem 1rem;
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--border-strong);
    color: var(--foreground);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
  }

  .reel-arrow-btn:active {
    transform: scale(0.95);
  }

  .reel-progress-track {
    flex: 1;
    height: 6px;
    border-radius: 9999px;
    background: var(--surface-1);
    border: 1px solid var(--border);
    overflow: hidden;
  }

  .reel-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--p1), var(--o1));
    border-radius: 9999px;
    transition: width 0.3s ease;
  }
}

/* ============================================================
   TESTIMONIALS SLIDING TRACK (Hardware-Accelerated Carousel)
   Continuous, butter-smooth 60/120 FPS glide track with zero DOM redraws
   ============================================================ */
.testimonials-carousel-viewport {
  overflow: hidden;
  width: 100%;
  padding: 0.5rem 0 1rem 0;
  position: relative;
}

.testimonials-track {
  display: flex;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
  gap: 1.5rem;
}

.testimonial-card-slide {
  flex: 0 0 calc((100% - 3rem) / 3);
  min-width: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

@media (max-width: 1024px) and (min-width: 641px) {
  .testimonial-card-slide {
    flex: 0 0 calc((100% - 1.5rem) / 2);
  }
}

@media (max-width: 640px) {
  .testimonial-card-slide {
    flex: 0 0 100%;
  }
}