/* Section pages: the header band, the panels under it, the list of pieces, the rows of cards.
   Loaded on section pages, the podcast page and the front page. */

/* the header band: name and one line on the left, rows on the right */
.sec-hero { background: var(--bg); border-bottom: 1px solid var(--rule); }
.sec-hero .page-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 380px); justify-content: space-between; align-items: center; gap: 30px 60px; padding: 40px 0; }
.sec-hero .page-head h1 { font-size: 57px; line-height: 60px; overflow-wrap: anywhere; }
.sec-hero .page-head .stand { margin-top: 10px; max-width: 520px; }
.sec-hero .ph-main { min-width: 0; }
.sec-hero .ph-rows { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.sec-hero .ph-rows li { display: flex; justify-content: space-between; align-items: center; gap: 15px; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.sec-hero .ph-rows .l { color: var(--text); font-weight: 500; font-size: 16px; line-height: 20px; }
.sec-hero .ph-rows .r { color: var(--meta); font-size: 15px; text-align: right; }
.sec-hero .ph-rows a { color: inherit; text-decoration: none; }
.sec-hero .ph-rows a:hover .r { color: var(--link-hover); }
.sec-hero .ph-icons { display: flex; gap: 5px; }
.sec-hero .ph-icons a { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid var(--rule); border-radius: 5px; color: var(--text); }
.sec-hero .ph-icons a:hover { border-color: var(--blue); color: var(--blue); }

/* the ground and the panels */
.sec-body { background: var(--panel); padding: 30px 0 60px; }
.sec-panel { background: var(--bg); border: 1px solid var(--rule-soft); border-radius: 5px; padding: 25px; margin-bottom: 20px; }
.sec-panel .block-head { align-items: center; }
.sec-panel .block-head h2 { font-size: 27px; line-height: 35px; }
.sec-panel .block-head a.btn { font-size: 15px; line-height: 20px; white-space: nowrap; }
.sec-panel .block-head a.btn, .sec-panel .block-head a.btn:hover { color: var(--white); }
.sec-body .pager { margin: 30px 0 0; }
.sec-empty { margin-bottom: 20px; }

/* the newest piece */
.sec-lead { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.sec-lead h2 { font-size: 33px; line-height: 40px; margin: 5px 0 10px; }
.sec-lead .meta { margin-top: 15px; }
.sec-lead .sec-score { margin: 5px 0 15px; }
.sec-lead .btn-row { margin-top: 20px; }

/* the lead that turns: the cover on one side, and on the other the same small centred block the front page leads with */
.sec-turn { position: relative; }
.sec-turn-slide { display: none; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.sec-turn-slide.is-on { display: grid; }
.sec-turn-text { display: flex; flex-direction: column; align-items: center; text-align: center; padding-bottom: 60px; }
.sec-turn-text h2 { font-size: 29px; line-height: 35px; margin-top: 10px; max-width: 480px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sec-turn-text .stand { max-width: 420px; margin-top: 10px; font-size: 16px; line-height: 25px; color: var(--meta); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
/* the two buttons are small, to sit with the small block of words */
.sec-turn-text .btn-row { margin-top: 20px; }
.sec-turn-text .btn { padding: 5px 15px; font-size: 15px; line-height: 25px; }
.sec-turn-ctl { position: absolute; right: 25px; bottom: 25px; width: calc((100% - 90px) / 2.15); display: flex; justify-content: center; align-items: center; gap: 10px; }
/* inside a panel that is already open the lead has no padding of its own; the card is the big part and the words take the narrower side */
.sec-turn.inside .sec-turn-slide { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.sec-turn.inside .cover { aspect-ratio: 16 / 9; }
.sec-turn.inside .sec-turn-text h2 { font-size: 24px; line-height: 30px; -webkit-line-clamp: 3; }
.sec-turn.inside .sec-turn-ctl { right: 0; bottom: 0; width: calc((100% - 40px) / 2.6); }
.sec-slide .cover { aspect-ratio: 16 / 9; }

/* the list: cover on the left, words beside it, two across */
.sec-list { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 40px; }
.sec-list li { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 20px; align-items: center; min-width: 0; }
.sec-list .cover { width: 100%; }
.sec-list .kicker { display: block; }
.sec-list h3 { font-size: 19px; line-height: 25px; margin: 5px 0; overflow-wrap: anywhere; }
.sec-list .dek { font-size: 15px; line-height: 25px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sec-list .label, .sec-list [class^="gap-"] { margin-top: 10px; }
/* the same list with the words under the cover, four across, or three when the count divides by three */
.sec-list.under { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 20px; }
.sec-list.under.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sec-list.under li { grid-template-columns: minmax(0, 1fr); gap: 15px; align-items: start; }

/* cards, chips, the strip of figures */
.sec-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
.sec-chips { display: flex; gap: 10px; flex-wrap: wrap; }
.sec-chips .tag { padding: 5px 15px; font-size: 15px; line-height: 20px; }
.sec-chips + .sec-two, .sec-chips + .sec-list { margin-top: 20px; }
.sec-strip { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border: 1px solid var(--rule-soft); border-radius: 5px; }
.sec-strip a { display: block; padding: 15px; border-left: 1px solid var(--rule-soft); min-width: 0; }
.sec-strip a:first-child { border-left: 0; }
.sec-strip span { display: block; font-size: 14px; line-height: 20px; color: var(--meta); overflow-wrap: anywhere; }
.sec-strip b { display: block; font-size: 19px; line-height: 25px; }
.sec-strip i { font-style: normal; font-size: 14px; line-height: 20px; color: var(--meta); }
.sec-strip a:hover b { color: var(--link-hover); }
.sec-points { list-style: none; }
.sec-points li { padding: 10px 0; border-top: 1px solid var(--rule-soft); font-size: 16px; line-height: 25px; }
.sec-points li:first-child { border-top: 0; padding-top: 0; }

/* the big card that slides, with four small pieces beside it */
.sec-robolead { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 30px; align-items: start; }
.sec-slider { position: relative; overflow: hidden; }
.sec-track { display: flex; transition: transform 0.6s ease; }
.sec-slide { flex: 0 0 100%; min-width: 0; }
.sec-slide h3, .sec-wide h3 { font-size: 27px; line-height: 35px; margin-top: 15px; overflow-wrap: anywhere; }
.sec-dots { display: flex; gap: 5px; margin-top: 5px; }
/* a thin bar to look at, a taller box to press */
.sec-dots button { box-sizing: content-box; width: 30px; height: 5px; border: 0; padding: 10px 0; background: var(--line); background-clip: content-box; cursor: pointer; }
.sec-dots button.on { background: var(--red); }
.sec-side { list-style: none; }
.sec-side li { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 15px; align-items: center; padding: 12px 0; border-top: 1px solid var(--rule-soft); }
.sec-side li:first-child { border-top: 0; padding-top: 0; }
.sec-side .cover { width: 100%; }
.sec-side .kicker { display: block; }
.sec-side h3 { font-size: 17px; line-height: 25px; margin-top: 5px; overflow-wrap: anywhere; }

/* two cards of unequal width */
.sec-two { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 15px; align-items: start; }
.sec-two .sec-wide .cover { aspect-ratio: 2 / 1; }
.sec-two + .sec-list { margin-top: 30px; }
.sec-ad { margin-top: 30px; }

/* reviews: the scores, the table, the panel for makers */
.sec-score { margin-top: 10px; }
.sec-tablewrap { overflow-x: auto; }
.sec-table { width: 100%; border-collapse: collapse; font-size: 16px; line-height: 25px; }
.sec-table th { text-align: left; font-size: 14px; line-height: 20px; font-weight: 500; color: var(--meta); padding: 10px 15px 10px 0; border-bottom: 1px solid var(--rule); }
.sec-table td { padding: 15px 15px 15px 0; border-bottom: 1px solid var(--rule-soft); vertical-align: middle; }
.sec-table td:first-child { font-weight: 600; }
.sec-pitch { display: flex; justify-content: space-between; align-items: center; gap: 30px; flex-wrap: wrap; background: var(--mist); }
.sec-pitch h2 { font-size: 27px; line-height: 35px; margin-bottom: 5px; }
.sec-pitch .btn { white-space: nowrap; }
:root[data-theme="dark"] .sec-pitch { background: var(--bg); }

/* the podcast page: one play button for each piece */
.sec-listen { margin-top: 10px; }
.sec-play { display: inline-flex; align-items: center; gap: 10px; font: 600 15px/20px 'Figtree', Helvetica, Arial, sans-serif; color: var(--text); background: var(--bg); border: 1px solid var(--rule); border-radius: 5px; padding: 5px 15px 5px 10px; cursor: pointer; }
.sec-play i { display: flex; align-items: center; justify-content: center; width: 20px; height: 20px; }
.sec-play:hover, .is-playing .sec-play.is-current { color: var(--white); background: var(--red); border-color: var(--red); }

/* the weekly issue: the cover, the lists of what is in it, the shelf of past covers.
   Sizes inside the cover are in cqw, hundredths of the cover's own inner width, so a small cover is the same page
   shrunk. The cover's own padding cannot use cqw (on the container itself that unit means the window), so it is a
   percentage: the cover always fills the box it sits in. */
.mag-lead { display: grid; grid-template-columns: minmax(0, 400px) minmax(0, 1fr); gap: 50px; align-items: center; }
.mag-lead h2 { font-size: 33px; line-height: 40px; margin: 5px 0 10px; }
.mag.cover { position: relative; display: flex; flex-direction: column; aspect-ratio: 3 / 4; padding: 5.5%; border-radius: 5px; overflow: hidden; container-type: inline-size; color: var(--ink); }
.mag-logo { flex: none; width: 26cqw; }
.mag-logo img { width: 100%; height: auto; display: block; }
/* the headline: a short phrase, solid, sized by its longest word; the line under it is lighter and always follows it */
.mag-word { flex: none; margin-top: 8cqw; font-family: 'Inter', Helvetica, Arial, sans-serif; font-weight: 700; font-size: min(17cqw, calc(150cqw / var(--n, 8))); line-height: 0.95; letter-spacing: -0.04em; overflow-wrap: anywhere; }
.mag-line { flex: none; margin-top: 3cqw; max-width: 66cqw; font-size: 3.4cqw; line-height: 4.6cqw; font-weight: 400; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mag .mag-art { flex: 1 1 0; min-height: 0; width: 100%; margin: -4cqw 0; }
.mag-edge { position: absolute; left: 1.6cqw; bottom: 30cqw; font-size: 1.7cqw; line-height: 1; transform: rotate(-90deg); transform-origin: left bottom; white-space: nowrap; opacity: 0.8; }
.mag-foot { flex: none; margin-top: auto; display: flex; align-items: stretch; font-size: 2.2cqw; line-height: 3cqw; }
.mag-foot b { flex: none; width: 15cqw; background: var(--red); color: var(--white); font-weight: 600; padding: 1.5cqw 2cqw; display: flex; align-items: center; }
.mag-foot span { flex: 1 1 0; min-width: 0; overflow-wrap: anywhere; padding: 0 2cqw; border-right: 1px solid currentColor; display: flex; align-items: center; }
.mag-foot span:last-of-type { border-right: 0; }
.mag-foot i { flex: none; width: 12cqw; margin-left: auto; padding-left: 0; font-style: normal; font-size: 1.22cqw; line-height: 1.8cqw; text-align: center; overflow: hidden; }
.mag-foot i em { display: block; font-style: normal; white-space: nowrap; }
.mag-code { width: 12cqw; height: 12cqw; display: block; margin-bottom: 0.8cqw; }
.mag.small .mag-word { margin-top: 22cqw; }
.mag-finds { list-style: none; margin-top: 20px; border-top: 1px solid var(--rule-soft); }
.mag-finds li { padding: 10px 0; border-bottom: 1px solid var(--rule-soft); font-size: 16px; line-height: 25px; }
.mag-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 30px; }
.mag-sec { font-size: 15px; line-height: 20px; color: var(--red-text); font-weight: 600; padding-bottom: 10px; border-bottom: 1px solid var(--rule); margin-bottom: 15px; }
.mag-heads { list-style: none; }
.mag-heads li { padding: 15px 0; border-top: 1px solid var(--rule-soft); }
.mag-heads li:first-child { border-top: 0; padding-top: 0; }
.mag-heads h4 { font-size: 17px; line-height: 25px; font-weight: 600; overflow-wrap: anywhere; }
.mag-shelf { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 20px; }
.mag-shelf .mag { margin-bottom: 15px; }
.mag-shelf .kicker { display: block; }
.mag-shelf h3 { font-size: 17px; line-height: 25px; margin-top: 5px; }
.mag-shelf li.is-held { display: none; }
.mag-more { margin-top: 30px; text-align: center; }

/* four columns of news: a picture, a headline, a rule, a second headline */
.sec-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 30px 25px; margin-top: 5px; }
.sec-cols .cover { margin-bottom: 15px; }
.sec-cols h3 { font-size: 21px; line-height: 30px; font-weight: 700; overflow-wrap: anywhere; }
.sec-second { margin-top: 15px; padding-top: 15px; border-top: 1px solid var(--rule); font-size: 16px; line-height: 25px; font-weight: 600; overflow-wrap: anywhere; }

/* the front page blocks that use the list */
.block .sec-list { margin-top: 5px; }

@media (max-width: 900px) {
  .sec-hero .page-head { grid-template-columns: minmax(0, 1fr); gap: 25px; }
  .sec-hero .page-head h1 { font-size: 40px; line-height: 45px; }
  .sec-lead, .sec-turn-slide { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .sec-turn-text { padding-bottom: 0; }
  .sec-turn-text h2 { font-size: 23px; line-height: 30px; -webkit-line-clamp: 3; }
  .sec-turn-ctl { position: static; width: auto; margin-top: 20px; }
  .sec-lead h2 { font-size: 27px; line-height: 35px; }
  .sec-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sec-cards .pillar-mark[data-cover], .sec-two .pillar-mark[data-cover] { max-width: 280px; }
  .sec-list { grid-template-columns: minmax(0, 1fr); }
  .sec-list li { grid-template-columns: 120px minmax(0, 1fr); gap: 15px; }
  .sec-list.under, .sec-list.under.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sec-list.under li { grid-template-columns: minmax(0, 1fr); }
  .sec-strip, .sec-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sec-strip a { border-left: 0; border-top: 1px solid var(--rule-soft); }
  .sec-strip a:nth-child(-n+2) { border-top: 0; }
  .sec-strip a:nth-child(even) { border-left: 1px solid var(--rule-soft); }
  .sec-robolead, .sec-two { grid-template-columns: minmax(0, 1fr); }
  .sec-two .sec-wide .cover { aspect-ratio: 4 / 3; }
  .sec-slide h3, .sec-wide h3 { font-size: 23px; line-height: 30px; }
  .sec-panel { padding: 20px 15px; }
  .mag-lead { grid-template-columns: minmax(0, 1fr); gap: 25px; }
  .mag-lead .mag { max-width: 400px; }
  .mag-shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sec-panel .block-head { flex-wrap: wrap; }
}
@media (max-width: 560px) {
  .sec-cols { grid-template-columns: minmax(0, 1fr); }
  .sec-cards { grid-template-columns: minmax(0, 1fr); }
  .sec-list.under, .sec-list.under.three { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .sec-track { transition: none; }
}
