/*
 Theme Name:   Van der Blij
 Theme URI:    https://www.vanderblij.nl
 Description:  Child theme
 Author:       Frans van Bijnen
 Author URI:   https://www.vanderblij.nl
 Template:     hello-elementor
 Version:      1.0.0
*/

/* Eigen CSS kan hieronder */

.elementor-form .elementor-field-group > label {
  display: block;
  margin-bottom: 6px; /* of 8px voor iets meer lucht */
  line-height: 1.3;
}

.borderless {
		border: none;
		text-align: center
}

table.borderless {
  border-collapse: collapse;
  width: 100%;
  table-layout: fixed;
}

table.borderless td {
  border: none;
  text-align: center;
  vertical-align: top;
  padding: 0.5em;
  background: #fff;
}

/* Wrapper met horizontale scroll en snap */
.compare-table-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory; /* ✅ zorgt voor snap scroll */
  scroll-behavior: smooth; /* ✅ maakt het scrollen vloeiend */
  scrollbar-width: thin; /* dunne scrollbar op desktop */
  scrollbar-color: #ccc transparent;
}

/* Optionele custom scrollbar styling (Chrome/Safari) */
.compare-table-wrapper::-webkit-scrollbar {
  height: 6px;
}
.compare-table-wrapper::-webkit-scrollbar-thumb {
  background-color: #bbb;
  border-radius: 3px;
}
.compare-table-wrapper::-webkit-scrollbar-track {
  background: transparent;
}

/* Basis tabel */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 2rem;
  font-family: inherit;
  min-width: 600px;
  scroll-snap-align: start;
}

/* Cell styling */
.compare-table th,
.compare-table td {
  padding: 12px 15px;
  text-align: center;
  vertical-align: middle;
  border: none;
  white-space: normal;
}

/* Header sticky */
.compare-table thead th {
  position: sticky;
  top: 0;
  background: #f5f5f5;
  z-index: 2;
  font-weight: 600;
}

/* Eerste kolom sticky */
.compare-table td:first-child {
  text-align: left;
  font-weight: 600;
  background: #fafafa;
  position: sticky;
  left: 0;
  z-index: 1;
  min-width: 120px;
  max-width: 180px;
}

/* Afwisselende achtergrond */
.compare-table tbody tr:nth-child(odd) td {
  background: #fff;
}
.compare-table tbody tr:nth-child(even) td {
  background: #f5f5f5;
}

/* Sticky eerste kolom iets donkerder */
.compare-table tbody tr:nth-child(odd) td:first-child {
  background: #fafafa;
}
.compare-table tbody tr:nth-child(even) td:first-child {
  background: #f0f0f0;
}

/* ✅ Mobiele optimalisatie */
@media (max-width: 768px) {
  .compare-table td:first-child {
    min-width: 90px;
    font-size: 14px;
  }

  .compare-table-wrapper {
    scroll-padding-left: 90px;
  }

  .compare-table td,
  .compare-table th {
    padding: 10px;
  }

  .compare-table {
    min-width: 500px;
  }
}

/* ✅ Extra smooth snap behavior */
.compare-table td,
.compare-table th {
  scroll-snap-align: start;
  scroll-snap-stop: always;
  transition: background-color 0.25s ease, transform 0.25s ease;
}

.compare-table-wrapper:active,
.compare-table-wrapper:focus-within {
  scroll-behavior: smooth;
}

@media (max-width: 768px) {
  /* Maak de key kolom smaller en laat tekst afbreken */
  .compare-table td:first-child,
  .compare-table th:first-child {
    min-width: 70px;         /* ✅ smallere kolom */
    max-width: 150px;
    font-size: 13px;
    white-space: normal !important; /* ✅ tekst mag doorlopen */
    line-height: 1.3;
    word-break: break-word;
  }

  /* Zorg dat andere cellen nog steeds netjes blijven */
  .compare-table td:not(:first-child),
  .compare-table th:not(:first-child) {
    min-width: 200px; /* iets breder voor producten */
  }

  /* Geef iets meer ruimte tussen rijen zodat dubbele regels niet te dicht op elkaar staan */
  .compare-table td {
    padding: 10px 8px;
  }
}


/* --- WooCommerce Product Eigenschappen Tabel --- */
.woocommerce-product-attributes.shop_attributes {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  line-height: 1.6;
  background-color: #fafafa;
  overflow: hidden;
}

/* Rij achtergrondafwisseling */
.woocommerce-product-attributes tr:nth-child(odd) {
  background-color: #ffffff;
}
.woocommerce-product-attributes tr:nth-child(even) {
  background-color: #ececec;
}

/* Labels (linkerkolom) */
.woocommerce-product-attributes-item__label {
  width: 40%;
  font-weight: 600;
  color: #333;
  background-color: #f0f0f0;
  padding: 12px 16px;
  text-align: left;
  border: none;
}

/* Waarden (rechterkolom) */
.woocommerce-product-attributes-item__value {
  padding: 12px 16px;
  color: #111;
  border: none;
}

/* <p> binnen value – verwijder marges */
.woocommerce-product-attributes-item__value p {
  margin: 0;
}

/* Optioneel: hover effect */
.woocommerce-product-attributes tr:hover {
  background-color: #eaeaea;
  transition: background-color 0.2s ease;
}

/* Verwijder italic uit WooCommerce producteigenschappen */
.woocommerce table.shop_attributes td,
.woocommerce table.shop_attributes td p {
  font-style: normal !important;
}

/* Responsief: kleinere tekst op mobiel */
@media (max-width: 768px) {
	
	.woocommerce table.shop_attributes th {
		width: 50%
	}
  .woocommerce-product-attributes.shop_attributes {
    font-size: 0.9rem;
  }
  .woocommerce-product-attributes-item__label,
  .woocommerce-product-attributes-item__value {
    width: 100%;
    text-align: left;
  }
  .woocommerce-product-attributes tr {
    margin-bottom: 0.75rem;
  }
}
.woocommerce table.shop_attributes,
.woocommerce table.shop_attributes th,
.woocommerce table.shop_attributes td {
  border: none !important;
}




/* Downloads bij producten */
.product-downloads {
  background: #fff;
  border-radius: 4px;
  padding: 15px;
}

.downloads-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.download-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #ddd;
}

.download-item:last-child {
  border-bottom: none;
}

.download-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.download-icon {
  color: #b48b2c; /* goudkleurig accent */
  font-size: 18px;
}

.download-name {
  font-weight: 400;
  color: #111;
}

.download-link {
  color: #111;
  font-weight: 500;
  text-decoration: none;
}

.download-link i {
  color: #b48b2c;
  margin-right: 5px;
}

.download-link:hover {
  text-decoration: underline;
}


/* Scrollbare wrapper voor mobiel */
.variant-table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 1rem;
}

/* Basistabel */
.variant-table {
  border-collapse: collapse;
  width: 100%;
  min-width: 700px;
}

/* Koptekst */
.variant-table thead tr {
  background-color: #FFB71B;
}

.variant-table th {
  color: black;
  font-weight: 700;
  text-align: left;
  padding: 6px 10px;
  white-space: nowrap;
}

/* Rij-opmaak */
.variant-table td {
  border: 1px solid #ddd;
  padding: 6px 10px;
  text-align: left;
}

.variant-table tbody tr:nth-child(even) {
  background-color: #fafafa;
}

/* Verbeterde mobiele weergave */
@media (max-width: 600px) {
  .variant-table th,
  .variant-table td {
    padding: 8px;
    font-size: 14px;
  }
}

