/*
 * Locus V56 · source-led discovery
 *
 * This layer is intentionally home-only. Detail, notes, plan and relay screens keep the
 * established DS1 component contract; the discovery surface gets its own consumer layout.
 */

.home-screen {
  --home-canvas: #f6f7f5;
  --home-surface: #ffffff;
  --home-surface-soft: #eef1ee;
  --home-ink: #171a18;
  --home-ink-2: #505854;
  --home-ink-3: #727a76;
  --home-line: #dfe4e0;
  --home-line-strong: #cbd2cd;
  --home-brand: #087b68;
  --home-brand-soft: #e3f3ef;
  --home-brand-ink: #075f52;
  --home-warning: #9a6508;
  --home-warning-soft: #fff5d8;
  --home-danger: #a74650;
  --home-radius: 16px;
  --home-shadow: 0 1px 2px rgb(16 24 20 / 4%), 0 12px 36px rgb(16 24 20 / 6%);
  min-height: 100dvh;
  color: var(--home-ink);
  background: var(--home-canvas);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
}

body:has(.home-screen) {
  background: var(--home-canvas, #f6f7f5);
}

.home-screen .shell-width {
  width: min(1200px, calc(100% - 48px));
  max-width: none;
  margin-inline: auto;
}

.home-screen .site-header {
  min-height: 64px;
  border-bottom: 1px solid color-mix(in srgb, var(--home-line) 82%, transparent);
  color: var(--home-ink);
  background: color-mix(in srgb, var(--home-canvas) 92%, transparent);
  box-shadow: none;
  backdrop-filter: blur(18px) saturate(1.15);
}

.home-screen .site-header__inner {
  width: min(1200px, calc(100% - 48px));
  min-height: 64px;
}

.home-screen .brand-mark,
.home-screen .site-nav a,
.home-screen .header-actions a,
.home-screen .matrix-button {
  color: var(--home-ink);
}

.home-screen .site-nav a {
  min-height: 40px;
  padding-inline: 14px;
  border-radius: 10px;
  font-size: 13px;
}

.home-screen .site-nav a[aria-current="page"] {
  color: var(--home-brand-ink);
  background: var(--home-brand-soft);
  box-shadow: none;
}

.home-screen .header-actions > a,
.home-screen .matrix-button {
  min-height: 40px;
  border-color: var(--home-line);
  border-radius: 10px;
  background: var(--home-surface);
  box-shadow: 0 1px 2px rgb(16 24 20 / 4%);
}

.home-screen .header-actions > a:last-child {
  color: #fff;
  border-color: var(--home-ink);
  background: var(--home-ink);
}

.home-screen #main {
  padding-bottom: 56px;
}

/* Compact context header --------------------------------------------------- */

.home-screen .home-deck {
  margin-top: 18px;
  padding: 0;
}

.home-screen .home-deck__frame {
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.home-screen .home-deck .home-intro {
  display: flex;
  min-height: 66px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 4px 2px 12px;
  border: 0;
  background: transparent;
}

.home-screen .home-deck .home-intro__mast {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.home-screen .home-deck .home-intro__mast > .eyebrow {
  display: block;
  margin: 0;
  color: var(--home-ink-3);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

.home-screen .home-deck h1 {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 10px;
  margin: 0;
  color: var(--home-ink);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: 30px;
  font-weight: 720;
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.home-screen .home-title-kicker {
  color: var(--home-ink);
}

.home-screen .home-title-date {
  color: var(--home-ink-2);
  font-size: 17px;
  font-weight: 620;
  letter-spacing: -0.02em;
}

.home-screen .home-title-weekday {
  color: var(--home-ink-3);
  font-size: 13px;
  font-weight: 560;
  letter-spacing: 0;
}

.home-screen .home-deck .home-intro__statusline {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 18px;
  padding: 0;
  color: var(--home-ink-2);
  text-align: right;
}

.home-screen .home-intro__edition {
  display: flex;
  min-height: 40px;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--home-ink-2);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.home-screen .home-intro__edition strong {
  color: var(--home-ink);
  font-weight: 650;
}

.home-screen .home-intro__edition i {
  color: var(--home-line-strong);
  font-style: normal;
}

.home-screen .home-deck .home-intro__meta {
  display: block;
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--home-ink-3);
  font-size: 11px;
}

.home-screen .home-deck .home-intro__meta a {
  display: grid;
  min-height: 44px;
  align-content: center;
  justify-items: end;
  color: var(--home-ink-3);
}

.home-screen .home-deck .home-intro__meta a strong {
  color: var(--home-brand-ink);
  font-size: 11px;
  text-decoration: none;
}

.home-screen .home-deck .scope-bar {
  display: flex;
  min-height: 52px;
  align-items: center;
  justify-content: space-between;
  padding: 3px 7px;
  border: 1px solid var(--home-line);
  border-radius: 14px;
  color: var(--home-ink);
  background: var(--home-surface);
  box-shadow: 0 1px 2px rgb(16 24 20 / 3%), 0 8px 28px rgb(16 24 20 / 4%);
}

.home-screen .home-deck .scope-tabs,
.home-screen .home-deck .unit-switch {
  display: flex;
  align-items: center;
  gap: 3px;
}

.home-screen .scope-dimension--unit {
  order: 10;
  margin: 0 6px 0 0;
  padding: 0 0 0 7px;
  border: 0;
  border-left: 1px solid var(--home-line);
  background: transparent;
}

.home-screen:not(.home-screen--week) .unit-switch a[aria-current="page"],
.home-screen--week .unit-switch a[aria-current="page"] {
  display: none;
}

.home-screen--week .scope-dimension--unit {
  order: -1;
  margin: 0 6px 0 0;
  padding: 0 7px 0 0;
  border-right: 1px solid var(--home-line);
  border-left: 0;
}

.home-screen .unit-label-full {
  display: inline;
}

.home-screen .unit-label-short {
  display: none;
}

.home-screen .scope-dimension__label {
  display: none;
}

.home-screen .home-deck .unit-switch a,
.home-screen .home-deck .scope-tabs > a {
  min-width: 52px;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: 9px;
  color: var(--home-ink-2);
  background: transparent;
  font-size: 12px;
  font-weight: 630;
  box-shadow: none;
}

.home-screen .home-deck .scope-tabs > a small {
  margin-left: 5px;
  color: var(--home-ink-3);
  font-size: 9px;
}

.home-screen .home-deck .unit-switch a[aria-current="page"],
.home-screen .home-deck .scope-tabs > a[aria-current="page"] {
  color: var(--home-brand-ink);
  background: var(--home-brand-soft);
  box-shadow: none;
}

.home-screen .home-deck .unit-switch a:hover,
.home-screen .home-deck .scope-tabs > a:hover {
  color: var(--home-ink);
  background: var(--home-surface-soft);
}

.home-screen .home-deck .scope-tools {
  align-self: stretch;
}

.home-screen .home-deck .filter-control {
  min-width: 126px;
  min-height: 44px;
  align-self: center;
  justify-content: center;
  gap: 8px;
  padding: 0 10px;
  border: 0;
  border-radius: 9px;
  color: var(--home-ink-2);
  background: var(--home-surface-soft);
  font-size: 11px;
}

.home-screen .filter-control__icon {
  width: 20px;
  height: 20px;
  border: 0;
  border-radius: 6px;
  color: var(--home-ink-2);
  background: transparent;
}

.home-screen .home-deck .filter-control[aria-pressed="true"] {
  color: var(--home-brand-ink);
  background: var(--home-brand-soft);
}

.home-screen .home-deck .filter-control[aria-pressed="true"] .filter-control__icon {
  color: var(--home-brand-ink);
  background: transparent;
}

/* Section rhythm ---------------------------------------------------------- */

.home-screen .home-grid--program {
  display: block;
  margin-top: 14px;
  padding-inline: 0;
}

.home-screen .home-grid--program .fixed-field {
  width: 100%;
}

.home-screen .section-heading {
  display: flex;
  min-height: 46px;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 0 2px 12px;
  border: 0;
  color: var(--home-ink);
}

.home-screen .section-heading .eyebrow {
  display: block;
  margin: 0 0 4px;
  color: var(--home-ink-3);
  font-size: 10px;
  font-weight: 590;
  letter-spacing: 0;
  text-transform: none;
}

.home-screen .section-heading h2 {
  color: var(--home-ink);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.home-screen .section-heading > span {
  padding: 0 0 2px;
  color: var(--home-ink-3);
  font-size: 11px;
}

.home-screen:not(.home-screen--week) .coordinate-field {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: 0;
}

.home-screen:not(.home-screen--week) .coordinate-field > .now-marker {
  display: none;
}

/* Image-led fixed events -------------------------------------------------- */

.home-screen .program-entry {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 0;
  height: 252px;
  min-height: 252px;
  grid-template-columns: 128px minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
  margin: 0;
  padding: 8px;
  overflow: hidden;
  border: 1px solid var(--home-line);
  border-radius: var(--home-radius);
  color: var(--home-ink);
  background: var(--home-surface);
  box-shadow: var(--home-shadow);
  transition: transform 380ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 380ms cubic-bezier(0.22, 1, 0.36, 1), border-color 380ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-screen .program-entry::before {
  display: none;
}

.home-screen .program-entry:hover {
  z-index: 1;
  border-color: var(--home-line-strong);
  background: var(--home-surface);
  box-shadow: 0 2px 4px rgb(16 24 20 / 5%), 0 18px 48px rgb(16 24 20 / 10%);
  transform: translateY(-3px);
}

.home-screen .program-entry .coordinate-row__main {
  border-radius: calc(var(--home-radius) - 1px);
}

.home-screen .program-entry .coordinate-row__main:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--home-brand) 78%, white);
  outline-offset: -4px;
  border-radius: calc(var(--home-radius) - 2px);
}

.home-screen .program-entry .row-cover--official {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 234px;
  grid-column: 1;
  grid-row: 1;
  margin: 0;
  overflow: hidden;
  border-radius: 11px;
  background: var(--home-surface-soft);
}

.home-screen .program-entry .row-cover--official img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transform: scale(1.001);
  transition: transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-screen .program-entry:hover .row-cover--official img {
  transform: scale(1.025);
}

.home-screen .program-entry .coordinate-time {
  position: static;
  display: flex;
  min-width: 0;
  grid-column: 2;
  grid-row: 1;
  align-self: start;
  align-items: baseline;
  justify-content: flex-start;
  flex-direction: row;
  gap: 8px;
  padding: 14px 88px 0 16px;
  border: 0;
  color: var(--home-ink);
  text-align: left;
}

.home-screen .program-entry .coordinate-time strong {
  color: var(--home-ink);
  font-family: "SFMono-Regular", "JetBrains Mono", ui-monospace, monospace;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 18px;
}

.home-screen .program-entry .coordinate-time span {
  margin: 0;
  color: var(--home-ink-3);
  font-family: "SFMono-Regular", "JetBrains Mono", ui-monospace, monospace;
  font-size: 9px;
}

.home-screen .program-entry .coordinate-axis,
.home-screen .program-entry .row-enter {
  display: none;
}

.home-screen .program-entry .coordinate-copy {
  display: block;
  min-width: 0;
  grid-column: 2;
  grid-row: 1;
  align-self: stretch;
  padding: 44px 16px 58px;
}

.home-screen .program-entry .row-status {
  position: static;
  display: none;
  min-height: 18px;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  margin: 0 0 8px;
}

.home-screen .program-entry .row-kind,
.home-screen .program-entry .src-stamp {
  display: none;
}

.home-screen .program-entry .row-status .truth-label,
.home-screen .program-entry .row-status .row-featured,
.home-screen .program-entry .row-status .row-commitment,
.home-screen .program-entry .row-status .row-expired,
.home-screen .program-entry .row-status .row-live {
  min-height: 22px;
  padding: 2px 7px;
  border: 0;
  border-radius: 6px;
  color: var(--home-ink-2);
  background: var(--home-surface-soft);
  font-size: 9px;
  line-height: 16px;
}

.home-screen .program-entry .row-featured {
  color: var(--home-brand-ink);
  background: var(--home-brand-soft);
}

.home-screen .program-entry .coordinate-copy h3 {
  display: -webkit-box;
  max-width: none;
  margin: 0;
  overflow: hidden;
  color: var(--home-ink);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: clamp(18px, 1.55vw, 22px);
  font-weight: 710;
  letter-spacing: -0.025em;
  line-height: 1.34;
  transform: none;
  transition: color 240ms cubic-bezier(0.22, 1, 0.36, 1);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.home-screen .program-entry:hover .coordinate-copy h3 {
  color: var(--home-brand-ink);
  transform: none;
}

.home-screen .program-entry .place-vector {
  display: grid;
  grid-template-columns: 9px minmax(0, 1fr);
  gap: 7px;
  margin: 10px 0 0;
}

.home-screen .program-entry .place-vector__line {
  width: 9px;
  height: 1px;
  align-self: center;
  background: var(--home-brand);
}

.home-screen .program-entry .place-vector strong {
  color: var(--home-ink-2);
  font-size: 11px;
  font-weight: 610;
}

.home-screen .program-entry .place-vector small {
  display: none;
}

.home-screen .program-entry .row-meta {
  display: block;
  margin-top: 8px;
}

.home-screen .program-entry .access-line {
  color: var(--home-ink-3);
  font-size: 11px;
  line-height: 1.45;
}

.home-screen .program-entry .source-line {
  display: none;
}

.home-screen .program-entry > .access-badge {
  position: absolute;
  z-index: 4;
  top: 15px;
  right: 15px;
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 0 7px;
  border-radius: 6px;
  font-size: 9px;
}

.home-screen .program-entry__actions {
  position: relative;
  z-index: 4;
  display: flex;
  min-width: 0;
  width: auto;
  grid-column: 2;
  grid-row: 1;
  align-self: end;
  align-items: center;
  justify-content: flex-start;
  flex-direction: row;
  gap: 8px;
  padding: 0 12px 8px 16px;
}

.home-screen .program-entry__actions .row-primary-action {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  left: auto;
  display: inline-flex;
  min-width: 102px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin: 0;
  padding: 0 12px;
  border: 1px solid var(--home-brand);
  border-radius: 10px;
  color: #fff;
  background: var(--home-brand);
  font-size: 10px;
  font-weight: 680;
  cursor: pointer;
  box-shadow: none;
}

.home-screen .program-entry__actions .row-primary-action::after {
  content: "↗";
  display: inline;
  width: auto;
  height: auto;
  flex: 0 0 auto;
  margin: 0;
  color: #fff;
  background: transparent;
  font-size: 12px;
  transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-screen .program-entry__actions .row-primary-action:hover {
  color: #fff;
  border-color: var(--home-brand-ink);
  background: var(--home-brand-ink);
  transform: none;
}

.home-screen .program-entry__actions .row-primary-action:hover::after {
  transform: translate(2px, -2px);
}

.home-screen .program-entry__actions .row-primary-action--done {
  color: var(--home-brand-ink);
  border-color: var(--home-brand-soft);
  background: var(--home-brand-soft);
}

.home-screen .program-entry__actions .row-primary-action--done::after {
  color: var(--home-brand-ink);
  background: color-mix(in srgb, var(--home-brand) 10%, transparent);
}

.home-screen .program-entry__actions .row-notes-link {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  left: auto;
  display: inline-flex;
  min-width: 64px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin: 0;
  color: var(--home-ink-3);
  font-size: 9px;
}

/* A source image is an enhancement, never a layout requirement. */
.home-screen .program-entry:not(.coordinate-row--has-artwork) {
  height: auto;
  min-height: 180px;
  grid-template-columns: minmax(0, 1fr);
}

.home-screen .program-entry:not(.coordinate-row--has-artwork) .coordinate-time,
.home-screen .program-entry:not(.coordinate-row--has-artwork) .coordinate-copy,
.home-screen .program-entry:not(.coordinate-row--has-artwork) .program-entry__actions {
  grid-column: 1;
}

/* Exhibition shelves ------------------------------------------------------ */

.home-screen .flex-field {
  margin-top: 34px;
  padding-inline: 0;
}

.home-screen .venue-program {
  display: block;
  margin: 0;
  padding: 22px 0 4px;
  border: 0;
  background: transparent;
}

.home-screen .venue-program + .venue-program {
  margin-top: 26px;
}

.home-screen .venue-program__head {
  display: flex;
  min-height: 44px;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 0 2px 12px;
}

.home-screen .venue-program__head .eyebrow {
  display: none;
}

.home-screen .venue-program__head h3 {
  max-width: none;
  margin: 0;
  color: var(--home-ink);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: 17px;
  font-weight: 680;
  letter-spacing: -0.02em;
}

.home-screen .venue-program__head > span {
  margin: 0;
  color: var(--home-ink-3);
  font-size: 10px;
  line-height: 1.4;
  text-align: right;
}

.home-screen .venue-program__list,
.home-screen .flex-venue-group--single .venue-program__list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.home-screen .exhibition-entry {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 0;
  min-height: 250px;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
  gap: 0;
  margin: 0;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 12px;
  color: var(--home-ink);
  background: transparent;
  box-shadow: none;
  transition: transform 360ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 360ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-screen .exhibition-entry::before,
.home-screen .exhibition-entry .coordinate-axis,
.home-screen .exhibition-entry .row-enter {
  display: none;
}

.home-screen .exhibition-entry:hover {
  z-index: 1;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  transform: translateY(-3px);
}

.home-screen .exhibition-entry .coordinate-row__main {
  border-radius: 14px;
}

.home-screen .exhibition-entry .coordinate-row__main:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--home-brand) 78%, white);
  outline-offset: -4px;
  border-radius: 13px;
}

.home-screen .exhibition-entry .row-cover--official {
  position: relative;
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 5 / 2;
  grid-column: 1;
  grid-row: 1;
  margin: 0;
  overflow: hidden;
  border-radius: 12px;
  background: var(--home-surface-soft);
}

.home-screen .exhibition-entry .row-cover--official img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
}

.home-screen .exhibition-entry:hover .row-cover--official img {
  transform: scale(1.025);
}

.home-screen .exhibition-entry .coordinate-time {
  position: absolute;
  z-index: 3;
  top: 16px;
  left: 16px;
  display: none;
}

.home-screen .exhibition-entry .coordinate-copy {
  display: block;
  min-width: 0;
  grid-column: 1;
  grid-row: 2;
  align-self: stretch;
  padding: 13px 2px 48px;
}

.home-screen .exhibition-entry .row-status {
  position: static;
  display: none;
  min-height: 18px;
  justify-content: flex-start;
  gap: 6px;
  margin: 0 0 6px;
}

.home-screen .exhibition-entry .row-kind,
.home-screen .exhibition-entry .src-stamp {
  display: none;
}

.home-screen .exhibition-entry .row-status .truth-label,
.home-screen .exhibition-entry .row-status .row-featured,
.home-screen .exhibition-entry .row-status .row-commitment,
.home-screen .exhibition-entry .row-status .row-expired,
.home-screen .exhibition-entry .row-status .row-live {
  min-height: 20px;
  padding: 1px 6px;
  border: 0;
  border-radius: 5px;
  color: var(--home-ink-2);
  background: var(--home-surface-soft);
  font-size: 8px;
}

.home-screen .exhibition-entry .coordinate-copy h3 {
  display: block;
  max-width: none;
  margin: 0;
  color: var(--home-ink);
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 680;
  letter-spacing: -0.02em;
  line-height: 1.38;
  transform: none;
  -webkit-line-clamp: unset;
}

.home-screen .exhibition-entry:hover .coordinate-copy h3 {
  color: var(--home-brand-ink);
  transform: none;
}

.home-screen .exhibition-entry .place-vector {
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr);
  gap: 6px;
  margin: 7px 0 0;
}

.home-screen .exhibition-entry .place-vector__line {
  width: 8px;
  height: 1px;
  align-self: center;
  background: var(--home-brand);
}

.home-screen .exhibition-entry .place-vector strong {
  color: var(--home-ink-2);
  font-size: 10px;
  font-weight: 610;
}

.home-screen .exhibition-entry .place-vector small,
.home-screen .exhibition-entry .row-meta {
  display: none;
}

.home-screen .exhibition-entry .coordinate-copy > .access-badge {
  position: static;
  z-index: auto;
  display: inline-flex;
  min-height: 22px;
  align-items: center;
  margin: 0 0 8px;
  padding: 0 7px;
  border-radius: 6px;
  font-size: 8px;
  backdrop-filter: none;
}

.home-screen .exhibition-entry .program-entry__actions {
  position: relative;
  z-index: 4;
  display: flex;
  width: auto;
  grid-column: 1;
  grid-row: 2;
  align-self: end;
  align-items: center;
  justify-content: flex-start;
  flex-direction: row;
  gap: 8px;
  padding: 0 0 2px 2px;
}

.home-screen .exhibition-entry .program-entry__actions .row-primary-action {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  left: auto;
  display: inline-flex;
  min-width: 112px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0 11px;
  border: 0;
  border-radius: 9px;
  color: var(--home-brand-ink);
  background: var(--home-brand-soft);
  font-size: 9px;
  font-weight: 650;
}

.home-screen .exhibition-entry .program-entry__actions .row-primary-action::after {
  content: "↗";
  margin-left: 8px;
  font-size: 11px;
}

.home-screen .exhibition-entry .program-entry__actions .row-notes-link {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  left: auto;
  display: inline-flex;
  min-width: 52px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 0;
  color: var(--home-ink-3);
  font-size: 8px;
}

.home-screen .exhibition-entry:not(.coordinate-row--has-artwork) {
  min-height: 184px;
  grid-template-rows: minmax(0, 1fr);
}

.home-screen .exhibition-entry:not(.coordinate-row--has-artwork) .coordinate-copy,
.home-screen .exhibition-entry:not(.coordinate-row--has-artwork) .program-entry__actions {
  grid-row: 1;
}

.home-screen .exhibition-entry:not(.coordinate-row--has-artwork) .coordinate-copy {
  padding-top: 18px;
}

/* Week keeps the same visual language at calendar density. */
.home-screen--week .week-strip {
  margin-top: 16px;
}

.home-screen--week .week-strip__row {
  gap: 6px;
  border: 0;
  background: transparent;
}

.home-screen--week .week-strip__cell {
  min-height: 56px;
  border: 1px solid var(--home-line);
  border-radius: 11px;
  color: var(--home-ink);
  background: var(--home-surface);
}

.home-screen--week .week-strip__cell--today {
  color: #fff;
  border-color: var(--home-brand);
  background: var(--home-brand);
}

.home-screen--week .week-strip__cell--today .week-strip__day,
.home-screen--week .week-strip__cell--today .week-strip__date,
.home-screen--week .week-strip__cell--today .week-strip__count {
  color: #fff;
}

.home-screen--week .week-strip__bar {
  display: none;
}

.home-screen--week .home-grid--program {
  margin-top: 16px;
}

.home-screen--week .week-day__head {
  margin-top: 20px;
  padding: 0 2px 10px;
  border-bottom: 1px solid var(--home-line);
  color: var(--home-ink);
}

.home-screen--week .week-day__name {
  font-family: "Instrument Local", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  font-size: 17px;
  font-weight: 680;
}

.home-screen--week .week-day .coordinate-field {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 12px 0 0;
}

.home-screen--week .program-entry {
  height: 228px;
  min-height: 228px;
  grid-template-columns: 118px minmax(0, 1fr);
}

.home-screen--week .program-entry .row-cover--official {
  min-height: 210px;
}

.home-screen--week .program-entry .coordinate-copy {
  padding-inline: 14px;
}

.home-screen--week .program-entry .coordinate-time {
  padding-left: 14px;
}

.home-screen--week .program-entry__actions {
  padding-left: 14px;
}

.home-screen--week .program-entry:not(.coordinate-row--has-artwork) {
  min-height: 168px;
}

.home-screen .data-provenance {
  color: var(--home-ink-2);
  border-color: var(--home-line);
  background: transparent;
}

/* Dark mode: quiet graphite, never neon. --------------------------------- */

html[data-theme="dark"] .home-screen {
    --home-canvas: #111411;
    --home-surface: #191d1a;
    --home-surface-soft: #232824;
    --home-ink: #eff3ef;
    --home-ink-2: #bec7c0;
    --home-ink-3: #919b94;
    --home-line: #2c332e;
    --home-line-strong: #3c463f;
    --home-brand: #59c6b0;
    --home-brand-soft: #183c34;
    --home-brand-ink: #8ee0cf;
    --home-warning: #e3b45a;
    --home-warning-soft: #3d311a;
    --home-danger: #ef9ba4;
    --home-shadow: 0 1px 2px rgb(0 0 0 / 18%), 0 16px 42px rgb(0 0 0 / 18%);
    color-scheme: dark;
}

html[data-theme="dark"] body:has(.home-screen) {
  background: #111411;
}

html[data-theme="dark"] .home-screen .header-actions > a:last-child {
  color: #101410;
  border-color: var(--home-ink);
  background: var(--home-ink);
}

html[data-theme="dark"] .home-screen .program-entry__actions .row-primary-action {
  color: #0f1714;
  border-color: var(--home-brand);
  background: var(--home-brand);
}

html[data-theme="dark"] .home-screen .program-entry__actions .row-primary-action::after {
  color: #0f1714;
  background: rgb(15 23 20 / 12%);
}

html[data-theme="dark"] .home-screen .program-entry__actions .row-primary-action:hover {
  color: #0f1714;
  border-color: #8ee0cf;
  background: #8ee0cf;
}

/* Mobile ------------------------------------------------------------------ */

@media (max-width: 900px) {
  .home-screen {
    padding-bottom: calc(76px + env(safe-area-inset-bottom));
  }

  .home-screen .shell-width,
  .home-screen .site-header__inner {
    width: calc(100% - 28px);
  }

  .home-screen .site-header,
  .home-screen .site-header__inner {
    min-height: 58px;
  }

  .home-screen #main {
    padding-bottom: 34px;
  }

  .home-screen .home-deck {
    margin-top: 10px;
  }

  .home-screen .home-deck .home-intro {
    min-height: 58px;
    gap: 10px;
    padding: 2px 0 9px;
  }

  .home-screen .home-deck .home-intro__mast > .eyebrow {
    font-size: 10px;
  }

  .home-screen .home-deck h1 {
    gap: 7px;
    font-size: 23px;
  }

  .home-screen .home-title-date {
    font-size: 13px;
  }

  .home-screen .home-title-weekday {
    font-size: 10px;
  }

  .home-screen .home-deck .home-intro__statusline {
    gap: 0;
  }

  .home-screen .home-intro__edition {
    display: grid;
    min-height: 38px;
    align-content: center;
    justify-items: end;
    gap: 0;
    font-size: 10.5px;
    line-height: 1.35;
  }

  .home-screen .home-intro__edition i,
  .home-screen .home-deck .home-intro__meta {
    display: none;
  }

  .home-screen .home-deck .scope-bar {
    min-height: 48px;
    padding: 3px;
    overflow: visible;
    border-radius: 12px;
  }

  .home-screen .home-deck .scope-tabs {
    min-width: 0;
    gap: 1px;
  }

  .home-screen .scope-dimension--unit {
    flex: 0 0 auto;
    margin: 0 0 0 2px;
    padding: 0 0 0 3px;
    border-right: 0;
    border-left: 1px solid var(--home-line);
  }

  .home-screen--week .scope-dimension--unit {
    margin: 0 2px 0 0;
    padding: 0 3px 0 0;
    border-right: 1px solid var(--home-line);
    border-left: 0;
  }

  .home-screen .home-deck .unit-switch a,
  .home-screen .home-deck .scope-tabs > a {
    min-width: 44px;
    min-height: 44px;
    padding: 0 8px;
    border-radius: 9px;
    font-size: 10px;
  }

  .home-screen .home-deck .scope-tabs > a small {
    display: none;
  }

  .home-screen .home-deck .filter-control {
    min-width: 60px;
    min-height: 44px;
    padding: 0 7px;
    background: transparent;
  }

  .home-screen .home-deck .filter-control__label {
    display: none;
  }

  .home-screen .home-deck .filter-control__short {
    display: inline;
    font-size: 9px;
  }

  .home-screen .home-grid--program {
    margin-top: 16px;
  }

  .home-screen .section-heading {
    min-height: 40px;
    padding-bottom: 10px;
  }

  .home-screen .section-heading .eyebrow {
    display: none;
  }

  .home-screen .section-heading h2 {
    font-size: 20px;
  }

  .home-screen .section-heading > span {
    max-width: 48%;
    font-size: 10px;
    line-height: 1.35;
    text-align: right;
  }

  .home-screen:not(.home-screen--week) .coordinate-field,
  .home-screen--week .week-day .coordinate-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .home-screen .program-entry,
  .home-screen--week .program-entry {
    min-height: 150px;
    grid-template-columns: 82px minmax(0, 1fr);
    grid-template-rows: minmax(0, 1fr);
    padding: 7px;
    border-radius: 14px;
  }

  .home-screen .program-entry.coordinate-row--has-artwork,
  .home-screen--week .program-entry.coordinate-row--has-artwork {
    height: 160px;
    min-height: 160px;
    max-height: 160px;
  }

  .home-screen .program-entry:hover {
    transform: none;
  }

  .home-screen .program-entry .row-cover--official,
  .home-screen--week .program-entry .row-cover--official {
    min-height: 146px;
    border-radius: 9px;
  }

  .home-screen .program-entry .coordinate-time {
    padding: 9px 72px 0 10px;
  }

  .home-screen .program-entry .coordinate-time strong {
    font-size: 12px;
    line-height: 16px;
  }

  .home-screen .program-entry .coordinate-time span {
    font-size: 8px;
  }

  .home-screen .program-entry .coordinate-time--pending strong {
    font-size: 10px;
    line-height: 16px;
  }

  .home-screen .program-entry .coordinate-copy,
  .home-screen--week .program-entry .coordinate-copy {
    padding: 32px 9px 45px;
  }

  .home-screen .program-entry .row-status {
    min-height: 15px;
    margin-bottom: 4px;
  }

  .home-screen .program-entry .row-status .truth-label,
  .home-screen .program-entry .row-status .row-featured,
  .home-screen .program-entry .row-status .row-commitment,
  .home-screen .program-entry .row-status .row-expired,
  .home-screen .program-entry .row-status .row-live {
    min-height: 18px;
    padding: 1px 5px;
    border-radius: 5px;
    font-size: 8px;
    line-height: 14px;
  }

  .home-screen .program-entry .coordinate-copy h3 {
    font-size: 14px;
    line-height: 1.25;
  }

  .home-screen .program-entry .place-vector {
    margin-top: 6px;
  }

  .home-screen .program-entry .place-vector strong {
    font-size: 9px;
    line-height: 1.35;
  }

  .home-screen .program-entry .row-meta {
    display: none;
  }

  .home-screen .program-entry > .access-badge {
    top: 9px;
    right: 11px;
    min-height: 20px;
    padding-inline: 5px;
    font-size: 8px;
  }

  .home-screen .program-entry__actions,
  .home-screen--week .program-entry__actions {
    padding: 0 6px 2px 9px;
  }

  .home-screen .program-entry__actions .row-primary-action {
    min-width: 88px;
    min-height: 44px;
    padding: 0 10px;
    border-radius: 9px;
    font-size: 9px;
  }

  .home-screen .program-entry__actions .row-primary-action::after {
    width: auto;
    height: auto;
    flex-basis: auto;
    font-size: 10px;
  }

  .home-screen .program-entry__actions .row-notes-link {
    min-width: 48px;
    min-height: 44px;
    font-size: 8px;
  }

  .home-screen .program-entry:not(.coordinate-row--has-artwork) {
    min-height: 150px;
    grid-template-columns: minmax(0, 1fr);
  }

  .home-screen .flex-field {
    margin-top: 20px;
  }

  .home-screen .venue-program {
    padding-top: 10px;
  }

  .home-screen .venue-program + .venue-program {
    margin-top: 20px;
  }

  .home-screen .venue-program__head {
    min-height: 34px;
    padding-bottom: 8px;
  }

  .home-screen .venue-program__head h3 {
    font-size: 15px;
  }

  .home-screen .venue-program__head > span {
    font-size: 8px;
  }

  .home-screen .venue-program__list,
  .home-screen .flex-venue-group--single .venue-program__list {
    display: flex;
    gap: 10px;
    padding: 0 0 5px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-snap-type: inline mandatory;
    scrollbar-width: none;
  }

  .home-screen .venue-program__list::-webkit-scrollbar {
    display: none;
  }

  .home-screen .exhibition-entry {
    width: min(276px, calc(100vw - 62px));
    min-width: min(276px, calc(100vw - 62px));
    min-height: 238px;
    grid-template-rows: auto minmax(0, 1fr);
    flex: 0 0 min(276px, calc(100vw - 62px));
    scroll-snap-align: start;
    border-radius: 14px;
  }

  /* Fully reset the denser V55 mobile specimen rules.  The extra .flex-list
     segment is deliberate: those old selectors otherwise win on specificity. */
  .home-screen .flex-list .exhibition-entry {
    width: min(276px, calc(100vw - 62px));
    min-width: min(276px, calc(100vw - 62px));
    min-height: 238px;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    row-gap: 0;
    padding: 0;
    border-radius: 14px;
  }

  .home-screen .flex-list .exhibition-entry .coordinate-time {
    display: none;
  }

  .home-screen .flex-list .exhibition-entry .coordinate-copy {
    grid-column: 1;
    grid-row: 2;
    align-self: stretch;
    padding: 11px 2px 48px;
  }

  .home-screen .flex-list .exhibition-entry .coordinate-copy h3 {
    display: block;
    overflow: visible;
    font-size: 15px;
    line-height: 1.38;
    -webkit-line-clamp: unset;
  }

  .home-screen .exhibition-entry:hover {
    transform: none;
  }

  .home-screen .exhibition-entry .coordinate-copy {
    padding-top: 11px;
  }

  .home-screen .exhibition-entry:not(.coordinate-row--has-artwork) {
    min-height: 172px;
  }

  .home-screen .exhibition-entry .program-entry__actions .row-primary-action,
  .home-screen .exhibition-entry .program-entry__actions .row-notes-link {
    min-height: 44px;
  }

  .home-screen--week .week-strip {
    margin-top: 10px;
    padding: 0;
    overflow: visible;
  }

  .home-screen--week .week-strip__row {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 4px;
  }

  .home-screen--week .week-strip__cell {
    min-height: 48px;
    border-radius: 9px;
  }

  .home-screen--week .week-strip__link,
  .home-screen--week .week-strip__cell:not(:has(.week-strip__link)) {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 0;
    padding: 4px 5px;
  }

  .home-screen--week .week-strip__day {
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
    font-size: 8px;
  }

  .home-screen--week .week-strip__count {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    font-size: 8px;
  }

  .home-screen--week .week-strip__date {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-self: center;
    font-size: 17px;
  }

  .home-screen--week .home-grid--program {
    margin-top: 8px;
  }

  .home-screen--week .week-day__head {
    margin-top: 8px;
    padding-bottom: 8px;
  }

  .home-screen--week .week-day .coordinate-field {
    padding-top: 8px;
  }

  .home-screen .mobile-nav {
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: none;
    min-height: calc(60px + env(safe-area-inset-bottom));
    margin: 0;
    padding: 0 8px env(safe-area-inset-bottom);
    border: 0;
    border-top: 1px solid var(--home-line);
    border-radius: 0;
    background: color-mix(in srgb, var(--home-surface) 94%, transparent);
    box-shadow: none;
    backdrop-filter: blur(18px) saturate(1.2);
  }

  .home-screen .mobile-nav a {
    border-radius: 0;
    color: var(--home-ink-3);
  }

  .home-screen .mobile-nav a[aria-current="page"] {
    color: var(--home-brand-ink);
    background: transparent;
    box-shadow: none;
  }

  .home-screen .mobile-nav a[aria-current="page"] .mobile-nav__icon {
    position: relative;
  }

  .home-screen .mobile-nav a[aria-current="page"] .mobile-nav__icon::after {
    content: "";
    position: absolute;
    right: -7px;
    bottom: 1px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--home-brand);
  }
}

@media (max-width: 370px) {
  .home-screen .home-deck h1 {
    font-size: 21px;
  }

  .home-screen .home-title-date {
    font-size: 12px;
  }

  .home-screen .program-entry,
  .home-screen--week .program-entry {
    grid-template-columns: 96px minmax(0, 1fr);
  }

  .home-screen .program-entry .coordinate-copy h3 {
    font-size: 14px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .home-screen .home-deck__frame,
  .home-screen .program-entry,
  .home-screen .venue-program {
    animation: home-v56-enter 520ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .home-screen .program-entry:nth-child(2),
  .home-screen .venue-program:nth-child(2) {
    animation-delay: 45ms;
  }

  @keyframes home-v56-enter {
    from {
      opacity: 0;
      transform: translateY(10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
}

@media (forced-colors: active) {
  .home-screen .home-deck .scope-bar,
  .home-screen .program-entry,
  .home-screen .exhibition-entry,
  .home-screen--week .week-strip__cell {
    border: 1px solid CanvasText;
  }

  .home-screen .program-entry__actions .row-primary-action {
    border: 1px solid ButtonText;
  }
}
