/* cost.html: the two-print opening, the two-sided bill, the why, the sum, the hand-off. Loaded after site.css. */

/* ---------- the first wall ---------- */
.the-first { padding-top: clamp(1.25rem, 4vh, 2.5rem); }
.the-first .the-wall { row-gap: 0.75rem; }
.the-cost-h1 { display: contents; }
.the-case-top {
  grid-column: 1 / span 16; grid-row: 1;
  align-self: start; padding-left: var(--the-edge);
  font: 400 clamp(1.75rem, 1.1rem + 2.9vw, 3.5rem)/1.1 var(--the-stencil);
  text-transform: lowercase; text-wrap: balance;
}
/* the h1's second thought, demoted to one line of reading copy in the right-hand corner */
.the-cost-line {
  grid-column: 12 / span 6; grid-row: 3;
  align-self: end; margin: 0; text-align: right;
  font: 400 clamp(1.0625rem, 1rem + 0.5vw, 1.375rem)/1.45 var(--the-voice);
  color: var(--the-chalk);
}
.the-hung { padding-left: var(--the-edge); }
.the-cases { --the-hang: 1 / span 15; --the-rung: 2; --the-narrow: 1 / -1; --the-shape: 16 / 9; }
.the-cases img { max-height: 42vh; }
.the-first-scene { --the-hang: 1 / span 11; --the-rung: 3; max-width: none; align-self: start; }
.the-sneakers { --the-hang: 18 / -1; --the-rung: 1 / span 3; --the-narrow: 1 / -1; --the-shape: 2 / 3; }
.the-sneakers img { max-height: 72vh; }

/* ---------- the two-sided bill ---------- */
.the-bill-head { --the-hang: 1 / span 13; --the-rung: 1; padding-left: var(--the-edge); }
.the-bill-gloss {
  --the-hang: 15 / -1; --the-rung: 1;
  align-self: end; margin: 0; padding-right: var(--the-edge);
  max-width: 34rem;
}
.the-family { --the-hang: 1 / span 11; --the-rung: 2; padding-left: var(--the-edge); }
.the-school { --the-hang: 13 / -1; --the-rung: 2; align-self: end; padding-right: var(--the-edge); }
.the-family p, .the-school p { margin: 0; }
/* the line box is as tall as the face itself, so the huge figure keeps clear of the caption head above it */
.the-nought {
  font: 400 clamp(6rem, 18vw, 17rem)/normal var(--the-stencil);
  color: var(--the-chalk);
}
.the-sum {
  font: 400 clamp(3rem, 9vw, 8.5rem)/0.95 var(--the-stencil);
  color: var(--the-chalk);
}
.the-hedge { display: block; font-size: 0.3em; line-height: 1.2; text-transform: lowercase; }
.the-per { margin-top: 0.5rem; font-size: 1.25rem; line-height: 1.3; }
.the-family .the-stencil-small, .the-school .the-stencil-small { margin-bottom: 0.5rem; }

.the-bill-rows {
  --the-hang: 1 / -1; --the-rung: 3;
  margin: 1rem 0 0; padding: 0 var(--the-edge); list-style: none;
}
.the-bill-rows li {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) auto;
  column-gap: 1.5rem; align-items: baseline;
  padding-block: 0.4rem;
}
.the-bill-rows a {
  display: inline-block; justify-self: start; min-height: 2.75rem; padding-block: 0.3rem;
  font: 400 clamp(1.5rem, 1.1rem + 1.6vw, 2.5rem)/1.15 var(--the-stencil);
  text-transform: lowercase; text-decoration: none;
}
.the-bill-rows a:hover, .the-bill-rows a:focus-visible {
  text-decoration: underline 0.125rem var(--the-brass); text-underline-offset: 0.2em;
  color: var(--the-gleam);
}
.the-kind { font-size: 1.0625rem; }
.the-free {
  font: 400 clamp(1.25rem, 1.05rem + 0.8vw, 1.625rem)/1.2 var(--the-stencil);
  color: var(--the-chalk); text-transform: lowercase; text-align: right;
}

/* ---------- why the school can do this ---------- */
.the-why-head { --the-hang: 1 / span 13; --the-rung: 1; padding-left: var(--the-edge); align-self: end; }
.the-why-a { --the-hang: 15 / -1; --the-rung: 1; align-self: end; padding-right: var(--the-edge); }
.the-lid { --the-hang: 1 / span 20; --the-rung: 2; padding-left: var(--the-edge); align-self: start; }
/* the Minuet print sits between the two chalk blocks, in the middle of the long text run */
.the-bowings {
  --the-hang: 1 / span 11; --the-rung: 3;
  --the-narrow: 1 / -1; --the-shape: 3 / 2;
}
.the-bowings img { max-height: 60vh; }
.the-why-b { --the-hang: 14 / -1; --the-rung: 3; align-self: center; padding-right: var(--the-edge); }
.the-why-a > p, .the-why-b > p { margin: 0; }

/* ---------- what the sum holds together ---------- */
.the-sum-note { --the-hang: 1 / span 10; --the-rung: 1; padding-left: var(--the-edge); }
.the-sum-note > p { margin: 0.9rem 0 0; max-width: 30rem; }
.the-tally-here { --the-hang: 13 / -1; --the-rung: 1; padding-right: var(--the-edge); }
.the-tally dt a { text-decoration: none; }
.the-tally dt a:hover, .the-tally dt a:focus-visible { text-decoration: underline 0.125rem var(--the-brass); text-underline-offset: 0.2em; }

/* ---------- the hand-off ---------- */
.the-onward-band { padding-block: 0; }
.the-onward {
  display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 1.5rem clamp(2rem, 6vw, 6rem); align-items: center;
}
.the-onward-text > p { flex: none; max-width: 40rem; }
.the-onward-text > p:last-child { margin: 0.75rem 0 0; }
.the-onward-links { display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; }
.the-onward-links .the-brass { font-size: clamp(1.75rem, 1.2rem + 2.2vw, 3rem); }

/* ---------- the wall folds when its band is narrow ---------- */
@container band (max-width: 44rem) {
  .the-case-top, .the-cost-line {
    grid-column: 1 / -1; grid-row: auto;
    padding-inline: var(--the-edge); text-align: left;
  }
  .the-case-top { font-size: clamp(1.75rem, 8vw, 2.125rem); }
  .the-cost-line { font-size: 1.0625rem; }
  .the-cases img { aspect-ratio: 3 / 2; max-height: 40vh; }
  .the-sneakers img { aspect-ratio: 4 / 5; max-height: 56vh; }
  .the-bowings img { aspect-ratio: 3 / 2; max-height: none; }
  .the-first-scene { max-width: none; }
  .the-nought { font-size: 7.5rem; }
  .the-sum { font-size: 3.75rem; }
  .the-family, .the-school { margin-top: 0.75rem; }
  .the-bill-rows li { grid-template-columns: minmax(0, 1fr) auto; }
  .the-kind { grid-column: 1 / -1; grid-row: 2; }
  .the-onward { grid-template-columns: minmax(0, 1fr); }
}
