.playroom-home {
  --ink: #292743;
  --paper: #fffaf0;
  --purple: #51449d;
  --green: #285b4b;
  color: var(--ink);
  background: var(--paper);
}
.play-wrap, .playroom-home .header-inner, .playroom-home .footer-inner {
  width: min(73rem, calc(100% - 4rem)); margin-inline: auto;
}
.playroom-home .site-header { background: #fffdf7; border-bottom: 1px solid #d9e3e5; }
.playroom-home .header-inner { min-height: 4.15rem; }
.playroom-home .header-inner .brand img { width: 8.4rem; }
.playroom-home .header-inner nav .nav-action { color: white; background: var(--ink); border-color: var(--ink); }
.playroom-home [hidden] { display: none !important; }
.playroom-home :is(a,button,video):focus-visible { outline: 3px solid #9a5009; outline-offset: 4px; }

.welcome-scene {
  position: relative; overflow: hidden; isolation: isolate;
  background-color: #ebf5fb;
  background-image: radial-gradient(ellipse at 69% 75%, #fff9df 0, transparent 41%), linear-gradient(115deg,#e3f1fb, #eff7fa 73%);
}
.welcome-scene::before, .welcome-scene::after {
  content: ""; position: absolute; z-index: -1; pointer-events: none; opacity: .72;
  width: 11rem; height: 4.25rem; border-radius: 5rem; background: #fff;
  box-shadow: 1.5rem -1.3rem 0 -.2rem #fff, 4rem -.2rem 0 -.25rem #fff;
}
.welcome-scene::before { top: 29%; left: -9.5rem; }
.welcome-scene::after { top: 19%; right: -8rem; transform: scale(.8); }
.welcome-layout {
  display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr);
  align-items: center; gap: clamp(2rem, 5vw, 5rem); padding-block: clamp(1.5rem, 3vw, 2.8rem) clamp(3.5rem, 4.5vw, 4.2rem);
}
.greeting { padding-left: clamp(0rem, 2vw, 2rem); }
.greeting h1 {
  font-size: clamp(3.2rem,6.6vw,6.2rem); line-height: .99; letter-spacing: -.035em;
}
.greeting h1 span { display: inline-block; color: #553c91; transform: rotate(-3deg); }
.greeting p { margin-top: 1rem; max-width: 40ch; color: #46475e; font-size: clamp(1.05rem,1.6vw,1.3rem); line-height: 1.5; }
.greeting-art { display: grid; place-items: center; }
.greeting-art img { width: min(100%, 25rem); height: auto; }

.app-doors {
  position: relative; display: grid; grid-template-columns: repeat(2,minmax(0,1fr));
  gap: clamp(1rem,2.3vw,1.85rem); margin-top: -1.85rem;
}
.door {
  --dark: #593b61; --surface: #f7dfd4; --edge: #e7bbad;
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: minmax(0,1.12fr) minmax(0,.85fr); gap: .5rem; align-items: center;
  padding: clamp(1.25rem,2.15vw,2.1rem); border: 1px solid var(--edge); border-radius: 1.65rem;
  background: var(--surface); box-shadow: 0 4px 0 var(--edge),0 13px 24px -20px #59493b85;
}
.learn-door { --dark: #265647; --surface: #e0efdf; --edge: #b8d7bf; }
.door::after {
  content: ""; position: absolute; z-index: -1; bottom: -28%; right: -13%; width: 52%; aspect-ratio: 1;
  border: 1px dashed var(--edge); border-radius: 50%;
}
.door-copy { display: flex; flex-direction: column; align-items: flex-start; align-self: stretch; }
.door h2 { font-size: clamp(1.65rem,2.65vw,2.65rem); color: var(--dark); line-height: 1.08; }
.door p { margin: .6rem 0 1rem; color: #3b3940; font-size: 1rem; line-height: 1.45; }
.door-art { width: 100%; height: clamp(6.3rem,12.5vw,10.8rem); object-fit: contain; transition: transform .22s ease; }
.door:focus-within .door-art { transform: translateY(-3px) rotate(2deg); }
@media (hover:hover) {
  .door:hover .door-art { transform: translateY(-4px) rotate(2deg); }
}
.door-button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 8.9rem;
  padding: .55rem 1.05rem; border-radius: .85rem; margin-top: auto;
  color: white; background: var(--dark); text-decoration: none; font-weight: 800;
}
.door-button:hover { text-decoration: underline; }

.preview-room { padding-block: clamp(2.8rem,5.6vw,5rem); }
.preview-top { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; margin-bottom: 1.4rem; }
.preview-top h2, .get-apps h2 { font-size: clamp(2.1rem,3.7vw,3.35rem); line-height: 1.1; letter-spacing: -.02em; }
.preview-picker { display: inline-flex; border: 1px solid #cdc7d9; background: #f3eef7; border-radius: 2rem; padding: .2rem; }
.preview-picker button { font: inherit; font-weight: 750; cursor: pointer; background: transparent; color: #484056; min-height: 44px; min-width: 6rem; padding: .45rem 1rem; border: 0; border-radius: 2rem; }
.preview-picker button[aria-pressed="true"] { background: var(--purple); color: white; }
.preview-picker button[data-show="learn-activity"][aria-pressed="true"] { background: var(--green); }
.play-preview {
  display: grid; grid-template-columns: minmax(0,.75fr) minmax(0,1.35fr); gap: clamp(1.5rem,4vw,3.6rem); align-items: center;
  padding: clamp(1.3rem,3.25vw,2.9rem); border-radius: 1.7rem; border: 1px solid #dcd4e3;
  background: #eee8f3;
}
.lesson-preview { background: #eaf2ed; border-color: #c9dbce; }
.play-preview + .play-preview { margin-top: 1.2rem; }
.preview-room.enhanced .play-preview { margin-top: 0; }
.preview-description .app-name { color: var(--purple); font-weight: 800; margin-bottom: .65rem; }
.lesson-preview .app-name { color: var(--green); }
.preview-description h3 { font: 400 clamp(2rem,3.1vw,3rem)/1.08 "Kreebo","Nunito",sans-serif; letter-spacing: -.02em; }
.preview-description p:not(.app-name) { font-size: 1.04rem; color: #414350; margin-top: .85rem; max-width: 42ch; }
.preview-description a { color: #453775; display: inline-flex; align-items: center; min-height: 44px; margin-top: .5rem; font-weight: 800; }
.lesson-preview .preview-description a { color: var(--green); }
.reader-device, .learn-device { width: 100%; display: block; background: #fffef9; border: .38rem solid #363347; border-radius: 1.1rem; box-shadow: 0 8px 16px -9px #2725376b; }
.reader-device { position: relative; max-width: 36rem; overflow: hidden; justify-self: center; }
.reader-device video { width: 100%; height: auto; display: block; background: #181924; aspect-ratio: 4 / 3; }
.play-story {
  position: absolute; left: 50%; bottom: 6%; transform: translateX(-50%); white-space: nowrap;
  display: inline-flex; align-items: center; gap: .55rem; min-height: 44px; padding: .55rem 1.15rem;
  border: 1px solid #fff9; border-radius: 2rem; background: #292743; color: white;
  font: 750 1rem/1.3 "Nunito", system-ui, sans-serif; cursor: pointer; box-shadow: 0 3px 12px #15152644;
}
.play-story::before { content: ""; width: .7rem; height: .8rem; background: currentColor; clip-path: polygon(0 0,100% 50%,0 100%); }
.learn-device { height: clamp(30rem,39vw,34.5rem); }

.get-apps { background: #2f2e4d; color: #fffaf3; padding: clamp(2.6rem,4.5vw,4.2rem) 0; }
.store-pair { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(1.5rem,4vw,4rem); margin-top: 1.6rem; }
.store-pair section { border-top: 1px solid #79738a; padding-top: 1.15rem; }
.store-pair h3 { font: 400 1.6rem/1.2 "Kreebo","Nunito",sans-serif; }
.store-pair p { color: #e5e0ee; max-width: 50ch; margin: .45rem 0 .8rem; }
.store-options { display: flex; flex-wrap: wrap; gap: .5rem; }
.store-options a { display: inline-flex; align-items: center; min-height: 42px; padding: .35rem .8rem; color: #fff; border: 1px solid #928ba6; border-radius: .65rem; font-size: .94rem; text-decoration: none; }
.store-options a:hover { background: #494460; text-decoration: underline; }
.playroom-home footer { background: #fffdf7; }

@media(max-width: 900px) {
  .play-wrap, .playroom-home .header-inner, .playroom-home .footer-inner { width: calc(100% - 2.5rem); }
  .welcome-layout { column-gap: 1rem; }
  .greeting { padding: 0; }
  .door { grid-template-columns: minmax(0,1fr) minmax(0,.55fr); padding: 1.25rem; }
  .play-preview { grid-template-columns: minmax(0,.75fr) minmax(0,1.2fr); gap: 1.3rem; padding: 1.5rem; }
}
@media(max-width: 720px) {
  .play-wrap, .playroom-home .header-inner, .playroom-home .footer-inner { width: calc(100% - 2rem); }
  .playroom-home .header-inner { min-height: 3.65rem; }
  .playroom-home .header-inner .brand img { width: 5.9rem; }
  .welcome-layout { grid-template-columns: minmax(0,1.16fr) minmax(0,.85fr); gap: .5rem; padding-block: 1.6rem 2.6rem; }
  .greeting h1 { font-size: clamp(2.1rem,6.9vw,3.25rem); }
  .greeting p { font-size: 1rem; line-height: 1.4; margin-top: .6rem; }
  .app-doors { grid-template-columns: minmax(0,1fr); margin-top: -1rem; gap: .95rem; }
  .door { grid-template-columns: minmax(0,1.4fr) minmax(0,.6fr); gap: .7rem; padding: 1.15rem 1.25rem; border-radius: 1.25rem; }
  .door h2 { font-size: 1.8rem; }
  .door p { margin: .35rem 0 .65rem; font-size: 1rem; }
  .door-art { height: 7rem; }
  .preview-room { padding-block: 2.75rem; }
  .preview-top { gap: .7rem; }
  .play-preview { display: flex; flex-direction: column; align-items: stretch; padding: 1.15rem; gap: 1rem; }
  .preview-description p:not(.app-name) { margin-top: .55rem; }
  .preview-description h3 { font-size: 1.9rem; }
  .learn-device { height: 34rem; }
  .store-pair { grid-template-columns: minmax(0,1fr); }
}
@media(max-width: 380px) {
  .welcome-layout { grid-template-columns: minmax(0,1fr) 28%; }
  .door { grid-template-columns: minmax(0,1fr) 24%; padding: 1.05rem; }
  .door-art { height: 5.3rem; }
  .greeting h1 { font-size: 2.2rem; }
  .learn-device { height: 36rem; }
  .play-preview { padding: .85rem; }
}
@media(prefers-reduced-motion: reduce) {
  .door-art { transition: none; }
  .door:hover .door-art, .door:focus-within .door-art { transform: none; }
}
