/* =========================================
   Oku Special Offer Carousel — CSS
   Matches Electro WooCommerce Theme Style
   ========================================= */

/* ── Wrapper ── */
.oku-sc-wrapper {
  width: 100%;
  padding: 32px 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* ── Header ── */
.oku-sc-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.oku-sc-title {
  font-size: 20px;
  font-weight: 700;
  color: #111;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0;
  white-space: nowrap;
}

.oku-sc-line {
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, #186E70 0%, rgba(24,110,112,0.1) 100%);
  border-radius: 2px;
}

/* ── Outer container ──
   No side padding needed — nav arrows have been removed.
   ── */
.oku-sc-outer {
  position: relative;
  padding: 0;
}

/* ── Track ── */
.oku-sc-track-outer {
  overflow: hidden;
  border-radius: 4px;
}

.oku-sc-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

/* ── Slide ──
   Base width reflects desktop default (4 slides = 25%).
   JS overrides this inline via setSlideWidths() at runtime;
   these values serve as no-JS fallbacks only.
   ── */
.oku-sc-slide {
  flex: 0 0 25%;       /* desktop default: 4 slides */
  min-width: 25%;
  padding: 8px;
  box-sizing: border-box;
}

/* ── Card ── */
.oku-sc-card {
  position: relative;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.oku-sc-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  transform: translateY(-3px);
}

/* ── Sale badge ── */
.oku-sc-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  background: #186E70;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 3px 9px;
  border-radius: 4px;
  text-transform: uppercase;
}

/* ── Image ── */
.oku-sc-img-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: #f8f8f8;
  height: 200px;
  overflow: hidden;
  text-decoration: none;
}

.oku-sc-img-wrap img {
  max-width: 100%;
  max-height: 160px;
  object-fit: contain;
  transition: transform 0.4s ease;
}

.oku-sc-card:hover .oku-sc-img-wrap img {
  transform: scale(1.06);
}

.oku-sc-no-img {
  font-size: 13px;
  color: #aaa;
}

/* ── Card body ── */
.oku-sc-body {
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}

/* ── Product name ── */
.oku-sc-name {
  font-size: 13.5px;
  font-weight: 600;
  color: #1a1a1a;
  text-decoration: none;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s;
}

.oku-sc-name:hover {
  color: #186E70;
}

/* ── Pricing ── */
.oku-sc-pricing {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
}

.oku-sc-pricing .woocommerce-Price-amount {
  font-size: 18px;
  font-weight: 700;
  color: #186E70;
}

.oku-sc-pricing del .woocommerce-Price-amount {
  font-size: 13px;
  font-weight: 400;
  color: #aaa;
}

.oku-sc-pricing ins {
  text-decoration: none;
}

.oku-sc-pricing del {
  opacity: 0.7;
}

/* ── Stock bar ── */
.oku-sc-stock-bar {
  margin-top: 4px;
}

.oku-sc-stock-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #888;
  margin-bottom: 5px;
}

.oku-sc-stock-meta strong {
  color: #444;
  font-weight: 600;
}

.oku-sc-bar-bg {
  width: 100%;
  height: 5px;
  background: #eee;
  border-radius: 10px;
  overflow: hidden;
}

.oku-sc-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #186E70, #0fd4b4);
  border-radius: 10px;
  transition: width 0.6s ease;
}

/* ── Availability ── */
.oku-sc-availability {
  font-size: 11.5px;
  font-weight: 500;
}

.oku-sc-availability.in-stock  { color: #186E70; }
.oku-sc-availability.out-stock { color: #e53935; }

/* ── Buttons ──
   Two variants:
     .oku-sc-btn--cart  → solid teal  (in stock)
     .oku-sc-btn--view  → outlined    (out of stock)
   ── */
.oku-sc-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 9px 14px;
  border-radius: 4px;
  text-decoration: none;
  margin-top: auto;
  white-space: nowrap;
  border: 2px solid transparent;
  cursor: pointer;
  line-height: 1;
  transition: background 0.22s, color 0.22s, border-color 0.22s,
              transform 0.18s, box-shadow 0.22s;
}

.oku-sc-btn svg {
  flex-shrink: 0;
  pointer-events: none;
}

/* Add to Cart — solid */
.oku-sc-btn--cart {
  background: #186E70;
  color: #fff;
  border-color: #186E70;
}

.oku-sc-btn--cart:hover {
  background: #fff;
  color: #186E70;
  border-color: #186E70;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(24,110,112,0.18);
}

/* View Product — outlined */
.oku-sc-btn--view {
  background: transparent;
  color: #186E70;
  border-color: #186E70;
}

.oku-sc-btn--view:hover {
  background: #186E70;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(24,110,112,0.18);
}

/* ── Dots ── */
.oku-sc-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 20px;
}

.oku-sc-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ddd;
  cursor: pointer;
  transition: background 0.2s, width 0.25s;
  border: none;
  padding: 0;
}

.oku-sc-dot.active {
  width: 22px;
  border-radius: 4px;
  background: #186E70;
}

/* ── Responsive fallbacks ──
   JS drives actual widths via inline styles (setSlideWidths).
   These media queries are no-JS fallbacks and must stay in
   sync with the JS/PHP defaults:
     desktop → 4 slides → 25%
     tablet  → 3 slides → 33.333%
     mobile  → 2 slides → 50%
   ── */
@media (max-width: 1024px) {
  .oku-sc-slide {
    flex: 0 0 33.333%;  /* tablet: 3 slides */
    min-width: 33.333%;
  }
}

@media (max-width: 640px) {
  .oku-sc-slide {
    flex: 0 0 50%;      /* mobile: 2 slides */
    min-width: 50%;
  }

  .oku-sc-img-wrap {
    height: 160px;
  }

  .oku-sc-title {
    font-size: 16px;
  }
}