/* app.css — tanima.mih.com.bd · Version v1.4 — 2026-11-07 17:00 (Asia/Dhaka)
   Changelog:
   v1.4 (2026-11-07 17:00): তারিখ বাছাইয়ের বার, চার্টের লেজেন্ড, ধরনের টেবিল, প্রিন্টের স্টাইল
   v1.3 (2026-11-07 16:45): ক্লিপ/আনকাট কার্ড চওড়া (১৬:৯) ছবিতে
   v1.2 (2026-11-07 17:10): লুকানো শর্টস তালিকা (hidden) দেখা যাচ্ছিল — ঠিক করা হলো
   v1.1 (2026-11-07 16:35): ড্যাশবোর্ডে Noto Serif Bengali; ব্লকগুলো বাবলি 3D; চার্টের নিচের ফাঁকা জায়গা বাদ; শর্টস তালিকা ও বাছাইয়ের স্টাইল
   v1.0 প্রথম ভার্সন */
:root{
  --bg:#eef3fb; --ink:#14213d; --muted:#6b7a99; --line:rgba(20,33,61,.08);
  --glass:rgba(255,255,255,.72); --glass2:rgba(255,255,255,.55);
  --acc:#2563eb; --acc2:#0ea5a4; --warm:#f59e0b; --good:#16a34a; --bad:#dc2626;
  --r:22px; --shadow:0 10px 30px rgba(30,60,120,.08);
}
html.dark{
  --bg:#0b1220; --ink:#e7edf8; --muted:#8fa0bf; --line:rgba(255,255,255,.08);
  --glass:rgba(22,32,52,.72); --glass2:rgba(22,32,52,.5); --shadow:0 10px 30px rgba(0,0,0,.35);
}
*{box-sizing:border-box}
body{margin:0;font-family:'Hind Siliguri',system-ui,sans-serif;background:var(--bg);color:var(--ink);font-size:15px;line-height:1.55;min-height:100vh;overflow-x:hidden}
a{color:inherit;text-decoration:none}
svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:none}
.blob{position:fixed;border-radius:50%;filter:blur(70px);z-index:0;pointer-events:none}
.b1{width:520px;height:520px;right:-140px;top:-160px;background:radial-gradient(circle,#fbbf24 0%,#f97316 60%,transparent 70%);opacity:.35}
.b2{width:560px;height:560px;left:20%;bottom:-260px;background:radial-gradient(circle,#38bdf8,#2563eb 60%,transparent 70%);opacity:.25}
html.dark .b1{opacity:.18} html.dark .b2{opacity:.2}
.shell{position:relative;z-index:1;display:grid;grid-template-columns:260px 1fr;gap:22px;padding:18px;max-width:1500px;margin:auto}
.glass{background:var(--glass);backdrop-filter:blur(18px);-webkit-backdrop-filter:blur(18px);border:1px solid rgba(255,255,255,.6);border-radius:var(--r);box-shadow:var(--shadow)}
html.dark .glass{border-color:rgba(255,255,255,.06)}
.side{position:sticky;top:18px;height:calc(100vh - 36px);padding:18px;display:flex;flex-direction:column;gap:6px}
.brand{display:flex;gap:10px;align-items:center;margin-bottom:10px}
.brand b{display:block;font-size:17px} .brand small{color:var(--muted);font-size:12px}
.logo{width:40px;height:40px;border-radius:12px;display:grid;place-items:center;color:#fff;font-weight:700;font-size:20px;background:linear-gradient(135deg,var(--acc),var(--acc2))}
.search{display:flex;align-items:center;gap:8px;background:var(--glass2);border:1px solid var(--line);border-radius:12px;padding:8px 10px;margin:4px 0 10px}
.search input{border:0;background:transparent;outline:0;color:var(--ink);font:inherit;width:100%}
.navlabel{font-size:11px;letter-spacing:.08em;color:var(--muted);margin:10px 6px 4px;text-transform:uppercase}
nav a{display:flex;gap:10px;align-items:center;padding:9px 12px;border-radius:12px;color:var(--muted);font-weight:500}
nav a:hover{background:var(--glass2);color:var(--ink)}
nav a.on{background:var(--acc);color:#fff;box-shadow:0 6px 16px rgba(37,99,235,.35)}
.side-foot{margin-top:auto;display:flex;flex-direction:column;gap:10px}
.theme{display:flex;align-items:center;gap:10px;border:0;background:transparent;color:var(--muted);font:inherit;cursor:pointer;padding:6px}
.sw{margin-left:auto;width:38px;height:22px;border-radius:20px;background:#cbd5e1;position:relative;transition:.2s}
.sw:after{content:'';position:absolute;top:3px;left:3px;width:16px;height:16px;border-radius:50%;background:#fff;transition:.2s}
html.dark .sw{background:var(--good)} html.dark .sw:after{left:19px}
.me{display:flex;gap:10px;align-items:center;padding:10px;border-radius:14px;background:var(--glass2);border:1px solid var(--line)}
.me b{display:block;font-size:14px} .me small{color:var(--muted)}
.av{width:34px;height:34px;border-radius:10px;background:#dbeafe;color:var(--acc);display:grid;place-items:center;font-weight:700}
main{min-width:0}
.top{display:flex;justify-content:space-between;align-items:flex-start;margin:6px 4px 18px}
.top h1{margin:0;font-size:26px}
.muted{color:var(--muted)}
.dot{display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--good);margin-right:6px}
.btn{display:inline-flex;align-items:center;gap:6px;background:var(--acc);color:#fff;padding:9px 16px;border-radius:999px;font-weight:600;border:0;cursor:pointer;font:inherit;font-weight:600}
.btn.ghost{background:var(--glass2);color:var(--ink);border:1px solid var(--line)}
.grid{display:grid;gap:18px}
.g-main{grid-template-columns:minmax(0,1fr) 340px}
.card{padding:20px}
.card h3{margin:0 0 4px;font-size:16px}
.kpis{display:grid;grid-template-columns:repeat(4,1fr);border-bottom:1px solid var(--line)}
.kpi{padding:18px 20px;border-right:1px solid var(--line)}
.kpi:last-child{border-right:0}
.kpi small{color:var(--muted)} .kpi .n{font-size:30px;font-weight:700;line-height:1.2;margin:4px 0}
.chip{display:inline-flex;align-items:center;gap:4px;font-size:12px;padding:2px 8px;border-radius:999px;background:#dcfce7;color:#166534;font-weight:600}
.chip.down{background:#fee2e2;color:#991b1b} .chip.info{background:#dbeafe;color:#1e40af}
html.dark .chip{background:rgba(22,163,74,.2);color:#86efac} html.dark .chip.down{background:rgba(220,38,38,.2);color:#fca5a5} html.dark .chip.info{background:rgba(37,99,235,.25);color:#93c5fd}
.seg{display:inline-flex;background:var(--glass2);border:1px solid var(--line);border-radius:999px;padding:3px}
.seg button{border:0;background:transparent;color:var(--muted);font:inherit;font-size:13px;padding:4px 12px;border-radius:999px;cursor:pointer}
.seg button.on{background:#fff;color:var(--ink);box-shadow:0 1px 4px rgba(0,0,0,.08)}
html.dark .seg button.on{background:#24324d}
.chartwrap{position:relative;height:300px;margin-top:10px}
.ring{position:relative;width:150px;height:150px;margin:8px auto}
.ring svg{width:150px;height:150px;transform:rotate(-90deg)}
.ring .c{position:absolute;inset:0;display:grid;place-items:center;text-align:center}
.ring .c b{font-size:28px;display:block;line-height:1}
.rows{display:flex;flex-direction:column;gap:2px;margin-top:8px}
.rows div{display:flex;justify-content:space-between;padding:6px 0;border-bottom:1px dashed var(--line);font-size:14px}
.rows div:last-child{border:0}
.ep{display:flex;gap:12px;align-items:center;padding:10px;border-radius:14px}
.ep:hover{background:var(--glass2)}
.ep img{width:120px;height:68px;object-fit:cover;border-radius:10px;flex:none;background:#cbd5e1}
.ep .t{font-weight:600;font-size:14px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.ep .m{font-size:12px;color:var(--muted)}
.ep .v{margin-left:auto;text-align:right;font-weight:700;white-space:nowrap}
table{width:100%;border-collapse:collapse;font-size:14px}
th{text-align:left;color:var(--muted);font-weight:500;font-size:12px;padding:8px;border-bottom:1px solid var(--line)}
td{padding:10px 8px;border-bottom:1px solid var(--line);vertical-align:top}
tr:hover td{background:var(--glass2)}
.badge{font-size:11px;padding:1px 7px;border-radius:6px;background:#e0e7ff;color:#3730a3;font-weight:600;white-space:nowrap}
html.dark .badge{background:#312e81;color:#c7d2fe}
.hero-ep img{width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:14px}
.bars{display:flex;align-items:flex-end;gap:3px;height:56px;margin:10px 0}
.bars i{flex:1;background:linear-gradient(var(--acc2),var(--acc));border-radius:3px 3px 0 0;opacity:.85}
.filters{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-bottom:14px}
.filters input,.filters select,.form input,.form select,.form textarea{background:var(--glass2);border:1px solid var(--line);border-radius:10px;padding:8px 12px;color:var(--ink);font:inherit}
.form{display:grid;gap:12px;max-width:520px} .form label{display:grid;gap:4px;font-size:14px;color:var(--muted)}
.shorts{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:14px}
.short{border-radius:16px;overflow:hidden}
.short img{width:100%;aspect-ratio:9/12;object-fit:cover;display:block;background:#cbd5e1}
.short .b{padding:10px} .short .b .t{font-size:13px;font-weight:600;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.video{aspect-ratio:16/9;width:100%;border:0;border-radius:16px}
.transcript{white-space:pre-wrap;max-height:520px;overflow:auto;font-size:15px;line-height:1.8;padding:14px;background:var(--glass2);border-radius:14px;border:1px solid var(--line)}
.pager{display:flex;gap:6px;justify-content:center;margin-top:14px}
.pager a{padding:6px 12px;border-radius:10px;background:var(--glass2);border:1px solid var(--line)}
.pager a.on{background:var(--acc);color:#fff}
.flash{padding:10px 14px;border-radius:12px;background:#dcfce7;color:#166534;margin-bottom:12px}
.flash.err{background:#fee2e2;color:#991b1b}
.foot{text-align:center;font-size:12px;margin:24px 0 6px}
@media (max-width:1100px){.g-main{grid-template-columns:1fr}.kpis{grid-template-columns:repeat(2,1fr)}.kpi:nth-child(2){border-right:0}}
@media (max-width:820px){.shell{grid-template-columns:1fr}.side{position:relative;height:auto;top:0}.side-foot{margin-top:10px}.ep img{width:96px;height:54px}}

/* ---------- v1.1 ---------- */
body.page-dash{font-family:'Noto Serif Bengali','Hind Siliguri',serif}
body.page-dash .kpi .n{letter-spacing:-.01em}

/* বাবলি 3D ব্লক */
.glass{border-radius:28px;
  background:linear-gradient(150deg,rgba(255,255,255,.95) 0%,rgba(255,255,255,.7) 55%,rgba(240,246,255,.65) 100%);
  box-shadow:inset 0 2px 0 rgba(255,255,255,.95),inset 0 -3px 8px rgba(37,99,235,.07),
    0 22px 44px -18px rgba(30,64,140,.35),0 6px 14px -4px rgba(30,64,140,.12);
  transition:transform .25s ease,box-shadow .25s ease}
section.glass:hover,.short.glass:hover{transform:translateY(-3px);
  box-shadow:inset 0 2px 0 rgba(255,255,255,.95),inset 0 -3px 8px rgba(37,99,235,.08),
    0 30px 54px -18px rgba(30,64,140,.42),0 8px 18px -4px rgba(30,64,140,.14)}
html.dark .glass{background:linear-gradient(150deg,rgba(36,50,78,.92),rgba(22,32,52,.78));
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08),inset 0 -3px 8px rgba(0,0,0,.25),0 22px 44px -18px rgba(0,0,0,.7),0 6px 14px -4px rgba(0,0,0,.4)}
.side.glass:hover{transform:none}
.kpis{gap:10px;padding:12px;border-bottom:0}
.kpi{border:0;border-radius:22px;background:linear-gradient(160deg,#fff,#f2f6ff);
  box-shadow:inset 0 2px 0 #fff,inset 0 -2px 6px rgba(37,99,235,.08),0 10px 20px -10px rgba(30,64,140,.35)}
html.dark .kpi{background:linear-gradient(160deg,#2a3a5c,#1c2840);box-shadow:inset 0 1px 0 rgba(255,255,255,.07),0 10px 20px -10px rgba(0,0,0,.6)}
.btn{background:linear-gradient(180deg,#3b82f6,#1d4ed8);box-shadow:inset 0 1px 0 rgba(255,255,255,.35),0 8px 16px -6px rgba(29,78,216,.6)}
.btn.ghost{background:linear-gradient(180deg,#fff,#eef3fb);box-shadow:inset 0 1px 0 #fff,0 4px 10px -4px rgba(30,64,140,.25)}
html.dark .btn.ghost{background:linear-gradient(180deg,#2a3a5c,#1c2840)}
nav a.on{background:linear-gradient(180deg,#3b82f6,#1d4ed8);box-shadow:inset 0 1px 0 rgba(255,255,255,.3),0 8px 16px -6px rgba(29,78,216,.55)}
.ep{border-radius:18px}
.ep img,.hero-ep img,.short img{box-shadow:0 8px 16px -8px rgba(0,0,0,.35)}
.chip,.badge{box-shadow:inset 0 1px 0 rgba(255,255,255,.6)}

/* চার্ট পুরো ব্লক জুড়ে */
.chartbox{display:flex;flex-direction:column}
.chartbox>.card{flex:1;display:flex;flex-direction:column}
.chartbox .chartwrap{flex:1;height:auto;min-height:300px}

/* শর্টস তালিকা (ড্যাশবোর্ড) */
.mini-shorts{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:12px;margin-top:12px}
.mini-shorts a{border-radius:18px;overflow:hidden;background:var(--glass2);box-shadow:0 10px 18px -10px rgba(30,64,140,.35);transition:transform .2s}
.mini-shorts a:hover{transform:translateY(-3px)}
.mini-shorts img{width:100%;aspect-ratio:9/12;object-fit:cover;display:block;background:#cbd5e1}
.mini-shorts .b{padding:8px 10px;font-size:12px}
.mini-shorts .t{font-weight:600;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.rankno{position:absolute;margin:8px;background:rgba(0,0,0,.6);color:#fff;border-radius:10px;padding:0 8px;font-weight:700}

/* শর্টস বাছাই (অ্যাডমিন) */
.pick{position:relative;cursor:pointer}
.pick input{position:absolute;top:10px;left:10px;width:22px;height:22px;accent-color:var(--acc);z-index:2}
.pick.sel{outline:3px solid var(--acc);outline-offset:-3px}
.stickybar{position:sticky;bottom:12px;display:flex;gap:10px;justify-content:space-between;align-items:center;margin-top:14px;padding:12px 16px}

.mini-shorts[hidden]{display:none}

.shorts.wide{grid-template-columns:repeat(auto-fill,minmax(240px,1fr))}
.shorts.wide img,.mini-shorts.wide img{aspect-ratio:16/9}
.mini-shorts.wide{grid-template-columns:repeat(auto-fill,minmax(200px,1fr))}

.rangebar{display:flex;justify-content:space-between;align-items:center;gap:14px;flex-wrap:wrap}
.rangectl{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.rangectl input[type=date]{padding:6px 10px}
.legend{display:flex;gap:12px;font-size:12px;color:var(--muted);flex-wrap:wrap}
.legend i{display:inline-block;width:10px;height:10px;border-radius:3px;margin-right:5px;vertical-align:middle}
table.mini td,table.mini th{padding:7px 6px}
@media print{
  .side,.noprint,.top .btn,.blob{display:none!important}
  .shell{grid-template-columns:1fr;padding:0}
  body{background:#fff}
  .glass{box-shadow:none!important;border:1px solid #ddd;background:#fff!important;break-inside:avoid}
  .mini-shorts[hidden]{display:none}
}
