/* WebShop styles. Portal palette with an industrial skin (playbook section 8).
   Does not load the static site's css/style.css: that sets min-width 960px, which breaks phones.
   The header reuses its background image, logo and nav colors instead. */
:root {
  --slate: #1c2333;
  --slate-2: #2a3347;
  --accent: #addcfe;
  --accent-dark: #484b4b;
  --bg: #f4f3f0;
  --card: #ffffff;
  --line: #d9d6cf;
  --text: #1c2333;
  --muted: #6b7180;
  --warn: #a4471f;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 "DM Sans", Arial, Helvetica, sans-serif;
}
img { max-width: 100%; border: 0; }
a { color: var(--slate); }
a:hover { color: var(--accent-dark); }
[hidden] { display: none !important; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.mono { font-family: var(--mono); font-weight: 500; }
.muted { color: var(--muted); font-size: 14px; }

/* Hazard stripe accent */
.hazard {
  height: 6px;
  background: repeating-linear-gradient(-45deg, var(--accent) 0 10px, var(--slate) 10px 20px);
}

/* ── Site header (matches the static site) ─────────────── */
.site-header {
  background: #0b1a26 url(/images/bg-header.png) repeat-x center top;
  min-height: 66px;
}
.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding-top: 16px;
  padding-bottom: 12px;
}
.site-logo img { display: block; width: 306px; height: auto; max-width: 70vw; }
.site-nav { display: flex; flex-wrap: wrap; gap: 4px 28px; font-family: Arial, Helvetica, sans-serif; }
.site-nav a { color: #efefef; text-decoration: none; line-height: 30px; }
.site-nav a:hover, .site-nav a.selected { color: #44b2f1; }

/* ── Steel band with title + search ────────────────────── */
.band {
  color: #fff;
  /* Same tiled texture as the front page body */
  background: #0c3e5a url(/images/bg-body.jpg) repeat left top;
}
.band .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 32px;
  padding-top: 22px;
  padding-bottom: 22px;
}
.band-name {
  display: block;
  color: var(--accent);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
}
.band-name:hover { var(--accent-dark); }
.band-sub { color: #b9bfcc; font-size: 14px; }
.band-tools { display: flex; flex-direction: column; gap: 8px; flex: 1 1 340px; max-width: 520px; }
.tools-row { display: flex; gap: 8px; }
.search { display: flex; flex: 1; min-width: 0; }
.cart-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid var(--accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.cart-link:hover { background: var(--accent); color: var(--slate); }
.cart-count {
  min-width: 22px;
  padding: 1px 6px;
  background: var(--accent);
  color: var(--slate);
  text-align: center;
  font-size: 13px;
}
.cart-link:hover .cart-count { background: var(--slate); color: var(--accent); }
.search input {
  flex: 1;
  min-width: 0;
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--accent);
  border-right: 0;
  border-radius: 0;
  background: #fff;
  color: var(--text);
}
.search input:focus { outline: 2px solid var(--accent); outline-offset: -2px; }
.search button {
  font: inherit;
  font-weight: 700;
  padding: 10px 18px;
  border: 1px solid var(--accent);
  border-radius: 0;
  background: var(--accent);
  color: var(--slate);
  cursor: pointer;
}
.search button:hover { background: #d8bb83; }
/* Category pulldown needs JS to jump, so it only shows with JS. */
.cat-jump {
  display: none;
  font: inherit;
  padding: 9px 10px;
  border: 1px solid var(--accent);
  border-radius: 0;
  background: #fff;
  color: var(--text);
  cursor: pointer;
}
.js .cat-jump { display: block; }
.carousel { scroll-margin-top: 12px; }
/* With JS the search filters as you type, so the button is only a fallback. */
.js .search button { display: none; }
.js .search input { border-right: 1px solid var(--accent); }

/* ── Catalog ───────────────────────────────────────────── */
.catalog { padding-top: 24px; padding-bottom: 40px; }
.carousel { margin-bottom: 30px; }
.carousel-head, .results-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 2px solid var(--slate);
  margin-bottom: 12px;
  padding-bottom: 6px;
}
.carousel h2, .results h2 { margin: 0; font-size: 20px; }
.count { color: var(--muted); font-size: 13px; margin-left: 6px; }
.arrows { display: none; gap: 6px; }
.js .arrows { display: flex; }
.arrow {
  width: 34px;
  height: 30px;
  font-size: 22px;
  line-height: 1;
  border: 1px solid var(--slate);
  border-radius: 0;
  background: var(--card);
  color: var(--slate);
  cursor: pointer;
}
.arrow:hover:not(:disabled) { background: var(--slate); color: #fff; }
.arrow:disabled { opacity: .3; cursor: default; }
.track {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding-bottom: 10px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.track > .card { flex: 0 0 210px; scroll-snap-align: start; }
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 14px;
}
.empty { color: var(--muted); padding: 24px 0; }
.link-btn { font-size: 14px; font-weight: 700; }

/* Item card */
.card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  transition: border-color .15s, box-shadow .15s;
}
.card:hover { color: var(--text); border-color: var(--accent); box-shadow: 0 2px 0 var(--accent); }
.card-photo {
  display: block;
  aspect-ratio: 4 / 3;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.card-photo img { width: 100%; height: 100%; object-fit: contain; display: block; }
.card-body { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px 12px; flex: 1; }
.card-name {
  font-weight: 700;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-sub { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: auto; padding-top: 6px; }
.price { font-size: 17px; }
.tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 2px 6px;
  border: 1px solid var(--slate);
  white-space: nowrap;
}
.tag-warn { border-color: var(--warn); color: var(--warn); }

/* ── Item page ─────────────────────────────────────────── */
.crumbs { font-size: 14px; color: var(--muted); margin: 18px 0; }
.crumbs a { text-decoration: none; font-weight: 700; }
.item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px;
  padding-bottom: 48px;
}
.item-photo {
  background: #fff;
  border: 1px solid var(--line);
  align-self: start;
  padding: 12px;
}
.item-photo img { display: block; width: 100%; max-height: 560px; object-fit: contain; }
/* Photo gallery (items with more than one photo) */
.gallery { align-self: start; min-width: 0; }
.gallery-main { position: relative; background: #fff; border: 1px solid var(--line); }
.gallery-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  aspect-ratio: 1 / 1;
  max-height: 560px;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-slide img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.gallery-arrow {
  display: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 52px;
  font-size: 30px;
  line-height: 1;
  border: 1px solid var(--slate);
  border-radius: 0;
  background: rgba(255,255,255,.9);
  color: var(--slate);
  cursor: pointer;
}
.js .gallery-arrow { display: block; }
.gallery-arrow:hover { background: var(--slate); color: #fff; }
.gallery-arrow.prev { left: 8px; }
.gallery-arrow.next { right: 8px; }
.gallery-count {
  position: absolute;
  bottom: 8px;
  right: 8px;
  padding: 2px 8px;
  font-size: 12px;
  background: var(--slate);
  color: #fff;
}
.gallery-thumbs { display: flex; gap: 8px; margin-top: 8px; overflow-x: auto; padding-bottom: 4px; }
.gallery-thumb {
  flex: 0 0 64px;
  height: 64px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 3px;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gallery-thumb.active { border: 2px solid var(--accent); padding: 2px; }

.item h1 { margin: 0 0 4px; font-size: 28px; line-height: 1.2; }
.item-sub { color: var(--muted); margin: 0 0 12px; }
.item-price { font-size: 30px; margin: 0 0 10px; }
.item-price span { font-family: "DM Sans", Arial, sans-serif; font-size: 14px; color: var(--muted); }
.item-desc { margin: 16px 0 20px; }
.notice {
  border-left: 4px solid var(--warn);
  background: #fbf1ec;
  padding: 8px 12px;
  margin: 10px 0;
  font-size: 15px;
}
.pickup-note { border-left-color: var(--accent); background: #faf5ea; }
.js .pickup-note { display: none; }
.js .pickup-note.visible { display: block; }

.buy {
  background: var(--card);
  border: 1px solid var(--line);
  border-top: 4px solid var(--slate);
  padding: 16px 18px;
  margin-bottom: 16px;
}
.buy-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.buy-row label, .fulfill legend { font-weight: 700; }
.buy-row input[type=number] {
  width: 80px;
  font: inherit;
  padding: 6px 8px;
  border: 1px solid var(--slate);
  border-radius: 0;
}
.fulfill { border: 0; margin: 0 0 8px; padding: 0; }
.fulfill legend { padding: 0; margin-bottom: 4px; }
.fulfill label { display: block; padding: 3px 0; cursor: pointer; }
.totals {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  margin: 14px 0;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}
.totals dt { font-weight: 700; }
.totals dd { margin: 0; text-align: right; }
.buy-btn {
  width: 100%;
  font: inherit;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 12px;
  border: 0;
  border-radius: 0;
  background: var(--accent);
  color: var(--slate);
  cursor: pointer;
}
.buy-btn:disabled { background: #d7d3ca; color: #7d7a72; cursor: not-allowed; }
.call { margin: 10px 0 0; font-size: 15px; text-align: center; }

.more { border: 1px solid var(--line); background: var(--card); padding: 0 16px; }
.more summary { cursor: pointer; font-weight: 700; padding: 12px 0; }
.more dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; margin: 0 0 12px; }
.more dt { color: var(--muted); }
.more dd { margin: 0; }

.more + .more { margin-top: 16px; }
.quote-form { display: grid; gap: 4px; padding-bottom: 16px; }
.quote-form p { margin: 0 0 6px; }
.quote-form label { font-weight: 700; margin-top: 8px; }
.quote-form input, .quote-form textarea {
  font: inherit;
  padding: 6px 8px;
  border: 1px solid var(--slate);
  border-radius: 0;
  width: 100%;
  box-sizing: border-box;
}
.quote-form input[readonly] { background: #f1efea; border-color: var(--line); color: var(--muted); }
.quote-form .buy-btn { margin-top: 14px; }
.req { color: var(--warn); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ── Flash banners ─────────────────────────────────────── */
.flashes { padding-top: 14px; }
.flash {
  margin: 0 0 8px;
  padding: 10px 14px;
  border-left: 4px solid #3f7d4e;
  background: #ecf4ee;
  font-weight: 500;
}
.flash-warn { border-left-color: var(--warn); background: #fbf1ec; }
.flash a { font-weight: 700; margin-left: 12px; }

/* ── Cart ──────────────────────────────────────────────── */
.cart { padding-bottom: 48px; }
.cart h1 { font-size: 28px; margin: 0 0 14px; }
.cart-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--line);
  border-top: 4px solid var(--slate);
}
.cart-table th {
  text-align: left;
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}
.cart-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.cart-table .num { text-align: right; white-space: nowrap; }
.cart-item { display: flex; gap: 12px; align-items: center; }
.cart-item > span { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cart-thumb {
  flex: 0 0 72px;
  height: 56px;
  background: #fff;
  border: 1px solid var(--line);
}
.cart-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.cart-name { font-weight: 700; text-decoration: none; }
.cart-item .tag { align-self: flex-start; }
.cart-qty {
  width: 70px;
  font: inherit;
  padding: 6px 8px;
  border: 1px solid var(--slate);
  border-radius: 0;
  text-align: right;
}
.cart-avail { display: block; font-size: 12px; }
.remove-btn { background: none; border: 0; padding: 0; color: var(--warn); cursor: pointer; text-decoration: underline; }
.cart-update { text-align: right; margin: 10px 0 18px; }
.btn-outline {
  font: inherit;
  font-weight: 700;
  padding: 8px 16px;
  border: 1px solid var(--slate);
  border-radius: 0;
  background: var(--card);
  color: var(--slate);
  cursor: pointer;
}
.btn-outline:hover { background: var(--slate); color: #fff; }
.cart-summary { max-width: 420px; margin-left: auto; }
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0; padding: 0; margin: -1px;
}

/* ── Policies / messages ───────────────────────────────── */
.prose, .message { max-width: 760px; padding-bottom: 48px; }
.prose h1, .message h1 { font-size: 28px; margin: 0 0 12px; }
.message h1 { margin-top: 32px; }
.prose h2 { font-size: 18px; margin: 26px 0 6px; padding-bottom: 4px; border-bottom: 1px solid var(--line); }
.prose p { margin: 0 0 10px; }

/* ── Footer ────────────────────────────────────────────── */
.site-footer { background: #072438; color: #7890a1; font-size: 14px; }
.footer-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  padding-top: 28px;
  padding-bottom: 12px;
}
.site-footer h4 { color: #fff; font-weight: 700; margin: 0 0 6px; }
.site-footer p { margin: 0; }
.site-footer a { color: #b6c7d4; }
.site-footer a:hover { color: #fff; }
.site-footer .footnote { font-size: 12px; padding-top: 12px; padding-bottom: 24px; color: #5d7486; }

/* ── Phones ────────────────────────────────────────────── */
@media (max-width: 760px) {
  .site-nav { gap: 0 18px; font-size: 15px; }
  .band-name { font-size: 22px; }
  .band .wrap { padding-top: 16px; padding-bottom: 16px; }
  .band-tools { flex-basis: 100%; max-width: none; }
  .track > .card { flex-basis: 160px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
  .item { grid-template-columns: 1fr; gap: 18px; }
  .item h1 { font-size: 23px; }
  .cart-link { padding: 0 10px; }
  /* Cart: each line becomes a stacked block */
  .cart-table thead { display: none; }
  .cart-table, .cart-table tbody, .cart-table tr, .cart-table td { display: block; width: 100%; }
  .cart-table tr { border-bottom: 1px solid var(--line); padding: 10px 0; }
  .cart-table td { border: 0; padding: 4px 12px; }
  .cart-table td.num { display: flex; justify-content: space-between; align-items: center; text-align: right; }
  .cart-table td.num:not([data-label]) { justify-content: flex-end; }
  .cart-table td.num[data-label]::before { content: attr(data-label); color: var(--muted); font-size: 14px; }
  .cart-avail { display: inline; margin-left: 6px; }
  .cart-summary { max-width: none; }
  .item-price { font-size: 26px; }
}
