/* Mesteze — folha de estilo
   Identidade: madeira, couro, barro, metal batido. Tipografia de sistema —
   títulos em caixa alta bem carregada (efeito "chapa martelada" / rótulo
   gravado), corpo em serifa de leitura, dados e legendas em monoespaçada
   de máquina de escrever de oficina. Sem nenhuma dependência externa. */

:root {
  /* --- claro: barro, linho cru, ferro em repouso --- */
  --bg: #e9e2d3;
  --bg-alt: #ddd2b8;
  --superficie: #f6f1e5;
  --superficie-2: #ece1c9;
  --texto: #241f18;
  --texto-suave: #5c5443;
  --linha: #c7bb9c;
  --marca: #9c3b1f;        /* ferro em brasa, oxidado */
  --marca-forte: #742a16;  /* ferrugem escura */
  --marca-clara: #c06238;
  --acento: #52684a;       /* pátina, azinhaga */
  --acento-forte: #37472f;
  --ouro: #9c7530;         /* latão envelhecido */
  --ok-bg: #e4ecdd;
  --ok-texto: #3a4f2f;
  --raro-bg: #f1e5c9;
  --raro-texto: #7a5a17;
  --extinto-bg: #e6ded1;
  --extinto-texto: #56503f;
  --sombra: 0 8px 26px -14px rgba(36, 31, 24, .38);
  --raio: 10px;
  --display: "Arial Black", "Haettenschweiler", "Franklin Gothic Bold", "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  --serif: Cambria, "Hoefler Text", "Liberation Serif", Georgia, ui-serif, serif;
  --sans: "Segoe UI", ui-sans-serif, system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --mono: "Courier New", Courier, "Liberation Mono", ui-monospace, "SFMono-Regular", monospace;
  /* tokens abstratos da camada premium */
  --realce: var(--marca);
  --realce-forte: var(--marca-forte);
  --realce-suave: color-mix(in srgb, var(--marca) 22%, transparent);
  --tinta-sobre-realce: #fbf3e4;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #18140f;
    --bg-alt: #201a13;
    --superficie: #241d15;
    --superficie-2: #2c2418;
    --texto: #ece3d2;
    --texto-suave: #beaf92;
    --linha: #423625;
    --marca: #e07f45;
    --marca-forte: #f2a468;
    --marca-clara: #e8975f;
    --acento: #93ab80;
    --acento-forte: #b3cca0;
    --ouro: #cda550;
    --ok-bg: #26301f;
    --ok-texto: #b7d6a0;
    --raro-bg: #362c14;
    --raro-texto: #e0bd6a;
    --extinto-bg: #2b271e;
    --extinto-texto: #b3a88f;
    --sombra: 0 10px 30px -14px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #18140f;
  --bg-alt: #201a13;
  --superficie: #241d15;
  --superficie-2: #2c2418;
  --texto: #ece3d2;
  --texto-suave: #beaf92;
  --linha: #423625;
  --marca: #e07f45;
  --marca-forte: #f2a468;
  --marca-clara: #e8975f;
  --acento: #93ab80;
  --acento-forte: #b3cca0;
  --ouro: #cda550;
  --ok-bg: #26301f;
  --ok-texto: #b7d6a0;
  --raro-bg: #362c14;
  --raro-texto: #e0bd6a;
  --extinto-bg: #2b271e;
  --extinto-texto: #b3a88f;
  --sombra: 0 10px 30px -14px rgba(0, 0, 0, .6);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--texto);
  font-family: var(--serif);
  font-size: 16.5px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }

h1, h2, h3, h4 {
  font-family: var(--display);
  color: var(--texto);
  line-height: 1.08;
  margin: 0 0 .7rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .01em;
}
h1 { font-size: clamp(1.9rem, 4.3vw, 3rem); letter-spacing: 0; }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); line-height: 1.02; letter-spacing: 0; }
h2 { font-size: clamp(1.35rem, 2.8vw, 1.9rem); }
h3 { font-size: 1.12rem; letter-spacing: .01em; }
h4 { font-size: .92rem; letter-spacing: .04em; }

p { margin: 0 0 1rem; color: var(--texto); }
a { color: var(--marca-forte); }

.moldura {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.4rem;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.saltar-conteudo {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--marca-forte); color: #fbf3e4; padding: .7rem 1.2rem;
  border-radius: 0 0 8px 0; font-weight: 700; font-family: var(--sans);
}
.saltar-conteudo:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--ouro);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ---------- cabeçalho ---------- */
.cabecalho {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 93%, transparent);
  backdrop-filter: blur(6px);
  border-bottom: 2px solid var(--linha);
}
.cabecalho .moldura {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding-top: .8rem; padding-bottom: .8rem;
}
.marca {
  display: flex; align-items: center; gap: .6rem;
  font-family: var(--display); font-weight: 900; font-size: 1.2rem;
  text-transform: uppercase; letter-spacing: .03em;
  color: var(--texto); text-decoration: none; white-space: nowrap;
}
.marca:hover { color: var(--marca-forte); }
.marca svg { width: 34px; height: 34px; flex: none; }

.nav-principal { display: flex; align-items: center; gap: .3rem; }
.nav-principal ul {
  display: flex; list-style: none; margin: 0; padding: 0; gap: .1rem; flex-wrap: wrap;
}
.nav-principal a {
  display: inline-block; padding: .5rem .75rem; border-radius: 6px;
  color: var(--texto-suave); text-decoration: none; font-weight: 700; font-size: .86rem;
  font-family: var(--sans); text-transform: uppercase; letter-spacing: .03em;
  transition: background .15s ease, color .15s ease;
}
.nav-principal a:hover { color: var(--texto); }
.nav-principal a[aria-current="page"] { color: var(--marca-forte); }

.botao-tema {
  border: 1px solid var(--linha); background: var(--superficie);
  color: var(--texto); width: 38px; height: 38px; border-radius: 6px;
  display: grid; place-items: center; cursor: pointer; flex: none;
  transition: transform .15s ease, background .15s ease;
}
.botao-tema:hover { background: var(--superficie-2); }
.botao-tema:active { transform: scale(.92); }
.botao-tema svg { width: 18px; height: 18px; }

.botao-nav-movel {
  display: none; border: 1px solid var(--linha); background: var(--superficie);
  border-radius: 6px; width: 38px; height: 38px; cursor: pointer;
  align-items: center; justify-content: center; flex: none;
}
.botao-nav-movel svg { width: 20px; height: 20px; stroke: var(--texto); }

@media (max-width: 980px) {
  .botao-nav-movel { display: inline-flex; }
  .nav-principal {
    position: absolute; inset: 100% 0 auto 0; background: var(--bg);
    border-bottom: 2px solid var(--linha); box-shadow: var(--sombra);
    display: none; padding: .5rem 1.4rem 1rem;
  }
  .nav-principal.aberta { display: block; }
  .nav-principal ul { flex-direction: column; gap: .1rem; }
  .nav-principal a { display: block; }
}

/* ---------- secções ---------- */
.seccao { padding: 4rem 0; }
.seccao-alt { background: var(--bg-alt); }
.seccao-fina { padding: 2.6rem 0; }

.etiqueta {
  display: inline-flex; align-items: center; gap: .4rem;
  font-family: var(--mono); font-size: .74rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--marca-forte); background: var(--superficie-2);
  border: 1px solid var(--linha); padding: .3rem .7rem; border-radius: 4px;
  margin-bottom: 1rem;
}

.lead { font-size: 1.12rem; color: var(--texto-suave); max-width: 62ch; }

/* ---------- hero ---------- */
.hero { position: relative; padding: 4.4rem 0 3.2rem; overflow: hidden; border-bottom: 1px solid var(--linha); }
.hero-fundo { position: absolute; inset: 0; z-index: 0; opacity: .5; pointer-events: none; }
.hero .moldura { position: relative; z-index: 1; }
.hero-grelha {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.5rem; align-items: center;
}
@media (max-width: 860px) { .hero-grelha { grid-template-columns: 1fr; } }

.acoes { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.6rem; }

.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--sans); font-weight: 700; font-size: .88rem;
  text-transform: uppercase; letter-spacing: .03em;
  padding: .75rem 1.3rem; border-radius: 6px; text-decoration: none;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .15s ease, background .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primario { background: var(--marca-forte); color: #fbf3e4; box-shadow: var(--sombra); }
.btn-primario:hover { background: var(--marca); }
.btn-secundario { background: var(--superficie); border-color: var(--linha); color: var(--texto); }
.btn-secundario:hover { border-color: var(--marca-clara); }
.btn-fantasma { background: transparent; border-color: var(--linha); color: var(--texto-suave); }
.btn-fantasma:hover { color: var(--texto); border-color: var(--marca-clara); }

/* ---------- grelhas / cartões ---------- */
.grelha-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.grelha-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.4rem; }
@media (max-width: 860px) { .grelha-3, .grelha-2 { grid-template-columns: 1fr; } }

.cartao {
  background: var(--superficie); border: 1px solid var(--linha);
  border-radius: var(--raio); padding: 1.7rem; box-shadow: var(--sombra);
}
.cartao-destaque {
  background: linear-gradient(160deg, var(--superficie) 0%, var(--superficie-2) 100%);
  border: 1px solid var(--linha); border-radius: var(--raio);
  padding: 2.1rem; box-shadow: var(--sombra);
  display: flex; flex-direction: column; gap: .9rem;
  border-top: 3px solid var(--marca);
}
.cartao-destaque h3 { font-size: 1.3rem; }
.icone-destaque {
  width: 46px; height: 46px; border-radius: 8px;
  background: var(--marca-forte); color: #fbf3e4;
  display: grid; place-items: center; flex: none;
}
.icone-destaque svg { width: 24px; height: 24px; }

/* ---------- texto corrido ---------- */
.artigo { max-width: 72ch; }
.artigo h2 { margin-top: 2.4rem; }
.artigo h2:first-child { margin-top: 0; }
.artigo ul, .artigo ol { padding-left: 1.3rem; }
.artigo li { margin-bottom: .4rem; }
.artigo blockquote {
  margin: 1.6rem 0; padding: .3rem 0 .3rem 1.2rem; border-left: 3px solid var(--marca);
  color: var(--texto-suave); font-style: italic;
}
.nota-verificar {
  display: inline-block; font-family: var(--mono); font-size: .82em;
  color: var(--marca-forte); background: var(--superficie-2);
  border: 1px dashed var(--marca-clara); border-radius: 4px; padding: .05em .4em;
}

table { border-collapse: collapse; width: 100%; }
caption { text-align: left; font-weight: 700; margin-bottom: .5rem; font-family: var(--sans); }
th, td { text-align: left; padding: .5rem .7rem; border-bottom: 1px solid var(--linha); vertical-align: top; }
th { font-family: var(--mono); font-size: .76rem; text-transform: uppercase; letter-spacing: .06em; color: var(--texto-suave); }
.tabela-scroll { overflow-x: auto; border: 1px solid var(--linha); border-radius: var(--raio); }
.tabela-scroll table { min-width: 560px; }

/* ---------- selo documental (reforço "não representamos artesãos") ---------- */
.selo-documental {
  display: flex; gap: .9rem; align-items: flex-start;
  background: var(--superficie-2); border: 1px dashed var(--marca-clara);
  border-radius: var(--raio); padding: 1.1rem 1.3rem; margin: 1.8rem 0;
}
.selo-documental svg { width: 28px; height: 28px; flex: none; color: var(--marca-forte); }
.selo-documental p { margin: 0; font-size: .92rem; color: var(--texto-suave); }
.selo-documental strong { color: var(--texto); }

/* ---------- estado do ofício (crachá) ---------- */
.estado {
  display: inline-flex; align-items: center; gap: .35rem;
  font-family: var(--mono); font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
  padding: .28rem .6rem; border-radius: 999px; white-space: nowrap;
}
.estado::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.estado-ativo { background: var(--ok-bg); color: var(--ok-texto); }
.estado-raro { background: var(--raro-bg); color: var(--raro-texto); }
.estado-extinto { background: var(--extinto-bg); color: var(--extinto-texto); }

/* ---------- catálogo de ofícios ---------- */
.oficios-lista { display: flex; flex-direction: column; gap: 2.4rem; }

.ficha-oficio {
  background: var(--superficie); border: 1px solid var(--linha); border-radius: var(--raio);
  padding: 2rem; box-shadow: var(--sombra); scroll-margin-top: 6rem;
}
.ficha-oficio-cabecalho {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start;
  gap: 1rem; margin-bottom: .3rem; padding-bottom: 1.1rem; border-bottom: 2px solid var(--linha);
}
.ficha-oficio-titulo { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.ficha-oficio-numero {
  font-family: var(--mono); font-size: .8rem; color: var(--texto-suave);
  border: 1px solid var(--linha); border-radius: 4px; padding: .15rem .5rem;
}
.ficha-oficio-titulo h3 { margin: 0; font-size: 1.5rem; }

.ficha-oficio-corpo { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2rem; margin-top: 1.4rem; }
@media (max-width: 900px) { .ficha-oficio-corpo { grid-template-columns: 1fr; } }

.ficha-oficio-dados dl { display: grid; grid-template-columns: auto 1fr; gap: .35rem 1rem; margin: 0 0 1.2rem; }
.ficha-oficio-dados dt {
  font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .05em;
  color: var(--texto-suave); padding-top: .1rem;
}
.ficha-oficio-dados dd { margin: 0; }

/* ---------- gesto animado (elemento-assinatura nº1) ---------- */
.gesto { background: var(--superficie-2); border: 1px solid var(--linha); border-radius: var(--raio); padding: 1.2rem; }
.gesto-svg-caixa {
  background: var(--bg); border: 1px solid var(--linha); border-radius: 8px;
  padding: .6rem; display: flex; align-items: center; justify-content: center;
}
.gesto-svg-caixa svg { width: 100%; height: auto; max-height: 220px; display: block; }

.gesto-figura { stroke: var(--texto); }
.gesto-ferramenta { stroke: var(--marca-forte); }
.gesto-peca { stroke: var(--acento-forte); }
.gesto-fundo-linha { stroke: var(--linha); }

.gesto-controlos { margin-top: .9rem; display: flex; flex-wrap: wrap; gap: .7rem; align-items: center; justify-content: space-between; }
.gesto-velocidade { display: inline-flex; border: 1px solid var(--linha); border-radius: 6px; overflow: hidden; }
.gesto-velocidade button {
  font-family: var(--mono); font-size: .74rem; text-transform: uppercase; letter-spacing: .04em;
  background: var(--superficie); color: var(--texto-suave); border: none; padding: .4rem .7rem;
  cursor: pointer; border-right: 1px solid var(--linha);
}
.gesto-velocidade button:last-child { border-right: none; }
.gesto-velocidade button[aria-pressed="true"] { background: var(--marca-forte); color: #fbf3e4; }
.gesto-velocidade button:disabled { opacity: .4; cursor: not-allowed; }

.gesto-modo-passo {
  font-family: var(--sans); font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
  background: var(--superficie); border: 1px solid var(--linha); border-radius: 6px;
  padding: .45rem .8rem; cursor: pointer; color: var(--texto);
}
.gesto-modo-passo[aria-pressed="true"] { background: var(--acento); color: #fff; border-color: var(--acento); }

.gesto-passo-nav {
  margin-top: .9rem; display: grid; grid-template-columns: auto 1fr auto; gap: .8rem; align-items: center;
  background: var(--bg); border: 1px solid var(--linha); border-radius: 8px; padding: .7rem .9rem;
}
.gesto-passo-nav button {
  width: 34px; height: 34px; border-radius: 6px; border: 1px solid var(--linha);
  background: var(--superficie); color: var(--texto); cursor: pointer; font-size: 1rem; flex: none;
}
.gesto-passo-nav button:disabled { opacity: .35; cursor: not-allowed; }
.gesto-legenda { margin: 0; font-size: .9rem; text-align: center; }
.gesto-legenda .passo-contagem { display: block; font-family: var(--mono); font-size: .7rem; color: var(--texto-suave); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .2rem; }
.aviso-movimento-reduzido {
  font-family: var(--mono); font-size: .76rem; color: var(--texto-suave);
  margin-top: .7rem; padding-top: .7rem; border-top: 1px dashed var(--linha);
}
.aviso-movimento-reduzido[hidden] { display: none; }

/* ---------- linha do tempo horizontal (elemento-assinatura nº2) ---------- */
.linha-tempo-shell { border: 1px solid var(--linha); border-radius: var(--raio); background: var(--superficie); overflow: hidden; box-shadow: var(--sombra); }
.linha-tempo-pista-caixa { overflow-x: auto; overflow-y: hidden; padding: 2.6rem 1.6rem 2rem; scroll-behavior: smooth; }
.linha-tempo-pista {
  position: relative; display: flex; align-items: flex-start; gap: 0; min-width: max-content;
  padding-top: 1.4rem;
}
.linha-tempo-pista::before {
  content: ""; position: absolute; left: 0; right: 0; top: 1.4rem; height: 3px; background: var(--linha);
}
.marco {
  position: relative; flex: none; width: 210px; padding: 0 1.1rem; text-align: left;
  background: transparent; border: none; cursor: pointer; font: inherit; color: var(--texto);
}
.marco-ano { font-family: var(--mono); font-size: .76rem; color: var(--texto-suave); display: block; margin-bottom: .35rem; }
.marco-ponto {
  position: absolute; top: 1.4rem; left: 1.1rem; transform: translate(-50%, -50%);
  width: 15px; height: 15px; border-radius: 50%; background: var(--superficie);
  border: 3px solid var(--marca-clara);
}
.marco[data-tipo="ameaca"] .marco-ponto { border-color: var(--marca-forte); }
.marco[data-tipo="salvacao"] .marco-ponto { border-color: var(--acento); }
.marco-titulo { font-family: var(--sans); font-weight: 700; font-size: .92rem; margin-top: 1.1rem; display: block; }
.marco-forca { font-family: var(--mono); font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--texto-suave); display: block; margin-top: .2rem; }
.marco[aria-current="true"] .marco-ponto { background: var(--marca-forte); border-color: var(--marca-forte); }
.marco[aria-current="true"] .marco-titulo { color: var(--marca-forte); }
.marco:hover .marco-titulo { text-decoration: underline; }

.linha-tempo-legenda { display: flex; flex-wrap: wrap; gap: 1.2rem; padding: 1rem 1.6rem; border-top: 1px solid var(--linha); background: var(--superficie-2); font-family: var(--mono); font-size: .76rem; color: var(--texto-suave); }
.linha-tempo-legenda span { display: inline-flex; align-items: center; gap: .4rem; }
.linha-tempo-legenda i { width: 11px; height: 11px; border-radius: 50%; border: 3px solid; display: inline-block; }
.linha-tempo-legenda i.li-ameaca { border-color: var(--marca-forte); }
.linha-tempo-legenda i.li-salvacao { border-color: var(--acento); }
.linha-tempo-legenda i.li-neutro { border-color: var(--marca-clara); }

.linha-tempo-nota {
  margin: 1.6rem 0 0; padding: 1.5rem 1.7rem; background: var(--superficie); border: 1px solid var(--linha);
  border-radius: var(--raio); scroll-margin-top: 6rem;
}
.linha-tempo-nota .marco-ano { font-size: .82rem; }
.linha-tempo-nota h3 { margin-top: .4rem; }
.linha-tempo-nota-vazia { color: var(--texto-suave); font-style: italic; }
.linha-tempo-nota .ofertas-tocadas { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.linha-tempo-nota .ofertas-tocadas a {
  font-family: var(--mono); font-size: .76rem; background: var(--superficie-2); border: 1px solid var(--linha);
  border-radius: 999px; padding: .3rem .7rem; text-decoration: none; color: var(--marca-forte);
}
.linha-tempo-nota .ofertas-tocadas a:hover { border-color: var(--marca-clara); }

.linha-tempo-ajuda { font-family: var(--mono); font-size: .8rem; color: var(--texto-suave); margin-top: 1rem; }
.linha-tempo-ajuda kbd {
  font-family: var(--mono); background: var(--superficie-2); border: 1px solid var(--linha);
  border-radius: 4px; padding: .05em .4em;
}

/* ---------- ferramentas (glossário ilustrado) ---------- */
.ferramentas-grelha { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 1.3rem; }
.ficha-ferramenta {
  background: var(--superficie); border: 1px solid var(--linha); border-radius: var(--raio);
  padding: 1.4rem; text-align: center;
}
.ficha-ferramenta-icone {
  width: 90px; height: 90px; margin: 0 auto .9rem; background: var(--bg); border: 1px solid var(--linha);
  border-radius: 8px; display: flex; align-items: center; justify-content: center;
}
.ficha-ferramenta-icone svg { width: 62px; height: 62px; }
.ficha-ferramenta h3 { font-size: 1rem; margin-bottom: .3rem; }
.ficha-ferramenta .ficha-oficio-usa { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .04em; color: var(--marca-forte); display: block; margin-bottom: .5rem; }
.ficha-ferramenta p { font-size: .88rem; color: var(--texto-suave); margin: 0; text-align: left; }

/* ---------- vocabulário ---------- */
.vocabulario-filtro { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.vocabulario-filtro button {
  font-family: var(--mono); font-size: .78rem; text-transform: uppercase; letter-spacing: .03em;
  background: var(--superficie); border: 1px solid var(--linha); border-radius: 999px;
  padding: .4rem .9rem; cursor: pointer; color: var(--texto-suave);
}
.vocabulario-filtro button[aria-pressed="true"] { background: var(--marca-forte); color: #fbf3e4; border-color: var(--marca-forte); }
.vocabulario-contagem { font-family: var(--mono); font-size: .8rem; color: var(--texto-suave); margin: 0 0 1.2rem; }

.vocabulario-lista { display: grid; gap: 1rem; }
.termo {
  background: var(--superficie); border: 1px solid var(--linha); border-left: 4px solid var(--marca-clara);
  border-radius: 0 var(--raio) var(--raio) 0; padding: 1.1rem 1.4rem;
}
.termo-cabecalho { display: flex; flex-wrap: wrap; align-items: baseline; gap: .6rem; justify-content: space-between; }
.termo h3 { font-family: var(--display); font-size: 1.05rem; text-transform: uppercase; margin: 0; }
.termo .termo-oficio { font-family: var(--mono); font-size: .68rem; text-transform: uppercase; letter-spacing: .04em; color: var(--texto-suave); }
.termo p { margin: .4rem 0 0; }
.termo[hidden] { display: none; }

/* ---------- aprender hoje ---------- */
.escola-cartao { background: var(--superficie); border: 1px solid var(--linha); border-radius: var(--raio); padding: 1.6rem; margin-bottom: 1.2rem; }
.escola-cartao h3 { font-size: 1.1rem; margin-bottom: .4rem; }
.escola-cartao .escola-tipo { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--marca-forte); display: block; margin-bottom: .6rem; }

/* ---------- formulário de contacto ---------- */
.aviso-ok {
  background: var(--ok-bg); color: var(--ok-texto); border: 1px solid color-mix(in srgb, var(--ok-texto) 40%, transparent);
  padding: 1rem 1.2rem; border-radius: 8px; margin-bottom: 1.6rem; font-weight: 700; font-family: var(--sans);
}
.forma-contacto { max-width: 560px; }
.campo { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1.1rem; }
.campo label { font-family: var(--mono); font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--texto-suave); }
.campo input, .campo select, .campo textarea {
  padding: .7rem .8rem; border-radius: 6px; border: 1px solid var(--linha);
  background: var(--superficie); color: var(--texto); font-family: var(--serif); font-size: 1rem;
  width: 100%;
}
.campo textarea { resize: vertical; min-height: 110px; }
.campo .ajuda { font-size: .82rem; color: var(--texto-suave); font-family: var(--sans); }

/* ---------- rodapé ---------- */
.rodape { background: var(--marca-forte); color: #f4e6d3; margin-top: 3rem; }
.rodape .moldura { padding: 3rem 1.4rem 1.6rem; display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 2rem; }
@media (max-width: 700px) { .rodape .moldura { grid-template-columns: 1fr; } }
.rodape h4 { color: #fbeedb; font-family: var(--sans); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .8rem; }
.rodape .marca-rodape { font-family: var(--display); font-weight: 900; font-size: 1.2rem; text-transform: uppercase; letter-spacing: .03em; color: #fbeedb; text-decoration: none; }
.rodape p { color: #e6c9ab; max-width: 36ch; }
.rodape ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.rodape a { color: #f1dcbf; text-decoration: none; font-family: var(--sans); font-size: .92rem; }
.rodape a:hover { color: #fbeedb; text-decoration: underline; }
.rodape-aviso { font-size: .84rem; color: #e6c9ab; border-top: 1px solid rgba(251,238,219,.2); margin-top: 1.6rem; padding-top: 1.4rem; }
.creditos { border-top: 1px solid rgba(255,255,255,.15); padding: 1.2rem 1.4rem; font-size: .84rem; color: #dcbb95; text-align: center; font-family: var(--sans); }

/* utilidade */
.centro { text-align: center; }
.mt-2 { margin-top: 2rem; }


/* ============================================================
   CAMADA PREMIUM — código canónico partilhado pelos seis sites
   (fartapao, bracarapipe, mesteze, noniussoftware, talkdesk, tibagroup).

   Como usar: copiar este bloco para o FIM do style.css do site e
   (1) mapear os tokens abstratos no :root do site:
         --realce: var(--marca);            tinta do site
         --realce-forte: var(--marca-forte);
         --realce-suave: color-mix(in srgb, var(--marca) 22%, transparent);
         --tinta-sobre-realce: #fffaf0;     texto sobre --realce-forte
   (2) apagar as regras antigas que este bloco substitui:
         .revela / .em-vista, .botao-tema .icone-* (display:none),
         .nav-principal a:hover / [aria-current] com pastilha de fundo,
         .btn:hover / .btn:active simples, .cartao/.cartao-destaque hover.
   (3) ajustar a escala do h1 do hero à tipografia do site (ver «HERO»).
   Requer html.js (script inline no <head>) e o main.js canónico.
   Tudo o que esconde conteúdo vive sob html.js + no-preference.
   ============================================================ */

:root {
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --ease-mola: linear(0, .006, .025 2.8%, .101 6.1%, .539 18.9%, .721 25.3%, .849 31.5%, .937 38.1%, .968 41.8%, .991 45.7%, 1.006 50.1%, 1.015 55%, 1.017 63.9%, 1.001);
}

/* ---------- fio de leitura ---------- */
.leitura-progresso {
  position: fixed; top: 0; left: 0; width: 100%; height: 3px; z-index: 300;
  background: linear-gradient(90deg, var(--realce), var(--realce-forte));
  transform: scaleX(0); transform-origin: 0 50%; pointer-events: none;
  view-transition-name: leitura;
}
html:not(.js) .leitura-progresso { display: none; }
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    html.js .leitura-progresso { animation: ler-progresso linear both; animation-timeline: scroll(root); }
  }
}
@keyframes ler-progresso { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ---------- cabeçalho vivo ---------- */
.cabecalho {
  view-transition-name: cabecalho;
  -webkit-backdrop-filter: blur(10px) saturate(1.15);
  backdrop-filter: blur(10px) saturate(1.15);
  transition: box-shadow .35s ease, background-color .35s ease;
}
.cabecalho .moldura { max-width: 1320px; transition: padding .3s var(--ease-out); }
.cabecalho.rolou {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  box-shadow: 0 10px 30px -22px rgba(0, 0, 0, .45);
}
.cabecalho.rolou .moldura { padding-top: .5rem; padding-bottom: .5rem; }

.nav-principal ul { gap: 0; }
.nav-principal a { position: relative; background: transparent; }
.nav-principal a::after {
  content: ""; position: absolute; left: .75rem; right: .75rem; bottom: .28rem; height: 2px;
  border-radius: 2px; background: var(--realce);
  transform: scaleX(0); transform-origin: left center;
  transition: transform .32s var(--ease-out);
}
.nav-principal a:hover, .nav-principal a:focus-visible { background: transparent; color: var(--texto); }
.nav-principal a[aria-current="page"] { background: transparent; color: var(--realce-forte); box-shadow: none; }
.nav-principal a:hover::after, .nav-principal a:focus-visible::after,
.nav-principal a[aria-current="page"]::after { transform: scaleX(1); }

/* botão de tema: os ícones rodam e deslizam, em vez de display:none */
.botao-tema { position: relative; overflow: hidden; }
.botao-tema svg {
  position: absolute; inset: 0; margin: auto;
  transition: transform .5s var(--ease-out), opacity .3s ease;
}
.botao-tema .icone-sol { display: block; opacity: 1; transform: none; }
.botao-tema .icone-lua { display: block; opacity: 0; transform: translateY(130%) rotate(-50deg); }
:root[data-theme="dark"] .botao-tema .icone-sol { opacity: 0; transform: translateY(-130%) rotate(50deg); }
:root[data-theme="dark"] .botao-tema .icone-lua { opacity: 1; transform: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .botao-tema .icone-sol { display: block; opacity: 0; transform: translateY(-130%) rotate(50deg); }
  :root:not([data-theme="light"]) .botao-tema .icone-lua { display: block; opacity: 1; transform: none; }
}
.botao-tema:hover { transform: rotate(12deg); }
.botao-tema:active { transform: scale(.9); }

/* menu móvel: abre a deslizar */
@media (prefers-reduced-motion: no-preference) {
  html.js .nav-principal.aberta { animation: nav-abrir .32s var(--ease-out) both; }
}
@keyframes nav-abrir { from { opacity: 0; transform: translateY(-8px); } }

/* ---------- navegação entre páginas como app ---------- */
@view-transition { navigation: auto; }
.rodape { view-transition-name: rodape; }
@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation: vt-sair .28s ease both; }
  ::view-transition-new(root) { animation: vt-entrar .42s var(--ease-out) both; }
}
@keyframes vt-sair { to { opacity: 0; transform: translateY(-6px); } }
@keyframes vt-entrar { from { opacity: 0; transform: translateY(10px); } }
/* círculo de luz a partir do botão de tema */
html.vt-circulo::view-transition-old(root) { animation: none; mix-blend-mode: normal; }
html.vt-circulo::view-transition-new(root) { animation: tema-circulo .6s var(--ease-in-out) both; mix-blend-mode: normal; }
@keyframes tema-circulo {
  from { clip-path: circle(0 at var(--vt-x, 50%) var(--vt-y, 0px)); }
  to { clip-path: circle(var(--vt-r, 141vmax) at var(--vt-x, 50%) var(--vt-y, 0px)); }
}
/* chegada por view transition: a página aterra composta, sem duplo reveal */
html.vt-instante .rv { transition: none !important; }
html.vt-instante .hero h1 .palavra { animation: none !important; opacity: 1 !important; transform: none !important; }

/* ---------- motor de revelação ---------- */
@media (prefers-reduced-motion: no-preference) {
  html.js .rv { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
  html.js .rv.in-view { opacity: 1; transform: none; }
}

/* ---------- hero: tipografia cinética, palavra-chave, ambiente ---------- */
.hero { isolation: isolate; }
.hero h1 { text-wrap: balance; }
.hero .lead { text-wrap: pretty; }
/* escala display — ajustar por site: serifados clamp(2.3rem,5.2vw,4.1rem);
   caixa alta/display (mesteze) clamp(2rem,4.8vw,3.6rem); mono (nónio) clamp(1.9rem,4.2vw,3.1rem) */
.hero h1 .palavra { display: inline-block; }
@media (prefers-reduced-motion: no-preference) {
  html.js .hero h1.tipo-viva .palavra {
    opacity: 0; transform: translateY(.6em) rotate(1.2deg);
    animation: palavra-sobe .95s var(--ease-out) both;
  }
  html.js .hero h1.tipo-viva ~ .lead,
  html.js .hero h1.tipo-viva ~ .acoes { animation: sobe-suave .9s var(--ease-out) both; }
  html.js .hero h1.tipo-viva ~ .lead { animation-delay: .45s; }
  html.js .hero h1.tipo-viva ~ .acoes { animation-delay: .6s; }
}
@keyframes palavra-sobe { to { opacity: 1; transform: none; } }
@keyframes sobe-suave { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.realce {
  background-image: linear-gradient(var(--realce-suave), var(--realce-suave));
  background-repeat: no-repeat; background-size: 100% .34em; background-position: 0 90%;
  padding: 0 .08em; margin: 0 -.08em; border-radius: .1em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
@media (prefers-reduced-motion: no-preference) {
  html.js .hero .realce { background-size: 0% .34em; animation: realce-pintar .9s var(--ease-out) 1s both; }
}
@keyframes realce-pintar { to { background-size: 100% .34em; } }

/* camadas de ambiente do hero: cada site define os seus filhos */
.hero-ambiente { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.hero-ambiente > * { position: absolute; }
/* animações contínuas do ambiente só correm com o hero em cena */
.hero:not(.em-cena) .hero-ambiente > * { animation-play-state: paused; }
html:not(.js) .hero .hero-ambiente > * { animation-play-state: running; }

/* vinheta: o cartão do hero deixa de ter hover de cartão */
.hero .cartao, .hero .hero-vinheta { transition: none; }
.hero .cartao:hover, .hero .hero-vinheta:hover { transform: none; }

/* ---------- botões ---------- */
.btn {
  position: relative; overflow: hidden; isolation: isolate;
  transition: transform .22s var(--ease-out), box-shadow .3s ease, background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); transition-duration: .08s; }
.btn-primario::after {
  content: ""; position: absolute; inset: -20% -40%; z-index: -1; pointer-events: none;
  background: linear-gradient(112deg, transparent 38%, rgba(255, 255, 255, .26) 50%, transparent 62%);
  transform: translateX(-70%);
}
@media (prefers-reduced-motion: no-preference) {
  .btn-primario:hover::after { transform: translateX(70%); transition: transform .85s var(--ease-out); }
}
.btn-primario:hover { box-shadow: 0 14px 30px -14px color-mix(in srgb, var(--realce-forte) 60%, transparent); }
.btn .seta { display: inline-block; transition: transform .3s var(--ease-out); }
.btn:hover .seta, .btn:focus-visible .seta { transform: translateX(4px); }
.btn-fantasma:hover { background: color-mix(in srgb, var(--realce) 8%, transparent); }

/* ---------- cartões ---------- */
.cartao, .cartao-destaque {
  position: relative;
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out), border-color .3s ease;
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  main .cartao:hover, main .cartao-destaque:hover {
    transform: translateY(-4px);
    border-color: color-mix(in srgb, var(--realce) 45%, var(--linha));
    box-shadow: 0 26px 44px -26px rgba(0, 0, 0, .4);
  }
}
.cartao-destaque { overflow: hidden; }
.cartao-destaque::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 40%), color-mix(in srgb, var(--realce) 18%, transparent), transparent 62%);
  opacity: 0; transition: opacity .45s ease;
}
.cartao-destaque:hover::before { opacity: 1; }
.cartao-destaque > * { position: relative; z-index: 1; }
.icone-destaque { transition: transform .45s var(--ease-out); }
.cartao-destaque:hover .icone-destaque { transform: translateY(-2px) rotate(-5deg); }

/* ---------- faixa de termos ---------- */
.faixa {
  position: relative; overflow: hidden;
  border-top: 1px solid var(--linha); border-bottom: 1px solid var(--linha);
  background: var(--superficie-2); padding: .95rem 0;
}
.faixa-mascara { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.faixa-pista {
  display: flex; width: max-content; margin: 0; padding: 0; list-style: none;
  font-family: var(--mono); font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--texto-suave); white-space: nowrap;
}
.faixa-pista > span { display: inline-flex; align-items: center; gap: 2.2rem; padding-right: 2.2rem; }
.faixa-pista i { font-style: normal; color: var(--realce); }
@media (prefers-reduced-motion: no-preference) {
  html.js .faixa-pista { animation: faixa-rolar 52s linear infinite; }
  .faixa:hover .faixa-pista, .faixa:focus-within .faixa-pista, .faixa.parada .faixa-pista { animation-play-state: paused; }
}
@keyframes faixa-rolar { to { transform: translateX(-50%); } }
.faixa-pausa {
  position: absolute; right: .9rem; top: 50%; transform: translateY(-50%);
  width: 30px; height: 30px; border-radius: 999px; border: 1px solid var(--linha);
  background: var(--superficie); color: var(--texto-suave); display: grid; place-items: center; cursor: pointer;
  transition: color .2s ease, border-color .2s ease;
}
.faixa-pausa:hover { color: var(--texto); border-color: var(--realce); }
.faixa-pausa svg { width: 12px; height: 12px; }
.faixa-pausa .icone-retomar { display: none; }
.faixa.parada .faixa-pausa .icone-pausar { display: none; }
.faixa.parada .faixa-pausa .icone-retomar { display: block; }
html:not(.js) .faixa-pausa { display: none; }
@media (prefers-reduced-motion: reduce) {
  .faixa-pista { animation: none; width: auto; flex-wrap: wrap; justify-content: center; white-space: normal; row-gap: .5rem; }
  .faixa-pista > span { flex-wrap: wrap; justify-content: center; row-gap: .5rem; }
  .faixa-pista > span:nth-child(2) { display: none; }
  .faixa-mascara { mask-image: none; -webkit-mask-image: none; }
  .faixa-pausa { display: none; }
}

/* ---------- banda de números ---------- */
.banda-numeros { padding: 2.6rem 0; }
.banda-numeros .moldura { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
@media (max-width: 720px) { .banda-numeros .moldura { grid-template-columns: 1fr; } }
.numero-facto { position: relative; padding: .4rem 0 .4rem 1.3rem; }
.numero-facto::before { content: ""; position: absolute; left: 0; top: .5rem; bottom: .5rem; width: 3px; border-radius: 3px; background: var(--realce); }
.numero-facto strong {
  display: block; font-family: var(--mono); font-weight: 700; font-size: clamp(2rem, 3.6vw, 2.8rem);
  line-height: 1; color: var(--realce-forte); font-variant-numeric: tabular-nums; letter-spacing: -.02em;
}
.numero-facto span { display: block; margin-top: .45rem; font-size: .92rem; color: var(--texto-suave); max-width: 26ch; }

/* ---------- formulário ---------- */
.campo input:focus-visible, .campo select:focus-visible, .campo textarea:focus-visible,
.decompositor-entrada textarea:focus-visible, .atlas-ferramentas input:focus-visible {
  outline: none; border-color: var(--realce);
  box-shadow: 0 0 0 4px var(--realce-suave);
}
.campo input, .campo select, .campo textarea { transition: border-color .2s ease, box-shadow .2s ease; }
.btn[aria-busy="true"] { opacity: .7; pointer-events: none; }
.btn[aria-busy="true"]::before {
  content: ""; width: 1em; height: 1em; border-radius: 50%; margin-right: .2em;
  border: 2px solid currentColor; border-right-color: transparent; animation: girar .8s linear infinite;
}
@keyframes girar { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: no-preference) {
  html.js .aviso-ok.a-entrar { animation: sobe-suave .6s var(--ease-out) both; }
}

/* ---------- rodapé ---------- */
.rodape { position: relative; }
.rodape::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--realce), transparent 60%); opacity: .9; }
.rodape a { position: relative; text-decoration: none; }
.rodape ul a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease-out); }
.rodape ul a:hover { text-decoration: none; }
.rodape ul a:hover::after { transform: scaleX(1); }

/* ---------- detalhes / tabelas ---------- */
details summary::before, details summary::marker { transition: transform .3s var(--ease-out); }
details summary { transition: color .2s ease; }

/* ---------- movimento reduzido: tudo visível e quieto ---------- */
@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*), ::view-transition-image-pair(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
  .leitura-progresso { display: none !important; }
  html.js .rv { opacity: 1; transform: none; transition: none; }
  html.js .hero h1.tipo-viva .palavra { animation: none; opacity: 1; transform: none; }
  html.js .hero .realce { animation: none; background-size: 100% .34em; }
  .hero-ambiente > * { animation: none !important; }
}


/* ============================================================
   MESTEZE — «a oficina em movimento» (por cima da camada premium)
   ============================================================ */

/* palavra-chave carimbada: bloco de tinta ligeiramente inclinado */
.realce { background: none; padding: 0 .1em; margin: 0 -.1em; position: relative; z-index: 0; }
.realce::before {
  content: ""; position: absolute; left: -.04em; right: -.04em; bottom: .04em; height: .42em; z-index: -1;
  background: var(--realce-suave); border-radius: .06em;
  transform: rotate(-1.4deg) skewX(-8deg); transform-origin: left bottom;
}
html.js .hero .realce { animation: none; background: none; }
@media (prefers-reduced-motion: no-preference) {
  html.js .hero .realce::before { transform: rotate(-1.4deg) skewX(-8deg) scaleX(0); animation: carimbo .7s var(--ease-out) 1.05s both; }
}
@keyframes carimbo { to { transform: rotate(-1.4deg) skewX(-8deg) scaleX(1); } }
@media (prefers-reduced-motion: reduce) {
  html.js .hero .realce::before { animation: none; transform: rotate(-1.4deg) skewX(-8deg) scaleX(1); }
}

/* ambiente: veio de madeira e brasa */
.hero-ambiente .veio {
  inset: -40px -60px; opacity: .55;
  background:
    repeating-linear-gradient(104deg, transparent 0 22px, color-mix(in srgb, var(--marca-forte) 6%, transparent) 22px 23px, transparent 23px 47px, color-mix(in srgb, var(--texto) 4%, transparent) 47px 48px),
    repeating-linear-gradient(103deg, transparent 0 140px, color-mix(in srgb, var(--ouro) 5%, transparent) 140px 148px);
  animation: veio-deriva 46s linear infinite alternate;
}
@keyframes veio-deriva { to { transform: translateX(-34px); } }
.hero-ambiente .brasa {
  left: -10%; bottom: -34%; width: 48vw; height: 48vw; max-width: 640px; max-height: 640px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--marca) 30%, transparent), color-mix(in srgb, var(--ouro) 10%, transparent) 42%, transparent 70%);
  opacity: .55; animation: brasa-pulsa 7s ease-in-out infinite;
}
:root[data-theme="dark"] .hero-ambiente .brasa { opacity: .9; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hero-ambiente .brasa { opacity: .9; } }
@keyframes brasa-pulsa { 0%, 100% { transform: scale(1); opacity: .5; } 50% { transform: scale(1.08); opacity: .85; } }
:root[data-theme="dark"] .hero-ambiente .brasa { animation-name: brasa-pulsa-escuro; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .hero-ambiente .brasa { animation-name: brasa-pulsa-escuro; } }
@keyframes brasa-pulsa-escuro { 0%, 100% { transform: scale(1); opacity: .7; } 50% { transform: scale(1.1); opacity: 1; } }

/* vinheta do torno */
.hero-vinheta { padding: 1.2rem; background: color-mix(in srgb, var(--superficie) 88%, transparent); }
.hero-vinheta svg { display: block; }

/* fichas de ofício: número como marca de água */
.ficha-oficio { overflow: hidden; }
.ficha-oficio::before {
  content: attr(data-numero); position: absolute; right: .6rem; top: -1.1rem; z-index: 0; pointer-events: none;
  font-family: var(--display); font-weight: 900; font-size: clamp(6rem, 12vw, 10rem); line-height: 1; letter-spacing: -.05em;
  color: var(--marca); opacity: .07;
}
.ficha-oficio > * { position: relative; z-index: 1; }

/* cartões menores: elevação discreta em hover */
.ficha-ferramenta, .termo, .escola-cartao { transition: transform .4s var(--ease-out), border-color .3s ease, box-shadow .4s var(--ease-out); }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .ficha-ferramenta:hover, .escola-cartao:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--marca) 45%, var(--linha)); box-shadow: var(--sombra); }
  .termo:hover { border-left-color: var(--marca-forte); transform: translateX(3px); }
}
.ficha-ferramenta-icone svg { transition: transform .5s var(--ease-out); }
.ficha-ferramenta:hover .ficha-ferramenta-icone svg { transform: rotate(-6deg) scale(1.06); }

/* linha do tempo: marcos que entram, pista que se preenche, anel no ativo */
.linha-tempo-preenchido {
  position: absolute; left: 0; top: 1.4rem; height: 3px; width: 100%; pointer-events: none;
  background: linear-gradient(90deg, var(--marca-forte), var(--marca)); border-radius: 3px;
  transform: scaleX(0); transform-origin: left center; transition: transform .7s var(--ease-out);
}
.marco { transition: opacity .6s var(--ease-out), transform .6s var(--ease-out); }
html.js .marco.marco-oculto { opacity: 0; transform: translateY(14px); }
.marco-ponto { transition: background .3s ease, border-color .3s ease, transform .3s var(--ease-out); z-index: 1; }
.marco:hover .marco-ponto { transform: translate(-50%, -50%) scale(1.15); }
.marco[aria-current="true"] .marco-ponto::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--marca-forte);
  animation: anel-pulsa 1.9s var(--ease-out) infinite;
}
@keyframes anel-pulsa { 0% { transform: scale(.7); opacity: .9; } 100% { transform: scale(2.3); opacity: 0; } }
.linha-tempo-nota { transition: opacity .32s ease, transform .32s var(--ease-out); }
.linha-tempo-nota.a-trocar { opacity: 0; transform: translateY(8px); }
@media (prefers-reduced-motion: reduce) {
  html.js .marco.marco-oculto { opacity: 1; transform: none; }
  .marco[aria-current="true"] .marco-ponto::after { animation: none; opacity: .6; transform: scale(1.4); }
}

/* gesto: o cartão do gesto tem um brilho de bancada */
.gesto-svg-caixa { background: linear-gradient(180deg, var(--bg), color-mix(in srgb, var(--bg) 80%, var(--superficie-2))); }

/* ---------- complementos da assinatura (por baixo da camada premium) ---------- */
/* a marca de água «01…09» posiciona-se em relação ao próprio cartão */
.ficha-oficio { position: relative; }
:root[data-theme="dark"] .ficha-oficio::before { opacity: .11; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .ficha-oficio::before { opacity: .11; } }

/* linha do tempo: a pista preenchida fica entre a linha base e os pontos */
.linha-tempo-preenchido { z-index: 0; }
.marco-ponto { position: absolute; }
@media (prefers-reduced-motion: reduce) {
  .linha-tempo-preenchido, .linha-tempo-nota, .marco, .marco-ponto { transition: none; }
  .linha-tempo-nota.a-trocar { opacity: 1; transform: none; }
}

/* o painel passo-a-passo só aparece em modo manual: o display:flex acima
   anulava o atributo hidden, e a barra ← → ficava visível em modo automático */
.gesto-passo-nav[hidden] { display: none; }

/* sem JS não há clone nem ciclo: a faixa comporta-se como em movimento
   reduzido — lista estática, centrada, sem máscara a cortar a primeira palavra */
html:not(.js) .faixa-pista { animation: none; width: auto; flex-wrap: wrap; justify-content: center; white-space: normal; row-gap: .5rem; }
html:not(.js) .faixa-pista > span { flex-wrap: wrap; justify-content: center; row-gap: .5rem; }
html:not(.js) .faixa-mascara { mask-image: none; -webkit-mask-image: none; }
