.home-title {
  margin: 24px 0;
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: 0;
}

.doors { display: grid; gap: 12px; }
.door { aspect-ratio: 16 / 11; }
.doors > :first-child > img { object-position: 43% 27%; }
.doors > :last-child > img { object-position: 49% 32%; }

.home-agents { margin-top: 32px; }
.home-agents h2 { font-size: var(--fs-h2); line-height: 1.2; }
.home-agents__list {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 12px) / 1.4);
  gap: 12px;
  margin: 13px calc(-1 * var(--gutter)) 0;
  padding: 4px var(--gutter) 12px; /* room for the card focus ring inside the scroller */
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
}
.home-agents__list > li { scroll-snap-align: start; }
.home-agents__list { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
.home-agents__list::-webkit-scrollbar { display: none; } /* WebKit only; standards browsers keep the thin bar */

.section-more { margin-top: var(--s-4); font-weight: 600; }
.section-more a { display: inline-block; padding-block: 11px; margin-block: -11px; text-decoration-thickness: 1px; } /* 44px target, same layout */
.section-more a:hover { text-decoration-thickness: 2px; }

.home-section { margin-top: var(--s-8); }
.home-section > h2 { margin-bottom: var(--s-5); font-size: var(--fs-h2); line-height: 1.2; }

.home-latest, .sector-links { display: grid; gap: var(--s-3); }

.home-how { display: grid; gap: var(--s-6); }
.home-how h3 { font-size: var(--fs-h3); font-weight: 600; }
.home-how ol { margin-top: var(--s-3); padding-left: 1.25em; color: var(--ink-2); max-width: 60ch; }
.home-how li + li { margin-top: var(--s-2); }
.home-how li::marker { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }

.home-close { margin-top: var(--s-8); padding: var(--s-8) 0; background: var(--accent-soft); }
.home-close__inner { display: grid; gap: var(--s-5); }
.home-close h2 { font-size: var(--fs-h2); line-height: 1.2; }
.home-close p { margin-top: var(--s-2); color: var(--ink-2); max-width: 60ch; }
.home-close__actions { display: flex; flex-wrap: wrap; gap: var(--s-3); }
.home-close__actions .btn { flex: 1 1 13em; } /* equal basis wider than the longer label: equal widths side by side, and full width once they wrap */

@media (min-width: 640px) {
  .home-title { margin-top: 13px; font-size: var(--fs-display); line-height: 1.067; text-align: center; }
  .doors { grid-template-columns: 1fr 1fr; gap: 16px; }
  .door { aspect-ratio: 4 / 3; }
  .home-agents__list { grid-auto-columns: calc((100% - 2 * 16px) / 2.5); gap: 16px; }
  .sector-links { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .home-how { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 1024px) {
  .doors {
    grid-template-columns: 759fr 795fr; /* the comp's door proportions */
    gap: clamp(16px, calc(16px + 9 * var(--wide)), 25px);
  }
  .door { aspect-ratio: auto; height: clamp(300px, 22.26vw, 374px); }
  .home-agents { margin-top: 22px; }
  .home-agents__list {
    grid-auto-flow: row;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: clamp(16px, calc(16px + 10 * var(--wide)), 26px);
    margin-inline: 0;
    padding: 0;
    overflow: visible;
    scroll-snap-type: none;
  }
  .home-section, .home-close { margin-top: var(--s-9); }
  .home-close__inner { grid-template-columns: 1fr auto; align-items: center; gap: var(--s-6); }
  .home-close__actions .btn { flex: 1 1 auto; }
}

/* columns step up only when a cell fits its longest content: opportunity terms strips need 2 across from 720 and 4 from 1440, sector labels 4 from 1300 */
@media (min-width: 720px) {
  .home-latest { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (min-width: 1300px) {
  .sector-links { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1440px) {
  .home-latest { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .home-latest, .sector-links, .home-how { gap: clamp(16px, calc(16px + 10 * var(--wide)), 26px); }
}

/* the closing band sits directly on the footer */
body:has(.home-close) .site-footer { margin-top: 0; }
