/* =============================================
   SHOP FILTER SIDEBAR — Ariklassi Arvutid
============================================= */

/* Layout */
.shop-with-filters {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2rem;
  align-items: start;
}

.shop-filter-sidebar {
  position: sticky;
  top: 80px;
}

.shop-products-wrap {
  min-width: 0;
}

/* =============================================
   FILTER WIDGET SHELL
============================================= */
.af-wrap {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 8px;
  overflow: hidden;
  font-family: var(--font-body);
  font-size: 13px;
}

/* Header */
.af-header {
  background: var(--black);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.af-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--white);
  font-weight: 400;
  display: flex;
  align-items: center;
  gap: 10px;
}

.af-badge {
  background: var(--red);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 100px;
  letter-spacing: 0;
}

.af-reset {
  font-family: var(--font-body);
  font-size: 10px;
  font-weight: 600;
  color: #888;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid #3a3a3a;
  padding: 5px 11px;
  border-radius: 3px;
  transition: color 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.af-reset:hover { color: var(--red); border-color: var(--red); }

.af-form { padding: 0; }

/* =============================================
   FILTER GROUP
============================================= */
.af-group {
  border-bottom: 1px solid var(--gray-200);
}
.af-group:last-of-type { border-bottom: none; }

.af-group-header {
  padding: 14px 18px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 600;
  color: var(--black);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  transition: background 0.12s;
}
.af-group-header:hover { background: var(--gray-100); }

.af-group-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
}

/* Ikoonid peidetud */
.af-group-icon { display: none !important; }

.af-group-label {
  flex: 1;
  font-family: var(--font-body);
}

.af-group-active-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--red);
  flex-shrink: 0;
}

.af-arrow {
  color: var(--gray-400);
  font-size: 16px;
  line-height: 1;
  transition: transform 0.2s;
}

.af-collapsed .af-arrow { transform: rotate(-90deg); }

.af-group-body {
  padding: 4px 0 10px;
}
.af-group-body.af-body-hidden { display: none; }

/* Scrollable long lists */
.af-group-body.af-scrollable {
  max-height: 210px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #ccc #f4f4f2;
}
.af-group-body.af-scrollable::-webkit-scrollbar { width: 3px; }
.af-group-body.af-scrollable::-webkit-scrollbar-track { background: var(--gray-100); }
.af-group-body.af-scrollable::-webkit-scrollbar-thumb { background: #bbb; border-radius: 2px; }

/* =============================================
   CHECKBOX ROWS
============================================= */
.af-option {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 16px;
  cursor: pointer;
  transition: background 0.1s;
  color: #444;
  border-radius: 0;
}
.af-option:hover { background: var(--gray-100); color: #111; }
.af-option.af-active { color: #111; }

/* Hidden real checkbox */
.af-checkbox { display: none; }

/* Custom checkbox box */
.af-checkbox-box {
  width: 15px;
  height: 15px;
  border: 1.5px solid #ccc;
  border-radius: 3px;
  background: #fff;
  flex-shrink: 0;
  transition: border-color 0.15s, background 0.15s;
  position: relative;
}
.af-option.af-active .af-checkbox-box {
  background: var(--red);
  border-color: var(--red);
}
.af-option.af-active .af-checkbox-box::after {
  content: '';
  position: absolute;
  left: 4px; top: 2px;
  width: 5px; height: 8px;
  border: 2px solid #fff;
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}

.af-option-name {
  flex: 1;
  line-height: 1.4;
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 400;
  letter-spacing: 0;
}

.af-count {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #999;
  background: var(--gray-100);
  padding: 1px 6px;
  border-radius: 100px;
  flex-shrink: 0;
  min-width: 20px;
  text-align: center;
}

/* =============================================
   PILL STYLE (RAM, SSD, Screen size etc)
============================================= */
.af-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 6px 14px 10px;
}

.af-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 14px;
  border: 1.5px solid var(--gray-200);
  border-radius: 100px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 12px;
  color: #444;
  background: #fff;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
  white-space: nowrap;
  user-select: none;
  font-weight: 500;
  letter-spacing: 0.01em;
}
.af-pill:hover { border-color: #999; color: #111; }
.af-pill-active {
  background: var(--black);
  border-color: var(--black);
  color: #fff;
}
.af-pill-active:hover { background: #222; border-color: #222; }

.af-pill-count {
  font-family: var(--font-mono);
  font-size: 10px;
  opacity: 0.6;
}
.af-pill-active .af-pill-count { opacity: 0.7; }

.af-pill-cb { display: none; }

/* =============================================
   PRICE RANGE
============================================= */
.af-price-wrap { padding: 10px 14px 14px !important; }

.af-price-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.af-price-field { flex: 1; display: flex; flex-direction: column; gap: 4px; }

.af-price-label {
  font-family: var(--font-body);
  font-size: 10px;
  color: #888;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
}

.af-price-input-wrap {
  position: relative;
}

.af-price-input {
  width: 100%;
  border: 1.5px solid var(--gray-200);
  border-radius: 5px;
  padding: 7px 28px 7px 10px;
  font-family: var(--font-body);
  font-size: 13px;
  color: #222;
  outline: none;
  transition: border-color 0.2s;
  -moz-appearance: textfield;
  background: #fff;
}
.af-price-input::-webkit-inner-spin-button,
.af-price-input::-webkit-outer-spin-button { -webkit-appearance: none; }
.af-price-input:focus { border-color: var(--red); }

.af-price-currency {
  position: absolute;
  right: 9px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: #999;
  pointer-events: none;
}

.af-price-divider {
  color: #bbb;
  font-size: 16px;
  padding-bottom: 8px;
  flex-shrink: 0;
}

/* Quick preset buttons */
.af-price-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.af-preset {
  background: none;
  border: 1px solid var(--gray-200);
  border-radius: 100px;
  padding: 5px 12px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 500;
  color: #555;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
  white-space: nowrap;
  letter-spacing: 0.02em;
}
.af-preset:hover { border-color: var(--red); color: var(--red); }
.af-preset.af-preset-active { background: var(--red); border-color: var(--red); color: #fff; }

/* =============================================
   SUBMIT FOOTER
============================================= */
.af-footer {
  padding: 12px 14px 14px;
  background: var(--gray-100);
  border-top: 1px solid var(--gray-200);
}

.af-submit {
  display: block;
  width: 100%;
  background: var(--red);
  color: #fff;
  border: none;
  padding: 13px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 3px;
  transition: background 0.2s;
}
.af-submit:hover { background: var(--red-dark); }

/* =============================================
   ACTIVE FILTERS BAR
============================================= */
.af-active-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 1.25rem;
  align-items: center;
}

.af-active-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: #999;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-right: 2px;
}

.af-active-tag {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}

.af-active-tag-remove {
  color: #888;
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
  text-decoration: none;
  transition: color 0.15s;
}
.af-active-tag-remove:hover { color: var(--red); }

.af-active-clear {
  background: var(--red) !important;
  color: #fff !important;
}

/* =============================================
   CHECKOUT TERMS
============================================= */
.woocommerce-terms-and-conditions-wrapper {
  background: #fff8f0;
  border: 1px solid #f0d8b0;
  border-radius: 4px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.25rem;
}
.woocommerce-terms-and-conditions-checkbox-text { font-size: 13px; color: #333; line-height: 1.6; }
.woocommerce-terms-and-conditions-checkbox-text a { color: var(--red); font-weight: 500; text-decoration: none; }
.woocommerce-terms-and-conditions-checkbox-text a:hover { text-decoration: underline; }
#terms { accent-color: var(--red); width: 16px; height: 16px; flex-shrink: 0; }
.woocommerce-checkout .woocommerce-terms-and-conditions-wrapper .woocommerce-form__input-checkbox {
  width: 16px !important; height: 16px !important; margin-top: 2px; accent-color: var(--red) !important;
}

/* =============================================
   BREADCRUMB — peidetud täielikult
============================================= */
.woocommerce-breadcrumb,
nav.woocommerce-breadcrumb,
.woocommerce .woocommerce-breadcrumb {
  display: none !important;
}

/* =============================================
   ARVUSTUSED — peidetud täielikult
============================================= */
.woocommerce-tabs .reviews_tab,
.woocommerce-tabs ul.tabs li.reviews_tab,
#tab-reviews,
.woocommerce-Reviews,
.woocommerce-Reviews *,
.comment-respond,
.comment-respond *,
#reviews,
.woocommerce #reviews,
.woocommerce-product-rating,
.star-rating,
p.stars,
.woocommerce-review-link {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

/* =============================================
   PRODUCT PAGE FIXES
============================================= */
.woocommerce div.product .summary { display: flex; flex-direction: column; }
.woocommerce div.product .product_title { order: -1; }

/* Sort dropdown */
.woocommerce-ordering select {
  border: 1px solid var(--gray-200) !important; border-radius: 3px !important;
  padding: 8px 14px !important; font-family: var(--font-body) !important;
  font-size: 13px !important; color: var(--gray-600) !important;
  outline: none !important; cursor: pointer !important;
  background: var(--white) !important; transition: border-color 0.2s !important;
}
.woocommerce-ordering select:focus { border-color: var(--red) !important; }

.woocommerce-tabs.wc-tabs-wrapper:empty,
.related.products:empty { display: none; }

/* =============================================
   RESPONSIVE
============================================= */
@media (max-width: 1100px) {
  .shop-with-filters { grid-template-columns: 240px 1fr; }
}

@media (max-width: 900px) {
  .shop-with-filters { grid-template-columns: 1fr; }
  .shop-filter-sidebar { position: static; }

  .af-wrap { display: none; }
  .af-wrap.open { display: block; }

  .af-mobile-toggle { display: flex !important; }
}

@media (min-width: 901px) {
  .af-mobile-toggle { display: none !important; }
}

.af-mobile-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  background: var(--black);
  color: var(--white);
  border: none;
  padding: 11px 20px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border-radius: 5px;
  margin-bottom: 1rem;
  letter-spacing: 0.04em;
  width: 100%;
  justify-content: center;
}
