/* ============================================================
   Fractal Observer — Art Gallery Stylesheet
   ============================================================ */

/* --- TOKENS --- */
:root {
  --bg: #000000;
  --deep: #03030a;
  --void: #07070f;
  --silver: #9898b0;
  --pale: #c4c4d8;
  --white: #e8e8f0;
  --violet-glow: rgba(120, 90, 200, 0.15);
  --blue-glow: rgba(40, 40, 120, 0.12);
  --accent: rgba(160, 130, 240, 0.9);
  --accent-dim: rgba(160, 130, 240, 0.3);
  --accent-solid: #a082f0;

  --font: Georgia, 'Times New Roman', serif;
  --mono: 'Courier New', monospace;

  --nav-h: 60px;
  --shop-w: clamp(300px, 42vw, 440px);
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Focus ring — consistent across all interactive elements */
  --focus-ring: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent-solid);
}

/* --- RESET --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}
body {
  font-family: var(--font);
  color: var(--pale);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  cursor: none;
}
a { color: inherit; text-decoration: none; cursor: none; }
button { cursor: none; background: none; border: none; color: inherit; font: inherit; }
img { display: block; max-width: 100%; }

/* Suppress browser default outlines globally;
   re-apply via :focus-visible on each element below */
:focus { outline: none; }

/* --- BODY LOCK (when shop/lightbox open) --- */
body.locked { overflow: hidden; }

/* --- CUSTOM CURSOR (desktop) --- */
#cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 5px; height: 5px;
  background: var(--white);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: transform 0.08s var(--ease-out), opacity 0.3s;
  mix-blend-mode: difference;
}
#cursor-ring {
  position: fixed;
  top: 0; left: 0;
  width: 34px; height: 34px;
  border: 1px solid rgba(200, 200, 220, 0.3);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width 0.35s var(--ease-out), height 0.35s var(--ease-out),
              border-color 0.3s, opacity 0.3s;
  mix-blend-mode: difference;
}
#cursor-ring.hover {
  width: 52px; height: 52px;
  border-color: var(--accent-solid);
}
@media (pointer: coarse) {
  #cursor-dot, #cursor-ring { display: none; }
  body, a, button { cursor: auto; }
}

/* --- STARFIELD CANVAS --- */
#starfield {
  position: fixed;
  inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  opacity: 0.55;
}

/* --- NEBULA LAYER --- */
#nebula-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.nebula {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  will-change: transform;
}
.n1 {
  width: 600px; height: 600px;
  top: -10%; left: -10%;
  background: radial-gradient(circle, rgba(80, 50, 160, 0.2) 0%, transparent 70%);
  animation: nebula-drift-1 40s ease-in-out infinite alternate;
}
.n2 {
  width: 500px; height: 500px;
  bottom: -5%; right: -5%;
  background: radial-gradient(circle, rgba(30, 40, 120, 0.18) 0%, transparent 70%);
  animation: nebula-drift-2 35s ease-in-out infinite alternate;
}
.n3 {
  width: 400px; height: 400px;
  top: 40%; left: 50%;
  background: radial-gradient(circle, rgba(100, 60, 180, 0.12) 0%, transparent 70%);
  animation: nebula-drift-3 45s ease-in-out infinite alternate;
}
@keyframes nebula-drift-1 {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(80px, 60px) scale(1.15); }
}
@keyframes nebula-drift-2 {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-60px, -40px) scale(1.1); }
}
@keyframes nebula-drift-3 {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, -50px) scale(1.2); }
}

/* --- ORBS --- */
#orbs {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  will-change: transform;
}
.orb-1 {
  width: 300px; height: 300px;
  top: 15%; left: 60%;
  background: rgba(110, 70, 200, 0.1);
  animation: orb-float-1 25s ease-in-out infinite alternate;
}
.orb-2 {
  width: 200px; height: 200px;
  top: 60%; left: 20%;
  background: rgba(50, 50, 150, 0.1);
  animation: orb-float-2 30s ease-in-out infinite alternate;
}
.orb-3 {
  width: 250px; height: 250px;
  top: 80%; left: 70%;
  background: rgba(130, 80, 200, 0.08);
  animation: orb-float-3 20s ease-in-out infinite alternate;
}
@keyframes orb-float-1 {
  0% { transform: translate(0, 0); }
  100% { transform: translate(-40px, 30px); }
}
@keyframes orb-float-2 {
  0% { transform: translate(0, 0); }
  100% { transform: translate(50px, -20px); }
}
@keyframes orb-float-3 {
  0% { transform: translate(0, 0); }
  100% { transform: translate(-30px, -40px); }
}

/* --- VIGNETTE --- */
#vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 45%, rgba(0,0,0,0.75) 100%);
}

/* --- PARALLAX STAGE --- */
#stage {
  position: relative;
  z-index: 2;
  will-change: transform;
  transition: transform 0.35s var(--ease-out);
}

/* ================================================================
   NAV
   ================================================================ */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 48px);
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(150, 150, 180, 0.05);
  transition: transform 0.45s var(--ease-out), opacity 0.45s;
}

/* hide-on-scroll class toggled by JS */
#nav.hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.nav-brand {
  font-size: 0.82rem;
  letter-spacing: 0.32em;
  color: var(--white);
  text-transform: uppercase;
  font-weight: normal;
  font-style: italic;
}
.nav-brand:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links a {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--silver);
  transition: color 0.3s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 1px;
  background: var(--accent-solid);
  transition: width 0.3s var(--ease-out);
}
.nav-links a:hover { color: var(--white); }
.nav-links a:hover::after { width: 100%; }
.nav-links a:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
  color: var(--white);
}
.nav-links a:focus-visible::after { width: 100%; }

/* Active nav link indicator */
.nav-links a.active-page {
  color: var(--white);
}
.nav-links a.active-page::after {
  width: 100%;
  background: var(--accent-solid);
}

.nav-shop-btn {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--accent-solid);
  padding: 8px 20px;
  border-radius: 2px;
  transition: background 0.3s, transform 0.2s;
  font-style: normal;
}
.nav-shop-btn:hover {
  background: #b89af8;
  transform: translateY(-1px);
}
.nav-shop-btn:active {
  transform: translateY(0);
  background: #8f6ee0;
}
.nav-shop-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

/* --- Cart button in nav --- */
.nav-cart-btn {
  position: relative;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--silver);
  padding: 8px 16px;
  border: 1px solid rgba(150, 150, 180, 0.12);
  border-radius: 2px;
  transition: border-color 0.3s, color 0.3s, background 0.3s;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.nav-cart-btn:hover {
  border-color: rgba(160, 130, 240, 0.25);
  color: var(--white);
}

/* --- Cart badge --- */
.cart-badge {
  background: var(--accent-solid);
  color: var(--bg);
  font-size: 0.58rem;
  font-style: normal;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  letter-spacing: 0;
  font-family: var(--mono);
  transition: transform 0.3s var(--ease-bounce);
}
.cart-badge.bump {
  transform: scale(1.3);
}
.cart-badge:empty {
  display: none;
}

/* --- HAMBURGER (mobile) --- */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  z-index: 110;
}
.hamburger span {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--pale);
  transition: transform 0.35s var(--ease-out), opacity 0.2s;
  transform-origin: center;
}
.hamburger.active span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.active span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }
.hamburger:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
}

/* --- MOBILE NAV DRAWER --- */
.mobile-nav {
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  z-index: 99;
  background: rgba(3, 3, 12, 0.97);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  padding: 8px clamp(16px, 4vw, 48px) 24px;
  display: flex;
  flex-direction: column;
  transform: translateY(-110%);
  opacity: 0;
  transition: transform 0.45s var(--ease-out), opacity 0.35s;
  pointer-events: none;
  border-bottom: 1px solid rgba(150, 150, 180, 0.06);
}
.mobile-nav.open {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}
.mobile-nav-link {
  display: block;
  padding: 16px 0;
  font-size: 1rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--silver);
  border-bottom: 1px solid rgba(150, 150, 180, 0.05);
  transition: color 0.2s, padding-left 0.3s var(--ease-out);
  text-align: left;
}
.mobile-nav-link:last-child { border-bottom: none; }
.mobile-nav-link:hover,
.mobile-nav-link:active {
  color: var(--white);
  padding-left: 6px;
}
.mobile-nav-link:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
  color: var(--white);
  padding-left: 6px;
}
.shop-mobile-trigger { color: var(--accent-solid); }

/* ================================================================
   HERO
   ================================================================ */
#hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: var(--nav-h) 24px 60px;
  position: relative;
}
.hero-content {
  animation: hero-fade-in 1.8s var(--ease-out) both;
}
@keyframes hero-fade-in {
  0% { opacity: 0; transform: translateY(28px); }
  100% { opacity: 1; transform: translateY(0); }
}
.hero-title {
  font-size: clamp(3.2rem, 13vw, 9rem);
  font-weight: normal;
  line-height: 0.88;
  letter-spacing: 0.08em;
  color: var(--white);
  margin-bottom: 24px;
  font-style: italic;
}
.hero-t-line {
  display: block;
  opacity: 0;
  animation: line-reveal 1s var(--ease-out) both;
}
.hero-t-line:nth-child(1) { animation-delay: 0.3s; }
.hero-t-line:nth-child(2) { animation-delay: 0.5s; }
@keyframes line-reveal {
  0% { opacity: 0; transform: translateY(20px); letter-spacing: 0.3em; }
  100% { opacity: 1; transform: translateY(0); letter-spacing: 0.08em; }
}
.hero-sub {
  font-size: clamp(0.82rem, 2vw, 1rem);
  color: var(--silver);
  letter-spacing: 0.22em;
  text-transform: lowercase;
  font-style: italic;
  margin-bottom: 44px;
  opacity: 0;
  animation: hero-fade-in 1.2s var(--ease-out) 0.8s both;
}
.hero-cta {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--pale);
  padding: 14px 38px;
  border: 1px solid rgba(150, 150, 180, 0.18);
  border-radius: 2px;
  transition: border-color 0.3s, color 0.3s, background 0.3s, transform 0.2s;
  opacity: 0;
  animation: hero-fade-in 1s var(--ease-out) 1.1s both;
}
.hero-cta:hover {
  border-color: var(--accent-solid);
  color: var(--white);
  background: rgba(160, 130, 240, 0.06);
  transform: translateY(-2px);
}
.hero-cta:active {
  transform: translateY(0);
  background: rgba(160, 130, 240, 0.12);
}
.hero-cta:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--white);
}

/* Scroll hint */
.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  animation: hero-fade-in 1s var(--ease-out) 1.8s both;
}
.scroll-line {
  width: 1px; height: 48px;
  background: linear-gradient(to bottom, var(--silver), transparent);
  animation: scroll-pulse 2s ease-in-out infinite;
}
@keyframes scroll-pulse {
  0%, 100% { opacity: 0.3; transform: scaleY(1); }
  50% { opacity: 0.65; transform: scaleY(1.2); }
}

/* ================================================================
   GALLERY SECTION
   ================================================================ */
#gallery {
  padding: 100px 0 120px;
  min-height: 100vh;
}
.section-header {
  text-align: center;
  margin-bottom: 52px;
  padding: 0 24px;
}
.section-header h2 {
  font-size: clamp(1.3rem, 4vw, 2rem);
  font-weight: normal;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-style: italic;
  color: var(--white);
  margin-bottom: 10px;
}
.section-sub {
  font-size: 0.76rem;
  color: var(--silver);
  letter-spacing: 0.12em;
}

/* Horizontal scroll carousel */
.gallery-track-wrapper {
  position: relative;
  overflow: hidden;
}
/* Edge fade masks */
.gallery-track-wrapper::before,
.gallery-track-wrapper::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 80px;
  z-index: 2;
  pointer-events: none;
}
.gallery-track-wrapper::before {
  left: 0;
  background: linear-gradient(to right, var(--bg), transparent);
}
.gallery-track-wrapper::after {
  right: 0;
  background: linear-gradient(to left, var(--bg), transparent);
}

.gallery-track {
  display: flex;
  gap: 24px;
  padding: 24px clamp(40px, 8vw, 100px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
}
.gallery-track:active { cursor: grabbing; }
.gallery-track::-webkit-scrollbar { display: none; }

/* Gallery card */
.gallery-card {
  flex: 0 0 auto;
  width: clamp(240px, 36vw, 360px);
  scroll-snap-align: center;
  perspective: 900px;
}
.gallery-card-inner {
  position: relative;
  aspect-ratio: 3 / 4;
  background: linear-gradient(145deg, rgba(12, 12, 26, 0.92), rgba(6, 6, 16, 0.96));
  border: 1px solid rgba(150, 150, 180, 0.07);
  border-radius: 3px;
  overflow: hidden;
  transition: transform 0.5s var(--ease-out),
              box-shadow 0.5s var(--ease-out),
              border-color 0.4s;
  will-change: transform;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  transform-style: preserve-3d;
}
/* JS sets inline transform for tilt. CSS handles hover border/shadow. */
.gallery-card-inner:hover {
  border-color: rgba(160, 130, 240, 0.14);
  box-shadow:
    0 24px 64px rgba(60, 30, 120, 0.12),
    0 0 0 1px rgba(160, 130, 240, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

/* Soft inner glow on hover */
.gallery-card-inner::before {
  content: '';
  position: absolute;
  inset: 15%;
  background: radial-gradient(circle, rgba(120, 90, 200, 0.07) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
}
.gallery-card-inner:hover::before { opacity: 1; }

.gallery-card img {
  max-width: 88%;
  max-height: 88%;
  object-fit: contain;
  transition: transform 0.5s var(--ease-out), filter 0.4s;
  filter: drop-shadow(0 4px 24px rgba(0, 0, 0, 0.6));
  pointer-events: none;
}
.gallery-card-inner:hover img {
  transform: scale(1.04);
  filter: drop-shadow(0 8px 32px rgba(100, 60, 200, 0.25));
}

.gallery-card-placeholder {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(80, 50, 140, 0.08) 0%, transparent 70%);
}

/* Card label */
.gallery-card-label {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 20px 18px 16px;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.4) 60%, transparent 100%);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.4s, transform 0.4s var(--ease-out);
  pointer-events: none;
}
.gallery-card-inner:hover .gallery-card-label {
  opacity: 1;
  transform: translateY(0);
}
.gallery-card-label h3 {
  font-size: 0.82rem;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.12em;
  color: var(--white);
}
.gallery-card-label p {
  font-size: 0.7rem;
  color: var(--silver);
  margin-top: 3px;
  letter-spacing: 0.06em;
}

/* Gallery nav arrows */
.gallery-nav {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 36px;
}
.gallery-arrow {
  width: 44px; height: 44px;
  border: 1px solid rgba(150, 150, 180, 0.12);
  border-radius: 50%;
  font-size: 1.3rem;
  color: var(--silver);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s, color 0.3s, background 0.3s, transform 0.2s;
}
.gallery-arrow:hover {
  border-color: var(--accent-solid);
  color: var(--white);
  background: rgba(160, 130, 240, 0.07);
  transform: scale(1.08);
}
.gallery-arrow:active {
  transform: scale(0.96);
  background: rgba(160, 130, 240, 0.14);
}
.gallery-arrow:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--white);
}

/* ================================================================
   ABOUT
   ================================================================ */
#about {
  padding: 100px clamp(24px, 7vw, 100px) 120px;
  max-width: 740px;
  margin: 0 auto;
}
#about h2 {
  font-size: clamp(1.3rem, 4vw, 2rem);
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 36px;
  text-align: center;
}
.about-body p {
  font-size: clamp(0.9rem, 2vw, 1.05rem);
  line-height: 1.85;
  color: var(--silver);
  margin-bottom: 22px;
}

/* ================================================================
   CONTACT
   ================================================================ */
#contact {
  padding: 80px clamp(24px, 6vw, 80px) 110px;
  text-align: center;
}
.contact-inner {
  max-width: 480px;
  margin: 0 auto;
}
#contact h2 {
  font-size: clamp(1.3rem, 4vw, 2rem);
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 44px;
}
.contact-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 52px;
}
.contact-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 15px 28px;
  border: 1px solid rgba(150, 150, 180, 0.09);
  border-radius: 2px;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  color: var(--silver);
  transition: border-color 0.3s, color 0.3s, background 0.3s, transform 0.2s;
}
.contact-link:hover {
  border-color: rgba(160, 130, 240, 0.2);
  color: var(--white);
  background: rgba(160, 130, 240, 0.04);
  transform: translateY(-1px);
}
.contact-link:active {
  transform: translateY(0);
  background: rgba(160, 130, 240, 0.08);
}
.contact-link:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--white);
}
.contact-icon {
  color: var(--accent-solid);
  font-size: 0.68rem;
}
.contact-footer {
  font-size: 0.68rem;
  color: rgba(150, 150, 180, 0.55);
  letter-spacing: 0.22em;
}

/* ================================================================
   SHOP PANEL — slides in from right
   ================================================================ */
.shop-panel {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: var(--shop-w);
  max-width: 100vw;
  z-index: 200;
  background: rgba(4, 4, 12, 0.98);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border-left: 1px solid rgba(150, 150, 180, 0.06);
  transform: translateX(100%);
  transition: transform 0.5s var(--ease-out);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
}
.shop-panel.open {
  transform: translateX(0);
}

/* Shared backdrop for shop & cart */
.shop-backdrop {
  position: fixed;
  inset: 0;
  z-index: 190;
  background: rgba(0, 0, 0, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s;
}
.shop-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  border-bottom: 1px solid rgba(150, 150, 180, 0.06);
  flex-shrink: 0;
}
.shop-header h2 {
  font-size: 0.82rem;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--white);
}
.shop-close {
  font-size: 1rem;
  color: var(--silver);
  transition: color 0.2s, transform 0.2s;
  padding: 8px;
  line-height: 1;
}
.shop-close:hover {
  color: var(--white);
  transform: rotate(90deg);
}
.shop-close:active { transform: rotate(90deg) scale(0.9); }
.shop-close:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
  color: var(--white);
}

/* Category nav */
.shop-categories {
  flex: 1;
  padding: 8px 0;
}
.shop-cat {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 28px;
  border-bottom: 1px solid rgba(150, 150, 180, 0.04);
  transition: background 0.3s;
}
.shop-cat:hover {
  background: rgba(160, 130, 240, 0.04);
}
.shop-cat-icon {
  color: var(--accent-dim);
  font-size: 0.75rem;
  transition: color 0.3s;
  flex-shrink: 0;
}
.shop-cat:hover .shop-cat-icon { color: var(--accent-solid); }
.shop-cat-label {
  flex: 1;
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  color: var(--silver);
  transition: color 0.3s;
}
.shop-cat:hover .shop-cat-label { color: var(--white); }
.shop-cat-arrow {
  font-size: 0.8rem;
  color: rgba(150, 150, 180, 0.18);
  transition: color 0.3s, transform 0.35s var(--ease-out);
}
.shop-cat:hover .shop-cat-arrow {
  color: var(--accent-solid);
  transform: translateX(5px);
}

.shop-footer {
  padding: 22px 28px;
  border-top: 1px solid rgba(150, 150, 180, 0.05);
  flex-shrink: 0;
}
.shop-footer p {
  font-size: 0.68rem;
  color: rgba(150, 150, 180, 0.22);
  letter-spacing: 0.12em;
}

/* ================================================================
   CART DRAWER — slides in over shop panel (right side, z:210)
   ================================================================ */
.cart-drawer {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: var(--shop-w);
  max-width: 100vw;
  z-index: 210;
  background: rgba(4, 4, 13, 0.99);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border-left: 1px solid rgba(150, 150, 180, 0.06);
  transform: translateX(100%);
  transition: transform 0.5s var(--ease-out);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.cart-drawer.open {
  transform: translateX(0);
}
.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px;
  border-bottom: 1px solid rgba(150, 150, 180, 0.06);
  flex-shrink: 0;
}
.cart-header h2 {
  font-size: 0.82rem;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--white);
}
.cart-close {
  font-size: 1rem;
  color: var(--silver);
  padding: 8px;
  line-height: 1;
  transition: color 0.2s, transform 0.2s;
}
.cart-close:hover {
  color: var(--white);
  transform: rotate(90deg);
}
.cart-close:active { transform: rotate(90deg) scale(0.9); }
.cart-close:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
  color: var(--white);
}

/* Cart body / item list */
.cart-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 0;
  scrollbar-width: none;
}
.cart-body::-webkit-scrollbar { display: none; }

.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 12px;
  padding: 40px 28px;
  color: rgba(150, 150, 180, 0.3);
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-align: center;
}

.cart-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 14px;
  align-items: start;
  padding: 16px 28px;
  border-bottom: 1px solid rgba(150, 150, 180, 0.04);
  transition: background 0.3s;
}
.cart-item:hover { background: rgba(160, 130, 240, 0.02); }

.cart-item-thumb {
  width: 64px; height: 80px;
  background: rgba(12, 12, 24, 0.8);
  border: 1px solid rgba(150, 150, 180, 0.07);
  border-radius: 2px;
  object-fit: cover;
  overflow: hidden;
  flex-shrink: 0;
}
.cart-item-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 2px;
}
.cart-item-name {
  font-size: 0.82rem;
  font-style: italic;
  color: var(--pale);
  letter-spacing: 0.06em;
}
.cart-item-variant {
  font-size: 0.68rem;
  color: var(--silver);
  letter-spacing: 0.08em;
}
.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}
.cart-item-qty button {
  width: 22px; height: 22px;
  border: 1px solid rgba(150, 150, 180, 0.12);
  border-radius: 50%;
  font-size: 0.9rem;
  color: var(--silver);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, color 0.2s;
  line-height: 1;
}
.cart-item-qty button:hover {
  border-color: var(--accent-solid);
  color: var(--white);
}
.cart-item-qty span {
  font-size: 0.78rem;
  color: var(--pale);
  min-width: 16px;
  text-align: center;
}

.cart-item-price {
  font-size: 0.82rem;
  color: var(--pale);
  letter-spacing: 0.06em;
  padding-top: 2px;
  white-space: nowrap;
}
.cart-item-remove {
  display: block;
  font-size: 0.65rem;
  color: rgba(150, 150, 180, 0.3);
  letter-spacing: 0.08em;
  margin-top: 8px;
  transition: color 0.2s;
}
.cart-item-remove:hover { color: rgba(220, 120, 120, 0.7); }

/* Cart footer */
.cart-footer {
  padding: 20px 28px;
  border-top: 1px solid rgba(150, 150, 180, 0.06);
  flex-shrink: 0;
}
.cart-subtotal {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 16px;
}
.cart-subtotal-label {
  font-size: 0.72rem;
  color: var(--silver);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.cart-subtotal-amount {
  font-size: 1rem;
  color: var(--white);
  font-style: italic;
  letter-spacing: 0.06em;
}
.cart-checkout-btn {
  display: block;
  width: 100%;
  padding: 15px 24px;
  background: var(--accent-solid);
  color: var(--bg);
  font-size: 0.75rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  text-align: center;
  border-radius: 2px;
  transition: background 0.3s, transform 0.2s;
  font-family: var(--font);
}
.cart-checkout-btn:hover {
  background: #b89af8;
  transform: translateY(-1px);
}
.cart-checkout-btn:active {
  transform: translateY(0);
  background: #8f6ee0;
}
.cart-checkout-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  background: #b89af8;
}

/* ================================================================
   PRODUCT CARD GRID (inside shop panel sub-views)
   ================================================================ */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: rgba(150, 150, 180, 0.05);
  padding: 0;
}

/* Single-col on narrow panels / mobile */
@media (max-width: 400px) {
  .product-grid {
    grid-template-columns: 1fr;
  }
}

.product-card {
  background: rgba(5, 5, 14, 0.96);
  padding: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: background 0.3s;
}
.product-card:hover { background: rgba(10, 10, 22, 0.98); }

.product-card-thumb {
  aspect-ratio: 1;
  background: linear-gradient(145deg, rgba(12, 12, 26, 0.9), rgba(6, 6, 16, 0.95));
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-card-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-out), filter 0.4s;
}
.product-card:hover .product-card-thumb img {
  transform: scale(1.06);
  filter: brightness(1.05);
}

/* "Sold out" ribbon */
.product-card[data-sold]::after {
  content: 'Sold out';
  position: absolute;
  top: 12px; left: -22px;
  background: rgba(0, 0, 0, 0.75);
  color: var(--silver);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 4px 28px;
  transform: rotate(-45deg);
}

.product-card-body {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.product-card-name {
  font-size: 0.78rem;
  font-style: italic;
  color: var(--pale);
  letter-spacing: 0.06em;
  line-height: 1.35;
}
.product-card-variant {
  font-size: 0.66rem;
  color: var(--silver);
  letter-spacing: 0.08em;
}
.product-card-price {
  font-size: 0.82rem;
  color: var(--white);
  letter-spacing: 0.06em;
  margin-top: auto;
  padding-top: 8px;
}
.product-card-add {
  width: 100%;
  margin-top: 10px;
  padding: 9px 12px;
  border: 1px solid rgba(160, 130, 240, 0.2);
  border-radius: 1px;
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-solid);
  transition: background 0.3s, border-color 0.3s, color 0.3s;
  text-align: center;
}
.product-card-add:hover {
  background: var(--accent-solid);
  color: var(--bg);
  border-color: var(--accent-solid);
}

/* ================================================================
   LIGHTBOX OVERLAY
   ================================================================ */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.94);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s;
}
.lightbox.active {
  opacity: 1;
  pointer-events: auto;
}
.lightbox-close {
  position: absolute;
  top: 18px; right: 22px;
  font-size: 1.1rem;
  color: var(--silver);
  z-index: 10;
  padding: 12px;
  transition: color 0.2s, transform 0.2s;
  line-height: 1;
}
.lightbox-close:hover {
  color: var(--white);
  transform: rotate(90deg);
}
.lightbox-close:active { transform: rotate(90deg) scale(0.9); }
.lightbox-close:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
  color: var(--white);
}
.lightbox-content {
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  transform: scale(0.94) translateY(12px);
  transition: transform 0.5s var(--ease-out);
}
.lightbox.active .lightbox-content {
  transform: scale(1) translateY(0);
}
#lightbox-img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  filter: drop-shadow(0 10px 50px rgba(0, 0, 0, 0.7));
  border-radius: 2px;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border: 1px solid rgba(160, 130, 240, 0.2);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  color: var(--white);
  font-size: 2rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s;
}
.lightbox-nav:hover,
.lightbox-nav:focus-visible {
  background: rgba(160, 130, 240, 0.18);
  border-color: var(--accent-solid);
  outline: none;
}
.lightbox-prev { left: max(18px, 4vw); }
.lightbox-next { right: max(18px, 4vw); }
.lightbox-counter {
  display: block;
  margin-bottom: 6px;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.16em;
  color: var(--silver);
}

.lightbox-info {
  text-align: center;
}
.lightbox-info h3 {
  font-size: 0.95rem;
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.16em;
  color: var(--white);
  margin-bottom: 5px;
}
.lightbox-info p {
  font-size: 0.76rem;
  color: var(--silver);
  letter-spacing: 0.08em;
}

/* ================================================================
   SCROLL REVEAL
   ================================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.85s var(--ease-out), transform 0.85s var(--ease-out);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ================================================================
   SECTION DIVIDERS
   ================================================================ */
#gallery, #about, #contact {
  position: relative;
}
#gallery::before, #about::before, #contact::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--accent-dim), transparent);
}

/* ================================================================
   SHOP PAGE STYLES (dedicated shop page, extends above)
   ================================================================ */

/* --- Shop page layout --- */
.shop-page {
  padding: calc(var(--nav-h) + 40px) clamp(16px, 4vw, 48px) 100px;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.shop-page-header {
  text-align: center;
  margin-bottom: 20px;
}
.shop-page-header h1 {
  font-size: clamp(1.6rem, 5vw, 2.6rem);
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 10px;
}
.shop-page-header p {
  font-size: 0.78rem;
  color: var(--silver);
  letter-spacing: 0.14em;
}

/* --- Filter bar --- */
.shop-filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 52px;
  padding: 0 8px;
}
.filter-btn {
  font-family: var(--font);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--silver);
  padding: 10px 22px;
  border: 1px solid rgba(150, 150, 180, 0.1);
  border-radius: 2px;
  transition: border-color 0.3s, color 0.3s, background 0.3s, transform 0.2s;
  white-space: nowrap;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
.filter-btn:hover {
  border-color: rgba(160, 130, 240, 0.25);
  color: var(--white);
  background: rgba(160, 130, 240, 0.04);
}
.filter-btn.active {
  border-color: var(--accent-solid);
  color: var(--white);
  background: rgba(160, 130, 240, 0.1);
}
.filter-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--white);
}

/* --- Tag filters --- */
.shop-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-bottom: 48px;
  padding: 0 8px;
}
.tag-btn {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  color: var(--silver);
  padding: 6px 14px;
  border: 1px solid rgba(150, 150, 180, 0.07);
  border-radius: 12px;
  transition: border-color 0.3s, color 0.3s, background 0.3s;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}
.tag-btn:hover {
  border-color: rgba(160, 130, 240, 0.2);
  color: var(--pale);
}
.tag-btn.active {
  border-color: var(--accent-dim);
  color: var(--white);
  background: rgba(160, 130, 240, 0.08);
}
.tag-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--pale);
}

/* --- Category section --- */
.shop-category {
  margin-bottom: 72px;
}
.shop-category.hidden {
  display: none;
}
.shop-category-header {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 28px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(150, 150, 180, 0.06);
}
.shop-category-header h2 {
  font-size: clamp(1rem, 3vw, 1.4rem);
  font-weight: normal;
  font-style: italic;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--white);
}
.shop-category-count {
  font-size: 0.66rem;
  color: var(--silver);
  letter-spacing: 0.1em;
}

/* --- Product grid (shop page version) --- */
.shop-product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1px;
  background: rgba(150, 150, 180, 0.04);
  border: 1px solid rgba(150, 150, 180, 0.04);
  border-radius: 3px;
  overflow: hidden;
}

.shop-product-card {
  background: rgba(5, 5, 14, 0.96);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition: background 0.3s;
}
.shop-product-card:hover {
  background: rgba(10, 10, 22, 0.98);
}
.shop-product-card.hidden-by-tag {
  display: none;
}

.shop-product-thumb {
  aspect-ratio: 1;
  background: linear-gradient(145deg, rgba(12, 12, 26, 0.9), rgba(6, 6, 16, 0.95));
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.shop-product-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-out), filter 0.4s;
}
.shop-product-card:hover .shop-product-thumb img {
  transform: scale(1.06);
  filter: brightness(1.05);
}

/* Placeholder label for products without images */
.shop-product-thumb-placeholder {
  aspect-ratio: 1;
  background: linear-gradient(145deg, rgba(12, 12, 26, 0.9), rgba(6, 6, 16, 0.95));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.shop-product-thumb-placeholder::after {
  content: attr(data-label);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(150, 150, 180, 0.15);
  text-align: center;
  padding: 20px;
}

/* Stock badge */
.stock-badge {
  position: absolute;
  top: 10px; right: 10px;
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 1px;
  z-index: 1;
}
.stock-badge.low {
  background: rgba(200, 120, 50, 0.2);
  color: rgba(220, 160, 80, 0.9);
  border: 1px solid rgba(200, 120, 50, 0.15);
}
.stock-badge.out {
  background: rgba(180, 60, 60, 0.15);
  color: rgba(200, 100, 100, 0.8);
  border: 1px solid rgba(180, 60, 60, 0.12);
}
.stock-badge.one-of-one {
  background: rgba(120, 90, 200, 0.12);
  color: var(--accent-solid);
  border: 1px solid rgba(120, 90, 200, 0.15);
}

/* Product tags on cards */
.shop-product-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 0 14px;
  margin-top: -2px;
}
.shop-product-tag {
  font-family: var(--mono);
  font-size: 0.56rem;
  letter-spacing: 0.06em;
  color: rgba(150, 150, 180, 0.35);
  background: rgba(150, 150, 180, 0.04);
  padding: 2px 8px;
  border-radius: 8px;
}

.shop-product-body {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.shop-product-name {
  font-size: 0.82rem;
  font-style: italic;
  color: var(--pale);
  letter-spacing: 0.06em;
  line-height: 1.35;
}
.shop-product-desc {
  font-size: 0.68rem;
  color: var(--silver);
  letter-spacing: 0.04em;
  line-height: 1.5;
  opacity: 0.7;
}
.shop-product-price {
  font-size: 0.88rem;
  color: var(--white);
  letter-spacing: 0.06em;
  margin-top: auto;
  padding-top: 10px;
}
.shop-product-price .original-price {
  text-decoration: line-through;
  color: var(--silver);
  font-size: 0.74rem;
  margin-left: 8px;
}

.shop-variant-picker {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-top: 10px;
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--silver);
}
.shop-variant-select {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid rgba(160, 130, 240, 0.18);
  border-radius: 1px;
  background: rgba(0, 0, 0, 0.28);
  color: var(--pale);
  font-family: var(--font);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}
.shop-variant-select:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
}

.shop-add-btn {
  width: 100%;
  margin-top: 10px;
  padding: 12px 12px;
  border: 1px solid rgba(160, 130, 240, 0.2);
  border-radius: 1px;
  font-size: 0.68rem;
  font-family: var(--font);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-solid);
  transition: background 0.3s, border-color 0.3s, color 0.3s;
  text-align: center;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.shop-add-btn:hover {
  background: var(--accent-solid);
  color: var(--bg);
  border-color: var(--accent-solid);
}
.shop-add-btn:active {
  background: #8f6ee0;
  border-color: #8f6ee0;
  color: var(--bg);
}
.shop-add-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  background: var(--accent-solid);
  color: var(--bg);
  border-color: var(--accent-solid);
}
.shop-add-btn:disabled {
  opacity: 0.3;
  pointer-events: none;
}
.shop-add-btn.added {
  background: rgba(80, 180, 100, 0.12);
  border-color: rgba(80, 180, 100, 0.25);
  color: rgba(120, 210, 140, 0.9);
}

/* --- No results message --- */
.shop-no-results {
  text-align: center;
  padding: 80px 24px;
  color: var(--silver);
  font-size: 0.88rem;
  letter-spacing: 0.1em;
  font-style: italic;
  display: none;
}
.shop-no-results.visible {
  display: block;
}

/* --- "Back to top" --- */
.shop-back-top {
  display: flex;
  justify-content: center;
  padding: 40px 0 0;
}
.shop-back-top a {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--silver);
  padding: 12px 24px;
  border: 1px solid rgba(150, 150, 180, 0.08);
  border-radius: 2px;
  transition: border-color 0.3s, color 0.3s;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
.shop-back-top a:hover {
  border-color: rgba(160, 130, 240, 0.2);
  color: var(--white);
}
.shop-back-top a:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-color: var(--accent-solid);
  color: var(--white);
}

/* ================================================================
   MOBILE ADJUSTMENTS (375px baseline)
   ================================================================ */
@media (max-width: 768px) {
  .gallery-card {
    width: clamp(220px, 74vw, 310px);
  }
  .gallery-track {
    gap: 14px;
    padding: 16px 24px;
  }
  .gallery-track-wrapper::before,
  .gallery-track-wrapper::after {
    width: 30px;
  }
  #hero {
    padding-bottom: 40px;
  }
  .hero-title {
    letter-spacing: 0.04em;
  }
  .shop-panel,
  .cart-drawer {
    width: 100vw;
    max-width: 100vw;
  }
  .nebula { filter: blur(80px); }
  .orb { filter: blur(50px); }
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  /* Shop page responsive */
  .shop-product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .shop-filters {
    gap: 6px;
  }
  .filter-btn {
    padding: 8px 16px;
    font-size: 0.66rem;
  }

  /* Tag filters — collapsed accordion on mobile */
  .shop-tags-wrapper {
    margin-bottom: 32px;
    padding: 0 8px;
  }
  .shop-tags-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(5, 5, 14, 0.96);
    border: 1px solid rgba(150, 150, 180, 0.1);
    border-radius: 2px;
    font-family: var(--font);
    font-size: 0.7rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--silver);
    transition: border-color 0.3s, color 0.3s;
    min-height: 44px;
  }
  .shop-tags-toggle:hover {
    border-color: rgba(160, 130, 240, 0.25);
    color: var(--white);
  }
  .shop-tags-toggle:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
    border-color: var(--accent-solid);
    color: var(--white);
  }
  .shop-tags-toggle-icon {
    font-size: 0.7rem;
    transition: transform 0.3s var(--ease-out);
    flex-shrink: 0;
  }
  .shop-tags-toggle[aria-expanded="true"] .shop-tags-toggle-icon {
    transform: rotate(180deg);
  }
  .shop-tags {
    margin-top: 10px;
    margin-bottom: 0;
  }
}

/* Desktop: always show tags, no toggle needed */
@media (pointer: fine) {
  .shop-tags-wrapper {
    display: contents;
  }
  .shop-tags-toggle {
    display: none;
  }
}

/* Mobile: tags start hidden, expand on toggle */
@media (max-width: 768px) {
  .shop-tags {
    display: none;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    padding: 0 8px;
  }
  .shop-tags.expanded {
    display: flex;
  }
  /* Re-add shop-tags reveal styles in mobile context */
  .shop-tags.reveal {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 480px) {
  .gallery-card {
    width: 82vw;
  }
  .cart-item {
    grid-template-columns: 56px 1fr auto;
    gap: 10px;
    padding: 14px 20px;
  }
  .cart-item-thumb {
    width: 56px; height: 68px;
  }
  .shop-header,
  .cart-header,
  .shop-footer,
  .cart-footer {
    padding-left: 20px;
    padding-right: 20px;
  }
  .shop-cat { padding-left: 20px; padding-right: 20px; }
  /* Shop page responsive */
  .shop-product-grid {
    grid-template-columns: 1fr;
  }
  .shop-product-body {
    padding: 12px 12px 14px;
  }
}

@media (max-width: 375px) {
  .gallery-card { width: 88vw; }
  .product-grid { grid-template-columns: 1fr; }
  /* Shop page responsive */
  .shop-product-grid {
    grid-template-columns: 1fr;
  }
}

/* ================================================================
   FLOATING CART BUTTON (mobile)
   ================================================================ */
.floating-cart-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--accent-solid);
  color: var(--bg);
  padding: 14px 20px;
  border-radius: 2px;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  z-index: 150;
  display: none;
  align-items: center;
  gap: 8px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  border: none;
  font-family: var(--font);
  transition: transform 0.2s, background 0.3s;
}
.floating-cart-btn.visible {
  display: flex;
}
.floating-cart-btn:hover {
  background: #b89af8;
  transform: translateY(-2px);
}
.floating-cart-btn:active {
  transform: translateY(0);
  background: #8f6ee0;
}
.floating-cart-btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}
.floating-cart-count {
  background: var(--bg);
  color: var(--accent-solid);
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.68rem;
  font-family: var(--mono);
}

/* Desktop: hide floating button (use nav cart button instead) */
@media (pointer: fine) {
  .floating-cart-btn { display: none !important; }
}

/* ================================================================
   REDUCED MOTION
   ================================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ============================================================
/* Screen reader only text */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
