/* ==========================================================================
   cóctel.com — Hoja de estilos 2026 (diseño nuevo, sin frameworks)
   ========================================================================== */

@font-face {
  font-family: "Oswald";
  src: url("Oswald.woff") format("woff"), url("Oswald.ttf") format("truetype");
  font-display: swap;
}

:root {
  --ink: #1b1420;
  --ink-2: #2a2030;
  --paper: #fbf6ef;
  --paper-2: #f3eadd;
  --card: #ffffff;
  --text: #2b2430;
  --muted: #6b6070;
  --line: #e6dccd;
  --coral: #d9472b;
  --coral-dark: #b33620;
  --amber: #f29b2c;
  --lime: #7aa82b;
  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(27, 20, 32, .25);
  --max: 1180px;
  --display: "Oswald", "Arial Narrow", Impact, sans-serif;
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--paper);
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--coral-dark); text-underline-offset: 3px; }
a:hover { color: var(--coral); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: .01em;
  color: var(--ink);
  margin: 0 0 .6em;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin-top: 2.2rem; }
h3 { font-size: 1.3rem; margin-top: 1.6rem; }
p { margin: 0 0 1.1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .container { padding: 0 28px; } }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--amber); color: var(--ink); padding: 10px 16px; border-radius: 8px;
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Cabecera ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  /* Sin backdrop-filter: crearia un bloque contenedor y el menu movil (position: fixed) quedaria atrapado en la cabecera */
  background: rgba(27, 20, 32, .985);
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.header-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand:hover { color: #fff; }
.brand img { width: 36px; height: 36px; border-radius: 50%; }
.brand span { font-family: var(--display); font-size: 1.5rem; letter-spacing: .02em; }
.brand b { color: var(--amber); font-weight: 500; }
.header-links { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; }
.header-links a {
  color: #e9e1ea; text-decoration: none; font-size: .92rem; padding: 6px 12px; border-radius: 999px;
}
.header-links a:hover, .header-links a[aria-current="page"] { background: rgba(255,255,255,.1); color: #fff; }
@media (max-width: 640px) { .header-links .opt { display: none; } }

/* ---------- Barra de categorías (pastillas desplazables) ---------- */
.cocktail-nav { border-top: 1px solid rgba(255,255,255,.07); background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,0)); }
.pills { position: relative; }
.pills-track {
  position: relative; display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 9px 2px;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; scroll-behavior: smooth; overscroll-behavior-x: contain;
  --fade-l: 0px; --fade-r: 0px;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--fade-l), #000 calc(100% - var(--fade-r)), transparent 100%);
          mask-image: linear-gradient(to right, transparent 0, #000 var(--fade-l), #000 calc(100% - var(--fade-r)), transparent 100%);
}
.pills.can-prev .pills-track { --fade-l: 56px; }
.pills.can-next .pills-track { --fade-r: 56px; }
.pills-track::-webkit-scrollbar { display: none; }
.pills-track li { flex: none; }
.pills-track a {
  display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; text-decoration: none;
  color: #efe6ee; font-size: .86rem; line-height: 1; padding: 7px 13px 7px 10px; border-radius: 999px;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.1);
  transition: background-color .25s, border-color .25s, color .25s, transform .3s var(--ease-out);
}
.pills-track .ico { width: 16px; height: 16px; color: var(--amber); transition: transform .4s var(--ease-out), color .25s; }
.pills-track a:hover { background: rgba(242,155,44,.12); border-color: rgba(242,155,44,.55); color: #fff; transform: translateY(-1px); }
.pills-track a:hover .ico { transform: rotate(-12deg) scale(1.12); }
.pills-track a[aria-current="page"] { background: var(--amber); border-color: var(--amber); color: var(--ink); font-weight: 600; box-shadow: 0 6px 16px -8px rgba(242,155,44,.9); }
.pills-track a[aria-current="page"] .ico { color: var(--ink); }
.pills-sep { width: 1px; height: 20px; margin: 0 6px; background: rgba(255,255,255,.16); }

.pills-arrow {
  position: absolute; top: 50%; z-index: 1; display: grid; place-items: center;
  width: 32px; height: 32px; margin-top: -16px; padding: 0; border-radius: 50%; cursor: pointer;
  color: #fff; background: var(--ink-2); border: 1px solid rgba(255,255,255,.18);
  box-shadow: 0 4px 14px -4px rgba(0,0,0,.6);
  opacity: 0; visibility: hidden; transform: scale(.8);
  transition: opacity .25s, transform .3s var(--ease-out), visibility 0s .3s, background-color .2s, border-color .2s;
}
.pills-arrow .ico { width: 16px; height: 16px; }
.pills-prev { left: 8px; }
.pills-prev .ico { transform: rotate(180deg); }
.pills-next { right: 8px; }
.pills-arrow:hover { background: var(--amber); border-color: var(--amber); color: var(--ink); }
.pills.can-prev .pills-prev, .pills.can-next .pills-next { opacity: 1; visibility: visible; transform: none; transition: opacity .25s, transform .3s var(--ease-out), background-color .2s, border-color .2s; }
@media (min-width: 720px) { .pills-prev { left: 20px; } .pills-next { right: 20px; } }
@media (hover: none) { .pills-arrow { display: none; } }

/* ---------- Menú principal con submenús ---------- */
:root { --ease-out: cubic-bezier(.22, 1, .36, 1); --header-h: 64px; }
.ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.mainnav-list { list-style: none; margin: 0; padding: 0; }
.mn-link {
  display: flex; align-items: center; gap: 8px; position: relative;
  font: inherit; font-size: .93rem; color: #e9e1ea; text-decoration: none;
  background: none; border: 0; cursor: pointer; border-radius: 999px;
  transition: color .25s, background-color .25s;
}
.mn-link > .ico:first-child { color: var(--amber); transition: transform .45s var(--ease-out); }
.mn-link .chev { width: 15px; height: 15px; opacity: .7; transition: transform .35s var(--ease-out), opacity .25s; }
.mn-link[aria-expanded="true"] .chev { transform: rotate(180deg); opacity: 1; }
.mn-link:hover > .ico:first-child, .mn-link[aria-expanded="true"] > .ico:first-child { transform: translateY(-1px) rotate(-10deg) scale(1.08); }

.mn-title {
  display: flex; align-items: center; gap: 10px; margin: 0 0 12px;
  font-family: var(--display); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.mn-title::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--coral); }

/* Recetas: lista en columnas */
.mn-recipes { list-style: none; margin: 0; padding: 0; columns: 4 170px; column-gap: 14px; }
.mn-recipes li { break-inside: avoid; }
.mn-recipes a {
  display: flex; align-items: center; gap: 8px; padding: 5px 9px; border-radius: 9px;
  color: var(--ink); text-decoration: none; font-size: .92rem; line-height: 1.35;
  transition: background-color .2s, color .2s, transform .25s var(--ease-out);
}
.mn-recipes .ico { width: 16px; height: 16px; color: var(--muted); transition: color .2s, transform .35s var(--ease-out); }
.mn-recipes a:hover { background: var(--paper-2); color: var(--coral-dark); transform: translateX(3px); }
.mn-recipes a:hover .ico { color: var(--coral); transform: rotate(-14deg); }
.mn-tag { margin-left: auto; font-size: .68rem; font-weight: 600; letter-spacing: .02em; color: #4b6b14; background: #e9f3d6; padding: 1px 7px; border-radius: 999px; white-space: nowrap; }

/* Tarjetas con icono (tipos, aprende, descubre) */
.mn-tiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.mn-tiles--cards { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 8px; }
.mn-tiles a {
  display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px;
  color: var(--ink); text-decoration: none; line-height: 1.3;
  transition: background-color .25s, box-shadow .25s, transform .3s var(--ease-out);
}
.mn-ic {
  display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 11px;
  background: var(--paper-2); color: var(--coral-dark);
  transition: background-color .25s, color .25s, transform .4s var(--ease-out);
}
.mn-ic .ico { transition: transform .45s var(--ease-out); }
.mn-txt strong { display: block; font-weight: 600; font-size: .95rem; }
.mn-txt small { display: block; font-size: .8rem; color: var(--muted); margin-top: 1px; }
.mn-tiles a:hover { background: var(--card); box-shadow: 0 8px 22px -14px rgba(27, 20, 32, .45); transform: translateY(-2px); }
.mn-tiles a:hover .mn-ic { background: var(--amber); color: var(--ink); }
.mn-tiles a:hover .mn-ic .ico { transform: rotate(-12deg) scale(1.12); }
.mn-recipes a[aria-current="page"], .mn-tiles a[aria-current="page"] { background: var(--ink); color: #fff; }
.mn-recipes a[aria-current="page"] .ico { color: var(--amber); }
.mn-tiles a[aria-current="page"] .mn-ic { background: var(--amber); color: var(--ink); }
.mn-tiles a[aria-current="page"] small { color: #cfc3cf; }

/* Tarjeta destacada del submenú de recetas */
.mn-promo {
  position: relative; overflow: hidden; border-radius: var(--radius); padding: 24px 22px;
  color: #efe6ef; background: radial-gradient(120% 90% at 100% 0%, #4a2a3a 0%, transparent 60%), linear-gradient(160deg, var(--ink-2), var(--ink));
}
.mn-promo::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 140px; height: 140px; border-radius: 50%; border: 18px solid rgba(242, 155, 44, .12); }
.mn-promo-ic { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: rgba(242, 155, 44, .16); color: var(--amber); }
.mn-promo-ic .ico { width: 26px; height: 26px; }
.mn-promo-num { font-family: var(--display); font-size: 3rem; line-height: 1; color: var(--amber); margin: 16px 0 6px; }
.mn-promo p:not(.mn-promo-num) { font-size: .92rem; line-height: 1.5; margin: 0 0 18px; }
.mn-cta {
  position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px;
  background: var(--amber); color: var(--ink); font-weight: 600; font-size: .9rem; text-decoration: none;
  transition: background-color .2s, box-shadow .25s;
}
.mn-cta .ico { width: 17px; height: 17px; transition: transform .35s var(--ease-out); }
.mn-cta:hover { background: #ffb24d; color: var(--ink); box-shadow: 0 8px 20px -8px rgba(242, 155, 44, .8); }
.mn-cta:hover .ico { transform: translateX(4px); }

/* Entrada escalonada de los elementos al abrir un submenú */
.mn-panel li { opacity: 0; transform: translateY(8px); transition: opacity .3s, transform .45s var(--ease-out); }
.mn-item.is-open .mn-panel li { opacity: 1; transform: none; transition-delay: calc(min(var(--i, 0), 26) * 14ms + 50ms); }
html:not(.js) .mn-panel li { opacity: 1; transform: none; }

.nav-backdrop { position: fixed; inset: var(--header-h) 0 0 0; z-index: 1; background: rgba(16, 10, 20, .45); opacity: 0; visibility: hidden; transition: opacity .3s, visibility 0s .3s; }
.site-header.panel-open .nav-backdrop, .site-header.nav-open .nav-backdrop { opacity: 1; visibility: visible; transition: opacity .3s; }
body.nav-locked { overflow: hidden; }

/* ----- Escritorio ----- */
@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .mainnav-list { display: flex; gap: 2px; }
  .mn-link { padding: 8px 13px; }
  .mn-link::after {
    content: ""; position: absolute; left: 14px; right: 14px; bottom: 2px; height: 2px; border-radius: 2px;
    background: var(--amber); transform: scaleX(0); transition: transform .35s var(--ease-out);
  }
  .mn-link:hover, .mn-link[aria-expanded="true"] { color: #fff; background: rgba(255, 255, 255, .07); }
  .mn-link:hover::after, .mn-link[aria-expanded="true"]::after, .mn-link.is-current::after, .mn-link[aria-current="page"]::after { transform: scaleX(1); }
  .mn-link.is-current, .mn-link[aria-current="page"] { color: #fff; }

  .mn-panel {
    position: absolute; left: 0; right: 0; top: var(--header-h); z-index: 2;
    background: var(--paper); border-top: 3px solid var(--amber);
    box-shadow: 0 40px 70px -30px rgba(16, 10, 20, .6);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto; overscroll-behavior: contain;
    opacity: 0; visibility: hidden; transform: translateY(-10px); pointer-events: none;
    transition: opacity .22s, transform .35s var(--ease-out), visibility 0s .35s;
  }
  .mn-item.is-open > .mn-panel { opacity: 1; visibility: visible; transform: none; pointer-events: auto; transition: opacity .25s, transform .4s var(--ease-out); }
  .site-header.mn-switch .mn-panel { transition: none; }
  html:not(.js) .mn-item:hover > .mn-panel, html:not(.js) .mn-item:focus-within > .mn-panel { opacity: 1; visibility: visible; transform: none; pointer-events: auto; }
  .mn-panel-inner { max-width: var(--max); margin: 0 auto; padding: 28px 28px 32px; }
  .mn-grid { display: grid; gap: 36px; }
  .mn-grid--recetas { grid-template-columns: minmax(0, 1fr) 270px; }
  .mn-grid--tipos { grid-template-columns: repeat(3, 1fr); }
}

/* ----- Móvil y tableta: panel lateral ----- */
@media (max-width: 959px) {
  .nav-toggle {
    display: inline-flex; align-items: center; gap: 10px; padding: 9px 14px 9px 12px; border-radius: 999px;
    font: inherit; font-size: .9rem; color: #fff; cursor: pointer;
    background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14);
    transition: background-color .25s, border-color .25s;
  }
  .nav-toggle:hover, .nav-toggle[aria-expanded="true"] { background: rgba(242, 155, 44, .14); border-color: rgba(242, 155, 44, .5); }
  .burger { position: relative; width: 20px; height: 14px; }
  .burger span { position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px; background: currentColor; transition: transform .4s var(--ease-out), opacity .2s, top .4s var(--ease-out); }
  .burger span:nth-child(1) { top: 0; }
  .burger span:nth-child(2) { top: 6px; }
  .burger span:nth-child(3) { top: 12px; }
  .nav-toggle[aria-expanded="true"] .burger span:nth-child(1) { top: 6px; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .burger span:nth-child(2) { opacity: 0; transform: scaleX(.2); }
  .nav-toggle[aria-expanded="true"] .burger span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

  .mainnav {
    position: fixed; top: var(--header-h); right: 0; bottom: 0; width: min(420px, 100%); z-index: 2;
    background: var(--ink); border-left: 1px solid rgba(255, 255, 255, .08);
    overflow-y: auto; overscroll-behavior: contain;
    transform: translateX(100%); visibility: hidden;
    transition: transform .45s var(--ease-out), visibility 0s .45s;
  }
  .site-header.nav-open .mainnav { transform: none; visibility: visible; transition: transform .45s var(--ease-out); }
  .mainnav-list { padding: 10px 18px 40px; }
  .mn-item { border-bottom: 1px solid rgba(255, 255, 255, .08); opacity: 0; transform: translateX(24px); transition: opacity .3s, transform .45s var(--ease-out); }
  .site-header.nav-open .mn-item { opacity: 1; transform: none; transition-delay: calc(var(--n, 0) * 55ms + 120ms); }
  .mn-link { width: 100%; padding: 15px 4px; font-size: 1.05rem; color: #fff; border-radius: 0; }
  .mn-link .chev { margin-left: auto; }
  .mn-link.is-current > span, .mn-link[aria-current="page"] > span { color: var(--amber); }

  .mn-panel { display: grid; grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows .4s var(--ease-out), visibility 0s .4s; }
  .mn-item.is-open > .mn-panel { grid-template-rows: 1fr; visibility: visible; transition: grid-template-rows .4s var(--ease-out); }
  .mn-panel-inner { overflow: hidden; min-height: 0; }
  .mn-panel-inner > * { padding-bottom: 18px; }
  .mn-grid { display: grid; gap: 18px; }
  .mn-title { color: #a596a8; margin-bottom: 8px; }
  .mn-recipes { columns: 2 140px; }
  .mn-recipes a, .mn-tiles a { color: #ece4ec; }
  .mn-recipes .ico { color: #a596a8; }
  .mn-recipes a:hover, .mn-tiles a:hover { background: rgba(255, 255, 255, .06); color: #fff; box-shadow: none; }
  .mn-tag { color: #cfe7a6; background: rgba(122, 168, 43, .22); }
  .mn-ic { width: 36px; height: 36px; background: rgba(255, 255, 255, .07); color: var(--amber); }
  .mn-txt small { color: #a596a8; }
  .mn-tiles--cards { grid-template-columns: 1fr; gap: 2px; }
  .mn-promo { padding: 16px 18px; display: grid; grid-template-columns: auto 1fr; gap: 0 14px; align-items: center; background: rgba(255, 255, 255, .05); }
  .mn-promo::after { display: none; }
  .mn-promo-num { font-size: 2rem; margin: 0; }
  .mn-promo p:not(.mn-promo-num) { grid-column: 1 / -1; margin: 10px 0 12px; }
  .mn-promo .mn-cta { grid-column: 1 / -1; justify-self: start; }
  .mn-promo-ic { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .mn-panel li, .mn-item { opacity: 1 !important; transform: none !important; }
}

/* ---------- Hero portada ---------- */
.hero {
  position: relative; color: #fff; isolation: isolate;
  min-height: clamp(420px, 62vh, 640px);
  display: flex; align-items: flex-end;
  background: var(--ink) url("../img/cabeceras/cocteles.webp") center 60% / cover no-repeat;
}
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(27,20,32,0) 65%, rgba(27,20,32,.25) 100%);
}

/* Recuadro translúcido para el texto sobre fotos: la foto se ve clara y el texto se lee */
.hero-card {
  max-width: 620px;
  background: rgba(27,20,32,.6);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 20px;
  padding: clamp(20px, 3vw, 32px) clamp(20px, 3vw, 36px);
  box-shadow: 0 20px 50px -20px rgba(0,0,0,.5);
}
.hero-card > :last-child { margin-bottom: 0; }
.hero .container { padding-bottom: clamp(32px, 6vw, 64px); }
.hero h1 { color: #fff; max-width: 15ch; margin-bottom: .35em; text-shadow: 0 2px 20px rgba(0,0,0,.35); }
.hero p { max-width: 58ch; font-size: 1.15rem; color: #f3ebe2; }
.eyebrow {
  display: inline-block; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--amber); font-weight: 700; margin-bottom: .8rem;
}
.btn {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
  background: var(--coral); color: #fff; padding: 12px 22px; border-radius: 999px; font-weight: 600;
  border: 2px solid var(--coral);
}
.btn:hover { background: var(--coral-dark); border-color: var(--coral-dark); color: #fff; }
.btn.ghost { background: transparent; border-color: rgba(255,255,255,.6); }
.btn.ghost:hover { background: rgba(255,255,255,.12); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

/* ---------- Cabecera de página interior ---------- */
.page-hero { background: var(--ink); color: #fff; padding: clamp(36px, 6vw, 64px) 0; }
.page-hero h1 { color: #fff; margin-bottom: .3em; }
.page-hero p { color: #e2d8df; max-width: 65ch; margin: 0; }

.breadcrumb { font-size: .88rem; margin-bottom: 14px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.breadcrumb li + li::before { content: "›"; margin-right: 6px; color: #9b8f9c; }
.breadcrumb a { color: #e9e1ea; }
.breadcrumb [aria-current] { color: var(--amber); }

/* Borde inferior curvo en todas las cabeceras.
   La máscara deja la cabecera entera salvo una franja final de alto --curva,
   donde una elipse ancha recorta los extremos: centro intacto, esquinas ~45% de --curva más arriba. */
.hero, .recipe-hero, .page-hero {
  --curva: clamp(40px, 7vw, 100px);
  --curva-mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--curva) + 1px) no-repeat,
    radial-gradient(60% 100% at 50% 0, #000 98%, transparent 100%) bottom / 100% var(--curva) no-repeat;
  -webkit-mask: var(--curva-mask);
  mask: var(--curva-mask);
}
/* Espacio extra bajo el texto para que la curva no se acerque al contenido */
.hero > .container, .recipe-hero > .container, .page-hero > .container { margin-bottom: calc(var(--curva) * .45); }
.hero > .ai-label, .page-hero > .ai-label { bottom: calc(14px + var(--curva) * .5); }
@media (min-width: 860px) {
  .recipe-hero > .ai-label { bottom: calc(14px + var(--curva) * .5); }
}
@media print {
  .hero, .recipe-hero, .page-hero { -webkit-mask: none; mask: none; }
}

/* Distintivo para imágenes generadas con IA */
.hero, .recipe-hero, .page-hero { position: relative; }
.ai-label {
  position: absolute; right: 16px; bottom: 14px; z-index: 2;
  background: rgba(27,20,32,.75); color: #fff;
  font-size: .75rem; font-weight: 600; letter-spacing: .04em; line-height: 1.2;
  padding: 5px 11px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.3);
  backdrop-filter: blur(4px);
  pointer-events: none;
}
@media (max-width: 859px) {
  .recipe-hero .ai-label { top: 10px; bottom: auto; right: 10px; }
}
/* Versión pequeña sobre fotos del contenido, tarjetas y menús */
figure, .menus article { position: relative; }
.ai-label--img {
  top: 10px; right: 10px; bottom: auto;
  font-size: .68rem; padding: 3px 9px;
}
.figure.right .ai-label--img, .figure.left .ai-label--img { top: 8px; right: 8px; }
.figure.right img, .figure.left img { width: 100%; }
/* La figura se ajusta a la foto para que el distintivo quede encima de la imagen */
.figure:not(.right):not(.left):not(.in-panel) { width: fit-content; max-width: 100%; margin-inline: auto; }

/* ---------- Ficha de receta ---------- */
/* Cabecera grande: la foto se ve entera; el degradado solo oscurece la zona del texto */
.recipe-hero {
  color: #fff;
  display: flex; align-items: flex-end;
  min-height: clamp(480px, 43vw, 780px);
  padding: 48px 0 clamp(32px, 4vw, 56px);
  background:
    var(--hero, none) center / cover no-repeat,
    var(--ink);
}
.recipe-hero .grid { display: block; }
.recipe-hero .grid > div { max-width: 600px; }
@media (min-width: 860px) {
  .recipe-hero .grid > div {
    background: rgba(27,20,32,.6);
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 20px;
    padding: 28px 34px;
    box-shadow: 0 20px 50px -20px rgba(0,0,0,.5);
  }
}
.recipe-hero h1 { color: #fff; text-shadow: 0 2px 18px rgba(0,0,0,.45); }
.recipe-hero .lead { color: #f3ebf2; font-size: 1.12rem; text-shadow: 0 1px 10px rgba(0,0,0,.5); }
.recipe-hero .meta li { background: rgba(27,20,32,.55); backdrop-filter: blur(4px); }
@media (max-width: 859px) {
  .recipe-hero {
    display: block; min-height: 0;
    padding-top: 38vw;
    background:
      linear-gradient(180deg, rgba(27,20,32,0) 0, rgba(27,20,32,0) 28vw, rgba(27,20,32,1) 43vw),
      var(--hero, none) center top / 100% auto no-repeat,
      var(--ink);
  }
}

.meta { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 22px 0 0; }
.meta li {
  display: flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px; padding: 7px 14px; font-size: .9rem; color: #fff;
}
.meta svg { width: 18px; height: 18px; flex: none; color: var(--amber); }

.layout { display: grid; gap: 40px; padding: clamp(32px, 5vw, 56px) 0; }
@media (min-width: 980px) { .layout { grid-template-columns: minmax(0, 1fr) 300px; } }
.content > :first-child { margin-top: 0; }

.ingredients-steps { display: grid; gap: 24px; margin-bottom: 8px; }
@media (min-width: 760px) and (max-width: 979px), (min-width: 1200px) { .ingredients-steps { grid-template-columns: 1fr 1.4fr; } }
.panel {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow);
}
.panel h2 { margin-top: 0; font-size: 1.45rem; }
.panel.tint { background: var(--paper-2); box-shadow: none; }

.check-list { list-style: none; padding: 0; margin: 0; }
.check-list li { position: relative; padding: 8px 0 8px 32px; border-bottom: 1px dashed var(--line); }
.check-list li:last-child { border-bottom: 0; }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: 13px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--lime) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 12px no-repeat;
}

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li { counter-increment: step; position: relative; padding: 0 0 22px 56px; }
.steps li:last-child { padding-bottom: 0; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: var(--coral); color: #fff; font-family: var(--display); font-size: 1.1rem;
}
.steps li:not(:last-child)::after {
  content: ""; position: absolute; left: 18px; top: 44px; bottom: 6px; width: 2px; background: var(--line);
}
.steps strong { display: block; color: var(--ink); }

.content ul:not([class]), .content ol:not([class]) { padding-left: 1.3em; }
.content ul:not([class]) li, .content ol:not([class]) li { margin-bottom: .55em; }
.content ul:not([class]) li::marker { color: var(--coral); }
.content ol:not([class]) li::marker { color: var(--coral); font-weight: 700; }

.section-title { display: flex; align-items: center; gap: 14px; }
.section-title::after { content: ""; flex: 1; height: 2px; background: linear-gradient(90deg, var(--amber), transparent); }

.figure { margin: 8px 0 24px; }
.figure img { border-radius: 14px; box-shadow: var(--shadow); }
.figure figcaption { font-size: .85rem; color: var(--muted); margin-top: 8px; text-align: center; }
@media (min-width: 680px) {
  .figure.right { float: right; width: min(42%, 320px); margin: 6px 0 18px 28px; }
  .figure.left { float: left; width: min(42%, 320px); margin: 6px 28px 18px 0; }
}
.clear { clear: both; }

/* Galería de variantes (fotos de bancos de imágenes) */
.gallery {
  display: grid; gap: 14px; margin: 18px 0 26px;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}
.gallery figure { margin: 0; }
.gallery img {
  width: 100%; aspect-ratio: 3 / 4; object-fit: cover;
  border-radius: 12px; box-shadow: var(--shadow);
  transition: transform .2s ease;
}
.gallery figure:hover img { transform: scale(1.02); }
.gallery figcaption { font-size: .85rem; color: var(--muted); text-align: center; margin-top: 6px; }
.gallery.wide-photos img { aspect-ratio: 3 / 2; }
.gallery.wide-photos { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.figure.in-panel { margin: 20px 0 0; }
.figure.in-panel img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; box-shadow: none; }

.menu-card {
  background: var(--card); border: 1px solid var(--line); border-left: 5px solid var(--amber);
  border-radius: 14px; padding: 20px 22px; margin: 18px 0 22px;
}
.menu-card h3 { margin-top: 0; }
.menu-card dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
.menu-card dt { font-weight: 700; color: var(--ink); }
.menu-card dd { margin: 0; }

.note {
  background: var(--paper-2); border-radius: 14px; padding: 18px 22px; margin: 24px 0; font-size: .97rem;
}

/* ---------- Barra lateral ---------- */
.sidebar { align-self: start; }
@media (min-width: 980px) { .sidebar { position: sticky; top: 140px; } }
.sidebar h2 { font-size: 1.25rem; margin: 0 0 12px; }
.side-list { list-style: none; padding: 0; margin: 0; }
.side-list a {
  display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 12px;
  text-decoration: none; color: var(--text);
}
.side-list a:hover { background: var(--paper-2); color: var(--ink); }
.side-list a[aria-current="page"] { background: var(--ink); color: #fff; }
.side-list img { width: 48px; height: 48px; object-fit: cover; border-radius: 10px; flex: none; }
.side-list span { font-weight: 600; line-height: 1.3; }
.side-list small { display: block; font-weight: 400; color: var(--muted); font-size: .8rem; }
.side-list a[aria-current="page"] small { color: #cfc3cf; }

/* ---------- Tarjetas de cócteles ---------- */
.section { padding: clamp(40px, 6vw, 72px) 0; }
.section.alt { background: var(--paper-2); }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 28px; }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; color: var(--muted); max-width: 52ch; }

.cards { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); list-style: none; padding: 0; margin: 0; }
.card {
  position: relative; display: flex; flex-direction: column; height: 100%;
  background: var(--card); border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line); box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -16px rgba(27,20,32,.4); }
.card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.card-body { padding: 16px 18px 20px; display: flex; flex-direction: column; flex: 1; }
.card h3 { margin: 0 0 6px; font-size: 1.3rem; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; }
.card p { margin: 0 0 12px; color: var(--muted); font-size: .95rem; }
.card .more { margin-top: auto; color: var(--coral-dark); font-weight: 600; font-size: .92rem; }
.tag {
  position: absolute; top: 12px; left: 12px; background: var(--lime); color: #fff;
  font-size: .75rem; font-weight: 700; padding: 4px 10px; border-radius: 999px;
}

/* Tarjeta sin foto: degradado con el nombre */
.card-ph {
  aspect-ratio: 4 / 3; display: grid; place-items: center; padding: 16px; text-align: center;
  background:
    radial-gradient(circle at 30% 25%, rgba(242,155,44,.55), transparent 55%),
    radial-gradient(circle at 75% 80%, rgba(217,71,43,.55), transparent 55%),
    var(--ink);
}
.card-ph span { font-family: var(--display); font-size: 1.7rem; color: #fff; letter-spacing: .02em; text-shadow: 0 2px 12px rgba(0,0,0,.4); }
.thumb-ph {
  width: 48px; height: 48px; border-radius: 10px; flex: none;
  background: radial-gradient(circle at 30% 30%, var(--amber), var(--coral) 70%);
}
.side-more { margin: 12px 0 0; font-weight: 600; font-size: .95rem; }

/* Rejilla de categorías */
.cat-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); list-style: none; padding: 0; margin: 0; }
.cat-grid a {
  display: flex; flex-direction: column; gap: 2px; height: 100%; text-decoration: none;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px;
  transition: border-color .2s, transform .2s;
}
.cat-grid a:hover { border-color: var(--amber); transform: translateY(-2px); }
.cat-grid strong { font-family: var(--display); font-weight: 500; font-size: 1.15rem; color: var(--ink); }
.cat-grid span { font-size: .85rem; color: var(--muted); }

/* Contenido largo en páginas de listado y guías */
.page-hero[style*="--hero"] {
  background: var(--hero) center / cover no-repeat, var(--ink);
  padding: clamp(56px, 9vw, 120px) 0;
}
.wide { padding: clamp(32px, 5vw, 56px) 0; }
.wide > .prose { padding: 0; }
.wide .cards { margin: 8px 0 32px; }
.table-wrap { overflow-x: auto; margin: 16px 0 24px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.table-wrap table { width: 100%; border-collapse: collapse; font-size: .95rem; min-width: 520px; }
.table-wrap th, .table-wrap td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table-wrap th { background: var(--paper-2); font-weight: 700; color: var(--ink); }
.table-wrap tr:last-child td { border-bottom: 0; }

/* Calculadora */
.calc { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.calc label { display: block; font-weight: 600; color: var(--ink); margin-bottom: 6px; }
.calc input, .calc select {
  width: 100%; font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--text);
}
.calc-result { margin-top: 20px; }
.calc-result output { display: block; }

/* ---------- Portada: bloques ---------- */
.intro-grid { display: grid; gap: 32px; align-items: start; }
@media (min-width: 900px) { .intro-grid { grid-template-columns: 1.3fr 1fr; } }
.pillars { display: grid; gap: 16px; list-style: none; padding: 0; margin: 0; }
.pillars li { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.pillars strong { display: block; font-family: var(--display); font-weight: 500; font-size: 1.2rem; color: var(--ink); margin-bottom: 4px; }

.timeline { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--amber); }
.timeline li { position: relative; padding: 0 0 22px 24px; }
.timeline li::before {
  content: ""; position: absolute; left: -8px; top: 6px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--paper); border: 3px solid var(--coral);
}
.timeline strong { display: block; font-family: var(--display); font-weight: 500; font-size: 1.15rem; color: var(--ink); }

.two-col { display: grid; gap: 28px; }
@media (min-width: 860px) { .two-col { grid-template-columns: 1fr 1fr; } }

.menus { display: grid; gap: 24px; }
@media (min-width: 960px) { .menus { grid-template-columns: repeat(3, 1fr); } }
.menus article { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.menus article img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.menus .body { padding: 20px 22px; }
.menus h3 { margin-top: 0; }
.menus .course { list-style: none; padding: 0; margin: 0 0 14px; font-size: .95rem; }
.menus .course li { padding: 4px 0; border-bottom: 1px dashed var(--line); }
.menus .course b { color: var(--coral-dark); }
.menus details summary { cursor: pointer; font-weight: 600; color: var(--coral-dark); }
.menus details p { font-size: .95rem; margin-top: 10px; }
.menus-nota { max-width: 68ch; margin: 32px auto 0; text-align: center; color: var(--muted); }

/* ---------- FAQ ---------- */
.faq details {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px; margin-bottom: 12px;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 52px 18px 20px; position: relative;
  font-weight: 600; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  font-size: 1.5rem; color: var(--coral); line-height: 1;
}
.faq details[open] summary::after { content: "–"; }
.faq details > div { padding: 0 20px 18px; }

/* ---------- Páginas de texto (legales, etc.) ---------- */
.prose { max-width: 78ch; padding: clamp(32px, 5vw, 56px) 0; }
.prose h2 { font-size: 1.5rem; padding-top: 1.2rem; border-top: 1px solid var(--line); }
.prose h2:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.prose ul li { margin-bottom: .4em; }
.data-box { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 18px 22px; }

.glossary { margin: 0; }
.glossary dt {
  font-family: var(--display); font-weight: 500; font-size: 1.2rem; color: var(--ink);
  margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line);
}
.glossary dt:first-child { border-top: 0; margin-top: 0; }
.glossary dd { margin: 4px 0 0; }

.prose .cards .panel { box-shadow: none; padding: 18px; }
.prose .cards .panel p { font-size: .95rem; margin-bottom: .6em; }

.sitemap-list { columns: 2 260px; column-gap: 40px; }
.sitemap-list section { break-inside: avoid; margin-bottom: 24px; }
.sitemap-list h2 { font-size: 1.25rem; margin-top: 0; }
.sitemap-list ul { padding-left: 1.2em; margin: 0; }

/* ---------- Pie ---------- */
.site-footer { background: var(--ink); color: #cfc3cf; padding: 48px 0 24px; margin-top: 0; font-size: .95rem; }
/* Borde superior curvo, simétrico al de las cabeceras: centro arriba, esquinas más abajo */
.site-footer {
  --curva: clamp(40px, 7vw, 100px);
  --curva-mask:
    radial-gradient(60% 100% at 50% 100%, #000 98%, transparent 100%) top / 100% var(--curva) no-repeat,
    linear-gradient(#000 0 0) bottom / 100% calc(100% - var(--curva) + 1px) no-repeat;
  -webkit-mask: var(--curva-mask);
  mask: var(--curva-mask);
  /* Sube sobre la sección anterior lo que bajan las esquinas, para que en ellas se vea su fondo y no el de la página */
  position: relative;
  margin-top: calc(var(--curva) * -.45);
  padding-top: calc(48px + var(--curva) * .45);
}
.footer-grid { display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.site-footer h2 { color: #fff; font-size: 1.1rem; margin: 0 0 12px; letter-spacing: .04em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 6px; }
.site-footer a { color: #f1e9f1; text-decoration: none; }
.site-footer a:hover { color: var(--amber); text-decoration: underline; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1); margin-top: 32px; padding-top: 18px;
  display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; font-size: .85rem; color: #a99ca9;
}
.responsible { color: #a99ca9; font-size: .85rem; }

.to-top {
  position: fixed; right: 16px; bottom: 16px; width: 44px; height: 44px; border-radius: 50%;
  background: var(--coral); color: #fff; display: grid; place-items: center; text-decoration: none;
  box-shadow: var(--shadow); font-size: 1.2rem; z-index: 40;
}
.to-top:hover { background: var(--coral-dark); color: #fff; }

/* ---------- Página de contacto ---------- */
.contacto-email { font-family: var(--display); font-size: clamp(1.4rem, 5vw, 2rem); margin: .2em 0 1em; overflow-wrap: anywhere; }

/* ---------- Aviso de consumo responsable (cabecera de recetas y pie) ---------- */
.aviso-18 {
  flex: none; display: inline-grid; place-items: center; width: 2.7em; height: 2.7em; border-radius: 50%;
  border: 2px solid currentColor; font-family: var(--sans); font-size: .72rem; font-weight: 700; letter-spacing: -.02em; line-height: 1;
}
.aviso-alcohol, .aviso-pie { display: flex; align-items: center; gap: 10px; }
.aviso-alcohol {
  margin: 16px 0 0; font-size: .88rem; line-height: 1.4; color: #f3ebf2;
  text-shadow: 0 1px 8px rgba(0,0,0,.5);
}
.aviso-alcohol .aviso-18 { color: var(--amber); text-shadow: none; }

/* ---------- Verificación de edad (js/edad.js) ---------- */
html.edad-abierta, html.edad-abierta body { overflow: hidden; }
.edad-gate {
  position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 16px;
  background: rgba(27, 20, 32, .9); overflow-y: auto; transition: opacity .3s;
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .edad-gate { background: rgba(27, 20, 32, .78); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
}
.edad-gate.edad-fuera { opacity: 0; pointer-events: none; }
.edad-caja {
  width: 100%; max-width: 440px; background: var(--paper); color: var(--text); text-align: center;
  border-radius: var(--radius); padding: clamp(24px, 6vw, 40px) clamp(20px, 6vw, 36px) 20px;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .6); border-top: 6px solid var(--coral);
}
.edad-caja:focus { outline: none; }
.edad-logo { display: block; margin: 0 auto 8px; }
.edad-marca { font-family: var(--display); font-size: 1.3rem; letter-spacing: .02em; color: var(--ink); margin: 0 0 18px; }
.edad-marca b { color: var(--coral); font-weight: 500; }
.edad-caja h2 { font-size: clamp(1.6rem, 6vw, 2rem); margin: 0 0 .4em; color: var(--ink); }
.edad-caja p { margin: 0 0 1em; }
.edad-botones { display: flex; flex-direction: column; gap: 10px; margin: 22px 0 18px; }
.edad-botones .btn { justify-content: center; font-size: 1.05rem; padding: 14px 22px; cursor: pointer; font-family: inherit; }
.edad-botones .edad-no { background: transparent; color: var(--ink); border-color: var(--line); }
.edad-botones .edad-no:hover { background: #fff; border-color: var(--muted); color: var(--ink); }
.edad-botones .btn:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }
.edad-nota { font-size: .85rem; color: var(--muted); }
.edad-legal { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 16px; font-size: .8rem; border-top: 1px solid var(--line); padding-top: 14px; margin: 0 !important; }
.edad-legal a { color: var(--muted); }
@media (prefers-reduced-motion: no-preference) {
  .edad-caja { animation: edad-entra .35s var(--ease-out) both; }
  @keyframes edad-entra { from { opacity: 0; transform: translateY(16px) scale(.98); } }
}

@media print {
  .site-header, .cocktail-nav, .sidebar, .site-footer, .to-top, .more-cocktails { display: none !important; }
  body { background: #fff; }
  .recipe-hero, .page-hero { background: none; color: #000; }
  .recipe-hero h1, .page-hero h1, .recipe-hero .lead { color: #000; }
}
