@import url("https://fonts.googleapis.com/css2?family=Arimo:wght@400;700&family=League+Gothic&family=Oswald:wght@400;500;700&family=Poppins:wght@400;500;600;700&family=Righteous&display=swap");
@import url("https://fonts.cdnfonts.com/css/open-sauce-one");

:root {
  --dark: #171717;
  --dark-2: #292929;
  --cream: #ebdcc4;
  --lime: #d7ff3f;
  --off-white: #ede1cd;
  --text-dark: #292929;
  /* Mesma margem horizontal dos 3 cards da page-3 */
  --page-inline-pad: 4.49%;
  /* Ajuste fino quando o box verde era 2.252% — alinha conteúdo ao novo inset */
  --green-box-shift: calc(var(--page-inline-pad) - 2.252%);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: #070707;
  font-family: "Open Sauce One", "Arimo", sans-serif;
}

.portfolio {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.page {
  position: relative;
  width: min(100vw, 1440px);
  height: min(56.25vw, 810px);
  min-height: 420px;
  margin: 0 auto;
  overflow: hidden;
}

.page img {
  border-radius: 30px;
}

.editable {
  user-select: none;
}

.page p,
.page h1,
.page h2,
.page h3,
.page h4,
.page span,
.page div {
  white-space: pre-wrap;
}

/* PAGE 1 */
.page-1 {
  background: #dbfc55;
  --section-bg: #dbfc55;
  color: var(--cream);
}

.page-1 .hero-photo {
  position: absolute;
  left: 52%;
  bottom: 0;
  height: 93%;
  width: auto;
  object-fit: contain;
  z-index: 2;
  opacity: 0;
  transform: translateX(-50%) translateY(40px) scale(0.95);
  animation: heroEntrance 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.6s forwards;
  border-radius: 0;
}

/* O <picture> não interfere no layout (grid/absoluto do .hero-photo) */
.page-1 .hero-photo-picture {
  display: contents;
}

.portfolio-word {
  position: absolute;
  margin: 0;
  font-family: "Righteous", sans-serif;
  font-size: clamp(70px, 15.8vw, 228px);
  line-height: 0.9;
  letter-spacing: 0.01em;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  text-transform: uppercase;
  display: flex;
  justify-content: center;
  width: 100%;
  white-space: nowrap;
}

.portfolio-word.fill {
  color: #171717;
  z-index: 1;
}

.portfolio-word .letter {
  display: inline-block;
  opacity: 0;
  transform: translateY(60px) scale(0.85);
  animation: letterReveal 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.portfolio-word .letter:nth-child(1) { animation-delay: 0.1s; }
.portfolio-word .letter:nth-child(2) { animation-delay: 0.18s; }
.portfolio-word .letter:nth-child(3) { animation-delay: 0.26s; }
.portfolio-word .letter:nth-child(4) { animation-delay: 0.34s; }
.portfolio-word .letter:nth-child(5) { animation-delay: 0.42s; }
.portfolio-word .letter:nth-child(6) { animation-delay: 0.50s; }
.portfolio-word .letter:nth-child(7) { animation-delay: 0.58s; }
.portfolio-word .letter:nth-child(8) { animation-delay: 0.66s; }
.portfolio-word .letter:nth-child(9) { animation-delay: 0.74s; }

.page-1 .hero-type-copy {
  position: absolute;
  left: 6%;
  top: 64%;
  width: 36%;
  margin: 0;
  z-index: 3;
  font-family: "Poppins", sans-serif;
  font-size: clamp(15px, 1vw, 13.2px);
  line-height: 1.38;
  font-weight: 500;
  letter-spacing: 0;
  color: #171717;
}

.page-1 .hero-cta-group {
  position: absolute;
  left: 6%;
  top: 80%;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: clamp(6px, 0.8vw, 14px);
}

.page-1 .hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 10%;
  padding: 1em 1em;
  border: 3px solid #171717;
  border-radius: 999px;
  text-decoration: none;
  font-family: "Poppins", sans-serif;
  font-size: clamp(18px, 0.66vw, 14px);
  font-weight: 500;
  line-height: 1;
  color: #171717;
  background: transparent;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease;
  opacity: 0;
  animation: heroCtaIn 0.75s cubic-bezier(0.16, 1, 0.3, 1) 1.6s forwards,
             heroCtaFloat 3.2s ease-in-out 3.4s infinite;
}

.page-1 .hero-cta-group .hero-cta:nth-child(2) {
  animation-delay: 1.8s, 3.6s;
}

.page-1 .hero-cta-group .hero-cta:nth-child(1) {
  background: #171717;
  color: #dbfc55;
}

.page-1 .hero-cta-group .hero-cta:nth-child(1):hover {
  background: transparent;
  color: #171717;
}

.page-1 .hero-cta:hover {
  background: #171717;
  color: #dbfc55;
  transform: translateY(-1px);
}

@keyframes heroCtaIn {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.94);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes heroCtaFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

.page-1 .hero-type-copy.typewriter .typing-char {
  opacity: 0;
  display: inline-block;
}

.page-1 .hero-type-copy.typewriter.is-playing .typing-char {
  animation: typingReveal 0.04s linear forwards;
  animation-delay: var(--char-delay, 0s);
}

.page-1 .hero-type-copy.typewriter.is-playing::after {
  content: "";
  display: inline-block;
  width: 0.08em;
  height: 1.05em;
  margin-left: 0.08em;
  background: currentColor;
  vertical-align: -0.08em;
  animation: caretBlink 0.85s steps(1) infinite;
}

@keyframes caretBlink {
  0%,
  48% {
    opacity: 1;
  }
  49%,
  100% {
    opacity: 0;
  }
}

@keyframes letterReveal {
  0% {
    opacity: 0;
    transform: translateY(60px) scale(0.85);
    filter: blur(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes heroEntrance {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(40px) scale(0.95);
    filter: blur(6px);
  }
  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
    filter: blur(0);
  }
}


.page-1 .top-left,
.page-1 .bottom-left,
.page-1 .bottom-right {
  position: absolute;
  margin: 0;
  font-family: "Arimo", sans-serif;
  font-size: clamp(10px, 1.66vw, 24px);
  color: var(--cream);
  letter-spacing: 0.002em;
  z-index: 4;
}

.page-1 .top-left {
  left: 5.625%;
  top: 10.074%;
}

.page-1 .top-left.logo {
  height: auto;
  width: auto;
  transform: scale(0.6);
  transform-origin: top left;
  filter: brightness(0) saturate(100%) invert(49%) sepia(29%) saturate(853%) hue-rotate(116deg) brightness(94%) contrast(91%);
}

.page-1 .bottom-left {
  left: 5.625%;
  top: 86.596%;
}

.page-1 .bottom-right {
  right: 5.625%;
  top: 86.596%;
  left: auto;
}

.social-icons {
  position: absolute;
  right: 5.625%;
  top: 10%;
  z-index: 4;
  display: flex;
  gap: clamp(3px, 0.5vw, 7px);
}

.social-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(28px, 3.2vw, 44px);
  height: clamp(28px, 3.2vw, 44px);
  border: 1.5px solid #171717;
  border-radius: 50%;
  color: #171717;
  text-decoration: none;
  transition: background 0.3s ease, color 0.3s ease, transform 0.2s ease;
  opacity: 0;
  animation: socialBounceIn 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.social-icons a:nth-child(1) { animation-delay: 0.9s; }
.social-icons a:nth-child(2) { animation-delay: 1.02s; }
.social-icons a:nth-child(3) { animation-delay: 1.14s; }
.social-icons a:nth-child(4) { animation-delay: 1.26s; }
.social-icons a:nth-child(5) { animation-delay: 1.38s; }
.social-icons a:nth-child(6) { animation-delay: 1.5s; }

@keyframes socialBounceIn {
  0% {
    opacity: 0;
    transform: scale(0.3);
  }
  55% {
    opacity: 1;
    transform: scale(1.15);
  }
  75% {
    transform: scale(0.92);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.social-icons a:hover {
  background: #171717;
  color: #dbfc55;
  transform: scale(1.1);
}

.social-icons a svg {
  width: 48%;
  height: 48%;
}

/* PAGE 2 */
.page-2 {
  background: #171717;
  --section-bg: #171717;
  color: #fff;
}

.page-2 .collage-left,
.page-2 .collage-right {
  position: absolute;
  top: 44.1%;
  height: 46.1%;
  object-fit: cover;
  opacity: 0;
  transform: translateY(50px) scale(0.96);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-2 .collage-left {
  left: 5.625%;
  width: 22.589%;
  transition-delay: 0.35s;
}

.page-2 .collage-right {
  left: 29.792%;
  width: 64.563%;
  transition-delay: 0.5s;
}

.page-2-headline-block {
  position: absolute;
  left: 5.625%;
  top: 10.434%;
  z-index: 2;
  display: flex;
  align-items: stretch;
  gap: clamp(10px, 1.35vw, 20px);
  max-width: 48%;
}

.page-2-years-badge {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  align-self: stretch;
  min-width: clamp(52px, 7.2vw, 92px);
  padding: clamp(6px, 0.9vw, 12px) clamp(8px, 1.1vw, 14px);
  background: #d6ff3f;
  border-radius: clamp(12px, 1.5vw, 20px);
  color: #171717;
  text-align: center;
  opacity: 0;
  transform: translateX(-50px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-2-years-stack {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  margin-inline: auto;
  min-width: 0;
  box-sizing: border-box;
}

.page-2-years-num {
  display: block;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  font-family: "Righteous", sans-serif;
  font-size: clamp(36px, 5.8vw, 84px);
  font-weight: 500;
  line-height: 0.88;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
}

.page-2-years-label {
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin-top: clamp(0px, 0.175vw, 0px);
  font-family: "Poppins", sans-serif;
  font-size: clamp(22px, 2.7vw, 34px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: lowercase;
  text-align: center;
}

.page-2-headline-lines {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-width: 0;
}

.page-2 .page-2-headline-lines h2 {
  margin: 0;
  position: relative;
  left: auto;
  top: auto;
  font-family: "Righteous", sans-serif;
  font-size: clamp(32px, 5.4vw, 78px);
  letter-spacing: 0.002em;
  line-height: 0.92;
  font-weight: 500;
  opacity: 0;
  transform: translateX(-60px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-2 .page-2-headline-lines h2:nth-of-type(1) {
  font-size: clamp(24px, 4.05vw, 58.5px);
  transition-delay: 0.05s;
}

.page-2 .page-2-headline-lines h2:nth-of-type(2) {
  font-size: clamp(24px, 4.05vw, 58.5px);
  transition-delay: 0.15s;
}

.page-2 .page-2-headline-lines h2.accent {
  color: #d6ff3f;
  line-height: 0.82;
  transition-delay: 0.25s;
}

.page-2 .copy {
  position: absolute;
  left: 57.078%;
  top: 14.562%;
  width: 32.153%;
  margin: 0;
  font-family: "Poppins", sans-serif;
  color: var(--off-white);
  font-size: clamp(9px, 1.35vw, 19px);
  line-height: 1.349;
  letter-spacing: 0;
  white-space: normal;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s,
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s;
}

.page-2 .copy.typewriter .typing-char {
  opacity: 0;
  display: inline;
}

.page-2 .copy.typewriter.is-playing .typing-char {
  animation: typingReveal 0.04s linear forwards;
  animation-delay: var(--char-delay, 0s);
}

.page-2.visible .page-2-years-badge,
.page-2.visible .page-2-headline-lines h2,
.page-2.visible .copy,
.page-2.visible .collage-left,
.page-2.visible .collage-right {
  opacity: 1;
  transform: translate(0, 0) scale(1);
}

@keyframes typingReveal {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* PAGE 3 — título no fluxo do grid (abaixo dele vêm os cards); altura automática evita faixa preta vazia */
.page.page-3 {
  height: auto;
  min-height: 0;
}

.page-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  gap: clamp(6px, 1.2vw, 16px) 3.11%;
  align-items: start;
  align-content: start;
  padding: 0% var(--page-inline-pad) 2.5%;
  background: #171717;
  --section-bg: #171717;
  color: var(--text-dark);
  overflow: hidden;
  margin-bottom: 0;
}

.page-3 .title {
  grid-column: 1 / -1;
  grid-row: 1;
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  margin: 0 auto;
  width: 100%;
  font-family: "Righteous", sans-serif;
  color: #d6ff3f;
  font-size: clamp(72px, 10.8vw, 120px);
  font-weight: 500;
  letter-spacing: 0.006em;
  line-height: 0.95;
  text-align: center;
  white-space: nowrap;
  opacity: 0;
  filter: blur(8px);
}

.page-3 .card {
  position: relative;
  grid-row: 2;
  align-self: start;
  margin-top: 0;
  background: var(--lime);
  border-radius: 28px;
  overflow: hidden;
  opacity: 0;
  transform: translateY(70px) scale(0.96) rotateX(8deg);
  transform-origin: center bottom;
  filter: blur(6px);
}

.page-3 .card img {
  width: 100%;
  height: auto;
  display: block;
  transform: scale(1.06);
  transition: transform 1.1s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-3 .card h3 {
  margin: clamp(8px, 2.2vw, 18px) 7.7% 2.3%;
  font-family: "Righteous", sans-serif;
  font-size: clamp(12px, 1.98vw, 28px);
  line-height: 1.18;
  letter-spacing: 0;
}

.page-3 .card p {
  margin: 0 7.7% 7%;
  font-family: "Poppins", sans-serif;
  font-size: clamp(8px, 0.99vw, 14px);
  line-height: 1.498;
  letter-spacing: 0;
}

.page-3.visible .title {
  animation: page3TitleReveal 0.95s cubic-bezier(0.16, 1, 0.3, 1) 0.05s forwards;
}

.page-3.visible .card {
  animation: page3CardIn 0.95s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.page-3.visible .card:nth-of-type(1) {
  animation-delay: 0.18s;
}

.page-3.visible .card:nth-of-type(2) {
  animation-delay: 0.34s;
}

.page-3.visible .card:nth-of-type(3) {
  animation-delay: 0.5s;
}

.page-3.visible .card img {
  transform: scale(1);
}

@keyframes page3TitleReveal {
  0% {
    opacity: 0;
    transform: translateY(-22px);
    filter: blur(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes page3CardIn {
  0% {
    opacity: 0;
    transform: translateY(70px) scale(0.96) rotateX(8deg);
    filter: blur(6px);
  }
  65% {
    opacity: 1;
    transform: translateY(-6px) scale(1.01) rotateX(0deg);
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1) rotateX(0deg);
    filter: blur(0);
  }
}

/* PAGE CLIENTES + LOGOS (entre Portfólio e História) */
.page.page-clientes {
  height: auto;
  min-height: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.page-clientes {
  background: #171717;
  --section-bg: #171717;
  color: #fff;
  --clientes-section-pad-y: clamp(10px, 1.54vw, 20px);
  --clientes-section-pad-bottom: clamp(0px, 0.35vw, 4px);
  padding: var(--clientes-section-pad-y) var(--page-inline-pad)
    var(--clientes-section-pad-bottom);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  overflow: hidden;
}

.page-clientes .clientes-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  width: 100%;
  max-width: 100%;
}

/* Título clientes: linha 1 branca, linha 2 verde */
.page-clientes .clientes-intro {
  --clientes-lh-white: 0.52;
  --clientes-lh-accent: 0.35;
  --clientes-fs-line: clamp(20px, 3.35vw, 52px);
  width: 100%;
  max-width: min(100%, 56rem);
  margin-inline: auto;
  margin-bottom: clamp(-25px, -3.5vw, -7.5px);
  text-align: center;
}

.page-clientes .clientes-intro h2 {
  margin-top: 0;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 0;
  font-family: "Righteous", sans-serif;
  letter-spacing: 0.002em;
  font-weight: 500;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.page-clientes .clientes-intro h2:first-of-type {
  font-size: var(--clientes-fs-line);
  line-height: var(--clientes-lh-white);
  transition-delay: 0.05s;
  white-space: nowrap;
}

.page-clientes .clientes-count-num {
  display: inline-block;
  font-variant-numeric: tabular-nums;
  min-width: 3ch;
  text-align: center;
}

.page-clientes .clientes-intro h2.accent {
  font-size: clamp(28px, 4.6vw, 72px);
  line-height: var(--clientes-lh-accent);
  margin-top: clamp(-4px, 0.1vw, 2px);
  margin-bottom: clamp(-18px, -2.25vw, -5px);
  color: #d6ff3f;
  transition-delay: 0.15s;
  white-space: nowrap;
}

@media (max-width: 720px) {
  .page-clientes .clientes-intro h2:first-of-type,
  .page-clientes .clientes-intro h2.accent {
    white-space: normal;
  }

  .page-clientes .clientes-intro {
    margin-bottom: clamp(-22px, -1.5vw, -2px);
  }

  .page-clientes .clientes-intro h2.accent {
    margin-bottom: clamp(-8px, -1.25vw, 0px);
  }

  .page-clientes .clientes-marquee-column {
    margin-top: clamp(-18px, -4.4vw, -8px);
  }
}

.page-clientes.visible .clientes-intro h2 {
  opacity: 1;
  transform: translateY(0);
}

.page-clientes .clientes-marquee-column {
  width: 100%;
  min-width: 0;
  container-type: inline-size;
  container-name: clientes-marquee;
  /* +25% mais próximo do título vs. valor anterior */
  margin-top: clamp(-45px, -6.25vw, -18px);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.12s,
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.12s;
}

.page-clientes.visible .clientes-marquee-column {
  opacity: 1;
  transform: translateY(0);
}

.page-clientes .clientes-marquee-viewport {
  overflow: hidden;
  width: 100%;
  mask-image: linear-gradient(
    90deg,
    transparent,
    #000 6%,
    #000 94%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    90deg,
    transparent,
    #000 6%,
    #000 94%,
    transparent
  );
}

.page-clientes .clientes-marquee-track {
  display: flex;
  width: max-content;
  animation: clientesMarqueeScroll 27.5s linear infinite;
  will-change: transform;
}

.page-clientes .clientes-marquee-sequence {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: clamp(0px, 0.2vw, 4px);
  padding-right: clamp(2px, 0.25vw, 6px);
}

.page-clientes .clientes-logo-item {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Fallback sem container queries: ~6 logos na largura da viewport */
  width: clamp(52px, 14.6vw, 200px);
  min-width: 52px;
}

@supports (width: 1cqi) {
  .page-clientes .clientes-logo-item {
    /* 6 logos visíveis; 5× gap (igual ao flex gap da sequência) */
    width: calc((100cqi - 5 * clamp(0px, 0.2vw, 4px)) / 6);
    max-width: none;
  }
}

.page-clientes .clientes-logo-item img {
  width: 100%;
  height: auto;
  max-height: clamp(88px, 10.4vw, 128px);
  object-fit: contain;
  display: block;
  filter: brightness(1.05);
}

@keyframes clientesMarqueeScroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-clientes .clientes-marquee-track {
    animation-duration: 60s;
  }
}

@media (prefers-reduced-motion: reduce) and (max-width: 720px) {
  .page-clientes .clientes-marquee-track {
    animation: none;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
    row-gap: 3px;
  }

  .page-clientes .clientes-marquee-sequence[aria-hidden="true"] {
    display: none;
  }
}

@media (max-width: 900px) {
  .page-clientes .clientes-marquee-column {
    margin-top: clamp(-65px, -7.5vw, -12px);
  }

  .page-clientes .clientes-intro {
    max-width: 100%;
  }

  .page-clientes .clientes-marquee-viewport {
    mask-image: none;
    -webkit-mask-image: none;
  }
}

/* PAGE HISTÓRIA (Timeline) */
.page.page-historia {
  height: auto;
  min-height: 0;
}

.page-historia {
  background: #171717;
  --section-bg: #171717;
  color: var(--off-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  /* padding-bottom −80% (20% do valor anterior) — aproxima da seção vídeo/Instagram */
  padding: clamp(4px, 0.7vw, 12px) var(--page-inline-pad) clamp(10px, 1.2vw, 20px);
  overflow: visible;
}

.page-historia .historia-banner {
  position: relative;
  width: 100%;
  background: #d6ff3f;
  border-radius: clamp(18px, 2.2vw, 32px);
  padding: clamp(16px, 2vw, 30px) clamp(20px, 2.8vw, 40px) clamp(20px, 3vw, 44px);
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 1.8vw, 26px);
  margin-bottom: clamp(30px, 4vw, 60px);
  opacity: 0;
  transform: translateY(30px) scale(0.97);
}

.page-historia .historia-banner-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-historia .historia-banner-tags {
  display: flex;
  align-items: center;
  gap: clamp(6px, 0.7vw, 12px);
}

.page-historia .historia-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  height: clamp(34px, 3.5vw, 50px);
  padding: 0 1.2em;
  border: 3px solid #292929;
  border-radius: 999px;
  background: transparent;
  color: #292929;
  font-family: "Poppins", sans-serif;
  font-size: clamp(11px, 1.15vw, 18px);
  font-weight: 500;
  line-height: 1.15;
  text-decoration: none;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
}

.page-historia .historia-desde {
  font-family: "Righteous", sans-serif;
  font-size: clamp(16px, 2vw, 30px);
  font-weight: 500;
  color: #171717;
  letter-spacing: 0;
  line-height: 1.18;
}

.page-historia .historia-banner-main {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 28px);
  width: 100%;
}

.page-historia .historia-capsule {
  flex: 1 1 auto;
  height: clamp(50px, 7vw, 100px);
  background: #171717;
  border-radius: 999px;
}

.page-historia .historia-title {
  margin: 0;
  flex: 0 0 auto;
  font-family: "Righteous", sans-serif;
  font-size: clamp(60px, 11.5vw, 166px);
  font-weight: 500;
  letter-spacing: 0.002em;
  line-height: 0.9;
  color: #171717;
  text-transform: uppercase;
}

.page-historia .historia-banner-notch {
  position: absolute;
  bottom: -20px;
  left: clamp(30px, 6%, 90px);
  width: 0;
  height: 0;
  border-left: 22px solid transparent;
  border-right: 22px solid transparent;
  border-top: 22px solid #d6ff3f;
}

.page-historia.visible .historia-banner {
  animation: historiaBannerIn 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
}

@keyframes historiaBannerIn {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.page-historia .timeline {
  --timeline-gap: clamp(12px, 2vw, 28px);
  --timeline-dot-size: clamp(12px, 1.4vw, 20px);
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--timeline-gap);
  width: 100%;
  max-width: 1200px;
}

.page-historia .timeline-line {
  position: absolute;
  top: calc(var(--timeline-dot-size) / 2 - 1px);
  left: calc(
    (100% - 3 * var(--timeline-gap)) / 8 - var(--timeline-dot-size) / 2
  );
  width: calc(
    75% + (3 * var(--timeline-gap) / 4) + var(--timeline-dot-size)
  );
  right: auto;
  height: 2px;
  background: linear-gradient(90deg, #d6ff3f 0%, rgba(214, 255, 63, 0.3) 50%, #d6ff3f 100%);
  z-index: 1;
}

.page-historia .timeline-item {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  opacity: 0;
  transform: translateY(40px);
}

.page-historia .timeline-dot {
  width: var(--timeline-dot-size);
  height: var(--timeline-dot-size);
  background: #d6ff3f;
  border: 3px solid #171717;
  border-radius: 50%;
  margin-bottom: clamp(14px, 1.8vw, 26px);
  box-shadow: 0 0 0 3px #d6ff3f;
  flex-shrink: 0;
}

.page-historia .timeline-item h3 {
  margin: 0 0 clamp(8px, 0.8vw, 14px);
  font-family: "Righteous", sans-serif;
  font-size: clamp(16px, 2vw, 28px);
  color: #d6ff3f;
  letter-spacing: 0.01em;
  line-height: 1.15;
}

.page-historia .timeline-item p {
  margin: 0;
  font-family: "Poppins", sans-serif;
  font-size: clamp(10px, 0.95vw, 14px);
  line-height: 1.55;
  color: rgba(237, 225, 205, 0.75);
  max-width: 90%;
}

.page-historia.visible .timeline-item {
  animation: historiaItemIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.page-historia.visible .timeline-item:nth-child(2) {
  animation-delay: 0.3s;
}

.page-historia.visible .timeline-item:nth-child(3) {
  animation-delay: 0.45s;
}

.page-historia.visible .timeline-item:nth-child(4) {
  animation-delay: 0.6s;
}

.page-historia.visible .timeline-item:nth-child(5) {
  animation-delay: 0.75s;
}

@keyframes historiaFadeUp {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes historiaItemIn {
  0% {
    opacity: 0;
    transform: translateY(40px);
  }
  65% {
    opacity: 1;
    transform: translateY(-4px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .page-historia .timeline {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-historia .timeline-line {
    display: none;
  }
}

/* PAGE MÍDIA — YouTube + Instagram (abaixo de História) */
.page.page-media {
  height: auto;
  min-height: 0;
}

.page-media {
  background: #171717;
  --section-bg: #171717;
  color: var(--off-white);
  /* padding vertical +20% vs. 15/1.7vw/20 e 28/4vw/56 */
  padding: clamp(60px, 5.04vw, 44px) var(--page-inline-pad) clamp(90px, 4.8vw, 67px);
  overflow: hidden;
}

.page-media-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(20px, 3.5vw, 40px);
  /* Colunas com altura própria; altura do vídeo = coluna Instagram via JS */
  align-items: start;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
}

.page-media-col--video {
  min-width: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-self: start;
}

.page-media-video-shell {
  position: relative;
  width: 100%;
  min-height: 140px;
  border-radius: clamp(16px, 2vw, 28px);
  overflow: hidden;
  background: #0a0a0a;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.page-media-youtube {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: inherit;
}

.page-media-col--instagram {
  display: flex;
  flex-direction: column;
  gap: clamp(10px, 1.4vw, 18px);
  align-items: stretch;
  min-width: 0;
}

.page-media-instagram-head {
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  width: 100%;
}

.page-media-instagram-handle {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(3px, 0.425vw, 5px);
  margin-top: clamp(4px, 0.575vw, 7px);
  color: var(--off-white);
  text-decoration: none;
  font-family: "Poppins", sans-serif;
  font-size: clamp(13px, 1.35vw, 17px);
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.25s ease;
}

.page-media-instagram-handle:hover,
.page-media-instagram-handle:focus-visible {
  color: #d6ff3f;
}

.page-media-instagram-handle:focus-visible {
  outline: 2px solid #d6ff3f;
  outline-offset: 4px;
}

.page-media-instagram-handle-icon {
  width: clamp(18px, 2vw, 24px);
  height: clamp(18px, 2vw, 24px);
  flex-shrink: 0;
}

.page-media .page-media-instagram-label {
  margin: 0;
  padding: 0;
  font-family: "Righteous", sans-serif;
  font-size: clamp(30px, 4.8vw, 56px);
  color: #d6ff3f;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 0.92;
  width: 100%;
  white-space: normal;
  text-align: left;
}

.page-media-instagram-widget {
  width: 100%;
  min-height: 120px;
  border-radius: clamp(12px, 1.6vw, 20px);
  overflow: hidden;
  line-height: 0;
  position: relative;
  z-index: 0;
  /* Recorta a faixa do SnapWidget com @agenciameasure sobre o feed */
  --snapwidget-header-crop: clamp(40px, 5.5vw, 56px);
}

/* iframe inline deixa vão sob a linha de base — display:block remove esse gap */
.page-media-instagram-widget iframe {
  display: block;
  width: 100% !important;
  border: 0;
  border-radius: inherit;
  position: relative;
  top: calc(-1 * var(--snapwidget-header-crop));
  margin-bottom: calc(-1 * var(--snapwidget-header-crop));
}

.page-media-instagram-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  background: #2a2a2a;
  border-radius: clamp(12px, 1.6vw, 20px);
}

.page-media-instagram-fallback a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #d6ff3f;
  text-decoration: none;
  font-family: "Poppins", sans-serif;
  font-size: clamp(13px, 1.5vw, 17px);
  font-weight: 500;
  padding: 14px 28px;
  border: 2px solid rgba(214, 255, 63, 0.4);
  border-radius: 50px;
  transition: background 0.2s, border-color 0.2s;
}

.page-media-instagram-fallback a:hover {
  background: rgba(214, 255, 63, 0.12);
  border-color: #d6ff3f;
}

.page-media-instagram-fallback svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.page-media .page-media-video-shell,
.page-media .page-media-instagram-widget {
  opacity: 0;
  transform: translateY(22px);
}

.page-media.visible .page-media-video-shell,
.page-media.visible .page-media-instagram-widget {
  animation: pageMediaIn 0.75s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.page-media.visible .page-media-video-shell {
  animation-delay: 0.04s;
}

.page-media.visible .page-media-instagram-widget {
  animation-delay: 0.12s;
}

@keyframes pageMediaIn {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-media .page-media-video-shell,
  .page-media .page-media-instagram-widget {
    opacity: 1;
    transform: none;
    animation: none !important;
  }
}

@media (max-width: 900px) {
  .page-media-inner {
    grid-template-columns: 1fr;
    gap: clamp(24px, 5vw, 36px);
  }

  .page-media-video-shell {
    height: auto !important;
    aspect-ratio: 16 / 9;
  }
}

/* PAGE 4 */
.page.page-4 {
  height: auto;
  min-height: 0;
}

.page-4 {
  background: #171717;
  --section-bg: #171717;
  color: var(--dark);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-4::before {
  content: "";
  position: absolute;
  left: var(--page-inline-pad);
  top: 0;
  width: calc(100% - 2 * var(--page-inline-pad));
  height: 100%;
  min-height: 100%;
  background: var(--lime);
  border-radius: clamp(18px, 2.2vw, 32px) clamp(18px, 2.2vw, 32px) 0 0;
  z-index: 1;
}

/* Mesma largura do ::before — título + grid centralizados no verde */
.page-4-inner {
  position: relative;
  z-index: 2;
  width: calc(100% - 2 * var(--page-inline-pad));
  max-width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  box-sizing: border-box;
  /* margem topo do título: +35% em relação ao valor anterior (11px / 1.75vw / 25px) */
  padding: clamp(15px, 2.36vw, 34px) clamp(10px, 1.2vw, 20px) clamp(12px, 1.6vw, 22px);
  gap: clamp(12px, 1.8vw, 26px);
  min-height: 0;
}

.page-4 .headline {
  /* +25% de espaço acima do título (25% do padding-top que envolve a seção) */
  margin: clamp(5.75px, 1vw, 10.5px) 0 0;
  position: relative;
  left: auto;
  top: auto;
  width: 100%;
  text-align: center;
  font-family: "Righteous", sans-serif;
  font-size: clamp(80px, 12vw, 173px);
  line-height: 1;
  letter-spacing: 0.002em;
  font-weight: 700;
  z-index: 2;
}

.page-4 .deliverable-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(10px, 2.2vw, 24px);
  width: 100%;
  align-items: stretch;
}

.deliverable {
  position: relative;
  top: auto;
  left: auto;
  width: 100%;
  min-height: clamp(220px, 36vw, 400px);
  height: auto;
  background: #292929;
  color: var(--off-white);
  border-radius: clamp(16px, 2vw, 28px);
  overflow: hidden;
  padding: 6% 7%;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-sizing: border-box;
}

.deliverable .index {
  position: relative;
  flex-shrink: 0;
  width: clamp(48px, 26%, 88px);
  aspect-ratio: 1;
  margin: 0 0 clamp(10px, 1.2vw, 18px);
  background: var(--lime);
  color: #171717;
  display: grid;
  place-items: center;
  font-size: clamp(18px, 2.33vw, 34px);
  font-weight: 700;
}

.deliverable h3 {
  /* 50% do espaço anterior entre título e parágrafo */
  margin: 0 0 clamp(5px, 0.55vw, 8px);
  font-family: "Righteous", sans-serif;
  font-size: clamp(18px, 2.33vw, 34px);
  line-height: 1.18;
  letter-spacing: 0;
  text-align: center;
  max-width: 100%;
}

.deliverable p {
  margin: 0;
  font-family: "Poppins", sans-serif;
  font-size: clamp(9px, 1.2vw, 17px);
  line-height: 1.47;
  letter-spacing: 0;
  text-align: center;
  max-width: 100%;
}

.deliverable-cta {
  margin-top: clamp(10px, 1.4vw, 20px);
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45em;
  padding: 0.55em 1.15em;
  border-radius: 999px;
  border: 2px solid var(--lime);
  background: var(--lime);
  color: #171717;
  font-family: "Poppins", sans-serif;
  font-size: clamp(10px, 1.05vw, 15px);
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease,
    box-shadow 0.25s ease;
}

.deliverable-cta:hover {
  background: transparent;
  color: var(--lime);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.deliverable-cta-icon {
  width: clamp(15px, 1.35vw, 20px);
  height: clamp(15px, 1.35vw, 20px);
  flex-shrink: 0;
  display: inline-flex;
}

.deliverable-cta-icon svg {
  width: 100%;
  height: 100%;
}

/* PAGE 5 */
.page-5 {
  background: #171717;
  --section-bg: #171717;
  color: #292929;
}

@media (min-width: 768px) {
  /* Fundo full-bleed por seção (desktop/tablet), mantendo conteúdo limitado */
  .portfolio > .page {
    box-shadow: 0 0 0 100vmax var(--section-bg, transparent);
    clip-path: inset(0 -100vmax);
  }
}

.page-5::before {
  content: "";
  position: absolute;
  left: var(--page-inline-pad);
  top: -11.614%;
  width: calc(100% - 2 * var(--page-inline-pad));
  height: 100%;
  background: var(--lime);
  border-radius: clamp(18px, 2.2vw, 32px);
}

/* Faixa superior: botões à esquerda, linha+círculos à direita */
.page-5 .top-strip {
  position: absolute;
  left: calc(5.552% + var(--green-box-shift));
  right: calc(5.552% + var(--green-box-shift));
  top: 4.8%;
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.2vw, 18px);
  z-index: 2;
}

.page-5 .top-buttons {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: clamp(6px, 0.8vw, 14px);
  flex: 0 0 auto;
}

.page-5 .top-buttons .top-btn {
  position: relative;
  flex: 0 1 auto;
  min-width: 0;
  height: clamp(34px, 3.5vw, 50px);
  border: 3px solid #292929;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Poppins", sans-serif;
  font-size: clamp(11px, 1.15vw, 18px);
  font-weight: 500;
  line-height: 1.15;
  padding: 0 1.2em;
  text-decoration: none;
  color: #292929;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
}

.page-5 .top-buttons .top-btn:hover {
  background: #292929;
  color: var(--lime);
  transform: translateY(-1px);
  box-shadow: 0 7px 24px rgba(0, 0, 0, 0.2);
}

.page-5 .top-buttons .top-btn:first-child {
  background: #292929;
  color: var(--lime);
}

.page-5 .top-buttons .top-btn:first-child:hover {
  background: transparent;
  color: #292929;
}

.page-5 .top-buttons .top-mid {
  gap: 0.5em;
}

.page-5 .btn-whatsapp {
  width: clamp(17px, 1.45vw, 22px);
  height: clamp(17px, 1.45vw, 22px);
  flex-shrink: 0;
  display: inline-flex;
}

.page-5 .btn-whatsapp svg {
  width: 100%;
  height: 100%;
}

.page-5 .top-right-decoration {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: clamp(8px, 0.8vw, 14px);
}

.page-5 .top-line {
  flex: 1 1 auto;
  min-width: 0;
  border-top: 2px solid #292929;
}

.page-5 .top-squares {
  display: flex;
  gap: 8px;
  flex: 0 0 auto;
}

.page-5 .top-squares span {
  width: 22px;
  height: 22px;
  border-radius: 50%;
}

.page-5 .top-squares span:nth-child(1) {
  background: #292929;
}

.page-5 .top-squares span:nth-child(2) {
  background: transparent;
  border: 3px solid #292929;
}

.page-5 .top-squares span:nth-child(3) {
  background: transparent;
  border: 3px solid #292929;
  box-shadow: inset 0 0 0 5px #292929;
}

.page-5 h2 {
  position: absolute;
  top: 15.584%;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  font-family: "Righteous", sans-serif;
  /* Menor que THANK YOU — “VAMOS CONVERSAR?” em uma linha dentro do verde */
  font-size: clamp(34px, 5.35vw, 98px);
  letter-spacing: 0.002em;
  line-height: 0.98;
  white-space: nowrap;
  max-width: calc(100% - 2 * var(--page-inline-pad) - 6%);
  text-align: center;
  z-index: 2;
}

.page-5 .contact-form {
  position: absolute;
  top: 29%;
  left: 50%;
  transform: translateX(-50%);
  width: min(72%, 840px);
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1vw, 14px);
  padding-bottom: clamp(14px, 1.6vw, 26px);
}

.page-5 .contact-form .hp-field {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

.page-5 .contact-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(8px, 1vw, 14px);
}

.page-5 .contact-form label {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.page-5 .contact-form label.full {
  grid-column: 1 / -1;
}

.page-5 .contact-form label span {
  font-family: "Poppins", sans-serif;
  font-size: clamp(11px, 0.9vw, 14px);
  font-weight: 600;
  color: #171717;
}

.page-5 .contact-form input,
.page-5 .contact-form textarea {
  width: 100%;
  border: 2px solid #171717;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.28);
  color: #171717;
  font-family: "Poppins", sans-serif;
  font-size: clamp(12px, 1vw, 15px);
  padding: clamp(8px, 0.7vw, 12px) clamp(10px, 0.9vw, 14px);
  outline: none;
}

.page-5 .contact-form textarea {
  resize: vertical;
  min-height: 84px;
  max-height: 140px;
}

.page-5 .contact-form input:focus,
.page-5 .contact-form textarea:focus {
  border-color: #292929;
  box-shadow: 0 0 0 2px rgba(23, 23, 23, 0.15);
}

.page-5 .contact-form button {
  align-self: center;
  border: 2px solid #171717;
  border-radius: 999px;
  background: #171717;
  color: #d7ff3f;
  font-family: "Poppins", sans-serif;
  font-size: clamp(12px, 1vw, 16px);
  font-weight: 600;
  padding: clamp(8px, 0.75vw, 12px) clamp(16px, 1.5vw, 24px);
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease;
}

.page-5 .contact-form button:hover {
  background: transparent;
  color: #171717;
  transform: translateY(-1px);
}

.page-5 .contact-form-feedback {
  margin: 0;
  min-height: 1.2em;
  font-family: "Poppins", sans-serif;
  font-size: clamp(11px, 0.95vw, 14px);
  font-weight: 600;
  color: #171717;
}

.page-5 .contact-form-feedback:empty {
  display: none;
}

.page-5 .contact-form-feedback.is-success {
  color: #115c10;
}

.page-5 .contact-form-feedback.is-error {
  color: #8b1212;
}

/* Modal — confirmação de envio do formulário */
.contact-success-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 28px);
  box-sizing: border-box;
}

.contact-success-modal[hidden] {
  display: none !important;
}

.contact-success-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, 0.78);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.contact-success-modal__dialog {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: min(92vw, 440px);
  margin: 0;
  padding: clamp(28px, 5vw, 40px) clamp(22px, 4vw, 36px);
  background: #171717;
  border: 3px solid #d6ff3f;
  border-radius: clamp(18px, 2.2vw, 28px);
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.55);
  text-align: center;
  box-sizing: border-box;
  animation: contactSuccessModalIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.contact-success-modal__message {
  margin: 0 0 clamp(20px, 3.5vw, 28px);
  font-family: "Poppins", sans-serif;
  font-size: clamp(16px, 2.1vw, 22px);
  font-weight: 600;
  line-height: 1.45;
  color: var(--off-white);
}

.contact-success-modal__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: clamp(140px, 36vw, 200px);
  padding: clamp(10px, 1.2vw, 14px) clamp(22px, 3vw, 32px);
  border: 2px solid #171717;
  border-radius: 999px;
  background: #d6ff3f;
  color: #171717;
  font-family: "Poppins", sans-serif;
  font-size: clamp(13px, 1.15vw, 16px);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.contact-success-modal__btn:hover {
  background: #171717;
  color: #d6ff3f;
  border-color: #d6ff3f;
  transform: translateY(-1px);
}

.contact-success-modal__btn:focus-visible {
  outline: 3px solid #d6ff3f;
  outline-offset: 3px;
}

@keyframes contactSuccessModalIn {
  from {
    opacity: 0;
    transform: scale(0.94) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .contact-success-modal__dialog {
    animation: none;
  }
}

.page-5 .contact-social-icons {
  display: flex;
  justify-content: center;
  width: 100%;
  align-items: center;
  gap: clamp(5px, 0.5vw, 8px);
  margin-top: clamp(6px, 0.8vw, 12px);
}

.page-5 .contact-social-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(28px, 3.2vw, 44px);
  height: clamp(28px, 3.2vw, 44px);
  border: 1.5px solid #171717;
  border-radius: 50%;
  color: #171717;
  text-decoration: none;
  transition: background 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.page-5 .contact-social-icons a:hover {
  background: #171717;
  color: #dbfc55;
  transform: scale(1.1);
}

.page-5 .contact-social-icons a svg {
  width: 48%;
  height: 48%;
}

.page-5 .contacts {
  position: absolute;
  left: 5.98%;
  right: 5.98%;
  bottom: clamp(14px, 2vw, 30px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.8%;
  z-index: 2;
}

.page-5 .contacts > div {
  flex: 1 1 0;
  display: flex;
  justify-content: center;
}

.page-5 .contacts h4 {
  margin: 0 0 8%;
  color: #d6ff3f;
  font-size: clamp(11px, 1.35vw, 20px);
  letter-spacing: 0;
  line-height: 1.1;
}

.page-5 .contacts p {
  margin: 0;
  color: var(--off-white);
  font-size: clamp(11px, 1.55vw, 24px);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.15;
  white-space: nowrap;
}

.page-5 .contacts .phone-line {
  display: inline-flex;
  align-items: center;
  gap: clamp(6px, 0.55vw, 10px);
}

.page-5 .contacts .phone-whatsapp {
  width: clamp(14px, 1.35vw, 22px);
  height: clamp(14px, 1.35vw, 22px);
  display: inline-flex;
  flex-shrink: 0;
}

.page-5 .contacts .phone-whatsapp svg {
  width: 100%;
  height: 100%;
}

@media (max-width: 980px) {
  .page {
    min-height: 520px;
  }

  .page-5 .contact-form {
    width: min(84%, 840px);
  }

  .page-5 .contact-form-grid {
    grid-template-columns: 1fr;
  }

  .page-5 .contact-form label.full {
    grid-column: auto;
  }
}

/* Celular: <768px (iPad portrait 768px+ mantém o layout “tablet/desktop” atual) */
@media (max-width: 767px) {
  :root {
    /* Mesmo recuo horizontal do conteúdo: alinha o verde de Soluções e Vamos conversar */
    --mobile-lime-inset: clamp(12px, 4vw, var(--page-inline-pad));
  }

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

  body {
    overflow-x: hidden;
  }

  .page {
    width: 100%;
    max-width: 100%;
    min-height: 0 !important;
  }

  .page img {
    border-radius: clamp(14px, 4vw, 22px);
  }

  /* —— Page 1 —— (mobile: logo → foto → ATENÇÃO → texto → CTAs → redes) */
  .page.page-1 {
    --p1-hero-pad-x: clamp(14px, 4.5vw, 20px);
    display: grid;
    /* minmax(0,1fr) evita overflow horizontal por min-width:auto dos filhos */
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    justify-items: stretch;
    height: auto !important;
    min-height: 0 !important;
    overflow-x: hidden;
    overflow-y: visible;
    padding: clamp(16px, 4vw, 24px) var(--p1-hero-pad-x) clamp(20px, 6vw, 32px);
  }

  .page-1 .top-left.logo {
    position: relative;
    grid-row: 1;
    grid-column: 1;
    justify-self: center;
    left: auto;
    top: auto;
    display: block;
    width: auto;
    /* +25% base; +15% adicional vs. min(250px, 90vw) */
    max-width: min(288px, 94vw);
    height: auto;
    transform: none;
    transform-origin: center center;
    /* +20% vs. padding-top da secção; logo→foto: −50% outra vez vs. clamp(2px,0.375vw,3px) */
    margin: calc(0.2 * clamp(16px, 4vw, 24px)) 0 clamp(1px, 0.1875vw, 1.5px);
  }

  /* ATENÇÃO: abaixo da foto; largura total + tipo maior para preencher a faixa */
  .page-1 .portfolio-word {
    grid-row: 3;
    grid-column: 1;
    position: relative;
    z-index: auto;
    align-self: center;
    justify-self: stretch;
    width: calc(100% + 2 * var(--p1-hero-pad-x));
    max-width: none;
    box-sizing: border-box;
    left: auto;
    right: auto;
    top: auto;
    margin: clamp(10px, 3vw, 18px) 0 clamp(4px, 1.4vw, 8px);
    margin-left: calc(-1 * var(--p1-hero-pad-x));
    margin-right: calc(-1 * var(--p1-hero-pad-x));
    padding: 0;
    transform: none;
    justify-content: center;
    flex-wrap: nowrap;
    white-space: nowrap;
    font-size: clamp(52px, 17.5vw, 82px);
    line-height: 0.9;
    pointer-events: none;
  }

  .page-1 .portfolio-word .letter {
    flex: 0 0 auto;
  }

  .page-1 .hero-photo {
    grid-row: 2;
    grid-column: 1;
    position: relative;
    z-index: auto;
    align-self: center;
    justify-self: stretch;
    left: auto;
    bottom: auto;
    /* Largura total (full-bleed); height:auto mantém proporção da imagem */
    width: calc(100% + 2 * var(--p1-hero-pad-x));
    max-width: none;
    min-width: 0;
    height: auto;
    max-height: none;
    margin-left: calc(-1 * var(--p1-hero-pad-x));
    margin-right: calc(-1 * var(--p1-hero-pad-x));
    margin-top: 0;
    margin-bottom: 0;
    display: block;
    object-fit: contain;
    border-radius: 0;
    opacity: 0;
    filter: none;
    transform: translateY(12px) scale(0.98);
    animation: heroPhotoMobileIn 1s cubic-bezier(0.16, 1, 0.3, 1) 0.35s forwards;
  }

  .page-1 .hero-type-copy {
    grid-row: 4;
    grid-column: 1;
    position: relative;
    left: auto;
    top: auto;
    justify-self: center;
    width: 100%;
    max-width: min(100%, 22rem);
    min-width: 0;
    /* −30% no margin-top vs. clamp(14px, 4vw, 22px): gap ATENÇÃO → parágrafo */
    margin: clamp(10px, 2.8vw, 15px) auto clamp(12px, 3.5vw, 18px);
    font-size: clamp(13px, 3.6vw, 15px);
    line-height: 1.42;
    text-align: center;
  }

  .page-1 .hero-cta-group {
    grid-row: 5;
    grid-column: 1;
    position: relative;
    left: auto;
    top: auto;
    justify-self: center;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0 0 clamp(14px, 4vw, 20px);
    gap: clamp(8px, 2.5vw, 14px);
  }

  .page-1 .hero-cta {
    flex: 0 1 auto;
    min-width: min(100%, 140px);
    font-size: clamp(12px, 3.2vw, 14px);
    padding: 0.75em 1em;
  }

  .page-1 .social-icons {
    grid-row: 6;
    grid-column: 1;
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    justify-self: center;
    align-self: center;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    gap: 3px;
  }

  .page-1 .social-icons a {
    width: clamp(26px, 7.5vw, 34px);
    height: clamp(26px, 7.5vw, 34px);
  }

  @keyframes heroPhotoMobileIn {
    from {
      opacity: 0;
      transform: translateY(12px) scale(0.98);
    }
    to {
      opacity: 1;
      transform: translateY(0) scale(1);
    }
  }

  /* —— Page 2 —— */
  .page.page-2 {
    --page-2-mobile-row-gap: clamp(12px, 3.5vw, 18px);
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto auto;
    gap: var(--page-2-mobile-row-gap);
    height: auto !important;
    min-height: 0 !important;
    overflow: visible;
    padding: clamp(18px, 5vw, 26px) var(--page-inline-pad) clamp(24px, 7vw, 40px);
    align-content: start;
  }

  .page-2-headline-block {
    grid-column: 1 / -1;
    grid-row: 1;
    justify-self: center;
    position: relative;
    left: auto;
    top: auto;
    width: max-content;
    max-width: 100%;
    flex-direction: row;
    align-items: stretch;
    gap: clamp(10px, 3vw, 16px);
    margin-top: calc(1.35 * var(--page-2-mobile-row-gap));
    margin-bottom: calc(1.35 * var(--page-2-mobile-row-gap));
  }

  .page-2-years-badge {
    flex: 0 0 auto;
    align-self: stretch;
    width: auto;
    min-width: clamp(56px, 17vw, 88px);
    padding: clamp(8px, 2.5vw, 14px) clamp(10px, 3vw, 16px);
  }

  .page-2-headline-lines {
    flex: 0 1 auto;
    min-width: 0;
    width: auto;
    align-items: flex-start;
    text-align: left;
  }

  .page-2 .page-2-headline-lines h2 {
    text-align: left;
    width: auto;
    max-width: 100%;
  }

  .page-2 .collage-left {
    grid-column: 1;
    grid-row: 2;
    position: relative;
    left: auto;
    top: auto;
    width: 100% !important;
    height: clamp(120px, 32vw, 200px) !important;
    opacity: 1;
    transform: none;
    object-fit: cover;
  }

  .page-2 .collage-right {
    grid-column: 2;
    grid-row: 2;
    position: relative;
    left: auto;
    top: auto;
    width: 100% !important;
    height: clamp(120px, 32vw, 200px) !important;
    opacity: 1;
    transform: none;
    object-fit: cover;
  }

  .page-2 .copy {
    grid-column: 1 / -1;
    grid-row: 3;
    position: relative;
    left: auto;
    top: auto;
    width: 100% !important;
    max-width: 100%;
    margin: 0;
    font-size: clamp(12px, 3.4vw, 15px);
    line-height: 1.45;
    text-align: center;
    opacity: 1;
    transform: none;
  }

  .page-2 .page-2-years-badge,
  .page-2 .page-2-headline-lines h2 {
    opacity: 1;
    transform: none;
  }

  /* —— Page 3 —— */
  .page-3 {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    gap: clamp(14px, 4vw, 22px);
    padding: clamp(16px, 4.5vw, 24px) var(--page-inline-pad)
      clamp(20px, 6vw, 32px);
  }

  .page-3 .card + .card {
    margin-top: clamp(14px, 4vw, 22px);
  }

  .page-3 .title {
    white-space: normal;
    font-size: clamp(44px, 13vw, 68px);
    line-height: 0.98;
    margin-bottom: clamp(4px, 1vw, 8px);
  }

  .page-3 .card {
    grid-row: auto;
    grid-column: 1;
  }

  .page-3 .card h3 {
    font-size: clamp(30px, 8.4vw, 44px);
    /* Espaço título → parágrafo: 50% do valor desktop (2,3% → 1,15%) */
    margin: clamp(8px, 2.2vw, 18px) 7.7% 1.15%;
  }

  .page-3 .card p {
    font-size: clamp(12px, 3.3vw, 15px);
  }

  /* Portfólio: revelar mais cedo no scroll (JS) + animação mais curta só no celular */
  .page-3 .card img {
    transition-duration: 0.55s;
  }

  .page-3.visible .title {
    animation-duration: 0.48s;
    animation-delay: 0s;
  }

  .page-3.visible .card {
    animation-duration: 0.48s;
  }

  .page-3.visible .card:nth-of-type(1) {
    animation-delay: 0.05s;
  }

  .page-3.visible .card:nth-of-type(2) {
    animation-delay: 0.1s;
  }

  .page-3.visible .card:nth-of-type(3) {
    animation-delay: 0.15s;
  }

  /* —— Clientes —— */
  .page-clientes {
    padding-left: clamp(12px, 4vw, var(--page-inline-pad));
    padding-right: clamp(12px, 4vw, var(--page-inline-pad));
    /* −50% do espaço entre logos e box verde da História (só celular) */
    padding-bottom: calc(clamp(0px, 0.35vw, 4px) / 2);
  }

  /* “MAIS DE 500…” = mesmo tamanho que “SOMOS UMA” / “AGÊNCIA DE” (page-2) */
  .page-clientes .clientes-intro {
    --clientes-fs-line: clamp(34px, 5.05vw, 58.5px);
    /* Entrelinhas da 1.ª linha (quebra “CLIENTES / ATENDIDOS”): um pouco mais ar */
    --clientes-lh-white: ;
  }

  /* Gap “MAIS DE 500…” ↔ “EM DIVERSOS…”: mais −50% vs. referência anterior (0,33 → 0,495× fs) */
  .page-clientes .clientes-intro h2.accent {
    margin-top: calc(clamp(-10px, 2vw, 2px) - 0.8 * var(--clientes-fs-line));
  }

  /* Gap “EM DIVERSOS…” ↔ carrossel: mais −50% do espaço de referência (soma 0,75 + 0,5) */
  .page-clientes .clientes-marquee-column {
    margin-top: calc(
      clamp(-65px, -7.5vw, -12px) - 1.25 * clamp(8px, 19vw, 52px)
    );
  }

  /* Carrossel: três logotipos visíveis ao mesmo tempo (desktop/tablet inalterados) */
  .page-clientes .clientes-logo-item {
    --clientes-marquee-gap: clamp(2px, 0.65vw, 12px);
    /* Fallback sem container query: viewport menos padding horizontal da seção */
    --clientes-mobile-inline: calc(2 * clamp(12px, 4vw, 20px));
    width: calc(
      (100vw - var(--clientes-mobile-inline) - 2 * var(--clientes-marquee-gap)) /
        3
    );
    min-width: 0;
    max-width: none;
  }

  @supports (width: 1cqi) {
    .page-clientes .clientes-logo-item {
      width: calc((100cqi - 2 * var(--clientes-marquee-gap)) / 3);
    }
  }

  .page-clientes .clientes-logo-item img {
    max-height: clamp(56px, 16vw, 96px);
  }

  .page-clientes .clientes-marquee-sequence {
    gap: clamp(2px, 0.65vw, 12px);
    padding-right: clamp(-40px, -0.8vw, -14px);
  }

  /* —— História —— */
  /* −50% do espaço entre logos dos clientes e o box verde (só celular) */
  .page-historia {
    padding-top: clamp(2px, 0.35vw, 6px);
  }

  .page-historia .timeline {
    grid-template-columns: 1fr;
    gap: clamp(20px, 5vw, 28px);
  }

  /* Banner História: layout em coluna centralizado (só celular; ≥768px inalterado) */
  .page-historia .historia-banner {
    align-items: center;
  }

  .page-historia .historia-banner-top {
    display: contents;
  }

  .page-historia .historia-banner-tags {
    order: 1;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    row-gap: 8px;
  }

  .page-historia .historia-banner-main {
    order: 2;
    width: 100%;
    justify-content: center;
    /* +15% do espaço vertical do banner acima de “HISTÓRIA”; −35% abaixo (vs. gap do banner) */
    margin-top: calc(0.5 * clamp(12px, 1.8vw, 26px));
    margin-bottom: calc(-0.35 * clamp(12px, 1.8vw, 26px));
  }

  .page-historia .historia-capsule {
    display: none;
  }

  .page-historia .historia-title {
    text-align: center;
  }

  .page-historia .historia-desde {
    order: 3;
    width: 100%;
    text-align: center;
    align-self: center;
  }

  .page-historia .historia-banner-notch {
    order: 4;
  }

  /* Mesmo tamanho de fonte que os h3 dos cards do Portfólio (ex.: “Pousada dos Tangarás”) */
  .page-historia .timeline-item h3 {
    font-size: clamp(20px, 6.4vw, 34px);
  }

  .page-historia .timeline-item p {
    max-width: 100%;
  }

  /* —— Mídia —— */
  .page-media {
    padding-left: clamp(12px, 4vw, var(--page-inline-pad));
    padding-right: clamp(12px, 4vw, var(--page-inline-pad));
  }

  /* +50% no espaço entre o vídeo (YouTube) e o bloco Instagram (vs. gap em ≤900px) */
  .page-media-inner {
    gap: calc(1.5 * clamp(24px, 5vw, 36px));
  }

  .page-media-instagram-head {
    align-items: center;
    text-align: center;
  }

  .page-media .page-media-instagram-label {
    /* Mesmo tamanho que “MAIS DE 500…” (clientes-intro, --clientes-fs-line no celular) */
    font-size: clamp(34px, 5.05vw, 58.5px);
    text-align: center;
  }

  .page-media-instagram-handle {
    justify-content: center;
  }

  /* —— Soluções (page 4) —— */
  .page-4::before {
    left: var(--mobile-lime-inset);
    width: calc(100% - 2 * var(--mobile-lime-inset));
  }

  .page-4-inner {
    width: calc(100% - 2 * var(--mobile-lime-inset));
    padding-left: clamp(8px, 2vw, 14px);
    padding-right: clamp(8px, 2vw, 14px);
  }

  .page-4 .headline {
    font-size: clamp(48px, 14vw, 88px);
  }

  .page-4 .deliverable-row {
    grid-template-columns: 1fr;
    gap: clamp(14px, 4vw, 20px);
  }

  .deliverable {
    min-height: 0;
    padding: clamp(18px, 5vw, 28px) clamp(16px, 4.5vw, 24px);
  }

  .deliverable .index {
    width: clamp(44px, 18vw, 72px);
  }

  /* Mesmo tamanho que os títulos da timeline (ex.: “Abril 2008”) */
  .deliverable h3 {
    font-size: clamp(20px, 6.4vw, 34px);
    /* 50% do gap já reduzido (título → parágrafo) */
    margin-bottom: calc(0.25 * clamp(10px, 1.1vw, 16px));
  }

  .deliverable p {
    font-size: clamp(12px, 3.4vw, 15px);
  }

  .deliverable-cta {
    margin-top: clamp(12px, 3.5vw, 20px);
    font-size: clamp(12px, 3.2vw, 15px);
    padding: 0.6em 1.2em;
  }

  .deliverable-cta-icon {
    width: clamp(16px, 4.2vw, 20px);
    height: clamp(16px, 4.2vw, 20px);
  }

  /* —— Contato (page 5) —— */
  .page.page-5 {
    position: relative;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible;
    /* Sem padding-top: cola o verde do contato ao verde de Soluções (page-4) */
    padding: 0 0 clamp(24px, 7vw, 40px);
    /* Box verde só até o fim do form (ícones); contatos ficam no fundo escuro */
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto auto auto;
    align-content: start;
  }

  .page-5::before {
    grid-column: 1;
    grid-row: 1 / 4;
    position: static;
    z-index: 0;
    top: auto;
    bottom: auto;
    left: auto;
    /* Mesma largura do box verde de Soluções (.page-4::before) */
    width: calc(100% - 2 * var(--mobile-lime-inset));
    max-width: 100%;
    height: auto;
    margin-left: auto;
    margin-right: auto;
    justify-self: center;
    align-self: stretch;
    background: var(--lime);
    /* Topo reto; arredondado só embaixo, até após os ícones sociais */
    border-radius: 0 0 clamp(16px, 4vw, 26px) clamp(16px, 4vw, 26px);
  }

  .page-5 .top-strip {
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    grid-column: 1;
    grid-row: 1;
    z-index: 1;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin: clamp(8px, 2.5vw, 14px)
      clamp(12px, 4vw, var(--page-inline-pad)) 0;
    padding: 0 clamp(4px, 1vw, 8px);
  }

  .page-5 .top-buttons {
    flex-wrap: wrap;
    justify-content: center;
  }

  .page-5 .top-right-decoration {
    width: 100%;
    /* +70% vs. referência do gap da faixa (12px): 12 × 1,7 */
    margin-top: calc(1.7 * 12px);
    margin-bottom: calc(1.7 * 12px);
  }

  .page-5 h2 {
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    grid-column: 1;
    grid-row: 2;
    z-index: 1;
    margin: clamp(14px, 4vw, 22px) clamp(12px, 4vw, var(--page-inline-pad));
    font-size: clamp(26px, 7.2vw, 40px);
    white-space: normal;
    text-align: center;
    line-height: 1.05;
    max-width: none;
  }

  .page-5 .contact-form {
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    grid-column: 1;
    grid-row: 3;
    z-index: 1;
    width: calc(100% - 2 * clamp(12px, 4vw, var(--page-inline-pad)));
    max-width: 100%;
    margin: 0 auto;
    padding: 0 clamp(12px, 4vw, var(--page-inline-pad))
      clamp(12px, 3vw, 20px);
  }

  .page-5 .contacts {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    grid-column: 1;
    grid-row: 4;
    z-index: 1;
    flex-direction: column;
    align-items: stretch;
    /* 50% do gap anterior: clamp(14px, 4vw, 20px) */
    gap: clamp(7px, 2vw, 10px);
    margin: clamp(18px, 5vw, 28px) clamp(12px, 4vw, var(--page-inline-pad)) 0;
    padding-bottom: 0;
  }

  .page-5 .contacts > div {
    flex: none;
    width: 100%;
  }

  .page-5 .contacts h4 {
    margin-bottom: 6px;
  }

  .page-5 .contacts p {
    white-space: normal;
    text-align: center;
    font-size: clamp(12px, 3.4vw, 15px);
    word-break: break-word;
  }
}

@media (max-width: 767px) and (prefers-reduced-motion: reduce) {
  .page-1 .portfolio-word .letter {
    animation: none;
    opacity: 1;
    transform: none;
    filter: none;
  }

  .page-1 .hero-photo {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .page-1 .hero-cta-group .hero-cta {
    animation: none;
    opacity: 1;
  }

  .page-1 .social-icons a {
    animation: none;
    opacity: 1;
  }
}
