:root{--bg:#f3f6fb;--panel:#ffffff;--text:#0f172a;--muted:#64748b;--line:#dbe4f0;--accent:#2563eb;--sidebar:#0f172a;--sidebarText:#e2e8f0;--radius:18px}
*{box-sizing:border-box}html,body{margin:0;padding:0;font:14px/1.45 Inter,Segoe UI,Arial,sans-serif;color:var(--text);background:var(--bg)}
a{text-decoration:none;color:inherit}
.panel-shell{display:grid;grid-template-columns:280px 1fr;min-height:100vh}
.sidebar{background:var(--sidebar);color:var(--sidebarText);padding:20px;position:sticky;top:0;height:100vh;overflow:auto}
.brand{display:flex;gap:12px;align-items:center;padding:10px 8px 18px;border-bottom:1px solid rgba(255,255,255,.08);margin-bottom:16px}
.brand strong{display:block;font-size:18px}.brand span{font-size:12px;opacity:.7}
.brand-logo{width:auto;max-width:150px;height:48px;object-fit:contain;border-radius:10px;background:#fff;padding:4px}
.menu{display:flex;flex-direction:column;gap:6px}.menu a{padding:10px 12px;border-radius:12px;color:var(--sidebarText);opacity:.92}
.menu a:hover,.menu a.active{background:rgba(255,255,255,.08);opacity:1}
.main{padding:24px;min-width:0;overflow:auto}
.topbar{display:flex;justify-content:space-between;align-items:center;margin-bottom:16px}
h1{font-size:28px;margin:0 0 8px}h2{font-size:20px;margin:0 0 12px}
.user{background:#fff;border:1px solid var(--line);padding:8px 12px;border-radius:999px}
.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px}
.card{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);padding:18px;box-shadow:0 8px 28px rgba(15,23,42,.04)}
table{width:100%;border-collapse:collapse;background:#fff;border-radius:14px;overflow:hidden;border:1px solid var(--line)}
th,td{padding:11px 12px;border-bottom:1px solid #eef2f7;text-align:left;vertical-align:top}
th{font-size:12px;text-transform:uppercase;letter-spacing:.04em;color:var(--muted);background:#f8fafc}
tr:last-child td{border-bottom:none}
.form-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:14px}
label{display:flex;flex-direction:column;gap:6px;font-weight:600;color:#334155}
input,textarea,select{width:100%;padding:11px 12px;border:1px solid var(--line);border-radius:12px;background:#fff;font:inherit}
textarea{min-height:120px;resize:vertical}
.actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}
.btn{display:inline-flex;align-items:center;justify-content:center;padding:10px 14px;border-radius:12px;border:1px solid var(--line);background:#fff;color:#0f172a;cursor:pointer}
.btn.primary{background:var(--accent);border-color:var(--accent);color:#fff}
.btn.danger{background:#ef4444;border-color:#ef4444;color:#fff}
.btn.muted{background:#f8fafc}
.flash{background:#dcfce7;border:1px solid #86efac;color:#166534;padding:12px 14px;border-radius:12px;margin:0 0 16px}
.small{font-size:12px;color:var(--muted)} .two{display:grid;grid-template-columns:1.2fr .8fr;gap:18px}
.badge{display:inline-block;padding:4px 8px;border-radius:999px;background:#eef2ff;color:#3730a3;font-size:12px}
.inline{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.code{font-family:ui-monospace,SFMono-Regular,Menlo,monospace}
.kpi{font-size:32px;font-weight:800;margin-top:6px}
.thumb{width:56px;height:56px;object-fit:cover;border-radius:10px;border:1px solid var(--line)}
.toolbar{position:sticky;top:0;background:#fff;border-bottom:1px solid var(--line);padding:12px;z-index:3}
@media(max-width:960px){.panel-shell{grid-template-columns:1fr}.sidebar{position:relative;height:auto}.two{grid-template-columns:1fr}}


/* v39 UI balance + menu icons */
body{min-height:100vh}
.panel-shell{display:grid;grid-template-columns:280px 1fr;min-height:100vh;align-items:stretch}
.sidebar{min-height:100vh;position:sticky;top:0;align-self:start}
.main{min-height:100vh;padding-bottom:36px}
.main > .card,.main > .two,.main > .three{position:relative}
.menu a{position:relative;padding-left:42px}
.menu a::before{content:"";position:absolute;left:14px;top:50%;width:16px;height:16px;transform:translateY(-50%);opacity:.95;border-radius:4px;background:rgba(255,255,255,.18)}
.menu a[href*="index.php"]::before{clip-path:polygon(50% 0,100% 38%,100% 100%,0 100%,0 38%)}
.menu a[href*="pages.php"]::before{background:linear-gradient(180deg,rgba(255,255,255,.8),rgba(255,255,255,.25))}
.menu a[href*="import-site.php"]::before{clip-path:polygon(50% 0,100% 50%,50% 100%,0 50%)}
.menu a[href*="media.php"]::before{border-radius:50%}
.menu a[href*="seo.php"]::before{clip-path:polygon(0 50%,45% 0,100% 50%,45% 100%)}
.menu a[href*="products.php"]::before{clip-path:polygon(12% 18%,88% 18%,88% 82%,12% 82%)}
.menu a[href*="orders.php"]::before{clip-path:polygon(20% 12%,80% 12%,80% 88%,20% 88%)}
.menu a[href*="discounts.php"]::before{clip-path:polygon(0 35%,35% 0,100% 65%,65% 100%)}
.menu a[href*="shipping.php"]::before{clip-path:polygon(10% 25%,78% 25%,92% 45%,92% 75%,10% 75%)}
.menu a[href*="payments.php"]::before{clip-path:polygon(5% 25%,95% 25%,95% 75%,5% 75%)}
.menu a[href*="shop-settings.php"]::before{clip-path:polygon(50% 0,64% 18%,88% 12%,82% 36%,100% 50%,82% 64%,88% 88%,64% 82%,50% 100%,36% 82%,12% 88%,18% 64%,0 50%,18% 36%,12% 12%,36% 18%)}
.menu a[href*="ads-tags.php"]::before{clip-path:polygon(50% 0,100% 100%,0 100%)}
.menu a[href*="header-footer.php"]::before{clip-path:polygon(0 0,100% 0,100% 25%,0 25%,0 75%,100% 75%,100% 100%,0 100%)}
.menu a[href*="settings.php"]::before{clip-path:polygon(50% 0,64% 18%,88% 12%,82% 36%,100% 50%,82% 64%,88% 88%,64% 82%,50% 100%,36% 82%,12% 88%,18% 64%,0 50%,18% 36%,12% 12%,36% 18%)}
.menu a[href*="users.php"]::before{clip-path:polygon(32% 28%,68% 28%,68% 56%,32% 56%,18% 86%,82% 86%)}
.menu a[href*="whitelabel.php"]::before{clip-path:polygon(50% 0,61% 35%,98% 35%,68% 57%,79% 91%,50% 70%,21% 91%,32% 57%,2% 35%,39% 35%)}
.menu a[href*="plugins.php"]::before{clip-path:polygon(25% 0,75% 0,75% 25%,100% 25%,100% 75%,75% 75%,75% 100%,25% 100%,25% 75%,0 75%,0 25%,25% 25%)}
.menu a[href*="ai-repair.php"]::before{clip-path:polygon(50% 0,83% 17%,100% 50%,83% 83%,50% 100%,17% 83%,0 50%,17% 17%)}
@media(max-width:980px){
  .panel-shell{grid-template-columns:1fr}
  .sidebar{position:relative;min-height:auto}
}


/* v40 modern sidebar + balanced scroll layout */
html,body{height:100%}
body{overflow-x:hidden}
.panel-shell{display:grid;grid-template-columns:260px minmax(0,1fr);min-height:100vh}
.sidebar{min-height:100vh;position:sticky;top:0;display:flex;flex-direction:column}
.menu{overflow:auto;padding-bottom:20px}
.main{min-width:0;min-height:100vh;padding:24px}
.main .card,.main .two,.main .three{min-width:0}
.card{overflow:hidden}
.menu a{position:relative;padding:12px 14px 12px 50px;border-radius:14px;margin:4px 0;font-weight:600}
.menu a::before{content:"";position:absolute;left:14px;top:50%;transform:translateY(-50%);width:22px;height:22px;border-radius:7px;background-color:rgba(255,255,255,.16);background-repeat:no-repeat;background-position:center;background-size:15px 15px;box-shadow:inset 0 0 0 1px rgba(255,255,255,.08)}
.menu a:hover,.menu a.active{background:rgba(255,255,255,.09)}
.menu a[href*="index.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 10.5 12 3l9 7.5'/%3E%3Cpath d='M5.5 9.5V20h13V9.5'/%3E%3Cpath d='M9.5 20v-6h5v6'/%3E%3C/svg%3E")}
.menu a[href*="pages.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='3.5' width='14' height='17' rx='2'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h5'/%3E%3C/svg%3E")}
.menu a[href*="import-site.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 4v11'/%3E%3Cpath d='m7.5 10.5 4.5 4.5 4.5-4.5'/%3E%3Cpath d='M4 19.5h16'/%3E%3C/svg%3E")}
.menu a[href*="media.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='14' rx='2'/%3E%3Ccircle cx='9' cy='10' r='1.4'/%3E%3Cpath d='m7 17 4.2-4.2a1 1 0 0 1 1.4 0L17 17'/%3E%3C/svg%3E")}
.menu a[href*="seo.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='5.5'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E")}
.menu a[href*="products.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 7h12l-1.2 10.2a2 2 0 0 1-2 1.8H9.2a2 2 0 0 1-2-1.8L6 7Z'/%3E%3Cpath d='M9 7a3 3 0 0 1 6 0'/%3E%3C/svg%3E")}
.menu a[href*="orders.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3 4.5 7v10L12 21l7.5-4V7L12 3Z'/%3E%3Cpath d='m4.5 7 7.5 4 7.5-4M12 11v10'/%3E%3C/svg%3E")}
.menu a[href*="discounts.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 8.5V6.8A1.8 1.8 0 0 1 7.8 5h8.4A1.8 1.8 0 0 1 18 6.8v1.7l-6 10-6-10Z'/%3E%3Ccircle cx='9' cy='9' r='1' fill='%23fff' stroke='none'/%3E%3Cpath d='m10 15 4-4'/%3E%3Ccircle cx='15' cy='14' r='1' fill='%23fff' stroke='none'/%3E%3C/svg%3E")}
.menu a[href*="shipping.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h10v7H4zM14 10h3l2 2v2h-5z'/%3E%3Ccircle cx='8' cy='18' r='1.8'/%3E%3Ccircle cx='17' cy='18' r='1.8'/%3E%3C/svg%3E")}
.menu a[href*="payments.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='6' width='17' height='12' rx='2'/%3E%3Cpath d='M3.5 10h17'/%3E%3Cpath d='M7.5 14.5h3.5'/%3E%3C/svg%3E")}
.menu a[href*="shop-settings.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3.2'/%3E%3Cpath d='M19.4 15a1 1 0 0 0 .2 1.1l.1.1a2 2 0 0 1-2.8 2.8l-.1-.1a1 1 0 0 0-1.1-.2 1 1 0 0 0-.6.9V20a2 2 0 0 1-4 0v-.2a1 1 0 0 0-.6-.9 1 1 0 0 0-1.1.2l-.1.1a2 2 0 1 1-2.8-2.8l.1-.1a1 1 0 0 0 .2-1.1 1 1 0 0 0-.9-.6H4a2 2 0 0 1 0-4h.2a1 1 0 0 0 .9-.6 1 1 0 0 0-.2-1.1l-.1-.1a2 2 0 1 1 2.8-2.8l.1.1a1 1 0 0 0 1.1.2 1 1 0 0 0 .6-.9V4a2 2 0 0 1 4 0v.2a1 1 0 0 0 .6.9 1 1 0 0 0 1.1-.2l.1-.1a2 2 0 1 1 2.8 2.8l-.1.1a1 1 0 0 0-.2 1.1 1 1 0 0 0 .9.6H20a2 2 0 0 1 0 4h-.2a1 1 0 0 0-.9.6Z'/%3E%3C/svg%3E")}
.menu a[href*="shop-tests.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 3h6'/%3E%3Cpath d='M10 3v3'/%3E%3Cpath d='M14 3v3'/%3E%3Cpath d='M8 8h8l2 4-6 9-6-9 2-4Z'/%3E%3Cpath d='M9.3 12.2 12 15l2.7-2.8'/%3E%3C/svg%3E")}
.menu a[href*="galleries.php"]::before,.menu a[href*="gallery.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='14' rx='2'/%3E%3Cpath d='m7 16 3.5-3.5a1 1 0 0 1 1.4 0L15 15l1-1a1 1 0 0 1 1.4 0l2.1 2.1'/%3E%3Ccircle cx='9' cy='9.5' r='1.3'/%3E%3C/svg%3E")}
.menu a[href*="gallery-queue-monitor.php"]::before,.menu a[href*="gallery-queue.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 5.5h12'/%3E%3Cpath d='M6 12h8'/%3E%3Cpath d='M6 18.5h10'/%3E%3Ccircle cx='18' cy='12' r='3.5'/%3E%3Cpath d='m18 10.8 1 1v1.4'/%3E%3C/svg%3E")}
.menu a[href*="ads-tags.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 14V10a2 2 0 0 1 2-2h3l5-3v14l-5-3H6a2 2 0 0 1-2-2Z'/%3E%3Cpath d='M16.5 9.5a4.5 4.5 0 0 1 0 5'/%3E%3C/svg%3E")}
.menu a[href*="cookie-consent.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12.5 4.5a5 5 0 1 0 7 7 6.5 6.5 0 1 1-7-7Z'/%3E%3Ccircle cx='14.4' cy='8.3' r='.8' fill='%23fff' stroke='none'/%3E%3Ccircle cx='10.3' cy='13.6' r='.9' fill='%23fff' stroke='none'/%3E%3Ccircle cx='15.2' cy='14.5' r='.7' fill='%23fff' stroke='none'/%3E%3C/svg%3E")}
.menu a[href*="header-footer.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6.5h16M4 17.5h16'/%3E%3Crect x='6' y='9' width='12' height='6' rx='1.5'/%3E%3C/svg%3E")}
.menu a[href*="settings.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h6'/%3E%3Cpath d='M14 7h6'/%3E%3Cpath d='M8 7a2 2 0 1 0 4 0 2 2 0 0 0-4 0Zm4 10H4'/%3E%3Cpath d='M20 17h-4'/%3E%3Cpath d='M12 17a2 2 0 1 0 4 0 2 2 0 0 0-4 0Z'/%3E%3C/svg%3E")}
.menu a[href*="updates.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 12a8 8 0 1 1-2.3-5.7'/%3E%3Cpath d='M20 4v5h-5'/%3E%3Cpath d='M12 8v4l2.5 1.5'/%3E%3C/svg%3E")}
.menu a[href*="users.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M16 19a4 4 0 0 0-8 0'/%3E%3Ccircle cx='12' cy='11' r='3'/%3E%3Cpath d='M19 19a3.5 3.5 0 0 0-3-3.5'/%3E%3C/svg%3E")}
.menu a[href*="whitelabel.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 3 2.2 4.5 5 .7-3.6 3.5.9 5-4.5-2.4-4.5 2.4.9-5L4.8 8.2l5-.7L12 3Z'/%3E%3C/svg%3E")}
.menu a[href*="plugins.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 3v5'/%3E%3Cpath d='M15 16v5'/%3E%3Cpath d='M6 8h6a3 3 0 0 1 0 6H6V8Zm6 2h6v6h-6a3 3 0 0 1 0-6Z'/%3E%3C/svg%3E")}
.menu a[href*="ai-repair.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='7' y='7' width='10' height='10' rx='2'/%3E%3Cpath d='M9 2v3M15 2v3M9 19v3M15 19v3M2 9h3M2 15h3M19 9h3M19 15h3M10 10h4M10 14h4'/%3E%3C/svg%3E")}
.menu a[href*="chatgpt-browser.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8'/%3E%3Cpath d='M4 12h16M12 4a12 12 0 0 1 0 16M12 4a12 12 0 0 0 0 16'/%3E%3C/svg%3E")}
.menu a[href*="code.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 8-4 4 4 4M15 8l4 4-4 4'/%3E%3C/svg%3E")}
.menu a[href*="developer.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m8 8-3 4 3 4M16 8l3 4-3 4M10.5 19l3-14'/%3E%3C/svg%3E")}
.menu a[href*="logout.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 4H6a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h4'/%3E%3Cpath d='m13 8 5 4-5 4M9 12h9'/%3E%3C/svg%3E")}
.topbar{display:flex;align-items:center;justify-content:space-between;gap:16px}
.two,.three{align-items:start}
@media(max-width:980px){
  .panel-shell{grid-template-columns:1fr}
  .sidebar{position:relative;min-height:auto}
  .main{padding:18px}
}


/* v41 global admin layout */
html,body{height:100%}
body{
  overflow:hidden;
  background:#f3f6fb;
}
.panel-shell{
  display:grid;
  grid-template-columns:270px minmax(0,1fr);
  height:100vh;
  min-height:100vh;
  overflow:hidden;
}
.sidebar{
  width:auto;
  min-height:100vh;
  height:100vh;
  position:relative;
  top:auto;
  align-self:stretch;
  overflow-y:auto;
  overflow-x:hidden;
  background:linear-gradient(180deg,#08162f 0%,#0b1e3b 100%);
  border-right:1px solid rgba(255,255,255,.08);
  padding:18px 14px 18px 14px;
}
.sidebar::-webkit-scrollbar,
.main::-webkit-scrollbar,
.ai-scroll::-webkit-scrollbar{
  width:10px;
  height:10px;
}
.sidebar::-webkit-scrollbar-thumb,
.main::-webkit-scrollbar-thumb,
.ai-scroll::-webkit-scrollbar-thumb{
  background:rgba(148,163,184,.35);
  border-radius:999px;
}
.main{
  min-width:0;
  width:100%;
  height:100vh;
  min-height:100vh;
  overflow-y:auto;
  overflow-x:hidden;
  padding:24px;
  background:linear-gradient(180deg,#f5f8fc 0%,#eef3f9 100%);
}
.main > *{
  max-width:100%;
}
.topbar{
  position:sticky;
  top:0;
  z-index:20;
  backdrop-filter:blur(10px);
  background:rgba(245,248,252,.88);
  border:1px solid #dbe4f0;
  border-radius:22px;
  padding:18px 22px;
  margin-bottom:18px;
  box-shadow:0 10px 28px rgba(15,23,42,.05);
}
.brand{
  display:flex !important;
  align-items:center;
  gap:12px;
  padding:10px 10px 16px;
  margin-bottom:10px;
  border-bottom:1px solid rgba(255,255,255,.08);
}
.brand-logo{
  width:46px !important;
  height:46px !important;
  max-width:46px !important;
  max-height:46px !important;
  border-radius:14px;
  object-fit:contain;
  background:#fff;
  padding:4px;
  box-shadow:0 8px 22px rgba(15,23,42,.18);
}
.brand strong{
  color:#fff;
  font-size:18px;
  line-height:1.1;
}
.brand span{
  color:rgba(255,255,255,.65) !important;
  font-size:12px;
}
.menu{
  display:flex;
  flex-direction:column;
  gap:6px;
  overflow-y:auto;
  padding-right:2px;
}
.menu a{
  display:flex;
  align-items:center;
  gap:12px;
  position:relative;
  padding:12px 14px 12px 14px;
  min-height:46px;
  color:rgba(255,255,255,.9);
  text-decoration:none;
  border-radius:14px;
  margin:0;
  font-weight:700;
  transition:all .18s ease;
  background:transparent;
}
.menu a::before{
  content:"";
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 22px;
  width:22px;
  height:22px;
  background-repeat:no-repeat !important;
  background-position:center !important;
  background-size:18px 18px !important;
  background-color:rgba(255,255,255,.12) !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.08) !important;
  border-radius:7px;
  position:static;
  transform:none;
}
.menu a:hover{
  background:rgba(255,255,255,.07);
  color:#fff;
}
.menu a.active{
  background:linear-gradient(180deg,rgba(255,255,255,.12) 0%,rgba(255,255,255,.08) 100%);
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.05);
  color:#fff;
}

.card{
  background:linear-gradient(180deg,#ffffff 0%,#fbfdff 100%);
  border:1px solid #dbe4f0;
  border-radius:28px;
  box-shadow:0 16px 36px rgba(15,23,42,.05);
  overflow:hidden;
}
.card h2{
  margin-top:0;
}
.two,.three{
  width:100%;
  max-width:100%;
  display:grid;
  gap:18px;
  align-items:start;
}
.two{grid-template-columns:repeat(2,minmax(0,1fr))}
.three{grid-template-columns:repeat(3,minmax(0,1fr))}
@media(max-width:1100px){
  .three{grid-template-columns:1fr}
}
@media(max-width:980px){
  .panel-shell{grid-template-columns:1fr}
  .sidebar{
    height:auto;
    min-height:auto;
    max-height:none;
    overflow:visible;
  }
  .main{
    height:auto;
    min-height:auto;
    overflow:visible;
    padding:18px;
  }
  .two,.three{grid-template-columns:1fr}
  body{overflow:auto}
}

table{
  width:100%;
  border-collapse:collapse;
}
th,td{
  padding:12px 14px;
  border-bottom:1px solid #edf2f7;
  text-align:left;
  vertical-align:top;
}
th{
  background:#f8fbff;
  color:#61738f;
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.06em;
}
.flash{
  border-radius:18px;
  margin-bottom:16px;
}

.ai-modern,
.ai-columns,
.ai-grid,
.ai-footer-grid{
  max-width:100%;
  min-width:0;
}
.ai-columns{
  display:grid !important;
  grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr) !important;
  gap:18px;
  align-items:start;
}
.ai-card,
.ai-pane{
  min-width:0;
}
.ai-pane{
  height:640px;
}
.ai-pane-body{
  flex:1 1 auto;
  min-height:0;
}
.ai-scroll{
  width:100%;
  max-width:100%;
  height:100%;
  max-height:100%;
  overflow:auto !important;
  border:1px solid #dbe4f0;
  border-radius:18px;
  background:#fff;
}
.ai-scroll table{
  min-width:980px;
}
.ai-footer-grid .ai-card{
  overflow:visible;
}
.ai-restore select{
  width:100%;
}

@media(max-width:1200px){
  .ai-columns{
    grid-template-columns:1fr !important;
  }
  .ai-pane{
    height:520px;
  }
}


/* v43 card opacity + whitelabel sticky bottom bar */
.card,
.topbar,
.ai-card,
.ai-stat,
.ai-scroll,
.ai-pane,
.ai-pane .ai-scroll,
article.card{
  background:rgba(255,255,255,var(--panel-opacity,0.96)) !important;
  backdrop-filter:blur(10px);
}
.whitelabel-bottom-safe{
  position:sticky;
  bottom:0;
  z-index:25;
  margin-top:16px;
  padding:14px 18px;
  border-top:1px solid #dbe4f0;
  background:rgba(255,255,255,var(--panel-opacity,0.96));
  backdrop-filter:blur(10px);
  display:flex;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}


/* v44 whitelabel preview + bottom bar */
.card,
.topbar,
.ai-card,
.ai-stat,
.ai-scroll,
.ai-pane,
.ai-pane .ai-scroll,
article.card{
  background:rgba(255,255,255,var(--panel-opacity,0.96)) !important;
  backdrop-filter:blur(10px);
}
.whitelabel-bottom-safe{
  position:sticky;
  bottom:0;
  z-index:25;
  margin-top:16px;
  padding:14px 18px;
  border-top:1px solid #dbe4f0;
  background:rgba(255,255,255,var(--panel-opacity,0.96));
  backdrop-filter:blur(10px);
  display:flex;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}


/* v46 white-label background visibility */
body.cms-has-wl-bg{
  background: transparent !important;
}
body.cms-has-wl-bg .panel-shell{
  background: transparent !important;
}
body.cms-has-wl-bg .main{
  background: transparent !important;
}
body.cms-has-wl-bg .main::before{
  content:"";
  position:fixed;
  inset:0;
  background:linear-gradient(180deg, rgba(245,248,252,.18) 0%, rgba(238,243,249,.10) 100%);
  pointer-events:none;
  z-index:1;
}
body.cms-has-wl-bg .sidebar{
  background:linear-gradient(180deg, rgba(8,22,47,.96) 0%, rgba(11,30,59,.94) 100%) !important;
}
body.cms-has-wl-bg .topbar,
body.cms-has-wl-bg .card,
body.cms-has-wl-bg .ai-card,
body.cms-has-wl-bg .ai-stat,
body.cms-has-wl-bg .ai-scroll,
body.cms-has-wl-bg article.card{
  background:rgba(255,255,255,var(--panel-opacity,0.78)) !important;
  backdrop-filter:blur(12px);
}
body.cms-has-wl-bg .whitelabel-bottom-safe,
body.cms-has-wl-bg .cms-wl-bottom-bar{
  background:rgba(255,255,255,.76) !important;
  backdrop-filter:blur(12px);
}




/* v48.13 responsive mobile CMS */
.mobile-menu-btn{display:none;align-items:center;justify-content:center;width:42px;height:42px;border-radius:12px;border:1px solid var(--line);background:#fff;color:#0f172a;cursor:pointer;font-size:20px;line-height:1;flex:0 0 42px;box-shadow:0 4px 14px rgba(15,23,42,.05)}
.table-wrap{width:100%;overflow:auto;border-radius:14px}
.card table{display:table}
img{max-width:100%;height:auto}
@media(max-width:980px){
  html,body{height:auto;min-height:100%}
  body{overflow-y:auto !important}
  .mobile-menu-btn{display:inline-flex}
  .topbar{justify-content:flex-start;flex-wrap:wrap}
  .topbar h1{flex:1 1 calc(100% - 60px);min-width:0}
  .topbar .user{margin-left:auto}
  .grid,.form-grid,.two,.three{grid-template-columns:1fr !important}
  .card{padding:14px;border-radius:16px}
  .actions,.inline{gap:8px}
  .actions .btn,.inline .btn,.btn{width:100%;max-width:100%}
  table{display:block;overflow-x:auto;white-space:nowrap}
  th,td{padding:10px}
  input,textarea,select{font-size:16px}
  .thumb{width:48px;height:48px}
  .toolbar{position:static;padding:10px}
  .cms-wl-bottom-wrap{align-items:flex-start}
  .cms-wl-bottom-right{width:100%}
}

/* v49.82 - complete sidebar icon coverage */
.menu a span{position:relative;z-index:1}
.menu a[href*="gallery-orders.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 4h10l1.5 16h-13L7 4Z'/%3E%3Cpath d='M9 8h6M9 12h6M9 16h4'/%3E%3C/svg%3E")}
.menu a[href*="gallery-redirects.php"]::before,.menu a[href*="route-mapping.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 7h9a4 4 0 0 1 0 8H8'/%3E%3Cpath d='m8 11-4 4 4 4'/%3E%3Cpath d='M16 5l3 3-3 3'/%3E%3C/svg%3E")}
.menu a[href*="security.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3 19 6v5c0 4.5-2.8 8-7 10-4.2-2-7-5.5-7-10V6l7-3Z'/%3E%3Cpath d='m9.5 12 1.7 1.7 3.5-4'/%3E%3C/svg%3E")}
.menu a[href*="ai-seo.php"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 18V6h16v12H4Z'/%3E%3Cpath d='M8 14l2.2-4 2.2 4M9 12h2.8M15 10v4M17 10v4'/%3E%3C/svg%3E")}
.menu a[href="/"]::before,.menu a[target="_blank"]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 5h5v5'/%3E%3Cpath d='m10 14 9-9'/%3E%3Cpath d='M19 14v4a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h4'/%3E%3C/svg%3E")}


/* v49.84 - keep existing inline sidebar icons; hide legacy CSS pseudo-icons to prevent duplicates */
.menu a{padding-left:14px !important;}
.menu a::before{display:none !important;content:none !important;background-image:none !important;}
.menu a .menu-ico{display:inline-flex !important;}
