@font-face {
  font-family: "Nursery Fraunces";
  src: url("/site/fonts/nursery/Fraunces-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

body:has(.nursery-page-hero) {
  --nursery-ink: #36242a;
  --nursery-muted: #635052;
  --nursery-accent: #783a50;
  --nursery-line: #e4d7cd;
  --nursery-heading: "Nursery Fraunces", Georgia, serif;
  background:
    radial-gradient(ellipse at 82% 0%, #f8dcd4, transparent 70%) top center / 100% clamp(620px, 75vw, 1020px) no-repeat,
    #fffaf7;
}
body:has(.nursery-page-hero) > .top {
  position: relative;
  inset: auto;
  translate: none;
  transition: none;
  background: transparent;
  color: var(--nursery-ink);
  border-bottom: 1px solid #74384e16;
  box-shadow: none;
}
body:has(.nursery-page-hero) > .top::before { display: none; }
body:has(.nursery-page-hero) > .top .wrap { padding-block: max(12px, env(safe-area-inset-top)) 12px; }
body:has(.nursery-page-hero) > .top :is(.brand, .nav a, .nav-explore summary) { color: var(--nursery-ink); }
body:has(.nursery-page-hero) > .top :is(.nav-menu, .nav a:hover, .nav-explore[open] summary, .nav-explore summary:hover) { background: #f8e9e2; }
body:has(.nursery-page-hero) > .top .nav-menu { box-shadow: 0 10px 30px #4e32392c; }
body:has(.nursery-page-hero) > .top .button.small {
  color: var(--nursery-ink);
  background: #fbe4bf;
  box-shadow: none;
  border: 1px solid #d3a475;
  border-radius: 999px;
}

.nursery-mobile-bar { display: none; }
.nursery-page-hero { color: var(--nursery-ink); }
.nursery-page-intro { padding-block: clamp(24px, 4.8vw, 70px); }
.nursery-page-parent {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--nursery-accent);
  font-size: .78rem;
  font-weight: 850;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-decoration: none;
}
.nursery-page-parent:hover { text-decoration: underline; }
.nursery-page-copy h1, .nursery-week-fact h2, .nursery-page-two h2 {
  font-family: var(--nursery-heading);
  font-weight: 550;
  line-height: 1.02;
  letter-spacing: -.045em;
}
.nursery-page-copy h1 { max-width: 11ch; font-size: clamp(3.25rem, 6.2vw, 5.9rem); overflow-wrap: anywhere; }
.nursery-page-copy p { margin-top: 14px; max-width: 36ch; color: var(--nursery-muted); font-size: clamp(1rem, 2vw, 1.16rem); }
.nursery-week-preview { position: relative; scroll-margin-top: 20px; }
.nursery-week-controls { margin-block: 21px 23px; }
.nursery-week-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 5px;
  color: var(--nursery-ink);
  font-size: .86rem;
  font-weight: 800;
}
.nursery-trimester { color: var(--nursery-muted); font-size: .82rem; font-weight: 600; }
.nursery-week-rail {
  position: relative;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 5px 5px 7px;
  border: 1px solid #e7c9c1;
  border-radius: 16px;
  background: #f8e5df;
  scrollbar-width: thin;
  scrollbar-color: #b7788a transparent;
}
.nursery-week-rail button {
  flex: 0 0 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 11px;
  background: #fff8f4;
  color: var(--nursery-ink);
  cursor: pointer;
  font: inherit;
  font-size: .94rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.nursery-week-rail button[aria-pressed="true"] { background: var(--nursery-accent); color: #fffaf7; }
.nursery-page-hero :focus-visible, .nursery-page-lullabies :focus-visible, .nursery-page-next :focus-visible {
  outline: 2px solid var(--nursery-accent);
  outline-offset: 3px;
}

.nursery-week { scroll-margin-top: 96px; }
.nursery-week > summary { padding: 12px 0; cursor: pointer; }
.nursery-week-controls:not([hidden]) ~ .nursery-week > summary { display: none; }
.nursery-week-stage { display: grid; gap: 24px; }
.nursery-week-visual {
  position: relative;
  display: grid;
  align-content: center;
  justify-items: center;
  min-width: 0;
  padding: clamp(8px, 1vw, 15px);
  border-radius: clamp(20px, 3vw, 36px);
  background: #391e30;
  box-shadow: 0 24px 56px -23px #6f344e7a;
  text-align: center;
}
.nursery-week-visual:has(.nursery-baby-view[hidden]) { background: #171a40; }
.nursery-week-visual figure { margin: 0; width: 100%; }
.nursery-week-visual figure:not([hidden]) + figure:not([hidden]) { margin-top: 14px; }
.nursery-week-visual figcaption { margin: 7px 0 2px; color: #fff2e9; font-size: .83rem; }
.nursery-baby-art, .nursery-size-art {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  height: auto;
  object-fit: cover;
  border-radius: clamp(13px, 2vw, 22px);
}
.nursery-baby-art { background: #402028; }
.nursery-size-art { background: #151a40; }
.nursery-visual-choices:not([hidden]) {
  display: flex;
  margin-top: 11px;
  flex-wrap: wrap;
  justify-content: center;
  padding: 2px;
  border-radius: 999px;
  background: #fff9f4;
}
.nursery-visual-choices button {
  min-height: 44px;
  padding: 0 13px;
  border: 0;
  border-radius: 999px;
  color: var(--nursery-accent);
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-weight: 750;
  font-size: .90rem;
}
.nursery-visual-choices button[aria-pressed="true"] { background: #f5e0d6; color: var(--nursery-ink); }
.nursery-week-fact h2 { font-size: clamp(1.8rem, 3.1vw, 2.75rem); text-wrap: balance; margin-bottom: 7px; }
.nursery-week-fact p { color: var(--nursery-muted); max-width: 43ch; }
.nursery-week-scale {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-top: 17px;
  padding-block: 12px;
  border-block: 1px solid var(--nursery-line);
}
.nursery-week-scale p { font-weight: 820; }
.nursery-scale-art { width: 58px; height: 58px; flex: 0 0 58px; border-radius: 14px; }
.nursery-measure { display: flex; flex-wrap: wrap; gap: 0 16px; margin: 2px 0 0; }
.nursery-measure div { display: flex; align-items: baseline; gap: 5px; }
.nursery-measure dt { color: var(--nursery-muted); font-size: .83rem; }
.nursery-measure dd { margin: 0; font-weight: 790; }
.nursery-week-listen a, .nursery-inline-action { display: inline-flex; gap: 10px; align-items: center; min-height: 44px; color: var(--nursery-accent); font-weight: 750; }
.nursery-week-reading { color: var(--nursery-muted); font-size: .95rem; }
.nursery-week-reading summary { width: fit-content; min-height: 44px; align-content: center; cursor: pointer; text-decoration: underline; text-underline-offset: .17em; }
.nursery-week-reading p + p { margin-top: 8px; }
.nursery-week-reading ul { padding-inline-start: 20px; margin-bottom: 0; }
.nursery-week-reading a, .nursery-week-note a { color: var(--nursery-accent); }
.nursery-week-note { margin: 24px 0 0; color: var(--nursery-muted); font-size: .86rem; }
.nursery-week-note summary { width: fit-content; min-height: 44px; align-content: center; cursor: pointer; }
.nursery-week-note p { max-width: 74ch; margin: 5px 0 8px; }

.nursery-page-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 1110px; gap: clamp(26px, 6vw, 76px); }
.nursery-page-two h2 { font-size: clamp(2.45rem, 5vw, 4.7rem); margin-bottom: 10px; }
.nursery-page-lullabies { color: #fbf1f2; background: #171a40; }
.nursery-page-lullabies .nursery-page-two { align-items: center; }
.nursery-listening > p { max-width: 34ch; color: #e1d7e9; }
.nursery-listen-art {
  display: block;
  width: min(100%, 410px);
  height: auto;
  justify-self: center;
  border-radius: clamp(22px, 4vw, 48px);
}
.nursery-page-lullabies :focus-visible { outline-color: #ffdcab; }
.nursery-audio-transport input:focus-visible { outline-color: var(--nursery-accent); }
.nursery-sound-picker:not([hidden]) {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 22px;
}
.nursery-sound-picker button {
  padding: 0 12px;
  min-height: 44px;
  border: 1px solid #696485;
  border-radius: 999px;
  color: #fff1f4;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: .82rem;
  font-weight: 750;
}
.nursery-sound-picker button[aria-pressed="true"] {
  color: var(--nursery-ink);
  background: #f8ded6;
  border-color: #f8ded6;
}
.nursery-page-player { margin: 16px 0 0; max-width: 440px; scroll-margin-top: 30px; }
.nursery-page-player figcaption { font-weight: 800; margin-bottom: 5px; }
.nursery-page-player figcaption span { display: block; font-size: .84rem; color: #e1d7e9; font-weight: 600; }
.nursery-page-player audio[controls] { display: block; color-scheme: light; width: 100%; }
.nursery-audio-transport:not([hidden]) {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 7px 14px 7px 8px;
  border: 1px solid #dccce1;
  border-radius: 18px;
  background: #fff8f4;
}
.nursery-audio-transport button {
  display: grid;
  place-content: center;
  height: 44px;
  width: 44px;
  border: 0;
  border-radius: 50%;
  background: var(--nursery-accent);
  color: #fffaf7;
  font: inherit;
  font-size: .92rem;
  cursor: pointer;
}
.nursery-audio-transport input { width: 100%; min-width: 0; min-height: 28px; margin: 0; accent-color: var(--nursery-accent); }
.nursery-audio-transport input:disabled { opacity: .6; }
.nursery-audio-time { color: var(--nursery-muted); white-space: nowrap; font-size: .8rem; font-variant-numeric: tabular-nums; }
.nursery-audio-error { margin-top: 5px; color: #ffdcab; font-size: .88rem; }
.nursery-app-guide, .nursery-page-next { color: var(--nursery-ink); background: #fffaf7; }
.nursery-page-lullabies + .nursery-app-guide { padding-top: clamp(38px, 6vw, 85px); }
.nursery-app-wrap { max-width: 1110px; }
.nursery-app-guide h2 {
  max-width: 22ch;
  margin-bottom: clamp(20px, 3.5vw, 36px);
  font-family: var(--nursery-heading);
  font-size: clamp(2.4rem, 5vw, 4.45rem);
  font-weight: 550;
  line-height: 1.04;
  letter-spacing: -.045em;
}
.nursery-app-tools { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(22px, 4vw, 48px); }
.nursery-app-tools h3 { margin-top: 13px; font-size: clamp(1.12rem, 2vw, 1.45rem); }
.nursery-app-tools p { margin-top: 5px; max-width: 43ch; color: var(--nursery-muted); }
.nursery-app-art { display: block; width: 100%; height: auto; border-radius: 18px; }
.nursery-app-link {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  gap: 10px;
  padding-inline: 17px;
  margin-top: 26px;
  color: #fffaf7;
  background: var(--nursery-accent);
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
}
.nursery-app-link:hover { background: #612b40; }
.nursery-app-link:focus-visible { outline: 2px solid var(--nursery-accent); outline-offset: 3px; }
.nursery-page-next .nursery-page-two { align-items: center; }
.nursery-page-next .nursery-page-two h2 { font-size: clamp(2.35rem, 4.25vw, 3.55rem); }
.nursery-app-guide + .nursery-page-next { padding-top: clamp(32px, 5vw, 66px); background: #faebe5; }
.nursery-baby-play-art { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 23px; }
.nursery-page-next :is(p, li) { color: var(--nursery-muted); }
.nursery-page-choice { margin-top: 22px; padding-top: 14px; border-top: 1px solid var(--nursery-line); }
.nursery-page-choice h3 { font-size: 1.28rem; margin: 6px 0 10px; }
.nursery-page-choice a { color: var(--nursery-accent); }
.nursery-page-choice ul { padding-left: 20px; margin: 9px 0 0; }
.nursery-page-choice li + li { margin-top: 8px; }

@media (min-width: 761px) {
  .nursery-week-preview:has(.nursery-week-controls:not([hidden])) {
    --art-width: min(518px, calc((100vw - 2 * var(--gutter)) * .48));
    --art-gap: clamp(30px, 5vw, 80px);
    padding-inline-end: calc(var(--art-width) + var(--art-gap));
    min-height: calc(var(--art-width) + 78px);
  }
  .nursery-week-controls:not([hidden]) ~ .nursery-week .nursery-week-visual {
    position: absolute;
    inset-block-start: 0;
    inset-inline-end: 0;
    width: var(--art-width);
    box-sizing: border-box;
  }
  .nursery-week-preview:not(:has(.nursery-week-controls:not([hidden]))) .nursery-week-stage {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
}
@media (hover: hover) {
  .nursery-week-rail button:not([aria-pressed="true"]):hover, .nursery-visual-choices button:not([aria-pressed="true"]):hover { background: #f5e0d6; }
}
@media (max-width: 760px) {
  body:has(.nursery-page-hero) > .top .wrap { position: relative; flex-wrap: nowrap; gap: 6px; }
  body:has(.nursery-page-hero) > .top .brand { flex: none; font-size: 1.25rem; }
  body:has(.nursery-page-hero) > .top .brand img { width: 36px; height: 36px; }
  body:has(.nursery-page-hero) > .top .nav {
    order: 0;
    width: auto;
    margin: 0 0 0 auto;
    padding: 0;
    overflow: visible;
    mask-image: none;
    background: none;
  }
  body:has(.nursery-page-hero) > .top .nav-explore { display: block; position: static; }
  body:has(.nursery-page-hero) > .top .nav-explore summary { font-size: .86rem; padding-inline: 6px; }
  body:has(.nursery-page-hero) > .top :is(.nav-flat, .nav > a) { display: none; }
  body:has(.nursery-page-hero) > .top .nav-menu { left: auto; right: var(--gutter); top: calc(100% + 4px); }
  body:has(.nursery-page-hero) > .top .nav-menu a { background: transparent; box-shadow: none; }
  body:has(.nursery-page-hero) > .top .nav-menu a:hover { background: #fffaf7; }
  body:has(.nursery-page-hero) > .top .button.small { flex: none; margin-left: 0; padding-inline: 10px; font-size: .86rem; }
  html:has(.nursery-mobile-bar) { scroll-padding-top: calc(52px + env(safe-area-inset-top)); }
  .nursery-mobile-bar {
    display: block;
    position: sticky;
    top: 0;
    z-index: 4;
    padding-top: env(safe-area-inset-top);
    border-bottom: 1px solid #74384e21;
    background: #fae6df;
    color: var(--nursery-ink);
  }
  .nursery-mobile-bar .wrap {
    display: flex;
    min-height: 44px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: .9rem;
    font-weight: 800;
  }
  .nursery-current-week {
    min-height: 44px;
    padding: 0 3px 0 8px;
    border: 0;
    background: transparent;
    color: var(--nursery-accent);
    cursor: pointer;
    font: inherit;
  }
  .nursery-current-week:focus-visible { outline: 2px solid var(--nursery-accent); outline-offset: -2px; }
  .nursery-week-label-text, .nursery-page-parent, .nursery-week-prompt { display: none; }
  .nursery-page-two, .nursery-app-tools { grid-template-columns: minmax(0, 1fr); }
  .nursery-page-intro { padding-top: 15px; }
  .nursery-page-copy h1 { font-size: clamp(2.9rem, 9vw, 4rem); }
  .nursery-week-visual { width: min(100%, 440px); }
  .nursery-week-controls { margin-block: 16px 19px; }
  .nursery-week-fact h2 { text-wrap: pretty; }
  .nursery-listen-art { width: min(100%, 340px); }
}
@media (max-width: 350px) {
  .nursery-page-copy h1 { font-size: 2.85rem; }
  .nursery-sound-picker:not([hidden]) { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .nursery-sound-picker button { padding-inline: 4px; font-size: .75rem; }
  .nursery-page-copy p { margin-top: 8px; font-size: .94rem; }
  body:has(.nursery-page-hero) .foot .wrap { grid-template-columns: minmax(0, 1fr); }
}
