/**
 * Mattonflex WooCommerce Styles
 * Basic structure and layout - Designer will add detailed styling
 */

/* ==========================================================================
   Product Page Layout
   ========================================================================== */

.mattonflex-single-product {
  padding: 40px 0;
}

.product-main-content {
  margin-bottom: 40px;
}

.product-gallery-col,
.product-summary-col {
  padding: 15px;
}

/* ==========================================================================
   Product Gallery
   ========================================================================== */

.mattonflex-product-gallery {
  width: 100%;
}

.woocommerce-product-gallery__main-image {
  margin-bottom: 20px;
}

.woocommerce-product-gallery__main-image img {
  width: 100%;
  height: auto;
  display: block;
}

.woocommerce-product-gallery__thumbnails {
  display: flex;
  gap: 10px;
  justify-content: flex-start;
}

.woocommerce-product-gallery__thumbnails .woocommerce-product-gallery__image {
  flex: 0 0 calc(33.333% - 7px);
  max-width: calc(33.333% - 7px);
}

.woocommerce-product-gallery__thumbnails img {
  width: 100%;
  height: auto;
  display: block;
  cursor: pointer;
}

/* ==========================================================================
   Product Summary
   ========================================================================== */

.mattonflex-product-title {
  margin-bottom: 20px;
}

.mattonflex-price-wrapper {
  margin-bottom: 20px;
}

/* .mattonflex-price-wrapper .price {
	font-size: 24px;
	color: #9d4425;
} */

.price-label {
  font-weight: 500;
  font-size: 28px;
}
}

.price-unit {
  font-size: 18px;
}

/* ==========================================================================
   Add to Cart Form
   ========================================================================== */

.mattonflex-package-selector {
  margin-bottom: 20px;
}

.mattonflex-package-selector label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.package-size-select {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

/* ==========================================================================
   Quantity Selector
   ========================================================================== */

.mattonflex-quantity-wrapper {
  margin-bottom: 20px;
}

.mattonflex-quantity-wrapper label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.quantity-selector {
  display: inline-flex;
  align-items: center;
  background: transparent;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  padding: 4px 8px;
  gap: 0;
}

.quantity-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  color: #1b1b25;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 22px;
  font-weight: 500;
  line-height: 1;
  transition: background-color 0.2s ease;
}

.quantity-btn:hover {
  background: #f2f2f2;
}

.quantity-btn:active {
  background: #e5e5e5;
}

/* Input number - remove default spinners */
.quantity-selector input[type="number"],
.mattonflex-quantity-input input[type="number"],
input.qty {
  min-width: 50px;
  width: 50px;
  padding: 6px 4px;
  text-align: center;
  border: none;
  background: transparent;
  font-size: 16px;
  font-weight: 600;
  color: #9d4425;
  -moz-appearance: textfield;
  appearance: textfield;
  transition: color 0.2s ease;
}

/* Over stock warning */
.quantity-selector input.qty.over-stock,
input.qty.over-stock {
  color: #fd1a38;
}

/* Remove spinners for Chrome, Safari, Edge */
.quantity-selector input[type="number"]::-webkit-outer-spin-button,
.quantity-selector input[type="number"]::-webkit-inner-spin-button,
input.qty::-webkit-outer-spin-button,
input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.quantity-selector input[type="number"]:focus,
input.qty:focus {
  outline: none;
}

.summary .product_meta {
  display: none;
}

/* ==========================================================================
   Warnings and Messages
   ========================================================================== */

.mattonflex-quantity-warning {
  background: #fff3cd;
  border: 1px solid #ffc107;
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 4px;
}

.warning-text {
  margin: 0;
  color: #856404;
}

.request-quote-link {
  color: #9d4425;
  font-weight: 600;
  text-decoration: underline;
}

/* ==========================================================================
   Quantity Row (Quantity + Package Info)
   ========================================================================== */

.mattonflex-quantity-row {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 15px;
}

.mattonflex-quantity-row .mattonflex-quantity-wrapper {
  margin-bottom: 0;
}

.package-info-label {
  font-size: 13px;
  color: #666;
  white-space: nowrap;
}

/* Mobile: stack vertically */
@media (max-width: 767px) {
  .mattonflex-quantity-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    flex-wrap: wrap;
    align-content: center;
  }

  .package-info-label {
    margin-top: 5px;
  }
}

/* ==========================================================================
   Package Recap List (small text)
   ========================================================================== */

.package-recap-list {
  list-style: none;
  margin: 0 0 15px 0;
  padding: 0;
  font-size: 12px;
  color: #666;
}

.package-recap-list li {
  display: inline;
}

.package-recap-list li:not(:last-child)::after {
  content: " · ";
}

/* ==========================================================================
   Totals Row (Weight + Price)
   ========================================================================== */

.mattonflex-totals-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 20px;
}

.total-weight-info,
.total-price-info {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.total-weight-label,
.total-label {
  font-size: 14px;
  color: #1b1b25;
}

.total-weight-value {
  font-weight: 600;
  color: #1b1b25;
  font-size: 14px;
}

.total-price-info {
  font-size: 18px;
}

.total-label {
  font-weight: 400;
}

.total-value {
  font-weight: 700;
  color: #9d4425;
}

/* Mobile: stack vertically */
@media (max-width: 767px) {
  .mattonflex-totals-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .total-price-info {
    width: 100%;
    justify-content: space-between;
  }
}

/* ==========================================================================
   Add to Cart Button
   ========================================================================== */

.mattonflex-add-to-cart {
  width: 100%;
  background: #9d4425;
  color: #fff;
  padding: 15px 30px;
  border: none;
  border-radius: 4px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
}

.mattonflex-add-to-cart:hover {
  background: #7d3419;
}

/* ==========================================================================
   Bulk Quote Modal
   ========================================================================== */

.mattonflex-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
}

.modal-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #fff;
  padding: 40px;
  border-radius: 8px;
  max-width: 600px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: transparent;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
}

.modal-icon {
  text-align: center;
  font-size: 48px;
  color: #ffc107;
  margin-bottom: 20px;
}

.modal-title {
  text-align: center;
  margin-bottom: 30px;
  color: #1b1b25;
}

.modal-form .form-group {
  margin-bottom: 20px;
}

.modal-form label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.modal-form input[type="text"],
.modal-form input[type="email"],
.modal-form input[type="tel"],
.modal-form textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.modal-form button[type="submit"] {
  width: 100%;
  background: #9d4425;
  color: #fff;
  padding: 12px;
  border: none;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
}

/* ==========================================================================
   Additional Information Section
   ========================================================================== */

.product-additional-info {
  margin-bottom: 40px;
}

.additional-info-title {
  margin-bottom: 20px;
  color: #1b1b25;
}

.mattonflex-additional-info .shop_attributes {
  width: 100%;
  border-collapse: collapse;
}

.mattonflex-additional-info .attribute-row {
  border-bottom: 1px solid #ddd;
}

.mattonflex-additional-info .attribute-label {
  width: 30%;
  padding: 15px;
  font-weight: 600;
  text-align: left;
}

.mattonflex-additional-info .attribute-value {
  padding: 15px;
}

.download-link,
.tutorial-link {
  color: #9d4425;
  text-decoration: underline;
}

/* ==========================================================================
   Related Products Carousel
   ========================================================================== */

.mattonflex-related-products {
  margin-bottom: 40px;
}

.mattonflex-related-products h2 {
  margin-bottom: 20px;
  color: #1b1b25;
}

.related-products-slider {
  position: relative;
}

.related-product-slide {
  padding: 10px;
}

.product-card {
  text-align: center;
}

.product-card img {
  width: 100%;
  height: auto;
  margin-bottom: 15px;
}

.product-title {
  font-size: 16px;
  margin-bottom: 10px;
}

.slick-nav-arrows {
  margin-top: 20px;
  text-align: center;
}

.slick-prev,
.slick-next {
  width: 38px;
  height: 38px;
  background: #9d4425;
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  margin: 0 5px;
}

/* ==========================================================================
   Carousels (Inspiration, Colors, etc.)
   ========================================================================== */

.product-inspiration-section,
.product-colors-section {
  margin-bottom: 40px;
}

.section-title {
  margin-bottom: 20px;
  color: #9d4425;
  font-weight: 500;
}

/* ==========================================================================
   Shop Page - Hero Section
   ========================================================================== */

.mattonflex-shop-page {
  padding: 0;
}

.shop-hero {
  text-align: center;
  padding: 80px 0 60px;
  background: linear-gradient(180deg, #faf9f7 0%, #fff 100%);
}

.shop-hero-title {
  font-size: 48px;
  color: #9d4425;
  font-weight: 300;
  margin: 0 0 15px 0;
  letter-spacing: -0.5px;
}

.shop-hero-subtitle {
  font-size: 18px;
  color: #666;
  margin: 0;
  font-weight: 400;
}

/* ==========================================================================
   Shop Page - Sections
   ========================================================================== */

.shop-section {
  padding: 60px 0;
}

.shop-section-mattone {
  background: #fff;
}

.shop-section-accessori {
  background: #faf9f7;
}

.shop-section-title {
  font-size: 32px;
  color: #1b1b25;
  font-weight: 400;
  margin: 0 0 40px 0;
  position: relative;
  padding-bottom: 20px;
}

.shop-section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: #9d4425;
}

/* ==========================================================================
   Shop Page - Products Grid
   ========================================================================== */

.shop-products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

@media (max-width: 992px) {
  .shop-products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .shop-products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .shop-hero {
    padding: 60px 0 40px;
  }

  .shop-hero-title {
    font-size: 36px;
  }

  .shop-section {
    padding: 40px 0;
  }

  .shop-section-title {
    font-size: 26px;
    margin-bottom: 30px;
  }
}

@media (max-width: 480px) {
  .shop-products-grid {
    grid-template-columns: 1fr;
  }

  .shop-hero-title {
    font-size: 32px;
  }

  .shop-hero-subtitle {
    font-size: 16px;
  }
}

/* ==========================================================================
   Shop Page - Product Card
   ========================================================================== */

.shop-product-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.shop-product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.shop-product-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.shop-product-image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: #f5f5f5;
}

.shop-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.shop-product-card:hover .shop-product-image img {
  transform: scale(1.08);
}

.shop-product-content {
  padding: 20px;
}

.shop-product-title {
  font-size: 16px;
  font-weight: 500;
  color: #1b1b25;
  margin: 0 0 10px 0;
  line-height: 1.4;
}

.shop-product-price {
  font-size: 18px;
  font-weight: 600;
  color: #9d4425;
}

.shop-product-price del {
  color: #999;
  font-weight: 400;
  margin-right: 8px;
  font-size: 14px;
}

.shop-product-price ins {
  text-decoration: none;
}

/* Legacy product card styles (for other pages) */
.products {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  list-style: none;
  padding: 0;
  margin: 0;
}

@media (max-width: 992px) {
  .products {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .products {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .products {
    grid-template-columns: 1fr;
  }
}

.mattonflex-product-card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
  transition:
    box-shadow 0.3s ease,
    transform 0.3s ease;
}

.mattonflex-product-card:hover {
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(-3px);
}

.mattonflex-product-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.mattonflex-product-image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1;
  background: #f5f5f5;
}

.mattonflex-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.mattonflex-product-card:hover .mattonflex-product-image img {
  transform: scale(1.05);
}

.mattonflex-product-image .onsale {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #9d4425;
  color: #fff;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 4px;
}

.mattonflex-product-info {
  padding: 20px;
  text-align: center;
}

.mattonflex-product-title {
  font-weight: 400;
  margin: 0 0 10px 0;
  line-height: 1.4;
  font-size: 30px;
}

.mattonflex-product-price {
  font-size: 18px;
  font-weight: 600;
  color: #9d4425;
}

.mattonflex-product-price del {
  color: #999;
  font-weight: 400;
  margin-right: 8px;
}

.mattonflex-product-price ins {
  text-decoration: none;
}

.mattonflex-product-actions {
  padding: 0 20px 20px;
  text-align: center;
}

.mattonflex-product-actions .button {
  display: inline-block;
  background: #9d4425;
  color: #fff;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.3s ease;
}

.mattonflex-product-actions .button:hover {
  background: #7d3419;
}

/* ==========================================================================
   Cart Page
   ========================================================================== */

.mattonflex-cart-page {
  padding: 60px 0;
}

.cart-title {
  font-size: 36px;
  color: #9d4425;
  font-weight: 300;
  margin-bottom: 40px;
  text-align: center;
}

/* Cart Table */
.woocommerce-cart-form .shop_table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 30px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.woocommerce-cart-form .shop_table thead th {
  background: #f8f8f8;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #666;
  padding: 18px 20px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.woocommerce-cart-form .shop_table tbody td {
  padding: 20px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
}

.woocommerce-cart-form .shop_table tbody tr:last-child td {
  border-bottom: none;
}

/* Product Thumbnail */
.woocommerce-cart-form .product-thumbnail {
  width: 100px;
}

.woocommerce-cart-form .product-thumbnail img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
}

/* Product Name */
.woocommerce-cart-form .product-name a {
  color: #1b1b25;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
}

.woocommerce-cart-form .product-name a:hover {
  color: #9d4425;
}

.woocommerce-cart-form .product-name .variation {
  margin-top: 8px;
  font-size: 13px;
  color: #666;
}

/* Product Price */
.woocommerce-cart-form .product-price,
.woocommerce-cart-form .product-subtotal {
  font-weight: 600;
  color: #1b1b25;
}

.woocommerce-cart-form .product-subtotal {
  color: #9d4425;
}

/* Quantity in Cart */
.woocommerce-cart-form .product-quantity .quantity {
  display: inline-flex;
  align-items: center;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  padding: 4px 8px;
}

.woocommerce-cart-form .product-quantity input.qty {
  min-width: 50px;
  width: 50px;
  text-align: center;
  border: none;
  font-weight: 600;
  color: #9d4425;
  background: transparent;
  -moz-appearance: textfield;
  appearance: textfield;
}

.woocommerce-cart-form .product-quantity input.qty::-webkit-outer-spin-button,
.woocommerce-cart-form .product-quantity input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Remove Button */
.woocommerce-cart-form .product-remove {
  width: 60px;
  text-align: center;
}

.woocommerce-cart-form .product-remove a.remove {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f5;
  color: #999 !important;
  border-radius: 50%;
  text-decoration: none;
  font-size: 20px;
  line-height: 1;
  transition: all 0.2s ease;
}

.woocommerce-cart-form .product-remove a.remove:hover {
  background: #dc3545;
  color: #fff !important;
}

/* Actions Row */
.woocommerce-cart-form .actions {
  padding: 25px 20px;
  background: #f9f9f9;
}

.woocommerce-cart-form .actions::after {
  content: "";
  display: table;
  clear: both;
}

.woocommerce-cart-form .coupon {
  display: flex;
  align-items: center;
  gap: 10px;
  float: left;
}

.woocommerce-cart-form .coupon label {
  display: none;
}

.woocommerce-cart-form .coupon input.input-text {
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  width: 200px;
  font-size: 14px;
}

.woocommerce-cart-form .coupon input.input-text:focus {
  border-color: #9d4425;
  outline: none;
}

.woocommerce-cart-form .coupon .button {
  background: #1b1b25;
  color: #fff;
  padding: 14px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.woocommerce-cart-form .coupon .button:hover {
  background: #000;
}

.woocommerce-cart-form button[name="update_cart"] {
  float: right;
  background: #1b1b25;
  color: #fff;
  padding: 14px 24px;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.woocommerce-cart-form button[name="update_cart"]:hover {
  background: #000;
}

.woocommerce-cart-form button[name="update_cart"]:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Cart Collaterals (Totals Box) */
.cart-collaterals {
  width: 100%;
  max-width: 600px;
  margin: 40px auto 0;
}

.cart_totals {
  background: #fff;
  padding: 35px 40px;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.cart_totals h2 {
  font-size: 22px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 24px 0;
  padding-bottom: 16px;
  border-bottom: 1px solid #eee;
  text-align: center;
}

/* Cart Totals Flex Layout */
.cart-totals-rows {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 24px;
}

.cart-totals-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid #eee;
}

.cart-totals-row:last-child {
  border-bottom: none;
}

.cart-totals-row .row-label {
  font-size: 14px;
  font-weight: 500;
  color: #666;
  flex-shrink: 0;
}

.cart-totals-row .row-value {
  font-size: 14px;
  font-weight: 500;
  color: #1b1b25;
  text-align: right;
}

/* Shipping row - full width content */
.cart-totals-row.shipping {
  flex-direction: column;
  gap: 12px;
}

.cart-totals-row.shipping .row-label {
  font-size: 14px;
  font-weight: 600;
  color: #1b1b25;
}

.cart-totals-row.shipping .row-value,
.cart-totals-row.shipping .shipping-content {
  width: 100%;
  text-align: left;
}

/* Order Total Row */
.cart-totals-row.order-total {
  margin-top: 8px;
  padding-top: 20px;
  border-top: 2px solid #9d4425;
  border-bottom: none;
}

.cart-totals-row.order-total .row-label {
  font-size: 18px;
  font-weight: 600;
  color: #1b1b25;
}

.cart-totals-row.order-total .row-value {
  font-size: 20px;
  font-weight: 700;
  color: #9d4425;
}

/* Proceed to Checkout Button */
.wc-proceed-to-checkout {
  margin-top: 5px;
}

.wc-proceed-to-checkout a.checkout-button {
  display: block;
  width: 100%;
  padding: 18px 30px;
  background: #9d4425;
  color: #fff;
  text-align: center;
  text-decoration: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: background 0.2s ease;
  box-sizing: border-box;
}

.wc-proceed-to-checkout a.checkout-button:hover {
  background: #7a3319;
  color: #fff;
}

/* ==========================================================================
   Shipping Methods List (Cart)
   ========================================================================== */

.woocommerce-shipping-methods {
  list-style: none;
  padding: 0;
  margin: 0;
}

.woocommerce-shipping-methods li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 8px;
  margin-bottom: 8px;
  transition: all 0.2s ease;
}

.woocommerce-shipping-methods li:last-child {
  margin-bottom: 0;
}

.woocommerce-shipping-methods li:hover {
  border-color: #ddd;
  background: #f5f5f5;
}

/* Radio Button Custom Style */
.woocommerce-shipping-methods input.shipping_method {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid #ccc;
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}

.woocommerce-shipping-methods input.shipping_method:checked {
  border-color: #9d4425;
  background: #fff;
}

.woocommerce-shipping-methods input.shipping_method:checked::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 10px;
  background: #9d4425;
  border-radius: 50%;
}

.woocommerce-shipping-methods input.shipping_method:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(157, 68, 37, 0.15);
}

/* Shipping Method Label */
.woocommerce-shipping-methods label {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  color: #1b1b25;
  cursor: pointer;
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.woocommerce-shipping-methods label .woocommerce-Price-amount {
  font-weight: 600;
  color: #9d4425;
}

/* Selected Method Highlight */
.woocommerce-shipping-methods li:has(input:checked) {
  border-color: #9d4425;
  background: rgba(157, 68, 37, 0.05);
}

/* Shipping Destination Text */
.woocommerce-shipping-destination {
  font-size: 13px;
  color: #666;
  margin: 12px 0 0 0;
  padding-top: 12px;
  border-top: 1px solid #eee;
}

.woocommerce-shipping-destination strong {
  color: #1b1b25;
}

/* ==========================================================================
   Shipping Calculator Form (Cart)
   ========================================================================== */

.cart_totals .shipping-calculator-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #9d4425;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
}

.cart_totals .shipping-calculator-button:hover {
  color: #7a3319;
  text-decoration: underline;
}

.cart_totals .shipping-calculator-button::before {
  content: "📍";
  font-size: 14px;
}

.shipping-calculator-form {
  margin-top: 20px;
  padding: 20px;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 12px;
}

.shipping-calculator-form .form-row {
  margin-bottom: 16px;
}

.shipping-calculator-form .form-row:last-of-type {
  margin-bottom: 20px;
}

.shipping-calculator-form label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #666;
  margin-bottom: 6px;
}

.shipping-calculator-form select,
.shipping-calculator-form input[type="text"] {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.4;
  min-height: 50px;
  color: #1b1b25;
  background: #fff;
  transition: all 0.2s ease;
  -webkit-appearance: none;
  appearance: none;
  box-sizing: border-box;
}

.shipping-calculator-form select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
  cursor: pointer;
}

.shipping-calculator-form select:focus,
.shipping-calculator-form input[type="text"]:focus {
  outline: none;
  border-color: #9d4425;
  box-shadow: 0 0 0 3px rgba(157, 68, 37, 0.1);
}

.shipping-calculator-form button[type="submit"],
.shipping-calculator-form button[name="calc_shipping"] {
  width: 100%;
  padding: 14px 24px;
  background: #9d4425;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.shipping-calculator-form button[type="submit"]:hover,
.shipping-calculator-form button[name="calc_shipping"]:hover {
  background: #7a3319;
}

/* State field has span wrapper - fix layout */
.shipping-calculator-form .form-row > span {
  display: block;
  width: 100%;
}

.shipping-calculator-form .form-row > span select,
.shipping-calculator-form .form-row > span .state_select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.4;
  min-height: 50px;
  color: #1b1b25;
  background: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.shipping-calculator-form .form-row > span select:focus {
  outline: none;
  border-color: #9d4425;
  box-shadow: 0 0 0 3px rgba(157, 68, 37, 0.1);
}

/* Hidden shipping inputs (when state has no dropdown) */
.shipping-calculator-form input[type="hidden"] + span {
  display: block;
}

/* ==========================================================================
   Notices
   ========================================================================== */

.mattonflex-notice {
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 4px;
}

.mattonflex-notice ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mattonflex-notice li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mattonflex-notice-error {
  background: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}

.mattonflex-notice-success {
  background: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 991px) {
  .product-gallery-col,
  .product-summary-col {
    margin-bottom: 30px;
  }

  .woocommerce-product-gallery__thumbnails {
    flex-wrap: wrap;
  }
}

@media (max-width: 767px) {
  .modal-content {
    padding: 20px;
  }

  /* Cart Page Mobile */
  .cart-title {
    font-size: 28px;
  }

  .woocommerce-cart-form .shop_table {
    font-size: 14px;
  }

  .woocommerce-cart-form .shop_table thead {
    display: none;
  }

  .woocommerce-cart-form .shop_table tbody tr {
    display: flex;
    flex-wrap: wrap;
    padding: 20px;
    border-bottom: 1px solid #eee;
    position: relative;
  }

  .woocommerce-cart-form .shop_table tbody td {
    border: none;
    padding: 5px 10px;
  }

  .woocommerce-cart-form .product-thumbnail {
    width: 80px;
    padding: 0;
  }

  .woocommerce-cart-form .product-thumbnail img {
    width: 70px;
    height: 70px;
  }

  .woocommerce-cart-form .product-name {
    flex: 1;
    padding-left: 15px;
  }

  .woocommerce-cart-form .product-price {
    display: none;
  }

  .woocommerce-cart-form .product-quantity,
  .woocommerce-cart-form .product-subtotal {
    width: 50%;
    margin-top: 15px;
  }

  .woocommerce-cart-form .product-quantity {
    text-align: left;
  }

  .woocommerce-cart-form .product-subtotal {
    text-align: right;
  }

  .woocommerce-cart-form .product-remove {
    position: absolute;
    top: 15px;
    right: 15px;
    width: auto;
  }

  .woocommerce-cart-form .actions {
    text-align: center;
    padding: 20px 15px;
  }

  .woocommerce-cart-form .coupon {
    float: none;
    flex-direction: column;
    width: 100%;
    margin-bottom: 15px;
  }

  .woocommerce-cart-form .coupon input.input-text {
    width: 100%;
  }

  .woocommerce-cart-form button[name="update_cart"] {
    float: none;
    width: 100%;
  }

  .cart-collaterals {
    max-width: 100%;
  }

  .cart_totals {
    padding: 24px 20px;
  }

  .cart_totals h2 {
    font-size: 20px;
  }

  .cart-totals-row {
    padding: 14px 0;
  }

  .cart-totals-row.order-total .row-label {
    font-size: 16px;
  }

  .cart-totals-row.order-total .row-value {
    font-size: 18px;
  }

  /* Shipping Methods Mobile */
  .woocommerce-shipping-methods li {
    padding: 10px 14px;
  }

  .woocommerce-shipping-methods label {
    font-size: 13px;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  /* Shipping Calculator Mobile */
  .shipping-calculator-form {
    padding: 16px;
  }

  .shipping-calculator-form select,
  .shipping-calculator-form input[type="text"] {
    padding: 10px 14px;
  }
}

/* ==========================================================================
   NEW SECTIONS - Based on Figma Design
   ========================================================================== */

/* ==========================================================================
   Product Page Container
   ========================================================================== */

.mattonflex-product-page {
  padding: 0;
}

.product-hero-section {
  padding: 40px 0;
}

/* ==========================================================================
   Product Gallery (Updated)
   ========================================================================== */

.mattonflex-product-gallery {
  width: 100%;
}

.product-gallery__main {
  margin-bottom: 15px;
  overflow: hidden;
  border-radius: 16px;
  aspect-ratio: 16/9;
}

.product-gallery__main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-gallery__thumbnails {
  display: flex;
  gap: 10px;
}

.product-thumbnail {
  flex: 0 0 calc(25% - 8px);
  max-width: calc(25% - 8px);
  aspect-ratio: 16/9;
  cursor: pointer;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.3s ease;
}

.product-thumbnail:hover,
.product-thumbnail.active {
  border-color: #9d4425;
}

.product-thumbnail img {
  width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================================
   Additional Information (Side-by-side layout)
   ========================================================================== */

.product-additional-info-section {
  padding: 40px 0;
}

.additional-info-wrapper {
  display: flex;
  flex-direction: row;
  gap: 40px;
}

.additional-info-title-col {
  flex: 0 0 250px;
  max-width: 250px;
}

.additional-info-title {
  position: sticky;
  top: 120px;
  margin: 0;
  color: #9d4425;
  font-weight: 600;
}

.additional-info-content-col {
  flex: 1;
  min-width: 0;
}

/* Mobile: stack vertically */
@media (max-width: 991px) {
  .additional-info-wrapper {
    flex-direction: column;
    gap: 20px;
  }

  .additional-info-title-col {
    flex: none;
    max-width: 100%;
  }

  .additional-info-title {
    position: static;
    margin-bottom: 0;
  }
}

@media (max-width: 767px) {
  .product-additional-info-section {
    padding: 30px 0;
  }

  .additional-info-wrapper {
    gap: 15px;
  }
}

/* ==========================================================================
   Installation Products Section
   ========================================================================== */

.mattonflex-installation-products {
  padding: 40px 0;
}

.mattonflex-installation-products .section-header {
  margin-bottom: 30px;
}

.mattonflex-installation-products .section-description {
  max-width: 800px;
}

/* Installation Products - card stessa altezza */
.installation-products-slider .slick-track {
  display: flex !important;
}

.installation-products-slider .slick-slide {
  height: inherit !important;
  display: flex !important;
}

.installation-products-slider .slick-slide > div {
  display: flex;
  width: 100%;
}

.installation-product-slide {
  display: flex !important;
  height: 100%;
}

.installation-product-slide .product-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
}

.installation-product-slide .product-card-link {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.installation-product-slide .product-card-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.installation-product-slide .product-card-title {
  flex: 1;
}

.installation-products-slider {
  margin: 0 -10px;
}

.installation-product-slide {
  padding: 0 10px;
  margin-bottom: 10px;
}

.installation-product-slide .product-card {
  background: #fff;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.installation-product-slide .product-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.installation-product-slide .product-card-image img {
  width: 100%;
  height: auto;
}

.installation-product-slide .product-card-info {
  padding: 15px;
}

.installation-product-slide .product-card-title {
  margin: 0 0 5px 0;
  font-weight: 400;
}

.installation-product-slide .product-card-price {
  font-weight: 600;
}

/* Slider navigation */
.mattonflex-installation-products .slider-nav,
.mattonflex-color-variants .slider-nav {
  text-align: right;
  margin-top: 20px;
}

.slider-prev,
.slider-next {
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid #9d4425;
  color: #9d4425;
  border-radius: 50%;
  cursor: pointer;
  margin-left: 10px;
  transition: all 0.3s ease;
}

.slider-prev:hover,
.slider-next:hover {
  background: #9d4425;
  color: #fff;
}

/* ==========================================================================
   Video Section
   ========================================================================== */

.mattonflex-video-section {
  padding: 60px 0;
}

.mattonflex-video-section .section-title {
  margin-bottom: 20px;
}

.video-section-text {
  line-height: 1.6;
}

.video-wrapper {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
}

.video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.video-placeholder {
  position: relative;
}

.video-placeholder .play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 72px;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  cursor: pointer;
}

/* ==========================================================================
   Usage Areas Section
   ========================================================================== */

.mattonflex-usage-areas {
  padding: 60px 0;
}

.mattonflex-usage-areas .section-header {
  max-width: 900px;
  margin: 0 auto 40px;
}

.mattonflex-usage-areas .section-description {
  color: #666;
}

.usage-areas-grid {
  margin: 0 -15px;
}

.usage-area-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 30px;
}

/* Title above image */
.usage-area-title {
  margin-bottom: 15px;
}

/* Square image - max 150px */
.usage-area-image {
  width: 150px;
  height: 150px;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 15px;
  flex-shrink: 0;
}

.usage-area-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.usage-area-placeholder {
  background: #f2f2f2;
  width: 100%;
  height: 100%;
}

/* Description below image */
.usage-area-description {
  max-width: 200px;
}

.usage-area-description p {
  color: #666;
  line-height: 1.5;
}

@media (max-width: 767px) {
  .usage-area-image {
    width: 120px;
    height: 120px;
  }

  .usage-area-description {
    max-width: 160px;
  }
}

.usage-area-link {
  text-decoration: none;
  color: inherit;
}

/* ==========================================================================
   Color Variants Section
   ========================================================================== */

.mattonflex-color-variants {
  padding: 60px 0;
}

.mattonflex-color-variants .section-title {
  margin-bottom: 20px;
}

.mattonflex-color-variants .section-description {
  color: #666;
  line-height: 1.6;
}

.color-variants-slider.slick-slider,
.color-variants-slider.slick-slider > div,
.color-variants-slider.slick-slider > div > div {
  display: flex;
  padding-bottom: 20px;
}

.color-variants-slider {
  margin: 0 -10px;
}

.color-variant-slide {
  padding: 0 10px;
  margin-bottom: 10px;
}

.color-variant-slide .product-card {
  background: #fff;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  height: 100%;
}

.color-variant-slide .product-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.color-variant-slide .product-card-image img {
  width: 100%;
  height: auto;
  aspect-ratio: 1/1;
}

.color-variant-slide .product-card-info {
  padding: 15px;
}

.color-variant-slide .product-card-title {
  margin: 0 0 5px 0;
  font-weight: 400;
}

.color-variant-slide .product-card-price {
  font-weight: 600;
}

/* ==========================================================================
   Certifications Section
   ========================================================================== */

.mattonflex-certifications {
  padding: 60px 0;
}

.mattonflex-certifications .section-header {
  max-width: 900px;
  margin: 0 auto 40px;
}

.mattonflex-certifications .section-description {
  color: #666;
}

.certifications-grid {
  margin: 0 -15px;
}

.certification-card {
  text-align: center;
  padding: 20px;
  margin-bottom: 30px;
}

.certification-logo {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
}

.certification-logo img {
  max-height: 80px;
  max-width: 100%;
  height: auto;
}

.certification-title {
  margin-bottom: 15px;
  color: #666;
}

.certification-download {
  margin-top: 15px;
}

/* Brown download button */
.btn-download-brown {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  background-color: #9d4425;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn-download-brown:hover {
  background-color: #7d3419;
  color: #fff;
  text-decoration: none;
}

.btn-download-brown i {
  font-size: 14px;
}

.btn-download-brown.btn-disabled {
  background-color: #ccc;
  cursor: not-allowed;
  pointer-events: none;
}

/* ==========================================================================
   Responsive Updates for New Sections
   ========================================================================== */

@media (max-width: 991px) {
  .mattonflex-video-section .row {
    flex-direction: column-reverse;
  }

  .mattonflex-video-section .col-md-5,
  .mattonflex-video-section .col-md-7 {
    margin-bottom: 30px;
  }

  .mattonflex-color-variants .row {
    flex-direction: column;
  }

  .mattonflex-color-variants .col-md-4 {
    margin-bottom: 30px;
  }
}

@media (max-width: 767px) {
  .product-gallery__thumbnails {
    flex-wrap: wrap;
  }

  .product-thumbnail {
    flex: 0 0 calc(25% - 8px);
    max-width: calc(25% - 8px);
  }

  .mattonflex-installation-products,
  .mattonflex-video-section,
  .mattonflex-usage-areas,
  .mattonflex-color-variants,
  .mattonflex-certifications {
    padding: 40px 0;
  }

  .certification-logo {
    height: 60px;
  }

  .certification-logo img {
    max-height: 60px;
  }
}

/* ==========================================================================
   Variable Product - Variant Selector (Figma Design)
   ========================================================================== */

.mattonflex-variations {
  margin-bottom: 20px;
}

.mattonflex-variant-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
}

.mattonflex-variant-row .variant-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
  white-space: nowrap;
}

.mattonflex-variant-row .variant-dot {
  width: 12px;
  height: 12px;
  background: #ccc;
  border-radius: 50%;
}

.variant-select-wrapper {
  flex: 1;
}

.mattonflex-variant-select {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
  background: #fff;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23666' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 15px center;
  cursor: pointer;
}

.mattonflex-variant-select:focus {
  border-color: #9d4425;
  outline: none;
}

/* Variable product total price */
.variations_form .mattonflex-total-price {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  font-size: 18px;
}

.variations_form .mattonflex-total-price .total-label {
  font-weight: 400;
}

.variations_form .mattonflex-total-price .total-value,
.variations_form .mattonflex-total-price .price {
  font-weight: 700;
  color: #9d4425;
}

/* Variable product quantity and button layout */
.woocommerce-variation-add-to-cart {
  display: flex;
  align-items: center;
  gap: 15px;
}

.woocommerce-variation-add-to-cart .mattonflex-quantity-wrapper {
  margin-bottom: 0;
  flex: 0 0 auto;
}

.woocommerce-variation-add-to-cart .quantity-selector {
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 0;
}

.woocommerce-variation-add-to-cart .quantity-btn {
  width: 40px;
  height: 40px;
  background: #fff;
  color: #1b1b25;
  border: none;
  border-radius: 0;
  font-size: 18px;
}

.woocommerce-variation-add-to-cart .quantity-btn:hover {
  background: #f2f2f2;
}

.woocommerce-variation-add-to-cart .quantity input {
  width: 50px;
  height: 40px;
  text-align: center;
  border: none;
  border-left: 1px solid #ddd;
  border-right: 1px solid #ddd;
  font-size: 16px;
}

.woocommerce-variation-add-to-cart .mattonflex-add-to-cart {
  flex: 1;
  height: auto;
  padding: 15px 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #9d4425;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
}

.woocommerce-variation-add-to-cart .mattonflex-add-to-cart:hover {
  background: #7d3419;
}

.woocommerce-variation-add-to-cart .mattonflex-add-to-cart:disabled {
  background: #ccc;
  cursor: not-allowed;
}

/* Hide default variation description */
.woocommerce-variation.single_variation {
  display: none !important;
}

/* ==========================================================================
   Environment Section (Rispetto per l'ambiente)
   ========================================================================== */

.product-environment-section {
  padding: 0;
}

.mattonflex-environment-section {
  margin-top: 20px;
}

.mattonflex-environment-section .environment-card {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 25px 30px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
}

.mattonflex-environment-section .environment-icon {
  flex: 0 0 60px;
}

.mattonflex-environment-section .environment-icon svg {
  width: 60px;
  height: 60px;
}

.mattonflex-environment-section .environment-content {
  flex: 1;
}

.mattonflex-environment-section .environment-title {
  font-weight: 400;
  margin-bottom: 8px;
}

.mattonflex-environment-section .environment-text {
  color: #666;
  line-height: 1.5;
  margin: 0 0 15px 0;
}

@media (max-width: 767px) {
  .mattonflex-environment-section .environment-card {
    flex-direction: column;
    text-align: center;
    padding: 20px;
  }

  .mattonflex-environment-section .environment-icon {
    margin: 0 auto;
  }

  .woocommerce-variation-add-to-cart {
    flex-wrap: wrap;
  }

  .woocommerce-variation-add-to-cart .mattonflex-quantity-wrapper {
    width: 100%;
    margin-bottom: 15px;
  }

  .woocommerce-variation-add-to-cart .quantity-selector {
    justify-content: center;
  }

  .woocommerce-variation-add-to-cart .mattonflex-add-to-cart {
    width: 100%;
    flex: none;
  }
}

/* ==========================================================================
   Header Cart Icon
   ========================================================================== */

.header-cart-link {
  display: flex;
  align-items: center;
  padding: 0 15px;
  color: #9d4425;
  font-size: 20px;
  position: relative;
  text-decoration: none;
  border: none !important;
}

.header-cart-link:hover {
  color: #7d3419;
}

.header-cart-link .cart-count {
  position: absolute;
  top: -5px;
  right: 5px;
  background: #9d4425;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

@media (max-width: 991px) {
  .header-cart-link {
    padding: 10px 0;
    justify-content: center;
  }
}

/* ==========================================================================
   Bulk Quote Popup (quantity > 12)
   ========================================================================== */

.mattonflex-bulk-popup {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bulk-popup-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  cursor: pointer;
}

.bulk-popup-content {
  position: relative;
  z-index: 101;
  background: #fff;
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  text-align: center;
  max-width: 400px;
  width: 90%;
}

.bulk-popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  font-size: 24px;
  color: #666;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s ease;
}

.bulk-popup-close:hover {
  color: #1b1b25;
}

.bulk-popup-title {
  margin: 0 0 24px 0;
  font-size: 20px;
  font-weight: 500;
  color: #1b1b25;
  line-height: 1.4;
}

.btn-bulk-quote {
  display: inline-block;
  padding: 14px 32px;
  background: #1b1b25;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
  transition: background-color 0.3s ease;
}

.btn-bulk-quote:hover {
  background: #000;
  color: #fff;
  text-decoration: none;
}

/* Ensure product summary column has relative positioning */
.product-summary-col,
.mattonflex-cart-form {
  position: relative;
}

/* Disabled add to cart button when popup is open */
.mattonflex-add-to-cart:disabled {
  background: #ccc;
  cursor: not-allowed;
}

@media (max-width: 767px) {
  .bulk-popup-content {
    padding: 30px 20px;
  }

  .bulk-popup-title {
    font-size: 18px;
  }

  .btn-bulk-quote {
    padding: 12px 24px;
    font-size: 14px;
  }
}

/* ==========================================================================
   CF7 Quote Modal (Fixed Centered)
   ========================================================================== */

.mattonflex-cf7-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.cf7-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  cursor: pointer;
}

.cf7-modal-content {
  position: relative;
  z-index: 1;
  background: #fff;
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.cf7-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 36px;
  height: 36px;
  background: #f5f5f5;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  line-height: 36px;
  color: #666;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cf7-modal-close:hover {
  background: #e0e0e0;
  color: #333;
}

.cf7-modal-title {
  margin: 0 0 24px 0;
  font-size: 24px;
  font-weight: 500;
  color: #1b1b25;
  text-align: center;
}

/* CF7 Form Styling inside Modal */
.cf7-modal-form .wpcf7-form p {
  margin-bottom: 0;
}

.cf7-modal-form .wpcf7-form label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: #333;
}

.cf7-modal-form input[type="text"],
.cf7-modal-form input[type="email"],
.cf7-modal-form input[type="tel"],
.cf7-modal-form input[type="number"],
.cf7-modal-form textarea,
.cf7-modal-form select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 16px;
  margin-bottom: 16px;
  transition: border-color 0.2s ease;
}

.cf7-modal-form input[type="text"]:focus,
.cf7-modal-form input[type="email"]:focus,
.cf7-modal-form input[type="tel"]:focus,
.cf7-modal-form input[type="number"]:focus,
.cf7-modal-form textarea:focus,
.cf7-modal-form select:focus {
  outline: none;
  border-color: #9d4425;
}

.cf7-modal-form textarea {
  min-height: 120px;
  resize: vertical;
}

.cf7-modal-form input[type="submit"] {
  width: 100%;
  padding: 14px 24px;
  background: #9d4425;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease;
  margin-top: 8px;
}

.cf7-modal-form input[type="submit"]:hover {
  background: #7a3319;
}

.cf7-modal-form .wpcf7-spinner {
  margin: 0 auto;
  display: block;
}

.cf7-modal-form .wpcf7-response-output {
  margin: 16px 0 0 0;
  padding: 12px;
  border-radius: 8px;
}

/* Body lock when CF7 modal open */
body.cf7-modal-open {
  overflow: hidden;
}

/* Responsive */
@media (max-width: 767px) {
  .cf7-modal-content {
    padding: 30px 20px;
    margin: 10px;
    max-height: 85vh;
  }

  .cf7-modal-title {
    font-size: 20px;
    padding-right: 30px;
  }

  .cf7-modal-form input[type="text"],
  .cf7-modal-form input[type="email"],
  .cf7-modal-form input[type="tel"],
  .cf7-modal-form textarea {
    padding: 10px 14px;
    font-size: 16px;
  }
}

/* ==========================================================================
   Checkout Page
   ========================================================================== */

/* Checkout Page Container */
.woocommerce-checkout {
  /* max-width: 1000px; */
  margin: 0 auto;
  padding: 60px 0px;
}

/* Two Column Layout */
.woocommerce-checkout .col2-set {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  margin-bottom: 40px;
}

.woocommerce-checkout .col2-set .col-1,
.woocommerce-checkout .col2-set .col-2 {
  flex: 1;
  min-width: 300px;
  max-width: 100%;
  padding: 0px;
}

.woocommerce-input-wrapper {
  width: 100%;
}

/* Billing/Shipping Section Cards */
.woocommerce-billing-fields,
.woocommerce-shipping-fields,
.woocommerce-additional-fields {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.woocommerce-shipping-fields {
  margin-bottom: 20px;
}

.woocommerce-account-fields {
  background: #fff;
  padding: 25px 30px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-top: 20px;
}

/* Section Headers */
.woocommerce-checkout h3 {
  font-size: 20px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 25px 0;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.woocommerce-billing-fields h3,
.woocommerce-shipping-fields h3,
.woocommerce-additional-fields h3 {
  font-size: 18px;
  color: #1b1b25;
  margin-bottom: 20px;
  border-bottom: 1px solid #eee;
}

#order_review_heading {
  font-size: 24px;
  color: #9d4425;
  font-weight: 600;
  margin: 40px 0 25px 0;
  padding-bottom: 15px;
  border-bottom: 2px solid #9d4425;
}

/* Form Fields */
.woocommerce-checkout .form-row {
  margin-bottom: 18px;
}

.woocommerce-checkout .form-row label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  font-size: 14px;
  color: #1b1b25;
}

.woocommerce-checkout .form-row label .optional {
  color: #999;
  font-weight: 400;
  font-size: 13px;
}

.woocommerce-checkout .form-row label .required {
  color: #9d4425;
}

.woocommerce-checkout .form-row input.input-text,
.woocommerce-checkout .form-row textarea,
.woocommerce-checkout .form-row select,
.woocommerce-checkout .select2-container--default .select2-selection--single {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.woocommerce-checkout .form-row input.input-text:focus,
.woocommerce-checkout .form-row textarea:focus,
.woocommerce-checkout .form-row select:focus {
  border-color: #9d4425;
  outline: none;
  box-shadow: 0 0 0 3px rgba(157, 68, 37, 0.1);
}

.woocommerce-checkout .form-row textarea {
  min-height: 100px;
  resize: vertical;
}

/* Checkbox styling */
.woocommerce-checkout .woocommerce-form__label-for-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
}

.woocommerce-checkout .woocommerce-form__input-checkbox {
  margin-top: 3px;
  accent-color: #9d4425;
}

/* Select2 dropdown styling */
.woocommerce-checkout .select2-container--default .select2-selection--single {
  height: auto;
  padding: 12px 16px;
  border: 1px solid #ddd;
}

.woocommerce-checkout
  .select2-container--default
  .select2-selection--single
  .select2-selection__rendered {
  line-height: 1.5;
  padding: 0;
  color: #333;
}

.woocommerce-checkout
  .select2-container--default
  .select2-selection--single
  .select2-selection__arrow {
  height: 100%;
  right: 12px;
}

.select2-container--open .select2-dropdown {
  border-color: #9d4425;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.select2-container--default
  .select2-results__option--highlighted[aria-selected] {
  background: #9d4425;
}

/* Two columns for name fields */
.woocommerce-billing-fields__field-wrapper,
.woocommerce-shipping-fields__field-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px 20px;
}

.woocommerce-billing-fields__field-wrapper .form-row-wide,
.woocommerce-shipping-fields__field-wrapper .form-row-wide {
  grid-column: 1 / -1;
}

.woocommerce-billing-fields__field-wrapper .form-row-first,
.woocommerce-shipping-fields__field-wrapper .form-row-first {
  grid-column: 1;
}

.woocommerce-billing-fields__field-wrapper .form-row-last,
.woocommerce-shipping-fields__field-wrapper .form-row-last {
  grid-column: 2;
}

/* Order Review Section */
.woocommerce-checkout-review-order {
  background: #fff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Order Review Table */
.woocommerce-checkout-review-order-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 0;
  background: transparent;
  border-radius: 0;
  overflow: visible;
  box-shadow: none;
}

.woocommerce-checkout-review-order-table thead th {
  background: #f8f8f8;
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #666;
  padding: 15px 0;
  border-bottom: 1px solid #eee;
}

.woocommerce-checkout-review-order-table thead th:last-child {
  text-align: right;
}

.woocommerce-checkout-review-order-table tbody td,
.woocommerce-checkout-review-order-table tfoot th,
.woocommerce-checkout-review-order-table tfoot td {
  padding: 15px 0;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.woocommerce-checkout-review-order-table tbody td {
  font-size: 15px;
}

.woocommerce-checkout-review-order-table tbody .product-name {
  font-weight: 500;
  color: #1b1b25;
}

.woocommerce-checkout-review-order-table tbody .product-quantity {
  color: #666;
  font-weight: 400;
}

.woocommerce-checkout-review-order-table tbody .product-total,
.woocommerce-checkout-review-order-table tfoot td {
  text-align: right;
  font-weight: 500;
}

.woocommerce-checkout-review-order-table tfoot th {
  font-weight: 500;
  color: #666;
}

.woocommerce-checkout-review-order-table .order-total th,
.woocommerce-checkout-review-order-table .order-total td {
  font-size: 20px;
  font-weight: 700;
  color: #9d4425;
  border-top: 2px solid #9d4425;
  border-bottom: none;
  padding-top: 20px;
}

/* Shipping Options */
.woocommerce-checkout-review-order-table .shipping th {
  vertical-align: top;
}

.woocommerce-checkout-review-order-table #shipping_method {
  list-style: none;
  padding: 0;
  margin: 0;
}

.woocommerce-checkout-review-order-table #shipping_method li {
  margin-bottom: 8px;
}

.woocommerce-checkout-review-order-table #shipping_method li label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-weight: 400;
}

.woocommerce-checkout-review-order-table #shipping_method li input {
  accent-color: #9d4425;
}

/* Payment Methods */
.woocommerce-checkout-payment {
  background: transparent;
  padding: 0;
  border-radius: 0;
  margin-top: 30px;
  border: none;
}

.wc_payment_methods {
  list-style: none;
  padding: 0;
  margin: 0 0 25px 0;
}

.wc_payment_methods li {
  padding: 20px;
  background: #f9f9f9;
  border: 2px solid transparent;
  border-radius: 10px;
  margin-bottom: 12px;
  transition: all 0.2s ease;
}

.wc_payment_methods li label {
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  color: #1b1b25;
}

.wc_payment_methods li input[type="radio"] {
  width: 20px;
  height: 20px;
  accent-color: #9d4425;
}

.wc_payment_methods li.payment_method_selected {
  background: #fff;
  border-color: #9d4425;
  box-shadow: 0 2px 8px rgba(157, 68, 37, 0.1);
}

.wc_payment_methods li:hover:not(.payment_method_selected) {
  background: #f5f5f5;
}

.wc_payment_methods .payment_box {
  margin-top: 15px;
  padding: 15px 20px;
  background: #fdf8f6;
  border-radius: 8px;
  font-size: 14px;
  color: #666;
  border-left: 3px solid #9d4425;
}

/* Privacy Policy Text */
.woocommerce-privacy-policy-text {
  font-size: 13px;
  color: #666;
  margin-bottom: 20px;
}

.woocommerce-privacy-policy-text a {
  color: #9d4425;
}

/* Terms Checkbox */
.woocommerce-terms-and-conditions-wrapper {
  margin-bottom: 20px;
}

.woocommerce-terms-and-conditions-wrapper
  .woocommerce-form__label-for-checkbox {
  font-size: 14px;
}

/* Place Order Button */
.place-order {
  margin-top: 0;
}

#place_order {
  width: 100%;
  padding: 20px 30px;
  background: #9d4425;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.1s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

#place_order:hover {
  background: #7a3319;
}

#place_order:active {
  transform: scale(0.98);
}

/* Coupon toggle notice */
.woocommerce-form-coupon-toggle {
  margin: 25px 0;
}

.woocommerce-form-coupon-toggle .woocommerce-info {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 18px 25px;
  margin-bottom: 0;
  color: #666;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.woocommerce-form-coupon-toggle .woocommerce-info::before {
  color: #9d4425;
}

.woocommerce-form-coupon-toggle .woocommerce-info a {
  color: #9d4425;
  font-weight: 600;
}

/* Coupon form */
.checkout_coupon {
  background: #fff;
  padding: 25px;
  border-radius: 10px;
  margin-bottom: 25px;
  border: 1px solid #eee;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.checkout_coupon p {
  margin: 0 0 15px 0;
  width: 100%;
  color: #666;
  font-size: 14px;
}

.checkout_coupon .form-row {
  margin: 0;
}

.checkout_coupon .form-row-first {
  flex: 1;
  min-width: 200px;
}

.checkout_coupon .form-row-first input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
}

.checkout_coupon .form-row-last .button {
  background: #1b1b25;
  color: #fff;
  border: none;
  padding: 14px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.checkout_coupon .form-row-last .button:hover {
  background: #000;
}

/* WooCommerce Notices */
.woocommerce-checkout .woocommerce-error,
.woocommerce-checkout .woocommerce-message {
  border-radius: 10px;
  margin-bottom: 25px;
}

.woocommerce-checkout .woocommerce-error {
  background: #fef2f2;
  border-color: #dc3545;
}

.woocommerce-checkout .woocommerce-message {
  background: #f0fdf4;
  border-color: #22c55e;
}

/* Login Form on Checkout */
.woocommerce-form-login-toggle .woocommerce-info {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 18px 25px;
  margin-bottom: 25px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.woocommerce-form-login {
  background: #fff;
  padding: 25px;
  border-radius: 10px;
  margin-bottom: 25px;
  border: 1px solid #eee;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Responsive */
@media (max-width: 767px) {
  .woocommerce-checkout {
    padding: 40px 0px;
  }

  .woocommerce-checkout .col2-set .col-1,
  .woocommerce-checkout .col2-set .col-2 {
    min-width: 100%;
  }

  .woocommerce-billing-fields,
  .woocommerce-shipping-fields,
  .woocommerce-additional-fields,
  .woocommerce-checkout-review-order {
    padding: 20px;
  }

  .woocommerce-billing-fields__field-wrapper,
  .woocommerce-shipping-fields__field-wrapper {
    grid-template-columns: 1fr;
  }

  .woocommerce-billing-fields__field-wrapper .form-row-first,
  .woocommerce-billing-fields__field-wrapper .form-row-last,
  .woocommerce-shipping-fields__field-wrapper .form-row-first,
  .woocommerce-shipping-fields__field-wrapper .form-row-last {
    grid-column: 1;
  }

  .wc_payment_methods li {
    padding: 15px;
  }

  .woocommerce-checkout-review-order-table th,
  .woocommerce-checkout-review-order-table td {
    padding: 12px 0;
  }

  #place_order {
    padding: 18px 20px;
    font-size: 16px;
  }

  .checkout_coupon {
    padding: 20px;
  }

  .checkout_coupon .form-row-first {
    min-width: 100%;
  }

  .checkout_coupon .form-row-last {
    width: 100%;
  }

  .checkout_coupon .form-row-last .button {
    width: 100%;
  }

  #order_review_heading {
    font-size: 20px;
    margin-top: 30px;
  }
}

/* ==========================================================================
   Thank You / Order Received Page
   ========================================================================== */

.mattonflex-thankyou-page {
  padding: 60px 0 80px;
  background: #f9f9f9;
  min-height: 60vh;
}

.mattonflex-thankyou-page .woocommerce-order {
  max-width: 900px;
  margin: 0 auto;
}

/* Header Section */
.thankyou-header {
  text-align: center;
  padding: 50px 30px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  margin-bottom: 30px;
}

.thankyou-icon {
  width: 100px;
  height: 100px;
  margin: 0 auto 25px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.thankyou-icon.success {
  background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
  color: #2e7d32;
}

.thankyou-icon.failed {
  background: linear-gradient(135deg, #ffebee 0%, #ffcdd2 100%);
  color: #c62828;
}

.thankyou-icon svg {
  width: 50px;
  height: 50px;
}

.thankyou-title {
  font-size: 36px;
  font-weight: 300;
  color: #1b1b25;
  margin: 0 0 15px;
}

.thankyou-success .thankyou-title {
  color: #9d4425;
}

.thankyou-failed .thankyou-title {
  color: #c62828;
}

.thankyou-message {
  font-size: 18px;
  color: #666;
  margin: 0;
  line-height: 1.6;
}

/* Failed Order Actions */
.thankyou-actions {
  margin-top: 30px;
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

.thankyou-actions .button {
  padding: 14px 30px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  text-decoration: none;
}

.thankyou-actions .btn-retry {
  background: #9d4425;
  color: #fff;
  border: none;
}

.thankyou-actions .btn-retry:hover {
  background: #7a3319;
  color: #fff;
}

.thankyou-actions .btn-account {
  background: transparent;
  color: #1b1b25;
  border: 2px solid #1b1b25;
}

.thankyou-actions .btn-account:hover {
  background: #1b1b25;
  color: #fff;
}

/* Order Overview Grid */
.order-overview-wrapper {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 30px;
  margin-bottom: 30px;
}

.order-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 25px;
}

.order-overview-item {
  text-align: center;
  padding: 20px;
  background: #f9f9f9;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.order-overview-item:hover {
  background: #f5f5f5;
}

.order-overview-item.highlight {
  background: linear-gradient(135deg, #fef5f2 0%, #fdeae4 100%);
  border: 1px solid rgba(157, 68, 37, 0.2);
}

.order-overview-item .overview-label {
  display: block;
  font-size: 12px;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.order-overview-item .overview-value {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: #1b1b25;
  word-break: break-word;
}

.order-overview-item.highlight .overview-value {
  color: #9d4425;
  font-size: 20px;
}

/* Order Details Section */
.mattonflex-thankyou-page .woocommerce-order-details {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 30px;
  margin-bottom: 30px;
}

.mattonflex-thankyou-page .woocommerce-order-details__title {
  font-size: 22px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 25px;
  padding-bottom: 15px;
  border-bottom: 2px solid #9d4425;
}

.mattonflex-thankyou-page .woocommerce-table--order-details {
  width: 100%;
  border: none;
}

.mattonflex-thankyou-page .woocommerce-table--order-details thead th {
  background: #f8f8f8;
  padding: 15px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #888;
  font-weight: 600;
  border: none;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  thead
  th:first-child {
  border-radius: 8px 0 0 8px;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  thead
  th:last-child {
  border-radius: 0 8px 8px 0;
  text-align: right;
}

.mattonflex-thankyou-page .woocommerce-table--order-details tbody td {
  padding: 18px 15px;
  border: none;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tbody
  td.product-name {
  font-weight: 500;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tbody
  td.product-name
  a {
  color: #1b1b25;
  text-decoration: none;
  transition: color 0.3s ease;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tbody
  td.product-name
  a:hover {
  color: #9d4425;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tbody
  td.product-total {
  text-align: right;
  font-weight: 600;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tbody
  .product-quantity {
  color: #888;
  font-weight: normal;
}

.mattonflex-thankyou-page .woocommerce-table--order-details tfoot th,
.mattonflex-thankyou-page .woocommerce-table--order-details tfoot td {
  padding: 12px 15px;
  border: none;
  border-top: 1px solid #eee;
}

.mattonflex-thankyou-page .woocommerce-table--order-details tfoot th {
  text-align: left;
  font-weight: 500;
  color: #666;
}

.mattonflex-thankyou-page .woocommerce-table--order-details tfoot td {
  text-align: right;
  font-weight: 600;
}

.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tfoot
  tr:last-child
  th,
.mattonflex-thankyou-page
  .woocommerce-table--order-details
  tfoot
  tr:last-child
  td {
  font-size: 18px;
  color: #9d4425;
  border-top: 2px solid #9d4425;
  padding-top: 18px;
}

/* Customer Details Section */
.mattonflex-thankyou-page .woocommerce-customer-details {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 30px;
  margin-bottom: 30px;
}

.mattonflex-thankyou-page
  .woocommerce-customer-details
  .woocommerce-column__title {
  font-size: 18px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 15px;
  padding-bottom: 12px;
  border-bottom: 1px solid #eee;
}

.mattonflex-thankyou-page .woocommerce-customer-details address {
  font-style: normal;
  line-height: 1.8;
  color: #666;
}

.mattonflex-thankyou-page .woocommerce-customer-details address p {
  margin: 0;
}

.mattonflex-thankyou-page .woocommerce-columns--addresses {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.mattonflex-thankyou-page .woocommerce-column--billing-address,
.mattonflex-thankyou-page .woocommerce-column--shipping-address {
  padding: 20px;
  background: #f9f9f9;
  border-radius: 10px;
}

/* Bank Details Section (for BACS) */
.mattonflex-thankyou-page .woocommerce-bacs-bank-details {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 30px;
  margin-bottom: 30px;
}

.mattonflex-thankyou-page .woocommerce-bacs-bank-details h2 {
  font-size: 22px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #9d4425;
}

.mattonflex-thankyou-page .woocommerce-bacs-bank-details ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mattonflex-thankyou-page .woocommerce-bacs-bank-details li {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #eee;
}

.mattonflex-thankyou-page .woocommerce-bacs-bank-details li:last-child {
  border-bottom: none;
}

/* Responsive Styles */
@media (max-width: 768px) {
  .mattonflex-thankyou-page {
    padding: 40px 0 60px;
  }

  .thankyou-header {
    padding: 40px 20px;
  }

  .thankyou-icon {
    width: 80px;
    height: 80px;
  }

  .thankyou-icon svg {
    width: 40px;
    height: 40px;
  }

  .thankyou-title {
    font-size: 28px;
  }

  .thankyou-message {
    font-size: 16px;
  }

  .thankyou-actions {
    flex-direction: column;
  }

  .thankyou-actions .button {
    width: 100%;
    text-align: center;
  }

  .order-overview-wrapper {
    padding: 20px;
  }

  .order-overview-grid {
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }

  .order-overview-item {
    padding: 15px;
  }

  .order-overview-item .overview-value {
    font-size: 14px;
  }

  .order-overview-item.highlight .overview-value {
    font-size: 18px;
  }

  .mattonflex-thankyou-page .woocommerce-order-details,
  .mattonflex-thankyou-page .woocommerce-customer-details,
  .mattonflex-thankyou-page .woocommerce-bacs-bank-details {
    padding: 20px;
  }

  .mattonflex-thankyou-page .woocommerce-table--order-details thead {
    display: none;
  }

  .mattonflex-thankyou-page .woocommerce-table--order-details tbody tr {
    display: block;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
  }

  .mattonflex-thankyou-page .woocommerce-table--order-details tbody td {
    display: block;
    padding: 5px 0;
    border: none;
    text-align: left !important;
  }

  .mattonflex-thankyou-page
    .woocommerce-table--order-details
    tbody
    td.product-total::before {
    content: "Totale: ";
    color: #888;
  }

  .mattonflex-thankyou-page .woocommerce-columns--addresses {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .order-overview-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Accessori e Collanti - New Sections
   ========================================================================== */

/* Vantaggi e Caratteristiche */
.mattonflex-vantaggi-section {
  padding: 60px 0;
}

.mattonflex-vantaggi-section .section-title {
  position: relative;
  padding-bottom: 20px;
}

.mattonflex-vantaggi-section .section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: #9d4425;
}

.mattonflex-vantaggi-section .section-description {
  line-height: 1.9;
  color: #555;
}

/* Limitazioni - con sfondo grigio parziale */
.mattonflex-limitazioni-section {
  position: relative;
  padding: 60px 0;
  overflow: hidden;
}

.mattonflex-limitazioni-section::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 75%;
  background: #f5f5f5;
  border-radius: 12px 0 0 12px;
  z-index: 0;
}

.mattonflex-limitazioni-section .container {
  position: relative;
  z-index: 1;
}

.mattonflex-limitazioni-section .limitazioni-image-wrapper {
  position: relative;
  z-index: 2;
}

.mattonflex-limitazioni-section .limitazioni-image-wrapper img {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 12px;
}

.mattonflex-limitazioni-section .limitazioni-content {
  padding-left: 40px;
}

.mattonflex-limitazioni-section .limitazioni-description {
  line-height: 1.8;
}

.mattonflex-limitazioni-section .limitazioni-description h4,
.mattonflex-limitazioni-section .limitazioni-description h5 {
  color: #9d4425;
  margin-top: 20px;
  margin-bottom: 10px;
  font-weight: 400;
}

.mattonflex-limitazioni-section .limitazioni-description p {
  margin-bottom: 10px;
}

/* Preparazione e Applicazione */
.mattonflex-preparazione-section {
  padding: 60px 0;
}

.mattonflex-preparazione-section .preparazione-step {
  padding: 15px 0;
}

.mattonflex-preparazione-section .step-title {
  margin-bottom: 10px;
}

.mattonflex-preparazione-section .step-text {
  line-height: 1.7;
  color: #555;
}

/* Errori da Evitare */
.mattonflex-errori-section {
  padding: 80px 0 60px;
}

.mattonflex-errori-section .errori-grid {
  row-gap: 24px;
}

.mattonflex-errori-section .errore-item {
  background: #fff;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  height: 100%;
  border: 1px solid #eee;
}

.mattonflex-errori-section .errore-title {
  margin-bottom: 12px;
}

.mattonflex-errori-section .errore-text {
  line-height: 1.7;
  color: #555;
  margin: 0;
}

/* Responsive */
@media (max-width: 767px) {
  .mattonflex-limitazioni-section::before {
    top: auto;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: calc(100% - 280px);
    border-radius: 12px 12px 0 0;
  }

  .mattonflex-limitazioni-section .limitazioni-content {
    padding-left: 0;
    padding-top: 30px;
  }

  .mattonflex-preparazione-section .preparazione-step {
    padding: 10px 0;
  }

  .mattonflex-errori-section {
    padding: 60px 0 40px;
  }
}

/* ==========================================================================
   Kit Campioni - Selettore Colorazioni
   ========================================================================== */

.mattonflex-campioni-selector {
  margin-bottom: 24px;
}

.mattonflex-campioni-intro {
  font-size: 14px;
  font-weight: 600;
  color: #1b1b25;
  margin: 0 0 16px 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Grid delle card mattone */
.mattonflex-campioni-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

@media (max-width: 991px) {
  .mattonflex-campioni-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 480px) {
  .mattonflex-campioni-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

/* Singola card */
.mattonflex-campione-card {
  position: relative;
  border: 2px solid #eee;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
  background: #fff;
  user-select: none;
  -webkit-user-select: none;
}

.mattonflex-campione-card:hover {
  border-color: #ccc;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.mattonflex-campione-card:focus {
  outline: none;
  border-color: #9d4425;
  box-shadow: 0 0 0 3px rgba(157, 68, 37, 0.15);
}

.mattonflex-campione-card.is-selected {
  border-color: #9d4425;
  box-shadow: 0 4px 16px rgba(157, 68, 37, 0.2);
}

.mattonflex-campione-card img {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.mattonflex-campione-card:hover img {
  transform: scale(1.05);
}

.mattonflex-campione-name {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: #1b1b25;
  padding: 8px 8px 9px;
  text-align: center;
  line-height: 1.3;
  background: #fff;
}

/* Badge slot numerico (1 / 2) */
.mattonflex-campione-slot-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 22px;
  height: 22px;
  background: #9d4425;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  pointer-events: none;
}

/* Checkmark (nascosto, sostituito dal badge) */
.mattonflex-campione-check {
  display: none;
}

/* Riepilogo selezione */
.mattonflex-campioni-riepilogo {
  background: #faf9f7;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mattonflex-campione-slot {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #666;
  transition: color 0.2s ease;
}

.mattonflex-campione-slot .slot-label {
  font-weight: 600;
  color: #1b1b25;
  white-space: nowrap;
  min-width: 160px;
}

.mattonflex-campione-slot .slot-value {
  color: #999;
  font-style: italic;
}

.mattonflex-campione-slot.is-filled .slot-value {
  color: #9d4425;
  font-style: normal;
  font-weight: 500;
}

/* Messaggio errore validazione */
.mattonflex-campioni-error {
  font-size: 13px;
  color: #c62828;
  background: #fef2f2;
  border: 1px solid #ffcdd2;
  border-radius: 6px;
  padding: 10px 14px;
  margin-top: 4px;
  margin-bottom: 0;
}

/* Messaggio nessuna colorazione */
.mattonflex-campioni-nessuno {
  font-size: 14px;
  color: #666;
  padding: 15px;
  background: #f9f9f9;
  border-radius: 8px;
  margin-bottom: 16px;
}

/* Responsive stacked slots su mobile */
@media (max-width: 480px) {
  .mattonflex-campione-slot {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .mattonflex-campione-slot .slot-label {
    min-width: auto;
  }
}

/* Nasconde il selettore quantità sulla pagina campione
   (se ne aggiunge sempre e solo 1 per volta) */
.mattonflex-campioni-selector ~ .mattonflex-quantity-wrapper,
.mattonflex-campioni-selector ~ * .mattonflex-quantity-wrapper,
body.campione-product .mattonflex-quantity-wrapper,
body.campione-product .quantity-selector {
  display: none !important;
}

/* Nasconde quantità nella riga carrello solo per i prodotti campione */
.cart-item-campione .product-quantity .quantity-selector,
.cart-item-campione .product-quantity .quantity {
  display: none !important;
}

.woocommerce-product-details__short-description {
  font-size: 16px;
}

.spedizione-gratuita-color {
  font-size: 13px;
  text-decoration: underline;
}