:root {
  --crimson: #991b1b;
  --crimson-bright: #b91c1c;
  --crimson-soft: #fef2f2;
  --slate-950: #0f172a;
  --slate-900: #111827;
  --slate-800: #1f2937;
  --slate-600: #4b5563;
  --slate-500: #6b7280;
  --bg: #f8fafc;
  --surface: #ffffff;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --emerald: #047857;
  --emerald-bg: #ecfdf5;
  --emerald-border: #a7f3d0;
  --sans: "Segoe UI", "Inter", -apple-system, BlinkMacSystemFont, Arial, sans-serif;
  --mono: "Consolas", "SFMono-Regular", ui-monospace, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--slate-900);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.mono {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

.container {
  max-width: 1320px;
  margin: 0 auto;
  padding-left: 28px;
  padding-right: 28px;
}

/* Announcement & Statutory Ribbon */
.top-ribbon {
  background: var(--slate-900);
  color: #f1f5f9;
  font-size: 12px;
  border-bottom: 2px solid var(--crimson);
}

.top-ribbon-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 8px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.ribbon-badge {
  display: inline-block;
  background: var(--crimson);
  color: #ffffff;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 3px;
  margin-right: 8px;
}

/* Main Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border-strong);
  position: sticky;
  top: 0;
  z-index: 40;
}

.header-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 28px;
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

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

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--crimson) 0%, var(--slate-900) 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.brand-name {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--slate-900);
  line-height: 1.15;
}

.brand-sub {
  font-size: 11px;
  color: var(--slate-600);
  font-family: var(--mono);
}

.nav-bar {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  text-decoration: none;
  color: var(--slate-800);
  font-size: 14px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}

.nav-link:hover {
  background: #f1f5f9;
}

.nav-link.active {
  background: var(--crimson);
  color: #ffffff;
}

.bag-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--slate-900);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 9px 15px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--sans);
}

.bag-btn:hover {
  background: var(--crimson);
}

.bag-count {
  background: var(--crimson-bright);
  color: #ffffff;
  border-radius: 999px;
  padding: 1px 7px;
  font-size: 11px;
  font-family: var(--mono);
}

/* Trust Strip */
.trust-strip {
  background: #ffffff;
  border-bottom: 1px solid var(--border);
}

.trust-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 11px 28px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.trust-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--slate-800);
}

.pill-tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  white-space: nowrap;
}

.pill-green {
  background: var(--emerald-bg);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
}

.pill-crimson {
  background: var(--crimson-soft);
  color: var(--crimson);
  border: 1px solid #fecaca;
}

/* Hero Section */
.main-wrap {
  padding: 26px 0 36px 0;
}

.hero-card {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-top: 4px solid var(--crimson);
  border-radius: 10px;
  padding: 26px 28px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.hero-kicker {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--crimson);
  background: var(--crimson-soft);
  border: 1px solid #fecaca;
  padding: 3px 9px;
  border-radius: 4px;
  margin-bottom: 10px;
}

.hero-title {
  font-size: 32px;
  line-height: 1.16;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--slate-950);
  margin-bottom: 12px;
}

.hero-lead {
  font-size: 14.5px;
  color: var(--slate-600);
  margin-bottom: 18px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.btn-primary {
  display: inline-block;
  background: var(--crimson);
  color: #ffffff;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 6px;
  border: 1px solid var(--crimson);
}

.btn-secondary {
  display: inline-block;
  background: #ffffff;
  color: var(--slate-900);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
}

.hero-meta-note {
  font-size: 12px;
  color: var(--slate-600);
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.entity-box {
  background: #f8fafc;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 18px;
}

.entity-box-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
  margin-bottom: 10px;
}

.entity-box-head h3 {
  font-size: 13px;
  font-family: var(--mono);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--slate-900);
}

.kv-grid {
  display: grid;
  grid-template-columns: 138px 1fr;
  row-gap: 7px;
  column-gap: 10px;
  font-size: 12.5px;
}

.kv-grid dt {
  color: var(--slate-600);
  font-weight: 600;
}

.kv-grid dd {
  color: var(--slate-900);
  font-family: var(--mono);
  font-weight: 700;
}

/* KPI Strip */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 20px;
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-left: 4px solid var(--crimson);
  border-radius: 8px;
  padding: 15px 18px;
}

.kpi-label {
  font-size: 11px;
  font-family: var(--mono);
  font-weight: 700;
  color: var(--slate-600);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.kpi-val {
  font-size: 25px;
  font-weight: 800;
  color: var(--slate-950);
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

.kpi-sub {
  font-size: 11.5px;
  color: var(--slate-600);
  margin-top: 3px;
}

/* Section Headers */
.sec-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-bottom: 2px solid var(--slate-900);
  padding-bottom: 9px;
  margin: 26px 0 16px 0;
  gap: 12px;
}

.sec-head h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--slate-950);
}

.sec-head .sec-sub {
  font-size: 12px;
  font-family: var(--mono);
  color: var(--slate-600);
  font-weight: 600;
}

/* Product Grid */
.filter-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.filter-pill {
  border: 1px solid var(--border-strong);
  background: #ffffff;
  color: var(--slate-800);
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}

.filter-pill.active {
  background: var(--slate-900);
  color: #ffffff;
  border-color: var(--slate-900);
}

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

.product-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: box-shadow 0.15s;
}

.product-card:hover {
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
}

.product-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.grade-tag {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  background: var(--emerald-bg);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
  padding: 2px 7px;
  border-radius: 4px;
}

.stock-tag {
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--crimson);
}

.product-img-box {
  height: 175px;
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  margin-bottom: 10px;
}

.product-img-box img {
  max-height: 158px;
  max-width: 100%;
  object-fit: contain;
}

.sku-line {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--slate-500);
  margin-bottom: 3px;
}

.product-name {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--slate-950);
  margin-bottom: 5px;
  line-height: 1.3;
}

.product-specs {
  font-size: 11.5px;
  color: var(--slate-600);
  border-top: 1px solid #f1f5f9;
  padding-top: 6px;
  margin-bottom: 10px;
}

.product-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border);
  padding-top: 10px;
  gap: 8px;
}

.price {
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 800;
  color: var(--slate-950);
}

.add-bag-btn {
  background: var(--crimson);
  color: #ffffff;
  border: none;
  border-radius: 5px;
  padding: 7px 11px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.add-bag-btn:hover {
  background: var(--slate-900);
}

/* Standards / 3-column Banner */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.pillar-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 18px;
}

.pillar-card h3 {
  font-size: 15px;
  font-weight: 800;
  color: var(--crimson);
  margin-bottom: 6px;
}

.pillar-card p {
  font-size: 13px;
  color: var(--slate-600);
}

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  overflow: hidden;
  font-size: 13px;
}

.data-table th {
  background: var(--slate-900);
  color: #ffffff;
  text-align: left;
  padding: 11px 14px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.data-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}

.data-table tr:nth-child(even) td {
  background: #f8fafc;
}

/* Reviews Page */
.reviews-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 20px;
}

.hist-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 20px;
}

.hist-row {
  display: grid;
  grid-template-columns: 52px 1fr 78px;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-family: var(--mono);
  margin-bottom: 8px;
}

.hist-bg {
  height: 11px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

.hist-fill {
  height: 100%;
  background: var(--emerald);
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.review-card {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-top: 3px solid var(--emerald);
  border-radius: 8px;
  padding: 16px;
}

.review-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-family: var(--mono);
  color: var(--slate-500);
  margin-bottom: 6px;
}

.stars {
  color: var(--emerald);
  font-weight: 800;
}

/* Shopping Bag Drawer */
.bag-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: none;
  justify-content: flex-end;
  z-index: 90;
}

.bag-drawer-backdrop.open {
  display: flex;
}

.bag-drawer {
  width: 390px;
  max-width: 92vw;
  background: #ffffff;
  height: 100%;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: -8px 0 28px rgba(15, 23, 42, 0.16);
}

.bag-items {
  flex: 1;
  overflow-y: auto;
  margin: 14px 0;
  border-top: 1px solid var(--border);
  padding-top: 10px;
}

.bag-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

/* Footer */
.site-footer {
  background: var(--slate-900);
  color: #cbd5e1;
  border-top: 3px solid var(--crimson);
  padding: 24px 0 18px 0;
  margin-top: 28px;
  font-size: 12.5px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 24px;
}

.footer-title {
  color: #ffffff;
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.footer-links a {
  display: block;
  color: #e2e8f0;
  text-decoration: none;
  margin-bottom: 4px;
}

.footer-links a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.footer-bottom {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid #334155;
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  font-family: var(--mono);
  color: #94a3b8;
  flex-wrap: wrap;
  gap: 10px;
}

@media (max-width: 1024px) {
  .hero-card, .kpi-grid, .product-grid, .pillars-grid, .reviews-layout, .review-grid, .footer-grid, .trust-inner {
    grid-template-columns: 1fr;
  }
}
