/* Confirma Horário - site de apresentação */

:root {
  --fundo: #FBF8F3;
  --parede: #F4EEE6;
  --piso: #E7D9C7;
  --terracota: #C46A4A;
  --ouro: #C79A5B;
  --petroleo: #4F7C8A;
  --preto: #1A1A1A;
  --texto-suave: #5B524A;

  --letra: ui-rounded, "SF Pro Rounded", "Nunito", "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --ciclo: 30s; /* 6 cenas x 5 segundos */
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--letra);
  color: var(--preto);
  background: var(--fundo);
  line-height: 1.5;
}

img { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

:focus-visible { outline: 3px solid var(--terracota); outline-offset: 3px; border-radius: 6px; }

.sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

/* ---------- Topo ---------- */

.topo {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  padding: 12px clamp(20px, 4vw, 48px);
  background: color-mix(in srgb, var(--fundo) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #E4D7C6;
}

.marca {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none;
  font-weight: 800; font-size: 1.2rem; letter-spacing: -0.01em;
}

.menu-largo { display: none; gap: 28px; }

.menu-largo a,
.menu-celular a {
  text-decoration: none; font-weight: 600;
}

.menu-largo a[aria-current="page"] {
  text-decoration: underline; text-decoration-color: var(--terracota);
  text-decoration-thickness: 3px; text-underline-offset: 8px;
}

.botao-menu, .fechar-menu {
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border: 0; border-radius: 12px;
  background: transparent; color: var(--preto);
  cursor: pointer;
}

.botao-menu:hover, .fechar-menu:hover { background: var(--piso); }

/* Menu do celular: painel que desce do topo */
.menu-celular {
  margin: 0; inset: 0 0 auto 0;
  width: 100%; max-width: none;
  padding: 12px clamp(16px, 4vw, 48px) 28px;
  border: 0; border-bottom: 1px solid #E4D7C6;
  background: var(--fundo); color: var(--preto);
  flex-direction: column; align-items: flex-start; gap: 4px;
}

.menu-celular:popover-open { display: flex; }

.menu-celular::backdrop { background: rgb(26 26 26 / .35); }

.fechar-menu { align-self: flex-end; }

.menu-celular a {
  font-size: 1.5rem; padding: 10px 0;
  width: 100%; border-bottom: 1px solid #E4D7C6;
}

@media (min-width: 760px) {
  .menu-largo { display: flex; }
  .botao-menu { display: none; }
}

/* ---------- Abertura (banner) ---------- */

.abertura {
  display: grid;
  gap: 28px;
  padding: 28px clamp(24px, 4vw, 48px) 64px;
  max-width: 1240px; margin: 0 auto;
}

.abertura h1 {
  margin: 0;
  font-size: clamp(2.1rem, 7vw, 4.2rem);
  line-height: 1.04; letter-spacing: -0.03em;
  font-weight: 800;
  max-width: 14ch;
  text-wrap: balance;
}

.abertura-texto > p:not(.para-quem) {
  margin: 18px 0 0;
  font-size: clamp(1.05rem, 2.4vw, 1.3rem);
  color: var(--texto-suave);
  max-width: 34ch;
}

/* Frase que troca junto com a imagem */
.para-quem { margin: 22px 0 0; min-height: 1.6em; }

.giro { display: grid; }

.giro span {
  grid-area: 1 / 1;
  font-weight: 700; font-size: 1.15rem;
  color: var(--terracota);
  opacity: 0;
}

/* Palco das cenas */
.palco {
  position: relative;
  padding-right: min(24%, 190px);
}

.cenas {
  display: grid;
  border-radius: 28px;
  overflow: hidden;
  background: var(--piso);
  aspect-ratio: 5 / 4;
}

.cenas img {
  grid-area: 1 / 1;
  width: 100%; height: 100%; object-fit: cover;
  opacity: 0;
}

.cenas img:first-child,
.giro span:first-child { opacity: 1; }

.telefone {
  position: absolute;
  right: 0; bottom: -6%;
  width: min(36%, 240px);
  filter: drop-shadow(0 18px 24px rgb(26 26 26 / .18));
}

/* Botão de pausar a troca */
.pausa { position: absolute; opacity: 0; width: 1px; height: 1px; }

.pausa-rotulo {
  position: absolute; z-index: 2; top: 14px; left: 14px;
  display: grid; place-items: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgb(255 255 255 / .85); color: var(--preto);
  cursor: pointer;
}

.pausa:focus-visible + .pausa-rotulo { outline: 3px solid var(--terracota); outline-offset: 3px; }

.ic-tocar { display: none; }
.pausa:checked + .pausa-rotulo .ic-pausar { display: none; }
.pausa:checked + .pausa-rotulo .ic-tocar { display: block; }

/* Troca automática: só para quem não pediu menos movimento */
@media (prefers-reduced-motion: no-preference) {
  .cenas img:first-child,
  .giro span:first-child {
    animation: primeira var(--ciclo) linear infinite both;
  }

  .cenas img:not(:first-child),
  .giro span:not(:first-child) {
    animation: troca var(--ciclo) linear infinite both;
  }

  .cenas img:nth-child(2), .giro span:nth-child(2) { animation-delay: 5s; }
  .cenas img:nth-child(3), .giro span:nth-child(3) { animation-delay: 10s; }
  .cenas img:nth-child(4), .giro span:nth-child(4) { animation-delay: 15s; }
  .cenas img:nth-child(5), .giro span:nth-child(5) { animation-delay: 20s; }
  .cenas img:nth-child(6), .giro span:nth-child(6) { animation-delay: 25s; }

  .palco:hover .cenas img,
  .abertura:has(.palco:hover) .giro span,
  .abertura:has(.pausa:checked) .cenas img,
  .abertura:has(.pausa:checked) .giro span {
    animation-play-state: paused;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pausa-rotulo { display: none; }
}

@keyframes primeira {
  0%      { opacity: 1; }
  16.66%  { opacity: 1; }
  19%     { opacity: 0; }
  97.66%  { opacity: 0; }
  100%    { opacity: 1; }
}

@keyframes troca {
  0%      { opacity: 0; }
  2.33%   { opacity: 1; }
  16.66%  { opacity: 1; }
  19%     { opacity: 0; }
  100%    { opacity: 0; }
}

/* Computador: texto à esquerda, cenas à direita */
@media (min-width: 960px) {
  .abertura {
    grid-template-columns: 1fr 1.15fr;
    align-items: center;
    gap: 48px;
    padding-top: 56px; padding-bottom: 80px;
  }
}

/* ---------- Faixas abaixo do banner ---------- */
/* Cada faixa tem cor própria de ponta a ponta, alternando escuro e claro. */

.faixa { padding: 64px 24px; }

.faixa-dentro {
  display: grid;
  gap: 32px;
  max-width: 1140px; margin: 0 auto;
  align-items: center;
}

.faixa img {
  width: 100%;
  border-radius: 22px;
}

.faixa h2 {
  margin: 0;
  font-size: clamp(1.9rem, 6.4vw, 3rem);
  line-height: 1.06; letter-spacing: -0.025em;
  font-weight: 800;
  max-width: 15ch;
  text-wrap: balance;
}

.faixa p {
  margin: 16px 0 0;
  font-size: clamp(1.08rem, 2.2vw, 1.25rem);
  line-height: 1.55;
  max-width: 32ch;
}

.faixa-escura   { background: #2B2420; color: #F4EEE6; }
.faixa-escura p { color: #D9CCBD; }

.faixa-agua     { background: #DCE9E7; color: var(--preto); }
.faixa-agua p   { color: #3F5A5F; }

.faixa-petroleo   { background: #33586A; color: #FFFFFF; }
.faixa-petroleo p { color: #D3E2E7; }

.faixa-pessego   { background: #F6E3D6; color: var(--preto); }
.faixa-pessego p { color: #6B4A3C; }

@media (min-width: 900px) {
  .faixa { padding: 104px 48px; }

  .faixa-dentro {
    grid-template-columns: 1fr 1.15fr;
    gap: 72px;
  }

  .faixa-inverte .faixa-texto { order: 2; }
}
