/* ═══════════════════════════════════════════
   SUFAM Admin — Master Stylesheet
   ═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;700;800;900&display=swap');

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

:root{
  --primary:#ea580c;
  --primary-dark:#c2410c;
  --primary-light:#fb923c;
  --primary-soft:#fff7ed;
  --dark:#0f172a;
  --dark-2:#1e293b;
  --bg:#f8fafc;
  --surface:#ffffff;
  --border:#e2e8f0;
  --text:#0f172a;
  --text-soft:#334155;
  --muted:#64748b;
  --success:#059669;
  --danger:#dc2626;
  --warning:#d97706;
  --info:#2563eb;
  --sidebar-w:260px;
  --header-h:64px;
  --radius:14px;
  --radius-sm:10px;
  --shadow-sm:0 1px 3px rgba(15,23,42,.06);
  --shadow-md:0 4px 15px rgba(15,23,42,.08);
  --shadow-lg:0 10px 30px -10px rgba(15,23,42,.15);
  --trans:.25s cubic-bezier(.4,0,.2,1);
}

html,body{
  font-family:'Tajawal',system-ui,-apple-system,sans-serif;
  background:var(--bg);
  color:var(--text);
  direction:rtl;
  line-height:1.7;
  min-height:100vh;
  -webkit-font-smoothing:antialiased;
}

button,input,textarea,select{font-family:inherit;color:inherit}
a{color:inherit;text-decoration:none}
img{max-width:100%;display:block}

/* ═══════════════════════════════════════════
   LOGIN SCREEN
   ═══════════════════════════════════════════ */
.login-screen{
  position:fixed;
  inset:0;
  background:linear-gradient(135deg,#0f172a 0%,#1e293b 50%,#0f172a 100%);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:20px;
  z-index:9999;
  overflow:hidden;
}

.login-screen::before{
  content:'';
  position:absolute;
  top:-50%;
  right:-30%;
  width:80%;
  height:200%;
  background:radial-gradient(circle,rgba(234,88,12,.3),transparent 60%);
  filter:blur(60px);
  pointer-events:none;
}

.login-box{
  position:relative;
  background:linear-gradient(135deg,#ea580c,#c2410c);
  border-radius:24px;
  padding:48px 40px;
  max-width:440px;
  width:100%;
  box-shadow:0 30px 60px -20px rgba(234,88,12,.5);
  overflow:hidden;
  color:#fff;
}

.login-box::before{
  content:'';
  position:absolute;
  top:-50%;
  right:-50%;
  width:200%;
  height:200%;
  background:radial-gradient(circle at 30% 30%,rgba(255,255,255,.15),transparent 55%);
  pointer-events:none;
}

.login-logo{
  font-size:72px;
  text-align:center;
  margin-bottom:20px;
  position:relative;
  filter:drop-shadow(0 8px 20px rgba(0,0,0,.3));
}

.login-title{
  font-size:26px;
  font-weight:900;
  text-align:center;
  margin-bottom:10px;
  position:relative;
}

.login-subtitle{
  font-size:14px;
  text-align:center;
  opacity:.95;
  margin-bottom:32px;
  position:relative;
}

.login-input{
  width:100%;
  background:rgba(255,255,255,.18);
  border:2px solid rgba(255,255,255,.35);
  border-radius:12px;
  padding:16px 18px;
  font-size:16px;
  font-weight:700;
  color:#fff;
  text-align:center;
  outline:none;
  transition:all var(--trans);
  position:relative;
}

.login-input::placeholder{color:rgba(255,255,255,.7);font-weight:500}
.login-input:focus{background:rgba(255,255,255,.28);border-color:#fff;box-shadow:0 0 0 4px rgba(255,255,255,.2)}

.login-btn{
  width:100%;
  background:#fff;
  color:#c2410c;
  border:none;
  border-radius:12px;
  padding:16px;
  font-size:17px;
  font-weight:900;
  cursor:pointer;
  margin-top:14px;
  transition:all var(--trans);
  box-shadow:0 8px 20px -8px rgba(0,0,0,.4);
  position:relative;
}

.login-btn:hover{transform:translateY(-2px);box-shadow:0 12px 26px -8px rgba(0,0,0,.5)}
.login-btn:disabled{opacity:.7;cursor:wait;transform:none}

.login-msg{
  text-align:center;
  font-size:14px;
  margin-top:14px;
  min-height:20px;
  font-weight:800;
  position:relative;
}

.login-message{
  color:#fef08a;
}

.login-success{
  color:#86efac;
}

/* ═══════════════════════════════════════════
   LAYOUT
   ═══════════════════════════════════════════ */
.admin-layout{
  display:none;
  min-height:100vh;
}

.admin-layout.active{display:block}

/* ═══════════════════════════════════════════
   SIDEBAR
   ═══════════════════════════════════════════ */
.sidebar{
  position:fixed;
  top:0;
  right:0;
  width:var(--sidebar-w);
  height:100vh;
  background:linear-gradient(180deg,#0f172a 0%,#1e293b 100%);
  color:#fff;
  z-index:100;
  overflow-y:auto;
  transition:transform var(--trans);
  box-shadow:-4px 0 20px rgba(0,0,0,.15);
}

.sidebar::-webkit-scrollbar{width:6px}
.sidebar::-webkit-scrollbar-track{background:rgba(255,255,255,.05)}
.sidebar::-webkit-scrollbar-thumb{background:var(--primary);border-radius:3px}

.sidebar-header{
  padding:24px 20px;
  display:flex;
  align-items:center;
  gap:12px;
  border-bottom:1px solid rgba(255,255,255,.1);
}

.sidebar-header img{
  width:44px;
  height:44px;
  border-radius:10px;
  object-fit:contain;
  filter:drop-shadow(0 4px 10px rgba(251,146,60,.5));
}

.sidebar-title{
  flex:1;
  min-width:0;
}

.sidebar-title h1{
  font-size:17px;
  font-weight:900;
  color:#fb923c;
  line-height:1.2;
}

.sidebar-title span{
  font-size:11px;
  color:#94a3b8;
  font-weight:600;
}

.sidebar-nav{
  padding:16px 10px;
}

.nav-section{
  margin-bottom:20px;
}

.nav-section-title{
  font-size:10px;
  font-weight:900;
  color:#64748b;
  letter-spacing:1.5px;
  text-transform:uppercase;
  padding:0 12px 8px;
}

.nav-item{
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px 14px;
  border-radius:10px;
  margin-bottom:4px;
  cursor:pointer;
  transition:all var(--trans);
  color:#cbd5e1;
  font-weight:700;
  font-size:14px;
  position:relative;
  border:1px solid transparent;
}

.nav-item:hover{
  background:rgba(234,88,12,.1);
  color:#fff;
  border-color:rgba(234,88,12,.3);
}

.nav-item.active{
  background:linear-gradient(135deg,#ea580c,#c2410c);
  color:#fff;
  box-shadow:0 6px 15px -6px rgba(234,88,12,.7);
}

.nav-icon{
  width:22px;
  height:22px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  font-size:18px;
}

.nav-label{
  flex:1;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.nav-badge{
  background:rgba(255,255,255,.15);
  color:#fff;
  font-size:10px;
  padding:2px 8px;
  border-radius:999px;
  font-weight:900;
}

.nav-item.active .nav-badge{
  background:rgba(255,255,255,.3);
}

.sidebar-footer{
  padding:16px 20px;
  border-top:1px solid rgba(255,255,255,.1);
  margin-top:auto;
}

.sidebar-user{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:12px;
}

.sidebar-user-avatar{
  width:36px;
  height:36px;
  border-radius:50%;
  background:linear-gradient(135deg,#ea580c,#c2410c);
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:900;
  font-size:15px;
  flex-shrink:0;
}

.sidebar-user-info{flex:1;min-width:0}
.sidebar-user-name{font-size:13px;font-weight:900;color:#fff;line-height:1.2}
.sidebar-user-status{font-size:10px;color:#4ade80;font-weight:700}

.logout-btn{
  width:100%;
  background:rgba(220,38,38,.15);
  color:#fca5a5;
  border:1px solid rgba(220,38,38,.3);
  padding:10px;
  border-radius:10px;
  cursor:pointer;
  font-weight:800;
  font-size:13px;
  transition:all var(--trans);
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
}

.logout-btn:hover{
  background:#dc2626;
  color:#fff;
  border-color:#dc2626;
}

/* ═══════════════════════════════════════════
   MAIN CONTENT
   ═══════════════════════════════════════════ */
.main{
  margin-right:var(--sidebar-w);
  min-height:100vh;
  display:flex;
  flex-direction:column;
}

.topbar{
  background:#fff;
  height:var(--header-h);
  display:flex;
  align-items:center;
  padding:0 24px;
  border-bottom:1px solid var(--border);
  position:sticky;
  top:0;
  z-index:50;
  gap:12px;
  box-shadow:var(--shadow-sm);
}

.menu-toggle{
  display:none;
  width:42px;
  height:42px;
  border-radius:10px;
  background:var(--primary-soft);
  color:var(--primary);
  border:none;
  cursor:pointer;
  font-size:20px;
}

.topbar-title{
  flex:1;
  min-width:0;
}

.topbar-title h2{
  font-size:18px;
  font-weight:900;
  color:var(--text);
  line-height:1.2;
}

.topbar-title p{
  font-size:12px;
  color:var(--muted);
  font-weight:600;
}

.topbar-actions{
  display:flex;
  align-items:center;
  gap:8px;
}

.topbar-btn{
  width:42px;
  height:42px;
  border-radius:10px;
  background:var(--bg);
  color:var(--text-soft);
  border:1.5px solid var(--border);
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:all var(--trans);
  font-size:17px;
  position:relative;
}

.topbar-btn:hover{
  background:var(--primary-soft);
  color:var(--primary);
  border-color:var(--primary);
}

.content{
  flex:1;
  padding:20px;
  position:relative;
}

/* ═══════════════════════════════════════════
   IFRAME
   ═══════════════════════════════════════════ */
.iframe-wrap{
  width:100%;
  height:calc(100vh - var(--header-h) - 40px);
  border-radius:var(--radius);
  overflow:hidden;
  background:#fff;
  border:1.5px solid var(--border);
  box-shadow:var(--shadow-sm);
  position:relative;
}

.iframe-wrap iframe{
  width:100%;
  height:100%;
  border:none;
  display:block;
}

.iframe-loader{
  position:absolute;
  inset:0;
  background:rgba(255,255,255,.95);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:14px;
  z-index:10;
  transition:opacity .3s;
}

.iframe-loader.hidden{opacity:0;pointer-events:none}

.spinner{
  width:44px;
  height:44px;
  border:4px solid rgba(234,88,12,.15);
  border-top-color:var(--primary);
  border-radius:50%;
  animation:spin 1s linear infinite;
}

@keyframes spin{to{transform:rotate(360deg)}}

.iframe-loader p{
  font-size:14px;
  color:var(--primary);
  font-weight:800;
}

/* ═══════════════════════════════════════════
   SIDEBAR BACKDROP (Mobile)
   ═══════════════════════════════════════════ */
.sidebar-backdrop{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(15,23,42,.5);
  z-index:99;
  backdrop-filter:blur(4px);
}

.sidebar-backdrop.active{display:block}

/* ═══════════════════════════════════════════
   TOAST
   ═══════════════════════════════════════════ */
.toast{
  position:fixed;
  bottom:24px;
  left:50%;
  transform:translateX(-50%) translateY(80px);
  background:var(--dark);
  color:#fff;
  padding:14px 24px;
  border-radius:12px;
  font-weight:800;
  font-size:14px;
  z-index:9999;
  opacity:0;
  transition:all .3s;
  box-shadow:0 10px 30px rgba(15,23,42,.4);
  max-width:90vw;
  text-align:center;
}

.toast.show{opacity:1;transform:translateX(-50%) translateY(0)}
.toast.success{background:linear-gradient(135deg,#059669,#047857)}
.toast.error{background:linear-gradient(135deg,#dc2626,#b91c1c)}
.toast.info{background:linear-gradient(135deg,#2563eb,#1d4ed8)}

/* ═══════════════════════════════════════════
   MOBILE
   ═══════════════════════════════════════════ */
@media (max-width:1024px){
  .sidebar{transform:translateX(100%)}
  .sidebar.open{transform:translateX(0)}
  .main{margin-right:0}
  .menu-toggle{display:flex}
  .content{padding:14px}
  .iframe-wrap{height:calc(100vh - var(--header-h) - 28px)}
}

@media (max-width:640px){
  .topbar{padding:0 14px}
  .topbar-title h2{font-size:15px}
  .topbar-title p{font-size:11px}
  .topbar-btn{width:38px;height:38px;font-size:15px}
  .login-box{padding:36px 26px;border-radius:20px}
  .login-logo{font-size:56px}
  .login-title{font-size:22px}
  .toast{left:14px;right:14px;transform:translateY(80px)}
  .toast.show{transform:translateY(0)}
}

/* ═══════════════════════════════════════════
   UTILITIES
   ═══════════════════════════════════════════ */
.hidden{display:none !important}

/* ═══════════════════════════════════════════
   🌙 DARK MODE
   ═══════════════════════════════════════════ */
html.is-dark {
  --bg: #0b1120;
  --surface: #111827;
  --border: #1f2937;
  --text: #e5e7eb;
  --text-soft: #cbd5e1;
  --muted: #94a3b8;
  --primary-soft: rgba(234,88,12,.15);
}

html.is-dark body {
  background: var(--bg);
  color: var(--text);
}

/* Sidebar */
html.is-dark .sidebar {
  background: linear-gradient(180deg, #050914 0%, #0b1120 100%);
  border-left: 1px solid #1f2937;
}

html.is-dark .nav-item {
  color: #94a3b8;
}

html.is-dark .nav-item:hover {
  background: rgba(234,88,12,.15);
  color: #fff;
}

html.is-dark .nav-item.active {
  background: linear-gradient(135deg,#ea580c,#c2410c);
  color: #fff;
}

html.is-dark .sidebar-footer {
  border-top-color: #1f2937;
}

/* Topbar */
html.is-dark .topbar {
  background: #111827;
  border-bottom-color: #1f2937;
}

html.is-dark .topbar-title h2 {
  color: #e5e7eb;
}

html.is-dark .topbar-title p {
  color: #94a3b8;
}

html.is-dark .topbar-btn {
  background: #1f2937;
  color: #cbd5e1;
  border-color: #374151;
}

html.is-dark .topbar-btn:hover {
  background: rgba(234,88,12,.2);
  color: #fb923c;
  border-color: #ea580c;
}

html.is-dark .menu-toggle {
  background: #1f2937;
  color: #fb923c;
}

/* Content & Cards */
html.is-dark .content {
  background: var(--bg);
}

html.is-dark .stat-card,
html.is-dark .status-row,
html.is-dark .quick-link,
html.is-dark .worker-card,
html.is-dark .task-item,
html.is-dark .settings-card,
html.is-dark .ord-stat,
html.is-dark .ord-toolbar,
html.is-dark .ord-table,
html.is-dark .rev-stat,
html.is-dark .rev-toolbar,
html.is-dark .rev-table,
html.is-dark .cust-stat,
html.is-dark .cust-toolbar,
html.is-dark .cust-table,
html.is-dark .card {
  background: #1a2332 !important;
  border-color: #1f2937 !important;
  color: #e5e7eb !important;
}

html.is-dark .stat-value,
html.is-dark .section-title-dash,
html.is-dark .settings-card h4,
html.is-dark .ord-stat .num,
html.is-dark .rev-stat .num,
html.is-dark .cust-stat .num,
html.is-dark .worker-name,
html.is-dark .task-text {
  color: #e5e7eb !important;
}

html.is-dark .stat-label,
html.is-dark .status-name,
html.is-dark .worker-url,
html.is-dark .task-text,
html.is-dark .ord-stat .lbl,
html.is-dark .rev-stat .lbl,
html.is-dark .cust-stat .lbl {
  color: #94a3b8 !important;
}

/* Tables */
html.is-dark .ord-row,
html.is-dark .rev-row,
html.is-dark .cust-row {
  border-bottom-color: #1f2937 !important;
  color: #cbd5e1;
}

html.is-dark .ord-row.head,
html.is-dark .rev-row.head,
html.is-dark .cust-row.head {
  background: #0f172a !important;
  color: #94a3b8 !important;
}

html.is-dark .ord-row:not(.head):hover,
html.is-dark .rev-row:not(.head):hover,
html.is-dark .cust-row:not(.head):hover {
  background: rgba(234,88,12,.1) !important;
}

html.is-dark .ord-cell.ref {
  color: #fb923c !important;
}

html.is-dark .rev-cell.name,
html.is-dark .cust-cell.name {
  color: #e5e7eb !important;
}

html.is-dark .rev-cell.text {
  color: #94a3b8 !important;
}

html.is-dark .cust-total {
  color: #10b981 !important;
}

html.is-dark .cust-orders {
  background: rgba(234,88,12,.2) !important;
  color: #fb923c !important;
}

/* Inputs */
html.is-dark .ord-toolbar input,
html.is-dark .ord-toolbar select,
html.is-dark .rev-toolbar input,
html.is-dark .cust-toolbar input {
  background: #0f172a !important;
  border-color: #1f2937 !important;
  color: #e5e7eb !important;
}

html.is-dark .ord-toolbar input:focus,
html.is-dark .rev-toolbar input:focus,
html.is-dark .cust-toolbar input:focus {
  border-color: #ea580c !important;
}

/* Buttons */
html.is-dark .rev-toolbar button:not(.active),
html.is-dark .settings-btn.secondary {
  background: #1f2937 !important;
  border-color: #374151 !important;
  color: #cbd5e1 !important;
}

html.is-dark .rev-toolbar button:not(.active):hover {
  border-color: #ea580c !important;
  color: #fb923c !important;
}

/* Settings */
html.is-dark .settings-row {
  border-bottom-color: #1f2937 !important;
}

html.is-dark .settings-row .sk {
  color: #94a3b8;
}

html.is-dark .settings-row .sv {
  color: #e5e7eb;
}

/* Toast */
html.is-dark .toast {
  background: #1f2937;
  color: #e5e7eb;
}

/* Transitions */
body, .stat-card, .ord-table, .rev-table, .cust-table, .topbar, .sidebar {
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}

/* ═══════════════════════════════════════════
   🌙 DARK MODE — INLINE STYLES FIX
   (هادشي كيصلح العناصر اللي فيها style="...")
   ═══════════════════════════════════════════ */

/* خلفيات بيضاء */
html.is-dark [style*="background:#fff"],
html.is-dark [style*="background: #fff"],
html.is-dark [style*="background:#ffffff"],
html.is-dark [style*="background:white"] {
  background: #1a2332 !important;
  color: #e5e7eb !important;
}

/* خلفيات رمادية فاتحة */
html.is-dark [style*="background:#f8fafc"],
html.is-dark [style*="background: #f8fafc"],
html.is-dark [style*="background:#f1f5f9"] {
  background: #0f172a !important;
  color: #cbd5e1 !important;
}

/* Borders فاتحة */
html.is-dark [style*="border:1.5px solid #e2e8f0"],
html.is-dark [style*="border: 1.5px solid #e2e8f0"],
html.is-dark [style*="border:2px solid #e2e8f0"] {
  border-color: #1f2937 !important;
}

/* Borders فاتحة (bottom) */
html.is-dark [style*="border-bottom:1px solid #f1f5f9"],
html.is-dark [style*="border-bottom: 1px solid #f1f5f9"],
html.is-dark [style*="border-bottom:1px solid #e2e8f0"] {
  border-bottom-color: #1f2937 !important;
}

/* Links باللون البرتقالي الغامق */
html.is-dark a[style*="color:#ea580c"],
html.is-dark a[style*="color: #ea580c"] {
  color: #fb923c !important;
}

html.is-dark a[style*="color:#c2410c"],
html.is-dark a[style*="color: #c2410c"] {
  color: #fb923c !important;
}

/* الروابط "فتح" — أزرق فاتح */
html.is-dark a[style*="color:#059669"],
html.is-dark a[style*="color: #059669"] {
  color: #10b981 !important;
}

/* النصوص الرمادية */
html.is-dark [style*="color:#64748b"],
html.is-dark [style*="color: #64748b"],
html.is-dark [style*="color:#94a3b8"] {
  color: #94a3b8 !important;
}

html.is-dark [style*="color:#475569"],
html.is-dark [style*="color: #475569"],
html.is-dark [style*="color:#334155"] {
  color: #cbd5e1 !important;
}

/* النصوص الداكنة */
html.is-dark [style*="color:#0f172a"],
html.is-dark [style*="color: #0f172a"] {
  color: #e5e7eb !important;
}

/* النصوص البيضاء (كيخليها) */
html.is-dark [style*="color:#fff"]:not([style*="color:#fff!important"]),
html.is-dark [style*="color:#ffffff"] {
  color: #e5e7eb !important;
}

/* Cards بحال SEO, DNS, Reports, Learning, Knowledge */
html.is-dark [style*="padding:18px;background:#fff"],
html.is-dark [style*="padding:20px;background:#fff"],
html.is-dark [style*="padding:22px;background:#fff"] {
  background: #1a2332 !important;
}

/* Headings */
html.is-dark [style*="font-weight:900"]:not([style*="color:#fff"]):not([style*="color:#ea580c"]) {
  color: #e5e7eb;
}

/* Code blocks */
html.is-dark code {
  background: #0f172a !important;
  color: #fb923c !important;
}

/* فقرات فيها نصوص عادية */
html.is-dark p:not([style*="color:#fff"]) {
  color: #cbd5e1;
}

/* Sitemap rows */
html.is-dark [style*="display:flex;justify-content:space-between"] {
  color: #cbd5e1;
  border-color: #1f2937 !important;
}

/* ═══════════════════════════════════════════
   📊 DASHBOARD CHARTS — Responsive
   ═══════════════════════════════════════════ */

/* Charts Grid */
.dash-charts-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 14px;
  margin-bottom: 20px;
}

.chart-card {
  background: #fff;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  padding: 18px;
  transition: all .25s;
}

.chart-card:hover {
  border-color: #ea580c;
  box-shadow: 0 6px 20px -8px rgba(234,88,12,.25);
}

.chart-card h4 {
  font-size: 14px;
  font-weight: 900;
  margin-bottom: 14px;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.chart-card h4 .chart-badge {
  background: rgba(234,88,12,.1);
  color: #c2410c;
  font-size: 10px;
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 800;
}

.chart-wrapper {
  position: relative;
  height: 220px;
  width: 100%;
}

.chart-wrapper.full {
  height: 260px;
}

/* Dark Mode */
html.is-dark .chart-card {
  background: #1a2332 !important;
  border-color: #1f2937 !important;
}

html.is-dark .chart-card h4 {
  color: #e5e7eb;
}

html.is-dark .chart-card h4 .chart-badge {
  background: rgba(249,115,22,.15);
  color: #fb923c;
}

/* ═══ Mobile ═══ */
@media (max-width: 900px) {
  .dash-charts-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  
  .chart-wrapper {
    height: 240px;
  }
  
  .chart-card {
    padding: 14px;
    border-radius: 12px;
  }
  
  .chart-card h4 {
    font-size: 13px;
    margin-bottom: 10px;
  }
  
  .chart-card h4 .chart-badge {
    font-size: 9px;
    padding: 2px 8px;
  }
}

@media (max-width: 640px) {
  .dash-charts-grid {
    gap: 10px;
    margin-bottom: 14px;
  }
  
  .chart-wrapper {
    height: 200px;
  }
  
  .chart-wrapper.full {
    height: 240px;
  }
  
  .chart-card {
    padding: 12px;
  }
  
  .chart-card h4 {
    font-size: 12.5px;
    flex-wrap: wrap;
  }
}

/* Dashboard Stats Mobile */
@media (max-width: 640px) {
  .dash-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
    margin-bottom: 14px !important;
  }
  
  .stat-card {
    padding: 14px !important;
    border-radius: 12px !important;
  }
  
  .stat-icon {
    width: 38px !important;
    height: 38px !important;
    font-size: 17px !important;
    margin-bottom: 10px !important;
  }
  
  .stat-value {
    font-size: 22px !important;
  }
  
  .stat-label {
    font-size: 11px !important;
  }
  
  .stat-trend {
    font-size: 10px !important;
    margin-top: 4px !important;
  }
  
  .section-title-dash {
    font-size: 14px !important;
    margin: 18px 0 10px !important;
  }
  
  .status-row {
    padding: 11px 14px !important;
    margin-bottom: 6px !important;
    border-radius: 10px !important;
  }
  
  .status-name {
    font-size: 13px !important;
  }
  
  .status-time {
    font-size: 11px !important;
  }
  
  .quick-links {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }
  
  .quick-link {
    padding: 11px !important;
    font-size: 12px !important;
    gap: 8px !important;
    border-radius: 10px !important;
  }
  
  .quick-link .ql-icon {
    width: 32px !important;
    height: 32px !important;
    font-size: 14px !important;
  }
}

@media (max-width: 400px) {
  .dash-grid {
    grid-template-columns: 1fr !important;
  }
  
  .quick-links {
    grid-template-columns: 1fr !important;
  }
}
