/* ================================================================
   SabrinaDreamCircuit — Design System
   A dreamy, cozy, pastel gamer-aesthetic portfolio
   ================================================================ */

/* ──────────────── Google Fonts & Custom Fonts ──────────────── */
@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;600;700&family=DM+Sans:wght@400;500;700&display=swap');

@font-face {
  font-family: 'Handodle';
  src: url('../assets/fonts/handodle/Handodle-rg38A.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  /* Exclude '&', '(', ')', and '0-9' */
  unicode-range: U+0000-0025, U+0027, U+002A-002F, U+003A-FFFF;
}

@font-face {
  font-family: 'Sister Lovely';
  src: url('../assets/fonts/sister-lovely/Sister Lovely.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
  unicode-range: U+0000-0025, U+0027, U+002A-002F, U+003A-FFFF;
}

@font-face {
  font-family: 'Child Hood';
  src: url('../assets/fonts/child-hood/Child Hood.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
  unicode-range: U+0000-0025, U+0027, U+002A-002F, U+003A-FFFF;
}

/* ──────────────── CSS Custom Properties ──────────────── */
:root {
  /* 🎇 Customize your fireworks burst here!
     Replace 'none' with url('../assets/images/your-spark.png') to use your own image. */
  --firework-image: url('../assets/icons/sparkles/41916488_8964633.png');

  /* ⭐ Custom Star Cursor Image */
  --star-cursor-img: url('../assets/icons/sparkles/silver-star-glitter-png%20(1).png');

  /* Primary Palette */
  --lavender: #c4b5fd;
  --lavender-light: #ddd6fe;
  --lavender-deep: #8b5cf6;
  --pink: #f9a8d4;
  --pink-light: #fbcfe8;
  --pink-deep: #ec4899;
  --mint: #a7f3d0;
  --mint-deep: #34d399;
  --blue: #93c5fd;
  --blue-deep: #60a5fa;
  --cream: #fef3c7;
  --cream-light: #fefce8;

  /* Background & Surface */
  --bg-primary: #0f0a19;
  --bg-secondary: #1a1025;
  --bg-card: rgba(30, 20, 50, 0.7);
  --bg-glass: rgba(30, 20, 50, 0.5);
  --bg-modal: rgba(10, 6, 18, 0.92);

  /* Text */
  --text-primary: #f0e6ff;
  --text-secondary: #b8a4d6;
  --text-muted: #8b7aad;

  /* Borders & Shadows */
  --border-glass: rgba(196, 181, 253, 0.15);
  --shadow-soft: 0 4px 30px rgba(139, 92, 246, 0.1);
  --shadow-glow: 0 0 30px rgba(196, 181, 253, 0.15);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);

  /* Gradients */
  --gradient-brand: linear-gradient(135deg, var(--lavender), var(--pink), var(--blue));
  --gradient-hero: linear-gradient(160deg, #1a1025 0%, #150d22 30%, #1e1433 60%, #0f0a19 100%);
  --gradient-btn: linear-gradient(135deg, var(--lavender-deep), var(--pink-deep));
  --gradient-btn-hover: linear-gradient(135deg, var(--pink-deep), var(--lavender-deep));

  /* Layout */
  --max-width: 1200px;
  --nav-height: 70px;
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 50px;

  /* Transitions */
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.2s var(--ease-smooth);
  --transition-med: 0.35s var(--ease-smooth);
  --transition-slow: 0.6s var(--ease-smooth);
}

/* ──────────────── Reset & Base ──────────────── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  overflow-x: hidden;
}

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

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-fast);
}

img {
  max-width: 100%;
  display: block;
}

ul {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  line-height: 1.3;
}

/* ──────────────── Utility Classes ──────────────── */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-title {
  font-size: 2.2rem;
  text-align: center;
  margin: 0 auto 48px;
  background: url('../assets/bg/button.png') center/contain no-repeat;
  padding: 30px 60px;
  display: block;
  width: fit-content;
  color: #5d4037;
  /* Brown text */
  text-shadow: 0 0 8px #fff, 0 0 12px #fff, 0 0 16px #fff;
  /* White glow */
  font-family: 'Child Hood', 'Quicksand', sans-serif;
}

.section-title span {
  display: inline-block;
  position: relative;
}

.section-title span::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  width: 60%;
  height: 3px;
  background: var(--gradient-brand);
  border-radius: 2px;
}

/* ──────────────── Sparkle / Stars Background ──────────────── */
.sparkle-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.sparkle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--lavender-light);
  border-radius: 50%;
  animation: sparkle-float 6s ease-in-out infinite;
  opacity: 0;
}

.sparkle:nth-child(odd) {
  background: var(--pink-light);
  animation-duration: 8s;
}

.sparkle:nth-child(3n) {
  background: var(--mint);
  width: 3px;
  height: 3px;
  animation-duration: 10s;
}

.sparkle:nth-child(5n) {
  background: var(--cream);
  width: 5px;
  height: 5px;
  animation-duration: 7s;
}

@keyframes sparkle-float {
  0% {
    opacity: 0;
    transform: translateY(0) scale(0);
  }

  20% {
    opacity: 1;
    transform: translateY(-30px) scale(1);
  }

  80% {
    opacity: 0.6;
    transform: translateY(-120px) scale(0.8);
  }

  100% {
    opacity: 0;
    transform: translateY(-180px) scale(0);
  }
}

/* Star twinkle effect */
.star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  animation: twinkle 3s ease-in-out infinite;
}

@keyframes twinkle {

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

  50% {
    opacity: 1;
    transform: scale(1.5);
  }
}

/* ──────────────── Navigation ──────────────── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  transition: background var(--transition-med);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

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

.nav-logo img {
  height: 48px;
  /* Increased height for better visibility */
  width: auto;
  display: block;
}


.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-links a {
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-secondary);
  position: relative;
  padding: 4px 0;
  transition: color var(--transition-fast);
  display: flex;
  align-items: center;
}

.nav-links a::before {
  content: '';
  display: inline-block;
  width: 22px;
  height: 22px;
  margin-right: 6px;
  background: url('../assets/bg/bow purple.png') center/contain no-repeat;
  transition: transform var(--transition-fast);
}

.nav-links a:hover::before {
  transform: rotate(-12deg) scale(1.1);
}

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--gradient-brand);
  border-radius: 2px;
  transition: width var(--transition-med);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}

.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition-fast);
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ──────────────── Hero Section ──────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--gradient-hero);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../assets/bg/hero-bg.png');
  background-size: cover;
  background-position: center;
  opacity: 0.35;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  padding: 0 24px;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: 1px;
  animation: fadeInUp 1s var(--ease-smooth) both;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-style: italic;
  animation: fadeInUp 1s 0.2s var(--ease-smooth) both;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: 36px;
  line-height: 1.8;
  animation: fadeInUp 1s 0.4s var(--ease-smooth) both;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 36px;
  background: var(--gradient-btn);
  color: white;
  border: none;
  border-radius: var(--radius-pill);
  font-family: 'Quicksand', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  animation: fadeInUp 1s 0.6s var(--ease-smooth) both;
  box-shadow: 0 4px 25px rgba(139, 92, 246, 0.3);
}

.hero-cta:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 35px rgba(139, 92, 246, 0.5);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ──────────────── Section Layout ──────────────── */
section {
  padding: 80px 0;
}

/* Tighten gap between Creative Vision → Featured Work */
#intro {
  padding-bottom: 32px;
}

#featured {
  padding-top: 32px;
}

/* ──────────────── Spinning Carousel ──────────────── */
.carousel-section {
  padding-top: var(--nav-height);
  padding-bottom: 20px;
  overflow: hidden;
  clip-path: inset(var(--nav-height) 0 0 0);
  /* Clip everything in the navbar area */
  display: flex;
  justify-content: center;
  align-items: flex-start;
  background: var(--bg-primary);
  min-height: 480px;
  position: relative;
}

.navbar {
  z-index: 5000 !important;
  /* Extremely high to stay above carousel items */
}

.carousel-container {
  width: 1px;
  height: 1px;
  position: relative;
  top: -600px;
  --wheel-angle: 0deg;
}

.spinning-wheel {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  transform: rotateZ(var(--wheel-angle));
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.carousel-nav-btn {
  position: absolute;
  top: 45%;
  /* Slightly higher for better mobile visibility */
  transform: translateY(-50%);
  width: 150px;
  height: 150px;
  background: none !important;
  border: none !important;
  cursor: pointer;
  z-index: 10000 !important;
  /* Above everything */
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast);
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  padding: 0;
}

.carousel-nav-btn img {
  width: 150px;
  /* HUGE arrows as requested */
  height: auto;
  opacity: 0.85;
  filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.6));
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.carousel-nav-btn:hover {
  transform: translateY(-50%) scale(1.15);
}

.carousel-nav-btn:hover img {
  opacity: 1;
  filter: drop-shadow(0 0 25px rgba(255, 255, 255, 0.9));
}

.prev-btn {
  left: 20px;
}

.next-btn {
  right: 20px;
}

/* Carousel Responsiveness */
@media (max-width: 1024px) {
  .carousel-container {
    transform: scale(0.8);
    top: -500px;
  }
}

@media (max-width: 768px) {
  .carousel-section {
    min-height: 350px; /* Increased to avoid clipping bottom of wheel */
  }

  .carousel-container {
    transform: scale(0.6);
    top: -330px;  /* Tucked up slightly to align with the < > arrows */
  }

  /* Arrows removed from mobile media query to keep the base 150px styles */
}

@media (max-width: 480px) {
  .carousel-section {
    min-height: 300px; /* Increased to give the wheel enough room */
  }

  .carousel-container {
    transform: scale(0.45);
    top: -240px;  /* Tucked up slightly to perfectly align with the < > arrows */
  }

  .prev-btn {
    left: 2px;
  }

  .next-btn {
    right: 2px;
  }

  .carousel-nav-btn img {
    width: 110px;
    /* Scale down slightly on mobile */
  }
}

.carousel-card {
  position: absolute;
  width: 150px;
  height: 200px;
  margin-left: -75px;
  margin-top: -100px;
  cursor: pointer;
  z-index: 10;
}

.carousel-card-counter-spin {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transform: rotateZ(calc(var(--card-theta) - var(--wheel-angle)));
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-circle {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-card);
  border: 4px solid var(--border-glass);
  transition: transform var(--transition-med), border-color var(--transition-med), box-shadow var(--transition-med);
}

.category-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: filter var(--transition-med), transform var(--transition-med);
}

.category-bottom-label {
  text-align: center;
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  color: var(--text-secondary);
  margin-top: 16px;
  font-size: 1.1rem;
  transition: color var(--transition-fast);
}

.category-center-label {
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 150px;
  /* Aligns with the circle height */
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  font-family: 'Quicksand', sans-serif;
  font-weight: 800;
  font-size: 1.8rem;
  color: #fff;
  opacity: 0;
  transform: scale(0.5);
  transition: opacity var(--transition-med), transform var(--transition-med);
  text-shadow: 0 4px 15px rgba(0, 0, 0, 0.9), 0 2px 5px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  white-space: nowrap;
  z-index: 20;
}

/* Revealed state (when clicked) */
.carousel-card.revealed .category-circle {
  transform: scale(1.15);
  border-color: var(--pink);
  box-shadow: 0 0 30px rgba(236, 72, 153, 0.4);
  z-index: 50;
}

.carousel-card.revealed .category-circle img {
  filter: brightness(0.3);
  transform: scale(1.08);
}

.carousel-card.revealed .category-center-label {
  opacity: 1;
  transform: scale(1.6);
  /* Pops massively, exceeding the circle bounds */
  z-index: 60;
  /* Display strongly above the circle */
}

.carousel-card.revealed .category-bottom-label {
  color: var(--pink);
}

/* ──────────────── Showreel Section ──────────────── */
.showreel-section {
  /* Extra top padding = original 60px + half the crystal height (~58px at new size) */
  padding: 118px 0 40px;
}

.showreel-wrapper {
  max-width: 100%;
  margin: 0 auto;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-glass);
  box-shadow: var(--shadow-glow);
  background: var(--bg-primary);
  position: relative;
  aspect-ratio: 16 / 9;
}

.showreel-wrapper iframe,
.showreel-wrapper video {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* ── Sliding Gate Overlay ── */
.gate {
  position: absolute;
  top: 0;
  width: 50%;
  height: 100%;
  z-index: 5;
  transition: transform 1.2s cubic-bezier(0.77, 0, 0.175, 1);
  will-change: transform;
  pointer-events: none;
}

.gate-left {
  left: 0;
  background: linear-gradient(135deg, var(--bg-primary) 60%, var(--bg-secondary));
  border-right: 1px solid rgba(196, 181, 253, 0.25);
  box-shadow: 2px 0 20px rgba(139, 92, 246, 0.15);
}

.gate-right {
  right: 0;
  background: linear-gradient(225deg, var(--bg-primary) 60%, var(--bg-secondary));
  border-left: 1px solid rgba(196, 181, 253, 0.25);
  box-shadow: -2px 0 20px rgba(139, 92, 246, 0.15);
}

/* Decorative logo / icon on each gate panel */
.gate::before {
  content: '✦';
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.6rem;
  color: rgba(196, 181, 253, 0.35);
  pointer-events: none;
}

.gate-left::before {
  right: 20px;
}

.gate-right::before {
  left: 20px;
}

/* Center seam glow */
.gate::after {
  content: '';
  position: absolute;
  top: 0;
  width: 2px;
  height: 100%;
  background: linear-gradient(to bottom,
      transparent 5%,
      rgba(196, 181, 253, 0.4) 30%,
      rgba(249, 168, 212, 0.5) 50%,
      rgba(196, 181, 253, 0.4) 70%,
      transparent 95%);
  pointer-events: none;
}

.gate-left::after {
  right: 0;
}

.gate-right::after {
  left: 0;
}

/* Open state — panels slide apart */
.gate-left.open {
  transform: translateX(-100%);
  box-shadow: inset -20px 0 40px rgba(196, 181, 253, 0.4), 2px 0 20px rgba(139, 92, 246, 0.15);
}

.gate-right.open {
  transform: translateX(100%);
  box-shadow: inset 20px 0 40px rgba(196, 181, 253, 0.4), -2px 0 20px rgba(139, 92, 246, 0.15);
}

.gate.open::before,
.gate.open::after {
  opacity: 0;
  transition: opacity 0.4s ease;
}

.section-intro {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 48px;
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

/* ── Crystal Scroll Hint (hero → showreel boundary) ── */
.crystal-scroll-hint {
  position: relative;
  height: 0;
  /* no layout height — pivot point at the section boundary */
  text-align: center;
  z-index: 20;
  pointer-events: none;
}

.crystal-scroll-hint img {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 169px;
  filter: drop-shadow(0 0 24px rgba(196, 181, 253, 0.55)) drop-shadow(0 0 8px rgba(139, 92, 246, 0.35));
  animation: crystal-float 3.2s ease-in-out infinite;
}

@keyframes crystal-float {

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

  50% {
    transform: translate(-50%, -50%) translateY(-14px);
  }
}

/* ── View More Crystal Button (below featured grid) ── */
.view-more-btn-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

.view-more-crystal-btn {
  position: relative;
  display: inline-block;
  text-decoration: none;
  transition: transform var(--transition-fast), filter var(--transition-fast);
}

.view-more-crystal-btn img {
  width: 182px;
  display: block;
  filter: drop-shadow(0 0 16px rgba(196, 181, 253, 0.4));
  transition: filter var(--transition-med);
}

.view-more-crystal-btn:hover {
  transform: translateY(-5px);
}

.view-more-crystal-btn:hover img {
  filter: drop-shadow(0 0 32px rgba(196, 181, 253, 0.85)) drop-shadow(0 0 12px rgba(139, 92, 246, 0.5));
}

.view-more-crystal-btn span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Child Hood', 'Quicksand', sans-serif;
  font-size: 1.5rem;
  color: #fff;
  text-shadow:
    0 0 14px rgba(196, 181, 253, 1),
    0 0 6px rgba(255, 255, 255, 0.9),
    0 2px 4px rgba(0, 0, 0, 0.4);
  white-space: nowrap;
  pointer-events: none;
  letter-spacing: 0.5px;
}

/* ──────────────── Featured Work (Home) ──────────────── */
.featured-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}


/* ──────────────── Base Hexagon Cards ──────────────── */
.featured-card,
.portfolio-card {
  position: relative;
  background: transparent;
  border: none;
  border-radius: 0;
  overflow: visible;
  transition: transform var(--transition-med), filter var(--transition-med);
  cursor: none !important;
  filter: drop-shadow(0 0 0px transparent);
}

.featured-card:hover,
.portfolio-card:hover {
  transform: translateY(-6px);
  filter: drop-shadow(0 0 25px rgba(0, 212, 255, 0.6));
}

/* Inner Hexagon Wrapper */
.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  clip-path: polygon(7% 0%, 93% 0%, 100% 50%, 93% 100%, 7% 100%, 0% 50%);
  background: var(--bg-card);
  overflow: hidden;
}

/* ──────────────── Revolving Neon Stroke Background ──────────────── */
@property --border-angle {
  syntax: "<angle>";
  inherits: true;
  initial-value: 0turn;
}

@keyframes revolve-stroke {
  to {
    --border-angle: 1turn;
  }
}

.featured-card::before,
.portfolio-card::before {
  content: '';
  position: absolute;
  inset: -4px;
  /* Extends outward to form a 4px border */
  background: conic-gradient(from var(--border-angle),
      transparent 20%,
      #00d4ff 45%,
      #ff9be8 50%,
      #00d4ff 55%,
      transparent 80%);
  clip-path: polygon(7% 0%, 93% 0%, 100% 50%, 93% 100%, 7% 100%, 0% 50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-med);
  z-index: -1;
  /* Always behind .card-inner */
}

.featured-card:hover::before,
.portfolio-card:hover::before {
  opacity: 1;
  animation: revolve-stroke 2.5s linear infinite;
}

/* ──────────────── Diagonal Shine Overlay ──────────────── */
@keyframes diagonal-shine {
  0% {
    background-position: 100% 0;
  }

  100% {
    background-position: 0% 0;
  }
}

.card-inner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg,
      transparent 0%,
      transparent 40%,
      rgba(4, 55, 242, 0.1) 45%,
      #859fffb3 50%,
      rgba(4, 55, 242, 0.1) 55%,
      transparent 60%,
      transparent 100%);
  background-size: 300% 100%;
  background-position: 100% 0;
  z-index: 8;
  pointer-events: none;
}

.featured-card:hover .card-inner::after,
.portfolio-card:hover .card-inner::after {
  animation: diagonal-shine 0.65s ease-out forwards;
}

/* ──────────────── Images ──────────────── */
.featured-card img,
.portfolio-card .thumb {
  width: 100%;
  aspect-ratio: 2/1;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.featured-card:hover img,
.portfolio-card:hover .thumb {
  transform: scale(1.05);
}

.featured-card .card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: linear-gradient(transparent, rgba(10, 6, 18, 0.9));
  transform: translateY(10px);
  opacity: 0;
  transition: var(--transition-med);
}

.featured-card:hover .card-overlay {
  transform: translateY(0);
  opacity: 1;
}

.card-overlay h3 {
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.card-overlay .card-tag {
  display: inline-block;
  font-size: 0.75rem;
  padding: 3px 10px;
  background: rgba(196, 181, 253, 0.2);
  border: 1px solid rgba(196, 181, 253, 0.3);
  border-radius: var(--radius-pill);
  color: var(--lavender-light);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
}

/* ──────────────── Portfolio Gallery ──────────────── */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
}

.filter-btn {
  padding: 8px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-pill);
  color: var(--text-secondary);
  font-family: 'Quicksand', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--gradient-btn);
  color: white;
  border-color: transparent;
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

/* portfolio-card base and thumb merged into the featured-card block above! */

.portfolio-card .card-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  background: linear-gradient(transparent, rgba(10, 6, 18, 0.9));
  opacity: 0;
  transform: translateY(8px);
  transition: var(--transition-med);
}

.portfolio-card:hover .card-info {
  opacity: 1;
  transform: translateY(0);
}

.portfolio-card .card-info h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.portfolio-card .card-info .card-tag {
  display: inline-block;
  font-size: 0.7rem;
  padding: 2px 8px;
  background: rgba(196, 181, 253, 0.2);
  border: 1px solid rgba(196, 181, 253, 0.3);
  border-radius: var(--radius-pill);
  color: var(--lavender-light);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
}

/* Card hidden by filter */
.portfolio-card.hidden {
  display: none;
}

/* ──────────────── ArtStation-Style Modal ──────────────── */
.project-modal {
  position: fixed;
  inset: 0;
  z-index: 6000;
  background: var(--bg-modal);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-med), visibility var(--transition-med);
  overflow-y: auto;
  padding: 40px 20px;
}

.project-modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  max-width: 900px;
  width: 100%;
  overflow: hidden;
  transform: scale(0.6);
  opacity: 0;
  transition: transform var(--transition-med), opacity var(--transition-med);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.project-modal.active .modal-content {
  transform: scale(1);
  opacity: 1;
}

.modal-close {
  position: fixed;
  top: 20px;
  right: 24px;
  width: 44px;
  height: 44px;
  background: rgba(30, 20, 50, 0.7);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-glass);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 6001;
  transition: var(--transition-fast);
  color: var(--text-primary);
  font-size: 1.3rem;
}

.modal-close:hover {
  background: var(--lavender-deep);
  transform: rotate(90deg);
}

/* Modal header */
.modal-header {
  padding: 32px 32px 16px;
}

.modal-header h2 {
  font-size: 1.6rem;
  margin-bottom: 8px;
}

.modal-header .modal-tag {
  display: inline-block;
  font-size: 0.78rem;
  padding: 4px 14px;
  background: rgba(196, 181, 253, 0.15);
  border: 1px solid rgba(196, 181, 253, 0.25);
  border-radius: var(--radius-pill);
  color: var(--lavender);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  margin-bottom: 16px;
}

.modal-description {
  padding: 0 32px 16px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.8;
}

.modal-tools {
  padding: 0 32px 24px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.modal-tools .tool-label {
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-right: 4px;
}

.modal-tools .tool-tag {
  font-size: 0.75rem;
  padding: 3px 10px;
  background: rgba(167, 243, 208, 0.1);
  border: 1px solid rgba(167, 243, 208, 0.2);
  border-radius: var(--radius-pill);
  color: var(--mint);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
}

/* ── Sub-category bar (inside modal, e.g. Traditional Art) ── */
/* One single wide rectangle; labels live inside it as inline items */
.subcategory-tabs {
  position: relative;
  /* needed for absolutely-placed bow */
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0 32px 20px;
  overflow: visible;
  /* let the bow peek above the bar */
}

/* The visible bar itself */
.subcategory-bar {
  display: flex;
  align-items: stretch;
  background: rgba(30, 20, 50, 0.7);
  border: 1px solid rgba(196, 181, 253, 0.25);
  border-radius: 10px;
  overflow: hidden;
  width: 100%;
  min-height: 44px;
}

/* Each category label inside the bar */
.subcategory-tab {
  flex: 1;
  padding: 10px 20px;
  background: transparent;
  border: none;
  border-right: 1px solid rgba(196, 181, 253, 0.15);
  color: var(--text-muted);
  font-family: 'Quicksand', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s ease, font-size 0.2s ease, background 0.2s ease;
  white-space: nowrap;
  letter-spacing: 0.3px;
}

.subcategory-tab:last-child {
  border-right: none;
}

.subcategory-tab:hover {
  color: var(--lavender-light);
  background: rgba(196, 181, 253, 0.06);
}

/* Active state: bigger text + gradient highlight */
.subcategory-tab.active {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.25), rgba(236, 72, 153, 0.18));
  color: #fff;
  font-size: 0.97rem;
  font-weight: 700;
  text-shadow: 0 0 12px rgba(196, 181, 253, 0.8);
  box-shadow: inset 0 0 16px rgba(196, 181, 253, 0.1);
}

/* ── Hopping Bow ── */
.hopping-bow {
  position: absolute;
  top: -28px;
  /* sits above the bar */
  left: 0;
  width: 36px;
  height: 36px;
  background: url('../assets/bg/bow purple.png') center/contain no-repeat;
  /* horizontal sliding transition */
  transition: left 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
  pointer-events: none;
  z-index: 20;
  opacity: 0;
  transform: translateX(-50%);
}

.hopping-bow.visible {
  opacity: 1;
}

.hopping-bow.hop-anim {
  animation: bow-hop 0.45s ease-out;
}

@keyframes bow-hop {
  0% {
    top: -28px;
  }

  40% {
    top: -50px;
  }

  100% {
    top: -28px;
  }
}

/* ── SVG arc trail keyframes ── */
@keyframes arc-draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes arc-fade {
  to {
    opacity: 0;
  }
}

@keyframes sparkle-pop {
  0% {
    opacity: 0;
  }

  30% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

/* Gallery rendered under a sub-category tab */
.subcategory-gallery {
  padding: 0 32px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.subcategory-gallery img {
  width: 100%;
  border-radius: var(--radius-sm);
  object-fit: contain;
  background: var(--bg-primary);
}

.subcategory-gallery video {
  width: 100%;
  border-radius: var(--radius-sm);
  background: var(--bg-primary);
}

.subcategory-gallery iframe {
  width: 100%;
  aspect-ratio: 16/9;
  border: none;
  border-radius: var(--radius-sm);
}

/* Modal gallery — scrollable vertical gallery like ArtStation */
.modal-gallery {
  padding: 0 32px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-gallery img {
  width: 100%;
  border-radius: var(--radius-sm);
  object-fit: contain;
  background: var(--bg-primary);
}

.modal-gallery video {
  width: 100%;
  border-radius: var(--radius-sm);
  background: var(--bg-primary);
}

.modal-gallery iframe {
  width: 100%;
  aspect-ratio: 16/9;
  border: none;
  border-radius: var(--radius-sm);
}

/* Gallery figure with caption */
.gallery-figure {
  margin: 0;
  display: flex;
  flex-direction: column;
}

/* Image wrapper — gives the overlay a reference box */
.figure-img-wrapper {
  position: relative;
  display: block;
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.figure-img-wrapper img {
  width: 100%;
  display: block;
  border-radius: var(--radius-sm);
  object-fit: contain;
  background: var(--bg-primary);
}

/* Tool labels overlaid at the bottom of each image */
.figure-tools-overlay {
  position: absolute;
  bottom: 10px;
  left: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  z-index: 5;
}

.figure-tools-overlay .figure-tool-tag {
  font-size: 0.7rem;
  padding: 2px 10px;
  background: rgba(10, 6, 18, 0.72);
  border: 1px solid rgba(196, 181, 253, 0.5);
  border-radius: var(--radius-pill);
  color: var(--lavender-light);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  box-shadow: 0 0 8px rgba(196, 181, 253, 0.2);
}

.gallery-caption {
  padding: 10px 4px 0;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-style: italic;
  border-top: 1px solid var(--border-glass);
  margin-top: 6px;
  padding-top: 8px;
}

/* Per-image tool tags (shown below each gallery image) */
.figure-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 0 4px;
}

.figure-tool-label {
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-right: 2px;
}

.figure-tool-tag {
  font-size: 0.73rem;
  padding: 2px 10px;
  background: rgba(167, 243, 208, 0.1);
  border: 1px solid rgba(167, 243, 208, 0.25);
  border-radius: var(--radius-pill);
  color: var(--mint);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
}

/* ──────────────── About Page ──────────────── */
.about-section {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
  align-items: start;
  background: url('../assets/bg/pastel plaid pattern texture.jpg') center/cover;
  padding: 60px;
  border-radius: 4px;
  box-shadow: 2px 10px 40px rgba(0, 0, 0, 0.5);
  position: relative;
  transform: rotate(-1.5deg);
  margin: 40px 0 60px;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.about-photo-wrapper {
  position: relative;
  transform: rotate(4deg);
  transition: transform var(--transition-med);
  z-index: 5;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border-radius: 2px;
  background: #fff;
  padding: 10px 10px 35px 10px;
  /* Polaroid paper effect */
}

.about-photo-wrapper:hover {
  transform: rotate(2deg) scale(1.02);
}

.about-photo-pin {
  position: absolute;
  top: -15px;
  right: -10px;
  font-size: 2.2rem;
  z-index: 10;
  text-shadow: 2px 4px 6px rgba(0, 0, 0, 0.4);
  pointer-events: none;
}

.about-photo {
  border-radius: 2px;
  overflow: hidden;
  position: relative;
}

.about-photo img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
  display: block;
}

.secret-note {
  margin-top: 40px;
  padding: 20px 24px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  transform: rotate(-2deg);
}

.secret-note h4 {
  font-family: 'Sister Lovely', 'Quicksand', sans-serif !important;
  font-size: 1.5rem;
  color: #1a1025;
  margin-bottom: 8px;
}

.secret-note p {
  font-family: 'Handodle', 'DM Sans', sans-serif !important;
  font-size: 1.15rem;
  color: #3f2a5a;
  line-height: 1.6;
}

.about-section h2 {
  font-family: 'Sister Lovely', 'Quicksand', sans-serif !important;
  color: #1a1025 !important;
  text-shadow: none;
}

.about-section h3 {
  font-family: 'Child Hood', 'Quicksand', sans-serif !important;
  color: #1a1025 !important;
  font-size: 2.2rem;
  text-shadow: none;
}

.about-section h2 .gradient-text {
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  -webkit-text-fill-color: #581c87;
  color: #581c87;
}

.about-text h2 {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.about-text-intro {
  background: url('../assets/bg/Fluffy bg.png') center/cover no-repeat;
  padding: 32px;
  border-radius: 12px;
  margin-bottom: 32px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.about-text-intro h2,
.about-text-intro p {
  color: #3f2a5a !important;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
}

.about-text p {
  font-family: 'Handodle', 'DM Sans', sans-serif !important;
  font-size: 1.25rem;
  color: #3f2a5a !important;
  font-weight: 500;
  margin-bottom: 16px;
  line-height: 1.6;
}

.brand-concept {
  background: rgba(255, 255, 255, 0.5);
  border-radius: var(--radius-md);
  padding: 32px;
  margin: 24px 0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  position: relative;
}

.brand-concept::before {
  content: '';
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  border-radius: calc(var(--radius-md) - 6px);
  background-image: url("data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='10' ry='10' stroke='%23581c87' stroke-width='2' stroke-dasharray='16%2c 16' stroke-dashoffset='0' stroke-linecap='square'/%3e%3c/svg%3e");
  pointer-events: none;
}

.brand-concept p {
  font-family: 'Handodle', 'DM Sans', sans-serif !important;
  font-size: 1.25rem;
  line-height: 1.6;
}

.brand-concept h3 {
  font-size: 2.4rem;
  margin-bottom: 12px;
}

.influences-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.influence-tag {
  padding: 6px 16px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--radius-pill);
  font-size: 1.15rem;
  font-family: 'Handodle', sans-serif;
  color: #3f2a5a;
  font-weight: 600;
  transition: var(--transition-fast);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.influence-tag:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.9);
  color: #1a1025;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 24px;
}

.skill-item {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  text-align: left;
  padding: 16px 20px;
  background: url('../assets/bg/Skills Paint.png') center/100% 100% no-repeat !important;
  border: none !important;
  border-radius: 8px;
  /* Slightly soften edges of the paint image if it reaches ends */
  font-size: 1.25rem;
  color: #1a1025 !important;
  text-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 5px rgba(255, 255, 255, 1), 0 2px 2px rgba(255, 255, 255, 0.8);
  font-family: 'Handodle', 'Quicksand', sans-serif !important;
  font-weight: 800;
  transition: var(--transition-fast);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.skill-item:hover {
  border-color: var(--lavender);
  transform: translateY(-2px);
}

.skill-item .skill-icon {
  font-size: 1.5rem;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.washi-resume-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 80px 140px;    /* Extra generous padding so 'contain' has a big bounding box */
  background: url('../assets/bg/Washi tape button.png') center/contain no-repeat;
  font-family: 'Handodle', sans-serif;
  font-size: 2.8rem;
  line-height: 0.85;     /* Tighten vertical gap when text wraps */
  word-spacing: -4px;
  color: #8b5cf6;
  text-shadow: 0 0 10px rgba(255,255,255,0.9), 1px 1px 0 #fff;
  text-decoration: none;
  font-weight: bold;
  transition: transform var(--transition-fast), filter var(--transition-fast);
  filter: drop-shadow(0 6px 15px rgba(0, 0, 0, 0.15));
}

.washi-resume-btn:hover {
  transform: translateY(-4px) rotate(-1deg);
  filter: drop-shadow(0 10px 20px rgba(139, 92, 246, 0.35));
}


/* ──────────────── Contact Page ──────────────── */
.contact-section {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1.3rem;
  color: var(--lavender);
  font-family: 'Quicksand', sans-serif;
  font-weight: 600;
  margin: 32px 0;
  padding: 20px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
}

.contact-email:hover {
  border-color: var(--lavender);
  box-shadow: var(--shadow-glow);
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
}

.social-link {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 50%;
  color: var(--text-secondary);
  font-size: 1.2rem;
  transition: var(--transition-fast);
}

.social-link:hover {
  background: var(--gradient-btn);
  color: white;
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(139, 92, 246, 0.3);
}

/* ──────────────── Footer ──────────────── */
.footer {
  padding: 40px 0;
  text-align: center;
  border-top: 1px solid var(--border-glass);
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer .footer-brand {
  font-family: 'Quicksand', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 8px;
}

/* ──────────────── Page Header (inner pages) ──────────────── */
.page-header {
  padding-top: calc(var(--nav-height) + 60px);
  padding-bottom: 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* Portfolio page: carousel already handles the nav-height offset,
   so the header below it only needs a small gap */
#portfolioPageHeader {
  padding-top: 24px;
  padding-bottom: 24px;
}

/* Tighten portfolio grid top padding */
#portfolioSection {
  padding-top: 24px;
}

/* Tighten gap between About page header and plaid section */
.page-header+section {
  padding-top: 32px;
}

.page-header h1 {
  font-size: 2.5rem;
}

.page-header p {
  color: var(--text-secondary);
  margin-top: 12px;
  font-size: 1.05rem;
}

/* ──────────────── Responsive ──────────────── */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-links {
    display: none !important;
    /* Absolute removal from layout */
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100vh;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-glass);
    flex-direction: column;
    justify-content: center;
    gap: 24px;
    z-index: 999;
  }

  .nav-links.open {
    display: flex !important;
  }

  .nav-links a {
    font-size: 1.15rem;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .featured-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .portfolio-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
  }

  .about-section {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 40px 24px;
    margin: 32px 0 40px;
  }

  .washi-resume-btn {
    padding: 50px 90px;
    font-size: 2rem;
  }

  .modal-header,
  .modal-description,
  .modal-tools,
  .modal-gallery {
    padding-left: 20px;
    padding-right: 20px;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .nav-logo {
    gap: 5px;
  }

  .nav-logo img {
    height: 32px;
  }

  .nav-logo img:nth-child(2) {
    max-width: 180px;
    object-fit: contain;
  }

  .filter-bar {
    gap: 6px;
  }

  .filter-btn {
    padding: 6px 14px;
    font-size: 0.78rem;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.8rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-description {
    font-size: 0.95rem;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .contact-email {
    font-size: 1rem;
    padding: 16px 20px;
  }

  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .about-section {
    padding: 24px 12px;
    margin: 16px 0 24px;
    overflow-x: hidden;
  }

  .brand-concept {
    padding: 20px;
  }

  .brand-concept h3 {
    font-size: 1.6rem;
  }

  .washi-resume-btn {
    padding: 24px 32px;
    font-size: 1.2rem; /* Reduced to ensure it fits 350px screens */
    width: 100%;
    box-sizing: border-box;
    white-space: normal;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for keyboard nav */
a:focus-visible,
button:focus-visible,
.filter-btn:focus-visible {
  outline: 2px solid var(--lavender);
  outline-offset: 3px;
}

/* ──────────────── Custom Neon JS Cursor ──────────────── */
.custom-cursor {
  position: fixed;
  pointer-events: none;
  z-index: 99999;
  width: 48px;
  height: 48px;
  background-image: var(--star-cursor-img);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;

  /* The extreme Neon Pink Drop-Shadow Stroke! */
  filter: drop-shadow(0px 0px 4px #ff00ff) drop-shadow(0px 0px 12px #ff1493) drop-shadow(0px 0px 20px #ff00ff);

  transform: translate(-50%, -50%) scale(0);
  opacity: 0;
  transition: transform 0.25s cubic-bezier(0.1, 0.8, 0.3, 1), opacity 0.2s;
  will-change: left, top, transform;
}

.custom-cursor.active {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

/* ──────────────── Fireworks Burst on Project Close ──────────────── */
.firework-particle {
  position: fixed;
  /* Increased size so custom PNGs/GIFs are much more visible */
  width: 80px;
  height: 80px;

  /* 1. Custom Image */
  background-image: var(--firework-image);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;

  /* 2. Fallback styling (Glowy circle) - 
     Commented out so it doesn't create a pink square behind your transparent GIF!
     Uncomment this if you change --firework-image back to 'none' */
  /* background-color: var(--pink-light);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--pink), 0 0 16px var(--lavender); */

  pointer-events: none;
  z-index: 9999;

  animation: explode var(--duration, 1.0s) cubic-bezier(0.1, 0.8, 0.3, 1) forwards;
}

@keyframes explode {
  0% {
    transform: translate(-50%, -50%) scale(0.2);
    opacity: 1;
  }

  100% {
    transform: translate(calc(-50% + var(--tx)), calc(-50% + var(--ty))) scale(var(--scale)) rotate(180deg);
    opacity: 0;
  }
}

/* ──────────────── Lightbox / Fullscreen Image ──────────────── */
.lightbox-modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(10, 5, 20, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 999999;
  display: flex;
  justify-content: center;
  align-items: center;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.3s ease, visibility 0.3s;
}

.lightbox-modal.active {
  visibility: visible;
  opacity: 1;
}

.lightbox-close {
  position: absolute;
  top: 24px; right: 32px;
  background: none; border: none; color: white;
  font-size: 3rem; cursor: pointer; z-index: 10;
  transition: color var(--transition-fast), transform var(--transition-fast);
  text-shadow: 0 0 10px rgba(255,255,255,0.5);
  padding: 0; line-height: 1;
}

.lightbox-close:hover {
  color: var(--pink);
  transform: scale(1.1) rotate(90deg);
}

.lightbox-content {
  width: 100%; height: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-start; /* Allows scrollbar to work properly from top */
  overflow: auto; 
  padding: 20px;
}

.lightbox-content img {
  max-width: 90%;
  max-height: 90vh;
  object-fit: contain;
  margin: auto; /* Centers the image inside the flex container */
  cursor: zoom-in;
  border-radius: 4px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  transition: width 0.3s ease, max-width 0.3s ease;
}

.lightbox-content img.zoomed {
  max-width: none;
  max-height: none;
  width: 200%; /* forces layout expansion for native scrolling */
  cursor: zoom-out;
}

@media (max-width: 768px) {
  .lightbox-content img.zoomed {
    width: 300%; /* Even bigger zoom on mobile to see details */
  }
}