/* Barman.cz — Dárkové sady, category 2015 only.
 * Native products, links, prices, availability, cart forms and favourites remain.
 * The enhancement class is applied by barman-gifts-v1.js after initialization.
 */

body.id-2015.type-category.bm-gifts-enhanced {
  --bm-gifts-ink: #111111;
  --bm-gifts-muted: #595959;
  --bm-gifts-line: #e3e3e3;
  --bm-gifts-pink: #ed2195;
  --bm-gifts-pink-light: #fff0f8;
  --bm-gifts-focus: #9400c4;
}

/* Author display rules must not override the currency guard's hidden state. */
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-budgets[hidden],
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters[hidden] {
  display: none !important;
}

/* Remove the duplicate promotion strip and replace only the old card copy. */
body.id-2015.type-category.bm-gifts-enhanced .products-top-wrapper,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .flags-default,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-desc {
  display: none !important;
}

/* Category controls: real links and native filters; no fixed counts or prices. */
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-controls {
  clear: both;
  margin: 18px 0 12px;
  padding: 14px 0;
  border-top: 1px solid var(--bm-gifts-line);
  border-bottom: 1px solid var(--bm-gifts-line);
  background: #ffffff;
  color: var(--bm-gifts-ink);
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-filterbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 18px;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-budgets {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  min-width: 0;
}

body.id-2015.type-category.bm-gifts-enhanced a.bm-gifts-budget {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 9px 13px;
  border: 1px solid #cecece;
  border-radius: 6px;
  background: #ffffff;
  color: var(--bm-gifts-ink);
  font: inherit;
  font-size: 13px;
  line-height: 1.35;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}

body.id-2015.type-category.bm-gifts-enhanced a.bm-gifts-budget:hover {
  border-color: var(--bm-gifts-pink);
  background: #fff8fc;
}

body.id-2015.type-category.bm-gifts-enhanced a.bm-gifts-budget.is-active,
body.id-2015.type-category.bm-gifts-enhanced a.bm-gifts-budget[aria-current="true"] {
  border-color: var(--bm-gifts-pink);
  box-shadow: inset 0 0 0 1px var(--bm-gifts-pink);
  background: var(--bm-gifts-pink-light);
  color: var(--bm-gifts-ink);
  font-weight: 600;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-stock {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin: 0;
  color: var(--bm-gifts-ink);
  font-size: 13px;
  line-height: 1.4;
  cursor: pointer;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-stock input[type="checkbox"] {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--bm-gifts-pink);
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters {
  margin-top: 8px;
  color: var(--bm-gifts-ink);
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters > summary {
  width: fit-content;
  max-width: 100%;
  min-height: 44px;
  padding: 11px 4px;
  color: var(--bm-gifts-ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  cursor: pointer;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters[open] > summary {
  margin-bottom: 8px;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters #filters {
  float: none !important;
  width: 100% !important;
  max-width: none !important;
  margin: 0;
  padding: 0;
  background: #ffffff;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters[open] #filters {
  display: block !important;
}

body.id-2015.type-category.bm-gifts-enhanced #category-header {
  margin-top: 0;
  margin-bottom: 14px;
}

body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
}

body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting > li {
  margin: 0;
  padding: 0;
  list-style: none;
}

body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting button,
body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting a {
  min-height: 44px;
  margin: 0;
  padding: 9px 11px;
  color: var(--bm-gifts-ink);
  font-size: 13px;
  line-height: 1.4;
  white-space: nowrap;
}

/* Four columns on desktop, two on phones. No product nodes are reordered. */
body.id-2015.type-category.bm-gifts-enhanced #products {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  align-items: stretch;
  background: #ffffff;
}

body.id-2015.type-category.bm-gifts-enhanced #products::before,
body.id-2015.type-category.bm-gifts-enhanced #products::after {
  display: none !important;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product {
  float: none !important;
  flex: none !important;
  width: auto !important;
  min-width: 0;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-width: 0;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--bm-gifts-line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--bm-gifts-ink);
  box-shadow: none;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .image {
  display: block;
  flex: 0 0 auto;
  width: 100%;
  height: auto;
  margin: 0 0 12px;
  padding: 0;
  background: #ffffff;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .image img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-in {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-in-in {
  height: auto;
  min-height: 0;
  padding: 0;
  color: var(--bm-gifts-ink);
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a.name {
  display: block;
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  margin: 0 0 8px;
  padding: 0;
  overflow: visible !important;
  color: var(--bm-gifts-ink);
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  text-transform: none;
  text-decoration: none;
  -webkit-line-clamp: unset;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a.name:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-purpose {
  margin: 0 0 6px;
  color: #684b5c;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-copy {
  margin: 0 0 9px;
  color: var(--bm-gifts-muted);
  font-size: 13px;
  line-height: 1.5;
}

body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-bonus {
  margin: 0 0 10px;
  color: #5c1d48;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .ratings-wrapper {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  margin: 10px 0;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .availability {
  height: auto;
  min-height: 0;
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .prices {
  margin: 0;
  color: var(--bm-gifts-ink);
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .price-final {
  color: var(--bm-gifts-ink);
  font-size: 23px;
  font-weight: 700;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .price-additional {
  color: var(--bm-gifts-muted);
  font-size: 12px;
  line-height: 1.4;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-bottom {
  margin-top: auto;
  padding-top: 10px;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-tools {
  width: 100%;
  min-width: 0;
  margin: 0;
}

/* Keep native add-to-cart forms and plus/minus controls fully operable. */
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-tools form {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 8px;
  width: 100%;
  margin: 0;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-tools form .quantity {
  box-sizing: border-box;
  position: relative;
  display: grid !important;
  flex: 1 0 132px;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  grid-template-rows: 44px;
  width: auto !important;
  min-width: 0;
  max-width: 180px;
  height: 44px !important;
  margin: 0 !important;
  padding: 0;
  border: 0;
}

/* Keep native quantity tooltips out of the three-column input layout. */
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity > .increase-tooltip,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity > .decrease-tooltip {
  position: absolute !important;
  pointer-events: none;
}

/* Shoptet wraps the number input in a label; the label is the grid item. */
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity > label {
  box-sizing: border-box;
  display: block;
  grid-column: 2;
  grid-row: 1;
  width: 100%;
  min-width: 0;
  height: 44px;
  margin: 0;
  padding: 0;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity input:not([type="hidden"]) {
  box-sizing: border-box;
  position: static !important;
  grid-column: 2;
  grid-row: 1;
  width: 100% !important;
  min-width: 0;
  max-width: none;
  height: 44px !important;
  min-height: 44px;
  margin: 0;
  padding: 6px 2px;
  border: 1px solid #cecece;
  border-radius: 0;
  color: var(--bm-gifts-ink);
  background: #ffffff;
  font-size: 15px;
  line-height: 1.2;
  text-align: center;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .increase,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .decrease {
  box-sizing: border-box;
  position: static !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  grid-row: 1;
  width: 44px !important;
  min-width: 44px;
  height: 44px !important;
  min-height: 44px;
  margin: 0;
  padding: 0;
  border: 1px solid #cecece;
  border-radius: 0;
  background: #f7f7f7;
  color: var(--bm-gifts-ink);
  line-height: 1;
  cursor: pointer;
  touch-action: manipulation;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .decrease {
  grid-column: 1;
  border-right: 0;
  border-radius: 5px 0 0 5px;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .increase {
  grid-column: 3;
  border-left: 0;
  border-radius: 0 5px 5px 0;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .increase::before,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .quantity .decrease::before {
  position: static !important;
  margin: 0;
  transform: none;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .btn-cart {
  display: inline-flex;
  flex: 1 0 100px;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 44px;
  margin: 0;
  padding: 10px 9px;
  border: 1px solid var(--bm-gifts-pink);
  border-radius: 5px;
  background: var(--bm-gifts-pink);
  color: var(--bm-gifts-ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  text-transform: none;
  white-space: normal;
}

body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .btn-cart:hover {
  border-color: #d91983;
  background: #f34aa8;
  color: var(--bm-gifts-ink);
}

/* Add focus treatment without changing the native controls' behaviour. */
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-controls a:focus-visible,
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-controls input:focus-visible,
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-controls summary:focus-visible,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a:focus-visible,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p button:focus-visible,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p input:focus-visible {
  outline: 3px solid var(--bm-gifts-focus);
  outline-offset: 3px;
}

@media (max-width: 767px) {
  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-controls {
    margin-top: 14px;
    padding: 10px 0;
  }

  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-filterbar {
    align-items: flex-start;
    gap: 8px;
  }

  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-budgets {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
    width: 100%;
  }

  body.id-2015.type-category.bm-gifts-enhanced a.bm-gifts-budget {
    padding: 8px 6px;
    font-size: 12px;
  }

  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-more-filters {
    margin-top: 0;
  }

  body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting {
    gap: 5px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting button,
  body.id-2015.type-category.bm-gifts-enhanced #category-header .listSorting a {
    padding-right: 8px;
    padding-left: 8px;
    font-size: 12px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p {
    padding: 10px;
    border-radius: 7px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .image {
    margin-bottom: 10px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a.name {
    font-size: 14px;
    line-height: 1.4;
  }

  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-purpose,
  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-bonus {
    font-size: 11.5px;
  }

  body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-copy {
    font-size: 12px;
    line-height: 1.45;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .price-final {
    font-size: 21px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-tools form {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 7px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-tools form .quantity {
    width: 100% !important;
    max-width: none;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .btn-cart {
    width: 100%;
    min-height: 44px;
    padding: 10px 5px;
    font-size: 12px;
  }
}

@media (max-width: 359px) {
  body.id-2015.type-category.bm-gifts-enhanced #products {
    gap: 8px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p {
    padding: 8px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a.name {
    font-size: 13px;
  }

  body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .price-final {
    font-size: 20px;
  }
}

/* v2: adjustments verified against the live Barman.cz template. */
body.id-2015.type-category.bm-gifts-enhanced .filters-wrapper {
  display: none !important;
}
body.id-2015.type-category.bm-gifts-enhanced .bm-gifts-stock input[type="checkbox"] {
  position: static !important;
  display: inline-block !important;
  clip: auto !important;
  clip-path: none !important;
  appearance: auto !important;
  -webkit-appearance: checkbox !important;
  width: 20px !important;
  height: 20px !important;
  padding: 0;
  overflow: visible;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .p-in-in {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .ratings-wrapper {
  margin-top: auto;
  padding-top: 12px;
  min-height: 0;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .stars-placeholder:empty {
  display: none;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p a.name,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .availability,
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .prices {
  text-align: left !important;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .availability span {
  font-size: inherit;
  line-height: inherit;
}
@media (max-width: 767px) {
  body.id-2015.type-category.bm-gifts-enhanced #category-header {
    flex-direction: column;
    align-items: stretch;
  }
  body.id-2015.type-category.bm-gifts-enhanced #category-header .listItemsTotal {
    display: block !important;
    float: none;
    margin: 8px 0 0;
    color: #595959;
    font-size: 12px;
    line-height: 1.5;
  }
}

/* v3: prevent the theme's wrapped column from pushing prices out of cards. */
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .ratings-wrapper {
  flex: 0 0 auto;
  flex-wrap: nowrap !important;
  align-items: stretch;
  height: auto !important;
  max-height: none;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .availability {
  width: 100%;
  height: auto !important;
  min-height: 0;
  flex: 0 0 auto;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .prices {
  flex: 0 0 auto;
  width: 100%;
  max-width: 100%;
  height: auto !important;
  align-items: flex-start;
}
body.id-2015.type-category.bm-gifts-enhanced #products > .product > .p .price-final {
  align-self: flex-start;
}
