/* The entry region sits outside the page shell. Scope the palette to the home route. */
html:has(.score-shell[data-page="home"]) #nh-entry {
  --entry-ink: #eee9df;
  --entry-muted: #c4bcb0;
  --entry-bronze: #c6ae8e;
  --entry-rule: #443f36;
  box-sizing: border-box;
  left: auto;
  right: max(12px, env(safe-area-inset-right));
  bottom: max(12px, env(safe-area-inset-bottom));
  width: min(390px, calc(100% - max(12px, env(safe-area-inset-left)) - max(12px, env(safe-area-inset-right))));
  max-height: calc(100svh - max(12px, env(safe-area-inset-top)) - max(12px, env(safe-area-inset-bottom)));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: clamp(16px, 2vw, 23px);
  border: 1px solid #5b5245;
  border-radius: 3px;
  background: linear-gradient(145deg, #201e1a, #141412 65%);
  box-shadow: 0 8px 26px rgb(0 0 0 / 32%);
  color: var(--entry-ink);

  & .nh-e-kicker { color: var(--entry-bronze); font-size: 10px; letter-spacing: .16em; }
  & .nh-e-titel {
    display: block;
    margin: 6px 0 13px;
    color: var(--entry-ink);
    font-size: clamp(19px, 2.2vw, 24px);
    line-height: 1.15;
    text-wrap: balance;
  }
  & .nh-e-titel em { color: var(--entry-bronze); }
  & button {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 2px 9px;
    min-height: 46px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--entry-rule);
    color: var(--entry-ink);
    font-size: 12px;
    letter-spacing: .065em;
    line-height: 1.35;
  }
  & button b {
    color: var(--entry-muted);
    font-size: 10px;
    letter-spacing: .06em;
    text-align: right;
  }
  & button:last-of-type { border-bottom: 0; }
  & .nh-e-both { background: #2b2822; border-bottom-color: #655948; }
  & .nh-e-both .nh-e-mark {
    position: static;
    grid-column: 1 / -1;
    color: var(--entry-bronze);
    font-size: 10px;
    letter-spacing: .12em;
  }
  & .nh-e-both span { color: var(--entry-ink); }
  & .nh-e-both b { color: #dec8ab; }
  & .nh-e-quiet { color: var(--entry-muted); }
  & button:focus-visible { outline: 2px solid #e0c8a9; outline-offset: -2px; }
  & button:active { background: #38332b; }
  @media (hover: hover) {
    & button:hover { background: #322e27; }
  }
  @media (min-width: 760px) {
    right: max(22px, env(safe-area-inset-right));
    bottom: max(22px, env(safe-area-inset-bottom));
  }
  @media (max-height: 480px) {
    & .nh-e-kicker { display: none; }
    & .nh-e-titel { margin: 0 0 8px; font-size: 18px; }
    & button { min-height: 44px; }
  }
}
