/* Percebeste? · percebeste.pt · "um site que se deixa perceber"
   Marca: tinta #15191b, papel #f5f2ea, marcador #C6F432, Bricolage Grotesque 800 + Inter.
   Acessibilidade: WCAG 2.1 AA. Contraste mínimo de 4,5:1 em todo o texto (medido). Foco sempre visível.
   Regra da marca: nunca um bloco lima/amarelo com texto preto sobre fundo preto. */
:root {
  --papel: #f5f2ea;
  --papel-2: #ebe6d9;
  --tinta: #15191b;
  --cinza: #6b675e;        /* 5,0:1 sobre o papel */
  --lima: #C6F432;
  --escuro: #15191b;
  --escuro-2: #1d2327;
  --cinza-esc: #8f9a98;    /* 6,1:1 sobre o escuro */
  --claro-esc: #aeb6b4;    /* 8,6:1 sobre o escuro */
  --linha: #d9d3c4;
  --linha-esc: #2c3439;
  --noite: #0b0f1a;
  --mono: ui-monospace, 'SF Mono', 'JetBrains Mono', Menlo, Consolas, monospace;
  --larg: 1200px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  background: var(--papel); color: var(--tinta);
  font: 400 17px/1.6 Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body::before {                              /* grão de papel, muito leve */
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .45 0 0 0 0 .35 0 0 0 .08 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
}
footer, .escuro, .jogos { position: relative; }
::selection { background: var(--lima); color: var(--tinta); }
a { color: inherit; text-underline-offset: 3px; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
.contentor { max-width: var(--larg); margin: 0 auto; padding: 0 32px; }
h1, h2, h3, h4, .logo { font-family: 'Bricolage Grotesque', Inter, sans-serif; font-weight: 800; letter-spacing: -.025em; line-height: 1; }
code { font-family: var(--mono); font-size: .88em; background: var(--papel-2); padding: 1px 6px; border-radius: 5px; }
s.riscado { text-decoration: none; }        /* sem CSS, o <s> continua riscado */
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- acessibilidade: saltar e foco ---------- */
.saltar { position: absolute; left: 16px; top: -100px; z-index: 1000; background: var(--tinta); color: var(--papel); padding: 12px 18px; border-radius: 8px; font-weight: 700; text-decoration: none; }
.saltar:focus { top: 12px; }
:focus { outline: none; }
:focus-visible { outline: 3px solid var(--tinta); outline-offset: 3px; box-shadow: 0 0 0 6px var(--lima); border-radius: 4px; }
.escuro :focus-visible, .jogos :focus-visible, footer :focus-visible, .doca :focus-visible, .jogo-topo :focus-visible { outline-color: var(--lima); box-shadow: 0 0 0 6px var(--tinta); }
main:focus { outline: none; }

/* ---------- o marcador (passa quando entra no ecrã) e o risco à mão ---------- */
.marca-txt { position: relative; display: inline-block; white-space: nowrap; }
.marca-txt > svg { position: absolute; left: -3%; top: 48%; width: 106%; height: 50%; transform: rotate(-1.2deg); overflow: visible; z-index: 0;
  clip-path: inset(0 100% 0 0); transition: clip-path .7s cubic-bezier(.6,.05,.3,1); }
.marca-txt.visto > svg { clip-path: inset(0 0 0 0); }
.marca-txt > span { position: relative; z-index: 1; }
.q { display: inline-block; font-size: 1.3em; line-height: 0; margin-left: .02em; }
.riscado { position: relative; display: inline-block; color: var(--cinza); }
.riscado > svg { position: absolute; left: -4%; top: 28%; width: 108%; height: 50%; overflow: visible; pointer-events: none;
  clip-path: inset(0 100% 0 0); transition: clip-path .55s cubic-bezier(.5,0,.4,1); }
.riscado.visto > svg { clip-path: inset(0 0 0 0); }
.riscado path { fill: none; stroke: var(--tinta); stroke-linecap: round; stroke-width: max(4px, .07em); }
.riscado path + path { stroke-width: max(3px, .045em); }

/* ---------- cabeçalho ---------- */
.topo { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--papel) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.topo.com-linha { border-bottom-color: var(--linha); }
.topo .contentor { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 16px; }
.logo { font-size: 28px; text-decoration: none; letter-spacing: -.5px; white-space: nowrap; }
.topo .logo .marca-txt > svg g { filter: none; }
.topo .logo .marca-txt > svg { top: 44%; height: 56%; }
.menu { display: flex; gap: 28px; align-items: center; font-weight: 600; font-size: 15px; }
.menu a { text-decoration: none; }
.menu a:not(.btn):hover, .menu a[aria-current] { text-decoration: underline; text-decoration-color: var(--lima); text-decoration-thickness: 5px; }
.btn { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 10px 22px; border-radius: 999px; font: 700 15px Inter, system-ui, sans-serif; text-decoration: none; border: 2px solid var(--tinta); transition: transform .15s, box-shadow .15s; background: transparent; cursor: pointer; color: inherit; }
.btn:hover { transform: translate(-2px, -2px); box-shadow: 3px 3px 0 var(--tinta); }
.btn-escuro { background: var(--tinta); color: var(--papel); }
.btn-escuro:hover { box-shadow: 3px 3px 0 var(--lima); }
.btn-lima { background: var(--lima); color: var(--tinta); border-color: var(--tinta); }
.menu .btn { min-height: 40px; padding: 8px 18px; }

/* ---------- abertura ---------- */
.abertura { padding: 72px 0 40px; }
.abertura .sobre-tit { font-family: var(--mono); font-size: 14px; color: var(--cinza); margin-bottom: 28px; }
.abertura .sobre-tit b { color: var(--tinta); font-weight: 600; }
.abertura .lema-grande { font-size: clamp(52px, 13vw, 184px); letter-spacing: -.045em; line-height: .92; }
.abertura .lema-grande .l2 { display: block; }
.abertura .base { display: grid; grid-template-columns: 1fr auto; gap: 48px; align-items: end; margin-top: 44px; }
.abertura p.intro { max-width: 580px; font-size: 21px; line-height: 1.5; }
.abertura .acoes { display: flex; gap: 14px; margin-top: 30px; flex-wrap: wrap; }
.postit { width: 280px; background: #fff; border: 2px solid var(--tinta); border-radius: 4px; padding: 22px 22px 20px; transform: rotate(2.2deg); box-shadow: 6px 6px 0 var(--tinta); position: relative; }
.postit::before { content: ""; position: absolute; top: -13px; left: 50%; width: 84px; height: 24px; background: color-mix(in srgb, var(--lima) 70%, transparent); transform: translateX(-50%) rotate(-3deg); }
.postit .tag { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--cinza); }
.postit p:not(.tag) { font-weight: 600; margin: 8px 0 14px; line-height: 1.4; }
.postit .btn { width: 100%; justify-content: center; }

/* ---------- faixa a correr (com pausa) ---------- */
.faixa-caixa { position: relative; margin-top: 64px; }
.faixa { background: var(--lima); border-block: 2px solid var(--tinta); overflow: hidden; transform: rotate(-1deg); }
.faixa .rolo { display: flex; width: max-content; animation: rola 42s linear infinite; }
.faixa.parada .rolo, .faixa-caixa:hover .rolo { animation-play-state: paused; }
.faixa span { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: 26px; padding: 12px 0; white-space: nowrap; color: var(--tinta); }
.faixa span::after { content: "✳"; margin: 0 28px; font-size: .8em; }
@keyframes rola { to { transform: translateX(-50%); } }
.faixa-pausa { position: absolute; right: 16px; top: calc(100% + 10px); font: 600 13px var(--mono); background: transparent; border: 0; color: var(--cinza); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; padding: 6px; min-height: 32px; }

/* ---------- secções ---------- */
section { padding: 120px 0; position: relative; }
.etiqueta { display: inline-block; font-family: var(--mono); font-size: 14px; color: var(--cinza); margin-bottom: 18px; }
.etiqueta::before { content: "// "; }
h2 { font-size: clamp(40px, 6.5vw, 88px); letter-spacing: -.04em; margin-bottom: 22px; }
.sub { font-size: 19px; color: var(--cinza); max-width: 640px; }

/* ---------- índice (matérias e episódios), fundo escuro ---------- */
.escuro { background: var(--escuro); color: var(--papel); }
.escuro .etiqueta, .escuro .sub { color: var(--cinza-esc); }
.escuro .marca-txt > svg g { mix-blend-mode: normal !important; }
.serie-cab { display: flex; justify-content: space-between; align-items: end; gap: 32px; flex-wrap: wrap; }
.progresso { font-family: var(--mono); font-size: 14px; color: var(--cinza-esc); display: flex; flex-direction: column; gap: 8px; }
.progresso .barra { display: block; width: 220px; height: 8px; background: var(--linha-esc); border-radius: 99px; overflow: hidden; }
.progresso .barra i { display: block; height: 100%; width: 0; background: var(--lima); transition: width .5s; }
.indice { margin-top: 56px; border-top: 1px solid var(--linha-esc); }
.indice > li { border-bottom: 1px solid var(--linha-esc); position: relative; }
.indice .linha { display: grid; grid-template-columns: 90px 1fr 280px 170px; gap: 24px; align-items: center; padding: 28px 8px; text-decoration: none; }
.indice .num { font-family: var(--mono); font-size: 15px; color: var(--cinza-esc); }
.indice .tit { font-size: clamp(28px, 3.6vw, 46px); letter-spacing: -.03em; line-height: 1.05; transition: color .2s, transform .25s; }
.indice .desc { font-size: 15px; color: var(--claro-esc); line-height: 1.45; }
.indice .desc a { color: var(--papel); }
.indice .estado { font-family: var(--mono); font-size: 13px; text-align: right; align-self: start; padding-top: 10px; }
.indice .estado.ja { color: var(--lima); }
.indice .estado.breve, .indice .breve-l .tit, .indice .breve-l .num { color: var(--cinza-esc); }
/* ao passar o rato: título lima e seta (nada de bloco lima com texto escuro) */
.indice .tit .seta { font-style: normal; display: inline-block; opacity: 0; transform: translateX(-12px); transition: opacity .2s, transform .25s; color: var(--lima); }
.indice a.linha:hover .tit, .indice a.linha:focus-visible .tit { color: var(--lima); transform: translateX(6px); }
.indice a.linha:hover .seta, .indice a.linha:focus-visible .seta { opacity: 1; transform: none; }
.indice a.linha:focus-visible { box-shadow: inset 0 0 0 3px var(--lima); outline: none; border-radius: 6px; }
.feito { display: inline-flex; gap: 10px; align-items: center; font-family: var(--mono); font-size: 13px; cursor: pointer; min-height: 32px; }
.feito input { accent-color: var(--lima); width: 18px; height: 18px; }
.indice .feito { position: absolute; right: 8px; bottom: 8px; color: var(--claro-esc); }
.materias .linha { grid-template-columns: 110px 1fr 340px 200px; }
.materias .num { font-size: 17px; color: var(--lima); }
.materias .tit { font-size: clamp(34px, 5vw, 64px); }

/* ---------- últimos vídeos ---------- */
.cartoes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 48px; }
.cartao { text-decoration: none; display: flex; flex-direction: column; gap: 8px; }
.capa { display: flex; flex-direction: column; justify-content: flex-end; aspect-ratio: 16/9; border: 2px solid var(--tinta); border-radius: 8px; padding: 22px 24px; position: relative; overflow: hidden; color: var(--papel); }
.capa .sup { font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--lima); position: relative; }
.capa .tit { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: clamp(22px, 2.4vw, 30px); line-height: 1.02; letter-spacing: -.02em; margin-top: 6px; position: relative; }
.capa-css { background: var(--escuro); }
.capa-css::before { content: "{ }"; position: absolute; top: 6px; left: 20px; font-family: var(--mono); font-size: 76px; color: #232b2f; font-weight: 700; }
.capa-pyvin { background: #0a1630 url(jogos/pyvin-fundo.jpg) center/cover; }
.capa-pyvin img { position: absolute; top: 8px; right: 12px; width: 120px; height: auto; filter: drop-shadow(0 4px 10px rgba(0,0,0,.5)); }
.cartao .capa { transition: transform .2s, box-shadow .2s; }
.cartao:hover .capa, .cartao:focus-visible .capa { transform: translate(-4px, -4px); box-shadow: 6px 6px 0 var(--tinta); }
.cartao:focus-visible { box-shadow: none; outline-offset: 6px; }
.cartao .meta { display: flex; gap: 10px; margin-top: 8px; font-family: var(--mono); font-size: 12px; color: var(--cinza); }
.cartao .selo { background: var(--tinta); color: var(--lima); padding: 2px 8px; border-radius: 4px; }
.cartao-tit { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: 22px; letter-spacing: -.02em; line-height: 1.1; }
.cartao-txt { font-size: 15px; color: var(--cinza); }

/* ---------- os jogos: um portal para outro mundo ---------- */
.jogos { background: var(--noite); color: var(--papel); overflow: hidden; }
.jogos .etiqueta, .jogos .sub { color: #8f9ab8; }
.portais { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 64px; }
.portal { position: relative; display: flex; flex-direction: column; text-decoration: none; border: 2px solid var(--papel); border-radius: 14px; overflow: hidden; min-height: 640px; transition: transform .3s; }
.portal-pyvin { background: #0a1630 url(jogos/pyvin-fundo.jpg) center/cover; transform: rotate(-1deg); box-shadow: 10px 10px 0 #2f7fd8; }
.portal-javin { background: #1a1030 url(jogos/javin-fundo.jpg) center 8% / auto 118% no-repeat; transform: rotate(1deg); box-shadow: 10px 10px 0 #e0702a; }
.portal:hover, .portal:focus-visible { transform: rotate(0) translateY(-6px); }
.portal .arte { flex: 1; display: grid; place-items: center; padding: 40px 32px 10px; min-height: 260px; }
.portal .arte img { width: 78%; max-width: 420px; height: auto; filter: drop-shadow(0 10px 24px rgba(0,0,0,.6)); transition: transform .4s; }
.portal:hover .arte img { transform: scale(1.05) rotate(-1deg); }
.portal .ficha { display: block; background: rgba(8,10,20,.88); backdrop-filter: blur(6px); padding: 26px 28px 28px; border-top: 1px solid rgba(255,255,255,.12); }
.portal .ling { display: block; font-family: var(--mono); font-size: 13px; color: #a3acc8; }
.portal-nome { font-size: 34px; margin-top: 6px; color: #fff; }
.portal-txt { display: block; margin: 10px 0 18px; color: #d8dbe6; font-size: 16px; }
.numeros { display: flex; gap: 32px; margin-bottom: 22px; }
.numeros dt { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: 44px; line-height: 1; color: #fff; }
.numeros dd { font-family: var(--mono); font-size: 13px; color: #a3acc8; margin-top: 4px; }
.portal .btn { border-color: var(--papel); }
.portal .btn:not(.btn-lima) { color: var(--papel); }

/* ---------- ver, perceber, fazer ---------- */
.tres { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 64px; border-top: 2px solid var(--tinta); }
.tres > li { padding: 32px 32px 8px 0; }
.tres > li + li { padding-left: 32px; border-left: 1px solid var(--linha); }
.tres .grande { font-size: clamp(44px, 5vw, 68px); letter-spacing: -.04em; }
.tres .n { font-family: var(--mono); font-size: 13px; color: var(--cinza); display: block; margin-bottom: 14px; }
.tres p { color: var(--cinza); margin-top: 16px; font-size: 16px; max-width: 320px; }

/* ---------- manifesto e sobre ---------- */
.manifesto { padding: 140px 0; }
.manifesto blockquote > p { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: clamp(44px, 8.5vw, 124px); line-height: .98; letter-spacing: -.045em; }
.manifesto .quem { display: flex; align-items: center; gap: 14px; margin-top: 40px; font-weight: 600; background: none; padding: 0; color: var(--tinta); font-size: 17px; }
.manifesto .quem img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; object-position: 50% 22%; border: 2px solid var(--tinta); }
.manifesto .quem span { color: var(--cinza); font-weight: 400; }
.sobre { border-top: 2px solid var(--tinta); padding: 96px 0; }
.sobre .grelha { display: grid; grid-template-columns: 340px 1fr; gap: 72px; align-items: center; }
.foto { position: relative; transform: rotate(-2.5deg); }
.foto img { width: 100%; height: auto; aspect-ratio: 4/5; object-fit: cover; object-position: 50% 20%; border: 2px solid var(--tinta); border-radius: 4px; box-shadow: 8px 8px 0 var(--tinta); }
.foto::before { content: ""; position: absolute; top: -14px; left: 50%; width: 110px; height: 28px; background: color-mix(in srgb, var(--lima) 75%, transparent); transform: translateX(-50%) rotate(4deg); z-index: 1; }
.foto .legenda { position: absolute; right: -26px; bottom: 28px; background: var(--tinta); color: var(--papel); font-family: var(--mono); font-size: 13px; padding: 8px 12px; transform: rotate(4deg); border-radius: 4px; }
.sobre h2 { font-size: clamp(40px, 5vw, 64px); }
.sobre p:not(.etiqueta) { font-size: 21px; line-height: 1.5; max-width: 560px; }
.sobre p + p { margin-top: 16px; }
.sobre .ligacoes { margin-top: 30px; display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- rodapé ---------- */
body > footer { background: var(--escuro); color: var(--claro-esc); padding: 96px 0 110px;   /* em baixo: espaço para a doca não tapar o fim */ font-size: 15px; overflow: hidden; }
footer .assinatura { font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: clamp(44px, 9vw, 132px); line-height: .95; letter-spacing: -.045em; color: var(--papel); }
footer .assinatura em { font-style: normal; color: var(--lima); }
footer .linha1 { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px 24px; margin-top: 64px; padding-top: 28px; border-top: 1px solid var(--linha-esc); }
body > footer nav { display: flex; gap: 8px 24px; flex-wrap: wrap; }
body > footer nav a { color: var(--papel); font-weight: 600; text-decoration: none; padding: 4px 0; }
body > footer nav a:hover { color: var(--lima); text-decoration: underline; }
body > footer nav.legal a { font-weight: 400; color: var(--claro-esc); }
footer .copy { margin-top: 18px; }

/* ---------- a doca: tirar o CSS e inspecionar ---------- */
.doca { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 50; display: flex; gap: 4px; padding: 5px; background: var(--tinta); border: 1px solid rgba(245,242,234,.25); border-radius: 999px; box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.doca button { font: 600 13px var(--mono); color: var(--papel); background: transparent; border: 0; padding: 10px 16px; min-height: 40px; border-radius: 999px; cursor: pointer; white-space: nowrap; }
.doca button:hover { background: var(--escuro-2); }
.doca button[aria-pressed="true"] { background: var(--lima); color: var(--tinta); }

/* ---------- página de matéria e de episódio ---------- */
.ep-topo { padding: 64px 0 32px; }
.migalhas { font-family: var(--mono); font-size: 14px; color: var(--cinza); margin-bottom: 18px; }
.migalhas a:hover { color: var(--tinta); }
.ep-topo h1 { font-size: clamp(48px, 8vw, 112px); letter-spacing: -.045em; }
.intro-materia { margin-top: 22px; }
.ep-topo + section.escuro { margin-top: 48px; }
.video { position: relative; aspect-ratio: 16/9; background: var(--escuro); border: 2px solid var(--tinta); border-radius: 8px; box-shadow: 8px 8px 0 var(--tinta); overflow: hidden; }
.video iframe { width: 100%; height: 100%; border: 0; display: block; }
.video-play { all: unset; position: absolute; inset: 0; cursor: pointer; display: block; }
.video-play:focus-visible { outline: 4px solid var(--lima); outline-offset: -8px; }
.video .capa { position: absolute; inset: 0; border: 0; border-radius: 0; aspect-ratio: auto; padding: clamp(20px, 4vw, 48px); }
.video .capa .tit { font-size: clamp(28px, 5vw, 64px); }
.video .capa-css::before { font-size: clamp(80px, 14vw, 200px); }
.botao-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 84px; height: 84px; border-radius: 50%; background: var(--lima); color: var(--tinta); display: grid; place-items: center; border: 2px solid var(--tinta); transition: transform .2s; }
.video-play:hover .botao-play { transform: translate(-50%, -50%) scale(1.08); }
.video-aviso { font-size: 14px; color: var(--cinza); margin-top: 18px; max-width: 760px; }
.video.estreia .estreia-txt { position: absolute; left: 0; right: 0; top: 0; padding: 14px clamp(20px, 4vw, 48px); background: rgba(0,0,0,.55); color: var(--papel); font-size: 15px; }
.video.estreia .estreia-txt a { color: var(--lima); }
.ep-corpo { display: grid; grid-template-columns: 1fr 340px; gap: 64px; padding: 72px 0 120px; }
.etiqueta-h { font-family: var(--mono); font-size: 14px; font-weight: 400; letter-spacing: 0; color: var(--cinza); margin-bottom: 8px; }
.etiqueta-h::before { content: "// "; }
.percebes { counter-reset: p; }
.percebes li { counter-increment: p; padding: 16px 0 16px 52px; border-bottom: 1px solid var(--linha); position: relative; font-size: 18px; }
.percebes li::before { content: counter(p, decimal-leading-zero); position: absolute; left: 0; top: 19px; font-family: var(--mono); font-size: 13px; color: var(--cinza); }
.desafio { background: var(--escuro); color: var(--papel); border-radius: 8px; padding: 34px; margin-top: 56px; transform: rotate(-.6deg); box-shadow: 8px 8px 0 var(--lima); }
.desafio .tag { display: inline-block; background: var(--lima); color: var(--tinta); font: 800 13px Inter, sans-serif; letter-spacing: .1em; text-transform: uppercase; padding: 5px 12px; border-radius: 6px; }
.desafio .ent { margin: 20px 0 12px; font-size: 19px; }
.desafio ol { list-style: decimal; padding-left: 24px; font-size: 18px; }
.desafio li { margin: 8px 0; }
.desafio .dica { margin-top: 16px; color: var(--claro-esc); }
.desafio .assin { margin-top: 26px; font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: 30px; letter-spacing: -.02em; line-height: 1.1; }
.desafio .assin em { font-style: normal; color: var(--lima); }
.desafio code { background: var(--linha-esc); }
.desafio .feito { margin-top: 22px; font-size: 14px; }
.lateral .caixa { background: #fff; border: 2px solid var(--tinta); border-radius: 6px; padding: 24px; }
.lateral .caixa + .caixa { margin-top: 20px; }
.lateral h2 { font-size: 22px; letter-spacing: -.02em; margin-bottom: 10px; }
.lateral p { font-size: 15px; color: var(--cinza); }
.lateral .btn { margin-top: 16px; width: 100%; justify-content: center; }
.navep { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-top: 2px solid var(--tinta); padding: 28px 0 0; margin-top: 56px; font-weight: 700; }
.navep a { text-decoration: none; }
.navep a:hover { text-decoration: underline; text-decoration-color: var(--lima); text-decoration-thickness: 5px; }
.em-breve-txt { color: var(--cinza); font-weight: 400; }

/* ---------- página de jogo ---------- */
.jogo-topo { background: var(--noite) center/cover; color: #fff; padding: 56px 0 72px; position: relative; }
.jogo-topo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,10,20,.25), rgba(8,10,20,.85)); }
.jogo-topo > .contentor { position: relative; z-index: 1; }
.jogo-pyvin { background-image: url(jogos/pyvin-fundo.jpg); }
.jogo-javin { background-image: url(jogos/javin-fundo.jpg); background-position: center 8%; min-height: 560px; display: flex; align-items: flex-end; }
.jogo-javin > .contentor { width: 100%; }
.jogo-javin { min-height: 620px; }
.jogo-javin::after { background: linear-gradient(90deg, rgba(8,10,20,.92) 0%, rgba(8,10,20,.75) 40%, rgba(8,10,20,.1) 70%), linear-gradient(180deg, transparent 50%, rgba(8,10,20,.9)); }
.mundos-grelha { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; counter-reset: m; }
.mundos-grelha li { background: #141a2b; border: 1px solid #222a3d; border-radius: 10px; padding: 20px; font-family: 'Bricolage Grotesque'; font-weight: 800; font-size: 22px; line-height: 1.1; color: #fff; min-height: 120px; }
@media (max-width: 900px) { .mundos-grelha { grid-template-columns: 1fr 1fr; } }
.jogo-topo .migalhas { color: #c3c9dc; }
.jogo-topo .migalhas a:hover { color: #fff; }
.jogo-logo { width: min(520px, 90%); height: auto; margin: 10px 0 24px; filter: drop-shadow(0 10px 24px rgba(0,0,0,.6)); }
.jogo-frase { font-size: 21px; max-width: 640px; color: #e6e8f0; margin-bottom: 28px; }
.jogo-ufcd { font-family: var(--mono); font-size: 13px; color: #c3c9dc; }
.jogo-lista { padding: 80px 0 120px; }
.jogo-lista h2 { margin-bottom: 40px; }
.mundo { padding: 32px 0; border-top: 1px solid #222a3d; }
.mundo h3 { font-size: clamp(26px, 3vw, 36px); margin-bottom: 22px; }
.mundo-n { display: block; font-family: var(--mono); font-size: 13px; font-weight: 400; letter-spacing: 0; color: #8f9ab8; margin-bottom: 8px; }
.licoes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.licao .video { box-shadow: 6px 6px 0 #2f7fd8; border-color: #c3c9dc; }
.licao .video .capa .tit { font-size: clamp(20px, 2vw, 26px); }
.licao .video .capa-pyvin img { width: 90px; }
.licao .botao-play { width: 56px; height: 56px; }
.licao h4 { font-size: 22px; margin-top: 18px; color: #fff; }
.licao .estado-l { font-family: var(--mono); font-size: 13px; color: var(--lima); margin-top: 6px; }
.licao .video-aviso { color: #a3acc8; font-size: 12px; }
.licao .video.estreia .estreia-txt { font-size: 13px; padding: 10px 14px; }
.mundo-vazio { color: #a3acc8; }
.aviso-estreia { color: #d8dbe6; background: #141a2b; border: 1px solid #222a3d; border-left: 6px solid var(--lima); border-radius: 6px; padding: 14px 18px; margin-bottom: 24px; max-width: 760px; }
.aviso-estreia a { color: var(--lima); }

/* ---------- páginas legais e 404 ---------- */
.texto-legal { max-width: 820px; padding-bottom: 120px; }
.texto-legal .atualizado { font-family: var(--mono); font-size: 13px; color: var(--cinza); margin-top: 18px; }
.texto-legal h2 { font-size: 32px; margin: 48px 0 14px; }
.texto-legal h3 { font-size: 22px; margin: 28px 0 8px; }
.texto-legal p, .texto-legal li { font-size: 18px; line-height: 1.65; }
.texto-legal p + p { margin-top: 12px; }
.texto-legal ul { list-style: disc; padding-left: 24px; }
.texto-legal li + li { margin-top: 8px; }
.destaque-legal { background: #fff; border: 2px solid var(--tinta); border-left: 10px solid var(--lima); padding: 18px 22px; border-radius: 6px; }
.pag-404 { padding: 96px 32px 140px; }
.pag-404 h1 { font-size: clamp(48px, 9vw, 120px); letter-spacing: -.045em; margin-bottom: 28px; line-height: 1; }
.pag-404 .sub { margin-bottom: 32px; }

/* ---------- ecrãs pequenos ---------- */
@media (max-width: 1000px) {
  .licoes { grid-template-columns: 1fr 1fr; }
  .materias .linha, .indice .linha { grid-template-columns: 70px 1fr 240px; }
  .indice .estado { grid-column: 3; }
  .indice .desc { grid-column: 2 / 4; grid-row: 2; }
}
@media (max-width: 900px) {
  .contentor { padding: 0 16px; }
  .menu { gap: 16px; }
  .menu a:not(.btn) { display: none; }
  .abertura { padding: 44px 0 24px; }
  .abertura .base { grid-template-columns: 1fr; gap: 40px; }
  .postit { width: auto; max-width: 320px; }
  section { padding: 80px 0; }
  .materias .linha, .indice .linha { grid-template-columns: 56px 1fr; gap: 6px 14px; padding: 22px 0; }
  .indice .desc, .indice .estado { grid-column: 2; grid-row: auto; text-align: left; padding-top: 0; }
  .indice .feito { position: static; margin: 0 0 18px 70px; }
  .cartoes, .portais, .licoes { grid-template-columns: 1fr; }
  .portais { gap: 36px; }
  .portal { min-height: 540px; }
  .tres { grid-template-columns: 1fr; }
  .tres > li, .tres > li + li { padding: 28px 0; border-left: 0; border-bottom: 1px solid var(--linha); }
  .sobre .grelha { grid-template-columns: 1fr; gap: 48px; }
  .foto { max-width: 300px; }
  .foto .legenda { right: -8px; }
  .ep-corpo { grid-template-columns: 1fr; gap: 48px; }
  .desafio { padding: 26px 22px; }
  .faixa span { font-size: 20px; }
  .pag-404 { padding: 64px 16px 96px; }
}
@media (max-width: 420px) {
  .logo { font-size: 24px; }
  .menu .btn { padding: 6px 14px; font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
  .marca-txt > svg, .riscado > svg { clip-path: none; }
  .faixa .rolo { animation: none; }
}
@media print {
  .topo, .doca, .faixa-caixa, .postit, body::before { display: none !important; }
  body > footer { padding-bottom: 36px; }
}

/* ================= brincar: gravidade, o "?" e o "Mexe no CSS" ================= */
html { scrollbar-gutter: stable; }
.doca { max-width: calc(100vw - 24px); overflow-x: auto; scrollbar-width: none; }
.doca::-webkit-scrollbar { display: none; }
.doca .doca-q { font: 800 18px 'Bricolage Grotesque', sans-serif; padding: 6px 15px; }
@media (max-width: 600px) { .doca button { padding: 10px 11px; font-size: 12px; } }

/* gravidade: as peças saem das caixas, por isso nada as pode cortar */
.gravidade, .gravidade body { overflow: hidden; }
.gravidade .jogos, .gravidade body > footer, .gravidade .portal, .gravidade .faixa, .gravidade .capa, .gravidade .video { overflow: visible; }
.gravidade .portal, .gravidade .postit, .gravidade .foto, .gravidade .faixa, .gravidade .desafio { transform: none; }
.gravidade .marca-txt > svg, .gravidade .riscado > svg { transition: none; }
.palavra { display: inline-block; }
.camada-gravidade { position: fixed; inset: 0; z-index: 45; cursor: grab; touch-action: none; }
.camada-gravidade:active { cursor: grabbing; }

/* o "?": a mascote (o ponto de interrogação do logótipo) */
.mascote { position: fixed; left: 0; top: 0; z-index: 48; width: 46px; height: 72px; padding: 0; border: 0; background: none; cursor: grab; touch-action: none;
  color: var(--tinta); font: 800 84px/72px 'Bricolage Grotesque', sans-serif; text-align: center; transform-origin: 50% 100%; }
.mascote:active { cursor: grabbing; }
.mascote-corpo { display: block; pointer-events: none; text-shadow: 3px 3px 0 var(--lima); user-select: none; -webkit-text-stroke: 3px var(--papel); paint-order: stroke fill; }   /* o contorno de papel vê-se nos fundos escuros */
.mascote.esquerda .mascote-corpo { transform: scaleX(-1); }
.mascote.dormir { left: 18px; top: auto; bottom: 12px; transform: rotate(-12deg) scale(.8); transition: transform .3s; }
.mascote.dormir:hover, .mascote.dormir:focus-visible { transform: rotate(0) scale(.9) translateY(-6px); }
.mascote.dormir .mascote-corpo::after { content: "z"; position: absolute; top: -6px; right: -10px; font: 700 14px var(--mono); color: var(--cinza); text-shadow: none; }
.mascote[hidden], .painel-css[hidden] { display: none; }
.mascote-fala { position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%) scale(.6); opacity: 0; pointer-events: none; white-space: nowrap;
  background: var(--tinta); color: var(--papel); font: 600 13px var(--mono); padding: 7px 11px; border-radius: 8px; transition: opacity .2s, transform .2s; text-shadow: none; }
.mascote-fala::after { content: ""; position: absolute; top: 100%; left: 50%; margin-left: -6px; border: 6px solid transparent; border-top-color: var(--tinta); }
.mascote-fala.ve { opacity: 1; transform: translateX(-50%) scale(1); }
.mascote.dormir .mascote-fala { left: 0; transform: none; }

/* Mexe no CSS */
.painel-css { position: fixed; right: 16px; bottom: 80px; z-index: 55; width: min(420px, calc(100vw - 32px)); max-height: calc(100vh - 120px); overflow: auto;
  background: var(--tinta); color: var(--papel); border: 2px solid var(--papel); border-radius: 12px; box-shadow: 8px 8px 0 var(--lima); padding: 20px; }
.painel-cab { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.painel-css h2 { font-size: 26px; margin: 0; letter-spacing: -.02em; }
.painel-fechar { background: none; border: 0; color: var(--papel); font-size: 30px; line-height: 1; width: 44px; height: 44px; cursor: pointer; border-radius: 8px; }
.painel-css p { font-size: 14px; color: var(--claro-esc); margin: 8px 0; }
.painel-rec-tit { font-family: var(--mono); }
.painel-receitas { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.painel-receitas button { font: 600 12px var(--mono); background: var(--escuro-2); color: var(--papel); border: 1px solid var(--linha-esc); border-radius: 999px; padding: 7px 11px; cursor: pointer; min-height: 32px; }
.painel-receitas button:hover { border-color: var(--lima); color: var(--lima); }
.painel-css textarea { width: 100%; min-height: 230px; resize: vertical; background: #0e1214; color: #e6e8e6; border: 1px solid var(--linha-esc); border-radius: 8px;
  padding: 12px; font: 13px/1.55 var(--mono); tab-size: 2; }
.painel-acoes { display: flex; justify-content: flex-end; margin-top: 12px; }
.painel-acoes .btn { border-color: var(--papel); }
.jogo-nota { font-size: 14px; color: #c3c9dc; margin-top: 8px; }
@media (max-width: 600px) { .painel-css { right: 8px; left: 8px; width: auto; bottom: 72px; } }
@media print { .mascote, .painel-css, .camada-gravidade { display: none !important; } }

/* ================= telemóvel (revisão de 2026-11-18) ================= */
.doca-abre { display: none; }
@media (max-width: 700px) {
  /* a doca vira um botão só, no canto direito; o "?" dorme no canto esquerdo */
  .doca { left: auto; right: 12px; bottom: 12px; transform: none; padding: 4px; overflow: visible; max-width: none; flex-direction: column; align-items: flex-end; border-radius: 26px; }
  .doca-abre { display: inline-flex; align-items: center; gap: 8px; font: 700 13px var(--mono) !important; padding: 10px 16px !important; min-height: 44px; }
  .doca-abre span { color: var(--lima); }
  .doca-botoes { display: none; flex-direction: column; align-items: stretch; gap: 2px; padding: 6px 4px 4px; min-width: 190px; }
  .doca.aberta .doca-botoes { display: flex; }
  .doca.aberta { border-radius: 18px; }
  .doca.aberta .doca-abre { order: 2; }
  .doca-botoes button { text-align: left; font-size: 14px !important; padding: 12px 14px !important; min-height: 44px; border-radius: 12px; }
  .doca .doca-q { text-align: left; }
  .doca .doca-q::after { content: "  mostrar / esconder"; font: 600 13px var(--mono); }
  .painel-css { bottom: 76px; }
}
@media (max-width: 900px) {
  .topo .contentor { height: 60px; }
  html { scroll-padding-top: 72px; }
  .abertura { padding: 32px 0 16px; }
  .abertura .sobre-tit { font-size: 13px; margin-bottom: 18px; }
  .abertura .lema-grande { font-size: clamp(56px, 17.5vw, 120px); }
  .abertura .base { margin-top: 28px; gap: 36px; }
  .abertura p.intro { font-size: 18px; }
  .abertura .acoes { margin-top: 22px; }
  .abertura .acoes .btn { flex: 1 1 auto; justify-content: center; }
  .postit { margin: 0 auto 0 4px; transform: rotate(1.5deg); }
  .faixa-caixa { margin-top: 44px; }
  section { padding: 64px 0; }
  h2 { font-size: clamp(36px, 11vw, 56px); margin-bottom: 16px; }
  .sub { font-size: 17px; }
  .indice { margin-top: 36px; }
  /* últimos vídeos: carrossel que se arrasta com o dedo */
  .cartoes { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 16px; margin: 32px -16px 0; padding: 4px 16px 12px; scrollbar-width: none; }
  .cartoes::-webkit-scrollbar { display: none; }
  .cartoes > li { flex: 0 0 82%; scroll-snap-align: start; }
  .cartao .capa .tit { font-size: 22px; }
  .serie-cab .btn { margin-top: -4px; }
  /* jogos */
  .portais { margin-top: 36px; gap: 28px; }
  .portal { min-height: 0; transform: none !important; }
  .portal .arte { min-height: 170px; padding: 28px 20px 8px; }
  .portal .arte img { width: 70%; }
  .portal-javin .arte { min-height: 210px; }
  .portal .ficha { padding: 20px; }
  .portal-nome { font-size: 28px; }
  .numeros { gap: 24px; margin-bottom: 18px; }
  .numeros dt { font-size: 36px; }
  /* ver, perceber, fazer: em linha, mais curto */
  .tres { margin-top: 36px; }
  .tres > li, .tres > li + li { padding: 20px 0; display: grid; grid-template-columns: 34px 1fr; column-gap: 8px; align-items: baseline; }
  .tres .n { margin: 0; }
  .tres .grande { font-size: 40px; }
  .tres p { grid-column: 2; margin-top: 8px; }
  .manifesto { padding: 72px 0; }
  .manifesto blockquote > p { font-size: clamp(40px, 12vw, 64px); }
  .sobre { padding: 64px 0; }
  .sobre .grelha { gap: 36px; }
  .foto { max-width: 240px; margin-left: 8px; }
  .sobre p:not(.etiqueta) { font-size: 18px; }
  body > footer { padding: 64px 0 96px; }
  footer .linha1 { margin-top: 40px; flex-direction: column; align-items: flex-start; }
  /* páginas interiores */
  .ep-topo { padding: 36px 0 24px; }
  .ep-topo h1 { font-size: clamp(42px, 13vw, 72px); }
  .ep-topo + section.escuro { margin-top: 24px; }
  .video { box-shadow: 5px 5px 0 var(--tinta); }
  .botao-play { width: 64px; height: 64px; }
  .ep-corpo { padding: 40px 0 72px; }
  .percebes li { font-size: 16px; padding: 14px 0 14px 40px; }
  .desafio { margin-top: 40px; transform: none; box-shadow: 5px 5px 0 var(--lima); }
  .desafio .assin { font-size: 24px; }
  .jogo-topo { padding: 32px 0 44px; }
  .jogo-javin { min-height: 520px; }
  .jogo-frase { font-size: 17px; }
  .jogo-lista { padding: 48px 0 72px; }
  .licoes { grid-template-columns: 1fr 1fr; gap: 16px; }
  .licao .video { box-shadow: 4px 4px 0 #2f7fd8; }
  .licao .video .capa { padding: 12px; }
  .licao .video .capa .tit { font-size: 15px; }
  .licao .video .capa .sup { font-size: 10px; }
  .licao .video .capa-pyvin img { width: 54px; top: 4px; right: 6px; }
  .licao h4 { font-size: 16px; margin-top: 12px; }
  .licao .estado-l { font-size: 11px; }
  .mundo { padding: 24px 0; }
  .texto-legal h2 { font-size: 26px; margin-top: 36px; }
  .texto-legal p, .texto-legal li { font-size: 16px; }
  .migalhas a { display: inline-block; padding: 6px 0; }
}
@media (max-width: 900px) {
  .cartoes { scroll-padding-inline: 16px; }
  /* o "?" a dormir espreita da borda, para não tapar o texto */
  .mascote.dormir { left: -10px; bottom: 20px; transform: rotate(16deg) scale(.68); }
  .mascote.dormir:hover, .mascote.dormir:focus-visible { transform: rotate(4deg) scale(.8) translateX(10px); }
  .mascote.dormir .mascote-corpo::after { display: none; }
}

/* ---------- cabeçalho no telemóvel (Safari do iOS com a barra flutuante) ----------
   O Safari pinta a zona de cima com a cor de um cabeçalho FIXO e OPACO; com um cabeçalho
   "sticky" e semitransparente, deixava ver a página por trás, por cima do cabeçalho. */
html { background: var(--papel); }
@media (max-width: 900px) {
  .topo { position: fixed; left: 0; right: 0; top: 0; background: var(--papel); backdrop-filter: none; }
  body { padding-top: 60px; }
}
.lista-yt { margin: 0 0 14px; }
.capa-img { padding: 0 !important; background: var(--escuro); }
.capa-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.licao .video .capa-img img { object-fit: cover; }
.jogo-lista-javin .licao .video { box-shadow: 4px 4px 0 #e0702a; }
.jogos .video-aviso { color: #a3acc8; margin: 0 0 24px; } .jogos .video-aviso a { color: var(--lima); }
.video video { width: 100%; height: 100%; display: block; background: #000; }

/* ---------- a página não desliza para os lados (Safari do iOS) ----------
   O iOS deixa arrastar para o lado se alguma coisa passar da largura do ecrã, mesmo com
   overflow-x: hidden no body (a faixa rodada, o traço do marcador, o carrossel).
   "clip" corta sem criar uma caixa com scroll, por isso não estraga o cabeçalho nem a gravidade. */
html, body { overscroll-behavior-x: none; }
.topo, main, body > footer { overflow-x: hidden; }
@supports (overflow-x: clip) { .topo, main, body > footer { overflow-x: clip; } }

/* ---------- o lema grande deixou de ser o h1 (o h1 é a marca, para o Google); o aspeto é o mesmo ---------- */
.abertura .lema-grande { font-family: 'Bricolage Grotesque', Inter, sans-serif; font-weight: 800; }
.abertura h1.sobre-tit { font-family: var(--mono); font-weight: 400; font-size: 14px; letter-spacing: 0; line-height: 1.6; color: var(--cinza); }
.abertura h1.sobre-tit b { color: var(--tinta); font-weight: 600; }
@media (max-width: 900px) { .abertura h1.sobre-tit { font-size: 13px; } }

/* ---------- perguntas ---------- */
.perguntas { border-top: 2px solid var(--tinta); padding: 96px 0; }
.faq { max-width: 860px; margin-top: 36px; border-top: 1px solid var(--linha); }
.faq details { border-bottom: 1px solid var(--linha); }
.faq summary { cursor: pointer; list-style: none; padding: 22px 48px 22px 0; position: relative; font-family: 'Bricolage Grotesque', Inter, sans-serif; font-weight: 800; font-size: clamp(20px, 2.4vw, 26px); letter-spacing: -.02em; line-height: 1.2; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font: 700 28px var(--mono); transition: transform .2s; }
.faq details[open] summary::after { content: "−"; }
.faq summary:hover { text-decoration: underline; text-decoration-color: var(--lima); text-decoration-thickness: 5px; text-underline-offset: 4px; }
.faq details p { padding: 0 0 24px; font-size: 18px; color: var(--cinza); max-width: 720px; }
@media (max-width: 900px) { .perguntas { padding: 64px 0; } .faq details p { font-size: 16px; } }
