:root {
  color-scheme: dark;
  --control-bg: rgb(10 10 10 / 72%);
  --control-border: rgb(255 255 255 / 26%);
  --control-text: #f9f7ef;
  --control-focus: #f5b51b;
  --goofy-yellow: #f5b51b;
  --paper: #f9f4e8;
  --slide-width: 1672;
  --slide-height: 941;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  overflow: hidden;
  background: #020202;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}

body.auth-locked .presentation {
  pointer-events: none;
  user-select: none;
  filter: blur(4px) brightness(0.42);
}

button {
  font: inherit;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 35%, rgb(245 181 27 / 12%), transparent 32%),
    rgb(0 0 0 / 82%);
  backdrop-filter: blur(10px);
}

.auth-gate[hidden] {
  display: none;
}

.auth-card {
  display: grid;
  width: min(420px, calc(100vw - 32px));
  gap: 16px;
  padding: clamp(22px, 3vw, 32px);
  color: var(--paper);
  border: 1px solid rgb(245 181 27 / 72%);
  border-radius: 8px;
  background: rgb(4 4 4 / 95%);
  box-shadow: 0 28px 80px rgb(0 0 0 / 68%);
}

.auth-kicker,
.auth-error {
  margin: 0;
}

.auth-kicker {
  color: var(--goofy-yellow);
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
}

.auth-card h1 {
  margin: 0;
  color: var(--paper);
  font-size: clamp(32px, 5vw, 54px);
  font-weight: 950;
  line-height: 0.95;
  text-transform: uppercase;
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-field label {
  color: rgb(249 244 232 / 72%);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.auth-field input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  color: var(--paper);
  font: inherit;
  font-size: 18px;
  font-weight: 800;
  border: 1px solid rgb(245 181 27 / 62%);
  border-radius: 6px;
  background: #0b0b0b;
}

.auth-field input:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.auth-error {
  color: #ffcf67;
  font-size: 14px;
  font-weight: 850;
}

.auth-submit {
  min-height: 48px;
  color: #050505;
  cursor: pointer;
  border: 1px solid #050505;
  border-radius: 6px;
  background: var(--goofy-yellow);
  font-size: 16px;
  font-weight: 950;
  text-transform: uppercase;
}

.auth-submit:hover {
  background: #ffd568;
}

.auth-submit:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.presentation {
  position: relative;
  display: grid;
  min-height: 100vh;
  place-items: center;
  background: #020202;
}

.slide-frame {
  display: grid;
  width: 100vw;
  height: 100vh;
  place-items: center;
}

.slide-canvas {
  position: relative;
  width: min(100vw, calc(100vh * var(--slide-width) / var(--slide-height)));
  height: min(100vh, calc(100vw * var(--slide-height) / var(--slide-width)));
  overflow: hidden;
  background-color: #020202;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
}

.hotspot-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.hotspot {
  position: absolute;
  display: block;
  padding: 0;
  cursor: pointer;
  border: 2px solid transparent;
  background: transparent;
}

.hotspot--cta {
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  color: #ffb21a;
  font-size: clamp(12px, 1.1vw, 18px);
  font-weight: 950;
  line-height: 1.08;
  letter-spacing: 0;
  text-align: center;
  text-decoration-line: underline;
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.18em;
  text-transform: uppercase;
  text-shadow:
    0 2px 4px rgb(0 0 0 / 88%),
    0 0 14px rgb(245 181 27 / 34%);
  border: 1px solid rgb(245 181 27 / 48%);
  border-radius: 6px;
  background: rgb(0 0 0 / 54%);
  box-shadow: 0 12px 22px rgb(0 0 0 / 38%);
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    background 160ms ease;
}

.hotspot--fixed-cta {
  position: fixed;
  top: max(18px, env(safe-area-inset-top));
  right: max(22px, env(safe-area-inset-right));
  left: auto !important;
  width: auto !important;
  height: auto !important;
}

.hotspot--toy-cta {
  align-items: center;
  min-width: 210px;
  min-height: 44px;
  background: rgb(0 0 0 / 68%);
}

.hotspot--cta:hover {
  transform: translateY(-2px);
  color: #ffd568;
  border-color: rgb(245 181 27 / 86%);
  background: rgb(0 0 0 / 72%);
}

.hotspot:focus-visible {
  outline: none;
  border-color: var(--control-focus);
  box-shadow: 0 0 0 4px rgb(245 181 27 / 28%);
}

.deck-controls {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--control-border);
  border-radius: 999px;
  background: var(--control-bg);
  backdrop-filter: blur(14px);
  box-shadow: 0 16px 40px rgb(0 0 0 / 42%);
}

.icon-button {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  padding: 0;
  color: var(--control-text);
  cursor: pointer;
  border: 1px solid rgb(255 255 255 / 18%);
  border-radius: 50%;
  background: rgb(255 255 255 / 8%);
}

.icon-button span {
  display: block;
  translate: 0 -1px;
  font-size: 32px;
  line-height: 1;
}

.icon-button:hover {
  background: rgb(255 255 255 / 16%);
}

.icon-button:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.icon-button:disabled {
  cursor: default;
  opacity: 0.42;
}

.slide-count {
  min-width: 40px;
  color: var(--control-text);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
}

.modal-shell {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  overflow: auto;
  padding: 24px;
  overscroll-behavior: contain;
}

.modal-shell[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgb(0 0 0 / 78%);
  backdrop-filter: blur(8px);
}

.carousel-modal,
.survey-modal {
  position: relative;
  display: grid;
  width: min(980px, calc(100vw - 32px));
  max-height: min(880px, calc(100dvh - 32px));
  min-height: 0;
  gap: 18px;
  padding: clamp(18px, 2.2vw, 28px);
  overflow: hidden;
  color: var(--paper);
  border: 1px solid rgb(245 181 27 / 72%);
  border-radius: 8px;
  background: rgb(4 4 4 / 94%);
  box-shadow: 0 28px 80px rgb(0 0 0 / 65%);
}

.survey-modal {
  grid-template-rows: auto minmax(0, 1fr);
  width: min(820px, calc(100vw - 32px));
  height: min(760px, calc(100dvh - 32px));
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.modal-header h2 {
  margin: 0;
  color: var(--goofy-yellow);
  font-size: clamp(28px, 4vw, 54px);
  font-weight: 950;
  line-height: 0.95;
  letter-spacing: 0;
  text-transform: uppercase;
}

.close-button,
.carousel-arrow {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  padding: 0;
  color: var(--paper);
  cursor: pointer;
  border: 1px solid rgb(255 255 255 / 20%);
  border-radius: 50%;
  background: rgb(255 255 255 / 8%);
}

.close-button {
  width: 42px;
  height: 42px;
}

.close-button span {
  translate: 0 -1px;
  font-size: 34px;
  line-height: 1;
}

.carousel-stage {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 54px;
  align-items: center;
  gap: 16px;
}

.carousel-arrow {
  width: 54px;
  height: 54px;
}

.carousel-arrow span {
  translate: 0 -2px;
  font-size: 46px;
  line-height: 1;
}

.close-button:hover,
.carousel-arrow:hover {
  background: rgb(255 255 255 / 16%);
}

.close-button:focus-visible,
.carousel-arrow:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.carousel-arrow:disabled {
  cursor: default;
  opacity: 0.38;
}

.carousel-figure {
  display: grid;
  min-width: 0;
  gap: 14px;
  margin: 0;
}

.carousel-image-wrap {
  --image-padding: 16px;
  position: relative;
  display: grid;
  height: min(62vh, 600px);
  min-height: 320px;
  place-items: center;
  overflow: hidden;
  padding: var(--image-padding);
  border: 1px solid rgb(255 255 255 / 14%);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgb(255 255 255 / 8%), transparent 38%),
    #0b0b0b;
}

#carouselImage {
  display: block;
  position: absolute;
  inset: var(--image-padding);
  width: calc(100% - (var(--image-padding) * 2));
  height: calc(100% - (var(--image-padding) * 2));
  min-width: 0;
  min-height: 0;
  max-width: calc(100% - (var(--image-padding) * 2));
  max-height: calc(100% - (var(--image-padding) * 2));
  object-fit: contain;
}

.carousel-empty {
  margin: 0;
  color: rgb(249 244 232 / 70%);
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 800;
  text-transform: uppercase;
}

#carouselName {
  min-height: 36px;
  color: var(--paper);
  font-size: clamp(22px, 2.8vw, 38px);
  font-weight: 900;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
}

.carousel-position {
  min-height: 18px;
  margin: 0;
  color: rgb(249 244 232 / 62%);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
}

.survey-picker {
  display: grid;
  gap: 8px;
}

.survey-form {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 14px;
  min-height: 0;
}

.survey-picker label {
  color: var(--goofy-yellow);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.survey-picker select {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  color: var(--paper);
  font: inherit;
  font-size: 16px;
  font-weight: 800;
  border: 1px solid rgb(245 181 27 / 62%);
  border-radius: 6px;
  background: #0b0b0b;
}

.survey-picker select:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.survey-panel {
  display: grid;
  gap: 18px;
  min-height: 0;
  height: 100%;
  padding: clamp(18px, 2vw, 26px);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  -webkit-overflow-scrolling: touch;
  border: 1px solid rgb(255 255 255 / 14%);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgb(255 255 255 / 8%), transparent 44%),
    #0b0b0b;
}

.survey-panel h3 {
  margin: 0;
  color: var(--goofy-yellow);
  font-size: clamp(22px, 3vw, 36px);
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
}

.survey-section {
  display: grid;
  gap: 10px;
}

.survey-section h4 {
  margin: 0;
  color: rgb(249 244 232 / 72%);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.survey-questions {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 1.4em;
}

.survey-questions li,
.survey-open-prompts li {
  display: grid;
  gap: 8px;
  color: var(--paper);
  font-size: clamp(16px, 2vw, 24px);
  font-weight: 750;
  line-height: 1.22;
}

.survey-open-prompts {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.survey-open-prompts li {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid rgb(245 181 27 / 32%);
  border-radius: 6px;
  background: rgb(245 181 27 / 7%);
}

.survey-questions input,
.survey-open-prompts textarea {
  width: 100%;
  min-height: 40px;
  padding: 10px 12px;
  color: var(--paper);
  font: inherit;
  font-size: 15px;
  font-weight: 750;
  line-height: 1.25;
  border: 1px solid rgb(255 255 255 / 16%);
  border-radius: 6px;
  background: rgb(0 0 0 / 36%);
}

.survey-open-prompts textarea {
  resize: vertical;
}

.survey-questions input:focus-visible,
.survey-open-prompts textarea:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

.survey-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.survey-status {
  min-height: 18px;
  margin: 0;
  color: rgb(249 244 232 / 72%);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.2;
}

.survey-submit {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 0 16px;
  color: #050505;
  cursor: pointer;
  border: 1px solid #050505;
  border-radius: 6px;
  background: var(--goofy-yellow);
  font-size: 14px;
  font-weight: 950;
  text-transform: uppercase;
}

.survey-submit:hover {
  background: #ffd568;
}

.survey-submit:disabled {
  cursor: default;
  opacity: 0.62;
}

.survey-submit:focus-visible {
  outline: 2px solid var(--control-focus);
  outline-offset: 3px;
}

@media (max-width: 520px) {
  .deck-controls {
    right: 50%;
    bottom: max(12px, env(safe-area-inset-bottom));
    translate: 50% 0;
  }

  .icon-button {
    width: 36px;
    height: 36px;
  }

  .hotspot--cta {
    max-width: min(260px, calc(100vw - 24px));
    font-size: 11px;
  }

  .hotspot--fixed-cta {
    right: 12px;
  }

  .hotspot--toy-cta {
    min-width: 160px;
    min-height: 36px;
  }

  .modal-shell {
    padding: 12px;
  }

  .carousel-modal,
  .survey-modal {
    width: calc(100vw - 24px);
    max-height: calc(100dvh - 24px);
    gap: 14px;
    padding: 16px;
  }

  .survey-modal {
    height: calc(100dvh - 24px);
  }

  .survey-actions {
    display: grid;
  }

  .survey-submit {
    width: 100%;
  }

  .carousel-stage {
    grid-template-columns: 42px minmax(0, 1fr) 42px;
    gap: 10px;
  }

  .carousel-arrow {
    width: 42px;
    height: 42px;
  }

  .carousel-arrow span {
    font-size: 36px;
  }

  .carousel-image-wrap {
    --image-padding: 10px;
    height: min(58vh, 480px);
    min-height: 220px;
  }

  .survey-panel {
    min-height: 0;
  }
}
