/* =========================================================
   Brava Parapente — link page
   Mobile-first · Montserrat · sem dependências de framework
   ========================================================= */

:root {
  --blue: #00aaff;
  --orange: #f8931f;
  --orange-hover: #ffa23a;
  --white: #ffffff;
  --ink: #101820;

  --text-soft: rgba(255, 255, 255, 0.82);
  --text-muted: rgba(255, 255, 255, 0.6);
  --line: rgba(255, 255, 255, 0.28);

  --radius: 12px;
  --btn-h: 56px;
  --col: 420px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--ink);
  color: var(--white);
  font-family: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-weight: 500;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

p,
h1 {
  margin: 0;
}

/* ---------- Background ---------- */
.bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: var(--ink);
  overflow: hidden;
}

.bg picture,
.bg img {
  display: block;
  width: 100%;
  height: 100%;
}

.bg img {
  object-fit: cover;
  object-position: 50% 30%;
  /* o desfoque já vem aplicado no arquivo (mais leve que filter: blur no mobile);
     scale evita bordas claras do blur nas extremidades */
  transform: scale(1.04);
  opacity: 0;
  transition: opacity 0.6s ease;
}

.bg.is-loaded img {
  opacity: 1;
}

/* overlay: escurece mais embaixo, onde ficam os botões */
.bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(16, 24, 32, 0.38) 0%, rgba(16, 24, 32, 0.58) 45%, rgba(16, 24, 32, 0.8) 100%);
}

/* ---------- Layout ---------- */
.page {
  flex: 1;
  width: 100%;
  max-width: calc(var(--col) + 40px);
  margin: 0 auto;
  padding:
    calc(48px + var(--safe-top))
    calc(20px + var(--safe-right))
    24px
    calc(20px + var(--safe-left));
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 36px;
}

/* ---------- Brand ---------- */
.brand {
  text-align: center;
}

.brand__logo {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  font-weight: 700;
  line-height: 1;
}

.brand__mark {
  display: block;
  width: 64px;
  height: auto;
  margin-bottom: 16px;
}

.brand__name {
  font-size: clamp(2.4rem, 11vw, 3rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  /* compensa o tracking da última letra para centralizar opticamente */
  margin-right: -0.14em;
}

.brand__sub {
  margin-top: 8px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.52em;
  margin-right: -0.52em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.brand__tagline {
  margin: 22px auto 0;
  max-width: 26ch;
  font-size: 1.05rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--white);
  text-wrap: balance;
}

/* ---------- Links ---------- */
.links {
  display: flex;
  flex-direction: column;
}

.links__label {
  margin-bottom: 12px;
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.links__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.links__list--info {
  margin-top: 26px;
  padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

/* ---------- Button ---------- */
.btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: var(--btn-h);
  padding: 12px 18px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: none;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  transition:
    background-color 0.18s var(--ease),
    border-color 0.18s var(--ease),
    color 0.18s var(--ease),
    transform 0.18s var(--ease);
}

.btn__icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 28px;
}

.btn__icon svg {
  display: block;
  width: 22px;
  height: 22px;
}

.btn__icon--flag svg {
  width: 26px;
  height: auto;
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(16, 24, 32, 0.12);
}

.btn__label {
  flex: 1;
}

.btn__arrow {
  flex: none;
  display: grid;
  place-items: center;
  opacity: 0.55;
  transition: transform 0.2s var(--ease), opacity 0.2s var(--ease);
}

.btn__arrow svg {
  width: 18px;
  height: 18px;
}

/* Primary — português */
.btn--primary {
  min-height: 60px;
  background: var(--orange);
  color: var(--ink);
  font-weight: 700;
}

.btn--primary .btn__arrow {
  opacity: 0.85;
}

/* Solid — espanhol / inglês */
.btn--solid {
  background: var(--white);
  color: var(--ink);
}

/* Ghost — informações */
.btn--ghost {
  min-height: 52px;
  background: rgba(16, 24, 32, 0.28);
  border-color: var(--line);
  color: var(--white);
  font-weight: 500;
  font-size: 0.95rem;
}

.btn--ghost .btn__icon {
  color: var(--orange);
}

@media (hover: hover) {
  .btn:hover .btn__arrow {
    opacity: 1;
    transform: translateX(3px);
  }
  .btn--primary:hover {
    background: var(--orange-hover);
  }
  .btn--solid:hover {
    background: #eef8ff;
  }
  .btn--ghost:hover {
    background: rgba(16, 24, 32, 0.45);
    border-color: rgba(255, 255, 255, 0.55);
  }
}

.btn:active {
  transform: scale(0.98);
}

.btn:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

/* ---------- Footer ---------- */
.footer {
  padding: 8px calc(20px + var(--safe-right)) calc(20px + var(--safe-bottom)) calc(20px + var(--safe-left));
  text-align: center;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--text-muted);
}

/* ---------- Entrada suave ---------- */
@media (prefers-reduced-motion: no-preference) {
  .brand,
  .links__label,
  .links__list li {
    animation: rise 0.6s var(--ease) both;
  }
  .links__label {
    animation-delay: 0.12s;
  }
  .links__list li {
    animation-delay: calc(0.16s + var(--i, 0) * 0.06s);
  }
  .links__list li:nth-child(1) { --i: 0; }
  .links__list li:nth-child(2) { --i: 1; }
  .links__list li:nth-child(3) { --i: 2; }
  .links__list--info li:nth-child(1) { --i: 3; }
  .links__list--info li:nth-child(2) { --i: 4; }

  @keyframes rise {
    from {
      opacity: 0;
      transform: translateY(10px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
}

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

/* ---------- Telas muito pequenas (iPhone SE / 320px) ---------- */
@media (max-width: 359px) {
  .page {
    padding-top: calc(32px + var(--safe-top));
    gap: 28px;
  }
  .btn {
    gap: 12px;
    padding-inline: 14px;
    font-size: 0.95rem;
  }
}

/* ---------- Tablet / desktop ---------- */
@media (min-width: 761px) {
  .page {
    padding-top: calc(64px + var(--safe-top));
    gap: 44px;
  }
  .bg img {
    object-position: 40% 40%;
  }
}
