:root {
  --ink: #17212b;
  --muted: #60707d;
  --line: #dce4ea;
  --page: #f4f7f8;
  --panel: #ffffff;
  --brand: #08766d;
  --brand-dark: #075d56;
  --soft: #e6f3f1;
  --warm: #fff4e7;
  --shadow: 0 18px 44px rgba(23, 33, 43, .09);
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--page); font-family: Arial, Helvetica, sans-serif; line-height: 1.45; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
.wrap { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.topbar { background: #111820; color: #e8eef2; font-size: 14px; }
.topbar .wrap, .header .wrap, .nav .wrap { min-height: 46px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.header { background: #fff; border-bottom: 1px solid var(--line); }
.header .wrap { min-height: 78px; }
.logo { display: flex; align-items: center; gap: 11px; font-size: 23px; font-weight: 900; }
.logo-mark { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 8px; background: var(--brand); color: white; }
.nav { background: white; border-bottom: 1px solid var(--line); }
.nav-links { display: flex; flex-wrap: wrap; gap: 4px; }
.nav a { padding: 11px 12px; border-radius: 7px; color: var(--muted); font-size: 14px; font-weight: 800; }
.nav a:hover, .nav a.active { background: var(--soft); color: var(--brand-dark); }
.hero { color: white; background: linear-gradient(90deg, rgba(17,24,32,.94), rgba(17,24,32,.68)), url("https://images.unsplash.com/photo-1556911220-bff31c812dba?auto=format&fit=crop&w=1800&q=80") center/cover; }
.hero .wrap { min-height: 360px; display: grid; grid-template-columns: minmax(0, 1fr) 370px; align-items: center; gap: 34px; padding: 38px 0; }
h1 { margin: 0 0 14px; font-size: clamp(38px, 5vw, 64px); line-height: 1; letter-spacing: 0; }
.hero p { max-width: 680px; color: #d9e3e8; font-size: 18px; }
.btn { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; padding: 0 16px; border: 0; border-radius: 8px; background: var(--brand); color: white; font-weight: 900; cursor: pointer; }
.btn.secondary { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.35); }
.danger { background: #b42318; }
.muted { background: #667085; }
main { padding: 30px 0 54px; }
.grid { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 18px; align-items: start; }
.panel { background: white; border: 1px solid var(--line); border-radius: 8px; padding: 16px; }
.panel h2, .panel h3 { margin: 0 0 13px; }
.field { display: grid; gap: 6px; margin-bottom: 11px; }
.field label { color: var(--muted); font-size: 13px; font-weight: 800; }
.field input, .field select, .field textarea { width: 100%; min-width: 0; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink); padding: 10px; outline-color: var(--brand); }
.field textarea { min-height: 78px; resize: vertical; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check-grid { display: grid; gap: 8px; margin: 2px 0 12px; }
.check-grid label { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 14px; }
.hint, .meta { color: var(--muted); font-size: 13px; }
.commission-box { display: grid; gap: 8px; margin: 12px 0; padding: 14px; border: 1px solid #badbd6; border-radius: 8px; background: var(--soft); }
.commission-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.commission-row strong { font-size: 19px; }
.filters { display: grid; grid-template-columns: minmax(180px, 1fr) 180px 140px auto; gap: 10px; margin-bottom: 14px; }
.filters input, .filters select { height: 42px; border: 1px solid var(--line); border-radius: 7px; padding: 0 10px; background: white; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.product { min-width: 0; display: grid; grid-template-rows: 160px 1fr; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: white; }
.product-media { position: relative; background: #eef3f5; overflow: hidden; }
.product-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.placeholder { height: 100%; display: grid; place-items: center; color: var(--muted); font-weight: 900; text-align: center; padding: 16px; }
.label { position: absolute; top: 10px; left: 10px; padding: 5px 8px; border-radius: 6px; background: var(--warm); color: #8a3d0a; font-size: 12px; font-weight: 900; }
.product-body { display: grid; gap: 8px; padding: 13px; }
.code { color: var(--muted); font-size: 13px; }
.product h3 { margin: 0; font-size: 17px; line-height: 1.25; }
.buy-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 3px; }
.price { font-size: 21px; font-weight: 900; }
.mini-btn { min-width: 92px; height: 38px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 8px; background: var(--brand); color: white; font-weight: 800; }
.notice { margin-bottom: 14px; padding: 12px 14px; border-radius: 8px; background: var(--soft); color: var(--brand-dark); }
.admin-table { width: 100%; border-collapse: collapse; background: white; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.admin-table th, .admin-table td { padding: 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; font-size: 14px; }
.admin-table th { background: #eef3f5; }
.actions { display: flex; flex-wrap: wrap; gap: 6px; }
.small { min-height: 34px; padding: 0 10px; font-size: 13px; }
.table-scroll { overflow-x: auto; }
footer { padding: 26px 0; border-top: 1px solid var(--line); background: white; color: var(--muted); }
footer .wrap { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
@media (max-width: 1020px) {
  .hero .wrap, .grid { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .wrap { width: min(100% - 24px, 1180px); }
  .topbar .wrap, .header .wrap, .nav .wrap, footer .wrap { align-items: flex-start; flex-direction: column; padding: 10px 0; }
  .filters, .two, .product-grid { grid-template-columns: 1fr; }
  .product { grid-template-rows: 188px 1fr; }
}
