/* PCFIXER — Premium light, warm off-white, mint accent */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --bg: #fafaf8;
  --bg-elev: #ffffff;
  --bg-sunken: #f3f3f0;
  --line: #e8e7e2;
  --line-strong: #d6d5cf;
  --ink: #0a0a0a;
  --ink-2: #2a2a2a;
  --ink-3: #6b6b68;
  --ink-4: #9a9a95;
  --accent: oklch(0.78 0.18 165);
  --accent-ink: oklch(0.28 0.08 165);
  --accent-soft: oklch(0.95 0.05 165);
  --danger: #c2410c;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-sm: 6px;
  --shadow-sm: 0 1px 2px rgba(10,10,10,0.04), 0 0 0 1px rgba(10,10,10,0.04);
  --shadow-md: 0 4px 20px -8px rgba(10,10,10,0.12), 0 0 0 1px rgba(10,10,10,0.05);
  --shadow-lg: 0 20px 60px -20px rgba(10,10,10,0.18), 0 0 0 1px rgba(10,10,10,0.05);
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;
}

[data-theme="dark"] {
  --bg: #0b0b0c;
  --bg-elev: #141416;
  --bg-sunken: #050506;
  --line: #222225;
  --line-strong: #2e2e32;
  --ink: #f5f5f3;
  --ink-2: #e5e5e2;
  --ink-3: #9a9a95;
  --ink-4: #6b6b68;
  --accent: oklch(0.82 0.18 165);
  --accent-ink: #0b0b0c;
  --accent-soft: oklch(0.28 0.08 165);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,255,255,0.04);
  --shadow-md: 0 4px 20px -8px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.05);
  --shadow-lg: 0 20px 60px -20px rgba(0,0,0,0.7), 0 0 0 1px rgba(255,255,255,0.06);
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv11', 'ss01';
  line-height: 1.5;
}
body { min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font-family: inherit; color: inherit; }
img { max-width: 100%; display: block; }

/* ============ LAYOUT ============ */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.container-wide { max-width: 1400px; margin: 0 auto; padding: 0 24px; }

/* ============ TOPBAR ============ */
.topbar {
  background: var(--ink);
  color: #fafaf8;
  font-size: 12.5px;
  letter-spacing: 0.01em;
}
[data-theme="dark"] .topbar { background: #000; }
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 36px;
}
.topbar-left { display: flex; gap: 20px; align-items: center; }
.topbar-right { display: flex; gap: 16px; align-items: center; }
.topbar .dot { width: 6px; height: 6px; background: var(--accent); border-radius: 50%; display: inline-block; margin-right: 6px; }
.topbar a:hover { color: var(--accent); }

/* ============ NAV ============ */
.nav {
  background: var(--bg-elev);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(8px);
}
.nav-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 32px;
  align-items: center;
  height: 72px;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 20px;
  letter-spacing: -0.02em;
}
.logo-mark {
  width: 32px; height: 32px; border-radius: 8px;
  background: var(--ink);
  color: var(--accent);
  display: grid; place-items: center;
  font-weight: 800;
  font-size: 16px;
  font-family: var(--mono);
}
.logo-mark::before { content: '>'; }
.logo sup { color: var(--accent); font-size: 10px; margin-left: 2px; }

.search {
  position: relative; display: flex; align-items: center;
  background: var(--bg-sunken);
  border: 1px solid var(--line);
  border-radius: 10px;
  height: 44px;
  padding: 0 14px;
  transition: all 0.15s;
}
.search:focus-within { border-color: var(--ink-3); background: var(--bg-elev); }
.search svg { flex-shrink: 0; color: var(--ink-3); }
.search input {
  flex: 1; border: none; background: none; outline: none;
  font-size: 14px; padding: 0 12px;
}
.search input::placeholder { color: var(--ink-3); }
.search kbd {
  font-family: var(--mono);
  font-size: 11px;
  padding: 2px 6px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--ink-3);
}

.nav-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  position: relative;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 10px;
  color: var(--ink-2);
  transition: all 0.15s;
}
.icon-btn:hover { background: var(--bg-sunken); }
.icon-btn .badge {
  position: absolute; top: 6px; right: 6px;
  min-width: 18px; height: 18px; padding: 0 5px;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: 9px;
  font-size: 10.5px; font-weight: 700;
  display: grid; place-items: center;
}

.nav-menu {
  background: var(--bg-elev);
  border-bottom: 1px solid var(--line);
}
.nav-menu-inner {
  display: flex;
  gap: 28px;
  height: 48px;
  align-items: center;
  font-size: 14px;
  font-weight: 500;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-menu-inner::-webkit-scrollbar { display: none; }
.nav-menu a {
  color: var(--ink-2);
  white-space: nowrap;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s;
  display: flex; align-items: center; gap: 6px;
}
.nav-menu a:hover { color: var(--ink); }
.nav-menu a.active { color: var(--ink); border-bottom-color: var(--accent); }
.nav-menu .pill {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: 3px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 0 20px;
  height: 48px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14.5px;
  letter-spacing: -0.005em;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn-primary {
  background: var(--ink);
  color: var(--bg);
}
.btn-primary:hover { background: var(--ink-2); transform: translateY(-1px); }
.btn-accent {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-accent:hover { filter: brightness(0.95); transform: translateY(-1px); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line-strong);
}
.btn-ghost:hover { background: var(--bg-sunken); border-color: var(--ink-3); }
.btn-sm { height: 36px; padding: 0 14px; font-size: 13px; border-radius: 8px; }
.btn-lg { height: 56px; padding: 0 28px; font-size: 16px; }
.btn-block { width: 100%; }

/* ============ TYPE ============ */
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  display: inline-flex; align-items: center; gap: 8px;
}
.eyebrow::before {
  content: ''; width: 6px; height: 6px; background: var(--accent); border-radius: 50%;
}
h1, h2, h3, h4 { letter-spacing: -0.025em; margin: 0; line-height: 1.1; font-weight: 700; }
h1 { font-size: clamp(40px, 5vw, 64px); font-weight: 800; letter-spacing: -0.035em; }
h2 { font-size: clamp(28px, 3vw, 40px); }
h3 { font-size: 20px; }
.lead { font-size: 18px; color: var(--ink-3); line-height: 1.5; max-width: 60ch; }

section { padding: 80px 0; }
.section-head {
  display: flex; align-items: end; justify-content: space-between;
  gap: 32px; margin-bottom: 40px; flex-wrap: wrap;
}
.section-head h2 { max-width: 18ch; }
.section-head p { margin: 12px 0 0; color: var(--ink-3); max-width: 50ch; }

/* ============ CARDS ============ */
.card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* product card */
.product-card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  transition: all 0.2s;
  overflow: hidden;
  display: flex; flex-direction: column;
  cursor: pointer;
}
.product-card:hover { border-color: var(--ink-3); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.product-card .media {
  aspect-ratio: 4 / 3;
  background: var(--bg-sunken);
  position: relative;
  display: grid; place-items: center;
  overflow: hidden;
}
.product-card .badges {
  position: absolute; top: 12px; left: 12px;
  display: flex; gap: 6px; flex-wrap: wrap;
}
.badge {
  font-size: 10.5px; font-weight: 700;
  padding: 4px 8px;
  border-radius: 4px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  background: var(--bg-elev);
  color: var(--ink);
  border: 1px solid var(--line);
}
.badge-accent { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.badge-danger { background: var(--danger); color: white; border-color: transparent; }
.badge-dark { background: var(--ink); color: var(--bg); border-color: transparent; }

.product-card .body { padding: 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.product-card .brand {
  font-size: 11px; font-weight: 600; color: var(--ink-3);
  text-transform: uppercase; letter-spacing: 0.06em;
}
.product-card .title {
  font-size: 15px; font-weight: 600; line-height: 1.35;
  color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.product-card .specs {
  display: flex; flex-wrap: wrap; gap: 4px 10px;
  font-size: 12px; color: var(--ink-3);
  font-family: var(--mono);
}
.product-card .price-row {
  display: flex; align-items: end; justify-content: space-between;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.product-card .price {
  font-size: 20px; font-weight: 700; letter-spacing: -0.02em;
}
.product-card .price-old {
  font-size: 12px; color: var(--ink-4); text-decoration: line-through;
  margin-right: 6px;
}
.product-card .stock {
  font-size: 11.5px; font-weight: 500; color: var(--ink-3);
  display: flex; align-items: center; gap: 5px;
}
.product-card .stock::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%; background: #16a34a;
}
.product-card .stock.low::before { background: #eab308; }

/* Placeholder image */
.ph {
  width: 100%; height: 100%;
  background-image:
    repeating-linear-gradient(45deg, transparent 0 8px, rgba(10,10,10,0.04) 8px 9px),
    linear-gradient(180deg, var(--bg-sunken), var(--bg));
  display: grid; place-items: center;
  color: var(--ink-4);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-align: center;
  padding: 20px;
}
[data-theme="dark"] .ph {
  background-image:
    repeating-linear-gradient(45deg, transparent 0 8px, rgba(255,255,255,0.03) 8px 9px),
    linear-gradient(180deg, var(--bg-sunken), var(--bg));
}
.ph-small { font-size: 9px; }

/* ============ FOOTER ============ */
footer {
  background: var(--ink);
  color: #dcdcd8;
  padding: 64px 0 24px;
  margin-top: 80px;
}
[data-theme="dark"] footer { background: #000; }
footer h4 { color: white; font-size: 13px; letter-spacing: 0.05em; text-transform: uppercase; margin-bottom: 18px; font-weight: 600; }
footer a { color: #a5a5a0; font-size: 14px; }
footer a:hover { color: white; }
footer .foot-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
footer .foot-bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px;
  padding-top: 24px;
  font-size: 12.5px;
  color: #85857f;
}

/* ============ UTILS ============ */
.row { display: flex; align-items: center; gap: 12px; }
.stack { display: flex; flex-direction: column; }
.grid { display: grid; gap: 16px; }
.hidden { display: none !important; }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--ink-4); }

/* Tweaks panel */
.tweaks-panel {
  position: fixed;
  bottom: 20px; right: 20px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  padding: 16px;
  z-index: 1000;
  min-width: 240px;
  font-size: 13px;
}
.tweaks-panel h4 {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--ink-3); margin: 0 0 12px;
}
.tweak-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.toggle {
  position: relative;
  width: 36px; height: 20px;
  background: var(--line-strong);
  border-radius: 10px;
  cursor: pointer; transition: background 0.2s;
}
.toggle.on { background: var(--accent); }
.toggle::after {
  content: ''; position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px; border-radius: 50%; background: white;
  transition: transform 0.2s;
}
.toggle.on::after { transform: translateX(16px); }

/* Mobile */
@media (max-width: 900px) {
  .nav-inner { grid-template-columns: auto auto; gap: 12px; }
  .search { display: none; }
  section { padding: 56px 0; }
  footer .foot-grid { grid-template-columns: 1fr 1fr; }
}
