/*** TIPOGRAFÍAS ***/
/* Montserrat para todo el texto y Outfit para la marca, igual que en la app */
@font-face { font-family: "Montserrat"; font-weight: 400; font-display: swap; src: url("../fonts/montserrat-regular.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 500; font-display: swap; src: url("../fonts/montserrat-medium.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 600; font-display: swap; src: url("../fonts/montserrat-semibold.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 700; font-display: swap; src: url("../fonts/montserrat-bold.woff2") format("woff2"); }
@font-face { font-family: "Montserrat"; font-weight: 800; font-display: swap; src: url("../fonts/montserrat-extrabold.woff2") format("woff2"); }
@font-face { font-family: "Outfit"; font-weight: 400; font-display: swap; src: url("../fonts/outfit-regular.woff2") format("woff2"); }

/*** PALETA DE SIMPLECAST ***/
/* Los mismos colores que la app (res/values/colors.xml) */
:root {
  --fondo: #121414;
  --tarjeta: #1B1C1C;
  --boton: #282A2A;
  --borde: #3C3F3F;
  --texto: #E3E2E2;
  --texto-sec: #BEC9C7;
  --texto-ter: #A3A3A3;
  --teal: #4E9993;
  --teal-claro: #89D4CD;
  --teal-logo-1: #407873;
  --teal-logo-2: #65C0B7;
  --dorado: #DDC25C;
  --dorado-claro: #E5D088;

  --ancho: 1100px;
  --radio: 16px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--fondo);
  color: var(--texto);
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; }
a { color: var(--teal-claro); }

/* El lienzo del fondo ocupa toda la ventana y se queda quieto detrás del contenido */
#fondo {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

/*** CABECERA ***/
.cabecera {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--ancho);
  margin: 0 auto;
  padding: 18px 24px;
}

/* Al bajar, la cabecera se oscurece un poco para que se lea (lo activa global.js) */
.cabecera::before {
  content: "";
  position: absolute;
  inset: 0 calc(50% - 50vw);
  z-index: -1;
  background: rgba(18, 20, 20, 0.75);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(60, 63, 63, 0.6);
  opacity: 0;
  transition: opacity 0.3s;
}
.cabecera.con-fondo::before { opacity: 1; }

.marca {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
}
.marca span { font-family: "Outfit", sans-serif; font-size: 24px; }

/*** BOTONES ***/
.boton {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 30px;
  border-radius: var(--radio);
  background: linear-gradient(180deg, var(--teal-logo-2), var(--teal));
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  box-shadow: 0 10px 30px -8px rgba(78, 153, 147, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.2s, box-shadow 0.2s;
}
.boton svg { width: 22px; height: 22px; fill: currentColor; }
.boton:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 40px -8px rgba(78, 153, 147, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.boton:active { transform: translateY(0); }

.boton--pequeno {
  padding: 10px 18px;
  font-size: 12px;
  box-shadow: none;
}

/*** PORTADA ***/
.portada {
  min-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 24px 80px;
}

/* Logo que flota, con ondas de emisión saliendo por detrás */
.portada__logo {
  position: relative;
  width: 240px;
  margin-bottom: 28px;
  animation: flotar 6s ease-in-out infinite;
}
.portada__logo img {
  position: relative;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 20px 40px rgba(78, 153, 147, 0.35));
}

.onda {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  aspect-ratio: 1;
  border: 2px solid var(--teal-claro);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0.6);
  opacity: 0;
  /* animation: onda 3.6s ease-out infinite; */
}
.onda:nth-child(2) { animation-delay: 1.2s; border-color: var(--dorado); }
.onda:nth-child(3) { animation-delay: 2.4s; }

@keyframes onda {
  0%   { transform: translate(-50%, -50%) scale(0.6); opacity: 0.55; }
  100% { transform: translate(-50%, -50%) scale(2.2); opacity: 0; }
}

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

.portada__nombre {
  margin: 0;
  font-family: "Outfit", sans-serif;
  font-weight: 400;
  font-size: clamp(56px, 11vw, 112px);
  line-height: 1;
  letter-spacing: -0.01em;
  color: #fff;
}

.portada__lema {
  max-width: 560px;
  margin: 18px 0 0;
  font-size: clamp(17px, 2.4vw, 21px);
  color: var(--texto-sec);
  text-wrap: balance;
}
.portada__lema strong { color: var(--texto); font-weight: 700; }

.etiquetas {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}
.etiquetas li {
  padding: 6px 14px;
  border: 1px solid var(--borde);
  border-radius: 999px;
  background: rgba(27, 28, 28, 0.6);
  font-size: 13px;
  font-weight: 600;
  color: var(--texto-sec);
}

.portada__acciones { margin-top: 40px; }
.portada__nota {
  margin: 14px 0 0;
  font-size: 13px;
  color: var(--texto-ter);
}

/*** SECCIONES ***/
.seccion {
  max-width: var(--ancho);
  margin: 0 auto;
  padding: 90px 24px;
}

.seccion__etiqueta {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dorado);
}

.seccion__titulo {
  max-width: 680px;
  margin: 10px 0 40px;
  font-size: clamp(28px, 4.4vw, 42px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.seccion__titulo span { color: var(--teal-claro); }
.seccion__titulo { text-wrap: balance; }

/* Raya dorada bajo los títulos, como en los documentos de la marca */
.seccion__titulo::after {
  content: "";
  display: block;
  width: 56px;
  height: 5px;
  margin-top: 16px;
  border-radius: 4px;
  background: var(--dorado);
}

/*** TARJETAS DE FUNCIONES ***/
.tarjetas {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.tarjeta {
  position: relative;
  padding: 26px;
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  background: rgba(27, 28, 28, 0.72);
  backdrop-filter: blur(6px);
  transition: transform 0.25s, border-color 0.25s;
}
.tarjeta:hover {
  transform: translateY(-4px);
  border-color: var(--teal);
}

.tarjeta__icono {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  border-radius: 14px;
  background: rgba(78, 153, 147, 0.15);
}
.tarjeta__icono svg { width: 24px; height: 24px; fill: var(--teal-claro); }

.tarjeta h3 { margin: 0 0 8px; font-size: 18px; font-weight: 700; }
.tarjeta p  { margin: 0; font-size: 14.5px; color: var(--texto-sec); }

/*** PASOS ***/
.pasos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.pasos li {
  padding: 26px;
  border-radius: var(--radio);
  background: linear-gradient(180deg, rgba(78, 153, 147, 0.14), rgba(27, 28, 28, 0.5));
  border: 1px solid rgba(78, 153, 147, 0.35);
}
.pasos__numero {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--teal);
  font-weight: 800;
  color: #fff;
}
.pasos h3 { margin: 0 0 6px; font-size: 18px; }
.pasos p  { margin: 0; font-size: 14.5px; color: var(--texto-sec); }

.cierre {
  margin-top: 60px;
  text-align: center;
}
.cierre p {
  margin: 0 0 20px;
  font-size: 22px;
  font-weight: 700;
}

/*** PIE ***/
.pie {
  max-width: var(--ancho);
  margin: 0 auto;
  padding: 40px 24px 50px;
  border-top: 1px solid var(--borde);
  text-align: center;
  font-size: 13px;
  color: var(--texto-ter);
}
.pie p { margin: 4px 0; }
.pie a { text-decoration: none; }
.pie__legal { font-size: 12px; opacity: 0.7; }

/*** APARECER AL BAJAR ***/
/* global.js añade «visible» cuando el elemento entra en pantalla */
.aparecer {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.aparecer.visible {
  opacity: 1;
  transform: none;
}

/*** MÓVIL ***/
@media (max-width: 480px) {
  .portada__logo { width: 190px; }
  .seccion { padding: 70px 20px; }
}

/*** MENOS MOVIMIENTO ***/
/* Si el usuario ha pedido menos animaciones en su sistema, las quitamos */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .portada__logo, .onda { animation: none; }
  .onda { display: none; }
  .aparecer { opacity: 1; transform: none; transition: none; }
}
