/* Public homepage. Manrope for reading, Plex Mono for field labels. */
:root { --line: #bfc9be; }
body { scrollbar-color: #788b76 var(--paper); }
.site-header { height: 78px; padding-inline: 6%; background: #10251dc4; border-bottom: 1px solid #ffffff38; }
.site-header nav { font: 14px/1.4 var(--sans); text-transform: none; gap: clamp(18px, 3vw, 44px); }
.site-header nav a, .header-contact { display: inline-flex; align-items: center; min-height: 44px; }
.header-contact { font: 13px var(--sans); border-color: #ffffff66; }
.brand-caption { font-size: 10px; }

.hero {
  display: grid; align-items: end; height: auto; min-height: clamp(620px, 79svh, 820px);
  max-height: none; padding: 168px 6% clamp(55px, 7vw, 100px); isolation: isolate;
}
.hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, #0c211c9c, transparent 72%), linear-gradient(0deg, #11251d80, transparent 65%);
}
.hero-content { position: relative; inset: auto; z-index: 1; width: fit-content; max-width: 100%; }
.eyebrow { font: 11px/1.5 var(--mono); letter-spacing: .09em; text-transform: uppercase; }
.hero-theme { color: #d5e6d3; margin-bottom: 22px; }
.hero h1 { font-size: clamp(54px, 5.9vw, 94px); letter-spacing: -.06em; line-height: 1.03; }
.hero-bottom { flex-direction: column; align-items: flex-start; gap: 25px; margin-top: 24px; }
.hero-bottom p { font: 17px/1.65 var(--sans); max-width: 49ch; color: #f1f4ee; }
.split-button { font: 500 14px/1.4 var(--sans); gap: 0; min-height: 46px; }
.split-button > span:first-child { padding: 13px 17px; border-radius: 2px 0 0 2px; }
.split-button > span:last-child { width: 38px; padding-right: 9px; border-radius: 0 2px 2px 0; font-size: 21px; }
.split-button:hover > span:last-child { transform: none; }
.split-button > span:only-child { width: auto; padding: 13px 17px; border-radius: 2px; font: inherit; }

.section-wrap { padding: clamp(54px, 6vw, 96px) max(6%, calc((100% - 1410px)/2)); }
h2 { font-size: clamp(34px, 3.7vw, 62px); line-height: 1.12; letter-spacing: -.05em; text-wrap: balance; }
.research { background: #eef1e9; }
.section-heading, .approach-content, .community-inner {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 7%; align-items: start; margin: 0;
}
.library-listen-link { text-decoration: underline; text-underline-offset: .17em; }
.section-heading { align-items: end; margin-bottom: 30px; }
.section-heading p, .community-inner p, .approach-copy p, .pilot-content > p:not(.eyebrow) {
  font: 16px/1.7 var(--sans); max-width: 52ch; color: #48594b; margin: 0;
}
.library-tools { border-top: 1px solid var(--line); align-items: center; padding: 16px 0 0; gap: 16px; }
.filters { gap: 4px; }
.filters button { min-height: 44px; font: 14px var(--sans); padding: 10px 16px; border-color: transparent; }
.search { min-height: 44px; gap: 8px; }
.search > span { font: 500 14px var(--sans); }
.search:focus-within { border-color: #31513c; }
.search input { font: 16px var(--sans); min-width: 0; width: 165px; padding: 9px 4px; }
.search input::placeholder { color: #53644e; opacity: 1; }
.library-note { gap: 10px 22px; flex-wrap: wrap; font: 13px/1.65 var(--sans); color: #50614c; }
.library-note a, .dialog-survey-link { text-decoration: underline; text-underline-offset: .2em; }
.ingredient-directory { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); gap: 0 24px; padding: 0; }
.ingredient-directory a { display: flex; align-items: center; min-height: 46px; border-bottom: 1px solid var(--line); text-decoration: underline; text-underline-offset: .2em; }
.research:not(.library-ready) :is(.library-tools, .research-carousel), .research.library-ready .ingredient-directory { display: none; }
#empty-state { padding: 24px 0; }
#empty-state p { margin: 0 0 8px; }
#reset-library { min-height: 44px; padding: 0 14px; border: 1px solid currentColor; background: transparent; border-radius: 2px; }
#reset-library:hover, #reset-library:active { background: var(--ink); color: var(--paper); }
.pilot { align-items: stretch; }
.pilot-image { min-height: 340px; }
.pilot-content { align-self: center; padding: clamp(40px, 5vw, 80px) 12%; }
.pilot-content .eyebrow { margin-bottom: 16px; color: #bed0bb; }
.pilot-content > p:not(.eyebrow) { color: #dbe4d7; margin: 20px 0 26px; }
.approach-content .eyebrow { color: #52664f; margin-bottom: 18px; }
.approach-copy { max-width: 54ch; }
.approach-copy p + p { margin-top: 14px; }
.approach-copy .project-credit { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 19px; font-size: 14px; }
.community { background: #e3e9de; border-top: 1px solid var(--line); }
.community-inner p { margin-bottom: 20px; }
.site-footer { padding-inline: 6%; }
.footer-top p, .footer-bottom { font: 13px/1.65 var(--sans); letter-spacing: 0; color: #c6d2c1; }
.back-top, .footer-bottom a, .dialog-survey-link { display: inline-flex; align-items: center; min-height: 44px; }
.back-top { font-size: 11px; }
.footer-bottom { border-top: 1px solid #ffffff26; align-items: center; gap: 20px; }
.footer-bottom nav { display: flex; gap: 4px 24px; flex-wrap: wrap; }
dialog p, dialog ul { font: 16px/1.7 var(--sans); }
dialog .dialog-kicker { font-size: 11px; }
.dialog-close { min-width: 44px; min-height: 44px; }
.dialog-survey-link { font-weight: 600; }
@media (max-width: 900px) {
  .site-header { padding-inline: 5%; }
  .header-contact { font-size: 12px; }
  .header-contact span { margin-left: 10px; }
  .filters button { padding-inline: 12px; }
}
@media (max-width: 700px) {
  .site-header { height: 66px; padding-inline: 6%; }
  .site-header .brand-caption { display: inline; font-size: 8px; margin-left: 12px; }
  .header-contact { display: none; }
  .menu-toggle { width: auto; height: 44px; padding: 0 12px; border: 1px solid #ffffff66; border-radius: 2px; font: 14px var(--sans); color: inherit; }
  .menu-toggle:hover, .menu-toggle[aria-expanded="true"] { background: #20362d; }
  .site-header:not(.menu-ready) .menu-toggle { display: none; }
  .site-header:not(.menu-ready) nav { display: flex; flex-flow: row wrap; gap: 0 12px; padding-block: 0; font-size: 13px; }
  .site-header nav { top: 65px; padding: 10px 6% 16px; gap: 0; font-size: 16px; }
  .site-header nav a { min-height: 48px; border-bottom: 1px solid #ffffff24; }
  .hero { min-height: 0; padding: 246px 6% 44px; }
  .hero::after { background: linear-gradient(0deg, #0d211cf0, #10231d94 60%, transparent 79%); }
  .hero-theme { margin-bottom: 16px; }
  .hero h1 { font-size: clamp(34px, 9.9vw, 60px); line-height: 1.08; }
  .hero-bottom { gap: 22px; margin-top: 18px; }
  .hero-bottom p { font-size: 16px; }
  .section-heading, .approach-content, .community-inner { grid-template-columns: 1fr; gap: 16px; }
  .section-heading { margin-bottom: 22px; }
  .library-tools { align-items: stretch; flex-direction: column; gap: 10px; }
  .filters { gap: 2px; }
  .filters button { padding: 8px; font-size: 13px; }
  .filters button span { margin-left: 3px; }
  .search input { width: 100%; }
  .pilot-image { min-height: clamp(180px, 52vw, 300px); }
  .pilot-content { padding: 32px 6% 44px; }
  .approach-content .eyebrow { margin-bottom: 12px; }
  .footer-top { align-items: flex-start; gap: 14px; padding-bottom: 18px; }
  .footer-top p { max-width: 35ch; }
  .back-top { width: auto; margin-left: auto; }
  .footer-bottom { align-items: flex-start; gap: 6px; }
  .footer-bottom nav { gap: 2px 17px; }
}

/* Homepage listening and signup */
.hero:has(.hero-entry) { padding-top: clamp(124px, 10vw, 172px); padding-bottom: clamp(36px, 5vw, 72px); }
.hero:has(.hero-entry) .hero-theme { font-size: 14px; }
.hero-entry { width: min(100%, 32rem); margin-top: 24px; }
.hero-quick {
  padding: 18px 20px 16px;
  background: #10261eee;
  color: #f4f7ef;
  border: 1px solid #738c79;
  border-radius: 9px;
}
.hero-quick-caption { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; }
.hero-quick h2 { margin: 0; font: 600 22px/1.25 var(--sans); letter-spacing: -.035em; }
.hero-quick-caption > span { font: 14px/1.5 var(--sans); font-variant-numeric: tabular-nums; color: #d8e5d6; }
.hero-quick audio { display: block; width: 100%; min-width: 0; height: 44px; margin-top: 13px; border-radius: 22px; cursor: auto; }
.hero-quick-status { margin: 8px 0 0; color: #dbe7da; font: 14px/1.5 var(--sans); }
.hero-quick-status:empty, .hero-quick-retry[hidden] { display: none; }
.hero-quick-retry { min-height: 44px; padding: 0; border: 0; background: transparent; color: white; font-size: 14px; text-decoration: underline; text-underline-offset: .2em; }
.hero-join {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 12px;
  min-height: 52px;
  margin-top: 10px;
  padding: 12px 20px;
  background: #d8e9ce;
  color: #183326;
  border-radius: 6px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
}
.hero-join:hover { background: #eaf3e4; }
.hero-join-hint { font-weight: 400; font-size: 14px; }
.hero-join-arrow { margin-left: auto; font-size: 22px; line-height: 1; }
.hero-quick audio:focus-visible, .hero-join:focus-visible, .hero-quick-retry:focus-visible, .hero-reading a:focus-visible {
  outline: 3px solid white;
  outline-offset: 3px;
}
.hero-reading { max-width: 52ch; margin-top: 20px; }
.hero-reading p { font: 15px/1.55 var(--sans); color: #f2f5ef; margin: 0; }
.hero-reading a { display: inline-flex; align-items: center; min-height: 44px; gap: 9px; font-size: 14px; text-decoration: underline; text-underline-offset: .24em; }
@media (max-width: 700px) {
  .hero:has(.hero-entry) { padding-top: clamp(102px, 15svh, 142px); padding-bottom: 22px; }
  .hero:has(.hero-entry)::after { background: linear-gradient(0deg, #0d211cf2, #10231dab 70%, #10231d44); }
  .hero:has(.hero-entry) .hero-content { width: 100%; }
  .hero:has(.hero-entry) .hero-theme { margin-bottom: 11px; }
  .hero-entry { margin-top: 19px; }
  .hero-quick { padding: 14px 15px; }
  .hero-quick-caption { justify-content: flex-start; }
  .hero-quick h2 { font-size: 20px; }
  .hero-quick audio { margin-top: 9px; }
  .hero-join { padding: 10px 15px; gap: 2px 9px; }
  .hero-reading { margin-top: 16px; }
}
@media (max-width: 420px) {
  .hero-join { display: grid; grid-template-columns: 1fr auto; }
  .hero-join-hint { grid-column: 1; }
  .hero-join-arrow { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
}
