:root {
  --bg: #0d0d0b;
  --bg-2: #161613;
  --paper: #f2efe8;
  --paper-2: #e7e2d7;
  --ink: #0d0d0b;
  --text: #f2efe8;
  --muted: #8f8b82;
  --line: rgba(242, 239, 232, 0.14);
  --line-ink: rgba(13, 13, 11, 0.16);

  --accent: #ffd400;
  --good: #3ddc84;
  --bad: #ff5a3c;
  --learn: #7aa2ff;

  --font-display: "Inter Tight", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 56px);
  --radius: 14px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* No modo Verdade o amarelo dá lugar ao vermelho (a classe fica no <html>) */
.truth { --accent: var(--bad); }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
a, button { -webkit-tap-highlight-color: transparent; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background 0.4s ease;
}

/* Grão de película por cima de tudo */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 200;
  opacity: 0.07;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--ink); }
em { font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -0.01em; }
.mono { font-family: var(--font-mono); }

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 28px;
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px var(--gutter);
  background: rgba(13, 13, 11, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav__logo {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 22px;
  letter-spacing: -0.04em;
  text-decoration: none;
}
.nav__logo span { color: var(--accent); transition: color 0.3s; }
.nav__links { display: flex; gap: 26px; margin-left: auto; }
.nav__links a { text-decoration: none; font-size: 14px; color: var(--muted); }
.nav__links a:hover { color: var(--text); }
.nav__links a[aria-current="page"] { color: var(--text); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 6px; text-decoration-thickness: 2px; }
@media (max-width: 760px) { .nav__links { display: none; } .truth-toggle { margin-left: auto; } }

.truth-toggle {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--line);
  background: var(--bg-2);
  border-radius: 999px;
  padding: 3px;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 12px;
}
.truth-toggle__opt {
  position: relative;
  z-index: 1;
  padding: 7px 14px;
  text-align: center;
  transition: color 0.3s;
}
.truth-toggle__opt:first-child { color: var(--ink); }
.truth-toggle__opt:nth-child(2) { color: var(--muted); }
.truth .truth-toggle__opt:first-child { color: var(--muted); }
.truth .truth-toggle__opt:nth-child(2) { color: var(--ink); }
.truth-toggle__knob {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 3px;
  width: calc(50% - 3px);
  border-radius: 999px;
  background: var(--accent);
  transition: transform 0.35s var(--ease), background 0.3s;
}
.truth .truth-toggle__knob { transform: translateX(100%); }
.truth-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Hero ---------- */
.hero { padding: clamp(56px, 10vw, 128px) 0 clamp(48px, 7vw, 88px); }
.hero__eyebrow { font-size: 12px; color: var(--muted); letter-spacing: 0.04em; margin: 0 0 32px; }
.hero__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(46px, 9.4vw, 148px);
  line-height: 0.92;
  letter-spacing: -0.05em;
  margin: 0 0 clamp(40px, 6vw, 72px);
  max-width: 12.5ch;
  text-wrap: balance;
}
.hero__title .line--serif {
  display: block;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(28px, 4.4vw, 66px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--accent);
  max-width: 22ch;
  margin-top: 0.4em;
  transition: color 0.3s;
}
.hero__bottom {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 32px 64px;
  align-items: end;
}
@media (max-width: 860px) { .hero__bottom { grid-template-columns: 1fr; } }
.hero__lead { margin: 0; max-width: 560px; font-size: clamp(18px, 1.8vw, 21px); color: #cfcbc2; }
.hero__hint { margin: 32px 0 0; font-size: 12px; color: var(--muted); }
.hero__hint strong { color: var(--accent); font-weight: 500; }

/* Página inicial: o hero ocupa o ecrã inteiro */
.hero--landing { padding: 0; }
.hero--landing .hero__inner {
  min-height: calc(100svh - 61px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 40px;
  padding-top: clamp(32px, 4vw, 56px);
  padding-bottom: clamp(32px, 4vw, 48px);
}
.hero--landing .hero__eyebrow { margin-bottom: 0; }
.hero--landing .hero__title { margin-bottom: 0; font-size: clamp(44px, 7.2vw, 116px); max-width: 14ch; }
.hero--landing .hero__title .line--serif { font-size: clamp(26px, 3.6vw, 54px); max-width: 30ch; }
.hero__title .line--serif.swap { display: grid; }
.hero__title .swap__b { color: var(--bad); }
.hero__clock { color: var(--text); }

.rotator {
  border: 1px solid var(--line);
  background: var(--bg-2);
  border-radius: var(--radius);
  padding: 18px 22px 16px;
  align-self: end;
}
.rotator__head, .rotator__foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 0;
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.rotator__head span:first-child { text-transform: uppercase; letter-spacing: 0.1em; }
.rotator__body {
  min-height: 150px;
  padding: 12px 0 10px;
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  filter: blur(4px);
  transition: opacity 0.25s ease, transform 0.25s ease, filter 0.25s ease;
}
.rotator__body.is-in { opacity: 1; transform: none; filter: none; transition-duration: 0.5s; transition-timing-function: var(--ease); }
.rotator__value {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(52px, 5.6vw, 76px);
  letter-spacing: -0.05em;
  line-height: 1;
  margin: 0 0 10px;
}
.rotator__value sup { font-size: 0.4em; color: var(--accent); vertical-align: top; position: relative; top: 0.1em; transition: color 0.3s; }
.rotator__label { margin: 0; font-size: 15px; color: #b8b4ab; max-width: 36ch; }
.rotator__truth {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 21px;
  line-height: 1.2;
  color: var(--bad);
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.5s var(--ease), opacity 0.4s ease, margin 0.4s;
}
.truth .rotator__truth { max-height: 120px; opacity: 1; margin-top: 12px; }
.truth .rotator__body { min-height: 230px; }
.rotator__foot a { color: var(--text); text-decoration: none; white-space: nowrap; }
.rotator__foot a:hover { color: var(--accent); }
.rotator__bar { flex: 1; height: 2px; background: var(--line); border-radius: 2px; overflow: hidden; }
.rotator__bar i { display: block; height: 100%; background: var(--accent); transform-origin: left; animation: rotator-bar var(--rotator-ms, 4200ms) linear both; }
.rotator.is-paused .rotator__bar i { animation-play-state: paused; }
@keyframes rotator-bar { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) { .rotator__bar { visibility: hidden; } }

/* ---------- Portas (página inicial) ---------- */
.doors { padding: clamp(72px, 10vw, 128px) 0 clamp(80px, 11vw, 140px); }
.doors__list { list-style: none; margin: 0; padding: 0; counter-reset: d; }
.door {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(0, auto) minmax(0, 1fr) 48px;
  align-items: center;
  gap: 8px clamp(20px, 3vw, 40px);
  padding: clamp(18px, 2.4vw, 30px) 12px;
  border-top: 1px solid var(--line);
  text-decoration: none;
  isolation: isolate;
  transition: color 0.35s var(--ease);
}
.doors__list li:last-child .door { border-bottom: 1px solid var(--line); }
/* Fundo que sobe ao passar o rato */
.door::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--accent);
  clip-path: inset(100% 0 0 0);
  transition: clip-path 0.5s var(--ease), background 0.3s;
}
.door:focus-visible::before { clip-path: inset(0 0 0 0); }
.door:focus-visible { color: var(--ink); outline: none; }
.door__num { font-size: 13px; color: var(--muted); align-self: start; padding-top: 0.9em; transition: color 0.35s; }
.door__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(48px, 9vw, 136px);
  line-height: 0.95;
  letter-spacing: -0.055em;
  transition: transform 0.5s var(--ease);
}
.door__desc { font-size: 16px; color: var(--muted); max-width: 30ch; justify-self: end; text-align: right; transition: color 0.35s; }
.door__desc .swap__b { font-size: 24px; line-height: 1.1; }
.door__arrow { font-size: clamp(28px, 3vw, 44px); justify-self: end; transition: transform 0.5s var(--ease); }
/* Efeitos de hover só com rato: no telemóvel o amarelo ficava preso depois do toque */
@media (hover: hover) {
  .door:hover::before { clip-path: inset(0 0 0 0); }
  .door:hover { color: var(--ink); }
  .door:hover .door__title { transform: translateX(14px); }
  .door:hover .door__num, .door:hover .door__desc, .door:hover .door__desc .swap__b { color: var(--ink); }
  .door:hover .door__arrow { transform: translateX(6px) rotate(-45deg); }
}
.door:focus-visible .door__num, .door:focus-visible .door__desc, .door:focus-visible .door__desc .swap__b { color: var(--ink); }
@media (max-width: 860px) {
  .door { grid-template-columns: 32px minmax(0, 1fr) 32px; padding: 22px 4px; }
  .door__num { padding-top: 0.6em; }
  .door__desc { grid-column: 2; grid-row: 2; justify-self: start; text-align: left; font-size: 15px; }
  .door__desc .swap__b { font-size: 20px; }
  .door__arrow { grid-column: 3; grid-row: 1; font-size: 26px; }
}

/* ---------- Pré-visualização que segue o rato ---------- */
.peek { display: none; }
.can-peek .peek {
  display: block;
  position: fixed;
  left: 0;
  top: 0;
  z-index: 150;
  width: clamp(300px, 30vw, 380px);
  pointer-events: none;
  opacity: 0;
  scale: 0.88;
  rotate: calc(var(--side, 1) * -3deg);
  transform: translate(
    calc(var(--mx, -999px) + var(--side, 1) * 40px + (var(--side, 1) - 1) * 50%),
    calc(var(--my, -999px) - 50%)
  );
  transition: opacity 0.25s ease, scale 0.4s var(--ease), rotate 0.4s var(--ease);
  color: var(--text);
  text-align: left;
}
.can-peek a:hover > .peek { opacity: 1; scale: 1; }
/* Em ecrãs estreitos não há espaço para a pré-visualização sem tapar o texto */
@media (max-width: 899px) { .can-peek .peek { display: none; } }
.peek__browser, .peek__card, .peek__log, .peek__visual, .peek__pair {
  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
  box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.75);
}
.peek__browser .v-browser__bar { padding: 8px 12px; }
.peek__browser img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; }
.peek__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 8px; }
.peek__pair img { border-radius: 6px; }
.peek__card { background: var(--paper); color: var(--ink); padding: 22px 24px; border: 0; }
.peek__card b { display: block; font-family: var(--font-display); font-weight: 900; font-size: 64px; letter-spacing: -0.05em; line-height: 1; }
.peek__card sup { font-size: 0.4em; color: #b3311a; }
.peek__card em { display: block; font-size: 22px; line-height: 1.15; margin-top: 12px; color: #b3311a; }
.peek__card--mail em { font-size: 44px; margin: 0; color: var(--ink); }
.peek__log { padding: 18px 20px; font-size: 13px; line-height: 2; background: #070706; }
.peek__log span { display: block; white-space: nowrap; color: #d6d2c9; }
.peek__log b { font-weight: 500; display: inline-block; width: 64px; }
.peek__visual { padding: 12px; max-height: 300px; zoom: 0.7; width: calc(100% / 0.7); }
.peek__visual .v-flow li { margin-bottom: 18px; }
.peek__visual .v-flow li:not(:last-child)::after { height: 18px; }
.peek__visual .v-kanban, .peek__visual .v-mystery { min-height: 0; }

/* ---------- Páginas interiores ---------- */
.page-head { padding: clamp(40px, 7vw, 88px) 0 0; }
.page-head .section-head { margin-bottom: clamp(32px, 5vw, 56px); }
.page-head__crumb { font-size: 12px; color: var(--muted); margin: 0 0 clamp(24px, 4vw, 48px); letter-spacing: 0.04em; }
.page-head__crumb a { text-decoration: none; color: var(--text); }
.page-head__crumb a:hover { color: var(--accent); }
.page-head__crumb--case { padding-top: clamp(32px, 5vw, 56px); margin-bottom: 0; }
.page-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(56px, 11vw, 168px);
  letter-spacing: -0.055em;
  line-height: 0.92;
  margin: 0;
}
.page-title.mono-title { font-size: clamp(44px, 8.6vw, 128px); }
.page-title em { color: var(--accent); transition: color 0.3s; }

/* Porta para a página seguinte, no fim de cada página */
.next {
  display: block;
  position: relative;
  isolation: isolate;
  text-decoration: none;
  border-top: 1px solid var(--line);
  padding: clamp(48px, 8vw, 104px) 0;
  transition: color 0.35s var(--ease);
}
.next::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--accent);
  clip-path: inset(100% 0 0 0);
  transition: clip-path 0.55s var(--ease), background 0.3s;
}
.next:hover::before, .next:focus-visible::before { clip-path: inset(0); }
.next:hover, .next:focus-visible { color: var(--ink); outline: none; }
.next__inner { display: flex; flex-direction: column; gap: 10px; }
.next__label { font-size: 12px; color: var(--muted); letter-spacing: 0.06em; transition: color 0.35s; }
.next:hover .next__label { color: var(--ink); }
.next__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(48px, 9vw, 136px);
  letter-spacing: -0.055em;
  line-height: 0.95;
}
.next__arrow { display: inline-block; transition: transform 0.5s var(--ease); }
.next:hover .next__arrow { transform: translateX(16px); }

/* ---------- Ticker ---------- */
.ticker {
  background: var(--accent);
  color: var(--ink);
  overflow: hidden;
  border-block: 1px solid var(--ink);
  transition: background 0.3s;
}
.ticker__track {
  display: flex;
  width: max-content;
  gap: 28px;
  padding: 14px 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(18px, 2.2vw, 26px);
  letter-spacing: -0.02em;
  white-space: nowrap;
  animation: ticker 40s linear infinite;
}
.ticker__dot { opacity: 0.5; }
@keyframes ticker { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }

/* ---------- Section heads ---------- */
.section-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px 48px;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.section-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(44px, 7.6vw, 112px);
  letter-spacing: -0.05em;
  line-height: 0.95;
  margin: 0;
}
.mono-title { font-family: var(--font-mono); font-weight: 500; letter-spacing: -0.04em; }
.section-sub { margin: 0; max-width: 400px; color: var(--muted); font-size: 17px; }

/* ---------- Números com asterisco ---------- */
.stats { background: var(--paper); color: var(--ink); padding: clamp(56px, 8vw, 104px) 0; }
.stats .section-sub { color: #5d5a53; }
.stats__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  border-top: 1.5px solid var(--ink);
  border-left: 1.5px solid var(--ink);
}
.stat {
  padding: 28px 28px 32px;
  border-right: 1.5px solid var(--ink);
  border-bottom: 1.5px solid var(--ink);
  transition: background 0.3s;
}
.stat--accent { background: var(--ink); color: var(--paper); }
.stat__value {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(52px, 6vw, 84px);
  letter-spacing: -0.05em;
  line-height: 1;
  margin: 0 0 16px;
}
.stat__value sup { font-size: 0.4em; color: var(--accent); vertical-align: top; position: relative; top: 0.1em; transition: color 0.3s; }
.stat--accent sup { color: var(--accent); }
.stats .stat:not(.stat--accent) sup { -webkit-text-stroke: 1px var(--ink); }
.stat__label { margin: 0; font-size: 15px; color: #5d5a53; max-width: 32ch; }
.stat--accent .stat__label { color: #b8b4ab; }
.stat__truth {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 22px;
  line-height: 1.2;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height 0.5s var(--ease), opacity 0.4s ease, margin 0.4s;
}
.truth .stat__truth { max-height: 160px; opacity: 1; margin-top: 16px; }
.truth .stat:not(.stat--accent) .stat__truth { color: #b3311a; }
.truth .stat--accent .stat__truth { color: var(--bad); }

/* ---------- Trabalho ---------- */
.work { padding: clamp(80px, 11vw, 140px) 0 0; }

.worklist { list-style: none; margin: 0; padding: 0 0 clamp(64px, 9vw, 120px); }
.work-row {
  position: relative;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 220px 40px;
  align-items: center;
  gap: 8px clamp(20px, 3vw, 40px);
  padding: clamp(22px, 2.6vw, 32px) 12px;
  border-top: 1px solid var(--line);
  text-decoration: none;
  isolation: isolate;
  transition: color 0.35s var(--ease);
}
.worklist li:last-child .work-row { border-bottom: 1px solid var(--line); }
.work-row::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--bg-2);
  opacity: 0;
  transition: opacity 0.3s;
}
.work-row:hover::before, .work-row:focus-visible::before { opacity: 1; }
.work-row:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.work-row__num { font-size: 13px; color: var(--muted); align-self: start; padding-top: 4px; transition: color 0.3s; }
.work-row:hover .work-row__num { color: var(--accent); }
.work-row__name { display: block; font-weight: 600; font-size: 14px; color: var(--accent); margin-bottom: 8px; transition: color 0.3s; }
.work-row__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(24px, 3.2vw, 44px);
  line-height: 1.04;
  letter-spacing: -0.035em;
  max-width: 24ch;
  transition: transform 0.5s var(--ease);
}
.work-row:hover .work-row__title { transform: translateX(10px); }
.work-row__meta { font-size: 12px; color: var(--muted); line-height: 1.7; text-align: right; }
.work-row__arrow { font-size: 28px; justify-self: end; transition: transform 0.5s var(--ease); }
.work-row:hover .work-row__arrow { transform: translateX(6px) rotate(-45deg); color: var(--accent); }
@media (max-width: 760px) {
  .work-row { grid-template-columns: 32px minmax(0, 1fr) 24px; padding: 22px 4px; }
  .work-row__meta { display: none; }
  .work-row__arrow { font-size: 22px; align-self: start; }
}

/* Anterior / seguinte, no fim de cada projeto */
.pager { border-top: 1px solid var(--line); }
.pager__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  padding-top: clamp(32px, 5vw, 56px);
  padding-bottom: clamp(32px, 5vw, 56px);
}
.pager__link { display: flex; flex-direction: column; gap: 6px; text-decoration: none; }
.pager__link span.mono { font-size: 12px; color: var(--muted); }
.pager__name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(20px, 2.6vw, 34px);
  letter-spacing: -0.03em;
  line-height: 1.05;
  transition: color 0.3s;
}
.pager__link:hover .pager__name { color: var(--accent); }
.pager__link--next { text-align: right; }
.pager__all {
  font-size: 12px;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 16px;
  white-space: nowrap;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
}
.pager__all:hover { background: var(--accent); color: var(--ink); border-color: var(--accent); }
@media (max-width: 640px) {
  .pager__inner { grid-template-columns: 1fr 1fr; }
  .pager__all { grid-column: 1 / -1; grid-row: 2; justify-self: center; }
}

.case { padding: clamp(40px, 6vw, 72px) 0 clamp(72px, 10vw, 128px); }
.case__head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px clamp(20px, 4vw, 48px);
  align-items: start;
  margin-bottom: clamp(40px, 6vw, 64px);
}
.case__num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(72px, 13vw, 200px);
  line-height: 0.8;
  letter-spacing: -0.06em;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--muted);
}
.case__meta { font-size: 12px; color: var(--muted); margin: 0 0 16px; letter-spacing: 0.02em; }
.case__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(32px, 4.8vw, 68px);
  line-height: 1;
  letter-spacing: -0.04em;
  margin: 0;
  max-width: 20ch;
}
@media (max-width: 640px) { .case__head { grid-template-columns: 1fr; } }

/* Troca de títulos: as duas versões ocupam o mesmo espaço */
.swap { display: grid; }
.swap > span { grid-area: 1 / 1; transition: opacity 0.45s ease, transform 0.55s var(--ease), filter 0.45s; }
.swap__b {
  opacity: 0;
  transform: translateY(18px);
  filter: blur(6px);
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--bad);
}
.truth .swap__a { opacity: 0; transform: translateY(-18px); filter: blur(6px); }
.truth .swap__b { opacity: 1; transform: none; filter: none; }

.case__body {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.25fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.case--flip .case__text { order: 2; }
@media (max-width: 900px) {
  .case__body { grid-template-columns: 1fr; }
  .case--flip .case__text { order: 0; }
}
.case__name { font-weight: 600; font-size: 14px; margin: 0 0 12px; color: var(--accent); transition: color 0.3s; }
.case__desc { margin: 0 0 32px; font-size: 18px; color: #d6d2c9; }
.case__facts { margin: 0; font-size: 12.5px; }
.case__facts div { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.case__facts dt { color: var(--muted); }
.case__facts dd { margin: 0; }
.case__facts a { text-decoration-color: var(--accent); text-underline-offset: 3px; }

.case__nums {
  list-style: none;
  padding: 0;
  margin: clamp(40px, 6vw, 64px) 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.case__nums li { background: var(--bg); padding: 20px 22px; }
.case__nums b {
  display: block;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(34px, 4vw, 52px);
  letter-spacing: -0.04em;
  line-height: 1.05;
}
.case__nums span { font-size: 13px; color: var(--muted); }

.case__verdict {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}
@media (max-width: 900px) { .case__verdict { grid-template-columns: 1fr; } }
.verdict {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform 0.4s var(--ease), opacity 0.4s, border-color 0.4s, background 0.4s;
}
.verdict h2 { margin: 0 0 10px; font-size: 11.5px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; }
.verdict h2::before { content: "● "; }
.verdict p { margin: 0; font-size: 15.5px; color: #d6d2c9; }
.verdict--good h2 { color: var(--good); }
.verdict--bad h2 { color: var(--bad); }
.verdict--learn h2 { color: var(--learn); }
.truth .verdict--good { opacity: 0.45; }
.truth .verdict--bad { background: var(--bad); border-color: var(--bad); transform: translateY(-6px); }
.truth .verdict--bad h2, .truth .verdict--bad p { color: var(--ink); }

/* ---------- Visuais dos projetos ---------- */
.v-browser {
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.7);
  transform: rotate(-0.6deg);
  transition: transform 0.6s var(--ease);
}
.case--flip .v-browser { transform: rotate(0.6deg); }
.case__visual:hover .v-browser { transform: none; }
.v-browser__bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.v-browser__bar i { width: 10px; height: 10px; border-radius: 50%; background: #3a3a35; }
.v-browser__bar span {
  margin-left: 12px;
  font-size: 11.5px;
  color: var(--muted);
  background: var(--bg);
  padding: 4px 12px;
  border-radius: 6px;
  flex: 1;
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.v-browser img { width: 100%; aspect-ratio: 16 / 9.4; object-fit: cover; object-position: top; }
.v-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.v-strip img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; filter: saturate(0.85); transition: filter 0.3s; }
.v-strip img:hover { filter: none; }

.v-creatives { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 24px 0; }
.v-creatives figure { margin: 0; transition: transform 0.6s var(--ease); }
.v-creatives { gap: 4%; }
.v-creatives figure:first-child { transform: rotate(-3deg) translateX(3%); z-index: 1; position: relative; }
.v-creatives figure:last-child { transform: rotate(2.5deg) translate(-3%, 8%); }
.v-creatives:hover figure:first-child { transform: rotate(-1deg); }
.v-creatives:hover figure:last-child { transform: rotate(1deg); }
.v-creatives img { width: 100%; border-radius: 6px; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.8); }
.v-creatives figcaption { font-size: 11.5px; color: var(--muted); margin-top: 12px; text-align: center; }

.v-flow { list-style: none; margin: 0; padding: 0; counter-reset: f; }
.v-flow li {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px 22px;
  margin-bottom: 28px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  margin-left: calc(var(--i) * 6%);
}
.v-flow li span { color: var(--accent); transition: color 0.3s; }
.v-flow li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 34px;
  top: 100%;
  width: 1px;
  height: 28px;
  background: linear-gradient(var(--accent), transparent);
}
.v-flow li:last-child { background: var(--accent); color: var(--ink); border-color: var(--accent); }
.v-flow li:last-child span { color: var(--ink); }

.v-code {
  background: #070706;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 22px 24px;
  font-size: 13px;
  line-height: 1.9;
  overflow-x: auto;
}
.v-code__head { color: var(--muted); margin-bottom: 10px; }
.v-code__line { display: grid; grid-template-columns: 22px 1fr; white-space: nowrap; }
.v-code__line b { font-weight: 500; }
.v-code__line.is-off { color: #6b6862; }
.v-code__line.is-off span { text-decoration: line-through; text-decoration-color: var(--bad); }
.v-code__line.is-off b { color: var(--bad); }
.v-code__line.is-ok b { color: var(--good); }
.v-code__line.is-warn { color: var(--accent); }

.v-kanban {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid rgba(79, 140, 255, 0.35);
  background: radial-gradient(120% 120% at 0% 0%, rgba(79, 140, 255, 0.18), transparent 60%), #070a18;
  min-height: 340px;
}
.v-kanban__col { display: flex; flex-direction: column; gap: 8px; }
.v-kanban__col p { margin: 0 0 6px; font-size: 10.5px; color: #8ea9e8; display: flex; justify-content: space-between; }
.v-kanban__col p span { color: #4f8cff; }
.v-kanban__card { background: rgba(79, 140, 255, 0.12); border: 1px solid rgba(79, 140, 255, 0.3); border-radius: 8px; padding: 10px; }
.v-kanban__card i { display: block; height: 6px; border-radius: 3px; background: rgba(160, 190, 255, 0.5); margin-bottom: 6px; }
.v-kanban__card i:last-child { width: 55%; background: rgba(160, 190, 255, 0.22); margin: 0; }
.v-kanban__empty {
  flex: 1;
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 10.5px;
  color: #5a6a94;
  border: 1px dashed rgba(79, 140, 255, 0.35);
  border-radius: 8px;
  min-height: 120px;
}
.truth .v-kanban__empty { color: var(--bad); border-color: var(--bad); }

.v-logo {
  margin: 0;
  border-radius: 14px;
  border: 1px solid var(--line);
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.v-logo img { max-width: 70%; max-height: 80%; object-fit: contain; }

/* Mistério: nomes rasurados e projetos ainda por revelar */
.redact {
  display: inline-block;
  min-width: 6ch;
  color: transparent;
  background: repeating-linear-gradient(90deg, var(--text) 0 1ch, rgba(242, 239, 232, 0.75) 1ch 2ch);
  border-radius: 2px;
  line-height: 1;
  vertical-align: -0.1em;
  user-select: none;
}
.v-mystery {
  margin: 0;
  border-radius: 14px;
  border: 1px dashed var(--line);
  aspect-ratio: 4 / 3;
  padding: clamp(20px, 4vw, 36px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: repeating-linear-gradient(135deg, rgba(242, 239, 232, 0.03) 0 12px, transparent 12px 24px), #0a0a09;
}
.v-mystery__tag { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin: 0; }
.v-mystery__bars { display: grid; gap: 12px; }
.v-mystery__bars i { display: block; height: 14px; border-radius: 3px; background: rgba(242, 239, 232, 0.12); }
.v-mystery__bars i:nth-child(2) { width: 78%; }
.v-mystery__bars i:nth-child(3) { width: 52%; }
.v-mystery__msg { margin: 0; font-size: 14px; color: var(--muted); }

/* ---------- Regras ---------- */
.rules { background: var(--accent); color: var(--ink); padding: clamp(80px, 11vw, 140px) 0; transition: background 0.3s; }
.rules .eyebrow { color: rgba(13, 13, 11, 0.6); }
.rules__list { list-style: none; margin: 0; padding: 0; }
.rules__list li {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: baseline;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(28px, 4.6vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  padding: 24px 0;
  border-top: 1.5px solid var(--ink);
}
.rules__list li:last-child { border-bottom: 1.5px solid var(--ink); }
.rules__list span { font-size: 13px; font-weight: 500; letter-spacing: 0; }

/* ---------- Sem filtro ---------- */
.honest { background: var(--paper); color: var(--ink); padding: clamp(80px, 11vw, 140px) 0; }
.honest .section-sub { color: #5d5a53; }
.honest .section-sub a { color: var(--ink); text-underline-offset: 3px; }
.honest__cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
}
.honest__col {
  background: #fbf9f4;
  border: 1px solid var(--line-ink);
  border-radius: var(--radius);
  padding: 28px;
  border-top: 6px solid var(--c);
}
.honest__col--good { --c: #1f9d57; }
.honest__col--bad { --c: #d8402a; }
.honest__col--learning { --c: #3b5bdb; }
.honest__col h3 { font-family: var(--font-display); font-weight: 800; font-size: 26px; letter-spacing: -0.03em; margin: 0 0 12px; }
.honest__col ul { margin: 0; padding: 0; list-style: none; }
.honest__col li { padding: 14px 0 14px 24px; border-top: 1px solid var(--line-ink); position: relative; font-size: 16px; }
.honest__col li::before { content: "→"; position: absolute; left: 0; color: var(--c); font-weight: 700; }
.truth .honest__col--bad { background: var(--ink); color: var(--paper); border-color: var(--ink); border-top-color: var(--bad); }
.truth .honest__col--bad li { border-color: var(--line); }

.honest__quote {
  margin: clamp(56px, 9vw, 112px) 0 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(34px, 5.4vw, 80px);
  line-height: 1.04;
  letter-spacing: -0.02em;
  max-width: 18ch;
}

/* ---------- Log ---------- */
.log { padding: 0 0 clamp(80px, 11vw, 140px); }
.log__status { list-style: none; margin: 0 0 clamp(48px, 7vw, 80px); padding: 0; font-size: 13px; max-width: 640px; }
.log__status li { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.log__status li:last-child { border-bottom: 1px solid var(--line); }
.log__status span { color: var(--muted); }
.log__list a { text-decoration-color: var(--accent); text-underline-offset: 3px; transition: color 0.2s; }
.log__list a:hover { color: var(--accent); }
.log .section-title em { color: var(--accent); transition: color 0.3s; }
.log__list { list-style: none; margin: 0; padding: 0 0 0 20px; font-size: 14px; border-left: 1px solid var(--line); }
.log__list li {
  position: relative;
  display: grid;
  grid-template-columns: 110px 70px 1fr;
  gap: 16px;
  padding: 14px 0;
  color: #d6d2c9;
}
.log__list li::before {
  content: "";
  position: absolute;
  left: -25px;
  top: 21px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--bg);
  border: 1.5px solid var(--muted);
}
.log__list time { color: var(--muted); }
.log__list b { font-weight: 500; }
.t-feat { color: var(--good); }
.t-fix { color: var(--accent); transition: color 0.3s; }
.t-learn { color: var(--learn); }
.t-revert { color: var(--bad); }
.t-wip { color: var(--muted); }
.log__head::before { background: var(--accent) !important; border-color: var(--accent) !important; }
.log__head { color: var(--text) !important; font-weight: 500; }
.cursor { display: inline-block; width: 9px; height: 1.1em; background: var(--accent); vertical-align: -3px; margin-left: 6px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
@media (max-width: 640px) {
  .log__list li { grid-template-columns: 1fr; gap: 2px; }
  .log__list b { display: none; }
}

/* ---------- Contacto ---------- */
.contact { background: var(--paper); color: var(--ink); padding: clamp(48px, 8vw, 104px) 0 clamp(88px, 13vw, 168px); min-height: calc(100svh - 61px); }
.contact .page-head__crumb, .contact .page-head__crumb a { color: #5d5a53; }
.contact .page-head__crumb a:hover { color: var(--ink); }
.contact .eyebrow { color: #5d5a53; }
.contact__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(38px, 6.6vw, 100px);
  line-height: 0.98;
  letter-spacing: -0.05em;
  margin: 0 0 28px;
  max-width: 16ch;
}
.contact__sub { max-width: 520px; font-size: 18px; color: #5d5a53; margin: 0 0 48px; }
.contact__mail {
  display: inline-block;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(22px, 3.6vw, 48px);
  text-decoration: none;
  border-bottom: 3px solid var(--accent);
  overflow-wrap: anywhere;
  transition: border-color 0.3s;
}
.contact__mail:hover { background: var(--accent); }
.contact__social { list-style: none; display: flex; flex-wrap: wrap; gap: 28px; padding: 0; margin: 40px 0 0; font-weight: 600; }
.contact__social a { text-decoration: none; }
.contact__social a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); }
.footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-top: 24px; padding-bottom: 24px; font-size: 12px; color: var(--muted); }

/* ---------- Telemóvel ---------- */
.tabbar { display: none; }
@media (max-width: 760px) {
  .nav { padding-top: calc(12px + env(safe-area-inset-top)); padding-bottom: 12px; }
  .tabbar {
    display: flex;
    position: fixed;
    z-index: 110;
    left: 50%;
    bottom: calc(14px + env(safe-area-inset-bottom));
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100% - 24px);
    gap: 2px;
    padding: 5px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(22, 22, 19, 0.82);
    backdrop-filter: blur(18px) saturate(1.4);
    -webkit-backdrop-filter: blur(18px) saturate(1.4);
    box-shadow: 0 12px 32px -8px rgba(0, 0, 0, 0.6);
  }
  .tabbar a {
    padding: 9px 13px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    color: var(--muted);
    white-space: nowrap;
    transition: background 0.25s, color 0.25s;
  }
  .tabbar a[aria-current="page"] { background: var(--accent); color: var(--ink); }
  .footer { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }

  .hero--landing .hero__inner { min-height: 0; padding-top: 40px; }
  .rotator { padding: 16px 18px 14px; }
  .case { padding: 32px 0 64px; }
  .case__nums { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case__nums li { padding: 16px; }
  .case__nums b { font-size: 30px; }
  .case__nums span { font-size: 12px; line-height: 1.4; display: block; }
  .stat { padding: 22px 20px 24px; }
  .stat__value { font-size: 54px; }
  .verdict { padding: 20px; }
  .rules__list li { grid-template-columns: 32px 1fr; padding: 18px 0; }
  .honest__col { padding: 22px; }
  .v-kanban { min-height: 240px; padding: 10px; gap: 5px; }
  .v-kanban__col p { font-size: 8.5px; }
  .v-creatives { padding: 8px 0 28px; }
  .contact__mail { font-size: 21px; }
  .truth .verdict--bad { transform: none; }
}

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.8s ease var(--d, 0ms), transform 0.8s var(--ease) var(--d, 0ms); }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Transição entre páginas (Chrome, Edge e Safari recentes) ---------- */
@view-transition { navigation: auto; }
.nav { view-transition-name: nav; }
.tabbar { view-transition-name: tabbar; }
::view-transition-old(root) { animation: vt-out 0.3s var(--ease) both; }
::view-transition-new(root) { animation: vt-in 0.55s var(--ease) both; }
@keyframes vt-out { to { opacity: 0; transform: translateY(-20px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(36px); } }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .swap > span { transition: none; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}
