/* v404: language landing pages. House-colored track player and the four-tab phone bar.
   The header and footer come from the house styles. Native audio controls stay off. */
:root {
  --ll-gold: #e8c878;
  --ll-ink: #f5ecd7;
  --ll-chrome: calc(env(safe-area-inset-bottom, 0px) + 0.55rem);
}

body {
  padding-bottom: calc(4.6rem + env(safe-area-inset-bottom, 0px));
}

.lang-landing {
  max-width: 40rem;
  margin: 0 auto;
  padding: 1.15rem clamp(1.1rem, 5vw, 2rem) 1.5rem;
}

.lang-landing h1 {
  margin: 0.2rem 0 0.9rem;
  color: var(--ll-gold);
  font-weight: 400;
  font-size: clamp(1.9rem, 7vw, 2.6rem);
  line-height: 1.25;
}

.lang-landing .intro {
  margin: 0;
  font-size: 1.02rem;
  color: rgba(245, 236, 215, 0.88);
}

.lang-landing .tracks {
  list-style: none;
  margin: 1.4rem 0;
  padding: 0;
  display: grid;
  gap: 0.9rem;
}

.lang-landing .track {
  border: 1px solid rgba(232, 200, 120, 0.38);
  border-radius: 16px;
  padding: 0.85rem 1rem 0.7rem;
  background: #050505;
}

/* The first meditation is the gold lead. Later ones stay quiet on black. */
.lang-landing[data-lang-layout="simple"] .track.is-lead,
.lang-landing .track.is-lead {
  border-color: #f8e7a8;
  background: linear-gradient(180deg, #f8e7a8, #e8c878 55%, #c9a24e);
  box-shadow: 0 0 18px rgba(232, 200, 120, 0.28);
  color: #120d02;
}

.lang-landing .track.is-day {
  background: #000;
  box-shadow: none;
  padding: 0.7rem 0.95rem 0.45rem;
}

.lang-landing .track.is-day .lp-bar { display: none; }

.lang-landing .track h2 {
  margin: 0 0 0.75rem;
  color: var(--ll-gold);
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1.3;
}

.lang-landing .track.is-lead h2 {
  color: #120d02;
  font-size: 1.55rem;
}

.lang-landing .track.is-day h2 {
  font-size: 1.15rem;
  margin-bottom: 0.35rem;
}

.lang-landing .len {
  font-size: 0.95rem;
}

.lp-player {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas:
    "play time"
    "bar bar";
  gap: 0.35rem 0.75rem;
  align-items: center;
}

.lp-play {
  grid-area: play;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  box-sizing: border-box;
  min-height: 48px;
  min-width: 44px;
  padding: 0.55rem 1.15rem;
  border: 0;
  border-radius: 999px;
  background: var(--ll-gold);
  color: #000;
  font: inherit;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
}

.lp-play svg {
  display: block;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.lang-landing .track.is-lead .lp-play {
  background: #120d02;
  color: #f8e7a8;
}

.lang-landing .track.is-lead .lp-time { color: rgba(18, 13, 2, 0.72); }

.lang-landing .track.is-lead .lp-range::-webkit-slider-runnable-track {
  background: linear-gradient(90deg, #120d02 var(--lp), rgba(18, 13, 2, 0.28) var(--lp));
}
.lang-landing .track.is-lead .lp-range::-webkit-slider-thumb { background: #120d02; }
.lang-landing .track.is-lead .lp-range::-moz-range-track { background: rgba(18, 13, 2, 0.28); }
.lang-landing .track.is-lead .lp-range::-moz-range-progress { background: #120d02; }
.lang-landing .track.is-lead .lp-range::-moz-range-thumb { background: #120d02; }

.lp-play .lp-icon-pause { display: none; }
.lp-play.is-playing .lp-icon-play { display: none; }
.lp-play.is-playing .lp-icon-pause { display: block; }

.lp-play:focus-visible,
.lang-landing .cta:focus-visible,
.lp-more-en:focus-visible,
.dd-share:focus-visible,
.tabbar a:focus-visible,
.tabbar button:focus-visible,
.more-sheet-list a:focus-visible,
.more-back:focus-visible {
  outline: 2px solid var(--ll-gold);
  outline-offset: 3px;
}

.lp-time {
  grid-area: time;
  color: rgba(245, 236, 215, 0.8);
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
}

.lp-bar {
  grid-area: bar;
  display: flex;
  align-items: center;
  min-height: 44px;
  margin: 0;
}

.lp-range {
  --lp: 0%;
  width: 100%;
  height: 44px;
  margin: 0;
  background: transparent;
  cursor: pointer;
  accent-color: var(--ll-gold);
  -webkit-appearance: none;
  appearance: none;
}

.lp-range::-webkit-slider-runnable-track {
  height: 4px;
  background: linear-gradient(90deg, var(--ll-gold) var(--lp), rgba(232, 200, 120, 0.35) var(--lp));
  border-radius: 999px;
}

.lp-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -7px;
  border: 0;
  border-radius: 50%;
  background: var(--ll-gold);
}

.lp-range::-moz-range-track {
  height: 4px;
  background: rgba(232, 200, 120, 0.35);
  border-radius: 999px;
}

.lp-range::-moz-range-progress {
  height: 4px;
  background: var(--ll-gold);
  border-radius: 999px;
}

.lp-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 0;
  border-radius: 50%;
  background: var(--ll-gold);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.lp-audio {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.lang-landing .cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 48px;
  min-width: 44px;
  padding: 0.6rem 1.4rem;
  border-radius: 999px;
  background: var(--ll-gold);
  color: #000;
  text-decoration: none;
  font-weight: 400;
}

/* Quiet text link into the full English library. Doors, chips, and length
   filters stay off until a language has at least 12 meditations. */
.lp-more { margin: 0.4rem 0 0.2rem; text-align: center; }
.lp-more-en {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 44px;
  min-width: 44px;
  padding: 0.35rem 0.7rem;
  color: rgba(232, 200, 120, 0.82);
  font-size: 0.98rem;
  text-decoration: underline;
  text-decoration-color: rgba(232, 200, 120, 0.4);
  text-underline-offset: 4px;
}
.lang-landing .lib-doors,
.lang-landing .lib-chip-row,
.lang-landing .lib-len-row,
.lang-landing .lib-any-line,
.lang-landing [data-lib-door],
.lang-landing [data-lib-chip],
.lang-landing [data-lib-len] { display: none !important; }
.lang-landing[data-lang-layout="full"] .lib-doors,
.lang-landing[data-lang-layout="full"] .lib-chip-row { display: flex !important; }
.lang-landing[data-lang-layout="full"] .lib-len-row { display: grid !important; }
.lang-landing[data-lang-layout="full"] .lib-any-line { display: block !important; }
.lang-landing[data-lang-layout="full"] [data-lib-door],
.lang-landing[data-lang-layout="full"] [data-lib-chip],
.lang-landing[data-lang-layout="full"] [data-lib-len] { display: inline-flex !important; }

.dd-share {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 48px;
  min-width: 44px;
  padding: 0.6rem 1.4rem;
  border-radius: 999px;
  border: 1px solid var(--ll-gold);
  background: transparent;
  color: var(--ll-ink);
  font: inherit;
  cursor: pointer;
}

.lang-landing .langs {
  margin-top: 1.6rem;
  font-size: 0.95rem;
}

.lang-landing .langs a {
  color: var(--ll-gold);
  display: inline-flex;
  min-height: 44px;
  min-width: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 0.35rem;
}

.tabbar {
  position: fixed;
  z-index: 40;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(100%, 28rem);
  display: flex;
  align-items: stretch;
  gap: 0;
  padding: 0.15rem 0.2rem var(--ll-chrome);
  border-top: 1px solid rgba(236, 184, 62, 0.16);
  background: #000;
}

.tabbar a,
.tabbar button {
  flex: 1 1 0;
  min-width: 44px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0.16rem;
  box-sizing: border-box;
  min-height: 48px;
  padding: 0.34rem 0.06rem 0.18rem;
  border: 0;
  background: none;
  color: rgba(236, 184, 62, 0.66);
  font-family: Outfit, system-ui, sans-serif;
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  line-height: 1.15;
  text-transform: uppercase;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.tabbar a[aria-current="page"],
.tabbar button[aria-current="page"],
.tabbar a.is-current {
  color: rgb(236, 184, 62);
}

.tabbar svg {
  display: block;
  width: 1.15rem;
  height: 1.15rem;
  flex: 0 0 auto;
}

.more-sheet {
  position: fixed;
  z-index: 39;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(100%, 28rem);
  height: 100%;
  pointer-events: none;
}

.more-sheet[hidden] { display: none; }

.more-sheet-backdrop {
  position: absolute;
  inset: 0;
  bottom: calc(3.35rem + var(--ll-chrome));
  background: rgba(0, 0, 0, 0.46);
  pointer-events: auto;
}

.more-sheet-panel {
  position: absolute;
  left: 0.55rem;
  right: 0.55rem;
  bottom: calc(3.45rem + var(--ll-chrome));
  pointer-events: auto;
  border: 1px solid rgba(232, 200, 120, 0.55);
  border-radius: 18px;
  background: #0c0a08;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  color: var(--ll-ink);
}

.more-sheet-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.85rem 0.55rem;
}

.more-sheet-title {
  margin: 0;
  color: var(--ll-gold);
  font-size: 1.45rem;
  font-weight: 500;
  line-height: 1;
}

.more-back {
  box-sizing: border-box;
  min-height: 44px;
  min-width: 44px;
  padding: 0 0.8rem;
  border: 1px solid rgba(232, 200, 120, 0.55);
  border-radius: 999px;
  background: transparent;
  color: var(--ll-ink);
  font: inherit;
  cursor: pointer;
}

.more-sheet-list {
  display: flex;
  flex-direction: column;
  padding: 0 0.35rem 0.45rem;
}

.more-sheet-list a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-sizing: border-box;
  min-height: 44px;
  min-width: 44px;
  padding: 0 0.7rem;
  border-top: 1px solid rgba(236, 184, 62, 0.16);
  color: var(--ll-ink);
  font-size: 0.98rem;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.more-sheet-list svg {
  width: 1.2rem;
  height: 1.2rem;
  flex: 0 0 auto;
  color: var(--ll-gold);
}

@media (prefers-reduced-motion: reduce) {
  .lp-play,
  .lang-landing .cta,
  .lp-more-en,
  .dd-share,
  .lang-landing .langs a,
  .tabbar a,
  .tabbar button,
  .more-sheet,
  .more-sheet-panel,
  .more-back {
    transition: none;
    animation: none;
  }
}

/* v489: Punjabi landing only. Same scale as /sit. Noto Sans Gurmukhi
   is already on this page (font-display: swap, Gurmukhi family). */
html[lang="pa"] .lang-landing,
html[lang="pa"] .lang-landing button {
  font-family: "Noto Sans Gurmukhi", "Outfit", system-ui, sans-serif;
  font-weight: 400;
}
html[lang="pa"] .lang-landing h1,
html[lang="pa"] .lang-landing h2 {
  font-family: "Noto Sans Gurmukhi", "Cormorant Garamond", serif;
  font-weight: 400;
  letter-spacing: 0;
  overflow-wrap: break-word;
}
html[lang="pa"] .lang-landing h1 {
  font-size: clamp(2rem, 8vw, 2.55rem);
  line-height: 1.45;
}
html[lang="pa"] .lang-landing .intro,
html[lang="pa"] .lang-landing .lp-guide,
html[lang="pa"] .lang-landing .lp-more-en,
html[lang="pa"] .lang-landing .lp-time {
  font-size: 20px;
  font-weight: 400;
  line-height: 1.65;
  letter-spacing: 0;
}
html[lang="pa"] .lang-landing .track h2,
html[lang="pa"] .lang-landing .track.is-day h2 {
  font-size: 1.5rem;
  line-height: 1.5;
}
html[lang="pa"] .lang-landing .track.is-lead h2 {
  font-size: 1.75rem;
  line-height: 1.45;
}
html[lang="pa"] .lang-landing .lp-play,
html[lang="pa"] .lang-landing .dd-share {
  font-size: 20px;
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: 0;
  min-height: 48px;
  min-width: 44px;
}
