/* ============================================================
   Laboral Estética Dental — Home (institucional premium)
   Self-contained (loaded only by index.html). Paleta da logo:
   azul institucional #166596 + branco + tons claros.
   ============================================================ */

/* ---- Shiny button @property vars ---- */
@property --gradient-angle {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}
@property --gradient-angle-offset {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}
@property --gradient-percent {
  syntax: "<percentage>";
  initial-value: 5%;
  inherits: false;
}
@property --gradient-shine {
  syntax: "<color>";
  initial-value: white;
  inherits: false;
}

@keyframes gradient-angle { to { --gradient-angle: 360deg; } }
/* CTA light button — pulso de borda */
@keyframes btn-border-pulse {
  0%, 100% { box-shadow: 0 1px 0 rgba(255,255,255,0.75) inset, 0 0 0 1.5px rgba(255,255,255,0.28), var(--shadow-pop); }
  50%       { box-shadow: 0 1px 0 rgba(255,255,255,0.75) inset, 0 0 0 1.5px rgba(255,255,255,0.7), 0 0 22px rgba(255,255,255,0.18), var(--shadow-pop); }
}

:root {
  --blue: #166596;
  --blue-deep: #0e4f76;
  --blue-bright: #166596;
  --navy: #0c3a59;
  --ink: #143a52;
  --body: #5f7682;
  --soft: #eef4f8;
  --soft-2: #f6fafc;
  --line: #e0eaf1;
  --white: #ffffff;

  --shell: min(1200px, calc(100vw - 48px));
  /* Altura padrão das heros das páginas internas (sobre, contato,
     soluções, portfólio, fluxo). A home usa a hero fullscreen própria. */
  --hero-pad: clamp(150px, 16vw, 215px) 0 clamp(110px, 12vw, 168px);
  --hero-min: clamp(600px, 92vh, 840px);
  --r: 16px;
  --pill: 999px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-card: 0 18px 40px rgba(12, 52, 82, 0.08);
  --shadow-pop: 0 14px 30px rgba(8, 40, 66, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  background-color: var(--navy); /* fundo escuro visível durante navegação — elimina flash branco */
  overflow-x: hidden; /* fallback navegadores antigos */
  overflow-x: clip; /* trava scroll horizontal mesmo quando um filho posicionado vaza (iOS) */
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  overflow-x: clip;
  max-width: 100%;
  background: var(--white);
  color: var(--ink);
  font-family: "Poppins", system-ui, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

img {
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  cursor: pointer;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.1;
}

p {
  margin: 0;
}

::selection {
  background: rgba(22, 101, 150, 0.2);
}

.lab-shell {
  width: var(--shell);
  margin: 0 auto;
}

/* ---- Buttons -------------------------------------------------------- */

.lab-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 28px;
  border: 1.5px solid transparent;
  border-radius: var(--pill);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  white-space: nowrap;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.lab-btn .lab-ic {
  width: 18px;
  height: 18px;
  transition: transform 0.25s var(--ease);
}

.lab-btn:hover {
  transform: translateY(-2px);
}

.lab-btn:hover .lab-ic {
  transform: translateX(3px);
}

.lab-btn--ghost {
  background: var(--white);
  color: var(--blue);
  box-shadow: var(--shadow-pop);
}

.lab-btn--ghost:hover {
  box-shadow: 0 18px 40px rgba(8, 40, 66, 0.28);
}

.lab-btn--light {
  background: var(--white);
  color: var(--blue);
  animation: btn-border-pulse 2.8s ease-in-out infinite;
}

.lab-btn--light:hover {
  animation: none;
  box-shadow: 0 1px 0 rgba(255,255,255,0.75) inset, 0 0 0 1.5px rgba(255,255,255,0.7), 0 18px 40px rgba(8,40,66,0.28);
}

.lab-btn--solid {
  background: var(--white);
  color: var(--blue);
  border-color: var(--line);
  box-shadow: 0 10px 26px rgba(8, 40, 66, 0.08);
}

.lab-btn--solid:hover {
  border-color: var(--blue);
}

/* contorno claro — botão secundário sobre fundos escuros/azuis */
.lab-btn--outline {
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.42);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.15) inset;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.lab-btn--outline:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.7);
}

/* preenchido azul — ação primária (shiny effect) */
.lab-btn--fill {
  --shiny-highlight: rgba(255, 255, 255, 0.88);
  --shiny-highlight-subtle: rgba(160, 210, 240, 0.85);
  --duration: 3s;
  --shadow-size: 2px;
  --ease-shiny: 800ms cubic-bezier(0.25, 1, 0.5, 1);

  isolation: isolate;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(140deg, var(--blue-bright), var(--blue-deep)) padding-box,
    conic-gradient(
      from calc(var(--gradient-angle) - var(--gradient-angle-offset)),
      transparent,
      var(--shiny-highlight)      var(--gradient-percent),
      var(--gradient-shine)       calc(var(--gradient-percent) * 2),
      var(--shiny-highlight)      calc(var(--gradient-percent) * 3),
      transparent                 calc(var(--gradient-percent) * 4)
    ) border-box;
  color: var(--white);
  box-shadow:
    inset 0 0 0 1px rgba(22, 101, 150, 0.5),
    0 12px 26px rgba(22, 101, 150, 0.32);
  transition-property: --gradient-angle-offset, --gradient-percent, --gradient-shine, transform, box-shadow;
  transition-duration: var(--ease-shiny), var(--ease-shiny), var(--ease-shiny), 0.25s, 0.25s;
  transition-timing-function: cubic-bezier(0.25,1,0.5,1);
  animation:
    gradient-angle linear var(--duration) infinite,
    gradient-angle linear calc(var(--duration) / 0.4) reverse paused;
  animation-composition: add;
}

/* Dots pattern */
.lab-btn--fill::before {
  content: "";
  pointer-events: none;
  position: absolute;
  inset-inline-start: 50%;
  inset-block-start: 50%;
  translate: -50% -50%;
  z-index: -1;
  width: calc(100% - var(--shadow-size) * 3);
  height: calc(100% - var(--shadow-size) * 3);
  background: radial-gradient(circle at 2px 2px, white 0.5px, transparent 0) padding-box;
  background-size: 4px 4px;
  background-repeat: space;
  mask-image: conic-gradient(
    from calc(var(--gradient-angle) + 45deg),
    black,
    transparent 10% 90%,
    black
  );
  border-radius: inherit;
  opacity: 0.35;
  animation:
    gradient-angle linear var(--duration) infinite,
    gradient-angle linear calc(var(--duration) / 0.4) reverse paused;
  animation-composition: add;
}


/* Span glow */
.lab-btn--fill > span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  position: relative;
  z-index: 1;
}

/* Hover: expande o arco de luz e acelera a animação */
.lab-btn--fill:is(:hover, :focus-visible) {
  --gradient-percent: 20%;
  --gradient-angle-offset: 95deg;
  --gradient-shine: var(--shiny-highlight-subtle);
  box-shadow:
    inset 0 0 0 1px rgba(22, 101, 150, 0.5),
    0 16px 34px rgba(22, 101, 150, 0.42);
}

.lab-btn--fill:is(:hover, :focus-visible),
.lab-btn--fill:is(:hover, :focus-visible)::before {
  animation-play-state: running, running;
}

.lab-btn--fill:active {
  translate: 0 1px;
}

.lab-btn--full {
  width: 100%;
  justify-content: center;
}

/* grupo de botões (ex.: dois CTAs lado a lado) */
.lab-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

/* ---- Section heads -------------------------------------------------- */

.lab-head h2 {
  text-transform: uppercase;
  color: var(--ink);
  font-size: clamp(1.5rem, 2.7vw, 2.15rem);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.lab-head p {
  margin-top: 10px;
  color: var(--body);
  font-size: clamp(1rem, 1.4vw, 1.12rem);
}

.lab-head--center {
  text-align: center;
  margin: 0 auto clamp(40px, 5vw, 66px);
}

/* ---- Circular seal -------------------------------------------------- */

.seal {
  width: 100%;
  height: auto;
  color: currentColor;
}

.seal text {
  fill: currentColor;
  font-family: "Poppins", sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 2.5px;
}

.seal-ring {
  transform-origin: 100px 100px;
  animation: seal-spin 26s linear infinite;
}

.seal-gem {
  color: currentColor;
}

@keyframes seal-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---- Header --------------------------------------------------------- */

.lab-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease), backdrop-filter 0.3s var(--ease);
}

.lab-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 86px;
  transition: min-height 0.3s var(--ease);
}

/* navbar fica sólida logo após o início do scroll (80px) */
.lab-header.is-stuck {
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  backdrop-filter: blur(18px) saturate(1.6);
  box-shadow: 0 1px 0 rgba(22, 101, 149, 0.08), 0 6px 26px rgba(12, 52, 82, 0.09);
}

.lab-header.is-stuck .lab-header-inner {
  min-height: 68px;
}

.lab-header.is-stuck .lab-brand {
  color: var(--ink);
}

.lab-header.is-stuck .lab-mark {
  color: var(--blue);
}

.lab-header.is-stuck .lab-word em {
  color: var(--body);
  opacity: 1;
}

.lab-header.is-stuck .nav-links > a:not(.lab-nav-cta) {
  color: var(--ink);
  opacity: 1;
}

.lab-header.is-stuck .nav-links > a:not(.lab-nav-cta):hover,
.lab-header.is-stuck .nav-links > a.is-active {
  color: var(--blue);
}

.lab-header.is-stuck .lab-nav-cta {
  background: var(--blue);
  color: var(--white);
  box-shadow: 0 8px 20px rgba(22, 101, 150, 0.3);
}

.lab-header.is-stuck .lab-nav-cta:hover {
  background: var(--blue-deep);
}

.lab-header.is-stuck .nav-toggle {
  background: rgba(22, 101, 150, 0.08);
  border-color: rgba(22, 101, 150, 0.25);
}

.lab-header.is-stuck .nav-toggle:hover {
  background: rgba(22, 101, 150, 0.15);
}

.lab-header.is-stuck .nav-toggle span {
  background: var(--ink);
}

.lab-brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  color: var(--white);
}

.lab-mark {
  width: 36px;
  height: 40px;
  color: currentColor;
  flex: none;
}

.lab-word {
  display: grid;
  line-height: 1;
}

.lab-word strong {
  font-weight: 500;
  font-size: 1.32rem;
  letter-spacing: 0.3em;
}

.lab-word em {
  margin-top: 5px;
  font-style: normal;
  font-size: 0.56rem;
  font-weight: 400;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  opacity: 0.82;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-links > a:not(.lab-nav-cta) {
  position: relative;
  color: var(--white);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 0;
  opacity: 0.92;
  transition: opacity 0.2s var(--ease);
}

.nav-links > a:not(.lab-nav-cta)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}

.nav-links > a:not(.lab-nav-cta):hover,
.nav-links > a.is-active {
  opacity: 1;
}

.nav-links > a.is-active::after,
.nav-links > a:not(.lab-nav-cta):hover::after {
  transform: scaleX(1);
}

.lab-nav-cta {
  text-transform: uppercase;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  padding: 11px 20px;
}

.lab-nav-cta .lab-ic {
  width: 15px;
  height: 15px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.15s var(--ease);
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.22);
}

.nav-toggle:active {
  transform: scale(0.93);
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transform-origin: center;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1),
              opacity 0.2s var(--ease);
}

/* X de fechamento: as 3 barras são iguais (gap 5px + altura 2px => 7px
   entre centros), então ±7px junta a 1ª e a 3ª no centro da 2ª. */
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---- Hero ----------------------------------------------------------- */

.lab-hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: clamp(620px, 88vh, 820px);
  padding: 130px 0 150px;
  overflow: hidden;
  background: var(--navy);
}

.lab-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.lab-hero-bg img {
  width: 100%;
  height: 116%;
  object-fit: cover;
  will-change: transform;
}

.lab-hero-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      100deg,
      rgba(6, 34, 56, 0.93) 0%,
      rgba(7, 40, 66, 0.84) 24%,
      rgba(9, 48, 78, 0.5) 44%,
      rgba(10, 52, 82, 0.2) 64%,
      rgba(10, 52, 82, 0.08) 82%,
      rgba(10, 52, 82, 0.2) 100%
    ),
    linear-gradient(180deg, rgba(6, 34, 56, 0.45) 0%, rgba(6, 34, 56, 0) 26%, rgba(6, 34, 56, 0) 72%, rgba(6, 34, 56, 0.4) 100%);
}

.lab-hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: 32px;
}

.lab-hero-copy {
  max-width: 720px;
  color: var(--white);
}

.lab-hero-title {
  text-transform: uppercase;
  margin-bottom: 24px;
  color: var(--white);
  text-shadow: 0 2px 14px rgba(3, 16, 30, 0.5);
}

.lab-hero-title .thin {
  display: block;
  font-weight: 300;
  font-size: clamp(1.35rem, 2.5vw, 2.05rem);
  letter-spacing: 0.02em;
  line-height: 1.1;
}

.lab-hero-title .bold {
  display: block;
  margin-top: 4px;
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3.35rem);
  letter-spacing: -0.01em;
  line-height: 1.02;
}

.lab-hero-sub {
  max-width: 458px;
  margin-bottom: 32px;
  color: rgba(255, 255, 255, 0.94);
  font-size: clamp(1rem, 1.3vw, 1.1rem);
  font-weight: 300;
  line-height: 1.7;
  text-shadow: 0 1px 16px rgba(4, 20, 36, 0.5);
}

.lab-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.lab-hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 34px;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
}

.lab-hero-badges li {
  display: flex;
  align-items: center;
  gap: 13px;
}

.lab-badge-ic {
  width: 30px;
  height: 33px;
  color: var(--white);
  flex: none;
}

.lab-hero-badges span {
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.94);
}

.lab-hero-seal {
  position: absolute;
  top: clamp(92px, 13vh, 152px);
  right: clamp(-92px, -4vw, -48px);
  width: clamp(230px, 27vw, 400px);
  color: rgba(255, 255, 255, 0.8);
  z-index: 2;
  will-change: transform;
}

.lab-wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  z-index: 1;
  width: 100%;
  height: clamp(82px, 8vw, 132px);
  filter: drop-shadow(0 -14px 22px rgba(5, 24, 41, 0.22));
}

/* Garante que todas as heros internas tenham altura mínima equivalente
   à home, mantendo a onda sempre próxima ao fundo do viewport. */
.sb-hero,
.ct-hero,
.sol-hero,
.pf-hero,
.fx-hero {
  height: var(--hero-min);
}

/* No mobile a onda fica colada nos botões; aumenta o respiro inferior
   (a onda tem ~82px de altura, então deixamos folga generosa por baixo). */
@media (max-width: 760px) {
  .sb-hero,
  .ct-hero,
  .sol-hero,
  .pf-hero,
  .fx-hero {
    height: auto;
    min-height: var(--hero-min);
    padding-bottom: clamp(150px, 30vw, 200px);
  }
}

/* ---- Hero scrubbing (sequência de frames em canvas) ---------------- */

.lab-hero-scrub {
  position: relative;
  background: var(--navy);
}

.lab-hero-pin {
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
  height: var(--hero-min);
  padding: 130px 0 150px;
}

.lab-hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  background: var(--navy);
}

/* Vídeo do hero: só aparece no mobile/touch (o desktop usa o scrub no canvas) */
.lab-hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: none;
  background: var(--navy);
}

@media (hover: none), (pointer: coarse) {
  .lab-hero-canvas {
    display: none;
  }
  .lab-hero-video {
    display: block;
  }
}

/* só em telas com mouse: vira seção alta + painel fixo (pinned) p/ o scrub */
@media (hover: hover) and (pointer: fine) {
  .lab-hero-scrub {
    height: 220vh;
  }

  .lab-hero-scrub .lab-hero-pin {
    position: sticky;
    top: 0;
    height: 100vh;
    min-height: 0;
    padding: 0;
  }
}

/* ---- Fluxo digital -------------------------------------------------- */

.lab-flow {
  position: relative;
  overflow: hidden;
  background: var(--white);
  padding: clamp(56px, 6.5vw, 92px) 0 clamp(108px, 10vw, 148px);
}

.lab-flow::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: -1px;
  height: clamp(78px, 8vw, 128px);
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 128' preserveAspectRatio='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 128V54C236 84 454 84 654 60C854 36 1050 22 1440 50V128H0Z' fill='%23eef4f8'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center bottom;
  background-size: 100% 100%;
  filter: drop-shadow(0 -12px 20px rgba(12, 52, 82, 0.08));
}

.lab-flow .lab-shell {
  position: relative;
  z-index: 1;
}

.lab-steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lab-step {
  position: relative;
  text-align: center;
}

/* dashed connector + arrow */
.lab-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 63px;
  left: calc(50% + 42px);
  right: calc(-50% + 42px);
  border-top: 2px dashed rgba(22, 101, 150, 0.38);
}

.lab-step:not(:last-child)::before {
  content: "";
  position: absolute;
  top: 59px;
  right: calc(-50% + 40px);
  width: 8px;
  height: 8px;
  border-top: 2px solid rgba(22, 101, 150, 0.55);
  border-right: 2px solid rgba(22, 101, 150, 0.55);
  transform: rotate(45deg);
  z-index: 1;
}

.lab-step-num {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--blue-bright), var(--blue));
  color: var(--white);
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 6px 16px rgba(22, 101, 150, 0.36);
}

.lab-step-ic {
  width: 48px;
  height: 48px;
  margin: 0 auto 18px;
  color: var(--blue);
  transition: transform 0.4s var(--ease);
}

.lab-step:hover .lab-step-ic {
  transform: translateY(-5px) scale(1.06);
}

.lab-step h3 {
  text-transform: uppercase;
  color: var(--ink);
  font-size: 0.94rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 9px;
}

.lab-step p {
  max-width: 205px;
  margin: 0 auto;
  color: var(--body);
  font-size: 0.85rem;
  line-height: 1.6;
}

/* ---- Soluções e materiais ------------------------------------------ */

.lab-solutions {
  position: relative;
  overflow: hidden;
  background: var(--soft);
  padding: clamp(56px, 6.5vw, 92px) 0 clamp(112px, 12vw, 164px);
}

.lab-solutions .lab-shell {
  position: relative;
  z-index: 1;
}

/* onda de saída para a seção de resultados (branca) */
.lab-solutions::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: -1px;
  height: clamp(68px, 8vw, 128px);
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1440 128' preserveAspectRatio='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 128V72C236 36 454 36 720 60C940 84 1200 108 1440 72V128H0Z' fill='%23ffffff'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center bottom;
  background-size: 100% 100%;
}

.lab-solutions .lab-head {
  margin-bottom: clamp(34px, 4vw, 52px);
}

.lab-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.lab-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border-radius: var(--r);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.lab-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 56px rgba(12, 52, 82, 0.16);
}

.lab-card-media {
  display: block;
  overflow: hidden;
  aspect-ratio: 4 / 3.3;
}

.lab-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.lab-card:hover .lab-card-media img {
  transform: scale(1.07);
}

.lab-card-body {
  position: relative;
  flex: 1;
  padding: 22px 22px 26px;
}

.lab-card-body h3 {
  text-transform: uppercase;
  color: var(--blue);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  margin-bottom: 10px;
}

.lab-card-body p {
  max-width: 86%;
  color: var(--body);
  font-size: 0.88rem;
  line-height: 1.55;
}

.lab-card-go {
  position: absolute;
  right: 20px;
  bottom: 22px;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px solid var(--blue);
  color: var(--blue);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease);
}

.lab-card-go svg {
  width: 18px;
  height: 18px;
}

.lab-card:hover .lab-card-go {
  background: var(--blue);
  color: var(--white);
  transform: translateX(3px);
}

/* ---- Bastidores / Resultados --------------------------------------- */

.lab-results {
  background: var(--white);
  padding: clamp(56px, 6.5vw, 92px) 0 clamp(34px, 4vw, 56px);
}

.lab-results-grid {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}

.lab-results-copy .lab-head {
  margin-bottom: 22px;
}

.lab-results-text {
  max-width: 42ch;
  margin-bottom: 30px;
  color: var(--body);
  font-size: 1rem;
  line-height: 1.7;
}

.lab-mosaic {
  display: grid;
  grid-template-columns: 1.45fr 1fr 1fr;
  grid-auto-rows: clamp(130px, 13vw, 175px);
  gap: 12px;
  grid-template-areas:
    "feat a b"
    "feat c d";
}

.lab-mosaic figure {
  margin: 0;
  overflow: hidden;
  border-radius: 12px;
}

.lab-mosaic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease);
}

.lab-mosaic figure:hover img {
  transform: scale(1.07);
}

.lab-mosaic-feature {
  grid-area: feat;
}
.lab-mosaic-feature img {
  height: 116%;
  will-change: transform;
}
.m-a {
  grid-area: a;
}
.m-b {
  grid-area: b;
}
.m-c {
  grid-area: c;
}
.m-d {
  grid-area: d;
}

.lab-results-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: fit-content;
  margin: clamp(28px, 4vw, 44px) auto 0;
  color: var(--blue);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.lab-results-more .lab-ic {
  width: 18px;
  height: 18px;
  transition: transform 0.25s var(--ease);
}

.lab-results-more:hover .lab-ic {
  transform: translateX(4px);
}

/* ---- CTA ------------------------------------------------------------ */

.lab-cta {
  position: relative;
  overflow: hidden;
  background: linear-gradient(118deg, var(--blue-deep) 0%, var(--blue) 58%, var(--blue-bright) 100%);
  color: var(--white);
  padding: clamp(48px, 6vw, 80px) 0 clamp(80px, 9vw, 120px);
}

/* ondas 3 camadas no topo e na base do CTA */
.lab-cta::before,
.lab-cta::after {
  content: "";
  position: absolute;
  left: -1px;
  right: -1px;
  height: clamp(72px, 9vw, 120px);
  z-index: 1;
  pointer-events: none;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
}

.lab-cta::before {
  display: none;
}

.lab-cta::after {
  bottom: -1px;
  background-image: url(../img/wave-cta-bottom.svg);
}

.lab-cta-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 28px;
}

.lab-cta-lead {
  display: flex;
  align-items: center;
  gap: 26px;
}

.lab-cta-seal {
  width: 96px;
  flex: none;
  color: rgba(255, 255, 255, 0.7);
}

.lab-cta-text h2 {
  text-transform: uppercase;
  color: var(--white);
  font-size: clamp(1.45rem, 2.8vw, 2.25rem);
  font-weight: 700;
  line-height: 1.15;
}

.lab-cta-text p {
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(0.95rem, 1.3vw, 1.08rem);
  font-weight: 300;
}

/* ---- Footer --------------------------------------------------------- */

.lab-footer {
  background: var(--white);
}

.lab-footer-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.7fr 1.1fr 0.9fr 1.1fr;
  gap: 40px;
  padding: clamp(46px, 5.5vw, 72px) 0 clamp(34px, 4vw, 48px);
}

.lab-brand--dark {
  color: var(--ink);
}

.lab-brand--dark .lab-mark {
  color: var(--blue);
}

.lab-footer-brand p {
  max-width: 34ch;
  margin: 18px 0 20px;
  color: var(--body);
  font-size: 0.92rem;
  line-height: 1.7;
}

.lab-social {
  display: flex;
  gap: 12px;
}

.lab-social a {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  color: var(--blue);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.lab-social a svg {
  width: 18px;
  height: 18px;
}

.lab-social a:hover {
  background: var(--blue);
  color: var(--white);
  border-color: var(--blue);
  transform: translateY(-3px);
}

.lab-footer-col h4 {
  margin-bottom: 18px;
  text-transform: uppercase;
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.lab-footer-col a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 0;
  min-width: 0; /* permite que o texto encolha dentro do flex */
  color: var(--body);
  font-size: 0.92rem;
  overflow-wrap: anywhere; /* e-mail longo quebra em vez de gerar scroll lateral */
  transition: color 0.2s var(--ease), transform 0.2s var(--ease);
}

.lab-footer-col a svg {
  width: 16px;
  height: 16px;
  color: var(--blue);
  flex: none;
}

.lab-footer-col a:hover {
  color: var(--blue);
  transform: translateX(3px);
}

.lab-hours {
  display: flex;
  flex-direction: column;
  margin-bottom: 14px;
  color: var(--body);
  font-size: 0.92rem;
}

.lab-hours strong {
  color: var(--ink);
  font-weight: 600;
}

.lab-footer-seal {
  position: absolute;
  right: -10px;
  top: 30px;
  width: 150px;
  color: var(--blue);
  opacity: 0.07;
  pointer-events: none;
}

.lab-footer-bottom {
  border-top: 1px solid var(--line);
}

.lab-footer-bottom .lab-shell {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding: 18px 0;
}

.lab-footer-bottom span {
  color: var(--blue);
  font-size: 0.8rem;
}

/* ---- Reveal (JS-gated, additive) ----------------------------------- */

html.js [data-rise] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

html.js [data-rise].in {
  opacity: 1;
  transform: none;
}

/* ---- Responsive ----------------------------------------------------- */

@media (max-width: 1024px) {
  .lab-hero-inner {
    grid-template-columns: 1fr;
  }

  /* Marca d'água girando: discreta, no canto inferior-direito do hero —
     atrás dos botões/badges e longe do título, então não atrapalha a leitura.
     É só rotação em CSS (composição na GPU): não pesa no mobile. */
  .lab-hero-seal {
    top: auto;
    bottom: clamp(118px, 24vw, 200px);
    right: clamp(-72px, -10vw, -30px);
    width: clamp(190px, 46vw, 300px);
    color: rgba(255, 255, 255, 0.13);
  }

  .lab-steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px 22px;
  }

  .lab-step:not(:last-child)::after,
  .lab-step:not(:last-child)::before {
    display: none;
  }

  .lab-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .lab-results-grid {
    grid-template-columns: 1fr;
  }

  .lab-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .lab-footer-seal {
    display: none;
  }
}

@media (max-width: 760px) {
  :root {
    --shell: calc(100vw - 36px);
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px;
    /* Fundo TOTALMENTE opaco: o WebKit/iOS desativa backdrop-filter aninhado
       (o header já tem um) e deixava o conteúdo do hero vazar por trás do menu.
       Solução: cor sólida sem alpha + sem backdrop-filter aqui. */
    background: linear-gradient(180deg, #0e4365 0%, #0a3050 100%);
    z-index: 60;
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 18px;
    box-shadow: 0 20px 48px rgba(4, 24, 40, 0.55), 0 1px 0 rgba(255,255,255,0.06) inset;
    opacity: 0;
    transform: translateY(-6px) scale(0.98);
    transform-origin: top center;
    pointer-events: none;
    transition: opacity 0.22s var(--ease), transform 0.22s var(--ease);
  }

  .lab-header-inner {
    position: relative;
  }

  .nav-links.is-open {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .nav-links > a:not(.lab-nav-cta) {
    padding: 14px 16px;
    font-size: 0.9rem;
    border-radius: 12px;
    transition: background 0.15s var(--ease), color 0.15s var(--ease);
  }

  /* O dropdown mobile é SEMPRE escuro; força texto claro mesmo com o header
     "is-stuck" (que torna os links escuros para a barra branca do topo).
     Sem isto, ao abrir o menu já rolado o texto ficava escuro/ilegível. */
  .lab-header .nav-links > a:not(.lab-nav-cta),
  .lab-header.is-stuck .nav-links > a:not(.lab-nav-cta) {
    color: rgba(255, 255, 255, 0.92);
    opacity: 1;
  }

  .lab-header .nav-links > a:not(.lab-nav-cta):hover,
  .lab-header .nav-links > a.is-active,
  .lab-header.is-stuck .nav-links > a:not(.lab-nav-cta):hover,
  .lab-header.is-stuck .nav-links > a.is-active {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    opacity: 1;
  }

  /* o "X" do hambúrguer fica sobre a barra branca quando rolado: mantém escuro */
  .lab-header.is-stuck .nav-toggle span {
    background: var(--ink);
  }

  .nav-links > a:not(.lab-nav-cta)::after {
    display: none;
  }

  .lab-nav-cta {
    justify-content: center;
    margin: 6px 0 2px;
    font-size: 0.88rem;
    border-radius: 12px;
  }

  .lab-hero {
    padding: 120px 0 130px;
    min-height: 0;
  }

  .lab-hero-pin {
    min-height: 760px;
    padding: 118px 0 110px;
  }

  .lab-hero-copy {
    width: 100%;
    max-width: 360px;
    min-width: 0;
  }

  .lab-hero-title .thin {
    font-size: 1.35rem;
  }

  .lab-hero-title .bold {
    max-width: 10ch;
    font-size: 2rem;
    letter-spacing: 0;
  }

  .lab-hero-sub {
    max-width: 100%;
    font-size: 0.98rem;
  }

  .lab-hero-actions {
    align-items: stretch;
    flex-direction: column;
    width: 100%;
    max-width: 300px;
  }

  .lab-hero-actions .lab-btn {
    width: 100%;
    justify-content: center;
    padding-inline: 20px;
  }

  .lab-hero-badges {
    gap: 18px 26px;
  }

  .lab-cards {
    grid-template-columns: 1fr;
  }

  .lab-mosaic {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 130px;
    grid-template-areas:
      "feat feat"
      "a b"
      "c d";
  }

  .lab-cta-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .lab-footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .lab-footer-bottom .lab-shell {
    flex-direction: column;
    text-align: left;
  }
}

@media (max-width: 480px) {
  :root {
    --shell: calc(100vw - 28px);
  }

  .lab-steps {
    grid-template-columns: 1fr;
  }

  .lab-hero-title .bold {
    font-size: 1.75rem;
  }

  .lab-hero-actions {
    max-width: 100%;
  }

  .lab-hero-badges {
    gap: 14px 20px;
  }

  .lab-hero-badge-ic {
    width: 24px;
    height: 24px;
  }

  .lab-cta-inner {
    gap: 20px;
  }

  .lab-cta-lead {
    gap: 16px;
  }

  .lab-cta-seal {
    width: 72px;
  }

  .lab-footer-grid {
    gap: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---- Transição de página ---- */

@keyframes lab-fadein  { from { opacity: 0 } to { opacity: 1 } }
@keyframes lab-fadeout { from { opacity: 1 } to { opacity: 0 } }

/* Chrome / Edge 126+: cross-document view transition — sem flash, sem JS */
@view-transition {
  navigation: auto;
}

@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) {
    animation: lab-fadeout 200ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }
  ::view-transition-new(root) {
    animation: lab-fadein  300ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  /* Outros browsers: fade-in ao carregar a página */
  body.lab {
    animation: lab-fadein 300ms cubic-bezier(0.22, 1, 0.36, 1) both;
  }
}
