/* ============================================================
   Secções novas: guia digital do hóspede (04) e logótipos (05).
   Só acrescenta; carrega depois do story.css.
   ============================================================ */

/* ── cabeçalho comum às duas secções ── */
.xs { position: relative; margin-top: var(--section-y); padding: 0 var(--gutter); }
.xs-inner { max-width: 1200px; margin: 0 auto; }
.xs-label {
  display: inline-flex; align-items: center; gap: 10px; margin: 0 0 14px;
  padding: 5px 12px 5px 6px; border-radius: var(--r-pill); border: 1px solid var(--nav-hair); background: var(--nav-soft);
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-muted);
}
.xs-label b { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 50%; background: var(--gradient); color: #fff; font-size: 10px; font-weight: 700; letter-spacing: 0; }
.xs-title { margin: 0; font-family: var(--font-display); font-weight: 700; letter-spacing: -.02em; line-height: 1.04; font-size: clamp(32px, 3.8vw, 50px); color: var(--text); text-wrap: balance; }
.xs-lead { margin: 18px 0 0; font-size: 16px; line-height: 1.65; color: var(--text-muted); max-width: 520px; text-wrap: pretty; }

/* entrada ao chegar ao ecrã */
.xs [data-xin] { opacity: 0; transform: translateY(22px); transition: opacity var(--dur-4) var(--ease-out), transform var(--dur-4) var(--ease-out); }
.xs [data-xin].is-in { opacity: 1; transform: none; }
.xs [data-xin="2"] { transition-delay: 90ms; }
.xs [data-xin="3"] { transition-delay: 180ms; }

/* ============ 04 · GUIA DIGITAL ============ */
.gd-grid { display: grid; grid-template-columns: 1fr auto; gap: clamp(40px, 6vw, 96px); align-items: center; }
.gd-list { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; max-width: 520px; }
.gd-list li { display: grid; grid-template-columns: 34px 1fr; gap: 14px; align-items: start; }
.gd-list .ic {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  border: 1px solid var(--nav-hair); background: var(--nav-soft); color: var(--text);
}
.gd-list .ic svg { width: 17px; height: 17px; }
.gd-list b { display: block; font-size: 15px; font-weight: 650; color: var(--text); }
.gd-list span { display: block; margin-top: 2px; font-size: 13.5px; line-height: 1.55; color: var(--text-muted); }
.gd-how {
  margin: 30px 0 0; padding: 16px 18px; max-width: 520px; border-radius: var(--r-card);
  border: 1px dashed var(--nav-hair); font-size: 13.5px; line-height: 1.6; color: var(--text-muted);
}
.gd-how strong { color: var(--text); font-weight: 650; }

/* o telemóvel */
.gd-stage { position: relative; justify-self: center; }
/* 24 set 2026: a secção tem de caber inteira no ecrã. O telemóvel tem sempre o tamanho de desenho
   (380×780) e o extra.js encolhe-o por escala (--gd-k) conforme a altura da janela; o palco
   recebe a altura já encolhida para o layout acompanhar. */
.gd { min-height: calc(100vh - 72px); min-height: calc(100svh - 72px); display: flex; align-items: center; }
.gd > .xs-inner { width: 100%; }
.gd-stage .gd-phone { transform: scale(var(--gd-k, 1)); transform-origin: top center; }
.gd-stage { width: calc(380px * var(--gd-k, 1)); height: calc(780px * var(--gd-k, 1) + 34px); }
.gd-stage .gd-phone { margin-left: calc((380px * var(--gd-k, 1) - 380px) / 2); }
.gd-stage .gd-caption { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); margin: 0; white-space: nowrap; }
.gd-phone {
  --pw: 380px; --ph: 780px;
  position: relative; width: var(--pw); height: var(--ph); padding: 12px; border-radius: 54px;
  background: linear-gradient(145deg, #2a2b31, #111216 55%, #26272c);
  box-shadow: 0 0 0 1.5px rgba(255,255,255,.07) inset, 0 40px 90px rgba(0,0,0,.45), 0 12px 30px rgba(0,0,0,.25);
}
html[data-theme="light"] .gd-phone { box-shadow: 0 0 0 1.5px rgba(255,255,255,.07) inset, 0 40px 80px rgba(139,47,224,.22), 0 12px 30px rgba(24,6,26,.18); }
.gd-phone::before { /* botões laterais */
  content: ""; position: absolute; right: -3px; top: 180px; width: 3px; height: 74px; border-radius: 0 3px 3px 0; background: #1b1c20;
}
.gd-screen { position: relative; width: 100%; height: 100%; border-radius: 42px; overflow: hidden; background: #F6F3EC; isolation: isolate; }
.gd-screen iframe { display: block; width: 100%; height: 100%; border: 0; }
.gd-island { position: absolute; z-index: 3; top: 11px; left: 50%; width: 96px; height: 27px; margin-left: -48px; border-radius: 20px; background: #0a0a0c; pointer-events: none; }

/* guia "adormecido": enquanto não se toca, o iframe não recebe gestos, e o scroll por cima do
   telemóvel desce a página. Um toque acorda-o (e já carrega no botão tocado); sai-se pelo botão
   "Sair do guia", ao tirar o rato, ao tocar fora ou quando a secção sai do ecrã. */
.gd-screen iframe { pointer-events: none; }
.gd-phone.is-live .gd-screen iframe { pointer-events: auto; }
.gd-lock { position: absolute; inset: 0; z-index: 2; border: 0; padding: 0; background: transparent; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.gd-phone.is-live .gd-lock { display: none; }
.gd-lock::after {
  content: attr(data-label); position: absolute; left: 50%; bottom: 22px; transform: translate(-50%, 8px);
  padding: 8px 14px; border-radius: var(--r-pill); background: rgba(10,12,24,.82); color: #fff; white-space: nowrap;
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); opacity: 0; transition: opacity var(--dur-2), transform var(--dur-2) var(--ease-out);
}
.gd-phone { transition: box-shadow var(--dur-3) var(--ease-out); }
.gd-phone.is-live { box-shadow: 0 0 0 1.5px rgba(255,255,255,.07) inset, 0 0 0 3px rgba(255,40,120,.55), 0 40px 90px rgba(0,0,0,.45), 0 0 60px rgba(255,40,120,.18); }
.gd-exit {
  position: absolute; z-index: 5; left: 50%; bottom: 18px; transform: translate(-50%, 14px); opacity: 0; pointer-events: none;
  display: inline-flex; align-items: center; gap: 7px; padding: 9px 15px 9px 12px; border: 1px solid rgba(255,255,255,.14); border-radius: var(--r-pill);
  background: rgba(10,12,24,.84); color: #fff; cursor: pointer; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase;
  box-shadow: 0 10px 30px rgba(0,0,0,.35); transition: opacity var(--dur-2), transform var(--dur-3) var(--ease-out);
}
.gd-exit svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.gd-phone.is-live .gd-exit { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; transition-delay: .25s; }
.gd-exit:active { transform: translate(-50%, 0) scale(.96); }

/* ajuda: seta + anel de toque. Some ao primeiro toque dentro do guia. */
.gd-hint { position: absolute; inset: 0; pointer-events: none; z-index: 4; transition: opacity var(--dur-3) var(--ease-mid); }
.gd-hint.is-gone, .gd-phone.is-live .gd-hint { opacity: 0; }
.gd-ring {
  position: absolute; left: var(--hx, 26%); top: var(--hy, 56%); width: 54px; height: 54px; margin: -27px 0 0 -27px; border-radius: 50%;
}
.gd-ring::before, .gd-ring::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid #FF2878;
  animation: gdPulse 1.8s var(--ease-out) infinite;
}
.gd-ring::after { animation-delay: .6s; }
.gd-ring i { position: absolute; inset: 17px; border-radius: 50%; background: #FF2878; box-shadow: 0 0 0 4px rgba(255,40,120,.25); animation: gdTap 1.8s ease-in-out infinite; }
@keyframes gdPulse { 0% { transform: scale(.45); opacity: .95; } 100% { transform: scale(1.5); opacity: 0; } }
@keyframes gdTap { 0%, 100% { transform: scale(1); } 12% { transform: scale(.72); } 26% { transform: scale(1); } }

.gd-arrow {
  position: absolute; left: calc(var(--hx, 28%) - 26px); top: calc(var(--hy, 57%) - 20px);
  transform: translate(-100%, -100%); color: var(--text);
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
}
.gd-arrow-t {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap;
  padding: 7px 12px; border-radius: var(--r-pill); background: var(--gradient); color: #fff; box-shadow: var(--shadow-btn);
  animation: gdBob 2.4s ease-in-out infinite;
}
.gd-arrow svg { width: 210px; height: 130px; overflow: visible; }
.gd-arrow path { fill: none; stroke: #FF2878; filter: drop-shadow(0 1px 2px rgba(0,0,0,.35)); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 260; stroke-dashoffset: 260; }
/* a seta desenha-se de trás para a frente */
.gd-stage.is-in .gd-arrow path { animation: gdDraw 1.1s var(--ease-out) .5s forwards; }
.gd-stage.is-in .gd-arrow path + path { animation-delay: 1.35s; animation-duration: .4s; }
@keyframes gdDraw { to { stroke-dashoffset: 0; } }
@keyframes gdBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }

.gd-caption { margin: 18px 0 0; text-align: center; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); }

/* ecrãs baixos: o texto aperta para caber ao lado do telemóvel */
@media (min-width: 901px) and (max-height: 880px) {
  .gd .xs-label { margin-bottom: 10px; }
  .gd .xs-title { font-size: clamp(28px, 3.1vw, 42px); }
  .gd .xs-lead { margin-top: 12px; font-size: 15px; line-height: 1.55; }
  .gd-list { margin-top: 18px; gap: 10px; }
  .gd-list span { font-size: 13px; line-height: 1.45; }
  .gd-how { margin-top: 16px; padding: 12px 14px; font-size: 13px; line-height: 1.5; }
}
@media (min-width: 901px) and (max-height: 720px) {
  .gd-list li:nth-child(n+3) { display: none; }
}
@media (max-width: 900px) {
  .gd { min-height: 0; display: block; }
  .gd-grid, .lg-grid { grid-template-columns: minmax(0, 1fr); }
  .gd-stage { margin-top: 24px; }
  .gd-arrow { left: calc(var(--hx, 28%) + 6px); transform: translate(0, -100%); align-items: flex-end; }
  .gd-arrow svg { transform: scaleX(-1); margin: 0 24px 0 0; width: 120px; height: 90px; }
}
@media (max-width: 600px) {
}

/* ============ 05 · LOGÓTIPOS (caso real: Under the Palms) ============ */
.lg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 96px); align-items: center; }
.lg-side { position: relative; display: grid; gap: 14px; justify-items: center; }
.lg-board {
  --cal: #FDFAF4; --cobalto: #0E4C86;
  position: relative; aspect-ratio: 1 / 1; max-width: 520px; width: 100%;
  border-radius: 28px; background: var(--cal); color: var(--cobalto);
  display: grid; place-items: center; overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,.35);
}
.lg-board::before { /* grelha de construção */
  content: ""; position: absolute; inset: 0; opacity: .5;
  background:
    linear-gradient(rgba(14,76,134,.10) 1px, transparent 1px) 0 0 / 40px 40px,
    linear-gradient(90deg, rgba(14,76,134,.10) 1px, transparent 1px) 0 0 / 40px 40px;
  mask-image: radial-gradient(circle at 50% 45%, #000 30%, transparent 75%);
}
.lg-mark { position: relative; width: 56%; height: auto; overflow: visible; margin-top: -8%; }
.lg-mark .guide { fill: none; stroke: rgba(14,76,134,.45); stroke-width: .35; stroke-dasharray: 1.4 1.4; opacity: 0; transition: opacity var(--dur-3); }
.lg-board.is-in .lg-mark .guide { opacity: 1; }
.lg-mark .part { fill: currentColor; transition: opacity var(--dur-2), fill var(--dur-2); }
/* a palmeira cresce de baixo para cima; a casa assenta */
.lg-mark .p-palm { clip-path: inset(100% 0 0 0); }
.lg-mark .p-house { opacity: 0; transform: translateY(6px); transition: opacity .6s var(--ease-out), transform .6s var(--ease-out); }
.lg-board.is-in .p-house { opacity: 1; transform: none; transition-delay: .3s; }
.lg-board.is-in .p-palm { animation: lgGrow 1.5s var(--ease-out) .8s forwards; }
@keyframes lgGrow { to { clip-path: inset(0 0 0 0); } }
.lg-board[data-focus] .part { opacity: .16; }
.lg-board[data-focus="palm"] .p-palm, .lg-board[data-focus="house"] .p-house { opacity: 1; }
.lg-board[data-focus="cor"] .part { opacity: 1; }
.lg-board[data-focus="cor"] { box-shadow: 0 0 0 3px var(--cobalto), 0 30px 80px rgba(0,0,0,.35); }
.lg-name {
  position: absolute; left: 0; right: 0; bottom: 9%; text-align: center; font-family: var(--font-display); font-weight: 700;
  font-size: clamp(18px, 2.1vw, 26px); letter-spacing: .02em; color: var(--cobalto);
  opacity: 0; transform: translateY(8px); transition: opacity var(--dur-4) var(--ease-out) 2.1s, transform var(--dur-4) var(--ease-out) 2.1s;
}
.lg-name small { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: rgba(14,76,134,.6); font-weight: 400; }
.lg-board.is-in .lg-name { opacity: 1; transform: none; }
.lg-case { margin: 0; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); text-align: center; }

.lg-steps { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 10px; counter-reset: lg; }
.lg-steps > li { padding: 16px 18px; border-radius: var(--r-card); border: 1px solid var(--nav-hair); background: var(--nav-soft); }
.lg-steps h3 { margin: 0; font-size: 15px; font-weight: 650; color: var(--text); display: flex; gap: 10px; align-items: baseline; }
.lg-steps h3::before { counter-increment: lg; content: "0" counter(lg); font-family: var(--font-mono); font-size: 11px; color: var(--text-dim); font-weight: 400; }
.lg-steps p { margin: 6px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--text-muted); }
.lg-steps q { color: var(--text); font-style: italic; }
.lg-steps s { color: var(--text-dim); text-decoration-thickness: 1.5px; }
.lg-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.lg-chip {
  font: inherit; font-size: 12.5px; font-weight: 600; color: var(--text); cursor: pointer; text-align: left;
  padding: 7px 12px; border-radius: var(--r-pill); border: 1px solid var(--nav-hair); background: var(--bg);
  transition: border-color var(--dur-2), transform var(--dur-1);
}
.lg-chip:hover, .lg-chip:focus-visible, .lg-chip.is-on { border-color: #FF2878; }
.lg-chip:active { transform: scale(.97); }
.lg-chip em { font-style: normal; font-weight: 400; color: var(--text-muted); }

/* grande reduzido contra desenho pequeno, em tamanho real */
.lg-sizes { display: grid; grid-template-columns: auto repeat(3, 1fr); gap: 8px 10px; align-items: center; margin-top: 12px; padding: 12px; border-radius: 14px; background: #FDFAF4; color: #0E4C86; }
.lg-sizes span { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .08em; text-transform: uppercase; color: rgba(14,76,134,.65); }
.lg-sizes .row-h { grid-column: 1; }
.lg-sizes .bad { color: #B03A62; } .lg-sizes .good { color: #12786B; }
.lg-sizes i { display: grid; place-items: center; }
.lg-sizes svg { display: block; fill: currentColor; }
.lg-sizes .hdr { text-align: center; }

.lg-kit { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 10px; }
.lg-kit figure { margin: 0; aspect-ratio: 1; border-radius: 14px; display: grid; place-items: center; border: 1px solid var(--nav-hair); position: relative; }
.lg-kit figure svg { width: 50%; height: auto; fill: currentColor; margin-top: -10%; }
.lg-kit figcaption { position: absolute; bottom: 6px; left: 0; right: 0; text-align: center; font-family: var(--font-mono); font-size: 8.5px; letter-spacing: .1em; text-transform: uppercase; }
.lg-kit .k1 { background: #FDFAF4; color: #0E4C86; }
.lg-kit .k2 { background: #0E4C86; color: #FDFAF4; }
.lg-kit .k3 { background: #F2ECE1; color: #12786B; }
.lg-kit .k4 { background: var(--bg); }
.lg-kit .k4 b { width: 38%; aspect-ratio: 44 / 40; border-radius: 22%; background: #0E4C86; display: grid; place-items: center; margin-top: -10%; }
.lg-kit .k4 b svg { width: 72%; margin: 0; fill: #FDFAF4; }
.lg-kit .k1 figcaption, .lg-kit .k3 figcaption { color: rgba(14,76,134,.6); }
.lg-kit .k2 figcaption { color: rgba(253,250,244,.65); }
.lg-kit .k4 figcaption { color: var(--text-dim); }

.lg-copy .lg-chips { margin-top: 24px; }
.lg-copy .lg-kit { margin-top: 28px; }
.lg-kit-cap { margin: 12px 0 0; font-size: 13.5px; color: var(--text-muted); }
.lg-note { margin: 18px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--text-muted); }
.lg-note strong { color: var(--text); }

@media (max-width: 900px) {
  .lg-grid { grid-template-columns: minmax(0, 1fr); }
  .lg-side { position: relative; top: 0; }
  .lg-board { max-width: 420px; }
}
@media (max-width: 480px) { .lg-kit { grid-template-columns: repeat(2, 1fr); } }

@media (prefers-reduced-motion: reduce) {
  .xs [data-xin] { opacity: 1; transform: none; transition: none; }
  .gd-ring::before, .gd-ring::after, .gd-ring i, .gd-arrow-t { animation: none; }
  .gd-arrow path { stroke-dashoffset: 0 !important; animation: none !important; }
  .lg-mark .p-palm { clip-path: none; animation: none; }
  .lg-mark .p-house { opacity: 1; transform: none; transition: none; }
  .lg-name { opacity: 1; transform: none; transition: none; }
}


/* ============ 06 · MISSÃO (no lugar dos cartões de serviços) ============ */
.mission .services-inner { max-width: 820px; margin: 0 auto; }
.mission-label { margin-bottom: 20px; }
.mission .mission-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(34px, 4.6vw, 60px); line-height: 1.04; letter-spacing: -.025em; max-width: none; text-wrap: balance; }
.mission .mission-text { max-width: 680px; margin-top: 28px; font-size: 17px; line-height: 1.7; color: var(--text); text-wrap: pretty; }
.mission .mission-seo { max-width: 680px; margin-top: 22px; padding-top: 22px; border-top: 1px solid var(--nav-hair); font-size: 13.5px; line-height: 1.7; color: var(--text-dim); }
@media (max-width: 600px) { .mission .mission-text { font-size: 15.5px; } .mission-title br { display: none; } }

/* ============ PÁGINAS DE SERVIÇO (animacoes/, videos/, guias/, identidade/) ============ */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .35s; }
.pg-main { padding-top: 88px; }
.pg-main > .xs:first-child, .pg-main > section:first-child { margin-top: 0; }
.pg-how { margin-top: clamp(56px, 7vw, 96px); }
.pg-how-title { margin: 0 0 22px; font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 2.8vw, 36px); letter-spacing: -.02em; color: var(--text); }
.pg-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.pg-steps li { padding: 22px 22px 24px; border-radius: var(--r-card); border: 1px solid var(--nav-hair); background: var(--nav-soft); }
.pg-steps b { display: block; font-family: var(--font-mono); font-size: 11px; font-weight: 400; color: var(--text-dim); margin-bottom: 14px; }
.pg-steps h3 { margin: 0; font-size: 16px; font-weight: 650; color: var(--text); }
.pg-steps p { margin: 8px 0 0; font-size: 14px; line-height: 1.6; color: var(--text-muted); }
@media (max-width: 800px) { .pg-steps { grid-template-columns: 1fr; } }
.pg-next { max-width: 1200px; margin: clamp(56px, 7vw, 96px) auto 0; padding: 0 var(--gutter) clamp(64px, 8vw, 112px); text-align: center; } /* espaço livre por baixo, antes do rodapé */
.pg-next-t { margin: 0 0 14px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--text-dim); }
.pg-next-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.pg-next-list a {
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: var(--r-pill);
  border: 1px solid var(--nav-hair); background: var(--nav-soft); color: var(--text); text-decoration: none;
  font-family: var(--font-display); font-weight: 700; font-size: 17px; transition: border-color var(--dur-2), transform var(--dur-2) var(--ease-out);
}
.pg-next-list a::after { content: "→"; font-family: var(--font); font-weight: 400; color: var(--text-dim); transition: transform var(--dur-2) var(--ease-out); }
.pg-next-list a:hover { border-color: #FF2878; transform: translateY(-2px); }
.pg-next-list a:hover::after { transform: translateX(3px); }
/* roda dos ofícios: as etiquetas são ligações */
a.ofc-tag { text-decoration: none; pointer-events: auto; transition: color var(--dur-2); }
a.ofc-tag::after { content: " →"; }
a.ofc-tag:hover { color: var(--text); }
/* na página dos vídeos o título tem de estar à vista logo ao abrir (na inicial entrava com o scroll) */
.pg-videos .wt-title .t-in { transform: none !important; opacity: 1 !important; }

/* ============ HEADER (24 set 2026): mais legível e sempre à vista ============ */
.header.is-hidden { transform: translate3d(0, 0, 0); }              /* já não se esconde ao descer */
html[data-theme="dark"] .header { background: rgba(5, 6, 14, .9); border-bottom: 1px solid rgba(255, 255, 255, .08); }
.main-nav { gap: 4px; padding: 5px; }
.main-nav a { font-size: 14px; padding: 8px 15px; color: var(--text); opacity: .72; transition: opacity var(--dur-2), background var(--dur-2); }
.main-nav a:hover { opacity: 1; }
.main-nav a.is-active { opacity: 1; }
.btn-contact { white-space: nowrap; }
/* ecrãs médios: o símbolo SP fica, o nome por extenso sai, para o menu respirar */
@media (min-width: 1240px) and (max-width: 1599px) {
  .header .logo-mark { display: none; }
  .main-nav { margin: 0 12px; }
  .main-nav a { padding: 8px 12px; font-size: 13.5px; }
}

/* roda dos ofícios: botão "Saber mais" que acompanha o ofício à frente */
.ofc-more { margin: 0 0 22px; align-self: flex-start; }
.ofc-copy { display: flex; flex-direction: column; align-items: flex-start; }
.ofc-copy > .ofc-words, .ofc-copy > .ofc-label { align-self: stretch; }
.ofc-copy > .ofc-label { align-self: flex-start; }
@media (max-width: 999px) { .ofc-more { margin: 4px 0 14px; padding: 10px 16px; font-size: 14px; } }

/* ============ MONTRA DAS PÁGINAS DE SERVIÇO (página inicial) ============ */
.hub { margin-top: var(--section-y); }
.hub-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 34px; }
.hub-card {
  display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden; text-decoration: none;
  border: 1px solid var(--nav-hair); background: var(--nav-soft); color: var(--text);
  transition: transform var(--dur-3) var(--ease-out), border-color var(--dur-2), box-shadow var(--dur-3);
}
.hub-card:hover { transform: translateY(-4px); border-color: rgba(255, 40, 120, .55); box-shadow: 0 24px 60px rgba(0, 0, 0, .35); }
.hub-media { display: block; aspect-ratio: 4 / 3; overflow: hidden; background: #0b0d1c; }
.hub-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform var(--dur-4) var(--ease-out); }
.hub-media img.hub-top { object-position: top; }
.hub-card:hover .hub-media img { transform: scale(1.04); }
.hub-logo { display: grid; place-items: center; width: 100%; height: 100%; background: #FDFAF4; color: #0E4C86; }
.hub-logo svg { width: 46%; height: auto; fill: currentColor; }
.hub-body { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px 18px; flex: 1; }
.hub-body b { font-family: var(--font-display); font-weight: 700; font-size: 20px; letter-spacing: -.01em; }
.hub-d { font-size: 13.5px; line-height: 1.5; color: var(--text-muted); flex: 1; }
.hub-go { margin-top: 8px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--text-dim); transition: color var(--dur-2); }
.hub-go::after { content: " →"; }
.hub-card:hover .hub-go { color: #FF2878; }
@media (max-width: 1000px) { .hub-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .hub-grid { grid-template-columns: 1fr 1fr; gap: 10px; } .hub-body { padding: 12px 12px 14px; } .hub-body b { font-size: 16px; } .hub-d { font-size: 12.5px; } }

/* ============ LABORATÓRIO: setas e janelas clicáveis (24 set 2026) ============ */
.lab-pin { position: relative; }
.lab-arrows { position: absolute; left: 0; right: 0; top: var(--lab-ay, 50%); height: 0; z-index: 6; pointer-events: none; }
.lab-arrow {
  position: absolute; top: 0; width: 52px; height: 52px; margin-top: -26px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer; pointer-events: auto; color: #fff;
  border: 1px solid rgba(255, 255, 255, .18); background: rgba(10, 12, 24, .72);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .35);
  transition: opacity var(--dur-2), transform var(--dur-2) var(--ease-out), border-color var(--dur-2), background var(--dur-2);
  -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
.lab-arrow svg { width: 22px; height: 22px; }
.lab-arrow--prev { left: calc(50% - var(--lab-cw, 700px) / 2 - 76px); }
.lab-arrow--next { right: calc(50% - var(--lab-cw, 700px) / 2 - 76px); }
@media (any-hover: hover) { .lab-arrow:hover { border-color: #FF2878; background: rgba(255, 40, 120, .22); transform: scale(1.06); } }
.lab-arrow:active { transform: scale(.94); }
.lab-arrow:focus-visible { outline: 2px solid #38E1FF; outline-offset: 3px; }
.lab-arrow.is-off { opacity: 0; pointer-events: none; }
/* a animação seguinte (ao lado) também se clica */
.lab-card.is-side { cursor: pointer; }
.lab-card.is-side .lab-win { transition: box-shadow var(--dur-2), outline-color var(--dur-2); outline: 1px solid transparent; }
@media (any-hover: hover) { .lab-card.is-side:hover .lab-win { outline-color: rgba(255, 40, 120, .6); box-shadow: 0 0 0 4px rgba(255, 40, 120, .12); } }
/* telemóvel e ecrãs estreitos: setas por cima das margens da janela, alvos de 44 px */
@media (max-width: 899px) {
  .lab-arrow { width: 44px; height: 44px; margin-top: -22px; }
  .lab-arrow svg { width: 19px; height: 19px; }
  .lab-arrow--prev { left: 8px; }
  .lab-arrow--next { right: 8px; }
}
/* ecrãs largos mas com pouco espaço ao lado da janela: setas por dentro */
@media (min-width: 900px) and (max-width: 1100px) {
  .lab-arrow--prev { left: max(12px, calc(50% - var(--lab-cw, 700px) / 2 - 64px)); }
  .lab-arrow--next { right: max(12px, calc(50% - var(--lab-cw, 700px) / 2 - 64px)); }
}

/* ============ PÁGINA DOS VÍDEOS: janela maior (24 set 2026) ============ */
.pg-videos .wt-frame {
  width: min(1180px, 84vw, calc((100vh - 390px) * 1.7778));
  width: min(1180px, 84vw, calc((100svh - 390px) * 1.7778));
}
@media (max-width: 900px) {
  /* telemóvel: a janela ocupa a largura útil e não passa da margem; o leque de fotos sai */
  .pg-videos .wt-stage { padding: 0 16px; }
  .pg-videos .wt-frame { width: 100%; min-width: 0; max-width: calc((100svh - 240px) * 1.7778); }
  .pg-videos .wt-photos { display: none; }
}

/* ============ POLÍTICA DE PRIVACIDADE ============ */
.legal { max-width: 760px; margin: 0 auto; padding: 24px var(--gutter) 0; color: var(--text-muted); font-size: 15.5px; line-height: 1.75; }
.legal-title { margin: 0; font-family: var(--font-display); font-weight: 700; font-size: clamp(34px, 4.4vw, 54px); letter-spacing: -.02em; line-height: 1.05; color: var(--text); }
.legal-date { margin: 12px 0 34px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim); }
.legal h2 { margin: 40px 0 10px; font-family: var(--font-display); font-weight: 700; font-size: 21px; letter-spacing: -.01em; color: var(--text); }
.legal p { margin: 0 0 14px; }
.legal ul { margin: 0 0 14px; padding-left: 20px; }
.legal li { margin: 0 0 8px; }
.legal strong { color: var(--text); font-weight: 650; }
.legal a { color: var(--text); text-underline-offset: 3px; }
.footer-nav { display: flex; gap: 18px; flex-wrap: wrap; justify-content: center; }
/* uma política por língua: mostra-se a da língua ativa */
html:not([lang="en"]) .legal[lang="en"], html[lang="en"] .legal[lang="pt"] { display: none; }
/* menu de ecrã inteiro com 8 entradas: a cascata de entrada continua até ao fim */
.menu-overlay.is-open li:nth-child(7) .menu-link { transition-delay: .43s; }
.menu-overlay.is-open li:nth-child(8) .menu-link { transition-delay: .48s; }
.menu-overlay.is-open li:nth-child(6) .menu-link { transition-delay: .38s; }

/* ============ HEADER NO TELEMÓVEL (24 set 2026, pedido do Pedro) ============
   PT/EN logo a seguir ao logótipo; à direita "Falar connosco" e depois o menu */
@media (max-width: 1239px) {
  .header-nav { flex: 1; margin-left: 12px; }
  .header-nav .lang-switcher { order: 0; margin-right: auto; }
  .header-nav .btn-contact { order: 1; }
  .header-nav .menu-btn { order: 2; }
}
/* laboratório no telemóvel (24 set 2026): janela centrada à largura útil; ecrãs baixos apertam o texto */
.lab-solo .lab-track { padding-left: 16px; padding-right: 16px; }
.lab-solo .lab-card { justify-self: center; }
.lab-tight .lab-lead { display: none; }
.lab-tight .lab-title { font-size: clamp(26px, 7.6vw, 34px); }
.lab-tight .lab-label { margin-bottom: 10px; }
.lab-tight .lab-pin { padding-top: 64px; }
.lab-xtight .lab-rail { display: none; }
