/* ---------- Reset & base ---------- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Montserrat', sans-serif;
  background: #ffffff;
  color: #111;
  overflow-x: hidden;
}

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

a {
  text-decoration: none;
}

body.is-loading {
  overflow: hidden;
  height: 100%;
}

/* ============================================================
   CINEMATIC LOADER
   ============================================================ */
.loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #AED600;
  transition: opacity 0.6s ease;
}

.loader__bg {
  position: absolute;
  inset: -6%;
  z-index: 0;
  background-color: #AED600;
  background-image: url('../assets/img/fundo-verde-55-800.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  animation: loader-bg-pan 9s ease-in-out infinite alternate;
}

@media (min-width: 900px) {
  .loader__bg {
    background-image: url('../assets/img/fundo-verde-55.png');
  }
}

.loader__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(120% 140% at 50% 50%, rgba(6, 15, 4, 0.08) 0%, rgba(6, 15, 4, 0.32) 65%, rgba(4, 10, 3, 0.55) 100%);
}

@keyframes loader-bg-pan {
  0% { transform: scale(1.06) translate(0, 0); }
  100% { transform: scale(1.16) translate(-1.5%, -1.5%); }
}

.loader__stage {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(16px, 3vw, 28px);
  opacity: 0;
  transform: scale(0.82);
  filter: blur(6px);
  animation: loader-logo-in 1.1s cubic-bezier(0.16, 0.8, 0.28, 1) 0.35s forwards;
}

.loader__logo {
  width: clamp(200px, 34vw, 420px);
  height: auto;
  filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.55));
}

.loader__track {
  width: clamp(160px, 26vw, 300px);
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  overflow: hidden;
}

.loader__fill {
  display: block;
  height: 100%;
  width: 40%;
  border-radius: 999px;
  background: linear-gradient(90deg, #00ccff, #c6e200);
  animation: loader-fill-sweep 1.15s ease-in-out infinite;
}

@keyframes loader-logo-in {
  to {
    opacity: 1;
    transform: scale(1);
    filter: blur(0);
  }
}

@keyframes loader-fill-sweep {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(350%); }
}

/* Hidden state: logo + background dissolve together, no leftover panels */
.loader.is-hiding .loader__stage {
  transition: opacity 0.5s ease, transform 0.5s ease;
  opacity: 0;
  transform: scale(1.06);
}

.loader.is-hiding {
  opacity: 0;
}

.loader.is-hidden {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .loader,
  .loader__bg,
  .loader__stage,
  .loader__fill {
    animation: none !important;
    transition: opacity 0.4s ease !important;
  }

  .loader__stage {
    opacity: 1;
    transform: none;
    filter: none;
  }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  background: #85B440;
}

.hero__inner {
  position: relative;
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  aspect-ratio: 1600 / 1068;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__photo {
  position: absolute;
  left: 1.9375%;
  top: 8.708%;
  width: 57.8125%;
  height: 91.29%;
  object-fit: contain;
  object-position: bottom;
}

.hero__headline {
  position: absolute;
  left: 41.625%;
  top: 22.566%;
  width: 47.9375%;
  height: 44.101%;
}

.hero__nome-numero {
  width: 100%;
  height: auto;
}

.social-grid {
  position: absolute;
  left: 21.1875%;
  top: 72.9%;
  width: 66.8125%;
  height: 17.42%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: repeat(2, 1fr);
  column-gap: 1.216%;
  row-gap: 8.6%;
}

.social-grid__item {
  display: block;
  width: 100%;
  height: 100%;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.social-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.social-grid__item:hover,
.social-grid__item:focus-visible {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

.divider {
  max-width: 1600px;
  margin: 0 auto;
  aspect-ratio: 1600 / 28;
  background: #00CCFF;
}

/* ============================================================
   ABOUT / "Quem é o DN?"
   ============================================================ */
.about {
  position: relative;
  background-color: #AED600;
  overflow: hidden;
}

.about__bg {
  position: absolute;
  inset: -12% -12%;
  background-image: url('../assets/img/fundo-verde-55-800.png');
  background-repeat: no-repeat;
  background-size: cover;
  background-position: top center;
  transform: scale(1.35);
  filter: blur(14px);
  opacity: 0;
  z-index: 0;
  transition:
    transform 2s cubic-bezier(0.16, 0.8, 0.28, 1),
    filter 1.6s ease-out,
    opacity 1.3s ease-out;
}

.about__bg.is-revealed {
  transform: scale(1.08);
  filter: blur(0);
  opacity: 1;
}

@media (min-width: 900px) {
  .about__bg {
    background-image: url('../assets/img/fundo-verde-55.png');
  }
}

@media (prefers-reduced-motion: reduce) {
  .about__bg {
    transition: opacity 0.4s ease-out;
    transform: scale(1.08);
    filter: blur(0);
  }
}

.about__inner {
  position: relative;
  z-index: 1;
  max-width: 1600px;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 80px) clamp(20px, 5vw, 96px) 0;
}

.about__flex {
  display: grid;
  grid-template-columns: minmax(220px, 380px) minmax(0, 1fr);
  align-items: start;
  gap: clamp(20px, 4vw, 64px);
}

.about__photo {
  width: 100%;
  aspect-ratio: 524 / 775;
  object-fit: cover;
  border-radius: clamp(18px, 3vw, 48px);
}

.about__text {
  min-width: 0;
}

.about__title {
  font-family: 'Baloo 2', sans-serif;
  font-weight: 700;
  font-size: clamp(2rem, 4.5vw, 3.6rem);
  color: #111;
  margin-bottom: 0.5em;
}

.about__text p {
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: clamp(0.95rem, 1.35vw, 1.15rem);
  line-height: 1.5;
  color: #111;
  margin-bottom: 1em;
}

/* ---------- Footer ---------- */
.footer {
  text-align: center;
  padding: clamp(32px, 6vw, 64px) 16px clamp(24px, 4vw, 48px);
}

.footer p {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: clamp(0.68rem, 1vw, 0.85rem);
  color: #111;
  line-height: 1.6;
}

/* ============================================================
   Back to top button
   ============================================================ */
.back-to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #00CCFF;
  color: #fff;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  z-index: 50;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: #00b8e6;
}

/* ============================================================
   Responsive tweaks
   ============================================================ */
@media (max-width: 900px) {
  .about__flex {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .about__photo {
    max-width: 220px;
  }

  .about__text {
    width: 100%;
  }

  /* Hero: the 1600x1068 landscape ratio squeezes everything into a
     tiny strip on narrow/medium screens, making the photo/text feel
     zoomed in and "shrunk desktop". Break out of the fixed ratio and
     stack the content top-to-bottom instead, with room to breathe. */
  .hero {
    padding: 20px 16px 28px;
  }

  .hero__inner {
    aspect-ratio: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    border-radius: 22px;
    padding: 26px 12px 30px;
  }

  .hero__photo {
    position: relative;
    left: auto;
    top: auto;
    z-index: 1;
    align-self: flex-start;
    width: 85%;
    max-width: 380px;
    height: auto;
    object-fit: contain;
    object-position: center;
    margin-left: 2%;
  }

  .hero__headline {
    position: relative;
    left: auto;
    top: auto;
    z-index: 1;
    align-self: flex-start;
    width: 92%;
    max-width: 420px;
    height: auto;
    margin-left: 2%;
    margin-top: -6%;
  }

  .social-grid {
    position: relative;
    left: auto;
    top: auto;
    z-index: 1;
    width: 100%;
    max-width: 520px;
    height: auto;
    aspect-ratio: 1069 / 186;
    row-gap: 8.6%;
    margin-top: 8px;
  }

  .divider {
    border-radius: 999px;
    width: 92%;
    aspect-ratio: 1600 / 40;
  }
}
