﻿/**
 * Tienda demo-b — clients/demo-b.local/design/b.local-tienda.html
 * Regenerar: python themes/base/scripts/extract-demo-b-pages-css.py
 * Requiere demo-b-shell.css (chrome).
 */

body.dpy-shop-pure {
  margin: 0 !important;
  padding: 0 !important;
  --wp--style--root--padding-top: 0 !important;
  --wp--style--root--padding-right: 0 !important;
  --wp--style--root--padding-bottom: 0 !important;
  --wp--style--root--padding-left: 0 !important;
}
body.dpy-shop-pure.admin-bar { padding-top: 32px !important; margin-top: 0 !important; }
body.dpy-shop-pure.admin-bar #main-header { top: 32px; }
body.dpy-shop-pure p,
body.dpy-shop-pure h1,
body.dpy-shop-pure h2,
body.dpy-shop-pure h3 {
  margin: 0;
  padding: 0;
}
body.dpy-shop-pure h1.shop-page-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 22px;
  color: #1a1a1a;
  margin: 0 0 16px;
  letter-spacing: -.3px;
}

  #cat-tabs { border-bottom: 1px solid #eee; background: #fff; }
  .tabs-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 0;
    flex-wrap: wrap;
  }
  .tab-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 6px 12px;
    box-sizing: border-box;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: #555;
    border: 1px solid #ddd;
    transition: all .15s;
    cursor: pointer;
  }
  .tab-chip:hover { border-color: var(--dpy-magenta, #e91e8c); color: var(--dpy-magenta, #e91e8c); }
  .tab-chip.active { background: #1a1a1a; color: #fff; border-color: #1a1a1a; }

  /* SHOP LAYOUT */
  #shop-content { padding: 20px 0 40px; }
  .shop-layout { display: flex; gap: 40px; align-items: flex-start; }

  /* SIDEBAR */
  .shop-sidebar { width: 240px; flex-shrink: 0; background: #fafafa; border: 1px solid #eee; border-radius: 8px; padding: 16px; }
  .sidebar-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
  }
  .sidebar-group:last-child { margin-bottom: 0; }
  /* MUST beat body.dpy-shop-pure p { margin:0 } */
  body.dpy-shop-pure .sidebar-label,
  .sidebar-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 13px;
    color: #fd00ae;
    margin: 0;
  }
  .sidebar-select { width: 100%; border: 1px solid #ddd; border-radius: 4px; padding: 8px 10px; font-size: 13px; color: #555; font-family: inherit; background: #fff; }

  /* PRODUCT SECTION */
  .shop-main { flex: 1; min-width: 0; }
  .breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 0;
    width: 100%;
    text-align: left;
    font-size: 12px;
    color: #777;
    margin-bottom: 10px;
    line-height: 1.4;
  }
  .breadcrumb a { color: #ff4fc8; text-decoration: none; }
  .breadcrumb a:hover { text-decoration: underline; }
  .breadcrumb span[aria-hidden="true"] { margin: 0 4px; color: #999; }
  .breadcrumb .current { color: #333; }
  .seo-desc { font-size: 13px; color: rgba(0,0,0,.6); line-height: 1.6; margin-bottom: 16px; max-width: 860px; }
  .shop-topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
  .shop-count { font-size: 13px; color: #555; }
  .sort-box { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #555; }
  .sort-box select { border: 1px solid #ddd; border-radius: 4px; padding: 6px 10px; font-size: 13px; color: #555; font-family: inherit; }

  /* PRODUCT GRID */
  /* WordPress: WooCommerce loop template */
  .product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; align-items: stretch; }
  .product-card { background: #fff; border: 2px solid #f1f1f1; border-radius: 14px; overflow: hidden; transition: box-shadow .2s, transform .2s; display: flex; flex-direction: column; height: 100%; }
  .product-card:hover { box-shadow: 0 8px 24px color-mix(in srgb, var(--dpy-magenta, #e91e8c) 12%, transparent); transform: translateY(-2px); }
  .pc-img { background: #f5f5f5; aspect-ratio: 1 / 1; height: auto; display: flex; align-items: center; justify-content: center; position: relative; flex-shrink: 0; }
  .pc-img .material-icons { font-size: 48px; color: rgba(0,0,0,.12); }
  .pc-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
  .pc-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    background: var(--dpy-magenta, #e91e8c);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 3px;
    line-height: 1.2;
  }
  .pc-body { padding: 8px 10px 10px; display: flex; flex-direction: column; flex: 1 1 auto; gap: 0; }
  .pc-name { font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 12px; color: #222; text-align: center; line-height: 1.35; margin: 0 0 4px; min-height: 32px; }
  /* Slot fijo de swatches (vacío o con colores) para alinear precios/CTA sin huecos grandes */
  .pc-swatches { display: flex; justify-content: center; align-items: center; gap: 5px; margin: 0 0 4px; height: 18px; min-height: 18px; flex-shrink: 0; overflow: hidden; }
  .swatch { width: 16px; height: 16px; border-radius: 50%; border: 2px solid #ddd; flex-shrink: 0; }
  .swatch.sel { border-color: #333; }
  .pc-prices { text-align: center; margin: 0 0 6px; min-height: 2.4em; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 1px; }
  .pc-old { font-size: 10px; color: #aaa; text-decoration: line-through; display: block; line-height: 1.2; }
  .pc-new { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 15px; color: #ff1493; display: block; line-height: 1.2; }
  .btn-ver-prod {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: var(--dpy-magenta, #e91e8c);
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 11px;
    min-height: 44px;
    padding: 10px 8px;
    box-sizing: border-box;
    border-radius: 8px;
    transition: background .15s;
    margin-top: auto;
    flex-shrink: 0;
    text-decoration: none;
  }
  .btn-ver-prod:hover,
  .btn-ver-prod:focus-visible { background: var(--dpy-magenta-dark, #c2185b); color: #fff; }

  /* PAGINATION */
  .pagination { display: flex; justify-content: center; gap: 6px; margin-top: 32px; }
  .page-btn { width: 42px; height: 42px; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 14px; border: 1px solid #ff1393; color: #fd00ae; cursor: pointer; transition: all .15s; }
  .page-btn.active { background: #ff1393; color: #fff; border-color: #ff1393; }
  .page-btn:hover:not(.active) { background: #fff0f6; }

  /* FOOTER */
body.dpy-shop-pure .tab-chip { text-decoration: none; display: inline-block; }
body.dpy-shop-pure .woocommerce-ordering,
body.dpy-shop-pure .woocommerce-result-count {
  margin: 0;
  padding: 0;
}
body.dpy-shop-pure .sort-box .woocommerce-ordering {
  display: inline;
}
body.dpy-shop-pure .pagination .woocommerce-pagination {
  width: 100%;
}
body.dpy-shop-pure .woocommerce-pagination ul.page-numbers {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  max-width: none;
  height: auto;
  margin: 32px 0 0;
  padding: 0;
  list-style: none;
  border: 0;
  background: transparent;
}
body.dpy-shop-pure .woocommerce-pagination ul.page-numbers li {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
}
/* Solo enlaces/spans: ul también tiene class page-numbers y no debe heredar width:42px. */
body.dpy-shop-pure .woocommerce-pagination li .page-numbers {
  box-sizing: border-box;
  width: 42px;
  height: 42px;
  border-radius: 4px;
  border: 1px solid #ff1393;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: #fd00ae;
  text-decoration: none;
}
body.dpy-shop-pure .woocommerce-pagination li .page-numbers.current {
  background: #ff1393;
  color: #fff;
  border-color: #ff1393;
}
body.dpy-shop-pure .woocommerce-pagination li a.page-numbers:hover {
  background: #fff0f6;
}
body.dpy-shop-pure .pc-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
