/* ============================================
   MACHINE MEMORY — Pitch Deck
   Dark gallery aesthetic, cinematic transitions
   ============================================ */

::selection {
  background: rgba(200, 200, 200, 0.25);
  color: #fff;
}

::-moz-selection {
  background: rgba(200, 200, 200, 0.25);
  color: #fff;
}

:root {
  --black: #050505;
  --near-black: #0a0a0a;
  --dark: #111111;
  --mid: #1a1a1a;
  --chrome: #c8c8c8;
  --chrome-bright: #e8e8e8;
  --chrome-dim: #666666;
  --text: #e0e0e0;
  --text-dim: #888888;
  --accent: #c8736a;
  --accent-glow: rgba(200, 115, 106, 0.3);
  --font-display: 'Outfit', -apple-system, sans-serif;
  --font-body: 'Outfit', -apple-system, sans-serif;
  --transition-slide: 0.8s cubic-bezier(0.65, 0, 0.35, 1);
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

::selection {
  background: var(--accent);
  color: var(--black);
}

html {
  overflow: hidden;
  height: 100%;
  height: 100dvh;
  background: var(--black);
}

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--black);
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- Progress Bar ---- */

.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.06);
  z-index: 1000;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--chrome-bright));
  transition: width 0.5s ease;
}

/* ---- Navigation ---- */

.slide-nav {
  position: fixed;
  right: 2rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.nav-dots {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.nav-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1px solid var(--chrome-dim);
  background: transparent;
  cursor: pointer;
  transition: all 0.4s ease;
  padding: 0;
}

.nav-dot:hover {
  border-color: var(--chrome);
  background: rgba(200, 200, 200, 0.2);
}

.nav-dot.active {
  background: var(--chrome-bright);
  border-color: var(--chrome-bright);
  box-shadow: 0 0 8px rgba(232, 232, 232, 0.3);
}

/* ---- Scroll Hint ---- */

.scroll-hint {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--chrome-dim);
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 300;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  opacity: 1;
  transition: opacity 0.6s ease;
}

.scroll-hint.hidden {
  opacity: 0;
  pointer-events: none;
}

.scroll-hint-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--chrome-dim));
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ---- Slides Container ---- */

.slides-container {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

/* ---- Individual Slide ---- */

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(60px);
  transition: opacity var(--transition-slide), transform var(--transition-slide);
  pointer-events: none;
  overflow: hidden;
}

.slide.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.slide.exit-up {
  opacity: 0;
  transform: translateY(-60px);
}

.slide-video-bg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  object-fit: cover;
  z-index: 0;
}

.slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 58% 80% at 50% 50%, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.78) 45%, rgba(0, 0, 0, 0.45) 75%, rgba(0, 0, 0, 0) 100%),
    rgba(5, 5, 5, 0.35);
  z-index: 1;
}

.slide-content {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  width: 90%;
  padding: 2rem;
  max-height: 90vh;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.slide-content::-webkit-scrollbar {
  display: none;
}

/* ---- Typography ---- */

.slide-content h1 {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 1.1;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--chrome-bright);
  margin-bottom: 1rem;
}

.slide-content h2 {
  font-family: var(--font-display);
  font-weight: 200;
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.2;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--chrome);
  margin-bottom: 1.5rem;
}

.slide-content h3 {
  font-family: var(--font-display);
  font-weight: 200;
  font-size: clamp(1rem, 2vw, 1.4rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--chrome);
  margin-bottom: 1.2rem;
  opacity: 0.7;
}

.slide-content p {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: clamp(0.9rem, 1.2vw, 1.05rem);
  line-height: 1.85;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-bottom: 1rem;
}

.slide-content strong {
  font-weight: 400;
  color: var(--chrome-bright);
}

.slide-content em {
  font-style: italic;
  color: var(--accent);
}

.slide-content a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease;
}

.slide-content a:hover {
  border-bottom-color: var(--accent);
}

/* ---- Tables ---- */

.slide-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.slide-content table th,
.slide-content table td {
  padding: 0.7rem 1rem;
  text-align: left;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.slide-content table th {
  font-weight: 400;
  color: var(--chrome);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.slide-content table td {
  font-weight: 300;
  color: var(--text);
}

.slide-content table td:first-child {
  color: var(--chrome-dim);
  font-weight: 300;
  white-space: nowrap;
}

/* ---- HERO SLIDE ---- */

.slide-hero .slide-content {
  display: none;
}

.slide-hero .slide-video-bg {
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  object-fit: contain;
  min-width: 0;
  min-height: 0;
  background: #050505;
}

/* ---- WORK SLIDE ---- */

.work-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 2.5rem;
  align-items: center;
}

.work-image img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 2px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.work-details table {
  margin-top: 1rem;
}

.work-details p {
  font-size: 0.9rem;
}

/* ---- STATEMENT SLIDE ---- */

.slide-statement {
  background: var(--near-black);
}

.statement-content {
  max-width: 760px;
}

.statement-content p {
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  line-height: 2;
  font-weight: 300;
  letter-spacing: 0.02em;
  color: var(--text);
}

.statement-content p:last-child {
  margin-top: 1.5rem;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  font-weight: 200;
  letter-spacing: 0.03em;
  color: var(--chrome-bright);
}

/* ---- FOUR FACES SLIDE ---- */

.faces-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  margin: 2rem 0;
}

.face-card {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
  aspect-ratio: 2/3;
}

.face-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.face-card:hover img {
  transform: scale(1.05);
}

.face-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 200;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--chrome);
}

.slide-faces .slide-content > p {
  text-align: center;
  margin: 0 auto;
}

.slide-faces .slide-content > h1 {
  text-align: center;
}

/* ---- LIVING SYSTEM SLIDE ---- */

.system-content {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.system-text p {
  max-width: 100%;
}

.system-visual img {
  width: 100%;
  border-radius: 2px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* ---- SPECS SLIDE ---- */

.specs-layout {
  display: grid;
  grid-template-columns: 0.7fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

.specs-hero-img img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 2px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
}

.specs-table table td:first-child {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--chrome-dim);
  letter-spacing: 0.08em;
  width: 140px;
}

/* ---- GALLERY SLIDE ---- */

.slide-gallery .slide-content {
  max-width: 1200px;
}

.slide-gallery h1 {
  text-align: center;
  margin-bottom: 1.5rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}

.gallery-grid + .gallery-grid {
  margin-top: 0.5rem;
}

.gallery-grid-videos {
  grid-template-columns: repeat(2, 1fr);
}

.gallery-grid-videos .gallery-item {
  aspect-ratio: 16/9;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
  cursor: pointer;
  aspect-ratio: 4/3;
  background: var(--mid);
}

.gallery-item img,
.gallery-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.gallery-item:hover img,
.gallery-item:hover video {
  transform: scale(1.06);
}

.gallery-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  transition: background 0.3s ease, transform 0.3s ease;
  padding-left: 3px;
}

.gallery-item:hover .gallery-play-btn {
  background: rgba(200, 115, 106, 0.7);
  transform: translate(-50%, -50%) scale(1.08);
}

.gallery-video.is-playing .gallery-play-btn {
  opacity: 0;
}

/* ---- CONTACT SLIDE ---- */

.slide-contact {
  background: var(--near-black);
}

.contact-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.contact-content h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 100;
  letter-spacing: 0.2em;
  background: linear-gradient(180deg, #ffffff 0%, #888888 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.contact-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}

.contact-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.3em;
  color: var(--chrome-dim);
  font-weight: 200;
}

.contact-block a {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 200;
  letter-spacing: 0.04em;
  color: var(--chrome);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.3s ease;
}

.contact-block a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ---- Lightbox ---- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.lightbox.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: var(--chrome);
  font-size: 2rem;
  cursor: pointer;
  z-index: 2001;
  transition: color 0.3s ease;
}

.lightbox-close:hover {
  color: var(--accent);
}

.lightbox-content {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-content img,
.lightbox-content video {
  width: 75vw;
  height: 75vh;
  object-fit: contain;
  border-radius: 2px;
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 2.5rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
  z-index: 2002;
  line-height: 0;
  padding: 0 0 3px 0;
}

.lightbox-arrow:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.4);
}

.lightbox-prev {
  left: 2rem;
}

.lightbox-next {
  right: 2rem;
}

.lightbox-counter {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  font-family: var(--font-body);
  letter-spacing: 0.05em;
}

/* ---- Reveal Animations ---- */

.slide.active .slide-content {
  animation: contentReveal 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes contentReveal {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Typing reveal (slides.js splits text into .tw-c characters) */
.tw-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.tw-c {
  position: relative;
}

.tw-c.tw-h {
  visibility: hidden;
}

.tw-caret {
  position: absolute;
  left: 100%;
  top: 0.14em;
  bottom: 0.06em;
  width: 0.5em;
  margin-left: 0.12em;
  background: #fff;
  visibility: visible;
  pointer-events: none;
}

.tw-caret.tw-rest {
  animation: twRest 0.6s forwards;
}

@keyframes twRest {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

.slide.active .work-image,
.slide.active .system-visual,
.slide.active .specs-hero-img {
  animation: imageReveal 1s 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

@keyframes imageReveal {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.slide.active .face-card,
.slide.active .gallery-item {
  animation: cardStagger 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

.slide.active .face-card:nth-child(1),
.slide.active .gallery-item:nth-child(1) { animation-delay: 0.15s; }
.slide.active .face-card:nth-child(2),
.slide.active .gallery-item:nth-child(2) { animation-delay: 0.25s; }
.slide.active .face-card:nth-child(3),
.slide.active .gallery-item:nth-child(3) { animation-delay: 0.35s; }
.slide.active .face-card:nth-child(4),
.slide.active .gallery-item:nth-child(4) { animation-delay: 0.45s; }
.slide.active .face-card:nth-child(5),
.slide.active .gallery-item:nth-child(5) { animation-delay: 0.55s; }
.slide.active .gallery-item:nth-child(6) { animation-delay: 0.6s; }
.slide.active .gallery-item:nth-child(7) { animation-delay: 0.65s; }
.slide.active .gallery-item:nth-child(8) { animation-delay: 0.7s; }
.slide.active .gallery-item:nth-child(9) { animation-delay: 0.75s; }
.slide.active .gallery-item:nth-child(10) { animation-delay: 0.8s; }
.slide.active .gallery-item:nth-child(11) { animation-delay: 0.85s; }
.slide.active .gallery-item:nth-child(12) { animation-delay: 0.9s; }

@keyframes cardStagger {
  from {
    opacity: 0;
    transform: translateY(25px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ---- Chrome accent line (between slides feel) ---- */

.slide::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200, 200, 200, 0.08), transparent);
}

/* ---- Responsive ---- */

@media (max-width: 768px) {
  /* One native scroll surface: no nested scrolling or scripted momentum. */
  .slides-container {
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    scrollbar-width: none;
  }
  .slides-container::-webkit-scrollbar { display: none; }
  body.has-lightbox .slides-container { overflow-y: hidden; }
  .slide {
    position: relative;
    height: auto;
    min-height: 100dvh;
    align-items: flex-start;
    opacity: 1;
    transform: none !important;
    transition: none;
    pointer-events: auto;
  }
  .slide.exit-up { opacity: 1; }
  .slides-container .slide .slide-content,
  .slides-container .slide .work-image,
  .slides-container .slide .system-visual,
  .slides-container .slide .specs-hero-img,
  .slides-container .slide .face-card,
  .slides-container .slide .gallery-item { animation: none; }
  .tw-c.tw-h { visibility: visible; }
  .tw-caret { display: none; }

  /* Size the video box to the viewport, not the source's intrinsic pixels. */
  .slide-video-bg {
    inset: 0;
    transform: none;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    object-fit: cover;
    object-position: center;
  }

  .slide-overlay { background: rgba(5, 5, 5, 0.7); }

  .slide-content {
    width: 100%;
    min-width: 0;
    max-height: none;
    padding: max(2rem, env(safe-area-inset-top)) max(1.5rem, env(safe-area-inset-right)) max(3rem, env(safe-area-inset-bottom)) max(1.5rem, env(safe-area-inset-left));
    overflow: visible;
    overflow-wrap: anywhere;
  }

  .slide-content h1,
  .slide-content h2,
  .slide-gallery h1,
  .contact-content h1 {
    font-size: clamp(1.6rem, 7vw, 2.5rem);
    font-weight: 100;
    line-height: 1.15;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    max-width: 100%;
  }

  .slide-content h3 {
    font-size: clamp(0.9rem, 3.6vw, 1.1rem);
    line-height: 1.5;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
  }

  .slide-content p,
  .statement-content p,
  .statement-content p:last-child {
    font-size: 0.9rem;
    line-height: 1.7;
  }

  /* Full-bleed film with a large, centered title over the image. */
  .slide-hero {
    height: 100dvh;
  }
  .slide-hero .slide-content {
    display: flex;
    position: absolute;
    inset: 0;
    height: 100%;
    align-items: center;
    justify-content: center;
    padding: 0 1.5rem;
    background: radial-gradient(ellipse 100% 30% at 50% 50%, rgba(0, 0, 0, 0.3), transparent);
    text-align: center;
    overflow: visible;
  }
  .slide-hero h1 {
    width: 80vw;
    max-width: 80vw;
    margin: 0 auto;
    font-size: 15.3vw;
    overflow-wrap: normal;
    line-height: 1.1;
    letter-spacing: 0.12em;
    text-wrap: balance;
    color: #fff;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.75);
  }
  .slide-hero .slide-video-bg {
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
    object-fit: cover;
    object-position: center;
  }
  .scroll-hint {
    bottom: max(0.8rem, env(safe-area-inset-bottom));
    color: #fff;
    text-shadow: 0 1px 6px #000;
    pointer-events: none;
  }
  .scroll-hint-line { height: 16px; }

  .work-grid,
  .system-content,
  .specs-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
  }
  .work-grid {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  .work-grid > *,
  .system-content > *,
  .specs-layout > * { min-width: 0; max-width: 100%; }
  .work-details { display: contents; }
  .work-details h2 { order: -2; margin-bottom: 0; }
  .work-image { order: -1; width: 100%; }
  .work-image img,
  .specs-hero-img img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 52dvh;
    object-fit: contain;
    object-position: center;
    margin-inline: auto;
  }
  .slide-content table { table-layout: fixed; margin-block: 0.5rem; }
  .slide-content table th,
  .slide-content table td {
    padding: 0.65rem 0.4rem;
    font-size: 0.8rem;
    line-height: 1.5;
    overflow-wrap: anywhere;
  }
  .slide-content table td:first-child {
    width: 38%;
    white-space: normal;
    padding-left: 0;
  }
  .slide-content table td:last-child { padding-right: 0; }

  .faces-grid,
  .gallery-grid,
  .gallery-grid-videos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.4rem; }
  .gallery-item img,
  .gallery-item video { object-fit: contain; object-position: center; }
  .gallery-grid-videos .gallery-item { aspect-ratio: 16 / 9; }
  .gallery-play-btn { width: 40px; height: 40px; font-size: 1rem; }

  .slide-contact { align-items: center; }
  .contact-content { gap: 1.5rem; }
  .contact-block { min-width: 0; max-width: 100%; }
  .slide-nav { right: max(0.5rem, env(safe-area-inset-right)); }
  .nav-dots { gap: 0.5rem; }
  .nav-dot { width: 6px; height: 6px; }
  .lightbox-content { width: 100%; }
  .lightbox-content img,
  .lightbox-content video { width: 100%; height: 80dvh; }
  .lightbox-prev { left: 0.5rem; }
  .lightbox-next { right: 0.5rem; }
}

@media (hover: none) {
  .gallery-item:hover img,
  .gallery-item:hover video { transform: none; }
  .gallery-item:hover .gallery-play-btn {
    background: rgba(0, 0, 0, 0.55);
    transform: translate(-50%, -50%);
  }
}
