/* =========================================================
   WIDE SCREENS (linked with media="(min-width:600px)", after the app's sheet, so a phone never waits for it)
   From 600 px (a tablet) the page is the phone's one column at a tablet's scale, kept together in
   the middle of a tall screen. From 900 px every screen is composed in two parts: the words on one
   side, the thing you act on beside it. Nothing here changes what a screen says or does.
   ========================================================= */

/* ---------- tablets: one column, larger, held together ---------- */
@media (min-width:600px){
  body{background:var(--fundo);font-size:19px}
  .app{max-width:none;background:none}
  /* the column is 640 px in the middle; what bled to the phone's edges (the course, the stub) still reaches the window's */
  .pagina{--margem:max(40px,calc(50vw - 320px));padding-bottom:40px}
  .h-topo{height:68px}
  .marca{height:32px}
  .i-topo{min-height:68px}
  .rotulo{font-size:15px}
  .chamada{font-size:30px;line-height:1.14;letter-spacing:-.016em}
  .b{min-height:60px;font-size:18px}
  .b-g{min-height:76px;max-width:460px;padding:0 28px;font-size:22px}
  .b-link,.i-topo .b-link{min-height:52px;font-size:19px}

  /* the first screen */
  .peito-faixa{min-height:46px;padding:12px 34px;font-size:16px}
  .furo{width:12px;height:12px}
  .furo.f1,.furo.f3{left:11px}.furo.f2,.furo.f4{right:11px}
  .furo.f1,.furo.f2{top:17px}.furo.f3,.furo.f4{bottom:13px}
  .s-h .peito-corpo{padding:22px 34px 24px}
  .peito-pe{margin:0 34px;padding:16px 0 22px}
  .peito-pe .mao{font-size:30px;-webkit-line-clamp:3}
  .h-fita{margin-top:20px}
  .s-h .chamada{margin-top:28px;font-size:34px;line-height:1.1}
  .s-h .h-acao{margin-top:24px}
  .h-pe{display:flex;justify-content:space-between;align-items:baseline;gap:32px;font-size:17px}
  .h-pe a{flex:none;margin-top:0;font-size:16px}
  .meu{grid-template-columns:52px minmax(0,1fr) auto;gap:0 14px;min-height:76px}
  .meu .az{width:52px;height:52px}
  .meu .q .mao{font-size:26px}
  .meu .q small{font-size:17px}

  /* record, name and kilometre, the typed recado: the two halves of each screen become boxes, centred as a pair */
  .s-i1,.s-i2,.s-k{padding-bottom:max(40px,7vh)}
  .i-fala{display:block;margin-top:auto}
  .i-quem{display:flex;flex-direction:column;margin-top:auto}
  .i-mesa,.i-onde{display:flex;flex-direction:column;margin-top:48px;margin-bottom:auto}
  .i-chamada{margin-top:0;font-size:36px;line-height:1.1}
  .i-txt{margin-top:10px;font-size:21px}
  .i-dica{margin-top:22px;padding-top:18px;font-size:19px}
  .i-dica .mao-fala{font-size:34px}
  .i-relogio{margin-top:0;padding-top:0}
  .i-tempo{font-size:min(152px,17vh)}
  .i-palco{margin-top:22px;padding-top:36px;gap:22px}
  .gravador{--lado:min(232px,27vh)}
  .i-solte{font-size:19px}
  .i-solte b{font-size:22px}
  .i-revisa,.i-preparo{margin-top:26px}
  [data-estado="sem-mic"] .i-mic{flex:none;margin-block:auto}
  .passos{margin-top:22px}
  .passos li{grid-template-columns:44px 1fr;min-height:72px;font-size:21px}
  .passos li::before{font-size:48px}
  .i-mic .acoes{margin-top:0;padding-top:32px}

  [data-slot="field"]{gap:12px}
  [data-slot="field-label"],.i-perg{font-size:26px;line-height:1.14;letter-spacing:-.014em}
  [data-slot="field"] input{height:64px;padding:0 16px;font-size:22px}
  [data-slot="field"] textarea{min-height:240px;padding:16px 18px;font-size:22px}
  [data-slot="field-description"],[data-slot="field-error"]{font-size:19px}
  .i-rot{margin-top:28px}
  .i-previa{grid-template-columns:60px minmax(0,1fr) auto;gap:16px;margin-top:10px;padding:12px}
  .i-previa .az{width:60px;height:60px}
  .i-previa .q .mao{font-size:32px}
  .i-previa .q small{margin-top:5px;font-size:17px}
  .i-previa .fala{font-size:24px}
  .bt-q{width:56px;height:56px}
  .i-km{margin-top:0}
  .i-km .km{font-size:72px}
  .s-i2 [data-slot="slider"]{margin-top:10px}
  .i-dica2{margin-top:8px;font-size:19px}
  .i-surpresa{margin-top:12px;min-height:76px}
  .i-surpresa b{font-size:19px}
  .i-surpresa small{font-size:17px}
  .i-manda{margin-top:0;padding-top:28px}
  .i-pe{font-size:17px}
  .i-erro{font-size:19px}
  .s-k [data-slot="field"]{margin-top:auto}
  .s-k [data-slot="field-label"]{margin-top:0;font-size:36px;line-height:1.1}
  .s-k [data-slot="textarea"]{margin-top:12px}
  .k-conta{font-size:17px}
  .s-k .i-manda{margin-bottom:auto}

  /* sent */
  .j-selo{margin-top:18px;gap:12px}
  .j-selo .az{width:130px;height:130px}
  .j-selo .km{font-size:120px}
  .j-de{margin-top:36px;font-size:46px}
  .j-titulo{margin-top:8px;margin-left:-3px;font-size:min(112px,16.4vw)}
  .j-txt{margin-top:22px;font-size:22px}
  .j-muda{margin-top:8px;font-size:18px}
  .j-mais{margin-top:10px}
  .j-canhoto{padding-bottom:48px}
  .j-canhoto p{margin-top:28px;font-size:26px;line-height:1.16}
  .j-canhoto .b-g{margin-top:20px}

  /* states */
  .e-titulo{margin-top:36px;margin-left:-3px;font-size:min(112px,15vw);line-height:.85}
  .e-txt{margin-top:24px;font-size:22px}
  .e-aviso{margin-top:22px;font-size:20px}
  .e-acoes{margin-top:40px;padding-top:0}
  .e-lado{margin-top:40px}
  .e-quem{margin-top:36px;padding-top:18px}
  .e-quem .mao{margin-top:10px;font-size:34px}
}

/* ---------- from 900 px: composed ---------- */
@media (min-width:900px){
  /* twelve columns' worth of page, 1392 px at most, in the middle of the window */
  .pagina{--margem:max(clamp(40px,5.2vw,84px),calc(50vw - 696px));padding-bottom:44px;column-gap:clamp(44px,6vw,104px)}
  .h-topo,.i-topo{height:88px;min-height:88px}
  .marca{height:36px}
  .b-g{min-height:80px;padding:0 32px;font-size:23px}

  /* the first screen: the bib as a poster, the invitation beside it, the course along the bottom */
  .s-h{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);grid-template-rows:auto auto auto 1fr auto;align-items:start}
  .s-h>.h-topo,.s-h>.h-fita,.s-h>.h-pe{grid-column:1/-1}
  .s-h>.peito{grid-column:1;grid-row:2}
  .s-h>.h-lado{display:flex;flex-direction:column;align-items:flex-start;grid-column:2;grid-row:2;align-self:center}
  .s-h>.h-ar{display:none}
  .peito-faixa{min-height:54px;padding:14px 46px;font-size:clamp(17px,1.3vw,21px)}
  .furo{width:15px;height:15px}
  .furo.f1,.furo.f3{left:15px}.furo.f2,.furo.f4{right:15px}
  .furo.f1,.furo.f2{top:19px}.furo.f3,.furo.f4{bottom:19px}
  .s-h .peito-corpo{padding:30px 46px 32px}
  .s-h .peito-corpo .rotulo{font-size:16px}
  .s-h .peito-corpo .voz{margin-top:14px}
  .peito-pe{margin:0 46px;padding:20px 0 30px;border-top-width:2px}
  .peito-pe .mao{margin-top:10px;font-size:clamp(36px,2.9vw,46px);line-height:1.02}
  .peito-pe .voz{padding-top:6px}
  .s-h .chamada{margin-top:0;font-size:clamp(34px,3.3vw,54px);line-height:1.06;letter-spacing:-.018em;max-width:11em}
  .s-h .h-acao{margin-top:36px;width:100%;max-width:520px}
  .s-h .h-escrever{margin-top:10px;min-height:56px;white-space:normal;line-height:1.3}
  .s-h .h-meus{align-self:stretch;margin-top:30px}
  /* big enough to number: the course reads as kilometres */
  .h-fita{grid-row:3;grid-template-columns:repeat(var(--cols),minmax(0,96px));gap:3px;margin:36px 0 0;padding:3px 0;counter-reset:km;border-block-width:2px}
  .h-fita .az{counter-increment:km}
  .h-fita .az::after{content:counter(km);position:absolute;left:8px;top:7px;font-family:var(--voz);font-stretch:72%;font-weight:700;font-size:13px;line-height:1;color:var(--txt-2);font-variant-numeric:lining-nums}
  .h-fita .az:is(.l1,.l2,.l3,.lt)::after{content:none}
  .h-pe{grid-row:5;margin-top:32px;padding-top:18px;border-top-width:2px;font-size:18px}
  .h-pe a{font-size:17px}
  .meu{grid-template-columns:56px minmax(0,1fr) auto;gap:0 16px;min-height:84px;border-top-width:2px}
  .meu:last-child{border-bottom-width:2px}
  .meu .az{width:56px;height:56px}
  .meu .q .mao{font-size:28px}
  .meu .q small{font-size:18px}

  /* record: what to do on the left, the instrument on the right */
  .s-i1,.s-i2,.s-k{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,6fr);grid-template-rows:auto 1fr;align-items:start;padding-bottom:44px}
  .s-i1>.i-topo,.s-i2>.i-topo,.s-k>.i-topo,.s-i1>.i-mic{grid-column:1/-1}
  .i-fala{grid-column:1;align-self:center;margin:0;padding-bottom:9vh}
  .i-mesa{grid-column:2;align-self:center;width:100%;max-width:640px;margin:0;padding-bottom:5vh}
  .i-chamada{font-size:clamp(38px,3.6vw,58px);line-height:1.05;letter-spacing:-.018em;max-width:10em}
  .i-txt{margin-top:16px;font-size:clamp(22px,1.7vw,26px)}
  .i-dica{margin-top:32px;padding-top:24px;font-size:20px;max-width:21em;border-top-width:2px}
  .i-dica .mao-fala{font-size:40px}
  .i-tempo{font-size:min(clamp(136px,11.5vw,188px),21vh)}
  /* the button sits on the clock's left edge, and what it says beside it */
  .i-palco{grid-template-columns:auto minmax(0,1fr);justify-items:start;align-items:end;gap:0 30px;margin-top:26px;padding-top:42px;border-top-width:2px}
  .gravador{--lado:min(clamp(208px,17.5vw,272px),31vh)}
  .i-solte{min-height:0;text-align:left}
  .i-solte b{font-size:24px;line-height:1.2}
  .i-revisa,.i-preparo{margin-top:42px}
  [data-estado="sem-mic"] .i-mic{display:grid;grid-template-columns:minmax(0,5fr) minmax(0,6fr);grid-template-rows:auto auto 1fr;column-gap:inherit;align-self:center;margin:0;padding-bottom:8vh}
  .i-mic>:is(h2,p,.acoes){grid-column:1}
  .i-mic .passos{grid-column:2;grid-row:1/span 3;margin-top:0;border-top-width:2px}
  .passos li{grid-template-columns:52px 1fr;min-height:84px;font-size:22px;border-bottom-width:2px}
  .passos li::before{font-size:56px}
  .i-mic .acoes{padding-top:36px;align-self:start}

  /* name and kilometre: who you are on the left, where you play on the right */
  .i-quem,.i-onde{margin:clamp(24px,10vh,128px) 0 0}
  .i-quem{grid-column:1}
  .i-onde{grid-column:2;width:100%;max-width:640px}
  [data-slot="field-label"],.i-perg{font-size:28px;line-height:1.12;letter-spacing:-.016em}
  [data-slot="field"]{gap:14px}
  [data-slot="field"] input{height:68px;padding:0 18px;font-size:23px}
  [data-slot="field"] textarea{min-height:280px;padding:18px 20px;font-size:23px}
  [data-slot="field-description"],[data-slot="field-error"]{font-size:20px}
  .i-rot{margin-top:36px}
  .i-previa{grid-template-columns:72px minmax(0,1fr) auto;gap:18px;margin-top:12px;padding:14px}
  .i-previa .az{width:72px;height:72px}
  .i-previa .q .mao{font-size:38px}
  .i-previa .q small{margin-top:6px;font-size:18px}
  .i-previa .fala{font-size:28px;-webkit-line-clamp:3}
  .bt-q{width:60px;height:60px}
  .i-km .km{font-size:84px}
  .s-i2 [data-slot="slider"]{margin-top:14px}
  .i-dica2{margin-top:10px;font-size:20px}
  .i-surpresa{margin-top:14px;min-height:84px;border-block-width:2px}
  .i-surpresa b{font-size:20px}
  .i-surpresa small{font-size:18px}
  .i-manda{padding-top:30px}
  .i-pe{font-size:18px}
  .i-apaga{margin-top:6px}

  /* the typed recado: the question on the left, the page to write on beside it */
  .s-k{grid-template-rows:auto auto auto auto auto 1fr}
  .s-k [data-slot="field"]{display:contents}
  .s-k [data-slot="field-label"]{grid-column:1;grid-row:2;margin-top:8vh;font-size:clamp(38px,3.6vw,58px);line-height:1.05;max-width:9em}
  .s-k [data-slot="field-description"]{grid-column:1;grid-row:3;margin-top:16px;font-size:clamp(22px,1.7vw,26px)}
  .s-k [data-slot="textarea"]{grid-column:2;grid-row:2/span 3;margin-top:8vh}
  .s-k [data-slot="field-error"]{grid-column:2;grid-row:5;margin-top:10px}
  .k-conta{grid-column:2;grid-row:5;font-size:18px}
  .s-k .i-manda{grid-column:2;grid-row:6;margin-bottom:0;padding-top:18px}

  /* sent: a ticket. What you made on the left; on the right, past the perforation, the stub that travels on,
     which runs to the edge of the window. */
  .s-j{display:grid;grid-template-columns:minmax(0,7fr) minmax(360px,5fr);grid-template-rows:auto repeat(6,auto) 1fr;column-gap:0;padding:0 0 0 var(--margem)}
  .s-j>*{grid-column:1;margin-right:clamp(28px,3.4vw,64px)}
  .j-selo{margin-top:clamp(8px,4vh,48px);gap:14px}
  .j-selo .az{width:160px;height:160px}
  .j-selo .km{font-size:148px}
  .j-de{margin-top:40px;font-size:56px}
  .j-titulo{margin-left:-4px;font-size:clamp(96px,9.6vw,164px)}
  .j-txt{margin-top:26px;font-size:24px}
  .j-muda{margin-top:10px;font-size:19px;max-width:30em}
  .j-mais{margin-top:14px;margin-bottom:40px}
  .s-j>.j-canhoto{grid-column:2;grid-row:1/-1;position:relative;display:flex;flex-direction:column;justify-content:center;margin:0;padding:48px var(--margem) 56px clamp(40px,5vw,88px)}
  .j-canhoto .picote{display:none}
  .j-canhoto::before{content:"";position:absolute;left:-1px;top:0;bottom:0;width:2px;background:repeating-linear-gradient(180deg,var(--txt) 0 6px,transparent 6px 11px)}
  .j-canhoto p{margin-top:0;font-size:clamp(30px,2.6vw,40px);line-height:1.12;letter-spacing:-.018em;max-width:11em}
  .j-canhoto .b-g{margin-top:34px}

  /* states: the headline at the size of a finish banner, across the page */
  .e-titulo{margin-top:5vh;margin-left:-5px;font-size:clamp(92px,11.4vw,196px);line-height:.84}
  .e-txt{margin-top:32px;font-size:24px;max-width:23em}
  .e-aviso{margin-top:28px;font-size:21px}
  .e-acoes{margin-top:44px}
  .e-quem{margin-top:0;padding-top:20px;border-top-width:2px}
  .e-quem .mao{margin-top:12px;font-size:40px;line-height:1.04}
  .s-e.dois{display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);grid-template-rows:auto repeat(4,auto) 1fr;align-items:start}
  .s-e.dois>*{grid-column:1}
  .s-e.dois>.h-topo{grid-column:1/-1}
  .s-e.dois>.e-lado{grid-column:2;grid-row:2/-1;margin-top:calc(5vh + 14px)}
  .s-e.dois .e-titulo{font-size:clamp(84px,9.4vw,150px)}
  .e-lado>[data-meus]:not(:empty){margin-bottom:36px}
}

/* a short, wide window: less air, the same parts */
@media (min-width:900px) and (max-height:760px){
  .h-topo,.i-topo{height:68px;min-height:68px}
  .pagina{padding-bottom:24px}
  .h-fita{margin-top:24px}
  .h-pe{margin-top:20px;padding-top:14px}
  .i-palco{margin-top:18px;padding-top:30px}
  .i-revisa,.i-preparo{margin-top:30px}
  .i-fala,.i-mesa{padding-bottom:0}
  .s-e.dois .e-titulo,.j-titulo{font-size:clamp(84px,9vw,128px)}
}

/* a mouse has no thumb to hold with: say what does */
@media (hover:hover) and (pointer:fine){
  [data-estado="parado"] .i-solte span:empty::before{content:"Com o mouse, ou com a barra de espaço."}
}
