:root {
  --bg: #120f0e;
  --card: #1e1a18;
  --card2: #282220;
  --line: #3a312d;
  --text: #f4ece6;
  --muted: #b3a59c;
  --red: #c8281e;
  --red2: #e2392d;
  --gold: #f2b233;
  --green: #2e9e5b;
  --radius: 14px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.45;
  -webkit-tap-highlight-color: transparent;
}
a { color: var(--gold); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.gold { color: var(--gold); }
.hidden { display: none !important; }

/* Üst çubuk */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(18, 15, 14, .94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 58px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: .5px; color: var(--text); text-decoration: none; font-size: 19px; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.brand span b { color: var(--gold); }

/* Butonlar */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 12px; padding: 12px 18px;
  font: inherit; font-weight: 700; cursor: pointer; text-decoration: none;
  background: var(--card2); color: var(--text);
  min-height: 46px;
}
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--red); color: #fff; }
.btn.primary:active { background: var(--red2); }
.btn.gold { background: var(--gold); color: #1a1200; }
.btn.green { background: var(--green); color: #fff; }
.btn.ghost { background: transparent; border: 1px solid var(--line); }
.btn.block { width: 100%; }
.btn.sm { min-height: 36px; padding: 6px 12px; font-size: 14px; border-radius: 10px; }

/* Kartlar */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.stack > * + * { margin-top: 12px; }

/* Form */
label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 15px; }
input, textarea, select {
  width: 100%; font: inherit; color: var(--text);
  background: var(--card2); border: 1px solid var(--line); border-radius: 10px;
  padding: 12px; min-height: 46px;
}
input:focus, textarea:focus, select:focus { outline: 2px solid var(--gold); outline-offset: 0; border-color: transparent; }
textarea { min-height: 80px; resize: vertical; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 14px; }
.check input { width: 22px; height: 22px; min-height: 0; margin: 0; flex: none; accent-color: var(--red); }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.seg input { display: none; }
.seg label { margin: 0; text-align: center; padding: 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--card2); cursor: pointer; }
.seg input:checked + label { border-color: var(--gold); color: var(--gold); }

/* Menü */
.cat-nav { display: flex; gap: 8px; overflow-x: auto; padding: 10px 0; scrollbar-width: none; }
.cat-nav::-webkit-scrollbar { display: none; }
.cat-nav a { flex: none; padding: 8px 14px; border-radius: 999px; background: var(--card2); color: var(--text); text-decoration: none; font-size: 14px; font-weight: 600; white-space: nowrap; }
.cat-nav a.on { background: var(--red); }
.cat-title { margin: 26px 0 10px; font-size: 20px; color: var(--gold); text-transform: uppercase; letter-spacing: 1px; scroll-margin-top: 120px; }
.item { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.item:last-child { border-bottom: 0; }
.item .info { flex: 1; min-width: 0; }
.item .name { font-weight: 700; }
.item .desc { color: var(--muted); font-size: 14px; }
.item .price { font-weight: 800; color: var(--gold); white-space: nowrap; }
.item.soldout { opacity: .45; }
.item .thumb { width: 104px; height: 78px; flex: none; border-radius: 12px; object-fit: cover; background: var(--card2); display: block; }
@media (min-width: 640px) { .item .thumb { width: 132px; height: 99px; } }
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--card2); color: var(--muted); }
.badge.red { background: var(--red); color: #fff; }
.badge.gold { background: var(--gold); color: #1a1200; }
.badge.green { background: var(--green); color: #fff; }

.qty { display: flex; align-items: center; gap: 6px; }
.qty button { width: 38px; height: 38px; border-radius: 10px; border: 0; background: var(--card2); color: var(--text); font-size: 22px; font-weight: 700; cursor: pointer; }
.qty button.add { background: var(--red); color: #fff; }
.qty span { min-width: 22px; text-align: center; font-weight: 800; }

/* Alt sepet çubuğu */
.cartbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: linear-gradient(to top, var(--bg) 70%, transparent);
}
.cartbar .btn { max-width: 728px; margin: 0 auto; display: flex; width: 100%; justify-content: space-between; }

/* Kapalı uyarısı */
.notice { background: #3a1a12; border: 1px solid #6b2a1c; color: #ffd5c7; border-radius: 12px; padding: 12px 14px; font-size: 15px; }
.ok-notice { background: #13301f; border: 1px solid #22573a; color: #c9f2d8; border-radius: 12px; padding: 12px 14px; }

/* Panel tablosu */
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.stat .v { font-size: 22px; font-weight: 800; }
.stat .l { color: var(--muted); font-size: 13px; }
.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin-bottom: 14px; overflow-x: auto; }
.tabs button { background: none; border: 0; color: var(--muted); font: inherit; font-weight: 700; padding: 12px 14px; cursor: pointer; border-bottom: 3px solid transparent; white-space: nowrap; }
.tabs button.on { color: var(--text); border-bottom-color: var(--red); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 10px 6px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; font-size: 13px; }
td.num, th.num { text-align: right; white-space: nowrap; }
.pos { color: #57d38c; }
.neg { color: #ff7a6b; }

.toast {
  position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%);
  background: #000; color: #fff; padding: 12px 18px; border-radius: 12px; z-index: 100;
  box-shadow: 0 6px 24px rgba(0,0,0,.5); max-width: 90vw; text-align: center;
}

footer.site { border-top: 1px solid var(--line); margin-top: 40px; padding: 24px 0 120px; color: var(--muted); font-size: 14px; }
