/* GOCABON — public site styles
   Tema gelap & terang memakai CSS variables. html[data-theme] diset oleh script kecil di <head>. */

:root,
:root[data-theme="dark"] {
  --bg: #0C0D0F;
  --surface: #111316;
  --surface-2: #15171A;
  --line: #23262B;
  --line-2: #2A2D33;
  --line-hover: #3A3E45;
  --text: #F2F2F0;
  --text-2: #C4C7CC;
  --muted: #A3A7AE;
  --faint: #6E737B;
  --accent: #E4FF3C;
  --on-accent: #0C0D0F;
  --accent-text: #E4FF3C;
  --primary-bg: var(--accent);
  --primary-text: #0C0D0F;
  --selected: var(--accent);
  --selected-bg: #1A1C10;
  --strip-bg: var(--accent);
  --strip-text: #0C0D0F;
  --block-text: #F2F2F0;
  --block-muted: #C4C7CC;
  --eyebrow-bg: rgba(228, 255, 60, .08);
  --tag-full-bg: #0C0D0F;  --tag-full-text: var(--accent);
  --tag-hy-bg: #0C0D0F;    --tag-hy-text: #C4C7CC;
  --weave-base: #16181B;
  --weave-a: rgba(255, 255, 255, .035);
  --weave-b: rgba(0, 0, 0, .35);
  --shadow: 0 8px 24px rgba(0, 0, 0, .45);
  --wa: #25D366;
  --on-wa: #06210F;
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #F4F5F6;
  --surface: #FFFFFF;
  --surface-2: #F4F5F6;
  --line: #DCDFE3;
  --line-2: #DCDFE3;
  --line-hover: #B9BEC5;
  --text: #111316;
  --text-2: #3E434A;
  --muted: #565B63;
  --faint: #6B7079;
  --on-accent: #111316;
  --accent-text: #4D5A00;
  --primary-bg: #111316;
  --primary-text: var(--accent);
  --selected: #111316;
  --selected-bg: #FFFFFF;
  --strip-bg: #111316;
  --strip-text: #F2F2F0;
  --eyebrow-bg: var(--accent);
  --tag-full-bg: var(--accent);  --tag-full-text: #111316;
  --tag-hy-bg: #111316;          --tag-hy-text: #FFFFFF;
  --weave-base: #E6E8EB;
  --weave-a: rgba(255, 255, 255, .55);
  --weave-b: rgba(0, 0, 0, .035);
  --shadow: 0 8px 24px rgba(17, 19, 22, .12);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Archivo', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent-text); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mono { font-family: 'JetBrains Mono', ui-monospace, monospace; }
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.weave {
  background-color: var(--weave-base);
  background-image:
    repeating-linear-gradient(45deg, var(--weave-a) 0 6px, transparent 6px 12px),
    repeating-linear-gradient(-45deg, var(--weave-b) 0 6px, transparent 6px 12px);
}

.display {
  font-weight: 800;
  font-stretch: 70%;
  text-transform: uppercase;
  line-height: 1;
  margin: 0;
}
.h2 { font-size: clamp(30px, 4vw, 40px); }
.eyebrow {
  align-self: flex-start;
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  letter-spacing: .08em;
  background: var(--eyebrow-bg);
  color: var(--accent-text);
  padding: 4px 8px;
  border-radius: 4px;
}
:root[data-theme="light"] .eyebrow { color: #111316; }
.label { font-size: 12px; font-weight: 700; letter-spacing: .08em; color: var(--muted); text-transform: uppercase; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 16px; border-radius: 8px; border: 1px solid transparent;
  font-weight: 700; font-size: 14px; cursor: pointer; white-space: nowrap;
}
.btn-primary { background: var(--primary-bg); color: var(--primary-text); letter-spacing: .04em; }
.btn-primary:hover { color: var(--primary-text); filter: brightness(1.08); }
.btn-ghost { background: transparent; border-color: var(--line-2); color: var(--text); }
.btn-ghost:hover { border-color: var(--line-hover); color: var(--text); }
.btn-wa { background: var(--wa); color: var(--on-wa); }
.btn-wa:hover { color: var(--on-wa); filter: brightness(1.05); }
.btn-lg { height: 56px; font-size: 16px; font-weight: 800; border-radius: 10px; }
.btn-icon { width: 44px; padding: 0; }
.chip {
  display: inline-flex; align-items: center; height: 40px; padding: 0 16px;
  border: 1px solid var(--line-2); border-radius: 999px; font-size: 14px; font-weight: 600;
  background: transparent; cursor: pointer;
}
.chip[aria-pressed="true"], .chip.is-active { border-color: var(--selected); color: var(--text); background: var(--selected-bg); }

/* ---------- Header ---------- */
.strip {
  background: var(--strip-bg); color: var(--strip-text);
  font-size: 13px; font-weight: 600; padding: 8px 16px;
  display: flex; justify-content: center; gap: 24px; flex-wrap: wrap; text-align: center;
}
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 20; }
:root[data-theme="dark"] .site-header { background: rgba(12, 13, 15, .92); backdrop-filter: blur(8px); }
.site-header .container { display: flex; align-items: center; gap: 28px; padding-top: 14px; padding-bottom: 14px; }
.logo { display: flex; align-items: baseline; gap: 6px; font-size: 26px; font-stretch: 70%; }
.logo b { font-weight: 800; }
.logo span { font-weight: 400; letter-spacing: .18em; color: var(--muted); }
.main-nav { display: flex; gap: 22px; font-size: 15px; font-weight: 500; flex: 1 1 auto; }
.header-actions { display: flex; gap: 10px; align-items: center; }
.search {
  display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px;
  background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 8px;
}
.search input { background: transparent; border: 0; outline: none; width: 180px; font-size: 14px; }
.menu-btn { display: none; }

@media (max-width: 980px) {
  .site-header .container { flex-wrap: wrap; gap: 12px; }
  .menu-btn { display: inline-flex; }
  .main-nav { order: 10; flex-basis: 100%; flex-direction: column; gap: 0; display: none; }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 0; border-top: 1px solid var(--line); }
  .logo { flex: 1 1 auto; font-size: 22px; }
  .header-actions { gap: 6px; }
  .header-actions .search { display: none; }
  .header-actions .btn-wa .txt { display: none; }
  .header-actions .btn-wa { width: 44px; padding: 0; }
}

/* ---------- Hero ---------- */
.hero { border-bottom: 1px solid var(--line); }
.hero .container { padding-top: 72px; padding-bottom: 64px; display: flex; flex-direction: column; gap: 32px; }
.hero-copy { display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.hero h1 { font-size: clamp(44px, 7vw, 88px); line-height: .95; font-stretch: 68%; }
.hero p { margin: 0; font-size: 18px; color: var(--text-2); max-width: 560px; }

.fitment-form {
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 12px; padding: 16px;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; align-items: end;
  max-width: 980px; box-shadow: var(--shadow);
}
.field { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: .06em; }
.field select, .field input {
  height: 48px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface-2);
  font-size: 15px; padding: 0 12px; letter-spacing: 0; font-weight: 400; color: var(--text);
}
.fitment-form .btn { height: 48px; font-size: 15px; font-weight: 800; }

/* ---------- Sections ---------- */
.section { padding-top: 64px; padding-bottom: 64px; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.band { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.brand-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; padding-top: 20px; padding-bottom: 20px; }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.cat-card {
  display: flex; flex-direction: column; justify-content: space-between; height: 140px; padding: 16px;
  border: 1px solid var(--line); border-radius: 12px;
}
.cat-card:hover { border-color: var(--line-hover); color: var(--text); }
.cat-card .n { font-size: 12px; color: var(--muted); }
.cat-card .t { font-size: 20px; font-weight: 700; font-stretch: 80%; text-transform: uppercase; }

/* ---------- Product cards ---------- */
.grid-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.card {
  display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 12px;
  overflow: hidden; background: var(--surface);
}
.card:hover { border-color: var(--line-hover); color: var(--text); }
.card .ph { position: relative; aspect-ratio: 4 / 3; display: flex; align-items: center; justify-content: center; }
.card .ph img { width: 100%; height: 100%; object-fit: cover; }
.card .ph .empty { font-size: 12px; color: var(--faint); }
.tag { position: absolute; top: 12px; left: 12px; font-size: 11px; font-weight: 700; letter-spacing: .06em; padding: 4px 8px; border-radius: 4px; }
.tag-full { background: var(--tag-full-bg); color: var(--tag-full-text); }
.tag-hybrid { background: var(--tag-hy-bg); color: var(--tag-hy-text); }
.card .body { padding: 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card .fit { font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: .04em; }
.card .name { font-size: 17px; font-weight: 700; line-height: 1.25; }
.card .sku { font-size: 11px; color: var(--faint); }
.card .foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: auto; padding-top: 8px; }
.card .price { font-size: 17px; font-weight: 800; }
.card .fin { font-size: 12px; color: var(--muted); }
.stock-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.stock-dot::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--wa); }

/* ---------- Tiers / steps ---------- */
.tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.tier { border-radius: 12px; padding: 24px; display: flex; flex-direction: column; gap: 12px; border: 1px solid var(--line); }
.tier ul { margin: 0; padding-left: 18px; color: var(--text-2); line-height: 1.8; font-size: 15px; }
.tier .big { font-size: 24px; font-weight: 800; font-stretch: 80%; }
.tier-dark { border-color: var(--line-hover); }
:root[data-theme="light"] .tier-dark { background: #111316; color: #F2F2F0; border-color: #111316; }
:root[data-theme="light"] .tier-dark ul { color: #C4C7CC; }
.tier-dark .label { color: var(--accent); }
:root[data-theme="dark"] .tier-dark .label { color: var(--accent); }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.step { border-top: 3px solid var(--selected); padding-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.step .n { align-self: flex-start; font-size: 13px; background: var(--accent); color: var(--on-accent); padding: 2px 6px; border-radius: 4px; }
.step .t { font-size: 20px; font-weight: 700; }
.step p { margin: 0; color: var(--text-2); font-size: 15px; }

.ship-band .container { padding-top: 48px; padding-bottom: 48px; display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.ship-band p { margin: 8px 0 0; color: var(--text-2); max-width: 640px; }
:root[data-theme="light"] .ship-band { background: #111316; color: #F2F2F0; background-image: none; }
:root[data-theme="light"] .ship-band p { color: #C4C7CC; }
.ship-band .hl { color: var(--accent); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); }
.site-footer .container { padding-top: 40px; padding-bottom: 40px; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; font-size: 14px; color: var(--muted); }
.site-footer .col { display: flex; flex-direction: column; gap: 8px; }
.site-footer .col b { color: var(--text); }
.site-footer .logo-txt { font-size: 22px; font-weight: 800; font-stretch: 70%; color: var(--text); letter-spacing: .04em; }

.wa-float {
  position: fixed; right: 20px; bottom: 20px; width: 60px; height: 60px; border-radius: 999px;
  background: var(--wa); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow); z-index: 30;
}

/* ---------- Shop ---------- */
.breadcrumb { font-size: 13px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); }
.shop-layout { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-start; padding-top: 32px; padding-bottom: 64px; }
.filters { flex: 1 1 240px; max-width: 280px; display: flex; flex-direction: column; gap: 20px; }
.filters .group { display: flex; flex-direction: column; gap: 8px; }
.filters .opt { display: flex; align-items: center; gap: 10px; min-height: 36px; font-size: 15px; cursor: pointer; }
.filters .opt input { width: 18px; height: 18px; accent-color: var(--accent); }
.shop-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.result-meta { color: var(--muted); font-size: 14px; }
.pagination { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.pagination a, .pagination span { min-width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line-2); border-radius: 8px; font-weight: 600; }
.pagination .cur { border-color: var(--selected); background: var(--selected-bg); }
.empty-state { border: 1px dashed var(--line-2); border-radius: 12px; padding: 40px 24px; text-align: center; color: var(--text-2); }
.filter-summary { display: none; width: 100%; list-style: none; }
.filter-summary::-webkit-details-marker { display: none; }
@media (max-width: 820px) {
  .filters { max-width: none; }
  .filter-summary { display: flex; }
  .filter-box[open] .filter-summary { margin-bottom: 16px; }
}
@media (max-width: 600px) { .strip span + span { display: none; } }

/* ---------- Product page ---------- */
.pdp { display: flex; flex-wrap: wrap; gap: 40px; padding: 32px 0 40px; }
.gallery { flex: 1 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.gallery .main { aspect-ratio: 4 / 3; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; display: flex; align-items: center; justify-content: center; position: relative; }
.gallery .main img { width: 100%; height: 100%; object-fit: contain; background: var(--surface); }
.gallery .count { position: absolute; bottom: 12px; right: 12px; font-size: 12px; background: var(--bg); padding: 4px 8px; border-radius: 4px; color: var(--muted); }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 8px; }
.thumbs button { aspect-ratio: 1 / 1; border-radius: 8px; border: 2px solid var(--line); padding: 0; overflow: hidden; cursor: pointer; background: var(--surface); }
.thumbs button[aria-current="true"] { border-color: var(--selected); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }

.buybox { flex: 1 1 400px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.buybox h1 { font-size: clamp(36px, 5vw, 48px); }
.buybox .price { font-size: 32px; font-weight: 800; }
.buybox .price-note { font-size: 13px; color: var(--muted); }
.opt-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.opt-card {
  min-height: 64px; text-align: left; padding: 12px 14px; border-radius: 10px; border: 2px solid var(--line-2);
  background: var(--surface); cursor: pointer; display: flex; flex-direction: column; gap: 4px;
}
.opt-card .n { font-size: 15px; font-weight: 700; }
.opt-card .d { font-size: 12px; color: var(--muted); }
.opt-card[aria-pressed="true"] { border-color: var(--selected); background: var(--selected-bg); }
.opt-card:disabled { opacity: .45; cursor: not-allowed; }
.pill { height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: 14px; font-weight: 700; cursor: pointer; }
.pill[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); border-color: var(--selected); }
.pill:disabled { opacity: .45; cursor: not-allowed; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
legend { padding: 0; margin-bottom: 8px; }
.info-box { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-size: 14px; color: var(--text-2); }
.info-box b { color: var(--text); }
.wa-preview { border: 1px dashed var(--line-2); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; }
.wa-preview pre { margin: 0; font-family: 'JetBrains Mono', monospace; font-size: 12px; color: var(--muted); white-space: pre-wrap; word-break: break-word; line-height: 1.6; }

.details { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; padding-bottom: 48px; }
.panel { border: 1px solid var(--line); border-radius: 12px; padding: 24px; background: var(--surface); }
.panel h2 { font-size: 22px; font-stretch: 75%; margin-bottom: 12px; }
.panel .prose { color: var(--text-2); line-height: 1.65; font-size: 15px; white-space: pre-line; }
.kv { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--muted); }
.kv span:last-child { text-align: right; }
.hint { font-size: 13px; color: var(--muted); margin-top: 8px; }

/* ---------- Theme toggle icon ---------- */
.theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }
:root[data-theme="dark"] .theme-toggle .moon { display: none; }
