/* ============================================================
   La Esquinita de Temoaya — Hoja de estilos
   Paleta: rojo fresa #c83e27 · maíz #f5a623 · crema #fbf3e4
           café #4a2c1a · verde menta #3e7c4f
   ============================================================ */

:root {
  --rojo: #c83e27;
  --rojo-oscuro: #a02e1c;
  --rojo-suave: #fbe3dc;
  --maiz: #f5a623;
  --maiz-oscuro: #d98a0d;
  --maiz-suave: #fdf0d5;
  --crema: #fbf3e4;
  --crema-oscura: #f1e3c8;
  --cafe: #4a2c1a;
  --cafe-claro: #7a5c47;
  --verde: #3e7c4f;
  --blanco: #fffdf8;
  --sombra: 0 10px 30px rgba(74, 44, 26, .12);
  --radio: 16px;
  --letra-texto: "Segoe UI", "Helvetica Neue", Arial, "Noto Sans", system-ui, sans-serif;
  --letra-titulo: Georgia, "Times New Roman", "Noto Serif", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--letra-texto);
  color: var(--cafe);
  background: var(--crema);
  line-height: 1.6;
  font-size: 1.02rem;
}

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

h1, h2, h3, h4 {
  font-family: var(--letra-titulo);
  line-height: 1.2;
  color: var(--cafe);
}

a { color: var(--rojo); }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.salto-contenido {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--cafe); color: var(--blanco); padding: .6rem 1rem;
}
.salto-contenido:focus { left: 0; }

/* ---------- Encabezado ---------- */

.encabezado {
  background: var(--blanco);
  border-bottom: 4px solid var(--rojo);
  position: sticky; top: 0; z-index: 50;
  box-shadow: 0 2px 12px rgba(74, 44, 26, .08);
}

.encabezado-interno {
  max-width: 1140px; margin: 0 auto; padding: .6rem 1.2rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}

.marca { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--cafe); }

.marca-logo { width: 54px; height: 54px; flex: 0 0 auto; }

.marca-texto strong {
  display: block; font-family: var(--letra-titulo);
  font-size: 1.02rem; line-height: 1.15; letter-spacing: .02em;
}

.marca-texto small {
  display: block; font-size: .72rem; color: var(--cafe-claro);
  letter-spacing: .04em; text-transform: uppercase; margin-top: 2px;
}

.nav-boton { display: none; }

.nav-lista {
  list-style: none; margin: 0; padding: 0;
  display: flex; gap: .25rem; flex-wrap: wrap;
}

.nav-lista a {
  display: block; padding: .55rem .9rem; border-radius: 999px;
  text-decoration: none; color: var(--cafe);
  font-weight: 600; font-size: .95rem;
  transition: background .15s, color .15s;
}

.nav-lista a:hover { background: var(--maiz-suave); color: var(--rojo-oscuro); }

.nav-lista a.activo { background: var(--rojo); color: var(--blanco); }

@media (max-width: 820px) {
  .nav-boton {
    display: block; background: none; border: 0; cursor: pointer;
    padding: .5rem; border-radius: 8px;
  }
  .nav-raya {
    display: block; width: 26px; height: 3px; background: var(--cafe);
    border-radius: 3px; margin: 5px 0; transition: transform .2s, opacity .2s;
  }
  .nav-boton[aria-expanded="true"] .nav-raya:nth-child(2) { opacity: 0; }
  .nav-boton[aria-expanded="true"] .nav-raya:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-boton[aria-expanded="true"] .nav-raya:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .nav-lista {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    background: var(--blanco); flex-direction: column; gap: 0;
    padding: .5rem 1rem 1rem; border-bottom: 4px solid var(--rojo);
    box-shadow: 0 12px 20px rgba(74, 44, 26, .12);
  }
  .nav-lista.abierto { display: flex; }
  .nav-lista a { border-radius: 8px; }
}

/* ---------- Contenedores y secciones ---------- */

.contenedor { max-width: 1140px; margin: 0 auto; padding: 0 1.2rem; }

.seccion { padding: 3.2rem 0; }

.seccion-titulo {
  font-size: 2rem; margin: 0 0 .4rem; text-align: center;
}

.seccion-sub {
  text-align: center; color: var(--cafe-claro);
  max-width: 720px; margin: 0 auto 2.2rem;
}

.etiqueta {
  display: inline-block; font-size: .78rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--rojo); background: var(--rojo-suave);
  padding: .25rem .8rem; border-radius: 999px; margin-bottom: .8rem;
}

.etiqueta.centrada { display: block; width: fit-content; margin: 0 auto .8rem; }

/* ---------- Hero (portada) ---------- */

.hero {
  position: relative;
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(245,166,35,.28), transparent 60%),
    linear-gradient(135deg, #7a1f14 0%, var(--rojo) 45%, var(--rojo-oscuro) 100%);
  color: var(--blanco);
  overflow: hidden;
}

.hero-interno {
  max-width: 1140px; margin: 0 auto; padding: 4.5rem 1.2rem 5.5rem;
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 3rem; align-items: center;
}

.hero-titulo {
  font-size: clamp(2.2rem, 5vw, 3.4rem); color: var(--blanco); margin: .4rem 0 1rem;
}

.hero-titulo em {
  font-style: italic; color: var(--maiz);
}

.hero p.hero-intro {
  font-size: 1.12rem; max-width: 46ch; margin: 0 0 1.6rem;
  color: rgba(255, 253, 248, .92);
}

.hero-meta {
  display: flex; flex-wrap: wrap; gap: 1.4rem; margin-bottom: 2rem;
  font-size: .92rem;
}

.hero-meta span { display: flex; align-items: center; gap: .45rem; }
.hero-meta svg { width: 18px; height: 18px; fill: var(--maiz); flex: 0 0 auto; }

.botones { display: flex; flex-wrap: wrap; gap: .8rem; }

.btn {
  display: inline-block; padding: .85rem 1.6rem; border-radius: 999px;
  font-weight: 700; text-decoration: none; font-size: 1rem;
  border: 2px solid transparent; cursor: pointer; transition: transform .12s, box-shadow .12s, background .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn:focus-visible { outline: 3px solid var(--maiz); outline-offset: 2px; }

.btn-maiz { background: var(--maiz); color: var(--cafe); box-shadow: 0 6px 18px rgba(245,166,35,.45); }
.btn-maiz:hover { background: #ffb63d; }

.btn-linea { border-color: rgba(255,253,248,.65); color: var(--blanco); }
.btn-linea:hover { background: rgba(255,253,248,.12); }

.hero-foto {
  position: relative;
}

.hero-foto img {
  border-radius: 50% 50% var(--radio) var(--radio) / 40% 40% var(--radio) var(--radio);
  box-shadow: 0 24px 60px rgba(58, 12, 6, .45);
  border: 6px solid rgba(255,253,248,.25);
  aspect-ratio: 4 / 5; object-fit: cover;
}

.chaparra {
  position: absolute; top: -18px; right: 8px;
  background: var(--maiz); color: var(--cafe);
  font-weight: 800; font-size: .85rem;
  padding: .5rem 1rem; border-radius: 999px;
  box-shadow: var(--sombra); transform: rotate(4deg);
}

.chaparra span { display: block; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }

.cinta-decorativa {
  height: 14px; margin: 0; border: 0;
  background: repeating-linear-gradient(-45deg,
    var(--maiz) 0 14px, var(--blanco) 14px 28px,
    var(--verde) 28px 42px, var(--blanco) 42px 56px);
}

/* ---------- Franja de datos ---------- */

.franja-datos { background: var(--cafe); color: var(--crema); }

.franja-datos .contenedor {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; padding-top: 1.6rem; padding-bottom: 1.6rem;
  text-align: center;
}

.franja-datos strong { display: block; font-family: var(--letra-titulo); font-size: 1.5rem; color: var(--maiz); }
.franja-datos small { display: block; font-size: .85rem; letter-spacing: .04em; }

@media (max-width: 760px) {
  .franja-datos .contenedor { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Tarjetas de producto ---------- */

.productos-cuadricula {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr));
  gap: 1.5rem;
}

.tarjeta-producto {
  background: var(--blanco); border-radius: var(--radio);
  box-shadow: var(--sombra); overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .15s, box-shadow .15s;
  border: 1px solid var(--crema-oscura);
}

.tarjeta-producto:hover { transform: translateY(-5px); box-shadow: 0 18px 40px rgba(74,44,26,.18); }

.tarjeta-foto { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }

.tarjeta-foto img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s;
}

.tarjeta-producto:hover .tarjeta-foto img { transform: scale(1.06); }

.tarjeta-precio {
  position: absolute; right: 12px; bottom: 12px;
  background: var(--rojo); color: var(--blanco);
  font-weight: 800; padding: .3rem .8rem; border-radius: 999px;
  font-size: .9rem; box-shadow: 0 4px 12px rgba(160, 46, 28, .5);
}

.tarjeta-cuerpo { padding: 1.1rem 1.2rem 1.3rem; display: flex; flex-direction: column; flex: 1; }

.tarjeta-cuerpo h3 { margin: 0 0 .35rem; font-size: 1.18rem; }

.tarjeta-cuerpo p { margin: 0; font-size: .92rem; color: var(--cafe-claro); flex: 1; }

.tarjeta-pie { margin-top: .9rem; display: flex; align-items: center; gap: .6rem; font-size: .88rem; font-weight: 600; color: var(--verde); }

/* ---------- Fichas / características ---------- */

.fichas {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.4rem; margin-top: 1rem;
}

.ficha {
  background: var(--blanco); border-radius: var(--radio);
  padding: 1.6rem; border-top: 5px solid var(--maiz);
  box-shadow: var(--sombra);
}

.ficha svg { width: 40px; height: 40px; fill: var(--rojo); }

.ficha h3 { margin: .8rem 0 .4rem; font-size: 1.1rem; }

.ficha p { margin: 0; font-size: .93rem; color: var(--cafe-claro); }

/* ---------- Cita / testimonio ---------- */

.cita-bandera { background: var(--maiz-suave); border-radius: var(--radio); padding: 2rem; margin-top: 2rem; }

.cita-bandera blockquote { margin: 0; font-family: var(--letra-titulo); font-size: 1.25rem; font-style: italic; }

.cita-bandera figcaption { margin-top: .8rem; font-weight: 700; font-size: .95rem; color: var(--rojo-oscuro); }

/* ---------- Tabla de precios ---------- */

.menu-grupo { margin-bottom: 2.6rem; }

.menu-grupo h2 {
  display: flex; align-items: center; gap: .8rem; font-size: 1.5rem;
  padding-bottom: .5rem; border-bottom: 3px solid var(--maiz);
}

.menu-grupo h2 svg { width: 30px; height: 30px; fill: var(--rojo); flex: 0 0 auto; }

.tabla-precios { width: 100%; border-collapse: collapse; }

.tabla-precios td, .tabla-precios th { padding: .85rem .6rem; text-align: left; border-bottom: 1px dashed var(--crema-oscura); vertical-align: top; }

.tabla-precios td:last-child { text-align: right; font-weight: 800; color: var(--rojo); white-space: nowrap; }

.tabla-precios strong { display: block; }

.tabla-precios small { color: var(--cafe-claro); font-weight: 400; font-size: .85rem; }

.nota-menu { font-size: .88rem; color: var(--cafe-claro); background: var(--blanco); border-radius: var(--radio); padding: 1rem 1.2rem; border-left: 5px solid var(--verde); }

/* ---------- Nosotros ---------- */

.dos-columnas {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2.6rem; align-items: center;
}

.dos-columnas img { border-radius: var(--radio); box-shadow: var(--sombra); aspect-ratio: 4/3; object-fit: cover; }

@media (max-width: 820px) { .dos-columnas { grid-template-columns: 1fr; } }

.lista-local { padding-left: 0; list-style: none; }

.lista-local li {
  position: relative; padding: .6rem 0 .6rem 2rem;
  border-bottom: 1px dashed var(--crema-oscura);
}

.lista-local li::before {
  content: ""; position: absolute; left: 0; top: .95rem;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--rojo);
  box-shadow: inset 0 -3px 0 rgba(0,0,0,.18), 0 0 0 4px var(--rojo-suave);
}

/* ---------- Mapa interactivo ---------- */

.mapa-marco {
  background: var(--blanco); border-radius: var(--radio);
  box-shadow: var(--sombra); overflow: hidden;
  border: 1px solid var(--crema-oscura);
}

.mapa-cabecera {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem 1.4rem; background: var(--cafe); color: var(--crema);
}

.mapa-cabecera h3 { margin: 0; color: var(--maiz); font-size: 1.15rem; }
.mapa-cabecera p { margin: 0; font-size: .85rem; color: rgba(255,253,248,.8); }

.mapa-controles { display: flex; gap: .4rem; }

.mapa-controles button {
  width: 38px; height: 38px; border-radius: 10px; border: 0;
  background: var(--maiz); color: var(--cafe); font-size: 1.15rem; font-weight: 800;
  cursor: pointer; transition: background .15s;
}
.mapa-controles button:hover { background: #ffb63d; }

.mapa-lienzo { position: relative; }

.mapa-lienzo svg { display: block; width: 100%; height: auto; touch-action: none; }

.mapa-zona { cursor: pointer; transition: fill-opacity .15s; }
.mapa-zona:hover { fill-opacity: .55; }

.mapa-marcador { cursor: pointer; transform-origin: center; transform-box: fill-box; }
.mapa-marcador:hover .mapa-punto { fill: var(--rojo); }

.mapa-anillo { animation: mapa-pulso 2.2s ease-out infinite; transform-origin: center; transform-box: fill-box; }

@keyframes mapa-pulso {
  0%   { opacity: .8; transform: scale(.5); }
  100% { opacity: 0; transform: scale(2.4); }
}

.mapa-ficha {
  position: absolute; left: 14px; bottom: 14px; max-width: 330px;
  background: var(--blanco); border-radius: 14px; box-shadow: var(--sombra);
  padding: 1rem 1.2rem; border-left: 5px solid var(--rojo);
  font-size: .9rem;
}

.mapa-ficha h4 { margin: 0 0 .3rem; font-size: 1.02rem; }
.mapa-ficha p { margin: .2rem 0; color: var(--cafe-claro); }
.mapa-ficha .mapa-ruta { margin-top: .4rem; font-weight: 700; color: var(--verde); }

.mapa-leyenda { display: flex; flex-wrap: wrap; gap: 1rem; padding: .9rem 1.4rem; background: var(--maiz-suave); font-size: .85rem; }
.mapa-leyenda span { display: flex; align-items: center; gap: .45rem; }
.mapa-leyenda i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; flex: 0 0 auto; }

@media (max-width: 720px) { .mapa-ficha { position: static; border-radius: 0; border-left: 0; border-top: 5px solid var(--rojo); } }

/* ---------- Contacto ---------- */

.contacto-cuadricula {
  display: grid; grid-template-columns: 1fr 1.1fr; gap: 2.2rem; align-items: start;
}

@media (max-width: 860px) { .contacto-cuadricula { grid-template-columns: 1fr; } }

.formulario {
  background: var(--blanco); border-radius: var(--radio);
  padding: 1.8rem; box-shadow: var(--sombra);
}

.formulario label { display: block; font-weight: 700; font-size: .92rem; margin-bottom: .3rem; }

.formulario input, .formulario textarea, .formulario select {
  width: 100%; padding: .75rem .9rem; margin-bottom: 1.1rem;
  border: 2px solid var(--crema-oscura); border-radius: 10px;
  font: inherit; color: var(--cafe); background: var(--crema);
  transition: border-color .15s;
}

.formulario input:focus, .formulario textarea:focus {
  outline: none; border-color: var(--rojo); background: var(--blanco);
}

.formulario .error { border-color: var(--rojo); background: #fdeeec; }

.formulario .mensaje-error { color: var(--rojo); font-size: .85rem; font-weight: 700; margin: -.5rem 0 1rem; display: block; }

.campo-trampa { position: absolute; left: -9999px; opacity: 0; height: 0; }

.alerta {
  border-radius: 12px; padding: 1rem 1.2rem; margin-bottom: 1.2rem; font-weight: 600;
}

.alerta-exito { background: #e4f2e7; color: #2a5c38; border: 1px solid #bcdcc5; }
.alerta-error { background: #fdeeec; color: var(--rojo-oscuro); border: 1px solid #f5c6bc; }

.datos-contacto { display: grid; gap: 1rem; }

.dato-contacto {
  display: flex; gap: .9rem; align-items: flex-start;
  background: var(--blanco); border-radius: 14px; padding: 1.1rem 1.2rem;
  box-shadow: var(--sombra);
}

.dato-contacto svg { width: 34px; height: 34px; fill: var(--rojo); flex: 0 0 auto; margin-top: 2px; }

.dato-contacto h3 { margin: 0 0 .2rem; font-size: 1rem; }

.dato-contacto p { margin: 0; font-size: .93rem; color: var(--cafe-claro); }

.dato-contacto a { font-weight: 700; }

/* ---------- Páginas legales ---------- */

.legal { max-width: 840px; margin: 0 auto; }

.legal h2 { font-size: 1.4rem; margin: 2rem 0 .6rem; color: var(--rojo-oscuro); }

.legal h3 { font-size: 1.1rem; margin: 1.4rem 0 .4rem; }

.legal p, .legal li { color: var(--cafe-claro); }

.legal ul { padding-left: 1.3rem; }

.legal .actualizacion {
  font-size: .85rem; color: var(--cafe-claro); font-style: italic;
  background: var(--maiz-suave); border-radius: 10px; padding: .6rem 1rem;
}

.legal .definicion { background: var(--blanco); border-left: 5px solid var(--maiz); border-radius: 10px; padding: 1rem 1.2rem; margin: 1.2rem 0; }

/* ---------- Encabezado interior de página ---------- */

.pagina-titulo {
  background: linear-gradient(135deg, #7a1f14, var(--rojo-oscuro));
  color: var(--blanco); padding: 3rem 0 2.6rem; text-align: center;
}

.pagina-titulo h1 { color: var(--blanco); font-size: 2.4rem; margin: 0 0 .3rem; }

.pagina-titulo p { margin: 0; color: rgba(255,253,248,.88); max-width: 640px; margin-left: auto; margin-right: auto; }

.migas {
  font-size: .85rem; margin-bottom: 1.4rem; color: var(--cafe-claro);
}

.migas a { color: var(--cafe-claro); text-decoration: none; }
.migas a:hover { color: var(--rojo); text-decoration: underline; }

/* ---------- Pie ---------- */

.pie { background: var(--cafe); color: var(--crema); margin-top: 3rem; }

.pie-interno { max-width: 1140px; margin: 0 auto; padding: 2.6rem 1.2rem 1.6rem; }

.pie-cols { display: grid; grid-template-columns: 1.3fr 1.1fr 1fr; gap: 2rem; }

@media (max-width: 820px) { .pie-cols { grid-template-columns: 1fr; gap: 1.6rem; } }

.pie-marca { font-family: var(--letra-titulo); font-size: 1.15rem; color: var(--maiz); margin: 0 0 .5rem; }

.pie p { color: rgba(255,253,248,.78); }

.pie-titulo {
  font-weight: 800; text-transform: uppercase; letter-spacing: .1em;
  font-size: .82rem; color: var(--maiz); margin: 0 0 .7rem;
}

.pie address { font-style: normal; color: rgba(255,253,248,.78); margin-bottom: .6rem; }

.pie a { color: var(--maiz); }

.pie-enlaces { list-style: none; padding: 0; margin: 0; }

.pie-enlaces li { margin-bottom: .45rem; }

.pie-enlaces a { text-decoration: none; color: rgba(255,253,248,.85); }
.pie-enlaces a:hover { color: var(--maiz); text-decoration: underline; }

.pie-legal {
  margin-top: 2rem; padding-top: 1.2rem;
  border-top: 1px solid rgba(255,253,248,.15);
  display: flex; flex-wrap: wrap; gap: .6rem; justify-content: space-between;
  font-size: .82rem;
}

.pie-legal p { margin: 0; }
.pie-creditos { color: rgba(255,253,248,.55) !important; }
