/* ===================================================================
   THE HISTORY OF JULIUS — Design System
   Immersive 3D Photo Gallery
   =================================================================== */

/* ─── Google Fonts ──────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Outfit:wght@200;300;400;500;600;700&family=JetBrains+Mono:wght@300;400;500&display=swap');

/* ─── Design Tokens ─────────────────────────────────────────────── */
:root {
  /* Colors */
  --color-bg:             #0a0a0a;
  --color-bg-elevated:    #111111;
  --color-surface:        #141414;
  --color-surface-hover:  #1a1a1a;
  --color-border:         rgba(255, 255, 255, 0.06);
  --color-border-hover:   rgba(255, 255, 255, 0.12);
  --color-text-primary:   #f0ece4;
  --color-text-secondary: #6b6560;
  --color-text-muted:     #3d3a37;
  --color-accent:         #c8b8a4;
  --color-accent-glow:    rgba(200, 184, 164, 0.15);
  --color-overlay:        rgba(0, 0, 0, 0.85);
  --color-glass:          rgba(20, 20, 20, 0.7);

  /* Typography */
  --font-heading:   'Outfit', sans-serif;
  --font-body:      'Inter', sans-serif;
  --font-mono:      'JetBrains Mono', monospace;

  /* Spacing Scale */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Radii */
  --radius-sm:  4px;
  --radius-md:  8px;
  --radius-lg:  12px;
  --radius-xl:  16px;
  --radius-2xl: 24px;
  --radius-full: 9999px;

  /* Transitions */
  --ease-out-expo:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-spring:    cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast:  150ms;
  --duration-med:   300ms;
  --duration-slow:  600ms;
  --duration-xslow: 1000ms;
  --duration-enter: 1200ms;

  /* Depth / 3D */
  --perspective:    1200px;
  --depth-1:        10px;
  --depth-2:        30px;
  --depth-3:        60px;
  --depth-4:        100px;
  --shadow-depth:   0 4px 30px rgba(0,0,0,0.4), 0 1px 3px rgba(0,0,0,0.3);
  --shadow-float:   0 20px 60px rgba(0,0,0,0.5), 0 4px 15px rgba(0,0,0,0.3);
  --shadow-glow:    0 0 40px rgba(200, 184, 164, 0.08);

  /* Z-index layers */
  --z-canvas:   0;
  --z-base:     1;
  --z-cards:    10;
  --z-nav:      100;
  --z-overlay:  500;
  --z-lightbox: 900;
  --z-gate:     1000;
  --z-cursor:   9999;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--color-text-primary);
  background-color: var(--color-bg);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100dvh;
}

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: var(--z-canvas);
  pointer-events: none;
  opacity: 0.25;
}

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

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

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
}

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

/* ─── Utility Classes ───────────────────────────────────────────── */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
}

/* ===================================================================
   PASSWORD GATE
   =================================================================== */
.gate {
  position: fixed;
  inset: 0;
  z-index: var(--z-gate);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg);
  transition: opacity var(--duration-enter) var(--ease-out-expo),
              transform var(--duration-enter) var(--ease-out-expo);
}

.gate.gate--unlocking {
  opacity: 0;
  transform: scale(1.1);
  pointer-events: none;
}

.gate.gate--hidden {
  display: none;
}

.gate__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xl);
  transform: translateY(-5vh);
}

.gate__title {
  font-family: var(--font-heading);
  font-weight: 200;
  font-size: clamp(1.8rem, 5vw, 3.5rem);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-text-primary);
  opacity: 0;
  animation: fadeSlideUp 1s var(--ease-out-expo) 0.2s forwards;
}

.gate__subtitle {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  opacity: 0;
  animation: fadeSlideUp 1s var(--ease-out-expo) 0.5s forwards;
}

.gate__form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-lg);
  opacity: 0;
  animation: fadeSlideUp 1s var(--ease-out-expo) 0.8s forwards;
}

.gate__input-wrap {
  position: relative;
  width: 280px;
}

.gate__input {
  width: 100%;
  padding: var(--space-md) var(--space-lg);
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  color: var(--color-text-primary);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 300;
  letter-spacing: 0.15em;
  text-align: center;
  outline: none;
  transition: border-color var(--duration-med) var(--ease-out-quart),
              box-shadow var(--duration-med) var(--ease-out-quart);
}

.gate__input::placeholder {
  color: var(--color-text-muted);
  letter-spacing: 0.2em;
  font-size: 0.75rem;
}

.gate__input:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 30px var(--color-accent-glow);
}

.gate__input--error {
  border-color: #8b4545;
  animation: shake 0.5s var(--ease-out-quart);
}

.gate__enter-hint {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  transition: color var(--duration-fast);
}

.gate__credit {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin-top: var(--space-2xl);
  opacity: 0;
  animation: fadeSlideUp 1s var(--ease-out-expo) 1.4s forwards;
}

.gate__credit a {
  color: var(--color-text-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--duration-fast);
}

.gate__credit a:hover {
  color: var(--color-accent);
}

.gate__line {
  position: absolute;
  bottom: -40px;
  left: 50%;
  width: 1px;
  height: 0;
  background: var(--color-border);
  opacity: 0;
  animation: lineGrow 1.5s var(--ease-out-expo) 1.2s forwards;
}

/* ===================================================================
   NAVIGATION
   =================================================================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-nav);
  padding: var(--space-lg) var(--space-xl);
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  mix-blend-mode: difference;
}

.nav > * {
  pointer-events: auto;
}

.nav__logo {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-primary);
  cursor: pointer;
  transition: opacity var(--duration-fast);
}

.nav__logo:hover {
  opacity: 0.7;
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.nav__link {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  transition: color var(--duration-fast);
  cursor: pointer;
}

.nav__link:hover,
.nav__link.is-active {
  color: var(--color-text-primary);
}

.nav__tag-toggle,
.nav__icon-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  transition: all var(--duration-fast);
  color: var(--color-text-secondary);
}

.nav__tag-toggle:hover,
.nav__icon-btn:hover {
  border-color: var(--color-accent);
  background: var(--color-accent-glow);
  color: var(--color-text-primary);
}

.nav__tag-toggle svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
}

/* ===================================================================
   HERO SECTION
   =================================================================== */
.hero {
  position: relative;
  width: 100%;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  perspective: var(--perspective);
}

.hero__bg {
  position: absolute;
  inset: -40px;
  z-index: 0;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.35) saturate(0.8);
  transform: scale(1.1);
  transition: transform 0.1s linear;
}

.hero__image-wrap {
  position: relative;
  z-index: var(--z-base);
  width: min(70vw, 700px);
  aspect-ratio: 3/2;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-float);
  transform-style: preserve-3d;
  transition: transform 0.15s linear;
}

.hero__image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    to bottom,
    transparent 40%,
    rgba(10, 10, 10, 0.6) 100%
  );
  pointer-events: none;
}

.hero__info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 3;
  padding: var(--space-2xl) var(--space-xl);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.hero__heading {
  font-family: var(--font-heading);
  font-weight: 200;
  font-size: clamp(2rem, 6vw, 4.5rem);
  letter-spacing: 0.08em;
  line-height: 1.1;
}

.hero__meta {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  text-align: right;
}

.hero__scroll-indicator {
  position: absolute;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  animation: floatBounce 2s ease-in-out infinite;
}

.hero__scroll-indicator span {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--color-text-muted), transparent);
}

/* ===================================================================
   ALBUMS GRID
   =================================================================== */
.albums {
  padding: var(--space-4xl) var(--space-xl) var(--space-5xl);
  perspective: var(--perspective);
}

.albums__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--space-3xl);
  padding: 0 var(--space-sm);
}

.albums__title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  letter-spacing: 0.1em;
}

.albums__count {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  color: var(--color-text-secondary);
  text-transform: uppercase;
}

.albums__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--space-lg);
  max-width: 1400px;
  margin: 0 auto;
}

/* ─── Album Card ─────────────────────────────────────────────────── */
.album-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform var(--duration-med) var(--ease-out-quart),
              box-shadow var(--duration-med) var(--ease-out-quart);
  will-change: transform;
}

.album-card:hover {
  box-shadow: var(--shadow-float);
}

.album-card__image-wrap {
  aspect-ratio: 4/3;
  overflow: hidden;
}

.album-card__image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--duration-slow) var(--ease-out-quart),
              filter var(--duration-med);
}

.album-card:hover .album-card__image-wrap img {
  transform: scale(1.05);
  filter: brightness(0.7);
}

.album-card__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-xl);
  background: linear-gradient(
    to top,
    rgba(10, 10, 10, 0.9) 0%,
    rgba(10, 10, 10, 0.3) 40%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity var(--duration-med) var(--ease-out-quart);
  backdrop-filter: blur(2px);
}

.album-card:hover .album-card__overlay {
  opacity: 1;
}

.album-card__name {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  margin-bottom: var(--space-xs);
  transform: translateY(10px);
  transition: transform var(--duration-med) var(--ease-out-expo);
}

.album-card:hover .album-card__name {
  transform: translateY(0);
}

.album-card__meta {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  transform: translateY(10px);
  opacity: 0;
  transition: all var(--duration-med) var(--ease-out-expo) 80ms;
}

.album-card:hover .album-card__meta {
  transform: translateY(0);
  opacity: 1;
}

/* ===================================================================
   PHOTO STREAM (Album Detail)
   =================================================================== */
.stream {
  padding: var(--space-5xl) var(--space-xl) var(--space-4xl);
  max-width: 1100px;
  margin: 0 auto;
  perspective: var(--perspective);
}

.stream__header {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  padding: var(--space-lg) 0;
  margin-bottom: var(--space-3xl);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(to bottom, var(--color-bg) 70%, transparent);
}

.stream__back {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: color var(--duration-fast);
}

.stream__back:hover {
  color: var(--color-text-primary);
}

.stream__back svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
}

.stream__album-title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: 1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.stream__photos {
  display: flex;
  flex-direction: column;
  gap: var(--space-3xl);
}

/* ─── Photo Item ─────────────────────────────────────────────────── */
.photo-item {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transform-style: preserve-3d;
  opacity: 0;
  transform: translateY(60px) scale(0.97);
  transition: opacity var(--duration-slow) var(--ease-out-expo),
              transform var(--duration-slow) var(--ease-out-expo);
}

.photo-item.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.photo-item__image-wrap {
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.photo-item__image-wrap img {
  width: 100%;
  display: block;
  transition: transform var(--duration-slow) var(--ease-out-quart);
}

.photo-item:hover .photo-item__image-wrap img {
  transform: scale(1.02);
}

.photo-item__info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-xl);
  background: linear-gradient(to top, rgba(10,10,10,0.8), transparent);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  opacity: 0;
  transform: translateY(10px);
  transition: all var(--duration-med) var(--ease-out-quart);
}

.photo-item:hover .photo-item__info {
  opacity: 1;
  transform: translateY(0);
}

.photo-item__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.photo-item__date {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: var(--color-text-secondary);
}

/* ===================================================================
   ALL PHOTOS GRID VIEW
   =================================================================== */
.all-photos {
  padding: var(--space-5xl) var(--space-xl) var(--space-4xl);
  max-width: 1400px;
  margin: 0 auto;
}

.all-photos__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--space-3xl);
}

.all-photos__title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  letter-spacing: 0.1em;
}

.all-photos__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--space-md);
}

.all-photos__grid .photo-item {
  border-radius: var(--radius-md);
}

.all-photos__grid .photo-item__image-wrap {
  aspect-ratio: 1;
  border-radius: var(--radius-md);
}

.all-photos__grid .photo-item__image-wrap img {
  height: 100%;
  object-fit: cover;
}

/* ===================================================================
   FILMSTRIP VIEW (Angela Ricciardi style)
   =================================================================== */
.filmstrip {
  padding: var(--space-5xl) 0 var(--space-4xl);
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.filmstrip__stage {
  position: relative;
  width: 90vw;
  max-width: 1000px;
  height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.filmstrip__main-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-float);
  transition: opacity var(--duration-med) var(--ease-out-quart),
              transform var(--duration-slow) var(--ease-out-expo);
}

.filmstrip__bar {
  position: absolute;
  bottom: var(--space-xl);
  left: var(--space-xl);
  right: var(--space-xl);
  display: flex;
  gap: var(--space-sm);
  overflow-x: auto;
  padding: var(--space-sm) 0;
  scrollbar-width: none;
}

.filmstrip__bar::-webkit-scrollbar {
  display: none;
}

.filmstrip__thumb {
  position: relative;
  width: 100px;
  height: 65px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  opacity: 0.4;
  border: 1px solid transparent;
  transition: all var(--duration-fast);
}

.filmstrip__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.filmstrip__thumb:hover,
.filmstrip__thumb.is-active {
  opacity: 1;
  border-color: var(--color-accent);
}

/* ===================================================================
   TAGS
   =================================================================== */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  font-family: var(--font-mono);
  font-size: 0.55rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out-quart);
  user-select: none;
  white-space: nowrap;
}

.tag:hover {
  color: var(--color-text-primary);
  border-color: var(--color-border-hover);
  background: rgba(255,255,255,0.03);
}

.tag.is-active {
  color: var(--color-bg);
  background: var(--color-accent);
  border-color: var(--color-accent);
  box-shadow: var(--shadow-glow);
}

/* ─── Tag Panel ──────────────────────────────────────────────────── */
.tag-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(400px, 90vw);
  z-index: var(--z-overlay);
  background: var(--color-glass);
  backdrop-filter: blur(30px) saturate(1.5);
  -webkit-backdrop-filter: blur(30px) saturate(1.5);
  border-left: 1px solid var(--color-border);
  padding: var(--space-4xl) var(--space-xl);
  transform: translateX(100%);
  transition: transform var(--duration-slow) var(--ease-out-expo);
  overflow-y: auto;
}

.tag-panel.is-open {
  transform: translateX(0);
}

.tag-panel__backdrop,
.modal__backdrop {
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-overlay) - 1);
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(5px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-med);
}

.tag-panel__backdrop.is-visible,
.modal__backdrop.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.tag-panel__title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: 1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.tag-panel__subtitle {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--color-text-secondary);
  letter-spacing: 0.1em;
  margin-bottom: var(--space-2xl);
}

.tag-panel__cloud {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.tag-panel__clear {
  margin-top: var(--space-xl);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: color var(--duration-fast);
}

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

/* ===================================================================
   MODALS (Shortcuts, etc.)
   =================================================================== */
.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  z-index: var(--z-overlay);
  width: min(450px, 90vw);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-float);
  opacity: 0;
  pointer-events: none;
  transition: all var(--duration-med) var(--ease-out-expo);
}

.modal.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

.modal__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-lg);
}

.modal__header h3 {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: 1rem;
  letter-spacing: 0.1em;
}

.modal__close {
  color: var(--color-text-secondary);
  font-size: 1.1rem;
}

.modal__close:hover {
  color: var(--color-text-primary);
}

.modal__body {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.shortcut-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--color-text-secondary);
  padding: var(--space-xs) 0;
}

kbd {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 2px 6px;
  color: var(--color-text-primary);
  font-family: var(--font-mono);
  font-size: 0.65rem;
}

/* ===================================================================
   LIGHTBOX
   =================================================================== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: var(--z-lightbox);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-med) var(--ease-out-quart);
}

.lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox__image-wrap {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0.9) translateY(20px);
  transition: transform var(--duration-slow) var(--ease-out-expo);
}

.lightbox.is-open .lightbox__image-wrap {
  transform: scale(1) translateY(0);
}

.lightbox__image-wrap img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-float);
}

.lightbox__close {
  position: absolute;
  top: var(--space-xl);
  right: var(--space-xl);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  font-size: 1.2rem;
  transition: all var(--duration-fast);
  z-index: 10;
}

.lightbox__close:hover {
  border-color: var(--color-text-primary);
  color: var(--color-text-primary);
  background: rgba(255,255,255,0.05);
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  transition: all var(--duration-fast);
}

.lightbox__nav:hover {
  border-color: var(--color-text-primary);
  color: var(--color-text-primary);
  background: rgba(255,255,255,0.05);
}

.lightbox__nav--prev {
  left: var(--space-xl);
}

.lightbox__nav--next {
  right: var(--space-xl);
}

.lightbox__nav svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
}

.lightbox__info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-xl) var(--space-2xl);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
  transform: translateY(20px);
  opacity: 0;
  transition: all var(--duration-med) var(--ease-out-expo) 200ms;
}

.lightbox.is-open .lightbox__info {
  transform: translateY(0);
  opacity: 1;
}

.lightbox__info-left {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.lightbox__photo-title {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
}

.lightbox__photo-date {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: var(--color-text-secondary);
}

.lightbox__info-tags {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
  justify-content: flex-end;
}

.lightbox__counter {
  position: absolute;
  top: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--color-text-muted);
}

/* ===================================================================
   CUSTOM CURSOR
   =================================================================== */
.cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  width: 8px;
  height: 8px;
  background: var(--color-accent);
  border-radius: 50%;
  pointer-events: none;
  z-index: var(--z-cursor);
  mix-blend-mode: difference;
  opacity: 0;
  transition: width var(--duration-fast), height var(--duration-fast),
              opacity var(--duration-med);
  transform: translate(-50%, -50%);
}

.cursor-dot.is-visible {
  opacity: 1;
}

.cursor-dot.is-hovering {
  width: 40px;
  height: 40px;
  background: rgba(200, 184, 164, 0.15);
  border: 1px solid var(--color-accent);
}

/* ===================================================================
   ACTIVE TAGS BAR (persistent filter strip)
   =================================================================== */
.active-tags-bar {
  position: fixed;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-nav);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: var(--color-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  opacity: 0;
  pointer-events: none;
  transition: all var(--duration-med) var(--ease-out-expo);
}

.active-tags-bar.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.active-tags-bar__label {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin-right: var(--space-xs);
}

/* ===================================================================
   FOOTER & CREDITS
   =================================================================== */
.footer {
  padding: var(--space-4xl) var(--space-xl) var(--space-xl);
  border-top: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer__left {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  color: var(--color-text-muted);
  text-transform: uppercase;
}

.footer__right {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
}

.footer__credit-link {
  color: var(--color-text-secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--duration-fast);
}

.footer__credit-link:hover {
  color: var(--color-accent);
}

/* ===================================================================
   ANIMATIONS
   =================================================================== */
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(5px); }
}

@keyframes floatBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

@keyframes lineGrow {
  from {
    height: 0;
    opacity: 0;
  }
  to {
    height: 60px;
    opacity: 0.3;
  }
}

/* ─── Stagger children ───────────────────────────────────────────── */
.stagger-in > * {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeSlideUp var(--duration-slow) var(--ease-out-expo) forwards;
}

.stagger-in > *:nth-child(1) { animation-delay: 0ms; }
.stagger-in > *:nth-child(2) { animation-delay: 80ms; }
.stagger-in > *:nth-child(3) { animation-delay: 160ms; }
.stagger-in > *:nth-child(4) { animation-delay: 240ms; }
.stagger-in > *:nth-child(5) { animation-delay: 320ms; }
.stagger-in > *:nth-child(6) { animation-delay: 400ms; }
.stagger-in > *:nth-child(7) { animation-delay: 480ms; }
.stagger-in > *:nth-child(8) { animation-delay: 560ms; }

/* ===================================================================
   RESPONSIVE
   =================================================================== */
@media (max-width: 768px) {
  .nav {
    padding: var(--space-md) var(--space-md);
  }

  .hero__image-wrap {
    width: 90vw;
  }

  .hero__info {
    flex-direction: column;
    gap: var(--space-md);
    padding: var(--space-lg);
  }

  .hero__meta {
    text-align: left;
  }

  .albums {
    padding: var(--space-3xl) var(--space-md) var(--space-4xl);
  }

  .albums__grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }

  .stream {
    padding: var(--space-4xl) var(--space-md);
  }

  .all-photos {
    padding: var(--space-4xl) var(--space-md);
  }

  .all-photos__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm);
  }

  .lightbox__nav {
    display: none;
  }

  .lightbox__close {
    top: var(--space-md);
    right: var(--space-md);
  }

  .cursor-dot {
    display: none;
  }

  .footer {
    flex-direction: column;
    gap: var(--space-md);
    text-align: center;
  }
}

@media (max-width: 480px) {
  .gate__title {
    font-size: 1.4rem;
  }

  .gate__input-wrap {
    width: 240px;
  }

  .all-photos__grid {
    grid-template-columns: 1fr;
  }
}

/* ─── Reduced Motion ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .hero__scroll-indicator {
    animation: none;
  }
}
