/* ============================================================
   GEWA Germany -- PRODUCT LISTING PAGE
   product-listing.css (products.html.twig)
   ============================================================ */

/* ── 09-14. PRODUCT LISTING PAGE ── */


  

  
  

  /* NAV — legacy bare `nav{}` / `.nav-links` / `.nav-cta` / `.lang-sw` /
     duplicate `.nav-logo` & `.nav-right` rules removed here. They were
     leftovers from an old product-listing prototype, unused in
     layout.html.twig, and were bleeding onto the live <nav class="gewa-nav">
     (matched the bare `nav` element selector) and overriding .nav-logo /
     .nav-right with conflicting values. */

  /* PAGE HEADER */
  .page-header {
    padding: 48px 48px 0;
    border-bottom: 0.5px solid var(--w06);
  }
  .ph-breadcrumb {
    display: flex; gap: 8px; align-items: center;
    font-size: 14px; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--w30); margin-bottom: 20px;
  }
  .ph-breadcrumb a { color: var(--w30); text-decoration: none; transition: color 0.15s; }
  .ph-breadcrumb a:hover, .ph-breadcrumb a:focus-visible { color: var(--gold); }
  .ph-breadcrumb span.sep { color: rgba(255,255,255,0.15); }
  .ph-breadcrumb span.current { color: var(--gold); }
  .ph-top { display: flex; align-items: flex-end; justify-content: space-between; padding-bottom: 24px; }
  .ph-title { font-family: 'Cormorant Garamond', serif; font-size: 42px; font-weight: 300; color: var(--cream); line-height: 1; }
  .ph-title em { font-style: italic; color: var(--gold); }
  .ph-count { font-size: 16px; letter-spacing: 0.1em; color: var(--w65); }
  .ph-count span { color: var(--gold); font-family: 'Cormorant Garamond', serif; font-size: 26px; font-weight: 300; }
  .ph-description { font-size: 15px; color: var(--w55); line-height: 1.7; margin-top: 16px; max-width: 640px; }

  /* ACTIVE FILTERS BAR */
  .active-filters {
    display: flex; gap: 8px; align-items: center;
    padding: 12px 48px;
    border-bottom: 0.5px solid var(--w06);
    background: var(--ink-mid);
    flex-wrap: wrap;
    min-height: 48px;
  }

  /* Mobile filter-drawer trigger — hidden on desktop, where the sidebar is
     always visible in its own grid column. Shown via the mobile media
     query further down. */
  .filter-toggle-btn {
    display: none;
    align-items: center; gap: 8px;
    font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--cream); background: var(--ink);
    border: 0.5px solid var(--w10);
    padding: 9px 14px;
    cursor: pointer;
    flex-shrink: 0;
  }
  .filter-toggle-btn svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  .filter-toggle-count {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 16px; height: 16px; padding: 0 4px;
    border-radius: 8px;
    background: var(--gold); color: var(--ink);
    font-size: 10px; font-weight: 700;
  }

  /* Backdrop behind the off-canvas filter drawer — same pattern as the
     mobile nav / dealer modal backdrops in gewa.css section 08. */
  .filter-backdrop {
    display: none;
    position: fixed; inset: 0; z-index: 899;
    background: rgba(0,0,0,0); pointer-events: none;
    transition: background 0.25s ease;
  }
  .filter-backdrop.visible { background: rgba(0,0,0,0.55); pointer-events: all; }
  .af-label { font-size: 15px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--w65); margin-right: 4px; }
  .af-tag {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 2px 10px;
    border: 0.5px solid var(--gold-dim);
    background: rgba(201,168,76,0.08);
    font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold);
    cursor: pointer; transition: background 0.2s;
  }
  .af-none { font-size:13px; color:var(--w55); letter-spacing:0.08em; }
  .af-tag:hover { background: rgba(201,168,76,0.15); }
  .af-tag .x { font-size: 24px; opacity: 0.7; color: inherit; text-decoration: none; transition: opacity 0.2s, color 0.2s; }
  .af-tag .x:hover { opacity: 1; color: var(--gold-light); }
  .af-clear { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--w55); cursor: pointer; margin-left: 8px; border: none; background: none; color: var(--w60); transition: color 0.2s; }
  .af-clear:hover { color: var(--gold); }

  /* LAYOUT */
  .layout { display: grid; grid-template-columns: 240px 1fr; min-height: calc(100vh - 64px); }

  /* SIDEBAR FILTERS */
  .sidebar {
    border-right: 0.5px solid var(--w06);
    padding: 28px 0;
    background: var(--ink-mid);
    position: sticky; top: 64px; align-self: start; height: calc(100vh - 64px); overflow-y: auto;
  }
  .sidebar::-webkit-scrollbar { width: 3px; }
  .sidebar::-webkit-scrollbar-thumb { background: var(--w10); }

  .filter-group { border-bottom: 0.5px solid var(--w06); padding: 0 20px 20px; margin-bottom: 0; }
  .filter-group:last-child { border-bottom: none; }
  .fg-head {
    font-size: 17px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--w65);
    padding: 20px 0 12px; display: flex; justify-content: space-between; align-items: center;
    cursor: pointer;
  }
  .fg-head .toggle { font-size: 17px; color: var(--w65); transition: transform 0.2s; }
  .fg-head.open .toggle { transform: rotate(180deg); }
  .fg-body { padding: 4px 8px 14px; }
  .fg-body.hidden { display: none; }

  .filter-opt {
    display: flex; align-items: center; gap: 10px;
    padding: 6px 8px; cursor: pointer;
    transition: background 0.15s; border-radius: 2px;
    color: inherit; text-decoration: none;
  }
  .filter-opt:hover { background: var(--w04); }
  .filter-opt.disabled { opacity: 0.3; cursor: not-allowed; }
  .filter-opt input[type="checkbox"] { display: none; }
  .fo-box {
    width: 14px; height: 14px;
    border: 0.5px solid var(--w30);
    flex-shrink: 0; position: relative;
    transition: border-color 0.15s, background 0.15s;
  }
  .filter-opt.checked .fo-box { border-color: var(--gold); background: var(--gold); }
  .filter-opt.checked .fo-box::after {
    content: ''; position: absolute; top: 2px; left: 4px;
    width: 4px; height: 7px; border-right: 1.5px solid #0e0d0b; border-bottom: 1.5px solid #0e0d0b;
    transform: rotate(45deg);
  }
  .fo-label { font-size: 14px; letter-spacing: 0.06em; color: var(--w60); flex: 1; }
  .filter-opt.checked .fo-label { color: var(--gold); }
  .fo-count { font-size: 14px; color: var(--w60); }
  .filter-opt.disabled .fo-label::after { content: ' —'; font-size: 10px; }

  /* Colour swatches */
  .swatch-grid { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 0; }
  .swatch {
    width: 24px; height: 24px; border-radius: 2px;
    border: 1.5px solid transparent; cursor: pointer;
    transition: border-color 0.15s; position: relative;
  }
  .swatch.selected { border-color: var(--gold); }
  .swatch[data-color="gold-lacquer"] { background: #c9a84c; }
  .swatch[data-color="silver-plate"] { background: #c4c4be; }
  .swatch[data-color="raw-brass"] { background: #8a7040; }
  .swatch[data-color="vintage"] { background: #7a5c38; }
  .swatch[data-color="matt-gold"] { background: #a88a38; }
  .swatch[data-color="black"] { background: #2a2a2a; }
  .swatch-label { font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--w55); margin-top: 8px; display: block; }

  /* Price range */
  .price-range { padding: 4px 0; }
  .pr-track { position: relative; height: 2px; background: var(--w10); margin: 16px 0; }
  .pr-fill { position: absolute; height: 100%; background: var(--gold); left: 0%; right: 20%; }
  .pr-thumb {
    position: absolute; top: 50%; transform: translate(-50%,-50%);
    width: 14px; height: 14px; border-radius: 50%;
    background: var(--gold); border: 2px solid var(--ink); cursor: pointer;
  }
  .pr-thumb.left { left: 0%; }
  .pr-thumb.right { left: 80%; }
  .pr-vals { display: flex; justify-content: space-between; font-size: 11px; color: var(--w55); }
  .pr-vals span { color: var(--cream); }
  input[type="range"].price-slider {
    width: 100%; accent-color: var(--gold); cursor: pointer;
    background: transparent; margin: 8px 0;
  }

  /* K. Sandner special filter */
  .ks-filter {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 8px; cursor: pointer;
    border: 0.5px solid rgba(201,168,76,0.2);
    background: rgba(201,168,76,0.05);
    margin-top: 8px;
    transition: background 0.2s;
  }
  .ks-filter:hover { background: rgba(201,168,76,0.1); }
  .ks-filter.checked { border-color: var(--gold); background: rgba(201,168,76,0.12); }
  .ks-icon { width: 20px; height: 20px; border-radius: 50%; background: var(--gold-dim); display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 600; color: var(--gold); flex-shrink: 0; }
  .ks-text { flex: 1; }
  .ks-name { font-size: 11px; letter-spacing: 0.06em; color: var(--gold-light); }
  .ks-sub { font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--w55); }

  /* Sort bar */
  .sort-bar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 28px;
    border-bottom: 0.5px solid var(--w06);
  }
  .sort-left { display: flex; gap: 4px; align-items: center; }
  .sort-right { display: flex; gap: 4px; align-items: center; }
  .sort-label { font-size:12px; letter-spacing:0.18em; text-transform:uppercase; color:var(--gold); margin-right:8px; }
  .sort-btn {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 14px; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--w60); background: none; border: 0.5px solid transparent;
    padding: 6px 12px; cursor: pointer; transition: all 0.15s;
    text-decoration: none;
  }
  .sort-btn:hover { border-color: var(--w20); color: var(--w70); }
  .sort-btn.active { border-color: var(--gold-dim); color: var(--gold); background: rgba(201,168,76,0.06); }
  .view-toggle { display: flex; gap: 4px; }
  .vt-btn { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border: 0.5px solid var(--w10); background: none; cursor: pointer; color: var(--w55); font-size: 14px; transition: all 0.15s; text-decoration: none; }
  .vt-btn.active { border-color: var(--gold-dim); color: var(--gold); background: rgba(201,168,76,0.06); }

  /* PRODUCT GRID */
  .product-area { padding: 0; min-width: 0; }
  .product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
  }
  .product-grid.list-view { grid-template-columns: 1fr; }

  /* PRODUCT CARD */
  /* background: #000 — product photography is being redone by the outside
     agency on solid black rather than transparent (the Art Director's call:
     black-background cutouts remain usable off our site — other channels,
     future redesigns — where a transparent-on-ink-soft image wouldn't).
     Kept as an explicit background here rather than left to .card-img alone
     so the whole card reads as one consistent black surface once images
     land, instead of a lighter card frame around a black image tile. */
  .product-card {
    background: #000;
    border: 0.5px solid var(--w10);
    padding: 24px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    position: relative;
    display: flex; flex-direction: column;
    text-decoration: none;
    color: inherit;
  }
  .product-card:hover { background: #000; border-color: var(--gold-dim); }

  /* series badges */
  .card-badges { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
  .badge {
    font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase;
    padding: 3px 8px; border: 0.5px solid;
  }
  .badge-ambition { color: rgba(255,255,255,0.5); border-color: rgba(255,255,255,0.15); }
  .badge-vision { color: #e8c86a; border-color: rgba(232,200,106,0.4); }
  .badge-artist { color: var(--gold-light); border-color: var(--gold); background: rgba(201,168,76,0.08); }
  .badge-ks { color: var(--gold); border-color: var(--gold); background: rgba(201,168,76,0.12); font-style: italic; }
  .badge-new { color: #5dcaa5; border-color: rgba(93,202,165,0.4); background: rgba(93,202,165,0.06); }

  .card-img {
    width: 100%; aspect-ratio: 4/3;
    display: flex; align-items: center; justify-content: center;
    background: #000; margin-bottom: 16px;
    position: relative; overflow: hidden;
  }
  .card-img img { max-width: 80%; max-height: 80%; object-fit: contain; }
  .card-img .img-placeholder {
    font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--w20); text-align: center;
  }
  .variant-dots { position: absolute; bottom: 8px; right: 8px; display: flex; gap: 4px; }
  .vdot { width: 10px; height: 10px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.2); }
  .vdot.gold { background: #c9a84c; }
  .vdot.silver { background: #c4c4be; }
  .vdot.vintage { background: #7a5c38; }
  .vdot.matt { background: #a88a38; }

  .card-type { font-size: 9px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); margin-bottom: 4px; }
  .card-name { font-family: 'Cormorant Garamond', serif; font-size: 27px; font-weight: 300; color: var(--cream); line-height: 1.1; margin-bottom: 6px; }
  .card-brand { font-size: 13px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); margin-bottom: 8px; }
  .card-model { font-size: 12px; letter-spacing: 0.12em; color: var(--w55); margin-bottom: 12px; }
  .card-badge { display: inline-block; font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase; padding: 3px 8px; }
  .card-badge--new { background: var(--gold); color: var(--ink); }
  .card-specs { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
  .cs-item { font-size: 13px; letter-spacing: 0.06em; color: var(--w55); }
  .cs-item strong { color: var(--w55); font-weight: 400; }

  .card-footer { margin-top: auto; display: flex; align-items: center; justify-content: space-between; padding-top: 14px; border-top: 0.5px solid var(--w10); transition: border-color 0.2s; }
  .product-card:hover .card-footer { border-top-color: var(--gold-dim); }
  .card-price { font-family: 'Cormorant Garamond', serif; font-size: 22px; font-weight: 300; color: var(--cream); }
  .card-price-note { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--w55); }
  .card-price-hidden { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--w55); }
  .card-cta {
    font-family: 'Barlow Condensed', sans-serif;
    font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase;
    color: var(--ink); background: var(--gold); border: none;
    padding: 9px 16px; cursor: pointer; font-weight: 600;
    opacity: 0; transition: opacity 0.2s;
  }
  .product-card:hover .card-cta { opacity: 1; }

  /* LIST VIEW card */
  .product-grid.list-view .product-card {
    flex-direction: row; gap: 24px; align-items: center;
    border-right: none;
    padding: 16px 28px;
  }
  .product-grid.list-view .card-img { width: 100px; min-width: 100px; aspect-ratio: 1; margin-bottom: 0; }
  .product-grid.list-view .card-badges { margin-bottom: 6px; }
  .product-grid.list-view .card-specs { margin-bottom: 0; }
  .product-grid.list-view .card-footer { border-top: none; padding-top: 0; flex-direction: column; align-items: flex-end; gap: 8px; min-width: 120px; }
  .product-grid.list-view .card-cta { opacity: 1; }
  .product-grid.list-view .card-content { flex: 1; }

  /* K. SANDNER SECTION DIVIDER */
  .ks-divider {
    grid-column: 1 / -1;
    display: flex; align-items: center; gap: 16px;
    padding: 20px 24px;
    background: rgba(201,168,76,0.04);
    border-top: 0.5px solid rgba(201,168,76,0.2);
    border-bottom: 0.5px solid rgba(201,168,76,0.2);
  }
  .ks-divider-line { flex: 1; height: 0.5px; background: rgba(201,168,76,0.2); }
  .ks-divider-text { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-style: italic; color: var(--gold); letter-spacing: 0.06em; white-space: nowrap; }
  .ks-divider-sub { font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--w55); }

  /* NO RESULTS */
  .no-results {
    grid-column: 1 / -1; padding: 80px 40px; text-align: center;
  }
  .nr-title { font-family: 'Cormorant Garamond', serif; font-size: 28px; font-weight: 300; color: var(--cream); margin-bottom: 12px; }
  .nr-sub { font-size: 12px; color: var(--w55); line-height: 1.7; }

  /* PAGINATION */
  .pagination { display: flex; justify-content: center; align-items: center; gap: 4px; padding: 40px; border-top: 0.5px solid var(--w06); }
  .pg-btn { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border: 0.5px solid var(--w10); background: none; color: var(--w55); cursor: pointer; font-family: 'Barlow Condensed', sans-serif; font-size: 12px; letter-spacing: 0.06em; transition: all 0.15s; }
  .pg-btn:hover { border-color: var(--gold-dim); color: var(--gold); }
  .pg-btn.active { border-color: var(--gold); color: var(--gold); background: rgba(201,168,76,0.08); }
  .pg-btn.arrow { font-size: 16px; }

  /* RESPONSIVE */
  @media (max-width: 1100px) { .product-grid { grid-template-columns: repeat(2,1fr); } }
  @media (max-width: 860px) {
    .layout { grid-template-columns: 1fr; }
    .page-header { padding: 24px 20px 0; }
    .active-filters { padding: 12px 20px; }
    .product-grid { grid-template-columns: 1fr; }

    /* Filters: off-canvas drawer instead of a static block that used to
       push the whole page down before the fold. Opened via
       .filter-toggle-btn (shown here, hidden on desktop); closed via its
       own backdrop, Escape, or tapping outside — see gewagermany.js /
       the template's own filter-drawer script. */
    .filter-toggle-btn { display: inline-flex; }
    .filter-backdrop { display: block; }
    .sidebar {
      position: fixed; top: 0; bottom: 0; left: 0; z-index: 900;
      width: 86vw; max-width: 340px;
      padding-top: calc(var(--nav-h) + 16px);
      transform: translateX(-100%);
      transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
      box-shadow: 24px 0 48px rgba(0,0,0,0.5);
    }
    .sidebar.open { transform: translateX(0); }

    /* Sort bar: let the sort options scroll horizontally within their own
       row instead of forcing the row (and therefore the page) wider than
       the viewport — .product-area already has min-width:0 above so this
       scroll area can't blow out the grid column. */
    .sort-bar { padding: 12px 16px; gap: 12px; }
    .sort-left {
      flex: 1 1 auto; min-width: 0;
      overflow-x: auto; -webkit-overflow-scrolling: touch;
      flex-wrap: nowrap; white-space: nowrap;
      scrollbar-width: none; -ms-overflow-style: none;
    }
    .sort-left::-webkit-scrollbar { display: none; }
    .sort-right { flex-shrink: 0; }

    /* Card CTA is opacity:0 until :hover, which doesn't exist on touch —
       so on mobile it just never appeared. Make it always visible there. */
    .card-cta { opacity: 1; }
  }