/* =================================================================
   HOÀNG VĂN TIẾN — PERSONAL PORTFOLIO
   Design System: Technical Precision / Architectural Minimalist
   Principles: Sharp hairlines, zero AI-slop pills, disciplined palette,
               tactile industrial feedback, scroll-driven blur/reveal.
================================================================= */

/* --- 1. DESIGN TOKENS --- */
:root {
  /* Light Theme (Studio Raw / Architectural Paper) */
  --bg-main: #f5f5f2;
  --bg-surface: rgba(255, 255, 255, 0.92);
  --bg-subtle: #eaeae4;
  --bg-accent: #0f172a;

  --text-main: #121316;
  --text-muted: #5e6472;
  --text-dim: #8b92a0;

  --border-line: #d8d8ce;
  --border-dark: #121316;

  --accent-color: #1e3a8a; /* Deep industrial indigo */
  --accent-signal: #ea580c; /* Functional amber signal */

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Be Vietnam Pro', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --radius-none: 0px;
  --radius-xs: 2px;
  --radius-sm: 4px;

  --header-height: 64px;
}

[data-theme="dark"] {
  /* Dark Theme (Raw Obsidian / Console Precision) */
  --bg-main: #0c0e12;
  --bg-surface: rgba(19, 23, 31, 0.92);
  --bg-subtle: #1a202c;
  --bg-accent: #f8fafc;

  --text-main: #f1f3f7;
  --text-muted: #9aa2b1;
  --text-dim: #5a6475;

  --border-line: rgba(255, 255, 255, 0.08);
  --border-dark: #f1f3f7;

  --accent-color: #3b82f6; /* Precision Electric Blue */
  --accent-signal: #f97316; /* Amber indicator */
}

[data-theme="xmas"] {
  /* Classic Christmas Green & Red Theme (Evergreen Pine Forest & Warm Cranberry Hearth) */
  --bg-main: #0a1811;
  --bg-surface: rgba(15, 34, 25, 0.90);
  --bg-subtle: #12281d;
  --bg-accent: #fef2f2;

  --text-main: #fcfbf9;
  --text-muted: #cbd5e1;
  --text-dim: #86efac;

  --border-line: rgba(74, 222, 128, 0.22);
  --border-dark: #ef4444;

  --accent-color: #ef4444; /* Vibrant Santa Red / Cranberry */
  --accent-signal: #22c55e; /* Christmas Pine Green */
}

/* --- 2. BASE RESET & TYPOGRAPHY --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-serif);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  transition: background-color 0.25s ease, color 0.25s ease;
}

::selection {
  background: var(--text-main);
  color: var(--bg-main);
}

/* Interactive Elastic Canvas Grid */
.interactive-grid-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-sans);
  color: var(--text-main);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: var(--border-line);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-dim);
}

/* --- 3. SCROLL REVEAL & ANTIGRAVITY WEIGHTLESS BLUR/FADE ANIMATIONS --- */
.reveal-ready .reveal {
  transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.85s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-ready .reveal:not(.is-visible) {
  opacity: 0;
  filter: blur(10px);
  transform: translateY(32px) scale(0.985);
  will-change: opacity, transform, filter;
}

.reveal-ready .reveal.is-visible {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

/* Stagger Delays for Grid Children (Weightless Wave Cascade) */
.stagger-1 { transition-delay: 0.06s; }
.stagger-2 { transition-delay: 0.14s; }
.stagger-3 { transition-delay: 0.22s; }
.stagger-4 { transition-delay: 0.30s; }

/* Antigravity Card Top-Edge Luminescence */
.about-box,
.profile-spec-plate,
.education-split {
  position: relative;
  overflow: hidden;
}

.about-box::before,
.profile-spec-plate::before,
.education-split::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.25) 50%, transparent 100%);
  pointer-events: none;
  z-index: 5;
}

[data-theme="light"] .about-box::before,
[data-theme="light"] .profile-spec-plate::before,
[data-theme="light"] .education-split::before {
  background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.18) 50%, transparent 100%);
}

/* --- 4. TOP TECHNICAL NAVBAR (SHARP, NOT A BUBBLY PILL) --- */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--bg-main);
  border-bottom: 1px solid var(--border-line);
  z-index: 100;
  display: flex;
  align-items: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.nav-inner {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-indicator {
  width: 8px;
  height: 8px;
  background: var(--accent-signal);
  display: inline-block;
}

.nav-brand-title {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.nav-brand-sub {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  border-left: 1px solid var(--border-line);
  padding-left: 10px;
}

.nav-menu {
  display: flex;
  list-style: none;
  border-left: 1px solid var(--border-line);
}

.nav-item {
  border-right: 1px solid var(--border-line);
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 20px;
  height: var(--header-height);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: background-color 0.15s ease, color 0.15s ease;
  position: relative;
}

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

.nav-link.active {
  background: var(--bg-surface);
  color: var(--text-main);
  font-weight: 700;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--text-main);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Sharp Industrial Buttons (Zero Pills) */
.btn-square {
  height: 38px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
  border-radius: var(--radius-none);
  color: var(--text-main);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-square:hover {
  background: var(--text-main);
  color: var(--bg-main);
  border-color: var(--text-main);
}

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

.btn-square-icon {
  width: 38px;
  padding: 0;
}

.mobile-toggle {
  display: none;
}

/* Mobile Drawer */
.mobile-nav-drawer {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-line);
  z-index: 99;
  flex-direction: column;
}

.mobile-nav-drawer.open {
  display: flex;
}

.mobile-nav-item {
  padding: 16px 24px;
  border-bottom: 1px solid var(--border-line);
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: var(--text-main);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mobile-nav-item:hover {
  background: var(--bg-subtle);
}

/* --- 5. MAIN CONTENT WRAPPER --- */
.main-wrapper {
  position: relative;
  z-index: 10;
  max-width: 1200px;
  margin: 0 auto;
  padding: calc(var(--header-height) + 40px) 24px 80px;
}

/* --- 6. SECTION STRUCTURAL LAYOUT --- */
.content-section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border-line);
}

.content-section:last-of-type {
  border-bottom: none;
}

/* Clean Editorial Section Header (No emoji badges, strict index hierarchy) */
.section-headline-box {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-line);
  padding-bottom: 16px;
  margin-bottom: 40px;
}

.section-index {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
  font-weight: 600;
  letter-spacing: 0.05em;
}

.section-heading {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.03em;
}

.section-summary-text {
  font-size: 0.92rem;
  color: var(--text-muted);
  max-width: 500px;
  text-align: right;
  line-height: 1.5;
}

/* --- 7. HERO SECTION (#home) --- */
.hero-container {
  display: grid;
  grid-template-columns: 1.35fr 0.85fr;
  gap: 48px;
  align-items: stretch;
  padding: 30px 0 60px;
}

.hero-main-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-meta-strip {
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.signal-dot {
  width: 6px;
  height: 6px;
  background: #10b981;
  display: inline-block;
  margin-right: 6px;
}

.hero-display-name {
  font-size: 3.4rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.08;
  margin-bottom: 24px;
  color: var(--text-main);
}

.hero-manifesto {
  font-size: 1.15rem;
  line-height: 1.68;
  color: var(--text-muted);
  margin-bottom: 32px;
  max-width: 640px;
}

.hero-manifesto strong {
  color: var(--text-main);
  font-weight: 600;
}

/* Industrial Specs Ledger */
.specs-ledger {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border-line);
  background: var(--bg-surface);
  margin-bottom: 36px;
}

.spec-cell {
  padding: 14px 18px;
  border-right: 1px solid var(--border-line);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.spec-cell:last-child {
  border-right: none;
}

.spec-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  color: var(--text-dim);
  letter-spacing: 0.06em;
}

.spec-val {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

.hero-btn-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-primary-sharp {
  background: var(--text-main);
  color: var(--bg-main);
  border-color: var(--text-main);
}

.btn-primary-sharp:hover {
  background: var(--bg-surface);
  color: var(--text-main);
  border-color: var(--text-main);
}

/* Hero Right: Architectural Framing */
.hero-frame-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.profile-spec-plate {
  border: 1px solid var(--border-line);
  background: var(--bg-surface);
  padding: 16px;
}

.plate-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-line);
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
}

.plate-photo-wrap {
  width: 100%;
  height: 380px;
  background: #000000;
  overflow: hidden;
  position: relative;
}

.plate-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(102%) brightness(98%);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.profile-spec-plate:hover .plate-photo-wrap img {
  transform: scale(1.03);
}

.plate-footer {
  display: flex;
  justify-content: space-between;
  padding-top: 12px;
  margin-top: 14px;
  border-top: 1px solid var(--border-line);
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

/* --- 8. ABOUT ME SECTION (#about) --- */
.about-grid-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  margin-bottom: 28px;
}

.about-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
  padding: 28px;
  position: relative;
}

.about-box-full {
  grid-column: span 2;
}

.box-title-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-line);
  padding-bottom: 14px;
  margin-bottom: 20px;
}

.box-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.box-number {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Box 1: Interests Table */
.interest-table {
  display: flex;
  flex-direction: column;
}

.interest-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-line);
  gap: 16px;
}

.interest-row:last-child {
  border-bottom: none;
}

.interest-name {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

.interest-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Box 2: Spotify Stream Console (Canvas Style) */
.spotify-deck-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
  display: flex;
  flex-direction: column;
}

.text-spotify {
  color: #1DB954;
}

.spotify-canvas-frame {
  position: relative;
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.25);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.spotify-canvas-frame:hover {
  border-color: var(--text-dim);
  box-shadow: inset 0 0 25px rgba(0, 0, 0, 0.35), 0 4px 20px rgba(0, 0, 0, 0.2);
}

.spotify-telemetry-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-line);
  color: var(--text-muted);
}

.telemetry-left {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-main);
  font-weight: 700;
}

.spotify-signal-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #1DB954;
  box-shadow: 0 0 8px #1DB954;
  animation: signal-blink 2s infinite ease-in-out;
}

.spotify-embed-container {
  width: 100%;
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.06);
  height: 152px;
  min-height: 152px;
}

.spotify-embed-container iframe {
  display: block;
  width: 100%;
  height: 152px;
  border: none;
}

.spotify-footer-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.68rem;
  padding-top: 6px;
  border-top: 1px solid var(--border-line);
  letter-spacing: 0.04em;
}

/* Box 3: Technical Skills Console (Interactive Carousel / Tabbed Showcase) */
.skill-stage-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
}

/* Skill Category Tabs (Hiện tại / Quan tâm) */
.skill-group-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-line);
  padding: 3px;
  border-radius: 6px;
}

[data-theme="light"] .skill-group-toggle {
  background: #f1f5f9;
}

.skill-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 4px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: all 0.22s ease;
  user-select: none;
}

.skill-filter-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.04);
}

[data-theme="light"] .skill-filter-btn:hover {
  background: rgba(0, 0, 0, 0.04);
}

.skill-filter-btn.active {
  color: var(--text-main);
  background: var(--bg-surface);
  border-color: var(--border-line);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

[data-theme="light"] .skill-filter-btn.active {
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.skill-filter-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-dim);
  transition: all 0.22s ease;
}

.skill-filter-btn.active .skill-filter-dot {
  background: var(--accent-signal);
  box-shadow: 0 0 8px var(--accent-signal);
}

.skill-count-badge {
  font-size: 0.68rem;
  padding: 1px 6px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-dim);
  line-height: 1.2;
}

[data-theme="light"] .skill-count-badge {
  background: rgba(0, 0, 0, 0.06);
}

.skill-filter-btn.active .skill-count-badge {
  background: rgba(59, 130, 246, 0.15);
  color: var(--accent-signal);
}

/* Subtitle / Context strip */
.skill-context-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  margin-bottom: 20px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-line);
  border-left: 3px solid var(--accent-signal);
  font-size: 0.78rem;
  color: var(--text-muted);
  transition: all 0.25s ease;
}

[data-theme="light"] .skill-context-strip {
  background: #f8fafc;
}

.skill-context-label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  line-height: 1.45;
}

#skillGroupDesc {
  display: inline-block;
  white-space: normal;
  transition: opacity 0.22s ease, transform 0.22s ease;
  will-change: opacity, transform;
}

.skill-context-meta {
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  white-space: nowrap;
  flex-shrink: 0;
}

.skill-carousel-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.skill-counter {
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  padding: 0 4px;
}

/* Skills Master-Detail Matrix Layout */
.skill-layout-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: stretch;
  min-height: auto;
}

/* LEFT COLUMN: Vertical Navigation List */
.skill-nav-vertical {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  align-items: start;
}

.skill-nav-group {
  grid-area: 1 / 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.skill-nav-group.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.skill-nav-btn {
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  border-left: 3px solid transparent;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  color: var(--text-muted);
}

.skill-nav-btn:hover {
  border-color: var(--text-dim);
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.025);
  transform: translateX(2px);
}

.skill-nav-btn.active {
  border-color: var(--accent-color);
  border-left-color: var(--accent-color);
  background: rgba(59, 130, 246, 0.06);
  color: var(--text-main);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
}

[data-theme="light"] .skill-nav-btn {
  background: #f8fafc;
}

[data-theme="light"] .skill-nav-btn.active {
  border-color: var(--text-main);
  border-left-color: var(--accent-signal);
  background: #f0f4f8;
}

.skill-nav-icons {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.skill-nav-icon {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  object-fit: contain;
  transition: transform 0.25s ease;
}

.skill-nav-btn:hover .skill-nav-icon {
  transform: scale(1.08);
}

.skill-nav-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex-grow: 1;
}

.skill-nav-title {
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skill-nav-sub {
  font-size: 0.66rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}

.skill-nav-btn.active .skill-nav-sub {
  color: var(--accent-signal);
}

.skill-nav-indicator {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--text-dim);
  transition: transform 0.25s ease, color 0.25s ease;
  flex-shrink: 0;
}

.skill-nav-btn:hover .skill-nav-indicator,
.skill-nav-btn.active .skill-nav-indicator {
  color: var(--accent-color);
  transform: translateX(3px);
}

.skill-nav-progress {
  display: none;
}

/* RIGHT COLUMN: Flat Technical Detail Showcase (Compact & Clean) */
.skill-content-panel {
  position: relative;
  min-height: 220px;
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  padding: 24px 28px;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
}

.skill-slides-group {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.38s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.38s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.38s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.skill-slides-group.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.skill-slide {
  grid-area: 1 / 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(4px);
  transition: opacity 0.38s ease-in-out,
              visibility 0.38s ease-in-out,
              transform 0.38s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.skill-slide.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.skill-panel-header {
  margin-bottom: 0;
}

.skill-badge-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  margin-bottom: 8px;
}

.skill-status-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-signal);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.skill-tag-accent {
  color: var(--accent-color);
}

.skill-item-name {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 10px;
  color: var(--text-main);
  line-height: 1.25;
}

.skill-item-desc {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 0;
}

/* Box 3: Landscape Photography Filmstrip (Horizontal Scroll) */
.filmstrip-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.filmstrip-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
}

.filmstrip-nav-group {
  display: flex;
  gap: 6px;
}

.filmstrip-scroll-area {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 14px;
  cursor: grab;
  scrollbar-width: thin;
}

.filmstrip-scroll-area:active {
  cursor: grabbing;
}

.filmstrip-frame {
  display: block;
  min-width: 0;
  font: inherit;
  text-align: left;
  flex: 0 0 340px;
  scroll-snap-align: start;
  border: 1px solid var(--border-line);
  background: var(--bg-main);
  padding: 10px;
  cursor: pointer;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.filmstrip-frame:hover {
  border-color: var(--text-main);
  transform: translateY(-2px);
}

.frame-media {
  display: block;
  width: 100%;
  height: 220px;
  background: #000;
  overflow: hidden;
  margin-bottom: 10px;
  border-radius: 2px;
}

.frame-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.5s ease;
}

.filmstrip-frame:hover .frame-media img {
  transform: scale(1.05);
}

.frame-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

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

.frame-exif {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-dim);
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

/* Box 4: Workspace & Tools Manifest (Antigravity High-End Carousel) */
.gear-manifest-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
}

.gear-carousel-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.gear-counter {
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  padding: 0 4px;
}

/* Gear Switcher Tabs */
.gear-tabs-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  border-bottom: 1px solid var(--border-line);
  padding-bottom: 14px;
  margin-bottom: 24px;
}

.gear-tab-btn {
  background: transparent;
  border: 1px solid var(--border-line);
  padding: 10px 14px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.3s ease;
  color: var(--text-muted);
  position: relative;
  overflow: hidden;
}

.gear-tab-btn:hover {
  border-color: var(--text-dim);
  color: var(--text-main);
  background: var(--bg-main);
}

.gear-tab-btn.active {
  border-color: var(--text-main);
  background: var(--bg-main);
  color: var(--text-main);
}

.gear-tab-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  font-weight: 700;
}

.gear-tab-btn.active .gear-tab-num {
  color: var(--accent-signal);
}

.gear-tab-label {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Tab Progress Indicator Bar (Disabled for manual mode) */
.gear-tab-progress {
  display: none;
}

/* Carousel Stage */
.gear-stage {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  min-height: 440px;
  width: 100%;
}

.gear-slide {
  grid-area: 1 / 1;
  width: 100%;
  display: grid;
  grid-template-columns: 1.18fr 0.82fr;
  gap: 36px;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.45s ease-in-out, visibility 0.45s ease-in-out;
  will-change: opacity;
}

.gear-slide.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Left Specs Column */
.gear-spec-col {
  display: flex;
  flex-direction: column;
}

.gear-badge-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  margin-bottom: 10px;
}

.gear-status-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-signal);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.gear-item-name {
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 10px;
  color: var(--text-main);
  line-height: 1.25;
}

.gear-item-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 22px;
}

.gear-specs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.gear-spec-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 14px;
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.gear-spec-card:hover {
  border-color: var(--text-dim);
  transform: translateY(-2px);
}

.gear-spec-k {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 700;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}

.gear-spec-v {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.35;
}

.gear-footer-note {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding-top: 14px;
  border-top: 1px solid var(--border-line);
}

/* Right Visual Column */
.gear-visual-col {
  display: flex;
  flex-direction: column;
  height: 100%;
  justify-content: center;
}

.gear-visual-frame {
  position: relative;
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  padding: 24px 20px 16px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  min-height: 380px;
  overflow: hidden;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.2);
}

.visual-corner {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1;
  user-select: none;
}

.visual-corner-tl { top: 6px; left: 8px; }
.visual-corner-tr { top: 6px; right: 8px; }
.visual-corner-bl { bottom: 6px; left: 8px; }
.visual-corner-br { bottom: 6px; right: 8px; }

.gear-visual-tag {
  font-size: 0.68rem;
  color: var(--text-dim);
  letter-spacing: 0.04em;
  align-self: flex-start;
  z-index: 2;
}

.gear-product-img-wrap {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gear-product-img {
  max-height: 220px;
  max-width: 92%;
  object-fit: contain;
  filter: drop-shadow(0 16px 24px rgba(0, 0, 0, 0.45));
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
  user-select: none;
}

[data-theme="light"] .gear-product-img {
  filter: drop-shadow(0 14px 20px rgba(0, 0, 0, 0.15));
}

.gear-visual-frame:hover .gear-product-img {
  transform: translateY(-5px) scale(1.03);
  filter: drop-shadow(0 20px 32px rgba(0, 0, 0, 0.55));
}

/* Antigravity Pedestal Grid & Elevation Aura */
.gear-pedestal-grid {
  position: absolute;
  bottom: 44px;
  width: 75%;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(59, 130, 246, 0.22) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
  filter: blur(4px);
}

[data-theme="light"] .gear-pedestal-grid {
  background: radial-gradient(ellipse at center, rgba(30, 58, 138, 0.12) 0%, transparent 70%);
}

.gear-visual-caption {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.7rem;
  color: var(--text-dim);
  padding-top: 10px;
  border-top: 1px solid var(--border-line);
  z-index: 2;
}

/* Tech Stack Icons Showcase in Workspace Slide */
.gear-stack-frame {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  min-height: 380px;
}

.tech-stack-showcase {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 8px;
  z-index: 3;
}

.tech-icons-grid {
  display: grid;
  grid-template-columns: repeat(5, 52px);
  gap: 14px 14px;
  justify-content: center;
  align-items: center;
}

.tech-icon-cell {
  position: relative;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), filter 0.25s ease;
}

.tech-badge-img {
  width: 100%;
  height: 100%;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease;
  user-select: none;
}

.tech-icon-cell:hover {
  transform: translateY(-5px) scale(1.1);
  z-index: 5;
}

.tech-icon-cell:hover .tech-badge-img {
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.5), 0 0 12px rgba(59, 130, 246, 0.4);
}

.tech-badge-tooltip {
  position: absolute;
  bottom: -22px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
  color: var(--text-main);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 10;
}

.tech-icon-cell:hover .tech-badge-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(-2px);
}

/* Responsive Overrides for Workspace Carousel & Skills Console */
@media (max-width: 992px) {
  .gear-tabs-bar {
    grid-template-columns: repeat(2, 1fr);
  }

  .gear-stage {
    min-height: auto;
  }

  .gear-slide {
    grid-area: 1 / 1;
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .gear-visual-frame {
    min-height: 280px;
  }

  .gear-product-img-wrap {
    height: 190px;
  }

  .gear-product-img {
    max-height: 180px;
  }

  /* Skills Matrix Master-Detail Responsive */
  .skill-layout-container {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .skill-nav-vertical {
    display: grid;
    grid-template-columns: 1fr;
    overflow: hidden;
  }

  .skill-nav-group {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 6px;
  }

  .skill-nav-btn {
    flex: 1;
    min-width: 200px;
  }

  .skill-slide {
    grid-area: 1 / 1;
    padding: 20px 18px;
  }
}

@media (max-width: 640px) {
  .gear-tabs-bar {
    grid-template-columns: 1fr;
  }

  .gear-specs-grid {
    grid-template-columns: 1fr;
  }

  .skill-nav-group {
    flex-direction: column;
    overflow-x: visible;
  }

  .skill-nav-btn {
    min-width: auto;
    width: 100%;
  }

  .skill-spec-row {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 10px 4px;
  }

  .tech-icons-grid {
    grid-template-columns: repeat(5, 42px);
    gap: 8px;
  }

  .tech-icon-cell {
    width: 42px;
    height: 42px;
  }
}

/* --- 9. EDUCATION SECTION (#education) --- */
.education-split {
  display: grid;
  grid-template-columns: 420px 1fr;
  gap: 36px;
  background: var(--bg-surface);
  border: 1px solid var(--border-line);
  padding: 32px 36px;
  align-items: center;
}

.edu-photo-block {
  display: flex;
  flex-direction: column;
}

.edu-img-wrap {
  display: block;
  padding: 0;
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  overflow: hidden;
  border: 1px solid var(--border-line);
  position: relative;
  background: #000;
  cursor: pointer;
}

.edu-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 55%;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.edu-img-wrap:hover img {
  transform: scale(1.03);
}

.edu-location-caption {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-dim);
  display: flex;
  justify-content: space-between;
}

.edu-details-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.edu-meta-row {
  display: flex;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.edu-degree {
  font-size: 1.55rem;
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

.edu-school {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.edu-desc {
  font-size: 0.94rem;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 0;
}

.edu-course-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 0;
}

.course-item {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 8px 12px;
  background: var(--bg-main);
  border: 1px solid var(--border-line);
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: border-color var(--transition-fast), background-color var(--transition-fast);
}

.course-item:hover {
  border-color: var(--border-focus);
  background: var(--bg-card);
}

.course-item::before {
  content: '—';
  color: var(--text-dim);
}

.edu-quote-note {
  font-size: 0.84rem;
  border-left: 2px solid var(--text-main);
  padding-left: 14px;
  color: var(--text-muted);
  font-style: italic;
}

/* --- 10. PROJECTS SECTION (#projects) --- */
.projects-empty-stage {
  min-height: 120px;
  border: 1px dashed var(--border-line);
  background: var(--bg-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  position: relative;
}

/* --- 11. LIGHTBOX MODAL --- */
.lightbox-frame-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 30px;
}

.lightbox-frame-modal[open] {
  display: flex;
}

.lightbox-frame-modal::backdrop {
  background: transparent;
}

.lightbox-dimmer {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(10px);
}

.lightbox-dialog {
  position: relative;
  z-index: 10;
  max-width: 1040px;
  width: 92vw;
  border: 1px solid var(--border-line);
  background: #000000;
  padding: 16px;
}

.lightbox-img-box {
  width: 100%;
  max-height: 78vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

.lightbox-img-box img {
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
}

.lightbox-meta-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: #fff;
}

/* --- 12. TOAST SYSTEM --- */
.toast-shelf {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 600;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast-msg {
  padding: 10px 18px;
  background: var(--text-main);
  color: var(--bg-main);
  border: 1px solid var(--border-line);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  animation: toast-fade 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes toast-fade {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --- 13. FOOTER / BIO HUB --- */
.main-footer {
  border-top: 1px solid var(--border-line);
  background: var(--bg-surface);
  padding: 40px 24px;
  position: relative;
  z-index: 10;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-cred {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-social-links {
  display: flex;
  gap: 8px;
}

.footer-contact-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-contact-title {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--accent-signal);
  letter-spacing: 0.06em;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-sub-note {
  width: 100%;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-dim);
  padding-top: 14px;
  margin-top: 20px;
  border-top: 1px dashed var(--border-line);
  letter-spacing: 0.02em;
}

/* --- 14. RESPONSIVE BREAKPOINTS --- */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .about-grid-layout {
    grid-template-columns: 1fr;
  }
  .about-box-full {
    grid-column: span 1;
  }
  .education-split {
    grid-template-columns: 300px 1fr;
    gap: 20px;
  }
  .spotlight-content {
    grid-template-columns: 1fr;
  }
  .projects-ledger {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .education-split {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 18px;
  }
  .edu-img-wrap {
    aspect-ratio: 16 / 10;
    max-height: 280px;
  }
  .nav-menu {
    display: none;
  }
  .nav-brand-sub {
    display: none;
  }
  .mobile-toggle {
    display: flex;
  }
  .hero-display-name {
    font-size: 2.4rem;
  }
  .hero-btn-row {
    flex-wrap: wrap;
  }
  .plate-photo-wrap {
    height: 300px;
  }
  .section-headline-box {
    flex-direction: column;
    gap: 8px;
  }
  .section-summary-text {
    text-align: left;
  }
  .specs-ledger {
    grid-template-columns: 1fr;
  }
  .spec-cell {
    border-right: none;
    border-bottom: 1px solid var(--border-line);
  }
  .spec-cell:last-child {
    border-bottom: none;
  }
  .interest-row {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 10px 0;
  }
  .skills-groups-wrapper {
    grid-template-columns: 1fr;
  }
  .skills-manifest-box .box-title-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .skill-stage-box .box-title-bar {
    flex-wrap: wrap;
    gap: 12px;
  }
  .skill-group-toggle {
    order: 3;
    width: 100%;
    justify-content: center;
  }
  .skill-filter-btn {
    flex: 1;
    justify-content: center;
  }
  .skill-context-strip {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .skill-context-meta {
    margin-left: 21px;
  }
  .skills-tab-nav {
    width: 100%;
    display: flex;
    justify-content: space-between;
  }
  .skills-nav-btn {
    flex: 1;
    justify-content: center;
    padding: 6px 4px;
    font-size: 0.68rem;
  }
  .filmstrip-frame {
    flex: 0 0 280px;
  }
  .manifest-grid {
    grid-template-columns: 1fr;
  }
  .edu-course-grid {
    grid-template-columns: 1fr;
  }
  .spotlight-content {
    padding: 24px 16px;
  }
  .spotlight-btn-group {
    flex-direction: column;
  }
  .cad-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .footer-inner {
    flex-direction: column;
    text-align: center;
    gap: 16px;
  }
  .footer-social-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* =================================================================
   WINTER & NOEL (CHRISTMAS) SEASONAL SYSTEM — ENHANCED VIBE
   ================================================================= */

/* 1. Snowflake Action Button */
.btn-xmas {
  position: relative;
  color: var(--text-muted);
  transition: all 0.25s ease;
}

.btn-xmas:hover {
  color: #38bdf8;
  border-color: #38bdf8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.45);
}

.btn-xmas.is-active {
  background: rgba(244, 63, 94, 0.18);
  color: #f43f5e;
  border-color: #f43f5e;
  box-shadow: 0 0 16px rgba(244, 63, 94, 0.5);
}

.btn-xmas.is-active i {
  color: #4ade80;
  filter: drop-shadow(0 0 8px rgba(74, 222, 128, 0.9));
  animation: snowflakeSpin 8s linear infinite;
}

@keyframes snowflakeSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 2. Atmospheric Snow Canvas & Warm Noel Green & Red Ambient Glow */
.snow-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 998;
  opacity: 0;
  transition: opacity 0.7s ease;
}

.xmas-mode .snow-canvas {
  opacity: 1;
}

.xmas-ambient-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    /* Top rich Christmas Red / Santa Cranberry glow */
    radial-gradient(ellipse 90% 55% at 50% -8%, rgba(225, 29, 72, 0.32), transparent 70%),
    /* Bottom-left rich Christmas Pine Green tree glow */
    radial-gradient(circle 650px at 5% 90%, rgba(22, 163, 74, 0.30), transparent 60%),
    /* Bottom-right warm Christmas Cranberry / Fireplace hearth glow */
    radial-gradient(circle 650px at 95% 90%, rgba(239, 68, 68, 0.28), transparent 60%),
    /* Center warm golden candlelight hearth glow */
    radial-gradient(ellipse 65% 45% at 50% 50%, rgba(245, 158, 11, 0.14), transparent 65%),
    /* Top-right Christmas Pine Green aura */
    radial-gradient(circle 500px at 90% 10%, rgba(34, 197, 94, 0.22), transparent 55%),
    /* Top-left subtle Christmas Red aura */
    radial-gradient(circle 500px at 10% 10%, rgba(244, 63, 94, 0.20), transparent 55%);
  opacity: 0;
  transition: opacity 0.8s ease;
}

.xmas-mode .xmas-ambient-glow {
  opacity: 1;
}

/* 3. Festive Fairy Lights String */
.xmas-fairy-lights {
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-around;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 102;
  overflow: hidden;
}

.xmas-mode .xmas-fairy-lights {
  opacity: 1;
}

.light-bulb {
  width: 6px;
  height: 9px;
  border-radius: 50% 50% 40% 40%;
  position: relative;
  box-shadow: 0 2px 8px currentColor;
  animation: fairyGlow 2s infinite alternate ease-in-out;
}

.light-bulb::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 1px;
  width: 4px;
  height: 2px;
  background: #334155;
  border-radius: 1px;
}

.light-red { color: #f43f5e; background: #f43f5e; animation-delay: 0s; }
.light-gold { color: #fbbf24; background: #fbbf24; animation-delay: 0.5s; }
.light-green { color: #22c55e; background: #22c55e; animation-delay: 1.0s; }
.light-blue { color: #38bdf8; background: #38bdf8; animation-delay: 1.5s; }

@keyframes fairyGlow {
  0% {
    opacity: 0.4;
    transform: scale(0.9);
    filter: brightness(0.85) drop-shadow(0 0 2px currentColor);
  }
  100% {
    opacity: 1;
    transform: scale(1.15);
    filter: brightness(1.35) drop-shadow(0 0 10px currentColor);
  }
}

/* Snow Accumulation Crest on Cards */
.xmas-mode .about-box,
.xmas-mode .profile-spec-plate,
.xmas-mode .education-split,
.xmas-mode .skill-stage-box,
.xmas-mode .projects-empty-stage,
.xmas-mode .specs-ledger {
  position: relative;
  background: rgba(15, 34, 25, 0.88) !important;
  border-color: rgba(74, 222, 128, 0.25) !important;
}

.xmas-mode .about-box::after,
.xmas-mode .profile-spec-plate::after,
.xmas-mode .education-split::after,
.xmas-mode .skill-stage-box::after,
.xmas-mode .projects-empty-stage::after,
.xmas-mode .specs-ledger::after {
  content: '';
  position: absolute;
  top: -1px;
  left: 6%;
  right: 6%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(254, 240, 138, 0.8) 25%, #ffffff 50%, rgba(254, 240, 138, 0.8) 75%, transparent);
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
  pointer-events: none;
  border-radius: 2px;
}

/* --- VÙNG 1: HERO SPECS STRIP (Ảnh 1) --- */
.xmas-mode .specs-ledger {
  border-color: rgba(74, 222, 128, 0.32) !important;
  background: rgba(15, 34, 25, 0.88) !important;
}

.xmas-mode .specs-ledger .spec-cell:nth-child(1) .spec-label::after {
  content: ' ❄️ 🧦';
  font-size: 0.82rem;
  margin-left: 4px;
}

.xmas-mode .specs-ledger .spec-cell:nth-child(2) .spec-label::after {
  content: ' 🎄 🎁';
  font-size: 0.82rem;
  margin-left: 4px;
}

.xmas-mode .specs-ledger .spec-cell:nth-child(3) .spec-label::after {
  content: ' 🦌 💤';
  font-size: 0.82rem;
  margin-left: 4px;
}

.xmas-mode .specs-ledger .spec-cell:hover {
  background: rgba(239, 68, 68, 0.15);
}

/* --- VÙNG 2: BOX 01 & BOX 02 (Ảnh 2) --- */
.xmas-mode .interest-row:nth-child(1) .interest-name::after { content: ' ❄️'; }
.xmas-mode .interest-row:nth-child(2) .interest-name::after { content: ' 📷 🎄'; }
.xmas-mode .interest-row:nth-child(3) .interest-name::after { content: ' ☕ 🎅'; }
.xmas-mode .interest-row:nth-child(4) .interest-name::after { content: ' 🦌 🧦'; }

.xmas-mode .about-box:nth-child(1) .box-number {
  color: #ef4444 !important;
}
.xmas-mode .about-box:nth-child(1) .box-number::before {
  content: '🎄 ';
}

.xmas-mode .spotify-deck-box .box-number {
  color: #22c55e !important;
}
.xmas-mode .spotify-deck-box .box-number::before {
  content: '❄️ ';
}

.xmas-mode .spotify-canvas-frame {
  position: relative;
  border-color: rgba(239, 68, 68, 0.35) !important;
}

.xmas-mode .spotify-canvas-frame::before {
  content: '🧦';
  position: absolute;
  top: -12px;
  right: 12px;
  font-size: 1.15rem;
  z-index: 10;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
  animation: giftWiggle 3.5s infinite ease-in-out;
}

/* --- VÙNG 3: SECTION 02 - TECH STACK RIGHT CONTENT PANE (Ảnh 3) --- */
.xmas-mode .skill-content-panel {
  position: relative;
  border-color: rgba(74, 222, 128, 0.28) !important;
  background: rgba(15, 34, 25, 0.75) !important;
}

.xmas-skill-badge {
  display: none;
  position: absolute;
  top: 14px;
  right: 16px;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: #86efac;
  background: rgba(34, 197, 94, 0.16);
  border: 1px solid rgba(74, 222, 128, 0.35);
  padding: 3px 8px;
  z-index: 5;
}

.xmas-mode .xmas-skill-badge {
  display: inline-flex;
}

.xmas-mode .skill-group-toggle {
  background: rgba(5, 18, 12, 0.7);
  border-color: rgba(74, 222, 128, 0.25);
}

.xmas-mode .skill-filter-btn.active {
  background: rgba(16, 44, 28, 0.85);
  border-color: rgba(74, 222, 128, 0.4);
}

.xmas-mode .skill-filter-btn.active .skill-filter-dot {
  background: #4ade80;
  box-shadow: 0 0 10px rgba(74, 222, 128, 0.8);
}

.xmas-mode .skill-filter-btn.active .skill-count-badge {
  background: rgba(74, 222, 128, 0.2);
  color: #4ade80;
}

.xmas-mode .skill-context-strip {
  background: rgba(10, 26, 18, 0.85);
  border-color: rgba(74, 222, 128, 0.25);
  border-left-color: #ef4444;
}

.xmas-mode .skill-context-strip .fa-terminal {
  color: #4ade80 !important;
}

.xmas-mode .skill-nav-btn:hover,
.xmas-mode .skill-nav-btn.active {
  border-color: rgba(239, 68, 68, 0.6) !important;
}

.xmas-mode .skill-nav-btn.active {
  background: rgba(239, 68, 68, 0.16) !important;
}

.xmas-mode #skillNavGroupCurrent .skill-nav-btn[data-skill-index="0"] .skill-nav-title::after { content: ' ❄️'; }
.xmas-mode #skillNavGroupCurrent .skill-nav-btn[data-skill-index="1"] .skill-nav-title::after { content: ' 🎄'; }
.xmas-mode #skillNavGroupCurrent .skill-nav-btn[data-skill-index="2"] .skill-nav-title::after { content: ' 🦌'; }
.xmas-mode #skillNavGroupCurrent .skill-nav-btn[data-skill-index="3"] .skill-nav-title::after { content: ' 🧦'; }
.xmas-mode #skillNavGroupCurrent .skill-nav-btn[data-skill-index="4"] .skill-nav-title::after { content: ' 🎁'; }

.xmas-mode #skillNavGroupInterested .skill-nav-btn[data-skill-index="0"] .skill-nav-title::after { content: ' ❄️'; }
.xmas-mode #skillNavGroupInterested .skill-nav-btn[data-skill-index="1"] .skill-nav-title::after { content: ' 🎄'; }
.xmas-mode #skillNavGroupInterested .skill-nav-btn[data-skill-index="2"] .skill-nav-title::after { content: ' 🎁'; }
.xmas-mode #skillNavGroupInterested .skill-nav-btn[data-skill-index="3"] .skill-nav-title::after { content: ' 🦌'; }

/* --- VÙNG 4: WORKSPACE MANIFEST (SPECS GRID & CAD RENDER) (Ảnh 4) --- */
.xmas-mode .gear-specs-grid .gear-spec-card {
  position: relative;
  border-color: rgba(74, 222, 128, 0.25) !important;
  background: rgba(15, 34, 25, 0.8) !important;
}

.xmas-mode .gear-specs-grid .gear-spec-card:nth-child(1) .gear-spec-k::after { content: ' ❄️'; }
.xmas-mode .gear-specs-grid .gear-spec-card:nth-child(2) .gear-spec-k::after { content: ' 🎁'; }
.xmas-mode .gear-specs-grid .gear-spec-card:nth-child(3) .gear-spec-k::after { content: ' 🧦'; }
.xmas-mode .gear-specs-grid .gear-spec-card:nth-child(4) .gear-spec-k::after { content: ' 🦌'; }

.xmas-mode .gear-visual-frame {
  position: relative;
  border-color: rgba(239, 68, 68, 0.35) !important;
}

.xmas-gear-hat {
  display: none;
  position: absolute;
  top: -14px;
  left: 12px;
  font-size: 1.4rem;
  z-index: 10;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.5));
  animation: giftWiggle 3.2s infinite ease-in-out;
}

.xmas-mode .xmas-gear-hat {
  display: block;
}

.xmas-mode .gear-visual-tag::after {
  content: ' ❄️ 🎄';
}

/* --- VÙNG 5: HỌC VẤN (TLU) & PROJECTS STAGE (Ảnh 5) --- */
.xmas-mode .edu-photo-block {
  position: relative;
}

.xmas-campus-badge {
  display: none;
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 1.2rem;
  z-index: 5;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

.xmas-mode .xmas-campus-badge {
  display: block;
}

.xmas-mode .edu-location-caption span:first-child::after {
  content: ' ❄️';
}
.xmas-mode .edu-location-caption span:last-child::after {
  content: ' 🎄';
}

.xmas-mode .edu-meta-row span:last-child::after {
  content: ' 🎓 ❄️';
}

.xmas-mode .edu-desc::after {
  content: ' ☕ 🎄';
}

/* Projects Empty Stage in Xmas mode */
.xmas-empty-banner {
  display: none;
  text-align: center;
  padding: 20px 14px;
}

.xmas-mode .projects-empty-stage .default-empty-msg {
  display: none;
}

.xmas-mode .projects-empty-stage .xmas-empty-banner {
  display: block;
}

.xmas-empty-emojis {
  font-size: 1.6rem;
  margin-bottom: 8px;
  letter-spacing: 6px;
  animation: giftWiggle 3s infinite ease-in-out;
}

.xmas-empty-lead {
  font-size: 0.85rem;
  color: #86efac;
  font-weight: 700;
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.xmas-empty-note {
  font-size: 0.82rem;
  color: #cbd5e1;
}

/* General Noel Typography & Floating Badge */
.xmas-mode .nav-brand .nav-indicator {
  background: #22c55e !important;
  box-shadow: 0 0 10px #22c55e;
}

.xmas-mode .nav-brand::after {
  content: ' 🎄';
  font-size: 0.9rem;
  margin-left: 2px;
}

.xmas-mode .hero-meta-strip span:last-child::after {
  content: ' ❄️ 🎄';
  font-size: 0.85rem;
}

.xmas-mode .about-box .box-title-bar .box-tag::after {
  content: ' 🎁';
  font-size: 0.85rem;
  margin-left: 4px;
}

.xmas-mode #education .section-heading::after {
  content: ' 🎄';
  font-size: 1.5rem;
  margin-left: 8px;
}

.xmas-mode #about .section-heading::after {
  content: ' ❄️';
  font-size: 1.5rem;
  margin-left: 8px;
}

.xmas-mode #projects .section-heading::after {
  content: ' 🔔';
  font-size: 1.5rem;
  margin-left: 8px;
}

/* Floating Cozy Christmas Gift Badge */
.xmas-floating-gift {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(16, 36, 26, 0.95);
  border: 1px solid rgba(239, 68, 68, 0.6);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5), 0 0 16px rgba(239, 68, 68, 0.4);
  color: #fcfbf9;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 0;
  cursor: pointer;
  z-index: 997;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.xmas-mode .xmas-floating-gift {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.xmas-floating-gift:hover {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.25);
  box-shadow: 0 6px 24px rgba(239, 68, 68, 0.55);
  transform: translateY(-2px);
}

.xmas-floating-gift .gift-icon {
  font-size: 1.15rem;
  animation: giftWiggle 3s infinite ease-in-out;
}

@keyframes giftWiggle {
  0%, 80%, 100% { transform: rotate(0deg); }
  85% { transform: rotate(-8deg) scale(1.08); }
  90% { transform: rotate(8deg) scale(1.08); }
  95% { transform: rotate(-4deg); }
}

/* Seasonal selection color */
.xmas-mode ::selection {
  background: #dc2626;
  color: #ffffff;
}

/* Seasonal hero primary button styling */
.xmas-mode .hero-btn-row .btn-primary-sharp {
  background: #dc2626 !important;
  color: #ffffff !important;
  border-color: #ef4444 !important;
  box-shadow: 0 0 20px rgba(220, 38, 38, 0.5);
}

.xmas-mode .hero-btn-row .btn-primary-sharp:hover {
  background: #b91c1c !important;
  box-shadow: 0 0 26px rgba(239, 68, 68, 0.7);
}

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

  .reveal-ready .reveal:not(.is-visible) {
    opacity: 1;
    filter: none;
    transform: none;
  }
}
