@font-face {
  font-family: Quicksand;
  src: url(quicksand.woff2) format("woff2");
  font-weight: 400 700;
  font-display: swap;
}
.dream {
  --line: #69538d;
  --muted: #ead8fb;
  --white: #2a1846;
  --shadow: 0 14px 34px #0a051e60;
  color: #fff5ff;
  background: radial-gradient(ellipse at 12% 22%, #54306f 0%, transparent 45%),
    radial-gradient(ellipse at 92% 72%, #1a4860 0%, transparent 55%),
    linear-gradient(150deg, #24133d, #160d2d 60%, #211433);
  min-height: 100vh;
  font-family: Quicksand, Nunito, system-ui, sans-serif;
  font-weight: 600;
}
.dream .site-head { background: #190e32; border-color: #503768; }
.dream .brand-mark { background: #5c3c81; }
.dream h1, .dream h2, .dream h3, .dream .brand, .dream .primary, .dream .soft { font-weight: 700; }
.dream h1, .dream h2, .dream h3 { letter-spacing: -.035em; }
.dream .primary { background: #f8a6dd; color: #291237; border-color: #ffbce8; }
.dream .primary:hover { background: #ffd0f0; }
.dream .soft { background: #3d285a; color: #fff0ff; }
.dream .soft:hover, .dream .site-head nav a:hover { background: #54356d; }
.dream .site-head nav a[aria-current] { background: #604183; color: #fff1ff; }
.dream .dream-hero {
  border-color: #9361b4;
  background: radial-gradient(circle at 82% 42%, #ef8be69c, transparent 18%),
    radial-gradient(ellipse at 95% 90%, #54d9d874, transparent 36%),
    linear-gradient(128deg, #49276f 12%, #6b3b9c 61%, #613c9c);
  box-shadow: 0 14px 42px #15092878;
}
.dream-hero .portal-intro { max-width: 76%; }
.dream-hero p { color: #fff0fb; }
.dream-hero .cloud { background: #eba2f14a; }
.dream-hero .cloud.right { background: #abf1ee59; top: auto; bottom: -12px; right: -25px; }
.dream-moon {
  position: absolute;
  right: 10%;
  top: 13%;
  font-size: clamp(36px, 10vw, 108px);
  line-height: 1;
  color: #ffeab3;
  text-shadow: 0 0 24px #ffd280ab;
  transform: rotate(-16deg);
}
.dream-moon small { position: absolute; color: #aafaf1; font-size: .3em; right: -.45em; top: .25em; }
.dream-moon::after { content: "✧"; position: absolute; color: #ffcfed; font-size: .26em; left: -.48em; bottom: .1em; }
.dream-horse {
  min-height: 145px;
  display: flex;
  justify-content: center;
  gap: .2em;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  background: radial-gradient(ellipse at 50% 70%, #fce0ba, transparent 64%), linear-gradient(125deg, #ae92ff, #fab1e3 53%, #78e3de);
}
.dream-horse span { font-size: .38em; align-self: center; color: #6a397d; }
.horse-portal { max-width: 790px; }
.horse-panel { padding: clamp(18px, 5vw, 34px); }
.horse-panel h1 { font-size: clamp(2rem, 6vw, 3.2rem); line-height: 1.08; }
.horse-panel .horse-question { font-size: clamp(1.65rem, 4.7vw, 2.5rem); }
.horse-panel h2 { margin-top: 1rem; }
.horse-panel p { margin: .65rem 0; }
.horse-panel button, .horse-panel .primary, .horse-panel .soft { min-height: 44px; }
.horse-actions { display: flex; gap: .65rem; align-items: center; flex-wrap: wrap; margin-top: 1rem; }
.horse-progress { width: 100%; height: 12px; accent-color: #faaee3; display: block; margin: .6rem 0 1rem; }
.horse-choices { display: grid; gap: .6rem; margin: 1rem 0; }
.horse-choice { text-align: left; border: 1px solid #8067a2; border-radius: 12px; color: #fff0ff; padding: 10px 14px; background: #422d61; }
.horse-choice:hover:not(:disabled) { background: #54356d; }
.horse-choice:disabled { opacity: 1; cursor: default; }
.horse-choice[data-mark="right"] { background: #1d523f; border-color: #84d6a4; }
.horse-choice[data-mark="miss"] { background: #652d49; border-color: #e69ab1; }
.horse-feedback:not(:empty) { padding: .85rem 1rem; border-radius: 12px; background: #483064; }
.horse-feedback strong { display: block; margin-bottom: .2rem; color: #ffcfed; }
.horse-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: .6rem; margin: 1rem 0; }
.horse-metrics div { background: #463063; border-radius: 12px; padding: .65rem .8rem; }
.horse-metrics strong { display: block; font-size: 1.45rem; color: #ffb9e9; }
.horse-history, .horse-topics { list-style: none; padding: 0; }
.horse-history li, .horse-topics li { padding: .45rem 0; border-bottom: 1px solid #69538d; }
.horse-topics li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .2rem .7rem; }
.horse-history time { color: var(--muted); }
.dream .storage-warning { color: #332042; }
.dream a:focus-visible, .dream button:focus-visible { outline: 2px solid #91f5ef; outline-offset: 3px; }
.secret-door:focus-visible { outline: 2px solid #70459b; outline-offset: 3px; }

.dream-welcome {
  width: min(540px, calc(100% - 32px));
  max-height: calc(100% - 32px);
  padding: 46px clamp(22px, 6vw, 60px) 34px;
  overflow: auto;
  isolation: isolate;
  border: 0;
  border-radius: 30% 30% 42% 42% / 13% 13% 19% 19%;
  background: transparent;
  color: #3e2558;
  text-align: center;
  filter: drop-shadow(0 0 24px #ecb7fa75);
}
.dream-welcome::backdrop { background: #130922c7; }
.dream-welcome::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  background:
    radial-gradient(ellipse 27% 38% at 30% 40%, #fff5ff 98%, transparent),
    radial-gradient(ellipse 29% 43% at 58% 45%, #fff5ff 98%, transparent),
    radial-gradient(ellipse 24% 36% at 75% 52%, #fff5ff 98%, transparent),
    radial-gradient(ellipse 28% 35% at 29% 64%, #fff5ff 98%, transparent),
    radial-gradient(ellipse 35% 45% at 56% 55%, #fff5ff 98%, transparent),
    radial-gradient(ellipse 26% 35% at 74% 65%, #fff5ff 98%, transparent);
}
.welcome-spark { display: block; font-size: 1.7rem; margin-bottom: .35rem; }
.dream-welcome p { margin: .7rem 0; }
.dream-welcome form { margin-top: 1rem; }
.dream-welcome button:focus-visible { outline-color: #70459b; }
@media (max-width: 560px) {
  .dream .head-inner { flex-wrap: wrap; }
  .dream-horse { min-height: 82px; }
}
.dream-exercises { display: grid; gap: 14px; }
.squish-art { background: linear-gradient(125deg, #ffd28c, #ffb7dc 64%, #bda3ff); }
.dog-art { background: linear-gradient(125deg, #99e7d9, #b9a1f6 55%, #ffcca8); }
