/*
 * 莫奈的画境 / Monet's Dreamscape v2.0
 * ======================================
 * 样式表 / Stylesheet
 *
 * 设计理念 / Design Philosophy:
 *   - 主色调 #f5ead0（暖黄白）模拟老旧画纸质感
 *   - 背景深色系 #0a0a12 提供画廊般的沉浸感
 *   - 大量使用 rgba 透明度层叠实现光影朦胧效果
 *   - backdrop-filter: blur 营造印象派的柔焦氛围
 *   - Georgia serif 字体呼应古典艺术气质
 *
 * z-index 层级规划 / Layer Hierarchy:
 *   1000 - 加载屏幕 Loading Screen
 *    910 - 语言切换按钮 Language Toggle
 *    900 - 主菜单 Main Menu
 *    860 - 画廊返回按钮 Gallery Back
 *    850 - 画廊 & 图鉴 Gallery & Album
 *    800 - 画作揭示 Painting Reveal
 *    750 - 暂停遮罩 Pause Overlay
 *    740 - 背包遮罩 Backpack Overlay
 *    700 - 转场遮罩 Transition Overlay
 *    200 - 移动端控制 Mobile Controls
 *    150 - 提示浮层 Hint Overlay
 *    100 - HUD 抬头显示
 */

/* === RESET & BASE === */
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { width: 100%; height: 100%; overflow: hidden; background: #0a0a12; font-family: 'Georgia', serif; }
canvas { display: block; }

/* === LOADING SCREEN === */
#loading-screen {
  position: fixed; inset: 0; z-index: 1000;
  background: linear-gradient(135deg, #0a0a12 0%, #1a1a2e 50%, #0a0a12 100%);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  transition: opacity 1s ease;
}
#loading-screen.fade-out { opacity: 0; pointer-events: none; }
#loading-screen h1 {
  font-size: 3em; color: #e8d5b7; letter-spacing: 0.3em;
  text-shadow: 0 0 30px rgba(232,213,183,0.3);
  font-weight: 300; margin-bottom: 10px;
}
#loading-screen .subtitle {
  font-size: 1.1em; color: rgba(232,213,183,0.5); letter-spacing: 0.5em;
  margin-bottom: 50px; font-style: italic;
}
#loading-bar-container {
  width: 300px; height: 3px; background: rgba(255,255,255,0.1);
  border-radius: 2px; overflow: hidden;
}
#loading-bar {
  width: 0%; height: 100%; background: linear-gradient(90deg, #e8d5b7, #f0e0c8);
  transition: width 0.3s ease; border-radius: 2px;
}
#loading-text {
  margin-top: 15px; color: rgba(232,213,183,0.4); font-size: 0.85em;
  letter-spacing: 0.2em;
}

/* === MAIN MENU === */
#main-menu {
  position: fixed; inset: 0; z-index: 900;
  display: none; flex-direction: column; align-items: center; justify-content: center;
}
#menu-canvas { position: absolute; inset: 0; z-index: -1; }
.menu-title {
  font-size: 4em; color: #f5ead0; letter-spacing: 0.2em;
  text-shadow: 0 0 60px rgba(245,234,208,0.2), 0 4px 20px rgba(0,0,0,0.5);
  font-weight: 300; margin-bottom: 5px;
}
.menu-subtitle {
  font-size: 1.2em; color: rgba(245,234,208,0.4); letter-spacing: 0.8em;
  font-style: italic; margin-bottom: 60px;
}
.menu-btn {
  display: block; width: 260px; padding: 16px 0; margin: 8px 0;
  background: rgba(245,234,208,0.08); border: 1px solid rgba(245,234,208,0.15);
  color: #f5ead0; font-family: 'Georgia', serif; font-size: 1.1em;
  letter-spacing: 0.3em; cursor: pointer; transition: all 0.4s ease;
  backdrop-filter: blur(10px); text-align: center;
}
.menu-btn:hover {
  background: rgba(245,234,208,0.15); border-color: rgba(245,234,208,0.3);
  transform: translateY(-2px); box-shadow: 0 8px 30px rgba(245,234,208,0.1);
}

/* === LANGUAGE TOGGLE === */
.lang-btn {
  position: absolute; top: 20px; right: 20px;
  padding: 8px 18px; background: rgba(245,234,208,0.08);
  border: 1px solid rgba(245,234,208,0.15); color: rgba(245,234,208,0.6);
  font-family: 'Georgia', serif; font-size: 0.85em; letter-spacing: 0.15em;
  cursor: pointer; transition: all 0.3s ease; backdrop-filter: blur(10px);
  z-index: 910;
}
.lang-btn:hover { background: rgba(245,234,208,0.15); color: #f5ead0; }
.hud-lang-btn {
  padding: 5px 14px; background: rgba(245,234,208,0.06);
  border: 1px solid rgba(245,234,208,0.12); color: rgba(245,234,208,0.45);
  font-family: 'Georgia', serif; font-size: 0.8em; letter-spacing: 0.12em;
  cursor: pointer; transition: all 0.3s ease; pointer-events: auto;
  margin-left: 14px; border-radius: 20px;
}
.hud-lang-btn:hover { background: rgba(245,234,208,0.12); color: #f5ead0; }
.hud-right { display: flex; align-items: center; gap: 2px; }
.hud-pause-btn {
  padding: 5px 12px; background: rgba(245,234,208,0.06);
  border: 1px solid rgba(245,234,208,0.12); color: rgba(245,234,208,0.45);
  font-size: 1em; cursor: pointer; transition: all 0.3s ease;
  pointer-events: auto; margin-left: 6px; border-radius: 20px;
  line-height: 1;
}
.hud-pause-btn:hover { background: rgba(245,234,208,0.12); color: #f5ead0; }

/* === PAUSE OVERLAY === */
#pause-overlay {
  position: fixed; inset: 0; z-index: 750;
  display: none; align-items: center; justify-content: center;
  background: rgba(10,10,18,0.85); backdrop-filter: blur(12px);
  opacity: 0; transition: opacity 0.4s ease;
}
#pause-overlay.show { display: flex; opacity: 1; }
.pause-content { text-align: center; }
.pause-content h2 {
  color: #f5ead0; font-size: 2.5em; font-weight: 300;
  letter-spacing: 0.3em; margin-bottom: 40px;
  text-shadow: 0 0 30px rgba(245,234,208,0.2);
}
.pause-btn {
  display: block; width: 240px; padding: 14px 0; margin: 10px auto;
  background: rgba(245,234,208,0.08); border: 1px solid rgba(245,234,208,0.15);
  color: #f5ead0; font-family: 'Georgia', serif; font-size: 1em;
  letter-spacing: 0.25em; cursor: pointer; transition: all 0.3s ease;
}
.pause-btn:hover {
  background: rgba(245,234,208,0.15); border-color: rgba(245,234,208,0.3);
  transform: translateY(-2px);
}

/* === BACKPACK OVERLAY === */
#backpack-overlay {
  position: fixed; inset: 0; z-index: 740;
  display: none; align-items: center; justify-content: center;
  background: rgba(10,10,18,0.8); backdrop-filter: blur(8px);
  opacity: 0; transition: opacity 0.3s ease;
}
#backpack-overlay.show { display: flex; opacity: 1; }
.backpack-content { text-align: center; min-width: 280px; }
.backpack-content h2 {
  color: #f5ead0; font-size: 1.8em; font-weight: 300;
  letter-spacing: 0.3em; margin-bottom: 20px;
}
.backpack-grid {
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: center;
  max-width: 500px; margin: 0 auto;
}
.backpack-item {
  padding: 10px 16px; background: rgba(245,234,208,0.05);
  border: 1px solid rgba(245,234,208,0.12); color: rgba(245,234,208,0.6);
  font-size: 0.85em; letter-spacing: 0.08em; border-radius: 8px;
  border-left: 3px solid rgba(245,234,208,0.2);
  min-width: 100px; text-align: left;
  transition: all 0.3s ease;
}
.backpack-item.collected { background: rgba(245,234,208,0.08); color: rgba(245,234,208,0.85); }
.backpack-item.key-item {
  border-left-color: rgba(240,200,60,0.7); color: rgba(240,200,60,0.85);
  background: rgba(240,200,60,0.06);
}
.backpack-item.key-item.collected {
  border-left-color: rgba(240,200,60,1); color: rgba(240,200,60,1);
  background: rgba(240,200,60,0.1);
}
.backpack-item .bp-icon { display: inline-block; margin-right: 6px; font-size: 1.1em; }
.backpack-item .bp-name { font-weight: 300; }
.backpack-hint { color: rgba(245,234,208,0.25); font-size: 0.75em; margin-top: 15px; }

/* === LEVEL SELECT === */
#level-select {
  position: fixed; inset: 0; z-index: 860;
  display: none; flex-direction: column;
  background: linear-gradient(135deg, #0a0a12, #1a1a2e);
  align-items: center; justify-content: center;
}
.levelsel-grid {
  display: flex; gap: 24px; justify-content: center;
  flex-wrap: wrap; padding: 20px;
}
.levelsel-card {
  width: 260px; border-radius: 12px; overflow: hidden;
  background: rgba(245,234,208,0.04);
  border: 1px solid rgba(245,234,208,0.1);
  cursor: pointer; transition: all 0.3s ease;
  position: relative;
}
.levelsel-card:hover { transform: translateY(-4px); border-color: rgba(245,234,208,0.25); background: rgba(245,234,208,0.08); }
.levelsel-card.locked { opacity: 0.35; pointer-events: none; filter: grayscale(0.6); }
.levelsel-card img { width: 100%; height: 140px; object-fit: cover; display: block; }
.levelsel-card .lsc-info { padding: 12px 16px; }
.levelsel-card .lsc-name { color: #f5ead0; font-size: 1.1em; font-weight: 300; letter-spacing: 0.15em; }
.levelsel-card .lsc-sub { color: rgba(245,234,208,0.45); font-size: 0.8em; margin-top: 4px; letter-spacing: 0.05em; }
.levelsel-card .lsc-lock { color: rgba(245,234,208,0.3); font-size: 0.75em; margin-top: 6px; }

/* === SOUVENIR ALBUM === */
#album {
  position: fixed; inset: 0; z-index: 850;
  display: none; flex-direction: column;
  background: linear-gradient(135deg, #0a0a12, #1a1a2e);
  overflow: hidden;
}
.album-body {
  flex: 1; overflow-y: auto; padding: 0 30px 30px;
}
.album-body::-webkit-scrollbar { width: 4px; }
.album-body::-webkit-scrollbar-track { background: transparent; }
.album-body::-webkit-scrollbar-thumb { background: rgba(245,234,208,0.12); border-radius: 2px; }
.album-level-section {
  margin-bottom: 8px;
}
.album-level-header {
  color: rgba(245,234,208,0.35); font-size: 0.72em;
  letter-spacing: 0.25em; padding: 14px 0 8px;
  border-bottom: 1px solid rgba(245,234,208,0.06);
  text-transform: uppercase; user-select: none;
}
.album-items-row {
  display: flex; flex-wrap: wrap; gap: 10px; padding: 10px 0;
}
.album-item {
  width: 110px; padding: 10px 8px; text-align: center;
  background: rgba(245,234,208,0.04); border: 1px solid rgba(245,234,208,0.08);
  border-radius: 8px; transition: all 0.25s ease; cursor: pointer;
  position: relative;
}
.album-item:not(.locked):hover {
  background: rgba(245,234,208,0.08); border-color: rgba(245,234,208,0.2);
  transform: translateY(-2px);
}
.album-item.selected {
  background: rgba(245,234,208,0.1); border-color: rgba(245,234,208,0.3);
  box-shadow: 0 0 12px rgba(245,234,208,0.06);
}
.album-item .icon { font-size: 1.8em; margin-bottom: 4px; }
.album-item .name {
  color: rgba(245,234,208,0.55); font-size: 0.72em; letter-spacing: 0.04em;
  line-height: 1.3;
}
.album-item.locked { opacity: 0.2; filter: grayscale(1); cursor: default; }
.album-item.locked .name { color: rgba(245,234,208,0.25); }

/* === SOUVENIR DETAIL DRAWER === */
.sv-detail-drawer {
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height 0.4s cubic-bezier(0.4,0,0.2,1), opacity 0.3s ease, margin 0.3s ease;
  margin: 0; border-radius: 10px;
}
.sv-detail-drawer.open {
  max-height: 280px; opacity: 1; margin: 4px 0 12px;
}
.sv-detail-inner {
  display: flex; align-items: flex-start; gap: 24px;
  padding: 20px 24px;
  background: rgba(245,234,208,0.03);
  border: 1px solid rgba(245,234,208,0.08);
  border-radius: 10px;
  position: relative;
}
.sv-detail-drawer .sv-img-wrap {
  width: 160px; height: 160px; min-width: 160px;
  border-radius: 10px; overflow: hidden;
  border: 1px solid rgba(245,234,208,0.1);
  box-shadow: 0 6px 24px rgba(0,0,0,0.35);
  background: rgba(245,234,208,0.02);
}
.sv-detail-drawer .sv-img-wrap img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.sv-detail-drawer .sv-text {
  flex: 1; padding-top: 4px;
}
.sv-detail-drawer .sv-text h3 {
  color: #f5ead0; font-size: 1.1em; font-weight: 300;
  letter-spacing: 0.18em; margin: 0 0 6px;
}
.sv-detail-drawer .sv-text .sv-level-tag {
  display: inline-block; padding: 2px 10px;
  background: rgba(245,234,208,0.06); border: 1px solid rgba(245,234,208,0.1);
  border-radius: 12px; color: rgba(245,234,208,0.35);
  font-size: 0.68em; letter-spacing: 0.12em; margin-bottom: 12px;
}
.sv-detail-drawer .sv-text p {
  color: rgba(245,234,208,0.55); font-size: 0.82em;
  line-height: 1.7; letter-spacing: 0.03em; margin: 0;
}
.sv-detail-drawer .sv-close-btn {
  position: absolute; top: 10px; right: 12px;
  background: none; border: none; color: rgba(245,234,208,0.3);
  font-size: 1.3em; cursor: pointer; line-height: 1;
  transition: color 0.2s ease; padding: 4px;
}
.sv-detail-drawer .sv-close-btn:hover { color: #f5ead0; }
@media (max-width: 700px) {
  .album-body { padding: 0 16px 20px; }
  .album-item { width: 90px; padding: 8px 6px; }
  .album-item .icon { font-size: 1.5em; }
  .album-item .name { font-size: 0.65em; }
  .sv-detail-inner { flex-direction: column; align-items: center; gap: 14px; padding: 16px; }
  .sv-detail-drawer .sv-img-wrap { width: 120px; height: 120px; min-width: 120px; }
  .sv-detail-drawer .sv-text { text-align: center; }
  .sv-detail-drawer.open { max-height: 400px; }
}


/* === HUD === */
#game-hud {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 16px 28px 24px; display: none;
  background: linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.2) 60%, transparent 100%);
  pointer-events: none;
}
.hud-top { display: flex; justify-content: space-between; align-items: center; }
.hud-level {
  color: #f5ead0; font-size: 1.25em; letter-spacing: 0.4em;
  text-shadow: 0 2px 12px rgba(0,0,0,0.6), 0 0 24px rgba(245,234,208,0.08);
  font-weight: 300;
  padding: 4px 16px 4px 0;
  border-right: 1px solid rgba(245,234,208,0.08);
}
.hud-collectibles {
  display: flex; align-items: center; gap: 6px;
  color: #f5ead0; font-size: 1em;
}
.hud-collectibles .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(245,234,208,0.3); border: 1px solid rgba(245,234,208,0.5);
  transition: all 0.3s ease;
}
.hud-collectibles .dot.collected {
  background: #f5ead0; box-shadow: 0 0 10px rgba(245,234,208,0.5);
}
.hud-keys {
  display: flex; gap: 6px; align-items: center;
  padding: 5px 10px;
  background: rgba(240,200,60,0.06); border: 1px solid rgba(240,200,60,0.15);
  border-radius: 20px;
}
.key-dot {
  font-size: 1em; opacity: 0.25; transition: all 0.4s ease; filter: grayscale(1);
}
.key-dot.collected {
  opacity: 1; filter: grayscale(0);
  text-shadow: 0 0 10px rgba(240,200,60,0.7);
  animation: keyPulse 2s ease-in-out infinite;
}
@keyframes keyPulse {
  0%, 100% { text-shadow: 0 0 10px rgba(240,200,60,0.7); }
  50% { text-shadow: 0 0 18px rgba(240,200,60,1); }
}
.hud-sep { color: rgba(245,234,208,0.12); margin: 0 10px; font-size: 0.7em; }
.hud-souvenir-count {
  padding: 4px 12px;
  background: rgba(245,234,208,0.06); border: 1px solid rgba(245,234,208,0.12);
  border-radius: 20px;
  color: rgba(245,234,208,0.55); font-size: 0.9em; letter-spacing: 0.08em;
}
.hud-paint-progress {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 12px;
  background: rgba(245,234,208,0.06); border: 1px solid rgba(245,234,208,0.12);
  border-radius: 20px; color: rgba(245,234,208,0.55); font-size: 0.85em;
}
.paint-bar {
  display: inline-block; width: 60px; height: 4px;
  background: rgba(245,234,208,0.1); border-radius: 2px; overflow: hidden;
}
.paint-fill {
  display: block; height: 100%;
  background: linear-gradient(90deg, rgba(240,200,60,0.6), rgba(245,234,208,0.8));
  border-radius: 2px; transition: width 0.5s ease;
}

/* === PAINTING REVEAL === */
#painting-reveal {
  position: fixed; inset: 0; z-index: 900;
  display: none; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(10,10,18,0); backdrop-filter: blur(0px);
  opacity: 0; transition: opacity 0.6s ease;
  padding: 24px;
}
#painting-reveal.show {
  opacity: 1;
  background: rgba(10,10,18,0.92); backdrop-filter: blur(24px);
  transition: opacity 0.8s ease, background 1.2s ease 0.2s, backdrop-filter 1.2s ease 0.2s;
}

/* Inner wrapper — switches between row (landscape) and column (portrait) */
.reveal-inner {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 28px; max-width: 92vw; max-height: 88vh;
}
#painting-reveal.layout-landscape .reveal-inner {
  flex-direction: row; gap: 44px;
}

.reveal-canvas-wrap {
  position: relative;
  overflow: visible; border-radius: 3px;
  background: transparent;
  flex-shrink: 0;
  /* Painting entrance animation */
  transform: scale(1.08); opacity: 0;
  transition: transform 1.4s cubic-bezier(0.22,1,0.36,1) 0.3s, opacity 1s ease 0.3s;
}
#painting-reveal.show .reveal-canvas-wrap {
  transform: scale(1); opacity: 1;
}
/* Golden frame effect */
.reveal-canvas-wrap::before {
  content: ''; position: absolute; inset: -6px; border-radius: 4px;
  border: 2px solid rgba(200,170,100,0.35);
  box-shadow: 0 0 40px rgba(200,170,100,0.08), inset 0 0 40px rgba(200,170,100,0.05),
              0 20px 60px rgba(0,0,0,0.5);
  pointer-events: none; z-index: 4;
}
.reveal-canvas-wrap::after {
  content: ''; position: absolute; inset: -2px; border-radius: 3px;
  border: 1px solid rgba(245,234,208,0.12);
  pointer-events: none; z-index: 4;
}

/* Painting image — sized naturally by image proportions */
.reveal-painting-img {
  display: block; max-height: 62vh; max-width: 80vw;
  width: auto; height: auto;
  border-radius: 2px;
}
/* Hide legacy layers */
.reveal-layer { display: none; }
#reveal-mask-canvas { display: none; }

#painting-reveal .info {
  text-align: center; max-width: 520px;
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.7s ease 1s, transform 0.7s ease 1s;
}
#painting-reveal.layout-landscape .info {
  text-align: left; max-width: 340px;
  transform: translateX(20px);
  transition: opacity 0.7s ease 1s, transform 0.7s ease 1s;
}
#painting-reveal.layout-landscape.show .info {
  opacity: 1; transform: translateX(0);
}
#painting-reveal.show .info {
  opacity: 1; transform: translateY(0);
}
#painting-reveal .info h2 {
  color: #f5ead0; font-size: 1.7em; font-weight: 300;
  letter-spacing: 0.2em; margin-bottom: 8px;
}
#painting-reveal .info .artist {
  color: rgba(200,170,100,0.6); font-size: 0.9em;
  letter-spacing: 0.3em; margin-bottom: 14px; font-style: italic;
}
#painting-reveal .info .desc {
  color: rgba(245,234,208,0.55); font-size: 0.88em;
  line-height: 1.8; letter-spacing: 0.04em;
}
#painting-reveal .continue-btn {
  margin-top: 16px; padding: 12px 50px;
  background: rgba(245,234,208,0.06); border: 1px solid rgba(245,234,208,0.15);
  color: rgba(245,234,208,0.7); font-family: 'Georgia', serif; font-size: 0.95em;
  letter-spacing: 0.3em; cursor: pointer;
  pointer-events: auto; opacity: 0; transform: translateY(10px);
  transition: all 0.3s ease, opacity 0.6s ease 1.4s, transform 0.6s ease 1.4s;
  flex-shrink: 0; border-radius: 2px;
}
#painting-reveal.show .continue-btn {
  opacity: 1; transform: translateY(0);
}
#painting-reveal .continue-btn:hover {
  background: rgba(245,234,208,0.12); color: #f5ead0;
  border-color: rgba(200,170,100,0.3); transform: translateY(-2px);
}
@media (max-width: 700px) {
  #painting-reveal { padding: 16px; }
  .reveal-inner { gap: 16px; }
  #painting-reveal.layout-landscape .reveal-inner { flex-direction: column; }
  .reveal-painting-img { max-height: 45vh; max-width: 92vw; }
  #painting-reveal.layout-landscape .info { text-align: center; max-width: 90vw; }
}


/* === MOBILE CONTROLS === */
#mobile-controls {
  position: fixed; bottom: 20px; left: 0; right: 0; z-index: 200;
  display: none; justify-content: space-between; padding: 0 20px;
  pointer-events: none;
}
.ctrl-btn {
  width: 65px; height: 65px; border-radius: 50%;
  background: rgba(245,234,208,0.1); border: 1px solid rgba(245,234,208,0.2);
  color: #f5ead0; font-size: 1.5em; display: flex; align-items: center;
  justify-content: center; pointer-events: auto; user-select: none;
  -webkit-user-select: none; touch-action: manipulation;
  backdrop-filter: blur(5px);
}
.ctrl-left { display: flex; gap: 15px; }
.ctrl-right { display: flex; gap: 15px; }

/* === HINT OVERLAY === */
#hint-overlay {
  position: fixed; bottom: 100px; left: 50%; transform: translateX(-50%);
  z-index: 150; padding: 12px 30px;
  background: rgba(10,10,18,0.7); border: 1px solid rgba(245,234,208,0.15);
  color: rgba(245,234,208,0.7); font-size: 0.85em; letter-spacing: 0.2em;
  backdrop-filter: blur(10px); white-space: nowrap;
  opacity: 0; transition: opacity 0.5s ease; pointer-events: none;
}
#hint-overlay.show { opacity: 1; }

/* === GALLERY === */
#gallery {
  position: fixed; inset: 0; z-index: 850;
  display: none; flex-direction: column;
  background: linear-gradient(135deg, #0a0a12, #1a1a2e);
  overflow-y: auto;
}
.gallery-header {
  text-align: center; padding: 40px 20px 20px;
}
.gallery-header h2 {
  color: #f5ead0; font-size: 2em; font-weight: 300;
  letter-spacing: 0.3em;
}
.gallery-grid {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 30px; padding: 30px 40px;
}
.gallery-item {
  width: 320px; cursor: pointer; transition: transform 0.3s ease;
}
.gallery-item:hover { transform: translateY(-5px); }
.gallery-item img {
  width: 100%; border: 1px solid rgba(245,234,208,0.15);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}
.gallery-item.locked img { filter: brightness(0.15) blur(3px); }
.gallery-item .label {
  text-align: center; margin-top: 10px;
  color: rgba(245,234,208,0.6); font-size: 0.9em; letter-spacing: 0.1em;
}
.gallery-item.locked .label { color: rgba(245,234,208,0.25); }
.gallery-back {
  position: fixed; top: 20px; left: 20px; z-index: 860;
  padding: 10px 25px; background: rgba(245,234,208,0.08);
  border: 1px solid rgba(245,234,208,0.15); color: #f5ead0;
  font-family: 'Georgia', serif; cursor: pointer; letter-spacing: 0.2em;
  font-size: 0.9em; transition: all 0.3s ease;
}
.gallery-back:hover { background: rgba(245,234,208,0.15); }

/* === TRANSITIONS === */
#transition-overlay {
  position: fixed; inset: 0; z-index: 700;
  background: #0a0a12; pointer-events: none;
  opacity: 0; transition: opacity 0.8s ease;
}
#transition-overlay.active { opacity: 1; }
