@font-face {
  font-family: "Fira Sans";
  src: url("../fonts/FiraSans-Light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fira Sans";
  src: url("../fonts/FiraSans-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fira Sans";
  src: url("../fonts/FiraSans-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

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

:root {
  --azul: #004a65;
  --branco: #ffffff;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: "Fira Sans", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--branco);
  background: var(--azul);
  overflow-x: hidden;
}

/* ---------- Mobile / retrato: layout empilhado (não há frame mobile no Figma) ---------- */

.banner {
  display: flex;
  flex-direction: column;
  gap: 32px;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 32px 24px;
}

.banner__logo {
  display: block;
  width: min(260px, 70%);
  height: auto;
}

.banner__tagline {
  margin-top: 12px;
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
}

.banner__photo {
  margin: 0 -24px;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.banner__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 15% 85%;
}

.banner__lines {
  display: none;
}

.banner__headline {
  font-size: 24px;
  line-height: 1.37;
  font-weight: 400;
}

.banner__headline strong,
.banner__tagline strong {
  font-weight: 700;
}

.banner__cta {
  align-self: flex-end;
  margin-top: auto;
  display: flex;
  flex-direction: column;
  padding: 24px 32px;
  background: var(--branco);
  border-radius: 24px 0 0 0;
  margin-right: -24px;
  margin-bottom: -32px;
  color: var(--azul);
  line-height: 1.1;
  text-decoration: none;
}

.banner__cta-strong {
  font-size: 48px;
  font-weight: 700;
}

.banner__cta-light {
  font-size: 60px;
  font-weight: 300;
}

.banner__cta:focus-visible {
  outline: 3px solid var(--branco);
  outline-offset: -8px;
  box-shadow: inset 0 0 0 5px var(--azul);
}

/* ---------- Desktop: composição 1600×882 do Figma, escalada para caber na tela ---------- */
/* --u = 1px do Figma. O palco fica ancorado embaixo à direita (onde está o CTA);
   a foto se estende até as bordas esquerda/superior da viewport quando sobra espaço. */

@media (orientation: landscape) and (min-width: 641px) and (min-height: 481px) {
  body {
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    place-items: end;
    overflow: hidden;
  }

  .banner {
    --vh: 100vh;
    --u: min(100vw / 1600, var(--vh) / 882);
    position: relative;
    display: block;
    min-height: 0;
    padding: 0;
    width: calc(1600 * var(--u));
    height: calc(882 * var(--u));
  }

  @supports (height: 100dvh) {
    .banner {
      --vh: 100dvh;
    }
  }

  .banner > * {
    position: absolute;
  }

  .banner__photo {
    margin: 0;
    aspect-ratio: auto;
    left: calc(100% - 100vw);
    top: calc(100% - var(--vh));
    right: calc(100% - 1184 * var(--u));
    bottom: 0;
    /* 1ª camada: tudo à esquerda do início da curva (inclui a sobra à esquerda/topo); 2ª: curva do Figma */
    -webkit-mask:
      linear-gradient(#000 0 0) left top / calc(100% - 273.5 * var(--u)) 100% no-repeat,
      url("../assets/mask.svg") right bottom / calc(1184 * var(--u)) calc(882 * var(--u)) no-repeat;
    mask:
      linear-gradient(#000 0 0) left top / calc(100% - 273.5 * var(--u)) 100% no-repeat,
      url("../assets/mask.svg") right bottom / calc(1184 * var(--u)) calc(882 * var(--u)) no-repeat;
  }

  .banner__photo img {
    position: absolute;
    right: 0;
    bottom: 0;
    width: calc(1357.56 * var(--u));
    height: calc(1403.23 * var(--u));
    min-width: 100%;
    min-height: 100%;
    object-position: right bottom;
  }

  .banner__lines {
    display: block;
    left: calc(3 * var(--u));
    top: 0;
    width: calc(1263 * var(--u));
    height: calc(882 * var(--u));
    pointer-events: none;
  }

  .banner__headline {
    left: calc(73 * var(--u));
    top: calc(64 * var(--u));
    width: calc(509 * var(--u));
    font-size: calc(36 * var(--u));
  }

  .banner__brand {
    left: calc(1194 * var(--u));
    top: calc(65 * var(--u));
  }

  .banner__logo {
    width: calc(353 * var(--u));
  }

  .banner__tagline {
    margin: calc(20 * var(--u)) 0 0 calc(63 * var(--u));
    font-size: calc(20 * var(--u));
    white-space: nowrap;
  }

  .banner__cta {
    right: 0;
    bottom: calc(-1 * var(--u));
    width: calc(459 * var(--u));
    height: calc(348 * var(--u));
    margin: 0;
    padding: calc(144 * var(--u)) 0 0 calc(210 * var(--u));
    border-radius: 0;
    background: url("../assets/corner.png") left top / calc(457 * var(--u)) 100% no-repeat;
    line-height: 1.37;
  }

  .banner__cta-strong {
    height: calc(56 * var(--u));
    font-size: calc(64 * var(--u));
  }

  .banner__cta-light {
    font-size: calc(80 * var(--u));
  }
}

/* ---------- Animações de entrada ---------- */
/* Parallax: foto, textos e CTA partem de distâncias/tempos diferentes e assentam juntos,
   dando sensação de profundidade. Deslocamentos em em escalam com o texto (e com --u). */

.banner__line {
  display: block;
}

.banner__photo img {
  transform-origin: 40% 75%;
  animation: photo-in 2.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.banner__line,
.banner__cta,
.banner__cta-strong,
.banner__cta-light {
  animation: parallax-in 1.6s cubic-bezier(0.16, 1, 0.3, 1) var(--delay, 0s) both;
}

.banner__line:nth-child(1) { --from-x: -1.5em; --delay: 0.5s; }
.banner__line:nth-child(2) { --from-x: -2.5em; --delay: 0.65s; }
.banner__line:nth-child(3) { --from-x: -3.5em; --delay: 0.8s; }

.banner__cta { --from-y: 100%; --delay: 0.9s; }
.banner__cta-strong { --from-y: 1em; --delay: 1.15s; }
.banner__cta-light { --from-y: 1.2em; --delay: 1.3s; }

.banner__logo,
.banner__tagline {
  animation: blur-in 1.4s ease-out var(--delay, 0s) both;
}

.banner__logo { --delay: 0.2s; }
.banner__tagline { --delay: 0.6s; }

@keyframes photo-in {
  from {
    opacity: 0;
    transform: scale(1.12) translateX(-3%);
  }

  35% {
    opacity: 1;
  }
}

@keyframes parallax-in {
  from {
    opacity: 0;
    transform: translate(var(--from-x, 0), var(--from-y, 0));
  }
}

@keyframes blur-in {
  from {
    opacity: 0;
    filter: blur(16px);
    transform: scale(1.06);
  }
}

/* Mobile: evita scroll momentâneo enquanto o CTA sobe de baixo */
@media not ((orientation: landscape) and (min-width: 641px) and (min-height: 481px)) {
  .banner {
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
  }
}
