/* =========================================================
   ArmourTop - Global styles & design tokens
   Design language: warm industrial B2B factory-direct style
   (inspired by cleaningsteamer.com source)
   Beige paper + deep ink blue + brick red accents
   ========================================================= */

:root {
  /* Brand palette (from cleaningsteamer.com source) */
  --ink: #11212d;
  --ink-2: #16303f;
  --paper: #fdf9f3;
  --paper-2: #f6efe4;
  --accent: #c84b31;
  --accent-dark: #a93c25;
  --accent-soft: #f7e7e2;
  --secondary: #f08c2e;
  --secondary-dark: #d9772a;

  --bg: var(--paper);
  --bg-soft: var(--paper-2);
  --bg-dark: var(--ink);
  --bg-card: #fffdf9;
  --text: #2b2b2b;
  --text-muted: #6b6b6b;
  --border: #e7ddcd;
  --white: #ffffff;

  --font-sans: "Segoe UI", "Helvetica Neue", Helvetica, Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  --container: 1200px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 8px 24px rgba(17, 33, 45, 0.08);
  --shadow-lg: 0 18px 44px rgba(17, 33, 45, 0.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, h5 { margin: 0 0 .5em; line-height: 1.2; color: var(--ink); font-weight: 700; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 1.2rem; }
.eyebrow { color: var(--accent); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; font-size: 13px; margin: 0 0 .4rem; }

/* Buttons */
.btn { display: inline-flex; justify-content: center; align-items: center; border-radius: 999px; padding: 0.7rem 1.2rem; font-size: 0.92rem; font-weight: 700; cursor: pointer; transition: background .2s, color .2s, transform .2s; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); }
.btn-secondary { border: 1px solid rgba(61,42,16,.18); color: var(--ink); }
.btn-secondary:hover { background: var(--accent-soft); }
.btn-light { background: var(--white); color: var(--accent); }
.btn-light:hover { background: var(--accent); color: #fff; }

/* Section helpers */
.section { padding: 3.2rem 0; }
.section--alt { background: linear-gradient(180deg, #f0e5d6 0%, #f8f4eb 80%); }
.section-title { font-size: clamp(1.5rem, 3vw, 2.2rem); margin: 0 0 1rem; }
.split-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1rem; flex-wrap: wrap; }
.text-link { color: var(--accent); text-decoration: underline; font-size: 0.92rem; }

/* Placeholder image block */
.ph {
  background: linear-gradient(150deg, #f3ece2 0%, #faf4ec 100%);
  color: #b8a98f; display: flex; align-items: center; justify-content: center;
  font-size: 12px; letter-spacing: .04em; text-align: center; padding: 8px;
}
.ph--hero { min-height: 460px; }
.ph--img { aspect-ratio: 4 / 3; }
.ph--banner { min-height: 300px; }

/* Product main-image container: consistent ratio for placeholder & real photos */
.model-card__img, .product-card__img, .product__media, .sub-card__img {
  aspect-ratio: 1 / 1; overflow: hidden; background: #eef1f5;
  display: flex; align-items: center; justify-content: center;
}
.model-card__img img, .product-card__img img, .product__media img, .sub-card__img img {
  width: 100%; height: 100%; object-fit: cover;
}

/* Grids */
.category-grid { margin-top: 1.1rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }

/* Category card */
.category-card { border: 1px solid var(--border); border-radius: 14px; background: var(--bg-card); padding: 1rem; transition: box-shadow .2s, transform .2s, border-color .2s; }
.category-card:hover { box-shadow: var(--shadow); border-color: #ccb89f; transform: translateY(-2px); }
.category-card__img { width: 100%; aspect-ratio: 1/1; border-radius: 9px; overflow: hidden; margin-bottom: .75rem; background: #f0e8da; display: flex; align-items: center; justify-content: center; }
.category-card__img img { width: 100%; height: 100%; object-fit: cover; }
.category-card h3 { margin: 0; font-size: 1.1rem; }
.category-card p { margin: .55rem 0; color: var(--text-muted); font-size: .9rem; line-height: 1.6; }
.category-card span { color: var(--accent-dark); font-size: .82rem; font-weight: 700; }

/* Product card */
.product-card { border: 1px solid var(--border); border-radius: 14px; overflow: hidden; background: var(--bg-card); transition: box-shadow .2s, transform .2s, border-color .2s; display: flex; flex-direction: column; }
.product-card:hover { box-shadow: var(--shadow); border-color: #ccb89f; transform: translateY(-2px); }
.product-card__body { padding: .9rem 1rem 1rem; flex: 1; display: flex; flex-direction: column; }
.product-card__cat { margin: 0 0 .25rem; font-size: .75rem; color: #7f7567; text-transform: uppercase; letter-spacing: .05em; }
.product-card__title { margin: 0 0 .75rem; font-size: .95rem; font-weight: 600; line-height: 1.4; color: var(--ink); }
.product-card__btn { margin-top: auto; align-self: flex-start; }

/* Model card (sub-collection) */
.model-card { border: 1px solid var(--border); border-radius: 14px; overflow: hidden; background: var(--bg-card); transition: box-shadow .2s, transform .2s, border-color .2s; }
.model-card:hover { box-shadow: var(--shadow); border-color: #ccb89f; transform: translateY(-2px); }
.model-card__body { padding: .9rem 1rem 1rem; }
.model-card__sku { color: var(--accent-dark); font-weight: 700; font-size: .85rem; }
.model-card__body h3 { margin: .3rem 0 .8rem; font-size: 1rem; }
.model-card__btn { display: inline-block; }

/* Tags */
.mini-tag { display: inline-block; background: var(--accent-soft); color: var(--accent-dark); font-size: .72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px; margin: 2px 4px 2px 0; }
.tag-filter { border: 1px solid transparent; cursor: pointer; transition: background .2s, border-color .2s, transform .15s; }
.tag-filter:hover { border-color: var(--accent); }
.tag-filter.is-active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Trust / snapshot grids */
.trust-grid { margin-top: 1rem; display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; }
.trust-grid article, .snapshot-grid article { background: var(--white); border: 1px solid var(--border); border-radius: 12px; padding: 1.1rem 1.2rem; }
.trust-grid h3, .snapshot-grid h3 { margin: 0 0 .55rem; font-size: 1.05rem; }
.trust-grid p, .snapshot-grid p { margin: 0; color: var(--text-muted); line-height: 1.65; font-size: .9rem; }
.snapshot-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.snapshot-grid article:last-child { grid-column: span 3; }

/* Support strip */
.support-inner { border: 1px solid #dccab2; border-radius: 14px; background: var(--white); padding: 1.2rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.support-inner h2 { margin: .45rem 0 0; font-size: clamp(1.2rem, 2.6vw, 1.7rem); max-width: 52ch; }

/* Breadcrumb */
.breadcrumb { font-size: 13px; color: var(--text-muted); padding: 1rem 0; }
.breadcrumb a:hover { color: var(--accent); }

/* Product detail */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; padding: 1rem 0 3rem; align-items: start; }
.product__gallery { display: grid; grid-template-columns: 1fr; gap: .6rem; }
.product__media-wrap { position: relative; }
.product__thumb-row { display: grid; grid-template-columns: repeat(5, 1fr); gap: .5rem; max-width: 460px; }
.gal-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255,255,255,.92); color: var(--ink); font-size: 24px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 10px rgba(0,0,0,.18); transition: background .2s, transform .2s;
}
.gal-arrow:hover { background: #fff; transform: translateY(-50%) scale(1.06); }
.gal-prev { left: 10px; }
.gal-next { right: 10px; }
.gal-count {
  position: absolute; right: 10px; bottom: 10px; z-index: 2;
  background: rgba(17,33,45,.68); color: #fff; font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 999px; letter-spacing: .03em;
}
.gal-thumb {
  border: 2px solid transparent; border-radius: 8px; padding: 0; overflow: hidden;
  cursor: pointer; background: #eef1f5; transition: border-color .2s;
}
.gal-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; aspect-ratio: 1 / 1; }
.gal-thumb:hover { border-color: #c9d2dd; }
.gal-thumb.is-active { border-color: var(--accent); }
.product__info h1 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
.product__tags { display: flex; flex-wrap: wrap; gap: .4rem; margin: .8rem 0 1.2rem; }
.product__meta { list-style: none; padding: 0; margin: 1rem 0; }
.product__meta li { padding: .5rem 0; border-bottom: 1px solid var(--border); font-size: .92rem; }
.product__meta strong { color: var(--ink); }

/* Full-width overview banner photos (above Product Overview) */
.product-overview-images { display: flex; flex-direction: column; gap: 1.5rem; margin-top: 2.5rem; }
.product-overview-images img { width: 100%; height: auto; display: block; border-radius: var(--radius-lg); }

/* Specification / size tables (100% width, below Service) */
.po-spec-full { grid-column: 1 / -1; }
.po-spec-full dd { width: 100%; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.spec-table, .size-table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.spec-table th, .spec-table td, .size-table th, .size-table td { border: 1px solid var(--border, #dde3ea); padding: .55rem .7rem; text-align: left; vertical-align: middle; }
.spec-table th, .size-table th { background: var(--bg-card, #f2f5f8); font-weight: 600; white-space: nowrap; }
.spec-table th { width: 32%; }
.size-table th, .size-table td { text-align: center; white-space: nowrap; }
.size-table td { color: var(--text, #333); }
@media (max-width: 640px) {
  .spec-table th { width: 42%; }
  .spec-table, .size-table { font-size: .82rem; }
  .spec-table th, .spec-table td, .size-table th, .size-table td { padding: .42rem .45rem; }
  /* Let long cells wrap on phones so the table fits the viewport width */
  .spec-table th, .spec-table td { white-space: normal; }
  .size-table th, .size-table td { white-space: normal; word-break: break-word; }
}

/* Product Overview (SEO/GEO block, patterned after karlead.com) */
.product-overview { margin-top: 2.5rem; padding: 1.8rem 2rem; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.po-title { font-size: 1.5rem; letter-spacing: .01em; margin: 0 0 1rem; color: var(--ink); position: relative; padding-bottom: .6rem; }
.po-title::after { content: ""; position: absolute; left: 0; bottom: 0; width: 54px; height: 3px; border-radius: 3px; background: var(--accent); }
.po-text { margin: 0; color: var(--text); font-size: 1rem; line-height: 1.8; }
.po-specs { display: grid; grid-template-columns: repeat(2, 1fr); gap: .8rem 2rem; margin: 1.5rem 0 0; padding-top: 1.3rem; border-top: 1px dashed var(--border); }
.po-spec { display: flex; flex-direction: column; gap: .15rem; }
.po-spec dt { font-size: .74rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); font-weight: 700; }
.po-spec dd { margin: 0; font-size: .95rem; color: var(--ink); font-weight: 600; }
@media (max-width: 620px) {
  .po-specs { grid-template-columns: 1fr; }
  .product-overview { padding: 1.4rem 1.2rem; }
}

/* Related products (same-category thumbnails under Product Overview) */
.related-products { margin-top: 2.5rem; }
.related-products .section-title { font-size: 1.4rem; margin: 0 0 .3rem; }

@media (max-width: 980px) {
  .category-grid, .product-grid, .trust-grid { grid-template-columns: 1fr 1fr; }
  .snapshot-grid { grid-template-columns: 1fr 1fr; }
  .snapshot-grid article:last-child { grid-column: span 2; }
  .product-detail { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .category-grid, .product-grid, .trust-grid, .snapshot-grid { grid-template-columns: 1fr; }
  .snapshot-grid article:last-child { grid-column: span 1; }
  .support-inner { flex-direction: column; align-items: flex-start; }
  .product-detail { gap: 1.2rem; }
  .product__thumb-row { grid-template-columns: repeat(4, 1fr); gap: .4rem; max-width: none; }
  .product-overview-images { gap: 1rem; }
}

/* ===== Mobile robustness: prevent horizontal overflow ===== */
html, body { overflow-x: hidden; }
p, li, a, h1, h2, h3, h4, h5, h6, span, dd, dt, td, th, button, label, input {
  overflow-wrap: break-word;
  word-break: break-word;
}
