/* Montra: ofício visual. Carrega depois de styles.css; só acrescenta, não reescreve. */

/* palco: luz ambiente com a cor da marca ativa + grão fino só no fundo (nunca por cima das peças) */
.am-sec {
  position: relative;
  isolation: isolate;
  overflow-x: clip;
}
.am-sec::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.045;
  mix-blend-mode: soft-light;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1.4 -.2'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}
.am-grelha {
  position: relative;
  isolation: isolate;
}
.am-grelha::before {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
  inset: -120px -8% -60px;
  background:
    radial-gradient(
      42% 38% at 58% 30%,
      rgb(var(--am-rgb, 34 227 200) / 0.11),
      transparent 72%
    ),
    radial-gradient(
      70% 22% at 50% 62%,
      rgb(var(--am-rgb, 34 227 200) / 0.05),
      transparent 70%
    );
}

/* separadores: controlo segmentado com lente de vidro líquido (estilo iOS 26) */
.js .am-tabs {
  display: inline-grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 0;
  padding: 4px;
  max-width: 100%;
  border-radius: 999px;
  background: rgba(241, 245, 244, 0.035);
  box-shadow:
    inset 0 0 0 1px rgba(241, 245, 244, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 1px 0 rgba(0, 0, 0, 0.4);
}
.js .am-tabs button {
  position: relative;
  z-index: 1;
  min-width: 0;
  min-height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: none;
  font: 500 14px/1 var(--corpo);
  letter-spacing: -0.005em;
  color: var(--cinza);
  white-space: nowrap;
}
.js .am-tabs button:hover {
  color: #c9d1cf;
  background: none;
}
.js .am-tabs button[aria-selected="true"] {
  color: var(--branco);
  background: none;
  border: 0;
}
.js .am-tabs button:focus-visible {
  outline: 2px solid var(--aqua);
  outline-offset: -2px;
}
.js .am-tabs .am-ind {
  display: none;
}
.am-lente {
  position: absolute;
  z-index: 2;
  top: 4px;
  left: 0;
  height: calc(100% - 8px);
  border-radius: 999px;
  pointer-events: none;
  transform: translateX(var(--lx, 4px));
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.065),
    rgba(255, 255, 255, 0.03)
  );
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -1px 0 rgba(255, 255, 255, 0.06),
    inset 0 0 0 1px rgba(255, 255, 255, 0.07),
    inset 0 -8px 14px -10px rgba(0, 0, 0, 0.5),
    0 6px 14px -6px rgba(0, 0, 0, 0.7);
  -webkit-backdrop-filter: saturate(1.5) brightness(1.15);
  backdrop-filter: saturate(1.5) brightness(1.15);
}
/* aresta especular de 1px: o ponto mais claro segue o rato */
.am-lente::before,
.fx-aresta::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  pointer-events: none;
  background: radial-gradient(
    120px 60px at var(--hx, 30%) 0%,
    rgba(255, 255, 255, 0.55),
    rgba(255, 255, 255, 0) 70%
  );
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

/* telemóveis: titânio escuro em vez de prata, aresta especular e reflexo no vidro que seguem o rato */
.am-grelha .tel {
  background: linear-gradient(
    90deg,
    #1d1f22 0%,
    #6d7278 2.2%,
    #34373b 5.5%,
    #3f4246 50%,
    #34373b 94.5%,
    #6d7278 97.8%,
    #1d1f22 100%
  );
  transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transform-style: preserve-3d;
  box-shadow:
    0 40px 60px -30px rgba(0, 0, 0, 0.9),
    0 18px 28px -18px rgba(0, 0, 0, 0.8);
}
.am-grelha .tel > i {
  background: linear-gradient(90deg, #2a2d31, #6a6f75 45%, #3a3e43);
}
.am-grelha .tel > .b4 {
  background: linear-gradient(270deg, #2a2d31, #6a6f75 45%, #3a3e43);
}
.am-grelha .tel.fx-aresta::before {
  z-index: 1;
  background: radial-gradient(
    160px 220px at var(--hx, 50%) var(--hy, 0%),
    rgba(255, 255, 255, 0.5),
    rgba(255, 255, 255, 0.06) 60%,
    rgba(255, 255, 255, 0.04)
  );
}
.am-grelha .vidro {
  box-shadow:
    inset 0 0 0 1px #1b1d20,
    inset 0 0 0 2px #000;
}
.am-grelha .vidro::after {
  content: "";
  position: absolute;
  inset: calc(var(--w) * 0.028);
  z-index: 8;
  border-radius: calc(var(--w) * 0.142);
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(
    70% 45% at var(--hx, 50%) var(--hy, 20%),
    rgba(255, 255, 255, 0.07),
    transparent 70%
  );
}
.am-grelha .tel-w:hover .vidro::after {
  opacity: 1;
}

/* botão de som por cima do vídeo: vidro com refração */
.am-som > span {
  background: rgba(10, 12, 12, 0.5);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1),
    0 4px 10px -4px rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(10px) saturate(1.6);
  backdrop-filter: blur(10px) saturate(1.6);
}
.am-som[aria-pressed="true"] > span {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 0 0 1px rgba(34, 227, 200, 0.45),
    0 4px 10px -4px rgba(0, 0, 0, 0.6);
}
.lg-svg .am-som > span {
  background: rgba(10, 12, 12, 0.5);
}

/* anúncio Meta dentro de uma publicação do Instagram (modo escuro) */
.fx-post {
  background: #000;
  border: 1px solid #262626;
  border-radius: 8px;
  overflow: hidden;
  color: #f5f5f5;
  font:
    13px/1.3 -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;
  box-shadow: 0 30px 50px -30px rgba(0, 0, 0, 0.9);
}
.fx-post .fx-cab {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
}
.fx-post .fx-av {
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--am-c, #333);
  color: #fff;
  font:
    600 14px/1 Georgia,
    serif;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.fx-post .fx-nm {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 1px;
}
.fx-post .fx-nm b {
  font-weight: 600;
  font-size: 13.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fx-post .fx-nm small {
  font-size: 12px;
  color: #a8a8a8;
}
.fx-post svg {
  width: 24px;
  height: 24px;
  flex: none;
  stroke: #f5f5f5;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.fx-post .fx-cab svg {
  width: 20px;
  fill: #f5f5f5;
  stroke: none;
}
.am-meta .fx-post img {
  border: 0;
  border-radius: 0;
}
.fx-post .fx-acoes {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 12px 12px;
}
.fx-post .fx-acoes .fx-gd {
  margin-left: auto;
}

/* Google: a caixa de pesquisa por cima dá o contexto de onde o anúncio aparece */
.am-g {
  border-radius: 10px;
  border-color: transparent;
  box-shadow: 0 30px 50px -30px rgba(0, 0, 0, 0.9);
}
.fx-pesq {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  margin: -4px -6px 14px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid #dfe1e5;
  color: #202124;
  font-size: 14px;
  box-shadow: 0 1px 6px rgba(32, 33, 36, 0.12);
  overflow: hidden;
}
.fx-pesq span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fx-pesq svg {
  width: 18px;
  height: 18px;
  flex: none;
}

@media (max-width: 520px) {
  .js .am-tabs {
    display: grid;
    width: 100%;
    grid-auto-columns: auto;
  }
  .js .am-tabs button {
    padding: 0 9px;
    font-size: 13px;
    letter-spacing: -0.01em;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .am-lente.liso {
    transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1);
  }
  .am-grelha .tel {
    transition: transform 200ms ease-out;
  }
  .am-grelha .tel.fx-segue {
    transition: transform 80ms linear;
  }
  .am-grelha .vidro::after {
    transition: opacity 200ms ease-out;
  }
  .js .am-tabs button {
    transition: color 150ms ease-out;
  }
}

/* todos os painéis começam colados aos separadores, não só o primeiro */
.js .am-tabs ~ .am-painel { border-top: 0; padding-top: 0; margin-top: 32px; }
