/* Correcciones de integración de las vistas Laravel.
   Se carga después del bundle visual para conservar el diseño de referencia. */

html {
  overflow-x: clip;
}

body.ec-site {
  min-width: 0;
  overflow-x: clip;
}

body.ec-site img {
  display: block;
  max-width: 100%;
}

/* El panel de sugerencias solo existe visualmente cuando contiene resultados. */
body.ec-site .ec-search-suggestions:not(.is-visible),
body.ec-site .ec-search-suggestions[hidden],
body.ec-site .ec-search-suggestions:empty {
  display: none !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

body.ec-site .ec-home-page {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

/* Orden visual del diseño aprobado: portada, pauta, categorías, solicitud y libros. */
body.ec-route-home .ec-home-hero-bleed { order: 1; }
body.ec-route-home .ec-home-deals-section { order: 2; }
body.ec-route-home .ec-home-categories { order: 3; }
body.ec-route-home .ec-home-request-book-section { order: 4; }
body.ec-route-home .novedades { order: 5; }
body.ec-route-home .ec-home-category-books { order: 5; }

body.ec-route-home .ec-home-category-books + .ec-home-category-books {
  margin-top: 18px;
}

body.ec-route-home .ec-home-category-books .ec-store-shelf-head {
  margin-bottom: 16px;
}

/* Evita los espacios artificiales que dejaba la carga diferida en HostGator. */
body.ec-site .ec-home-section,
body.ec-site .ec-lazy-section,
body.ec-site .ec-book-card,
body.ec-route-book .ec-detail-lower-section {
  content-visibility: visible !important;
  contain: none !important;
  contain-intrinsic-size: none !important;
}

body.ec-site .ec-main,
body.ec-site.ec-route-home .ec-main {
  min-height: 0;
}

body.ec-route-home .ec-home-deals-section {
  margin-top: 28px;
}

body.ec-route-home .ec-home-deals-section .ec-home-section-head h2 {
  font-size: clamp(24px, 2.2vw, 34px);
}

/* Cuadrícula real para los libros de inicio. */
body.ec-site .ec-store-shelf-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  width: 100%;
  align-items: stretch;
}

body.ec-site .ec-store-shelf-grid > * {
  min-width: 0;
}

body.ec-site .ec-store-shelf-grid .ec-book-card-compact-shop {
  display: flex;
  min-width: 0;
  height: 100%;
  flex-direction: column;
  overflow: hidden;
  border-radius: 18px;
}

body.ec-site .ec-store-shelf-grid .ec-book-cover-link,
body.ec-site .ec-store-shelf-grid .ec-book-cover-shell {
  display: block;
  width: 100%;
  min-width: 0;
}

body.ec-site .ec-store-shelf-grid .ec-book-cover-shell {
  aspect-ratio: 4 / 5.35;
  padding: 12px;
  overflow: hidden;
  background: linear-gradient(180deg, #fff8f3 0%, #efe8e2 100%);
}

body.ec-site .ec-store-shelf-grid img.ec-book-cover {
  width: 100% !important;
  height: 100% !important;
  max-height: none !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
  object-position: center;
  background: transparent;
}

body.ec-site .ec-store-shelf-grid .ec-book-body {
  display: flex;
  min-width: 0;
  height: 100%;
  flex: 1 1 auto;
  flex-direction: column;
  padding: 13px;
}

body.ec-site .ec-store-shelf-grid .ec-book-byline,
body.ec-site .ec-store-shelf-grid .ec-book-title,
body.ec-site .ec-store-shelf-grid .ec-book-support-copy {
  overflow-wrap: anywhere;
}

body.ec-site .ec-store-shelf-grid .ec-book-title {
  margin: 6px 0 0;
  font-family: 'Fraunces', Georgia, serif;
  font-size: 15px;
  line-height: 1.25;
}

body.ec-site .ec-store-shelf-grid .ec-book-title a {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

body.ec-site .ec-store-shelf-grid .ec-book-support-copy {
  display: -webkit-box;
  min-height: 2.7em;
  margin: 7px 0 0;
  overflow: hidden;
  color: var(--ec-muted);
  font-size: 10px;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

body.ec-site .ec-store-shelf-grid .ec-book-support-copy span {
  display: block;
}

body.ec-site .ec-store-shelf-grid .ec-book-price-row {
  margin-top: auto;
  padding-top: 10px;
}

body.ec-site .ec-store-shelf-grid .ec-book-price strong {
  font-size: 16px;
}

body.ec-site .ec-store-shelf-grid .ec-book-mini-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 10px;
}

body.ec-site .ec-store-shelf-grid .ec-book-mini-actions form {
  margin: 0;
}

body.ec-site .ec-store-shelf-grid .ec-book-mini-cart {
  min-width: 82px;
  min-height: 34px;
  padding: 7px 13px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(180deg, #64160f 0%, #300406 100%);
  font-size: 10px;
  font-weight: 700;
}

/* Encabezado y pie: el logotipo conserva sus proporciones reales. */
body.ec-site .ec-brand-mark-wordmark {
  width: 220px;
  height: 64px;
}

body.ec-site .ec-brand-logo-wordmark,
body.ec-site .ec-footer-brand .ec-brand-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

body.ec-site .ec-footer-brand .ec-brand-mark {
  width: 92px;
  height: 58px;
  flex: 0 0 92px;
}

/* El detalle termina junto a su contenido, sin una pantalla vacía antes del pie. */
body.ec-route-book .ec-main {
  padding-bottom: 34px;
}

body.ec-route-book .ec-detail-lower-section {
  min-height: 0 !important;
  margin-top: 18px;
}

body.ec-route-book .ec-detail-related-section {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(75, 16, 13, .12);
}

body.ec-route-book .ec-detail-related-copy {
  margin: 5px 0 0;
  color: var(--ec-muted);
  font-size: 12px;
}

body.ec-route-book .ec-detail-tab-content,
body.ec-route-book .ec-detail-panel-content,
body.ec-route-book .ec-detail-copy-shell {
  min-height: 0 !important;
}

body.ec-route-book .ec-detail-gallery-main img {
  width: 100%;
  max-height: 560px;
  object-fit: contain;
}

body.ec-site .ec-mobile-dock {
  display: none;
}

@media (max-width: 1199.98px) {
  body.ec-site .ec-store-shelf-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  body.ec-site {
    padding-bottom: 88px;
  }

  body.ec-site .ec-site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 251, 252, 0.98);
    box-shadow: 0 4px 18px rgba(48, 4, 6, 0.08);
  }

  body.ec-site .ec-header-strip {
    height: auto;
  }

  body.ec-site .ec-main-header {
    top: 0;
    display: grid;
    grid-template-areas: 'toggle brand';
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 10px;
    min-height: 62px;
    padding: 7px 0;
  }

  body.ec-site .ec-brand-link {
    justify-self: center;
    padding-right: 42px;
  }

  body.ec-site .ec-brand-mark-wordmark {
    width: min(170px, 56vw);
    height: 48px;
  }

  body.ec-site .ec-header-search-shell,
  body.ec-site .ec-header-actions {
    display: none;
  }

  body.ec-site .ec-nav-strip {
    position: relative;
    display: block;
    height: 0;
    min-height: 0;
    border: 0;
  }

  body.ec-site .ec-nav-shell {
    min-height: 0;
  }

  body.ec-site .ec-main-nav.is-open {
    position: fixed;
    top: 68px;
    right: 12px;
    left: 12px;
    display: flex;
  }

  body.ec-site .ec-store-shelf-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  body.ec-site .ec-mobile-dock {
    position: fixed;
    right: max(10px, env(safe-area-inset-right));
    bottom: max(10px, env(safe-area-inset-bottom));
    left: max(10px, env(safe-area-inset-left));
    z-index: 110;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
    padding: 8px;
    border: 1px solid rgba(75, 16, 13, 0.12);
    border-radius: 22px;
    background: rgba(255, 251, 248, 0.96);
    box-shadow: 0 14px 34px rgba(42, 27, 14, 0.18);
    backdrop-filter: blur(18px);
  }

  body.ec-site .ec-mobile-dock-link {
    display: grid;
    gap: 3px;
    min-width: 0;
    padding: 6px 3px;
    border-radius: 14px;
    justify-items: center;
    color: var(--ec-muted);
    font-size: 10px;
    font-weight: 700;
  }

  body.ec-site .ec-mobile-dock-link.is-active {
    color: var(--ec-wine);
    background: rgba(75, 16, 13, 0.09);
  }

  body.ec-site .ec-mobile-dock-icon {
    font-size: 18px;
    line-height: 1;
  }

  body.ec-site .ec-whatsapp-fab {
    bottom: 96px;
  }

  body.ec-route-book .ec-detail-hero {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 767.98px) {
  body.ec-site .container-xxl {
    width: 100%;
    padding-right: 12px;
    padding-left: 12px;
  }

  body.ec-site .ec-main,
  body.ec-site.ec-route-home .ec-main {
    padding-bottom: 20px;
  }

  body.ec-route-home .ec-home-deals-section {
    margin-top: 18px;
  }

  body.ec-site .ec-home-section,
  body.ec-site .ec-home-request-book-section {
    margin-bottom: 22px;
  }

  body.ec-site .ec-home-section-head {
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    gap: 10px;
  }

  body.ec-site .ec-home-section-head h2,
  body.ec-route-home .ec-home-deals-section .ec-home-section-head h2 {
    font-size: clamp(20px, 7vw, 27px);
  }

  body.ec-site .ec-store-shelf-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-card-compact-shop {
    border-radius: 14px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-cover-shell {
    padding: 8px;
    aspect-ratio: 4 / 5.25;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-body {
    padding: 9px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-byline {
    font-size: 8px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-title {
    font-size: 12px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-support-copy {
    min-height: 2.5em;
    font-size: 8px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-price strong {
    font-size: 13px;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-mini-link {
    display: none;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-mini-actions {
    justify-content: flex-end;
  }

  body.ec-site .ec-store-shelf-grid .ec-book-mini-cart {
    min-width: 68px;
    min-height: 30px;
    padding: 5px 9px;
    font-size: 9px;
  }

  body.ec-site .ec-home-category-card {
    min-width: 0;
  }

  body.ec-site .ec-home-category-copy {
    min-width: 0;
  }

  body.ec-site .ec-home-category-copy strong,
  body.ec-site .ec-home-category-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  body.ec-site .ec-footer-main {
    padding: 24px 0 14px;
  }

  body.ec-site .ec-footer-grid {
    gap: 18px;
  }

  body.ec-site .ec-footer-column:not(.ec-footer-brand-column) {
    display: none;
  }

  body.ec-site .ec-footer-brand {
    align-items: center;
  }

  body.ec-site .ec-footer-bottom {
    margin-top: 16px;
    gap: 8px;
  }

  body.ec-site .ec-footer-payments {
    display: none;
  }

  body.ec-route-book .ec-main {
    padding-top: 10px;
  }

  body.ec-route-book .ec-detail-breadcrumbs {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }

  body.ec-route-book .ec-detail-gallery-panel,
  body.ec-route-book .ec-detail-summary-panel {
    padding: 12px;
    border-radius: 16px;
  }

  body.ec-route-book .ec-detail-gallery-main img {
    max-height: 430px;
    padding: 6px;
  }

  body.ec-route-book .ec-detail-title {
    font-size: clamp(28px, 9vw, 36px);
  }

  body.ec-route-book .ec-detail-whatsapp-offer-head {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  body.ec-route-book .ec-detail-buy-row,
  body.ec-route-book .ec-detail-actions,
  body.ec-route-book .ec-detail-benefits-row {
    grid-template-columns: 1fr;
  }

  body.ec-route-book .ec-detail-qty-box {
    width: 100%;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
  }

  body.ec-route-book .ec-detail-tabs {
    padding: 0 6px;
    overflow-x: auto;
  }

  body.ec-route-book .ec-detail-tabs .nav-link {
    padding: 12px 10px;
  }

  body.ec-route-book .ec-detail-tab-content {
    padding: 14px;
  }
}

/* Slider automático alimentado por los archivos de la carpeta /banner. */
body.ec-site .ec-banner-slider {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid rgba(75, 16, 13, .12);
  border-radius: 20px;
  background: #f8f1eb;
  box-shadow: 0 12px 30px rgba(48, 4, 6, .08);
}

body.ec-site .ec-banner-slides,
body.ec-site .ec-banner-slide {
  width: 100%;
  margin: 0;
}

body.ec-site .ec-banner-slide {
  display: none;
}

body.ec-site .ec-banner-slide.is-active {
  display: block;
}

body.ec-site .ec-banner-slide img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2089 / 753;
  object-fit: cover;
}

body.ec-site .ec-banner-control {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  transform: translateY(-50%);
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 50%;
  color: #fff;
  background: rgba(48, 4, 6, .76);
  font-size: 28px;
  line-height: 1;
}

body.ec-site .ec-banner-control.is-prev { left: 14px; }
body.ec-site .ec-banner-control.is-next { right: 14px; }

body.ec-site .ec-banner-dots {
  position: absolute;
  right: 0;
  bottom: 12px;
  left: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 7px;
}

body.ec-site .ec-banner-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 1px solid #fff;
  border-radius: 50%;
  background: rgba(255, 255, 255, .5);
}

body.ec-site .ec-banner-dots button.is-active {
  background: var(--ec-wine);
}

body.ec-route-book .ec-detail-whatsapp-discount {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px dashed rgba(75, 16, 13, .35);
  border-radius: 12px;
  background: #fff8e7;
}

body.ec-route-book .ec-detail-whatsapp-discount strong {
  flex: 0 0 auto;
  color: var(--ec-wine);
  font-size: 15px;
}

body.ec-route-book .ec-detail-whatsapp-discount span {
  color: var(--ec-ink);
  font-size: 11px;
  line-height: 1.4;
}

@media (max-width: 575.98px) {
  body.ec-site .ec-banner-slider { border-radius: 12px; }
  body.ec-site .ec-banner-control { width: 34px; height: 34px; font-size: 22px; }
  body.ec-site .ec-banner-control.is-prev { left: 8px; }
  body.ec-site .ec-banner-control.is-next { right: 8px; }
}

/* Búsqueda personalizada en formato banner compacto. */
body.ec-site .ec-home-request-book-section {
  padding-block: 6px;
}

body.ec-site .ec-home-request-book-card-featured {
  grid-template-columns: minmax(0, 1.15fr) minmax(390px, .85fr);
  gap: 28px;
  padding: 24px 30px;
  border-radius: 24px;
}

body.ec-site .ec-home-request-book-kicker {
  margin-bottom: 10px;
  padding: 6px 10px;
  font-size: 10px;
}

body.ec-site .ec-home-request-book-card-featured h2 {
  max-width: 19ch;
  font-size: clamp(27px, 3vw, 39px);
  line-height: 1.02;
}

body.ec-site .ec-home-request-book-intro {
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.45;
}

body.ec-site .ec-home-request-book-points {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

body.ec-site .ec-home-request-book-points > span {
  gap: 7px;
  padding: 9px 10px;
  border-radius: 12px;
}

body.ec-site .ec-home-request-book-points i {
  width: 28px;
  height: 28px;
  flex-basis: 28px;
  border-radius: 9px;
  font-size: 13px;
}

body.ec-site .ec-home-request-book-points strong {
  font-size: 11px;
}

body.ec-site .ec-home-request-book-points small {
  font-size: 10px;
  line-height: 1.25;
}

body.ec-site .ec-home-request-book-form {
  padding: 18px;
  border-radius: 20px;
}

body.ec-site .ec-home-request-book-form-head {
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 12px;
}

body.ec-site .ec-home-request-book-form-icon {
  width: 40px;
  height: 40px;
  flex-basis: 40px;
  border-radius: 12px;
  font-size: 19px;
}

body.ec-site .ec-home-request-book-form-head strong {
  font-size: 15px;
}

body.ec-site .ec-home-request-book-form-head small,
body.ec-site .ec-home-request-book-form .ec-label {
  font-size: 11px;
}

body.ec-site .ec-home-request-book-form .ec-label {
  margin-bottom: 6px;
}

body.ec-site .ec-home-request-book-controls {
  grid-template-columns: minmax(0, 1fr) minmax(190px, .72fr);
  gap: 9px;
}

body.ec-site .ec-home-request-book-input,
body.ec-site .ec-home-request-book-button {
  min-height: 46px;
}

body.ec-site .ec-home-request-book-input {
  padding: 10px 12px 10px 42px;
  border-radius: 14px;
  font-size: 13px;
}

body.ec-site .ec-home-request-book-input-wrap > i {
  left: 14px;
  font-size: 15px;
}

body.ec-site .ec-home-request-book-button {
  padding-inline: 14px !important;
  font-size: 12px !important;
}

body.ec-site .ec-home-request-book-note {
  margin-top: 9px;
  font-size: 10px;
  line-height: 1.35;
}

@media (max-width: 899.98px) {
  body.ec-site .ec-home-request-book-card-featured {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 22px;
  }

  body.ec-site .ec-home-request-book-controls {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 575.98px) {
  body.ec-site .ec-home-request-book-card-featured {
    gap: 16px;
    padding: 20px 16px;
    border-radius: 20px;
  }

  body.ec-site .ec-home-request-book-card-featured h2 {
    font-size: 29px;
  }

  body.ec-site .ec-home-request-book-points {
    grid-template-columns: 1fr;
  }
}

/* Inicio: diez categorias, cinco por fila, sin bloque promocional lateral. */
body.ec-site .ec-home-categories-layout {
  display: block;
}

body.ec-site .ec-home-categories-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  width: 100%;
}

@media (max-width: 1199.98px) {
  body.ec-site .ec-home-categories-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  body.ec-site .ec-home-categories-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 479.98px) {
  body.ec-site .ec-home-categories-grid {
    grid-template-columns: 1fr;
  }
}

/* 1.0.31: tipografía local, iconografía SVG y pedidos por encargo. */
body.ec-site {
  font-family: 'Plus Jakarta Sans', 'Segoe UI', Arial, sans-serif !important;
}

body.ec-site h1,
body.ec-site h2,
body.ec-site h3,
body.ec-site h4,
body.ec-site h5,
body.ec-site h6 {
  font-family: 'Fraunces', Georgia, serif !important;
}

body.ec-site button,
body.ec-site .btn,
body.ec-site input[type='button'],
body.ec-site input[type='submit'],
body.ec-site [class*='-button'],
body.ec-site [class*='-btn'],
body.ec-site .ec-book-mini-cart,
body.ec-site .ec-book-mini-link,
body.ec-site .ec-home-hero-cta {
  font-weight: 500 !important;
}

body.ec-site .ec-icon {
  display: inline-block;
  flex: 0 0 auto;
  width: 1em;
  height: 1em;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.14em;
}

body.ec-site .ec-search-submit .ec-icon,
body.ec-site .ec-cart-link-icon .ec-icon,
body.ec-site .ec-mobile-dock-icon .ec-icon {
  width: 20px;
  height: 20px;
}

body.ec-site .ec-whatsapp-fab .ec-icon {
  width: 27px;
  height: 27px;
}

body.ec-site .ec-book-mini-order {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #fff !important;
  background: #237a4b !important;
  text-decoration: none;
}

body.ec-site .ec-book-mini-order:hover {
  background: #185e38 !important;
}

body.ec-site .ec-detail-badge.is-order {
  color: #5a3a08;
  border-color: rgba(200, 149, 63, .48);
  background: #fff4d9;
}

body.ec-site .ec-detail-btn-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

body.ec-site .ec-detail-order-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px;
  border: 1px solid rgba(35, 122, 75, .28);
  border-radius: 18px;
  background: #f4fbf7;
}

body.ec-site .ec-detail-order-box strong,
body.ec-site .ec-detail-order-box p {
  display: block;
  margin: 0;
}

body.ec-site .ec-detail-order-box p {
  margin-top: 4px;
  color: var(--ec-muted);
  font-size: 12px;
}

body.ec-site .ec-detail-btn-order {
  flex: 0 0 auto;
  color: #fff !important;
  border-color: #237a4b !important;
  background: #237a4b !important;
}

body.ec-site .ec-detail-btn-order:hover {
  border-color: #185e38 !important;
  background: #185e38 !important;
}

body.ec-site .ec-detail-whatsapp-benefits span,
body.ec-site .ec-home-request-book-note,
body.ec-site .ec-home-request-book-kicker {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

body.ec-site .ec-auth-card-head > span .ec-icon,
body.ec-site .ec-account-empty > span .ec-icon,
body.ec-site .ec-empty-icon .ec-icon,
body.ec-site .ec-store-confirmation-icon .ec-icon {
  width: 1em;
  height: 1em;
}

@media (max-width: 767.98px) {
  body.ec-site .ec-detail-order-box {
    align-items: stretch;
    flex-direction: column;
  }

  body.ec-site .ec-detail-btn-order {
    width: 100%;
  }
}

/* Paginación compartida del catálogo Laravel. */
body.ec-site .ec-unified-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 28px;
}

body.ec-site .ec-unified-pagination a,
body.ec-site .ec-unified-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--ec-border);
  border-radius: 999px;
  color: var(--ec-ink);
  background: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
}

body.ec-site .ec-unified-pagination a:hover,
body.ec-site .ec-unified-pagination .is-current {
  border-color: var(--ec-wine);
  color: #fff;
  background: var(--ec-wine);
}

body.ec-site .ec-unified-pagination .is-disabled {
  color: var(--ec-muted);
  background: var(--ec-sand);
  opacity: .55;
}

body.ec-site .ec-directory-pagination {
  width: 100%;
  clear: both;
}

body.ec-site .ec-directory-pagination .ec-unified-pagination {
  margin: 30px auto 0;
}

body.ec-site .ec-directory-pagination svg {
  width: 16px !important;
  height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
}

body.ec-site .ec-unified-pagination .ec-page-navigation {
  gap: 6px;
  padding-inline: 16px;
}

body.ec-site .ec-unified-pagination .ec-page-ellipsis {
  min-width: 24px;
  padding-inline: 6px;
  border-color: transparent;
  background: transparent;
}

@media (max-width: 575.98px) {
  body.ec-site .ec-unified-pagination {
    gap: 6px;
  }

  body.ec-site .ec-unified-pagination a,
  body.ec-site .ec-unified-pagination span {
    min-width: 36px;
    min-height: 36px;
    padding: 7px 11px;
    font-size: 12px;
  }

  body.ec-site .ec-unified-pagination .ec-page-navigation {
    flex: 1 1 120px;
  }
}

body.ec-site .ec-detail-quick-link.is-static {
  cursor: default;
}

body.ec-site .ec-detail-quick-link.is-static:hover {
  border-color: var(--ec-border);
  color: var(--ec-ink);
  background: #fff;
  transform: none;
}

/* Catálogo compacto: búsqueda y resultados dentro de un solo bloque. */
body.ec-site.ec-route-catalog-compact .ec-main {
  padding-top: 24px;
  padding-bottom: 36px;
}

body.ec-site .ec-compact-catalog {
  padding: 22px;
  border: 1px solid rgba(75, 16, 13, .09);
  border-radius: 24px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 18px 46px rgba(58, 30, 24, .08);
}

body.ec-site .ec-compact-catalog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(75, 16, 13, .1);
}

body.ec-site .ec-compact-catalog-head h1 {
  margin: 3px 0 2px;
  color: var(--ec-ink);
  font-family: 'Fraunces', serif;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.08;
}

body.ec-site .ec-compact-catalog-head p {
  margin: 0;
  color: var(--ec-muted);
  font-size: 13px;
}

body.ec-site .ec-compact-clear {
  flex: 0 0 auto;
  padding: 9px 15px;
  border: 1px solid rgba(75, 16, 13, .18);
  border-radius: 999px;
  color: var(--ec-wine);
  background: var(--ec-sand);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

body.ec-site .ec-compact-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 205px));
  align-items: start;
  justify-content: start;
  gap: 18px;
}

body.ec-site .ec-compact-results-grid .ec-book-card-compact-shop {
  width: 100%;
  height: auto;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  border-radius: 18px;
}

body.ec-site .ec-compact-results-grid .ec-book-cover-link,
body.ec-site .ec-compact-results-grid .ec-book-cover-shell {
  display: block;
  width: 100%;
  min-width: 0;
}

body.ec-site .ec-compact-results-grid .ec-book-cover-shell {
  aspect-ratio: 4 / 5.35;
  padding: 10px;
  overflow: hidden;
  background: linear-gradient(180deg, #fff8f3 0%, #efe8e2 100%);
}

body.ec-site .ec-compact-results-grid img.ec-book-cover {
  display: block;
  width: 100% !important;
  height: 100% !important;
  max-height: none !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
}

/* La galería del detalle debe ser blanca, sin fondos beige. */
body.ec-route-book .ec-detail-gallery-panel,
body.ec-route-book .ec-detail-gallery-stage,
body.ec-route-book .ec-detail-gallery-main,
body.ec-route-book .ec-detail-gallery-main img,
body.ec-route-book .ec-detail-thumb,
body.ec-route-book .ec-detail-thumb img {
  background: #fff !important;
}

body.ec-route-book .ec-detail-thumb img {
  object-fit: contain;
}

/* Jerarquía tipográfica global: títulos 600, subtítulos 500, texto 300. */
body.ec-site,
body.ec-site * {
  font-weight: 300 !important;
}

body.ec-site h1,
body.ec-site h1 *,
body.ec-site h2,
body.ec-site h2 *,
body.ec-site h3,
body.ec-site h3 *,
body.ec-site h4,
body.ec-site h4 *,
body.ec-site h5,
body.ec-site h5 *,
body.ec-site h6,
body.ec-site h6 *,
body.ec-site .ec-detail-title,
body.ec-site .ec-detail-title *,
body.ec-site .ec-summary-title,
body.ec-site .ec-summary-title *,
body.ec-site .ec-store-hero-title,
body.ec-site .ec-store-hero-title * {
  font-weight: 600 !important;
}

body.ec-site strong,
body.ec-site b,
body.ec-site label,
body.ec-site button,
body.ec-site .btn,
body.ec-site nav,
body.ec-site nav *,
body.ec-site [class*="-kicker"],
body.ec-site [class*="-eyebrow"],
body.ec-site [class*="-badge"],
body.ec-site [class*="-label"],
body.ec-site [class*="-byline"],
body.ec-site .bi {
  font-weight: 500 !important;
}

body.ec-site h1,
body.ec-site h1 *,
body.ec-site h2,
body.ec-site h2 *,
body.ec-site h3,
body.ec-site h3 *,
body.ec-site h4,
body.ec-site h4 *,
body.ec-site h5,
body.ec-site h5 *,
body.ec-site h6,
body.ec-site h6 * {
  font-weight: 600 !important;
}

/* Acceso y cuenta exclusivos para clientes. */
body.ec-site .ec-auth-page {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(420px, 1fr);
  gap: 28px;
  max-width: 1040px;
  margin: 38px auto 52px;
}

body.ec-site .ec-auth-intro,
body.ec-site .ec-auth-card,
body.ec-site .ec-account-head,
body.ec-site .ec-account-panel {
  border: 1px solid var(--ec-border);
  border-radius: 24px;
  box-shadow: var(--ec-shadow-card);
}

body.ec-site .ec-auth-intro {
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding: 38px;
  color: #fff;
  background: linear-gradient(145deg, var(--ec-wine) 0%, #651b14 100%);
}

body.ec-site .ec-auth-intro h1 {
  margin: 8px 0 14px;
  font-size: clamp(34px, 5vw, 54px);
}

body.ec-site .ec-auth-intro p,
body.ec-site .ec-auth-intro li {
  color: rgba(255, 255, 255, .84);
}

body.ec-site .ec-auth-intro ul {
  display: grid;
  gap: 9px;
  margin: 18px 0 0;
  padding-left: 20px;
}

body.ec-site .ec-auth-card {
  padding: 30px;
  background: #fff;
}

body.ec-site .ec-auth-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}

body.ec-site .ec-auth-card-head > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 50%;
  color: #fff;
  background: var(--ec-wine);
}

body.ec-site .ec-auth-card-head h2,
body.ec-site .ec-auth-card-head p {
  margin: 0;
}

body.ec-site .ec-auth-form {
  display: grid;
  gap: 10px;
}

body.ec-site .ec-auth-form .ec-input {
  min-height: 48px;
  margin-bottom: 5px;
  border-color: rgba(75, 16, 13, .18);
  background: #fff;
}

body.ec-site .ec-auth-check {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 7px 0 12px;
  color: var(--ec-muted);
  font-size: 12px;
}

body.ec-site .ec-auth-check input {
  margin-top: 3px;
}

body.ec-site .ec-auth-help {
  display: block;
  margin-top: 5px;
  color: var(--ec-muted);
}

body.ec-site .ec-auth-switch {
  margin: 20px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--ec-border);
  text-align: center;
}

body.ec-site .ec-auth-switch a {
  color: var(--ec-wine);
  font-weight: 500 !important;
}

body.ec-site .ec-account-page {
  max-width: 1100px;
  margin: 32px auto 52px;
}

body.ec-site .ec-account-head,
body.ec-site .ec-account-panel-head,
body.ec-site .ec-account-order {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

body.ec-site .ec-account-head {
  margin-bottom: 20px;
  padding: 24px;
  background: #fff;
}

body.ec-site .ec-account-head h1,
body.ec-site .ec-account-head p,
body.ec-site .ec-account-panel-head h2 {
  margin: 0;
}

body.ec-site .ec-account-panel {
  padding: 24px;
  background: #fff;
}

body.ec-site .ec-account-panel-head {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--ec-border);
}

body.ec-site .ec-account-orders {
  display: grid;
  gap: 10px;
  padding-top: 16px;
}

body.ec-site .ec-account-order {
  display: grid;
  grid-template-columns: minmax(170px, 1.4fr) repeat(3, minmax(110px, 1fr));
  padding: 15px 16px;
  border: 1px solid var(--ec-border);
  border-radius: 14px;
  background: var(--ec-sand);
}

body.ec-site .ec-account-order div {
  display: grid;
  gap: 3px;
}

body.ec-site .ec-account-order small {
  color: var(--ec-muted);
}

body.ec-site .ec-account-status {
  color: var(--ec-wine);
  font-weight: 500 !important;
}

body.ec-site .ec-account-empty {
  padding: 42px 16px 28px;
  text-align: center;
}

body.ec-site .ec-account-empty > span {
  display: block;
  margin-bottom: 10px;
  color: var(--ec-wine);
  font-size: 34px;
}

@media (max-width: 767.98px) {
  body.ec-site .ec-auth-page {
    grid-template-columns: 1fr;
    gap: 14px;
    margin: 16px auto 32px;
  }

  body.ec-site .ec-auth-intro,
  body.ec-site .ec-auth-card,
  body.ec-site .ec-account-head,
  body.ec-site .ec-account-panel {
    padding: 18px;
    border-radius: 18px;
  }

  body.ec-site .ec-auth-intro ul {
    display: none;
  }

  body.ec-site .ec-account-head,
  body.ec-site .ec-account-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  body.ec-site .ec-account-order {
    grid-template-columns: 1fr 1fr;
  }
}

body.ec-site .ec-compact-results-grid .ec-book-body {
  padding: 13px;
}

body.ec-site .ec-compact-results-grid .ec-book-title {
  margin: 6px 0 0;
  font-size: 14px;
}

body.ec-site .ec-compact-results-grid .ec-book-support-copy {
  min-height: 2.6rem;
  margin-top: 6px;
  font-size: 10px;
}

body.ec-site .ec-compact-results-grid .ec-book-price-row {
  margin-top: 9px;
  padding-bottom: 9px;
}

body.ec-site .ec-compact-results-grid .ec-book-price strong {
  font-size: 16px;
}

body.ec-site .ec-compact-empty {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border-radius: 16px;
  background: var(--ec-sand);
}

body.ec-site .ec-compact-empty > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: #fff;
  background: var(--ec-wine);
}

body.ec-site .ec-compact-empty div {
  flex: 1;
}

body.ec-site .ec-compact-empty h2,
body.ec-site .ec-compact-empty p {
  margin: 0;
}

@media (max-width: 767.98px) {
  body.ec-site.ec-route-catalog-compact .ec-main {
    padding-top: 12px;
  }

  body.ec-site .ec-compact-catalog {
    padding: 14px;
    border-radius: 18px;
  }

  body.ec-site .ec-compact-catalog-head,
  body.ec-site .ec-compact-empty {
    align-items: flex-start;
    flex-direction: column;
  }

  body.ec-site .ec-compact-results-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  body.ec-site .ec-compact-results-grid .ec-book-mini-actions {
    align-items: stretch;
    flex-direction: column;
  }

  body.ec-site .ec-compact-results-grid .ec-book-mini-cart {
    width: 100%;
  }
}

@media (max-width: 359.98px) {
  body.ec-site .ec-home-categories-grid {
    grid-template-columns: 1fr;
  }
}

/* Navegación relacional del catálogo: autor, editorial y categoría. */
body.ec-site .ec-catalog-facets {
  padding: 22px 0 0;
}

body.ec-site .ec-catalog-facets-panel {
  padding: 22px;
}

body.ec-site .ec-catalog-facets-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

body.ec-site .ec-catalog-facets-heading h2 {
  margin: 2px 0 0;
  font-family: 'Fraunces', Georgia, serif;
  font-size: clamp(24px, 2.4vw, 34px);
  color: var(--ec-ink);
}

body.ec-site .ec-catalog-facets-heading p {
  margin: 7px 0 0;
  color: var(--ec-muted);
  font-size: 12px;
}

body.ec-site .ec-catalog-active-search {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 420px;
  padding: 9px 12px;
  border: 1px solid rgba(200, 149, 63, 0.35);
  border-radius: 999px;
  background: rgba(200, 149, 63, 0.1);
  font-size: 11px;
}

body.ec-site .ec-catalog-active-search strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.ec-site .ec-catalog-active-search a {
  color: var(--ec-wine);
  font-weight: 800;
}

body.ec-site .ec-catalog-facets-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

body.ec-site .ec-catalog-facet-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--ec-border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
}

body.ec-site .ec-catalog-facet-title {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}

body.ec-site .ec-catalog-facet-title > span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  color: var(--ec-wine);
  background: rgba(75, 16, 13, 0.08);
  font-size: 18px;
}

body.ec-site .ec-catalog-facet-title h3,
body.ec-site .ec-catalog-facet-title p {
  margin: 0;
}

body.ec-site .ec-catalog-facet-title h3 {
  font-size: 15px;
  color: var(--ec-ink);
}

body.ec-site .ec-catalog-facet-title p {
  margin-top: 2px;
  color: var(--ec-muted);
  font-size: 10px;
}

body.ec-site .ec-catalog-facet-list {
  display: grid;
  gap: 6px;
}

body.ec-site .ec-catalog-facet-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  padding: 9px 10px;
  border-radius: 10px;
  color: var(--ec-ink);
  background: var(--ec-sand);
  font-size: 11px;
  transition: background-color .18s ease, color .18s ease, transform .18s ease;
}

body.ec-site .ec-catalog-facet-link span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 700;
}

body.ec-site .ec-catalog-facet-link small {
  flex: 0 0 auto;
  color: var(--ec-muted);
  font-size: 9px;
}

body.ec-site .ec-catalog-facet-link:hover,
body.ec-site .ec-catalog-facet-link.is-active {
  color: #fff8f0;
  background: var(--ec-wine);
  transform: translateX(2px);
}

body.ec-site .ec-catalog-facet-link:hover small,
body.ec-site .ec-catalog-facet-link.is-active small {
  color: rgba(255, 248, 240, .78);
}

body.ec-site .ec-catalog-facet-empty {
  padding: 10px;
  color: var(--ec-muted);
  font-size: 10px;
}

/* Únicos filtros de los listados: orden de precio y edición/año. */
body.ec-site .ec-book-list-filters {
  display: grid;
  grid-template-columns: minmax(210px, 1fr) minmax(180px, 1fr) auto auto;
  align-items: end;
  gap: 12px;
  margin: 18px 0 22px;
  padding: 16px;
  border: 1px solid rgba(75, 16, 13, .14);
  border-radius: 16px;
  background: #fffaf6;
}

body.ec-site .ec-book-list-filter-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

body.ec-site .ec-book-list-filter-field span {
  color: var(--ec-ink);
  font-size: 11px;
  font-weight: 700;
}

body.ec-site .ec-book-list-filter-field select,
body.ec-site .ec-book-list-filter-field input {
  width: 100%;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid rgba(75, 16, 13, .2);
  border-radius: 10px;
  color: var(--ec-ink);
  background: #fff;
}

body.ec-site .ec-book-list-filter-submit {
  min-height: 42px;
  padding: 9px 18px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--ec-wine);
  font-weight: 700;
}

body.ec-site .ec-book-list-filter-clear {
  align-self: center;
  color: var(--ec-wine);
  font-size: 12px;
  font-weight: 700;
}

@media (max-width: 767.98px) {
  body.ec-site .ec-book-list-filters {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  body.ec-site .ec-book-list-filter-submit {
    width: 100%;
  }
}

body.ec-site .ec-delivery-notice,
body.ec-site .ec-delivery-summary,
body.ec-site .ec-cart-delivery {
  display: grid;
  gap: 4px;
  margin: 12px 0;
  padding: 12px 14px;
  border: 1px solid rgba(75, 16, 13, .16);
  border-radius: 12px;
  color: var(--ec-ink);
  background: #fbf5ef;
  font-size: 12px;
  line-height: 1.45;
}

body.ec-site .ec-cart-delivery {
  margin: 8px 0 0;
  padding: 8px 10px;
}

@media (max-width: 991.98px) {
  body.ec-site .ec-catalog-facets-grid {
    grid-template-columns: 1fr;
  }

  body.ec-site .ec-catalog-facet-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  body.ec-site .ec-catalog-facets {
    padding-top: 12px;
  }

  body.ec-site .ec-catalog-facets-panel {
    padding: 14px;
    border-radius: 18px;
  }

  body.ec-site .ec-catalog-facets-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  body.ec-site .ec-catalog-active-search {
    width: 100%;
    max-width: none;
  }

  body.ec-site .ec-catalog-facet-card {
    padding: 12px;
    border-radius: 14px;
  }

  body.ec-site .ec-catalog-facet-list {
    grid-template-columns: 1fr;
    max-height: 270px;
    overflow-y: auto;
  }
}

/* Banners fijos: contenedor de 12 columnas dividido en dos columnas de 6. */
body.ec-site .ec-banner-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  width: 100%;
}

body.ec-site .ec-banner-grid-item {
  width: 100%;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(75, 16, 13, .12);
  border-radius: 16px;
  background: #f8f1eb;
  box-shadow: 0 10px 24px rgba(48, 4, 6, .08);
}

body.ec-site .ec-banner-grid-item img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2089 / 753;
  object-fit: cover;
}

@media (max-width: 767.98px) {
  body.ec-site .ec-banner-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  body.ec-site .ec-banner-grid-item {
    border-radius: 12px;
  }
}
