:root {
  --max-width: 1100px;
  --pad: 18px;
  --radius: 14px;
  --shadow: 0 8px 28px rgba(0,0,0,.12);
  --border: 1px solid rgba(0,0,0,.12);
  --brown: #6b3f2a;
  --gold: #b7925a;
  --text: var(--brown);
  --muted: rgba(107,63,42,.7);
  --bg: #fff;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: #fafafa;
}

.app {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 24px var(--pad);
}

.top {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 14px;
}

.title {
  margin: 6px 0 0 0;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: 0.2px;
  text-align: center;
  color: var(--brown);
}

.controls {
  background: var(--bg);
  border: var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}

.labels {
  display: flex;
  justify-content: space-between;
  font-size: 20px;
  color: var(--gold);
  font-weight: 500;
  margin-bottom: 10px;
}

.control-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.slider { width: 100%; height: 28px; }

.play-toggle {
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: var(--border);
  background: var(--brown);
  color: #fff;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 18px rgba(0,0,0,.18);
  transition: transform .08s ease;
}
.play-toggle:active { transform: scale(0.95); }
.play-icon { pointer-events: none; }

.stage {
  position: relative;
  background: var(--bg);
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
}

.image-wrap {
  position: relative;
  z-index: 1;
  width: 100%;
  height: min(72vh, 720px);
  border-radius: 10px;
  overflow: hidden;
  background: #f3f3f3;
}

.image-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}

#imgA { opacity: 1; }
#imgB { opacity: 0; }

.nav {
  position: absolute;
  z-index: 20;
  color: var(--brown);
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 54px;
  border-radius: 12px;
  border: var(--border);
  background: rgba(255,255,255,.92);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 18px rgba(0,0,0,.12);
}
.nav:hover { background: rgba(255,255,255,1); }
.nav:active { transform: translateY(-50%) scale(0.98); }
.nav-left { left: 10px; }
.nav-right { right: 10px; }

.status {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  padding: 6px 10px;
  border-radius: 10px;
  background: rgba(107,63,42,.75);
  color: #fff;
  font-size: 12px;
  z-index: 25;
  text-align: center;
}

.instructions {
  margin-top: 14px;
  text-align: center;
  font-size: 18px;
  color: var(--brown);
  font-weight: 500;
}

@media (max-width: 540px) {
  .image-wrap { height: min(66vh, 560px); }
  .nav { width: 42px; height: 52px; }
  .instructions { font-size: 16px; }
  .play-toggle { width: 48px; height: 48px; font-size: 20px; }
}

.logo {
  max-width: 420px;
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}

.audio-panel {
  position: fixed;
  right: 18px;
  top: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-radius: 16px;
  border: var(--border);
  background: rgba(255,255,255,.95);
  box-shadow: 0 8px 22px rgba(0,0,0,.18);
  z-index: 999;
}

.audio-btn {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  border: none;
  background: var(--brown);
  color: #fff;
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 16px rgba(0,0,0,.22);
  transition: transform .08s ease, background .15s ease;
}
.audio-btn:hover { background: #57331f; }
.audio-btn:active { transform: scale(0.95); }
.audio-btn.muted { background: var(--gold); }
.audio-icon { pointer-events: none; }

.volume {
  width: 86px;
  height: 22px;
  accent-color: var(--brown);
  cursor: pointer;
}

@media (max-width: 540px) {
  .audio-btn { width: 56px; height: 56px; font-size: 26px; }
  .audio-panel { right: 12px; top: 12px; }
}
