:root{
  /* Яркая, тёплая “менюшная” палитра */
  --bg: #fff7ed;          /* тёплый кремовый */
  --card: #ffffff;
  --text: #1f2937;        /* почти чёрный */
  --muted: #6b7280;

  --accent: #f97316;      /* оранжевый */
  --accent2: #22c55e;     /* зелёный */
  --accent3: #06b6d4;     /* бирюзовый */

  --line: #fde68a;        /* мягкая линия */
  --shadow: 0 12px 30px rgba(31,41,55,.12);
}

*{ box-sizing:border-box; }

body{
  margin:0;
  background:
    radial-gradient(900px 600px at 15% -10%, rgba(249,115,22,0.22), transparent 60%),
    radial-gradient(800px 500px at 90% 0%, rgba(34,197,94,0.18), transparent 60%),
    radial-gradient(700px 500px at 60% 110%, rgba(6,182,212,0.14), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
}

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

.container{ width:min(1100px, calc(100% - 32px)); margin:0 auto; }

/* === ШАПКА: теперь НЕ sticky === */
.topbar{
  border-bottom: 1px solid rgba(249,115,22,0.25);
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(10px);
  position: relative; /* было sticky */
  top: auto;
  z-index: 10;
}

.topbar-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 12px 0;
  gap: 14px;
}

.brand{ display:flex; align-items:center; gap: 10px; }
.brand-title{
  font-weight: 900;
  letter-spacing: .2px;
  font-size: 18px;
  padding: 8px 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(249,115,22,0.18), rgba(34,197,94,0.14));
  border: 1px solid rgba(249,115,22,0.25);
}

.nav{ display:flex; gap: 14px; }
.nav a{
  color: var(--muted);
  font-weight: 700;
}
.nav a:hover{ color: var(--text); text-decoration:none; }

.hero{ padding: 20px 0 10px; }
.hero-row{ display:flex; align-items:flex-start; justify-content:space-between; gap: 16px; }
h1{ margin:0 0 8px; font-size: 34px; }
h2{ margin:0 0 12px; font-size: 22px; }
h3{ margin:0 0 10px; font-size: 16px; }

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

.btn{
  background: rgba(249,115,22,0.15);
  border: 1px solid rgba(249,115,22,0.30);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 14px;
  cursor:pointer;
  font-weight: 800;
}
.btn:hover{ filter: brightness(1.02); }
.btn-primary{
  background: linear-gradient(90deg, rgba(249,115,22,0.85), rgba(34,197,94,0.78));
  border-color: rgba(249,115,22,0.35);
  color: #ffffff;
}
.btn-primary:hover{ filter: brightness(1.05); }
.btn-danger{
  background: rgba(239,68,68,0.14);
  border-color: rgba(239,68,68,0.30);
}
.btn-danger:hover{ background: rgba(239,68,68,0.18); }

.card{
  background: rgba(255,255,255,0.88);
  border: 1px solid rgba(31,41,55,0.10);
  border-radius: 18px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.item{
  border-radius: 18px;
  padding: 14px;
  border: 1px solid rgba(31,41,55,0.10);
  background: rgba(255,255,255,0.92);
  display:flex;
  flex-direction:column;
  gap: 10px;
  box-shadow: var(--shadow);
}

.bright-item{
  border-top: 4px solid rgba(249,115,22,0.55);
}

.item .title{ font-weight: 900; font-size: 16px; }
.item .desc{ color: var(--muted); font-size: 13px; line-height: 1.35; }
.item .meta{ display:flex; align-items:center; justify-content:space-between; gap: 10px; }

.badge{
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(34,197,94,0.30);
  color: #166534;
  background: rgba(34,197,94,0.10);
  font-weight: 800;
}
.price{ font-weight: 1000; }

.thumb{
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  border: 1px solid rgba(31,41,55,0.10);
  overflow:hidden;
  background: rgba(255,255,255,0.7);
}
.thumb img{ width:100%; height:100%; object-fit: cover; display:block; }

.footer{
  padding: 24px 0;
  border-top: 1px solid rgba(249,115,22,0.18);
  color: var(--muted);
  background: rgba(255,255,255,0.55);
}

/* admin layout */
.two-col{
  display:grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 14px;
  margin-bottom: 24px;
}
@media (max-width: 920px){
  .two-col{ grid-template-columns: 1fr; }
}

.row{ display:flex; gap: 12px; flex-wrap: wrap; }
.row > .field{ min-width: 240px; flex: 1; }

.field{ display:flex; flex-direction:column; gap: 6px; min-width: 240px; }

label{ font-size: 12px; color: var(--muted); font-weight: 700; }

input, select, textarea{
  background: rgba(255,255,255,0.95);
  border: 1px solid rgba(31,41,55,0.12);
  color: var(--text);
  border-radius: 14px;
  padding: 10px 12px;
  outline: none;
}
input:focus, select:focus, textarea:focus{
  border-color: rgba(249,115,22,0.55);
  box-shadow: 0 0 0 4px rgba(249,115,22,0.12);
}

.form{ display:flex; flex-direction:column; gap: 10px; }
.form-inline{ display:flex; gap: 10px; align-items:flex-end; }

.sep{ border:0; border-top: 1px solid rgba(31,41,55,0.10); margin: 14px 0; }

.list{ display:flex; flex-direction:column; gap: 10px; margin-top: 12px; }

.list-row{
  display:flex;
  gap: 10px;
  align-items:flex-start;
  justify-content:space-between;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(31,41,55,0.10);
  background: rgba(255,255,255,0.9);
  box-shadow: var(--shadow);
}
.list-row .left{ display:flex; flex-direction:column; gap: 4px; }
.list-row .right{ display:flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.small{ font-size: 12px; color: var(--muted); }

.alert{
  background: rgba(239,68,68,0.10);
  border: 1px solid rgba(239,68,68,0.25);
  padding: 10px 12px;
  border-radius: 14px;
}

.ok{
  background: rgba(34,197,94,0.10);
  border: 1px solid rgba(34,197,94,0.22);
  padding: 10px 12px;
  border-radius: 14px;
}

/* === Панель категорий: sticky всегда сверху окна === */
.category-bar-wrap{
  position: sticky;
  top: 0;          /* было 64px, теперь липнет к самому верху */
  z-index: 50;     /* выше контента */
  padding: 10px 0;
}

.category-bar{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(6,182,212,0.20);
  box-shadow: var(--shadow);
}

.cat-pill{
  border: 1px solid rgba(249,115,22,0.28);
  background: rgba(249,115,22,0.12);
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 900;
  color: #9a3412;
}
.cat-pill:hover{ filter: brightness(1.03); }
.cat-pill.active{
  background: linear-gradient(90deg, rgba(249,115,22,0.85), rgba(6,182,212,0.70));
  color: #ffffff;
  border-color: rgba(249,115,22,0.35);
}

.menu-sections{
  padding-bottom: 10px;
}

.menu-section{
  scroll-margin-top: 110px; /* чтобы якорь не прятался под липкой панелью */
  margin: 14px 0 18px;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(31,41,55,0.10);
  background: rgba(255,255,255,0.70);
  box-shadow: var(--shadow);
}

.section-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.empty-note{
  color: var(--muted);
  font-weight: 700;
  padding: 10px 6px;
}

.preview-wrap{
  margin-top: 10px;
}

.preview{
  margin-top: 8px;
  width: 100%;
  max-width: 420px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(31,41,55,0.10);
  box-shadow: var(--shadow);
  background: rgba(255,255,255,0.9);
}
.preview img{
  width: 100%;
  display:block;
}
