/* Tipografía y reset movidos a base.css */

#inicio button {
  /* corregido typo: '2x' -> '2px' y valor rgba mal formado -> 0.5 */
  border: 2px solid rgba(0, 0, 0, 0.5);
  width: 110px;
  height: 110px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 1.5em;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  color: white;
  background-color: var(--color-primary);
  border-radius: 50%;
  cursor: pointer;
}

/* Emergency safe guard: prevent any page-wide horizontal scroll caused by
   transformed tracks, negative-positioned buttons or layout gaps. This is a
   defensive rule; it's safe and non-destructive for most layouts. */
html,
body {
  overflow-x: hidden !important;
}

/* Navbar móvil: fondo blanco y enlaces con estilo como en escritorio */
@media (max-width: 726px) {
  .navbar-menu {
    background-color: var(--color-white) !important;
  }

  .navbar-menu a,
  .navbar-menu .link {
    color: var(--color-dark) !important;
    text-shadow: none !important;
    font-size: 1.25em;
    font-weight: 400;
    padding: 5px 10px;
    display: inline-flex;
    align-items: center;
    width: auto;
  }

  /* Asegurar que el subrayado animado use el color oscuro en móvil */
  .navbar-menu a::after {
    background: var(--color-dark);
  }
}

#justeat,
#glovo {
  background-size: cover;
  width: 130px;
  height: 130px;
  display: block;
  margin: 0 auto; /* centrar dentro de su contenedor */
  align-self: center;
}

#justeat {
  background-image: url("../img/justeat.webp");
}

#glovo {
  background-image: url("../img/glovo.webp");
}

button:hover {
  background-color: grey;
}

.container {
  margin: auto;
}

.color-acc {
  color: var(--color-primary);
}

.color-ac {
  color: var(--color-primary);
}

.color-ac:hover {
  color: var(--color-primary);
}

/* Mantener header siempre con fondo blanco; comprobaremos comportamiento al hacer scroll */
header.scrolled {
  background-color: var(--color-white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

header.unscrolled {
  background-color: var(--color-white);
}

header.unscrolled .logo {
  margin: 0;
  padding: 0px 25px;
  font-weight: 400;
  color: var(--color-white);
  font-size: 1.2em;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
}

header.scrolled .logo {
  margin: 0;
  font-weight: 400;
  color: var(--color-primary);
  font-size: 1.2em;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
}

header .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  /* asegurar que el contenedor del header ocupe todo el ancho
     (anula la regla global .container cuando está dentro del header) */
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

header nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: 25px;
  align-items: center;
}

header.scrolled a {
  text-decoration: none;
  color: var(--color-dark);
  font-size: 1.25em;
  font-weight: 400;
  padding: 5px 10px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
}

header.unscrolled a {
  text-decoration: none;
  color: var(--color-dark);
  font-size: 1.25em;
  font-weight: 400;
  padding: 5px 10px;
  text-shadow: none;
  transition: all 0.2s linear;
}

/* Cambiar comportamiento hover: mostrar subrayado animado SOLO en enlaces del menú
   (excluir el logo). */
.navbar-menu a {
  position: relative;
  text-decoration: none;
  display: inline-block;
}

/* Subrayado animado SOLO bajo el texto: envolvemos el texto en .link-text */
.navbar-menu a .link-text {
  position: relative; /* referencia para el pseudo-elemento */
  display: inline-block;
  padding: 5px 10px; /* mantener el padding en el span para accesibilidad */
}

.navbar-menu a .link-text::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  height: 2px;
  width: 0;
  background: var(--color-dark);
  transition: width 0.25s ease;
}

.navbar-menu a:hover .link-text::after {
  width: 100%;
}

/* Asegurar que el enlace del logo no muestre pseudo-elementos ni subrayado */
.logo-d {
  text-decoration: none !important;
}
.logo-d::after {
  display: none !important;
}

.navbar-title {
  width: 100%;
  /* fijar una altura máxima para el header logo y esconder cualquier overflow
     así el logo no sobresale y siempre queda contenido dentro del header */
  height: 100px;
  overflow: hidden;
  padding: 6px 0;
  display: flex;
  justify-content: flex-start;
  align-items: center;
}

.a-space {
  color: rgb(66, 64, 64);
  font-size: 1.25em;
  font-weight: bold;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
}

.enc-svg {
  filter: drop-shadow(8px 8px 10px var(--color-muted));
  stroke: var(--color-accent);
}

#enc-a:hover + .enc-svg {
  stroke: var(--color-accent);
  transition: all 0.2s linear;
}

#enc-a:hover {
  color: var(--color-accent);
  stroke: var(--color-accent);
  transition: all 0.2s linear;
}

#enc-a {
  text-decoration: none;
  font-weight: bold;
  padding: 5px 10px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
  display: flex;
  align-items: center;
}

.enc {
  display: flex;
  flex-direction: row;
  align-items: center;
  width: 100%;
  line-height: 2;
}

.enc-t.scrolled {
  color: var(--color-dark);
}

#inicio {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex-direction: column;
  height: 120vh;
  color: white;
  background-image: linear-gradient(
      0deg,
      rgba(0, 0, 0, 0.5),
      rgba(0, 0, 0, 0.5)
    ),
    url("../img/cafeteria.webp");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center center;
  position: relative; /* necesario para posicionar .inicio-curvas */
}

/* Contenedor interno del hero para desplazar su contenido un poco hacia abajo */
#inicio .inicio-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  /* mover hacia abajo respecto al centro del viewport */
  transform: translateY(-5vh);
}

@media (max-width: 726px) {
  #inicio .inicio-inner {
    transform: translateY(6vh);
  }
}

/* curva de transición al final del hero */
.inicio-curvas {
  /* Posicionado absolutamente dentro de #inicio para que se solape
    con la parte inferior del hero. Aumentamos tamaño de la imagen
    para que la curva sea más evidente. */
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 22vh;
  max-height: 260px;
  background-image: url("../img/curvas.webp");
  background-repeat: no-repeat;
  background-position: bottom center;
  /* Hacer la imagen más grande para que la curva ocupe más área */
  background-size: 140% auto;
  pointer-events: none;
  z-index: 5;
}

@media (max-width: 726px) {
  .inicio-curvas {
    /* en móvil mantener posicion absoluta y aumentar visibilidad */
    height: 26vh;
    max-height: 220px;
    background-size: 160% auto;
    bottom: 0;
  }
}

#inicio h1 {
  color: white;
  padding-top: 30px;
}

#inicio span {
  color: rgba(255, 255, 255, 0.671);
  padding-top: 30px;
  font-weight: bold;
}

#inicio button {
  font-size: 1.75em;
  margin: 0px 30px;
}

#inicio .container {
  flex-direction: row;
  margin: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  /* centrar elementos (botones) dentro del contenedor de inicio */
  justify-content: center;
  width: 100%;
}

#menu {
  background: var(--color-white);
  width: 100%;
  padding: 60px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Grid limpio y responsive para las tarjetas */
.menu {
  max-width: calc(var(--container-width) + 160px);
  width: 100%;
  display: grid;
  /* Make columns grow up to a reasonable max so a single card doesn't stretch full width.
     Use auto-fit with a max column width and center the grid. */
  grid-template-columns: repeat(auto-fit, minmax(280px, 820px));
  gap: 24px;
  margin-top: 12px;
  padding: 0 8px;
  justify-content: center;
  justify-items: center;
}

.menu.menu-row.menu-row--drinks {
  width: min(960px, 100%);
}

/* Forzar que .menu-row coloque sus hijos en una sola fila.
   Use flex no-wrap para mantenerlos en línea y overflow-x:auto
   para permitir scroll horizontal en pantallas pequeñas. */
.menu-row {
  display: flex;
  flex-direction: row;
  /* permitir que las cartas ocupen fila pero puedan hacer wrap en pantallas
     estrechas; no queremos scroll horizontal para los desayunos. */
  flex-wrap: wrap;
  gap: 24px;
  align-items: stretch;
  justify-content: flex-start;
  width: 100%;
  padding-bottom: 8px;
}

/* Por defecto los hijos se adaptan al espacio; en escritorio forzamos dos
   columnas con un ancho base, en móvil ocupan 100% (lista vertical). */
.menu-row > * {
  flex: 1 1 100%;
  max-width: 100%;
}

@media (min-width: 727px) {
  .menu-row > * {
    flex: 0 0 calc(50% - 12px);
    max-width: calc(50% - 12px);
  }
}

@media (max-width: 726px) {
  .menu-row {
    gap: 16px;
  }
  .menu-row > * {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

#menu h3 {
  padding: 0;
  margin: 0 0 18px 0;
  font-weight: 600;
  color: var(--dark-slate-grey);
  font-size: 1.75rem;
  text-shadow: none;
}

.menu-h {
  display: block;
  padding-bottom: 8px;
  /* espacio superior para separar visualmente cada bloque */
  padding-top: 24px;
}

/* Ensure cards don't stretch full width when there's a single card; center them */
.menu > .carta {
  max-width: 820px;
  margin: 0 auto;
}

#menu h2 {
  font-size: 2.25rem;
  color: var(--dark-slate-grey);
  margin: 0 0 8px 0;
}

.h-menu {
  text-align: center;
  padding: 8px 0 24px 0;
}

#menu p {
  max-width: 900px;
  margin: 0 auto 20px auto;
  color: var(--color-black);
  line-height: 1.6;
}

.carta p {
  font-size: 16px;
  line-height: 1.6;
  max-width: 100%;
  margin: 0;
  color: var(--dark-slate-grey);
}

.carta p a {
  text-decoration: underline;
  color: var(--color-primary);
  font-size: 1em;
  padding-left: 4px;
  text-shadow: none;
}

.carta p a:hover {
  color: var(--color-accent);
}

.carta p a::after {
  display: none;
}

.img-menu {
  width: 100%;
  height: 180px;
  border-radius: 10px;
  background-image: url("../img/postres.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  margin-bottom: 12px;
}

#menu .carta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  margin: 0;
  padding: 20px;
  border-radius: var(--radius-md);
  color: var(--dark-slate-grey);
  background-color: var(--almost-white);
  width: 100%;
  /* una sombra ligera para dar profundidad */
  box-shadow: 0 8px 20px rgba(17, 17, 17, 0.06);
}

/* Product card (desayunos) */
.carta--product {
  display: flex;
  flex-direction: column;
  background-color: var(--almost-white);
  padding: 0;
  border-radius: 12px;
  overflow: hidden;
}

.carta--product .img-menu {
  height: 145px;
  min-height: 145px;
  max-height: 145px;
  width: 100%;
  max-width: 240px;
  border-radius: 0;
  margin: 0 auto;
  background-size: cover;
  background-position: center;
}

.carta--product .card-body {
  padding: 14px;
}

.carta-title {
  margin: 0 0 6px 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark-slate-grey);
}

.carta-desc {
  margin: 0 0 8px 0;
  color: var(--color-muted);
  font-size: 0.95rem;
}

.carta-price {
  margin: 0;
  font-weight: 700;
  color: var(--color-primary);
}

/* Align action button to the bottom-right inside product cards */
.card-actions.card-actions-right {
  justify-content: flex-end;
  padding: 12px 14px 16px 14px;
}

/* Drink card: large image and footer name */
.carta--drink {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 0;
  border-radius: 12px;
  overflow: hidden;
  background: var(--almost-white);
}

.carta--drink .img-menu {
  min-height: 160px;
  height: 160px;
  border-radius: 0;
}

.carta-footer {
  padding: 12px;
  text-align: center;
  font-weight: 700;
  color: var(--dark-slate-grey);
  background: transparent;
}

/* Ensure .menu-row cards have visual separation */
.menu.menu-row > .carta {
  margin: 0;
  border-radius: 12px;
}

/* Force equal sizes for breakfast product cards */
.carta--product {
  height: 420px; /* fixed height so both cards match */
  display: flex;
  flex-direction: column;
}
.carta--product .card-body {
  /* Make the body a flex column so its inner content can be vertically centered
     while the .card-actions stays pinned to the bottom via margin-top:auto. */
  display: flex;
  flex-direction: column;
  justify-content: center; /* vertical centering */
  align-items: flex-start; /* keep text left-aligned on desktop by default */
  align-self: center; /* center the body container within the card horizontally */
  flex: 1 1 auto; /* allow body to grow and push actions to bottom */
}
.carta--product .card-actions {
  /* ensure action stays at the bottom of the product card */
  margin-top: auto;
  align-self: flex-end;
  width: auto;
}

/* Reinforce equal card height on desktop with higher specificity */
@media (min-width: 727px) {
  #menu .menu.menu-row > .carta.carta--product {
    height: 420px !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }
  #menu .menu.menu-row > .carta.carta--product .img-menu {
    height: 160px !important;
    background-size: cover !important;
    background-position: center center !important;
  }
}

/* Carousel styles for drinks */
.menu-carousel {
  position: relative;
  overflow: visible;
  width: min(960px, 100%);
  margin: 0 auto;
  box-sizing: border-box;
  padding: 0 60px;
}

.menu-row--drinks {
  position: relative;
  display: block;
  min-height: 360px;
  padding: 32px 48px;
  box-sizing: border-box;
  margin: 0 auto;
}

.menu-carousel .menu.menu-row.menu-row--drinks {
  width: 100%;
  max-width: 100%;
  justify-self: stretch;
  grid-template-columns: none;
}

/* Carousel dots */
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 12px;
}
.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-muted);
  cursor: pointer;
  display: inline-block;
  border: none;
}
.carousel-dot.active {
  background: var(--color-primary);
  transform: scale(1.2);
}

/* Hide dots in infinite loop mode as requested */
.carousel-dots {
  display: none !important;
}

/* Make dot labels bold when active (also support text dots) */
.carousel-dot[aria-pressed="true"] {
  font-weight: 700;
}

.carousel-group {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: clamp(16px, 2vw, 32px);
  justify-content: center;
  align-content: center;
  padding: 0 clamp(16px, 4vw, 48px);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
  z-index: 1;
}

.carousel-group.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  z-index: 2;
}

.carousel-group .carta {
  width: 100%;
  max-width: 240px;
}

.menu-carousel .menu.menu-row.menu-row--drinks,
.menu-carousel .menu {
  max-width: 960px !important;
  width: 100% !important;
  display: block !important;
}

#menu .menu-carousel .menu.menu-row.menu-row--drinks {
  display: block !important;
  width: 75vw !important;
  max-width: min(960px, 100%) !important;
  padding: 0 !important;
  margin: 0 auto !important;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--color-dark);
  z-index: 3;
}

.carousel-prev {
  left: -52px;
}

.carousel-next {
  right: -52px;
}

@media (min-width: 727px) {
  .carousel-btn {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  /* make drinks show as carousel (320px cards) on desktop */
  .menu-row--drinks {
    padding: 12px 48px;
  }
}

@media (max-width: 726px) {
  .menu-row--drinks > .carta {
    flex: 0 0 84%;
    max-width: 84%;
  }
  .carousel-btn {
    display: none;
  }

  .carousel-group {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px !important;
    position: static;
    opacity: 1 !important;
    transform: none !important;
    pointer-events: auto !important;
    z-index: auto !important;
  }

  .carousel-group .carta {
    flex: initial;
    width: 100%;
    max-width: 100%;
  }
}

/* Mobile tweaks requested: center breakfast text/button and show drinks as 2x2 grid */
@media (max-width: 726px) {
  /* Desayunos: center text and CTA */
  .menu.menu-row .carta--product .card-body {
    text-align: center !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  .menu.menu-row .carta--product .card-actions.card-actions-right {
    justify-content: center !important;
    align-items: center !important;
    align-self: center !important;
    padding-bottom: 12px !important;
  }

  .menu.menu-row .carta--product .card-body .carta-title,
  .menu.menu-row .carta--product .card-body .carta-desc,
  .menu.menu-row .carta--product .card-body .carta-price {
    text-align: center !important;
  }

  /* Bebidas: switch carousel-track into a 2-column grid */
  #menu .menu.menu-row.menu-row--drinks {
    overflow: visible !important;
  }
  #menu .menu.menu-row.menu-row--drinks .carousel-track {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px !important;
    transform: none !important;
    transition: none !important;
  }
  #menu .menu.menu-row.menu-row--drinks .carousel-track > .carta {
    flex: initial !important;
    max-width: 100% !important;
    min-width: initial !important;
    width: 100% !important;
  }
  /* hide carousel nav buttons and dots on mobile if desired */
  .carousel-btn {
    display: none !important;
  }
  .carousel-dots {
    display: none !important;
  }
}

/* Stronger mobile override: ensure the .card-body is centered both vertically
   and horizontally and the CTA is centered. Use #menu selector to increase
   specificity and !important where necessary to beat competing rules. */
@media (max-width: 726px) {
  #menu .menu.menu-row > .carta.carta--product .card-body {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important; /* center horizontally */
    text-align: center !important;
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  #menu .menu.menu-row > .carta.carta--product .card-actions,
  #menu
    .menu.menu-row
    > .carta.carta--product
    .card-actions.card-actions-right {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    align-self: center !important;
    width: 100% !important;
    padding: 12px !important;
  }

  #menu .menu.menu-row > .carta.carta--product .card-actions .btn-cta {
    margin: 0 auto !important;
  }
}

.card-actions {
  margin-top: auto;
  width: 100%;
  display: flex;
  justify-content: center; /* centrar el CTA horizontalmente */
  align-items: flex-end;
}

.btn-cta {
  display: inline-block;
  background: var(--color-primary);
  color: var(--color-white);
  padding: 12px 22px; /* un poco más grande */
  border-radius: 999px; /* más redondeado */
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 10px 24px rgba(17, 17, 17, 0.08);
  transition: transform 160ms ease, background 160ms ease;
}

.btn-cta:hover {
  background: var(--color-accent);
  transform: translateY(-3px);
}

#menu .carta:hover {
  transform: translateY(-4px);
  transition: transform 180ms ease;
}

/* Carta que contiene solo imagen: hacer que la imagen ocupe todo el espacio */
.carta--image {
  padding: 0; /* quitar padding para que la imagen llene la carta */
  overflow: hidden;
}

.carta--image .img-menu {
  width: 100%;
  height: 100%;
  min-height: 260px;
  border-radius: 0; /* la carta tiene el radio ya */
  background-image: url("../img/postres.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: block;
}

/* En pantallas de escritorio: forzar dos columnas en la row y alturas iguales */
@media (min-width: 727px) {
  .menu {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 1fr; /* filas con altura igual a la más alta */
    align-items: stretch;
  }

  /* cada carta ocupa el 100% de la celda (igualando alturas) */
  #menu .carta {
    height: 100%;
    display: flex;
    flex-direction: column;
  }

  /* Asegurar que la carta-imagen llene su contenedor cuando esté en la misma fila */
  .carta--image .img-menu {
    height: 100%;
  }
}

#logros .container {
  text-align: center;
  padding: 100px 0px;
}

#logros li {
  margin: 16px 0px;
  font-weight: bold;
  font-size: 1.25em;
}

#contacta {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  flex-direction: column;
  height: 90vh;
  background-color: rgba(30, 30, 30);
  color: white;
  height: 100%;
}

#contacto button {
  font-size: 1.75em;
}

.footer-distributed {
  background: var(--color-dark);
  box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.12);
  box-sizing: border-box;
  width: 100%;
  text-align: left;
  padding: 50px 60px 40px;
  overflow: hidden;
  display: inline-block;
  font-family: var(--font-sans);
  vertical-align: top;
}

/* Footer left */

.footer-distributed .footer-left {
  float: left;
}

/* Logo */

.footer-distributed h3 {
  color: var(--color-white);
  margin: 0 0 10px;
}

.footer-distributed h3 span {
  color: var(--color-highlight);
}

/* Footer links */

.footer-distributed .footer-links {
  color: var(--color-white);
  margin: 0 0 10px;
  padding: 0;
}

.footer-distributed .footer-links a {
  display: inline-block;
  line-height: 1.8;
  text-decoration: none;
  color: inherit;
}

.footer-distributed .footer-company-name {
  color: var(--color-muted);
  font-size: 18px;
  font-weight: normal;
  margin: 0;
}

.footer-distributed .footer-icons {
  margin-top: 40px;
}

.footer-distributed .footer-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  margin-right: 10px;
  cursor: pointer;
  background-color: var(--color-dark);
  border-radius: 50%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;

  font-size: 20px;
  color: var(--color-white);
  text-align: center;
  line-height: 1;

  margin-right: 3px;
  margin-bottom: 5px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 60%;
}

.footer-distributed p {
  font-size: 25px;
}

.footer-distributed .footer-icons #fb {
  background-image: url("../img/facebuk.webp");
}

.footer-distributed .footer-icons #ig {
  background-image: url("../img/instagram3.webp");
}

.footer-distributed .footer-icons #maps {
  background-image: url("../img/periscope.webp");
}

.footer-distributed .footer-icons a:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.25);
}

/* Footer right */

.footer-distributed .footer-right {
  float: right;
}

.footer-distributed .footer-right p {
  display: flex;
  flex-direction: column;
  vertical-align: bottom;
  margin: 15px 42px 0 0;
  color: var(--color-white);
  align-items: flex-end;
  font-size: 1.2em;
}

/* Contacto */

.footer-distributed form {
  display: inline-block;
  clear: right;
}

.footer-distributed form input,
.footer-distributed form textarea {
  display: block;
  border-radius: 3px;
  box-sizing: border-box;
  background-color: var(--color-dark);
  box-shadow: 0 1px 0 0 rgba(255, 255, 255, 0.1);
  border: none;
  resize: none;

  font: inherit;
  font-size: 14px;
  font-weight: normal;
  color: var(--silver);

  width: 400px;
  padding: 18px;
}

.footer-distributed ::-webkit-input-placeholder {
  color: var(--color-muted);
}

.footer-distributed ::-moz-placeholder {
  color: var(--color-muted);
  opacity: 1;
}

.footer-distributed :-ms-input-placeholder {
  color: var(--color-muted);
}

.footer-distributed form input {
  height: 55px;
  margin-bottom: 15px;
}

.footer-distributed form textarea {
  height: 100px;
  margin-bottom: 20px;
}

.footer-distributed form button {
  border-radius: 3px;
  background-color: var(--color-dark);
  color: var(--color-white);
  border: 0;
  padding: 15px 50px;
  font-weight: bold;
  float: right;
  text-align: center;
  width: 400px;
  height: 100px;
  color: var(--silver);
}

.footer-distributed form button:hover {
  color: var(--silver);
}

@media (max-width: 1000px) {
  .footer-distributed .footer-company-name {
    font-size: 12px;
  }

  .footer-distributed form input,
  .footer-distributed form textarea {
    width: 250px;
  }

  .footer-distributed form button {
    padding: 10px 35px;
  }
}

@media (max-width: 800px) {
  .footer-distributed {
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .footer-distributed .footer-left,
  .footer-distributed .footer-right {
    float: none;
    clear: right;
  }

  .footer-distributed .footer-left {
    margin-bottom: 40px;
    align-items: center;
    justify-content: center;
  }

  .footer-distributed form {
    margin-top: 30px;
  }

  .footer-distributed form {
    display: block;
  }

  .footer-distributed form button {
    float: none;
  }

  .footer-distributed .footer-right p {
    display: block;
    margin: 0;
    text-align: center;
  }

  .footer-links {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
  }

  .footer-links a {
    margin: 0 10px;
  }

  .footer-distributed .footer-icons a {
    margin-right: 0;
  }

  .footer-distributed .footer-company-name {
    margin-top: 10px;
    text-align: center;
    font-size: 16px;
  }

  .footer-distributed .footer-icons {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
  }

  .footer-distributed .footer-icons a {
    margin-right: 10px;
  }
}

@media (min-width: 727px) {
  header {
    position: fixed;
    width: 100%;
    z-index: 100;
    display: flex;
  }

  header .container {
    flex-direction: row;
    justify-content: space-between;
    margin: 0px;
    width: 100%;
  }

  header nav {
    flex-direction: row-reverse;
    padding-bottom: 0;
    width: 100%;
  }

  header button {
    display: none;
  }

  .mainInner {
    display: none;
  }

  #hero h1 {
    font-size: 4em;
  }

  #menu .texto {
    width: 50%;
    text-align: initial;
    padding: 0px 30px;
    max-width: 600px;
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
  }

  #menu h2 {
    margin: 0;
  }

  #inicio .proyectos {
    justify-content: center;
  }

  #inicio p {
    display: block;
    margin-bottom: 30px;
  }

  #inicio h3 {
    margin-top: 0px;
  }

  #inicio .carta {
    padding: 15px;
  }

  #inicio .carta .img-container {
    height: 300px;
    width: 300px;
  }

  #inicio .carta .img-container img {
    height: 100%;
    width: 100%;
    object-fit: cover;
  }

  #contacto .container {
    text-align: left;
  }

  #contacto h2 {
    margin-left: 50px;
  }

  #contacto ul {
    margin-left: 10px;
    font-size: 0.85em;
  }

  #contacto button {
    font-size: 1.75em;
  }
}

.author {
  font-size: 0.75em !important;
  color: var(--color-muted) !important;
  text-align: center;
  margin-top: 20px;
}

.author a {
  text-decoration: none;
  font-size: 1em;
  padding-left: 5px;
  color: var(--color-muted) !important;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
  transition: all 0.2s linear;
}

.author a:hover {
  color: var(--color-white) !important;
  text-decoration: none;
}

.author a::after {
  content: "";
  display: block;
  width: 0;
  height: 2px;
  background: var(--color-white);
  transition: width 0.4s ease;
  text-decoration: none;
}

.sbuttons {
  bottom: 5%;
  position: fixed;
  margin: 1em;
  left: 0;
  z-index: 1000;
}
.sbutton {
  display: block;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  text-align: center;
  color: white;
  margin: 20px auto 0;
  box-shadow: 0px 5px 11px -2px rgba(0, 0, 0, 0.18),
    0px 4px 12px -7px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  -webkit-transition: all 0.1s ease-out;
  transition: all 0.1s ease-out;
  position: relative;
}
.sbutton > i {
  font-size: 38px;
  line-height: 60px;
  transition: all 0.2s ease-in-out;
  transition-delay: 2s;
}
.sbutton:active,
.sbutton:focus,
.sbutton:hover {
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.14), 0 4px 8px rgba(0, 0, 0, 0.28);
}
.sbutton:not(:last-child) {
  width: 60px;
  height: 60px;
  margin: 20px auto 0;
  opacity: 0;
}
.sbutton:not(:last-child) > i {
  font-size: 25px;
  line-height: 60px;
  transition: all 0.3s ease-in-out;
}
.sbuttons:hover .sbutton:not(:last-child) {
  opacity: 1;
  width: 60px;
  height: 60px;
  margin: 15px auto 0;
}
.sbutton:nth-last-child(1) {
  -webkit-transition-delay: 25ms;
  transition-delay: 25ms;
}
.sbutton:not(:last-child):nth-last-child(2) {
  -webkit-transition-delay: 20ms;
  transition-delay: 20ms;
}
.sbutton:not(:last-child):nth-last-child(3) {
  -webkit-transition-delay: 40ms;
  transition-delay: 40ms;
}
.sbutton:not(:last-child):nth-last-child(4) {
  -webkit-transition-delay: 60ms;
  transition-delay: 60ms;
}
.sbutton:not(:last-child):nth-last-child(5) {
  -webkit-transition-delay: 80ms;
  transition-delay: 80ms;
}
.sbutton:not(:last-child):nth-last-child(6) {
  -webkit-transition-delay: 100ms;
  transition-delay: 100ms;
}

[tooltip]:before {
  font-family: "Roboto";
  font-weight: 600;
  border-radius: 2px;
  background-color: #585858;
  color: #fff;
  content: attr(tooltip);
  font-size: 12px;
  visibility: hidden;
  opacity: 0;
  padding: 5px 7px;
  margin-left: 10px;
  position: absolute;
  left: 100%;
  bottom: 20%;
  white-space: nowrap;
}

[tooltip]:hover:before,
[tooltip]:hover:after {
  visibility: none;
  opacity: 1;
}
.sbutton.mainsbutton {
  background: var(--color-justeat);
}
.sbutton.gplus {
  background: #f44336;
}
.sbutton.pinteres {
  background: var(--color-pinterest);
}
.sbutton.twitt {
  background: var(--color-twitter);
}
.sbutton.fb {
  background: var(--color-facebook);
}
.sbutton.whatsapp {
  background: var(--color-whatsapp);
}

@media screen and (max-width: 726px) {
  header .logo {
    width: 100%;
    text-align: center;
  }

  .footer-distributed h3 {
    font-size: 26px;
    text-align: center;
  }

  .menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .footer-distributed a {
    font-size: 18px;
  }

  .footer-distributed .footer-icons {
    margin: 20px auto;
  }

  .footer-distributed .footer-left {
    margin: 0;
  }

  .footer-distributed .footer-right p {
    text-align: center;
    font-size: 16px;
    padding: 5px;
  }

  header .logo {
    width: 100%;
    text-align: center;
    font-size: 23px;
  }

  header a {
    color: var(--color-primary) !important;
  }

  .footer-distributed h3 {
    font-size: 26px;
    text-align: center;
  }

  .menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .footer-distributed a {
    font-size: 18px;
  }

  header .container {
    margin: 0;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
  }

  .mainInner {
    margin-right: 20px;
  }

  header.unscrolled svg {
    stroke: var(--color-primary);
  }

  svg {
    width: 25px;
    height: 25px;
    stroke: var(--color-primary);
    cursor: pointer;
  }

  .svg-x {
    margin-left: 10px;
  }

  .cover {
    display: block;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-color: transparent;
    z-index: 2;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s ease;
  }

  .header-wrap {
    width: 100%;
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 10;
  }

  .header-wrap .mainInner {
    max-width: calc(1050px + 40px);
    /* permitir que el header crezca con el logo: usar min-height en lugar de height */
    min-height: 100px;
    padding: 0 20px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .navbar-title h1 {
    font-size: 26px;
    font-weight: 400;
    letter-spacing: 2px;
    color: #f6f6f6;
  }

  /* navbar-menu background intentionally left to responsive rules (mobile/desktop)
     Removed hard-coded taupe background so mobile white background can apply. */

  .navbar-menu ul {
    display: flex;
    list-style: none;
  }

  .navbar-menu ul li:not(:last-child) {
    margin-right: 30px;
  }

  .navbar-menu .link {
    display: inline-flex; /* evitar que el enlace ocupe todo el ancho */
    align-items: center;
    font-size: 15px;
    width: auto;
    padding: 5px 10px;
  }

  .navbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .theme-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.5);
    background: transparent;
    color: var(--color-white);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease;
  }

  .theme-toggle:hover {
    transform: translateY(-2px);
    border-color: var(--color-light);
  }

  body.dark-theme .theme-toggle {
    border-color: rgba(255, 255, 255, 0.8);
    color: var(--color-light);
  }

  .navbar-menu .link::hover {
    color: var(--color-primary);
  }

  .navbar-close,
  .navbar-icon,
  .navbar-icon > * {
    display: none;
    align-items: center;
  }

  .main-wrap {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    height: 100vh;
    filter: brightness(60%);
    -webkit-filter: brightness(60%);
  }

  .navbar-menu ul {
    flex-direction: column;
  }

  .navbar-menu ul li:not(:last-child) {
    margin: 0;
  }

  .navbar-menu .link {
    padding: 14px 22px;
  }

  .navbar-close {
    padding: 30px 22px 14px 22px !important;
    justify-content: flex-end;
    width: 100%;
  }

  .navbar-close label {
    display: flex;
    align-items: center;
    color: var(--color-primary);
  }

  .off-navmenu:checked ~ .navbar-menu {
    right: 0;
    visibility: visible;
    opacity: 1;
  }

  .off-navmenu:checked ~ .navC {
    backdrop-filter: blur(2px);
    background-color: rgba(0, 0, 0, 0.8);
    opacity: 1;
    visibility: visible;
  }

  .enc {
    display: block;
    width: auto;
  }

  .enc svg {
    display: none;
  }
}

#cookiePopup {
  background-color: var(--color-white);
  position: fixed;
  font-size: 14px;
  width: 70vw;
  max-width: 42.85em;
  box-shadow: 0 0 2em rgba(5, 0, 31, 0.15);
  font-family: "Poppins", sans-serif;
  text-align: justify;
  line-height: 1.8em;
  padding: 2em 1.4em;
  border-radius: 6px;
  transition: all 0.5s ease-in;
  z-index: 4;
}

#cookiePopup img {
  display: block;
  width: 10em;
  height: 100%;
  transform: translateZ(0);
  position: relative;
  margin: auto;
}

#cookiePopup p {
  text-align: center;
  margin: 1.4em 0;
}

#cookiePopup button {
  background-color: var(--color-btn-primary);
  border: none;
  color: var(--color-white);
  font-size: 1.2em;
  padding: 0.5em 0.7em;
  display: block;
  position: relative;
  margin: auto;
  border-radius: 5px;
  width: 90px;
  height: 70px;
  cursor: pointer;
}
#cookiePopup a {
  color: var(--color-btn-primary);
}

.hide {
  visibility: hidden;
  bottom: 0;
  right: 2em;
}

.show {
  visibility: visible;
  bottom: 2em;
  right: 2em;
}

@media only screen and (max-width: 37.5em) {
  #cookiePopup {
    width: 100%;
  }
  .hide {
    bottom: 2em;
    right: 0;
  }
  .show {
    right: 0;
    bottom: 0;
  }
}

@media (min-width: 767px) {
  .menu {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0 0 40px 0;
  }
}

@media (max-width: 767px) {
  .menu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }
}

@media (max-width: 726px) {
  /* reducir padding-top en mobile para ahorrar espacio vertical */
  .menu-h {
    padding-top: 16px;
  }
}

.hidden {
  display: none;
}

.cover {
  display: block;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background-color: transparent;
  z-index: 2;
  opacity: 0;
  visibility: hidden;
  transition: 0.2s ease;
}

.header-wrap {
  width: 100%;
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 10;
}

header.scrolled.header-wrap .container .mainInner {
  height: 60px;
}

.header-wrap .mainInner {
  width: 100%;
  /* usar min-height para contener el logo aumentado */
  min-height: 100px;
  padding: 0 20px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* Transición para animar cambios al añadir/quitar la clase .scrolled */
  transition: padding 0.3s ease, height 0.3s ease, min-height 0.3s ease;
}

.navbar-title h1 {
  font-size: 26px;
  font-weight: 400;
  letter-spacing: 2px;
  color: #f6f6f6;
}

/* Eliminada regla de reducción del logo al hacer scroll (pedido del usuario).
   El logo mantendrá su tamaño y el header contendrá su altura mediante
   min-height en .header-wrap .mainInner. */
/* (Regla previa comentada para referencia)
header.scrolled .logo-img,
.header-wrap.header.scrolled .logo-img {
  max-height: 48px;
  padding: 4px 6px;
  transition: max-height 0.25s ease, padding 0.25s ease;
}
*/

.navbar-menu ul {
  display: flex;
  list-style: none;
  justify-content: center;
  text-align: center;
  align-items: center;
}

.navbar-close,
.navbar-icon,
.navbar-icon > * {
  display: none;
  align-items: center;
}

.main-wrap {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 100vh;
  filter: brightness(60%);
  -webkit-filter: brightness(60%);
}

@media screen and (max-width: 726px) {
  .navbar-menu {
    position: fixed;
    top: 0;
    right: -100%;
    bottom: 0;
    width: 55%;
    height: 100vh;
    z-index: 20;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s ease;
  }

  .navbar-actions {
    margin-top: 12px;
    justify-content: center;
    width: 100%;
  }

  .navbar-menu ul {
    flex-direction: column;
    width: 100%;
    padding: 0;
  }

  .navbar-menu ul li:not(:last-child) {
    margin: 0;
  }

  .a-space {
    display: none;
  }

  #enc-a {
    padding: 14px 22px;
    width: auto;
  }

  .navbar-menu .link {
    padding: 14px 22px;
  }

  .navbar-menu .link::hover {
    color: var(--color-primary);
  }

  .navbar-close,
  .navbar-icon,
  .navbar-icon > * {
    display: flex;
  }

  .navbar-close {
    padding: 14px 22px;
    justify-content: flex-end;
  }

  .navbar-close label {
    display: flex;
    align-items: center;
  }

  .navbar-close label::before {
    content: "Cerrar";
    font-size: 17px;
    color: var(--color-primary);
    font-weight: bold;
    opacity: 0.9;
    cursor: pointer;
    transition: 0.2s ease;
  }

  .off-navmenu:checked ~ .navbar-menu {
    right: 0;
    visibility: visible;
    opacity: 1;
  }

  .off-navmenu:checked ~ .navC {
    backdrop-filter: blur(2px);
    background-color: rgba(0, 0, 0, 0.8);
    opacity: 1;
    visibility: visible;
  }
}

/* Forzar layout de dos columnas y alturas iguales para #menu en escritorio
   con mayor especificidad para evitar reglas anteriores que lo cambien */
@media (min-width: 767px) {
  #menu .menu {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 24px !important;
    grid-auto-rows: 1fr !important;
    align-items: stretch !important;
  }

  #menu .menu > .carta {
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
  }

  #menu .carta--image .img-menu {
    height: 100% !important;
    max-height: 420px !important;
  }
}

/* Fallback: forzar layout en flex si grid no toma efecto por algún conflicto */
@media (min-width: 767px) {
  #menu .menu {
    display: flex !important;
    flex-direction: row !important;
    /* allow wrapping so single item can be centered and multiple items flow */
    flex-wrap: wrap !important;
    /* center items as a group */
    justify-content: center !important;
    gap: 24px !important;
    align-items: stretch !important;
  }

  #menu .menu > .carta {
    flex: 0 0 calc(50% - 12px) !important; /* dos columnas con gap aproximado */
    max-width: calc(50% - 12px) !important;
  }

  /* asegurar la imagen no desborde y ocupe la altura de la carta */
  #menu .carta--image .img-menu {
    height: 100% !important;
    max-height: 420px !important;
  }
}

/* Separación entre bloques repetibles: .menu-block hermanos */
.menu-block + .menu-block {
  margin-top: 28px;
}

@media (max-width: 726px) {
  .menu-block + .menu-block {
    margin-top: 18px;
  }
}

/* High-specificity override for the drinks carousel to beat the #menu rules
   that force two-column grid/flex layouts. This ensures the drinks area
   becomes a single-row scrollable carousel showing 3 cards per view. */
@media (min-width: 727px) {
  #menu .menu.menu-row.menu-row--drinks {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    overflow: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    gap: 20px !important;
    padding: 12px 48px !important;
    scroll-snap-type: x mandatory !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
  }

  /* Force each drink card to take ~1/3 of the available viewport area but
     cap sizes so they remain visually similar to the breakfast cards. */
  #menu .menu.menu-row.menu-row--drinks .carousel-track > .carta {
    flex: 0 0 calc((100% - 40px) / 3) !important;
    max-width: 360px !important;
    min-width: 260px !important;
    scroll-snap-align: center !important;
  }

  /* Track that wraps cards when using transform-based carousel */
  #menu .menu.menu-row.menu-row--drinks .carousel-track {
    display: flex;
    gap: 20px;
    transition: transform 420ms cubic-bezier(0.22, 0.9, 0.2, 1);
    will-change: transform;
    /* Allow vertical page scrolling while preventing native horizontal
       panning so the custom pointer drag can work reliably. */
    touch-action: pan-y;
    cursor: grab;
    -webkit-user-select: none;
    user-select: none;
  }

  .carousel-track.dragging {
    cursor: grabbing;
  }

  /* Limit the image height so the cards are compact and match the desayuno size */
  #menu .menu.menu-row.menu-row--drinks .carousel-track > .carta .img-menu {
    height: 200px !important;
    min-height: 200px !important;
    background-size: cover !important;
    background-position: center center !important;
  }
}

/* Rules with higher specificity to ensure .menu.menu-row lays out as a single
   horizontal row even when other rules target #menu .menu with !important. */
#menu .menu.menu-row {
  display: flex !important;
  flex-direction: row !important;
  /* allow wrap so items form rows (no horizontal scroll) */
  flex-wrap: wrap !important;
  gap: 24px !important;
}

#menu .menu.menu-row > .carta {
  /* Two-column layout on desktop: each card takes ~50% minus gap */
  flex: 0 0 calc(50% - 12px) !important;
  max-width: calc(50% - 12px) !important;
}

@media (max-width: 726px) {
  #menu .menu.menu-row > .carta {
    flex: 1 1 100% !important;
    max-width: 100% !important;
  }
}

/* Final override placed at the end to beat earlier generic rules: ensure
   carousel-track cards take an exact width so 3 cards fit per page and are
   centered by JS. These selectors intentionally include #menu to increase
   specificity and appear late in the file so they win even over earlier
   !important declarations. */
@media (min-width: 727px) {
  #menu .menu.menu-row.menu-row--drinks .carousel-track > .carta {
    flex: 0 0 calc((100% - 40px) / 3) !important;
    max-width: 420px !important; /* allow JS to shrink if needed */
    min-width: 200px !important;
  }

  /* Ensure images inside those cards are compact */
  #menu .menu.menu-row.menu-row--drinks .carousel-track > .carta .img-menu {
    height: 200px !important;
    min-height: 200px !important;
    background-size: cover !important;
  }
}

/* Override the flex-heavy selectors so the drinks carousel uses the wide
   block frame we expect, letting the absolute groups stretch the full
   carousel width without being clipped by the two-column layout rules. */
#menu .menu.menu-row.menu-row--drinks {
  display: block !important;
  width: min(960px, 100%) !important;
  max-width: min(960px, 100%) !important;
  margin: 0 auto !important;
  position: relative !important;
  flex-wrap: nowrap !important;
  justify-content: stretch !important;
  padding: 0 !important;
}

.carousel-group,
.carousel-group.active {
  width: 100% !important;
  max-width: 100% !important;
  inset: 0;
}
