/* ==========================================================================
   MayFlow — Hero D (fiel à referência aprovada)
   Notebook apoiado num chão escuro e molhado que reflete a luz, universo e
   fitas de energia atrás, o M oficial com circuitos acendendo ao fundo.
   Clique no notebook: ele vem para a frente e passa as páginas com som.
   ========================================================================== */
.hd {
  --verde: #2fd28a;
  --turq: #19c7c1;
  --ciano: #5ce1e6;
  --azul: #2a7de1;
  --ease: cubic-bezier(0.19, 1, 0.22, 1);
  --mfu-verde: #2fd28a; --mfu-turquesa: #19c7c1; --mfu-ciano: #5ce1e6; --mfu-azul: #2a7de1;
  --mfu-texto: #eaf4ff; --mfu-texto-2: #a9bdd4; --mfu-suave: cubic-bezier(0.22, 0.8, 0.24, 1);
  --mx: 0;
  --my: 0;
  position: relative;
  min-height: clamp(660px, calc(100svh - 70px), 900px);
  overflow: hidden;
  isolation: isolate;
  color: #eaf4ff;
  background: radial-gradient(80% 70% at 70% 38%, #031a2a 0%, #020c16 50%, #01050a 100%);
}

/* menu escuro por cima */
.nav { background: rgba(1, 6, 12, 0.88) !important; -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border-bottom: 1px solid rgba(92, 225, 230, 0.1) !important; box-shadow: none !important; }
.nav .nav-links a:not(.btn) { color: rgba(234, 244, 255, 0.82); }

.hd-cosmos { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; }
.hd-cena { position: absolute; inset: 0; z-index: 1; }

/* raios de luz girando atrás do símbolo */
.hd-raios {
  position: absolute;
  left: 46%;
  top: -30%;
  width: 70vw;
  aspect-ratio: 1;
  z-index: 0;
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, rgba(92, 225, 230, 0.09) 0deg 3deg, transparent 3deg 14deg);
  -webkit-mask: radial-gradient(closest-side, #000 10%, transparent 70%);
  mask: radial-gradient(closest-side, #000 10%, transparent 70%);
  pointer-events: none;
}

/* ---------- símbolo oficial com circuitos ---------- */
.hd-simbolo {
  position: absolute;
  left: 41%;
  top: 2%;
  width: 56%;
  aspect-ratio: 1764 / 621;
  z-index: 1;
  pointer-events: none;
}
.hd-simbolo::before {
  content: "";
  position: absolute;
  left: 28%;
  right: 28%;
  top: -10%;
  bottom: -10%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(47, 210, 138, 0.5), rgba(42, 125, 225, 0.3) 55%, transparent);
  filter: blur(30px);
}
.hd-simbolo__img { position: absolute; inset: 0; width: 100%; height: 100%; filter: drop-shadow(0 0 18px rgba(92, 225, 230, 0.45)); }
/* luz que percorre os circuitos e o M (máscara = a própria logo) */
.hd-simbolo__brilho {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 0 40%, rgba(255, 255, 255, 0.95) 48%, rgba(170, 255, 240, 0.8) 52%, transparent 60% 100%);
  background-size: 260% 100%;
  -webkit-mask: url("mayflow-simbolo-circuito.webp") center / 100% 100% no-repeat;
  mask: url("mayflow-simbolo-circuito.webp") center / 100% 100% no-repeat;
  mix-blend-mode: screen;
  opacity: 0.85;
}
/* terminais dos circuitos que pulsam */
.hd-no {
  position: absolute;
  width: 0.9%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 50%;
  background: #e8fffb;
  box-shadow: 0 0 10px 3px rgba(92, 225, 230, 0.9);
  opacity: 0;
}
.hd-ligacoes { position: absolute; left: -12%; right: -12%; top: -30%; bottom: -40%; width: 124%; height: 170%; overflow: visible; }
.hd-ligacoes path { fill: none; stroke: rgba(92, 225, 230, 0.28); stroke-width: 1.2; }
.hd-ligacoes .pulso { stroke: #c9fff5; stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 0.06 0.94; stroke-dashoffset: 1; filter: drop-shadow(0 0 4px #5ce1e6); }
.hd-ico {
  position: absolute;
  width: 3.4%;
  min-width: 26px;
  aspect-ratio: 1;
  translate: -50% -50%;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #c9fff5;
  background: rgba(4, 22, 38, 0.8);
  box-shadow: 0 0 0 1px rgba(92, 225, 230, 0.6), 0 0 18px rgba(92, 225, 230, 0.5);
}
.hd-ico svg { width: 55%; height: 55%; }

/* ---------- chão molhado ---------- */
.hd-chao {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--hd-chao, 26%);
  z-index: 2;
  background:
    radial-gradient(60% 120% at 68% 0%, rgba(25, 199, 193, 0.22), transparent 60%),
    linear-gradient(180deg, rgba(4, 26, 38, 0.92) 0%, rgba(2, 10, 18, 0.98) 40%, #01050a 100%);
  overflow: hidden;
}
/* linha do horizonte acesa */
.hd-chao::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 2%, rgba(47, 210, 138, 0.8) 25%, rgba(156, 239, 255, 0.95) 60%, rgba(42, 125, 225, 0.8) 85%, transparent 99%);
  box-shadow: 0 0 22px 4px rgba(92, 225, 230, 0.45);
}
/* reflexos verticais de luz na superfície molhada */
.hd-chao__reflexos {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(90deg, transparent 0 46px, rgba(92, 225, 230, 0.22) 46px 49px, transparent 49px 120px, rgba(47, 210, 138, 0.18) 120px 122px, transparent 122px 190px),
    repeating-linear-gradient(90deg, transparent 0 77px, rgba(120, 170, 255, 0.16) 77px 80px, transparent 80px 230px);
  filter: blur(3px);
  -webkit-mask: linear-gradient(180deg, #000, transparent 85%);
  mask: linear-gradient(180deg, #000, transparent 85%);
  opacity: 0.8;
}
/* brilho ondulando na água */
.hd-chao__onda {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(180deg, transparent 0 9px, rgba(156, 239, 255, 0.05) 9px 10px);
  -webkit-mask: radial-gradient(60% 90% at 66% 0%, #000, transparent 75%);
  mask: radial-gradient(60% 90% at 66% 0%, #000, transparent 75%);
}

/* ---------- palco do notebook ---------- */
.hd-palco {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 60%;
  height: 100%;
  z-index: 3;
  perspective: 2000px;
  perspective-origin: 50% 40%;
}
.hd-espelho {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  transform: scaleY(-1);
  transform-origin: 50% calc(100% - var(--hd-chao, 26%));
  opacity: 0.32;
  filter: blur(2.5px) saturate(1.3);
  -webkit-mask: linear-gradient(180deg, transparent calc(100% - var(--hd-chao, 26%) - 30%), #000 calc(100% - var(--hd-chao, 26%)), #000 100%);
  mask: linear-gradient(180deg, transparent calc(100% - var(--hd-chao, 26%) - 30%), #000 calc(100% - var(--hd-chao, 26%)), #000 100%);
}

.hd-lap {
  position: absolute;
  left: 14%;
  width: 72%;
  bottom: calc(var(--hd-chao, 26%) + 8%);
  transform-style: preserve-3d;
  transform: rotateX(calc(-20deg + var(--my) * -3deg)) rotateY(calc(-26deg + var(--mx) * 7deg));
  transition: transform 1.3s var(--ease), left 1.2s var(--ease), width 1.2s var(--ease), bottom 1.2s var(--ease);
  cursor: pointer;
}
.hd-lap__tampa {
  position: relative;
  padding: 1.4% 1.4% 2%;
  border-radius: 16px 16px 5px 5px;
  background: linear-gradient(160deg, #3d4a5d 0%, #1b2433 30%, #0a0f17 100%);
  box-shadow:
    0 0 0 1px rgba(205, 225, 245, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 0 0 3px #05080d,
    0 0 70px -6px rgba(92, 225, 230, 0.55);
  transform-origin: 50% 100%;
  transform: rotateX(6deg);
  transform-style: preserve-3d;
}
.hd-lap__cam { position: absolute; left: 50%; top: 0.45%; width: 5px; height: 5px; translate: -50% 0; border-radius: 50%; background: #05080d; box-shadow: inset 0 0 0 1px #34404f, 0 0 3px rgba(92, 225, 230, 0.5); }
.hd-lap__tela { position: relative; aspect-ratio: 1366 / 694; border-radius: 5px; overflow: hidden; background: #071220; }
.hd-lap__tela::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background: linear-gradient(118deg, rgba(255, 255, 255, 0.11), transparent 26%, transparent 74%, rgba(92, 225, 230, 0.06));
  pointer-events: none;
}
.hd-pag {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateX(6%);
  transition: opacity 0.55s ease, transform 0.8s var(--ease);
}
.hd-pag.ativa { opacity: 1; transform: none; z-index: 1; }
.hd-pag.sai { opacity: 0; transform: translateX(-6%); }
.hd-pag img { width: 100%; height: 100%; object-fit: cover; object-position: top left; display: block; }
/* páginas futuras: tela reservada, no visual do app */
.hd-pag--breve {
  display: grid;
  grid-template-columns: 17% 1fr;
  background: #0b1626;
  font-size: clamp(7px, 0.9vw, 13px);
}
.hd-pag__lado { background: linear-gradient(180deg, #0f2140, #0a1730); border-right: 1px solid rgba(92, 225, 230, 0.12); padding: 6% 8%; display: grid; align-content: start; gap: 7%; }
.hd-pag__lado img { width: 90%; justify-self: center; }
.hd-pag__lado i { display: block; height: 0.55em; border-radius: 3px; background: rgba(255, 255, 255, 0.12); }
.hd-pag__lado i.on { background: linear-gradient(90deg, #ff4f9a, #e6418c); }
.hd-pag__corpo { display: grid; place-items: center; text-align: center; padding: 6%; background: radial-gradient(60% 60% at 50% 40%, rgba(25, 199, 193, 0.16), transparent 70%); }
.hd-pag__corpo b { display: block; margin: 0.6em 0 0.3em; font-size: 2em; font-weight: 700; color: #fff; }
.hd-pag__corpo span { color: rgba(219, 233, 247, 0.72); font-size: 1.05em; }
.hd-pag__corpo em {
  display: inline-block;
  margin-top: 1em;
  padding: 0.35em 0.9em;
  border-radius: 999px;
  font-style: normal;
  font-weight: 600;
  color: #04162b;
  background: linear-gradient(90deg, #2fd28a, #5ce1e6);
}
.hd-pag__icone { width: 3.6em; height: 3.6em; margin: 0 auto; display: grid; place-items: center; border-radius: 1em; color: #04162b; background: linear-gradient(135deg, #2fd28a, #19c7c1 50%, #2a7de1); box-shadow: 0 0 2em rgba(25, 199, 193, 0.6); }
.hd-pag__icone svg { width: 55%; height: 55%; }

/* dica de clique sobre a tela */
.hd-dica {
  position: absolute;
  left: 50%;
  bottom: 8%;
  z-index: 4;
  translate: -50% 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  font-size: clamp(9px, 0.85vw, 13px);
  font-weight: 600;
  white-space: nowrap;
  color: #04162b;
  background: linear-gradient(90deg, #2fd28a, #5ce1e6);
  box-shadow: 0 0 24px rgba(92, 225, 230, 0.7);
  transition: opacity 0.4s;
}
.hd--foco .hd-dica { opacity: 0; }

/* base: alumínio, alto-falantes, teclado de verdade e touchpad */
.hd-lap__base {
  position: absolute;
  left: -4%;
  right: -4%;
  top: 100%;
  height: 0;
  padding-bottom: 62%;
  border-radius: 6px 6px 24px 24px;
  background:
    radial-gradient(70% 40% at 50% 0%, rgba(92, 225, 230, 0.16), transparent 70%),
    linear-gradient(180deg, #56637a 0%, #323d4f 26%, #222b3a 62%, #1a2230 100%);
  box-shadow: inset 0 0 0 1px rgba(210, 228, 245, 0.38), inset 0 3px 0 rgba(255, 255, 255, 0.2), inset 0 -10px 30px rgba(0, 0, 0, 0.35);
  transform-origin: 50% 0;
  transform: rotateX(84deg);
  transform-style: preserve-3d;
}
.hd-lap__base::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 13px;
  border-radius: 0 0 24px 24px;
  background: linear-gradient(180deg, #c9d6e6, #6b7a90 45%, #252e3d);
  transform-origin: 50% 100%;
  transform: translateY(100%) rotateX(-90deg) translateY(-100%);
}
.hd-lap__som { position: absolute; top: 7%; height: 49%; width: 7%; background-image: radial-gradient(circle, rgba(0, 0, 0, 0.75) 0 1.1px, transparent 1.4px); background-size: 7px 7px; opacity: 0.8; }
.hd-lap__som--e { left: 2.5%; }
.hd-lap__som--d { right: 2.5%; }
.hd-teclado {
  position: absolute;
  left: 11%;
  right: 11%;
  top: 6%;
  height: 51%;
  display: flex;
  flex-direction: column;
  gap: 2.4%;
  padding: 1.8% 1.6%;
  border-radius: 7px;
  background: #06090f;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.06);
}
.hd-linha { display: flex; flex: 1; gap: 0.9%; }
.hd-linha i {
  display: grid;
  place-items: center;
  border-radius: 3px;
  font: 600 clamp(4px, 0.42vw, 7px)/1 system-ui, sans-serif;
  font-style: normal;
  color: rgba(156, 239, 255, 0.85);
  text-shadow: 0 0 4px rgba(92, 225, 230, 0.9);
  background: linear-gradient(180deg, #1f2734, #121822);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 0 4px rgba(92, 225, 230, 0.35), 0 1px 0 rgba(0, 0, 0, 0.8);
  transition: background 0.12s, box-shadow 0.12s, color 0.12s;
}
.hd-linha i.aperta { background: linear-gradient(180deg, #2fd28a, #19c7c1); color: #04162b; box-shadow: 0 0 10px rgba(47, 210, 138, 0.9); }
.hd-touch {
  position: absolute;
  left: 32%;
  right: 32%;
  top: 63%;
  height: 29%;
  border-radius: 10px;
  background: linear-gradient(160deg, #3a4558, #2a3343);
  box-shadow: inset 0 0 0 1px rgba(215, 230, 245, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}
.hd-lap__luz {
  /* luz da tela caindo sobre o teclado */
  position: absolute;
  inset: 0 0 40% 0;
  border-radius: inherit;
  background: radial-gradient(80% 100% at 50% 0%, rgba(92, 225, 230, 0.2), transparent 70%);
  pointer-events: none;
}

/* ---------- modo foco: o notebook vem para a frente ---------- */
.hd--foco .hd-lap { left: 4%; width: 92%; bottom: calc(var(--hd-chao, 26%) + 4%); transform: rotateX(-12deg) rotateY(-8deg); }
.hd-fechar {
  position: absolute;
  right: 3%;
  top: 4%;
  z-index: 8;
  display: none;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(92, 225, 230, 0.5);
  border-radius: 999px;
  font: 600 0.84rem/1 var(--body);
  color: #eaf4ff;
  background: rgba(4, 18, 32, 0.8);
  cursor: pointer;
}
.hd--foco .hd-fechar { display: inline-flex; }
.hd-som-btn { margin-left: 4px; }
.hd--foco .hd__texto { opacity: 0.18; filter: blur(2px); pointer-events: none; }
.hd__texto { transition: opacity 0.6s ease, filter 0.6s ease; }

/* ---------- textos ---------- */
.hd .wrap { position: relative; z-index: 4; height: 100%; }
.hd__texto { width: min(560px, 46%); padding: clamp(36px, 5vw, 70px) 0 clamp(150px, 16vw, 220px); }
.hd__titulo { margin: 16px 0 0; font-family: var(--display); font-size: clamp(2.6rem, 4.9vw, 4.6rem); font-weight: 700; line-height: 0.98; letter-spacing: -0.04em; }
.hd__titulo span { display: block; }
.hd__grad {
  background: linear-gradient(92deg, #19d3e6 0%, #2fd28a 40%, #9be27c 64%, #f0cf7c 86%, #ffd98e 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 24px rgba(47, 210, 138, 0.35));
}
.hd__lead { max-width: 46ch; margin: 18px 0 0; font-size: clamp(1rem, 1.2vw, 1.12rem); line-height: 1.55; color: rgba(219, 233, 247, 0.82); }
.hd__acoes { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; margin-top: 26px; }
.hd__selo { display: inline-flex; align-items: center; gap: 12px; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: #bff7ee; }
.hd__selo::before { content: ""; width: 34px; height: 1px; background: linear-gradient(90deg, var(--verde), var(--ciano)); }

/* botões de páginas */
.hd-paginas { margin-top: 22px; }
.hd-paginas__rotulo { margin: 0 0 10px; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: #9cefff; display: flex; align-items: center; gap: 8px; }
.hd-paginas__rotulo i { width: 8px; height: 8px; border-radius: 50%; background: var(--verde); }
.hd-paginas__lista { display: flex; flex-wrap: wrap; gap: 7px; }
.hd-paginas__lista button {
  padding: 7px 12px;
  border: 1px solid rgba(92, 225, 230, 0.2);
  border-radius: 999px;
  font: 600 0.78rem/1 var(--body);
  color: rgba(234, 244, 255, 0.78);
  background: rgba(6, 24, 40, 0.6);
  cursor: pointer;
  transition: color 0.3s, border-color 0.3s, background 0.3s;
}
.hd-paginas__lista button small { margin-left: 5px; font-size: 0.66rem; color: #f0cf7c; }
.hd-paginas__lista button[aria-pressed="true"] { color: #fff; border-color: rgba(92, 225, 230, 0.7); background: rgba(25, 199, 193, 0.2); }
@media (hover: hover) { .hd-paginas__lista button:hover { color: #fff; border-color: rgba(92, 225, 230, 0.5); } }

/* cartões de vidro (benefícios) */
.hd-vidros { position: absolute; left: 0; bottom: clamp(24px, 3vw, 44px); z-index: 5; display: flex; gap: 14px; perspective: 900px; }
.hd-vidro {
  width: clamp(150px, 13vw, 200px);
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid rgba(92, 225, 230, 0.4);
  border-radius: 14px;
  font-size: 0.74rem;
  line-height: 1.35;
  color: rgba(219, 233, 247, 0.8);
  background: linear-gradient(150deg, rgba(25, 199, 193, 0.2), rgba(4, 18, 32, 0.6) 60%);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.9), 0 0 30px -10px rgba(47, 210, 138, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  transform: rotateY(var(--ry, 12deg)) rotateX(8deg) rotateZ(var(--rz, -3deg));
  transition: transform 0.8s var(--ease), box-shadow 0.5s;
}
.hd-vidro:nth-child(2) { --ry: 4deg; --rz: 2deg; margin-top: 22px; }
.hd-vidro:nth-child(3) { --ry: -6deg; --rz: 4deg; }
.hd-vidro svg { width: 26px; height: 26px; color: var(--verde); filter: drop-shadow(0 0 8px rgba(47, 210, 138, 0.8)); }
.hd-vidro b { font-size: 0.86rem; color: #fff; }
@media (hover: hover) { .hd-vidro:hover { transform: translateY(-6px); box-shadow: 0 26px 50px -20px rgba(0, 0, 0, 0.9), 0 0 40px -6px rgba(47, 210, 138, 0.8); } }
.hd-nota { position: absolute; left: 0; bottom: 4px; z-index: 5; margin: 0; font-size: 0.7rem; color: rgba(255, 230, 160, 0.85); }
.hd-legenda { position: absolute; right: 3%; bottom: 10px; z-index: 5; margin: 0; font-size: 0.72rem; color: rgba(219, 233, 247, 0.5); }

/* MAY no canto da tela */
.hd-may {
  position: absolute;
  z-index: 6;
  right: 4%;
  top: 30%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px 8px 8px;
  border: 1px solid rgba(92, 225, 230, 0.4);
  border-radius: 999px;
  font-size: 0.8rem;
  color: #eaf4ff;
  background: rgba(4, 18, 32, 0.75);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 0 30px -6px rgba(92, 225, 230, 0.6);
}
.hd-may img { width: 46px; height: 46px; border-radius: 50%; padding: 2px; background: conic-gradient(var(--verde), var(--ciano), var(--azul), var(--verde)); }
.hd-may b { display: block; }
.hd-may small { color: rgba(219, 233, 247, 0.7); }

/* ---------- movimento ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hd-raios { animation: hd-gira 80s linear infinite; }
  .hd-simbolo__brilho { animation: hd-varre 5.5s ease-in-out infinite; }
  .hd-no { animation: hd-pisca 3.2s ease-in-out infinite; animation-delay: var(--atraso, 0s); }
  .hd-ligacoes .pulso { animation: hd-corre var(--dur, 3s) linear infinite; animation-delay: var(--atraso, 0s); }
  .hd-ico { animation: hd-boia 6s ease-in-out infinite; animation-delay: var(--atraso, 0s); }
  .hd-chao__reflexos { animation: hd-agua 9s ease-in-out infinite alternate; }
  .hd-chao__onda { animation: hd-onda 4s linear infinite; }
  .hd-lap__boia { animation: hd-flutua 7s ease-in-out infinite; }
  .hd__grad { animation: hn-brilho 8s ease-in-out infinite; }
  .hd-may { animation: hd-boia 7s ease-in-out -2s infinite; }
  .hd-dica { animation: hd-chama 2.4s ease-in-out infinite; }
  .hd-paginas__rotulo i { animation: hn-c-ping 2s ease-out infinite; }
  [data-hd-entra] { opacity: 0; translate: 0 24px; transition: opacity 1s ease, translate 1.2s var(--ease); transition-delay: calc(var(--d, 0) * 1ms); }
  .hd--pronta [data-hd-entra] { opacity: 1; translate: 0 0; }
}
@keyframes hd-gira { to { rotate: 360deg; } }
@keyframes hd-varre { 0% { background-position: 120% 0; } 70%, 100% { background-position: -20% 0; } }
@keyframes hd-pisca { 0%, 100% { opacity: 0; scale: 0.6; } 40% { opacity: 1; scale: 1.4; } 60% { opacity: 0.8; scale: 1; } }
@keyframes hd-corre { to { stroke-dashoffset: 0; } }
@keyframes hd-boia { 0%, 100% { translate: -50% -50%; } 50% { translate: -50% calc(-50% - 8px); } }
@keyframes hd-agua { from { transform: translateX(0) scaleY(1); } to { transform: translateX(-60px) scaleY(1.08); } }
@keyframes hd-onda { to { background-position: 0 20px; } }
@keyframes hd-flutua { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes hd-chama { 0%, 100% { scale: 1; } 50% { scale: 1.06; } }
@keyframes hn-brilho { 0%, 100% { background-position: 0 0; } 50% { background-position: 100% 0; } }
@keyframes hn-c-ping { 0% { box-shadow: 0 0 0 0 rgba(47, 210, 138, 0.7); } 100% { box-shadow: 0 0 0 10px rgba(47, 210, 138, 0); } }
.hd-may { animation-name: hd-boia2; }
@keyframes hd-boia2 { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }

/* ---------- responsivo ---------- */
@media (max-width: 1100px) {
  .hd-vidro { width: clamp(130px, 15vw, 170px); }
  .hd-vidro:nth-child(3) { display: none; }
}
@media (max-width: 940px) {
  .hd { min-height: 0; display: flex; flex-direction: column; }
  .hd .wrap { height: auto; }
  .hd__texto { width: 100%; padding: 32px 0 0; text-align: center; }
  .hd__lead { margin-left: auto; margin-right: auto; }
  .hd__acoes, .hd-paginas__lista, .hd-paginas__rotulo { justify-content: center; }
  .hd__selo { justify-content: center; }
  .hd-cena { position: relative; height: clamp(360px, 92vw, 560px); margin-top: 10px; }
  .hd-palco { width: 100%; }
  .hd-simbolo { left: 4%; width: 92%; top: 0; }
  .hd-raios { left: -20%; width: 140vw; top: -10%; }
  .hd-lap { left: 9%; width: 82%; }
  .hd--foco .hd-lap { left: 3%; width: 94%; }
  .hd-vidros { position: relative; left: auto; bottom: auto; justify-content: center; margin: 18px 16px 0; flex-wrap: wrap; }
  .hd-vidro:nth-child(3) { display: grid; }
  .hd-nota, .hd-legenda { position: static; text-align: center; padding: 8px 16px 16px; }
  .hd-may { top: 4%; right: 2%; }
}
@media (max-width: 560px) {
  .hd-vidro { width: calc(50% - 8px); transform: none; margin-top: 0 !important; }
  .hd-vidro:nth-child(3) { width: 100%; }
  .hd-may small { display: none; }
  .hd-ico { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hd-lap, .hd-pag { transition: none; }
}

/* ajustes: 3D preservado na camada que flutua e hero do tamanho da tela */
.hd-lap__boia { transform-style: preserve-3d; }
@media (min-width: 941px) {
  .hd { height: clamp(680px, calc(100svh - 70px), 880px); min-height: 0; }
  .hd__texto { padding: clamp(28px, 4vh, 56px) 0 0; }
  .hd__titulo { font-size: clamp(2.4rem, 4.3vw, 4.2rem); }
  .hd__lead { margin-top: 14px; }
  .hd__acoes { margin-top: 20px; }
  .hd-paginas { margin-top: 18px; }
  .hd-paginas__lista { gap: 6px; max-width: 520px; }
  .hd-paginas__lista button { padding: 6px 10px; font-size: 0.74rem; }
  .hd-paginas__lista button small { display: none; }
  .hd-paginas__lista button:not(:first-child)::after { content: ""; display: inline-block; width: 5px; height: 5px; margin-left: 6px; border-radius: 50%; background: #f0cf7c; vertical-align: middle; }
  .hd-vidros { bottom: clamp(18px, 2.4vh, 30px); }
  .hd-vidro { padding: 11px 12px; }
}

/* composição da referência: M inteiro acima da tampa, notebook pousado no chão */
@media (min-width: 941px) {
  .hd { --hd-chao: 22%; }
  .hd-simbolo { left: 40%; top: 3%; width: 54%; }
  .hd-lap { left: 20%; width: 62%; bottom: calc(var(--hd-chao) + 12.5vw); }
  .hd--foco .hd-lap { left: 6%; width: 84%; bottom: calc(var(--hd-chao) + 15vw); }
  .hd-may { top: 34%; right: 2%; }
  .hd-vidros { position: static; margin-top: 22px; }
  .hd-vidro { width: auto; flex: 1; max-width: 180px; transform: rotateY(var(--ry, 8deg)) rotateX(6deg) rotateZ(var(--rz, -2deg)); }
  .hd-vidro:nth-child(2) { margin-top: 0; }
  .hd-vidro:nth-child(3) { display: grid; }
  .hd-nota { position: static; margin-top: 10px; }
  .hd-legenda { bottom: 8px; }
}
@media (min-width: 941px) {
  .hd-simbolo { top: -2%; width: 56%; left: 39%; }
  .hd-lap { bottom: calc(var(--hd-chao) + 10.4vw); left: 22%; width: 60%; }
  .hd-espelho { opacity: 0.45; }
}
@media (max-width: 940px) {
  .hd { --hd-chao: 22%; }
  .hd .wrap { order: 1; }
  .hd-cena { position: relative; order: 2; inset: auto; height: clamp(380px, 96vw, 600px); }
  .hd-palco { width: 100%; }
  .hd-simbolo { left: 2%; width: 96%; top: 4%; }
  .hd-lap { left: 12%; width: 76%; bottom: calc(var(--hd-chao) + 27vw); }
  .hd--foco .hd-lap { left: 3%; width: 94%; bottom: calc(var(--hd-chao) + 32vw); }
  .hd-legenda { position: absolute; left: 0; right: 0; bottom: 6px; padding: 0 16px; }
  .hd-vidros { margin: 20px 0 0; }
  .hd-nota { text-align: center; }
  .hd__texto { padding-bottom: 8px; }
}
@media (max-width: 560px) {
  .hd-lap { left: 8%; width: 84%; bottom: calc(var(--hd-chao) + 30vw); }
  .hd-may { top: 2%; padding: 5px 10px 5px 5px; }
  .hd-may img { width: 34px; height: 34px; }
  .hd-dica { font-size: 9px; padding: 4px 9px; }
  .hd-fechar { top: 1%; font-size: 0.74rem; }
}
@media (max-width: 940px) {
  .hd .wrap, .hd__texto { display: contents; }
  .hd__selo, .hd__titulo, .hd__lead, .hd__acoes, .hd-paginas, .hd-vidros, .hd-nota { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); position: relative; z-index: 4; }
  .hd__selo { order: 1; margin-top: 30px; align-self: center; }
  .hd__titulo { order: 2; text-align: center; }
  .hd__lead { order: 3; text-align: center; }
  .hd__acoes { order: 4; justify-content: center; }
  .hd-cena { order: 5; }
  .hd-paginas { order: 6; text-align: center; }
  .hd-vidros { order: 7; }
  .hd-nota { order: 8; padding-bottom: 20px; }
}
@media (max-width: 560px) {
  .hd-lap { left: 13%; width: 76%; bottom: calc(var(--hd-chao) + 27vw); }
}
@media (max-width: 560px) {
  .hd-lap { bottom: calc(var(--hd-chao) + 15vw); }
  .hd--foco .hd-lap { left: 4%; width: 92%; bottom: calc(var(--hd-chao) + 18vw); }
  .hd-simbolo { top: 0; }
}
/* a camada de texto não pode bloquear o clique no notebook */
.hd .wrap { pointer-events: none; }
.hd__texto > *, .hd-vidros, .hd-nota { pointer-events: auto; }
@media (min-width: 941px) { .hd__texto { pointer-events: none; } }
/* foco: notebook centralizado na hero */
.hd-palco { transition: width 1.2s var(--ease); }
.hd-may { transition: opacity 0.4s; }
.hd--foco .hd-may { opacity: 0; pointer-events: none; }
@media (min-width: 941px) {
  .hd--foco .hd-palco { width: 100%; }
  .hd--foco .hd-lap { left: 16%; width: 68%; bottom: calc(var(--hd-chao) + 13.5vw); transform: rotateX(-14deg) rotateY(-4deg); }
  .hd--foco .hd-fechar { right: 4%; top: 5%; }
}
@media (min-width: 941px) {
  .hd--foco .hd-lap { left: 25%; width: 50%; bottom: calc(var(--hd-chao) + 8.6vw); transform: rotateX(-16deg) rotateY(-4deg); }
}
/* "clip" não cria área rolável: o foco no notebook não desloca a cena */
.hd, .hd-chao, .hd-lap__tela { overflow: clip; }
