:root {
  --bg: #0f172a;
  --bg-soft: #111827;
  --card: rgba(255, 255, 255, 0.92);
  --card-dark: rgba(17, 24, 39, 0.74);
  --text: #111827;
  --muted: #6b7280;
  --primary: #4f46e5;
  --primary-2: #7c3aed;
  --danger: #ef4444;
  --success: #10b981;
  --warning: #f59e0b;
  --line: rgba(148, 163, 184, 0.26);
  --shadow: 0 20px 50px rgba(2, 6, 23, 0.22);
  --radius: 26px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Noto Sans Thai', system-ui, sans-serif;
  color: var(--text);
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(99,102,241,0.35), transparent 34rem),
    radial-gradient(circle at bottom right, rgba(236,72,153,0.24), transparent 28rem),
    linear-gradient(145deg, #0f172a 0%, #111827 60%, #020617 100%);
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; border: 0; }
input, select, textarea {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255,255,255,0.92);
  border-radius: 16px;
  padding: 13px 14px;
  outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(79,70,229,0.12); }

.hidden { display: none !important; }
.app-shell { max-width: 520px; margin: 0 auto; min-height: 100vh; position: relative; }
.auth-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.glass-card, .panel-card, .hero-card, .stat-card, .item-card {
  background: var(--card);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255,255,255,0.42);
  box-shadow: var(--shadow);
}
.auth-card { width: 100%; border-radius: 34px; padding: 28px; }
.brand-mark {
  width: 58px; height: 58px; display: grid; place-items: center;
  border-radius: 20px; color: white; font-weight: 800; font-size: 28px;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
}
.eyebrow { margin: 0 0 4px; color: #6366f1; font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
h1, h2, h3, p { margin-top: 0; }
.auth-card h1 { margin: 8px 0 2px; font-size: 42px; line-height: 1; }
.muted { color: var(--muted); }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; background: #eef2ff; padding: 5px; border-radius: 18px; margin: 22px 0; }
.tab-btn { border-radius: 14px; padding: 11px 8px; background: transparent; color: #475569; font-weight: 800; }
.tab-btn.active { background: white; color: var(--primary); box-shadow: 0 8px 18px rgba(79,70,229,.12); }
.form-stack, .compact-form { display: grid; gap: 12px; }
.field label { display: block; margin-bottom: 6px; font-weight: 700; font-size: 13px; color: #475569; }
.primary-btn, .danger-btn {
  width: 100%; border-radius: 18px; padding: 14px 16px; color: white; font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 14px 28px rgba(79,70,229,.24);
}
.danger-btn { margin-top: 12px; background: linear-gradient(135deg, #ef4444, #f97316); }
.text-btn { background: transparent; color: var(--primary); font-weight: 700; padding: 10px; }

.main-app { min-height: 100vh; padding: 18px 16px 96px; }
.topbar { display: flex; align-items: center; justify-content: space-between; color: white; padding: 8px 2px 18px; }
.topbar h2 { margin: 0; font-size: 28px; }
.avatar-btn { width: 48px; height: 48px; border-radius: 18px; background: rgba(255,255,255,.16); color: white; font-weight: 800; overflow: hidden; }
.avatar-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.page { display: none; animation: rise .25s ease; }
.active-page { display: block; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.hero-card { border-radius: 32px; padding: 22px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.hero-card h1 { margin-bottom: 4px; font-size: 30px; }
.round-btn { width: 54px; height: 54px; border-radius: 20px; background: #111827; color: white; font-size: 28px; box-shadow: 0 14px 28px rgba(17,24,39,.22); }
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
.stat-card { border-radius: 24px; padding: 16px; min-height: 104px; }
.stat-card span { color: var(--muted); font-size: 13px; font-weight: 700; }
.stat-card strong { display: block; margin-top: 8px; font-size: 24px; }
.income strong { color: var(--success); } .expense strong { color: var(--danger); } .balance strong { color: var(--primary); } .tasks strong { color: var(--warning); }
.section-head { display: flex; align-items: center; justify-content: space-between; color: white; margin: 18px 2px 10px; }
.section-head h3 { margin: 0; }
.mini-btn { background: rgba(255,255,255,.16); color: white; padding: 8px 12px; border-radius: 999px; font-weight: 700; }
.panel-card { border-radius: 28px; padding: 18px; margin-bottom: 16px; }
.panel-card h3 { margin-bottom: 12px; }
.list-stack { display: grid; gap: 10px; }
.empty-box { color: rgba(255,255,255,.72); border: 1px dashed rgba(255,255,255,.24); border-radius: 22px; padding: 18px; text-align: center; }
.item-card { border-radius: 22px; padding: 14px; display: grid; gap: 6px; text-align: left; }
.item-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.item-title { font-weight: 800; }
.item-meta { color: var(--muted); font-size: 13px; }
.item-actions { display: flex; gap: 8px; }
.icon-btn { width: 36px; height: 36px; border-radius: 13px; background: #eef2ff; color: var(--primary); font-weight: 800; }
.icon-btn.delete { background: #fee2e2; color: var(--danger); }
.done .item-title { text-decoration: line-through; color: var(--muted); }
.profile-card { border-radius: 30px; padding: 24px; margin-bottom: 16px; text-align: center; }
.profile-avatar-wrap { width: 98px; height: 98px; margin: 0 auto 12px; border-radius: 32px; display: grid; place-items: center; overflow: hidden; background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: white; font-size: 42px; font-weight: 800; }
.profile-avatar { width: 100%; height: 100%; object-fit: cover; }
.bottom-nav {
  position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%);
  width: min(492px, calc(100% - 24px));
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px;
  background: rgba(255,255,255,.92); backdrop-filter: blur(18px);
  padding: 8px; border-radius: 26px; box-shadow: 0 18px 48px rgba(2,6,23,.28); z-index: 20;
}
.nav-btn { background: transparent; color: #64748b; border-radius: 18px; padding: 8px 4px; font-size: 11px; font-weight: 800; }
.nav-btn span { display: block; font-size: 18px; line-height: 1.1; }
.nav-btn.active { background: #111827; color: white; }
.toast { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); background: #111827; color: white; padding: 12px 16px; border-radius: 999px; box-shadow: var(--shadow); z-index: 30; font-weight: 700; }
@media (min-width: 720px) { .app-shell { max-width: 560px; } }

/* MyHub v2 */
.pill-select { width: auto; min-width: 118px; border-radius: 999px; padding: 8px 12px; font-size: 13px; font-weight: 800; }
.filter-row { display: flex; gap: 8px; margin: -2px 0 14px; overflow-x: auto; }
.filter-chip { flex: 0 0 auto; padding: 9px 13px; border-radius: 999px; background: rgba(255,255,255,.16); color: white; font-weight: 800; }
.filter-chip.active { background: white; color: var(--primary); }
.search-field { margin-bottom: 14px; }
.sheet-backdrop { position: fixed; inset: 0; background: rgba(2,6,23,.55); z-index: 50; display: flex; align-items: flex-end; justify-content: center; padding: 14px; }
.bottom-sheet { width: min(520px, 100%); background: rgba(255,255,255,.96); border-radius: 30px 30px 24px 24px; padding: 12px 16px 18px; box-shadow: 0 -24px 60px rgba(2,6,23,.32); animation: sheetUp .22s ease; max-height: 88vh; overflow-y: auto; }
@keyframes sheetUp { from { transform: translateY(24px); opacity: .6; } to { transform: none; opacity: 1; } }
.sheet-handle { width: 48px; height: 5px; border-radius: 99px; background: #cbd5e1; margin: 0 auto 10px; }
.sheet-title { color: var(--text); margin: 4px 0 14px; }
.mini-btn.dark { color: white; background: #111827; }
.quick-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.quick-card { text-align: left; border-radius: 22px; padding: 16px; background: #f8fafc; border: 1px solid #e2e8f0; display: grid; gap: 4px; }
.quick-card span { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 16px; background: #111827; color: white; font-size: 22px; margin-bottom: 6px; }
.quick-card strong { font-size: 15px; }
.quick-card small { color: var(--muted); }
.edit-btn { background: #e0f2fe; color: #0369a1; }
.item-row strong.money-income { color: var(--success); }
.item-row strong.money-expense { color: var(--danger); }
.inline-date { color: #94a3b8; font-size: 12px; margin-top: 4px; }
@media (max-width: 390px) { .quick-grid { grid-template-columns: 1fr; } .stat-card strong { font-size: 20px; } }


/* ===== MyHub v3 ===== */
body.light-mode{color:#111827;background:linear-gradient(145deg,#eef2ff 0%,#f8fafc 70%,#fff 100%)}.dashboard-actions{display:flex;gap:10px;justify-content:flex-end;margin:10px 0 14px}.mini-btn.install{background:linear-gradient(135deg,var(--primary),var(--primary-2));color:#fff}.dashboard-chart-card{margin-top:14px;overflow:hidden}#expenseChart{width:100%;display:block;margin-top:8px}.mini-badge{font-size:12px;padding:7px 10px;border-radius:999px;background:rgba(79,70,229,.10);color:#4f46e5;font-weight:800}.insight-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:14px 0}.mini-stat{background:rgba(255,255,255,.88);border:1px solid rgba(148,163,184,.22);border-radius:20px;padding:14px 12px;box-shadow:0 12px 26px rgba(2,6,23,.10)}.mini-stat span{display:block;color:var(--muted);font-size:12px;margin-bottom:6px}.mini-stat strong{font-size:24px}.profile-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.profile-stats div{padding:14px;border-radius:18px;background:rgba(15,23,42,.05)}.profile-stats span{display:block;color:var(--muted);font-size:12px}.profile-stats strong{font-size:24px}@media(display-mode:standalone){.install{display:none!important}.topbar{padding-top:max(18px,env(safe-area-inset-top))}}@media(max-width:390px){.insight-grid{grid-template-columns:1fr}}


/* v4 Watchlist Movie Library */
.form-grid-2{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.movie-grid{display:grid;gap:14px}
.movie-card{display:grid;grid-template-columns:96px 1fr;gap:14px;background:rgba(255,255,255,.92);border:1px solid rgba(255,255,255,.55);border-radius:24px;padding:12px;box-shadow:0 18px 40px rgba(3,7,18,.18);overflow:hidden}
.movie-poster{width:96px;aspect-ratio:2/3;border-radius:18px;overflow:hidden;background:linear-gradient(135deg,#4f46e5,#7c3aed);display:grid;place-items:center;color:#fff;font-size:28px;font-weight:900;box-shadow:inset 0 0 0 1px rgba(255,255,255,.2)}
.movie-poster img{width:100%;height:100%;object-fit:cover;display:block}
.poster-fallback{width:100%;height:100%;display:grid;place-items:center;background:linear-gradient(135deg,#111827,#4f46e5)}
.movie-info{min-width:0;display:flex;flex-direction:column;gap:7px}
.movie-info h3{font-size:18px;line-height:1.15;margin:0;color:#0f172a;word-break:break-word}
.movie-topline{display:flex;justify-content:space-between;gap:8px;align-items:center;font-size:12px;color:#64748b;font-weight:800}
.movie-rating{color:#7c3aed;white-space:nowrap}
.movie-badges{display:flex;flex-wrap:wrap;gap:6px}
.movie-badges span{font-size:11px;font-weight:800;color:#475569;background:#eef2ff;border-radius:999px;padding:5px 8px}
.movie-badges .status-badge{color:#fff;background:linear-gradient(135deg,#4f46e5,#7c3aed)}
.movie-note{margin:0;color:#64748b;font-size:13px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.movie-actions{margin-top:auto;justify-content:flex-start}
@media (max-width:420px){.form-grid-2{grid-template-columns:1fr}.movie-card{grid-template-columns:82px 1fr;border-radius:22px}.movie-poster{width:82px}.movie-info h3{font-size:16px}.movie-topline{flex-direction:column;align-items:flex-start;gap:2px}}

.status-tabs,.watch-status-filter{display:flex;gap:8px;flex-wrap:wrap}
.status-tab,.platform-chip{border:0;border-radius:999px;background:rgba(15,23,42,.08);color:#0f172a;font-weight:900;padding:10px 13px;cursor:pointer}
.status-tab.active{background:linear-gradient(135deg,#4f46e5,#7c3aed);color:#fff;box-shadow:0 10px 24px rgba(79,70,229,.25)}
.platform-picker{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:2px 0 4px}
.platform-chip{display:flex;align-items:center;gap:8px;justify-content:flex-start;background:#fff;border:1px solid rgba(148,163,184,.35);box-shadow:0 6px 16px rgba(15,23,42,.06)}
.platform-chip span{width:28px;height:28px;border-radius:10px;background:#0f172a;color:#fff;display:grid;place-items:center;font-size:12px;font-weight:1000}
.platform-chip.active{border-color:#7c3aed;box-shadow:0 0 0 3px rgba(124,58,237,.14);background:#f5f3ff;color:#4c1d95}
.tiny-hint{font-size:11px;color:#64748b;margin:-2px 2px 0}
.movie-head-row{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.platform-line{display:flex;align-items:center;gap:7px;color:#475569;font-size:12px;font-weight:900}
.platform-mini-icon{width:26px;height:26px;border-radius:9px;background:#0f172a;color:#fff;display:grid;place-items:center;font-size:11px;font-weight:1000}
.status-badge.status-watching{background:linear-gradient(135deg,#0ea5e9,#2563eb)}
.status-badge.status-done{background:linear-gradient(135deg,#10b981,#059669)}
.status-badge.status-queued{background:linear-gradient(135deg,#4f46e5,#7c3aed)}
.upgraded-movie-card{grid-template-columns:104px 1fr}
@media (max-width:420px){.platform-picker{grid-template-columns:1fr 1fr}.platform-chip{font-size:12px;padding:9px 10px}.upgraded-movie-card{grid-template-columns:88px 1fr}}

/* Watchlist v4.2 cleanup */
.movie-form-simple{gap:12px}
.watch-simple-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.platform-select{font-weight:900}
.type-badge{background:#e0f2fe!important;color:#075985!important}
@media (max-width:420px){.watch-simple-grid{grid-template-columns:1fr}.status-tabs .status-tab{flex:1;min-width:0;padding-inline:8px}}

/* v4.3 Premium custom dropdowns */
.app-dropdown{position:relative;width:100%;z-index:3}
.app-dropdown.open{z-index:60}
.dropdown-trigger{width:100%;min-height:54px;border:1px solid rgba(148,163,184,.32);border-radius:20px;background:linear-gradient(180deg,#fff,#f8fafc);box-shadow:0 10px 24px rgba(15,23,42,.08);display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 14px;color:#0f172a;font-weight:900;cursor:pointer;transition:.18s ease}
.dropdown-trigger:hover{transform:translateY(-1px);box-shadow:0 16px 30px rgba(15,23,42,.12)}
.app-dropdown.open .dropdown-trigger{border-color:#7c3aed;box-shadow:0 0 0 4px rgba(124,58,237,.14),0 18px 36px rgba(15,23,42,.14)}
.dropdown-current{display:flex;align-items:center;gap:10px;min-width:0}
.dropdown-current span:last-child{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.dropdown-chevron{width:30px;height:30px;border-radius:999px;background:#eef2ff;color:#4f46e5;display:grid;place-items:center;font-size:18px;line-height:1;transition:.18s ease;flex:0 0 auto}
.app-dropdown.open .dropdown-chevron{transform:rotate(180deg);background:#7c3aed;color:#fff}
.dropdown-menu{position:absolute;top:calc(100% + 8px);left:0;right:0;max-height:310px;overflow:auto;border:1px solid rgba(148,163,184,.32);border-radius:22px;background:rgba(255,255,255,.96);backdrop-filter:blur(14px);box-shadow:0 24px 56px rgba(15,23,42,.25);padding:8px;display:none}
.app-dropdown.open .dropdown-menu{display:block;animation:dropdownPop .16s ease-out}
@keyframes dropdownPop{from{opacity:0;transform:translateY(-6px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}
.dropdown-option{width:100%;border:0;background:transparent;border-radius:16px;display:flex;align-items:center;gap:10px;padding:11px 10px;color:#0f172a;font-weight:900;text-align:left;cursor:pointer}
.dropdown-option:hover{background:#f1f5f9}
.dropdown-option.selected{background:linear-gradient(135deg,rgba(99,102,241,.12),rgba(124,58,237,.14));color:#5b21b6}
.dropdown-option b{margin-left:auto;display:none;color:#7c3aed}
.dropdown-option.selected b{display:block}
.brand-icon{width:30px;height:30px;border-radius:11px;background:#0f172a;display:grid;place-items:center;overflow:hidden;flex:0 0 auto;box-shadow:0 7px 14px rgba(15,23,42,.18)}
.brand-icon img{width:19px;height:19px;filter:brightness(0) invert(1);display:block}
.text-icon,.type-icon{color:#fff;font-size:13px;font-weight:1000}
.type-icon{background:linear-gradient(135deg,#4f46e5,#7c3aed)}
.platform-line .brand-icon{width:25px;height:25px;border-radius:9px;box-shadow:none}
.platform-line .brand-icon img{width:15px;height:15px}
.platform-line{margin-top:8px}
@media(max-width:420px){.dropdown-trigger{min-height:52px;border-radius:18px;padding:10px 12px}.dropdown-menu{max-height:270px}.brand-icon{width:28px;height:28px}.dropdown-option{padding:10px 9px}}

/* v4.4 Watchlist polish */
.watch-status-filter{margin-bottom:10px}
#watchSearch{margin-top:8px}
#watchList{margin-top:14px}
.search-field{margin-bottom:18px}
.movie-actions{display:flex;flex-wrap:wrap;gap:7px;margin-top:10px}
.status-action{background:#eef2ff;color:#4338ca;font-weight:900}
.done-action{background:#dcfce7;color:#047857}
.movie-poster img{background:#1e1b4b}
.poster-fallback{font-size:30px}
@media(max-width:420px){.movie-actions .icon-btn{padding:8px 10px;font-size:12px}.watch-status-filter{gap:7px}}

/* v45 Watchlist polish */
.movie-status-actions{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0 2px}
.pill-status-btn{border:0;border-radius:999px;padding:8px 12px;font-size:12px;font-weight:900;color:#334155;background:rgba(226,232,240,.9);box-shadow:inset 0 0 0 1px rgba(148,163,184,.18);cursor:pointer;transition:transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease}
.pill-status-btn:active{transform:scale(.96)}
.pill-status-btn.active{color:white;background:linear-gradient(135deg,#4f46e5,#7c3aed);box-shadow:0 10px 22px rgba(79,70,229,.28)}
.pill-status-btn.done.active{background:linear-gradient(135deg,#10b981,#22c55e);box-shadow:0 10px 22px rgba(16,185,129,.24)}
.movie-actions{gap:8px;margin-top:8px}
.movie-actions .icon-btn{border:0;border-radius:999px;padding:9px 14px;font-size:13px;font-weight:900;box-shadow:0 8px 18px rgba(15,23,42,.08)}
.movie-actions .edit-btn{background:#e0f2fe;color:#0369a1}
.movie-actions .delete{background:#ffe4e6;color:#e11d48}
.poster-fallback{height:100%;width:100%;display:flex;flex-direction:column;gap:7px;align-items:center;justify-content:center;text-align:center;background:linear-gradient(135deg,#312e81,#6d28d9);color:#fff}
.poster-fallback span{font-size:30px;line-height:1}
.poster-fallback small{font-size:9px;line-height:1.15;opacity:.85;padding:0 8px}
.movie-poster.poster-error::after{content:'ไม่พบโปสเตอร์';font-size:10px;text-align:center;padding:0 8px;opacity:.85}
@media(max-width:420px){.movie-status-actions{gap:6px}.pill-status-btn{padding:7px 10px;font-size:11px}.movie-actions .icon-btn{padding:8px 12px;font-size:12px}}

/* v4.6 Watchlist polish */
.two-status-actions{display:flex;gap:10px;margin-top:14px;align-items:center;flex-wrap:wrap}
.two-status-actions .pill-status-btn{min-width:112px;padding:10px 14px;border-radius:999px;background:#f1f5f9;border:1px solid rgba(148,163,184,.28);color:#243041;box-shadow:0 8px 18px rgba(15,23,42,.06);font-weight:900;letter-spacing:-.01em}
.two-status-actions .pill-status-btn.active{background:linear-gradient(135deg,#4f46e5,#7c3aed);color:#fff;border-color:transparent;box-shadow:0 14px 28px rgba(99,102,241,.26)}
.two-status-actions .pill-status-btn.done.active{background:linear-gradient(135deg,#10b981,#22c55e);box-shadow:0 14px 28px rgba(16,185,129,.22)}
.pretty-actions{display:flex;gap:12px!important;margin-top:16px!important;align-items:center;flex-wrap:wrap}
.pretty-actions .icon-btn{height:38px;min-width:82px;border-radius:999px!important;display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 15px!important;border:1px solid transparent!important;font-size:13px!important;font-weight:950!important;box-shadow:0 12px 22px rgba(15,23,42,.08)!important}
.pretty-actions .edit-btn{background:linear-gradient(135deg,#e0f7ff,#dff6ff)!important;color:#0369a1!important;border-color:rgba(14,165,233,.16)!important}
.pretty-actions .delete{background:linear-gradient(135deg,#ffe4e6,#ffecef)!important;color:#e11d48!important;border-color:rgba(244,63,94,.14)!important}
.movie-card.upgraded-movie-card{gap:18px}
@media(max-width:420px){.two-status-actions{gap:8px}.two-status-actions .pill-status-btn{min-width:auto;padding:9px 11px;font-size:12px}.pretty-actions{gap:10px!important}.pretty-actions .icon-btn{height:36px;min-width:74px;padding:0 12px!important}}


/* v4.7 Premium compact status controls */
.two-status-actions{
  display:inline-flex!important;
  width:auto!important;
  max-width:max-content!important;
  gap:4px!important;
  padding:4px;
  margin-top:14px!important;
  align-items:center;
  flex-wrap:nowrap!important;
  border-radius:999px;
  background:rgba(226,232,240,.72);
  border:1px solid rgba(148,163,184,.26);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.7),0 12px 28px rgba(15,23,42,.07);
}
.two-status-actions .pill-status-btn{
  min-width:0!important;
  width:auto!important;
  flex:0 0 auto!important;
  border:0!important;
  border-radius:999px!important;
  padding:9px 13px!important;
  font-size:12px!important;
  line-height:1!important;
  color:#334155!important;
  background:transparent!important;
  box-shadow:none!important;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:5px;
  white-space:nowrap;
}
.two-status-actions .pill-status-btn.active{
  color:#fff!important;
  background:linear-gradient(135deg,#4f46e5,#7c3aed)!important;
  box-shadow:0 10px 22px rgba(99,102,241,.28)!important;
}
.two-status-actions .pill-status-btn.done.active{
  background:linear-gradient(135deg,#10b981,#22c55e)!important;
  box-shadow:0 10px 22px rgba(16,185,129,.22)!important;
}
.two-status-actions .pill-status-btn:active{transform:scale(.96)}
.pretty-actions{
  gap:8px!important;
  margin-top:12px!important;
}
.pretty-actions .icon-btn{
  min-width:0!important;
  height:36px!important;
  padding:0 13px!important;
}
@media(max-width:420px){
  .two-status-actions{gap:3px!important;padding:3px;margin-top:12px!important;}
  .two-status-actions .pill-status-btn{padding:8px 11px!important;font-size:11.5px!important;}
  .pretty-actions{gap:8px!important;}
}


/* v4.8 Watchlist top action menu */
.movie-card-menu-card{
  position:relative;
  padding-right:58px!important;
}
.movie-more-menu{
  position:absolute;
  top:14px;
  right:14px;
  z-index:8;
}
.movie-more-menu summary{
  width:38px;
  height:38px;
  border-radius:999px;
  display:grid;
  place-items:center;
  list-style:none;
  cursor:pointer;
  font-size:22px;
  font-weight:950;
  line-height:1;
  color:#0f172a;
  background:rgba(255,255,255,.72);
  border:1px solid rgba(148,163,184,.22);
  box-shadow:0 12px 28px rgba(15,23,42,.08), inset 0 1px 0 rgba(255,255,255,.9);
  backdrop-filter:blur(10px);
  transition:transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.movie-more-menu summary::-webkit-details-marker{display:none}
.movie-more-menu summary:active{transform:scale(.94)}
.movie-more-menu[open] summary{
  background:#111827;
  color:#fff;
  box-shadow:0 14px 30px rgba(15,23,42,.20);
}
.movie-more-panel{
  position:absolute;
  top:46px;
  right:0;
  min-width:142px;
  padding:8px;
  border-radius:20px;
  background:rgba(255,255,255,.94);
  border:1px solid rgba(148,163,184,.22);
  box-shadow:0 20px 45px rgba(15,23,42,.18);
  backdrop-filter:blur(14px);
  display:grid;
  gap:6px;
}
.more-action{
  width:100%;
  border:0;
  border-radius:14px;
  padding:11px 12px;
  display:flex;
  align-items:center;
  gap:8px;
  font-size:13px;
  font-weight:950;
  color:#0f172a;
  background:transparent;
  cursor:pointer;
  text-align:left;
}
.more-action:hover{background:#eef6ff}
.more-action.danger{color:#e11d48}
.more-action.danger:hover{background:#fff1f2}
@media(max-width:420px){
  .movie-card-menu-card{padding-right:50px!important;}
  .movie-more-menu{top:12px;right:12px;}
  .movie-more-menu summary{width:34px;height:34px;font-size:20px;}
  .movie-more-panel{top:42px;min-width:132px;}
}

/* ===== MyHub v5: Premium Tasks ===== */
.tasks-premium-page{padding-bottom:112px}
.task-hero-card{border-radius:30px;padding:20px;display:flex;align-items:center;justify-content:space-between;gap:14px;background:linear-gradient(135deg,rgba(99,102,241,.98),rgba(124,58,237,.96));color:#fff;box-shadow:0 24px 56px rgba(79,70,229,.28);margin-bottom:14px;overflow:hidden;position:relative}
.task-hero-card:before{content:"";position:absolute;inset:auto -40px -60px auto;width:170px;height:170px;border-radius:50%;background:rgba(255,255,255,.16)}
.task-hero-card h3{font-size:26px;margin:2px 0 4px;letter-spacing:-.04em}.task-hero-card .muted{color:rgba(255,255,255,.78);max-width:280px}.task-hero-card .eyebrow{color:rgba(255,255,255,.82)}
.task-hero-ring{width:82px;height:82px;border-radius:26px;background:rgba(255,255,255,.16);backdrop-filter:blur(12px);display:grid;place-items:center;align-content:center;box-shadow:inset 0 0 0 1px rgba(255,255,255,.18);position:relative;z-index:1;flex:0 0 auto}.task-hero-ring span{font-size:22px;font-weight:900}.task-hero-ring small{font-size:11px;font-weight:800;color:rgba(255,255,255,.78)}
.task-stat-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin-bottom:14px}.task-stat-grid article{background:rgba(255,255,255,.92);border-radius:22px;padding:12px 10px;box-shadow:0 14px 34px rgba(15,23,42,.10);text-align:center}.task-stat-grid span{font-size:11px;font-weight:800;color:#64748b}.task-stat-grid strong{display:block;font-size:22px;line-height:1;color:#111827;margin-top:5px}
.task-add-card{border-radius:28px!important}.task-premium-form{display:grid;gap:11px}.task-title-input,.task-search-input{height:54px;border-radius:20px!important;font-weight:800}.task-form-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}.task-priority-select,#taskDue{height:52px;border-radius:18px!important;font-weight:800}.task-toolbar{display:grid;gap:10px;margin:14px 0}.task-view-tabs{display:flex;gap:8px;overflow-x:auto;padding-bottom:2px}.task-search-input{width:100%;background:rgba(255,255,255,.95)!important}
.task-list-premium{display:grid;gap:12px}.task-card-premium{position:relative;border-radius:28px;background:rgba(255,255,255,.94);box-shadow:0 18px 42px rgba(15,23,42,.12);padding:16px;overflow:hidden;border:1px solid rgba(255,255,255,.72)}.task-card-premium.done{opacity:.72}.task-card-premium.done .task-card-title{text-decoration:line-through;color:#64748b}.task-card-premium:before{content:"";position:absolute;left:0;top:18px;bottom:18px;width:5px;border-radius:999px;background:linear-gradient(180deg,#94a3b8,#cbd5e1)}.task-card-premium.priority-important:before{background:linear-gradient(180deg,#f97316,#ef4444)}.task-card-premium.overdue:before{background:linear-gradient(180deg,#ef4444,#be123c)}.task-card-main{display:grid;grid-template-columns:auto 1fr auto;gap:12px;align-items:start}.task-check-btn{width:44px;height:44px;border:0;border-radius:16px;background:#eef2ff;color:#4f46e5;font-weight:900;font-size:18px;box-shadow:inset 0 0 0 1px rgba(79,70,229,.12);cursor:pointer}.task-check-btn.done{background:linear-gradient(135deg,#10b981,#22c55e);color:white;box-shadow:0 12px 24px rgba(16,185,129,.22)}.task-card-title{font-size:18px;font-weight:900;color:#0f172a;letter-spacing:-.03em;margin-bottom:8px}.task-meta-row{display:flex;gap:7px;flex-wrap:wrap}.task-chip{display:inline-flex;align-items:center;gap:4px;border-radius:999px;padding:6px 9px;font-size:11px;font-weight:900;background:#e0f2fe;color:#0369a1}.task-chip.priority{background:#fff7ed;color:#ea580c}.task-chip.normal{background:#f1f5f9;color:#475569}.task-chip.overdue{background:#ffe4e6;color:#e11d48}.task-chip.done{background:#dcfce7;color:#059669}.task-menu{position:relative}.task-menu summary{list-style:none;width:38px;height:38px;border-radius:16px;display:grid;place-items:center;background:#f8fafc;color:#0f172a;font-size:20px;font-weight:900;cursor:pointer;box-shadow:inset 0 0 0 1px rgba(148,163,184,.22)}.task-menu summary::-webkit-details-marker{display:none}.task-menu-panel{position:absolute;right:0;top:46px;background:white;border-radius:22px;box-shadow:0 20px 46px rgba(15,23,42,.20);padding:8px;z-index:8;min-width:132px;display:grid;gap:4px}.task-menu-panel button{border:0;background:transparent;text-align:left;padding:10px 12px;border-radius:14px;font-weight:900;color:#0f172a}.task-menu-panel button.delete{color:#f43f5e}.task-empty-hint{border-radius:28px;padding:24px;text-align:center;background:rgba(255,255,255,.9);font-weight:900;color:#64748b}.light-mode .task-card-premium,.light-mode .task-stat-grid article,.light-mode .task-search-input{background:rgba(255,255,255,.96)!important}
@media(max-width:430px){.task-stat-grid{grid-template-columns:repeat(2,1fr)}.task-form-row{grid-template-columns:1fr}.task-hero-card{border-radius:26px}.task-hero-ring{width:74px;height:74px;border-radius:22px}.task-card-main{grid-template-columns:auto 1fr auto;gap:10px}.task-card-title{font-size:17px}.task-check-btn{width:40px;height:40px;border-radius:14px}.task-view-tabs .filter-chip{padding-inline:14px}}


/* ===== MyHub v5.1 Tasks UX: simple, clear, action-first ===== */
.tasks-ux-page{padding-bottom:112px;display:grid;gap:16px}
.task-quick-card{border-radius:30px;padding:20px;background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(255,255,255,.88));box-shadow:0 22px 52px rgba(15,23,42,.16);border:1px solid rgba(255,255,255,.72)}
.task-quick-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:14px}.task-quick-head h3{font-size:24px;margin:2px 0 0;color:#0f172a;letter-spacing:-.04em}.task-quick-head .eyebrow{color:#6d28d9;font-weight:900;letter-spacing:.08em;text-transform:uppercase;font-size:12px}
.task-ux-form{display:grid;gap:12px}.task-ux-input{height:58px;border-radius:22px!important;font-size:16px!important;font-weight:800!important;background:#fff!important;box-shadow:inset 0 0 0 1px rgba(148,163,184,.22)}
.task-quick-options{display:flex;gap:8px;overflow-x:auto;padding-bottom:2px}.task-option-chip{border:0;border-radius:999px;background:#eef2ff;color:#4338ca;padding:10px 13px;font-weight:900;white-space:nowrap;box-shadow:inset 0 0 0 1px rgba(79,70,229,.08);cursor:pointer}.task-option-chip.active{background:linear-gradient(135deg,#5b4df5,#7c3aed);color:white;box-shadow:0 12px 26px rgba(99,102,241,.22)}.task-option-chip.priority.active{background:linear-gradient(135deg,#fb923c,#ef4444)}
.task-add-main{height:54px;border-radius:20px!important;font-size:16px!important}.task-section-block{display:grid;gap:10px}.task-section-title{display:flex;align-items:center;justify-content:space-between}.task-section-title h3{font-size:20px;color:#fff;margin:0;letter-spacing:-.03em}.count-pill{min-width:32px;height:32px;border-radius:999px;background:rgba(255,255,255,.95);color:#4f46e5;font-weight:900;display:grid;place-items:center;padding:0 10px}.task-toolbar-ux{margin:0;gap:10px}.task-list-ux{display:grid;gap:10px}.task-list-ux.empty-box{background:transparent;padding:0;color:#fff}
.task-card-premium{border-radius:26px!important;padding:14px!important;background:rgba(255,255,255,.95)!important}.task-card-main{display:grid!important;grid-template-columns:1fr auto!important;gap:12px!important;align-items:center!important}.task-check-btn{width:auto!important;min-width:84px!important;height:42px!important;border-radius:999px!important;font-size:14px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;padding:0 14px!important}.task-check-btn:not(.done)::after{content:'เสร็จ'} .task-check-btn.done::after{content:'แล้ว'}
.task-card-title{font-size:18px!important;margin-bottom:7px!important}.task-meta-row{gap:6px!important}.task-chip{font-size:11px!important;padding:6px 8px!important}.task-menu{position:absolute!important;right:14px!important;top:14px!important}.task-card-premium .task-card-main>div{padding-right:42px}.task-menu summary{width:34px!important;height:34px!important;border-radius:999px!important;background:#f8fafc!important}.task-menu-panel{right:0!important;top:40px!important}.task-card-premium:before{top:16px!important;bottom:16px!important;width:4px!important}.task-card-premium.done{opacity:.78!important}.task-card-premium.done .task-check-btn{background:linear-gradient(135deg,#10b981,#22c55e)!important;color:#fff!important}.task-empty-hint{border-radius:24px!important;padding:18px!important;background:rgba(255,255,255,.9)!important;color:#64748b!important}.task-search-input{height:52px!important;border-radius:20px!important}
.light-mode .task-section-title h3{color:#0f172a}.light-mode .task-list-ux.empty-box{color:#64748b}
@media(max-width:430px){.task-quick-card{border-radius:28px;padding:18px}.task-quick-head h3{font-size:22px}.task-card-main{grid-template-columns:1fr!important}.task-check-btn{width:100%!important}.task-menu{right:12px!important;top:12px!important}.task-card-premium .task-card-main>div{padding-right:40px}.task-view-tabs .filter-chip{padding-inline:14px}}

/* v5.2 Tasks action menu fix */
.task-card-premium{overflow:visible!important;position:relative!important;}
.task-card-main{grid-template-columns:1fr auto!important;align-items:center!important;}
.task-card-premium .task-card-main>div{padding-right:46px!important;}
.task-menu{display:none!important;}
.task-menu-trigger{position:absolute;right:14px;top:14px;width:34px;height:34px;border:0;border-radius:999px;background:#f8fafc;color:#0f172a;font-size:18px;font-weight:900;line-height:1;display:grid;place-items:center;cursor:pointer;box-shadow:inset 0 0 0 1px rgba(148,163,184,.22),0 8px 18px rgba(15,23,42,.08);z-index:4;}
.task-menu-trigger.active{background:#0f172a;color:#fff;box-shadow:0 14px 28px rgba(15,23,42,.22);}
.task-menu-panel-clean{position:absolute;right:14px;top:54px;min-width:138px;padding:8px;border-radius:22px;background:rgba(255,255,255,.98);box-shadow:0 24px 54px rgba(15,23,42,.22);border:1px solid rgba(226,232,240,.85);display:none;gap:4px;z-index:20;}
.task-menu-panel-clean.show{display:grid;animation:menuPop .14s ease-out;}
.task-menu-panel-clean button{border:0;background:transparent;text-align:left;padding:11px 13px;border-radius:15px;font-weight:900;color:#0f172a;cursor:pointer;}
.task-menu-panel-clean button:hover{background:#f1f5f9;}
.task-menu-panel-clean button.delete{color:#f43f5e;}
.task-menu-panel-clean button.delete:hover{background:#fff1f2;}
.task-check-btn{min-width:92px!important;width:auto!important;}
@keyframes menuPop{from{opacity:0;transform:translateY(-4px) scale(.96)}to{opacity:1;transform:translateY(0) scale(1)}}
@media(max-width:430px){.task-card-main{grid-template-columns:1fr auto!important}.task-check-btn{width:auto!important;min-width:86px!important}.task-menu-panel-clean{right:12px;top:50px}.task-card-premium .task-card-main>div{padding-right:42px!important}}

/* ===== v5.3 fix: keep inactive pages hidden even when a page has layout display rules ===== */
.page:not(.active-page) {
  display: none !important;
}
.page.active-page.tasks-ux-page {
  display: grid;
}

/* ===== MyHub v5.4: Tasks swipe actions ===== */
.task-swipe-card{
  overflow:hidden!important;
  padding:0!important;
  border-radius:26px!important;
  background:transparent!important;
  box-shadow:none!important;
  border:0!important;
}
.task-swipe-card:before{display:none!important;}
.task-card-surface{
  position:relative;
  z-index:2;
  border-radius:26px;
  padding:14px;
  background:rgba(255,255,255,.95);
  box-shadow:0 18px 42px rgba(15,23,42,.12);
  border:1px solid rgba(255,255,255,.72);
  transition:transform .24s cubic-bezier(.2,.8,.2,1), box-shadow .2s ease;
  touch-action:pan-y;
}
.task-swipe-card.priority-important .task-card-surface:before,
.task-swipe-card.overdue .task-card-surface:before{
  content:"";
  position:absolute;
  left:0;
  top:16px;
  bottom:16px;
  width:4px;
  border-radius:999px;
  background:linear-gradient(180deg,#f97316,#ef4444);
}
.task-swipe-card.overdue .task-card-surface:before{background:linear-gradient(180deg,#ef4444,#be123c);}
.task-swipe-card.swipe-open .task-card-surface{transform:translateX(-132px);}
.task-swipe-actions{
  position:absolute;
  inset:0 0 0 auto;
  width:124px;
  display:flex;
  align-items:stretch;
  justify-content:flex-end;
  gap:8px;
  padding:10px 10px 10px 0;
  z-index:1;
}
.swipe-action{
  width:56px;
  border:0;
  border-radius:22px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:5px;
  font-weight:900;
  font-size:18px;
  cursor:pointer;
  box-shadow:0 16px 32px rgba(15,23,42,.16);
}
.swipe-action span{font-size:12px;line-height:1;}
.swipe-action.edit{background:linear-gradient(135deg,#e0f2fe,#bae6fd);color:#0369a1;}
.swipe-action.delete{background:linear-gradient(135deg,#ffe4e6,#fecdd3);color:#e11d48;}
.task-menu-trigger,.task-menu-panel-clean{display:none!important;}
.task-swipe-card.done .task-card-surface{opacity:.78;}
.task-swipe-card.done .task-card-title{text-decoration:line-through;color:#64748b;}
@media(max-width:430px){
  .task-swipe-card.swipe-open .task-card-surface{transform:translateX(-122px);}
  .task-swipe-actions{width:116px;gap:6px;padding-right:8px;}
  .swipe-action{width:52px;border-radius:20px;}
}

/* ===== MyHub v5.5: Hide swipe actions until user actually swipes ===== */
.task-swipe-card{
  overflow:hidden!important;
  isolation:isolate;
}
.task-swipe-actions{
  opacity:0!important;
  visibility:hidden!important;
  pointer-events:none!important;
  transform:translateX(16px);
  transition:opacity .18s ease, transform .22s cubic-bezier(.2,.8,.2,1), visibility .18s ease;
}
.task-swipe-card.swipe-open .task-swipe-actions,
.task-swipe-card.swiping .task-swipe-actions{
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  transform:translateX(0);
}
.task-card-surface{
  width:100%;
  min-height:100%;
  box-sizing:border-box;
}
.task-swipe-card:not(.swipe-open):not(.swiping) .task-card-surface{
  transform:translateX(0)!important;
}


/* ===== MyHub v5.7: Drag + Subtasks (right-swipe done removed) ===== */
.mini-badge{background:linear-gradient(135deg,#ede9fe,#ddd6fe)!important;color:#5b21b6!important;}
.subtask-input{margin-top:10px;}
.task-card-main{grid-template-columns:auto 1fr auto!important;gap:12px!important;align-items:center!important;}
.drag-handle{width:32px;height:42px;border:0;border-radius:16px;background:rgba(99,102,241,.10);color:#6d28d9;font-weight:900;font-size:18px;cursor:grab;touch-action:none;}
.drag-handle:active{cursor:grabbing;transform:scale(.96);}
.task-content-block{min-width:0;}
.subtask-list{display:flex;flex-wrap:wrap;gap:7px;margin-top:10px;}
.subtask-pill{border:0;border-radius:999px;padding:7px 10px;background:#f1f5f9;color:#334155;font-size:12px;font-weight:800;box-shadow:inset 0 0 0 1px rgba(148,163,184,.18);}
.subtask-pill.done{background:#dcfce7;color:#047857;text-decoration:line-through;}
.task-chip.subtask-progress{background:#eef2ff;color:#4f46e5;}
.task-swipe-card.dragging{opacity:.58;transform:scale(.985);}
.task-swipe-card.drag-over .task-card-surface{box-shadow:0 0 0 3px rgba(124,58,237,.28),0 18px 42px rgba(15,23,42,.12);}
@media(max-width:430px){.task-card-main{grid-template-columns:28px 1fr auto!important;gap:8px!important}.drag-handle{width:28px;height:38px;font-size:15px}.subtask-pill{font-size:11px;padding:6px 8px}.task-check-btn{min-width:76px!important}}

/* ===== MyHub v5.8: Premium Subtask UI ===== */
.subtask-composer{
  margin-top:12px;
  padding:12px;
  border-radius:22px;
  background:rgba(255,255,255,.08);
  border:1px solid rgba(148,163,184,.18);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08);
}
.light-mode .subtask-composer{background:#f8fafc;border-color:#e2e8f0;}
.subtask-composer-label{font-size:12px;font-weight:900;color:#94a3b8;margin:0 0 8px 4px;letter-spacing:.02em;}
.subtask-input-row{display:grid;grid-template-columns:1fr 44px;gap:8px;align-items:center;}
.subtask-draft-input,
.edit-subtask-input{
  width:100%;box-sizing:border-box;border:0;outline:none;border-radius:18px;padding:13px 14px;
  background:rgba(15,23,42,.50);color:#fff;font-weight:800;font-size:14px;
  box-shadow:inset 0 0 0 1px rgba(148,163,184,.18);
}
.light-mode .subtask-draft-input,.light-mode .edit-subtask-input{background:#fff;color:#0f172a;box-shadow:inset 0 0 0 1px #e2e8f0;}
.subtask-add-btn,.edit-subtask-add-btn{
  height:44px;border:0;border-radius:16px;cursor:pointer;font-weight:1000;font-size:18px;color:#fff;
  background:linear-gradient(135deg,#7c3aed,#ec4899);box-shadow:0 12px 28px rgba(124,58,237,.28);
}
.subtask-draft-list,.edit-subtask-list{display:flex;flex-direction:column;gap:8px;margin-top:10px;}
.subtask-draft-chip,.edit-subtask-row{
  display:flex;align-items:center;gap:9px;padding:9px 10px;border-radius:16px;
  background:rgba(15,23,42,.35);border:1px solid rgba(148,163,184,.14);
}
.light-mode .subtask-draft-chip,.light-mode .edit-subtask-row{background:#fff;border-color:#e2e8f0;}
.subtask-draft-dot{width:18px;height:18px;border-radius:50%;display:grid;place-items:center;background:rgba(124,58,237,.14);color:#a78bfa;font-size:11px;font-weight:1000;flex:0 0 18px;}
.subtask-draft-text,.edit-subtask-text{flex:1;font-size:13px;font-weight:850;color:#e2e8f0;line-height:1.35;}
.light-mode .subtask-draft-text,.light-mode .edit-subtask-text{color:#0f172a;}
.subtask-remove-btn,.edit-subtask-remove-btn{border:0;background:rgba(239,68,68,.12);color:#fca5a5;width:30px;height:30px;border-radius:12px;font-weight:1000;cursor:pointer;}
.light-mode .subtask-remove-btn,.light-mode .edit-subtask-remove-btn{color:#dc2626;background:#fee2e2;}
.task-subtask-panel{margin-top:12px;padding:10px;border-radius:18px;background:rgba(255,255,255,.07);border:1px solid rgba(148,163,184,.15);}
.light-mode .task-subtask-panel{background:#f8fafc;border-color:#e2e8f0;}
.subtask-progress-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px;}
.subtask-progress-title{font-size:12px;font-weight:950;color:#c4b5fd;}
.light-mode .subtask-progress-title{color:#6d28d9;}
.subtask-progress-count{font-size:11px;font-weight:950;color:#94a3b8;}
.subtask-progress-track{height:7px;border-radius:999px;background:rgba(148,163,184,.20);overflow:hidden;margin-bottom:9px;}
.subtask-progress-fill{height:100%;border-radius:inherit;background:linear-gradient(135deg,#7c3aed,#22c55e);transition:width .25s ease;}
.subtask-check-list{display:flex;flex-direction:column;gap:7px;}
.subtask-check-item{display:flex;align-items:center;gap:9px;width:100%;border:0;background:transparent;color:inherit;text-align:left;padding:6px;border-radius:13px;cursor:pointer;}
.subtask-check-item:hover{background:rgba(148,163,184,.10);}
.subtask-checkbox{width:22px;height:22px;border-radius:9px;display:grid;place-items:center;flex:0 0 22px;background:rgba(148,163,184,.18);color:transparent;font-size:13px;font-weight:1000;box-shadow:inset 0 0 0 1px rgba(148,163,184,.20);}
.subtask-check-item.done .subtask-checkbox{background:linear-gradient(135deg,#22c55e,#10b981);color:#fff;box-shadow:none;}
.subtask-check-text{font-size:12.5px;font-weight:850;color:#cbd5e1;line-height:1.35;}
.light-mode .subtask-check-text{color:#334155;}
.subtask-check-item.done .subtask-check-text{text-decoration:line-through;opacity:.62;}
.edit-subtask-builder{display:flex;flex-direction:column;gap:9px;margin:10px 0 12px;}
.edit-subtask-row .mini-check{width:22px;height:22px;border-radius:8px;border:0;background:#e0f2fe;color:#0284c7;font-weight:1000;cursor:pointer;}
.edit-subtask-row.done .mini-check{background:#dcfce7;color:#047857;}
.edit-subtask-row.done .edit-subtask-text{text-decoration:line-through;opacity:.65;}
@media(max-width:430px){
  .subtask-composer{padding:10px;border-radius:18px;}
  .subtask-draft-input,.edit-subtask-input{font-size:13px;padding:12px;}
  .subtask-add-btn,.edit-subtask-add-btn{height:42px;border-radius:15px;}
  .task-subtask-panel{padding:9px;}
  .subtask-check-text{font-size:12px;}
}

/* ===== MyHub v5.9: Tasks readability + clean action buttons ===== */
.task-quick-card,.task-card-surface,.task-card-premium,.task-empty-hint{color:#0f172a!important}.task-quick-card .muted,.task-card-surface .muted,.task-card-premium .muted{color:#64748b!important}
.subtask-composer{background:#f8fafc!important;border:1px solid #e2e8f0!important;box-shadow:inset 0 0 0 1px rgba(255,255,255,.65)}.subtask-composer-label{color:#475569!important}.subtask-draft-input,.edit-subtask-input{background:#fff!important;color:#0f172a!important;border:1px solid #dbe3ee!important;box-shadow:0 8px 20px rgba(15,23,42,.04)!important}.subtask-draft-input::placeholder,.edit-subtask-input::placeholder{color:#94a3b8!important}.subtask-draft-chip,.edit-subtask-row{background:#fff!important;border-color:#e2e8f0!important}.subtask-draft-text,.edit-subtask-text{color:#0f172a!important}.subtask-empty-hint{color:#64748b!important;font-weight:800;font-size:12px}
.task-subtask-panel{background:#f8fafc!important;border:1px solid #e2e8f0!important}.subtask-progress-title{color:#4f46e5!important}.subtask-progress-count{color:#475569!important}.subtask-progress-track{background:#e2e8f0!important}.subtask-check-text{color:#1f2937!important}.subtask-check-item.done .subtask-check-text{color:#64748b!important}.subtask-check-item:hover{background:#eef2ff!important}
.task-check-btn::after,.task-check-btn:not(.done)::after,.task-check-btn.done::after{content:none!important}.task-check-btn{min-width:92px!important;height:40px!important;padding:0 14px!important;white-space:nowrap!important;line-height:1!important;gap:6px!important;box-shadow:inset 0 0 0 1px rgba(99,102,241,.18),0 8px 18px rgba(99,102,241,.08)!important}.task-check-btn.done{min-width:92px!important;background:#ecfdf5!important;color:#047857!important;box-shadow:inset 0 0 0 1px rgba(16,185,129,.22),0 8px 18px rgba(16,185,129,.08)!important}
.task-card-main{grid-template-columns:30px minmax(0,1fr) auto!important}.task-content-block{min-width:0!important}.task-card-title{color:#0f172a!important}.drag-handle{color:#7c3aed!important;background:#f5f3ff!important}.task-chip{color:#0369a1!important;background:#e0f2fe!important}.task-chip.priority{color:#ea580c!important;background:#fff7ed!important}.task-chip.subtask-progress{color:#4f46e5!important;background:#eef2ff!important}.task-chip.done{color:#059669!important;background:#dcfce7!important}
@media(max-width:430px){.task-card-main{grid-template-columns:28px minmax(0,1fr) auto!important;gap:8px!important}.task-check-btn{min-width:78px!important;height:38px!important;padding:0 11px!important;font-size:13px!important}.task-check-btn.done{min-width:78px!important}.task-subtask-panel{margin-right:-2px}}

/* ===== MyHub v6 Dashboard UI Premium ===== */
.dashboard-v6-page{display:none;gap:14px}.dashboard-v6-page.active-page{display:block}.dash-hero-v6{position:relative;overflow:hidden;border-radius:34px;padding:22px;background:linear-gradient(135deg,rgba(79,70,229,.96),rgba(124,58,237,.92) 56%,rgba(236,72,153,.82));box-shadow:0 26px 60px rgba(49,46,129,.36);color:#fff;margin-bottom:12px}.dash-hero-v6:before{content:"";position:absolute;inset:-90px -70px auto auto;width:210px;height:210px;border-radius:50%;background:rgba(255,255,255,.18);filter:blur(1px)}.dash-hero-v6:after{content:"";position:absolute;left:-60px;bottom:-95px;width:210px;height:210px;border-radius:50%;background:rgba(255,255,255,.10)}.dash-hero-top{position:relative;z-index:1;display:flex;justify-content:space-between;align-items:flex-start;gap:14px}.dash-hero-v6 .eyebrow{color:rgba(255,255,255,.8)}.dash-hero-v6 h1{font-size:30px;line-height:1.08;margin:6px 0}.dash-hero-sub{margin:0;color:rgba(255,255,255,.82);font-weight:700}.dash-add-btn{width:58px;height:58px;border-radius:22px;background:rgba(255,255,255,.22);color:#fff;font-size:28px;font-weight:900;box-shadow:inset 0 0 0 1px rgba(255,255,255,.26),0 16px 30px rgba(15,23,42,.24);backdrop-filter:blur(12px)}.dash-focus-card{position:relative;z-index:1;margin-top:22px;padding:14px;border-radius:24px;background:rgba(255,255,255,.16);display:flex;align-items:center;justify-content:space-between;gap:12px;box-shadow:inset 0 0 0 1px rgba(255,255,255,.18)}.focus-label{display:block;color:rgba(255,255,255,.72);font-size:12px;font-weight:900;text-transform:uppercase;letter-spacing:.08em}.dash-focus-card strong{display:block;font-size:34px;line-height:1;font-weight:1000}.focus-ring{width:86px;height:86px;border-radius:50%;display:grid;place-items:center;background:conic-gradient(from 120deg,#fff 0 75%,rgba(255,255,255,.28) 75%);color:#312e81;box-shadow:0 18px 36px rgba(15,23,42,.20)}.focus-ring span{font-size:24px;font-weight:1000;line-height:1}.focus-ring small{font-size:10px;margin-top:-18px;font-weight:900;color:#4c1d95}.v6-actions{margin:8px 0 12px}.dash-quick-row{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin:10px 0 14px}.dash-quick-action{min-height:74px;border-radius:23px;background:rgba(255,255,255,.92);box-shadow:0 14px 30px rgba(2,6,23,.13);border:1px solid rgba(255,255,255,.5);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;color:#111827;font-weight:900}.dash-quick-action span{width:31px;height:31px;border-radius:13px;display:grid;place-items:center;background:linear-gradient(135deg,#eef2ff,#f5f3ff);color:#4f46e5;font-weight:1000}.dash-quick-action:active{transform:scale(.97)}.dash-stat-v6-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:12px 0}.dash-stat-v6{border-radius:28px;padding:18px;min-height:126px;color:#fff;box-shadow:0 22px 48px rgba(15,23,42,.22);position:relative;overflow:hidden}.dash-stat-v6:after{content:"";position:absolute;right:-36px;bottom:-54px;width:130px;height:130px;border-radius:50%;background:rgba(255,255,255,.16)}.dash-stat-v6 span,.dash-stat-v6 small{display:block;position:relative;z-index:1}.dash-stat-v6 span{font-size:12px;font-weight:900;color:rgba(255,255,255,.8)}.dash-stat-v6 strong{display:block;position:relative;z-index:1;font-size:25px;line-height:1.1;margin:12px 0 7px;letter-spacing:-.02em}.dash-stat-v6 small{font-size:11px;color:rgba(255,255,255,.78);font-weight:800}.dash-stat-v6.spend{background:linear-gradient(135deg,#fb7185,#f97316)}.dash-stat-v6.balance{background:linear-gradient(135deg,#10b981,#0891b2)}.dash-section-card{background:rgba(255,255,255,.94);border:1px solid rgba(255,255,255,.52);border-radius:30px;padding:18px;margin:14px 0;box-shadow:0 18px 45px rgba(2,6,23,.16);backdrop-filter:blur(18px)}.dash-section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.dash-section-head h3{margin:0;font-size:18px}.dash-section-head .eyebrow{margin-bottom:2px}.dash-pill{border-radius:999px;background:#eef2ff;color:#4f46e5;padding:8px 11px;font-weight:1000;font-size:12px;white-space:nowrap}.money-pulse-card canvas{width:100%;display:block;margin-top:4px}.dash-list{display:grid;gap:10px}.dash-mini-item{display:grid;grid-template-columns:42px 1fr;gap:11px;align-items:center;border-radius:21px;padding:11px;background:linear-gradient(180deg,#fff,#f8fafc);border:1px solid rgba(148,163,184,.18);box-shadow:0 10px 22px rgba(15,23,42,.06)}.dash-mini-item strong{display:block;font-size:14px;color:#0f172a;line-height:1.25;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dash-mini-item small{display:block;margin-top:3px;color:#64748b;font-size:12px;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dash-mini-icon{width:42px;height:42px;border-radius:16px;display:grid;place-items:center;background:#eef2ff;color:#4f46e5;font-weight:1000}.dash-mini-item.important .dash-mini-icon{background:#fff1f2;color:#e11d48}.dash-watch-poster{width:42px;height:58px;border-radius:14px;overflow:hidden;background:linear-gradient(135deg,#4f46e5,#7c3aed);display:grid;place-items:center;color:#fff;font-weight:1000;box-shadow:0 10px 18px rgba(79,70,229,.22)}.dash-watch-poster img{width:100%;height:100%;object-fit:cover;display:block}.dash-empty{border-radius:20px;padding:15px;text-align:center;color:#64748b;background:#f8fafc;font-weight:800}.light-mode .dash-section-card,.light-mode .dash-quick-action{background:rgba(255,255,255,.96)}.light-mode .dash-mini-item{background:#fff}@media(max-width:420px){.dash-hero-v6{border-radius:30px;padding:19px}.dash-hero-v6 h1{font-size:26px}.dash-focus-card strong{font-size:30px}.focus-ring{width:78px;height:78px}.dash-stat-v6{border-radius:24px;padding:15px;min-height:116px}.dash-stat-v6 strong{font-size:21px}.dash-section-card{border-radius:26px;padding:15px}.dash-quick-row{gap:8px}.dash-quick-action{min-height:66px;border-radius:20px;font-size:13px}.dash-quick-action span{width:28px;height:28px;border-radius:11px}}


/* ===== v6.1 Dashboard clean-up ===== */
.topbar-actions{
  display:flex;
  align-items:center;
  gap:10px;
}
.top-install-btn{
  width:48px;
  height:48px;
  border-radius:18px;
  display:grid;
  place-items:center;
  background:linear-gradient(135deg,#4f46e5,#7c3aed);
  color:#fff;
  font-size:28px;
  font-weight:900;
  box-shadow:0 14px 28px rgba(79,70,229,.28);
}
.top-install-btn.hidden{display:none!important;}
.profile-settings-card h3{margin-bottom:14px;}
.setting-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:14px;
  border-radius:22px;
  background:rgba(15,23,42,.04);
  border:1px solid rgba(148,163,184,.18);
}
.setting-row strong{
  display:block;
  font-size:16px;
  color:#0f172a;
}
.setting-row p{
  margin:4px 0 0;
  font-size:12px;
}
.theme-switch{
  position:relative;
  flex:0 0 auto;
  width:66px;
  height:38px;
  border-radius:999px;
  background:#cbd5e1;
  box-shadow:inset 0 0 0 1px rgba(15,23,42,.08);
  transition:.2s ease;
}
.theme-switch span{
  position:absolute;
  width:30px;
  height:30px;
  left:4px;
  top:4px;
  border-radius:50%;
  background:#fff;
  box-shadow:0 8px 18px rgba(15,23,42,.18);
  transition:.2s ease;
}
.theme-switch[aria-checked="true"]{
  background:linear-gradient(135deg,#4f46e5,#7c3aed);
}
.theme-switch[aria-checked="true"] span{
  transform:translateX(28px);
}

/* Better real light mode readability */
body.light-mode{
  --bg:#f8fafc;
  --bg-soft:#eef2ff;
  --card:rgba(255,255,255,.96);
  --text:#0f172a;
  --muted:#64748b;
  color:#0f172a!important;
  background:
    radial-gradient(circle at top left, rgba(99,102,241,.16), transparent 30rem),
    linear-gradient(145deg,#eef2ff 0%,#f8fafc 60%,#ffffff 100%)!important;
}
body.light-mode .topbar{
  color:#0f172a!important;
}
body.light-mode .topbar .eyebrow{
  color:#4f46e5!important;
}
body.light-mode .avatar-btn{
  background:#ffffff!important;
  color:#0f172a!important;
  box-shadow:0 12px 26px rgba(15,23,42,.10);
}
body.light-mode .panel-card,
body.light-mode .glass-card,
body.light-mode .item-card,
body.light-mode .task-card-premium,
body.light-mode .task-quick-card,
body.light-mode .task-empty-hint,
body.light-mode .dash-section-card{
  background:rgba(255,255,255,.96)!important;
  color:#0f172a!important;
  border-color:rgba(148,163,184,.22)!important;
}
body.light-mode h1,
body.light-mode h2,
body.light-mode h3,
body.light-mode strong,
body.light-mode .task-card-title,
body.light-mode .dash-mini-item strong{
  color:#0f172a!important;
}
body.light-mode p,
body.light-mode .muted,
body.light-mode small,
body.light-mode .dash-mini-item small{
  color:#64748b!important;
}
body.light-mode input,
body.light-mode textarea,
body.light-mode select{
  background:#ffffff!important;
  color:#0f172a!important;
}
body.light-mode input::placeholder,
body.light-mode textarea::placeholder{
  color:#94a3b8!important;
}
body.light-mode .bottom-nav{
  background:rgba(255,255,255,.94)!important;
  box-shadow:0 18px 40px rgba(15,23,42,.14);
}
body.light-mode .nav-btn{
  color:#64748b!important;
}
body.light-mode .nav-btn.active{
  color:#ffffff!important;
}
body.light-mode .setting-row{
  background:#f8fafc!important;
}
body.light-mode .dash-empty{
  background:#f8fafc!important;
  color:#64748b!important;
}

@media(max-width:420px){
  .top-install-btn,.avatar-btn{width:46px;height:46px;border-radius:17px;}
}
