/* The home page's bands (stage 3 spec 5), after site-picture.css. */

/* A tag on a tile takes the tile's edge colour. The icons are flag blue, which vanishes on the
   tile, so a filter turns them white. */
.band .tag { background: var(--blue-line); color: var(--on-blue); }
.tile .tag { justify-self: start; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(16rem, 100%), 1fr)); gap: var(--space-4); }
.tile {
  display: grid; gap: 10px; align-content: start; padding: var(--space-5); border-radius: var(--radius-card);
  background: var(--blue-2); border: 1px solid var(--blue-line); color: var(--on-blue); text-decoration: none;
  transition: transform 0.15s var(--ease), border-color 0.15s;
}
.tile:hover { transform: translateY(-3px); border-color: var(--on-blue-2); color: var(--on-blue); }
.tile img { inline-size: 34px; block-size: 34px; filter: brightness(0) invert(1); }
.tile h3 { font-size: var(--text-lg); letter-spacing: var(--track-lg); margin: 0; }

/* Eleven bands sit closer than stage 1's six, to keep the page within spec 2's heights. */
main:has(.hero) > .section:not(.hero) { padding-block: var(--space-8); }
main:has(.hero) .head { margin-block-end: var(--space-6); }
main:has(.hero) .faq summary { padding-block: var(--space-4); }
main:has(.hero) .tint + .arc { background: var(--paper-2); }
@media (max-width: 559px) {
  main:has(.hero) > .section:not(.hero) { padding-block: var(--space-7); }
  main:has(.hero) .tile { grid-template-columns: 34px minmax(0, 1fr); align-items: center; column-gap: var(--space-3); padding: var(--space-4); }
  main:has(.hero) .tile > :not(img, h3) { grid-column: 1 / -1; }
  main:has(.hero) :is(.tile, .fours .card, .step) p, main:has(.hero) .fact p:not(.fact__value) { font-size: var(--text-sm); }
  main:has(.hero) .ticks { gap: var(--space-2); }
  main:has(.hero) :is(.plan, .fours .card) { padding: var(--space-4); }
}

/* What it already knows: three facts. */
.facts { display: grid; gap: var(--space-6); }
@media (min-width: 860px) {
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-7); }
  .fact + .fact { padding-inline-start: var(--space-7); border-inline-start: 1px solid var(--line); }
}
.fact > *, .step > *, .result > * { margin: 0; }
.fact > * + * { margin-block-start: var(--space-3); }
.fact p, .step p { color: var(--ink-2); }
.fact .fact__value { color: var(--blue); font-size: var(--text-xl); font-weight: 700; line-height: var(--leading-tight); letter-spacing: var(--track-lg); }
.chips { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.chip { padding: 2px var(--space-3); border-radius: var(--radius-pill); background: var(--paper-2); font-size: var(--text-sm); font-weight: 500; }

/* How it works in three pictures; below 860px each picture sits beside its words. */
.how { display: grid; gap: var(--space-5); counter-reset: step; }
.step { counter-increment: step; display: grid; gap: var(--space-3); align-content: start; }
.step__pic { display: grid; place-items: center; align-content: center; gap: var(--space-2); padding: var(--space-5) var(--space-4); background: var(--card); border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.step__art { inline-size: 100%; max-inline-size: 13rem; }
.step__chip { padding: 2px var(--space-3); border-radius: var(--radius-inline); background: var(--code); font-size: var(--text-sm); }
.step h3 { display: flex; align-items: center; gap: var(--space-3); margin-block-start: var(--space-2); font-size: var(--text-lg); letter-spacing: var(--track-lg); }
.step h3::before { content: counter(step); display: grid; place-items: center; flex: none; inline-size: 2rem; block-size: 2rem; border-radius: 50%; background: var(--blue); color: var(--on-blue); font-size: 1rem; }
.how__more { margin: var(--space-5) auto 0; text-align: center; }
@media (min-width: 860px) { .how { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 859px) {
  .step { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); column-gap: var(--space-4); }
  .step__pic { grid-row: span 2; align-self: start; padding: var(--space-3); }
  .step__chip { font-size: var(--text-xs); }
}

/* Words beside their evidence from 860px, before the tabs, whose rules must win. */
.split { display: grid; gap: var(--space-6); align-items: center; }
.split > * { min-inline-size: 0; }
.card.split { padding: clamp(var(--space-4), 4vw, var(--space-7)); }
.split :is(h2, h3), .result h3 { font-size: var(--text-xl); line-height: var(--leading-tight); letter-spacing: var(--track-lg); margin: 0; }
@media (min-width: 860px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--figure { grid-template-columns: auto 1fr; gap: var(--space-8); }
}
.fours { display: grid; gap: var(--space-4); }
@media (min-width: 560px) { .fours { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .fours { grid-template-columns: repeat(4, 1fr); } }
.fragment { padding: clamp(var(--space-3), 3vw, var(--space-5)); border-radius: var(--radius-panel); background: var(--paper-2); }
.fragment .table { background: var(--card); }
.big-number { margin: 0; font-size: var(--text-3xl); font-weight: 700; line-height: 1; color: var(--blue); }
.big-number small { display: block; margin-block-start: var(--space-2); font-size: var(--text-sm); line-height: 1.4; color: var(--ink-2); }

/* The results: each picture under its words, side by side from 1000px. */
.results { display: grid; gap: var(--space-7); }
@media (min-width: 1000px) { .results { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-8); } }
.result { display: grid; gap: var(--space-4); align-content: start; min-inline-size: 0; }
.result .shot { margin-block-start: var(--space-3); }

/* Tabs: radio inputs, so no script. The label list is the first div, so panel n is div n + 1. */
.tabs > input { position: absolute; opacity: 0; pointer-events: none; }
.tabs__list { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; padding: 6px; background: var(--paper-2); border-radius: var(--radius-pill); inline-size: fit-content; max-inline-size: 100%; margin-inline: auto; }
@media (max-width: 640px) { .tabs__list { border-radius: var(--radius-panel); } }
.tabs__list label { padding: 10px 18px; border-radius: var(--radius-pill); font-weight: 600; cursor: pointer; color: var(--ink-2); }
.tabs__list label:hover { color: var(--ink); }
.tabs__panel { display: none; margin-block-start: var(--space-5); animation: switch 0.3s var(--ease); }
@keyframes switch { from { opacity: 0; transform: translateY(6px); } }
.tabs input:nth-of-type(1):checked ~ .tabs__list label:nth-of-type(1),
.tabs input:nth-of-type(2):checked ~ .tabs__list label:nth-of-type(2),
.tabs input:nth-of-type(3):checked ~ .tabs__list label:nth-of-type(3),
.tabs input:nth-of-type(4):checked ~ .tabs__list label:nth-of-type(4) { background: var(--blue); color: var(--on-blue); }
.tabs input:nth-of-type(1):focus-visible ~ .tabs__list label:nth-of-type(1),
.tabs input:nth-of-type(2):focus-visible ~ .tabs__list label:nth-of-type(2),
.tabs input:nth-of-type(3):focus-visible ~ .tabs__list label:nth-of-type(3),
.tabs input:nth-of-type(4):focus-visible ~ .tabs__list label:nth-of-type(4) { outline: 3px solid var(--seal); outline-offset: 2px; }
.tabs input:nth-of-type(1):checked ~ .tabs__panel:nth-of-type(2),
.tabs input:nth-of-type(2):checked ~ .tabs__panel:nth-of-type(3),
.tabs input:nth-of-type(3):checked ~ .tabs__panel:nth-of-type(4),
.tabs input:nth-of-type(4):checked ~ .tabs__panel:nth-of-type(5) { display: grid; }
