:root {
  --navy: #071b34;
  --ink: #142033;
  --muted: #5d6d7e;
  --line: #dfe6ec;
  --paper: #fbfcf8;
  --panel: #ffffff;
  --mist: #edf5f6;
  --teal: #167070;
  --copper: #b55227;
  --gold: #e2b247;
  --shadow: 0 16px 44px rgba(7, 27, 52, 0.09);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.wrap {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
}

.store-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(251, 252, 248, 0.94);
  border-bottom: 1px solid rgba(7, 27, 52, 0.12);
  backdrop-filter: blur(16px);
}

.store-nav {
  width: min(1160px, calc(100% - 40px));
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--navy);
  text-decoration: none;
}

.brand img {
  width: 92px;
  height: 56px;
  object-fit: contain;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 0.98rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.78rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.nav-links a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 13px;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 800;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: rgba(22, 112, 112, 0.1);
  color: var(--teal);
}

.store-hero {
  padding: clamp(58px, 8vw, 96px) 0;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(7, 27, 52, 0.96), rgba(7, 27, 52, 0.78)),
    url("../../images/Northific_blue.png") right center / min(620px, 70vw) auto no-repeat,
    var(--navy);
}

.store-hero h1,
.cart-page h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(2.4rem, 6vw, 5rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.store-hero p:not(.eyebrow) {
  max-width: 650px;
  color: #d8e5ea;
  font-size: 1.12rem;
}

.gateway-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.gateway-section {
  padding: clamp(54px, 8vw, 88px) 0;
}

.gateway-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.gateway-grid article {
  min-height: 100%;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.gateway-grid h2 {
  margin: 16px 0 10px;
  color: var(--navy);
  font-size: clamp(1.45rem, 3vw, 2.2rem);
  line-height: 1.05;
}

.gateway-grid p {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--copper);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.catalog {
  padding: 70px 0 94px;
}

.category-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 64px;
}

.category-card {
  min-height: 100%;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 34px rgba(7, 27, 52, 0.06);
}

.category-card h2 {
  margin: 0 0 10px;
  font-size: 1.22rem;
  line-height: 1.2;
}

.category-card p {
  margin: 0 0 16px;
  color: var(--muted);
}

.store-notice {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  background: rgba(226, 178, 71, 0.16);
}

.store-notice p {
  margin: 0;
  color: var(--navy);
  font-weight: 800;
}

.category-section + .category-section {
  margin-top: 72px;
}

.category-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.category-head h2 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  line-height: 1.05;
}

.category-head p:not(.eyebrow) {
  max-width: 680px;
  margin: 10px 0 0;
  color: var(--muted);
}

.subtle-link {
  color: var(--teal);
  font-weight: 800;
  text-decoration: none;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 18px;
}

.product-card,
.product-detail {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.product-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.product-media,
.detail-media {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 190px;
  background: var(--mist);
  text-decoration: none;
}

.product-media img,
.detail-media img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
}

.media-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(7, 27, 52, 0.16);
  font-size: 3rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.product-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 22px;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.status,
.category-pill {
  width: max-content;
  max-width: 100%;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(181, 82, 39, 0.1);
  color: var(--copper);
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.category-pill {
  background: rgba(22, 112, 112, 0.1);
  color: var(--teal);
}

.status[data-stock="In stock"] {
  background: rgba(22, 112, 112, 0.1);
  color: var(--teal);
}

.status[data-stock="Low stock"],
.status[data-stock="Backorder available"] {
  background: rgba(226, 178, 71, 0.2);
  color: #7d6511;
}

.status[data-stock="Out of stock"],
.status[data-stock="Request quote"] {
  background: rgba(93, 109, 126, 0.12);
  color: var(--muted);
}

.product-card h3 {
  margin: 16px 0 8px;
  color: var(--navy);
  line-height: 1.2;
}

.product-card h3 a {
  text-decoration: none;
}

.product-card p {
  margin: 0;
  color: var(--muted);
}

.product-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 20px;
}

.price,
.detail-price {
  color: var(--navy);
  font-weight: 900;
}

.primary-button,
.secondary-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  padding: 0 16px;
  background: var(--navy);
  color: #fff;
  font: inherit;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

.secondary-button {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
}

.compact-button {
  min-height: 38px;
  padding: 0 13px;
}

.product-page {
  padding: 54px 0 92px;
}

.product-detail {
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(0, 1.18fr);
  gap: clamp(28px, 5vw, 58px);
  margin-top: 24px;
  padding: clamp(22px, 4vw, 44px);
}

.detail-media {
  min-height: 420px;
  border-radius: 8px;
}

.detail-copy h1 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 1;
}

.detail-description,
.detail-commerce-note,
.support-notes {
  color: var(--muted);
}

.detail-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 26px 0;
}

.detail-lists {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.detail-lists-wide {
  margin-top: 18px;
}

.detail-lists h2 {
  margin: 0 0 8px;
  color: var(--navy);
  font-size: 1rem;
}

.detail-lists ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.detail-lists a {
  color: var(--teal);
  font-weight: 800;
}

.store-footer {
  padding: 28px 0;
  border-top: 1px solid var(--line);
  background: #fff;
}

.store-footer .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  color: var(--muted);
}

.store-footer a {
  color: var(--navy);
  font-weight: 900;
  text-decoration: none;
}

@media (max-width: 820px) {
  .store-nav,
  .category-head,
  .product-detail,
  .gateway-grid,
  .category-card-grid {
    grid-template-columns: 1fr;
  }

  .store-nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 0;
  }

  .detail-lists {
    grid-template-columns: 1fr;
  }

}

@media (max-width: 520px) {
  .wrap,
  .store-nav {
    width: min(100% - 28px, 1160px);
  }

  .product-bottom,
  .detail-actions,
  .nav-links {
    align-items: stretch;
    flex-direction: column;
  }

  .primary-button,
  .secondary-button,
  .gateway-actions {
    width: 100%;
  }
}
