/* ──────────────────────────────────────────────────────────────
   Tartan Finder Page — Hero
   Scoped to .tf-* class prefix; uses local CSS variables so it
   doesn't depend on any other stylesheet's tokens.
   ────────────────────────────────────────────────────────────── */

.tf-hero {
  --tf-ivory: #F5F0E8;
  --tf-parch-l: #F0E7D8;
  --tf-white: #FFFFFF;
  --tf-slate: #2C3E50;
  --tf-slate-d: #1E2D3B;
  --tf-slate-l: #3A5269;
  --tf-amber: #B8520A;
  --tf-amber-l: #D4681A;
  --tf-cream: #E8C9A8;
  --tf-cream-d: #D4AF7A;
  --tf-r: 6px;
  --tf-rl: 10px;
  --tf-rxl: 14px;

  position: relative;
  background: linear-gradient(135deg, var(--tf-slate-d) 0%, var(--tf-slate) 100%);
  color: var(--tf-parch-l);
  padding: 48px 24px 44px;
  border-bottom: 1px solid var(--tf-slate-d);
  overflow: hidden;
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  line-height: 1.55;
}

/* Subtle diagonal grid pattern overlay */
.tf-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(45deg, rgba(232, 201, 168, .04) 1px, transparent 1px),
    linear-gradient(-45deg, rgba(232, 201, 168, .04) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
  z-index: 0;
}

.tf-hero-wrap {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
}

.tf-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
}

/* Text column */
.tf-hero-text { min-width: 0; }

.tf-hero-eb {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-weight: 500;
  color: var(--tf-cream-d);
  margin-bottom: 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.tf-hero-eb::before {
  content: '';
  width: 22px;
  height: 1px;
  background: var(--tf-cream-d);
  opacity: .6;
}

.tf-hero-h {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -.01em;
  color: var(--tf-white);
  margin: 0 0 12px;
}
.tf-hero-h em {
  font-style: italic;
  color: var(--tf-cream);
}
/* Richtext wraps text in <p> — strip the paragraph default margin/font */
.tf-hero-h p { margin: 0; font: inherit; }

.tf-hero-sub {
  font-size: 15px;
  max-width: 520px;
  margin: 0 0 18px;
  color: var(--tf-parch-l);
  opacity: .94;
  line-height: 1.55;
}
.tf-hero-sub p { margin: 0 0 8px; }
.tf-hero-sub p:last-child { margin-bottom: 0; }
.tf-hero-sub strong {
  color: var(--tf-cream-d);
  font-weight: 500;
}

/* Popular pills */
.tf-hero-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 18px 0 16px;
  align-items: center;
}
.tf-hero-quick-label {
  font-size: 12px;
  color: var(--tf-cream-d);
  font-weight: 500;
  margin-right: 4px;
  opacity: .85;
}
.tf-hero-quick-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(232, 201, 168, .28);
  padding: 7px 14px;
  border-radius: 18px;
  font-size: 13px;
  font-weight: 400;
  color: var(--tf-cream);
  text-decoration: none;
  transition: background .15s, border-color .15s, color .15s;
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.tf-hero-quick-pill:hover,
.tf-hero-quick-pill:focus-visible {
  background: var(--tf-amber);
  border-color: var(--tf-amber);
  color: var(--tf-white);
  text-decoration: none;
  outline: none;
}

/* Trust row */
.tf-hero-trust {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 14px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--tf-parch-l);
  opacity: .88;
}
.tf-hero-trust-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tf-hero-trust-item svg {
  color: var(--tf-cream-d);
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

/* Reviews trust item doubles as the all-reviews popup trigger. Chrome-only
   reset: no font-size or colour, so it stays visually identical to the
   sibling <span> items next to it. Layout comes from .tf-hero-trust-item. */
.tf-hero-trust-item--btn {
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.tf-hero-trust-item--btn:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.tf-hero-trust-item--btn:focus-visible {
  outline: 2px solid var(--tf-cream-d);
  outline-offset: 3px;
  border-radius: 3px;
}

/* Visual / image column */
.tf-hero-visual {
  position: relative;
  border-radius: var(--tf-rxl);
  overflow: hidden;
  background: var(--tf-slate-l);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .25), inset 0 0 0 1px rgba(232, 201, 168, .15);
  aspect-ratio: 16 / 11;
}
.tf-hero-visual-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

/* Desktop layout — two-column grid with image on the right */
@media (min-width: 900px) {
  .tf-hero {
    padding: 64px 32px 56px;
  }
  .tf-hero-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 48px;
  }
  .tf-hero-visual {
    aspect-ratio: 4 / 3;
  }
}

@media (min-width: 1200px) {
  .tf-hero-grid {
    gap: 64px;
  }
}

/* ──────────────────────────────────────────────────────────────
   Sticky search bar (between hero and main)
   ────────────────────────────────────────────────────────────── */

.tf-sticky-bar {
  --tf-ivory: #F5F0E8;
  --tf-parch-l: #F0E7D8;
  --tf-amber: #B8520A;
  --tf-amber-d: #9A4308;
  --tf-amber-p: #FEF3EC;
  --tf-slate-d: #1E2D3B;
  --tf-onyx: #1A1A1A;
  --tf-body: #4A4440;
  --tf-muted: #7A726B;
  --tf-rule: rgba(74, 68, 64, .14);
  --tf-rule2: rgba(74, 68, 64, .22);
  position: relative;
  background: #fff;
  border-bottom: 1px solid var(--tf-rule);
  padding: 14px 24px;
  font-family: 'Jost', sans-serif;
}
.tf-sticky-bar-wrap {
  max-width: 1380px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
}
.tf-sticky-bar-label {
  font-family: 'Playfair Display', serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--tf-onyx);
  flex-shrink: 0;
}
@media (max-width: 600px) {
  .tf-sticky-bar-label { display: none; }
}

.tf-sticky-search {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  background: var(--tf-ivory);
  border: 1px solid var(--tf-rule2);
  border-radius: 22px;
  padding: 0 12px;
  transition: border-color .15s, background .15s;
}
.tf-sticky-search:focus-within {
  border-color: var(--tf-amber);
  background: #fff;
}
.tf-sticky-search-icon {
  width: 15px;
  height: 15px;
  color: var(--tf-muted);
  flex-shrink: 0;
}
.tf-sticky-search-input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  padding: 8px 10px;
  font-family: inherit;
  font-size: 14px;
  color: var(--tf-onyx);
  min-width: 0;
  box-shadow: none;
}
/* Override Dawn's universal *:focus-visible outline */
.tf-sticky-search-input:focus,
.tf-sticky-search-input:focus-visible {
  outline: none;
  box-shadow: none;
  border: 0;
}
.tf-sticky-search-input::placeholder { color: var(--tf-muted); }
.tf-sticky-search-input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
.tf-sticky-search-clear {
  background: none;
  border: 0;
  padding: 0 6px;
  font-size: 20px;
  line-height: 1;
  color: var(--tf-muted);
  cursor: pointer;
  border-radius: 50%;
}
.tf-sticky-search-clear:hover { color: var(--tf-amber); }

/* Typeahead dropdown */
.tf-typeahead {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid var(--tf-rule);
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(28, 40, 56, .10);
  max-height: 340px;
  overflow-y: auto;
  display: none;
  z-index: 50;
}
.tf-typeahead[data-open="true"] { display: block; }
.tf-typeahead-group {
  padding: 8px 16px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 500;
  color: var(--tf-muted);
  background: var(--tf-parch-l);
}
.tf-typeahead-item {
  padding: 10px 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid var(--tf-rule);
}
.tf-typeahead-item:last-child { border-bottom: 0; }
.tf-typeahead-item:hover,
.tf-typeahead-item.is-active { background: var(--tf-amber-p); }
.tf-typeahead-item-name {
  font-size: 14px;
  color: var(--tf-onyx);
}
.tf-typeahead-item-name strong {
  color: var(--tf-amber-d);
  font-weight: 600;
}
.tf-typeahead-item-count {
  font-size: 12px;
  color: var(--tf-muted);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.tf-typeahead-empty {
  padding: 14px 16px;
  font-size: 13px;
  color: var(--tf-muted);
  text-align: center;
}

/* ──────────────────────────────────────────────────────────────
   Main area (filter rail + results)
   ────────────────────────────────────────────────────────────── */

.tf-main {
  --tf-ivory: #F5F0E8;
  --tf-parch-l: #F0E7D8;
  --tf-slate: #2C3E50;
  --tf-slate-d: #1E2D3B;
  --tf-slate-l: #3A5269;
  --tf-amber: #B8520A;
  --tf-amber-l: #D4681A;
  --tf-amber-p: #FEF3EC;
  --tf-cream: #E8C9A8;
  --tf-rule: rgba(74, 68, 64, .14);
  --tf-rule2: rgba(74, 68, 64, .22);
  --tf-body: #4A4440;
  --tf-onyx: #1A1A1A;
  --tf-muted: #7A726B;
  --tf-muted-l: #9A9088;
  --tf-shadow-1: 0 1px 2px rgba(28, 40, 56, .06);
  --tf-shadow-3: 0 12px 32px rgba(28, 40, 56, .14);
  background: var(--tf-ivory);
  padding: 28px 20px 60px;
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  color: var(--tf-body);
}

.tf-main-wrap {
  max-width: 1380px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
}

/* ── Filter rail ── */
.tf-filter-rail {
  background: #fff;
  border: 1px solid var(--tf-rule);
  border-radius: 12px;
  box-shadow: var(--tf-shadow-1);
  overflow: hidden;
}

.tf-filter-rail-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--tf-rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* Stick to the top of the rail when its internal scroll container scrolls. */
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 5;
}
.tf-filter-rail-title {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--tf-onyx);
  margin: 0;
}

/* Full-width Clearance button — visual parity with the Quick Ship / All Tartans
   toggle, plus a crimson sale-tag icon badge to signal it's a special offer. */
.tf-availability-clearance {
  margin-top: 8px;
  position: relative;
}
.tf-availability-clearance input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.tf-availability-clearance label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: #fff;
  border: 1px solid var(--tf-rule2);
  border-radius: 6px;
  cursor: pointer;
  transition: background .12s, border-color .12s;
}
.tf-availability-clearance label:hover {
  background: var(--tf-parch-l);
}
.tf-availability-clearance input:checked + label {
  background: var(--tf-parch-l);
  border-color: #8C1F1F;
}
.tf-availability-clearance input:focus-visible + label {
  outline: 2px solid var(--tf-amber);
  outline-offset: 2px;
}
.tf-av-clearance-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: #8C1F1F;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(140, 31, 31, .25);
}
.tf-av-clearance-icon svg {
  width: 16px;
  height: 16px;
  display: block;
}
.tf-av-clearance-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
  align-items: flex-start;
}
.tf-availability-clearance .tf-av-title {
  color: #8C1F1F;
  font-weight: 600;
}
.tf-filter-clear {
  background: none;
  border: 0;
  color: var(--tf-amber);
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
}
.tf-filter-clear:hover { background: var(--tf-parch-l, #F0E7D8); }

/* Active filter chips — shown at top of the rail when any filter is applied */
.tf-filter-chips {
  padding: 10px 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  border-bottom: 1px solid var(--tf-rule);
  background: var(--tf-parch-l);
}
.tf-filter-chips:empty { display: none; }
.tf-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fff;
  border: 1px solid var(--tf-rule2);
  padding: 3px 5px 3px 9px;
  border-radius: 13px;
  font-size: 11.5px;
  color: var(--tf-body);
  font-weight: 400;
}
.tf-filter-chip-x {
  width: 17px;
  height: 17px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--tf-muted);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  transition: background .15s, color .15s;
}
.tf-filter-chip-x:hover {
  background: #8B1F1F;
  color: #fff;
}

.tf-filter-group {
  padding: 14px 16px;
  border-bottom: 1px solid var(--tf-rule);
}
.tf-filter-group:last-of-type { border-bottom: 0; }
.tf-filter-group-h {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 600;
  color: var(--tf-slate-l);
  margin: 0 0 10px;
  font-family: 'Jost', sans-serif;
}

.tf-filter-options {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.tf-filter-opt {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 7px;
  border-radius: 4px;
  font-size: 13.5px;
  font-weight: 400;
  cursor: pointer;
  transition: background .12s;
  color: var(--tf-body);
  line-height: 1.3;
}
.tf-filter-opt:hover { background: var(--tf-parch-l); }
.tf-filter-opt input {
  flex-shrink: 0;
  accent-color: var(--tf-amber);
  cursor: pointer;
  width: 14px;
  height: 14px;
  margin: 0;
}
.tf-filter-opt > span:not(.tf-filter-opt-count) {
  flex: 1;
  min-width: 0;
}
.tf-filter-opt-count {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--tf-muted);
  font-variant-numeric: tabular-nums;
}

/* Availability toggle — two stacked options with title + pattern count */
.tf-availability-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.tf-availability-toggle input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.tf-availability-toggle label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  padding: 10px 12px;
  background: #fff;
  border: 1px solid var(--tf-rule2);
  border-radius: 6px;
  cursor: pointer;
  transition: background .12s, border-color .12s;
}
.tf-availability-toggle label:hover {
  background: var(--tf-parch-l);
}
.tf-availability-toggle input:checked + label {
  background: var(--tf-parch-l);
  border-color: var(--tf-rule);
}
.tf-availability-toggle input:focus-visible + label {
  outline: 2px solid var(--tf-amber);
  outline-offset: 2px;
}
.tf-av-title {
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--tf-onyx);
  line-height: 1.2;
}
.tf-av-count {
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 400;
  color: var(--tf-muted);
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

/* Colour palette — tartan-sett SVG tiles with text labels */
.tf-palette-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.tf-palette-opt {
  position: relative;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border-radius: 6px;
  background: var(--tf-ivory);
  border: 0;
  transition: background .15s;
  font-family: inherit;
}
.tf-palette-opt:hover { background: var(--tf-parch-l); }
.tf-palette-opt.is-active .tf-palette-opt-tile {
  box-shadow: 0 0 0 2px var(--tf-amber);
  transform: scale(1.05);
}
.tf-palette-opt.is-active .tf-palette-opt-label {
  color: var(--tf-amber);
  font-weight: 500;
}
.tf-palette-opt-tile {
  width: 42px;
  height: 42px;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  transition: transform .15s, box-shadow .15s;
  background: #3a3a35;
  display: block;
}
.tf-palette-opt-tile svg {
  width: 100%;
  height: 100%;
  display: block;
}
.tf-palette-opt-label {
  font-size: 11px;
  color: var(--tf-body);
  text-align: center;
  line-height: 1.15;
  font-weight: 400;
}

/* ── Results column ── */
.tf-results { min-width: 0; }

.tf-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.tf-results-count {
  font-size: 13.5px;
  color: var(--tf-body);
  margin: 0;
}
.tf-results-count strong {
  color: var(--tf-onyx);
  font-weight: 600;
}
.tf-results-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.tf-results-search {
  background: #fff;
  border: 1px solid var(--tf-rule2);
  border-radius: 6px;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 13px;
  color: var(--tf-onyx);
  min-width: 240px;
}
.tf-results-search:focus {
  outline: none;
  border-color: var(--tf-amber);
  box-shadow: 0 0 0 3px rgba(184, 82, 10, .1);
}
.tf-results-sort {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--tf-muted);
}
.tf-results-sort-select {
  background: #fff;
  border: 1px solid var(--tf-rule2);
  border-radius: 6px;
  padding: 7px 10px;
  font-family: inherit;
  font-size: 13px;
  color: var(--tf-onyx);
  cursor: pointer;
}

/* ── Tartan grid ── */
.tf-tartan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.tf-grid-loading {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 20px;
  color: var(--tf-muted);
  font-size: 13.5px;
}

/* Card */
.tf-card {
  background: #fff;
  border: 1px solid var(--tf-rule);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: var(--tf-body);
  transition: transform .15s, box-shadow .15s, border-color .15s;
  position: relative;
}
.tf-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--tf-shadow-3);
  border-color: var(--tf-amber-l);
  text-decoration: none;
}
.tf-card-img-wrap {
  aspect-ratio: 1;
  position: relative;
  background: var(--tf-parch-l, #F0E7D8);
  overflow: hidden;
}
.tf-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s;
}
.tf-card:hover .tf-card-img { transform: scale(1.04); }

.tf-card-badges {
  position: absolute;
  top: 9px;
  left: 9px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-start;
  z-index: 2;
}
.tf-card-badge {
  padding: 3px 8px;
  border-radius: 11px;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  box-shadow: var(--tf-shadow-1);
  background: #fff;
  color: var(--tf-slate-d);
}
.tf-card-badge.is-qs { background: #1A5C2A; color: #fff; }
.tf-card-badge.is-cw { background: var(--tf-slate-d); color: var(--tf-cream); }
.tf-card-badge.is-cl { background: #8C1F1F; color: #fff; }
.tf-card-badge.is-var { background: var(--tf-amber-p); color: var(--tf-amber); }

.tf-card-body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}
.tf-card-name {
  font-family: 'Playfair Display', serif;
  font-size: 15.5px;
  font-weight: 600;
  color: var(--tf-onyx);
  line-height: 1.2;
  letter-spacing: -.01em;
  margin: 0;
  min-height: 2.4em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tf-card-meta {
  font-size: 11.5px;
  color: var(--tf-muted);
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
  line-height: 1.3;
  margin: 0;
}
.tf-card-meta-clan {
  color: var(--tf-slate-l);
  font-weight: 500;
}
.tf-card-meta-sep { color: var(--tf-rule2); }

.tf-card-price {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--tf-rule);
}
.tf-card-price-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
}
.tf-card-price-eb {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 500;
  color: var(--tf-muted);
}
.tf-card-price-val {
  font-family: 'Playfair Display', serif;
  font-size: 17px;
  font-weight: 600;
  color: var(--tf-onyx);
  line-height: 1;
}
.tf-card-price-secondary {
  font-size: 11.5px;
  color: var(--tf-muted);
  margin-top: 4px;
}

.tf-card-cta {
  margin-top: 10px;
  padding: 9px 12px;
  background: var(--tf-slate);
  color: #fff;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background .15s;
}
.tf-card:hover .tf-card-cta {
  background: var(--tf-amber);
}

/* Empty + load more */
.tf-results-empty {
  text-align: center;
  padding: 60px 24px;
  background: #fff;
  border: 1px solid var(--tf-rule);
  border-radius: 12px;
  margin-top: 20px;
}
.tf-results-empty h3 {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  color: var(--tf-onyx);
  margin: 0 0 6px;
}
.tf-results-empty p {
  font-size: 13.5px;
  color: var(--tf-muted);
  margin: 0 0 16px;
}
.tf-results-empty-btn {
  background: var(--tf-amber);
  color: #fff;
  border: 0;
  padding: 10px 20px;
  border-radius: 6px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.tf-results-empty-btn:hover { background: var(--tf-amber-l); }

.tf-load-more-wrap {
  margin-top: 24px;
  text-align: center;
}
.tf-load-more-btn {
  background: #fff;
  border: 1px solid var(--tf-rule2);
  color: var(--tf-onyx);
  padding: 11px 22px;
  border-radius: 6px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.tf-load-more-btn:hover {
  background: var(--tf-amber);
  color: #fff;
  border-color: var(--tf-amber);
}

/* Desktop layout — sidebar + main */
@media (min-width: 900px) {
  .tf-main {
    padding: 32px 24px 64px;
  }
  .tf-main-wrap {
    grid-template-columns: 280px 1fr;
    gap: 28px;
  }
  .tf-filter-rail {
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
  }
}

/* Mobile-only: drawer-style filter rail + 2-col tartan grid */
.tf-filter-open-btn { display: none; }
.tf-filter-rail-close { display: none; }
.tf-filter-backdrop { display: none; }

@media (max-width: 899px) {
  /* 2 tartans per row on mobile */
  .tf-tartan-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  /* Keep results count + sort on the same line */
  .tf-results-header {
    flex-wrap: nowrap;
    gap: 10px;
  }
  .tf-results-count {
    font-size: 12.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .tf-results-controls {
    flex-wrap: nowrap;
    flex-shrink: 0;
  }
  .tf-results-sort label { font-size: 12.5px; }
  .tf-results-sort-select { font-size: 12.5px; padding: 5px 22px 5px 8px; }

  /* "Filters" trigger button — sits inline with the sticky search */
  .tf-filter-open-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: #2C3E50;
    border: 1px solid #2C3E50;
    border-radius: 22px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    color: #fff;
    cursor: pointer;
    line-height: 1;
    flex-shrink: 0;
  }
  .tf-filter-open-btn:hover { background: #1E2D3B; }
  .tf-filter-open-btn svg { color: #fff; }

  /* Filter rail becomes a slide-in drawer from the left */
  .tf-filter-rail {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(85vw, 340px);
    max-height: 100vh;
    overflow-y: auto;
    border-radius: 0;
    border: 0;
    border-right: 1px solid var(--tf-rule);
    z-index: 1001;
    transform: translateX(-100%);
    transition: transform .25s ease;
    box-shadow: 0 0 24px rgba(0,0,0,.2);
  }
  .tf-filter-rail.is-open {
    transform: translateX(0);
  }

  /* Close (×) button visible in drawer header */
  .tf-filter-rail-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin-left: 8px;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 50%;
    color: var(--tf-onyx);
    cursor: pointer;
  }
  .tf-filter-rail-close:hover { background: var(--tf-ivory); }

  /* Backdrop */
  .tf-filter-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
  }
  .tf-filter-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }

  /* Lock body scroll when drawer is open */
  body.tf-filter-lock {
    overflow: hidden;
  }
}

/* ──────────────────────────────────────────────────────────────
   Custom Weave band (MTO)
   ────────────────────────────────────────────────────────────── */

.tf-mto {
  --tf-ivory: #F5F0E8;
  --tf-parch-l: #F0E7D8;
  --tf-slate: #2C3E50;
  --tf-slate-d: #1E2D3B;
  --tf-slate-l: #3A5269;
  --tf-amber: #B8520A;
  --tf-amber-l: #D4681A;
  --tf-cream: #E8C9A8;
  --tf-cream-d: #D4AF7A;
  --tf-rxl: 14px;
  position: relative;
  background: linear-gradient(135deg, var(--tf-slate-d) 0%, var(--tf-slate) 100%);
  color: #F0E7D8;
  padding: 48px 24px;
  overflow: hidden;
  font-family: 'Jost', sans-serif;
  font-weight: 300;
}
.tf-mto::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(45deg, rgba(232, 201, 168, .04) 1px, transparent 1px),
    linear-gradient(-45deg, rgba(232, 201, 168, .04) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}
.tf-mto-wrap {
  max-width: 1080px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
  position: relative;
  z-index: 1;
}
.tf-mto-text { min-width: 0; }
.tf-mto-eb {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--tf-cream-d);
  margin-bottom: 12px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}
.tf-mto-eb::before {
  content: '';
  width: 20px;
  height: 1px;
  background: var(--tf-cream-d);
}
.tf-mto-h {
  font-family: 'Playfair Display', serif;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  color: #fff;
  margin: 0 0 12px;
  font-weight: 600;
  letter-spacing: -.01em;
}
.tf-mto-h em { color: var(--tf-cream); font-style: italic; }
.tf-mto-h p { margin: 0; font: inherit; }
.tf-mto-p {
  font-size: 14.5px;
  color: #F0E7D8;
  line-height: 1.6;
  margin: 0 0 20px;
  opacity: .92;
}
.tf-mto-p p { margin: 0 0 8px; }
.tf-mto-p p:last-child { margin: 0; }
.tf-mto-p strong { color: var(--tf-cream-d); font-weight: 500; }

.tf-mto-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 20px 0 22px;
}
.tf-mto-stat {
  border-left: 2px solid var(--tf-cream-d);
  padding-left: 12px;
}
.tf-mto-stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 600;
  color: #fff;
  line-height: 1;
}
.tf-mto-stat-num small {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--tf-cream-d);
}
.tf-mto-stat-label {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--tf-cream-d);
  margin-top: 4px;
  font-weight: 500;
}

.tf-mto-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--tf-amber);
  color: #fff;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 14px;
  transition: background .15s;
  text-decoration: none;
}
.tf-mto-cta:hover { background: var(--tf-amber-l); color: #fff; text-decoration: none; }
.tf-mto-cta svg { width: 16px; height: 16px; }
.tf-mto-cta-2 {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 14px;
  color: var(--tf-cream);
  border: 1px solid rgba(232, 201, 168, .3);
  margin-left: 10px;
  transition: background .15s;
  text-decoration: none;
}
.tf-mto-cta-2:hover { background: rgba(232, 201, 168, .1); color: var(--tf-cream); text-decoration: none; }
@media (max-width: 480px) { .tf-mto-cta-2 { display: none; } }

.tf-mto-visual {
  position: relative;
  border-radius: var(--tf-rxl);
  overflow: hidden;
  background: var(--tf-slate-l);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .25), inset 0 0 0 1px rgba(232, 201, 168, .15);
  aspect-ratio: 16 / 11;
}
.tf-mto-visual-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

@media (min-width: 780px) {
  .tf-mto-wrap {
    grid-template-columns: 1.3fr 1fr;
    gap: 42px;
  }
  .tf-mto-visual {
    aspect-ratio: 4 / 3;
  }
}

/* ──────────────────────────────────────────────────────────────
   Heritage cross-link (Not sure of your clan?)
   ────────────────────────────────────────────────────────────── */

.tf-heritage {
  --tf-parch: #E8DFD0;
  --tf-cream: #E8C9A8;
  --tf-cream-d: #D4AF7A;
  --tf-slate: #2C3E50;
  --tf-slate-d: #1E2D3B;
  --tf-amber-d: #9A4308;
  --tf-onyx: #1A1A1A;
  background: linear-gradient(135deg, var(--tf-cream) 0%, var(--tf-parch) 50%, var(--tf-cream-d) 100%);
  padding: 40px 24px;
  font-family: 'Jost', sans-serif;
}
.tf-heritage-wrap {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  text-align: center;
  gap: 16px;
  align-items: center;
}
.tf-heritage-ico {
  width: 56px;
  height: 56px;
  background: var(--tf-slate-d);
  color: var(--tf-cream);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin: 0 auto;
}
.tf-heritage-ico svg { width: 24px; height: 24px; }
.tf-heritage-h {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--tf-slate-d);
  margin: 0 0 4px;
  line-height: 1.2;
}
.tf-heritage-h em { color: var(--tf-amber-d); font-style: italic; }
.tf-heritage-p {
  font-size: 14px;
  color: var(--tf-slate);
  margin: 0;
  line-height: 1.5;
}
.tf-heritage-p p { margin: 0; }
.tf-heritage-p em { color: var(--tf-amber-d); font-style: italic; }
.tf-heritage-cta {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--tf-slate-d);
  color: var(--tf-cream);
  padding: 13px 24px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 14px;
  text-decoration: none;
  transition: background .15s;
  flex-shrink: 0;
  justify-self: center;
}
.tf-heritage-cta:hover { background: var(--tf-onyx); color: var(--tf-cream); text-decoration: none; }
.tf-heritage-cta svg { width: 16px; height: 16px; }

@media (min-width: 780px) {
  .tf-heritage-wrap {
    grid-template-columns: auto 1fr auto;
    text-align: left;
    gap: 24px;
  }
  .tf-heritage-ico { margin: 0; }
}

/* ──────────────────────────────────────────────────────────────
   FAQ
   ────────────────────────────────────────────────────────────── */

.tf-faq {
  --tf-ivory: #F5F0E8;
  --tf-white: #FFFFFF;
  --tf-amber: #B8520A;
  --tf-amber-l: #D4681A;
  --tf-amber-d: #9A4308;
  --tf-onyx: #1A1A1A;
  --tf-body: #4A4440;
  --tf-rule: rgba(74, 68, 64, .14);
  --tf-rl: 10px;
  --tf-shadow-2: 0 4px 14px rgba(28, 40, 56, .10);
  background: var(--tf-ivory);
  padding: 56px 24px;
  font-family: 'Jost', sans-serif;
}
.tf-faq-wrap {
  max-width: 780px;
  margin: 0 auto;
}
.tf-faq-head {
  text-align: center;
  margin-bottom: 28px;
}
.tf-faq-eb {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--tf-amber-d);
  font-weight: 500;
  margin-bottom: 8px;
}
.tf-faq-h {
  font-family: 'Playfair Display', serif;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
  color: var(--tf-onyx);
  margin: 0;
  font-weight: 600;
}
.tf-faq-h em { color: var(--tf-amber-d); font-style: italic; }
.tf-faq-h p { margin: 0; font: inherit; }

.tf-faq-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.tf-faq-item {
  background: var(--tf-white);
  border: 1px solid var(--tf-rule);
  border-radius: var(--tf-rl);
  overflow: hidden;
  transition: border-color .15s, box-shadow .15s;
}
.tf-faq-item[open] {
  border-color: var(--tf-amber-l);
  box-shadow: var(--tf-shadow-2);
}
.tf-faq-summary {
  padding: 16px 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  list-style: none;
  font-family: 'Playfair Display', serif;
  font-size: 15.5px;
  font-weight: 600;
  color: var(--tf-onyx);
  line-height: 1.3;
}
.tf-faq-summary::-webkit-details-marker { display: none; }
.tf-faq-chev {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform .2s;
  color: var(--tf-amber);
}
.tf-faq-item[open] .tf-faq-chev { transform: rotate(180deg); }
.tf-faq-a {
  padding: 0 20px 18px;
  font-size: 14px;
  color: var(--tf-body);
  line-height: 1.6;
}
.tf-faq-a p { margin: 0 0 8px; }
.tf-faq-a p:last-child { margin: 0; }
.tf-faq-a a { color: var(--tf-amber-d); font-weight: 500; }
.tf-faq-a strong { font-weight: 600; }

/* ═══════════════════════════════════════════════════════════════
   INTRO — informational block above the FAQ (enrichment pack TF-03a)
   Sits visually as the FAQ section's lead-in: same ivory ground,
   same 780px measure, serif heading in the tf-faq voice.
   ═══════════════════════════════════════════════════════════════ */
.tf-intro {
  --tf-ivory: #F5F0E8;
  --tf-amber: #B8520A;
  --tf-onyx: #1A1A1A;
  --tf-body: #4A4440;
  background: var(--tf-ivory);
  padding: 56px 24px 8px;
  font-family: 'Jost', sans-serif;
}
.tf-intro-wrap {
  max-width: 780px;
  margin: 0 auto;
}
.tf-intro-h {
  font-family: 'Playfair Display', serif;
  font-size: clamp(22px, 2.6vw, 28px);
  line-height: 1.2;
  color: var(--tf-onyx);
  margin: 0 0 14px;
  font-weight: 600;
}
.tf-intro-body p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--tf-body);
  margin: 0 0 12px;
  font-weight: 300;
}
.tf-intro-body p:last-child { margin-bottom: 0; }
.tf-intro-body a {
  color: var(--tf-amber);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* "About Tartan" divider between the buying FAQs (1–6) and the
   informational set (7+) — pack placement rule TF-03. */
.tf-faq-split {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--tf-onyx);
  margin: 36px 0 10px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--tf-amber);
}
