/* =========================================================
   Farbror Fisk — Product Cards (Fiskdirekt-inspired)
   ========================================================= */

/* ---- Grid ---- */
.ff-product-col {
  padding-left: 6px;
  padding-right: 6px;
  margin-bottom: 12px;
}

.woocommerce ul.products {
  gap: 0 !important;
  row-gap: 0 !important;
}

/* ---- Card link wrapper ---- */
.ff-product-card {
  display: block;
  text-decoration: none !important;
  color: inherit;
  transition: opacity 0.2s ease;
}
.ff-product-card:hover {
  opacity: 0.88;
  color: inherit;
  text-decoration: none !important;
}

/* ---- Image ---- */
.ff-product-image {
  overflow: hidden;
  border-radius: 0;
  line-height: 0;
}

.ff-product-image img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 4px;
}
/* ---- Info area ---- */
.ff-product-info {
  padding: 0.7rem 0 0.3rem;
}

/* ---- Title + add icon row ---- */
.ff-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.ff-product-title {
  font-family: 'Jost', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.3;
  margin: 0;
  color: #1a1a1a;
  flex: 1;
  text-transform: none;
  letter-spacing: 0;
}

.ff-add-icon {
  flex-shrink: 0;
  color: #444;
  transition: color 0.15s ease;
  margin-top: 1px;
}
.ff-product-card:hover .ff-add-icon {
  color: #000;
}

/* ---- Price ---- */
.ff-product-price {
  font-family: 'Jost', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: #111;
  margin: 0.2rem 0 0;
  letter-spacing: -0.01em;
}

/* ---- Remove old Bootscore card styling that leaks through ---- */
.woocommerce ul.products li.product .card,
.woocommerce ul.products li.product .card-body {
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
  padding: 0 !important;
  border-radius: 0 !important;
}

.woocommerce ul.products li.product .card {
  height: auto !important;
}

/* ---- Responsive tweaks ---- */
@media (max-width: 575.98px) {
  .ff-product-title {
    font-size: 0.85rem;
  }
  .ff-product-price {
    font-size: 0.95rem;
  }
  .ff-add-icon svg {
    width: 24px;
    height: 24px;
  }
}

/* =========================================================
   Single Product Page
   ========================================================= */

/* ---- Breadcrumb polish ---- */
.wc-breadcrumb {
  background: transparent !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  font-size: 0.875rem;
}

.wc-breadcrumb .breadcrumb {
  background: transparent;
}

.wc-breadcrumb .breadcrumb-item a {
  color: var(--bs-primary);
  text-decoration: none;
  font-weight: 500;
}

.wc-breadcrumb .breadcrumb-item a:hover {
  text-decoration: underline;
}

/* ---- Per-kg price label ---- */
.ff-price-per-kg {
  font-family: 'Jost', sans-serif;
  font-size: 1rem;
  color: var(--bs-secondary-color);
  margin: 0.25rem 0 0.5rem;
}

.ff-price-per-kg__label {
  text-transform: uppercase;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: var(--bs-secondary-color);
}

.ff-price-per-kg__unit {
  font-size: 0.85rem;
  color: var(--bs-secondary-color);
}

/* ---- "Från" price for variable products ---- */
.ff-price-from {
  text-transform: uppercase;
  font-size: 0.7em;
  font-weight: 600;
  letter-spacing: 0.03em;
  opacity: 0.7;
}

/* ---- Sortiment category headings ---- */
.ff-sortiment-category {
  /* spacing is handled by mb-5 utility */
}

.ff-category-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--bs-primary, #0d2b45);
  border-bottom: 2px solid var(--bs-primary, #0d2b45);
  padding-bottom: 0.5rem;
}

.ff-category-title a {
  color: inherit;
  text-decoration: none;
}

.ff-category-title a:hover {
  opacity: 0.8;
}

.ff-price-unit {
  font-size: 0.6em;
  opacity: 0.7;
}

/* ---- Variation savings badge ---- */
.ff-variation-savings {
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  color: #28753b;
  background: #e9f7ee;
  padding: 0.6rem 1rem;
  border-radius: var(--bs-border-radius);
  margin: 0.5rem 0 1rem;
  font-weight: 500;
}

.ff-variation-savings i {
  color: #28753b;
}

/* ---- Active variation price (bigger, bolder) ---- */
.woocommerce div.product p.price,
.woocommerce div.product span.price {
  font-family: 'Jost', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: #102944;
}

.woocommerce div.product .woocommerce-variation-price .price {
  font-size: 2rem;
  font-weight: 800;
}

/* ---- Hide any leftover WooCommerce tabs ---- */
.woocommerce div.product .woocommerce-tabs {
  display: none !important;
}

/* ---- Inline description (tabs removed) ---- */
.ff-product-description {
  clear: both;
  width: 100%;
  padding: 2.5rem 0 1rem;
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1rem;
  font-family: 'Jost', sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: #333;
}

.ff-product-description h2,
.ff-product-description h3,
.ff-product-description h4 {
  color: #102944;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.ff-product-description h2:first-child {
  margin-top: 0;
}

.ff-product-description ul {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.ff-product-description table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

.ff-product-description table td,
.ff-product-description table th {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--bs-border-color);
  vertical-align: top;
}

.ff-product-description table td:last-child {
  text-align: right;
}

/* ---- Quantity & add to cart row ---- */
.woocommerce div.product form.cart {
  display: flex;
  align-items: stretch;
  gap: 0;
}

.woocommerce div.product form.cart .quantity {
  display: flex;
  align-items: stretch;
  height: auto;
}

.woocommerce div.product form.cart .quantity .qty,
.woocommerce div.product form.cart .quantity .minus,
.woocommerce div.product form.cart .quantity .plus {
  font-family: 'Jost', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  height: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--bs-border-color);
}

.woocommerce div.product form.cart .quantity .qty {
  width: 3.5rem;
  text-align: center;
  border-left: 0;
  border-right: 0;
}

.woocommerce div.product form.cart .quantity .minus {
  border-radius: var(--bs-border-radius) 0 0 var(--bs-border-radius);
}

.woocommerce div.product form.cart .quantity .plus {
  border-radius: 0 var(--bs-border-radius) var(--bs-border-radius) 0;
}

.woocommerce div.product form.cart .single_add_to_cart_button {
  font-family: 'Jost', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.75rem 2rem;
  font-size: 1rem;
  flex: 1;
  margin-left: 0.75rem;
  color: #fff !important;
  background-color: var(--bs-primary) !important;
}

.woocommerce div.product form.cart .single_add_to_cart_button:visited,
.woocommerce div.product form.cart .single_add_to_cart_button:active {
  color: #fff !important;
  background-color: var(--bs-primary) !important;
}

/* ---- Linked recipes on single product ---- */
.ff-product-recipes {
  clear: both;
  width: 100%;
  padding: 2.5rem 0 1rem;
  border-top: 1px solid var(--bs-border-color);
  margin-top: 1.5rem;
}

/* ---- Mobile: smaller quantity + add-to-cart ---- */
@media (max-width: 767.98px) {
  .woocommerce div.product form.cart .quantity .qty,
  .woocommerce div.product form.cart .quantity .minus,
  .woocommerce div.product form.cart .quantity .plus {
    font-size: 0.9rem;
    padding: 0.6rem 0.75rem;
  }

  .woocommerce div.product form.cart .quantity .qty {
    width: 2.8rem;
  }

  .woocommerce div.product form.cart .single_add_to_cart_button {
    font-size: 0.88rem;
    padding: 0.6rem 1.2rem;
    margin-left: 0.5rem;
    letter-spacing: 0.02em;
  }
}

.ff-product-recipes__title {
  font-family: 'DM Serif Text', serif;
  font-size: 1.5rem;
  color: #102944;
  margin-bottom: 1.25rem;
}

.ff-product-recipes__title i {
  color: var(--bs-primary);
}
