/* ---- tokens ---- */
:root {
  --ink: #1C1F1D;
  --canvas: #EFEDE4;
  --steel: #545B54;
  --hi-vis: #D7E600;
  --rust: #B8420C;
  --line: #D8D4C6;
  --font-display: 'Archivo Black', 'Arial Black', sans-serif;
  --font-body: 'IBM Plex Sans', 'Segoe UI', sans-serif;
}

@import url('https://fonts.googleapis.com/css2?family=Archivo+Black&family=IBM+Plex+Sans:wght@400;500;600&display=swap');

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }

/* ---- signature element: hazard rule ---- */
.hazard-rule {
  height: 8px;
  background: repeating-linear-gradient(
    45deg,
    var(--ink),
    var(--ink) 12px,
    var(--hi-vis) 12px,
    var(--hi-vis) 24px
  );
}

/* ---- header ---- */
.site-header {
  padding: 2.5rem 2rem 1.25rem;
  text-align: left;
}
.site-header__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}
.lang-switch {
  border: 1.5px solid var(--ink);
  border-radius: 2px;
  padding: 0.2rem 0.6rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}
.lang-switch:hover {
  background: var(--ink);
  color: var(--hi-vis);
}
.wordmark {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 3rem);
  letter-spacing: -0.02em;
  display: block;
}
.tagline {
  color: var(--steel);
  margin: 0.25rem 0 0;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---- mega nav ---- */
.mega-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding: 0 2rem 1.5rem;
  position: relative;
}
.mega-item {
  position: relative;
}
.mega-item--home {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid var(--ink);
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 2px;
}
.mega-item > summary {
  list-style: none;
  cursor: pointer;
  border: 1.5px solid var(--ink);
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 2px;
  transition: background 0.15s ease, color 0.15s ease;
}
.mega-item > summary::-webkit-details-marker { display: none; }
.mega-item > summary::after { content: " ▾"; font-size: 0.7em; }
.mega-item[open] > summary,
.mega-item--home:hover,
.mega-item > summary:hover {
  background: var(--ink);
  color: var(--hi-vis);
}
.mega-panel {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  z-index: 20;
  background: white;
  border: 1px solid var(--line);
  border-radius: 3px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
  padding: 0.75rem;
  min-width: 220px;
  max-height: 70vh;
  overflow-y: auto;
}
.mega-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mega-list li {
  padding: 0.1rem 0;
}
.mega-list a {
  display: block;
  padding: 0.35rem 0.5rem;
  border-radius: 2px;
  font-size: 0.9rem;
}
.mega-list a:hover {
  background: var(--canvas);
}
.mega-view-all {
  font-weight: 700;
  color: var(--rust);
}
.mega-sub {
  margin-left: 0;
}
.mega-sub > summary {
  list-style: none;
  cursor: pointer;
  padding: 0.35rem 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: 2px;
}
.mega-sub > summary::-webkit-details-marker { display: none; }
.mega-sub > summary::after { content: " ▸"; font-size: 0.7em; color: var(--steel); }
.mega-sub[open] > summary::after { content: " ▾"; }
.mega-sub > summary:hover { background: var(--canvas); }
.mega-sub .mega-list {
  margin-left: 0.75rem;
  border-left: 2px solid var(--line);
  padding-left: 0.5rem;
}

main {
  padding: 2.5rem 2rem 4rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* ---- breadcrumb ---- */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--steel);
  margin-bottom: 1.5rem;
}
.breadcrumb a { color: var(--steel); }
.breadcrumb a:hover { color: var(--rust); }
.breadcrumb-sep { margin: 0 0.4rem; }
.breadcrumb-current { color: var(--ink); font-weight: 600; }

/* ---- homepage tiles ---- */
.tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.5rem;
}
.tile {
  display: block;
  background: white;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}
.tile-thumb {
  aspect-ratio: 4 / 3;
  background: var(--canvas);
  overflow: hidden;
}
.tile-thumb img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.tile-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin: 0;
  padding: 1rem 1rem 0.25rem;
}
.tile-count {
  display: block;
  padding: 0 1rem 1rem;
  color: var(--steel);
  font-size: 0.85rem;
}

/* ---- subcategory cards (within a category hub page) ---- */
.subcat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.subcat-card {
  display: block;
  background: white;
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  text-align: center;
  transition: border-color 0.15s ease;
}
.subcat-card:hover { border-color: var(--rust); }
.subcat-thumb {
  aspect-ratio: 1 / 1;
  background: var(--canvas);
}
.subcat-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.subcat-name {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.6rem 0.5rem 0.1rem;
}
.subcat-count {
  display: block;
  color: var(--steel);
  font-size: 0.75rem;
  padding-bottom: 0.5rem;
}

/* ---- category layout (sidebar filters + main grid) ---- */
.category-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 2rem;
  align-items: start;
}
.filters {
  background: white;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 1rem;
  position: sticky;
  top: 1rem;
}
.filters__head {
  margin-bottom: 0.5rem;
}
.filters__clear {
  background: none;
  border: none;
  color: var(--rust);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}
.filters__clear:hover { text-decoration: underline; }
.filter-group {
  border: none;
  border-top: 1px solid var(--line);
  padding: 0.75rem 0 0;
  margin: 0.75rem 0 0;
}
.filter-group legend {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--steel);
  padding: 0;
}
.filter-option {
  display: block;
  font-size: 0.85rem;
  padding: 0.25rem 0;
  cursor: pointer;
}
.filter-option input { margin-right: 0.4rem; }
.filter-count {
  color: var(--steel);
  font-size: 0.85rem;
  margin: 0 0 1rem;
}
.filter-empty {
  color: var(--steel);
  padding: 2rem 0;
  text-align: center;
}

@media (max-width: 700px) {
  .category-layout {
    grid-template-columns: 1fr;
  }
  .filters {
    position: static;
  }
}

/* ---- price display (product cards + product detail) ---- */
.product-price, .detail-price {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.product-price {
  padding: 0.75rem 1rem 0;
}
.detail-price {
  margin: 1.25rem 0;
  font-size: 1.3rem;
}
.price-now {
  font-weight: 700;
  color: var(--ink);
}
.detail-price .price-now { font-size: 1.6rem; }
.price-old {
  color: var(--steel);
  text-decoration: line-through;
  font-size: 0.9em;
}
.price-badge {
  background: var(--rust);
  color: white;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 0.15rem 0.5rem;
  border-radius: 2px;
}

/* ---- category section ---- */
.category-section {
  margin-bottom: 3.5rem;
}
.category-heading {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.5vw, 1.9rem);
  margin: 0 0 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.eyebrow {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--rust);
}

/* ---- product grid ---- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}
.product-card {
  display: block;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.product-card[hidden] {
  display: none;
}
.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}
.product-thumb {
  aspect-ratio: 1 / 1;
  background: var(--canvas);
  overflow: hidden;
}
.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-thumb--empty {
  background: repeating-linear-gradient(
    45deg, var(--line), var(--line) 6px, transparent 6px, transparent 12px
  );
}
.product-thumb--large {
  aspect-ratio: 4 / 3;
  border-radius: 3px;
}
.product-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
  padding: 0.85rem 1rem 1rem;
}

/* ---- product detail ---- */
.product-detail {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2.5rem;
  align-items: start;
}
.product-gallery {
  display: grid;
  gap: 0.75rem;
}
.product-gallery img {
  width: 100%;
  border-radius: 3px;
  border: 1px solid var(--line);
}
.product-info h1 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  margin: 0.35rem 0 0.5rem;
}
.spec-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.3rem 1rem;
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
}
.spec-list dt {
  color: var(--steel);
  font-weight: 600;
}
.spec-list dd {
  margin: 0;
}
.size-list {
  margin: 0 0 1rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.size-list__label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--steel);
  margin-right: 0.2rem;
}
.size-pill {
  display: inline-block;
  border: 1.5px solid var(--line);
  border-radius: 2px;
  padding: 0.15rem 0.55rem;
  font-size: 0.85rem;
  font-weight: 600;
}
.product-description {
  grid-column: 1 / -1;
  max-width: 65ch;
  font-size: 1rem;
  color: #333;
}
.description-intro {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--rust);
  margin: 0 0 1rem;
}
.description-bullets {
  margin: 0 0 1.5rem;
  padding-left: 1.1rem;
}
.description-bullets li {
  margin-bottom: 0.5rem;
}
.description-bullets li::marker {
  color: var(--rust);
}
.description-more-info {
  border-top: 1px dashed var(--line);
  padding-top: 1rem;
  color: #444;
}
.inquire-btn {
  display: inline-block;
  margin-top: 1.5rem;
  background: var(--ink);
  color: var(--hi-vis);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.85rem;
  padding: 0.85rem 1.5rem;
  border-radius: 2px;
  transition: background 0.15s ease;
}
.inquire-btn:hover {
  background: var(--rust);
  color: #fff;
}

@media (max-width: 700px) {
  .product-detail {
    grid-template-columns: 1fr;
  }
  .site-header, .mega-nav, main {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }
}

/* ---- footer ---- */
.site-footer {
  margin-top: 2rem;
}
.site-footer p {
  text-align: center;
  color: var(--steel);
  font-size: 0.8rem;
  padding: 1.5rem 2rem;
}
