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

:root {
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --bg: #0a0a0a;
  --text: #f0ece2;
  --accent: #d4a574;
}

html, body {
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: 'Georgia', serif;
}

/* ── Track ── */
.gallery-track {
  display: flex;
  align-items: center;
  height: 100dvh;
  will-change: transform;
  padding: 0 10vw;
  gap: 0;
}

/* ── Individual slide ── */
.slide {
  flex: 0 0 auto;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 0 3vw;
  transition: opacity 0.4s var(--ease);
}

.slide-inner {
  position: relative;
  max-height: calc(100dvh - 40px);
  transition: transform 0.6s var(--ease), filter 0.6s var(--ease);
}

.slide-inner img {
  display: block;
  max-height: calc(100dvh - 40px);
  max-width: 80vw;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 8px 25px rgba(0,0,0,0.3);
  transition: box-shadow 0.6s var(--ease);
}

/* Active slide emphasis */
.slide.active .slide-inner {
  transform: scale(1.04);
}

.slide.active .slide-inner img {
  box-shadow: 0 30px 90px rgba(0,0,0,0.6), 0 12px 35px rgba(0,0,0,0.4);
}

.slide:not(.active) .slide-inner {
  transform: scale(0.88);
  filter: brightness(0.5) saturate(0.6);
}

/* ── Slide caption ── */
.slide-caption {
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  opacity: 0;
  transition: opacity 0.5s var(--ease) 0.15s, transform 0.5s var(--ease) 0.15s;
  transform: translateX(-50%) translateY(10px);
  white-space: nowrap;
}

.slide.active .slide-caption {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.slide-caption .num {
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: 0.4;
}

/* ── Progress bar ── */
.progress-track {
  position: fixed;
  bottom: calc(30px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: min(400px, 60vw);
  height: 2px;
  background: rgba(255,255,255,0.1);
  border-radius: 1px;
  z-index: 10;
}

.progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 1px;
  width: 0%;
  transition: width 0.3s var(--ease);
}

/* ── Dots ── */
.dots {
  position: fixed;
  bottom: calc(50px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}

.dot.active {
  background: var(--accent);
  transform: scale(1.4);
}

.dot:hover { background: rgba(255,255,255,0.5); }

/* ── Counter ── */
.counter {
  position: fixed;
  top: 30px;
  right: 30px;
  z-index: 10;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  opacity: 0.4;
}

/* ── Title ── */
.gallery-title {
  position: fixed;
  top: 30px;
  left: 30px;
  z-index: 10;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: 0.4;
}

/* ── Arrows ── */
.arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 50px;
  height: 50px;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  background: rgba(0,0,0,0.3);
  backdrop-filter: blur(10px);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s, background 0.3s;
}

.arrow:hover {
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.08);
}

.arrow.left { left: calc(20px + env(safe-area-inset-left)); }
.arrow.right { right: calc(20px + env(safe-area-inset-right)); }

.arrow svg {
  width: 18px;
  height: 18px;
  stroke: var(--text);
  stroke-width: 1.5;
  fill: none;
  opacity: 0.6;
}

.arrow.disabled {
  opacity: 0.15;
  pointer-events: none;
}

/* ── Keyboard hint ── */
.keyboard-hint {
  position: fixed;
  bottom: calc(80px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.6rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  opacity: 0.25;
  z-index: 10;
  transition: opacity 0.5s;
}
