:root{--bg:#0b0d11;--surface:#12151b;--surface2:#171b22;--line:#252b35;--text:#f4f7fb;--muted:#8a94a2;--accent:#f97316;--accent2:#fb923c;--good:#22c55e;--warn:#eab308;--bad:#ef4444;--blue:#60a5fa;--shadow:0 20px 60px rgba(0,0,0,.28)}html[data-theme=light]{--bg:#f4f6f8;--surface:#ffffff;--surface2:#f8fafc;--line:#dfe5eb;--text:#1d232b;--muted:#6d7783;--shadow:0 14px 38px rgba(45,52,62,.08)}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font-family:Vazirmatn,Tahoma,sans-serif;font-size:13px}button,input,select,textarea{font:inherit}a{color:inherit;text-decoration:none}.app-shell{min-height:100vh;display:grid;grid-template-columns:265px minmax(0,1fr)}.sidebar{position:sticky;top:0;height:100vh;padding:18px 14px;display:flex;flex-direction:column;background:linear-gradient(180deg,#101319,#0a0c10);border-left:1px solid #21262e;z-index:30}.side-brand{display:flex;align-items:center;gap:11px;padding:7px 7px 18px;border-bottom:1px solid #20252d}.brand-orb{width:44px;height:44px;border-radius:15px;display:grid;place-items:center;font-weight:900;font-size:20px;color:white;background:radial-gradient(circle at 30% 20%,#ffd29f,transparent 28%),linear-gradient(145deg,#fb923c,#c2410c 68%,#7c2d12);box-shadow:0 9px 26px rgba(249,115,22,.25)}.side-brand strong{display:block;font-size:12.5px}.side-brand small{display:block;margin-top:3px;color:#697383;font-size:12.5px}.side-nav{padding:10px 2px;overflow:auto;scrollbar-width:none}.side-nav::-webkit-scrollbar{display:none}.nav-label{padding:15px 10px 6px;color:#586273;font-size:12.5px;font-weight:700;letter-spacing:.08em}.side-nav a{display:flex;align-items:center;gap:10px;min-height:42px;margin:2px 0;padding:0 10px;border-radius:12px;color:#aab2bd;transition:.18s}.side-nav a i{width:25px;height:25px;display:grid;place-items:center;border-radius:8px;background:#171b22;color:#7f8996;font-style:normal}.side-nav a:hover{background:#151922;color:#fff}.side-nav a.active{background:linear-gradient(90deg,rgba(249,115,22,.18),rgba(249,115,22,.05));color:#fff;box-shadow:inset -2px 0 #f97316}.side-nav a.active i{background:rgba(249,115,22,.16);color:#fb923c}.soon{margin-right:auto;padding:2px 5px;border-radius:6px;background:#252b34;color:#8f98a4;font-size:12.5px}.side-footer{margin-top:auto;display:grid;gap:6px;padding:12px 4px 2px;border-top:1px solid #20252d}.side-footer a{padding:9px 10px;border-radius:10px;color:#7f8997;font-size:12.5px}.side-footer a:hover{background:#171b21;color:#fff}.side-footer .danger:hover{color:#ff8279}.main-column{min-width:0}.topbar{position:sticky;top:0;z-index:20;height:70px;padding:0 24px;display:flex;align-items:center;justify-content:space-between;background:color-mix(in srgb,var(--bg) 83%,transparent);backdrop-filter:blur(16px);border-bottom:1px solid var(--line)}.top-title{display:flex;flex-direction:column}.eyebrow{color:#e67c29;font-size:12.5px;font-weight:700;letter-spacing:.11em}.top-title strong{margin-top:3px;font-size:14px}.top-actions{display:flex;align-items:center;gap:9px}.icon-btn,.ghost-btn,.primary-btn{border:1px solid var(--line);border-radius:11px;cursor:pointer;transition:.18s}.icon-btn{width:37px;height:37px;background:var(--surface);color:var(--text)}.ghost-btn{min-height:38px;padding:0 13px;background:var(--surface2);color:var(--text)}.primary-btn{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:0 15px;border-color:#f58b3d;background:linear-gradient(135deg,#fb923c,#ea580c);color:white;font-weight:700;box-shadow:0 10px 23px rgba(249,115,22,.18)}.ghost-btn:hover,.icon-btn:hover{border-color:#f2a16a}.primary-btn:hover{transform:translateY(-1px)}.health-dot{display:flex;align-items:center;gap:6px;padding:7px 10px;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--muted);font-size:12.5px}.health-dot i{width:7px;height:7px;border-radius:50%;background:var(--good);box-shadow:0 0 0 4px rgba(34,197,94,.1)}.admin-chip{display:flex;align-items:center;gap:8px;padding:5px 8px;border:1px solid var(--line);border-radius:12px;background:var(--surface)}.mini-avatar{width:30px;height:30px;display:grid;place-items:center;border-radius:9px;background:linear-gradient(145deg,#fb923c,#c2410c);color:white;font-weight:700}.admin-chip strong,.admin-chip small{display:block}.admin-chip strong{font-size:12.5px}.admin-chip small{margin-top:2px;color:var(--muted);font-size:12.5px}.content{max-width:1600px;margin:0 auto;padding:24px}.hero{position:relative;overflow:hidden;display:flex;align-items:center;justify-content:space-between;gap:20px;min-height:185px;margin-bottom:18px;padding:28px;border:1px solid rgba(249,115,22,.23);border-radius:24px;background:radial-gradient(480px 220px at 5% 0,rgba(249,115,22,.17),transparent 68%),linear-gradient(135deg,var(--surface),var(--surface2));box-shadow:var(--shadow)}.hero.compact{min-height:135px;padding:23px 25px}.hero h1{margin:6px 0 7px;font-size:26px;letter-spacing:-.03em}.hero p{max-width:740px;margin:0;color:var(--muted);font-size:12.5px;line-height:1.9}.hero-actions{display:flex;gap:8px}.stat-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;margin-bottom:16px}.stat-grid.small{grid-template-columns:repeat(4,minmax(0,1fr))}.stat-card{min-height:116px;padding:16px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(145deg,var(--surface),var(--surface2));box-shadow:0 10px 30px rgba(0,0,0,.09)}.stat-card .icon{width:34px;height:34px;display:grid;place-items:center;border-radius:11px;background:rgba(249,115,22,.1);color:#fb923c}.stat-card strong{display:block;margin-top:13px;font-size:22px}.stat-card small{display:block;margin-top:3px;color:var(--muted);font-size:12.5px}.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:15px;margin-bottom:15px}.panel{padding:18px;border:1px solid var(--line);border-radius:20px;background:var(--surface);box-shadow:0 12px 35px rgba(0,0,0,.08)}.panel-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:14px}.panel h2{margin:4px 0 0;font-size:13px}.health-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.health-grid.big{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:15px}.health-card{padding:13px;border:1px solid var(--line);border-radius:14px;background:var(--surface2)}.health-card .row{display:flex;align-items:center;justify-content:space-between;gap:8px}.health-card b{font-size:12.5px}.health-card small{color:var(--muted);font-size:12.5px}.badge{display:inline-flex;align-items:center;justify-content:center;min-height:23px;padding:0 8px;border-radius:999px;font-size:12.5px;font-weight:700}.badge.good{background:rgba(34,197,94,.12);color:#58d977}.badge.warn{background:rgba(234,179,8,.13);color:#ebc735}.badge.bad{background:rgba(239,68,68,.12);color:#ff756d}.badge.info{background:rgba(96,165,250,.12);color:#81b9ff}.timeline{display:grid;gap:9px}.timeline-item{display:grid;grid-template-columns:9px minmax(0,1fr) auto;gap:9px;align-items:start;padding:8px 0;border-bottom:1px solid var(--line)}.timeline-item:last-child{border:0}.timeline-dot{width:7px;height:7px;margin-top:5px;border-radius:50%;background:#fb923c}.timeline-item b{display:block;font-size:12.5px}.timeline-item span,.timeline-item time{color:var(--muted);font-size:12.5px}.mini-bars{display:grid;gap:8px}.bar-row{display:grid;grid-template-columns:90px minmax(0,1fr) 38px;gap:8px;align-items:center}.bar-track{height:7px;overflow:hidden;border-radius:999px;background:var(--surface2)}.bar-track i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#fb923c,#f97316)}.bar-row span,.bar-row b{font-size:12.5px}.queue-box,.service-card,.secret-list{display:grid;gap:9px}.metric-row,.secret-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid var(--line);border-radius:12px;background:var(--surface2)}.metric-row span,.secret-row span{color:var(--muted);font-size:12.5px}.metric-row b,.secret-row b{font-size:12.5px}.toolbar{display:flex;align-items:center;gap:8px;margin-bottom:13px}.toolbar input,.toolbar select,.form-grid input,.form-grid select,.form-grid textarea{min-height:39px;padding:8px 10px;border:1px solid var(--line);border-radius:10px;background:var(--surface2);color:var(--text);outline:0}.toolbar input{flex:1}.toolbar input:focus,.form-grid input:focus,.form-grid textarea:focus,.form-grid select:focus{border-color:rgba(249,115,22,.6);box-shadow:0 0 0 3px rgba(249,115,22,.08)}.table-wrap{overflow:auto;border:1px solid var(--line);border-radius:14px}table{width:100%;border-collapse:collapse;white-space:nowrap}th,td{padding:11px 12px;border-bottom:1px solid var(--line);text-align:right}th{position:sticky;top:0;background:var(--surface2);color:var(--muted);font-size:12.5px;z-index:1}td{font-size:12.5px}tbody tr:hover{background:color-mix(in srgb,var(--surface2) 60%,transparent)}tbody tr:last-child td{border:0}.user-cell{display:flex;align-items:center;gap:8px}.avatar{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;background:linear-gradient(145deg,rgba(249,115,22,.2),rgba(249,115,22,.05));border:1px solid rgba(249,115,22,.25);color:#ffad70;font-weight:700}.user-cell b,.user-cell small{display:block}.user-cell small{color:var(--muted);font-size:12.5px}.row-actions{display:flex;gap:5px}.mini-btn{min-height:28px;padding:0 8px;border:1px solid var(--line);border-radius:8px;background:var(--surface2);color:var(--text);font-size:12.5px;cursor:pointer}.mini-btn:hover{border-color:#f69a5c}.mini-btn.danger{color:#ff7770}.cards-list{display:grid;gap:8px}.channel-card{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;border:1px solid var(--line);border-radius:13px;background:var(--surface2)}.channel-card strong,.channel-card small{display:block}.channel-card small{margin-top:3px;color:var(--muted);font-size:12.5px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:11px}.form-grid label{display:grid;gap:5px;color:var(--muted);font-size:12.5px}.form-grid .full{grid-column:1/-1}.form-grid textarea{resize:vertical;line-height:1.8}.notice{padding:10px 12px;border-radius:11px;font-size:12.5px;line-height:1.8}.notice.info{background:rgba(96,165,250,.09);color:#8bbdff;border:1px solid rgba(96,165,250,.18)}.notice.error{background:rgba(239,68,68,.1);color:#ff8d87;border:1px solid rgba(239,68,68,.18)}.log-view{min-height:520px;max-height:68vh;margin:0;padding:15px;overflow:auto;border:1px solid var(--line);border-radius:14px;background:#07090c;color:#aab7c8;font:11px/1.8 Consolas,monospace;direction:ltr;text-align:left;white-space:pre-wrap}.module-roadmap{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px}.module-roadmap article{padding:16px;border:1px solid var(--line);border-radius:15px;background:var(--surface2)}.module-roadmap b,.module-roadmap span{display:block}.module-roadmap span{margin-top:6px;color:var(--muted);font-size:12.5px;line-height:1.8}.toast-stack{position:fixed;left:18px;bottom:18px;z-index:100;display:grid;gap:8px}.toast{min-width:260px;max-width:420px;padding:11px 13px;border:1px solid var(--line);border-radius:12px;background:var(--surface);box-shadow:var(--shadow);font-size:12.5px}.toast.ok{border-color:rgba(34,197,94,.3)}.toast.error{border-color:rgba(239,68,68,.35);color:#ff9790}.modal-backdrop{position:fixed;inset:0;z-index:80;background:rgba(2,4,7,.62);backdrop-filter:blur(5px)}.modal{position:fixed;inset:0;z-index:81;display:grid;place-items:center;padding:16px}.modal[hidden],.modal-backdrop[hidden]{display:none}.modal-card{width:min(720px,100%);max-height:90vh;overflow:auto;border:1px solid var(--line);border-radius:20px;background:var(--surface);box-shadow:0 30px 90px rgba(0,0,0,.42)}.modal-head{position:sticky;top:0;display:flex;align-items:center;justify-content:space-between;padding:15px 17px;background:var(--surface);border-bottom:1px solid var(--line);z-index:2}.modal-head h3{margin:0;font-size:12.5px}.modal-head button{width:31px;height:31px;border:1px solid var(--line);border-radius:9px;background:var(--surface2);color:var(--text);cursor:pointer}#modalBody{padding:17px}.json-view{padding:12px;border-radius:12px;background:#090b0f;color:#a8b5c6;font:10px/1.8 Consolas,monospace;direction:ltr;text-align:left;white-space:pre-wrap}.empty{padding:30px;text-align:center;color:var(--muted)}.loading{opacity:.55;pointer-events:none}.mobile-only{display:none}
.login-body{min-height:100vh;display:grid;place-items:center;background:radial-gradient(800px 500px at 20% 10%,rgba(249,115,22,.12),transparent 65%),#090b0f}.login-shell{width:min(980px,calc(100% - 30px));display:grid;grid-template-columns:1.15fr .85fr;overflow:hidden;border:1px solid #222833;border-radius:28px;background:#0f1218;box-shadow:0 35px 100px rgba(0,0,0,.42)}.login-brand{padding:50px;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;background:radial-gradient(450px 260px at 10% 10%,rgba(249,115,22,.2),transparent 68%),linear-gradient(145deg,#15120f,#0c1016)}.login-brand h1{margin:10px 0 8px;font-size:30px}.login-brand p{color:#848e9c;font-size:12.5px}.login-points{display:flex;gap:8px;flex-wrap:wrap;margin-top:20px}.login-points span{padding:6px 9px;border:1px solid #2b313b;border-radius:9px;color:#96a0ad;font-size:12.5px}.login-card{padding:40px;display:grid;gap:14px;align-content:center}.login-card h2{margin:5px 0;font-size:20px}.login-card p{margin:0;color:#7f8996;font-size:12.5px}.login-card label{display:grid;gap:6px;color:#8d97a4;font-size:12.5px}.login-card input{min-height:45px;padding:10px 12px;border:1px solid #2b313a;border-radius:12px;background:#151920;color:#fff;outline:0}.login-card input:focus{border-color:#f28b42}.login-card button{min-height:47px;border:0;border-radius:13px;background:linear-gradient(135deg,#fb923c,#ea580c);color:#fff;font-weight:700;cursor:pointer}.login-card footer{text-align:center;color:#586170;font-size:12.5px}
@media(max-width:1100px){.stat-grid{grid-template-columns:repeat(3,1fr)}.health-grid.big{grid-template-columns:repeat(2,1fr)}}@media(max-width:860px){.app-shell{grid-template-columns:1fr}.sidebar{position:fixed;right:0;transform:translateX(105%);width:270px;box-shadow:-20px 0 50px rgba(0,0,0,.35);transition:.2s}.sidebar.open{transform:none}.mobile-only{display:grid}.topbar{padding:0 14px}.content{padding:14px}.grid-2{grid-template-columns:1fr}.stat-grid,.stat-grid.small{grid-template-columns:repeat(2,1fr)}.admin-chip>div{display:none}.login-shell{grid-template-columns:1fr}.login-brand{display:none}.login-card{padding:30px}}@media(max-width:540px){.hero,.hero.compact{align-items:flex-start;flex-direction:column;padding:19px;border-radius:19px}.hero h1{font-size:21px}.stat-grid,.stat-grid.small{grid-template-columns:1fr 1fr;gap:8px}.stat-card{min-height:100px;padding:13px}.stat-card strong{font-size:19px}.health-grid,.health-grid.big{grid-template-columns:1fr}.content{padding:10px}.panel{padding:12px;border-radius:16px}.toolbar{align-items:stretch;flex-direction:column}.form-grid{grid-template-columns:1fr}.form-grid .full{grid-column:auto}.module-roadmap{grid-template-columns:1fr}.top-title strong{font-size:12.5px}.health-dot{display:none}.login-card{padding:24px}}


/* ===== MCC v1.0.1 Visual Polish Hotfix ===== */
body{font-size:15px;line-height:1.65}
.app-shell{grid-template-columns:290px minmax(0,1fr)}
.content{padding:30px}
.sidebar{padding:20px 16px;background:linear-gradient(180deg,#131820 0%,#0d1016 100%);border-left:1px solid rgba(255,255,255,.06);box-shadow:0 0 0 1px rgba(255,255,255,.02) inset, 0 24px 70px rgba(0,0,0,.28)}
.side-brand{padding:10px 10px 20px;margin-bottom:4px}
.brand-orb{width:50px;height:50px;border-radius:18px;font-size:22px;box-shadow:0 12px 30px rgba(249,115,22,.28)}
.side-brand strong{font-size:15px;line-height:1.25}
.side-brand small{font-size:12.5px;color:#98a3b3}
.nav-label{padding:18px 12px 8px;font-size:12.5px;color:#8d98a8}
.side-nav a{position:relative;min-height:50px;padding:0 12px 0 14px;border-radius:15px;font-size:14px;font-weight:700;color:#c0c8d3}
.side-nav a i{width:34px;height:34px;border-radius:12px;font-size:16px;background:rgba(255,255,255,.04);color:#d6dde8;box-shadow:inset 0 1px 0 rgba(255,255,255,.04)}
.side-nav a:hover{background:rgba(255,255,255,.055);color:#fff;transform:translateX(-2px)}
.side-nav a.active{background:linear-gradient(90deg,rgba(249,115,22,.22),rgba(249,115,22,.08));box-shadow:inset -3px 0 #f97316, 0 12px 28px rgba(249,115,22,.08);color:#fff}
.side-nav a.active i{background:linear-gradient(180deg,rgba(249,115,22,.27),rgba(249,115,22,.16));color:#ffd4b2}
.soon{padding:3px 7px;font-size:12.5px;border-radius:999px}
.side-footer{gap:8px;padding:14px 6px 2px}
.side-footer a{font-size:13px;padding:11px 12px;border-radius:12px}
.topbar{height:78px;padding:0 28px}
.eyebrow{font-size:12.5px}
.top-title strong{font-size:21px}
.top-actions{gap:12px}
.icon-btn{width:42px;height:42px;font-size:16px}
.ghost-btn{min-height:42px;padding:0 16px;font-size:14px}
.primary-btn{min-height:44px;padding:0 18px;font-size:14px}
.health-dot{padding:9px 12px;font-size:12.5px}
.admin-chip{padding:7px 10px;border-radius:14px}
.mini-avatar{width:34px;height:34px;border-radius:11px;font-size:14px}
.admin-chip strong{font-size:13px}
.admin-chip small{font-size:12.5px}
.hero{min-height:210px;padding:34px;border-radius:28px}
.hero.compact{min-height:156px;padding:28px 30px}
.hero h1{font-size:35px;line-height:1.2}
.hero p{font-size:14px;line-height:2.05;max-width:820px}
.stat-grid{gap:14px;margin-bottom:20px}
.stat-card{min-height:132px;padding:18px 18px 16px;border-radius:22px}
.stat-card .icon{width:42px;height:42px;border-radius:14px;font-size:18px}
.stat-card strong{font-size:28px;margin-top:14px}
.stat-card small{font-size:12.5px;line-height:1.8}
.grid-2{gap:18px;margin-bottom:18px}
.panel{padding:22px;border-radius:24px}
.panel h2{font-size:19px}
.panel-head{margin-bottom:16px}
.health-grid{gap:12px}
.health-card{padding:16px;border-radius:18px}
.health-card b{font-size:15px}
.health-card small{font-size:12.5px;line-height:1.8}
.badge{min-height:28px;padding:0 11px;font-size:12.5px}
.timeline{gap:10px}
.timeline-item{grid-template-columns:12px minmax(0,1fr) auto;gap:12px;padding:11px 0}
.timeline-dot{width:9px;height:9px}
.timeline-item b{font-size:14px}
.timeline-item span,.timeline-item time{font-size:12.5px}
.bar-row{grid-template-columns:120px minmax(0,1fr) 52px}
.bar-row span,.bar-row b{font-size:12.5px}
.bar-track{height:10px}
.metric-row,.secret-row{padding:13px 14px;border-radius:14px}
.metric-row span,.secret-row span{font-size:12.5px}
.metric-row b,.secret-row b{font-size:14px}
.toolbar{gap:10px;margin-bottom:15px}
.toolbar input,.toolbar select,.form-grid input,.form-grid select,.form-grid textarea{min-height:46px;padding:10px 13px;border-radius:13px;font-size:14px}
.form-grid{gap:14px}
.form-grid label{font-size:13px;gap:7px}
.notice{padding:12px 14px;font-size:13px;border-radius:14px}
.table-wrap{border-radius:18px}
th,td{padding:14px 14px}
th{font-size:12.5px}
td{font-size:14px}
.user-cell{gap:10px}
.avatar{width:40px;height:40px;border-radius:12px;font-size:14px}
.user-cell b{font-size:14px}
.user-cell small{font-size:12.5px}
.row-actions{gap:7px}
.mini-btn{min-height:33px;padding:0 10px;font-size:12.5px;border-radius:10px}
.channel-card{padding:14px 15px;border-radius:16px}
.channel-card strong{font-size:14px}
.channel-card small{font-size:12.5px}
.log-view{min-height:560px;padding:18px;font:13px/1.95 Consolas,monospace;border-radius:18px}
.module-roadmap{gap:14px}
.module-roadmap article{padding:18px;border-radius:18px}
.module-roadmap b{font-size:15px}
.module-roadmap span{font-size:13px}
.toast{font-size:13px;padding:13px 15px;border-radius:14px}
.modal-card{border-radius:24px}
.modal-head{padding:17px 20px}
.modal-head h3{font-size:18px}
.modal-head button{width:36px;height:36px;border-radius:11px}
#modalBody{padding:20px}
.json-view{font:12px/1.95 Consolas,monospace;padding:15px;border-radius:15px}
.empty{padding:34px;font-size:14px}

/* login redesign */
.login-body{background:radial-gradient(900px 540px at 18% 8%,rgba(249,115,22,.16),transparent 60%),radial-gradient(780px 480px at 92% 100%,rgba(96,165,250,.08),transparent 55%),#0b0e14}
.login-shell{width:min(1080px,calc(100% - 34px));grid-template-columns:1.1fr .9fr;border-radius:34px;border:1px solid rgba(255,255,255,.07);background:linear-gradient(180deg,#12161d 0%,#0d1117 100%);box-shadow:0 40px 120px rgba(0,0,0,.44)}
.login-brand{padding:58px;background:radial-gradient(500px 280px at 8% 12%,rgba(249,115,22,.22),transparent 60%),linear-gradient(145deg,#171310,#0f141b)}
.login-brand .kicker{font-size:12.5px;color:#f4a261;letter-spacing:.14em;font-weight:800}
.login-brand h1{font-size:38px;line-height:1.2;margin:12px 0 12px}
.login-brand p{font-size:15px;line-height:2;color:#a2adba;max-width:420px}
.login-points{gap:10px;margin-top:24px}
.login-points span{padding:8px 12px;font-size:12.5px;border-radius:12px}
.login-card{padding:44px 42px;gap:16px}
.login-card small{font-size:12.5px;color:#f0a15f;font-weight:800;letter-spacing:.1em}
.login-card h2{font-size:28px;margin:6px 0}
.login-card p{font-size:14px;line-height:1.95;color:#97a2af}
.login-card label{font-size:13px;color:#b5bfcb;gap:8px}
.login-card input{min-height:52px;padding:12px 14px;border-radius:15px;font-size:15px;background:#171c24}
.login-card button{min-height:52px;border-radius:16px;font-size:15px;box-shadow:0 14px 34px rgba(249,115,22,.18)}
.login-card footer{font-size:12.5px;color:#738091}

/* light theme proper sidebar and panels */
html[data-theme=light] body{background:linear-gradient(180deg,#f5f7fb 0%,#edf2f7 100%)}
html[data-theme=light] .sidebar{background:linear-gradient(180deg,#ffffff 0%,#f5f8fc 100%);border-left:1px solid #e5eaf1;box-shadow:0 18px 50px rgba(60,72,88,.08)}
html[data-theme=light] .side-brand{border-bottom:1px solid #edf1f5}
html[data-theme=light] .side-brand small{color:#8a97a6}
html[data-theme=light] .nav-label{color:#99a3b0}
html[data-theme=light] .side-nav a{color:#4c5a6b}
html[data-theme=light] .side-nav a i{background:#eef3f8;color:#6e7b8d;box-shadow:none}
html[data-theme=light] .side-nav a:hover{background:#f0f4f9;color:#1f2937}
html[data-theme=light] .side-nav a.active{background:linear-gradient(90deg,rgba(249,115,22,.17),rgba(249,115,22,.04));color:#1d2a36;box-shadow:inset -3px 0 #f97316,0 10px 22px rgba(249,115,22,.07)}
html[data-theme=light] .side-nav a.active i{background:rgba(249,115,22,.14);color:#d66a18}
html[data-theme=light] .soon{background:#eef2f7;color:#748094}
html[data-theme=light] .side-footer{border-top:1px solid #edf1f5}
html[data-theme=light] .side-footer a{color:#5c6a79}
html[data-theme=light] .side-footer a:hover{background:#eef3f8;color:#1f2937}
html[data-theme=light] .topbar{background:rgba(245,247,251,.82)}
html[data-theme=light] .hero{background:radial-gradient(480px 220px at 5% 0,rgba(249,115,22,.11),transparent 68%),linear-gradient(135deg,#ffffff,#f8fafc)}
html[data-theme=light] .panel,
html[data-theme=light] .stat-card{box-shadow:0 14px 34px rgba(31,41,55,.06)}
html[data-theme=light] .health-card,
html[data-theme=light] .metric-row,
html[data-theme=light] .secret-row,
html[data-theme=light] .channel-card,
html[data-theme=light] .toolbar input,
html[data-theme=light] .toolbar select,
html[data-theme=light] .form-grid input,
html[data-theme=light] .form-grid select,
html[data-theme=light] .form-grid textarea{background:#f8fafc}
html[data-theme=light] th{background:#f6f8fb}
html[data-theme=light] .log-view{background:#fffdf9;color:#334155;border-color:#e6ebf2}
html[data-theme=light] .json-view{background:#fffdf9;color:#334155}
html[data-theme=light] .notice.info{background:rgba(96,165,250,.08);color:#2f5d9b;border-color:rgba(96,165,250,.18)}
html[data-theme=light] .notice.error{background:rgba(239,68,68,.07);color:#b8403d;border-color:rgba(239,68,68,.18)}

/* better mobile */
@media(max-width:1100px){
  .app-shell{grid-template-columns:1fr}
}
@media(max-width:860px){
  body{font-size:14px}
  .sidebar{width:292px}
  .topbar{height:72px;padding:0 14px}
  .top-title strong{font-size:17px}
  .content{padding:14px}
  .hero{padding:22px;border-radius:22px;min-height:auto}
  .hero.compact{padding:20px 22px}
  .hero h1{font-size:28px}
  .hero p{font-size:13px}
  .panel{padding:16px;border-radius:18px}
  .panel h2{font-size:17px}
  .stat-card{min-height:118px}
  .stat-card strong{font-size:24px}
  th{font-size:12.5px}
  td{font-size:13px}
}
@media(max-width:540px){
  .login-card{padding:26px 22px}
  .login-card h2{font-size:24px}
  .login-card p,.login-card label,.login-card footer{font-size:13px}
  .login-card input,.login-card button{min-height:50px;font-size:14px}
}


/* ===== MCC v1.0.2 refinement hotfix ===== */
html,body{max-width:100%;overflow-x:hidden}
.app-shell{grid-template-columns:300px minmax(0,1fr)}
.main-column{min-width:0;overflow-x:hidden}
.content{max-width:none;padding:24px 20px 28px;overflow-x:hidden}
.topbar{padding:0 18px}
.top-title strong{font-size:18px}
.hero{min-height:150px;padding:22px 24px;border-radius:24px}
.hero.compact{min-height:120px;padding:18px 22px}
.hero h1{font-size:24px;line-height:1.35;margin:4px 0 6px}
.hero p{font-size:13px;line-height:1.95;max-width:760px}
.panel{padding:18px;border-radius:22px}
.panel h2{font-size:17px}
.eyebrow{font-size:12.5px}
.stat-grid,.grid-2{gap:14px}
.stat-card{min-height:120px;border-radius:20px}
.stat-card strong{font-size:24px}
.stat-card small{font-size:12.5px}
.sidebar{padding:18px 14px;background:linear-gradient(180deg,#111722 0%,#0d121b 100%)}
.side-brand{padding:8px 8px 18px;margin-bottom:6px}
.side-nav{padding:8px 2px}
.nav-label{padding:18px 10px 8px;font-size:12.5px}
.side-nav a{min-height:52px;padding:0 12px;border:1px solid rgba(255,255,255,.06);background:rgba(255,255,255,.018);border-radius:16px;margin:0 0 8px 0;font-size:14px;box-shadow:inset 0 1px 0 rgba(255,255,255,.02)}
.side-nav a i{width:36px;height:36px;border-radius:12px;font-size:15px;background:rgba(255,255,255,.04)}
.side-nav a:hover{background:rgba(255,255,255,.05);border-color:rgba(249,115,22,.16);transform:none}
.side-nav a.active{background:linear-gradient(90deg,rgba(249,115,22,.22),rgba(249,115,22,.08));border-color:rgba(249,115,22,.28);box-shadow:inset -3px 0 #f97316,0 14px 26px rgba(249,115,22,.08)}
.side-footer a{border:1px solid rgba(255,255,255,.05);background:rgba(255,255,255,.018)}
.table-wrap{max-width:100%;overflow-x:auto;overflow-y:hidden;-webkit-overflow-scrolling:touch}
table{width:max(100%,860px);table-layout:auto;border-collapse:separate;border-spacing:0;white-space:normal}
th,td{padding:13px 12px;vertical-align:top;word-break:break-word}
.table-wrap table small{display:inline-block;line-height:1.8;white-space:normal}
.user-cell{align-items:flex-start}
.toolbar{flex-wrap:wrap}
.toolbar input,.toolbar select{flex:1 1 220px}
.grid-2 > *{min-width:0}
.cards-list,.channel-card,.health-grid,.health-grid.big{min-width:0}
.channel-card{align-items:flex-start;gap:12px}
.channel-card .row-actions{flex-wrap:wrap;justify-content:flex-end}
.log-view{max-width:100%;overflow:auto}
.login-shell{width:min(1040px,calc(100% - 32px));grid-template-columns:.95fr 1.05fr}
.login-card{padding:38px 36px;gap:14px;background:linear-gradient(180deg,rgba(255,255,255,.02),rgba(255,255,255,.01))}
.login-card h2{font-size:26px}
.login-card p{font-size:13px;line-height:1.9;color:#9eabb9}
.login-card label{font-size:12.5px}
.login-card input{min-height:50px;border-radius:14px;background:#e7edf6;color:#111827;border-color:#d4ddea}
.login-card button{min-height:50px;border-radius:14px;font-size:14px}
.login-card footer{font-size:12.5px}
.login-brand{padding:46px 42px}
.login-brand h1{font-size:34px;margin-bottom:10px}
.login-brand p{font-size:14px;line-height:1.95}
.login-points{display:grid;grid-template-columns:1fr;gap:10px;margin-top:18px;width:100%}
.status-chip{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 14px;border:1px solid rgba(255,255,255,.08);border-radius:14px;background:rgba(255,255,255,.03)}
.status-chip b{font-size:13px;color:#f2f6fb}
.status-chip small{font-size:12.5px;color:#9aa6b5}
.status-chip::before{content:'';width:11px;height:11px;border-radius:50%;background:#eab308;box-shadow:0 0 0 4px rgba(234,179,8,.12)}
.status-chip.ok::before{background:#22c55e;box-shadow:0 0 0 4px rgba(34,197,94,.12)}
.status-chip.bad::before{background:#ef4444;box-shadow:0 0 0 4px rgba(239,68,68,.12)}
html[data-theme=light] .sidebar{background:linear-gradient(180deg,#ffffff 0%,#f7f9fc 100%)}
html[data-theme=light] .side-nav a{background:#ffffff;border-color:#e7ecf3;box-shadow:0 6px 14px rgba(40,52,70,.03)}
html[data-theme=light] .side-nav a i{background:#f3f6fa}
html[data-theme=light] .side-nav a:hover{background:#f8fafc;border-color:#f0b183}
html[data-theme=light] .side-footer a{background:#fff;border-color:#e7ecf3}
html[data-theme=light] .login-card input{background:#f8fafc;color:#111827;border-color:#dfe7f2}
html[data-theme=light] .status-chip{background:#fff;border-color:#e8edf3}
html[data-theme=light] .status-chip b{color:#1e293b}
html[data-theme=light] .status-chip small{color:#64748b}
@media(max-width:1100px){
  .app-shell{grid-template-columns:1fr}
  .login-shell{grid-template-columns:1fr}
}
@media(max-width:860px){
  .content{padding:14px 12px 18px}
  .hero h1{font-size:21px}
  .hero p{font-size:12.5px}
  .top-title strong{font-size:16px}
  .side-nav a{min-height:48px;font-size:13px}
  table{width:max(100%,760px)}
}
@media(max-width:540px){
  .login-shell{width:min(100%,calc(100% - 16px));border-radius:24px}
  .login-card{padding:24px 20px}
  .login-brand{padding:28px 22px}
  .login-brand h1{font-size:28px}
  .hero{padding:18px}
  .hero h1{font-size:19px}
  .panel h2{font-size:16px}
  table{width:max(100%,680px)}
}

/* ===== MCC v1.0.3 — Telegram / Publishing / Login refinement ===== */
@font-face{font-family:'Vazirmatn';src:url('../fonts/Vazirmatn-Regular.woff2') format('woff2');font-weight:400;font-style:normal;font-display:swap}
@font-face{font-family:'Vazirmatn';src:url('../fonts/Vazirmatn-Bold.woff2') format('woff2');font-weight:700 900;font-style:normal;font-display:swap}
body,button,input,select,textarea{font-family:'Vazirmatn',Tahoma,sans-serif}

/* compact page hero titles */
.hero.compact h1{font-size:20px!important;line-height:1.45!important;margin:3px 0 5px!important}
.hero.compact p{font-size:12.5px!important;line-height:1.9!important}

/* login — black fields + orange fine line */
.login-card input{
  background:#080b10!important;
  color:#f8fafc!important;
  border:1px solid rgba(249,115,22,.62)!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.025),0 0 0 1px rgba(249,115,22,.025)!important;
}
.login-card input:hover{border-color:rgba(251,146,60,.82)!important}
.login-card input:focus{
  border-color:#fb923c!important;
  box-shadow:0 0 0 3px rgba(249,115,22,.10),0 10px 24px rgba(0,0,0,.12)!important;
}
.login-card input:-webkit-autofill,
.login-card input:-webkit-autofill:hover,
.login-card input:-webkit-autofill:focus{
  -webkit-text-fill-color:#f8fafc!important;
  -webkit-box-shadow:0 0 0 1000px #080b10 inset!important;
  caret-color:#fff!important;
  border:1px solid rgba(249,115,22,.62)!important;
}
.status-chip{
  position:relative!important;
  min-height:52px!important;
  background:linear-gradient(180deg,#0b0e13,#080a0e)!important;
  border:1px solid rgba(249,115,22,.38)!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.025),0 10px 28px rgba(0,0,0,.12)!important;
}
.status-chip b{color:#f8fafc!important;font-size:13.5px!important}
.status-chip small{color:#a6b0bd!important;font-size:12.5px!important}
.status-chip.ok{border-color:rgba(34,197,94,.34)!important}
.status-chip.bad{border-color:rgba(239,68,68,.40)!important}

/* Sidebar — distinct cards; light theme keeps orange fine outline */
.side-nav a{border-color:rgba(249,115,22,.10)!important}
.side-nav a:hover{border-color:rgba(249,115,22,.32)!important}
html[data-theme=light] .side-nav a{
  background:#fff!important;
  border:1px solid rgba(249,115,22,.22)!important;
  box-shadow:0 6px 18px rgba(35,48,66,.035)!important;
}
html[data-theme=light] .side-nav a:hover{
  background:#fffaf6!important;
  border-color:rgba(249,115,22,.48)!important;
}
html[data-theme=light] .side-nav a.active{
  background:linear-gradient(90deg,#fff1e7,#fff8f2)!important;
  border-color:rgba(249,115,22,.58)!important;
  box-shadow:inset -3px 0 #f97316,0 8px 20px rgba(249,115,22,.08)!important;
}
html[data-theme=light] .side-nav a i{
  background:#fff5ed!important;
  color:#c95a0c!important;
  border:1px solid rgba(249,115,22,.14)!important;
}

/* Telegram center layout */
.telegram-layout{
  grid-template-columns:minmax(290px,.72fr) minmax(0,1.6fr)!important;
  align-items:start;
}
.telegram-channels-panel,.telegram-deliveries-panel{min-width:0}
.telegram-channels-panel .cards-list{gap:10px}
.telegram-channels-panel .channel-card{
  display:grid!important;
  grid-template-columns:minmax(0,1fr)!important;
  gap:11px!important;
  padding:14px!important;
  border-radius:17px!important;
}
.channel-copy{min-width:0;display:grid;gap:4px}
.channel-copy strong{font-size:14px!important}
.channel-copy small{font-size:12.5px!important;line-height:1.65;overflow-wrap:anywhere}
.telegram-channels-panel .row-actions{justify-content:flex-start!important;gap:6px!important}
.page-size-badge{
  display:inline-flex;align-items:center;min-height:28px;padding:0 10px;
  border:1px solid rgba(249,115,22,.18);border-radius:999px;
  background:rgba(249,115,22,.06);color:var(--muted);font-size:12.5px;font-weight:700;
}
.telegram-table-wrap table{width:100%!important;min-width:760px!important;table-layout:fixed!important}
.telegram-table-wrap th:nth-child(1),.telegram-table-wrap td:nth-child(1){width:62px}
.telegram-table-wrap th:nth-child(2),.telegram-table-wrap td:nth-child(2){width:24%}
.telegram-table-wrap th:nth-child(3),.telegram-table-wrap td:nth-child(3){width:18%}
.telegram-table-wrap th:nth-child(4),.telegram-table-wrap td:nth-child(4){width:115px}
.telegram-table-wrap th:nth-child(5),.telegram-table-wrap td:nth-child(5){width:65px}
.telegram-table-wrap th:nth-child(6),.telegram-table-wrap td:nth-child(6){width:18%}
.telegram-table-wrap th:nth-child(7),.telegram-table-wrap td:nth-child(7){width:145px}
.telegram-table-wrap td{overflow-wrap:anywhere;word-break:normal!important}
.event-name{display:block;font-weight:800;color:var(--text);line-height:1.55}
.telegram-table-wrap td small{display:block;margin-top:4px;color:var(--muted);font-size:12.5px;line-height:1.45;overflow-wrap:anywhere}
.tg-message-cell{font-size:12.5px!important;line-height:1.65!important;color:var(--muted)}
.pager{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:14px;padding-top:13px;border-top:1px solid var(--line);flex-wrap:wrap}
.pager-info{color:var(--muted);font-size:12.5px}
.pager-buttons{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
.pager-buttons .mini-btn.active{background:linear-gradient(135deg,#fb923c,#ea580c);border-color:#f97316;color:#fff}
.pager-buttons .mini-btn:disabled{opacity:.4;cursor:not-allowed}

/* Telegram create/edit modal */
#tgChannelForm{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
#tgChannelForm label{padding:0!important}
#tgChannelForm input,#tgChannelForm select{width:100%;min-width:0}
#tgChannelForm label.full{grid-column:1/-1}
#tgChannelForm label[style*="display:flex"]{
  display:flex!important;align-items:flex-start!important;gap:10px!important;
  padding:12px 13px!important;border:1px solid var(--line)!important;border-radius:13px!important;background:var(--surface2)!important;
}
#tgChannelForm label[style*="display:flex"] input{margin-top:3px;flex:none}

/* Publishing cards — admin view with thumbnail/actions */
.publishing-panel{overflow:hidden}
.publishing-cards{display:grid;gap:12px}
.pub-card{
  position:relative;display:grid;grid-template-columns:118px minmax(0,1fr);gap:16px;
  min-width:0;padding:13px;border:1px solid var(--line);border-radius:19px;
  background:linear-gradient(145deg,var(--surface2),var(--surface));overflow:hidden;
  transition:border-color .18s ease,transform .18s ease,box-shadow .18s ease;
}
.pub-card:hover{border-color:rgba(249,115,22,.32);box-shadow:0 12px 28px rgba(0,0,0,.07)}
.pub-media{
  position:relative;width:118px;height:154px;padding:0;overflow:hidden;border:1px solid rgba(249,115,22,.20);
  border-radius:15px;background:linear-gradient(145deg,#1b2028,#10141a);cursor:pointer;color:#fb923c;
}
.pub-media img{width:100%;height:100%;display:block;object-fit:cover}
.pub-media>span{height:100%;display:grid;place-items:center;font-size:27px}
.pub-media>b{position:absolute;right:7px;bottom:7px;padding:4px 7px;border-radius:8px;background:rgba(3,7,12,.72);color:#fff;font-size:12.5px;backdrop-filter:blur(8px)}
.pub-media.is-broken::after{content:'تصویر';position:absolute;inset:0;display:grid;place-items:center;color:#aab3c0;font-size:12.5px}
.pub-main{min-width:0;display:flex;flex-direction:column;gap:9px}
.pub-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.pub-card-head strong{display:block;font-size:15px;direction:ltr;text-align:right}
.pub-card-head small{display:block;margin-top:3px;color:var(--muted);font-size:12.5px}
.pub-main>p{margin:0;max-width:950px;color:var(--text);font-size:12.5px;line-height:1.9;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.pub-meta{display:flex;align-items:center;gap:7px;flex-wrap:wrap}
.pub-meta>span{display:inline-flex;align-items:center;min-height:28px;padding:0 9px;border:1px solid var(--line);border-radius:9px;background:var(--surface2);color:var(--muted);font-size:12.5px}
.pub-error{padding:9px 10px;border:1px solid rgba(239,68,68,.18);border-radius:10px;background:rgba(239,68,68,.07);color:#ef7771;font-size:12.5px;line-height:1.7;overflow-wrap:anywhere}
.pub-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:auto}
.pub-actions .primary-btn{min-height:34px;padding:0 11px;font-size:12.5px;border-radius:10px}
.pub-actions .mini-btn{min-height:34px;font-size:12.5px}
.pub-progress{position:absolute;inset:0;z-index:5;display:none;place-items:center;align-content:center;gap:10px;background:rgba(7,10,14,.80);backdrop-filter:blur(5px);color:#fff}
.pub-progress i{width:30px;height:30px;border:3px solid rgba(255,255,255,.18);border-top-color:#fb923c;border-radius:50%;animation:mccSpin .75s linear infinite}
.pub-progress b{font-size:13px}
.pub-card.is-publishing .pub-progress{display:grid}
@keyframes mccSpin{to{transform:rotate(360deg)}}
.pub-preview-modal{display:grid;grid-template-columns:minmax(220px,320px) minmax(0,1fr);gap:18px;align-items:start}
.pub-preview-modal>img{width:100%;max-height:70vh;object-fit:contain;border:1px solid var(--line);border-radius:16px;background:#080b10}
.pub-preview-info{display:grid;gap:10px}
.pub-preview-info>strong{font-size:18px;direction:ltr;text-align:right}
.pub-preview-info>p{margin:0;font-size:13px;line-height:2;white-space:pre-wrap}
.pub-edit-form textarea{min-height:125px}

html[data-theme=light] .pub-card{background:linear-gradient(145deg,#fff,#f8fafc)}
html[data-theme=light] .pub-media{background:#f2f5f8;border-color:rgba(249,115,22,.24)}
html[data-theme=light] .pub-meta>span{background:#f8fafc}

@media(max-width:1180px){
  .telegram-layout{grid-template-columns:1fr!important}
}
@media(max-width:760px){
  #tgChannelForm{grid-template-columns:1fr}
  #tgChannelForm label.full{grid-column:auto}
  .pub-card{grid-template-columns:92px minmax(0,1fr);gap:11px;padding:10px}
  .pub-media{width:92px;height:124px;border-radius:13px}
  .pub-card-head{flex-direction:column;gap:7px}
  .pub-preview-modal{grid-template-columns:1fr}
  .pub-preview-modal>img{max-height:55vh}
}
@media(max-width:480px){
  .pub-card{grid-template-columns:1fr}
  .pub-media{width:100%;height:240px}
  .pub-actions>*{flex:1 1 auto}
  .pager{align-items:stretch;flex-direction:column}
}


/* ===== MCC v1.0.4 — Login health reliability + row alignment ===== */
.login-shell{align-items:stretch!important}
.login-card,.login-brand{min-height:474px!important}
.login-card{
  display:grid!important;
  grid-template-rows:132px 68px 68px 52px 22px!important;
  gap:12px!important;
  align-content:center!important;
}
.login-form-intro{align-self:end}
.login-form-intro h2{margin:5px 0!important}
.login-form-intro p{margin:0!important}
.login-field{display:grid!important;grid-template-rows:18px 50px!important;gap:0!important;align-self:stretch!important}
.login-field input{height:50px!important;min-height:50px!important;margin:0!important}
.login-submit{height:52px!important;min-height:52px!important;margin:0!important}
.login-card footer{align-self:center!important}
.login-error{position:absolute;top:14px;right:24px;left:24px;z-index:3}
.login-card{position:relative}
.login-brand{
  display:grid!important;
  grid-template-rows:168px auto!important;
  align-content:center!important;
  gap:12px!important;
  justify-content:stretch!important;
}
.login-brand-intro{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-end;min-width:0}
.login-brand-intro .brand-orb{margin-bottom:4px}
.login-brand-intro h1{margin:7px 0 7px!important}
.login-brand-intro p{margin:0!important}
.login-points{
  display:grid!important;
  grid-template-columns:1fr!important;
  grid-template-rows:52px 52px 52px!important;
  gap:10px!important;
  margin:0!important;
  width:100%!important;
  align-content:start!important;
}
.status-chip{height:52px!important;min-height:52px!important;padding:0 14px!important}
/* the third health row visually lines up with the password row */
.login-brand .login-points{transform:translateY(-2px)}
@media(max-width:860px){
  .login-card,.login-brand{min-height:auto!important}
  .login-card{grid-template-rows:auto!important;gap:14px!important}
  .login-brand{display:none!important}
  .login-error{position:static}
}

/* ===== MCC v1.0.5 Sidebar Flow Hotfix ===== */
@media (min-width:861px){
  .app-shell{
    grid-template-columns:320px minmax(0,1fr) !important;
    align-items:start;
  }
  .sidebar{
    position:relative !important;
    top:auto !important;
    right:auto !important;
    height:auto !important;
    min-height:100vh;
    align-self:stretch;
    overflow:visible !important;
    padding:22px 18px 24px !important;
  }
  .side-brand{
    position:relative;
    padding:10px 10px 20px !important;
  }
  .side-nav{
    overflow:visible !important;
    max-height:none !important;
    padding:10px 2px 14px !important;
  }
  .side-nav a{
    min-height:54px !important;
    padding-inline:14px !important;
    font-size:14.5px !important;
  }
  .side-nav a i{
    width:38px !important;
    height:38px !important;
    border-radius:13px !important;
    font-size:16px !important;
  }
  .nav-label{
    font-size:12.5px !important;
    padding:20px 12px 9px !important;
  }
  .side-footer{
    margin-top:18px !important;
    padding-top:16px !important;
  }
  .side-footer a{
    min-height:44px;
    display:flex;
    align-items:center;
    padding-inline:14px !important;
    font-size:13px !important;
  }
}


/* ===== MCC v1.0.5 Publishing filters + thumbnail-first cards ===== */
.publishing-filter-shell{display:grid;gap:12px;margin-bottom:16px;padding:14px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(145deg,var(--surface2),var(--surface))}
.publishing-quick-filters{display:flex;gap:8px;flex-wrap:wrap}
.pub-filter-chip{min-height:38px;padding:0 14px;border:1px solid var(--line);border-radius:11px;background:var(--surface);color:var(--muted);font:inherit;font-size:12.5px;font-weight:800;cursor:pointer;transition:.16s ease}
.pub-filter-chip:hover{border-color:rgba(249,115,22,.42);color:var(--text)}
.pub-filter-chip.active{border-color:#f97316;background:linear-gradient(135deg,rgba(249,115,22,.18),rgba(249,115,22,.08));color:#fb923c;box-shadow:0 7px 18px rgba(249,115,22,.08)}
.pub-filter-chip.danger.active{border-color:#ef4444;background:rgba(239,68,68,.09);color:#f87171}
.publishing-filter-row{display:grid;grid-template-columns:minmax(0,1fr) 210px;gap:10px}
.pub-search-wrap{position:relative;min-width:0}
.pub-search-wrap>span{position:absolute;right:13px;top:50%;transform:translateY(-50%);color:var(--muted);font-size:17px;pointer-events:none}
.pub-search-wrap input{width:100%;min-height:44px;padding:0 40px 0 13px;border:1px solid var(--line);border-radius:13px;background:var(--surface);color:var(--text);outline:0;font:inherit}
.publishing-filter-row>select,.jalali-filter select{min-height:44px;padding:0 12px;border:1px solid var(--line);border-radius:13px;background:var(--surface);color:var(--text);font:inherit;outline:0}
.pub-search-wrap input:focus,.publishing-filter-row>select:focus,.jalali-filter select:focus{border-color:rgba(249,115,22,.65);box-shadow:0 0 0 3px rgba(249,115,22,.08)}
.jalali-filter{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px 13px;border:1px dashed rgba(249,115,22,.26);border-radius:14px;background:rgba(249,115,22,.035)}
.jalali-filter-title{display:flex;align-items:center;gap:9px;min-width:170px}
.jalali-filter-title>span{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;background:rgba(249,115,22,.11)}
.jalali-filter-title b,.jalali-filter-title small{display:block}
.jalali-filter-title b{font-size:12.5px}
.jalali-filter-title small{margin-top:2px;color:var(--muted);font-size:12.5px}
.jalali-filter-selects{display:flex;align-items:center;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.jalali-filter-selects select{min-width:100px}
.publishing-filter-summary{min-height:22px;color:var(--muted);font-size:12.5px;font-weight:700}
.publishing-cards{gap:14px}
.pub-card{grid-template-columns:110px minmax(0,1fr);gap:15px;padding:14px 15px;border-radius:20px;background:linear-gradient(135deg,var(--surface),var(--surface2));box-shadow:0 9px 25px rgba(0,0,0,.045)}
.pub-card:hover{transform:translateY(-1px);border-color:rgba(249,115,22,.38);box-shadow:0 14px 30px rgba(0,0,0,.07)}
.pub-visual{display:flex;flex-direction:column;align-items:center;gap:6px}
.pub-media{width:110px;height:148px;border-radius:14px;background:linear-gradient(145deg,#171c24,#0e1218)}
.pub-thumb-label{font-size:12.5px;color:var(--muted)}
.pub-main{gap:8px}
.pub-account strong{font-size:15px}
.pub-account small{display:block;margin-top:2px;color:var(--muted);font-size:12.5px}
.pub-status-stack{display:grid;gap:6px;justify-items:end;text-align:left}
.pub-status-stack>small{font-size:12.5px;color:var(--muted)}
.pub-main>p{padding:8px 10px;border-radius:11px;background:color-mix(in srgb,var(--surface2) 72%,transparent);font-size:12.5px;line-height:1.85}
.pub-meta>span{min-height:27px;font-size:12.5px}
.pub-error b{color:inherit}
html[data-theme=light] .publishing-filter-shell{background:linear-gradient(145deg,#fff,#f8fafc)}
html[data-theme=light] .pub-filter-chip{background:#fff}
html[data-theme=light] .pub-search-wrap input,html[data-theme=light] .publishing-filter-row>select,html[data-theme=light] .jalali-filter select{background:#fff}
html[data-theme=light] .jalali-filter{background:#fffaf5}
html[data-theme=light] .pub-main>p{background:#f8fafc}
@media(max-width:900px){.jalali-filter{align-items:flex-start;flex-direction:column}.jalali-filter-selects{width:100%;justify-content:flex-start}.publishing-filter-row{grid-template-columns:1fr}}
@media(max-width:620px){.publishing-quick-filters{display:grid;grid-template-columns:1fr 1fr}.pub-filter-chip{width:100%;padding-inline:8px}.jalali-filter-selects{display:grid;grid-template-columns:1fr 1fr;width:100%}.jalali-filter-selects select{min-width:0;width:100%}.jalali-filter-selects .ghost-btn{grid-column:1/-1}.pub-card{grid-template-columns:84px minmax(0,1fr);gap:10px;padding:10px}.pub-media{width:84px;height:114px}.pub-thumb-label{display:none}.pub-card-head{gap:6px}.pub-main>p{font-size:12.5px}.pub-actions>*{flex:1 1 auto}}


/* ===== MCC v1.0.6 — list beauty + mobile tables + publishing cards ===== */
@media (min-width:861px){
  .sidebar{width:340px;min-width:340px}
  .app-shell{grid-template-columns:340px minmax(0,1fr)!important}
}
.side-nav a{min-height:56px;padding:0 14px;border:1px solid rgba(249,115,22,.12);background:linear-gradient(180deg,rgba(255,255,255,.02),rgba(255,255,255,.01));margin-bottom:10px;border-radius:18px}
.side-nav a i{width:34px;height:34px;border-radius:12px}
html[data-theme=light] .side-nav a{background:#fff;border-color:rgba(249,115,22,.18);box-shadow:0 10px 20px rgba(16,24,40,.04)}
.cards-list{gap:14px}
.channel-card{padding:15px 16px;border-radius:18px}
.channel-card .channel-copy strong{font-size:14px}
.channel-card .channel-copy small{font-size:12.5px;line-height:1.75}
.table-wrap{border-radius:20px;background:linear-gradient(180deg,var(--surface),var(--surface2))}
table{white-space:normal}
th,td{font-size:12.5px}
th{font-size:12.5px}
.user-cell{align-items:flex-start;gap:12px}
.user-cell .avatar{width:42px;height:42px;border-radius:14px;font-size:16px}
.user-cell b{font-size:13.5px}
.user-cell small{font-size:12.5px;line-height:1.7}
.telegram-table-wrap .event-name{display:block;font-weight:700;font-size:12.5px;line-height:1.8}
.telegram-table-wrap td small{font-size:12.5px}
.pub-card--fancy{display:grid;grid-template-columns:152px minmax(0,1fr) 132px;gap:18px;padding:18px;border-radius:24px;border:1px solid rgba(249,115,22,.18);background:radial-gradient(460px 160px at 0 0,rgba(249,115,22,.08),transparent 60%),linear-gradient(135deg,var(--surface),var(--surface2));box-shadow:0 14px 34px rgba(0,0,0,.09)}
.pub-actions-col{display:flex;flex-direction:column;gap:8px;align-items:flex-start;justify-content:center}
.pub-actions-col .mini-btn,.pub-actions-col .primary-btn{min-width:110px;justify-content:center}
.pub-topline{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.pub-status-side{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.pub-status-side small,.pub-date-side span{display:inline-flex;align-items:center;gap:6px;color:var(--muted);font-size:12.5px}
.pub-status-side .dot{width:6px;height:6px;border-radius:50%;background:#f97316;display:inline-block}
.pub-date-side{display:grid;justify-items:end;gap:2px}
.pub-date-side b{font-size:12.5px;color:var(--text);font-weight:600}
.pub-account strong{font-size:28px;line-height:1.15}
.pub-account small{font-size:12.5px;line-height:1.8}
.pub-main>p{min-height:46px;font-size:12.5px;color:var(--muted)}
.pub-meta{gap:8px}
.pub-meta>span,.mini-chip{display:inline-flex;align-items:center;min-height:30px;padding:0 10px;border:1px solid var(--line);border-radius:999px;background:rgba(255,255,255,.02);font-size:12.5px;color:var(--muted)}
.mini-chip{color:var(--text)}
.pub-actions-inline{display:flex;gap:8px;flex-wrap:wrap}
.pub-actions-inline .mini-btn{min-height:34px;border-radius:11px}
.pub-visual{display:flex;flex-direction:column;align-items:flex-end;justify-content:center;gap:8px}
.pub-media{width:120px;height:166px;border-radius:18px;box-shadow:0 16px 30px rgba(0,0,0,.18)}
.pub-media.is-broken{background:linear-gradient(145deg,#141922,#0b1017)}
.pub-media.is-broken::after{content:'بدون\A تصویر';white-space:pre;line-height:1.8;color:#97a3b3;font-size:12.5px}
.pub-thumb-label{font-size:12.5px;color:var(--muted)}
html[data-theme=light] .pub-card--fancy{background:radial-gradient(460px 160px at 0 0,rgba(249,115,22,.08),transparent 60%),linear-gradient(145deg,#fff,#f8fafc);box-shadow:0 18px 35px rgba(15,23,42,.05)}
html[data-theme=light] .pub-meta>span,html[data-theme=light] .mini-chip{background:#fff}
@media(max-width:1180px){.pub-card--fancy{grid-template-columns:132px minmax(0,1fr) 112px}.pub-account strong{font-size:24px}}
@media(max-width:860px){
  .table-wrap{overflow:visible;border:none;background:transparent}
  .table-wrap table,.table-wrap thead,.table-wrap tbody,.table-wrap tr,.table-wrap th,.table-wrap td{display:block;width:100%!important}
  .table-wrap thead{display:none}
  .table-wrap tbody{display:grid;gap:12px}
  .table-wrap tr{padding:14px;border:1px solid var(--line);border-radius:18px;background:linear-gradient(145deg,var(--surface),var(--surface2));box-shadow:0 10px 24px rgba(0,0,0,.06)}
  .table-wrap td{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:8px 0;border-bottom:1px dashed rgba(255,255,255,.08);text-align:left}
  html[data-theme=light] .table-wrap td{border-bottom-color:#e7edf5}
  .table-wrap td:last-child{border-bottom:none;padding-bottom:0}
  .table-wrap td::before{content:attr(data-label);flex:0 0 92px;text-align:right;color:var(--muted);font-size:12.5px;font-weight:700}
  .table-wrap td>*{max-width:calc(100% - 100px)}
  .telegram-table-wrap table{min-width:0!important}
  .telegram-table-wrap td,.telegram-table-wrap th{width:100%!important}
  .pub-card--fancy{grid-template-columns:1fr;gap:14px;padding:14px}
  .pub-actions-col{order:3;display:grid;grid-template-columns:1fr 1fr;gap:8px}
  .pub-actions-col .mini-btn,.pub-actions-col .primary-btn{width:100%;min-width:0}
  .pub-main{order:2}
  .pub-visual{order:1;align-items:flex-start}
  .pub-media{width:108px;height:146px}
  .pub-topline,.pub-card-head{flex-direction:column;align-items:flex-start}
  .pub-date-side{justify-items:start}
  .pub-account strong{font-size:22px}
  .pub-actions-inline .mini-btn{flex:1 1 140px}
}
@media(max-width:540px){
  .toolbar input,.toolbar select,.form-grid input,.form-grid select,.form-grid textarea{font-size:13px;min-height:44px}
  .table-wrap td{flex-direction:column;align-items:stretch;gap:6px}
  .table-wrap td::before{flex:none;text-align:right}
  .table-wrap td>*{max-width:100%}
  .user-cell{gap:10px}
  .user-cell .avatar{width:38px;height:38px}
  .pub-actions-col{grid-template-columns:1fr}
  .pub-media{width:100%;height:220px}
  .pub-thumb-label{display:none}
}


/* ===== MCC v1.0.7 — Admin Lists Freeze ===== */
.admin-list-wrap{border:0!important;background:transparent!important;overflow:visible!important}
.admin-list-table{border-collapse:separate!important;border-spacing:0 10px!important;white-space:normal!important}
.admin-list-table thead th{position:static!important;background:transparent!important;border:0!important;padding:0 14px 7px!important;color:var(--muted);font-size:12.5px!important;font-weight:700}
.admin-list-table tbody tr{filter:drop-shadow(0 8px 18px rgba(0,0,0,.035))}
.admin-list-table tbody td{padding:15px 14px!important;background:linear-gradient(180deg,var(--surface2),var(--surface));border-top:1px solid var(--line)!important;border-bottom:1px solid var(--line)!important;vertical-align:middle!important}
.admin-list-table tbody td:first-child{border-right:1px solid var(--line)!important;border-radius:0 18px 18px 0}
.admin-list-table tbody td:last-child{border-left:1px solid var(--line)!important;border-radius:18px 0 0 18px}
.admin-list-table tbody tr:hover td{border-color:rgba(249,115,22,.24)!important;background:linear-gradient(180deg,color-mix(in srgb,var(--surface2) 90%,#f97316 10%),var(--surface))}
.user-cell-rich .avatar{border-color:rgba(249,115,22,.38);background:linear-gradient(145deg,rgba(249,115,22,.22),rgba(249,115,22,.06));color:#ff9b55}
.user-contact-lines{display:grid;gap:2px;margin-top:5px;color:var(--muted);font-size:12.5px;direction:ltr;text-align:right}
.dual-badges{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.user-activity-cell,.token-cell,.membership-cell,.login-cell{display:grid;gap:3px}
.user-activity-cell b,.token-cell b,.membership-cell b,.login-cell b{font-size:13px}
.user-activity-cell small,.token-cell small,.membership-cell small,.login-cell small{font-size:12.5px;color:var(--muted)}
.list-actions{flex-wrap:wrap}.list-actions .mini-btn{min-height:34px;padding-inline:12px}.token-btn{border-color:rgba(234,179,8,.30)!important;color:#f0c63c!important}
html[data-theme=light] .admin-list-table tbody td{background:linear-gradient(180deg,#fff,#fbfcfe);box-shadow:none}
html[data-theme=light] .admin-list-table tbody tr:hover td{background:linear-gradient(180deg,#fffaf5,#fff)}

.publishing-list{display:grid;gap:12px}
.pub-row{position:relative;display:grid;grid-template-columns:145px 150px 170px minmax(0,1fr) 118px;align-items:center;gap:16px;padding:14px 16px;border:1px solid var(--line);border-radius:22px;background:linear-gradient(180deg,var(--surface2),var(--surface));box-shadow:0 10px 24px rgba(0,0,0,.055);overflow:hidden;transition:.18s}
.pub-row:hover{border-color:rgba(249,115,22,.34);transform:translateY(-1px);box-shadow:0 15px 32px rgba(0,0,0,.075)}
.pub-row-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}.pub-row-actions .primary-btn{grid-column:1/-1;min-height:38px;font-size:12.5px}.pub-row-actions .mini-btn{min-height:34px;font-size:12.5px}
.pub-row-status{display:grid;justify-items:center;gap:7px}.pub-row-status small{color:var(--muted);font-size:12.5px}
.pub-row-time{display:grid;justify-items:center;gap:5px}.pub-row-time b{font-size:15px;direction:ltr}.pub-row-time small{font-size:12.5px;color:var(--muted);text-align:center}
.pub-row-account{min-width:0;display:grid;gap:4px}.pub-row-account>strong{font-size:16px}.pub-row-account>small{font-size:12.5px;color:var(--muted)}.pub-row-account>p{margin:5px 0 2px;font-size:12.5px;color:var(--text);line-height:1.8;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.pub-row-mini-actions{display:flex;gap:6px;flex-wrap:wrap}.pub-row-mini-actions .mini-btn{min-height:30px;font-size:12.5px}
.pub-row-media{display:grid;justify-items:center;gap:6px}.pub-row-media .pub-media{width:88px;height:122px;border-radius:15px}.pub-row-media>small{font-size:12.5px;color:var(--muted)}
html[data-theme=light] .pub-row{background:linear-gradient(180deg,#fff,#fbfcfe);box-shadow:0 12px 25px rgba(15,23,42,.045)}

@media(max-width:1180px){.pub-row{grid-template-columns:130px 125px 145px minmax(0,1fr) 100px;gap:11px;padding:12px}.pub-row-media .pub-media{width:80px;height:112px}}
@media(max-width:860px){
  .admin-list-table{border-spacing:0!important}
  .admin-list-table tbody{gap:12px!important}
  .admin-list-table tbody tr{filter:none!important}
  .admin-list-table tbody td{border-left:1px solid var(--line)!important;border-right:1px solid var(--line)!important;border-top:0!important;border-bottom:1px dashed var(--line)!important;border-radius:0!important;padding:10px 12px!important}
  .admin-list-table tbody td:first-child{border-top:1px solid var(--line)!important;border-radius:18px 18px 0 0!important}
  .admin-list-table tbody td:last-child{border-bottom:1px solid var(--line)!important;border-radius:0 0 18px 18px!important}
  .pub-row{grid-template-columns:104px minmax(0,1fr);grid-template-areas:'media account' 'status time' 'actions actions';gap:12px;padding:13px}
  .pub-row-media{grid-area:media;justify-items:start}.pub-row-account{grid-area:account}.pub-row-status{grid-area:status;justify-items:start}.pub-row-time{grid-area:time;justify-items:end}.pub-row-actions{grid-area:actions;grid-template-columns:1fr 1fr 1fr}.pub-row-actions .primary-btn{grid-column:auto}
  .pub-row-media .pub-media{width:96px;height:132px}
  .pub-row-account>strong{font-size:15px}.pub-row-account>p{font-size:12.5px}
}
@media(max-width:540px){
  .pub-row{grid-template-columns:82px minmax(0,1fr);grid-template-areas:'media account' 'status status' 'time time' 'actions actions'}
  .pub-row-media .pub-media{width:76px;height:108px}.pub-row-actions{grid-template-columns:1fr}.pub-row-time{justify-items:start}.pub-row-status{justify-items:start}
  .admin-list-table td::before{font-size:12.5px!important}.admin-list-table td{font-size:12.5px!important}
}


/* ===== MCC v1.0.8 — Visual / Modal / OAuth / Publishing Regression Fix Pack ===== */
/* universal text guards: never break badges/buttons letter by letter */
.badge,.mini-btn,.primary-btn,.ghost-btn,.side-nav a,.count-pill,.date-cell,.ig-owner,.token-cell,.dual-badges{word-break:keep-all!important;overflow-wrap:normal!important;white-space:nowrap}
.row-actions{flex-wrap:wrap;align-items:center}
.row-actions>*{flex:0 0 auto}

/* Billing: keep payment rows inside their own grid column */
.billing-grid{grid-template-columns:minmax(0,1.18fr) minmax(320px,.82fr)!important;align-items:start}
.billing-grid>.panel{min-width:0!important;max-width:100%;overflow:hidden}
.billing-payments-panel .billing-list-wrap{width:100%;max-width:100%;overflow:hidden!important}
.billing-payments-panel .admin-list-table{width:100%!important;max-width:100%;min-width:0!important;table-layout:fixed!important}
.billing-payments-panel .admin-list-table th,.billing-payments-panel .admin-list-table td{min-width:0!important;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap!important}
.billing-payments-panel .admin-list-table th:nth-child(1){width:9%}.billing-payments-panel .admin-list-table th:nth-child(2){width:20%}.billing-payments-panel .admin-list-table th:nth-child(3){width:16%}.billing-payments-panel .admin-list-table th:nth-child(4){width:17%}.billing-payments-panel .admin-list-table th:nth-child(5){width:18%}.billing-payments-panel .admin-list-table th:nth-child(6){width:20%}

/* Instagram list: stable columns and readable metadata */
#igTable .ig-account-cell{min-width:180px}
#igTable .ig-account-cell b{font-size:14px;white-space:nowrap;word-break:normal!important}
#igTable .ig-account-cell small{font-size:12.5px;white-space:normal;overflow-wrap:anywhere}
.ig-avatar{flex:0 0 44px;width:44px;height:44px;border-radius:15px;font-size:14px}
.ig-owner{display:inline-block;max-width:150px;overflow:hidden;text-overflow:ellipsis}
.count-pill{display:inline-flex;min-width:34px;min-height:30px;align-items:center;justify-content:center;border:1px solid var(--line);border-radius:999px;background:var(--surface2);font-weight:800}
.date-cell{font-size:12.5px;color:var(--muted)}
.ig-row-actions{display:grid!important;grid-template-columns:repeat(2,max-content);gap:7px!important;justify-content:end}
.ig-row-actions .oauth-btn{grid-column:1/-1;color:#f6a56d;border-color:rgba(249,115,22,.32)}
.admin-list-table td{word-break:normal!important;overflow-wrap:normal!important}

/* Premium modal system for every edit form */
.modal-backdrop{background:rgba(2,5,10,.74)!important;backdrop-filter:blur(10px)!important}
.modal{padding:22px!important}
.modal-card-premium{width:min(860px,calc(100vw - 32px))!important;max-height:min(90vh,900px)!important;border:1px solid rgba(249,115,22,.22)!important;border-radius:28px!important;background:linear-gradient(165deg,var(--surface),color-mix(in srgb,var(--surface2) 94%,#f97316 6%))!important;box-shadow:0 38px 110px rgba(0,0,0,.5)!important;overflow:auto!important}
.modal-head{padding:18px 22px!important;background:color-mix(in srgb,var(--surface) 92%,transparent)!important;backdrop-filter:blur(16px);border-bottom:1px solid rgba(249,115,22,.13)!important}
.modal-head h3{font-size:18px!important;font-weight:900;letter-spacing:-.02em}
.modal-head button{width:40px!important;height:40px!important;border-radius:13px!important;font-size:22px!important}
#modalBody{padding:22px!important}
.edit-modal-shell{display:grid;gap:16px}
.edit-modal-banner{display:flex;align-items:center;gap:13px;padding:15px 16px;border:1px solid rgba(249,115,22,.17);border-radius:18px;background:linear-gradient(135deg,rgba(249,115,22,.09),rgba(249,115,22,.025))}
.edit-modal-icon{width:46px;height:46px;flex:0 0 46px;display:grid;place-items:center;border-radius:15px;background:linear-gradient(145deg,#fb923c,#c2410c);color:#fff;font-size:22px;box-shadow:0 12px 30px rgba(249,115,22,.2)}
.edit-modal-banner b{display:block;font-size:15px}.edit-modal-banner small{display:block;margin-top:4px;color:var(--muted);font-size:12.5px;line-height:1.8}.modal-status{margin-right:auto}
.premium-form{gap:12px!important}
#modalBody .premium-form>label:not(.switch-row),#modalBody .form-grid>label:not(.switch-row){padding:12px 13px;border:1px solid var(--line);border-radius:15px;background:color-mix(in srgb,var(--surface2) 90%,transparent);font-size:12.5px!important;gap:8px!important}
#modalBody .premium-form label>span:first-child{display:flex;align-items:center;justify-content:space-between;gap:8px;color:var(--muted);font-weight:700}
#modalBody input:not([type=checkbox]),#modalBody select,#modalBody textarea{width:100%;min-height:46px;padding:10px 12px;border:1px solid color-mix(in srgb,var(--line) 78%,#f97316 22%);border-radius:12px;background:var(--bg);color:var(--text);font-size:13px;outline:none}
#modalBody textarea{min-height:116px;resize:vertical;line-height:1.9}
#modalBody input:focus,#modalBody select:focus,#modalBody textarea:focus{border-color:#f97316;box-shadow:0 0 0 3px rgba(249,115,22,.10)}
.switch-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.switch-row{display:flex!important;align-items:flex-start!important;gap:10px!important;padding:12px 13px;border:1px solid var(--line);border-radius:15px;background:var(--surface2);color:var(--text)!important}
.switch-row input{width:18px;height:18px;flex:0 0 18px;margin-top:2px;accent-color:#f97316}.switch-row b,.switch-row small{display:block}.switch-row b{font-size:12.5px}.switch-row small{margin-top:3px;color:var(--muted);font-size:12.5px;line-height:1.7}
.oauth-recheck-card{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 15px;border:1px solid rgba(34,197,94,.22);border-radius:17px;background:rgba(34,197,94,.055)}
.oauth-recheck-card b,.oauth-recheck-card small{display:block}.oauth-recheck-card b{font-size:13px}.oauth-recheck-card small{margin-top:4px;color:var(--muted);font-size:12.5px;line-height:1.8}.primary-btn.compact{min-height:40px;font-size:12.5px;white-space:nowrap}
.modal-footer-actions{display:flex!important;justify-content:flex-end;gap:9px;padding-top:6px}.modal-footer-actions>*{min-width:135px}
.form-grid.is-busy{opacity:.62;pointer-events:none}.is-hidden{display:none!important}

/* Publishing: force true RTL visual order — thumbnail at the RIGHT */
.publishing-list{display:grid;gap:12px}
.pub-row{direction:rtl!important;display:grid!important;grid-template-columns:118px minmax(280px,1fr) 170px 150px 150px!important;grid-template-areas:'media account time status actions'!important;gap:16px!important;align-items:center!important;padding:15px 16px!important;overflow:visible!important}
.pub-row-media{grid-area:media!important;justify-items:center!important}.pub-row-account{grid-area:account!important;text-align:right!important}.pub-row-time{grid-area:time!important}.pub-row-status{grid-area:status!important}.pub-row-actions{grid-area:actions!important}
.pub-row-account>strong{font-size:16px!important;direction:ltr;text-align:right;white-space:nowrap}.pub-row-account>small{font-size:12.5px}.pub-row-account>p{max-width:620px}
.pub-row-media .pub-media{width:94px!important;height:132px!important;border:1px solid rgba(249,115,22,.32)!important;box-shadow:0 10px 25px rgba(0,0,0,.14)}
.pub-row-actions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:7px!important}.pub-row-actions .primary-btn{grid-column:1/-1!important}.pub-row-actions button:disabled{opacity:.38;cursor:not-allowed}
.pub-row-mini-actions{justify-content:flex-start}

/* light theme modal/list polish */
html[data-theme=light] .modal-card-premium{background:linear-gradient(165deg,#fff,#f8fafc)!important;box-shadow:0 32px 90px rgba(15,23,42,.18)!important}
html[data-theme=light] #modalBody input:not([type=checkbox]),html[data-theme=light] #modalBody select,html[data-theme=light] #modalBody textarea{background:#fff}
html[data-theme=light] .switch-row{background:#fbfcfe}

@media(max-width:1180px){.billing-grid{grid-template-columns:1fr!important}.billing-payments-panel .billing-list-wrap{overflow:auto!important}.pub-row{grid-template-columns:100px minmax(220px,1fr) 140px 125px 130px!important;gap:10px!important}}
@media(max-width:860px){
  .billing-payments-panel .admin-list-table{table-layout:auto!important}
  .ig-row-actions{display:flex!important;justify-content:flex-start;flex-wrap:wrap}.ig-row-actions .oauth-btn{grid-column:auto}
  .switch-grid{grid-template-columns:1fr}
  .oauth-recheck-card{align-items:stretch;flex-direction:column}.oauth-recheck-card .primary-btn{width:100%}
  .modal-card-premium{width:min(96vw,760px)!important;border-radius:22px!important}.modal{padding:10px!important}#modalBody{padding:16px!important}
  .pub-row{grid-template-columns:96px minmax(0,1fr)!important;grid-template-areas:'media account' 'time status' 'actions actions'!important;gap:12px!important}.pub-row-media{justify-items:start!important}.pub-row-time,.pub-row-status{justify-items:start!important}.pub-row-actions{grid-template-columns:repeat(3,1fr)!important}.pub-row-actions .primary-btn{grid-column:auto!important}
}
@media(max-width:540px){
  .modal-head h3{font-size:15px!important}.edit-modal-banner{align-items:flex-start}.edit-modal-icon{width:40px;height:40px;flex-basis:40px}.modal-status{margin-right:0;margin-left:auto}.modal-footer-actions{display:grid!important;grid-template-columns:1fr 1fr}.modal-footer-actions>*{min-width:0;width:100%}
  .pub-row{grid-template-columns:84px minmax(0,1fr)!important;grid-template-areas:'media account' 'status status' 'time time' 'actions actions'!important}.pub-row-media .pub-media{width:80px!important;height:112px!important}.pub-row-actions{grid-template-columns:1fr!important}
}

/* ===== MCC v1.0.9 — Jalali AJAX filters + Story editor parity + layout guards ===== */
.admin-date-filter{
  margin:12px 0 16px;padding:14px 15px;border:1px solid rgba(249,115,22,.20);border-radius:20px;
  background:radial-gradient(440px 150px at 100% 0,rgba(249,115,22,.09),transparent 68%),linear-gradient(145deg,var(--surface2),var(--surface));
  box-shadow:0 10px 28px rgba(0,0,0,.045)
}
.admin-date-filter.compact{margin-top:0}
.date-filter-head{display:flex;align-items:center;gap:11px;margin-bottom:12px;min-width:0}
.date-filter-icon{width:42px;height:42px;flex:0 0 42px;display:grid;place-items:center;border-radius:14px;background:linear-gradient(145deg,rgba(249,115,22,.18),rgba(249,115,22,.08));border:1px solid rgba(249,115,22,.19);font-size:18px}
.date-filter-copy{min-width:0}.date-filter-copy b,.date-filter-copy small{display:block}.date-filter-copy b{font-size:13px}.date-filter-copy small{margin-top:3px;color:var(--muted);font-size:12.5px;line-height:1.7}
.date-filter-readout{margin-right:auto;max-width:280px;padding:8px 11px;border:1px solid var(--line);border-radius:11px;background:var(--surface);color:#fb923c;font-size:12.5px;font-weight:800;text-align:center}
.date-filter-controls{display:grid;grid-template-columns:repeat(3,minmax(120px,1fr)) minmax(270px,1.25fr);gap:9px;align-items:stretch}
.date-choice-card{position:relative;display:grid!important;gap:5px!important;padding:9px 10px!important;border:1px solid var(--line)!important;border-radius:14px!important;background:var(--surface)!important;color:var(--muted)!important}
.date-choice-card>span{font-size:12.5px;font-weight:800}
.date-choice-card select{width:100%;min-height:36px!important;padding:0!important;border:0!important;background:transparent!important;color:var(--text)!important;font-size:12.5px!important;font-weight:800;outline:0;box-shadow:none!important}
.date-filter-actions{display:grid;grid-template-columns:1fr 1fr 1.25fr;gap:7px}
.date-quick-btn,.date-clear-btn{border:1px solid var(--line);border-radius:13px;background:var(--surface);color:var(--text);font:inherit;font-size:12.5px;font-weight:800;cursor:pointer;transition:.18s}
.date-quick-btn:hover{border-color:rgba(249,115,22,.42);background:rgba(249,115,22,.07)}
.date-clear-btn{border-color:rgba(249,115,22,.25);color:#fb923c;background:rgba(249,115,22,.045)}
html[data-theme=light] .admin-date-filter{background:radial-gradient(440px 150px at 100% 0,rgba(249,115,22,.08),transparent 68%),linear-gradient(145deg,#fff,#f8fafc)}
html[data-theme=light] .date-choice-card,html[data-theme=light] .date-filter-readout,html[data-theme=light] .date-quick-btn{background:#fff!important}

/* publishing row must never escape its panel */
.publishing-panel{min-width:0;max-width:100%;overflow:hidden!important}
.publishing-list{min-width:0;max-width:100%;overflow:hidden}
.pub-row{width:100%;max-width:100%;min-width:0;box-sizing:border-box;overflow:hidden!important}
.pub-row>*{min-width:0;max-width:100%}
.pub-row-account{overflow:hidden}.pub-row-account>strong,.pub-row-account>small,.pub-row-account>p{max-width:100%;overflow:hidden;text-overflow:ellipsis}
.pub-row-actions .mini-btn,.pub-row-actions .primary-btn{min-width:0!important;width:100%;white-space:nowrap}
.pub-row-media .pub-media{max-width:100%}
.pub-row.is-removing{opacity:.42;transform:scale(.992);pointer-events:none;transition:.18s}

/* Story edit modal: aligned with the user-panel scheduling language */
.story-edit-shell{gap:14px}
.pub-edit-form{display:grid;gap:14px!important}
.story-edit-caption>label{display:grid;gap:8px;padding:13px 14px;border:1px solid var(--line);border-radius:17px;background:var(--surface2)}
.story-edit-caption>label>span{font-size:12.5px;color:var(--muted);font-weight:800}
.story-edit-caption textarea{min-height:108px!important}
.schedule-card-admin{width:100%;min-width:0;padding:14px;border:1px solid rgba(249,115,22,.28);border-radius:19px;background:linear-gradient(145deg,rgba(249,115,22,.08),rgba(255,255,255,.018));transition:.18s}
.schedule-card-admin.is-disabled{opacity:.48;filter:saturate(.55)}
.schedule-admin-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.schedule-admin-head>div{display:flex;align-items:center;gap:9px;min-width:0}.schedule-admin-head b,.schedule-admin-head small{display:block}.schedule-admin-head b{font-size:13px}.schedule-admin-head small{margin-top:2px;color:var(--muted);font-size:12.5px}.schedule-admin-head>strong{max-width:50%;color:#fb923c;font-size:12.5px;text-align:left}
.schedule-admin-icon{width:36px;height:36px;display:grid;place-items:center;border-radius:12px;background:rgba(249,115,22,.12);color:#fb923c;font-size:17px}
.schedule-wheel-grid{display:grid;grid-template-columns:1.05fr 1.45fr .78fr .78fr .78fr;gap:6px;direction:rtl}
.schedule-wheel-wrap{min-width:0}.schedule-wheel-wrap>span{display:block;margin-bottom:5px;text-align:center;color:var(--muted);font-size:12.5px;font-weight:800}
.schedule-wheel{display:grid;overflow:hidden;border:1px solid var(--line);border-radius:13px;background:var(--surface)}
.schedule-wheel button{height:36px;padding:0 5px;border:0;border-bottom:1px solid var(--line);background:transparent;color:var(--muted);font:inherit;font-size:12.5px;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.schedule-wheel button:last-child{border-bottom:0}.schedule-wheel button:hover{background:rgba(249,115,22,.06);color:var(--text)}
.schedule-wheel button.selected{height:42px;background:linear-gradient(90deg,rgba(249,115,22,.18),rgba(249,115,22,.08));color:#fff;font-size:12.5px;font-weight:900;box-shadow:inset 0 0 0 1px rgba(249,115,22,.34)}
html[data-theme=light] .schedule-card-admin{background:linear-gradient(145deg,#fffaf5,#fff)}
html[data-theme=light] .schedule-wheel{background:#f7f9fc}.schedule-wheel button.selected{color:#f97316}
.story-status-card{display:grid;gap:10px;padding:13px 14px;border:1px solid var(--line);border-radius:17px;background:var(--surface2)}
.story-status-title b,.story-status-title small{display:block}.story-status-title b{font-size:12.5px}.story-status-title small{margin-top:2px;color:var(--muted);font-size:12.5px}
.story-status-toggle{display:grid;grid-template-columns:repeat(4,1fr);gap:7px}
.story-status-toggle button{min-height:40px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--muted);font:inherit;font-size:12.5px;font-weight:800;cursor:pointer;white-space:nowrap}
.story-status-toggle button.active{border-color:rgba(249,115,22,.42);background:linear-gradient(145deg,rgba(249,115,22,.18),rgba(249,115,22,.07));color:#fb923c;box-shadow:0 7px 18px rgba(249,115,22,.08)}

/* generic admin list width / mobile safety */
.grid-2,.grid-2>*{min-width:0}.panel{min-width:0;max-width:100%}.admin-list-wrap{max-width:100%}
.admin-list-table td,.admin-list-table th{word-break:normal!important;overflow-wrap:normal!important}
.admin-list-table .badge,.admin-list-table button,.admin-list-table a{white-space:nowrap!important}

@media(max-width:1260px){
  .date-filter-controls{grid-template-columns:repeat(3,1fr)}.date-filter-actions{grid-column:1/-1}
  .pub-row{grid-template-columns:104px minmax(220px,1fr) 125px 112px 128px!important;gap:9px!important}
}
@media(max-width:1040px){
  .pub-row{grid-template-columns:92px minmax(0,1fr)!important;grid-template-areas:'media account' 'time status' 'actions actions'!important}
  .pub-row-media{grid-area:media!important;justify-items:start!important}.pub-row-account{grid-area:account!important}.pub-row-time{grid-area:time!important;justify-items:start!important}.pub-row-status{grid-area:status!important;justify-items:start!important}.pub-row-actions{grid-area:actions!important;grid-template-columns:repeat(3,1fr)!important}.pub-row-actions .primary-btn{grid-column:auto!important}
}
@media(max-width:760px){
  .date-filter-head{align-items:flex-start;flex-wrap:wrap}.date-filter-readout{order:3;width:100%;max-width:none;margin:0}.date-filter-controls{grid-template-columns:1fr 1fr}.date-filter-actions{grid-column:1/-1}.date-choice-card:nth-child(3){grid-column:1/-1}
  .schedule-admin-head{align-items:flex-start;flex-direction:column}.schedule-admin-head>strong{max-width:100%;text-align:right}.schedule-wheel-grid{grid-template-columns:1fr 1.3fr 1fr;gap:5px}.schedule-wheel-wrap:nth-child(4),.schedule-wheel-wrap:nth-child(5){grid-column:auto}.story-status-toggle{grid-template-columns:1fr 1fr}
}
@media(max-width:540px){
  .admin-date-filter{padding:11px;border-radius:16px}.date-filter-controls{grid-template-columns:1fr}.date-choice-card:nth-child(3),.date-filter-actions{grid-column:auto}.date-filter-actions{grid-template-columns:1fr 1fr}.date-clear-btn{grid-column:1/-1;min-height:40px}
  .pub-row{grid-template-columns:78px minmax(0,1fr)!important;grid-template-areas:'media account' 'status status' 'time time' 'actions actions'!important;padding:11px!important}.pub-row-actions{grid-template-columns:1fr!important}.pub-row-media .pub-media{width:74px!important;height:104px!important}
  .schedule-wheel-grid{grid-template-columns:1fr 1.25fr 1fr}.schedule-wheel-wrap:nth-child(4),.schedule-wheel-wrap:nth-child(5){grid-column:span 1}.schedule-wheel button{height:33px;font-size:12.5px}.schedule-wheel button.selected{height:38px;font-size:12.5px}
  .story-status-toggle{grid-template-columns:1fr}
}
.story-current-media{display:grid;grid-template-columns:92px minmax(0,1fr);gap:13px;align-items:center;padding:12px 13px;border:1px solid rgba(249,115,22,.18);border-radius:17px;background:linear-gradient(145deg,rgba(249,115,22,.065),rgba(255,255,255,.015))}
.story-current-media-frame{width:92px;height:124px;overflow:hidden;border:1px solid rgba(249,115,22,.28);border-radius:14px;background:var(--surface);box-shadow:0 10px 24px rgba(0,0,0,.13)}
.story-current-media-frame img{width:100%;height:100%;object-fit:cover;display:block}.story-current-media b,.story-current-media small{display:block}.story-current-media b{font-size:13px}.story-current-media small{margin:4px 0 9px;color:var(--muted);font-size:12.5px;line-height:1.8}
@media(max-width:540px){.story-current-media{grid-template-columns:72px minmax(0,1fr)}.story-current-media-frame{width:72px;height:98px}}
.schedule-card-admin.is-disabled .schedule-wheel-grid{pointer-events:none}


/* ===== MCC v1.0.10 — Exact MSM Jalali ribbon + hard containment ===== */
html,body{max-width:100%;overflow-x:hidden!important}
.app-shell,.main-column,.content,.panel,.grid-2,.grid-2>*,.publishing-panel,.publishing-filter-shell,.publishing-list,.telegram-layout,.billing-grid{min-width:0!important;max-width:100%!important}
.content{overflow-x:hidden!important}
.panel{overflow:hidden!important}
.admin-list-wrap{width:100%!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;contain:layout paint}
.admin-list-table{min-width:0;max-width:100%}

/* Exact date ribbon copied from the visual language of MSM Story list */
.admin-date-filter{margin:12px 0 16px!important;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;max-width:100%;overflow:hidden}
.msm-date-card{position:relative;width:100%;max-width:100%;padding:13px;border:1px solid rgba(249,115,22,.23);border-radius:18px;background:linear-gradient(145deg,var(--surface2),var(--surface));overflow:hidden}
.msm-date-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px;min-width:0}
.msm-date-title{display:flex;align-items:center;gap:9px;min-width:0}.msm-date-title>div{min-width:0}.msm-date-title b,.msm-date-title small{display:block}.msm-date-title b{font-size:12.5px}.msm-date-title small{margin-top:2px;color:var(--muted);font-size:12.5px}
.msm-date-icon{width:34px;height:34px;flex:0 0 34px;display:grid;place-items:center;border-radius:10px;background:rgba(249,115,22,.11);font-size:16px}
.msm-date-mode{max-width:34%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#fb923c;font-size:12.5px;font-weight:900}
.msm-date-nav{display:flex;align-items:center;gap:6px;direction:ltr;max-width:100%;min-width:0}
.msm-date-strip-wrap{flex:1 1 auto;min-width:0;overflow-x:auto;scrollbar-width:none;overscroll-behavior-inline:contain}.msm-date-strip-wrap::-webkit-scrollbar{display:none}
.msm-date-strip{display:flex;gap:7px;width:max-content;min-width:100%;direction:rtl;justify-content:flex-start}
.msm-date-arrow{flex:0 0 32px;width:32px;height:34px;padding:0;border:1px solid #30353c;border-radius:10px;background:#12161b;color:#b2b7be;font-size:16px;cursor:pointer;transition:.16s}.msm-date-arrow:hover{border-color:#f97316;color:#ff9a4d;background:rgba(249,115,22,.10)}
.msm-date-day{flex:0 0 78px;width:78px;min-height:67px;padding:8px 6px;border:1px solid #2d333a;border-radius:12px;background:#12161b;color:var(--text);display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;cursor:pointer;transition:.16s ease;user-select:none}
.msm-date-day:hover{transform:translateY(-2px);border-color:#f97316;background:linear-gradient(145deg,rgba(249,115,22,.18),rgba(249,115,22,.045));box-shadow:0 8px 20px rgba(249,115,22,.13)}
.msm-date-day .wd{font-size:12.5px;margin-bottom:5px;color:#8f98a3;white-space:nowrap}.msm-date-day strong{font-size:12.5px;line-height:1.45;white-space:nowrap}.msm-date-day small{margin-top:3px;color:#66707b;font-size:12.5px;white-space:nowrap}
.msm-date-day.today{border-color:rgba(249,115,22,.62);box-shadow:inset 0 0 0 1px rgba(249,115,22,.09)}
.msm-date-day.selected{transform:none;background:linear-gradient(135deg,#ff812b,#f2610b);border-color:#ff8a38;box-shadow:0 7px 18px rgba(249,115,22,.28)}.msm-date-day.selected *{color:#fff!important}
.msm-date-readout{margin-top:9px;padding-top:8px;border-top:1px dashed rgba(255,255,255,.12);text-align:center;color:var(--muted);font-size:12.5px}.msm-date-readout b{color:#fb923c;font-weight:900}
.msm-date-quick{display:flex;justify-content:center;gap:6px;flex-wrap:wrap;margin-top:8px}.msm-date-quick button{min-height:34px;padding:0 11px;border:1px solid var(--line);border-radius:10px;background:var(--surface2);color:var(--muted);font:inherit;font-size:12.5px;font-weight:800;cursor:pointer}.msm-date-quick button.active,.msm-date-quick button:hover{border-color:rgba(249,115,22,.42);background:rgba(249,115,22,.10);color:#fb923c}
.msm-date-loading{position:absolute;inset:0;display:none;place-items:center;background:rgba(7,10,14,.48);backdrop-filter:blur(2px);z-index:4}.msm-date-loading i{width:28px;height:28px;border:3px solid rgba(255,255,255,.18);border-top-color:#f97316;border-radius:50%;animation:mccSpin .7s linear infinite}.admin-date-filter.is-loading .msm-date-loading{display:grid}
html[data-theme=light] .msm-date-card{background:linear-gradient(145deg,#fff,#f8fafc)}html[data-theme=light] .msm-date-arrow,html[data-theme=light] .msm-date-day{background:#fff;border-color:#d9e0e8;color:#26313d}html[data-theme=light] .msm-date-day .wd{color:#747d87}html[data-theme=light] .msm-date-day small{color:#9aa3ad}html[data-theme=light] .msm-date-readout{border-top-color:#e6eaf0}

/* Publishing row: explicit physical columns, no grid-area ambiguity, no escape */
.pub-row{direction:rtl!important;display:grid!important;grid-template-columns:100px minmax(0,1fr) 112px 112px 138px!important;grid-template-areas:none!important;gap:11px!important;width:100%!important;max-width:100%!important;min-width:0!important;padding:14px!important;margin:0!important;box-sizing:border-box!important;overflow:hidden!important;contain:layout paint}
.pub-row-media{grid-column:1!important;grid-row:1!important;min-width:0!important}.pub-row-account{grid-column:2!important;grid-row:1!important;min-width:0!important;overflow:hidden!important}.pub-row-time{grid-column:3!important;grid-row:1!important;min-width:0!important}.pub-row-status{grid-column:4!important;grid-row:1!important;min-width:0!important}.pub-row-actions{grid-column:5!important;grid-row:1!important;min-width:0!important;display:grid!important;grid-template-columns:1fr!important;gap:7px!important;align-self:center!important}
.pub-row-actions>*{display:flex!important;width:100%!important;max-width:100%!important;min-width:0!important;box-sizing:border-box!important;justify-content:center!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}
.pub-row-account>strong,.pub-row-account>small,.pub-row-account>p{max-width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important}.pub-row-account>p{white-space:nowrap!important}
.pub-row-media .pub-media{width:88px!important;height:124px!important;max-width:100%!important}

/* laptop widths: do NOT keep narrow two-column operational list layouts */
@media(max-width:1450px){.telegram-layout,.billing-grid{grid-template-columns:1fr!important}.telegram-channels-panel,.telegram-deliveries-panel,.billing-payments-panel{width:100%!important;max-width:100%!important}}
@media(max-width:1100px){.pub-row{grid-template-columns:88px minmax(0,1fr) 104px 104px 124px!important;gap:8px!important}}
@media(max-width:980px){.pub-row{grid-template-columns:82px minmax(0,1fr)!important;grid-template-rows:auto auto auto;gap:10px!important}.pub-row-media{grid-column:1!important;grid-row:1!important}.pub-row-account{grid-column:2!important;grid-row:1!important}.pub-row-time{grid-column:1!important;grid-row:2!important}.pub-row-status{grid-column:2!important;grid-row:2!important}.pub-row-actions{grid-column:1/3!important;grid-row:3!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}.pub-row-media .pub-media{width:78px!important;height:108px!important}}
@media(max-width:700px){.msm-date-card{padding:10px}.msm-date-day{flex-basis:72px;width:72px;min-height:63px}.msm-date-arrow{flex-basis:29px;width:29px;height:32px}.msm-date-mode{max-width:42%;font-size:12.5px}.pub-row-actions{grid-template-columns:1fr!important}.pub-row{grid-template-columns:76px minmax(0,1fr)!important}.pub-row-media .pub-media{width:72px!important;height:100px!important}}


/* ===== MCC v1.0.11 — Telegram test + exact date + mobile hardening ===== */
/* Desktop Telegram panels remain in one row; delivery gets more room. */
@media (min-width:1201px){
  .telegram-layout{display:grid!important;grid-template-columns:minmax(300px,.38fr) minmax(0,.62fr)!important;gap:16px!important;align-items:start!important}
  .telegram-channels-panel,.telegram-deliveries-panel{min-width:0!important;width:auto!important;max-width:100%!important}
}
/* Billing is allowed to be two-column only when enough room exists. */
@media (min-width:1381px){.billing-grid{grid-template-columns:minmax(0,1.25fr) minmax(330px,.75fr)!important;align-items:start!important}}
@media (max-width:1380px){.billing-grid{grid-template-columns:1fr!important}}

/* Exact Jalali ribbon: every child is contained by its own card. */
.admin-date-filter{width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;box-sizing:border-box!important}
.msm-date-card{width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important;box-sizing:border-box!important;padding:14px!important}
.msm-date-head{margin:0 0 12px!important;min-width:0!important}
.msm-date-carousel{display:grid!important;grid-template-columns:36px minmax(0,1fr) 36px!important;gap:8px!important;align-items:center!important;width:100%!important;max-width:100%!important;min-width:0!important;direction:ltr!important}
.msm-date-strip-wrap{width:100%!important;min-width:0!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;scrollbar-width:none!important;overscroll-behavior-x:contain!important}
.msm-date-strip-wrap::-webkit-scrollbar{display:none!important}
.msm-date-strip{display:flex!important;gap:8px!important;width:max-content!important;min-width:0!important;max-width:none!important;direction:rtl!important;justify-content:flex-start!important}
.msm-date-day{flex:0 0 80px!important;width:80px!important;min-width:80px!important;max-width:80px!important;box-sizing:border-box!important}
.msm-date-arrow{width:36px!important;min-width:36px!important;max-width:36px!important;height:38px!important;box-sizing:border-box!important}
.msm-date-footer{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:10px!important;min-width:0!important;margin-top:10px!important;padding-top:9px!important;border-top:1px dashed rgba(255,255,255,.12)!important}
html[data-theme=light] .msm-date-footer{border-top-color:#e6eaf0!important}
.msm-date-readout{margin:0!important;padding:0!important;border:0!important;background:transparent!important;min-width:0!important;max-width:45%!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;text-align:right!important}
.msm-date-quick{margin:0!important;display:flex!important;flex-wrap:wrap!important;justify-content:flex-end!important;gap:6px!important;min-width:0!important;max-width:55%!important}
.msm-date-quick button{white-space:nowrap!important;flex:0 0 auto!important}
.admin-date-filter.compact .msm-date-card{padding:12px!important}.admin-date-filter.compact .msm-date-day{flex-basis:70px!important;width:70px!important;min-width:70px!important;max-width:70px!important;min-height:62px!important}

/* Rich secret status: billing key fallback is valid, not an error. */
.secret-row-rich>div{min-width:0;display:grid;gap:4px}.secret-row-rich small{display:block;color:var(--muted);font-size:12.5px;line-height:1.65;overflow-wrap:anywhere}.secret-row-rich>b{flex:0 0 auto}

/* Telegram channel card and test button */
.channel-card{min-width:0!important}.channel-card>.channel-copy{min-width:0!important;flex:1 1 auto}.channel-card>.row-actions{flex:0 0 auto}.mini-btn.is-working{opacity:.72;cursor:wait}

/* Universal mobile hardening — fixes huge toolbar fields and list overflow in both themes. */
@media (max-width:860px){
  html,body{width:100%;max-width:100%;overflow-x:hidden!important}
  body{font-size:13px}
  .app-shell,.main-column,.content{width:100%!important;max-width:100%!important;min-width:0!important}
  .content{padding:10px!important;overflow-x:hidden!important}
  .topbar{height:64px!important;padding:0 10px!important;gap:8px!important}.top-title{min-width:0!important}.top-title strong{font-size:14px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.top-actions{gap:6px!important}.admin-chip{padding:4px!important}.mini-avatar{width:32px;height:32px}.health-dot{display:none!important}
  .sidebar{width:min(86vw,320px)!important;max-width:320px!important;height:100dvh!important;overflow-y:auto!important;padding:14px 12px!important}.side-nav a{min-height:50px!important;margin-bottom:7px!important;font-size:13px!important}.side-footer{margin-top:14px!important}
  .hero,.hero.compact{min-height:0!important;padding:16px!important;border-radius:18px!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:12px!important}.hero h1{font-size:19px!important;margin:4px 0!important}.hero p{font-size:12.5px!important;line-height:1.8!important}.hero-actions{display:grid!important;grid-template-columns:1fr!important;gap:8px!important}.hero-actions>*{width:100%!important}
  .stat-grid,.stat-grid.small{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}.stat-card{min-width:0!important;min-height:98px!important;padding:12px!important;border-radius:16px!important}.stat-card strong{font-size:20px!important}.stat-card small{font-size:12.5px!important}
  .grid-2,.telegram-layout,.billing-grid,.health-grid.big{grid-template-columns:1fr!important;gap:10px!important}.panel{width:100%!important;max-width:100%!important;min-width:0!important;padding:12px!important;border-radius:17px!important;overflow:hidden!important}.panel-head{gap:8px!important;flex-wrap:wrap!important}.panel h2{font-size:15px!important}
  .toolbar{display:grid!important;grid-template-columns:1fr!important;gap:8px!important;align-items:stretch!important}.toolbar input,.toolbar select,.toolbar button{width:100%!important;max-width:100%!important;min-width:0!important;flex:0 0 auto!important;height:46px!important;min-height:46px!important;max-height:46px!important;margin:0!important;padding:0 12px!important}.toolbar input{line-height:46px!important}
  .publishing-filter-row{grid-template-columns:1fr!important}.pub-search-wrap,.pub-search-wrap input,.publishing-filter-row>select{width:100%!important;max-width:100%!important;min-width:0!important;height:46px!important}.publishing-quick-filters{display:grid!important;grid-template-columns:1fr 1fr!important;gap:7px!important}.pub-filter-chip{width:100%!important;min-width:0!important;white-space:normal!important;line-height:1.5!important}
  .admin-date-filter{margin:10px 0 12px!important}.msm-date-card{padding:10px!important;border-radius:16px!important}.msm-date-title b{font-size:12.5px!important}.msm-date-title small{font-size:12.5px!important}.msm-date-carousel{grid-template-columns:30px minmax(0,1fr) 30px!important;gap:5px!important}.msm-date-arrow{width:30px!important;min-width:30px!important;max-width:30px!important;height:34px!important}.msm-date-day,.admin-date-filter.compact .msm-date-day{flex-basis:72px!important;width:72px!important;min-width:72px!important;max-width:72px!important;min-height:62px!important}.msm-date-footer{align-items:stretch!important;flex-direction:column!important;gap:8px!important}.msm-date-readout,.msm-date-quick{width:100%!important;max-width:100%!important}.msm-date-readout{text-align:center!important;white-space:normal!important}.msm-date-quick{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}.msm-date-quick button{width:100%!important;min-width:0!important;padding:0 6px!important;font-size:12.5px!important}
  .table-wrap,.admin-list-wrap{width:100%!important;max-width:100%!important;min-width:0!important;overflow:visible!important;border:0!important;background:transparent!important;contain:none!important}.admin-list-table,.admin-list-table thead,.admin-list-table tbody,.admin-list-table tr,.admin-list-table th,.admin-list-table td{display:block!important;width:100%!important;max-width:100%!important;min-width:0!important}.admin-list-table thead{display:none!important}.admin-list-table tbody{display:grid!important;gap:10px!important}.admin-list-table tr{padding:12px!important;border:1px solid var(--line)!important;border-radius:16px!important;background:var(--surface)!important;box-shadow:0 8px 18px rgba(0,0,0,.055)!important;overflow:hidden!important}.admin-list-table td{display:grid!important;grid-template-columns:92px minmax(0,1fr)!important;gap:10px!important;align-items:start!important;padding:8px 0!important;border:0!important;border-bottom:1px dashed color-mix(in srgb,var(--line) 75%,transparent)!important;text-align:right!important;white-space:normal!important;overflow-wrap:anywhere!important}.admin-list-table td:last-child{border-bottom:0!important}.admin-list-table td::before{content:attr(data-label)!important;display:block!important;color:var(--muted)!important;font-size:12.5px!important;font-weight:800!important;text-align:right!important}.admin-list-table td>*{max-width:100%!important;min-width:0!important}.row-actions{display:flex!important;flex-wrap:wrap!important;gap:6px!important}.row-actions>*{flex:1 1 auto!important;min-width:74px!important;white-space:nowrap!important}.badge{white-space:nowrap!important}
  .channel-card{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;padding:13px!important;border-radius:16px!important}.channel-card>.row-actions{justify-content:stretch!important}.channel-card>.row-actions>*{flex:1 1 auto!important}
  .form-grid{grid-template-columns:1fr!important;gap:10px!important}.form-grid .full{grid-column:auto!important}.form-grid input,.form-grid select,.form-grid textarea{width:100%!important;max-width:100%!important;min-width:0!important;font-size:13px!important}.form-grid input,.form-grid select{height:46px!important;min-height:46px!important}.form-grid textarea{min-height:110px!important}
  .modal{padding:0!important;align-items:end!important}.modal-card{width:100%!important;max-width:100%!important;max-height:92dvh!important;border-radius:24px 24px 0 0!important;border-bottom:0!important}.modal-head{padding:14px 15px!important}.modal-head h3{font-size:15px!important}#modalBody{padding:14px!important}
  .log-view{min-height:54vh!important;max-height:70vh!important;font-size:12.5px!important}
  .secret-row,.metric-row{min-width:0!important;padding:11px!important}.secret-row span,.metric-row span{overflow-wrap:anywhere!important}
  .pager{gap:7px!important;flex-direction:column!important;align-items:stretch!important}.pager-buttons{display:flex!important;flex-wrap:wrap!important;justify-content:center!important}
}
@media (max-width:480px){
  .stat-grid,.stat-grid.small{grid-template-columns:1fr 1fr!important}.content{padding:8px!important}.panel{padding:10px!important}.admin-list-table td{grid-template-columns:78px minmax(0,1fr)!important;gap:8px!important}.toolbar input,.toolbar select,.toolbar button{height:44px!important;min-height:44px!important;max-height:44px!important}.msm-date-day,.admin-date-filter.compact .msm-date-day{flex-basis:68px!important;width:68px!important;min-width:68px!important;max-width:68px!important}.publishing-quick-filters{grid-template-columns:1fr!important}
}
/* light-theme mobile cards must stay light */
@media (max-width:860px){html[data-theme=light] .admin-list-table tr{background:#fff!important;box-shadow:0 8px 18px rgba(15,23,42,.045)!important}html[data-theme=light] .modal-card{background:#fff!important}html[data-theme=light] .toolbar input,html[data-theme=light] .toolbar select{background:#fff!important}}


/* ===== MCC v1.0.12 — exact Jalali ribbon + publishing containment FINAL ===== */
/* New component intentionally ignores all legacy msm-date-* rules. */
.admin-date-filter{display:block!important;width:100%!important;max-width:100%!important;min-width:0!important;margin:0 0 16px!important;overflow:hidden!important}
.mcc-jalali-card{position:relative;width:100%;max-width:100%;min-width:0;padding:13px;border:1px solid rgba(249,115,22,.24);border-radius:17px;background:linear-gradient(145deg,rgba(249,115,22,.07),rgba(255,255,255,.018));overflow:hidden}
.mcc-jalali-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}
.mcc-jalali-title{display:flex;align-items:center;gap:9px;min-width:0}.mcc-jalali-title>div{min-width:0}.mcc-jalali-title b,.mcc-jalali-title small{display:block}.mcc-jalali-title b{font-size:12.5px;color:var(--text)}.mcc-jalali-title small{margin-top:2px;font-size:12.5px;color:var(--muted)}
.mcc-jalali-icon{flex:none;width:32px;height:32px;display:grid;place-items:center;border-radius:10px;background:linear-gradient(135deg,#fb923c,#ea580c);box-shadow:0 6px 16px rgba(249,115,22,.22);font-size:14px}
.mcc-jalali-clear{flex:none;min-height:32px;padding:0 11px;border:1px solid var(--line);border-radius:10px;background:var(--surface2);color:var(--muted);font-size:12.5px;font-weight:700;cursor:pointer}.mcc-jalali-clear:hover,.mcc-jalali-clear.active{border-color:rgba(249,115,22,.45);color:#fb923c;background:rgba(249,115,22,.07)}
.mcc-jalali-picker{width:100%;min-width:0;padding:9px;border:1px solid rgba(255,255,255,.08);border-radius:13px;background:rgba(0,0,0,.18);overflow:hidden}
.mcc-jalali-nav{display:flex;align-items:center;gap:7px;direction:ltr;width:100%;min-width:0;overflow:hidden}
.mcc-jalali-arrow{flex:0 0 31px;width:31px;height:34px;padding:0;display:grid;place-items:center;border:1px solid var(--line);border-radius:9px;background:var(--surface2);color:var(--muted);font-size:18px;cursor:pointer}.mcc-jalali-arrow:hover{border-color:var(--accent);color:var(--accent2)}
.mcc-jalali-strip-wrap{flex:1 1 auto;min-width:0;max-width:100%;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;overscroll-behavior-inline:contain;direction:ltr}.mcc-jalali-strip-wrap::-webkit-scrollbar{display:none}
.mcc-jalali-strip{display:flex;width:max-content;min-width:100%;gap:7px;direction:rtl;justify-content:flex-start}
.mcc-jalali-day{flex:0 0 82px;width:82px;min-width:82px;min-height:66px;padding:8px 5px;border:1px solid var(--line);border-radius:11px;background:var(--surface2);color:var(--text);text-align:center;cursor:pointer;transition:.15s ease}.mcc-jalali-day span,.mcc-jalali-day strong,.mcc-jalali-day small{display:block;white-space:nowrap}.mcc-jalali-day span{font-size:12.5px;color:var(--muted);margin-bottom:4px}.mcc-jalali-day strong{font-size:12.5px;font-weight:800}.mcc-jalali-day small{margin-top:4px;font-size:12.5px;color:var(--muted)}.mcc-jalali-day:hover{border-color:rgba(249,115,22,.55)}.mcc-jalali-day.today{border-color:rgba(249,115,22,.65)}.mcc-jalali-day.today strong{color:#fb923c}.mcc-jalali-day.selected{background:linear-gradient(135deg,#fb923c,#ea580c);border-color:#f97316;box-shadow:0 6px 16px rgba(249,115,22,.25)}.mcc-jalali-day.selected span,.mcc-jalali-day.selected strong,.mcc-jalali-day.selected small{color:#fff}
.mcc-jalali-readout{margin-top:9px;padding-top:8px;border-top:1px dashed rgba(255,255,255,.10);text-align:center;font-size:12.5px;color:var(--muted);white-space:normal}.mcc-jalali-readout b{color:#fb923c;font-weight:800}
.mcc-jalali-loading{position:absolute;inset:0;display:none;place-items:center;background:rgba(9,12,17,.38);backdrop-filter:blur(2px);z-index:2}.admin-date-filter.is-loading .mcc-jalali-loading{display:grid}.mcc-jalali-loading i{width:24px;height:24px;border:3px solid rgba(255,255,255,.16);border-top-color:#fb923c;border-radius:50%;animation:mccSpin .7s linear infinite}
html[data-theme=light] .mcc-jalali-card{background:linear-gradient(145deg,#fffaf5,#fff);border-color:#f1c79f}html[data-theme=light] .mcc-jalali-picker{background:#f5f7fa;border-color:#dde4eb}html[data-theme=light] .mcc-jalali-day,html[data-theme=light] .mcc-jalali-arrow,html[data-theme=light] .mcc-jalali-clear{background:#fff;border-color:#dce3eb}html[data-theme=light] .mcc-jalali-readout{border-color:#dbe2ea}

/* Publishing row: fixed inside the parent in every desktop width. */
.publishing-panel,.publishing-list{width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important}
.pub-row{direction:rtl!important;display:grid!important;grid-template-columns:96px minmax(180px,1fr) 96px 102px 126px!important;gap:9px!important;align-items:center!important;width:100%!important;max-width:100%!important;min-width:0!important;margin:0!important;padding:13px!important;border-radius:20px!important;box-sizing:border-box!important;overflow:hidden!important;contain:layout paint!important}
.pub-row-media{grid-column:1!important;min-width:0!important;overflow:hidden!important}.pub-row-account{grid-column:2!important;min-width:0!important;overflow:hidden!important}.pub-row-time{grid-column:3!important;min-width:0!important;overflow:hidden!important}.pub-row-status{grid-column:4!important;min-width:0!important;overflow:hidden!important}.pub-row-actions{grid-column:5!important;min-width:0!important;max-width:126px!important;width:126px!important;display:grid!important;grid-template-columns:1fr!important;gap:6px!important;justify-self:end!important}
.pub-row-actions>*{width:100%!important;min-width:0!important;max-width:100%!important;height:auto!important;min-height:33px!important;padding:0 6px!important;margin:0!important;box-sizing:border-box!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;transform:none!important}.pub-row-actions .primary-btn{grid-column:auto!important;box-shadow:0 8px 18px rgba(249,115,22,.15)!important}
.pub-row-media .pub-media{width:86px!important;height:120px!important;max-width:86px!important}.pub-row-account>strong,.pub-row-account>small,.pub-row-account>p{display:block;max-width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important}.pub-row-account>strong,.pub-row-account>small{white-space:nowrap!important}.pub-row-account>p{white-space:normal!important;display:-webkit-box!important;-webkit-line-clamp:2;-webkit-box-orient:vertical}
@media(max-width:1280px){.pub-row{grid-template-columns:88px minmax(160px,1fr) 88px 92px 116px!important;gap:7px!important;padding:11px!important}.pub-row-actions{width:116px!important;max-width:116px!important}.pub-row-media .pub-media{width:78px!important;height:108px!important}}
@media(max-width:1120px){.pub-row{grid-template-columns:84px minmax(0,1fr)!important;grid-template-rows:auto auto auto!important;grid-template-areas:'media account' 'time status' 'actions actions'!important;gap:9px!important}.pub-row-media{grid-area:media!important;grid-column:auto!important}.pub-row-account{grid-area:account!important;grid-column:auto!important}.pub-row-time{grid-area:time!important;grid-column:auto!important;justify-items:start!important}.pub-row-status{grid-area:status!important;grid-column:auto!important;justify-items:start!important}.pub-row-actions{grid-area:actions!important;grid-column:auto!important;width:100%!important;max-width:100%!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}.pub-row-media .pub-media{width:78px!important;height:108px!important}}
@media(max-width:700px){.mcc-jalali-card{padding:10px}.mcc-jalali-head{align-items:flex-start}.mcc-jalali-title b{font-size:12.5px}.mcc-jalali-clear{font-size:12.5px;padding:0 8px}.mcc-jalali-picker{padding:7px}.mcc-jalali-day{flex-basis:74px;width:74px;min-width:74px;min-height:62px}.mcc-jalali-arrow{flex-basis:29px;width:29px;height:32px}.pub-row{grid-template-columns:76px minmax(0,1fr)!important;grid-template-areas:'media account' 'status status' 'time time' 'actions actions'!important;padding:10px!important}.pub-row-actions{grid-template-columns:1fr!important}.pub-row-media .pub-media{width:70px!important;height:98px!important}}


/* ===== MCC v1.0.13 — exact working MSM date/wheel components ===== */
.admin-date-filter{width:100%;min-width:0;max-width:100%;margin:14px 0;overflow:hidden}
.admin-date-filter .schedule-card{position:relative;width:100%;min-width:0;max-width:100%;padding:13px!important;background:linear-gradient(145deg,rgba(249,115,22,.10),rgba(255,255,255,.03));border:1px solid rgba(249,115,22,.28);border-radius:16px;overflow:hidden}
.admin-date-filter .schedule-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px!important;flex-wrap:wrap}
.admin-date-filter .schedule-title{display:flex;align-items:center;gap:9px;font-size:13.5px;font-weight:700}
.admin-date-filter .schedule-icon{display:grid;place-items:center;width:32px;height:32px;border-radius:10px;color:#fff;background:linear-gradient(135deg,#fb923c,#ea580c);box-shadow:0 6px 16px rgba(249,115,22,.3);font-size:14px}
.admin-date-filter .schedule-preview{color:#fdba74;font-size:12.5px;direction:rtl;font-weight:600}
.admin-date-filter .picker-box{min-width:0;border:1px solid rgba(255,255,255,.1);background:rgba(0,0,0,.28);border-radius:12px;padding:9px!important}
.admin-date-filter .picker-label{display:block;color:#a3a3a3;font-size:12.5px;margin-bottom:6px!important;font-weight:600}
.admin-date-filter .qp-nav-row{display:flex;align-items:center;gap:5px!important;direction:ltr;width:100%;min-width:0}
.admin-date-filter .qp-nav-row .qp-strip-wrap{flex:1 1 auto;min-width:0;max-width:100%}
.admin-date-filter .qp-nav-btn{flex:none;width:32px;height:34px;border-radius:10px;background:#12161b;border:1px solid #30353c;color:#b2b7be;display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0}
.admin-date-filter .qp-nav-btn:hover{border-color:#f97316;color:#ff9a4d;background:rgba(249,115,22,.10);box-shadow:0 0 0 3px rgba(249,115,22,.055),0 7px 18px rgba(249,115,22,.11)}
.admin-date-filter .qp-nav-btn svg{width:14px;height:14px;display:block}
.admin-date-filter .qp-strip-wrap{overflow-x:auto;overflow-y:hidden;padding:2px 0!important;direction:ltr;scrollbar-width:none;-ms-overflow-style:none;overscroll-behavior-inline:contain;scroll-behavior:smooth}
.admin-date-filter .qp-strip-wrap::-webkit-scrollbar{display:none;width:0;height:0}
.admin-date-filter .qp-strip{display:flex;gap:6px!important;width:max-content;align-items:stretch;direction:rtl}
.admin-date-filter .qp-day-card{flex:0 0 78px;width:78px!important;min-width:78px;min-height:67px;padding:8px 6px!important;display:flex;flex-direction:column;justify-content:center;border-radius:12px!important;background:#12161b!important;border:1px solid #2d333a!important;text-align:center;cursor:pointer;user-select:none;transition:transform .16s ease,border-color .16s ease,background .16s ease,box-shadow .16s ease!important;color:var(--text)}
.admin-date-filter .qp-day-card:hover{transform:translateY(-2px);border-color:#f97316!important;background:linear-gradient(145deg,rgba(249,115,22,.18),rgba(249,115,22,.045))!important;box-shadow:0 8px 20px rgba(249,115,22,.13)}
.admin-date-filter .qp-day-card .qp-wd{font-size:12.5px!important;margin:0 0 5px!important;color:#8f98a3!important;white-space:nowrap;font-weight:600}
.admin-date-filter .qp-day-card .qp-date-full{font-size:12.5px;font-weight:900;color:#eef0f2;white-space:nowrap;line-height:1.45}
.admin-date-filter .qp-day-card .qp-year{margin-top:3px;font-size:12.5px;color:#66707b;white-space:nowrap}
.admin-date-filter .qp-day-card.today{border-color:rgba(249,115,22,.62)!important;box-shadow:inset 0 0 0 1px rgba(249,115,22,.09)}
.admin-date-filter .qp-day-card.selected{transform:none!important;background:linear-gradient(135deg,#ff812b,#f2610b)!important;border-color:#ff8a38!important;box-shadow:0 7px 18px rgba(249,115,22,.28)!important}
.admin-date-filter .qp-day-card.selected .qp-wd,.admin-date-filter .qp-day-card.selected .qp-date-full,.admin-date-filter .qp-day-card.selected .qp-year{color:#fff!important}
.admin-date-filter .qp-readout{margin-top:7px!important;padding-top:7px!important;border-top:1px dashed rgba(255,255,255,.12);text-align:center;font-size:12.5px;color:var(--muted);line-height:1.7}
.admin-date-filter .qp-readout b{color:#fb923c;font-weight:800}
.admin-date-filter .quick-times{display:flex;gap:6px!important;flex-wrap:wrap;margin-top:8px!important}
.admin-date-filter .time-chip{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:38px;padding:9px 10px!important;border-radius:12px;background:#141414;color:var(--text);border:1px solid #2a2b30;font-size:12.5px;font-weight:700;cursor:pointer;transition:.15s ease;flex:1 1 0;white-space:nowrap}
.admin-date-filter .time-chip:hover{border-color:#f97316}.admin-date-filter .time-chip.active{background:linear-gradient(135deg,#fb923c,#ea580c);color:#fff;border-color:#f97316;box-shadow:0 6px 16px rgba(249,115,22,.25)}
.admin-date-filter .mcc-jalali-loading{position:absolute;inset:0;display:none;place-items:center;background:rgba(9,12,17,.34);backdrop-filter:blur(2px);z-index:5}.admin-date-filter.is-loading .mcc-jalali-loading{display:grid}.admin-date-filter .mcc-jalali-loading i{width:24px;height:24px;border:3px solid rgba(255,255,255,.16);border-top-color:#fb923c;border-radius:50%;animation:mccSpin .7s linear infinite}

/* Exact edit wheel from the working MSM edit form */
.exact-story-editor .exact-edit-schedule{background:linear-gradient(145deg,rgba(249,115,22,.10),rgba(255,255,255,.03));border:1px solid rgba(249,115,22,.28);border-radius:16px;padding:13px}
.exact-story-editor .schedule-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px;flex-wrap:wrap}.exact-story-editor .schedule-title{display:flex;align-items:center;gap:9px;font-size:13.5px;font-weight:700}.exact-story-editor .schedule-icon{display:grid;place-items:center;width:32px;height:32px;border-radius:10px;color:#fff;background:linear-gradient(135deg,#fb923c,#ea580c);box-shadow:0 6px 16px rgba(249,115,22,.3);font-size:14px}.exact-story-editor .schedule-preview{color:#fdba74;font-size:12.5px;font-weight:600}.exact-story-editor .picker-box{min-width:0;border:1px solid rgba(255,255,255,.1);background:rgba(0,0,0,.28);border-radius:13px;padding:12px}.exact-story-editor .picker-label{display:block;color:#a3a3a3;font-size:12.5px;margin-bottom:8px;font-weight:600}.exact-story-editor .wheel-picker{position:relative;direction:ltr}.exact-story-editor .wheel-grid{display:grid;grid-template-columns:1.1fr 1.6fr .8fr .8fr .8fr;gap:5px;direction:rtl}.exact-story-editor .wheel-col-wrap{min-width:0;text-align:center;position:relative}.exact-story-editor .wheel-col-title{display:block;color:var(--muted);font-size:12.5px;margin-bottom:6px}.exact-story-editor .wheel-col{position:relative;height:150px;overflow-y:auto;overscroll-behavior:contain;scroll-snap-type:y mandatory;scrollbar-width:none;-ms-overflow-style:none;border-radius:11px;background:rgba(0,0,0,.24);touch-action:pan-y}.exact-story-editor .wheel-col::-webkit-scrollbar{display:none;width:0;height:0}.exact-story-editor .wheel-col::before,.exact-story-editor .wheel-col::after{content:'';display:block;height:50px}.exact-story-editor .wheel-item{height:50px;display:flex;align-items:center;justify-content:center;scroll-snap-align:center;color:var(--muted);font-size:13px;font-weight:600;cursor:pointer;user-select:none;transition:color .15s,transform .15s}.exact-story-editor .wheel-item.selected{color:#fff;font-size:15px;font-weight:800;transform:scale(1.03);background:rgba(249,115,22,.12);border:1px solid rgba(249,115,22,.75);border-radius:9px;box-shadow:inset 0 0 0 1px rgba(249,115,22,.08)}.exact-story-editor .wheel-readout{margin-top:11px;text-align:center;color:#fdba74;font-size:12.5px;font-weight:700}.exact-story-editor .schedule-error{display:none;color:#fca5a5;font-size:12.5px;margin-top:9px}.exact-story-editor .exact-edit-schedule.is-disabled{opacity:.58}.exact-story-editor .exact-edit-schedule.is-disabled .wheel-grid{pointer-events:none}

/* Publishing action typography: never jump vertically */
.pub-row-actions .mini-btn,.pub-row-actions .primary-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;line-height:1.2!important;white-space:nowrap!important;padding-top:0!important;padding-bottom:0!important}.pub-row-actions .btn-icon,.pub-row-actions .btn-label{display:inline-flex;align-items:center;line-height:1!important}.pub-row-actions .btn-label{transform:none!important;position:static!important}

html[data-theme=light] .admin-date-filter .schedule-card{background:linear-gradient(145deg,#fff,#f7f8fa);border-color:#dfe3e8}.html[data-theme=light] .admin-date-filter .picker-box{background:#f7f9fb}
html[data-theme=light] .admin-date-filter .picker-box{background:#f7f9fb;border-color:#dfe3e8}html[data-theme=light] .admin-date-filter .qp-nav-btn,html[data-theme=light] .admin-date-filter .qp-day-card,html[data-theme=light] .admin-date-filter .time-chip{background:#fff!important;border-color:#d9e0e8!important}html[data-theme=light] .admin-date-filter .qp-day-card .qp-wd{color:#59636e!important}html[data-theme=light] .admin-date-filter .qp-day-card .qp-date-full{color:#2f3740!important}html[data-theme=light] .admin-date-filter .qp-day-card .qp-year{color:#6d7782!important}html[data-theme=light] .admin-date-filter .qp-day-card.selected .qp-wd,html[data-theme=light] .admin-date-filter .qp-day-card.selected .qp-date-full,html[data-theme=light] .admin-date-filter .qp-day-card.selected .qp-year{color:#fff!important}.exact-story-editor html[data-theme=light] .picker-box{background:#f7f9fb}
html[data-theme=light] .exact-story-editor .picker-box,html[data-theme=light] .exact-story-editor .wheel-col{background:#f7f9fb;border-color:#dfe3e8}html[data-theme=light] .exact-story-editor .wheel-item.selected{color:#c7510b;background:#fff1e6}
@media(max-width:700px){.admin-date-filter .schedule-card{padding:10px!important}.admin-date-filter .qp-day-card{width:72px!important;min-width:72px;min-height:63px}.admin-date-filter .quick-times{display:grid;grid-template-columns:1fr 1fr 1fr}.exact-story-editor .wheel-grid{gap:3px;grid-template-columns:1.05fr 1.45fr .75fr .75fr .75fr}.exact-story-editor .wheel-item{font-size:12.5px}.exact-story-editor .wheel-item.selected{font-size:13px}}
@media(max-width:480px){.admin-date-filter .schedule-head{align-items:flex-start;flex-direction:column}.admin-date-filter .schedule-preview{font-size:12.5px}.admin-date-filter .quick-times{grid-template-columns:1fr}.exact-story-editor .wheel-grid{grid-template-columns:1fr 1.35fr 1fr;gap:3px}.exact-story-editor .wheel-col-wrap:nth-child(4),.exact-story-editor .wheel-col-wrap:nth-child(5){grid-column:span 1}.exact-story-editor .wheel-col{height:132px}.exact-story-editor .wheel-col::before,.exact-story-editor .wheel-col::after{height:44px}.exact-story-editor .wheel-item{height:44px}}


/* ===== MCC v1.0.14 — Telegram layout structural fix ===== */
.telegram-overview-row{
  display:grid!important;
  grid-template-columns:minmax(300px,.36fr) minmax(0,.64fr)!important;
  gap:16px!important;
  align-items:start!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  margin-bottom:16px!important;
}
.telegram-overview-row>.panel{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  height:100%!important;
  margin:0!important;
  overflow:hidden!important;
}
.telegram-filter-panel .admin-date-filter{
  margin:0!important;
  width:100%!important;
  max-width:100%!important;
}
.telegram-history-panel{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  margin:0!important;
  overflow:hidden!important;
}
.telegram-history-head{margin-bottom:12px!important}
.telegram-history-note{color:var(--muted);font-size:12.5px;font-weight:700}
.telegram-history-panel .telegram-table-wrap{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
}
.telegram-history-panel .telegram-table-wrap table{
  width:100%!important;
  min-width:760px!important;
  max-width:none!important;
  margin:0!important;
}
/* neutralize older telegram-layout rules on this page */
.telegram-overview-row + .telegram-history-panel{clear:both}
@media(max-width:1180px){
  .telegram-overview-row{grid-template-columns:minmax(280px,.42fr) minmax(0,.58fr)!important;gap:12px!important}
}
@media(max-width:900px){
  .telegram-overview-row{grid-template-columns:1fr!important;gap:12px!important}
  .telegram-overview-row>.panel{height:auto!important}
  .telegram-history-panel{padding:12px!important}
}
@media(max-width:540px){
  .telegram-overview-row{gap:10px!important;margin-bottom:10px!important}
  .telegram-overview-row>.panel,.telegram-history-panel{border-radius:17px!important}
  .telegram-history-note{width:100%;font-size:12.5px}
}


/* ===== MCC v1.0.15 — local thumbnails + soft orange corner aura ===== */
:root{--mcc-aura-core:rgba(249,115,22,.16);--mcc-aura-mid:rgba(249,115,22,.065)}
html[data-theme=light]{--mcc-aura-core:rgba(249,115,22,.115);--mcc-aura-mid:rgba(249,115,22,.035)}
:is(.panel,.stat-card,.health-card,.channel-card,.pub-row,.schedule-card,.modal-card,.metric-row,.secret-row,.module-roadmap article,.story-status-card,.edit-modal-banner,.publishing-filter-shell){
  position:relative;isolation:isolate;overflow:hidden;
}
:is(.panel,.stat-card,.health-card,.channel-card,.pub-row,.schedule-card,.modal-card,.metric-row,.secret-row,.module-roadmap article,.story-status-card,.edit-modal-banner,.publishing-filter-shell)::before{
  content:"";position:absolute;z-index:0;pointer-events:none;right:-62px;top:-72px;width:210px;height:210px;border-radius:50%;
  background:radial-gradient(circle at 50% 50%,var(--mcc-aura-core) 0%,var(--mcc-aura-mid) 38%,transparent 71%);
  filter:blur(1px);
}
:is(.panel,.stat-card,.health-card,.channel-card,.pub-row,.schedule-card,.modal-card,.metric-row,.secret-row,.module-roadmap article,.story-status-card,.edit-modal-banner,.publishing-filter-shell)>*{position:relative;z-index:1}
/* Keep nested media/content fully clickable above the decorative aura. */
.pub-row .pub-progress{z-index:8}
html[data-theme=light] :is(.panel,.stat-card,.health-card,.channel-card,.pub-row,.schedule-card,.modal-card,.metric-row,.secret-row,.module-roadmap article,.story-status-card,.edit-modal-banner,.publishing-filter-shell)::before{filter:blur(2px)}
