/* ==========================================================
   MPS Electronics — warehouse ticket stylesheet
   Paper white, ink black, electric blue, acid sticker, hot red.
   ========================================================== */

:root {
  --paper: #fafaf7;
  --ink: #0c0c12;
  --blue: #1f3bff;
  --blue-deep: #162fcc;
  --acid: #d9ff3b;
  --hot: #ff4b2b;
  --rule: #d9d9d4;
  --muted: #5b5b64;
  --max: 1320px;
  --gutter: clamp(16px, 3vw, 40px);
  --sans: "Saira", system-ui, sans-serif;
  --mono: "Space Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 15.5px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--blue); color: #fff; }
:focus-visible { outline: 3px solid var(--hot); outline-offset: 2px; }
button { font: inherit; color: inherit; }
.wrap { width: min(100% - var(--gutter) * 2, var(--max)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- ticker ---------- */

.ticker { background: var(--blue); color: var(--acid); border-bottom: 2px solid var(--ink); overflow: hidden; }
.ticker-track { display: flex; width: max-content; animation: slide 38s linear infinite; }
.ticker-track span { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; padding: 6px 0; white-space: nowrap; }
.ticker-track span::after { content: "///"; margin: 0 18px; color: #fff; opacity: .7; }
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } }

/* ---------- masthead ---------- */

.masthead { border-bottom: 2px solid var(--ink); background: var(--paper); }
.masthead .wrap { display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center; padding: 16px 0; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-mark { width: 46px; height: 46px; background: var(--ink); color: var(--acid); display: grid; place-items: center; font: 800 20px/1 var(--sans); font-variation-settings: "wdth" 70; letter-spacing: -0.04em; }
.brand-name { font-weight: 800; font-size: clamp(22px, 2.6vw, 30px); line-height: 0.9; letter-spacing: -0.03em; text-transform: uppercase; }
.brand-name small { display: block; font-family: var(--mono); font-size: 9px; font-weight: 400; letter-spacing: 0.2em; color: var(--muted); margin-top: 3px; }
.mastnav { display: flex; gap: clamp(10px, 2vw, 24px); justify-content: center; font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
.mastnav a { text-decoration: none; border-bottom: 2px solid transparent; padding: 4px 0; }
.mastnav a:hover { border-color: var(--hot); }
.tools { display: flex; gap: 10px; align-items: center; }
.searchbox { display: flex; border: 2px solid var(--ink); background: #fff; }
.searchbox input { border: 0; background: transparent; padding: 9px 10px; font: inherit; font-size: 13px; width: 180px; min-width: 0; color: var(--ink); }
.searchbox input:focus { outline: none; }
.searchbox:focus-within { box-shadow: 3px 3px 0 var(--blue); }
.bagbtn { display: inline-flex; align-items: center; gap: 7px; border: 2px solid var(--ink); background: var(--ink); color: #fff; padding: 9px 13px; cursor: pointer; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; }
.bagbtn b { color: var(--acid); font-weight: 400; }
.bagbtn:hover { background: var(--blue); border-color: var(--blue); }

/* ---------- hero ---------- */

.hero { background: var(--blue); color: #fff; border-bottom: 2px solid var(--ink); position: relative; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.25fr 0.75fr; gap: clamp(20px, 4vw, 60px); padding: clamp(30px, 5.5vw, 64px) 0; align-items: center; }
.kicker { display: inline-flex; align-items: center; gap: 8px; background: var(--acid); color: var(--ink); font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 9px; transform: rotate(-1.2deg); }
.hero h1 { font-weight: 800; font-variation-settings: "wdth" 72; text-transform: uppercase; font-size: clamp(44px, 8vw, 104px); line-height: 0.84; letter-spacing: -0.045em; margin: 16px 0 18px; }
.hero h1 .line2 { color: var(--acid); }
.hero-lede { max-width: 48ch; font-size: clamp(15px, 1.6vw, 17px); color: #e4e8ff; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 18px 26px; margin-top: 24px; border-top: 2px solid rgba(255,255,255,.3); padding-top: 16px; }
.hero-facts div b { font-family: var(--mono); font-size: 14px; color: var(--acid); display: block; }
.hero-facts div span { font-size: 12px; color: #d5dbff; }

.stickers { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.sticker { border: 2px solid var(--ink); box-shadow: 5px 5px 0 var(--ink); padding: 12px 15px; width: 150px; color: var(--ink); }
.sticker:nth-child(odd) { background: var(--acid); transform: rotate(-2deg); }
.sticker:nth-child(even) { background: #fff; transform: rotate(1.6deg); }
.sticker b { display: block; font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase; }
.sticker strong { display: block; font-size: 24px; font-weight: 800; font-variation-settings: "wdth" 80; text-transform: uppercase; line-height: 1; margin: 3px 0; }
.sticker span { font-family: var(--mono); font-size: 10px; }

/* ---------- category band ---------- */

.catband { border-bottom: 2px solid var(--ink); background: #fff; position: sticky; top: 0; z-index: 30; }
.catband .wrap { display: flex; align-items: center; gap: 14px; padding: 9px 0; overflow-x: auto; scrollbar-width: none; }
.catband .wrap::-webkit-scrollbar { display: none; }
.catband .label { font-family: var(--mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.chips { display: flex; gap: 6px; }
.chip { white-space: nowrap; border: 1.5px solid var(--ink); background: transparent; padding: 5px 10px; font-family: var(--mono); font-size: 10px; letter-spacing: 0.05em; text-transform: uppercase; cursor: pointer; }
.chip:hover { background: var(--acid); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--acid); }
.catband .sort { margin-left: auto; display: flex; gap: 6px; align-items: center; font-family: var(--mono); font-size: 10px; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.catband select { font: inherit; font-family: var(--mono); font-size: 10px; border: 1.5px solid var(--ink); background: #fff; padding: 4px 5px; color: var(--ink); }

/* ---------- catalogue ---------- */

.catalog-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 20px 0 4px; }
.catalog-head h2 { margin: 0; font-weight: 800; text-transform: uppercase; font-size: 22px; letter-spacing: -0.02em; }
.catalog-head .count { font-family: var(--mono); font-size: 11px; color: var(--muted); }
.catalog-head .count b { color: var(--ink); }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding: 14px 0 40px; }
.card { background: #fff; border: 2px solid var(--ink); box-shadow: 5px 5px 0 var(--ink); display: flex; flex-direction: column; position: relative; }
.card:nth-child(3n+2) { box-shadow: 5px 5px 0 var(--blue); }
.card-body { padding: 14px 14px 10px; flex: 1; }
.card-meta { display: flex; justify-content: space-between; gap: 8px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.card-meta .brand { color: var(--hot); font-family: var(--mono); font-size: 9px; }
.card h3 { font-weight: 700; font-variation-settings: "wdth" 88; text-transform: uppercase; font-size: 19px; line-height: 1.05; letter-spacing: -0.02em; margin: 0 0 7px; }
.card p { font-size: 13px; color: #33333b; margin: 0 0 9px; }
.specs { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; padding: 0; margin: 0; }
.specs li { font-family: var(--mono); font-size: 9px; border: 1px solid var(--rule); padding: 2px 5px; color: var(--muted); text-transform: uppercase; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 2px dashed var(--rule); padding: 10px 14px 13px; }
.price { background: var(--acid); border: 2px solid var(--ink); font-family: var(--mono); font-weight: 700; font-size: 16px; padding: 5px 9px; transform: rotate(-1.5deg); line-height: 1; }
.price small { display: block; font-size: 8px; font-weight: 400; letter-spacing: 0.04em; }
.stock { font-family: var(--mono); font-size: 9px; color: var(--muted); }
.stock.low { color: var(--hot); }
.addbtn { border: 2px solid var(--ink); background: var(--ink); color: #fff; padding: 8px 12px; cursor: pointer; font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; }
.addbtn:hover { background: var(--blue); border-color: var(--blue); }
.addbtn.added { background: var(--blue); border-color: var(--blue); }
.empty { grid-column: 1 / -1; border: 2px dashed var(--rule); padding: 46px 20px; text-align: center; color: var(--muted); font-size: 14px; }
.empty button { border: 2px solid var(--ink); background: var(--acid); padding: 7px 11px; font-family: var(--mono); font-size: 10px; text-transform: uppercase; cursor: pointer; margin-left: 6px; }

/* ---------- why strip ---------- */

.strip { background: var(--acid); border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.strip .wrap { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(20px, 4vw, 60px); padding: 32px 0; align-items: start; }
.strip h2 { margin: 0 0 8px; font-weight: 800; text-transform: uppercase; font-variation-settings: "wdth" 75; font-size: clamp(26px, 4vw, 46px); line-height: 0.92; letter-spacing: -0.03em; }
.strip p { margin: 0; max-width: 44ch; font-size: 14px; }
.strip ul { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.strip li { border-bottom: 2px solid var(--ink); padding: 9px 0; display: grid; grid-template-columns: 26px 1fr; gap: 8px; font-size: 13.5px; }
.strip li b { font-family: var(--mono); font-weight: 400; }

/* ---------- pages ---------- */

.pagehead { background: var(--blue); color: #fff; border-bottom: 2px solid var(--ink); padding: clamp(28px, 5vw, 50px) 0 24px; }
.pagehead .kicker { margin-bottom: 12px; }
.pagehead h1 { font-weight: 800; text-transform: uppercase; font-variation-settings: "wdth" 74; font-size: clamp(32px, 6vw, 66px); line-height: 0.88; letter-spacing: -0.04em; margin: 0 0 8px; }
.pagehead p { color: #dfe3ff; margin: 0; max-width: 60ch; }

.prose { max-width: 76ch; padding: 26px 0 50px; }
.prose h2 { font-weight: 800; text-transform: uppercase; font-size: 20px; letter-spacing: -0.01em; margin: 28px 0 7px; }
.prose p, .prose li { color: #2c2c34; }
.prose li { margin-bottom: 5px; }
.prose a { color: var(--blue); }
.prose table { border-collapse: collapse; width: 100%; margin: 12px 0; font-size: 13.5px; }
.prose th, .prose td { border: 1.5px solid var(--ink); padding: 7px 9px; text-align: left; vertical-align: top; }
.prose th { background: var(--acid); font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; }
.callout { border: 2px solid var(--ink); border-left: 8px solid var(--hot); background: #fff; padding: 11px 13px; margin: 16px 0; font-size: 13.5px; }

/* ---------- contact ---------- */

.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-bottom: 2px solid var(--ink); }
.ccol { padding: 26px 28px 36px 0; border-right: 2px solid var(--ink); }
.ccol + .ccol { padding-left: 28px; padding-right: 0; border-right: 0; }
.ccol h2 { font-size: 14px; text-transform: uppercase; letter-spacing: 0.03em; margin: 0 0 9px; }
.ccol p { font-size: 13.5px; }
.ccol a { color: var(--blue); }
.hours { list-style: none; padding: 0; margin: 10px 0; font-family: var(--mono); font-size: 12px; }
.hours li { display: flex; justify-content: space-between; border-bottom: 1px dotted var(--rule); padding: 5px 0; }
.form { display: grid; gap: 9px; margin-top: 12px; }
.form label { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.form input, .form select, .form textarea { width: 100%; border: 1.5px solid var(--ink); background: #fff; padding: 8px; font: inherit; font-size: 13.5px; }
.form button { border: 2px solid var(--ink); background: var(--ink); color: var(--acid); padding: 11px; cursor: pointer; font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; }
.form button:hover { background: var(--blue); border-color: var(--blue); color: #fff; }

/* ---------- bag ---------- */

.bagwrap { position: fixed; inset: 0; z-index: 90; display: none; }
.bagwrap[data-open] { display: block; }
.bagscrim { position: absolute; inset: 0; background: rgba(12, 12, 18, .5); }
.bag { position: absolute; top: 0; right: 0; bottom: 0; width: min(420px, 100%); background: var(--paper); border-left: 2px solid var(--ink); display: flex; flex-direction: column; }
.bag-head { display: flex; justify-content: space-between; align-items: center; background: var(--blue); color: #fff; border-bottom: 2px solid var(--ink); padding: 14px 16px; }
.bag-head h2 { margin: 0; font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; }
.bag-close { border: 2px solid #fff; background: transparent; color: #fff; width: 30px; height: 30px; cursor: pointer; font-size: 16px; line-height: 1; }
.bag-body { overflow: auto; flex: 1; padding: 6px 16px; }
.bag-line { display: grid; grid-template-columns: 1fr auto; gap: 8px; border-bottom: 1px dotted var(--rule); padding: 10px 0; font-size: 13px; }
.bag-line .n { font-weight: 700; text-transform: uppercase; font-size: 12.5px; }
.bag-line .s { font-family: var(--mono); font-size: 10px; color: var(--muted); margin-top: 2px; }
.qty { display: flex; align-items: center; gap: 6px; margin-top: 5px; }
.qty button { width: 22px; height: 22px; border: 1.5px solid var(--ink); background: #fff; cursor: pointer; line-height: 1; }
.qty button.rm { width: auto; padding: 0 6px; font-family: var(--mono); font-size: 9px; text-transform: uppercase; }
.bag-empty { color: var(--muted); font-size: 13px; padding: 26px 0; }
.bag-foot { border-top: 2px solid var(--ink); padding: 13px 16px; background: #fff; }
.bag-total { display: flex; justify-content: space-between; font-weight: 700; margin-bottom: 3px; }
.bag-total .v { font-family: var(--mono); }
.bag-small { font-size: 11px; color: var(--muted); margin: 0 0 10px; }
.checkout { display: block; text-align: center; background: var(--blue); color: #fff; border: 2px solid var(--blue); text-decoration: none; font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; padding: 11px; }
.checkout:hover { background: var(--blue-deep); }
.payrow { display: flex; gap: 6px; align-items: center; margin-top: 10px; }
.payrow svg { height: 24px; background: #fff; border: 1px solid var(--rule); }
.pci { font-size: 10.5px; color: var(--muted); margin: 7px 0 0; }

/* ---------- footer ---------- */

footer { border-top: 2px solid var(--ink); background: var(--ink); color: var(--paper); }
.footgrid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 26px; padding: 28px 0 18px; }
footer h3 { font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.14em; text-transform: uppercase; color: #8f9098; margin: 0 0 8px; font-weight: 400; }
footer ul { list-style: none; margin: 0; padding: 0; font-size: 12.5px; }
footer li { padding: 3px 0; }
footer a { text-decoration: none; }
footer a:hover { color: var(--acid); }
.footabout { font-size: 12.5px; color: #c9c9cf; max-width: 44ch; }
.footabout strong { display: block; font-size: 16px; text-transform: uppercase; letter-spacing: -0.01em; margin-bottom: 5px; color: #fff; }
.footbase { border-top: 1px solid #2c2c36; padding: 12px 0 20px; display: flex; justify-content: space-between; gap: 16px; font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.04em; color: #8f9098; }

/* ---------- responsive ---------- */

@media (max-width: 1040px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .stickers { justify-content: flex-start; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .card:nth-child(3n+2) { box-shadow: 5px 5px 0 var(--ink); }
  .card:nth-child(2n) { box-shadow: 5px 5px 0 var(--blue); }
  .strip .wrap, .contact-grid, .footgrid { grid-template-columns: 1fr; }
  .ccol, .ccol + .ccol { padding: 22px 0; border-right: 0; border-bottom: 2px solid var(--ink); }
}
@media (max-width: 700px) {
  .masthead .wrap { grid-template-columns: 1fr auto; }
  .mastnav { display: none; }
  .searchbox input { width: 108px; }
  .grid { grid-template-columns: 1fr; gap: 14px; }
  .catband .sort { order: -1; margin-left: 0; }
  .footbase { flex-direction: column; gap: 3px; }
}
