:root {
  --ink: #102034;
  --muted: #5e6b78;
  --line: #dce3ea;
  --surface: #ffffff;
  --soft: #f4f7f9;
  --navy: #0a1a2f;
  --blue: #1769ff;
  --blue-dark: #0c4ed8;
  --green: #087a55;
  --amber: #9a6300;
  --red: #b42318;
  --radius: 18px;
  --shadow: 0 20px 55px rgba(16, 32, 52, .11);
}

* { box-sizing: border-box; }
html { color-scheme: light; scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--soft);
  font: 16px/1.55 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
img { max-width: 100%; }
[hidden] { display: none !important; }

.shell { width: min(1180px, calc(100% - 36px)); margin-inline: auto; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.site-nav {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--navy);
  font-weight: 900;
  letter-spacing: .1em;
  text-decoration: none;
}
.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  color: #fff;
  background: var(--navy);
  letter-spacing: 0;
}
.nav-links, .nav-actions { display: flex; align-items: center; gap: 18px; }
.nav-links a, .nav-actions a {
  color: var(--muted);
  font-weight: 700;
  text-decoration: none;
}
.nav-links a:hover, .nav-actions a:hover { color: var(--blue); }
.nav-cart-summary {
  position: relative;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid rgba(23, 105, 255, .2);
  border-radius: 999px;
  color: #fff !important;
  background: linear-gradient(135deg, var(--navy), #123f78);
  box-shadow: 0 10px 24px rgba(10, 26, 47, .16);
  transition: transform .18s ease, box-shadow .18s ease;
}
.nav-cart-summary:hover {
  color: #fff !important;
  transform: translateY(-1px);
  box-shadow: 0 13px 30px rgba(10, 26, 47, .22);
}
.nav-cart-summary svg { flex: 0 0 auto; }
.nav-cart-amount {
  min-width: 54px;
  font-variant-numeric: tabular-nums;
  font-size: .86rem;
  font-weight: 900;
  white-space: nowrap;
}
.nav-cart-count {
  min-width: 19px;
  height: 19px;
  position: absolute;
  top: -6px;
  right: -5px;
  display: grid;
  place-items: center;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  color: #fff;
  background: var(--blue);
  font-size: .65rem;
  font-weight: 900;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 800;
  text-decoration: none;
  transition: .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button:disabled { cursor: not-allowed; opacity: .52; transform: none; }
.button-primary { color: #fff; background: var(--blue); }
.button-primary:hover { background: var(--blue-dark); }
.button-secondary { color: var(--ink); background: #fff; border-color: var(--line); }
.button-danger { color: #fff; background: var(--red); }
.button-small { min-height: 36px; padding: 7px 13px; font-size: .88rem; }

.page { min-height: calc(100vh - 150px); padding: 54px 0 76px; }
.page-header { margin-bottom: 28px; }
.eyebrow {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: .78rem;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}
h1, h2, h3, p { overflow-wrap: anywhere; }
h1 { margin: 0; font-size: clamp(2.1rem, 5vw, 4rem); line-height: 1.02; letter-spacing: -.045em; }
h2 { margin: 0; font-size: clamp(1.35rem, 3vw, 2rem); line-height: 1.16; }
h3 { margin: 0; }
.lead { max-width: 720px; color: var(--muted); font-size: 1.08rem; }
.muted { color: var(--muted); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 8px 26px rgba(16, 32, 52, .05);
}
.card-pad { padding: clamp(20px, 4vw, 34px); }
.stack { display: grid; gap: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 18px; }

.field-group { display: grid; gap: 7px; }
.field-group label { font-size: .9rem; font-weight: 800; }
.field {
  width: 100%;
  min-height: 46px;
  padding: 10px 13px;
  border: 1px solid #cbd5df;
  border-radius: 11px;
  color: var(--ink);
  background: #fff;
  outline: none;
}
textarea.field { min-height: 130px; resize: vertical; }
.field:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(23, 105, 255, .13); }
.field[readonly] { color: var(--muted); background: var(--soft); }
.hint { margin: 0; color: var(--muted); font-size: .83rem; }

.notice {
  padding: 13px 15px;
  border: 1px solid #bfd4ff;
  border-radius: 12px;
  color: #123c85;
  background: #edf4ff;
}
.notice.success { color: #075e43; border-color: #a7e2cc; background: #edfbf6; }
.notice.warning { color: #744b00; border-color: #f2d08b; background: #fff8e7; }
.notice.error { color: #8f1d18; border-color: #f2b6b1; background: #fff1f0; }
.state {
  min-height: 260px;
  display: grid;
  place-items: center;
  padding: 34px;
  text-align: center;
}
.state-copy { max-width: 540px; }
.state-copy p { color: var(--muted); }
.spinner {
  width: 34px;
  height: 34px;
  margin: 0 auto 14px;
  border: 3px solid #dce6f5;
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin .75s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--green);
  background: #e9f9f3;
  font-size: .78rem;
  font-weight: 900;
  text-transform: uppercase;
}
.badge.pending { color: var(--amber); background: #fff5d9; }
.badge.failed, .badge.canceled, .badge.rejected, .badge.error { color: var(--red); background: #fff0ee; }
.badge.fulfilled, .badge.published, .badge.paid, .badge.success { color: var(--green); background: #e9f9f3; }

.empty { padding: 42px 20px; text-align: center; color: var(--muted); }
.pagination { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 24px; }
.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 80;
  max-width: min(420px, calc(100% - 40px));
  padding: 13px 16px;
  border-radius: 12px;
  color: #fff;
  background: var(--navy);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: .2s ease;
}
.toast.visible { opacity: 1; transform: translateY(0); }

.product-detail-blocks-section {
  display: grid;
  gap: 22px;
  margin-top: 22px;
}
.product-detail-blocks-section[hidden] { display: none; }
.product-detail-blocks-section > div { display: grid; gap: 22px; }
.product-detail-block {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 8px 26px rgba(16, 32, 52, .05);
}
.product-detail-markdown { padding: clamp(20px, 4vw, 34px); }
.product-detail-media img,
.product-detail-video {
  display: block;
  width: 100%;
  max-height: min(76vh, 820px);
  object-fit: contain;
  background: #07182d;
}
.product-detail-block-caption {
  padding: 13px 18px;
  color: var(--muted);
  font-size: .9rem;
  line-height: 1.55;
}
.product-detail-media-fallback {
  display: grid;
  min-height: 180px;
  place-items: center;
  padding: 24px;
  color: var(--muted);
  background: var(--soft);
  text-align: center;
}

.site-footer { padding: 28px 0; color: #b9c6d5; background: var(--navy); }
.footer-row { display: flex; justify-content: space-between; gap: 24px; align-items: center; }
.site-footer .brand { color: #fff; }
.footer-links { display: flex; flex-wrap: wrap; gap: 16px; }
.footer-links a { text-decoration: none; }

@media (max-width: 800px) {
  .nav-links { display: none; }
  .grid-2 { grid-template-columns: 1fr; }
  .footer-row { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 520px) {
  .shell { width: min(100% - 24px, 1180px); }
  .site-nav { min-height: 62px; }
  .nav-actions { gap: 10px; }
  .nav-actions a { font-size: .86rem; }
  .nav-cart-summary { min-width: 44px; padding-inline: 11px; }
  .nav-cart-amount { display: none; }
  .page { padding-top: 34px; }
  .button { padding-inline: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation-duration: .01ms !important; }
}
