/* ==========================================================================
   Bocados Felices — estilos
   Diseño de referencia: Web/Página en construcción/Web liso.png (1920×1080).
   Escala: --px equivale a 1px del diseño en Figma y se ajusta a la pantalla
   (por ancho o por alto, el que limite), así se mantienen las proporciones.
   Ej.: calc(164 * var(--px)) = 164px en una pantalla de 1920×1080.
   ========================================================================== */

:root {
  --px: min(100vw / 1920, 100vh / 1080);
}

/* --- Fuentes (DM Sans, OFL) — subset latino, eje opsz fijado en 9 como en Figma */
@font-face {
  font-family: "DM Sans";
  src: url("../fonts/dm-sans-latin.woff2") format("woff2");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "DM Sans";
  src: url("../fonts/dm-sans-italic-latin.woff2") format("woff2");
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

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

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: var(--font-weight-regular);
  color: var(--color-light-mode);
  background-color: var(--color-verde-menta);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

h1,
p {
  margin: 0;
}

/* --- Página "Muy pronto" ---------------------------------------------- */
.coming-soon {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: clamp(2rem, 6vw, 4rem) 1.5rem;
  overflow: hidden;
  /* Fondo del brandbook (Fondos/Fondo gradiente verde). Debajo, un degradé con
     colores de la paleta que se ve mientras la imagen carga. */
  background-image:
    url("../img/backgrounds/fondo-gradiente-verde-1920.webp"),
    linear-gradient(var(--color-verde-menta), var(--color-manzana-verde));
  background-size: cover;
  background-position: center;
}

@media (orientation: landscape) and (max-width: 1280px) {
  .coming-soon {
    background-image:
      url("../img/backgrounds/fondo-gradiente-verde-1280.webp"),
      linear-gradient(var(--color-verde-menta), var(--color-manzana-verde));
  }
}

@media (orientation: portrait) {
  .coming-soon {
    background-image:
      url("../img/backgrounds/fondo-gradiente-verde-vertical-800.webp"),
      linear-gradient(var(--color-verde-menta), var(--color-manzana-verde));
  }
}

.coming-soon__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  /* En el diseño el bloque queda levemente por encima del centro */
  margin-bottom: calc(81.5 * var(--px));
}

.coming-soon__logo {
  width: max(7.5rem, calc(228 * var(--px)));
}

.coming-soon__title {
  margin-top: calc(54.4 * var(--px));
  font-size: max(2.75rem, calc(164 * var(--px)));
  font-style: italic;
  font-weight: var(--font-weight-bold);
  line-height: 1.1;
}

.coming-soon__text {
  max-width: 21.5em;
  margin-top: calc(38.1 * var(--px));
  font-size: max(1.125rem, calc(40.6 * var(--px)));
  line-height: 1.3;
}

/* --- Ilustraciones (mockup "Web iconos") ------------------------------
   Posiciones y tamaños medidos sobre el diseño de 1920×1080. Las que tocan
   un borde se anclan a ese borde; las del medio, al centro vertical. */
.coming-soon__decor {
  position: absolute;
  inset: 0;
}

.decor {
  position: absolute;
  height: auto;
  pointer-events: none;
  user-select: none;
}

.decor--zanahoria {
  top: calc(74 * var(--px));
  left: calc(-22 * var(--px));
  width: calc(260.3 * var(--px));
}

.decor--carne {
  top: calc(-44 * var(--px));
  right: calc(260.1 * var(--px));
  width: calc(277.9 * var(--px));
}

.decor--huevo {
  top: calc(50% - 168 * var(--px));
  right: calc(76.7 * var(--px));
  width: calc(217.3 * var(--px));
}

.decor--pescado {
  top: calc(50% + 134.1 * var(--px));
  left: calc(183.7 * var(--px));
  width: calc(294.1 * var(--px));
}

.decor--pollo {
  bottom: calc(-91.1 * var(--px));
  left: calc(50% - 441 * var(--px));
  width: calc(254.5 * var(--px));
}

.decor--zukini {
  bottom: calc(-17.6 * var(--px));
  right: calc(201.6 * var(--px));
  width: calc(260.4 * var(--px));
}

/* --- Botón -------------------------------------------------------------- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: max(3rem, calc(67 * var(--px)));
  margin-top: calc(43.1 * var(--px));
  padding: 0.25em 3.07em;
  border-radius: 999px;
  font-size: max(1rem, calc(28.5 * var(--px)));
  line-height: 1.2;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--color-verde-menta);
  background-color: var(--color-light-mode);
  transition: background-color 0.2s ease;
}

/* Hover/foco: no están definidos en el diseño → propuesta con colores de paleta */
.button:hover {
  background-color: var(--color-lima);
}

.button:focus-visible {
  outline: 3px solid var(--color-limon);
  outline-offset: 4px;
}

/* --- Mobile ------------------------------------------------------------- */
@media (max-width: 600px) {
  .coming-soon__logo {
    width: 40vw;
  }

  .coming-soon__title {
    margin-top: 2.5rem;
    font-size: 12.5vw;
  }

  .coming-soon__text {
    margin-top: 1rem;
    font-size: 4.6vw;
  }

  .button {
    width: 100%;
    max-width: 22rem;
    margin-top: 2rem;
    padding-inline: 1.5em;
    font-size: 4.1vw;
  }
}

/* Celular vertical: sin diseño propio, ilustraciones en dos franjas
   (arriba y abajo) para no tapar el contenido. */
@media (orientation: portrait) {
  .decor--zanahoria { top: 3%;    left: -5vw;   right: auto; bottom: auto; width: 24vw; }
  .decor--huevo     { top: 9%;    left: 38vw;   right: auto; bottom: auto; width: 20vw; }
  .decor--carne     { top: -2%;   right: -4vw;  left: auto;  bottom: auto; width: 28vw; }
  .decor--pescado   { bottom: 9%; left: -3vw;   right: auto; top: auto;    width: 28vw; }
  .decor--pollo     { bottom: -5%; left: 38vw;  right: auto; top: auto;    width: 24vw; }
  .decor--zukini    { bottom: 2%; right: -4vw;  left: auto;  top: auto;    width: 26vw; }
}

/* --- Pantallas bajas en horizontal (celular acostado) -------------------- */
@media (orientation: landscape) and (max-height: 540px) {
  .coming-soon {
    padding-block: 1.5rem;
  }

  .coming-soon__content {
    margin-bottom: 0;
  }

  .coming-soon__logo {
    width: 22vh;
  }

  .coming-soon__title {
    margin-top: 4vh;
    font-size: 14vh;
  }

  .coming-soon__text {
    margin-top: 2.5vh;
    font-size: max(1rem, 4.2vh);
  }

  .button {
    min-height: 2.75rem;
    margin-top: 5vh;
    font-size: max(0.875rem, 3.4vh);
  }

  /* El contenido es proporcionalmente más alto: el pollo se corre para no tocar el botón */
  .decor--pollo {
    left: calc(50% - 700 * var(--px));
  }
}

@media (prefers-reduced-motion: reduce) {
  .button {
    transition: none;
  }
}
