@import url("https://fonts.googleapis.com/css2?family=Caveat+Brush&display=swap");

:root {
  --bg: #2a1d34;
  --panel: rgba(73, 43, 89, 0.78);
  --panel-solid: #5f426f;
  --text: #fff8f6;
  --accent: #ffd487;
  --accent-strong: #ffac73;
  --border: rgba(255, 243, 247, 0.22);
  --shadow: 0 18px 48px rgba(48, 22, 47, 0.34);
  --safe-top: max(1rem, env(safe-area-inset-top));
  --safe-right: max(1rem, env(safe-area-inset-right));
  --safe-bottom: max(1rem, env(safe-area-inset-bottom));
  --safe-left: max(1rem, env(safe-area-inset-left));
  --touch-target: 44px;
  --shell-gap: clamp(0.85rem, 2.2vw, 1.4rem);
  --card-radius: clamp(20px, 3vw, 28px);
  --cat-size: clamp(132px, 17vw, 198px);
  --home-side-cat-size: clamp(150px, 16vw, 230px);
  --home-side-cat-right:.65rem;
  --home-side-cat-bottom: 0.8rem;
  --home-thought-right: 62%;
  --home-thought-bottom: 65%;
  --home-side-cat-size-iphone: clamp(260px, 13.8vw, 135px);
  --home-side-cat-right-iphone: .35rem;
  --home-side-cat-bottom-iphone: -4rem;
  --home-thought-width-iphone: min(24vw, 9rem);
  --home-thought-font-iphone: 0.66rem;
  --home-thought-right-iphone: 70%;
  --home-thought-bottom-iphone: 62%;
  --remote-hotspot-dot-size-iphone: 1.95rem;
  --remote-hotspot-dot-inner-inset-iphone: 0.34rem;
  --kitchen-hotspot-pasta-top-iphone: -15%;
  --kitchen-hotspot-pasta-left-iphone: 60%;
  --kitchen-hotspot-pasta-width-iphone: 33%;
  --kitchen-hotspot-sauce-top-iphone: 15%;
  --kitchen-hotspot-sauce-left-iphone: 46%;
  --kitchen-hotspot-sauce-width-iphone: 9%;
  --kitchen-hotspot-cheese-top-iphone: 19%;
  --kitchen-hotspot-cheese-left-iphone: 213%;
  --kitchen-hotspot-cheese-width-iphone: 19%;
  --kitchen-hotspot-garlic-top-iphone: 15%;
  --kitchen-hotspot-garlic-left-iphone: 153%;
  --kitchen-hotspot-garlic-width-iphone: 14%;
  --kitchen-hotspot-sorry-bottom-iphone: 2%;
  --kitchen-hotspot-sorry-left-iphone: 102%;
  --kitchen-hotspot-sorry-width-iphone: 24%;
  --kitchen-hotspot-cheese-joke-bottom-iphone: 65%;
  --kitchen-hotspot-cheese-joke-left-iphone: 195%;
  --kitchen-hotspot-cheese-joke-width-iphone: 25%;
  --kitchen-hotspot-mix-bottom-iphone: -34%;
  --kitchen-hotspot-mix-right-iphone: -70%;
  --kitchen-hotspot-mix-width-iphone: 35%;
  --kitchen-hotspot-spill-left-iphone: 113%;
  --kitchen-hotspot-spill-bottom-iphone: 19%;
  --kitchen-hotspot-sponge-left-iphone: 135%;
  --kitchen-hotspot-sponge-bottom-iphone: 32%;
  --kitchen-hotspot-sponge-width-iphone: 19%;
  --kitchen-spill-zone-left-iphone: 50%;
  --kitchen-spill-zone-bottom-iphone: 10%;
  --kitchen-spill-zone-width-iphone: 54%;
  --kitchen-spill-spot-one-top-iphone: 14%;
  --kitchen-spill-spot-one-left-iphone: 10%;
  --kitchen-spill-spot-two-top-iphone: 4%;
  --kitchen-spill-spot-two-left-iphone: 39%;
  --kitchen-spill-spot-three-top-iphone: 36%;
  --kitchen-spill-spot-three-left-iphone: 58%;
  --remote-hotspot-bookshelf-top-iphone: 1%;
  --remote-hotspot-bookshelf-left-iphone: 3%;
  --remote-hotspot-blanket-top-iphone: 60%;
  --remote-hotspot-blanket-left-iphone: 40%;
  --remote-hotspot-wall-art-top-iphone: -68%;
  --remote-hotspot-wall-art-left-iphone: 110%;
  --remote-hotspot-lamp-top-iphone: 40%;
  --remote-hotspot-lamp-left-iphone: 215%;
  --remote-hotspot-rug-left-iphone: 152%;
  --remote-hotspot-rug-bottom-iphone: -10%;
  --remote-hotspot-cat-bed-left-iphone: 7%;
  --remote-hotspot-cat-bed-bottom-iphone: 15%;
  --remote-hotspot-table-top-iphone: 58%;
  --remote-hotspot-table-left-iphone: 105%;
  --remote-hotspot-couch-top-iphone: 11%;
  --remote-hotspot-couch-left-iphone: 109%;
  --remote-hotspot-bed-right-iphone: 9%;
  --remote-hotspot-bed-bottom-iphone: 9%;
  --remote-story-cat-size: clamp(210px, 10vw, 205px);
  --remote-story-cat-left: -2rem;
  --remote-story-cat-bottom: -7rem;
  --remote-story-cat-size-iphone: clamp(210px, 10vw, 205px);
  --remote-story-cat-left-iphone: -12rem;
  --remote-story-cat-bottom-iphone: -15rem;
  --remote-hud-cat-size: clamp(95px, 10vw, 175px);
  --remote-hud-cat-left: 1rem;
  --remote-hud-cat-bottom: 4.5rem;
  --remote-hud-cat-size-iphone: clamp(195px, 10vw, 175px);
  --remote-hud-cat-left-iphone: 1rem;
  --remote-hud-cat-bottom-iphone: -1rem;
  --login-story-cat-size: clamp(110px, 15vw, 210px);
  --login-story-cat-left: -1.6rem;
  --login-story-cat-bottom: -7.5rem;
  --login-story-cat-size-iphone: clamp(110px, 15vw, 210px);
  --login-story-cat-left-iphone: -1.6rem;
  --login-story-cat-bottom-iphone: -7.5rem;
  --movie-cat-size: clamp(100px, 10vw, 185px);
  --movie-cat-left: -1.4rem;
  --movie-cat-bottom: -6.8rem;
  --movie-cat-size-iphone: clamp(200px, 10vw, 185px);
  --movie-cat-left-iphone: -3rem;
  --movie-cat-bottom-iphone: -6.8rem;
  --kitchen-story-stage-padding-bottom-iphone: 4.2rem;
  --kitchen-story-cat-size: clamp(230px, 20vw, 250px);
  --kitchen-story-cat-left: -11rem;
  --kitchen-story-cat-bottom: 28rem;
  --kitchen-story-cat-size-iphone: clamp(250px, 20vw, 250px);
  --kitchen-story-cat-left-iphone: -11rem;
  --kitchen-story-cat-bottom-iphone: -19rem;
  --kitchen-hud-cat-size: clamp(290px, 9vw, 150px);
  --kitchen-hud-cat-left: 0.75rem;
  --kitchen-hud-cat-bottom: -3rem;
  --kitchen-hud-cat-size-iphone: clamp(265px, 9vw, 150px);
  --kitchen-hud-cat-left-iphone: 30rem;
  --kitchen-hud-cat-bottom-iphone: -8rem;
  --ending-cat-apology-size: clamp(130px, 17vw, 220px);
  --ending-cat-apology-x: 0px;
  --ending-cat-apology-y: 86px;
  --ending-cat-apology-size-iphone: clamp(130px, 17vw, 220px);
  --ending-cat-apology-x-iphone: 0px;
  --ending-cat-apology-y-iphone: 135px;
  --ending-cat-sleep-size: clamp(130px, 17vw, 220px);
  --ending-cat-sleep-x: 3px;
  --ending-cat-sleep-y: 128px;
  --ending-cat-sleep-scale: 1.04;
  --ending-cat-sleep-size-iphone: clamp(130px, 17vw, 220px);
  --ending-cat-sleep-x-iphone: 20px;
  --ending-cat-sleep-y-iphone: 120px;
  --ending-cat-sleep-scale-iphone: 1.04;
}

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: "Caveat Brush", "Trebuchet MS", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top, rgba(255, 191, 164, 0.25), transparent 34%),
    radial-gradient(circle at bottom right, rgba(173, 130, 255, 0.16), transparent 28%),
    linear-gradient(180deg, #33213d 0%, #5d4266 100%);
  color: var(--text);
  overflow: auto;
}

button {
  font: inherit;
  min-height: var(--touch-target);
  min-width: var(--touch-target);
  touch-action: manipulation;
}

.app-shell {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: var(--safe-top) var(--safe-right) var(--safe-bottom) var(--safe-left);
}

.top-bar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--shell-gap);
  padding: 0 0 0.25rem;
}

.game-title {
  margin: 0;
  font-size: clamp(1.5rem, 2vw, 2rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.top-bar-spacer {
  width: 5.5rem;
}

.ghost-button,
.scene-actions button,
.phone-close,
.phone-back {
  padding: 0.82rem 1rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  cursor: pointer;
  transition: transform 140ms ease, background 140ms ease;
}

.ghost-button:hover,
.scene-actions button:hover,
.settings-card button:hover,
.settings-button:hover {
  transform: translateY(-1px);
}

.ghost-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.scene-root {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 0.15rem 0 calc(var(--safe-bottom) + 4.65rem);
  min-height: 0;
  overflow: hidden;
  width: 100%;
}

.scene-card {
  position: relative;
  width: min(100%, 1100px);
  min-height: min(78dvh, 820px);
  max-height: calc(100dvh - var(--safe-top) - var(--safe-bottom) - 0.8rem);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: var(--shell-gap);
  padding: clamp(0.95rem, 2vw, 1.5rem);
  border: 1px solid var(--border);
  border-radius: var(--card-radius);
  background-color: #6d4c70;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  box-shadow: var(--shadow);
  overflow: auto;
}

.kitchen-scene {
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.25rem;
}

.login-scene {
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.25rem;
}

.kitchen-scene-story {
  justify-content: center;
}

.login-scene-story {
  justify-content: center;
}

.kitchen-scene-gameplay {
  justify-content: space-between;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  overflow: hidden;
}

.login-scene-gameplay {
  justify-content: space-between;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  overflow: hidden;
}

.scene-overlay {
  max-width: 36rem;
  padding: 1.25rem;
  border-radius: 24px;
  background: var(--panel);
  backdrop-filter: blur(8px);
}

.scene-overlay h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(2rem, 4vw, 3rem);
}

.scene-overlay p {
  margin: 0;
  line-height: 1.5;
}

.home-scene {
  justify-content: center;
}

.home-overlay {
  width: min(100%, 41rem);
  display: grid;
  gap: 0.8rem;
}

.home-side-cat {
  position: absolute;
  right: var(--home-side-cat-right);
  bottom: var(--home-side-cat-bottom);
  z-index: 3;
  pointer-events: auto;
}

.home-side-cat-trigger {
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: 14px;
  cursor: pointer;
  min-width: 0;
  min-height: 0;
  line-height: 0;
  transition: transform 180ms ease, filter 180ms ease;
}

.home-side-cat-trigger:hover {
  transform: translateY(-2px) scale(1.02);
  filter: saturate(1.06);
}

.home-side-cat-trigger:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.85);
  outline-offset: 4px;
}

.home-side-cat-image {
  width: var(--home-side-cat-size);
  max-width: 100%;
  height: auto;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 16px 22px rgba(39, 18, 44, 0.22));
  transition: opacity 150ms ease, transform 220ms ease;
}

.home-cat-bounce .home-side-cat-image {
  animation: home-cat-click-bounce 220ms ease;
}

@keyframes home-cat-click-bounce {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  45% {
    transform: scale(1.05) rotate(-1.2deg);
    opacity: 0.94;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.home-thought-bubble {
  position: absolute;
  right: var(--home-thought-right);
  bottom: var(--home-thought-bottom);
  margin: 0;
  width: min(42vw, 14rem);
  padding: 0.55rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #3c2f52;
  font-size: 0.82rem;
  line-height: 1.35;
  text-align: center;
  transition: transform 180ms ease, opacity 180ms ease;
}

.home-side-cat-trigger:hover + .home-thought-bubble {
  transform: translateY(-1px);
}

.scene-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1rem;
}

.kitchen-hud {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: -0.85rem;
}

.kitchen-mode-pill {
  min-width: 0;
  max-width: 12.5rem;
  padding: 0.58rem 0.72rem;
  border-radius: 16px;
}

.kitchen-mode-pill p:last-child {
  margin-top: 0.12rem;
  font-size: 0.84rem;
}

.story-stage,
.cookbook-stage {
  display: grid;
  gap: var(--shell-gap);
  width: min(100%, 46rem);
  margin: auto;
  min-width: 0;
}

.story-characters {
  display: flex;
  justify-content: flex-end;
  align-items: end;
  gap: 1rem;
  min-height: 12rem;
}

.story-characters .owner-standin,
.story-characters .kitchen-owner-standin {
  display: none;
}

.story-cat-art {
  width: var(--cat-size);
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 18px 24px rgba(39, 18, 44, 0.22));
}

.story-dialogue-box {
  width: min(100%, 42rem);
  min-height: 8.4rem;
  padding: 1.15rem 1.2rem;
  border-radius: 26px;
  background: rgba(255, 248, 246, 0.14);
  border-color: rgba(255, 235, 229, 0.3);
  box-shadow:
    0 18px 40px rgba(42, 17, 44, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.26);
}

.story-dialogue-box .dialogue-speaker {
  margin-bottom: 0.45rem;
  font-size: 0.92rem;
  letter-spacing: 0.03em;
  text-transform: none;
}

.story-dialogue-box .dialogue-text {
  font-size: clamp(1.05rem, 2vw, 1.18rem);
  line-height: 1.68;
}

.story-dialogue-box .dialogue-controls {
  justify-content: flex-start;
}

.story-dialogue-box .dialogue-controls button {
  min-width: 7.5rem;
  padding: 0.85rem 1.05rem;
  background: rgba(255, 250, 248, 0.14);
}

.cookbook-panel,
.gameplay-banner {
  border: 1px solid var(--border);
  background: rgba(83, 49, 95, 0.76);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.cookbook-panel {
  border-radius: 24px;
  padding: 1.2rem;
}

.cookbook-page h2 {
  margin: 0.2rem 0 0.8rem;
}

.cookbook-page p {
  margin: 0 0 0.55rem;
  line-height: 1.6;
}

.cookbook-options {
  display: grid;
  gap: 0.9rem;
  margin-top: 1rem;
}

.cookbook-options button,
.cookbook-page .dialogue-controls button {
  padding: 0.95rem 1rem;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.cookbook-kicker {
  margin: 0.18rem 0 0.1rem;
  color: rgba(255, 244, 218, 0.9);
  font-size: 0.92rem;
}

.cookbook-choice-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.cookbook-choice-card {
  min-height: 13rem;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.7rem;
  padding: 0.72rem;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.08));
  border: 1px solid rgba(255, 245, 236, 0.34);
  box-shadow: 0 14px 28px rgba(36, 15, 48, 0.22);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.cookbook-choice-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 32px rgba(36, 15, 48, 0.28);
  border-color: rgba(255, 255, 255, 0.5);
}

.cookbook-choice-card:focus-visible {
  outline: 2px solid rgba(255, 235, 199, 0.95);
  outline-offset: 2px;
}

.cookbook-choice-image-wrap {
  display: grid;
  place-items: center;
  min-height: 5rem;
  padding: 0.5rem;
  border-radius: 14px;
  background: rgba(255, 250, 244, 0.22);
}

.cookbook-choice-image-wrap img {
  width: 100%;
  max-width: 8.5rem;
  max-height: 5.2rem;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(36, 15, 48, 0.22));
}

.cookbook-choice-copy {
  display: grid;
  gap: 0.22rem;
}

.cookbook-choice-title {
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.2;
}

.cookbook-choice-subtitle {
  font-size: 0.8rem;
  color: rgba(255, 245, 227, 0.9);
}

.cookbook-choice-note {
  font-size: 0.76rem;
  color: rgba(248, 238, 228, 0.85);
  line-height: 1.35;
}

.cookbook-choice-water .cookbook-choice-image-wrap {
  background: rgba(197, 233, 255, 0.26);
}

.cookbook-choice-spaghetti .cookbook-choice-image-wrap {
  background: rgba(255, 221, 182, 0.24);
}

.cookbook-recipe-hero {
  margin: 0.25rem 0 0.7rem;
  padding: 0.68rem;
  border-radius: 15px;
  border: 1px solid rgba(255, 236, 211, 0.32);
  background: rgba(255, 240, 223, 0.16);
  display: grid;
  place-items: center;
}

.cookbook-recipe-hero img {
  width: min(100%, 12rem);
  max-height: 6rem;
  object-fit: contain;
  filter: drop-shadow(0 9px 14px rgba(36, 15, 48, 0.24));
}

@media (max-width: 780px) {
  .cookbook-choice-grid {
    grid-template-columns: 1fr;
  }

  .cookbook-choice-card {
    min-height: 11.2rem;
  }
}

.cookbook-ingredients ul {
  margin: 0.45rem 0 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.4rem;
}

.gameplay-banner {
  padding: 1rem 1.05rem;
  border-radius: 20px;
}

.gameplay-banner p:last-child {
  margin: 0.25rem 0 0;
}

.ingredient-panel,
.dialogue-box,
.spill-status {
  border: 1px solid var(--border);
  background: rgba(76, 43, 87, 0.8);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.ingredient-panel {
  min-width: 15rem;
  padding: 1rem 1.15rem;
  border-radius: 20px;
}

.ingredient-panel ul {
  margin: 0.7rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.5rem;
}

.panel-label {
  margin: 0;
  color: var(--accent);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cat-status img {
  width: var(--cat-size);
  height: auto;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 18px 24px rgba(39, 18, 44, 0.22));
}

.kitchen-playfield {
  position: relative;
  flex: 1;
  min-height: 18rem;
  min-width: 0;
  height: 100%;
  overflow: visible;
  z-index: 2;
}

.remote-playfield {
  position: relative;
  flex: 1;
  min-height: 18rem;
  min-width: 0;
}

.remote-playfield .hotspot-dot {
  width: 2.15rem;
  height: 2.15rem;
  max-width: none;
  padding: 0;
}

.remote-playfield .hotspot-dot-inner {
  inset: 0.38rem;
}

.movie-grid-panel {
  display: grid;
  flex: none;
  width: min(86vw, 38rem);
  max-width: 38rem;
  margin: auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-content: center;
  justify-content: center;
  padding-top: 0;
  align-self: center;
  justify-self: center;
}

.movie-select-header {
  text-align: center;
}

.movie-select-header p {
  margin: 0.2rem 0 0;
}

.ending-scene {
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem;
}

.ending-stage {
  display: flex;
  flex: 1;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 3rem;
}

.ending-characters {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.owner-standin {
  min-height: 12rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(76, 43, 87, 0.5);
  color: rgba(245, 247, 251, 0.9);
  box-shadow: var(--shadow);
}

.ending-cat {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 18px 24px rgba(39, 18, 44, 0.24));
  transition: transform 240ms ease;
}

.ending-cat-apology {
  width: var(--ending-cat-apology-size);
  transform: translate(var(--ending-cat-apology-x), var(--ending-cat-apology-y));
}

.ending-cat-sleeping {
  width: var(--ending-cat-sleep-size);
  transform: translate(var(--ending-cat-sleep-x), var(--ending-cat-sleep-y)) scale(var(--ending-cat-sleep-scale));
}

.ending-fade-panel {
  padding: 1.15rem;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(76, 43, 87, 0.74);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}

.ending-fade-panel-complete {
  background: rgba(76, 43, 87, 0.82);
}

.ending-card-text {
  margin: 0;
  text-align: center;
  font-size: clamp(1.15rem, 2.4vw, 1.45rem);
  line-height: 1.6;
}

.credits-block {
  text-align: center;
}

.credits-block h2 {
  margin: 0 0 1rem;
}

.credits-block p {
  margin: 0 0 1rem;
  line-height: 1.6;
}

.login-hud,
.remote-hud {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.remote-mode-pill {
  min-width: 0;
  padding: 0.8rem 0.95rem;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(76, 43, 87, 0.72);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.remote-mode-pill p {
  margin: 0;
}

.remote-mode-pill p:last-child {
  margin-top: 0.2rem;
  font-size: 0.92rem;
}

.hotspot {
  position: absolute;
  max-width: min(34vw, 180px);
  padding: 0.82rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 16px;
  background: rgba(76, 43, 87, 0.76);
  color: var(--text);
  cursor: pointer;
  white-space: normal;
  line-height: 1.2;
  text-align: center;
  box-shadow: 0 14px 28px rgba(46, 23, 48, 0.24);
}

.hotspot:hover {
  background: rgba(255, 212, 135, 0.18);
}

.hotspot-dot {
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.46);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  box-shadow:
    0 12px 28px rgba(56, 31, 61, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.hotspot-dot:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: scale(1.04);
}

.hotspot-dot-inner {
  position: absolute;
  inset: 0.42rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.56);
}

.hotspot-kitchen-art {
  max-width: none;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.hotspot-kitchen-art:hover {
  background: transparent;
  transform: translateY(-1px);
}

.hotspot-kitchen-image {
  display: block;
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 16px rgba(61, 30, 55, 0.22));
}

.spill-zone {
  position: absolute;
  left: 95%;
  bottom: 8%;
  width: 42%;
  max-width: 24rem;
  pointer-events: auto;
  z-index: 4;
  transform: translateX(-50%);
}

.spill-image {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 12px 18px rgba(46, 23, 48, 0.22));
  transition: opacity 120ms ease;
}

.spill-spot {
  position: absolute;
  width: 20%;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.45),
    0 10px 18px rgba(46, 23, 48, 0.18);
  cursor: pointer;
}

.spill-spot:hover {
  background: rgba(255, 255, 255, 0.24);
}

.spill-spot-one { top: 14%; left: 10%; }
.spill-spot-two { top: 2%; left: 39%; }
.spill-spot-three { top: 34%; left: 58%; }

.hotspot-dot-alert {
  border-color: rgba(255, 99, 99, 0.72);
  background: rgba(255, 115, 115, 0.28);
}

.hotspot-dot-alert .hotspot-dot-inner {
  background: rgba(255, 94, 94, 0.82);
}

.hotspot-pasta { top: 25%; left: 57%; width: 26.5%; }
.hotspot-sauce { top: 42%; left: 35%; width: 12%; }
.hotspot-cheese { top: 39%; left: 152%; width: 12.5%; }
.hotspot-garlic { top: 45%; left: 120%; width: -12%; }
.hotspot-sorry { bottom: 15%; left: 80%; width: 15%; }
.hotspot-cheese-joke { bottom: 20%; left: 162%; width: 25%; }
.hotspot-mix { bottom: -39%; right: -35%; width: 30%; }
.hotspot-spill { bottom: 8%; left: 42%; min-width: 9rem; }
.hotspot-sponge { bottom: 8%; left: 115%; width: 18%; z-index: 5; touch-action: none; }
.hotspot-mix { z-index: 5; }
.hotspot-bookshelf { top: 36%; left: -1%; }
.hotspot-blanket { top: 63%; left: 45%; }
.hotspot-wall-art { top: -25%; left: 85%; }
.hotspot-lamp { top: 39%; left: 152%; }
.hotspot-rug { bottom: 5%; left: 125%; }
.hotspot-cat-bed { bottom: -1%; left: 7%; }
.hotspot-table { top: 63%; left: 85%; }
.hotspot-remote { bottom: 8%; padding-inline: 1rem; background: rgba(255, 209, 102, 0.22); }
.hotspot-remote-couch { top: 30%; left: 93%; }
.hotspot-remote-bed { right: 16%; }

.remote-placeholder {
  position: absolute;
  top: 54%;
  left: 35%;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 243, 247, 0.22);
  background: rgba(76, 43, 87, 0.82);
  color: var(--text);
  font-size: 0.78rem;
  box-shadow: var(--shadow);
}

.remote-placeholder-image {
  position: absolute;
  top: 50%;
  left: 62%;
  width: 4rem;
  height: auto;
  filter: drop-shadow(0 12px 18px rgba(46, 23, 48, 0.26));
}

.sponge-ready {
  outline: 2px solid var(--accent);
}

.sponge-dragging {
  cursor: grabbing;
  filter: drop-shadow(0 18px 24px rgba(61, 30, 55, 0.28));
}

.spill-status {
  position: absolute;
  left: 50%;
  bottom: 5.75rem;
  transform: translateX(-50%);
  padding: 0.8rem 1rem;
  border-radius: 999px;
  font-size: 0.95rem;
  width: min(90%, 26rem);
  text-align: center;
}

.spill-status-top {
  top: 0.5rem;
  bottom: auto;
  width: min(88%, 22rem);
}

.dialogue-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(92%, 44rem);
  padding: 1rem 1.1rem;
  border-radius: 22px;
  margin-top: auto;
  margin-inline: auto;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}

.kitchen-scene-gameplay .dialogue-box {
  padding: 0.72rem 0.55rem 0.72rem 0.9rem;
  border-radius: 18px;
  z-index: 14;
}

.kitchen-scene-gameplay .spill-status {
  z-index: 13;
}

.kitchen-scene-gameplay .spill-status-top {
  left: auto;
  right: max(5rem, env(safe-area-inset-right));
  transform: none;
  width: min(36vw, 16rem);
  max-width: calc(100% - 1.5rem);
}

.kitchen-scene.kitchen-spill-active .spill-zone {
  z-index: 11;
}

.kitchen-scene.kitchen-spill-active .hotspot-sponge {
  z-index: 12;
  pointer-events: auto;
}

.kitchen-scene.kitchen-spill-active .hotspot-kitchen-art:not(.hotspot-sponge) {
  pointer-events: none;
  z-index: 3;
}

.kitchen-scene-gameplay .dialogue-text {
  font-size: 0.97rem;
  line-height: 1.45;
}

.kitchen-scene-gameplay .dialogue-controls {
  gap: 0.45rem;
  flex: 0 0 auto;
  justify-content: flex-end;
  align-self: center;
}

.kitchen-scene-gameplay .dialogue-controls button {
  padding: 0.68rem 0.74rem;
}

.remote-playfield + .dialogue-box {
  padding: 0.9rem 1rem;
}

.dialogue-box > div:first-child {
  min-width: 0;
  flex: 1;
}

.dialogue-speaker {
  margin: 0 0 0.35rem;
  color: var(--accent);
  font-weight: 700;
  text-transform: none;
  letter-spacing: 0.02em;
  font-size: 0.92rem;
}

.dialogue-text {
  margin: 0;
  line-height: 1.68;
  font-size: clamp(1.03rem, 1.85vw, 1.12rem);
  overflow-wrap: anywhere;
}

.dialogue-text em {
  font-style: italic;
  color: #ffdca5;
  letter-spacing: 0.01em;
}

.dialogue-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.8rem;
}

.dialogue-controls button {
  padding: 0.82rem 1rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 249, 246, 0.12);
  color: var(--text);
  cursor: pointer;
}

.kitchen-scene,
.remote-scene,
.login-scene,
.movie-select-scene {
  position: relative;
}

/* Kitchen story cat */
.kitchen-scene .story-stage {
  position: relative;
  padding-bottom: 8rem;
}

.kitchen-scene .story-characters {
  position: absolute;
  left: var(--kitchen-story-cat-left);
  bottom: var(--kitchen-story-cat-bottom);
  display: flex;
  justify-content: flex-start;
  min-height: 0;
  z-index: 2;
}

.kitchen-scene .story-cat-art {
  width: var(--kitchen-story-cat-size);
}

/* Kitchen gameplay cat */
.kitchen-scene .kitchen-hud .cat-status {
  position: absolute;
  left: var(--kitchen-hud-cat-left);
  bottom: var(--kitchen-hud-cat-bottom);
  z-index: 2;
  pointer-events: none;
}

.kitchen-scene .kitchen-hud .cat-status img {
  width: var(--kitchen-hud-cat-size);
}

/* Remote story + gameplay cats */
.remote-scene .story-stage {
  position: relative;
  padding-bottom: 8rem;
}

.remote-scene .story-characters {
  position: absolute;
  left: var(--remote-story-cat-left);
  bottom: var(--remote-story-cat-bottom);
  display: flex;
  justify-content: flex-start;
  min-height: 0;
  z-index: 2;
}

.remote-scene .story-cat-art {
  width: var(--remote-story-cat-size);
}

.remote-scene .remote-hud .cat-status {
  position: absolute;
  left: var(--remote-hud-cat-left);
  bottom: var(--remote-hud-cat-bottom);
  z-index: 2;
  pointer-events: none;
}

.remote-scene .remote-hud .cat-status img {
  width: var(--remote-hud-cat-size);
}

/* Login story cat */
.login-scene .story-stage {
  position: relative;
  padding-bottom: 8rem;
}

.login-scene .story-characters {
  position: absolute;
  left: var(--login-story-cat-left);
  bottom: var(--login-story-cat-bottom);
  display: flex;
  justify-content: flex-start;
  min-height: 0;
  z-index: 2;
}

.login-scene .story-cat-art {
  width: var(--login-story-cat-size);
}

/* Movie selection cat */
.movie-select-scene .movie-select-stage {
  position: relative;
  padding-bottom: 6.25rem;
}

.movie-select-scene .story-characters {
  position: absolute;
  left: var(--movie-cat-left);
  bottom: var(--movie-cat-bottom);
  display: flex;
  justify-content: flex-start;
  min-height: 0;
  z-index: 2;
}

.movie-select-scene .story-cat-art {
  width: var(--movie-cat-size);
}

.remote-scene .dialogue-box,
.login-scene .dialogue-box,
.movie-select-scene .dialogue-box {
  padding: 1.08rem 1.18rem;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 250, 247, 0.16), rgba(255, 243, 240, 0.06)),
    rgba(74, 42, 86, 0.82);
  border-color: rgba(255, 237, 229, 0.28);
  box-shadow:
    0 20px 46px rgba(39, 18, 44, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.login-scene-gameplay .dialogue-box {
  width: min(72%, 30rem);
  margin-left: 0;
  margin-right: auto;
}

.movie-select-scene .dialogue-box {
  width: min(72%, 30rem);
  margin-left: 0;
  margin-right: auto;
}

.ending-scene .dialogue-box {
  width: min(69%, 33rem);
  margin-left: 0;
  margin-right: auto;
}

.ending-scene-complete .dialogue-box {
  width: min(78%, 38rem);
}

.remote-scene .dialogue-text,
.login-scene .dialogue-text,
.movie-select-scene .dialogue-text {
  line-height: 1.68;
  font-size: clamp(1.03rem, 1.85vw, 1.12rem);
}

.remote-scene .story-dialogue-box,
.login-scene .story-dialogue-box {
  background:
    linear-gradient(180deg, rgba(255, 250, 247, 0.18), rgba(255, 245, 243, 0.08)),
    rgba(84, 48, 95, 0.72);
  border-color: rgba(255, 239, 233, 0.34);
  box-shadow:
    0 22px 48px rgba(42, 17, 44, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    inset 0 -1px 0 rgba(255, 255, 255, 0.08);
}

.tv-screen-panel,
.phone-panel {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(77, 44, 88, 0.8);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.login-stage .tv-screen-panel {
  width: 100%;
  align-self: center;
}

.login-scene-gameplay .login-stage {
  padding-top: 1.1rem;
}

.movie-select-stage .movie-grid-panel {
  align-self: center;
  justify-self: center;
}

.movie-select-stage {
  padding-top: 1.1rem;
}

.tv-helper {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.45;
}

.movie-card {
  min-height: 7.8rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 183, 140, 0.24), rgba(255, 255, 255, 0.06)),
    rgba(74, 45, 86, 0.84);
  color: var(--text);
  box-shadow: var(--shadow);
  font-size: clamp(1.4rem, 2.4vw, 2rem);
  font-weight: 700;
  cursor: pointer;
  line-height: 1.2;
}

.movie-card:hover {
  background:
    linear-gradient(180deg, rgba(255, 183, 140, 0.36), rgba(255, 255, 255, 0.08)),
    rgba(74, 45, 86, 0.9);
}

.movie-card-twilight {
  background:
    linear-gradient(180deg, rgba(192, 162, 255, 0.28), rgba(255, 255, 255, 0.06)),
    rgba(74, 45, 86, 0.84);
}

.tv-screen {
  width: min(100%, 28rem);
  margin: 0 auto;
  display: grid;
  gap: 0.8rem;
  padding: clamp(0.95rem, 2.4vw, 1.5rem);
  text-align: center;
}

.tv-brand {
  margin: 0;
  color: var(--accent);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.tv-screen h2 {
  margin: 0;
  font-size: clamp(1.6rem, 4vw, 2.35rem);
}

.tv-label {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.tv-password-input {
  width: 100%;
  padding: 0.82rem 0.95rem;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 245, 246, 0.1);
  color: var(--text);
  text-align: center;
  font: inherit;
}

.tv-username-input {
  color: rgba(255, 248, 246, 0.82);
  background: rgba(255, 245, 246, 0.06);
}

.tv-actions,
.phone-header,
.phone-body {
  display: flex;
}

.tv-actions {
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.tv-hint-button {
  background: rgba(188, 55, 72, 0.88) !important;
  border-color: rgba(255, 202, 210, 0.32) !important;
}

.tv-hint-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.tv-hint-tooltip {
  margin: -0.1rem auto 0;
  width: fit-content;
  max-width: 100%;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 231, 173, 0.14);
  border: 1px solid rgba(255, 220, 133, 0.24);
  color: #ffeab9;
  font-size: 0.82rem;
}

.tv-actions button,
.phone-header button,
.notes-sidebar button {
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  cursor: pointer;
}

.phone-panel {
  display: flex;
  flex-direction: column;
}

.phone-header {
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.05rem;
  border-bottom: 1px solid var(--border);
}

.phone-header p {
  margin: 0;
  color: var(--accent);
  font-weight: 700;
}

.phone-body {
  flex: 1;
  min-height: 20rem;
  height: 100%;
  min-width: 0;
}

.notes-sidebar {
  width: 13.5rem;
  display: grid;
  gap: 0.8rem;
  padding: 1rem;
  border-right: 1px solid var(--border);
}

.note-detail {
  flex: 1;
  padding: 1.15rem;
  overflow: auto;
  min-height: 0;
  min-width: 0;
}

.note-detail h3 {
  margin: 0 0 0.9rem;
}

.note-listing {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.75rem;
  line-height: 1.5;
}

.password-note-scroll {
  max-height: min(48svh, 22rem);
  overflow: auto;
  padding-right: 0.55rem;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.password-note-scroll p {
  margin: 0 0 0.7rem;
  line-height: 1.45;
}

.settings-button {
  position: fixed;
  right: var(--safe-right);
  bottom: var(--safe-bottom);
  z-index: 30;
  width: 4.9rem;
  height: 5.9rem;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: var(--shadow);
  cursor: pointer;
}

.phone-launcher-body {
  width: 100%;
  height: 100%;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 0.2rem;
  padding: 0.35rem 0.25rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 1.45rem;
  background: linear-gradient(180deg, rgba(255, 238, 244, 0.96), rgba(252, 203, 219, 0.94));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.72),
    0 16px 28px rgba(61, 30, 55, 0.28);
}

.phone-launcher-icon {
  width: 3.2rem;
  height: 3.9rem;
  object-fit: contain;
  filter: drop-shadow(0 8px 10px rgba(61, 30, 55, 0.12));
}

.phone-launcher-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #5b4057;
}

.settings-panel {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: var(--safe-top) var(--safe-right) var(--safe-bottom) var(--safe-left);
  background: rgba(34, 18, 40, 0.68);
}

.phone-popup {
  position: relative;
  z-index: 41;
  width: min(96vw, 28rem);
  height: min(92svh, 52rem);
  display: grid;
  place-items: center;
}

.phone-shell {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 0.55rem;
  padding: 0.55rem 0.7rem 0.8rem;
  border: 3px solid rgba(255, 255, 255, 0.08);
  border-radius: 2.2rem;
  background:
    linear-gradient(160deg, rgba(44, 54, 74, 0.98), rgba(8, 12, 20, 0.98));
  box-shadow:
    0 22px 50px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.phone-notch {
  justify-self: center;
  width: 7.2rem;
  height: 1.05rem;
  border-radius: 999px;
  background: rgba(3, 6, 12, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.phone-statusbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.4rem;
  font-size: 0.78rem;
  color: rgba(245, 247, 251, 0.92);
}

.phone-status-time {
  font-weight: 700;
  letter-spacing: 0.03em;
}

.phone-status-icons {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.status-signal {
  width: 0.95rem;
  height: 0.7rem;
  display: inline-block;
  background:
    linear-gradient(to top, rgba(245, 247, 251, 0.92) 0 100%) left bottom/2px 25% no-repeat,
    linear-gradient(to top, rgba(245, 247, 251, 0.92) 0 100%) center bottom/2px 55% no-repeat,
    linear-gradient(to top, rgba(245, 247, 251, 0.92) 0 100%) right bottom/2px 100% no-repeat;
}

.status-battery {
  position: relative;
  width: 1.55rem;
  height: 0.75rem;
  border: 1.8px solid rgba(245, 247, 251, 0.92);
  border-radius: 0.22rem;
}

.status-battery::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 0.12rem;
  background: rgba(134, 243, 170, 0.95);
}

.status-battery::after {
  content: "";
  position: absolute;
  right: -0.22rem;
  top: 0.16rem;
  width: 0.14rem;
  height: 0.32rem;
  border-radius: 0 0.12rem 0.12rem 0;
  background: rgba(245, 247, 251, 0.92);
}

.phone-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.25rem 0.15rem 0;
}

.phone-topbar h2 {
  margin: 0;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  text-transform: none;
}

.phone-back,
.phone-close {
  min-width: 3.9rem;
  padding: 0.62rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(245, 247, 251, 0.95);
  cursor: pointer;
}

.phone-screen {
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.65rem;
  padding: 0.2rem 0.1rem 0;
  border-radius: 1.65rem;
  background:
    linear-gradient(180deg, rgba(229, 234, 243, 0.95), rgba(201, 211, 228, 0.92));
  overflow: hidden;
}

.phone-view {
  min-height: 0;
  height: 100%;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 0 0.55rem 0.35rem;
}

.phone-home-header {
  padding: 0.4rem 0.2rem 0.85rem;
}

.phone-home-greeting,
.phone-home-subtitle {
  margin: 0;
}

.phone-home-greeting {
  font-size: 1.08rem;
  font-weight: 800;
  color: #102036;
}

.phone-home-subtitle {
  margin-top: 0.25rem;
  font-size: 0.78rem;
  color: #4f627c;
}

.phone-app-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-content: start;
}

.phone-app-button {
  min-height: 7.9rem;
  display: grid;
  place-items: center;
  gap: 0.5rem;
  padding: 1.1rem 0.88rem;
  border: 0;
  border-radius: 1.3rem;
  background: transparent;
  color: #102036;
  cursor: pointer;
  text-align: center;
}

.phone-app-icon {
  display: grid;
  place-items: center;
  width: 4.35rem;
  height: 4.35rem;
  border-radius: 1rem;
  font-size: 1.6rem;
  font-weight: 700;
  color: #102036;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.65),
    0 10px 20px rgba(37, 48, 77, 0.18);
}

.phone-app-label {
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.2;
  color: #102036;
}

.phone-app-resume .phone-app-icon {
  background: linear-gradient(180deg, #ffd5dd, #ffb8c7);
}

.phone-app-home .phone-app-icon {
  background: linear-gradient(180deg, #c9f5ff, #9ce3ff);
}

.phone-app-music .phone-app-icon {
  background: linear-gradient(180deg, #c8f6d4, #94e9a8);
}

.phone-app-reset .phone-app-icon {
  background: linear-gradient(180deg, #ffe0ad, #ffc970);
}

.phone-app-notes .phone-app-icon {
  background: linear-gradient(180deg, #fff2a8, #ffe06d);
}

.phone-app-playlist .phone-app-icon {
  background: linear-gradient(180deg, #d7d0ff, #b9afff);
}

.phone-app-webtoon .phone-app-icon {
  background: linear-gradient(180deg, #c8f0d7, #8edca8);
}

.notes-app-shell {
  height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.6rem;
}

.notes-app-header {
  padding: 0.2rem 0.25rem 0;
}

.notes-app-kicker {
  margin: 0;
  color: #846d00;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.notes-app-header h3 {
  margin: 0.18rem 0 0;
  font-size: 1.28rem;
  color: #3c2f00;
}

.notes-phone-body {
  flex: 1;
  height: 100%;
  min-width: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.8rem;
  border: 1px solid rgba(144, 118, 11, 0.16);
  border-radius: 1.5rem;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.45), transparent 28%),
    linear-gradient(180deg, #fff7cf, #f5e39d);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.75),
    0 10px 22px rgba(130, 107, 11, 0.1);
  padding: 0.95rem;
}

.notes-sidebar {
  display: grid;
  gap: 0.72rem;
  padding: 0;
  background: transparent;
  border-right: 0;
  overflow: auto;
}

.notes-sidebar button {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 0.72rem;
  padding: 0.98rem 1rem;
  border: 1px solid rgba(144, 118, 11, 0.12);
  border-radius: 1.1rem;
  background: rgba(255, 252, 244, 0.85);
  color: #4a3c05;
  text-align: left;
  box-shadow:
    0 10px 18px rgba(130, 107, 11, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.notes-sidebar button:hover {
  transform: translateY(-1px);
  box-shadow:
    0 12px 20px rgba(130, 107, 11, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.notes-note-active {
  background: linear-gradient(180deg, #fff9d8, #ffeaa0) !important;
  border-color: rgba(181, 146, 18, 0.3) !important;
  transform: translateY(-1px);
}

.notes-note-icon {
  width: 2.6rem;
  height: 2.6rem;
  display: grid;
  place-items: center;
  border-radius: 0.95rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 238, 184, 0.95));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 8px 12px rgba(130, 107, 11, 0.08);
  font-size: 1.15rem;
}

.notes-note-copy {
  min-width: 0;
  display: grid;
  gap: 0.22rem;
}

.notes-sidebar button strong {
  font-size: 0.95rem;
}

.notes-sidebar button span {
  font-size: 0.76rem;
  color: #766524;
}

.note-detail {
  padding: 0;
  overflow: auto;
  min-height: 0;
  min-width: 0;
  color: #3e3307;
}

.note-paper {
  min-height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  padding: 1.15rem 1.1rem 1.3rem;
  border-radius: 1.25rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 249, 0.98), rgba(255, 248, 219, 0.98));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.75),
    0 12px 22px rgba(130, 107, 11, 0.1);
  position: relative;
}

.note-paper::before {
  content: "";
  position: absolute;
  top: 1rem;
  bottom: 1rem;
  left: 1.1rem;
  width: 2px;
  background: rgba(227, 143, 152, 0.35);
  border-radius: 999px;
}

.note-paper::after {
  content: "";
  position: absolute;
  inset: 4.1rem 0 0;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent 1.75rem,
      rgba(120, 160, 214, 0.18) 1.75rem,
      rgba(120, 160, 214, 0.18) 1.83rem
    );
  pointer-events: none;
}

.note-paper-topper {
  position: relative;
  z-index: 1;
  margin-bottom: 0.75rem;
  padding: 0 0 0.4rem 1rem;
  border-bottom: 1px solid rgba(201, 176, 90, 0.25);
}

.note-paper-title {
  margin: 0;
  font-size: 1.06rem;
  color: #433204;
}

.note-paper-meta {
  margin: 0.18rem 0 0;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #91761c;
}

.note-paper-content {
  position: relative;
  z-index: 1;
  min-height: 0;
  padding: 0.1rem 0.25rem 0 1.35rem;
}

.note-listing {
  margin: 0;
  padding-left: 1.15rem;
  display: grid;
  gap: 0.92rem;
  line-height: 1.62;
}

.password-note-scroll {
  max-height: none;
  overflow: auto;
  padding-right: 0.5rem;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.password-note-scroll p {
  margin: 0 0 0.95rem;
  line-height: 1.6;
}

.note-paper-content-passwords .password-note-scroll p {
  padding: 0.12rem 0.45rem;
  border-radius: 0.7rem;
  background: rgba(255, 255, 255, 0.36);
}

.spotify-panel {
  height: 100%;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 0.9rem;
  padding: 1rem;
  border-radius: 1.35rem;
  background:
    radial-gradient(circle at top left, rgba(127, 255, 181, 0.16), transparent 28%),
    linear-gradient(180deg, #14281f 0%, #10241d 14%, #0f1518 100%);
  color: #f6fff9;
}

.spotify-playlist {
  margin: 0;
  padding: 0 0.1rem 0 0;
  display: grid;
  gap: 0.85rem;
  overflow: auto;
  min-height: 0;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.spotify-playlist-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.spotify-playlist-tab {
  min-height: 2.9rem;
  padding: 0.72rem 0.8rem;
  border: 1px solid rgba(111, 227, 142, 0.16);
  border-radius: 0.95rem;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(246, 255, 249, 0.84);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.spotify-playlist-tab-active {
  background: rgba(111, 227, 142, 0.18);
  border-color: rgba(111, 227, 142, 0.32);
  color: #f6fff9;
}

.spotify-embed-card {
  display: grid;
  gap: 0.7rem;
  padding: 0.9rem;
  border-radius: 1.15rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(111, 227, 142, 0.14);
}

.spotify-embed-card-active {
  border-color: rgba(111, 227, 142, 0.32);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.22);
}

.spotify-embed-shell {
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgba(111, 227, 142, 0.18);
  background: rgba(255, 255, 255, 0.04);
}

.spotify-embed-frame {
  display: block;
  border: 0;
  border-radius: 12px;
}

.spotify-open-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.7rem;
  padding: 0.7rem 0.9rem;
  border-radius: 0.95rem;
  background: rgba(111, 227, 142, 0.14);
  border: 1px solid rgba(111, 227, 142, 0.2);
  color: #ecfff1;
  text-decoration: none;
  font-weight: 700;
}

.spotify-open-link:hover,
.spotify-open-link:focus-visible {
  background: rgba(111, 227, 142, 0.2);
}

.webtoon-panel {
  height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0.9rem;
  padding: 1rem;
  border-radius: 1.35rem;
  background:
    radial-gradient(circle at top left, rgba(160, 255, 198, 0.16), transparent 28%),
    linear-gradient(180deg, #12221a 0%, #10241d 16%, #0e1613 100%);
  color: #f1fff5;
}

.webtoon-header h3 {
  margin: 0.18rem 0 0.28rem;
  font-size: 1.34rem;
}

.webtoon-header p:last-child {
  margin: 0;
  color: rgba(241, 255, 245, 0.78);
}

.webtoon-list {
  display: grid;
  gap: 0.85rem;
  align-content: start;
}

.webtoon-series-card {
  display: grid;
  gap: 0.32rem;
  padding: 1rem;
  border-radius: 1.05rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(143, 231, 172, 0.18);
  color: #effff3;
  text-decoration: none;
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.18);
}

.webtoon-series-card strong {
  font-size: 1.06rem;
}

.webtoon-series-card span:last-child {
  color: rgba(241, 255, 245, 0.78);
}

.webtoon-series-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: rgba(143, 231, 172, 0.14);
  color: #bbffd0;
  font-size: 0.67rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.webtoon-series-card:hover,
.webtoon-series-card:focus-visible {
  background: rgba(143, 231, 172, 0.22);
}

.phone-home-indicator {
  justify-self: center;
  width: 7rem;
  height: 0.34rem;
  border-radius: 999px;
  background: rgba(245, 247, 251, 0.3);
}

.orientation-overlay {
  position: fixed;
  inset: 0;
  z-index: 8;
  display: grid;
  place-items: center;
  padding: var(--safe-top) var(--safe-right) var(--safe-bottom) var(--safe-left);
  background: rgba(6, 10, 18, 0.96);
}

.viewport-debug {
  position: fixed;
  top: max(0.55rem, env(safe-area-inset-top));
  left: max(0.55rem, env(safe-area-inset-left));
  z-index: 9;
  margin: 0;
  padding: 0.45rem 0.55rem;
  border: 1px solid rgba(222, 239, 255, 0.38);
  border-radius: 0.6rem;
  background: rgba(6, 10, 18, 0.78);
  color: rgba(225, 243, 255, 0.98);
  font: 600 10px/1.28 "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
  white-space: pre;
  pointer-events: none;
  max-width: min(62vw, 18rem);
  backdrop-filter: blur(4px);
}

.orientation-card {
  width: min(100%, 24rem);
  display: grid;
  gap: 1rem;
  justify-items: center;
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(28, 44, 69, 0.98), rgba(11, 19, 33, 0.98));
  text-align: center;
  box-shadow: var(--shadow);
}

.orientation-card h2,
.orientation-card p {
  margin: 0;
}

.rotate-icon {
  position: relative;
  width: 5.5rem;
  height: 5.5rem;
}

.rotate-phone {
  position: absolute;
  inset: 0.8rem 1.35rem;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 0.9rem;
  transform: rotate(90deg);
}

.rotate-arrow {
  position: absolute;
  right: 0.2rem;
  top: 0.25rem;
  font-size: 1.9rem;
  color: var(--accent);
}

.hidden {
  display: none;
}

@media (max-width: 820px) {
  .top-bar {
    gap: 0.75rem;
  }

  .top-bar-spacer {
    width: 0.5rem;
  }

  .scene-card {
    min-height: 100%;
    max-height: none;
    border-radius: 24px;
    overflow: auto;
  }

  .kitchen-scene-gameplay,
  .login-scene-gameplay {
    max-height: calc(100svh - var(--safe-top) - var(--safe-bottom) - 6.25rem);
    overflow: hidden;
  }

  .kitchen-scene-gameplay {
    overflow: visible;
  }

  .kitchen-hud,
  .dialogue-box,
  .login-hud,
  .remote-hud {
    flex-direction: column;
    align-items: stretch;
  }

  .ingredient-panel {
    min-width: 0;
  }

  .kitchen-playfield {
    min-height: 18rem;
  }

  .remote-playfield {
    min-height: 18rem;
  }

  .remote-playfield .hotspot-dot {
    width: 1.95rem;
    height: 1.95rem;
  }

.remote-playfield .hotspot-dot-inner {
    inset: 0.34rem;
  }

  .scene-root {
    align-items: stretch;
    padding-bottom: calc(var(--safe-bottom) + 6rem);
  }

  .dialogue-box {
    padding: 1rem;
  }

  .kitchen-scene-gameplay .dialogue-box {
    padding: 0.65rem 0.45rem 0.65rem 0.8rem;
  }

  .dialogue-controls button,
  .ghost-button,
  .scene-actions button,
  .phone-app-button,
  .notes-sidebar button,
  .tv-actions button,
  .spotify-track-button {
    min-height: 48px;
  }

  .phone-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .movie-grid-panel {
    grid-template-columns: 1fr;
  }

  .story-characters {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .story-stage,
  .cookbook-stage {
    width: 100%;
  }

  .story-dialogue-box {
    min-height: 10rem;
  }

  .ending-characters {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .owner-standin {
    width: min(100%, 18rem);
    min-height: 7rem;
  }

  .notes-sidebar {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

.phone-popup {
    width: min(96vw, 23rem);
    height: min(90svh, 44rem);
  }

  .phone-body {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .hotspot {
    max-width: 36vw;
    font-size: 0.88rem;
  }

  .hotspot-pasta { top: 40%; left: 25%; width: 11%; }
  .hotspot-sauce { top: 39%; left: 16%; width: 10%; }
  .hotspot-cheese { top: 39%; left: 67%; width: 10%; }
  .hotspot-garlic { top: 39%; left: 21.5%; width: 9%; }
  .hotspot-sorry { bottom: 24%; left: 36%; width: 11%; }
  .hotspot-cheese-joke { bottom: 21%; left: 53%; width: 11%; }
  .hotspot-mix { bottom: 17%; right: 10%; width: 10%; }
  .hotspot-spill { left: 30%; bottom: 9%; }
  .hotspot-sponge { left: 62%; bottom: 8%; width: 19%; }
  .spill-zone { left: 50%; bottom: 10%; width: 54%; max-width: none; transform: translateX(-50%); }
  .spill-spot-one { top: 14%; left: 10%; }
  .spill-spot-two { top: 4%; left: 39%; }
  .spill-spot-three { top: 36%; left: 58%; }
  .kitchen-mode-pill {
    max-width: 100%;
  }
  .remote-mode-pill {
    order: 3;
  }

  .hotspot-bookshelf { top: 35%; left: 3%; }
  .hotspot-blanket { top: 63%; left: 20%; }
  .hotspot-wall-art { top: 8%; left: 49%; }
  .hotspot-lamp { top: 40%; left: 83%; }
  .hotspot-rug { left: 56%; bottom: 16%; }
  .hotspot-cat-bed { left: 7%; bottom: 1%; }
  .hotspot-table { top: 63%; left: 55%; }
  .hotspot-remote-couch { top: 11%; left: 49%; bottom: auto; }
  .hotspot-remote-bed { right: 9%; bottom: 9%; }

  .dialogue-controls {
    justify-content: flex-start;
  }
}

@media (min-width: 821px) and (max-width: 1180px) {
  .scene-card {
    width: 100%;
    min-height: min(82svh, 860px);
  }

  .phone-popup {
    width: min(96vw, 29rem);
  }
}

@media (orientation: landscape) and (pointer: coarse) and (max-height: 620px) {
  html,
  body {
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
  }

  .app-shell {
    height: 100svh;
    min-height: 100svh;
    padding: max(0.45rem, env(safe-area-inset-top)) max(0.6rem, env(safe-area-inset-right)) max(0.45rem, env(safe-area-inset-bottom)) max(0.6rem, env(safe-area-inset-left));
    overflow: hidden;
  }

  .top-bar {
    gap: 0.55rem;
    padding-bottom: 0.02rem;
  }

  .game-title {
    font-size: clamp(0.92rem, 2.4vw, 1.2rem);
    letter-spacing: 0.06em;
  }

  .ghost-button {
    padding: 0.44rem 0.62rem;
    min-height: 38px;
    min-width: 38px;
    font-size: 0.84rem;
  }

  .scene-root {
    align-items: stretch;
    height: 100%;
    padding: 0;
    overflow: hidden;
  }

  .scene-card {
    width: 100%;
    height: 100%;
    min-height: 0;
    max-height: none;
    border-radius: 18px;
    padding: 0.68rem;
    overflow: auto;
  }

  .settings-button {
    width: 3.9rem;
    height: 4.75rem;
    right: max(0.45rem, env(safe-area-inset-right));
    bottom: max(0.45rem, env(safe-area-inset-bottom));
  }

  .phone-launcher-icon {
    width: 2.55rem;
    height: 2.95rem;
  }

  .phone-launcher-label {
    font-size: 0.58rem;
  }

  .kitchen-scene-story,
  .login-scene-story {
    justify-content: flex-start;
    overflow: auto;
  }

  .kitchen-scene .story-stage {
    padding-bottom: var(--kitchen-story-stage-padding-bottom-iphone);
  }

  .kitchen-scene .story-characters {
    left: var(--kitchen-story-cat-left-iphone);
    bottom: var(--kitchen-story-cat-bottom-iphone);
  }

  .kitchen-scene .story-cat-art {
    width: var(--kitchen-story-cat-size-iphone);
  }

  .kitchen-scene .kitchen-hud .cat-status {
    left: var(--kitchen-hud-cat-left-iphone);
    bottom: var(--kitchen-hud-cat-bottom-iphone);
  }

  .kitchen-scene .kitchen-hud .cat-status img {
    width: var(--kitchen-hud-cat-size-iphone);
  }

  .remote-scene .story-characters {
    left: var(--remote-story-cat-left-iphone);
    bottom: var(--remote-story-cat-bottom-iphone);
  }

  .remote-scene .story-cat-art {
    width: var(--remote-story-cat-size-iphone);
  }

  .remote-scene .remote-hud .cat-status {
    left: var(--remote-hud-cat-left-iphone);
    bottom: var(--remote-hud-cat-bottom-iphone);
  }

  .remote-scene .remote-hud .cat-status img {
    width: var(--remote-hud-cat-size-iphone);
  }

  .login-scene .story-characters {
    left: var(--login-story-cat-left-iphone);
    bottom: var(--login-story-cat-bottom-iphone);
  }

  .login-scene .story-cat-art {
    width: var(--login-story-cat-size-iphone);
  }

  .movie-select-scene .story-characters {
    left: var(--movie-cat-left-iphone);
    bottom: var(--movie-cat-bottom-iphone);
  }

  .movie-select-scene .story-cat-art {
    width: var(--movie-cat-size-iphone);
  }

  .ending-cat-apology {
    width: var(--ending-cat-apology-size-iphone);
    transform: translate(var(--ending-cat-apology-x-iphone), var(--ending-cat-apology-y-iphone));
  }

  .ending-cat-sleeping {
    width: var(--ending-cat-sleep-size-iphone);
    transform: translate(var(--ending-cat-sleep-x-iphone), var(--ending-cat-sleep-y-iphone)) scale(var(--ending-cat-sleep-scale-iphone));
  }

  .scene-overlay {
    max-width: min(50vw, 20rem);
    padding: 0.85rem;
  }

  .scene-actions {
    gap: 0.65rem;
  }

  .scene-actions button {
    padding: 0.62rem 0.78rem;
    font-size: 0.92rem;
  }

  .home-overlay {
    width: min(48vw, 20rem);
  }

  .home-side-cat {
    right: var(--home-side-cat-right-iphone);
    bottom: var(--home-side-cat-bottom-iphone);
  }

  .home-side-cat-image {
    width: var(--home-side-cat-size-iphone);
  }

  .home-thought-bubble {
    width: var(--home-thought-width-iphone);
    font-size: var(--home-thought-font-iphone);
    right: var(--home-thought-right-iphone);
    bottom: var(--home-thought-bottom-iphone);
  }

  .kitchen-scene-gameplay,
  .login-scene-gameplay {
    grid-template-rows: auto minmax(0, 1fr) auto;
    min-height: 0;
    max-height: none;
    overflow: hidden;
  }

  .kitchen-hud,
  .remote-hud,
  .login-hud,
  .dialogue-box {
    flex-direction: row;
    align-items: center;
  }

  .kitchen-hud,
  .remote-hud,
  .login-hud {
    gap: 0.65rem;
    margin-bottom: 0;
  }

  .ingredient-panel {
    min-width: 9rem;
    padding: 0.6rem 0.75rem;
  }

  .ingredient-panel ul {
    gap: 0.3rem;
    margin-top: 0.35rem;
    font-size: 0.88rem;
  }

  .gameplay-banner {
    padding: 0.6rem 0.72rem;
  }

  .kitchen-mode-pill,
  .remote-mode-pill {
    max-width: 9.2rem;
  }

  .kitchen-playfield,
  .remote-playfield {
    min-height: clamp(9.5rem, 44vh, 14rem);
    height: 100%;
  }

  .kitchen-scene-gameplay .kitchen-playfield {
    overflow: visible;
  }

  .kitchen-scene-gameplay .kitchen-playfield .hotspot-kitchen-art {
    z-index: 8;
  }

  .kitchen-scene-gameplay .kitchen-playfield .hotspot-kitchen-image {
    filter: drop-shadow(0 10px 12px rgba(40, 18, 46, 0.34));
  }

  .dialogue-box {
    width: 100%;
    padding: 0.6rem 0.75rem;
    gap: 0.55rem;
  }

  .login-scene-gameplay .dialogue-box {
    width: min(62%, 18rem);
    margin-left: 0;
    margin-right: auto;
  }

  .movie-select-scene .dialogue-box {
    width: min(62%, 38rem);
    margin-left: 0;
    margin-right: auto;
  }

  .ending-scene .dialogue-box {
    width: min(54%, 16rem);
    margin-left: 0;
    margin-right: auto;
  }

  .ending-scene-complete .dialogue-box {
    width: min(72%, 22rem);
  }

  .login-scene-gameplay .login-stage {
    padding-top: 0.75rem;
  }

  .movie-select-stage {
    padding-top: 6.75rem;
  }

  .kitchen-scene-gameplay .dialogue-box {
    width: 100%;
    padding: 0.54rem 0.7rem;
  }

  .dialogue-text,
  .kitchen-scene-gameplay .dialogue-text {
    font-size: 0.88rem;
    line-height: 1.28;
  }

  .dialogue-controls {
    justify-content: flex-end;
    gap: 0.35rem;
    flex: 0 0 auto;
  }

  .dialogue-controls button {
    padding: 0.54rem 0.68rem;
    font-size: 0.86rem;
  }

  .cat-status img {
    width: clamp(72px, 10vw, 98px);
  }

  .phone-popup {
    width: min(94vw, 40rem);
    height: min(90dvh, 23rem);
  }

  .phone-shell {
    padding: 0.5rem 0.7rem 0.7rem;
    border-radius: 1.85rem;
    gap: 0.4rem;
  }

  .phone-notch {
    width: 6.2rem;
    height: 0.92rem;
  }

  .phone-topbar {
    padding-top: 0.1rem;
  }

  .phone-screen {
    grid-template-rows: auto minmax(0, 1fr);
    padding-top: 0;
  }

  .phone-view {
    padding: 0 0.7rem 0.45rem;
  }

  .phone-home-header {
    padding: 0.2rem 0.18rem 0.42rem;
  }

  .phone-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .75rem;
  }

  .phone-app-button {
    min-height: 6.35rem;
    padding: 0.7rem 0.58rem;
  }

  .phone-app-icon {
    width: 4.15rem;
    height: 4.15rem;
    font-size: 1.3rem;
  }

  .phone-app-label {
    font-size: 0.95rem;
  }

  .notes-phone-body {
    grid-template-columns: minmax(11rem, 12.8rem) minmax(0, 1fr);
    grid-template-rows: none;
    align-items: stretch;
  }

  .notes-sidebar {
    border-bottom: 0;
    border-right: 1px solid rgba(144, 118, 11, 0.14);
    padding-right: 0.85rem;
  }

  .movie-grid-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(78vw, 28rem);
    gap: 0.65rem;
  }

  .story-dialogue-box {
    width: min(100%, 30rem);
    min-height: 5.9rem;
    padding: 0.75rem 0.9rem;
  }

  .story-stage,
  .cookbook-stage {
    width: min(100%, 30rem);
    max-width: 30rem;
    margin-top: 0;
    margin-bottom: 0;
  }

  .cookbook-panel {
    padding: 0.72rem;
  }

  .cookbook-choice-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .cookbook-choice-card {
    min-height: 8.8rem;
  }

  .hotspot {
    max-width: none;
  }

  .kitchen-scene-gameplay .hotspot-pasta {
    top: var(--kitchen-hotspot-pasta-top-iphone);
    left: var(--kitchen-hotspot-pasta-left-iphone);
    width: var(--kitchen-hotspot-pasta-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-sauce {
    top: var(--kitchen-hotspot-sauce-top-iphone);
    left: var(--kitchen-hotspot-sauce-left-iphone);
    width: var(--kitchen-hotspot-sauce-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-cheese {
    top: var(--kitchen-hotspot-cheese-top-iphone);
    left: var(--kitchen-hotspot-cheese-left-iphone);
    width: var(--kitchen-hotspot-cheese-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-garlic {
    top: var(--kitchen-hotspot-garlic-top-iphone);
    left: var(--kitchen-hotspot-garlic-left-iphone);
    width: var(--kitchen-hotspot-garlic-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-sorry {
    bottom: var(--kitchen-hotspot-sorry-bottom-iphone);
    left: var(--kitchen-hotspot-sorry-left-iphone);
    width: var(--kitchen-hotspot-sorry-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-cheese-joke {
    bottom: var(--kitchen-hotspot-cheese-joke-bottom-iphone);
    left: var(--kitchen-hotspot-cheese-joke-left-iphone);
    width: var(--kitchen-hotspot-cheese-joke-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-mix {
    bottom: var(--kitchen-hotspot-mix-bottom-iphone);
    right: var(--kitchen-hotspot-mix-right-iphone);
    width: var(--kitchen-hotspot-mix-width-iphone);
  }
  .kitchen-scene-gameplay .hotspot-sponge {
    left: var(--kitchen-hotspot-sponge-left-iphone);
    bottom: var(--kitchen-hotspot-sponge-bottom-iphone);
    width: var(--kitchen-hotspot-sponge-width-iphone);
  }
  .kitchen-scene-gameplay .spill-zone {
    left: var(--kitchen-hotspot-spill-left-iphone);
    bottom: var(--kitchen-hotspot-spill-bottom-iphone);
    width: var(--kitchen-spill-zone-width-iphone);
    max-width: none;
    transform: translateX(-50%);
  }
  .kitchen-scene-gameplay .spill-spot-one {
    top: var(--kitchen-spill-spot-one-top-iphone);
    left: var(--kitchen-spill-spot-one-left-iphone);
  }
  .kitchen-scene-gameplay .spill-spot-two {
    top: var(--kitchen-spill-spot-two-top-iphone);
    left: var(--kitchen-spill-spot-two-left-iphone);
  }
  .kitchen-scene-gameplay .spill-spot-three {
    top: var(--kitchen-spill-spot-three-top-iphone);
    left: var(--kitchen-spill-spot-three-left-iphone);
  }
  .remote-scene .hotspot-bookshelf {
    top: var(--remote-hotspot-bookshelf-top-iphone);
    left: var(--remote-hotspot-bookshelf-left-iphone);
  }
  .remote-scene .hotspot-blanket {
    top: var(--remote-hotspot-blanket-top-iphone);
    left: var(--remote-hotspot-blanket-left-iphone);
  }
  .remote-scene .hotspot-wall-art {
    top: var(--remote-hotspot-wall-art-top-iphone);
    left: var(--remote-hotspot-wall-art-left-iphone);
  }
  .remote-scene .hotspot-lamp {
    top: var(--remote-hotspot-lamp-top-iphone);
    left: var(--remote-hotspot-lamp-left-iphone);
  }
  .remote-scene .hotspot-rug {
    left: var(--remote-hotspot-rug-left-iphone);
    bottom: var(--remote-hotspot-rug-bottom-iphone);
  }
  .remote-scene .hotspot-cat-bed {
    left: var(--remote-hotspot-cat-bed-left-iphone);
    bottom: var(--remote-hotspot-cat-bed-bottom-iphone);
  }
  .remote-scene .hotspot-table {
    top: var(--remote-hotspot-table-top-iphone);
    left: var(--remote-hotspot-table-left-iphone);
  }
  .remote-scene .hotspot-remote-couch {
    top: var(--remote-hotspot-couch-top-iphone);
    left: var(--remote-hotspot-couch-left-iphone);
    bottom: auto;
  }
  .remote-scene .hotspot-remote-bed {
    right: var(--remote-hotspot-bed-right-iphone);
    bottom: var(--remote-hotspot-bed-bottom-iphone);
  }
}

/* Centering fix: login + movie-select */
.login-scene,
.movie-select-scene {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.login-scene .login-scene-stage,
.movie-select-scene .movie-select-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1;
  min-height: 0;
}

.login-stage,
.login-stage .tv-screen-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: min(92vw, 32rem);
  max-width: 32rem;
  margin: 0 auto;
  position: relative;
  left: 0;
  transform: none;
}

.movie-select-scene .movie-select-header,
.movie-select-scene .movie-grid-panel {
  margin: 0 auto;
  position: relative;
  left: 0;
  transform: none;
}

.movie-select-scene .movie-select-header {
  width: min(92vw, 32rem);
  max-width: 32rem;
}

.movie-select-scene .movie-grid-panel {
  width: min(92vw, 38rem);
  max-width: 38rem;
}
