/* Costan's League Tab: page CSS. Everything here sits inside a visual (the live rank banner, the
   search bar, the miniature tab, the picker shots, the diagram frame) or sets a size the kit asks
   the page to set (--p-h, the close's name). Layout, type and colour come from assets/system.css. */

/* the lit ground of the closing slab: the brand's own cream in place of a dealt sand, sky or sage */
:root, :root[data-ground] {
  --ground-bg: #f0e6d2; --ground-surface: #f7f0e2; --ground-ink: #010a13; --ground-muted: #4d5354; --ground-accent: #785a28;
  --gold: #c8aa6e; --gold-hi: #f0d48a; --teal: #0ac8b9; --ui-dark: rgb(8 14 24 / .88);
}

.logo-mark { border-radius: 6px; }
.nav__logo .logo-mark, .footer .nav__logo .logo-mark { width: 28px; height: 28px; }

/* ---------- the rank banner, built from the extension's own layers ---------- */
.rk { position: relative; display: block; container-type: inline-size; overflow: hidden; color: #fff; font-family: var(--font-display); text-align: center; --rk-top: 26cqw; }
.rk::before { content: ""; position: absolute; inset: 0 3% auto 3%; height: calc(var(--rk-top) + 150cqw); background: #0c1722; }
.rk > .rk__bg { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 50% 100%; }
.rk__name, .rk__tier, .rk__lp { position: absolute; left: 0; right: 0; line-height: 1.2; white-space: nowrap; }
.rk__name { top: var(--rk-top); font-size: max(13px, 7.4cqw); letter-spacing: .02em; }
.rk__crest { position: absolute; left: 7cqw; width: 86cqw; top: calc(var(--rk-top) + 13cqw); aspect-ratio: 240 / 280; }
.rk__crest > img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: contain; }
.rk__crest > .rk__avatar { inset: auto; left: 25%; top: 50%; width: 50%; height: auto; aspect-ratio: 1; border-radius: 50%; translate: 0 -50%; object-fit: cover; }
.rk__level { position: absolute; left: 50%; bottom: calc(23% - 2px); translate: -50% 0; padding: 2px 5px; border-radius: 99px; background: #05090f; font: 500 max(11px, 4.6cqw)/1 var(--font-text); }
.rk__tier { top: calc(var(--rk-top) + 13cqw + 100.4cqw + 8cqw); font-size: max(13px, 8.2cqw); letter-spacing: .06em; text-transform: uppercase; }
.rk__lp { top: calc(var(--rk-top) + 13cqw + 100.4cqw + 20cqw); font-size: max(13px, 6cqw); letter-spacing: .08em; color: #a3a6a0; }
.rk > .rk__trim { position: absolute; left: 0; bottom: 0; width: 100%; height: auto; max-width: none; }
.rk[data-tier="unranked"] :is(.rk__sword, .rk__crown, .rk__lp), .rk:is([data-tier="master"], [data-tier="grandmaster"], [data-tier="challenger"]) .rk__crown { display: none; }
.rk[data-tier="unranked"] .rk__ring { inset: 9% 2% 9% 2%; width: 96%; height: 82%; }
.rk[data-tier="unranked"] .rk__level { bottom: calc(26% - 2px); }

/* ---------- the search bar and its shortcuts ---------- */
.sb { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 8px 0 14px; border-radius: 999px; background: var(--ui-dark); border: 1px solid rgb(200 170 110 / .45); color: #cdbe9a; font: 400 14px/1 var(--font-text); }
.sb svg { flex: none; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.sb__ph { flex: 1; min-width: 0; overflow: hidden; text-align: left; white-space: nowrap; color: #b9b6ab; }
.sb__add { flex: none; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 1px solid rgb(200 170 110 / .6); color: var(--gold-hi); font-size: 16px; }
.sc { display: flex; justify-content: center; gap: 14px; margin-top: 14px; }
.sc__item { display: grid; justify-items: center; gap: 6px; padding: 0 0 4px; font: 500 13px/1.2 var(--font-text); color: #f0e6d2; }
.sc__dot { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--ui-dark); border: 1px solid rgb(200 170 110 / .35); }
.sc__dot > img { width: 22px; height: 22px; }
.sc__item { background: var(--ui-dark); border-radius: 26px 26px 10px 10px; padding: 0 6px 6px; }

/* ---------- hero collage pieces ---------- */
.ly-collage { container-type: inline-size; }
.ly-collage .ly-piece { box-shadow: 0 1px 2px rgb(0 0 0 / .4), 0 24px 48px -20px rgb(0 0 0 / .7); border: 1px solid rgb(200 170 110 / .28); }
.ly-collage .pc-rank { background: url("img/banner.webp") 50% 100% / cover no-repeat; border: 0; box-shadow: none; border-radius: 0; filter: drop-shadow(0 18px 28px rgb(0 0 0 / .6)); }
.ly-collage .pc-rank > .rk { width: 100%; height: 100%; --rk-top: 20cqw; }

/* ---------- the whole tab ---------- */
.tab-head { margin-bottom: var(--s-7); }
.tab-shot { border: 1px solid rgb(200 170 110 / .28); }
.tab-shot > .frame__img { object-position: 50% 0; }
@media (max-width: 639px) { .tab-shot > .frame__img { object-position: 100% 0; } }

/* ---------- the three things: one panel height for the group ---------- */
#does .panel { --p-h: 372px; position: relative; overflow: hidden; }
@media (max-width: 639px) { #does .panel { --p-h: 190px; } }
.panel--rank > .rk { position: absolute; left: 50%; top: 24px; width: 204px; height: 520px; margin-left: -102px; --rk-top: 13cqw; filter: drop-shadow(0 14px 24px rgb(0 0 0 / .55)); }
.panel--search > .sb-wrap { position: absolute; left: 24px; right: 24px; top: 50%; translate: 0 -50%; }
@media (max-width: 639px) {
  .panel--rank > .rk { width: 132px; margin-left: -66px; top: 10px; --rk-top: 6cqw; }
  .panel--search > .sb-wrap { left: 16px; right: 16px; }
  .panel--search .sc { margin-top: 10px; }
  .panel--search .sc__dot { width: 40px; height: 40px; }
}

/* ---------- the rank card's demo frame ---------- */
.rankdemo { display: flex; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: var(--s-5); padding: var(--s-6); aspect-ratio: 1; background: var(--surface); }
.rankdemo::before { content: none; }
.rankdemo__stage { position: relative; flex: 1 1 0; min-height: 0; overflow: hidden; }
.rankdemo__stage > .rk { position: absolute; left: 0; top: 0; width: 218px; height: 100%; --rk-top: 16cqw; filter: drop-shadow(0 14px 24px rgb(0 0 0 / .5)); }
.rankdemo__stage > .rankdemo__menu { position: absolute; right: 0; top: 0; box-shadow: 0 14px 28px -10px rgb(0 0 0 / .6); width: min(258px, calc(100% - 250px)); height: auto; border-radius: var(--r-sm); border: 1px solid rgb(200 170 110 / .28); }
.tiers { flex: none; display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 6px; padding: 8px; border-radius: var(--r-md); background: rgb(5 10 18 / .94); }
.tier { appearance: none; display: grid; place-items: center; min-width: 0; height: 48px; padding: 3px; border-radius: var(--r-sm); border: 1px solid rgb(240 230 210 / .16); background: none; cursor: pointer; transition: border-color var(--m-in, 150ms) var(--ease), background-color var(--m-in, 150ms) var(--ease); }
.tier > img { width: 100%; height: 100%; object-fit: contain; }
.tier:hover { border-color: var(--line-strong); background: rgb(240 230 210 / .05); }
.tier[aria-pressed="true"] { border-color: var(--gold-hi); background: rgb(240 212 138 / .1); }
.tier:focus-visible { outline: 2px solid var(--action); outline-offset: 2px; }
@media (min-width: 1024px) and (max-width: 1279px) { .rankdemo { aspect-ratio: 4 / 5; } }
@media (max-width: 1279px) {
  .tiers { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .rankdemo__stage > .rk { width: 170px; }
  .rankdemo__stage > .rankdemo__menu { width: min(258px, calc(100% - 186px)); }
}
@media (min-width: 640px) and (max-width: 1023px) {
  .tiers { grid-template-columns: repeat(11, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .rankdemo { padding: var(--s-4); gap: var(--s-4); }
  .rankdemo__stage > .rk { width: 148px; }
  .rankdemo__stage > .rankdemo__menu { width: calc(100% - 160px); }
}

/* ---------- the skin picker's two screenshots ---------- */
.picker-shot { display: block; overflow: hidden; border-radius: var(--r-md); border: 1px solid rgb(200 170 110 / .28); align-self: start; }
.picker-shot::before { content: none; }
.picker-shot { aspect-ratio: 410 / 596; }
.picker-shot > img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
#skins .rows > li > p { max-width: 40ch; }
#skins .section-head { margin-bottom: var(--s-7); }

/* ---------- settings: the controls and the miniature tab ---------- */
.opts { display: grid; gap: var(--s-3); }
.opt { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: var(--s-4); padding: 0 0 var(--s-3); border-bottom: 1px solid var(--line); min-width: 0; }
.opt__name { font: 500 var(--t-body)/1.5 var(--font-text); color: var(--ink); }
.opt__seg { display: inline-flex; padding: 3px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); }
.opt__seg > label { position: relative; display: block; cursor: pointer; }
.opt__seg input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.opt__seg span { display: grid; place-items: center; min-width: 76px; height: 38px; padding: 0 var(--s-3); border-radius: calc(var(--r-sm) - 2px); font: 500 var(--t-small)/1 var(--font-text); color: var(--ink); transition: background-color var(--m-in, 150ms) var(--ease), color var(--m-in, 150ms) var(--ease); }
.opt__seg label:hover span { background: rgb(240 230 210 / .07); }
.opt__seg input:checked + span { background: var(--gold-hi); color: #010a13; }
.opt__seg input:focus-visible + span { outline: 2px solid var(--action); outline-offset: 2px; }
@media (max-width: 639px) { .opt__seg span { height: 44px; } }

.nt { display: block; padding: 0; aspect-ratio: 5 / 4; background: #060c14; border: 1px solid rgb(200 170 110 / .28); }
.nt::before { content: none; }
.nt > .nt__art { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; }
.nt[data-bg="centered"] > .nt__art--splash, .nt[data-bg="splash"] > .nt__art--centered { visibility: hidden; }
.nt > .nt__pill { position: absolute; left: 3%; top: 4%; padding: 9px 14px; border-radius: 6px; background: var(--ui-dark); color: #f0e6d2; font: 500 13px/1 var(--font-text); }
/* the banner as the extension hangs it: 80% of the tab tall, the crest 30% of the way down it */
.nt > .rk { position: absolute; top: 0; right: 5%; width: max(19%, 112px); height: 80%; container-type: size; --rk-top: calc(30cqh - 13cqw); }
.nt[data-banner="left"] > .rk { right: auto; left: 5%; }
.nt[data-banner="left"] > .nt__pill { left: auto; right: 3%; }
.nt > .sb { position: absolute; left: 50%; top: 50%; width: min(46%, 300px); translate: -50% -50%; }
.nt[data-search="bottom"] > .sb { top: auto; bottom: 8%; translate: -50% 0; }
.nt[data-search="hidden"] > .sb { display: none; }
@keyframes nt-drop { from { transform: translateY(-14%); opacity: 0; } }
@keyframes nt-rise { from { opacity: 0; } }
.nt.is-in[data-anim="on"] > .rk { animation: nt-drop 260ms var(--m-ease-enter, ease-out) both; }
.nt.is-in[data-anim="on"] > .sb { animation: nt-rise 260ms ease-out both; }
@media (prefers-reduced-motion: reduce) { .nt.is-in > :is(.rk, .sb) { animation: none; } }
@media (max-width: 639px) {
  .nt > .rk { width: 96px; height: 92%; }
  .nt > .rk .rk__lp { display: none; }
  /* the bar sits in the room beside the banner, so it never crosses the crest */
  .nt > .sb { left: calc((95% - 96px) / 2); width: calc(95% - 96px - 20px); height: 40px; gap: 6px; padding-left: 10px; }
  .nt[data-banner="left"] > .sb { left: calc(5% + 96px + (95% - 96px) / 2); }
  .nt > .sb .sb__go { display: none; }
}

/* ---------- privacy: the diagram's frame ---------- */
.privacy-dg { position: relative; aspect-ratio: 5 / 4; height: auto; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
/* the route card: what leaves the browser, with the values the extension really sends (background.js).
   Dark UI cards on the panel's lit ground, as the page's other live pieces. */
.pf { position: absolute; inset: 0; display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); grid-template-rows: auto minmax(auto, 1fr) auto;
  grid-template-areas: 'local local' 'wr wa' 'back art'; column-gap: var(--s-4); padding: var(--s-6); color: #f0e6d2; font: 400 14px/1.4 var(--font-text); }
.pf__local { grid-area: local; } .pf__wire--rank { grid-area: wr; } .pf__wire--art { grid-area: wa; } .pf__back { grid-area: back; } .pf__art { grid-area: art; }
.pf__zone { display: grid; gap: var(--s-2); align-content: start; padding: var(--s-4); border-radius: var(--r-md); background: #0c1722; box-shadow: 0 1px 2px rgb(1 10 19 / .25), 0 16px 32px -18px rgb(1 10 19 / .6); }
.pf__local { grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: var(--s-5); row-gap: var(--s-2); padding: var(--s-3) var(--s-4) var(--s-4); background: rgb(1 10 19 / .06); border: 1.5px dashed rgb(1 10 19 / .5); box-shadow: none; }
.pf__zone-name { grid-column: 1 / -1; color: #010a13; font: 400 12px/1.4 var(--font-display); letter-spacing: .14em; text-transform: uppercase; }
.pf__local > .pf__node, .pf__store { padding: 12px 14px; border-radius: var(--r-sm); background: #0c1722; box-shadow: 0 12px 24px -16px rgb(1 10 19 / .6); align-self: stretch; }
.pf__node { display: flex; align-items: center; gap: 10px; min-width: 0; }
.pf__name { font: 400 17px/1.2 var(--font-display); letter-spacing: .01em; }
.pf__mark { width: 22px; height: 22px; flex: none; }
.pf__ic { width: 20px; height: 20px; flex: none; fill: none; stroke: #c8aa6e; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.pf__store { display: grid; gap: 8px; justify-items: start; min-width: 0; }
.pf__store-name { display: inline-flex; align-items: center; gap: 8px; color: #d6cfbf; font-size: 13px; }
.pf__store-name .pf__ic { width: 16px; height: 16px; }
.pf__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.pf__chips > span { padding: 4px 9px; border-radius: 99px; background: rgb(240 230 210 / .1); font-size: 12px; line-height: 1.2; }
.pf__route { display: grid; justify-items: start; gap: 4px; }
/* backend to Riot API and back: a short upright hairline under the backend's icon */
.pf__hop { width: 1px; height: 18px; margin-left: 9.5px; background: #c8aa6e; position: relative; flex: none; }
.pf__hop::before, .pf__hop::after { content: ''; position: absolute; left: -3px; border: 3.5px solid transparent; }
.pf__hop::before { bottom: -1px; border-top-color: #c8aa6e; border-bottom: 0; }
.pf__hop::after { top: -1px; border-bottom-color: #c8aa6e; border-top: 0; }
.pf__note { color: #c2bba9; font-size: 13px; max-width: 34ch; }
/* the wire: one lane per direction, an ink hairline with an arrowhead and the values riding on it */
.pf__wire { display: flex; justify-content: space-evenly; gap: var(--s-3); min-height: 0; }
.pf__lane { display: flex; flex-direction: column; align-items: center; min-height: 0; }
.pf__line { position: relative; flex: 1 1 0; min-height: 12px; width: 1.5px; background: rgb(1 10 19 / .7); }
.pf__lane--down > .pf__line:last-child::after, .pf__lane--up > .pf__line:first-child::after { content: ''; position: absolute; left: -4.25px; border: 5px solid transparent; }
.pf__lane--down > .pf__line:last-child::after { bottom: -1px; border-top-color: #010a13; border-bottom: 0; }
.pf__lane--up > .pf__line:first-child::after { top: -1px; border-bottom-color: #010a13; border-top: 0; }
.pf__packet { display: grid; gap: 3px; padding: 8px 11px; border-radius: 8px; background: #0b2a2e; border: 1px solid #0ac8b9; box-shadow: 0 12px 24px -16px rgb(1 10 19 / .6); font: 400 12px/1.35 var(--font-mono); white-space: nowrap; }
.pf__dir { font: 500 11px/1.2 var(--font-text); letter-spacing: .08em; text-transform: uppercase; color: #8fe3d9; }
.pf__kv { display: flex; justify-content: space-between; gap: 12px; color: #a9c2bf; }
.pf__kv > b { font-weight: 500; color: #f2fffd; }
@media (min-width: 1024px) and (max-width: 1279px) {
  #privacy .privacy-dg { aspect-ratio: auto; align-self: stretch; min-height: 520px; }
  .pf { padding: var(--s-5); column-gap: var(--s-3); grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
  .pf__local { grid-template-columns: 1fr; }
  .pf__name { font-size: 15px; }
  .pf__packet { padding: 6px 8px; font-size: 11px; }
  .pf__kv { gap: 8px; }
}
/* tablet: the frame takes the height the card needs, so the values never slide under the backend */
@media (min-width: 640px) and (max-width: 1023px) { #privacy .privacy-dg { min-height: 440px; } }
/* below 1024 the rows beside the card already say what the backend keeps: the card drops its notes for the wires */
@media (max-width: 1023px) { .pf__note { display: none; } .pf__line { min-height: 22px; } }
@media (max-width: 639px) {
  /* one column, with the art's lane on a rail down the right edge: from the tab straight to the art servers, past the backend */
  .pf { grid-template-columns: minmax(0, 1fr) 22px; grid-template-rows: auto minmax(auto, 1.6fr) auto minmax(auto, 1fr) auto;
    grid-template-areas: 'local local' 'wr rail' 'back rail' 'wa wa' 'art art'; column-gap: var(--s-2); padding: var(--s-4); }
  .pf::after { content: ''; grid-area: rail; justify-self: center; width: 1.5px; background: rgb(1 10 19 / .7); }
  .pf__wire--art { justify-content: flex-end; }
  .pf__wire--art > .pf__lane { align-items: flex-end; }
  .pf__wire--art .pf__line { margin-right: 10.25px; }
  .pf__local { grid-template-columns: 1fr; }
  .pf__name { font-size: 15px; }
  .pf__packet { padding: 6px 9px; font-size: 11px; }
  .pf__kv { gap: 8px; }
}

/* ---------- the close and the footer ---------- */
.closing__cta.close--word { container-type: inline-size; }
.close__word { font-size: 11.2cqw; letter-spacing: -0.02em; line-height: 1.15; max-width: 100%; }
.footer__disclaimer { max-width: 68ch; font-size: var(--t-small); line-height: 1.5; color: var(--ink); }

/* ---------- the statement's line reads in the ink ---------- */
#why .mo-la__sub { color: var(--ink); }

/* ---------- one action, one size: the close's button is the hero's ---------- */
.closing__cta.close--word .btn--primary { height: 64px; padding-inline: var(--s-6); font-size: var(--t-lead); }
@media (max-width: 1023px) { .closing__cta.close--word .btn--primary { height: 56px; font-size: var(--t-body); } }

/* ---------- questions: the region art under the heading ---------- */
.faq-art { --ratio: 62%; margin-top: var(--s-6); padding: 0; border: 1px solid rgb(200 170 110 / .28); }

/* ---------- desktop: the split frames keep their own ratio (below 1024 they fill what the screen leaves) ---------- */
@media (min-width: 1024px) { .rankdemo.frame--fill, .nt.frame--fill { height: auto; } }
@media (max-width: 1023px) { #privacy .grid { display: flex; flex-direction: column; gap: var(--s-6); } #privacy .privacy-dg { flex: 1 1 0; } }
@media (max-width: 1023px) { .rankdemo, .nt, .privacy-dg { aspect-ratio: auto; min-height: 320px; } }

/* ---------- tablet (640 to 1023): rows that stay rows, so each section keeps one screen ---------- */
@media (min-width: 640px) and (max-width: 1023px) {
  #does .grid > .card, #skins .grid > * { grid-column: auto / span 4; }
  #does .panel { --p-h: 260px; }
  .panel--rank > .rk { width: 168px; margin-left: -84px; }
  .panel--search > .sb-wrap { left: 12px; right: 12px; }
  .panel--search .sb__go { display: none; }
  .panel--search .sc { gap: 6px; }
  #questions .grid > .span-5 { grid-column: 1 / span 4; }
  #questions .grid > .faq { grid-column: 5 / -1; }
  .nt > .sb { width: min(52%, 300px); }
}

/* ---------- phone (under 640) ---------- */
@media (max-width: 639px) {
  #does .panel { --p-h: 290px; }
  /* two screens: the words, then the frame filling the second */
  #summoner .grid, #privacy .grid, #questions .grid { display: contents; }
  #summoner .rankdemo, #privacy .privacy-dg { align-self: stretch; height: auto; min-height: 0; }
  #questions .faq { align-self: start; }
  /* skins: one screen, three rows and the two shots side by side */
  #skins .rows > li:nth-child(n+4) { display: none; }
  #skins .picker-shot { grid-column: auto / span 6; aspect-ratio: 165 / 190; }
  /* settings: one screen, the miniature between the heading and its controls */
  #settings .grid { display: flex; flex-direction: column; gap: var(--s-4); }
  #settings .grid > .span-5 { display: contents; }
  #settings .grid > .span-5 > * { margin-top: 0; }
  #settings .grid > .span-5 > p { display: none; }
  #settings .nt { order: 1; flex: none; aspect-ratio: 19 / 15; min-height: 0; height: auto; }
  #settings .opts { order: 2; gap: var(--s-2); }
  #settings .opt { grid-template-columns: minmax(0, 1fr) auto; padding-bottom: var(--s-2); }
  #settings .opt__seg span { min-width: 56px; padding: 0 var(--s-2); }
}

/* ---------- phone: the footer's second screen holds the disclaimer, the links and the legal row ---------- */
@media (max-width: 639px) {
  .closing__links > .grid .nav__logo { display: none; }
  .closing__links { gap: var(--s-5); }
  .closing__links > .grid .stack-4 > * { margin-top: 0; }
}

/* ---------- phone: questions in two whole screens ---------- */
@media (max-width: 639px) {
  #questions .faq > .faq__item { padding: 12px 0; }
  #questions .faq > .faq__item:first-child { padding-top: 0; }
  .faq-art { --ratio: 100%; }
}

/* ---------- below 1024 the collage stands on a panel from line to line ---------- */
@media (max-width: 1023px) { .hero--triptych .ly-collage { background: var(--surface); border-radius: var(--r-lg); } }
@media (min-width: 640px) and (max-width: 1023px) {
  .hero--triptych .hero__cta { justify-content: flex-start; }
  .hero--triptych .hero__cta .btn { width: auto; }
}

/* ---------- below 1280: the rank demo in a narrower frame ---------- */
@media (max-width: 1279px) {
  .rankdemo { padding: var(--s-5); gap: var(--s-4); }
  .rankdemo__stage > .rk { width: 150px; }
  .rankdemo__stage > .rankdemo__menu { width: min(258px, calc(100% - 166px)); }
  .nt > .sb .sb__go { display: none; }
}
@media (min-width: 1024px) and (max-width: 1279px) { .rankdemo { aspect-ratio: 10 / 11; } }

/* ---------- tablet (640 to 1023): the splits that stay side by side, on the page's split lines ---------- */
@media (min-width: 640px) and (max-width: 1023px) {
  .tiers { grid-template-columns: repeat(11, minmax(0, 1fr)); }
  #does .panel { --p-h: 460px; }
  #why .mo-la__type { font-size: 20vw; line-height: 1; max-width: none; }
  #why .mo-la__sub { font-size: 24px; margin-top: var(--s-8); }
  #questions .grid > .span-5 { grid-column: 1 / span 6; }
  #questions .grid > .faq { grid-column: 7 / -1; }
  #tab .tab-shot > .frame__img { object-position: 100% 0; }
  .panel--search .sc__item { padding: 0 2px 6px; }
  .panel--search .sc__dot { width: 40px; height: 40px; }
}

/* ---------- the skin picker's moment: its panel keeps 20px from the band's edge ---------- */
/* the skin picker's moment, edge to edge and eased: no gutter round the stage, so the band's ground wipes up the whole
   section; the line's two positions are registered so they glide to where the scroll puts them (the kit sets them each
   frame), the words fade with the same ease, and the line is a gold edge with a glow */
@property --mo-cut { syntax: '<length-percentage>'; inherits: true; initial-value: 100%; }
@property --mo-below { syntax: '<length-percentage>'; inherits: true; initial-value: 0px; }
#skins.mo-lc { --mo-gap: 0px; transition: --mo-cut 750ms cubic-bezier(.16, 1, .3, 1), --mo-below 750ms cubic-bezier(.16, 1, .3, 1); }
#skins.mo-lc > .mo-lc__stage { border-radius: 0; transition: visibility 0s; }
/* the kit takes the stage away the moment the line arrives; here it stays until the eased line has caught up */
#skins.mo-lc.is-open > .mo-lc__stage { display: block; visibility: hidden; transition: visibility 0s 750ms; }
#skins .mo-lc__line { height: 2px; margin-top: -1px; background: var(--gold-hi, #f0d48a); box-shadow: 0 0 22px 3px rgb(240 212 138 / .45), 0 0 4px rgb(240 212 138 / .9); }
#skins.mo-lc.is-live :is(h2, p, li, figure) { transition: opacity 650ms cubic-bezier(.22, 1, .36, 1); }
@media (prefers-reduced-motion: reduce) { #skins.mo-lc { transition: none; } }

/* ---------- 1024 to 1279: the rank section as two equal columns, so it ends with the screen's usual gap ---------- */
@media (min-width: 1024px) and (max-width: 1279px) {
  #summoner .grid > .span-5 { grid-column: 1 / span 6; }
  #summoner .rankdemo { grid-column: 7 / -1; }
}
@media (max-width: 1279px) { #summoner .t-lead, #privacy .t-lead { font-size: var(--t-body); line-height: 1.6; } }

/* ---------- tablet: the close's button keeps its own width, like the hero's ---------- */
@media (min-width: 640px) and (max-width: 1023px) { .closing__cta.close--word .section-head--split > .btn { width: auto; } }

/* ---------- phone: the statement set large enough to carry its screen ---------- */
@media (max-width: 639px) {
  #why .mo-la__type { font-size: 24vw; line-height: 1; }
  #why .mo-la__sub { font-size: var(--t-lead); margin-top: var(--s-7); }
}

/* ---------- the rank demo's banner is a card over the art: it carries the banner as its own ground ---------- */
.rankdemo__stage > .rk { background: url("img/banner.webp") 50% 100% / cover no-repeat; }

/* ---------- 1024 to 1279: the three cards stay three-up, so the section keeps its one screen ---------- */
@media (min-width: 1024px) and (max-width: 1279px) {
  #does .grid > .card { grid-column: auto / span 4; }
  #does .panel { --p-h: 290px; }
  .panel--rank > .rk { width: 168px; margin-left: -84px; top: 16px; }
  .panel--search .sb__go { display: none; }
}

/* ---------- phone: the bar holds the name and the menu; Add to Chrome is in the menu's sheet ---------- */
@media (max-width: 639px) {
  .nav:not(.is-open) .nav__actions { display: none; }
  .nav:not(.is-open) .nav__actions + .nav__toggle { margin-left: auto; }
}

/* ---------- tablet: the rank demo stops short of the screen's foot, before the skin picker's band ---------- */
@media (min-width: 640px) and (max-width: 1023px) { #summoner .rankdemo { margin-bottom: 100px; } }

/* ---------- tablet: the three rank rows stand side by side, so the demo below has the height for a whole banner
   (name, crest, tier, LP and the tier's trim) ---------- */
@media (min-width: 640px) and (max-width: 1023px) {
  #summoner .rows { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--s-5); }
  #summoner .rows > li { padding-top: 0; align-content: start; }
}
/* below 1280 the banner is never wider than half its stage's height, so the trim stays clear of the LP line */
@media (max-width: 1279px) {
  .rankdemo__stage { container-type: size; }
  .rankdemo__stage > .rk { width: min(150px, 48cqh); }
}

/* ---------- 1024 to 1279: the miniature is narrow, so its search bar centres in the room beside the banner ---------- */
@media (min-width: 1024px) and (max-width: 1279px) {
  .nt > .sb { left: calc((95% - max(19%, 112px)) / 2); }
  .nt[data-banner="left"] > .sb { left: calc(5% + max(19%, 112px) + (95% - max(19%, 112px)) / 2); }
}

/* ---------- desktop: the whole tab shows whole. The screenshot keeps its own ratio (2560 x 1319) inside what the
   screen leaves under the heading, never cropped, so the banner and its crest stay in view on HD and 2K screens.
   It always spans the column; on a short screen only its foot is trimmed (never its sides, where the banner is), and on a
   screen wider than the column it may grow past it, up to 80px from the screen's edges. ---------- */
@media (min-width: 1024px) {
  #tab .tab-shot { container-type: size; display: grid; justify-items: unsafe center; align-items: start; overflow: visible; border: 0; border-radius: 0; background: none; box-shadow: none; }
  #tab .tab-shot::before, #tab .tab-shot::after { content: none; }
  #tab .tab-shot > .frame__img { position: relative; inset: auto; width: max(100cqw, min(calc(100vw - 160px), calc(100cqh * 2560 / 1319))); max-width: none; height: auto; max-height: 100cqh; aspect-ratio: 2560 / 1319;
    object-fit: cover; object-position: 50% 0; border: 1px solid rgb(200 170 110 / .28); border-radius: var(--r-lg); }
}
