/* Wenex — "Modo Wenex" do Acium Manager levado ao cinema: azul-tinta quase
   negro, o degradê lima → ciano → azul em luzes largas, vidro e luz branca. */
:root {
  --ink: #010204;
  --ink-2: #081120;
  --text: #EAF4FF;
  --sub: rgba(206, 226, 250, 0.62);
  --faint: rgba(206, 226, 250, 0.38);
  --lime: #A8F23A;
  --cyan: #22D3EE;
  --blue: #0A62F4;
  --line: rgba(160, 210, 255, 0.16);
  --glass: rgba(14, 22, 40, 0.58);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --u: min(0.6px, calc(84vw / 1454), calc(34vh / 355));
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { background: var(--ink); scrollbar-width: none; overflow: hidden; }
html::-webkit-scrollbar { display: none; }
html.sheet-on { overflow: hidden; }
body { min-height: 100%; }

body {
  background: var(--ink);
  color: var(--text);
  font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
  overscroll-behavior: none;
  cursor: default;
  -webkit-tap-highlight-color: transparent;
}

::selection { background: var(--text); color: var(--ink); }

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- atmosfera ---------- */
#light {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  display: block;
}

.grain {
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  opacity: .035;
  pointer-events: none;
  animation: grain 1s steps(6) infinite;
}

@keyframes grain {
  0%   { transform: translate(0, 0); }
  20%  { transform: translate(-7%, 4%); }
  40%  { transform: translate(5%, -9%); }
  60%  { transform: translate(-3%, 7%); }
  80%  { transform: translate(8%, 2%); }
  100% { transform: translate(-5%, -4%); }
}

.vignette {
  position: fixed; inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%, transparent 50%, rgba(0, 0, 0, .8) 100%);
}

/* barras de cinema e o risco de luz anamórfico da abertura */
.bar {
  position: fixed; left: 0; right: 0;
  height: 12vh;
  background: #000;
  z-index: 20;
  pointer-events: none;
  transform: scaleY(0);
}
.bar-top { top: 0; transform-origin: top; }
.bar-bottom { bottom: 0; transform-origin: bottom; }

.flare {
  position: fixed; left: 50%; top: 50%;
  width: 0; height: 0;
  z-index: 15;
  pointer-events: none;
  mix-blend-mode: screen;
}
.flare i {
  position: absolute;
  left: -70vw; top: -1px;
  width: 140vw; height: 2px;
  opacity: 0;
  transform: scaleX(0);
  background: linear-gradient(90deg,
    transparent 0%, rgba(10, 98, 244, .0) 8%, rgba(10, 98, 244, .55) 30%,
    rgba(34, 211, 238, .9) 46%, #fff 50%, rgba(34, 211, 238, .9) 54%,
    rgba(168, 242, 58, .5) 72%, transparent 92%);
  box-shadow: 0 0 18px 2px rgba(34, 211, 238, .55), 0 0 60px 6px rgba(10, 98, 244, .35);
  border-radius: 2px;
}

/* ---------- palco ---------- */
.stage {
  position: fixed; inset: 0;
  z-index: 10;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 10vh 16px 16vh;
  transform-origin: 50% 40%;
}

.stage > * { flex-shrink: 0; }

.lockup {
  display: flex; align-items: center;
  gap: calc(84 * var(--u));
  position: relative;
}

.mark-wrap {
  width: calc(370 * var(--u));
  height: calc(355 * var(--u));
  position: relative;
  z-index: 2;
}

/* a folha de alta definição do símbolo (ver --hd no JS) */
.mark-hd {
  position: absolute; left: 50%; top: 50%;
  width: calc(100% * var(--hd, 1));
  height: calc(100% * var(--hd, 1));
  transform: translate(-50%, -50%) scale(calc(1 / var(--hd, 1)));
  perspective: calc(900px * var(--hd, 1));
}

.mark {
  position: absolute; inset: 0;
  transform-style: preserve-3d;
  cursor: pointer;
}

.layer {
  position: absolute; inset: 0;
  transform-style: preserve-3d;
  pointer-events: none;
}
.layer .fly { position: absolute; inset: 0; }
.tilebox, .glass, .gembox { position: absolute; inset: 0; }
/* camadas próprias na placa gráfica: mexer-lhes não obriga a redesenhar o vidro */
.tilebox, .gembox, svg.live, svg.core-svg, .layer.links svg { will-change: transform; }
.layer svg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  overflow: visible;
}
/* profundidade: o núcleo flutua à frente do vidro, as ligações entre eles */
.layer.gem { transform: translateZ(calc(64px * var(--hd, 1))); }
.layer.links { transform: translateZ(calc(4px * var(--hd, 1))); }
.layer.tl, .layer.br { transform: translateZ(calc(8px * var(--hd, 1))); }

.gem-shine { mix-blend-mode: screen; }
.cast { mix-blend-mode: screen; }

.ring {
  position: absolute;
  left: calc((298 - 115) / 370 * 100%);
  top: calc((462 - 285) / 355 * 100%);
  width: calc(170 * var(--u) * var(--hd, 1)); height: calc(170 * var(--u) * var(--hd, 1));
  margin: calc(-85 * var(--u) * var(--hd, 1)) 0 0 calc(-85 * var(--u) * var(--hd, 1));
  border-radius: 50%;
  border: 1px solid rgba(34, 211, 238, .9);
  box-shadow: 0 0 24px rgba(34, 211, 238, .5), inset 0 0 24px rgba(34, 211, 238, .25);
  opacity: 0;
  pointer-events: none;
  transform: translateZ(calc(64px * var(--hd, 1))) scale(.4);
}

.word {
  width: calc(1014 * var(--u));
  height: calc(210 * var(--u));
  position: relative;
  margin-top: calc(22 * var(--u));
}
.word svg { width: 100%; height: 100%; overflow: visible; display: block; }

/* ---------- história ao rolar ---------- */
.track { display: none; }
html:not(.sheet-on) body { touch-action: none; }

/* pontos das fases, à direita */
.steps {
  position: fixed; right: clamp(14px, 2.2vw, 30px); top: 50%;
  transform: translateY(-50%);
  z-index: 13;
  display: flex; flex-direction: column; gap: 10px;
  opacity: 0; pointer-events: none;
  transition: opacity .8s ease;
}
.ready .steps { opacity: 1; pointer-events: auto; }
.sheet-on .steps, .showcase .steps { opacity: 0; pointer-events: none; }
.steps button {
  width: 6px; height: 6px; padding: 0;
  border: 0; border-radius: 3px;
  background: rgba(206, 226, 250, .28);
  cursor: pointer;
  transition: height .5s var(--ease-out), background .4s;
  position: relative;
}
.steps button::before { content: ''; position: absolute; inset: -8px; }
.steps button:hover { background: rgba(206, 226, 250, .6); }
.steps button[aria-current="step"] { height: 22px; background: var(--cyan); }
.steps button:focus-visible { outline: 1px solid var(--cyan); outline-offset: 3px; }

.hero-copy { display: flex; flex-direction: column; align-items: center; will-change: opacity, transform; }
.lockup { will-change: transform; }
.word { will-change: opacity, filter; }

.chapters { position: fixed; inset: 0; z-index: 11; pointer-events: none; }
.chapter {
  position: absolute; left: 50%; top: clamp(76px, 10vh, 124px);
  width: min(1180px, calc(100vw - 40px));
  margin-left: calc(min(1180px, calc(100vw - 40px)) / -2);
  text-align: center;
  opacity: 0; visibility: hidden;
  will-change: opacity, transform;
}
.ch-kicker {
  font-size: 15px; letter-spacing: -.01em; font-weight: 600;
  color: var(--cyan);
  display: inline-block;
  margin-bottom: 18px;
}
.ch-title {
  font-size: clamp(32px, 4.3vw, 68px);
  font-weight: 600;
  letter-spacing: -.035em;
  line-height: 1.04;
  text-wrap: balance;
  color: #F5F9FF;
}
.ch-title .sw { transition: opacity .25s linear; }
.ch-sub {
  margin: 18px auto 0;
  max-width: 58ch;
  font-size: clamp(16px, 1.45vw, 21px);
  line-height: 1.45;
  font-weight: 400;
  color: var(--sub);
  letter-spacing: -.005em;
}
.chapter.big .ch-title { font-size: clamp(36px, 5.6vw, 84px); letter-spacing: -.04em; }
.grad {
  background: linear-gradient(100deg, #B9F56A 0%, #4DE2BE 32%, #22D3EE 58%, #2F8BFF 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.grad .sw { color: transparent; }
.chapter.final { top: 47vh; /* o JS recalcula conforme o ecrã */ }
.chapter.final .ch-title { font-size: clamp(32px, 4.4vw, 64px); }
.final-actions {
  margin-top: clamp(26px, 4vh, 40px);
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}
.final-mail {
  color: var(--sub); text-decoration: none; font-size: 14px; letter-spacing: .02em;
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
  transition: color .3s;
}
.final-mail:hover { color: var(--text); }

/* etiquetas das ferramentas (vista explodida) — contrariam a escala do símbolo */
.tools { position: absolute; inset: 0; pointer-events: none; }
.tool {
  position: absolute;
  width: 0; height: 0;
  opacity: 0;
}
.tool-in {
  position: absolute;
  display: flex; flex-direction: column; gap: 3px;
  white-space: nowrap;
  transform: translateY(-50%) translateY(var(--rise, 0px)) scale(var(--inv, 1));
}
.tool.tl .tool-in, .tool.bl .tool-in { right: 0; text-align: right; align-items: flex-end; transform-origin: right center; }
.tool.tr .tool-in, .tool.br .tool-in { left: 0; transform-origin: left center; }
.tool i {
  font-style: normal; font-size: 11px; letter-spacing: .18em;
  color: var(--cyan); font-weight: 500;
}
.tool b { font-size: 22px; font-weight: 600; letter-spacing: -.02em; color: #F5F9FF; }
.tool small { font-size: 13.5px; color: var(--sub); letter-spacing: 0; }

.narrow .tool-in { align-items: center !important; text-align: center !important; left: auto; right: auto; }
.narrow .tool.tl .tool-in, .narrow .tool.tr .tool-in { bottom: 0; transform: translateX(-50%) translateY(var(--rise, 0px)) scale(var(--inv, 1)); transform-origin: center bottom; left: 0; right: auto; }
.narrow .tool.bl .tool-in, .narrow .tool.br .tool-in { top: 0; transform: translateX(-50%) translateY(var(--rise, 0px)) scale(var(--inv, 1)); transform-origin: center top; left: 0; right: auto; }
.narrow .tool b { font-size: 17px; }
.narrow .tool small { display: none; }

/* barra de topo em vidro quando se rola (como em apple.com) */
.chrome.top::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(rgba(6, 10, 20, .9), rgba(6, 10, 20, .78));
  border-bottom: 1px solid rgba(160, 210, 255, .08);
  opacity: 0;
  transition: opacity .5s ease;
  z-index: -1;
}
/* sem barra: os controlos ficam soltos sobre o fundo, tudo numa peça só */
.chrome.top::before { display: none; }
.chrome.top { height: 56px; justify-content: flex-end; transition: height .5s var(--ease-out); }
.top-right { display: flex; align-items: center; gap: 14px; }
.nav-cta {
  font: inherit; font-size: 12px; letter-spacing: .02em; text-transform: none; font-weight: 500;
  color: #06101e; background: #F3F8FF;
  border: 0; border-radius: 999px;
  height: 30px; padding: 0 14px;
  cursor: pointer;
  opacity: 0; transform: translateY(-4px); pointer-events: none;
  transition: opacity .4s ease, transform .4s var(--ease-out), background .3s;
}
.scrolled .nav-cta { opacity: 1; transform: none; pointer-events: auto; }
.nav-cta:hover { background: #fff; }

/* convite a rolar */
.hint {
  position: absolute; left: 50%; bottom: 22px;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  font-size: 10.5px; letter-spacing: .2em;
  color: var(--faint);
  pointer-events: none;
}
.hint i {
  display: block; width: 1px; height: 34px;
  background: linear-gradient(rgba(206, 226, 250, 0), rgba(206, 226, 250, .7));
  transform-origin: top;
  animation: hint 2.2s cubic-bezier(.6, 0, .2, 1) infinite;
}
@keyframes hint {
  0% { transform: scaleY(0); opacity: 1; }
  60% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1) translateY(10px); opacity: 0; }
}
.chrome.bottom { height: 90px; align-items: flex-end; padding-bottom: 26px; }

/* ---------- texto e contacto ---------- */
.tagline {
  margin-top: clamp(34px, 5.6vh, 60px);
  font-size: clamp(15px, 1.3vw, 19px);
  font-weight: 300;
  letter-spacing: .005em;
  color: var(--sub);
  text-align: center;
  max-width: 52ch;
  line-height: 1.5;
  text-wrap: balance;
}
.tagline .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; }
.tagline .w > span { display: inline-block; }

.contact {
  margin-top: clamp(24px, 4vh, 40px);
  display: flex; flex-direction: column; align-items: center;
  gap: 16px;
}

/* botão: pílula branca, que se enche com o degradê da marca */
.cta {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 54px;
  padding: 0 24px 0 30px;
  border-radius: 999px;
  border: 0;
  color: #06101e;
  background: #F3F8FF;
  text-decoration: none;
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: .005em;
  cursor: pointer;
  isolation: isolate;
  overflow: hidden;
  transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .5) inset,
    0 10px 30px -10px rgba(140, 220, 255, .45),
    0 0 60px -10px rgba(34, 211, 238, .35);
  will-change: transform;
}
.cta-fill {
  position: absolute; inset: 0;
  z-index: -1;
  background: linear-gradient(105deg, #A8F23A, #4DE2BE 34%, var(--cyan) 58%, #1A8CF6);
  clip-path: circle(0% at var(--fx, 50%) var(--fy, 50%));
  transition: clip-path .7s var(--ease-out);
}
.cta:hover .cta-fill, .cta:focus-visible .cta-fill { clip-path: circle(150% at var(--fx, 50%) var(--fy, 50%)); }
.cta:hover, .cta:focus-visible {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .4) inset,
    0 14px 40px -10px rgba(34, 211, 238, .7),
    0 0 90px -10px rgba(34, 211, 238, .55);
}
.cta:focus-visible { outline: 2px solid rgba(34, 211, 238, .6); outline-offset: 4px; }
.cta:active { transform: scale(.97) !important; }
.cta-arrow {
  width: 19px; height: 19px;
  fill: none; stroke: currentColor; stroke-width: 1.9;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform .5s var(--ease-out);
}
.cta:hover .cta-arrow { transform: translateX(4px); }

.email {
  display: inline-flex; align-items: baseline; gap: 8px;
  background: none; border: 0;
  color: var(--faint);
  font: inherit; font-size: 13px;
  letter-spacing: .02em;
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 8px;
  transition: color .3s;
}
.email-addr { color: var(--sub); transition: color .3s; border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.email-state {
  font-size: 11px; text-transform: uppercase; letter-spacing: .14em;
  color: var(--cyan);
  opacity: 0; transform: translateX(-4px);
  transition: opacity .3s, transform .3s var(--ease-out);
}
.email:hover .email-addr, .email:focus-visible .email-addr { color: var(--text); }
.email:hover .email-state, .email:focus-visible .email-state, .email.done .email-state { opacity: 1; transform: none; }
.email:focus-visible { outline: 1px solid var(--line); }

/* ---------- moldura ---------- */
.chrome {
  position: fixed; left: 0; right: 0;
  z-index: 12;
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 clamp(18px, 3.2vw, 44px);
  height: 72px;
  font-size: 11.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--faint);
}
.chrome.top { top: env(safe-area-inset-top, 0); }
.chrome.bottom { bottom: env(safe-area-inset-bottom, 0); }

.lang { display: flex; gap: 2px; }
.lang button {
  background: none; border: 0;
  font: inherit; letter-spacing: .14em;
  color: var(--faint);
  padding: 10px 9px;
  cursor: pointer;
  border-radius: 6px;
  transition: color .3s;
  position: relative;
}
.lang button:hover { color: var(--sub); }
.lang button[aria-pressed="true"] { color: var(--text); }
.lang button[aria-pressed="true"]::after {
  content: ''; position: absolute; left: 50%; bottom: 4px;
  width: 3px; height: 3px; margin-left: -1.5px; border-radius: 50%;
  background: var(--cyan);
}
.lang button:focus-visible { outline: 1px solid var(--line); }

.noscript { position: fixed; inset: 0; z-index: 30; display: grid; place-content: center; text-align: center; gap: 24px; }
.noscript img { max-width: 80vw; height: auto; }
.noscript a { color: var(--cyan); }

/* ---------- painel de contacto (vidro) ---------- */
.sheet {
  position: fixed; inset: 0;
  z-index: 40;
  display: grid; place-items: center;
  padding: 24px;
}
.sheet[hidden] { display: none; }
.sheet-backdrop {
  position: absolute; inset: 0;
  background: rgba(2, 5, 12, .55);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
          backdrop-filter: blur(14px) saturate(140%);
}

.sheet-panel {
  position: relative;
  width: min(620px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 44px 44px 36px;
  border-radius: 28px;
  background:
    radial-gradient(120% 70% at 0% 0%, rgba(168, 242, 58, .07), transparent 55%),
    radial-gradient(100% 70% at 100% 0%, rgba(34, 211, 238, .09), transparent 55%),
    radial-gradient(120% 80% at 100% 100%, rgba(10, 98, 244, .12), transparent 60%),
    var(--glass);
  -webkit-backdrop-filter: blur(40px) saturate(170%);
          backdrop-filter: blur(40px) saturate(170%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .22),
    inset 0 0 0 1px rgba(170, 220, 255, .12),
    inset 0 -30px 60px -40px rgba(34, 211, 238, .25),
    0 40px 120px -30px rgba(0, 0, 0, .8),
    0 0 120px -40px rgba(34, 211, 238, .35);
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.15) transparent;
}
/* aro especular do vidro */
.sheet-panel::before {
  content: '';
  position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(150deg, rgba(255,255,255,.55), rgba(255,255,255,.04) 30%, rgba(255,255,255,0) 60%, rgba(34,211,238,.35));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
}

.sheet-grip { display: none; }

.sheet-close {
  position: absolute; top: 18px; right: 18px;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, .06);
  color: var(--sub);
  cursor: pointer;
  transition: background .3s, color .3s, transform .4s var(--ease-out);
}
.sheet-close:hover { background: rgba(255, 255, 255, .12); color: var(--text); transform: rotate(90deg); }
.sheet-close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }

.sheet-kicker {
  font-size: 14px; letter-spacing: -.005em;
  color: var(--cyan);
  font-weight: 500;
  display: inline-block;
}
.sheet-title {
  margin-top: 12px;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
  text-wrap: balance;
  padding-right: 36px;
}
.sheet-sub {
  margin-top: 10px;
  font-size: 14.5px; line-height: 1.55;
  color: var(--sub);
  font-weight: 300;
  max-width: 46ch;
}

.fields {
  margin-top: 28px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.full { grid-column: 1 / -1; }

.field {
  position: relative;
  display: block;
}
.field input, .field textarea {
  width: 100%;
  font: inherit; font-size: 15px;
  color: var(--text);
  background: rgba(255, 255, 255, .045);
  border: 1px solid rgba(170, 220, 255, .12);
  border-radius: 14px;
  padding: 24px 16px 9px;
  outline: none;
  transition: border-color .3s, background .3s, box-shadow .3s;
  resize: none;
  -webkit-appearance: none;
}
.field textarea { min-height: 120px; line-height: 1.5; padding-top: 28px; }
.field span {
  position: absolute; left: 17px; top: 17px;
  font-size: 15px;
  color: var(--faint);
  pointer-events: none;
  transform-origin: left top;
  transition: transform .35s var(--ease-out), color .3s;
}
.field input:focus, .field textarea:focus {
  border-color: rgba(34, 211, 238, .55);
  background: rgba(255, 255, 255, .07);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, .1);
}
.field input:focus + span, .field textarea:focus + span,
.field input:not(:placeholder-shown) + span, .field textarea:not(:placeholder-shown) + span {
  transform: translateY(-9px) scale(.76);
  color: var(--sub);
}
.field input:focus + span, .field textarea:focus + span { color: var(--cyan); }
.field input:-webkit-autofill {
  -webkit-text-fill-color: var(--text);
  -webkit-box-shadow: 0 0 0 100px #0d1626 inset;
  caret-color: var(--text);
}
.field.bad input, .field.bad textarea { border-color: rgba(255, 107, 129, .7); }
.field.bad::after {
  content: attr(data-err);
  position: absolute; right: 14px; top: 9px;
  font-size: 11px; letter-spacing: .02em;
  color: #FF8A9B;
}

.chips { border: 0; margin: 4px 0 2px; }
.chips legend {
  font-size: 13px; color: var(--faint);
  margin-bottom: 10px;
}
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font: inherit; font-size: 13.5px;
  color: var(--sub);
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(170, 220, 255, .14);
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  transition: color .25s, background .25s, border-color .25s, transform .3s var(--ease-out);
}
.chip:hover { color: var(--text); border-color: rgba(170, 220, 255, .3); }
.chip:active { transform: scale(.96); }
.chip[aria-pressed="true"] {
  color: #04121c;
  background: linear-gradient(105deg, #B9F56A, #5FE6CF 50%, #4FD8F2);
  border-color: transparent;
}
.chip:focus-visible { outline: 2px solid rgba(34, 211, 238, .5); outline-offset: 2px; }

.sheet-actions {
  margin-top: 26px;
  display: flex; align-items: center; gap: 20px;
}
.cta.send { flex: none; }
.sheet-note {
  font-size: 12.5px; line-height: 1.5;
  color: var(--faint);
}

.sheet-done {
  padding: 26px 0 8px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
}
.sheet-done[hidden] { display: none; }
.sheet-done .sheet-title { padding: 0; margin-top: 22px; }
.sheet-done .sheet-sub { margin-top: 10px; }
.done-mark svg { width: 64px; height: 64px; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.done-mark circle { stroke: rgba(34, 211, 238, .35); }
.done-mark path { stroke: var(--cyan); stroke-dasharray: 40; stroke-dashoffset: 40; animation: tick .7s .25s var(--ease-out) forwards; }
@keyframes tick { to { stroke-dashoffset: 0; } }
.done-link {
  margin-top: 18px;
  color: var(--text);
  font-size: 15px;
  text-decoration: none;
  border-bottom: 1px solid rgba(34, 211, 238, .5);
  padding-bottom: 2px;
}

/* ---------- estado inicial da abertura (o JS revela) ---------- */
.js .tagline, .js .contact, .js .chrome { opacity: 0; }

/* ---------- telemóvel / ecrãs estreitos ---------- */
@media (max-width: 720px), (max-aspect-ratio: 4/5) {
  :root { --u: min(0.5px, calc(46vw / 370), calc(24vh / 355)); --uw: min(0.32px, calc(70vw / 1014)); }
  .stage { padding: 76px 22px 22vh; }
  .lockup { flex-direction: column; gap: clamp(22px, 4vh, 34px); }
  .word { width: calc(1014 * var(--uw)); height: calc(210 * var(--uw)); margin-top: 0; }
  .tagline { font-size: 16px; max-width: 26ch; margin-top: clamp(24px, 4.2vh, 40px); }
  .contact { width: 100%; margin-top: clamp(22px, 3.6vh, 34px); }
  .cta { height: 56px; width: min(100%, 300px); font-size: 16px; }
  .email-pre, .email-state { display: none; }
  .email.done .email-state { display: inline; }
  .chrome { height: 60px; font-size: 10.5px; }
  .top-right { gap: 6px; }
  .lang button { padding: 10px 6px; }
  .chrome.bottom .meta { font-size: 10px; }
  .chrome.bottom { justify-content: flex-start; }
  .chrome.bottom > .meta:first-child { display: none; }
  .chapter { top: clamp(78px, 11vh, 110px); }
  .ch-title { font-size: clamp(30px, 8.6vw, 40px); }
  .ch-sub { font-size: 16px; margin-top: 14px; max-width: 30ch; }
  .chapter.big .ch-title { font-size: clamp(34px, 10vw, 48px); }
  .chapter.final .ch-title { font-size: clamp(28px, 8vw, 38px); }
  .bar { height: 9vh; }
}

@media (max-width: 720px) and (max-height: 700px) {
  :root { --u: min(0.42px, calc(40vw / 370), calc(21vh / 355)); }
  .stage { padding-top: 64px; }
  .tagline { margin-top: 18px; }
  .contact { margin-top: 18px; gap: 10px; }
}

/* no telemóvel o painel é uma folha que sobe de baixo */
@media (max-width: 720px) {
  .sheet { padding: 0; place-items: end stretch; }
  .sheet-panel {
    width: 100%;
    max-height: calc(100dvh - 28px);
    border-radius: 26px 26px 0 0;
    padding: 30px 20px calc(24px + env(safe-area-inset-bottom, 0px));
  }
  .sheet-panel::before { border-radius: 26px 26px 0 0; }
  .sheet-grip {
    display: block;
    position: absolute; top: 9px; left: 50%;
    width: 38px; height: 5px; margin-left: -19px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .22);
  }
  .sheet-close { top: 14px; right: 14px; width: 34px; height: 34px; }
  .sheet-title { font-size: 25px; }
  .fields { grid-template-columns: 1fr; gap: 10px; margin-top: 22px; }
  .field input, .field textarea { font-size: 16px; }
  .chip { font-size: 14px; padding: 9px 14px; }
  .sheet-actions { flex-direction: column; align-items: stretch; gap: 12px; }
  .cta.send { width: 100%; }
  .sheet-note { text-align: center; }
}

@media (max-height: 560px) and (min-width: 721px) {
  .stage { padding-top: 70px; padding-bottom: 12vh; }
  .tagline { margin-top: 20px; }
  .contact { margin-top: 16px; gap: 8px; }
}


/* vitrine (clique no símbolo): só o símbolo e as ferramentas */
.chrome.bottom > * { transition: opacity .5s ease; }
.showcase .chrome.bottom > * { opacity: 0 !important; }
.showcase .mark { cursor: zoom-out; }

/* ecrãs baixos (portátil com zoom, janela pequena, telemóvel deitado) */
@media (max-height: 640px) and (min-width: 721px) {
  .chapter { top: 66px; }
  .ch-kicker { margin-bottom: 8px; font-size: 13px; }
  .ch-title { font-size: clamp(26px, 3.6vw, 44px); }
  .chapter.big .ch-title { font-size: clamp(28px, 4vw, 50px); }
  .chapter.final .ch-title { font-size: clamp(26px, 3.4vw, 40px); }
  .ch-sub { font-size: 15px; margin-top: 10px; }
  .final-actions { margin-top: 18px; gap: 10px; }
  .chrome.bottom { height: 56px; padding-bottom: 14px; }
  .hint i { height: 22px; }
}
@media (max-height: 460px) and (min-width: 721px) {
  .chapter { top: 58px; }
  .ch-title { font-size: clamp(22px, 3vw, 32px); }
  .chapter.big .ch-title { font-size: clamp(24px, 3.2vw, 36px); }
  .ch-sub { display: none; }
  .chapter.final .ch-sub { display: block; font-size: 13px; }
  .hint { display: none; }
}
/* ecrãs muito grandes: o texto não cresce para sempre */
@media (min-width: 2200px) {
  .chapter { width: min(1280px, calc(100vw - 40px)); margin-left: calc(min(1280px, calc(100vw - 40px)) / -2); }
}

/* ---------- ferramentas: clicáveis na vista explodida ---------- */
.tool-hit {
  position: absolute;
  width: 40%; height: 41%;
  transform: translate(-50%, -50%);
  border: 0; padding: 0; margin: 0;
  background: transparent;
  border-radius: 22%;
  cursor: pointer;
  pointer-events: none;
}
.tools-live .tool-hit { pointer-events: auto; }
.tools-live .tool-in { pointer-events: auto; cursor: pointer; }
.tool-in { transition: color .3s; }
.tools-live .tool:hover b { color: var(--cyan); }
.tool-on .tool-hit, .tool-on .tool-in { pointer-events: none !important; }
.tool-on .steps { opacity: 0; pointer-events: none; }

/* painel da ferramenta: vidro ao lado da peça */
.tool-panel {
  position: fixed;
  right: clamp(20px, 5vw, 96px); top: 50%;
  width: min(440px, 38vw);
  transform: translateY(-50%);
  z-index: 14;
  padding: 26px 30px 28px;
  border-radius: 26px;
  background:
    radial-gradient(120% 70% at 0% 0%, rgba(168, 242, 58, .06), transparent 55%),
    radial-gradient(120% 80% at 100% 100%, rgba(10, 98, 244, .12), transparent 60%),
    rgba(12, 20, 38, .72);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
          backdrop-filter: blur(24px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), inset 0 0 0 1px rgba(170,220,255,.12), 0 40px 100px -30px rgba(0,0,0,.8);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .5s ease, visibility 0s linear .5s;
}
.tool-on .tool-panel { opacity: 1; visibility: visible; pointer-events: auto; transition: opacity .5s ease; }
.tp-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 22px; }
.tp-tabs button {
  font: inherit; font-size: 12.5px; font-weight: 500;
  color: var(--sub);
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(170,220,255,.12);
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
  transition: color .3s, background .3s, border-color .3s;
}
.tp-tabs button:hover { color: var(--text); }
.tp-tabs button[aria-selected="true"] { color: #04121c; background: #EAF4FF; border-color: transparent; }
.tp-kicker { font-size: 13px; font-weight: 600; color: var(--cyan); letter-spacing: .02em; }
.tp-title { margin-top: 10px; font-size: clamp(24px, 2.3vw, 32px); font-weight: 600; letter-spacing: -.03em; line-height: 1.12; text-wrap: balance; }
.tp-text { margin-top: 12px; font-size: 15px; line-height: 1.55; color: var(--sub); }
.tp-list { list-style: none; margin-top: 18px; display: grid; gap: 10px; }
.tp-list li { position: relative; padding-left: 22px; font-size: 14.5px; color: var(--text); line-height: 1.4; }
.tp-list li::before {
  content: ''; position: absolute; left: 0; top: .42em;
  width: 9px; height: 9px; border-radius: 3px;
  background: linear-gradient(135deg, #A8F23A, #22D3EE 55%, #0A62F4);
  box-shadow: 0 0 10px rgba(34, 211, 238, .5);
}
.tp-actions { margin-top: 24px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.tp-cta { height: 48px; padding: 0 20px 0 24px; font-size: 14.5px; }
.tp-back {
  display: inline-flex; align-items: center; gap: 8px;
  background: none; border: 0; cursor: pointer;
  font: inherit; font-size: 14px; color: var(--sub);
  padding: 8px 4px;
  transition: color .3s;
}
.tp-back:hover { color: var(--text); }
.tp-back svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

@media (max-width: 720px), (max-aspect-ratio: 4/5) {
  .tool-panel {
    left: 12px; right: 12px; top: auto; bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    width: auto; transform: none;
    max-height: 58vh; overflow: auto;
    padding: 20px 20px 22px;
    border-radius: 24px;
  }
  .tp-tabs { margin-bottom: 14px; }
  .tp-tabs button { font-size: 12px; padding: 6px 10px; }
  .tp-title { font-size: 22px; }
  .tp-text { font-size: 14px; margin-top: 8px; }
  .tp-list { margin-top: 12px; gap: 7px; }
  .tp-list li { font-size: 13.5px; }
  .tp-actions { margin-top: 16px; }
}

/* envio do contacto */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cta.send.is-sending { pointer-events: none; }
.cta.send.is-sending .cta-arrow { animation: sendPulse 1s ease-in-out infinite; }
@keyframes sendPulse { 0%, 100% { transform: translateX(0); opacity: 1; } 50% { transform: translateX(6px); opacity: .4; } }
.done-link[hidden] { display: none; }

/* ---------- download: botão no topo e catálogo de empresas ---------- */
.nav-dl {
  display: inline-flex; align-items: center; gap: 7px;
  height: 30px; padding: 0 13px 0 11px;
  border-radius: 999px;
  border: 1px solid rgba(206, 226, 250, .2);
  background: rgba(255, 255, 255, .04);
  color: var(--text);
  font: inherit; font-size: 12px; letter-spacing: .02em; text-transform: none; font-weight: 500;
  cursor: pointer;
  transition: background .3s, border-color .3s;
}
.nav-dl:hover { background: rgba(255, 255, 255, .1); border-color: rgba(206, 226, 250, .35); }
.nav-dl svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

.catalog { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; padding: 20px; }
.catalog[hidden] { display: none; }
.catalog-bg { position: absolute; inset: 0; background: rgba(2, 5, 12, .55); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.catalog-panel {
  position: relative;
  width: min(460px, 100%);
  padding: 30px 28px 24px;
  border-radius: 26px;
  background:
    radial-gradient(120% 70% at 0% 0%, rgba(168, 242, 58, .06), transparent 55%),
    radial-gradient(120% 80% at 100% 100%, rgba(10, 98, 244, .12), transparent 60%),
    rgba(12, 20, 38, .82);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), inset 0 0 0 1px rgba(170,220,255,.12), 0 40px 100px -30px rgba(0,0,0,.8);
}
.catalog-kicker { font-size: 14px; font-weight: 600; color: var(--cyan); }
.catalog-title { margin-top: 8px; font-size: 26px; font-weight: 600; letter-spacing: -.025em; }
.catalog-sub { margin-top: 8px; font-size: 14.5px; line-height: 1.5; color: var(--sub); }
.catalog-list { list-style: none; margin-top: 20px; display: grid; gap: 10px; }
.catalog-item {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(170, 220, 255, .1);
  color: var(--text); text-decoration: none;
  transition: background .3s, border-color .3s, transform .4s var(--ease-out);
}
.catalog-item:hover { background: rgba(255, 255, 255, .08); border-color: rgba(170, 220, 255, .25); transform: translateY(-1px); }
.catalog-item img { width: 48px; height: 48px; border-radius: 12px; flex: none; }
.ci-text { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.ci-text b { font-size: 16px; font-weight: 600; }
.ci-text small { font-size: 13px; color: var(--sub); }
.ci-go { width: 20px; height: 20px; fill: none; stroke: var(--sub); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease-out), stroke .3s; }
.catalog-item:hover .ci-go { transform: translateX(4px); stroke: var(--text); }
.catalog-note { margin-top: 18px; font-size: 13px; color: var(--faint); cursor: pointer; text-align: center; }
.catalog-note:hover { color: var(--sub); }
.catalog-on .steps { opacity: 0; pointer-events: none; }
@media (max-width: 720px) {
  .nav-dl span { display: none; }
  .nav-dl { padding: 0 9px; }
  .catalog { place-items: end stretch; padding: 0; }
  .catalog-panel { width: 100%; border-radius: 26px 26px 0 0; padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px)); }
}

/* catálogo: procurar + cartão com o nome da empresa */
.catalog-search { position: relative; display: flex; align-items: center; margin-top: 18px; }
.catalog-search svg { position: absolute; left: 14px; width: 17px; height: 17px; fill: none; stroke: var(--faint); stroke-width: 1.8; stroke-linecap: round; pointer-events: none; }
.catalog-search input {
  width: 100%; height: 44px; padding: 0 14px 0 40px;
  border-radius: 999px; border: 1px solid rgba(170, 220, 255, .14);
  background: rgba(255, 255, 255, .045); color: var(--text);
  font: inherit; font-size: 14.5px; outline: none;
  transition: border-color .3s, background .3s, box-shadow .3s;
}
.catalog-search input::placeholder { color: var(--faint); }
.catalog-search input:focus { border-color: rgba(34, 211, 238, .5); box-shadow: 0 0 0 4px rgba(34, 211, 238, .1); }
.catalog-search input::-webkit-search-cancel-button { filter: invert(1); opacity: .5; }
.catalog-list { margin-top: 14px; }
.catalog-list li[hidden] { display: none; }
.catalog-item { flex-wrap: wrap; padding: 18px 18px 16px; gap: 12px 14px; background: rgba(0, 0, 0, .35); }
.ci-logo { flex: 1; display: flex; align-items: center; min-height: 34px; }
.ci-logo img { height: 26px; width: auto; display: block; filter: drop-shadow(0 0 18px rgba(255,255,255,.18)); }
.ci-apps { order: 3; flex-basis: 100%; display: flex; align-items: center; gap: 10px; padding-top: 12px; border-top: 1px solid rgba(170, 220, 255, .08); }
.ci-apps img { width: 26px; height: 26px; border-radius: 7px; }
.ci-count { font-size: 12.5px; color: var(--sub); }
.catalog-none { margin-top: 16px; text-align: center; font-size: 14px; color: var(--sub); }
.catalog-none[hidden] { display: none; }

/* painel de contacto: o botão de enviar nunca fica cortado.
   Os campos rolam por trás; a barra do botão fica presa ao fundo do painel. */
.sheet-panel { padding-bottom: 0; }
.sheet-actions {
  position: sticky; bottom: 0; z-index: 2;
  margin: 22px -44px 0;
  padding: 16px 44px 30px;
  background: linear-gradient(to bottom, rgba(12, 19, 36, 0), rgba(12, 19, 36, .94) 26%, rgba(12, 19, 36, .98));
  border-radius: 0 0 28px 28px;
}
.sheet-done { padding-bottom: 32px; }
@media (max-height: 860px) and (min-width: 721px) {
  .sheet-panel { padding-top: 32px; }
  .sheet-title { font-size: 26px; margin-top: 8px; }
  .sheet-sub { margin-top: 6px; font-size: 14px; }
  .fields { margin-top: 18px; gap: 10px; }
  .field input, .field textarea { padding-top: 21px; padding-bottom: 7px; }
  .field textarea { min-height: 88px; padding-top: 25px; }
  .chips legend { margin-bottom: 7px; }
  .chip { padding: 6px 12px; font-size: 13px; }
  .sheet-actions { margin-top: 14px; padding-top: 12px; padding-bottom: 22px; }
  .sheet-actions .cta { height: 48px; }
}
@media (max-width: 720px) {
  .sheet-actions { margin: 16px -20px 0; padding: 14px 20px calc(18px + env(safe-area-inset-bottom, 0px)); border-radius: 0; }
  .sheet-panel { padding-bottom: 0; }
}
