/* Custom Tooted & Galerii Enhancements for Saunamaterjal.ee */

/* ==========================================================================
   1. PRODUCT CARDS & INTERACTIVITY (/tooted/)
   ========================================================================== */

.js-pf .wpb_column {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
}

.js-product-card-enhanced {
  cursor: pointer;
  background: #ffffff;
  border-radius: 8px;
  padding: 15px;
  border: 1px solid #e8e8e8;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.js-product-card-enhanced:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
  border-color: #2f6b4f;
}

.js-product-card-enhanced img {
  border-radius: 6px;
  transition: transform 0.4s ease;
  width: 100%;
  object-fit: cover;
  max-height: 220px;
}

.js-product-card-enhanced:hover img {
  transform: scale(1.04);
}

.product-badge {
  position: absolute;
  top: 25px;
  right: 25px;
  background: rgba(47, 107, 79, 0.9);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
  backdrop-filter: blur(4px);
}

.product-click-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  color: #2f6b4f;
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.product-click-hint i {
  font-size: 12px;
  transition: transform 0.2s ease;
}

.js-product-card-enhanced:hover .product-click-hint i {
  transform: translateX(4px);
}

/* Remove product and gallery filter buttons completely */
.js-product-filter-btns-div,
.js-product-filter-btn,
.product-filter-nav,
.sml-styled-filter-btn,
.galerii-filter-bar,
.galerii-filter-btn {
  display: none !important;
}

/* ==========================================================================
   2. PREMIUM WOOCOMMERCE-STYLE SINGLE PRODUCT PAGE (/toode/[slug]/)
   ========================================================================== */

.sml-woo-single-wrapper {
  background: #ffffff;
  color: #333;
  font-family: inherit;
}

.sml-woo-breadcrumbs {
  font-size: 13px;
  color: #888;
  margin-bottom: 25px;
}

.sml-woo-breadcrumbs a {
  color: #2f6b4f;
  text-decoration: none;
  font-weight: 500;
}

.sml-woo-breadcrumbs a:hover {
  text-decoration: underline;
}

.sml-woo-breadcrumbs .sep {
  margin: 0 6px;
  color: #ccc;
}

.sml-woo-breadcrumbs .current {
  color: #555;
  font-weight: 600;
}

.sml-woo-product-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-bottom: 50px;
}

@media (max-width: 768px) {
  .sml-woo-product-main {
    grid-template-columns: 1fr;
    gap: 25px;
  }
}

.sml-woo-gallery {
  position: relative;
}

.sml-woo-img-holder {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #dde6df;
  box-shadow: 0 8px 25px rgba(0,0,0,0.06);
  background: #f7f9f6;
}

.sml-woo-img-holder img {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
}

.sml-woo-badge {
  position: absolute;
  top: 15px;
  left: 15px;
  background: #2f6b4f;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
}

.sml-woo-summary {
  display: flex;
  flex-direction: column;
}

.sml-woo-meta-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.sml-woo-cat {
  color: #2f6b4f;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.sml-woo-stock {
  color: #2e7d32;
  font-size: 13px;
  font-weight: 600;
}

.sml-woo-title {
  font-size: 30px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 15px 0;
  line-height: 1.25;
}

.sml-woo-price-block {
  background: #fafcf9;
  border: 1px solid #e3ece5;
  border-left: 4px solid #2f6b4f;
  padding: 15px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sml-price-amount {
  font-size: 24px;
  font-weight: 700;
  color: #2f6b4f;
}

.sml-price-tax-note {
  font-size: 12px;
  color: #777;
}

.sml-woo-short-desc {
  font-size: 15px;
  line-height: 1.6;
  color: #555;
  margin-bottom: 20px;
}

.sml-woo-highlights {
  list-style: none;
  padding: 0;
  margin: 0 0 25px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sml-woo-highlights li {
  font-size: 14px;
  color: #333;
  display: flex;
  align-items: center;
  gap: 10px;
}

.sml-woo-highlights li i {
  color: #2f6b4f;
  font-size: 15px;
}

.sml-btn-add-to-quote {
  background: linear-gradient(135deg, #2f6b4f 0%, #1d4533 100%);
  color: #ffffff !important;
  font-weight: 700;
  font-size: 16px;
  padding: 16px 32px;
  border-radius: 8px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 6px 20px rgba(47, 107, 79, 0.35);
  transition: all 0.25s ease;
  width: 100%;
  box-sizing: border-box;
}

.sml-btn-add-to-quote:hover {
  background: linear-gradient(135deg, #3b8061 0%, #265a42 100%);
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(47, 107, 79, 0.45);
}

/* Tabs Section */
.sml-woo-tabs-wrapper {
  background: #ffffff;
  border: 1px solid #dde6df;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
  margin-bottom: 50px;
}

.sml-woo-tabs-nav {
  display: flex;
  gap: 15px;
  border-bottom: 2px solid #e8efe9;
  margin-bottom: 25px;
}

.sml-tab-btn {
  background: none;
  border: none;
  font-size: 16px;
  font-weight: 600;
  color: #777;
  padding: 10px 15px;
  cursor: pointer;
  position: relative;
  transition: color 0.2s ease;
}

.sml-tab-btn:hover {
  color: #2f6b4f;
}

.sml-tab-btn.active {
  color: #2f6b4f;
}

.sml-tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 3px;
  background: #2f6b4f;
  border-radius: 2px;
}

.sml-woo-tab-content {
  display: none;
}

.sml-woo-tab-content.active {
  display: block;
}

.sml-woo-tab-content h2 {
  font-size: 22px;
  font-weight: 700;
  color: #222;
  margin-bottom: 15px;
}

.sml-tab-seo-text p {
  font-size: 15px;
  line-height: 1.7;
  color: #444;
  margin-bottom: 12px;
}

.sml-woo-specs-table {
  width: 100%;
  border-collapse: collapse;
}

.sml-woo-specs-table tr {
  border-bottom: 1px solid #eff4f0;
}

.sml-woo-specs-table tr:nth-child(even) {
  background: #f7f9f6;
}

.sml-woo-specs-table th {
  padding: 12px 16px;
  font-weight: 600;
  color: #555;
  text-align: left;
  width: 30%;
}

.sml-woo-specs-table td {
  padding: 12px 16px;
  color: #222;
  font-weight: 500;
}

.sml-tab-fitting-text ul {
  padding-left: 20px;
  line-height: 1.8;
  color: #444;
}

/* Related Products */
.sml-related-heading {
  font-size: 22px;
  font-weight: 700;
  color: #222;
  margin-bottom: 20px;
}

.sml-woo-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.sml-woo-card {
  background: #ffffff;
  border: 1px solid #dde6df;
  border-radius: 10px;
  padding: 12px;
  transition: all 0.25s ease;
}

.sml-woo-card a {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.sml-woo-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 22px rgba(0,0,0,0.08);
  border-color: #2f6b4f;
}

.sml-woo-card .card-img-holder {
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 10px;
  height: 160px;
}

.sml-woo-card .card-img-holder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sml-woo-card .card-cat {
  font-size: 11px;
  color: #2f6b4f;
  font-weight: 700;
  text-transform: uppercase;
}

.sml-woo-card .card-title {
  font-size: 15px;
  font-weight: 700;
  color: #222;
  margin: 4px 0 8px 0;
}

.sml-woo-card .card-price {
  font-size: 14px;
  font-weight: 700;
  color: #2f6b4f;
}

/* ==========================================================================
   3. MODERN GALERII GRID & LIGHTBOX (/galerii/)
   ========================================================================== */

.galerii-enhanced-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 15px 35px 15px;
}

.galerii-masonry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 25px;
}

.galerii-card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  background: #222;
  aspect-ratio: 4 / 3;
}

.galerii-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  display: block;
}

.galerii-card:hover img {
  transform: scale(1.08);
}

.galerii-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.2) 60%, rgba(0, 0, 0, 0) 100%);
  opacity: 0;
  transition: opacity 0.35s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px;
  box-sizing: border-box;
}

.galerii-card:hover .galerii-overlay {
  opacity: 1;
}

.galerii-overlay-title {
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 6px 0;
  transform: translateY(10px);
  transition: transform 0.35s ease;
}

.galerii-overlay-tag {
  color: #c9a45c;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.galerii-card:hover .galerii-overlay-title {
  transform: translateY(0);
}

.galerii-zoom-icon {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(6px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  transform: scale(0.8);
  transition: transform 0.3s ease;
}

.galerii-card:hover .galerii-zoom-icon {
  transform: scale(1);
}

/* Lightbox Modal */
.sml-lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(10px);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.sml-lightbox-overlay.active {
  opacity: 1;
  visibility: visible;
}

.sml-lightbox-content {
  max-width: 90vw;
  max-height: 85vh;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.sml-lightbox-content img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  object-fit: contain;
}

.sml-lightbox-caption {
  color: #e0e0e0;
  margin-top: 15px;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
}

.sml-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.sml-lightbox-nav:hover {
  background: rgba(47, 107, 79, 0.8);
}

.sml-lightbox-prev {
  left: -70px;
}

.sml-lightbox-next {
  right: -70px;
}

@media (max-width: 768px) {
  .sml-lightbox-prev { left: 10px; }
  .sml-lightbox-next { right: 10px; }
}

.sml-lightbox-close {
  position: absolute;
  top: -45px;
  right: 0;
  background: none;
  border: none;
  color: #ffffff;
  font-size: 32px;
  cursor: pointer;
  line-height: 1;
}

/* ==========================================================================
   4. [sml_products] SHORTCODE GRID (managed from the "Tooted" wp-admin menu)
   ========================================================================== */

.sml-products-shortcode-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  background: #ffffff;
  padding: 50px 20px 20px 20px;
  box-sizing: border-box;
}

.sml-products-cat-heading {
  font-size: 24px;
  font-weight: 700;
  color: #222;
  margin: 40px 0 20px 0;
}

.sml-products-cat-heading:first-child {
  margin-top: 0;
}

.sml-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 24px;
  margin-bottom: 20px;
}

.sml-product-card-imglink {
  display: block;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 12px;
}

.sml-product-card-imglink img {
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  display: block;
}

.sml-product-card-title {
  font-size: 17px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 4px 0;
}

.sml-product-card-title a {
  color: inherit;
  text-decoration: none;
}

.sml-product-card-title a:hover {
  color: #2f6b4f;
}

.sml-product-card-subtitle {
  font-size: 13px;
  font-weight: 600;
  color: #2f6b4f;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 8px;
}

.sml-product-card-intro {
  font-size: 13px;
  color: #666;
  margin: 0 0 10px 0;
  line-height: 1.5;
}

.sml-product-card-specs {
  list-style: none;
  padding: 10px 0 0 0;
  margin: 0 0 12px 0;
  font-size: 13px;
  color: #444;
  border-top: 1px solid #e8efe9;
}

.sml-product-card-specs li {
  margin-bottom: 4px;
}

.sml-product-card-specs li strong {
  color: #222;
}

.sml-product-card-price {
  font-size: 15px;
  font-weight: 700;
  color: #2f6b4f;
  margin-bottom: 14px;
}

.sml-product-card-actions {
  margin-bottom: 10px;
}

.sml-btn-add-to-quote.sml-btn-small {
  width: auto;
  display: inline-flex;
  padding: 10px 18px;
  font-size: 13px;
  box-shadow: none;
}

.sml-product-card .product-click-hint {
  display: block;
  text-align: center;
  margin-top: 4px;
}

/* Footer Top Spacing & Padding */
footer,
.qodef-footer-top-holder {
  margin-top: 25px !important;
  padding-top: 15px !important;
}

