/* ═══════════════════════════════════════════════════════════
   سينابونة CINABOONA — منيو رقمي (نسخة PHP للاستضافة المشتركة)
   ───────────────────────────────────────────────────────────
   واجهة الزبائن: ثيم داكن شبابي — أسود دافئ + بني كراميل
   مستوحى من لوغو رول القرفة، بخطي Lemonada للعناوين وTajawal للنصوص
   ───────────────────────────────────────────────────────────
   ملاحظة نظامية: جميع الفئات والمعرفات محفوظة كما هي لضمان عمل
   النظام (السلة، الطلب، الدفع، لوحة التحكم) دون أي تغيير.
   متغيرات :root تحفظ ثيم اللوحة الداكن كما هو، وثيم الموقع
   الجديد يُطبَّق عبر body.theme-bakery فقط — التغيير شكلي بحت.
   ═══════════════════════════════════════════════════════════ */

:root {
    --brand-black: #150d05;
    --brand-dark: #241508;
    --brand-gold: #e9a83b;
    --brand-gold-dark: #b57718;
    --brand-gold-light: #f7d27c;
    --background: #150d05;
    --foreground: #f8f0dd;
    --card: #1f1409;
    --secondary: #2b1b0c;
    --muted: #261809;
    --muted-fg: #b6a184;
    --border: rgba(233, 168, 59, 0.16);
    --border-soft: rgba(233, 168, 59, 0.10);
    --green: #4ade80;
    --red: #f87171;
    --radius: 16px;
    --font-display: 'El Messiri', 'Cairo', system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    font-family: 'Cairo', system-ui, -apple-system, 'Segoe UI', sans-serif;
    background-color: var(--background);
    background-image: radial-gradient(rgba(151, 121, 90, 0.06) 1.1px, transparent 1.4px);
    background-size: 26px 26px;
    color: var(--foreground);
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, textarea, select { font-family: inherit; font-size: 15px; }
a { color: inherit; text-decoration: none; }

/* ─── أدوات مساعدة ─── */
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.gold { color: var(--brand-gold); }
.dim { color: var(--muted-fg); }
.semibold { font-weight: 700; }
.no-scrollbar { scrollbar-width: none; }
.no-scrollbar::-webkit-scrollbar { display: none; }
.nice-scrollbar { scrollbar-width: thin; scrollbar-color: rgba(200,129,31,0.4) transparent; }
.nice-scrollbar::-webkit-scrollbar { width: 6px; }
.nice-scrollbar::-webkit-scrollbar-track { background: transparent; }
.nice-scrollbar::-webkit-scrollbar-thumb { background: rgba(200,129,31,0.35); border-radius: 99px; }
.nice-scrollbar::-webkit-scrollbar-thumb:hover { background: rgba(200,129,31,0.55); }

.ic { width: 18px; height: 18px; flex-shrink: 0; }
.ic.lg { width: 22px; height: 22px; }
.ic.xs { width: 12px; height: 12px; }
.ic.big { width: 40px; height: 40px; }
.ic.gold { color: var(--brand-gold); }

.t-gold {
    background: linear-gradient(105deg, #eaa53d, #c8811f 48%, #9c6210 90%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.gold-glow { box-shadow: 0 2px 22px rgba(200, 129, 31, 0.28); }

.fade-up { animation: fadeUp 0.5s ease-out both; animation-delay: var(--d, 0s); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ═══════════════════════════════════════════════════════════
   سينابونة CINABOONA — الثيم الجديد لواجهة الزبائن
   ───────────────────────────────────────────────────────────
   الهوية: حلويات قرفة شبابية — أسود دافئ + بني كراميل أساسي
   مستوحاة من اللوغو (رول القرفة + الكريمة + القلب الوردي)
   الخطوط: Lemonada للعناوين + Tajawal للنصوص
   ───────────────────────────────────────────────────────────
   ملاحظة نظامية: جميع الفئات والمعرفات محفوظة كما هي لضمان عمل
   النظام (السلة، الطلب، الدفع، لوحة التحكم) دون أي تغيير.
   قواعد لوحة التحكم تبقى كما هي عبر متغيرات :root الأصلية،
   وثيم الموقع يُطبَّق عبر body.theme-bakery فقط.
   ═══════════════════════════════════════════════════════════ */

/* ─── لوحة ألوان سينابونة — تُطبَّق على واجهة الزبائن فقط ─── */
body.theme-bakery {
    --brand-black: #0f0904;
    --brand-dark: #170e07;
    --brand-gold: #d18a3f;
    --brand-gold-dark: #9a6224;
    --brand-gold-light: #eec182;
    --background: #0f0904;
    --foreground: #f6ecda;
    --card: #1e1309;
    --secondary: #2a1b0d;
    --muted: #241609;
    --muted-fg: #b6a087;
    --border: rgba(209, 138, 63, 0.20);
    --border-soft: rgba(209, 138, 63, 0.11);
    --green: #4ade80;
    --red: #f87171;
    --radius: 18px;
    --font-display: 'Lemonada', 'Tajawal', system-ui, sans-serif;
    --brand-pink: #f085ab;
    --brand-pink-dark: #d95f88;
    --ink-on-gold: #1c1006;
}

body.theme-bakery {
    font-family: 'Tajawal', system-ui, -apple-system, 'Segoe UI', sans-serif;
    background-color: var(--background);
    background-image:
        radial-gradient(720px 340px at 85% -6%, rgba(209, 138, 63, 0.10), transparent 65%),
        radial-gradient(560px 300px at -10% 12%, rgba(240, 133, 171, 0.05), transparent 60%),
        radial-gradient(rgba(209, 138, 63, 0.05) 1.1px, transparent 1.4px);
    background-size: auto, auto, 26px 26px;
    background-attachment: fixed, fixed, fixed;
}

body.theme-bakery ::selection { background: rgba(209, 138, 63, 0.45); color: #fff8ec; }

/* ─── لمسات الهوية المشتركة (تتجاوز الأدوات العامة لواجهة الزبائن) ─── */
body.theme-bakery .t-gold {
    background: linear-gradient(105deg, #eec182, #d18a3f 48%, #9a6224 90%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
body.theme-bakery .gold-glow { box-shadow: 0 2px 24px rgba(209, 138, 63, 0.30); }
body.theme-bakery .nice-scrollbar { scrollbar-color: rgba(209,138,63,0.45) transparent; }
body.theme-bakery .nice-scrollbar::-webkit-scrollbar-thumb { background: rgba(209,138,63,0.40); }
body.theme-bakery .nice-scrollbar::-webkit-scrollbar-thumb:hover { background: rgba(209,138,63,0.60); }

/* ═══════════ قسم البطل — هيرو سينابونة الداكن ═══════════ */
.hero { position: relative; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; animation: heroZoom 20s ease-out both; }
@keyframes heroZoom { from { transform: scale(1.09); } to { transform: scale(1); } }
.hero-shade {
    position: absolute; inset: 0;
    background: rgba(15, 9, 4, 0.52);
}
.hero-shade::after {
    content: ''; position: absolute; inset: 0;
    background:
        radial-gradient(680px 320px at 50% 0%, rgba(209, 138, 63, 0.16), transparent 70%),
        linear-gradient(to bottom, rgba(15, 9, 4, 0.30) 0%, rgba(15, 9, 4, 0.55) 42%, rgba(15, 9, 4, 0.92) 78%, #0f0904 100%);
}

.hero-inner {
    position: relative;
    max-width: 660px; margin: 0 auto;
    display: flex; flex-direction: column; align-items: center; gap: 15px;
    padding: 48px 24px 62px; text-align: center;
    min-height: 88svh; justify-content: center;
}
@media (min-width: 640px) { .hero-inner { padding-top: 60px; min-height: 92svh; } }

/* الشعار: إطار زجاجي داكن بحلقة كراميل متوهجة + حركة طفو ناعمة */
.hero-logo-wrap { position: relative; display: inline-flex; padding: 6px; border-radius: 34px; }
.hero-logo-wrap::before {
    content: ''; position: absolute; inset: -12px; border-radius: 44px;
    border: 1.5px dashed rgba(209, 138, 63, 0.55);
    animation: haloSpin 14s linear infinite;
}
@keyframes haloSpin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.04); }
    100% { transform: rotate(360deg) scale(1); }
}
.hero-logo-wrap::after {
    content: ''; position: absolute; inset: 0; border-radius: 30px;
    background: radial-gradient(90px 60px at 50% 15%, rgba(238, 193, 130, 0.22), transparent 75%);
    pointer-events: none;
}
.hero-logo {
    width: 122px; height: 122px; border-radius: 28px; object-fit: cover;
    border: 3px solid rgba(238, 193, 130, 0.75);
    box-shadow:
        0 0 0 1px rgba(209, 138, 63, 0.35),
        0 18px 44px rgba(0, 0, 0, 0.55),
        0 0 34px rgba(209, 138, 63, 0.28);
    animation: logoFloat 4.5s ease-in-out infinite;
}
@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}
@media (min-width: 640px) { .hero-logo { width: 140px; height: 140px; border-radius: 32px; } }

/* اسم العلامة باللاتينية — سطر تعريفي من اللوغو */
.hero-latin {
    font-family: var(--font-display);
    font-size: 13px; font-weight: 700;
    letter-spacing: 7px; text-indent: 7px;
    color: var(--brand-gold-light);
    text-transform: uppercase;
    opacity: 0.95;
}
@media (min-width: 640px) { .hero-latin { font-size: 15px; letter-spacing: 9px; text-indent: 9px; } }

.status-badge {
    display: inline-flex; align-items: center; gap: 8px;
    border-radius: 999px; padding: 7px 16px;
    font-size: 12px; font-weight: 800;
    backdrop-filter: blur(8px);
}
@media (min-width: 640px) { .status-badge { font-size: 13px; } }
.status-badge.is-open {
    border: 1px solid rgba(74, 222, 128, 0.35);
    background: rgba(15, 26, 16, 0.62);
    color: #86efac;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35), inset 0 0 14px rgba(74, 222, 128, 0.06);
}
.status-badge.is-closed {
    border: 1px solid rgba(248, 113, 113, 0.32);
    background: rgba(30, 12, 10, 0.62);
    color: #fca5a5;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}
.dot-wrap { position: relative; display: flex; width: 8px; height: 8px; }
.status-badge .dot { position: relative; display: inline-flex; width: 8px; height: 8px; border-radius: 50%; }
.status-badge.is-open .dot { background: #4ade80; }
.status-badge.is-open .dot::after {
    content: ''; position: absolute; inset: 0; border-radius: 50%;
    background: #4ade80; opacity: 0.75; animation: ping 1.2s cubic-bezier(0,0,0.2,1) infinite;
}
.status-badge.is-closed .dot { background: var(--red); }
@keyframes ping { 75%, 100% { transform: scale(2.2); opacity: 0; } }

/* فاصل زخرفي بمعيّن مركزي */
.hero-ornament {
    display: flex; align-items: center; gap: 10px;
    width: min(320px, 72vw); color: var(--brand-gold);
}
.hero-ornament::before, .hero-ornament::after {
    content: ''; flex: 1; height: 1.5px;
    background: linear-gradient(to var(--orn-dir, left), rgba(209,138,63,0.65), transparent);
}
.hero-ornament::after { --orn-dir: right; }
.hero-ornament .orn-diamond {
    width: 9px; height: 9px; flex-shrink: 0;
    background: var(--brand-gold);
    transform: rotate(45deg);
}

.hero-kicker {
    display: flex; align-items: center; gap: 9px;
    color: var(--brand-gold-light); font-size: 14.5px; font-weight: 800;
    letter-spacing: 0.3px;
}
.kdot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-pink); box-shadow: 0 0 8px rgba(240, 133, 171, 0.7); }

.hero-title {
    font-family: var(--font-display);
    font-size: 46px; font-weight: 700; line-height: 1.3;
    text-shadow: 0 4px 26px rgba(0, 0, 0, 0.55);
}
@media (min-width: 640px) { .hero-title { font-size: 60px; } }
.hero-title .t-white { color: var(--foreground); }
.hero-title .t-gold { font-size: inherit; filter: drop-shadow(0 2px 14px rgba(209, 138, 63, 0.4)); }

.hero-desc { max-width: 470px; color: rgba(246, 236, 218, 0.82); font-size: 14.5px; font-weight: 500; }
@media (min-width: 640px) { .hero-desc { font-size: 16px; } }

/* زر سينابونة الأساسي — قاعدة مشتركة مع اللوحة ثم تخصيص الواجهة */
.btn-gold {
    position: relative; overflow: hidden;
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 55%, var(--brand-gold-dark));
    color: #fffdf8;
    border-radius: 14px; padding: 12px 28px;
    font-size: 15px; font-weight: 900;
    text-shadow: 0 1px 2px rgba(122, 78, 20, 0.35);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 4px 18px rgba(200, 129, 31, 0.3);
    transition: all 0.18s;
}
body.theme-bakery .btn-gold {
    color: var(--ink-on-gold, #1c1006);
    text-shadow: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 6px 22px rgba(209, 138, 63, 0.35);
}
.btn-gold::after {
    content: ''; position: absolute; top: 0; bottom: 0; width: 38%;
    right: -60%; transform: skewX(-18deg);
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.45), transparent);
    transition: right 0.5s ease;
}
.btn-gold:hover { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 8px 30px rgba(209, 138, 63, 0.5); transform: translateY(-1px); }
.btn-gold:hover::after { right: 125%; }
.btn-gold:active { transform: scale(0.96); }
.btn-gold.btn-lg { min-height: 50px; font-size: 16px; }
body.theme-bakery .btn-gold { border-radius: 999px; }
body.theme-bakery .btn-gold.btn-lg { font-size: 16.5px; }

.hero-feats {
    margin-top: 10px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: center;
    color: rgba(246, 236, 218, 0.85); font-size: 12px; font-weight: 700;
}
@media (min-width: 640px) { .hero-feats { font-size: 13px; gap: 20px; } }
.hero-feats span:not(.vline) {
    display: flex; align-items: center; gap: 6px;
    border: 1px solid rgba(209, 138, 63, 0.30);
    background: rgba(23, 14, 7, 0.55);
    backdrop-filter: blur(6px);
    border-radius: 999px; padding: 7px 14px;
}
.hero-feats .ic { color: var(--brand-gold-light); }
.hero-feats .vline { display: none; }
@media (min-width: 640px) { .hero-feats .vline { display: block; width: 1px; height: 16px; background: rgba(209, 138, 63, 0.35); } }

/* ═══════════ تنبيه الإغلاق ═══════════ */
.closed-alert {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 16px; text-align: center;
    border-top: 1px solid rgba(248, 113, 113, 0.25); border-bottom: 1px solid rgba(248, 113, 113, 0.25);
    background: rgba(52, 16, 12, 0.5);
    color: #fca5a5; font-size: 14px; font-weight: 800;
    backdrop-filter: blur(6px);
}
.closed-alert .ic { width: 16px; height: 16px; flex-shrink: 0; }

/* ═══════════ المنيو ═══════════ */
.menu-wrap { max-width: 1080px; width: 100%; margin: 0 auto; flex: 1; padding: 34px 14px 170px; }

.menu-title {
    font-family: var(--font-display);
    font-size: 29px; font-weight: 700; margin: 0 4px 18px;
    display: flex; align-items: center; gap: 10px;
    color: var(--foreground);
}
.menu-title::before {
    content: ''; width: 5px; height: 26px; border-radius: 99px;
    background: linear-gradient(to bottom, var(--brand-gold-light), var(--brand-gold));
    box-shadow: 0 0 12px rgba(209, 138, 63, 0.5);
}
@media (min-width: 640px) { .menu-title { font-size: 34px; } .menu-title::before { height: 30px; } }
.menu-title .gold {
    background: linear-gradient(105deg, #eec182, #d18a3f 55%, #9a6224);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}

.cat-tabs {
    position: sticky; top: 0; z-index: 30;
    border-bottom: 1px solid var(--border-soft);
    background: rgba(15, 9, 4, 0.88);
    backdrop-filter: blur(14px);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
    margin: 0 -14px;
}
.cat-tabs-scroll { display: flex; gap: 7px; overflow-x: auto; padding: 10px 12px; }
.cat-tab {
    position: relative; flex-shrink: 0;
    display: flex; align-items: center; gap: 6px;
    padding: 9px 16px; font-size: 13.5px; font-weight: 800;
    color: var(--muted-fg);
    border: 1px solid var(--border-soft); border-radius: 999px;
    background: rgba(30, 19, 9, 0.6);
    transition: color 0.2s, background 0.2s, transform 0.1s, box-shadow 0.2s, border-color 0.2s;
}
.cat-tab:hover { color: var(--foreground); background: var(--secondary); border-color: var(--border); }
.cat-tab:active { transform: scale(0.95); }
.cat-tab.active {
    color: var(--ink-on-gold, #1c1006);
    background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 60%, var(--brand-gold-dark));
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(209, 138, 63, 0.4);
}
.cat-ic { font-size: 17px; line-height: 1; }

.menu-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.cat-heading {
    font-family: var(--font-display);
    font-size: 20px; font-weight: 700; padding: 0 4px;
    display: flex; align-items: center; gap: 8px;
    color: var(--foreground);
}
@media (min-width: 640px) { .cat-heading { font-size: 22px; } }
.count-chip {
    font-size: 11px; font-weight: 800;
    border: 1px solid var(--border); background: var(--card);
    color: var(--muted-fg);
    padding: 3px 9px; border-radius: 8px;
}
.count-chip.gold-chip { border-color: rgba(209,138,63,0.45); background: rgba(209,138,63,0.12); color: var(--brand-gold-light); }

.search-box { position: relative; width: 176px; flex-shrink: 0; }
@media (min-width: 640px) { .search-box { width: 250px; } }
.search-box .ic { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted-fg); width: 16px; height: 16px; }
/* قاعدة مشتركة مع اللوحة ثم تخصيص الواجهة */
.search-box input {
    width: 100%; height: 42px;
    border: 1px solid var(--border); border-radius: 13px;
    background: var(--card); color: var(--foreground);
    padding: 0 36px 0 12px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.search-box input::placeholder { color: rgba(182, 160, 135, 0.75); }
.search-box input:focus { outline: none; border-color: rgba(209,138,63,0.65); box-shadow: 0 0 0 3px rgba(209,138,63,0.18); }
body.theme-bakery .search-box input { border-radius: 999px; }

/* ═══════════ بطاقات الوجبات — شبكة أفقية ═══════════
   جوال = عمودان │ تابلت = 3 أعمدة │ كمبيوتر = 4 أعمدة */
.cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}
@media (min-width: 640px) { .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 1024px) { .cards { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.meal-card {
    position: relative;
    display: flex; flex-direction: column; overflow: hidden;
    border: 1px solid var(--border-soft); border-radius: 20px;
    background: var(--card);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
    animation: cardIn 0.25s ease-out both;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.meal-card:hover {
    border-color: rgba(209,138,63,0.5);
    box-shadow: 0 16px 38px rgba(0, 0, 0, 0.5), 0 0 24px rgba(209, 138, 63, 0.12);
    transform: translateY(-4px);
}

.meal-media {
    position: relative; flex-shrink: 0;
    width: 100%; aspect-ratio: 4 / 3;
    background: var(--secondary);
    overflow: hidden;
}
.meal-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.45s ease; }
.meal-card:hover .meal-media img { transform: scale(1.06); }
.meal-noimg {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    font-size: 38px;
    background:
        radial-gradient(140px 90px at 50% 42%, rgba(209, 138, 63, 0.14), transparent 75%),
        var(--secondary);
}

.meal-body { display: flex; flex-direction: column; flex: 1; min-width: 0; padding: 12px 12px 14px; }
.meal-titlerow { display: flex; align-items: flex-start; gap: 8px; }
.meal-name {
    font-family: var(--font-display);
    font-size: 14px; font-weight: 700; line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    color: var(--foreground);
}
@media (min-width: 640px) { .meal-name { font-size: 15.5px; } }

/* شارة «مميز» تطفو فوق زاوية الصورة — لمسة وردية من قلب اللوغو */
.feat-badge {
    position: absolute; top: 10px; right: 10px; z-index: 2;
    display: inline-flex; align-items: center; gap: 4px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: linear-gradient(135deg, var(--brand-pink), var(--brand-pink-dark));
    color: #fff7fa;
    font-size: 11px; font-weight: 800;
    padding: 3px 9px; border-radius: 999px;
    box-shadow: 0 4px 14px rgba(217, 95, 136, 0.45);
    backdrop-filter: blur(4px);
}
.feat-badge .ic.xs { fill: currentColor; }

.meal-desc {
    margin-top: 4px;
    color: var(--muted-fg); font-size: 12px; line-height: 1.7;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
@media (min-width: 640px) { .meal-desc { font-size: 12.5px; } }

.meal-foot {
    display: flex; flex-direction: column; align-items: stretch; gap: 10px;
    margin-top: auto; padding-top: 11px;
    border-top: 1px dashed var(--border-soft);
}
.meal-price {
    display: inline-flex; align-items: baseline; gap: 3px;
    color: var(--brand-gold-light); font-size: 20px; font-weight: 800; white-space: nowrap;
    text-shadow: 0 0 18px rgba(209, 138, 63, 0.35);
}
@media (min-width: 640px) { .meal-price { font-size: 22px; } }
.meal-price small { font-size: 11px; font-weight: 700; color: var(--muted-fg); text-shadow: none; }

.add-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    width: 100%; min-height: 42px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 60%, var(--brand-gold-dark));
    color: var(--ink-on-gold, #1c1006);
    font-size: 12.5px; font-weight: 800;
    white-space: nowrap; flex-shrink: 0;
    box-shadow: 0 6px 18px rgba(209, 138, 63, 0.35);
    transition: all 0.15s;
}
@media (min-width: 640px) { .add-btn { font-size: 13px; } }
.add-btn:hover { box-shadow: 0 8px 24px rgba(209,138,63,0.5); filter: brightness(1.05); }
.add-btn:active { transform: scale(0.95); }
.add-btn:disabled { cursor: not-allowed; background: var(--secondary); color: var(--muted-fg); border: 1px dashed var(--border); box-shadow: none; }

/* حالات الفراغ */
.empty-cat, .search-empty {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    padding: 56px 16px; text-align: center; color: var(--muted-fg);
    font-size: 14px;
}
.search-empty { padding-top: 30px; }
.search-empty .ic.big { color: rgba(209,138,63,0.65); }
.big-emoji { font-size: 36px; }
.search-empty p:first-of-type { color: var(--foreground); }
.search-empty .dim { font-size: 12px; }

/* ═══════════ شريط السلة العائم ═══════════ */
.cart-fab {
    position: fixed; left: 12px; right: 12px; bottom: calc(84px + env(safe-area-inset-bottom));
    z-index: 40; margin: 0 auto; max-width: 548px;
    display: flex; align-items: center; gap: 10px;
    min-height: 58px; padding: 0 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 55%, var(--brand-gold-dark));
    color: var(--ink-on-gold, #1c1006);
    box-shadow: 0 14px 44px rgba(0, 0, 0, 0.55), 0 6px 24px rgba(209, 138, 63, 0.4);
    transition: transform 0.1s;
}
.cart-fab:active { transform: scale(0.98); }
.fab-label { font-size: 16px; font-weight: 800; }
.fab-count {
    display: flex; align-items: center; justify-content: center;
    width: 24px; height: 24px; border-radius: 50%;
    background: var(--ink-on-gold, #1c1006); color: var(--brand-gold-light);
    font-size: 12px; font-weight: 800;
}
.fab-total { margin-right: auto; font-size: 18px; font-weight: 800; }
.fab-total small { font-size: 12px; font-weight: 700; opacity: 0.8; }

/* ═══════════ الشريط السفلي ═══════════ */
.sticky-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    border-top: 1px solid var(--border);
    background: rgba(13, 8, 3, 0.94);
    backdrop-filter: blur(14px);
    box-shadow: 0 -10px 34px rgba(0, 0, 0, 0.5);
    padding-bottom: env(safe-area-inset-bottom);
}
.sticky-inner { max-width: 600px; margin: 0 auto; display: flex; align-items: center; gap: 8px; padding: 10px 12px; }
.sticky-bar .call-btn { flex: 1; min-height: 48px; }
.soc-btn {
    display: flex; align-items: center; justify-content: center;
    width: 48px; height: 48px; flex-shrink: 0;
    border: 1px solid var(--border); border-radius: 14px;
    background: rgba(30, 19, 9, 0.8);
    color: var(--brand-gold-light);
    transition: all 0.15s;
}
.soc-btn:hover { border-color: var(--brand-gold); color: var(--brand-gold-light); box-shadow: 0 4px 16px rgba(209, 138, 63, 0.3); transform: translateY(-1px); }
.soc-btn:active { transform: scale(0.95); }
.soc-btn.soc-wa { color: #4ade80; border-color: rgba(74, 222, 128, 0.35); }
.soc-btn.soc-wa:hover { border-color: #4ade80; color: #4ade80; box-shadow: 0 4px 16px rgba(74, 222, 128, 0.25); }

/* ═══════════ الفوتر ═══════════ */
.site-footer {
    position: relative;
    margin-top: auto;
    border-top: 1px solid var(--border);
    background:
        radial-gradient(700px 260px at 50% 0%, rgba(209, 138, 63, 0.08), transparent 70%),
        #0b0602;
    padding: 0 0 108px;
}
.footer-ornament {
    display: flex; align-items: center; gap: 12px;
    max-width: 600px; margin: 28px auto 4px; padding: 0 20px;
    color: var(--brand-gold);
}
.footer-ornament::before, .footer-ornament::after {
    content: ''; flex: 1; height: 1px;
    background: linear-gradient(to var(--orn-dir, left), rgba(209,138,63,0.55), transparent);
}
.footer-ornament::after { --orn-dir: right; }
.footer-ornament .orn-diamond {
    width: 8px; height: 8px; flex-shrink: 0;
    background: var(--brand-pink); transform: rotate(45deg);
    box-shadow: 0 0 10px rgba(240, 133, 171, 0.6);
}

.footer-grid {
    max-width: 1080px; margin: 20px auto 0; padding: 0 20px;
    display: grid; grid-template-columns: 1fr; gap: 26px;
}
@media (min-width: 640px) { .footer-grid { grid-template-columns: 1.25fr 1fr 1fr; gap: 18px; } }

.footer-brand { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; }
@media (min-width: 640px) { .footer-brand { align-items: flex-start; text-align: right; } }
.footer-logo {
    width: 86px; height: 86px; border-radius: 24px; object-fit: cover;
    border: 3px solid rgba(238, 193, 130, 0.6);
    box-shadow: 0 0 0 1px var(--border), 0 10px 28px rgba(0, 0, 0, 0.5);
}
.footer-name { font-family: var(--font-display); font-size: 22px; font-weight: 700; color: var(--foreground); }
.footer-slogan { color: var(--brand-gold-light); font-size: 12.5px; font-weight: 700; letter-spacing: 0.3px; }
.footer-about { color: var(--muted-fg); font-size: 12px; line-height: 1.9; max-width: 300px; }

.footer-col-title {
    font-family: var(--font-display);
    font-size: 15px; font-weight: 700; color: var(--foreground);
    display: flex; align-items: center; gap: 8px;
    margin-bottom: 14px;
}
.footer-col-title::after {
    content: ''; flex: 1; height: 1px;
    background: linear-gradient(to left, rgba(209,138,63,0.45), transparent);
}

.footer-contact-list { display: flex; flex-direction: column; gap: 10px; }
.fc-item {
    display: flex; align-items: center; gap: 10px;
    color: var(--muted-fg); font-size: 13px; font-weight: 700;
    transition: color 0.15s;
}
a.fc-item:hover { color: var(--brand-gold-light); }
.fc-ic {
    display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; flex-shrink: 0;
    border: 1px solid var(--border); border-radius: 11px;
    background: var(--card); color: var(--brand-gold-light);
    font-size: 15px;
}
.fc-ic.wa-ic { color: #4ade80; border-color: rgba(74, 222, 128, 0.3); }
.fc-item b { color: var(--foreground); font-weight: 800; }
.footer-hours { color: var(--muted-fg); font-size: 12.5px; font-weight: 600; line-height: 1.9; }
.footer-hours b { color: var(--brand-gold-light); }

.f-social-row { display: flex; gap: 10px; }
.f-social {
    display: flex; align-items: center; justify-content: center;
    width: 46px; height: 46px;
    border: 1px solid var(--border); border-radius: 14px;
    background: var(--card); color: var(--brand-gold-light);
    transition: all 0.15s;
}
.f-social:hover {
    border-color: var(--brand-gold); color: var(--brand-gold-light);
    box-shadow: 0 6px 18px rgba(209, 138, 63, 0.3);
    transform: translateY(-2px);
}
.f-social:active { transform: scale(0.95); }

.footer-bottom {
    max-width: 600px; margin: 26px auto 0; padding: 14px 20px 0;
    border-top: 1px solid rgba(209, 138, 63, 0.16);
    text-align: center;
}
.footer-copy { color: rgba(246, 236, 218, 0.55); font-size: 11.5px; font-weight: 700; }
.footer-copy .gold { font-weight: 800; }

.footer-credit {
    max-width: 600px; margin: 8px auto 0; padding: 0 20px;
    text-align: center; color: rgba(246, 236, 218, 0.4);
    font-size: 11px; line-height: 1.8;
}
@media (min-width: 640px) { .footer-credit { font-size: 12px; } }
.footer-credit .gold { font-weight: 800; color: rgba(238, 193, 130, 0.9); }
.footer-credit a { font-weight: 800; color: rgba(246, 236, 218, 0.7); text-decoration: underline; text-decoration-color: rgba(209,138,63,0.55); text-underline-offset: 4px; }
.footer-credit a:hover { color: var(--brand-gold-light); }

.admin-dot {
    display: block; width: 32px; margin: 8px auto 0; text-align: center;
    font-size: 19px; color: rgba(246, 236, 218, 0.18);
    transition: color 0.15s;
}
.admin-dot:hover { color: rgba(209,138,63,0.75); }

/* ═══════════ درج السلة ═══════════ */
.drawer-backdrop {
    position: fixed; inset: 0; z-index: 50;
    background: rgba(5, 3, 1, 0.62); backdrop-filter: blur(4px);
    animation: fadeIn 0.2s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.cart-drawer {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    margin: 0 auto; max-width: 600px;
    max-height: 92vh; max-height: 92dvh;
    display: flex; flex-direction: column;
    overflow: hidden;
    background:
        radial-gradient(500px 200px at 50% 0%, rgba(209, 138, 63, 0.08), transparent 70%),
        var(--brand-dark);
    border: 1px solid var(--border); border-bottom: 0;
    border-radius: 26px 26px 0 0;
    box-shadow: 0 -24px 70px rgba(0, 0, 0, 0.6);
    transform: translateY(105%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    padding-bottom: env(safe-area-inset-bottom);
}
.cart-drawer.open { transform: translateY(0); }
.drawer-grip { width: 44px; height: 4px; border-radius: 4px; background: var(--border); margin: 10px auto 0; }

.drawer-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 14px 18px 8px; }
.drawer-title { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-size: 18px; font-weight: 700; color: var(--foreground); }
.drawer-sub { color: var(--muted-fg); font-size: 12px; margin-top: 2px; }
.drawer-close {
    display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border-radius: 11px;
    background: var(--secondary); color: var(--muted-fg);
    font-size: 15px;
}
.drawer-close:hover { background: rgba(209, 138, 63, 0.18); color: var(--brand-gold-light); }

.drawer-items {
    overflow-y: auto;
    padding: 6px 18px;
    max-height: 46vh; max-height: 46dvh;
    min-height: 0;
    flex: 0 1 auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}
.drawer-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 34px 0; text-align: center; color: var(--muted-fg); }
.drawer-empty .big-emoji { font-size: 38px; }
.drawer-empty p:first-of-type { color: var(--foreground); font-weight: 700; font-size: 14px; }
.drawer-empty p:last-child { font-size: 12px; }

.ci {
    display: flex; align-items: center; gap: 10px;
    border: 1px solid var(--border-soft); background: var(--card);
    border-radius: 16px; padding: 8px; margin-bottom: 8px;
    transition: border-color 0.15s;
}
.ci:hover { border-color: rgba(209, 138, 63, 0.45); }
.ci-img { width: 48px; height: 48px; border-radius: 12px; object-fit: cover; flex-shrink: 0; background: var(--secondary); }
.ci-noimg { width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0; background: var(--secondary); display: flex; align-items: center; justify-content: center; font-size: 20px; }
.ci-info { flex: 1; min-width: 0; }
.ci-name { font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--foreground); }
.ci-price { font-size: 12px; font-weight: 700; color: var(--brand-gold-light); }
.ci-qty { display: flex; align-items: center; gap: 4px; }
.qbtn {
    display: flex; align-items: center; justify-content: center;
    width: 32px; height: 32px; border-radius: 50%;
    background: var(--secondary); color: var(--foreground);
    border: 1px solid var(--border-soft);
    transition: transform 0.1s, background 0.15s, color 0.15s;
}
.qbtn:hover { background: rgba(209, 138, 63, 0.22); color: var(--brand-gold-light); }
.qbtn:active { transform: scale(0.88); }
.qbtn.del { background: rgba(248,113,113,0.08); color: var(--red); border-color: rgba(248,113,113,0.2); margin-right: 4px; }
.qbtn.del:hover { background: rgba(248, 113, 113, 0.16); }

/* منطقة الخطوات قابلة للتمرير دائماً — زر التأكيد يبقى في المتناول */
.drawer-form {
    padding: 0 18px 18px;
    border-top: 1px solid var(--border-soft);
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}
.form-label { font-size: 14px; font-weight: 800; margin: 14px 0 8px; color: var(--foreground); }
.order-types { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.otype {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    min-height: 46px; padding: 8px 12px;
    border: 2px solid var(--border); border-radius: 14px;
    background: var(--card); color: var(--muted-fg);
    font-size: 13.5px; font-weight: 700;
    transition: all 0.15s;
}
.otype:active { transform: scale(0.98); }
.otype.active {
    border-color: var(--brand-gold); background: rgba(209, 138, 63, 0.14);
    color: var(--foreground); box-shadow: 0 0 0 3px rgba(209,138,63,0.14);
}

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.field { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 700; margin-top: 12px; }
.field .req { color: var(--red); }
.field .opt { color: var(--muted-fg); font-weight: 400; }
/* قاعدة مشتركة مع اللوحة ثم تخصيص الواجهة */
.field input, .field textarea {
    border: 1px solid var(--border); border-radius: 11px;
    background: rgba(0,0,0,0.32); color: var(--foreground);
    padding: 10px 12px; font-size: 14px; resize: vertical;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: rgba(200,129,31,0.6); box-shadow: 0 0 0 3px rgba(200,129,31,0.13); }
body.theme-bakery .field input, body.theme-bakery .field textarea { background: var(--card); }
body.theme-bakery .field input:focus, body.theme-bakery .field textarea:focus { border-color: rgba(209,138,63,0.65); box-shadow: 0 0 0 3px rgba(209,138,63,0.15); }

.drawer-totalrow {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 14px; font-weight: 800; margin: 14px 0 10px;
    border-top: 1px dashed var(--border); padding-top: 12px;
}
.total-val { font-size: 19px; }

.wa-send {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; min-height: 50px;
    background: linear-gradient(135deg, #2fe171, #22c35e);
    color: #fff;
    border-radius: 14px; font-size: 15px; font-weight: 800;
    box-shadow: 0 8px 26px rgba(37, 211, 102, 0.3);
    transition: filter 0.15s, transform 0.1s;
}
.wa-send:hover { filter: brightness(1.07); }
.wa-send:active { transform: scale(0.98); }
.wa-send:disabled { cursor: not-allowed; background: var(--secondary); color: var(--muted-fg); box-shadow: none; }
.closed-note { margin-top: 8px; text-align: center; font-size: 12px; font-weight: 700; color: var(--red); }

/* ═══════════ خطوات الطلب + طرق الدفع + الإيصال ═══════════ */

/* شريط الخطوات */
.steps-bar { display: flex; align-items: center; gap: 8px; margin: 14px 0 4px; }
.step-pill {
    display: inline-flex; align-items: center; gap: 6px;
    font-size: 11.5px; font-weight: 800; color: var(--muted-fg);
    border: 1px solid var(--border); border-radius: 999px;
    padding: 5px 12px; background: var(--card);
    transition: all 0.2s;
}
.step-pill b {
    width: 18px; height: 18px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--secondary); font-size: 10.5px;
}
.step-pill.active { color: var(--brand-gold-light); border-color: rgba(209,138,63,0.6); background: rgba(209,138,63,0.12); box-shadow: 0 0 14px rgba(209, 138, 63, 0.15); }
.step-pill.active b { background: var(--brand-gold); color: var(--ink-on-gold, #1c1006); }
.step-pill.done { color: var(--green); border-color: rgba(74,222,128,0.4); }
.step-pill.done b { background: var(--green); color: #08260f; }
.step-line { flex: 1; height: 1px; background: var(--border); }

/* زر متابعة إلى الدفع + رابط رجوع */
.btn-continue {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; min-height: 50px;
    background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 55%, var(--brand-gold-dark));
    color: var(--ink-on-gold, #1c1006); border-radius: 999px;
    font-size: 15px; font-weight: 800;
    box-shadow: 0 8px 26px rgba(209, 138, 63, 0.35);
    transition: filter 0.15s, transform 0.1s;
}
.btn-continue:hover { filter: brightness(1.06); }
.btn-continue:active { transform: scale(0.98); }
.btn-continue:disabled { cursor: not-allowed; background: var(--secondary); color: var(--muted-fg); box-shadow: none; }

.back-link {
    display: inline-flex; align-items: center; gap: 4px;
    margin-top: 12px; font-size: 12.5px; font-weight: 800;
    color: var(--muted-fg); transition: color 0.15s;
}
.back-link:hover { color: var(--brand-gold-light); }

/* طرق الدفع */
.pay-methods { display: flex; flex-direction: column; gap: 8px; }
.pmeth {
    display: flex; align-items: center; gap: 12px;
    border: 2px solid var(--border); border-radius: 16px;
    background: var(--card); padding: 12px 14px;
    text-align: right; color: var(--foreground);
    transition: all 0.15s; min-height: 56px;
}
.pmeth:active { transform: scale(0.985); }
.pmeth.active { border-color: var(--brand-gold); background: rgba(209,138,63,0.12); box-shadow: 0 0 0 3px rgba(209,138,63,0.14); }
.pmeth-ic { font-size: 22px; flex-shrink: 0; }
.pmeth-txt { flex: 1; font-size: 14px; font-weight: 800; display: flex; flex-direction: column; gap: 1px; }
.pmeth-txt small { color: var(--muted-fg); font-size: 11.5px; font-weight: 600; }
.pmeth-check {
    width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0;
    border: 2px solid var(--border); transition: all 0.15s;
}
.pmeth.active .pmeth-check { border-color: var(--brand-gold); background: var(--brand-gold); box-shadow: inset 0 0 0 3px var(--brand-dark); }

/* لوحة تفاصيل طريقة الدفع */
.pay-panel {
    margin-top: 10px; border: 1px solid var(--border-soft);
    border-radius: 16px; background: var(--card); padding: 14px;
}
.pay-amount-row {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 13.5px; font-weight: 800;
    border-bottom: 1px dashed var(--border); padding-bottom: 10px; margin-bottom: 10px;
}
.pay-amount-row b { font-size: 19px; }
.pay-steps { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.pay-steps li { font-size: 12.5px; color: var(--muted-fg); font-weight: 600; display: flex; gap: 7px; }
.pay-steps li::before { content: '◆'; color: var(--brand-gold); font-weight: 900; font-size: 8px; margin-top: 4px; }

/* صندوق التحذير — قاعدة عامة (تحتاجها لوحة التحكم أيضاً) ثم تخصيص الواجهة */
.warn-box {
    margin-top: 10px; padding: 10px 12px;
    border: 1px solid #f3cfc2; border-radius: 12px;
    background: #fdeee8;
    color: #9c3a20; font-size: 12px; font-weight: 700; line-height: 1.7;
}
body.theme-bakery .warn-box {
    border-color: rgba(248, 180, 84, 0.35);
    background: rgba(94, 54, 12, 0.35);
    color: #fcd9a0;
}

/* صندوق QR شام كاش — يبقى فاتحاً ليقرأه ماسح الكود */
.qr-box {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    background: #ffffff; border-radius: 16px; padding: 14px; margin-bottom: 12px;
    border: 1px solid rgba(209, 138, 63, 0.45);
}
/* QR متجاوب: حد أقصى 250px مع توسيط دائم — لا يبتلع الشاشة على الجوال */
.qr-box img {
    width: min(230px, 62vw);
    max-width: 250px;
    max-height: 250px;
    aspect-ratio: 1 / 1;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    margin-inline: auto;
}
.qr-cap { color: #7a5420; font-size: 11.5px; font-weight: 800; text-align: center; }
.sham-account {
    border: 1px dashed rgba(209,138,63,0.5); border-radius: 12px;
    padding: 8px 12px; margin-bottom: 10px;
    font-size: 12.5px; color: var(--muted-fg); font-weight: 700;
    display: flex; flex-direction: column; gap: 3px;
}
.sham-account b { color: var(--foreground); }

/* رفع إيصال الدفع */
.receipt-upload {
    position: relative; margin-top: 10px;
    border: 2px dashed rgba(209,138,63,0.55); border-radius: 16px;
    background: rgba(209, 138, 63, 0.07);
    cursor: pointer; transition: all 0.15s;
    overflow: hidden;
}
.receipt-upload:hover { border-color: var(--brand-gold); background: rgba(209, 138, 63, 0.13); }
.receipt-placeholder {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 22px 14px; text-align: center;
}
.receipt-placeholder .rp-ic { font-size: 30px; }
.receipt-placeholder b { font-size: 13.5px; font-weight: 800; color: var(--foreground); }
.receipt-placeholder small { font-size: 11px; color: var(--muted-fg); font-weight: 600; }
.receipt-preview { width: 100%; max-height: 260px; object-fit: contain; background: #ffffff; }
.receipt-hint { margin-top: 8px; font-size: 12px; font-weight: 700; color: var(--green); text-align: center; }

/* رقم واتساب الوجهة */
.wa-target {
    margin-top: 9px; text-align: center;
    font-size: 11.5px; font-weight: 700; color: var(--muted-fg);
}

/* شاشة النجاح */
.done-box { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 26px 8px 14px; text-align: center; }
.done-ic {
    width: 62px; height: 62px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: rgba(74,222,128,0.12); color: var(--green);
    font-size: 30px; font-weight: 900;
    border: 2px solid rgba(74,222,128,0.35);
    animation: popIn 0.3s ease-out;
}
@keyframes popIn { from { transform: scale(0.5); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.done-box h4 { font-family: var(--font-display); font-size: 18px; font-weight: 700; color: var(--foreground); }
.done-ref { font-size: 13.5px; color: var(--muted-fg); font-weight: 700; }
.done-ref b { color: var(--brand-gold-light); font-size: 15px; letter-spacing: 1px; }
.done-sub { font-size: 12px; color: var(--muted-fg); font-weight: 600; }
.done-note {
    font-size: 11px; color: var(--muted-fg); font-weight: 600;
    border: 1px dashed var(--border); border-radius: 10px;
    padding: 8px 12px; line-height: 1.7;
}
.done-box .btn-ghost { min-height: 42px; padding: 0 22px; border: 1px solid var(--border); border-radius: 12px; background: var(--card); display: inline-flex; align-items: center; font-weight: 800; font-size: 13px; }
.done-box .btn-ghost:hover { border-color: rgba(209,138,63,0.55); color: var(--brand-gold-light); }

/* مؤشر التحميل */
.spinner {
    width: 17px; height: 17px; border-radius: 50%;
    border: 2.5px solid rgba(255,255,255,0.35); border-top-color: #fff;
    animation: spin 0.7s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════ Toasts ═══════════ */
.toasts { position: fixed; top: 14px; left: 0; right: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
.toast {
    pointer-events: auto;
    max-width: 480px; width: 100%;
    display: flex; align-items: center; gap: 10px;
    background: #241609; color: var(--foreground);
    border: 1px solid var(--border);
    border-radius: 16px; padding: 12px 16px;
    box-shadow: 0 14px 44px rgba(0, 0, 0, 0.55);
    font-size: 13.5px; font-weight: 700;
    animation: toastIn 0.25s ease-out;
}
.toast.out { animation: toastOut 0.25s ease-in forwards; }
.toast .t-ic { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; }
.toast.success .t-ic { background: rgba(74,222,128,0.14); color: var(--green); }
.toast.error { border-color: rgba(248,113,113,0.4); }
.toast.error .t-ic { background: rgba(248,113,113,0.12); color: var(--red); }
.toast small { display: block; color: var(--muted-fg); font-weight: 400; font-size: 12px; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-10px); } }

/* ═══════════ التجاوب الكامل مع الجوال ═══════════ */
@media (max-width: 640px) {
    .cart-drawer {
        max-height: 94vh; max-height: 94dvh;
        border-radius: 22px 22px 0 0;
    }
    .drawer-head { padding: 12px 16px 6px; }
    .drawer-title { font-size: 16px; }
    .drawer-items { max-height: 32vh; max-height: 32dvh; padding: 6px 16px; }
    .drawer-form { padding: 0 16px calc(16px + env(safe-area-inset-bottom)); }
    .steps-bar { margin: 10px 0 4px; }
    .pay-panel { padding: 12px; }
    .qr-box { padding: 12px; margin-bottom: 10px; }
    .qr-box img { width: min(250px, 66vw); }
    .receipt-preview { max-height: 200px; }
    .pay-amount-row b { font-size: 17px; }
    .drawer-totalrow { margin: 12px 0 8px; }
    .wa-send, .btn-continue { min-height: 50px; } /* هدف لمس مريح ≥44px */
    .footer-grid { gap: 24px; }
    .footer-brand { align-items: center; text-align: center; }
    .cards { gap: 10px; }
    .menu-wrap { padding-bottom: 170px; }
    .hero-inner { min-height: 86svh; }
}

/* شاشات جوال قصيرة (أفقية أو صغيرة) */
@media (max-width: 640px) and (max-height: 640px) {
    .drawer-items { max-height: 26vh; max-height: 26dvh; }
    .drawer-empty { padding: 20px 0; }
    .hero-inner { min-height: 0; padding-top: 40px; }
}

/* شاشات واسعة جداً: منيو مريح بدون تمدد مبالغ */
@media (min-width: 1280px) {
    .menu-wrap { padding-top: 44px; }
}

/* تقليل الحركة لمن يفضل ذلك */
@media (prefers-reduced-motion: reduce) {
    .hero-bg img, .fade-up, .meal-card, .hero-logo, .hero-logo-wrap::before { animation: none !important; }
    html { scroll-behavior: auto; }
}

/* ═══════════ لوحة التحكم ═══════════ */
/* جسم اللوحة: عمود مرن حتى يبقى الفوتر أسفل الشاشة دون أن يغطي المحتوى */
.admin-body { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; background: radial-gradient(900px 400px at 80% -10%, rgba(233,168,59,0.07), transparent 60%), var(--background); }

.login-wrap { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; justify-content: center; padding: 20px; position: relative; overflow: hidden; }
.login-glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.17; pointer-events: none; }
.login-glow.g1 { width: 420px; height: 420px; background: var(--brand-gold); top: -140px; left: -120px; }
.login-glow.g2 { width: 360px; height: 360px; background: var(--brand-gold-dark); bottom: -120px; right: -100px; }
.login-card {
    position: relative; width: 100%; max-width: 400px;
    background: linear-gradient(170deg, var(--brand-dark), #170e05);
    border: 1px solid rgba(233,168,59,0.4); border-radius: 24px;
    padding: 34px 28px; text-align: center;
    box-shadow: 0 30px 80px rgba(0,0,0,0.65), 0 0 40px rgba(233, 168, 59, 0.07);
}
.login-logo {
    width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin: 0 auto 14px;
    border: 3px solid var(--brand-gold);
    box-shadow: 0 0 0 3px rgba(233, 168, 59, 0.2), 0 0 34px rgba(233, 168, 59, 0.35);
}
.login-title { font-family: var(--font-display); font-size: 22px; font-weight: 700; }
.login-sub { color: var(--muted-fg); font-size: 13px; margin: 4px 0 22px; }
.login-card .field { text-align: right; margin-top: 0; }
.pw-wrap { position: relative; }
.pw-toggle { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--muted-fg); padding: 4px; }
.pw-toggle:hover { color: var(--brand-gold); }
.login-err {
    display: none; align-items: center; gap: 8px;
    margin-bottom: 12px; padding: 10px 12px;
    border: 1px solid rgba(248,113,113,0.35); background: rgba(69,10,10,0.35);
    color: #fca5a5; border-radius: 10px; font-size: 13px; font-weight: 700;
}
.login-err.show { display: flex; }
.btn-block { width: 100%; min-height: 48px; margin-top: 16px; }
.login-hint { margin-top: 16px; font-size: 11px; color: rgba(255,255,255,0.35); }

.admin-header {
    position: sticky; top: 0; z-index: 40;
    background: rgba(18, 11, 4, 0.97); backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(233,168,59,0.2);
}
.admin-header-inner { max-width: 720px; margin: 0 auto; display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
.admin-logo { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; border: 2px solid var(--brand-gold); box-shadow: 0 0 14px rgba(233, 168, 59, 0.3); }
.admin-title { font-family: var(--font-display); font-size: 17px; font-weight: 700; }
.admin-title small { display: block; font-size: 11px; color: var(--brand-gold); font-weight: 700; }
.btn-logout {
    margin-right: auto; display: flex; align-items: center; gap: 6px;
    min-height: 40px; padding: 0 14px;
    border: 1px solid rgba(248,113,113,0.35); border-radius: 10px;
    color: var(--red); font-size: 13px; font-weight: 800;
    transition: all 0.15s;
}
.btn-logout:hover { background: rgba(248,113,113,0.1); }

.admin-main { flex: 1 0 auto; width: 100%; max-width: 720px; margin: 0 auto; padding: 18px 16px 28px; }

.admin-tabs { display: flex; gap: 6px; background: var(--brand-dark); border: 1px solid var(--border); border-radius: 14px; padding: 5px; margin-bottom: 18px; }
.atab { flex: 1; min-height: 42px; border-radius: 10px; font-size: 14px; font-weight: 800; color: var(--muted-fg); transition: all 0.15s; }
.atab:hover { color: var(--foreground); }
.atab.active { background: linear-gradient(135deg, var(--brand-gold-light), var(--brand-gold) 60%, var(--brand-gold-dark)); color: #1d1002; box-shadow: 0 2px 14px rgba(233, 168, 59, 0.3); }

.flash { display: flex; align-items: center; gap: 8px; border-radius: 12px; padding: 12px 14px; font-size: 13.5px; font-weight: 700; margin-bottom: 14px; animation: toastIn 0.25s ease-out; }
.flash.success { border: 1px solid rgba(74,222,128,0.35); background: rgba(9,46,28,0.4); color: #86efac; }
.flash.error { border: 1px solid rgba(248,113,113,0.4); background: rgba(69,10,10,0.4); color: #fca5a5; }

.acard {
    border: 1px solid var(--border); background: var(--card);
    border-radius: 18px; padding: 18px; margin-bottom: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.acard-title { font-family: var(--font-display); font-size: 16px; font-weight: 700; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }

.status-card { background: linear-gradient(170deg, var(--brand-dark), #170e05); border: 1px solid rgba(233,168,59,0.3); }
.status-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.status-pill { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 900; }
.status-pill.on { background: #16a34a; color: #fff; border: 1px solid #4ade80; }
.status-pill.off { background: #b91c1c; color: #fff; border: 1px solid var(--red); }
.status-meta { font-size: 12px; color: var(--muted-fg); font-weight: 700; }
.status-meta b { color: var(--brand-gold); }

.mode-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
@media (max-width: 560px) { .mode-grid { grid-template-columns: 1fr; } }
.mode-opt {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    min-height: 64px; justify-content: center;
    border: 2px solid var(--border); border-radius: 12px;
    background: var(--brand-dark); padding: 10px;
    font-size: 13px; font-weight: 800; color: var(--muted-fg);
    cursor: pointer; transition: all 0.15s;
}
.mode-opt small { font-size: 10.5px; font-weight: 400; color: var(--muted-fg); }
.mode-opt:has(input:checked) { border-color: var(--brand-gold); background: rgba(233,168,59,0.08); color: var(--foreground); box-shadow: 0 0 0 3px rgba(233,168,59,0.08); }
.mode-opt:has(input[value="closed"]:checked) { border-color: var(--red); background: rgba(248,113,113,0.06); color: #fca5a5; }
.mode-opt input { position: absolute; opacity: 0; pointer-events: none; }

.field label { display: block; }
.afield { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; font-weight: 700; margin-bottom: 14px; }
.afield .hint { font-size: 11px; color: var(--muted-fg); font-weight: 400; }
.afield input, .afield textarea, .afield select {
    border: 1px solid var(--border); border-radius: 10px;
    background: var(--brand-dark); color: var(--foreground);
    padding: 11px 12px; font-size: 14px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.afield input:focus, .afield textarea:focus, .afield select:focus { outline: none; border-color: rgba(233,168,59,0.55); box-shadow: 0 0 0 3px rgba(233,168,59,0.11); }
.afield input[type="time"] { direction: ltr; text-align: center; }
.afield input[dir="ltr"] { direction: ltr; text-align: right; }
.afield textarea { resize: vertical; }

.btn-gold.sm { min-height: 42px; padding: 8px 18px; font-size: 13.5px; }
.btn-ghost {
    display: inline-flex; align-items: center; gap: 6px;
    min-height: 42px; padding: 8px 16px;
    border: 1px solid var(--border); border-radius: 10px;
    background: var(--brand-dark); color: var(--muted-fg);
    font-size: 13px; font-weight: 700;
    transition: all 0.15s;
}
.btn-ghost:hover { color: var(--brand-gold); border-color: rgba(233,168,59,0.4); }
.btn-danger {
    display: inline-flex; align-items: center; gap: 6px;
    min-height: 42px; padding: 8px 16px;
    border: 1px solid rgba(248,113,113,0.35); border-radius: 10px;
    background: transparent; color: var(--red);
    font-size: 13px; font-weight: 700;
    transition: all 0.15s;
}
.btn-danger:hover { background: rgba(248,113,113,0.1); }

.items-toolbar { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.items-toolbar .search-box { flex: 1; min-width: 150px; width: auto; }
.items-toolbar select {
    height: 42px; padding: 0 12px;
    border: 1px solid var(--border); border-radius: 12px;
    background: var(--card); color: var(--foreground); font-size: 13.5px;
}
.items-list { display: flex; flex-direction: column; gap: 10px; max-height: 70vh; overflow-y: auto; padding-left: 2px; }

.aitem { display: flex; align-items: center; gap: 12px; border: 1px solid var(--border-soft); background: var(--brand-dark); border-radius: 14px; padding: 10px; transition: border-color 0.15s; }
.aitem:hover { border-color: rgba(233, 168, 59, 0.3); }
.aitem-img { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: var(--muted); }
.aitem-noimg { width: 56px; height: 56px; border-radius: 10px; flex-shrink: 0; background: var(--muted); display: flex; align-items: center; justify-content: center; font-size: 22px; }
.aitem-info { flex: 1; min-width: 0; }
.aitem-name { font-size: 14px; font-weight: 800; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.aitem-cat { font-size: 10.5px; font-weight: 700; color: var(--brand-gold); border: 1px solid rgba(233,168,59,0.3); background: rgba(233,168,59,0.08); padding: 2px 8px; border-radius: 6px; }
.aitem-price { font-size: 12px; color: var(--brand-gold); font-weight: 800; margin-top: 2px; }
.aitem-actions { display: flex; align-items: center; gap: 6px; }
.star { color: var(--brand-gold); width: 16px; height: 16px; }

.switch { position: relative; display: inline-flex; width: 44px; height: 26px; flex-shrink: 0; cursor: pointer; }
.switch input { position: absolute; opacity: 0; }
.switch .track { position: absolute; inset: 0; border-radius: 999px; background: var(--secondary); border: 1px solid var(--border); transition: background 0.15s; }
.switch .track::after { content: ''; position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; background: var(--muted-fg); transition: transform 0.15s, background 0.15s; }
.switch input:checked + .track { background: rgba(233,168,59,0.25); border-color: var(--brand-gold); }
.switch input:checked + .track::after { transform: translateX(-18px); background: var(--brand-gold); }

.icon-btn { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--border); color: var(--muted-fg); transition: all 0.15s; }
.icon-btn:hover { color: var(--brand-gold); border-color: rgba(233,168,59,0.4); }
.icon-btn.del:hover { color: var(--red); border-color: rgba(248,113,113,0.4); }

.upload-box { border: 2px dashed rgba(233,168,59,0.4); border-radius: 14px; padding: 18px; text-align: center; cursor: pointer; transition: all 0.15s; background: rgba(233,168,59,0.03); }
.upload-box:hover { border-color: var(--brand-gold); background: rgba(233,168,59,0.07); }
.upload-preview { width: 110px; height: 110px; border-radius: 14px; object-fit: cover; margin: 0 auto 10px; border: 2px solid rgba(233,168,59,0.45); }
.upload-hint { font-size: 12px; color: var(--muted-fg); }

.cats-list { display: flex; flex-direction: column; gap: 10px; }
.acat { display: flex; align-items: center; gap: 12px; border: 1px solid var(--border-soft); background: var(--brand-dark); border-radius: 14px; padding: 12px; }
.cat-icon { width: 44px; height: 44px; border-radius: 50%; background: var(--card); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 21px; flex-shrink: 0; }
.acat form { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.acat input {
    border: 1px solid var(--border); border-radius: 10px;
    background: var(--card); color: var(--foreground);
    font-size: 14px; font-weight: 700;
    padding: 10px 12px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.acat input:focus { outline: none; border-color: rgba(233,168,59,0.55); box-shadow: 0 0 0 3px rgba(233,168,59,0.11); }
.acat input.ic-in { width: 64px; text-align: center; font-size: 18px; padding: 8px 4px; }
.acat input.nm-in { flex: 1; min-width: 0; }
.cat-count { font-size: 11px; font-weight: 800; color: var(--muted-fg); border: 1px solid var(--border); border-radius: 7px; padding: 3px 9px; background: var(--card); white-space: nowrap; }

.dialog-confirm { border: 1px solid rgba(248,113,113,0.35); border-radius: 16px; background: var(--brand-dark); color: var(--foreground); padding: 0; max-width: 340px; width: 100%; }
.dialog-confirm::backdrop { background: rgba(0,0,0,0.65); backdrop-filter: blur(3px); }
.dialog-confirm .dc-body { padding: 22px; text-align: center; }
.dialog-confirm h4 { font-size: 16px; font-weight: 900; margin-bottom: 6px; }
.dialog-confirm p { font-size: 13px; color: var(--muted-fg); }
.dialog-confirm .dc-actions { display: flex; gap: 8px; padding: 14px 22px 22px; }
.dialog-confirm .dc-actions button { flex: 1; min-height: 44px; border-radius: 10px; font-weight: 800; font-size: 14px; }
.dc-cancel { background: var(--secondary); color: var(--foreground); }
.dc-ok { background: #b91c1c; color: #fff; }

.empty-note { text-align: center; color: var(--muted-fg); font-size: 13px; padding: 26px 0; }

/* الفوتر داخل التدفق الطبيعي (مع flex body): يلتصق بأسفل الشاشة عند الصفحات القصيرة
   ويُدفع طبيعياً تحت المحتوى عند الصفحات الطويلة — لا يغطي أي محتوى أبداً */
.admin-footer { margin-top: auto; background: #110a03; border-top: 1px solid var(--border-soft); text-align: center; font-size: 11px; color: rgba(255,255,255,0.4); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
.admin-footer b { color: rgba(233,168,59,0.85); }

/* ─── حركات الحفظ ─── */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ═══════════ إدارة الطلبات (لوحة التحكم) ═══════════ */
.atab .new-dot {
    display: inline-block; width: 7px; height: 7px; border-radius: 50%;
    background: var(--red); margin-right: 4px; vertical-align: middle;
    box-shadow: 0 0 8px rgba(248,113,113,0.8);
}

.obadge {
    display: inline-flex; align-items: center; gap: 5px;
    font-size: 10.5px; font-weight: 800;
    border-radius: 999px; padding: 3px 10px; white-space: nowrap;
}
.obadge.st-awaiting_send   { background: rgba(233,168,59,0.12);  color: var(--brand-gold); border: 1px solid rgba(233,168,59,0.35); }
.obadge.st-pending_verification { background: rgba(251,191,36,0.12); color: #fbbf24; border: 1px solid rgba(251,191,36,0.4); }
.obadge.st-verified        { background: rgba(74,222,128,0.12);  color: var(--green); border: 1px solid rgba(74,222,128,0.4); }
.obadge.st-rejected        { background: rgba(248,113,113,0.12); color: var(--red); border: 1px solid rgba(248,113,113,0.4); }
.obadge.st-completed       { background: rgba(255,255,255,0.07); color: var(--foreground); border: 1px solid var(--border); }
.obadge.st-cancelled       { background: rgba(255,255,255,0.05); color: var(--muted-fg); border: 1px solid var(--border); }

.orders-list { display: flex; flex-direction: column; gap: 10px; }
.ord {
    display: flex; align-items: center; gap: 12px;
    border: 1px solid var(--border-soft); border-radius: 14px;
    background: var(--brand-dark); padding: 13px 14px;
    transition: border-color 0.15s;
}
.ord:hover { border-color: rgba(233,168,59,0.35); }
.ord-ref { font-weight: 900; font-size: 13.5px; letter-spacing: 0.5px; color: var(--brand-gold); }
.ord-meta { display: flex; flex-wrap: wrap; gap: 5px 10px; font-size: 11px; color: var(--muted-fg); font-weight: 700; margin-top: 3px; align-items: center; }
.ord-total { font-size: 14px; font-weight: 900; white-space: nowrap; }
.ord-actions { display: flex; align-items: center; gap: 8px; }

.ord-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.ord-kv { font-size: 13px; display: flex; flex-direction: column; gap: 2px; }
.ord-kv span { color: var(--muted-fg); font-size: 11px; font-weight: 700; }
.ord-kv b { font-weight: 800; }

.oi-row {
    display: flex; align-items: center; gap: 10px;
    border: 1px solid var(--border-soft); border-radius: 10px;
    padding: 8px 10px; margin-bottom: 7px; background: var(--card);
}
.oi-name { flex: 1; font-size: 13px; font-weight: 700; }
.oi-qty { font-size: 12px; font-weight: 800; color: var(--muted-fg); }
.oi-sum { font-size: 13px; font-weight: 800; color: var(--brand-gold); }

.receipt-view { max-width: 320px; width: 100%; border-radius: 14px; border: 2px solid rgba(233,168,59,0.4); background: #fff; }
.receipt-empty {
    border: 2px dashed var(--border); border-radius: 14px;
    padding: 26px 14px; text-align: center; color: var(--muted-fg);
    font-size: 12.5px; font-weight: 700;
}

.status-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.status-actions button, .status-actions a.sab {
    display: inline-flex; align-items: center; gap: 6px;
    min-height: 42px; padding: 0 16px; border-radius: 10px;
    font-size: 13px; font-weight: 800; border: 1px solid var(--border);
    background: var(--card); color: var(--foreground);
    transition: all 0.15s;
}
.status-actions button:hover { border-color: rgba(233,168,59,0.5); }
.sab-verify { background: rgba(74,222,128,0.12) !important; color: var(--green) !important; border-color: rgba(74,222,128,0.4) !important; }
.sab-reject { background: rgba(248,113,113,0.1) !important; color: var(--red) !important; border-color: rgba(248,113,113,0.4) !important; }
.sab-done   { background: rgba(233,168,59,0.1) !important; color: var(--brand-gold) !important; border-color: rgba(233,168,59,0.4) !important; }

.pay-toggle-row {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    border: 1px solid var(--border); border-radius: 12px;
    padding: 12px 14px; margin-bottom: 10px; background: var(--card);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.pay-toggle-row .pt-info { font-size: 13.5px; font-weight: 800; }
.pay-toggle-row .pt-info small { display: block; color: var(--muted-fg); font-weight: 500; font-size: 11.5px; margin-top: 2px; }

.acard-title .qr-status { font-size: 11px; font-weight: 800; margin-right: 8px; }
.qr-status.ok { color: var(--green); }
.qr-status.missing { color: var(--red); }

.admin-note {
    border: 1px dashed rgba(233,168,59,0.4); border-radius: 12px;
    background: rgba(233,168,59,0.05); color: var(--muted-fg);
    font-size: 11.5px; font-weight: 600; line-height: 1.8;
    padding: 10px 12px; margin-top: 10px;
}

@media (max-width: 480px) {
    .ord-detail-grid { grid-template-columns: 1fr; }
    .ord { flex-wrap: wrap; }
    .ord-actions { margin-right: auto; }
}

/* ═══════════════════════════════════════════════════════════
   لوحة التحكم: قسمَي صور QR شام كاش (استلام / دليفري) + الصورة القديمة
   ═══════════════════════════════════════════════════════════ */
.admin-warn {
    border: 1px dashed rgba(248,113,113,0.5); border-radius: 12px;
    background: rgba(248,113,113,0.07); color: var(--red);
    font-size: 12px; font-weight: 700; line-height: 1.9;
    padding: 10px 12px; margin-top: 10px;
}

.qr-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.qr-card {
    border: 1px solid var(--border); border-radius: 14px;
    background: rgba(255,255,255,0.02);
    padding: 14px;
}
.qr-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.qr-card-title { font-size: 13.5px; font-weight: 800; display: flex; align-items: center; gap: 6px; }
.qr-card-head .qr-status { font-size: 11px; font-weight: 800; }
.qr-card-sub { color: var(--muted-fg); font-size: 11.5px; line-height: 1.8; margin: 6px 0 12px; }
@media (max-width: 760px) { .qr-cards { grid-template-columns: 1fr; } }

/* صندوق الصورة القديمة (من قبل التحديث) — انتظار تعيين المدير لها */
.legacy-box {
    border: 1px dashed rgba(233,168,59,0.5); border-radius: 14px;
    background: rgba(233,168,59,0.06);
    padding: 14px 16px;
}
.legacy-info > b { font-size: 13.5px; display: block; margin-bottom: 6px; }
.legacy-info p { color: var(--muted-fg); font-size: 12px; font-weight: 600; line-height: 1.9; margin-bottom: 4px; }
.legacy-flex { display: flex; gap: 12px; align-items: flex-start; }
@media (max-width: 560px) { .legacy-flex { flex-direction: column; } }
.legacy-thumb {
    width: 110px; height: 110px; object-fit: contain; flex-shrink: 0;
    border-radius: 12px; background: #fff; padding: 6px;
    border: 1px solid rgba(233,168,59,0.4);
}
.legacy-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.inline-form { display: inline-flex; margin: 0; }
.btn-sm { padding: 8px 14px; font-size: 12.5px; min-height: 40px; border-radius: 10px; gap: 6px; }

/* ═══════════════════════════════════════════════════════════
   لوحة التحكم: بطاقة تغيير كلمة سر اللوحة (تحتاج كلمة السر الحالية)
   ═══════════════════════════════════════════════════════════ */
/* الحقول داخل pw-wrap بعرض كامل + مساحة يسار لزر العين (حتى لا تخرج العين خارج الحقل) */
.pw-wrap { position: relative; display: block; }
.pw-wrap input { width: 100%; padding-left: 42px; }
.pw-toggle.pw-on { color: var(--brand-gold); }

/* ═══════════════════════════════════════════════════════════
   لوحة التحكم — تجاوب الجوال (≤640px)
   إعادة تصميم التبويبات وصفوف الأقسام والأصناف لتناسب أبعاد الموبايل
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 640px) {

    /* شريط التبويبات: صفّان متوازنان بدل قصّ الأسماء — يصلح للتبويبات الأربع
       وللتبويبات الفرعية لصفحة الطلبات (الكل + الحالات) */
    .admin-tabs { flex-wrap: wrap; gap: 5px; }
    .atab { flex: 1 1 calc(50% - 3px); min-width: calc(50% - 3px); font-size: 13px; padding: 8px 6px; }

    /* أدوات المنيو: البحث بصف كامل، ثم الفلتر وزر الصنف الجديد يتشاركان الصف الثاني */
    .items-toolbar { gap: 8px; }
    .items-toolbar .search-box { flex: 1 1 100%; width: auto; }
    .items-toolbar select { flex: 1 1 auto; min-width: 0; height: 44px; }
    .items-toolbar > .btn-gold.sm { flex: 0 0 auto; }

    /* صفوف الأصناف: الصورة والاسم بالصف الأول والإجراءات بصف ثانٍ مرتب */
    .aitem { flex-wrap: wrap; row-gap: 10px; }
    .aitem-info { flex: 1 1 0; min-width: 140px; }
    .aitem-actions { flex: 1 1 100%; justify-content: flex-end; padding-top: 2px; border-top: 1px dashed var(--border-soft); }

    /* صفوف الأقسام: الأيقونة والاسم بالصف الأول، والعدّاد والحذف بالصف الثاني
       — لا يخرج أي زر خارج الشاشة كما كان يحدث */
    .acat { flex-wrap: wrap; row-gap: 10px; }
    .acat form { flex: 1 1 0; min-width: 170px; }
    .acat form .btn-ghost,
    .acat form .btn-gold { flex-shrink: 0; }
    .acat > .cat-count { order: 3; }
    .acat > .icon-btn.del { order: 4; margin-inline-start: auto; }

    /* رأس الصفحة: تصغير طفيف ليتنفس أفضل على الشاشات الضيقة */
    .admin-header-inner { padding: 10px 12px; gap: 8px; }
    .admin-main { padding: 14px 12px 24px; }
    .acard { padding: 14px; }
}
