/* =============================================================
   Corps Security — CVA Shop
   Brand tokens + shop page styles
   Navy accent (#18355e) is the default; burgundy & charcoal
   alternates are available below — swap the --cs-accent var.
   ============================================================= */

:root {
  /* ----- Brand core ----- */
  --cs-burgundy:     #841627; /* Pantone 202C — corporate primary */
  --cs-burgundy-dk:  #6a1020;
  --cs-burgundy-tn:  #f5e8ea;

  --cs-grey:         #AAACB0; /* Pantone Cool Grey 5 */
  --cs-grey-dk:      #6b6d71;
  --cs-grey-lt:      #e6e7e9;

  /* ----- CVA shop accent (navy chosen) -----
     Swap to --cs-burgundy for a burgundy-led shop,
     or --cs-ink for a charcoal/neutral scheme.     */
  --cs-accent:       #18355e;
  --cs-accent-dk:    #0f2644;
  --cs-accent-tn:    #e5ebf3;

  /* ----- Neutral system ----- */
  --cs-ink:          #1b1b1e;
  --cs-ink-80:       rgba(27, 27, 30, 0.8);
  --cs-ink-60:       rgba(27, 27, 30, 0.6);
  --cs-paper:        #fbfbfa;
  --cs-paper-tn:     #f4f2ee;
  --cs-line:         #e3e1dd;

  /* ----- Type ----- */
  --cs-sans:  "Gill Sans", "Gill Sans Nova", "Gill Sans MT",
              "Seravek", "Trebuchet MS", "Lato", sans-serif;
  --cs-mono:  "JetBrains Mono", ui-monospace, Menlo, monospace;

  /* ----- Radius / shadow ----- */
  --cs-r:   2px;
  --cs-r-lg: 4px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }
body {
  font-family: var(--cs-sans);
  color: var(--cs-ink);
  background: #fff;
  font-weight: 400;
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  margin-bottom: 0 !important;
}

a { color: inherit; }

/* ============================================================
   CORPS CHROME — utility bar + main header
   Mirrors corpssecurity.co.uk so the shop feels native.
   ============================================================ */

.cs-utility {
  background: #f5f4f0;
  border-bottom: 1px solid var(--cs-line);
  font-size: 12px;
  color: var(--cs-ink-80);
}
.cs-utility__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.cs-utility a { text-decoration: none; }
.cs-utility a:hover { color: var(--cs-burgundy); }
.cs-utility__links { display: flex; gap: 20px; align-items: center; }
.cs-utility__sep { width: 1px; height: 12px; background: var(--cs-grey); opacity: .5; }
.cs-utility__phone { font-weight: 600; letter-spacing: .02em; }

.cs-header {
  background: #fff;
  border-bottom: 1px solid var(--cs-line);
  position: sticky;
  top: 0;
  z-index: 100;
}
.cs-header__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 22px 32px 14px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
}
.cs-logo { height: 52px; display: block; }

.cs-nav { display: flex; align-items: stretch; }
.cs-nav a {
  display: flex;
  align-items: center;
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--cs-ink);
  text-decoration: none;
  border-bottom: 3px solid transparent;
  transition: all .15s ease;
}
.cs-nav a:hover { color: var(--cs-accent); }
.cs-nav a.is-active {
  color: var(--cs-accent);
  border-bottom-color: var(--cs-accent);
}
/* Staff-only sign-in — intentionally invisible to casual visitors */
.cs-nav__signin-subtle {
  color: rgba(27, 27, 30, 0.15) !important;
  font-size: 10px !important;
  padding: 14px 4px !important;
  letter-spacing: 0 !important;
  border-bottom-color: transparent !important;
}
.cs-nav__signin-subtle:hover {
  color: rgba(27, 27, 30, 0.35) !important;
}

.cs-nav__cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  margin-left: 8px;
  background: var(--cs-accent);
  color: #fff;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 700;
}

/* ============================================================
   GENERAL PAGE CONTENT — cart page container
   ============================================================ */

.cart-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 32px 64px;
}

/* Cart action buttons */
.cart-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.cart-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  font-family: var(--cs-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border: none;
  border-radius: var(--cs-r);
  cursor: pointer;
  transition: background .15s, color .15s;
}
.cart-action-btn--primary {
  background: var(--cs-accent);
  color: #fff;
}
.cart-action-btn--primary:hover { background: var(--cs-accent-dk); color: #fff; }

.cart-action-btn--secondary {
  background: var(--cs-ink);
  color: #fff;
}
.cart-action-btn--secondary:hover { background: #000; color: #fff; }

.cart-action-btn--ghost {
  background: transparent;
  color: var(--cs-ink-60);
  border: 1px solid var(--cs-line);
}
.cart-action-btn--ghost:hover { border-color: var(--cs-ink); color: var(--cs-ink); }

.cart-remove-btn {
  background: none;
  border: 1px solid var(--cs-line);
  color: var(--cs-ink-60);
  padding: 4px 12px;
  font-family: var(--cs-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: var(--cs-r);
  transition: all .15s;
}
.cart-remove-btn:hover {
  border-color: var(--cs-burgundy);
  color: var(--cs-burgundy);
}

/* Cart table quantity controls */
.quantity-btn {
  background: var(--cs-accent);
  color: #fff;
  border: none;
  border-radius: var(--cs-r);
  padding: 2px 10px;
  cursor: pointer;
  font-size: 13px;
  font-family: var(--cs-sans);
  transition: background .15s;
}
.quantity-btn:hover { background: var(--cs-accent-dk); }

.quantity-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.quantity-input {
  width: 56px;
  text-align: center;
  padding: 4px 6px;
  border: 1px solid var(--cs-line);
  border-radius: var(--cs-r);
  font-family: var(--cs-sans);
  font-size: 13px;
}

/* ============================================================
   SHOP HEADER — compact page banner (replaces the full hero)
   ============================================================ */

/* CVA banner image: burgundy field with watermark crest (left ~24%)
   and officer photo (right ~22%). Compressed to ~52KB JPEG @2x from
   the 1.4MB source PNG. Text sits in the clear middle band; type is
   vw-scaled so it tracks the aspect-ratio-locked banner height. */
.shop-banner {
  position: relative;
  background: #56101d url("../images/assets/cva-banner.jpg") right center / cover no-repeat;
  color: #fff;
  border-bottom: 4px solid var(--cs-accent);
  aspect-ratio: 1905 / 267;
  display: flex;
  align-items: center;
}
.shop-banner__inner {
  width: 100%;
  /* clear the watermark crest (left) and the officer photo (right) */
  padding: 0 21vw 0 26vw;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}
.shop-banner__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: clamp(9px, 0.65vw, 12px);
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255,255,255,.7);
  margin-bottom: 0.6vw;
}
.shop-banner__eyebrow::before {
  content: "";
  width: 28px; height: 1px;
  background: rgba(255,255,255,.4);
}
.shop-banner__title {
  font-size: clamp(19px, 2.2vw, 44px);
  text-shadow: 0 1px 12px rgba(0,0,0,.25);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.01em;
  margin: 0;
}
.shop-banner__sub {
  font-size: clamp(10px, 0.78vw, 15px);
  color: rgba(255,255,255,.75);
  max-width: 34em;
  margin-top: 0.6vw;
  line-height: 1.5;
}
/* ============================================================
   SHOP BODY
   ============================================================ */

.shop {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px 32px 64px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
}

/* ---- Sidebar ---- */
.shop-sidebar { align-self: start; position: sticky; top: 100px; }
.shop-sidebar__group { margin-bottom: 28px; padding-bottom: 22px; border-bottom: 1px solid var(--cs-line); }
.shop-sidebar__group:last-child { border-bottom: 0; }
.shop-sidebar__title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cs-ink);
  margin: 0 0 12px;
}
.shop-sidebar__list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.shop-sidebar__list a {
  display: flex;
  justify-content: space-between;
  padding: 7px 10px;
  font-size: 13px;
  color: var(--cs-ink-80);
  text-decoration: none;
  border-radius: var(--cs-r);
  transition: all .12s;
}
.shop-sidebar__list a:hover { background: var(--cs-paper-tn); color: var(--cs-ink); }
.shop-sidebar__list a.is-active {
  background: var(--cs-accent-tn);
  color: var(--cs-accent);
  font-weight: 600;
}
.shop-sidebar__list a .cnt { color: var(--cs-ink-60); font-size: 12px; font-weight: 400; }
.shop-sidebar__list a.is-active .cnt { color: var(--cs-accent); }

/* ---- Toolbar ---- */
.shop-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 16px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--cs-line);
  font-size: 13px;
  color: var(--cs-ink-60);
}
.shop-toolbar__count b { color: var(--cs-ink); font-weight: 600; }
.shop-toolbar__right { display: flex; gap: 8px; align-items: center; }
.shop-toolbar select {
  border: 1px solid var(--cs-line);
  padding: 8px 12px;
  font-family: inherit;
  font-size: 13px;
  background: #fff;
  color: var(--cs-ink);
  cursor: pointer;
  border-radius: var(--cs-r);
}
.shop-toolbar__view {
  display: inline-flex;
  border: 1px solid var(--cs-line);
  border-radius: var(--cs-r);
}
.shop-toolbar__view button {
  width: 34px; height: 34px;
  border: 0;
  background: #fff;
  cursor: pointer;
  color: var(--cs-ink-60);
  display: flex; align-items: center; justify-content: center;
}
.shop-toolbar__view button.is-active { background: var(--cs-ink); color: #fff; }
.shop-toolbar__sort-label {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cs-ink-60);
}

/* ---- Product grid ---- */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px 24px;
}
.shop-grid--list {
  grid-template-columns: 1fr;
}

.product {
  display: flex;
  flex-direction: column;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  transition: transform .2s ease;
}
.product:hover { transform: translateY(-2px); }

.product__media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: var(--cs-paper-tn);
  overflow: hidden;
  margin-bottom: 14px;
}
.product__media img {
  width: 100%; height: 100%; object-fit: contain; object-position: center;
  transition: transform .4s ease;
}
.product:hover .product__media img { transform: scale(1.03); }

.product__tag {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--cs-ink);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  padding: 5px 10px;
  text-transform: uppercase;
  z-index: 1;
}
.product__tag--new        { background: var(--cs-accent); }
.product__tag--bestseller { background: #1b5e3f; }
.product__tag--sale       { background: var(--cs-burgundy); }
.product__tag--featured   { background: var(--cs-accent); }

.product__quick {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  background: var(--cs-ink);
  color: #fff;
  padding: 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  transform: translateY(100%);
  transition: transform .22s ease;
}
.product:hover .product__quick { transform: translateY(0); }

.product__cat {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cs-grey-dk);
  margin-bottom: 4px;
}
.product__name {
  font-size: 16px;
  font-weight: 600;
  color: var(--cs-ink);
  margin: 0 0 8px;
  line-height: 1.3;
}
.product__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.product__price {
  font-size: 17px;
  font-weight: 600;
  color: var(--cs-accent);
}
.product__price del { color: var(--cs-ink-60); margin-right: 8px; font-weight: 400; }
.product__colors { display: flex; gap: 5px; }
.product__colors .dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,.15);
}

/* "No image" placeholder */
.product__noimg {
  width: 100%; height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cs-grey-dk);
  font-size: 13px;
  font-style: italic;
  background: var(--cs-grey-lt);
}

/* Variation selects inside product cards */
.product__variations {
  margin: 8px 0 4px;
}
.variation-group { margin-bottom: 6px; }
.variation-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cs-ink-60);
  margin-bottom: 3px;
}
.variation-label::after { content: " *"; color: var(--cs-burgundy); }
.variation-select {
  width: 100%;
  padding: 6px 8px;
  border: 1px solid var(--cs-line);
  border-radius: var(--cs-r);
  font-family: var(--cs-sans);
  font-size: 13px;
  background: #fff;
  color: var(--cs-ink);
  cursor: pointer;
}
.variation-select.error {
  border-color: var(--cs-burgundy);
  box-shadow: 0 0 0 3px rgba(132, 22, 39, 0.1);
}

/* Add to bag button */
.product__add-btn {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  background: var(--cs-accent);
  color: #fff;
  border: none;
  font-family: var(--cs-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: var(--cs-r);
  transition: background .15s;
}
.product__add-btn:hover:not(:disabled) { background: var(--cs-accent-dk); }
.product__add-btn:disabled { background: var(--cs-grey); cursor: not-allowed; }

/* ---- Empty / loading states ---- */
.shop-empty {
  padding: 80px 32px;
  text-align: center;
  color: var(--cs-ink-60);
}
.shop-empty h3 { font-size: 20px; color: var(--cs-ink); margin: 0 0 8px; }

/* Notification (reused from existing) */
.notification {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #1b5e3f;
  color: #fff;
  padding: 15px 20px;
  border-radius: var(--cs-r-lg);
  box-shadow: 0 4px 12px rgba(0,0,0,.15);
  opacity: 0;
  transform: translateY(20px);
  transition: all .3s ease;
  z-index: 2000;
  max-width: 350px;
  font-size: 14px;
}
.notification.show { opacity: 1; transform: translateY(0); }
.notification-warning { background: #ffc107 !important; color: #000 !important; }
.notification-error { background: var(--cs-burgundy) !important; }

/* ---- Pagination ---- */
.shop-pagination {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--cs-line);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
}
.shop-pagination button,
.shop-pagination a {
  min-width: 38px;
  height: 38px;
  border: 1px solid var(--cs-line);
  background: #fff;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--cs-ink-80);
  cursor: pointer;
  border-radius: var(--cs-r);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 0 12px;
}
.shop-pagination button:hover,
.shop-pagination a:hover { border-color: var(--cs-ink); color: var(--cs-ink); }
.shop-pagination .is-active {
  background: var(--cs-ink);
  color: #fff;
  border-color: var(--cs-ink);
}

/* ============================================================
   FOOTER
   ============================================================ */

.cs-footer {
  background: var(--cs-ink);
  color: rgba(255,255,255,.7);
  padding: 48px 0;
}
.cs-footer__inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  justify-content: space-between;
  gap: 32px;
  align-items: center;
  flex-wrap: wrap;
}
.cs-footer img { height: 36px; filter: brightness(0) invert(1); opacity: .95; }
.cs-footer__logos {
  display: flex;
  align-items: center;
  gap: 20px;
}
.cs-footer__logos-sep {
  width: 1px;
  height: 28px;
  background: rgba(255,255,255,.25);
  flex-shrink: 0;
}
.cs-footer__cva-logo { height: 28px; }
.cs-footer__links { display: flex; gap: 24px; }
.cs-footer a { color: rgba(255,255,255,.7); text-decoration: none; font-size: 13px; }
.cs-footer a:hover { color: #fff; }
.cs-footer__legal { font-size: 12px; color: rgba(255,255,255,.5); }

/* ============================================================
   IMAGE LIGHTBOX
   ============================================================ */

.product-main-image { cursor: zoom-in; }

.img-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(0,0,0,.88);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
}
.img-lightbox__stage {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  max-height: calc(100vh - 100px);
  padding: 0 64px;
}
.img-lightbox__img {
  max-width: 100%;
  max-height: calc(100vh - 120px);
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 48px rgba(0,0,0,.6);
  user-select: none;
}
.img-lightbox__close {
  position: absolute;
  top: 16px; right: 20px;
  background: none;
  border: none;
  color: #fff;
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
  opacity: .75;
  transition: opacity .15s;
}
.img-lightbox__close:hover { opacity: 1; }
.img-lightbox__prev,
.img-lightbox__next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,.12);
  border: none;
  color: #fff;
  font-size: 48px;
  line-height: 1;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s;
}
.img-lightbox__prev { left: 16px; }
.img-lightbox__next { right: 16px; }
.img-lightbox__prev:hover,
.img-lightbox__next:hover { background: rgba(255,255,255,.25); }
.img-lightbox__prev[hidden],
.img-lightbox__next[hidden] { display: none; }
.img-lightbox__dots {
  display: flex;
  gap: 8px;
  padding-bottom: 16px;
}
.img-lightbox__dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.35);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background .15s;
}
.img-lightbox__dot.is-active { background: #fff; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
  .shop { grid-template-columns: 1fr; }
  .shop-sidebar { position: static; }
  .shop-grid { grid-template-columns: repeat(2, 1fr); }
  .cs-nav a { padding: 14px 12px; font-size: 13px; }
}
@media (max-width: 768px) {
  /* Keep the nav (incl. the Bag link) on phones — compact instead of hidden */
  .cs-header__inner { align-items: center; padding: 12px 16px; gap: 12px; }
  .cs-logo { height: 40px; }
  .cs-nav { flex-wrap: wrap; justify-content: flex-end; }
  .cs-nav a { padding: 10px 8px; font-size: 13px; }
  .shop-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .shop-grid { grid-template-columns: 1fr; }
  .shop-banner { aspect-ratio: auto; min-height: 150px; background-position: left center; }
  .shop-banner__inner { flex-direction: column; align-items: flex-start; padding: 22px 24px; gap: 14px; }
  .shop-banner__title { font-size: 24px; }
  .shop-banner__sub { font-size: 12px; }
  .cs-utility__links { display: none; }
  .shop { padding: 24px 16px 48px; }
  .cs-utility__inner { padding: 10px 16px; }
}
