:root {
  color-scheme: light;
  --ink: #17211f;
  --muted: #64716e;
  --line: #d8dfdc;
  --panel: #ffffff;
  --soft: #f4f7f2;
  --brand: #1d6f5f;
  --brand-dark: #10483f;
  --accent: #c84f38;
  --gold: #b07822;
  --shadow: 0 16px 44px rgb(23 33 31 / 12%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--soft);
  color: var(--ink);
}

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

button,
input,
select,
textarea {
  font: inherit;
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgb(255 255 255 / 94%);
  backdrop-filter: blur(12px);
}

.nav,
main,
.footer {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 74px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: var(--brand-dark);
  color: white;
  font-weight: 800;
}

.brand small,
.eyebrow,
.category,
.product-body p,
.footer,
.profile-list dt {
  color: var(--muted);
}

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

.nav-links {
  display: flex;
  gap: 18px;
  margin-left: auto;
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 650;
}

.nav-links a[aria-current="page"] {
  color: var(--brand-dark);
}

.nav-links strong {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  margin-left: 4px;
  border-radius: 99px;
  background: var(--accent);
  color: white;
  font-size: 12px;
}

.cart-button,
.button,
.cart-header button,
.quantity button {
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 750;
}

.cart-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--ink);
  color: white;
}

.cart-button strong {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  border-radius: 99px;
  background: var(--accent);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
  gap: 48px;
  align-items: center;
  min-height: calc(100vh - 74px);
  padding: 54px 0 44px;
}

.hero h1,
.section h2 {
  margin: 0;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 850px;
  font-size: clamp(42px, 7vw, 86px);
  line-height: 0.94;
}

.hero p {
  max-width: 680px;
  font-size: 18px;
  line-height: 1.65;
}

.eyebrow {
  margin: 0 0 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 12px;
  font-weight: 800;
}

.hero-actions,
.catalog-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  text-decoration: none;
}

.button.primary {
  background: var(--brand);
  color: white;
}

.button.secondary {
  background: white;
  border: 1px solid var(--line);
}

.hero-board {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: white;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
}

.metrics div {
  padding: 22px;
  background: white;
}

.metrics strong,
.metrics span {
  display: block;
}

.metrics strong {
  font-size: 30px;
}

.section {
  padding: 72px 0;
}

.section.compact {
  padding-top: 28px;
}

.page-hero {
  padding: 58px 0 28px;
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  max-width: 860px;
  margin: 0;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 0.98;
  letter-spacing: 0;
}

.page-hero p:not(.eyebrow) {
  max-width: 760px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

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

.section h2 {
  font-size: clamp(30px, 4vw, 48px);
}

.search,
.select,
.account-form label,
.checkout-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.search input,
.select select,
.account-form input,
.checkout-form input,
.checkout-form textarea {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  padding: 0 12px;
}

.catalog-tools.standalone {
  align-items: end;
  margin-bottom: 22px;
}

.checkout-form textarea {
  min-height: 92px;
  padding-top: 10px;
  resize: vertical;
}

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

.product-card {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  min-height: 100%;
}

.product-card[hidden] {
  display: none;
}

.product-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}

.product-body {
  display: grid;
  grid-template-rows: auto auto 1fr auto auto;
  gap: 10px;
  padding: 16px;
}

.category,
.product-body h2,
.product-body p {
  margin: 0;
}

.product-body h2 {
  font-size: 18px;
  letter-spacing: 0;
}

.product-body p {
  line-height: 1.45;
}

.product-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.price {
  font-size: 20px;
  font-weight: 850;
}

.rating {
  color: var(--gold);
  font-weight: 850;
}

.rating::before {
  content: "Rating ";
  color: var(--muted);
  font-weight: 650;
}

.product-action {
  width: 100%;
  background: var(--ink);
  color: white;
}

.split {
  border-top: 1px solid var(--line);
}

.deal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.deal-grid article,
.checkout-box,
.account-form,
.checkout-form {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  padding: 22px;
}

.deal-grid h2,
.deal-grid p {
  margin-top: 0;
}

.deal-grid h2 {
  font-size: 22px;
  letter-spacing: 0;
}

.deal-grid p,
.split p {
  color: var(--muted);
  line-height: 1.6;
}

.link-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

.link-grid a {
  display: grid;
  gap: 10px;
  min-height: 156px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  text-decoration: none;
}

.link-grid strong {
  font-size: 20px;
}

.link-grid span {
  color: var(--muted);
  line-height: 1.45;
}

.promo-band {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 18px;
  padding: 22px;
  border-radius: 8px;
  background: var(--brand-dark);
  color: white;
}

.split {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 42px;
  align-items: start;
}

.profile-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.profile-list div {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.profile-list dd {
  margin: 0;
  font-weight: 750;
}

.account-form,
.checkout-form {
  display: grid;
  gap: 16px;
}

.checkbox {
  grid-template-columns: auto 1fr;
  align-items: center;
}

.checkout-box {
  display: grid;
  gap: 12px;
}

.checkout-box h2 {
  margin: 0;
  font-size: 24px;
}

.checkout-items {
  display: grid;
  gap: 8px;
  min-height: 44px;
}

.checkout-line,
.totals {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.totals {
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.totals.grand {
  font-size: 20px;
}

.form-status {
  min-height: 24px;
  color: var(--brand-dark);
  font-weight: 750;
}

.empty-state {
  margin: 0;
  color: var(--muted);
}

.cart-drawer {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: flex;
  justify-content: end;
  background: rgb(23 33 31 / 48%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.cart-drawer[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.cart-panel {
  display: grid;
  grid-template-rows: auto 1fr auto;
  width: min(420px, 100%);
  height: 100%;
  background: white;
  box-shadow: var(--shadow);
}

.cart-header,
.cart-footer {
  padding: 20px;
  border-bottom: 1px solid var(--line);
}

.cart-footer {
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart-header h2 {
  margin: 0;
}

.cart-header button {
  padding: 8px 12px;
}

.cart-items,
.cart-page-list {
  display: grid;
  align-content: start;
  gap: 14px;
  overflow: auto;
  padding: 20px;
}

.cart-page-list {
  min-height: 240px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.cart-line {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
}

.cart-line img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}

.cart-line strong,
.cart-line span {
  display: block;
}

.quantity {
  display: inline-grid;
  grid-template-columns: 32px 38px 32px;
  align-items: center;
  margin-top: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.quantity button {
  height: 32px;
}

.quantity span {
  text-align: center;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 34px 0;
  border-top: 1px solid var(--line);
}

@media (max-width: 980px) {
  .hero,
  .split,
  .section-heading {
    grid-template-columns: 1fr;
    display: grid;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .deal-grid,
  .link-grid,
  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .nav {
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .nav-links {
    order: 3;
    width: 100%;
    margin-left: 0;
    overflow: auto;
    padding-bottom: 4px;
  }
}

@media (max-width: 640px) {
  .nav,
  main,
  .footer {
    width: min(100% - 24px, 1180px);
  }

  .hero {
    min-height: auto;
    padding-top: 34px;
  }

  .hero h1 {
    font-size: 42px;
  }

  .product-grid,
  .deal-grid,
  .link-grid,
  .metrics {
    grid-template-columns: 1fr;
  }

  .catalog-tools,
  .catalog-tools label {
    width: 100%;
  }

  .footer,
  .profile-list div,
  .promo-band {
    display: grid;
    grid-template-columns: 1fr;
  }
}
