/* SA Home Furniture: consistent self-hosted Figtree across public pages.
 * Only font-family changes. Layout, breakpoints, sizing, icons and the
 * WordPress administration toolbar retain their original behaviour. */
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/figtree/figtree-400.ttf') format('truetype');
}
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/figtree/figtree-600.ttf') format('truetype');
}
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fonts/figtree/figtree-700.ttf') format('truetype');
}

:root {
  --clx-sitewide-text-font: 'Figtree', Arial, Helvetica, sans-serif;
}

/* Body inheritance covers text in custom widgets as well as WooCommerce. */
body:not(.wp-admin) {
  font-family: var(--clx-sitewide-text-font) !important;
}

/* Keep long product names elegant without letting them take over the page.
 * Scope strictly to single-product titles, leaving catalogue headings and
 * every other responsive layout unchanged. */
body.single-product .clx-single-summary > h1 {
  font-size: var(--clx-single-title-desktop-size, 36px) !important;
  line-height: 1.12 !important;
  overflow-wrap: break-word;
}

@media (max-width: 767px) {
  body.single-product .clx-single-summary > h1 {
    font-size: var(--clx-single-title-mobile-size, 26px) !important;
  }
}

/* One progressive, fractional-star presentation for the genuine overall
 * rating on Shop, categories, individual products and review overviews.
 * Original WooCommerce star HTML remains screen-reader accessible. */
.clwr-shop-stars .clx-progressive-stars,
.clwr-single-rating-link .clx-progressive-stars,
.clwr-overview-score .clx-progressive-stars {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  flex-shrink: 0;
  vertical-align: middle;
  line-height: 1;
}
.clwr-single-rating-link .clx-progressive-stars svg,
.clwr-overview-score .clx-progressive-stars svg {
  display: block;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}
.clwr-shop-stars .clx-progressive-stars svg {
  display: block;
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
}
.clwr-shop-stars .clx-shop-rating-average {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  color: #272622;
  font-variant-numeric: tabular-nums;
}
.clwr-shop-stars .clx-progressive-stars + .star-rating,
.clwr-single-rating-link .clx-progressive-stars + .star-rating,
.clwr-overview-score .clx-progressive-stars + .star-rating {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Explicit text-family rules override legacy serif/Arial settings in theme,
 * Elementor and WooCommerce blocks without touching their responsive CSS.
 * Keep icons, glyph fonts, logos supplied as SVG and admin-bar controls safe.
 * WooCommerce star ratings use glyphs encoded as S/s in their own font; their
 * inner spans MUST inherit WooCommerce, otherwise the glyphs render as text. */
body:not(.wp-admin) :is(
  header, nav, main, section, article, aside, footer,
  div, h1, h2, h3, h4, h5, h6,
  p, span, a, strong, b, em, small, label, legend,
  ins, del, abbr, mark, address, caption,
  button, input, select, option, textarea,
  ul, ol, li, dl, dt, dd,
  table, thead, tbody, tfoot, tr, th, td,
  blockquote, cite, figcaption, summary, details, time
):not(#wpadminbar, #wpadminbar *):not(.dashicons, .dashicons-before, .fa, .fas, .far, .fab, .fal, .fad,
      .fa-solid, .fa-regular, .fa-brands, .eicon, .elementor-icon,
      .material-icons, .material-symbols-outlined, .material-symbols-rounded,
      .star-rating, .star-rating *, .stars, .stars *,
      .icon, [class^='icon-'], [class*=' icon-'],
      [class^='flaticon-'], [class*=' flaticon-'],
      [class^='ti-'], [class*=' ti-']) {
  font-family: var(--clx-sitewide-text-font) !important;
}
