:root {
  --ink: #241816;
  --muted: #756761;
  --line: #e5d8ca;
  --paper: #f7f1e9;
  --panel: #ffffff;
  --accent: #b31217;
  --accent-dark: #7f0d11;
  --coral: #d89b23;
  --gold: #e0ad36;
  --blue: #263f66;
  --shadow: 0 18px 55px rgba(91, 22, 17, 0.14);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

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

.site-footer {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  padding: 24px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
  border-top: 1px solid var(--line);
  background: var(--panel);
}

.site-footer p {
  margin: 0;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.policy-page {
  display: grid;
  gap: 20px;
  padding-top: 40px;
  padding-bottom: 60px;
}

.policy-page p {
  color: var(--muted);
  line-height: 1.9;
}

.review-card {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.review-card p {
  margin: 8px 0;
}

.table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.product-importer {
  margin-bottom: 20px;
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: 14px;
  background: var(--paper);
}

.product-importer label {
  display: grid;
  gap: 8px;
}

.product-importer small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
}

button,
input,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(179, 18, 23, 0.12);
  background: rgba(255, 251, 246, 0.94);
  backdrop-filter: blur(18px);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.brand-mark {
  width: 46px;
  height: 46px;
  display: block;
  flex: 0 0 46px;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: 0 10px 22px rgba(179, 18, 23, 0.18);
}

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

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

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.nav-links a {
  padding: 10px 12px;
  color: #3d4348;
  font-size: 14px;
}

.nav-links a:hover {
  color: var(--accent);
}

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

.icon-button,
.cart-button,
.tab-button {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
}

.icon-button {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  font-weight: 700;
}

.cart-button {
  height: 42px;
  min-width: 82px;
  border-radius: 8px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.cart-button b {
  min-width: 24px;
  height: 24px;
  padding: 0 7px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: white;
  background: var(--accent);
  font-size: 12px;
}

.hero {
  min-height: clamp(540px, 72svh, 720px);
  position: relative;
  display: grid;
  align-items: center;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(61, 7, 8, 0.84), rgba(105, 14, 14, 0.5) 48%, rgba(36, 24, 22, 0.12)),
    linear-gradient(0deg, rgba(36, 24, 22, 0.48), rgba(36, 24, 22, 0));
}

.hero-media {
  position: absolute;
  inset: 0;
  background-image: url("https://images.unsplash.com/photo-1556742049-0cfed4f6a45d?auto=format&fit=crop&w=1800&q=82");
  background-size: cover;
  background-position: center 48%;
  transform: scale(1.03);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 58px;
  color: white;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #ffd56a;
}

.hero h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(42px, 7vw, 92px);
  line-height: 1.02;
  letter-spacing: 0;
}

.hero p:not(.eyebrow) {
  max-width: 620px;
  margin: 20px 0 0;
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.55;
}

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

.primary-link,
.secondary-link,
.primary-button {
  min-height: 46px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  font-weight: 800;
}

.primary-link,
.primary-button {
  border: 0;
  color: white;
  background: linear-gradient(135deg, var(--accent), #d1252b);
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(179, 18, 23, 0.22);
}

.primary-link:hover,
.primary-button:hover {
  background: linear-gradient(135deg, var(--accent-dark), var(--accent));
}

.secondary-link {
  border: 1px solid rgba(255, 255, 255, 0.72);
  color: white;
}

.member-entry {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: #fffaf3;
  font-size: 13px;
  font-weight: 800;
}

.full {
  width: 100%;
}

.trust-strip {
  width: min(1180px, calc(100% - 32px));
  margin: -30px auto 0;
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--panel);
}

.trust-strip div {
  min-height: 112px;
  padding: 24px;
  border-right: 1px solid var(--line);
}

.trust-strip div:last-child {
  border-right: 0;
}

.trust-strip strong,
.trust-strip span {
  display: block;
}

.trust-strip strong {
  font-size: 18px;
}

.trust-strip span {
  margin-top: 7px;
  color: var(--muted);
  line-height: 1.45;
}

.rewards-band {
  display: grid;
  grid-template-columns: 0.86fr 1.14fr;
  gap: 28px;
  align-items: start;
}

.reward-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.reward-steps div,
.stat-card,
.admin-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 10px 32px rgba(32, 33, 36, 0.07);
}

.reward-steps div {
  min-height: 150px;
  padding: 18px;
  border-top: 4px solid var(--gold);
}

.reward-steps strong,
.reward-steps span {
  display: block;
}

.reward-steps strong {
  line-height: 1.35;
}

.reward-steps span {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.55;
}

.promo-band {
  min-height: 420px;
  position: relative;
  overflow: hidden;
  display: grid;
  align-items: end;
  padding: 40px;
  border-radius: 8px;
  color: white;
  background: var(--accent-dark);
}

.promo-band::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(70, 8, 10, 0.86), rgba(70, 8, 10, 0.22));
}

.promo-band img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.promo-band > div {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.promo-band h2 {
  margin-bottom: 22px;
}

.section-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 74px 0 0;
}

.split-section {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 50px;
  align-items: start;
}

h2 {
  margin: 0;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.05;
  letter-spacing: 0;
}

.split-section p:last-child,
.checkout-copy p:last-child {
  margin: 35px 0 0;
  color: #454c52;
  font-size: 18px;
  line-height: 1.72;
}

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

.search-box,
.sort-box,
.checkout-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.search-box input,
.sort-box select,
.checkout-form input,
.checkout-form select {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  color: var(--ink);
  background: white;
  outline: none;
}

.search-box input:focus,
.sort-box select:focus,
.checkout-form input:focus,
.checkout-form select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.search-box {
  width: min(340px, 100%);
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tab-button {
  height: 40px;
  border-radius: 8px;
  padding: 0 14px;
  font-weight: 800;
}

.tab-button.active {
  border-color: var(--accent);
  color: white;
  background: var(--accent);
}

.sort-box {
  min-width: 190px;
}

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

.product-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 10px 32px rgba(32, 33, 36, 0.07);
}

.product-image {
  aspect-ratio: 4 / 3;
  background: #eef1f2;
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 220ms ease;
}

.product-card:hover img {
  transform: scale(1.04);
}

.product-body {
  padding: 16px;
}

.product-meta {
  min-height: 26px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.product-body h3 {
  min-height: 48px;
  margin: 7px 0 9px;
  font-size: 18px;
  line-height: 1.3;
}

.product-body p {
  min-height: 44px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 15px;
}

.price-row strong {
  font-size: 20px;
}

.add-button,
.quantity-button {
  border: 0;
  border-radius: 8px;
  color: white;
  background: var(--ink);
  cursor: pointer;
}

.add-button {
  min-height: 40px;
  padding: 0 12px;
  font-weight: 800;
}

.add-button:hover {
  background: var(--blue);
}

.empty-state {
  grid-column: 1 / -1;
  padding: 42px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.checkout-section {
  padding-bottom: 86px;
  display: grid;
  grid-template-columns: 0.85fr 1.1fr 0.8fr;
  gap: 22px;
  align-items: start;
}

.home-checkout-section {
  display: none !important;
}

.checkout-page-heading {
  padding-bottom: 24px;
}

.checkout-page-heading h1 {
  margin: 8px 0;
  font-size: clamp(30px, 5vw, 52px);
}

.checkout-page-section {
  padding-top: 0;
}

.checkout-form,
.summary-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  box-shadow: 0 10px 32px rgba(32, 33, 36, 0.07);
}

.checkout-form {
  padding: 22px;
}

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

.wide {
  grid-column: 1 / -1;
}

.primary-button {
  width: 100%;
  margin-top: 18px;
}

.form-status {
  min-height: 24px;
  margin: 12px 0 0;
  color: var(--accent);
  font-weight: 800;
}

.summary-panel {
  padding: 22px;
}

.summary-panel h3 {
  margin: 0 0 16px;
  font-size: 22px;
}

.summary-items {
  display: grid;
  gap: 12px;
  max-height: 260px;
  overflow: auto;
}

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

.summary-line img,
.cart-line img {
  width: 52px;
  height: 52px;
  border-radius: 8px;
  object-fit: cover;
}

.summary-line strong,
.cart-line strong {
  display: block;
  line-height: 1.25;
}

.summary-line span,
.cart-line span {
  color: var(--muted);
  font-size: 13px;
}

.totals {
  margin: 18px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.totals div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin: 10px 0;
}

.totals dt {
  color: var(--muted);
}

.totals dd {
  margin: 0;
  font-weight: 800;
}

.grand-total {
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 22px;
}

.cart-drawer {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  background: rgba(32, 33, 36, 0);
  transition: background 180ms ease;
}

.cart-drawer.open {
  pointer-events: auto;
  background: rgba(32, 33, 36, 0.42);
}

.drawer-panel {
  width: min(420px, 100%);
  height: 100%;
  margin-left: auto;
  padding: 20px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: var(--paper);
  transform: translateX(100%);
  transition: transform 220ms ease;
}

.cart-drawer.open .drawer-panel {
  transform: translateX(0);
}

.drawer-header {
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-header h2 {
  font-size: 28px;
}

.cart-items {
  display: grid;
  align-content: start;
  gap: 14px;
  overflow: auto;
  padding: 12px 0;
}

.cart-line {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: white;
}

.quantity-controls {
  display: flex;
  align-items: center;
  gap: 7px;
}

.quantity-button {
  width: 28px;
  height: 28px;
}

.drawer-footer {
  display: grid;
  gap: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.drawer-footer div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.admin-body {
  background: #f5f7f6;
}

.admin-body .nav-shell {
  min-height: 56px;
  gap: 12px;
}

.admin-body .brand {
  min-width: 180px;
  gap: 8px;
}

.admin-body .brand-mark {
  width: 30px;
  height: 30px;
  flex-basis: 30px;
}

.admin-body .brand strong {
  font-size: 13px;
}

.admin-body .brand small {
  margin-top: 0;
  font-size: 10px;
}

.admin-body .nav-links {
  gap: 4px;
}

.admin-body .nav-links a {
  padding: 6px 7px;
  font-size: 12px;
}

.admin-body .nav-links a.active {
  color: white;
  background: var(--accent);
}

.admin-body .nav-actions {
  gap: 6px;
  font-size: 12px;
}

.admin-refresh-status {
  color: var(--muted);
  white-space: nowrap;
}

.admin-shell {
  width: min(1220px, calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 42px;
  font-size: 12px;
}

.admin-hero {
  min-height: 86px;
  display: grid;
  align-items: end;
  padding: 14px 16px;
  border-radius: 8px;
  color: white;
  background:
    linear-gradient(90deg, rgba(32, 33, 36, 0.86), rgba(32, 33, 36, 0.38)),
    url("https://images.unsplash.com/photo-1460925895917-afdab827c52f?auto=format&fit=crop&w=1600&q=82") center / cover;
}

.admin-hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(18px, 2vw, 26px);
  line-height: 1;
}

.admin-hero p:last-child {
  max-width: 650px;
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 12px;
  line-height: 1.35;
}

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

.stat-card {
  min-height: 54px;
  padding: 8px;
}

.stat-link {
  width: 100%;
  color: inherit;
  text-align: left;
  border: 1px solid var(--line);
  cursor: pointer;
}

.stat-link:hover {
  border-color: rgba(177, 69, 47, 0.34);
  transform: translateY(-1px);
}

.stat-link em {
  display: block;
  margin-top: 6px;
  color: var(--primary);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.stat-card span,
.panel-heading span,
.admin-table span,
.admin-note {
  color: var(--muted);
  font-size: 11px;
}

.stat-card strong {
  display: block;
  margin-top: 5px;
  font-size: clamp(14px, 1.5vw, 18px);
  line-height: 1;
}

.fund-pool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 10px 0;
}

.fund-pool-card {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  width: 100%;
  padding: 14px;
  color: inherit;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(250, 244, 235, 0.92));
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}

.fund-pool-card:hover {
  border-color: rgba(177, 69, 47, 0.32);
  transform: translateY(-1px);
}

.fund-pool-card.globalDividend {
  background: linear-gradient(135deg, rgba(245, 249, 255, 0.98), rgba(240, 247, 244, 0.94));
}

.fund-pool-icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: rgba(177, 69, 47, 0.1);
  font-size: 28px;
}

.fund-pool-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.fund-pool-head span {
  font-size: 14px;
  font-weight: 900;
}

.fund-pool-head em {
  padding: 4px 8px;
  color: var(--primary);
  border-radius: 999px;
  background: rgba(177, 69, 47, 0.08);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.fund-pool-main strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: clamp(22px, 2.4vw, 32px);
  line-height: 1;
}

.fund-pool-main p {
  margin: 8px 0;
  color: var(--muted);
  font-size: 12px;
}

.fund-pool-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
}

.fund-pool-meta span {
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
}

.fund-pool-progress {
  height: 8px;
  margin-top: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(22, 32, 45, 0.1);
}

.fund-pool-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.admin-panel {
  min-width: 0;
  padding: 9px;
  margin-top: 8px;
}

.admin-page-intro {
  margin-bottom: 8px;
}

.admin-subnav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-subnav a {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #f7f8f7;
  font-size: 12px;
  font-weight: 800;
}

.admin-subnav a:hover {
  color: white;
  background: var(--accent);
}

.admin-grid .admin-panel {
  margin-top: 0;
}

.panel-heading {
  min-height: 24px;
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 7px;
}

.panel-heading h2 {
  font-size: 14px;
  line-height: 1.15;
}

.admin-table {
  width: 100%;
  overflow: auto;
}

.admin-table table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.admin-table th,
.admin-table td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: #454c52;
  font-size: 11px;
  background: #f7f8f7;
}

.admin-table strong {
  display: block;
}

.status-pill,
.table-button {
  min-height: 22px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 7px;
  font-size: 11px;
}

.status-pill {
  color: white;
  background: var(--accent);
  font-size: 12px;
  font-weight: 800;
}

.table-button {
  border: 1px solid var(--line);
  background: white;
  cursor: pointer;
  font-weight: 800;
}

.danger-button {
  color: #b42318;
  border-color: #f3b7b1;
  background: #fff7f6;
}

.table-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.admin-table input[type="checkbox"]:disabled {
  cursor: not-allowed;
  opacity: 0.35;
}

.admin-note {
  margin: 8px 0 0;
  line-height: 1.5;
}

.role-guide {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 12px;
  margin: 10px 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f8f7;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.role-guide strong {
  grid-column: 1 / -1;
  color: var(--ink);
  font-size: 12px;
}

.aiops-summary,
.aiops-grid,
.aiops-layout {
  display: grid;
  gap: 8px;
}

.aiops-shell {
  width: min(1380px, calc(100% - 32px));
  font-size: 13px;
}

.aiops-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 10px;
  align-items: stretch;
  margin-bottom: 10px;
}

.aiops-hero > div,
.aiops-hero-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}

.aiops-hero > div:first-child {
  padding: 16px 18px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(32, 33, 36, 0.9), rgba(32, 33, 36, 0.48)),
    url("https://images.unsplash.com/photo-1516321318423-f06f85e504b3?auto=format&fit=crop&w=1600&q=82") center / cover;
}

.aiops-hero h1 {
  margin: 0;
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1;
}

.aiops-hero p:last-child {
  max-width: 780px;
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
  line-height: 1.4;
}

.aiops-hero-card {
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 12px;
}

.aiops-hero-card span,
.aiops-hero-card small {
  color: var(--muted);
}

.aiops-hero-card strong {
  font-size: 18px;
  line-height: 1;
}

.aiops-summary {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-bottom: 8px;
}

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

.aiops-summary-wide {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.aiops-layout {
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 8px;
}

.aiops-config-layout {
  margin-top: 8px;
}

.aiops-metric,
.aiops-card,
.aiops-item {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.aiops-metric {
  padding: 8px;
}

.aiops-metric span,
.aiops-item span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.aiops-metric strong {
  display: block;
  margin-top: 4px;
  font-size: 14px;
}

.aiops-normal {
  border-color: #a7d8b8;
  background: #f4fbf6;
}

.aiops-warning {
  border-color: #f4c76b;
  background: #fff8e8;
}

.aiops-critical {
  border-color: #f1a6a0;
  background: #fff3f1;
}

.aiops-status-normal {
  color: #207a3d;
}

.aiops-status-warning {
  color: #b7791f;
}

.aiops-status-critical {
  color: #b42318;
}

.aiops-card {
  padding: 9px;
}

.aiops-shell .panel-heading {
  min-height: 24px;
  margin-bottom: 7px;
}

.aiops-shell .panel-heading h2 {
  font-size: 14px;
}

.aiops-shell .panel-heading span {
  font-size: 11px;
}

.aiops-card-large {
  min-height: 180px;
}

.aiops-card h3 {
  margin-bottom: 6px;
  font-size: 14px;
}

.aiops-item {
  padding: 7px;
}

.aiops-item + .aiops-item {
  margin-top: 6px;
}

.aiops-item strong {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 3px;
  font-size: 13px;
}

.aiops-item em {
  border-radius: 999px;
  padding: 1px 5px;
  color: #fff;
  background: var(--accent);
  font-size: 10px;
  font-style: normal;
}

.aiops-item small {
  display: block;
  margin-top: 4px;
  color: #747b80;
  font-size: 11px;
}

.aiops-provider-form {
  display: grid;
  grid-template-columns: minmax(220px, 1.1fr) minmax(180px, 0.9fr) minmax(160px, 0.7fr) auto auto;
  gap: 6px;
  align-items: center;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.aiops-provider-form + .aiops-provider-form {
  margin-top: 6px;
}

.aiops-provider-form strong,
.aiops-provider-form span,
.aiops-provider-form small {
  display: block;
}

.aiops-provider-form span,
.aiops-provider-form small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.aiops-provider-form input,
.aiops-shell .compact-form input {
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  font-size: 11px;
}

.aiops-shell .compact-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.aiops-shell .compact-form label {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 11px;
}

.aiops-switch-row {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 7px;
  align-items: start;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.aiops-switch-row + .aiops-switch-row {
  margin-top: 6px;
}

.aiops-switch-row input {
  width: 14px;
  height: 14px;
  margin-top: 2px;
}

.aiops-switch-row strong,
.aiops-switch-row small {
  display: block;
}

.aiops-switch-row small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.aiops-task-filters {
  display: grid;
  grid-template-columns: 120px 120px 120px minmax(160px, 1fr);
  gap: 6px;
  margin-bottom: 7px;
}

.aiops-task-filters select,
.aiops-task-filters input {
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  background: #fff;
  font-size: 11px;
}

.aiops-action-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.aiops-task-detail {
  margin-top: 8px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f7f8f7;
}

.aiops-task-detail p {
  margin: 0 0 8px;
  color: #4f565c;
  line-height: 1.45;
}

.aiops-task-detail dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin: 0 0 8px;
}

.aiops-task-detail dl div {
  padding: 6px;
  border-radius: 10px;
  background: #fff;
}

.aiops-task-detail dt {
  color: var(--muted);
  font-size: 11px;
}

.aiops-task-detail dd {
  margin: 2px 0 0;
  word-break: break-all;
}

.aiops-task-detail pre {
  max-height: 180px;
  overflow: auto;
  margin: 5px 0 0;
  padding: 8px;
  border-radius: 10px;
  background: #fff;
  font-size: 11px;
}

.aiops-support-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 8px;
}

.aiops-support-form input,
.aiops-support-form select,
.aiops-support-form textarea {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  background: #fff;
  font-size: 11px;
}

.aiops-support-form input,
.aiops-support-form select {
  height: 28px;
}

.aiops-support-form textarea {
  grid-column: 1 / -2;
  min-height: 62px;
  padding-top: 7px;
  resize: vertical;
}

.aiops-support-form button {
  min-height: 62px;
}

.aiops-support-draft {
  margin: 6px 0;
  padding: 7px;
  border-radius: 10px;
  background: #f7f8f7;
  white-space: pre-wrap;
  font-size: 11px;
  line-height: 1.45;
}

.aiops-item-critical em {
  background: #b42318;
}

.aiops-item-warning em {
  background: #b7791f;
}

#aiOpsReport {
  min-height: 108px;
  margin: 0;
  padding: 8px;
  border-radius: 12px;
  color: #26312d;
  background: #f7f8f7;
  white-space: pre-wrap;
  font-size: 11px;
  line-height: 1.45;
}

.admin-panel label,
.auth-form label,
.designer-form label {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.admin-panel input,
.admin-panel select,
.auth-form input,
.auth-form select,
.designer-form input,
.designer-form select {
  width: 100%;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  color: var(--ink);
  background: white;
  outline: none;
  font-size: 12px;
}

.designer-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1.1fr);
  gap: 10px;
  align-items: start;
}

.layout-editor {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f8f7;
}

.layout-editor > strong {
  display: block;
  margin-bottom: 8px;
}

.section-control {
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid var(--line);
}

.section-control label {
  display: flex;
  align-items: center;
}

.section-control input {
  width: 14px;
  height: 14px;
}

.store-preview {
  position: sticky;
  top: 70px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: white;
}

.preview-toolbar {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px;
  border-bottom: 1px solid var(--line);
}

.store-preview iframe {
  width: 100%;
  height: 560px;
  display: block;
  border: 0;
}

.level-select {
  min-width: 150px;
  height: 28px !important;
}

.member-body {
  background: #f5f7f6;
}

.member-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0 80px;
}

.auth-layout {
  min-height: calc(100vh - 110px);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 12px;
  align-items: stretch;
}

.auth-intro,
.auth-panel {
  border-radius: 8px;
}

.auth-intro {
  display: grid;
  align-content: end;
  padding: 28px;
  color: white;
  background:
    linear-gradient(0deg, rgba(26, 29, 29, 0.84), rgba(26, 29, 29, 0.2)),
    url("https://images.unsplash.com/photo-1528360983277-13d401cdc186?auto=format&fit=crop&w=1400&q=82") center / cover;
}

.auth-intro h1,
.member-heading h1 {
  margin: 0;
  font-size: clamp(24px, 4vw, 42px);
  line-height: 1;
}

.auth-intro > p:last-of-type {
  max-width: 620px;
  font-size: 13px;
  line-height: 1.45;
}

.auth-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.auth-points span {
  padding: 6px 8px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 8px;
  font-weight: 800;
}

.auth-panel {
  padding: 18px;
  align-self: center;
  border: 1px solid var(--line);
  background: white;
  box-shadow: var(--shadow);
}

.auth-form {
  display: grid;
  gap: 9px;
  margin-top: 12px;
}

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

.member-heading p:last-child {
  color: var(--muted);
}

.share-box {
  width: min(360px, 100%);
  display: grid;
  gap: 8px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.share-box span {
  color: var(--muted);
  font-size: 13px;
}

.share-box strong {
  color: var(--accent);
  font-size: 28px;
}

.share-box input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 10px;
}

.member-stats {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

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

.logistics-editor {
  min-width: 180px;
  display: grid;
  gap: 6px;
}

.logistics-editor input,
.logistics-editor select {
  width: 100%;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
}

.logistics-editor-disabled {
  padding: 8px;
  border: 1px dashed #cfd5d2;
  border-radius: 8px;
  color: #8a9290;
  background: #f5f6f5;
  cursor: not-allowed;
}

.logistics-editor-disabled strong,
.logistics-editor-disabled span,
.logistics-editor-disabled small {
  display: block;
}

.logistics-editor-disabled small {
  margin-top: 2px;
  color: #9aa19f;
  font-size: 11px;
}

.wallet-balances {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.wallet-balances div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f8f7;
}

.wallet-balances span,
.wallet-balances strong {
  display: block;
}

.wallet-balances span {
  color: var(--muted);
  font-size: 13px;
}

.wallet-balances strong {
  margin-top: 7px;
  font-size: 22px;
}

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

.compact-form button,
.compact-form label:last-of-type {
  grid-column: 1 / -1;
}

.progress-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 14px 0 6px;
}

progress {
  width: 100%;
  height: 12px;
  accent-color: var(--accent);
}

.level-list {
  display: grid;
  gap: 8px;
  margin-top: 18px;
}

.level-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.level-row span {
  color: var(--muted);
  font-size: 13px;
}

.level-row.active {
  border-color: var(--accent);
  background: #f4f8f7;
}

.upload-field small,
.admin-panel small {
  color: var(--muted);
  line-height: 1.45;
}

.upload-field input[type="file"] {
  height: auto;
  padding: 9px;
}

.input-action {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.category-manager {
  display: grid;
  gap: 14px;
}

.inline-admin-form {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1.2fr 0.6fr 0.7fr auto;
  gap: 12px;
  align-items: end;
}

.sub-editor {
  margin: 18px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7f8f7;
}

.media-editor-row,
.variant-editor-row {
  display: grid;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}

.media-editor-row {
  grid-template-columns: 64px 1fr auto 32px;
}

.media-editor-row img {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
  background: #e9ecec;
}

.variant-editor-row {
  grid-template-columns: 1fr 1fr 0.7fr 0.7fr 32px;
}

.file-button {
  position: relative;
  overflow: hidden;
}

.file-button input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.product-detail-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 50px 0 90px;
}

.product-detail-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: start;
}

.detail-main-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 8px;
  background: #eef1f2;
}

.detail-main-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-thumbnails {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.detail-thumbnails button {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  background: white;
  cursor: pointer;
}

.detail-thumbnails button.active {
  border-color: var(--accent);
}

.detail-thumbnails img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail-copy h1 {
  margin: 0;
  font-size: clamp(36px, 5vw, 64px);
  line-height: 1;
}

.product-detail-copy > p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.product-detail-en {
  font-size: 14px !important;
}

.detail-price {
  display: block;
  margin: 22px 0;
  font-size: 32px;
}

.spec-copy {
  margin: 20px 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.detail-variant {
  display: grid;
  gap: 7px;
  margin-bottom: 18px;
}

.detail-variant select {
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: white;
}

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

.share-product-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.share-product-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
}

.share-product-card div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.share-product-card input {
  width: 100%;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  font-size: 12px;
}

.captcha-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
}

.captcha-row strong {
  min-width: 88px;
  padding: 12px 8px;
  border-radius: 8px;
  color: var(--accent);
  background: #f1f4f3;
  text-align: center;
}

@media (max-width: 980px) {
  .nav-links {
    display: none;
  }

  .trust-strip,
  .split-section,
  .checkout-section,
  .rewards-band,
  .admin-grid,
  .aiops-hero,
  .aiops-layout,
  .designer-grid,
  .auth-layout,
  .member-grid,
  .product-detail-grid {
    grid-template-columns: 1fr;
  }

  .reward-steps,
  .stats-grid,
  .fund-pool-grid,
  .aiops-summary,
  .aiops-grid,
  .aiops-summary-wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .store-preview {
    position: static;
  }

  .member-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .trust-strip div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .trust-strip div:last-child {
    border-bottom: 0;
  }

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

@media (max-width: 640px) {
  .nav-shell {
    width: calc(100% - 20px);
    min-height: 68px;
    gap: 10px;
  }

  .brand {
    min-width: 0;
  }

  .brand small {
    display: none;
  }

  .brand strong {
    max-width: 138px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .hero {
    min-height: clamp(500px, 74svh, 600px);
  }

  .hero::after {
    background: linear-gradient(0deg, rgba(80, 8, 10, 0.86), rgba(80, 8, 10, 0.26));
  }

  .hero-content {
    width: calc(100% - 24px);
    padding-bottom: 54px;
  }

  .trust-strip,
  .section-shell,
  .admin-shell,
  .member-shell {
    width: calc(100% - 24px);
  }

  .section-heading,
  .toolbar {
    display: grid;
    align-items: stretch;
  }

  .search-box,
  .sort-box {
    width: 100%;
  }

  .product-grid,
  .field-grid,
  .reward-steps,
  .stats-grid,
  .fund-pool-grid,
  .aiops-summary,
  .aiops-grid,
  .aiops-summary-wide,
  .aiops-hero,
  .aiops-layout {
    grid-template-columns: 1fr;
  }

  .admin-hero {
    padding: 28px 20px;
  }

  .member-heading {
    display: grid;
    align-items: stretch;
  }

  .share-box {
    width: 100%;
  }

  .wallet-balances,
  .compact-form,
  .member-stats {
    grid-template-columns: 1fr;
  }

  .compact-form button,
  .compact-form label:last-of-type {
    grid-column: auto;
  }

  .auth-intro {
    min-height: 480px;
    padding: 28px 20px;
  }

  .product-detail-shell {
    width: calc(100% - 24px);
  }

  .inline-admin-form,
  .share-product-grid,
  .media-editor-row,
  .variant-editor-row {
    grid-template-columns: 1fr;
  }

  .media-editor-row img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
  }

  .captcha-row {
    grid-template-columns: 1fr;
  }

  .wide {
    grid-column: auto;
  }

  .product-body h3,
  .product-body p {
    min-height: auto;
  }

.site-footer {
    flex-direction: column;
    gap: 8px;
  }
}

.positive {
  color: #0f766e;
}

.negative {
  color: #b1452f;
}
