/* =========================================================================
   El Castillo de Dulces — hoja del tema (diseño 1b)
   Fase 2.1: fuentes self-hosted + tokens de color + base tipográfica
   Fase 2.2: chrome global (ticker, header, footer, WhatsApp flotante)
   Fidelidad: .planning/specs/home-1b-referencia.html
   ========================================================================= */

/* ---------- Fuentes self-hosted (variables, latin) ---------------------- */
@font-face {
  font-family: 'Baloo 2';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/baloo2.woff2') format('woff2');
}

@font-face {
  font-family: 'Nunito Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../fonts/nunitosans.woff2') format('woff2');
}

/* ---------- Tokens de color -------------------------------------------- */
:root {
  --cdd-chocolate: #3A1E0E;
  --cdd-cafe: #5A2E17;
  --cdd-fucsia: #E85AA0;
  --cdd-fucsia-hover: #D64B92;
  /* #C43B85 daba 4.19:1 sobre crema (bajo AA). Se oscurece a #B0306F (5.17:1)
     manteniendo el fucsia de marca; mejora también el blanco encima (badges). */
  --cdd-fucsia-texto: #B0306F;
  --cdd-amarillo: #F2C230;
  --cdd-verde-claro: #86EFAC;
  --cdd-crema: #F2EEE0;
  --cdd-crema2: #EAE4D4;
  --cdd-borde: rgba(90, 46, 23, .15);
  /* #8a6a50 daba 4.25:1 sobre crema (bajo AA). #7d5f47 = 5.02:1 (AA ok). */
  --cdd-texto-suave: #7d5f47;
  --cdd-whatsapp: #25D366;
}

/* ---------- Base tipográfica ------------------------------------------- */
body {
  font-family: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--cdd-chocolate);
  background: var(--cdd-crema);
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
}

/* Foco accesible consistente con la referencia */
a:focus-visible,
button:focus-visible,
.cdd-btn:focus-visible {
  outline: 3px solid var(--cdd-fucsia-texto);
  outline-offset: 2px;
}

/* =========================================================================
   Chrome global
   ========================================================================= */

/* ---------- Ticker / marquee ------------------------------------------- */
.cdd-ticker {
  display: flex;
  align-items: center;
  background: var(--cdd-verde-claro);
  overflow: hidden;
  padding: 0;
  white-space: nowrap;
}

.cdd-ticker__viewport {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  padding: 10px 0;
}

.cdd-ticker__cta {
  flex: 0 0 auto;
  margin: 4px 16px;
  padding: 7px 20px;
  border-radius: 999px;
  background: var(--cdd-chocolate);
  color: #fff;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: .04em;
  text-decoration: none;
  transition: background .16s ease;
}

.cdd-ticker__cta:hover { background: var(--cdd-fucsia-texto); color: #fff; }

.cdd-ticker__track {
  display: inline-block;
  animation: cdd-marquee 44s linear infinite;
  will-change: transform;
}

.cdd-ticker__track span {
  color: var(--cdd-chocolate);
  font-weight: 800;
  font-size: 12.5px;
  letter-spacing: .08em;
}

@keyframes cdd-marquee {
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .cdd-ticker__track {
    animation: none;
    transform: none;
  }
}

/* ---------- Header ----------------------------------------------------- */
.cdd-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 32px;
  border-bottom: 1.5px solid var(--cdd-borde);
  background: var(--cdd-crema);
}

.cdd-header__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  text-decoration: none;
}

.cdd-header__brand img {
  height: 88px;
  width: auto;
  display: block;
  transition: transform 0.2s ease;
}

.cdd-header__brand img:hover {
  transform: scale(1.04);
}

.cdd-header__brand-name {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 22px;
  color: var(--cdd-cafe);
}

.cdd-nav {
  flex: 1 1 auto;
  min-width: 0;
  padding-inline: 20px; /* aire entre el menú, la marca y el buscador */
}

.cdd-nav__menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 1.3vw, 22px);
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: clamp(14px, 1vw, 16px);
  line-height: 1.2;
  font-weight: 700;
}

.cdd-nav__menu li {
  display: flex;
  align-items: center;
  height: 48px;
  margin: 0;
}

/* Todos los enlaces (con o sin dropdown) con la misma caja y línea base. */
.cdd-nav__menu li > a {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  line-height: 1.2;
  white-space: nowrap; /* cada ítem en una sola línea */
}

/* "Cotiza aquí": resaltado como botón. */
.cdd-nav__menu .cdd-nav__item--cta > a {
  background: var(--cdd-fucsia-texto);
  color: #fff;
  padding: 0 20px;
  min-height: 42px;
  border-radius: 999px;
}
.cdd-nav__menu .cdd-nav__item--cta > a:hover { background: var(--cdd-cafe); color: #fff; }

/* El submenú desplegable no hereda la altura fija de los ítems superiores. */
.cdd-nav__submenu li { height: auto; display: block; }
.cdd-nav__submenu li > a { display: block; min-height: 0; }

.cdd-nav__menu a {
  color: var(--cdd-cafe);
  text-decoration: none;
  transition: color .16s ease;
}

.cdd-nav__menu a:hover { color: var(--cdd-fucsia-texto); }

/* ---------- Dropdown de categorías "Catálogo ▾" (T3) ------------------- */
.cdd-nav__menu .cdd-nav__item { position: relative; }

.cdd-nav__item--dropdown {
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.cdd-nav__toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--cdd-cafe);
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
  padding: 6px;
  min-width: 28px;
  min-height: 28px;
  border-radius: 999px;
  transition: color .16s ease;
}

.cdd-nav__toggle:hover { color: var(--cdd-fucsia-texto); }

.cdd-nav__toggle:focus-visible,
.cdd-nav__sublink:focus-visible {
  outline: 2px solid var(--cdd-fucsia-texto);
  outline-offset: 2px;
}

.cdd-nav__caret {
  display: inline-block;
  transition: transform .16s ease;
}

.cdd-nav__item--dropdown.is-open .cdd-nav__caret { transform: rotate(180deg); }

.cdd-nav__submenu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 1000;
  min-width: 210px;
  margin: 0;
  padding: 8px;
  list-style: none;
  background: #fff;
  border: 1px solid rgba(90, 46, 23, .12);
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(58, 30, 14, .16);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .16s ease, transform .16s ease, visibility .16s;
}

/* Puente invisible: evita que el panel se cierre al mover el cursor del
   disparador al panel (hay 8px de separación). */
.cdd-nav__submenu::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}

.cdd-nav__item--dropdown.is-open > .cdd-nav__submenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* Respaldo sin JS para ratón: en dispositivos con hover, abre por :hover. */
@media (hover: hover) {
  .cdd-nav__item--dropdown:hover > .cdd-nav__submenu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
}

.cdd-nav__submenu li { margin: 0; }

.cdd-nav__sublink {
  display: block;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  color: var(--cdd-cafe);
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .16s ease, color .16s ease;
}

.cdd-nav__sublink:hover,
.cdd-nav__sublink:focus-visible {
  background: var(--cdd-crema);
  color: var(--cdd-fucsia-texto);
}

@media (prefers-reduced-motion: reduce) {
  .cdd-nav__submenu,
  .cdd-nav__caret {
    transition: none;
  }
}

.cdd-header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  justify-content: flex-end;
}

/* Cuenta: ícono + "Hola, Inicia sesión / Ingresa / Regístrate" */
.cdd-account {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-left: 6px;
  color: var(--cdd-cafe);
  text-decoration: none;
  white-space: nowrap;
}

.cdd-account__icon { color: #ff3d8b; flex: none; }

.cdd-account__text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.cdd-account__hello { font-size: 12.5px; font-weight: 600; color: var(--cdd-texto-suave); }
.cdd-account__action { font-size: 14px; font-weight: 800; }
.cdd-account:hover .cdd-account__action { color: var(--cdd-fucsia-texto); }

/* Pantallas medianas: el logo ya trae el nombre, así que se oculta el texto repetido
   junto a él para dar espacio al menú y al acceso a la cuenta. */
@media (max-width: 1700px) {
  .cdd-header__brand-name {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
  .cdd-header__brand img { height: 96px; }
}

/* Botones pill */
.cdd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 10px 18px;
  min-height: 44px;
  font-family: 'Nunito Sans', sans-serif;
  cursor: pointer;
  text-decoration: none;
  transition: filter .16s ease, transform .16s ease;
}

.cdd-btn:hover { filter: brightness(.93); }

/* Buscador del header (pill: input + botón), mismo look que el antiguo botón */
.cdd-search {
  display: flex;
  align-items: center;
  background: #fff;
  border: 1.5px solid rgba(90, 46, 23, .25);
  border-radius: 999px;
  min-height: 44px;
  padding: 0 6px 0 16px;
  transition: border-color .16s ease;
}

.cdd-search:focus-within {
  border-color: var(--cdd-fucsia-texto);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--cdd-fucsia-texto) 25%, transparent);
}

.cdd-search__input {
  border: 0;
  outline: none;
  background: transparent;
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 600;
  font-size: 13.5px;
  color: var(--cdd-texto-suave);
  padding: 8px 6px;
  width: 120px;
  min-width: 0;
}

.cdd-search__input::placeholder { color: var(--cdd-texto-suave); opacity: .8; }

.cdd-search__submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  color: var(--cdd-cafe);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 6px 10px;
  min-height: 32px;
  border-radius: 999px;
  transition: color .16s ease;
}

.cdd-search__submit:hover { color: var(--cdd-fucsia-texto); }
.cdd-search__submit:focus-visible {
  outline: 2px solid var(--cdd-fucsia-texto);
  outline-offset: 2px;
}

.cdd-btn--cart {
  background: var(--cdd-cafe);
  color: #F7F5F0;
  border: 0;
  font-weight: 700;
  font-size: 13.5px;
}

/* ---------- Footer ----------------------------------------------------- */
.cdd-footer {
  background: var(--cdd-chocolate);
  color: #cbb69e;
  padding: 26px 48px;
  /* Tres columnas: marca | dirección (centrada de verdad) | redes. */
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  font-size: 13px;
  gap: 12px 24px;
}

.cdd-footer__address { text-align: center; }
.cdd-footer__social { justify-self: end; }

.cdd-footer__brand-block {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cdd-footer__brand {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 16px;
  color: var(--cdd-crema);
}

.cdd-footer__tagline {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--cdd-amarillo);
}

.cdd-footer__social {
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.cdd-footer__social a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #cbb69e;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  transition: color 0.2s ease, transform 0.2s ease;
}

.cdd-social-icon {
  width: 18px;
  height: 18px;
}

.cdd-footer__social a:hover {
  color: var(--cdd-amarillo);
  transform: translateY(-2px);
}

/* Crédito de desarrollador: línea completa, discreta, con separador superior. */
.cdd-footer__credit {
  grid-column: 1 / -1;
  flex-basis: 100%;
  margin: 6px 0 0;
  padding-top: 14px;
  border-top: 1px solid rgba(203, 182, 158, .22);
  text-align: center;
  font-size: 12px;
  color: #a68e74;
}
.cdd-footer__credit a {
  color: var(--cdd-amarillo);
  font-weight: 700;
  text-decoration: none;
  transition: color .16s ease;
}
.cdd-footer__credit a:hover { color: var(--cdd-crema); text-decoration: underline; }

/* ---------- Botón WhatsApp flotante (global) --------------------------- */
.cdd-whatsapp {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--cdd-whatsapp);
  border: 0;
  color: #fff;
  box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: transform .16s ease;
  /* Aparición suave al cargar. Sin fill-mode forwards a propósito: al terminar,
     el elemento vuelve a su estado base (transform:none) y el :hover funciona. */
  animation: cdd-wa-in .45s cubic-bezier(0.16, 1, 0.3, 1);
}

.cdd-whatsapp:hover { transform: scale(1.06); }

.cdd-whatsapp svg {
  width: 30px;
  height: 30px;
  fill: #fff;
}

/* Entrada del botón WhatsApp: fade + slide-up + escala. Sin 'to' → interpola
   hacia el estado base del elemento. */
@keyframes cdd-wa-in {
  from { opacity: 0; transform: translateY(14px) scale(.85); }
}

@media (prefers-reduced-motion: reduce) {
  .cdd-whatsapp { animation: none; }
}

/* ---------- Responsive ------------------------------------------------- */
/* Pantallas medianas: el menú pasa a una segunda fila, para que ningún ítem
   se parta en dos líneas. */
@media (max-width: 1400px) {
  .cdd-header { flex-wrap: wrap; row-gap: 6px; }
  .cdd-header__brand { flex: 1 1 auto; }
  .cdd-nav { order: 3; flex: 1 1 100%; }
}

@media (max-width: 860px) {
  .cdd-header {
    flex-wrap: wrap;
    padding: 14px 20px;
    gap: 14px;
  }
  .cdd-header__brand { flex: 1 1 auto; }
  .cdd-header__brand img { height: 68px; }
  .cdd-header__actions { flex: 0 0 auto; }
  .cdd-nav__menu {
    order: 3;
    flex-basis: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
  }
  /* Táctil: el panel no depende de hover; se abre en flujo bajo el ítem por tap
     (clase is-open del JS), sin posicionamiento absoluto que desborde. */
  .cdd-nav__item--dropdown { flex-wrap: wrap; justify-content: center; }
  .cdd-nav__submenu {
    position: static;
    top: auto;
    display: none;
    width: 100%;
    min-width: 220px;
    margin-top: 8px;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
  }
  .cdd-nav__item--dropdown.is-open > .cdd-nav__submenu { display: block; }
  .cdd-nav__submenu::before { display: none; }
  .cdd-footer {
    padding: 22px 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
  }
  .cdd-footer__social { justify-self: auto; justify-content: center; }
  .cdd-footer__brand-block { align-items: center; }
}

@media (max-width: 480px) {
  .cdd-header__brand img { height: 54px; }
  .cdd-header__brand-name { font-size: 20px; }
  .cdd-header__actions {
    flex-basis: 100%;
    justify-content: center;
    flex-wrap: wrap;
  }
  .cdd-search { flex: 1 1 200px; }
  .cdd-search__input { width: auto; flex: 1 1 auto; }
}

/* =========================================================================
   HOME 1b — portada (Fase 2.3 / 2.4 / 2.5)
   Fidelidad: .planning/specs/home-1b-referencia.html
   ========================================================================= */

/* ---------- Utilidades de interacción (de la referencia) --------------- */
.hovlift { transition: transform .16s ease, box-shadow .16s ease; }
.hovlift:hover { transform: translateY(-3px); box-shadow: 0 10px 22px rgba(58, 30, 14, .16); }
.hovdim { transition: filter .16s ease, transform .16s ease; }
.hovdim:hover { filter: brightness(.93); }
.catcard { transition: transform .16s ease, box-shadow .16s ease; }
.catcard:hover { transform: translateY(-3px); box-shadow: 0 8px 18px rgba(58, 30, 14, .14); }

.cdd-accent-text { color: var(--cdd-fucsia-texto); }

/* ---------- Portada a todo el ancho (neutraliza el contenedor GP) ------ */
.home #page,
.home #content,
.home .site-content {
  max-width: 100%;
  padding: 0;
  margin: 0;
}

.cdd-home { width: 100%; }

/* Contenedor interno centrado para cada sección */
.cdd-home__inner {
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: 48px;
}

/* ---------- Hero Slider Interactivo & Animado (REQ-02) ----------------- */
.cdd-hero-slider {
  position: relative;
  overflow: hidden;
  border-bottom: 4px solid var(--cdd-amarillo);
  box-shadow: inset 0 -10px 20px rgba(0, 0, 0, 0.2);
  min-height: 480px;
}

.cdd-hero-slides {
  position: relative;
  width: 100%;
  min-height: 480px;
}

.cdd-hero-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 68px 0 64px;
}

.cdd-hero-slide.is-active {
  position: relative;
  opacity: 1;
  visibility: visible;
  z-index: 2;
}

.cdd-hero-slide__bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  transform: scale(1.03);
  transition: transform 7s ease-out;
  z-index: 1;
}

.cdd-hero-slide.is-active .cdd-hero-slide__bg {
  transform: scale(1.08);
}

.cdd-hero-slide__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(65, 12, 50, 0.82) 0%, rgba(120, 20, 90, 0.76) 50%, rgba(45, 10, 38, 0.86) 100%);
  z-index: 2;
}

.cdd-hero-slide__overlay--choc {
  background: linear-gradient(135deg, rgba(45, 20, 10, 0.85) 0%, rgba(95, 45, 20, 0.80) 50%, rgba(35, 15, 8, 0.88) 100%);
}

.cdd-hero-slide__overlay--party {
  background: linear-gradient(135deg, rgba(10, 60, 80, 0.85) 0%, rgba(140, 20, 100, 0.78) 50%, rgba(200, 140, 10, 0.80) 100%);
}

.cdd-hero-slide__content {
  position: relative;
  z-index: 3;
  width: 100%;
  color: #ffffff;
}

/* ---- Portadas ilustradas (portada-1/2/3.jpg): traen el logo arriba al centro --- */
.cdd-hero-slider,
.cdd-hero-slides { min-height: clamp(520px, 40vw, 700px); }

.cdd-hero-slide--1 .cdd-hero-slide__bg,
.cdd-hero-slide--2 .cdd-hero-slide__bg,
.cdd-hero-slide--3 .cdd-hero-slide__bg {
  background-position: center 12%;
  transform: none;
  transition: none;
}

/* Velo suave solo para dar contraste al texto; la ilustración se ve completa. */
.cdd-hero-slide--1 .cdd-hero-slide__overlay,
.cdd-hero-slide--2 .cdd-hero-slide__overlay {
  background: rgba(30, 12, 55, 0.30);
}
.cdd-hero-slide--3 .cdd-hero-slide__overlay { display: none; }

/* Deja libre el logo que viene dentro de la imagen. */
.cdd-hero-slide--1,
.cdd-hero-slide--2 { padding-top: 150px; }

/* Banner 3: la imagen ya trae el mensaje; todo el banner enlaza a "Cotiza aquí". */
.cdd-hero-slide--3 { padding: 0; }

/* Cada diapositiva ocupa toda la altura del banner: sin franja al pie (velo cortado)
   y la diapositiva 3, que no tiene contenido en flujo, deja de colapsar a 0 px. */
.cdd-hero-slide { min-height: clamp(520px, 40vw, 700px); }
.cdd-hero-slide__link {
  position: absolute;
  inset: 0;
  z-index: 4;
}

.cdd-hero__eyebrow {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .18em;
  color: #FFE680;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
  margin: 0 0 14px;
}

.cdd-hero__brandtag { color: #FF99DD; }

.cdd-hero__tagline {
  margin: 12px 0 0;
  font-size: 17px;
  font-weight: 800;
  color: #FFFFFF;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.cdd-hero__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 76px;
  line-height: .98;
  color: #FFFFFF;
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.7), 0 2px 4px rgba(0, 0, 0, 0.8);
  margin: 0 auto;
  max-width: 900px;
  text-wrap: balance;
}

.cdd-hero__sub {
  font-size: 18.5px;
  line-height: 1.55;
  color: #FFF5EA;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
  margin: 18px auto 28px;
  max-width: 640px;
  font-weight: 600;
}

/* Animaciones de Entrada de Texto por Capas */
.cdd-hero-slide.is-active .cdd-hero__eyebrow {
  animation: cddHeroFadeDown 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.cdd-hero-slide.is-active .cdd-hero__title {
  animation: cddHeroScaleUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.25s both;
}

.cdd-hero-slide.is-active .cdd-hero__sub {
  animation: cddHeroFadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both;
}

.cdd-hero-slide.is-active .cdd-seg-wrap,
.cdd-hero-slide.is-active .cdd-hero__btn-wrap {
  animation: cddHeroPopIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.55s both;
}

@keyframes cddHeroFadeDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cddHeroScaleUp {
  from { opacity: 0; transform: scale(0.92) translateY(15px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes cddHeroFadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes cddHeroPopIn {
  from { opacity: 0; transform: scale(0.88); }
  to { opacity: 1; transform: scale(1); }
}

.cdd-hero__btn-wrap {
  margin-top: 20px;
}

.cdd-hero__btn-wrap .cdd-btn-yellow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 800;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  border-radius: 999px;
  text-decoration: none;
}

/* Controles de Flechas */
.cdd-hero-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #ffffff;
  font-size: 24px;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.cdd-hero-nav:hover {
  background: rgba(255, 255, 255, 0.45);
  color: var(--cdd-chocolate);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.cdd-hero-nav--prev { left: 24px; }
.cdd-hero-nav--next { right: 24px; }

/* Indicadores Dots */
.cdd-hero-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  gap: 10px;
  background: rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(6px);
  padding: 6px 14px;
  border-radius: 99px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.cdd-hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease, width 0.25s ease;
}

.cdd-hero-dot.is-active {
  background: var(--cdd-amarillo);
  width: 24px;
  border-radius: 99px;
  box-shadow: 0 0 8px rgba(242, 194, 48, 0.8);
}

/* ---------- Selector Detalle/Mayorista (pill) -------------------------- */
.cdd-seg-wrap {
  display: inline-flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}

.cdd-seg {
  display: inline-flex;
  background: #fff;
  border: 2px solid var(--cdd-chocolate);
  border-radius: 999px;
  padding: 5px;
  gap: 4px;
  box-shadow: 0 4px 12px rgba(58, 30, 14, .12);
}

.cdd-seg__btn {
  border: 0;
  border-radius: 999px;
  padding: 12px 28px;
  font: 800 15px 'Nunito Sans', sans-serif;
  min-height: 44px;
  background: transparent;
  color: var(--cdd-chocolate);
  transition: background .16s ease, color .16s ease;
}

.cdd-seg__btn.is-active {
  background: var(--cdd-chocolate);
  color: #F7F5F0;
}

/* Variante con una sola opción (mayorista): enlace a "Cotiza aquí", siempre activo. */
.cdd-seg--solo .cdd-seg__btn {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  cursor: pointer;
  background: var(--cdd-chocolate) !important;
  color: #F7F5F0 !important;
}

.cdd-seg__hint {
  font-size: 13px;
  color: var(--cdd-texto-suave);
  font-weight: 600;
}

/* ---------- Scallop chocolate ------------------------------------------ */
.cdd-scallop {
  height: 26px;
  background: radial-gradient(circle at 14px -8px, var(--cdd-cafe) 18px, transparent 19px);
  background-size: 28px 26px;
  background-repeat: repeat-x;
}

/* ---------- Categorías ------------------------------------------------- */
/* ---------- Marquee Continuo de Categorías (REQ-04) -------------------- */
.cdd-cats {
  padding: 36px 0 16px;
  overflow: hidden;
  position: relative;
}

.cdd-cats__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1240px;
  margin: 0 auto 16px;
  padding: 0 48px;
}

.cdd-cats__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 26px;
  color: var(--cdd-chocolate);
  margin: 0;
}

.cdd-cats__badge {
  font-size: 13px;
  font-weight: 700;
  color: var(--cdd-fucsia-texto);
  background: rgba(232, 90, 160, 0.1);
  padding: 4px 12px;
  border-radius: 99px;
}

.cdd-marquee-container {
  display: flex;
  overflow: hidden;
  width: 100%;
  position: relative;
  mask-image: linear-gradient(to right, transparent, black 4%, black 96%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 4%, black 96%, transparent);
}

.cdd-marquee-track {
  display: flex;
  width: max-content;
  animation: cdd-marquee-scroll 22s linear infinite;
  will-change: transform;
}

.cdd-marquee-track:hover {
  animation-play-state: paused;
}

.cdd-marquee-group {
  display: flex;
  gap: 16px;
  padding-right: 16px;
}

.cdd-cat {
  flex: 0 0 180px;
  width: 180px;
  background: #fff;
  border-radius: 14px;
  border-top: 5px solid var(--cdd-chocolate);
  padding: 16px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 3px 10px rgba(58, 30, 14, .08);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cdd-cat:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(58, 30, 14, .15);
}

.cdd-cat__name {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 17.5px;
  color: var(--cdd-chocolate);
}

.cdd-cat__note {
  font-size: 12px;
  color: var(--cdd-texto-suave);
  font-weight: 600;
}

@keyframes cdd-marquee-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Color de borde por categoría */
.cdd-cat--gomitas    { border-top-color: #4CAF6E; }
.cdd-cat--chocolates { border-top-color: #7A3E22; }
.cdd-cat--dulces     { border-top-color: #E85AA0; }
.cdd-cat--galletas   { border-top-color: #F2C230; }
.cdd-cat--confites   { border-top-color: #8E5AA8; }
.cdd-cat--cotillon   { border-top-color: #E8730C; }
.cdd-cat--despensa   { border-top-color: #4A90D9; }

/* ---------- Más vendidos ----------------------------------------------- */
.cdd-best { padding: 36px 0 12px; }

.cdd-best__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 16px;
}

.cdd-best__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 26px;
  color: var(--cdd-chocolate);
  margin: 0;
}

.cdd-best__showing {
  font-size: 13px;
  font-weight: 700;
  color: var(--cdd-texto-suave);
}

.cdd-best__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.cdd-best__cta {
  display: flex;
  justify-content: center;
  margin: 22px 0 8px;
}

.cdd-btn-outline {
  background: transparent;
  border: 2px solid var(--cdd-cafe);
  color: var(--cdd-cafe);
  border-radius: 999px;
  padding: 13px 30px;
  font: 800 15px 'Nunito Sans', sans-serif;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

/* ---------- Card de producto ------------------------------------------- */
.cdd-card {
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-card__media {
  position: relative;
  height: 160px;
  overflow: hidden;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-bottom: 1px solid #F0E8DD;
}

/* Imagen del producto con fondo blanco estandarizado (REQ-03) */
.cdd-card__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 8px;
  display: block;
  transition: transform 0.25s ease;
}

.cdd-card:hover .cdd-card__img {
  transform: scale(1.05);
}

.cdd-card__media-label {
  font: 11px ui-monospace, Menlo, monospace;
  color: #9c8b74;
}

.cdd-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  border-radius: 6px;
  padding: 3px 8px;
}

.cdd-badge--vendido { background: #8E5AA8; }
.cdd-badge--nuevo   { background: #2F6FB5; }
.cdd-badge--oferta  { background: #B23A78; }
.cdd-badge--default { background: var(--cdd-chocolate); }

.cdd-card__body {
  padding: 13px 15px 15px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.cdd-card__name {
  font-size: 14px;
  font-weight: 700;
  color: var(--cdd-chocolate);
  line-height: 1.3;
  min-height: 36px;
  text-decoration: none;
}

.cdd-card__price-block { margin-top: auto; }

.cdd-card__price-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .06em;
  color: var(--cdd-texto-suave);
}

.cdd-card__ref {
  display: inline-block;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .04em;
  color: #fff;
  background: var(--cdd-fucsia-texto);
  border-radius: 4px;
  padding: 1px 5px;
  margin-left: 4px;
  vertical-align: middle;
  text-transform: uppercase;
}

.cdd-card__price {
  font-size: 21px;
  font-weight: 800;
  color: var(--cdd-chocolate);
}

.cdd-card__price-unit {
  font-size: 12px;
  font-weight: 700;
  color: var(--cdd-texto-suave);
}

.cdd-card__price-sub {
  font-size: 12px;
  color: #7a5c40;
  font-weight: 600;
}

.cdd-card__add {
  background: var(--cdd-fucsia);
  color: var(--cdd-chocolate);
  border: 0;
  border-radius: 999px;
  padding: 11px 0;
  font: 800 14px 'Nunito Sans', sans-serif;
  min-height: 44px;
  margin-top: 6px;
  text-align: center;
  text-decoration: none;
}

/* Producto sin precio ("Consultar precio"): precio en tono suave y botón
   neutro (secundario) que lleva a la ficha a cotizar, no a comprar. */
.cdd-card__price--consulta {
  font-size: 16px;
  color: var(--cdd-chocolate);
}
.cdd-card__add--consulta {
  background: transparent;
  color: var(--cdd-chocolate);
  border: 1.5px solid var(--cdd-borde, #E0D6C4);
}

/* ---------- Banda & Feed de Instagram ---------------------------------- */
.cdd-ig {
  background: var(--cdd-cafe);
  margin-top: 36px;
  padding: 52px 0 60px;
}

.cdd-ig__wrapper {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.cdd-ig__head {
  display: flex;
  align-items: center;
  gap: 48px;
  flex-wrap: wrap;
}

.cdd-ig__count {
  flex: none;
  text-align: center;
}

.cdd-ig__number {
  display: block;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 84px;
  line-height: 1;
  color: var(--cdd-amarillo);
}

.cdd-ig__label {
  display: block;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .1em;
  color: #e6d5c2;
}

.cdd-ig__copy {
  flex: 1;
  min-width: 280px;
}

.cdd-ig__text {
  margin: 0 0 14px;
  font-size: 16px;
  line-height: 1.55;
  color: #e6d5c2;
  max-width: 520px;
}

.cdd-ig__text b { color: #F7F5F0; }

.cdd-btn-yellow {
  background: var(--cdd-amarillo);
  color: var(--cdd-chocolate);
  border: 0;
  border-radius: 999px;
  padding: 12px 24px;
  font: 800 14px 'Nunito Sans', sans-serif;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.cdd-ig-feed {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 10px;
}

.cdd-ig-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 1;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  display: block;
  text-decoration: none;
}

.cdd-ig-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.cdd-ig-card__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(58, 30, 14, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #ffffff;
  padding: 16px;
  text-align: center;
}

.cdd-ig-card:hover .cdd-ig-card__overlay {
  opacity: 1;
}

.cdd-ig-card:hover img {
  transform: scale(1.08);
}

.cdd-ig-card__badge {
  font-size: 12px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.25);
  padding: 4px 12px;
  border-radius: 99px;
  letter-spacing: .05em;
  color: var(--cdd-amarillo);
}

.cdd-ig-card__badge--reel {
  background: rgba(232, 90, 160, 0.4);
  color: #FFFFFF;
}

.cdd-ig-card__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 17px;
  color: #FFFFFF;
  line-height: 1.2;
  margin: 4px 0;
}

.cdd-ig-card__action {
  font-size: 14px;
  font-weight: 800;
  color: #FFFFFF;
  background: var(--cdd-fucsia);
  padding: 6px 16px;
  border-radius: 99px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.cdd-ig-feed-oembed {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 20px;
  align-items: start;
}

.cdd-ig-embed-col {
  width: 100%;
  display: flex;
  justify-content: center;
}

.cdd-ig-embed-col blockquote.instagram-media {
  background: #ffffff !important;
  border-radius: 16px !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25) !important;
  margin: 0 !important;
  width: 100% !important;
  min-width: 100% !important;
}

@media (max-width: 900px) {
  .cdd-ig-feed-oembed {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* ---------- 3 pasos de compra ------------------------------------------ */
.cdd-steps { padding: 40px 0; }

.cdd-steps__heading {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 34px;
  line-height: 1.1;
  text-align: center;
  color: var(--cdd-chocolate);
  margin: 0 auto 26px;
  max-width: 760px;
  text-wrap: balance;
}

.cdd-steps__cta {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

.cdd-steps__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.cdd-step {
  background: #fff;
  border-radius: 14px;
  padding: 20px 22px;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-step__num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  /* Número oscuro sobre círculo de color: AA en los 3 (amarillo con blanco daba
     1.69:1). Chocolate sobre fucsia/amarillo/verde = 4.67 / 9.14 / 5.59. */
  color: var(--cdd-chocolate);
  font: 800 16px 'Baloo 2', cursive;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}

.cdd-step__num--1 { background: var(--cdd-fucsia); }
.cdd-step__num--2 { background: var(--cdd-amarillo); }
.cdd-step__num--3 { background: #4CAF6E; }

.cdd-step__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 18px;
  color: var(--cdd-chocolate);
  margin-bottom: 4px;
}

.cdd-step__text {
  font-size: 13.5px;
  line-height: 1.5;
  color: #7a5c40;
}

/* ---------- Reduced motion (home) -------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .hovlift, .hovdim, .catcard, .cdd-seg__btn {
    transition: none;
  }
  .hovlift:hover, .catcard:hover { transform: none; }
}

/* ---------- Responsive (home) ------------------------------------------ */
@media (max-width: 1100px) {
  .cdd-hero__title { font-size: 60px; }
  .cdd-best__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  .cdd-home__inner { padding-inline: 24px; }
  .cdd-hero { padding: 40px 0 32px; }
  .cdd-hero__title { font-size: 46px; }
  .cdd-best__grid { grid-template-columns: repeat(2, 1fr); }
  .cdd-ig { padding: 36px 0; }
  .cdd-ig__inner { gap: 28px; }
  .cdd-ig__number { font-size: 64px; }
  .cdd-steps__grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .cdd-hero__title { font-size: 38px; }
  .cdd-cat { flex: 1 1 130px; max-width: 100%; }
  .cdd-best__grid { grid-template-columns: repeat(2, 1fr); }
  .cdd-seg { flex-direction: column; }
  .cdd-best__head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .cdd-ig__tiles { grid-template-columns: repeat(3, 1fr); width: 100%; }
}

/* ------------------------------------------------------------------ */
/* Nota de precio mayorista referencial en la ficha de producto (Fase 4) */
/* ------------------------------------------------------------------ */
.cdd-mayor-ficha {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .4rem .6rem;
  margin: -.4rem 0 1.1rem;
  padding: .55rem .8rem;
  background: var(--cdd-crema2);
  border-left: 3px solid var(--cdd-fucsia);
  border-radius: 8px;
  font-size: .95rem;
}
.cdd-mayor-ficha .cdd-mayor__label {
  font-weight: 700;
  color: var(--cdd-fucsia-texto);
  text-transform: uppercase;
  letter-spacing: .02em;
  font-size: .78rem;
}
.cdd-mayor-ficha .cdd-mayor__price {
  font-weight: 700;
  color: var(--cdd-chocolate);
}
.cdd-mayor-ficha .cdd-mayor__hint {
  color: var(--cdd-texto-suave);
  font-size: .82rem;
}

/* =========================================================================
   CATÁLOGO / ARCHIVE 1b (Fase A · noche 2)
   Tienda (/shop) y categorías (/product-category/<slug>).
   Reutiliza .cdd-card / .cdd-seg del home; solo añade cabecera, chips,
   toolbar de orden, grilla y paginación.
   Fidelidad: .planning/specs/home-1b-referencia.html
   ========================================================================= */

/* ---------- Breadcrumb nativo Woo estilizado --------------------------- */
.woocommerce .woocommerce-breadcrumb {
  font-size: 13px;
  font-weight: 600;
  color: var(--cdd-texto-suave);
  margin: 4px 0 16px;
}
.woocommerce .woocommerce-breadcrumb a {
  color: var(--cdd-fucsia-texto);
  text-decoration: none;
}
.woocommerce .woocommerce-breadcrumb a:hover { text-decoration: underline; }

/* ---------- Cabecera branded ------------------------------------------- */
.cdd-shop-head { margin: 4px 0 24px; }

.cdd-shop-head__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.cdd-shop-head__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 42px;
  line-height: 1.02;
  color: var(--cdd-chocolate);
  margin: 0 0 6px;
}

.cdd-shop-head__showing {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--cdd-texto-suave);
  margin: 0;
}

/* Control de segmento compacto en el catálogo */
.cdd-seg-wrap.cdd-seg--compact { align-items: flex-end; }
.cdd-seg--compact .cdd-seg__btn { padding: 9px 20px; font-size: 14px; min-height: 42px; }
.cdd-seg--compact .cdd-seg__hint { text-align: right; max-width: 260px; }

/* ---------- Chips de categorías ---------------------------------------- */
.cdd-shop-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.cdd-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-left-width: 5px;
  border-radius: 999px;
  padding: 9px 16px;
  min-height: 42px;
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 800;
  font-size: 13.5px;
  color: var(--cdd-chocolate);
  text-decoration: none;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, color .16s ease;
}

.cdd-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(58, 30, 14, .14);
}

.cdd-chip.is-active {
  background: var(--cdd-chocolate);
  color: #F7F5F0;
  border-color: var(--cdd-chocolate);
}

.cdd-chip__count {
  font-size: 11px;
  font-weight: 700;
  opacity: .65;
}

/* Color de borde por categoría (coincide con las cards del home) */
.cdd-chip--todos      { border-left-color: var(--cdd-chocolate); }
.cdd-chip--gomitas    { border-left-color: #4CAF6E; }
.cdd-chip--chocolates { border-left-color: #7A3E22; }
.cdd-chip--dulces     { border-left-color: #E85AA0; }
.cdd-chip--galletas   { border-left-color: #F2C230; }
.cdd-chip--confites   { border-left-color: #8E5AA8; }
.cdd-chip--cotillon   { border-left-color: #E8730C; }
.cdd-chip--despensa   { border-left-color: #4A90D9; }

/* ---------- Toolbar: contador + orden ---------------------------------- */
.cdd-shop-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 4px;
  border-top: 1.5px solid var(--cdd-borde);
}

.cdd-shop-toolbar .woocommerce-result-count {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--cdd-texto-suave);
}

.cdd-shop-toolbar .woocommerce-ordering { margin: 0; }

.woocommerce .cdd-shop-toolbar select.orderby,
.cdd-shop-toolbar select.orderby {
  appearance: none;
  -webkit-appearance: none;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%235A2E17' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  border: 1.5px solid rgba(90, 46, 23, .25);
  border-radius: 999px;
  padding: 10px 38px 10px 16px;
  min-height: 44px;
  font: 700 13.5px 'Nunito Sans', sans-serif;
  color: var(--cdd-cafe);
  cursor: pointer;
}

/* ---------- Grilla del catálogo (reusa la card 1b) --------------------- */
.cdd-shop__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 0 0 8px;
  padding: 0;
  list-style: none;
}

/* Neutraliza restos de estilos Woo por si aparece ul.products en algún flujo */
.woocommerce .cdd-shop__grid::before,
.woocommerce .cdd-shop__grid::after { content: none; display: none; }

/* ---------- Paginación ------------------------------------------------- */
.woocommerce nav.woocommerce-pagination { margin: 28px 0 8px; text-align: center; }

.woocommerce nav.woocommerce-pagination ul {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  border: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}

.woocommerce nav.woocommerce-pagination ul li {
  border: 0;
  margin: 0;
  overflow: visible;
}

.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 999px;
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  color: var(--cdd-cafe);
  font: 800 14px 'Nunito Sans', sans-serif;
  text-decoration: none;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}

.woocommerce nav.woocommerce-pagination ul li span.current {
  background: var(--cdd-chocolate);
  color: #F7F5F0;
  border-color: var(--cdd-chocolate);
}

.woocommerce nav.woocommerce-pagination ul li a:hover {
  border-color: var(--cdd-fucsia);
  color: var(--cdd-fucsia-texto);
}

/* ---------- Reduced motion (catálogo) ---------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .cdd-chip { transition: none; }
  .cdd-chip:hover { transform: none; }
}

/* ---------- Responsive (catálogo) -------------------------------------- */
@media (max-width: 1100px) {
  .cdd-shop__grid { grid-template-columns: repeat(3, 1fr); }
  .cdd-shop-head__title { font-size: 34px; }
}

@media (max-width: 860px) {
  .cdd-shop__grid { grid-template-columns: repeat(2, 1fr); }
  .cdd-shop-head__top { align-items: flex-start; }
  .cdd-seg--compact .cdd-seg__hint { text-align: left; }
}

@media (max-width: 560px) {
  .cdd-shop-head__title { font-size: 28px; }
  .cdd-shop__grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .cdd-shop-toolbar { flex-direction: column; align-items: flex-start; gap: 10px; }
  .cdd-seg--compact .cdd-seg { width: 100%; }
  .cdd-seg--compact .cdd-seg__btn { flex: 1; }
}

/* =========================================================================
   FICHA DE PRODUCTO / SINGLE 1b (Fase B · noche 2)
   Layout 2 columnas (galería placeholder + info), precio Detalle/Mayorista
   que toglea con el selector, bloque mayorista referencial y relacionados.
   Reutiliza tokens/patrones del home y del catálogo.
   Fidelidad: .planning/specs/home-1b-referencia.html
   ========================================================================= */

/* ---------- Layout 2 columnas ------------------------------------------ */
.woocommerce div.product,
.woocommerce-page div.product {
  display: grid;
  grid-template-columns: minmax(0, 440px) minmax(0, 1fr);
  column-gap: 44px;
  row-gap: 8px;
  align-items: start;
}

/* La galería (placeholder o real) va a la columna 1; la info (summary) a la 2. */
.woocommerce div.product > .cdd-single__gallery,
.woocommerce div.product > .woocommerce-product-gallery {
  grid-column: 1;
  grid-row: 1;
  width: auto;
  max-width: 100%;
  float: none;
  margin: 0;
}

.woocommerce div.product > .summary,
.woocommerce div.product > .entry-summary {
  grid-column: 2;
  grid-row: 1;
  width: auto;
  float: none;
  margin: 0;
}

/* Tabs, up-sells y relacionados: fila inferior a todo el ancho. */
.woocommerce div.product > .woocommerce-tabs,
.woocommerce div.product > .up-sells,
.woocommerce div.product > .related {
  grid-column: 1 / -1;
  width: auto;
  float: none;
}

/* ---------- Galería placeholder (consistente con las cards) ------------ */
.cdd-single__media {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  background: repeating-linear-gradient(45deg, #EFE8D8 0 16px, #F7F3EA 16px 32px);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

/* Imagen de la ficha (real o placeholder branded — Fase D). */
.cdd-single__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cdd-single__media-label {
  font: 13px ui-monospace, Menlo, monospace;
  color: #9c8b74;
}

/* ---------- Miniaturas del carrito / mini-cart (placeholder branded) ---- */
.cdd-cart-thumb {
  width: 100%;
  height: 100%;
  max-width: 72px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
  display: block;
}

.cdd-single__media-disclaimer {
  display: flex;
  align-items: center;
  gap: 6px;
  clear: both;
  margin-top: 10px;
  padding: 4px 2px;
  font-size: 11.5px;
  line-height: 1.45;
  color: #7A6959;
  font-weight: 500;
  letter-spacing: 0.01em;
  font-family: 'Nunito Sans', system-ui, -apple-system, sans-serif;
}

.cdd-single__disclaimer-icon {
  flex-shrink: 0;
  color: #A38C76;
}

/* ---------- Columna de info -------------------------------------------- */
.cdd-single__chip {
  margin-bottom: 14px;
  cursor: pointer;
}

.woocommerce div.product .product_title,
.woocommerce div.product .summary .product_title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 34px;
  line-height: 1.08;
  color: var(--cdd-chocolate);
  margin: 0 0 14px;
}

/* Bloque de precio grande (toglea con el selector) */
.cdd-single__price {
  margin: 0 0 6px;
}

.cdd-single__price-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  color: var(--cdd-texto-suave);
  margin-bottom: 2px;
}

/* Reutiliza el badge "referencial" de la card en el label del precio */
.cdd-single__price-label .cdd-card__ref { font-size: 10px; }

.cdd-single__price-main {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 40px;
  line-height: 1.05;
  color: var(--cdd-chocolate);
}

.cdd-single__price-unit {
  font-family: 'Nunito Sans', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--cdd-texto-suave);
}

.cdd-single__price-sub {
  margin-top: 4px;
  font-size: 14px;
  font-weight: 600;
  color: #7a5c40;
}

/* Bloque mayorista referencial: detalle de caja en línea aparte */
.cdd-mayor-ficha .cdd-mayor__caja {
  flex-basis: 100%;
  font-size: .85rem;
  font-weight: 600;
  color: var(--cdd-cafe);
}

/* Selector en la ficha: alineado a la izquierda bajo el precio */
.cdd-seg--single { align-items: flex-start; margin: 4px 0 20px; }
.cdd-seg--single .cdd-seg__hint { text-align: left; max-width: none; }

/* ---------- Cantidad + Agregar al carrito ------------------------------ */
.woocommerce div.product form.cart {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 0 22px;
}

.woocommerce div.product form.cart .quantity {
  margin: 0;
}

.woocommerce div.product form.cart .quantity input.qty {
  width: 78px;
  height: 52px;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 12px;
  background: #fff;
  font: 800 16px 'Nunito Sans', sans-serif;
  color: var(--cdd-chocolate);
  text-align: center;
}

.woocommerce div.product form.cart .button,
.woocommerce div.product form.cart button.single_add_to_cart_button {
  background: var(--cdd-fucsia);
  color: var(--cdd-chocolate);
  border: 0;
  border-radius: 999px;
  padding: 0 34px;
  min-height: 52px;
  font: 800 16px 'Nunito Sans', sans-serif;
  text-transform: none;
  letter-spacing: 0;
  transition: background .16s ease, transform .16s ease;
}

.woocommerce div.product form.cart .button:hover,
.woocommerce div.product form.cart button.single_add_to_cart_button:hover {
  background: var(--cdd-fucsia-hover);
  transform: translateY(-1px);
}

/* Descripción corta */
.woocommerce div.product .woocommerce-product-details__short-description {
  font-size: 15px;
  line-height: 1.6;
  color: var(--cdd-cafe);
  margin-bottom: 18px;
}

/* Meta (SKU / categoría) */
.woocommerce div.product .product_meta {
  font-size: 13px;
  color: var(--cdd-texto-suave);
  border-top: 1.5px solid var(--cdd-borde);
  padding-top: 14px;
}
.woocommerce div.product .product_meta a { color: var(--cdd-fucsia-texto); text-decoration: none; }
.woocommerce div.product .product_meta a:hover { text-decoration: underline; }

/* ---------- Relacionados ----------------------------------------------- */
.woocommerce .related.products,
.woocommerce .up-sells {
  margin-top: 44px;
  padding-top: 28px;
  border-top: 1.5px solid var(--cdd-borde);
}

.woocommerce .related.products > h2,
.woocommerce .up-sells > h2 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 26px;
  color: var(--cdd-chocolate);
  margin: 0 0 20px;
}

/* Tabs nativas: si aparecen (descripción/valoraciones), tono 1b discreto */
.woocommerce div.product .woocommerce-tabs { margin-top: 40px; }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: var(--cdd-fucsia-texto); }

/* ---------- Responsive (ficha) ----------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .woocommerce div.product form.cart button.single_add_to_cart_button { transition: none; }
  .woocommerce div.product form.cart button.single_add_to_cart_button:hover { transform: none; }
}

@media (max-width: 860px) {
  .woocommerce div.product,
  .woocommerce-page div.product {
    grid-template-columns: 1fr;
    row-gap: 24px;
  }
  .woocommerce div.product > .cdd-single__gallery,
  .woocommerce div.product > .woocommerce-product-gallery { grid-column: 1; grid-row: 1; }
  .woocommerce div.product > .summary,
  .woocommerce div.product > .entry-summary { grid-column: 1; grid-row: 2; }
  .cdd-single__media { max-width: 420px; }
  .woocommerce div.product .product_title { font-size: 28px; }
  .cdd-single__price-main { font-size: 34px; }
}

@media (max-width: 560px) {
  .woocommerce div.product form.cart { gap: 10px; }
  .woocommerce div.product form.cart .quantity,
  .woocommerce div.product form.cart .button,
  .woocommerce div.product form.cart button.single_add_to_cart_button { flex: 1 1 auto; }
  .woocommerce div.product form.cart .quantity input.qty { width: 100%; }
}

/* =========================================================================
   CARRITO · CHECKOUT · PEDIDO RECIBIDO · MI CUENTA (Fase C · noche 2)
   Estiliza el flujo de compra clásico de WooCommerce al lenguaje 1b sin
   reimplementarlo (se mantienen Transferencia bancaria + Retiro en tienda).
   Reutiliza tokens del home/catálogo. Fidelidad: home-1b-referencia.html
   ========================================================================= */

/* ---------- Botones WooCommerce genéricos (pill de marca) --------------- */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
  background: var(--cdd-cafe);
  color: #F7F5F0;
  border: 0;
  border-radius: 999px;
  padding: 12px 26px;
  min-height: 48px;
  font: 800 14.5px 'Nunito Sans', sans-serif;
  text-transform: none;
  letter-spacing: 0;
  line-height: 1.2;
  transition: filter .16s ease, transform .16s ease, background .16s ease;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover {
  filter: brightness(.94);
  transform: translateY(-1px);
  color: #F7F5F0;
}

/* Botones de acción primaria (finalizar compra / realizar pedido) en fucsia */
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.woocommerce #place_order,
.woocommerce .wc-proceed-to-checkout a.checkout-button {
  background: var(--cdd-fucsia);
  color: var(--cdd-chocolate);
}

.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover,
.woocommerce #place_order:hover,
.woocommerce .wc-proceed-to-checkout a.checkout-button:hover {
  background: var(--cdd-fucsia-hover);
  color: var(--cdd-chocolate);
}

/* ---------- Avisos de WooCommerce (message / info / error) -------------- */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce-noreviews,
.woocommerce p.cart-empty {
  border-radius: 12px;
  border: 0;
  border-left: 5px solid var(--cdd-fucsia);
  background: #fff;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
  color: var(--cdd-chocolate);
  font-weight: 600;
}

.woocommerce-message::before,
.woocommerce-info::before,
.woocommerce-error::before { color: var(--cdd-fucsia-texto); }

.woocommerce-message { border-left-color: #4CAF6E; }
.woocommerce-message::before { color: #4CAF6E; }
.woocommerce-error { border-left-color: #B23A78; }
.woocommerce-error::before { color: #B23A78; }

.woocommerce-message .button,
.woocommerce-info .button {
  min-height: 40px;
  padding: 9px 18px;
}

/* ---------- Tablas WooCommerce (base común) ---------------------------- */
.woocommerce table.shop_table {
  border-radius: 14px;
  border: 1.5px solid var(--cdd-borde);
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  overflow: hidden;
}

.woocommerce table.shop_table th {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 800;
  color: var(--cdd-cafe);
}

.woocommerce table.shop_table td { color: var(--cdd-chocolate); }

.woocommerce table.shop_table thead th {
  background: var(--cdd-crema2);
  font-size: 12.5px;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* =========================================================================
   CARRITO (/cart)
   ========================================================================= */

.woocommerce-cart .woocommerce {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 32px;
  align-items: start;
}

/* El clearfix ::before/::after de .woocommerce se convertiría en ítem del grid
   y robaría celdas (descuadra las columnas). Se neutraliza en los contenedores
   que convertimos a grid (carrito y mi cuenta). */
.woocommerce-cart .woocommerce::before,
.woocommerce-cart .woocommerce::after,
.woocommerce-account.logged-in .woocommerce::before,
.woocommerce-account.logged-in .woocommerce::after {
  content: none;
  display: none;
}

/* La barra de avisos (agregado/actualizado) ocupa el ancho completo */
.woocommerce-cart .woocommerce > .woocommerce-notices-wrapper { grid-column: 1 / -1; }

.woocommerce-cart form.woocommerce-cart-form { margin: 0; min-width: 0; }
.woocommerce-cart .cart-collaterals { width: auto; float: none; margin: 0; min-width: 0; }
.woocommerce-cart .cart-collaterals .cart_totals { width: auto; float: none; }

.woocommerce-cart table.cart .product-thumbnail img {
  width: 66px;
  height: 66px;
  border-radius: 10px;
  object-fit: cover;
}

.woocommerce-cart table.cart td.product-name a {
  color: var(--cdd-chocolate);
  font-weight: 700;
  text-decoration: none;
}
.woocommerce-cart table.cart td.product-name a:hover { color: var(--cdd-fucsia-texto); }

.woocommerce-cart table.cart a.remove {
  color: var(--cdd-fucsia-texto) !important;
  border: 1.5px solid var(--cdd-borde);
  font-weight: 700;
}
.woocommerce-cart table.cart a.remove:hover {
  background: var(--cdd-fucsia) !important;
  color: var(--cdd-chocolate) !important;
}

/* Input de cantidad tipo 1b */
.woocommerce .quantity input.qty {
  width: 72px;
  height: 46px;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 10px;
  background: #fff;
  font: 800 15px 'Nunito Sans', sans-serif;
  color: var(--cdd-chocolate);
  text-align: center;
}

/* Fila de acciones: cupón + actualizar + seguir comprando */
.woocommerce-cart table.cart td.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  background: var(--cdd-crema);
}

.woocommerce-cart table.cart td.actions .coupon {
  display: flex;
  gap: 8px;
  align-items: center;
  margin: 0;
  flex-wrap: wrap;
}

.woocommerce-cart table.cart td.actions .coupon .input-text {
  height: 46px;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 999px;
  padding: 0 18px;
  min-width: 160px;
  font: 600 14px 'Nunito Sans', sans-serif;
  color: var(--cdd-chocolate);
  background: #fff;
}

.woocommerce-cart table.cart td.actions button[name="update_cart"] {
  background: #fff;
  color: var(--cdd-cafe);
  border: 1.5px solid rgba(90, 46, 23, .25);
}
.woocommerce-cart table.cart td.actions button[name="update_cart"]:hover {
  background: var(--cdd-crema2);
  color: var(--cdd-cafe);
}

/* "Seguir comprando" — pill outline, empujado a la derecha */
.woocommerce-cart .cdd-cart__continue {
  margin-left: auto;
  background: transparent !important;
  color: var(--cdd-cafe) !important;
  border: 2px solid var(--cdd-cafe) !important;
}
.woocommerce-cart .cdd-cart__continue:hover {
  background: var(--cdd-cafe) !important;
  color: #F7F5F0 !important;
}

/* Totales del carrito como tarjeta */
.woocommerce-cart .cart_totals {
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 16px;
  padding: 22px 22px 20px;
  box-shadow: 0 2px 10px rgba(58, 30, 14, .08);
}

.woocommerce-cart .cart_totals h2 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 22px;
  color: var(--cdd-chocolate);
  margin: 0 0 14px;
}

.woocommerce-cart .cart_totals table.shop_table {
  border: 0;
  border-radius: 0;
}
.woocommerce-cart .cart_totals table.shop_table th,
.woocommerce-cart .cart_totals table.shop_table td {
  border-top: 1px solid var(--cdd-borde);
  padding: 12px 0;
  background: transparent;
}
.woocommerce-cart .cart_totals table.shop_table thead { display: none; }
.woocommerce-cart .cart_totals tr.order-total th,
.woocommerce-cart .cart_totals tr.order-total td {
  font-size: 18px;
  color: var(--cdd-chocolate);
}
.woocommerce-cart .cart_totals tr.order-total .amount { color: var(--cdd-fucsia-texto); }

.woocommerce-cart .wc-proceed-to-checkout { padding: 16px 0 0; }
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button {
  display: block;
  text-align: center;
  font-size: 16px;
  min-height: 52px;
  line-height: 52px;
  padding: 0 20px;
}

/* Nota transferencia/retiro bajo los totales */
.cdd-cart-note {
  margin-top: 16px;
  padding: 14px 16px;
  background: var(--cdd-crema2);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cdd-cart-note__item {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
  color: var(--cdd-cafe);
}
.cdd-cart-note__item b { color: var(--cdd-chocolate); }
.cdd-cart-note__ico { font-size: 17px; line-height: 1.2; flex: none; }

/* Carrito vacío */
.woocommerce .cart-empty.woocommerce-info { font-size: 16px; }
.woocommerce .return-to-shop { margin-top: 18px; }

/* ---------- Estados AJAX de la card (agregar desde el catálogo) --------- */
.cdd-card__add.loading { opacity: .75; }
.cdd-card__add.added { pointer-events: none; }
.cdd-card .added_to_cart {
  display: inline-block;
  margin-top: 6px;
  font: 700 12.5px 'Nunito Sans', sans-serif;
  color: var(--cdd-fucsia-texto);
  text-align: center;
  text-decoration: none;
}
.cdd-card .added_to_cart:hover { text-decoration: underline; }

/* =========================================================================
   CHECKOUT (/checkout)
   ========================================================================= */

/* Banda de mensajería (transferencia + retiro) */
.cdd-checkout-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 0 0 26px;
}
.cdd-checkout-info__card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-left: 5px solid var(--cdd-fucsia);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}
.cdd-checkout-info__card:nth-child(2) { border-left-color: var(--cdd-amarillo); }
.cdd-checkout-info__ico { font-size: 24px; line-height: 1; flex: none; }
.cdd-checkout-info__title {
  display: block;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 16px;
  color: var(--cdd-chocolate);
  margin-bottom: 2px;
}
.cdd-checkout-info__text {
  display: block;
  font-size: 13px;
  line-height: 1.45;
  color: var(--cdd-cafe);
}

/* Layout de columnas del checkout */
.woocommerce-checkout .col2-set { width: 100%; }
.woocommerce-checkout form.checkout .col2-set .col-1,
.woocommerce-checkout form.checkout .col2-set .col-2 { width: 100%; float: none; }

/* Encabezados de sección */
.woocommerce-checkout h3,
.woocommerce-checkout #order_review_heading {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 22px;
  color: var(--cdd-chocolate);
  margin: 0 0 14px;
}
.cdd-checkout-review__eyebrow {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--cdd-texto-suave);
  margin: 0 0 2px;
}

/* Campos del formulario */
.woocommerce form .form-row label,
.woocommerce-checkout .woocommerce-billing-fields label {
  font-weight: 700;
  font-size: 13.5px;
  color: var(--cdd-cafe);
}
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce-checkout select,
.select2-container .select2-selection--single {
  border: 1.5px solid var(--cdd-borde);
  border-radius: 12px;
  background: #fff;
  min-height: 48px;
  padding: 10px 14px;
  font: 600 15px 'Nunito Sans', sans-serif;
  color: var(--cdd-chocolate);
  box-shadow: none;
}
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce-checkout select:focus {
  outline: 3px solid var(--cdd-fucsia-texto);
  outline-offset: 1px;
  border-color: var(--cdd-fucsia);
}
.select2-container--default .select2-selection--single { height: 48px; }
.select2-container--default .select2-selection--single .select2-selection__rendered {
  line-height: 46px;
  color: var(--cdd-chocolate);
}
.select2-container--default .select2-selection--single .select2-selection__arrow { height: 46px; }

/* Resumen del pedido (order review) */
.woocommerce-checkout #order_review {
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 16px;
  padding: 22px;
  box-shadow: 0 2px 10px rgba(58, 30, 14, .08);
}
.woocommerce-checkout table.woocommerce-checkout-review-order-table { border: 0; }
.woocommerce-checkout table.woocommerce-checkout-review-order-table thead th {
  background: transparent;
  border-bottom: 1.5px solid var(--cdd-borde);
}
.woocommerce-checkout table.woocommerce-checkout-review-order-table td,
.woocommerce-checkout table.woocommerce-checkout-review-order-table th {
  padding: 12px 0;
}
.woocommerce-checkout table.woocommerce-checkout-review-order-table tfoot .order-total th,
.woocommerce-checkout table.woocommerce-checkout-review-order-table tfoot .order-total td {
  font-size: 17px;
  color: var(--cdd-chocolate);
}
.woocommerce-checkout .order-total .amount { color: var(--cdd-fucsia-texto); }

/* Métodos de pago (BACS) */
.woocommerce-checkout #payment,
.woocommerce-checkout ul.payment_methods {
  background: transparent;
  border: 0;
}
.woocommerce-checkout ul.payment_methods {
  border-top: 1.5px solid var(--cdd-borde);
  padding: 16px 0 0;
}
.woocommerce-checkout ul.payment_methods li { list-style: none; }
.woocommerce-checkout ul.payment_methods label {
  font-weight: 800;
  color: var(--cdd-chocolate);
}
.woocommerce-checkout #payment div.payment_box {
  background: var(--cdd-crema2);
  border-radius: 12px;
  color: var(--cdd-cafe);
  font-size: 13.5px;
}
.woocommerce-checkout #payment div.payment_box::before { border-bottom-color: var(--cdd-crema2); }
.woocommerce-checkout #payment .place-order { padding: 16px 0 0; }
.woocommerce-checkout #place_order {
  width: 100%;
  font-size: 16px;
  min-height: 54px;
}

/* Métodos de envío (retiro en tienda) */
.woocommerce-checkout #shipping_method li { list-style: none; }
.woocommerce-checkout .woocommerce-shipping-methods label { color: var(--cdd-chocolate); font-weight: 700; }

/* =========================================================================
   PEDIDO RECIBIDO (thank-you)
   ========================================================================= */

.cdd-thankyou {
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-top: 5px solid var(--cdd-fucsia);
  border-radius: 16px;
  padding: 30px 28px;
  margin: 0 0 28px;
  box-shadow: 0 2px 10px rgba(58, 30, 14, .08);
  text-align: center;
}
.cdd-thankyou__emoji { font-size: 44px; display: block; line-height: 1; }
.cdd-thankyou__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 30px;
  color: var(--cdd-chocolate);
  margin: 10px 0 6px;
}
.cdd-thankyou__lead {
  font-size: 15px;
  color: var(--cdd-cafe);
  margin: 0 0 18px;
}
.cdd-thankyou__steps {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  max-width: 520px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cdd-thankyou__steps li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: var(--cdd-crema);
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--cdd-cafe);
}
.cdd-thankyou__steps li b { color: var(--cdd-chocolate); }
.cdd-thankyou__step-ico { font-size: 20px; line-height: 1.2; flex: none; }

/* Resumen del pedido (overview) */
.woocommerce ul.order_details {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  background: var(--cdd-crema2);
  border-radius: 14px;
  padding: 18px 20px;
  margin: 0 0 26px;
}
.woocommerce ul.order_details li {
  border: 0;
  padding: 0 18px 0 0;
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--cdd-texto-suave);
}
.woocommerce ul.order_details li strong {
  display: block;
  margin-top: 3px;
  font-size: 16px;
  text-transform: none;
  letter-spacing: 0;
  color: var(--cdd-chocolate);
}

/* Datos bancarios BACS */
.woocommerce .woocommerce-order .woocommerce-bacs-bank-details,
.woocommerce-order-received .woocommerce-bacs-bank-details {
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-left: 5px solid var(--cdd-amarillo);
  border-radius: 14px;
  padding: 18px 20px;
  margin: 0 0 26px;
}
.woocommerce .wc-bacs-bank-details-heading,
.woocommerce h2.wc-bacs-bank-details-account-name {
  font-family: 'Baloo 2', cursive;
  color: var(--cdd-chocolate);
}

/* Detalle del pedido + direcciones */
.woocommerce .woocommerce-order-details__title,
.woocommerce .woocommerce-column__title,
.woocommerce-customer-details h2 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 20px;
  color: var(--cdd-chocolate);
}

/* =========================================================================
   MI CUENTA (shortcode clásico)
   ========================================================================= */

/* Introducción sobre login/registro */
.cdd-account-intro { margin: 0 0 24px; }
.cdd-account-intro__eyebrow {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--cdd-texto-suave);
}
.cdd-account-intro__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 34px;
  color: var(--cdd-chocolate);
  margin: 4px 0 8px;
}
.cdd-account-intro__text {
  font-size: 15px;
  color: var(--cdd-cafe);
  max-width: 540px;
  margin: 0;
}

/* Formularios de login/registro como tarjetas */
.woocommerce-account .woocommerce > .u-columns#customer_login {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.woocommerce-account #customer_login .u-column1,
.woocommerce-account #customer_login .u-column2 { width: auto; float: none; }
.woocommerce-account form.login,
.woocommerce-account form.register {
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 2px 10px rgba(58, 30, 14, .08);
}
.woocommerce-account #customer_login h2 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 22px;
  color: var(--cdd-chocolate);
}

/* Panel de mi cuenta: navegación + contenido */
.woocommerce-account .woocommerce {
  display: grid;
  grid-template-columns: minmax(200px, 240px) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}
.woocommerce-account .woocommerce > .woocommerce-notices-wrapper { grid-column: 1 / -1; }
/* Cuando NO hay sesión (login/registro) el grid de 2 col no aplica */
.woocommerce-account:not(.logged-in) .woocommerce { display: block; }

/* Especificidad .woocommerce-account para vencer los float/width nativos de Woo */
.woocommerce-account .woocommerce-MyAccount-navigation {
  width: auto;
  float: none;
}
.woocommerce-MyAccount-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.woocommerce-MyAccount-navigation ul li { margin: 0; border: 0; }
.woocommerce-MyAccount-navigation ul li a {
  display: block;
  padding: 12px 16px;
  border-radius: 10px;
  background: #fff;
  border: 1.5px solid var(--cdd-borde);
  color: var(--cdd-cafe);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  transition: background .16s ease, color .16s ease, border-color .16s ease;
}
.woocommerce-MyAccount-navigation ul li a:hover {
  border-color: var(--cdd-fucsia);
  color: var(--cdd-fucsia-texto);
}
.woocommerce-MyAccount-navigation ul li.is-active a {
  background: var(--cdd-chocolate);
  color: #F7F5F0;
  border-color: var(--cdd-chocolate);
}

.woocommerce-account .woocommerce-MyAccount-content { width: auto; float: none; min-width: 0; }
.woocommerce-MyAccount-content .woocommerce-Address-title h3,
.woocommerce-MyAccount-content h2,
.woocommerce-MyAccount-content h3 {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  color: var(--cdd-chocolate);
}

/* Tabla de pedidos en mi cuenta */
.woocommerce-account table.woocommerce-orders-table td,
.woocommerce-account table.woocommerce-orders-table th { padding: 12px; }
.woocommerce-account table.woocommerce-orders-table .button {
  min-height: 40px;
  padding: 8px 16px;
  font-size: 13px;
}

/* =========================================================================
   Responsive (Fase C)
   ========================================================================= */
@media (max-width: 980px) {
  .woocommerce-cart .woocommerce { grid-template-columns: 1fr; }
  .woocommerce-account .woocommerce { grid-template-columns: 1fr; }
  .woocommerce-MyAccount-navigation ul { flex-direction: row; flex-wrap: wrap; }
  .woocommerce-MyAccount-navigation ul li a { padding: 10px 14px; }
}

@media (max-width: 780px) {
  .cdd-checkout-info { grid-template-columns: 1fr; }
  .woocommerce-account .woocommerce > .u-columns#customer_login { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .woocommerce-cart table.cart td.actions {
    flex-direction: column;
    align-items: stretch;
  }
  .woocommerce-cart table.cart td.actions .coupon { justify-content: space-between; }
  .woocommerce-cart table.cart td.actions .coupon .input-text { flex: 1; min-width: 0; }
  .woocommerce-cart .cdd-cart__continue { margin-left: 0; text-align: center; }
}

/* ---------- Reduced motion (Fase C) ------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .woocommerce #place_order,
  .woocommerce .wc-proceed-to-checkout a.checkout-button,
  .woocommerce-MyAccount-navigation ul li a { transition: none; }
  .woocommerce a.button:hover,
  .woocommerce button.button:hover { transform: none; }
}

/* ============================================================================
   Reveal al scroll + stagger de cards (T5)
   ----------------------------------------------------------------------------
   El estado oculto lo aplica anim.js (clase .cdd-reveal). Sin JS, esta clase
   nunca se añade → todo el contenido queda visible. Solo se anima opacity y
   transform (compositor): sin CLS ni jank. --cdd-delay lo setea el JS para el
   escalonado de las grillas.
   ========================================================================== */
.cdd-reveal {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity .55s cubic-bezier(.16, 1, .3, 1),
    transform .55s cubic-bezier(.16, 1, .3, 1);
  transition-delay: var(--cdd-delay, 0ms);
  will-change: opacity, transform;
}

.cdd-reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Reduced motion: neutraliza cualquier reveal (belt-and-suspenders; anim.js ya
   sale temprano y ni siquiera añade .cdd-reveal si el usuario lo pide). */
@media (prefers-reduced-motion: reduce) {
  .cdd-reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* =========================================================================
   PÁGINAS DE CONTENIDO (T6)
   Mayoristas · Cómo comprar · Ubicación. Reutilizan tokens, .cdd-home__inner,
   .cdd-scallop, .cdd-steps y utilidades de interacción del home 1b. Solo se
   añade lo específico de estas páginas (hero de sección, feat cards, notas,
   info del local, bloque de mapa y banda CTA de cierre).
   ========================================================================= */

/* Ancho completo: neutraliza el contenedor de GeneratePress (igual que la home) */
.cdd-content-page #page,
.cdd-content-page #content,
.cdd-content-page .site-content {
  max-width: 100%;
  padding: 0;
  margin: 0;
}

.cdd-page { width: 100%; }

/* ---------- Hero de sección ------------------------------------------- */
.cdd-page-hero {
  padding: 52px 0 40px;
  text-align: center;
  background: var(--cdd-crema);
}

.cdd-page-hero__eyebrow {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .18em;
  color: var(--cdd-texto-suave);
  margin: 0 0 14px;
}

.cdd-page-hero__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: 58px;
  line-height: 1;
  color: var(--cdd-chocolate);
  margin: 0 auto;
  max-width: 820px;
  text-wrap: balance;
}

.cdd-page-hero__sub {
  font-size: 17px;
  line-height: 1.55;
  color: #5a4632;
  margin: 18px auto 0;
  max-width: 620px;
}

/* ---------- Secciones ------------------------------------------------- */
.cdd-page-section { padding: 40px 0; }
.cdd-page-section--tint { background: var(--cdd-crema2); }

.cdd-page-section__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 28px;
  color: var(--cdd-chocolate);
  margin: 0 0 22px;
  text-align: center;
}

/* ---------- Feat cards (ventajas / notas) ----------------------------- */
.cdd-feats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.cdd-feat {
  background: #fff;
  border-radius: 14px;
  border-top: 5px solid var(--cdd-fucsia);
  padding: 24px 22px 22px;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-feat__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--cdd-crema);
  font-size: 26px;
  margin-bottom: 14px;
}

.cdd-feat__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 19px;
  color: var(--cdd-chocolate);
  margin: 0 0 6px;
}

.cdd-feat__text {
  font-size: 14px;
  line-height: 1.55;
  color: #7a5c40;
  margin: 0;
}

/* ---------- Nota / callout referencial -------------------------------- */
.cdd-note {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .4rem .6rem;
  margin: 24px auto 0;
  max-width: 820px;
  padding: 14px 18px;
  background: #fff;
  border-left: 4px solid var(--cdd-amarillo);
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.55;
  color: #6b5238;
}

.cdd-note--inline { margin-top: 12px; }

.cdd-note__badge {
  flex: none;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--cdd-chocolate);
  background: var(--cdd-amarillo);
  border-radius: 5px;
  padding: 2px 8px;
}

/* ---------- Ubicación: info del local + mapa -------------------------- */
.cdd-ubi {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 22px;
  align-items: start;
}

.cdd-ubi__info {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cdd-infocard {
  display: flex;
  gap: 14px;
  background: #fff;
  border-radius: 14px;
  padding: 20px 22px;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-infocard__icon {
  flex: none;
  font-size: 24px;
  line-height: 1.2;
}

.cdd-infocard__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 18px;
  color: var(--cdd-chocolate);
  margin: 0 0 6px;
}

.cdd-infocard__text {
  font-size: 14px;
  line-height: 1.55;
  color: #7a5c40;
  margin: 0;
}

.cdd-link-maps {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  font-weight: 800;
  color: var(--cdd-fucsia-texto);
  text-decoration: none;
}

.cdd-link-maps:hover { text-decoration: underline; }

/* Horario desglosado */
.cdd-hours {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cdd-hours li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 7px 0;
  border-bottom: 1px solid var(--cdd-borde);
  font-size: 14px;
}

.cdd-hours li:last-child { border-bottom: 0; }
.cdd-hours__day { font-weight: 700; color: var(--cdd-cafe); }
.cdd-hours__time { color: #7a5c40; font-weight: 600; }

/* Bloque mapa: placeholder branded que enlaza a Google Maps (sin iframe/CSP) */
.cdd-map {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 320px;
  height: 100%;
  padding: 32px;
  text-align: center;
  text-decoration: none;
  border-radius: 16px;
  color: #F7F5F0;
  background:
    radial-gradient(circle at 20% 20%, rgba(232, 90, 160, .28), transparent 42%),
    radial-gradient(circle at 80% 80%, rgba(242, 194, 48, .26), transparent 46%),
    var(--cdd-cafe);
  border: 1px solid rgba(255, 255, 255, .08);
  transition: transform .16s ease, box-shadow .16s ease;
}

.cdd-map:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 26px rgba(58, 30, 14, .22);
}

.cdd-map__pin { font-size: 46px; line-height: 1; }

.cdd-map__addr {
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 19px;
  max-width: 280px;
}

.cdd-map__cta {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .02em;
  color: var(--cdd-amarillo);
}

/* ---------- Confianza: "Nuestros emprendedores nos respaldan" ----------- */
.cdd-trust { padding: 56px 0; }

.cdd-trust__title {
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  font-size: clamp(30px, 4.2vw, 52px);
  line-height: 1.35;
  text-align: center;
  text-transform: uppercase;
  color: #fff;
  margin: 0 0 40px;
}

/* Cada línea roja es un bloque propio, una debajo de la otra y separadas. */
.cdd-trust__title span {
  display: block;
  width: fit-content;
  margin: 0 auto 14px;
  background: linear-gradient(180deg, #c93a3a, #a82424);
  padding: 4px 16px;
  text-shadow: 0 3px 10px rgba(0, 0, 0, .35);
}
.cdd-trust__title span:last-child { margin-bottom: 0; }
.cdd-trust__title br { display: none; }

.cdd-trust__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1080px;
  margin: 0 auto;
}

.cdd-trust__card {
  background: var(--cdd-chocolate);
  border-radius: 6px;
  padding: 28px 26px 30px;
  text-transform: uppercase;
  font-family: 'Baloo 2', cursive;
  font-weight: 800;
  line-height: 1.05;
  box-shadow: 0 6px 18px rgba(58, 30, 14, .25);
}

.cdd-trust__row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.cdd-trust__num {
  font-size: 76px;
  line-height: .9;
  color: #F7F0DC;
  text-shadow: 0 3px 8px rgba(0, 0, 0, .4);
}

.cdd-trust__sm { font-size: 18px; color: var(--cdd-amarillo); }
.cdd-trust__y1 { font-size: 30px; color: var(--cdd-amarillo); margin-top: 6px; }
.cdd-trust__y2 { font-size: 19px; color: var(--cdd-amarillo); margin-top: 8px; }
.cdd-trust__w  { font-size: 32px; color: #F7F0DC; margin-top: 6px; text-shadow: 0 2px 6px rgba(0, 0, 0, .35); }

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

/* ---------- Quiénes somos --------------------------------------------- */
.cdd-about__cover {
  margin: 0;
  line-height: 0;
}

.cdd-about__cover img {
  width: 100%;
  height: clamp(260px, 32vw, 480px);
  object-fit: cover;
  object-position: center 45%;
  display: block;
}

.cdd-about__story {
  max-width: 820px;
  margin: 0 auto;
}

.cdd-about__story p {
  font-size: 18px;
  line-height: 1.7;
  color: #5a4632;
  margin: 0 0 18px;
}

.cdd-about__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.cdd-about__grid .cdd-feat__text {
  font-size: 16px;
  line-height: 1.65;
}

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

/* Mapa embebido de Google Maps */
.cdd-map-embed {
  border-radius: 16px;
  overflow: hidden;
  min-height: 380px;
  height: 100%;
  background: var(--cdd-crema2);
  box-shadow: 0 1px 4px rgba(58, 30, 14, .12);
}

.cdd-map-embed iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 380px;
  border: 0;
}

/* ---------- Botón sólido fucsia (CTA de páginas) ---------------------- */
.cdd-btn-solid {
  background: var(--cdd-fucsia);
  color: var(--cdd-chocolate);
  border: 0;
  border-radius: 999px;
  padding: 14px 34px;
  font: 800 15px 'Nunito Sans', sans-serif;
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

/* ---------- Banda CTA de cierre --------------------------------------- */
.cdd-page-cta {
  background: var(--cdd-chocolate);
  padding: 44px 0;
}

.cdd-page-cta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.cdd-page-cta__title {
  margin: 0;
  font-family: 'Baloo 2', cursive;
  font-weight: 700;
  font-size: 26px;
  color: #F7F5F0;
}

/* ---------- Reduced motion (páginas) ---------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .cdd-map { transition: none; }
  .cdd-map:hover { transform: none; }
}

/* ---------- Responsive (páginas) -------------------------------------- */
@media (max-width: 1100px) {
  .cdd-page-hero__title { font-size: 48px; }
}

@media (max-width: 860px) {
  .cdd-page-hero__title { font-size: 40px; }
  .cdd-feats { grid-template-columns: 1fr; }
  .cdd-ubi { grid-template-columns: 1fr; }
  .cdd-map { min-height: 240px; }
  .cdd-page-cta__inner { flex-direction: column; text-align: center; }
}

@media (max-width: 560px) {
  .cdd-page-hero__title { font-size: 34px; }
  .cdd-page-hero { padding: 40px 0 32px; }
}

/* =========================================================================
   FORMULARIO DE CONTACTO (T7)
   Sección branded en la página Ubicación. Mismo lenguaje visual que las
   páginas de contenido 1b: inputs sobre crema, foco fucsia (coherente con
   .cdd-search__input), botón pill fucsia (.cdd-btn-solid). Responsive y
   respeta prefers-reduced-motion.
   ========================================================================= */

.cdd-contacto {
  max-width: 640px;
  margin: 0 auto;
  background: #fff;
  border-radius: 16px;
  border-top: 5px solid var(--cdd-fucsia);
  padding: 28px 26px 30px;
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-contacto__row {
  margin-bottom: 16px;
}

.cdd-contacto__label {
  display: block;
  font-weight: 800;
  font-size: 14px;
  color: var(--cdd-cafe);
  margin-bottom: 6px;
}

.cdd-contacto__req { color: var(--cdd-fucsia-texto); }

.cdd-contacto__input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  font: 400 15px 'Nunito Sans', sans-serif;
  color: var(--cdd-chocolate);
  background: var(--cdd-crema);
  border: 1.5px solid var(--cdd-borde);
  border-radius: 12px;
  transition: border-color .16s ease, box-shadow .16s ease;
}

.cdd-contacto__input::placeholder { color: var(--cdd-texto-suave); opacity: .8; }

.cdd-contacto__input:focus {
  outline: none;
  border-color: var(--cdd-fucsia-texto);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--cdd-fucsia-texto) 25%, transparent);
}

.cdd-contacto__textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.5;
}

.cdd-contacto__input[aria-invalid="true"] {
  border-color: #C0392B;
}

.cdd-contacto__error {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #C0392B;
}

.cdd-contacto__error-general,
.cdd-contacto__ok {
  max-width: 640px;
  margin: 0 auto 18px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 15px;
  line-height: 1.5;
  font-weight: 700;
}

.cdd-contacto__error-general {
  background: #FDEDEC;
  border-left: 4px solid #C0392B;
  color: #922B21;
}

.cdd-contacto__ok {
  display: flex;
  align-items: baseline;
  gap: .5rem;
  background: #fff;
  border-left: 4px solid var(--cdd-fucsia);
  color: var(--cdd-chocolate);
  box-shadow: 0 1px 4px rgba(58, 30, 14, .08);
}

.cdd-contacto__submit {
  margin-top: 6px;
  border: 0;
  cursor: pointer;
}

/* Honeypot: fuera del flujo visual y del foco, pero presente en el DOM. */
.cdd-contacto__hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

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

@media (max-width: 560px) {
  .cdd-contacto { padding: 22px 18px 24px; }
}

/* ---------- Estilos para contenido de Bloques Nativos / GenerateBlocks ------ */
.cdd-entry-content {
  color: var(--cdd-chocolate);
  font-size: 16px;
  line-height: 1.65;
}

.cdd-entry-content h1,
.cdd-entry-content h2,
.cdd-entry-content h3,
.cdd-entry-content h4,
.cdd-entry-content h5,
.cdd-entry-content h6 {
  font-family: 'Baloo 2', cursive;
  color: var(--cdd-chocolate);
  margin-top: 1.4em;
  margin-bottom: .5em;
}

.cdd-entry-content a {
  color: var(--cdd-fucsia-texto);
  text-decoration: underline;
}

.cdd-entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
}

/* ---------- WooCommerce Single Product Page Styling ------------------- */
/* Limpiar wrappers intermedios de GeneratePress para eliminar fondos y sombras duplicadas */
.single-product .site-main,
.single-product article,
.single-product .inside-article,
.single-product .entry-content {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

.single-product div.product,
.woocommerce div.product,
.woocommerce-page div.product {
  display: grid !important;
  grid-template-columns: 460px 1fr !important;
  gap: 48px !important;
  align-items: start !important;
  background: #ffffff !important;
  padding: 40px !important;
  border-radius: 24px !important;
  box-shadow: 0 6px 24px rgba(58, 30, 14, 0.05) !important;
  border: 1px solid #F2E9DE !important;
  margin-top: 24px !important;
  margin-bottom: 40px !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

/* Desactivar floats viejos de WooCommerce */
.woocommerce div.product div.images,
.woocommerce div.product div.summary,
.woocommerce-page div.product div.images,
.woocommerce-page div.product div.summary {
  float: none !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  box-sizing: border-box !important;
}

/* Galería / Imagen Destacada (Limpio sin sombras o fondos fantasma superiores) */
.woocommerce div.product div.images,
.cdd-single__gallery,
.cdd-single__media,
.woocommerce-product-gallery {
  background: transparent !important;
  box-shadow: none !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  width: 100% !important;
  position: sticky;
  top: 100px;
}

.woocommerce div.product div.images .woocommerce-product-gallery__wrapper {
  background: transparent !important;
  box-shadow: none !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
}

.woocommerce div.product div.images img,
.woocommerce-product-gallery__image img,
.cdd-single__img {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1 !important;
  object-fit: cover !important;
  border-radius: 20px !important;
  border: 1px solid #EFE6DC !important;
  box-shadow: 0 8px 30px rgba(58, 30, 14, 0.1) !important;
}

/* Resumen del producto (Columna Derecha a 100% de Ancho Completo) */
.woocommerce div.product div.summary,
.woocommerce-page div.product div.summary,
.single-product div.product div.summary,
.single-product .summary.entry-summary {
  float: none !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 16px !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

/* Título del producto */
.woocommerce div.product .product_title {
  font-family: 'Baloo 2', cursive !important;
  font-size: 34px !important;
  font-weight: 800 !important;
  color: var(--cdd-chocolate) !important;
  line-height: 1.25 !important;
  margin: 0 !important;
}

/* Sub-metadata tras el título (Categoría • SKU • Stock) */
.cdd-single__sub-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 13px;
  color: #7F8C8D;
  margin-top: -4px;
  margin-bottom: 6px;
}

.cdd-single__sub-cat a {
  color: var(--cdd-fucsia-texto);
  font-weight: 700;
  text-decoration: none;
}

.cdd-single__sub-cat a:hover {
  text-decoration: underline;
}

.cdd-single__sub-sku strong {
  color: var(--cdd-chocolate);
}

.cdd-single__dot {
  color: #BDC3C7;
}

.cdd-single__sub-stock--in {
  color: #27AE60;
  font-weight: 700;
}

/* Bloque de Precio Detalle */
.cdd-single__price-wrapper {
  width: 100% !important;
  box-sizing: border-box !important;
}

.cdd-single__price-box {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cdd-single__price-tag {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #8C7A6B;
}

.cdd-single__price-val {
  font-family: 'Baloo 2', cursive;
  font-size: 36px;
  font-weight: 800;
  color: var(--cdd-fucsia-texto);
  line-height: 1.1;
}

/* Tarjeta de Precio Mayorista Referencial a 100% Ancho */
.cdd-mayor-card {
  width: 100% !important;
  box-sizing: border-box !important;
  background: linear-gradient(135deg, #FFFDF9 0%, #FFF5EA 100%);
  border: 1.5px solid #F5DBC4;
  border-radius: 16px;
  padding: 20px 24px;
  margin: 6px 0;
  box-shadow: 0 4px 14px rgba(211, 84, 0, 0.05);
}

.cdd-mayor-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 8px;
}

.cdd-mayor-card__badge {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #D35400;
  background: #FDEBD0;
  padding: 4px 12px;
  border-radius: 12px;
}

.cdd-mayor-card__savings {
  font-size: 12px;
  font-weight: 800;
  color: #27AE60;
  background: #E8F8F5;
  padding: 4px 10px;
  border-radius: 10px;
}

.cdd-mayor-card__price {
  font-family: 'Baloo 2', cursive;
  font-size: 32px;
  font-weight: 800;
  color: var(--cdd-chocolate);
  line-height: 1.1;
}

.cdd-mayor-card__unit {
  font-size: 16px;
  font-weight: 600;
  color: #7F8C8D;
}

.cdd-mayor-card__desc {
  font-size: 13px;
  color: #6E5C4F;
  margin: 6px 0 0 0;
  line-height: 1.4;
}

/* Selector de Cantidad + Botón Carrito */
.woocommerce div.product form.cart {
  display: flex !important;
  gap: 16px !important;
  align-items: center !important;
  margin: 12px 0 !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.woocommerce div.product form.cart .quantity {
  margin: 0 !important;
}

.woocommerce div.product form.cart .quantity input.qty {
  width: 80px !important;
  height: 52px !important;
  border-radius: 14px !important;
  border: 1.5px solid #E0D4C5 !important;
  background: #FFFBF7 !important;
  font-family: 'Baloo 2', cursive !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  color: var(--cdd-chocolate) !important;
  text-align: center !important;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.03) !important;
}

.woocommerce div.product form.cart .single_add_to_cart_button {
  flex: 1 !important;
  width: 100% !important;
  height: 52px !important;
  padding: 0 32px !important;
  background: linear-gradient(135deg, var(--cdd-fucsia) 0%, #E02E76 100%) !important;
  color: #ffffff !important;
  font-family: 'Baloo 2', cursive !important;
  font-size: 18px !important;
  font-weight: 800 !important;
  border-radius: 14px !important;
  border: 0 !important;
  box-shadow: 0 6px 20px rgba(230, 48, 126, 0.3) !important;
  cursor: pointer !important;
  transition: transform 0.16s ease, box-shadow 0.16s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
}

.woocommerce div.product form.cart .single_add_to_cart_button:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(230, 48, 126, 0.4) !important;
}

/* Acciones extras & Barra de confianza a 100% Ancho */
.cdd-single__actions-extra {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100% !important;
  box-sizing: border-box !important;
}

.cdd-single__wa-btn {
  width: 100% !important;
  box-sizing: border-box !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  background: #25D366;
  color: #ffffff;
  font-weight: 700;
  font-size: 15px;
  border-radius: 14px;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.22);
  transition: transform 0.16s ease, background-color 0.16s ease;
}

.cdd-single__wa-btn:hover {
  background: #20BD5A;
  color: #ffffff;
  transform: translateY(-2px);
}

.cdd-single__trust-bar {
  width: 100% !important;
  box-sizing: border-box !important;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  background: #FDFBF7;
  border: 1px solid #F0E6D8;
  border-radius: 16px;
  padding: 16px;
}

.cdd-single__trust-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: #5A4A3E;
}

.cdd-single__trust-icon {
  font-size: 22px;
}

.cdd-single__trust-item strong {
  display: block;
  font-size: 13px;
  color: var(--cdd-chocolate);
  line-height: 1.2;
}

.cdd-single__trust-item span {
  font-size: 11px;
  color: #8C7A6B;
}

/* Adaptación responsive */
@media (max-width: 992px) {
  .single-product .site-main,
  .woocommerce div.product,
  .woocommerce-page div.product {
    grid-template-columns: 1fr !important;
    gap: 32px !important;
    padding: 24px !important;
  }

  .woocommerce div.product div.images {
    position: static;
  }

  .cdd-single__trust-bar {
    grid-template-columns: 1fr;
  }
}





/* =========================================================================
   Ajustes de portada, cuenta y móvil (se mantienen al final para ganar la cascada)
   ========================================================================= */

/* Banner 3 (escritorio): botón "Cotiza aquí" sobre la imagen, bajo el centro. */
.cdd-hero-slide__content--cta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 74px;
  z-index: 5;
  width: auto;
}

@media (max-width: 860px) {
  /* Cuenta: solo el ícono, junto al carrito. */
  .cdd-account__text { display: none; }
  .cdd-account { margin-left: 0; order: -1; } /* a la izquierda del buscador */
  .cdd-header__actions {
    flex: 1 1 100%;
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 8px;
  }
  .cdd-search { flex: 1 1 auto; min-width: 0; }
  .cdd-search__input { width: 100%; min-width: 0; flex: 1 1 auto; }
  .cdd-header__actions .cdd-btn--cart { flex: none; padding: 10px 14px; }

  /* Banners en celular: la ilustración y el texto siguen juntos. Las flechas bajan
     junto a los puntos, para que nunca tapen el texto. */
  .cdd-hero-slider,
  .cdd-hero-slides { min-height: 0; }

  .cdd-hero-slide--1,
  .cdd-hero-slide--2 {
    min-height: 560px;
    padding: 130px 0 76px;
  }
  .cdd-hero-slide--1 .cdd-hero-slide__overlay,
  .cdd-hero-slide--2 .cdd-hero-slide__overlay { background: rgba(30, 12, 55, 0.45); }

  .cdd-hero-slide .cdd-hero__title { font-size: 34px; }
  .cdd-hero-slide .cdd-hero__sub { font-size: 16px; }

  /* Banner 3: la imagen ya trae el mensaje; se ve completa y el botón va encima. */
  .cdd-hero-slide--3 {
    min-height: 0;
    aspect-ratio: 945 / 591;
  }
  .cdd-hero-slide--3 .cdd-hero-slide__bg { background-size: 100% 100%; }
  .cdd-hero-slide__content--cta { bottom: 54px; }
  .cdd-hero-slide__content--cta .cdd-btn-yellow { padding: 10px 22px; font-size: 15px; }

  /* Flechas abajo, a los lados de los puntos (fuera del texto). */
  .cdd-hero-nav {
    top: auto;
    bottom: 8px;
    transform: none;
    width: 36px;
    height: 36px;
    font-size: 20px;
  }
  .cdd-hero-nav:hover { transform: none; }
  .cdd-hero-nav--prev { left: calc(50% - 96px); }
  .cdd-hero-nav--next { right: calc(50% - 96px); }
  .cdd-hero-dots { bottom: 14px; }
}

/* Escritorio: el banner sigue la proporción de las portadas (2953×1845 ≈ 1,6:1),
   limitado al 88 % de la altura de la pantalla, para mostrar casi toda la ilustración. */
@media (min-width: 861px) {
  .cdd-hero-slider,
  .cdd-hero-slides,
  .cdd-hero-slide {
    min-height: clamp(520px, min(62.5vw, 88vh), 1100px);
  }
  .cdd-hero-slide--1 .cdd-hero-slide__bg,
  .cdd-hero-slide--2 .cdd-hero-slide__bg,
  .cdd-hero-slide--3 .cdd-hero-slide__bg {
    background-position: center center;
  }
}

/* Escritorio: el banner tiene EXACTAMENTE la proporción de las portadas (2953×1845),
   así que la ilustración se ve completa, sin recortes. */
@media (min-width: 861px) {
  .cdd-hero-slider,
  .cdd-hero-slides {
    min-height: 0;
  }
  .cdd-hero-slide {
    min-height: 0;
    aspect-ratio: 2953 / 1845;
    padding: 0;
  }
  .cdd-hero-slide:not(.is-active) { height: auto; }
  .cdd-hero-slide--3 .cdd-hero-slide__bg,
  .cdd-hero-slide--1 .cdd-hero-slide__bg,
  .cdd-hero-slide--2 .cdd-hero-slide__bg {
    background-size: 100% 100%;
  }
  /* Con la ilustración completa, el botón del banner 3 sube al pie de la imagen. */
  .cdd-hero-slide__content--cta { bottom: 9%; }
}

/* ---- Banners editables: el estilo depende de si muestran texto o solo imagen ---- */
.cdd-hero-slide--img .cdd-hero-slide__overlay { display: none; }
.cdd-hero-slide--img { padding: 0; }

/* Banner con texto (cualquiera que sea su número): velo suave y texto centrado. */
.cdd-hero-slide--txt .cdd-hero-slide__overlay {
  display: block;
  background: rgba(30, 12, 55, 0.30);
}

@media (max-width: 860px) {
  /* Con texto: la ilustración con el texto encima. */
  .cdd-hero-slide--txt {
    min-height: 560px;
    aspect-ratio: auto;
    padding: 130px 0 76px;
  }
  .cdd-hero-slide--txt .cdd-hero-slide__bg { background-size: cover; }
  .cdd-hero-slide--txt .cdd-hero-slide__overlay { background: rgba(30, 12, 55, 0.45); }

  /* Solo imagen: se ve completa, con el botón encima. */
  .cdd-hero-slide--img {
    min-height: 0;
    padding: 0;
    aspect-ratio: 2953 / 1845;
  }
  .cdd-hero-slide--img .cdd-hero-slide__bg { background-size: 100% 100%; }
}
