*{margin:0;padding:0;box-sizing:border-box}
:root {
--bg:#fafafa;--nav-bg:#ffffff;--text:#1a1a1a;--text-muted:#888;
--border:#e5e5e5;--hover:#f0f0f0;--accent:#333;
--overlay:rgba(0,0,0,0.3);--shadow:0 1px 3px rgba(0,0,0,0.06);
--danger:#dc3545;--success:#28a745;--warning:#f59e0b;
--hour-height:72px;
}
body{font-family:'Inter',sans-serif;background:var(--bg);color:var(--text);min-height:100vh;transition:background 0.4s,color 0.3s}
#bg-layer{position:fixed;inset:0;z-index:-2;background-size:cover;background-position:center;background-repeat:no-repeat;background-attachment:fixed;opacity:0;transition:opacity 0.6s ease}
#bg-layer.visible{opacity:1}
#bg-overlay{position:fixed;inset:0;z-index:-1;opacity:0;pointer-events:none;transition:opacity 0.6s ease}
#bg-overlay.visible{opacity:1}
#password-screen{display:none;align-items:center;justify-content:center;min-height:100vh;flex-direction:column;position:relative;z-index:1}
.pw-card{display:flex;flex-direction:column;align-items:center;gap:20px;padding:48px 44px;border-radius:16px;transition:background 0.3s,border-color 0.3s}
.image-theme .pw-card{background:var(--nav-bg);backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px);border:1px solid var(--border)}
.pw-card h1{font-size:1.6rem;font-weight:300;letter-spacing:0.12em;color:var(--text-muted)}
.pw-card input{background:transparent;border:none;border-bottom:1px solid var(--border);padding:10px 16px;font-size:1rem;font-family:'Inter',sans-serif;color:var(--text);text-align:center;outline:none;width:200px;transition:border-color 0.3s}
.pw-card input:focus{border-bottom-color:var(--accent)}
.pw-card input::placeholder{color:var(--text-muted)}
.error{color:var(--danger);font-size:0.8rem;height:1rem}
#app{display:block;position:relative;z-index:1}
.navbar{position:fixed;top:0;left:0;right:0;height:56px;background:var(--nav-bg);border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;padding:0 16px;z-index:100;box-shadow:var(--shadow);transition:background 0.3s,border-color 0.3s}
.image-theme .navbar{backdrop-filter:blur(22px);-webkit-backdrop-filter:blur(22px)}
.nav-left,.nav-right{display:flex;align-items:center;gap:4px}
.nav-center{position:absolute;left:50%;transform:translateX(-50%);font-size:1rem;font-weight:300;letter-spacing:0.15em;color:var(--text-muted)}
.nav-btn{background:none;border:none;color:var(--text);cursor:pointer;width:40px;height:40px;display:flex;align-items:center;justify-content:center;border-radius:8px;transition:background 0.2s;position:relative}
.nav-btn:hover{background:var(--hover)}
.nav-btn svg{width:20px;height:20px;stroke:var(--text);stroke-width:1.5;fill:none;stroke-linecap:round;stroke-linejoin:round;transition:stroke 0.3s}
.theme-picker-wrap{position:relative}
.theme-picker{position:absolute;top:calc(100% + 10px);right:0;background:var(--nav-bg);border:1px solid var(--border);border-radius:14px;padding:6px;min-width:200px;box-shadow:0 8px 32px rgba(0,0,0,0.12);opacity:0;transform:translateY(-6px) scale(0.97);pointer-events:none;transition:opacity 0.2s,transform 0.2s;z-index:1000}
.theme-picker.active{opacity:1;transform:translateY(0) scale(1);pointer-events:all}
.image-theme .theme-picker{backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px)}
.theme-option{display:flex;align-items:center;gap:11px;padding:10px 12px;border-radius:9px;cursor:pointer;font-size:0.85rem;color:var(--text);transition:background 0.15s}
.theme-option:hover{background:var(--hover)}
.theme-dot{width:16px;height:16px;border-radius:50%;flex-shrink:0;border:2px solid rgba(128,128,128,0.12)}
.theme-option .check-icon{margin-left:auto;width:15px;height:15px;stroke:var(--accent);stroke-width:2.2;fill:none;stroke-linecap:round;stroke-linejoin:round;opacity:0;transition:opacity 0.15s}
.theme-option.active .check-icon{opacity:1}
.sidebar-overlay{position:fixed;inset:0;background:var(--overlay);z-index:200;opacity:0;pointer-events:none;transition:opacity 0.3s}
.sidebar-overlay.active{opacity:1;pointer-events:all}
.sidebar{position:fixed;top:0;left:-290px;width:280px;height:100vh;background:var(--nav-bg);z-index:300;transition:left 0.3s ease,background 0.3s;padding:24px 0;overflow-y:auto}
.image-theme .sidebar{backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px)}
.sidebar.active{left:0}
.sidebar-header{padding:0 20px 20px;border-bottom:1px solid var(--border);margin-bottom:8px;display:flex;align-items:center;justify-content:space-between}
.sidebar-header span{font-size:0.75rem;font-weight:500;letter-spacing:0.15em;color:var(--text-muted)}
.sidebar-close{background:none;border:none;color:var(--text);cursor:pointer;width:32px;height:32px;display:flex;align-items:center;justify-content:center;border-radius:6px;transition:background 0.2s}
.sidebar-close:hover{background:var(--hover)}
.sidebar-close svg{width:18px;height:18px;stroke:var(--text);stroke-width:1.5;fill:none;stroke-linecap:round;stroke-linejoin:round}
.menu-item{display:flex;align-items:center;gap:13px;padding:12px 20px;cursor:pointer;transition:background 0.15s;font-size:0.88rem;font-weight:400;color:var(--text);text-decoration:none}
.menu-item:hover{background:var(--hover)}
.menu-item.active{background:var(--hover)}
.menu-item svg,.menu-header svg{width:18px;height:18px;stroke:var(--text-muted);stroke-width:1.5;fill:none;flex-shrink:0;stroke-linecap:round;stroke-linejoin:round;transition:stroke 0.3s}
.menu-header{display:flex;align-items:center;gap:13px;padding:12px 20px;font-size:0.88rem;font-weight:500;color:var(--text);cursor:pointer;transition:background 0.15s}
.menu-header:hover{background:var(--hover)}
.menu-header .chevron{margin-left:auto;width:14px;height:14px;stroke:var(--text-muted);transition:transform 0.25s}
.menu-header.open .chevron{transform:rotate(90deg)}
.submenu{display:none;padding-left:18px}
.submenu.open{display:block}
.submenu .menu-item{font-size:0.82rem;padding:9px 20px;color:var(--text-muted)}
.submenu .menu-item:hover{color:var(--text)}
.menu-divider{height:1px;background:var(--border);margin:8px 20px;transition:background 0.3s}
.page-content{padding-top:56px;min-height:100vh}
.page{display:none;padding:32px 20px;max-width:720px;margin:0 auto}
.page.active{display:block}
#page-planner.active{display:block;padding:0;max-width:none;margin:0}
.btn{display:inline-flex;align-items:center;gap:6px;padding:8px 14px;border-radius:8px;font-size:0.82rem;font-family:'Inter',sans-serif;font-weight:500;cursor:pointer;border:1px solid var(--border);background:var(--nav-bg);color:var(--text);transition:all 0.15s}
.btn:hover{background:var(--hover)}
.btn-primary{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.btn-primary:hover{opacity:0.85}
.btn-danger{color:var(--danger);border-color:var(--danger)}
.btn-danger:hover{background:var(--danger);color:#fff}
.btn-sm{padding:5px 10px;font-size:0.75rem}
.btn svg{width:14px;height:14px;stroke:currentColor;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.tasks-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:28px;flex-wrap:wrap;gap:12px}
.tasks-header h2{font-size:1.4rem;font-weight:600;color:var(--text)}
.tasks-header-right{display:flex;align-items:center;gap:10px}
.tasks-overview{display:flex;align-items:center;gap:20px;padding:20px;border-radius:14px;margin-bottom:28px;background:var(--nav-bg);border:1px solid var(--border);transition:background 0.3s,border-color 0.3s}
.image-theme .tasks-overview{backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.pie-container{position:relative;width:80px;height:80px;flex-shrink:0}
.pie-container canvas{width:80px;height:80px}
.pie-label{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;font-size:0.85rem;font-weight:600;color:var(--text)}
.overview-stats{display:flex;flex-direction:column;gap:4px}
.overview-stats .stat-line{font-size:0.82rem;color:var(--text-muted);display:flex;align-items:center;gap:6px}
.stat-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}
.stat-dot.done{background:var(--success)}
.stat-dot.pending{background:var(--border)}
.stat-dot.overdue{background:var(--danger)}
.filter-bar{display:flex;align-items:center;gap:6px;margin-bottom:20px;overflow-x:auto;padding-bottom:4px}
.filter-chip{padding:5px 12px;border-radius:20px;font-size:0.75rem;font-weight:500;cursor:pointer;white-space:nowrap;border:1px solid var(--border);background:var(--nav-bg);color:var(--text-muted);transition:all 0.15s}
.filter-chip:hover{border-color:var(--accent);color:var(--text)}
.filter-chip.active{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.task-group{margin-bottom:24px}
.task-group-label{font-size:0.7rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:8px;padding-left:4px}
.task-group-label.overdue-label{color:var(--danger)}
.task-card{display:flex;align-items:flex-start;gap:12px;padding:14px 16px;border-radius:10px;margin-bottom:6px;background:var(--nav-bg);border:1px solid var(--border);transition:all 0.15s;position:relative}
.image-theme .task-card{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.task-card:hover{box-shadow:0 2px 8px rgba(0,0,0,0.06)}
.task-card.overdue{border-left:3px solid var(--danger)}
.task-card.completed{opacity:0.55}
.task-card.completed .task-title{text-decoration:line-through}
.task-checkbox{width:20px;height:20px;border-radius:50%;border:2px solid var(--border);cursor:pointer;flex-shrink:0;margin-top:1px;display:flex;align-items:center;justify-content:center;transition:all 0.2s}
.task-checkbox:hover{border-color:var(--accent)}
.task-checkbox.checked{background:var(--success);border-color:var(--success)}
.task-checkbox.checked::after{content:'';width:6px;height:10px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg);margin-top:-2px}
.task-body{flex:1;min-width:0}
.task-title{font-size:0.88rem;font-weight:500;color:var(--text);margin-bottom:4px;word-break:break-word}
.task-meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.task-date{font-size:0.72rem;color:var(--text-muted);display:flex;align-items:center;gap:3px}
.task-date svg{width:11px;height:11px;stroke:currentColor;stroke-width:1.8;fill:none;stroke-linecap:round;stroke-linejoin:round}
.task-date.overdue-text{color:var(--danger)}
.task-tag{font-size:0.68rem;font-weight:500;padding:2px 8px;border-radius:10px;background:var(--hover);color:var(--text-muted)}
.task-tag[data-tag="personal"]{background:rgba(59,130,246,0.1);color:#3b82f6}
.task-tag[data-tag="school"]{background:rgba(245,158,11,0.1);color:#d97706}
.task-tag[data-tag="algebra-2"]{background:rgba(139,92,246,0.1);color:#8b5cf6}
.task-tag[data-tag="writing"]{background:rgba(236,72,153,0.1);color:#ec4899}
.task-tag[data-tag="demologia"]{background:rgba(20,184,166,0.1);color:#14b8a6}
.task-tag[data-tag="mun"]{background:rgba(249,115,22,0.1);color:#f97316}
.task-tag[data-tag="running"]{background:rgba(34,197,94,0.1);color:#22c55e}
.task-actions{display:flex;gap:2px;opacity:0;transition:opacity 0.15s;flex-shrink:0}
.task-card:hover .task-actions{opacity:1}
.task-action-btn{background:none;border:none;cursor:pointer;width:28px;height:28px;display:flex;align-items:center;justify-content:center;border-radius:6px;transition:background 0.15s}
.task-action-btn:hover{background:var(--hover)}
.task-action-btn svg{width:14px;height:14px;stroke:var(--text-muted);stroke-width:1.8;fill:none;stroke-linecap:round;stroke-linejoin:round}
.task-action-btn.delete-btn:hover svg{stroke:var(--danger)}
.task-action-btn.recover-btn:hover svg{stroke:var(--success)}
.tasks-empty{text-align:center;padding:60px 20px;color:var(--text-muted)}
.tasks-empty svg{width:48px;height:48px;stroke:var(--border);stroke-width:1;fill:none;margin-bottom:16px;stroke-linecap:round;stroke-linejoin:round}
.tasks-empty p{font-size:0.88rem;margin-top:8px}
.history-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:28px;flex-wrap:wrap;gap:12px}
.history-header h2{font-size:1.4rem;font-weight:600;color:var(--text)}
.history-tally{display:flex;align-items:center;gap:20px;padding:20px 24px;border-radius:14px;margin-bottom:28px;background:var(--nav-bg);border:1px solid var(--border);transition:background 0.3s,border-color 0.3s}
.image-theme .history-tally{backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.tally-number{font-size:2.4rem;font-weight:700;color:var(--success);line-height:1}
.tally-details{display:flex;flex-direction:column;gap:2px}
.tally-label{font-size:0.82rem;font-weight:500;color:var(--text)}
.tally-sub{font-size:0.72rem;color:var(--text-muted)}
.history-search-row{display:flex;align-items:center;gap:10px;margin-bottom:20px;flex-wrap:wrap}
.history-search{flex:1;min-width:180px;padding:9px 14px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.84rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s}
.history-search:focus{border-color:var(--accent)}
.history-search::placeholder{color:var(--text-muted)}
.history-card{display:flex;align-items:flex-start;gap:12px;padding:14px 16px;border-radius:10px;margin-bottom:6px;background:var(--nav-bg);border:1px solid var(--border);transition:all 0.15s;border-left:3px solid var(--success)}
.image-theme .history-card{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.history-card:hover{box-shadow:0 2px 8px rgba(0,0,0,0.06)}
.history-icon{width:20px;height:20px;border-radius:50%;background:var(--success);flex-shrink:0;margin-top:1px;display:flex;align-items:center;justify-content:center}
.history-icon::after{content:'';width:6px;height:10px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg);margin-top:-2px}
.history-body{flex:1;min-width:0}
.history-title{font-size:0.88rem;font-weight:500;color:var(--text);margin-bottom:4px;word-break:break-word}
.history-meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.history-completed-date{font-size:0.72rem;color:var(--text-muted);display:flex;align-items:center;gap:3px}
.history-completed-date svg{width:11px;height:11px;stroke:currentColor;stroke-width:1.8;fill:none;stroke-linecap:round;stroke-linejoin:round}
.history-due-label{font-size:0.68rem;color:var(--text-muted);font-style:italic}
.history-actions{display:flex;gap:2px;opacity:0;transition:opacity 0.15s;flex-shrink:0}
.history-card:hover .history-actions{opacity:1}
.history-group{margin-bottom:24px}
.history-group-label{font-size:0.7rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:8px;padding-left:4px}
.history-load-more{display:flex;justify-content:center;margin-top:20px}

/* ═══════════════════════════════════════
PLANNER STYLES
═══════════════════════════════════════ */
.planner-wrap{display:flex;height:calc(100vh - 56px);overflow:hidden}
.planner-side{width:260px;min-width:260px;border-right:1px solid var(--border);background:var(--nav-bg);display:flex;flex-direction:column;transition:margin-left 0.3s,background 0.3s,border-color 0.3s;overflow:hidden}
.image-theme .planner-side{backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.planner-side.collapsed{margin-left:-260px}
.planner-side-header{padding:16px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--border);flex-shrink:0}
.planner-side-header span{font-size:0.72rem;font-weight:600;letter-spacing:0.12em;text-transform:uppercase;color:var(--text-muted)}
.planner-side-toggle{background:none;border:none;cursor:pointer;width:28px;height:28px;display:flex;align-items:center;justify-content:center;border-radius:6px;transition:background 0.15s}
.planner-side-toggle:hover{background:var(--hover)}
.planner-side-toggle svg{width:16px;height:16px;stroke:var(--text-muted);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.planner-side-body{flex:1;overflow-y:auto;padding:12px}
.planner-side-section{margin-bottom:20px}
.planner-side-label{font-size:0.68rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:8px}
.planner-side-item{display:flex;align-items:center;gap:8px;padding:8px 10px;border-radius:8px;margin-bottom:4px;background:var(--hover);cursor:grab;transition:box-shadow 0.15s,opacity 0.15s;font-size:0.8rem;color:var(--text);user-select:none;border:1px solid transparent}
.planner-side-item:hover{box-shadow:0 2px 6px rgba(0,0,0,0.08);border-color:var(--border)}
.planner-side-item:active{cursor:grabbing;opacity:0.7}
.planner-side-item .psi-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}
.planner-side-item .psi-dot.task-dot{background:var(--accent)}
.planner-side-item .psi-dot.idea-dot{background:var(--warning)}
.planner-side-item .psi-title{flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.planner-side-item .psi-remove{background:none;border:none;cursor:pointer;width:20px;height:20px;display:flex;align-items:center;justify-content:center;border-radius:4px;opacity:0;transition:opacity 0.15s}
.planner-side-item:hover .psi-remove{opacity:1}
.planner-side-item .psi-remove:hover{background:var(--hover)}
.planner-side-item .psi-remove svg{width:12px;height:12px;stroke:var(--text-muted);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.planner-idea-input{width:100%;padding:7px 10px;border-radius:6px;border:1px solid var(--border);background:transparent;font-size:0.78rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s}
.planner-idea-input:focus{border-color:var(--accent)}
.planner-idea-input::placeholder{color:var(--text-muted)}
.planner-main{flex:1;display:flex;flex-direction:column;overflow:hidden}
.planner-controls{display:flex;align-items:center;justify-content:space-between;padding:12px 16px;border-bottom:1px solid var(--border);flex-shrink:0;flex-wrap:wrap;gap:8px;background:var(--nav-bg);transition:background 0.3s,border-color 0.3s}
.image-theme .planner-controls{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.planner-controls-left{display:flex;align-items:center;gap:8px}
.planner-controls-right{display:flex;align-items:center;gap:6px}
.planner-tab{padding:5px 12px;border-radius:6px;font-size:0.76rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:transparent;color:var(--text-muted);font-family:'Inter',sans-serif;transition:all 0.15s}
.planner-tab:hover{color:var(--text);border-color:var(--accent)}
.planner-tab.active{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.planner-nav-btn{background:none;border:1px solid var(--border);width:30px;height:30px;border-radius:6px;display:flex;align-items:center;justify-content:center;cursor:pointer;color:var(--text);font-size:0.8rem;transition:all 0.15s;font-family:'Inter',sans-serif}
.planner-nav-btn:hover{background:var(--hover);border-color:var(--accent)}
.planner-date-label{font-size:0.84rem;font-weight:600;color:var(--text);min-width:140px;text-align:center}
.planner-today-btn{padding:4px 10px;border-radius:6px;font-size:0.72rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:transparent;color:var(--text-muted);font-family:'Inter',sans-serif;transition:all 0.15s}
.planner-today-btn:hover{border-color:var(--accent);color:var(--text)}
.planner-expand-btn{background:none;border:1px solid var(--border);width:30px;height:30px;border-radius:6px;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:all 0.15s}
.planner-expand-btn:hover{background:var(--hover)}
.planner-expand-btn svg{width:16px;height:16px;stroke:var(--text-muted);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.time-grid{display:flex;position:relative;min-height:100%}
.time-labels{width:52px;flex-shrink:0;position:sticky;left:0;z-index:2;background:var(--bg);transition:background 0.3s}
.time-label{height:var(--hour-height);display:flex;align-items:flex-start;justify-content:flex-end;padding-right:8px;padding-top:0;font-size:0.65rem;color:var(--text-muted);transform:translateY(-7px)}
.time-columns{display:flex;flex:1;position:relative}
.time-col{flex:1;position:relative;border-left:1px solid var(--border);min-width:80px}
.time-col-header{position:sticky;top:0;z-index:3;text-align:center;padding:6px 4px;font-size:0.7rem;font-weight:600;color:var(--text-muted);background:var(--nav-bg);border-bottom:1px solid var(--border);transition:background 0.3s}
.time-col-header.today{color:var(--accent);background:var(--hover)}
.time-col-body{position:relative;height:calc(var(--hour-height) * 24)}
.time-row{position:absolute;left:0;right:0;border-top:1px solid var(--border);pointer-events:none}
.time-row.half{border-top:1px dashed rgba(128,128,128,0.15)}
.time-now-line{position:absolute;left:0;right:0;height:2px;background:var(--danger);z-index:5;pointer-events:none}
.time-now-dot{position:absolute;left:-4px;top:-3px;width:8px;height:8px;border-radius:50%;background:var(--danger)}
.pblock{position:absolute;left:3px;right:3px;border-radius:6px;padding:4px 7px;cursor:grab;overflow:hidden;z-index:4;transition:box-shadow 0.15s;font-size:0.72rem;min-height:16px;display:flex;flex-direction:column;user-select:none}
.pblock:hover{box-shadow:0 3px 10px rgba(0,0,0,0.12);z-index:6}
.pblock:active{cursor:grabbing}
.pblock-title{font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;line-height:1.3}
.pblock-time{font-size:0.62rem;opacity:0.8;white-space:nowrap}
.pblock-resize{position:absolute;bottom:0;left:0;right:0;height:6px;cursor:ns-resize;border-radius:0 0 6px 6px}
.pblock-actions{position:absolute;top:2px;right:2px;display:none;gap:1px}
.pblock:hover .pblock-actions{display:flex}
.pblock-act{width:18px;height:18px;border-radius:4px;display:flex;align-items:center;justify-content:center;cursor:pointer;background:rgba(255,255,255,0.4);backdrop-filter:blur(4px)}
.pblock-act:hover{background:rgba(255,255,255,0.7)}
.pblock-act svg{width:10px;height:10px;stroke:#333;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.pblock-blue{background:rgba(59,130,246,0.82);color:#fff}
.pblock-green{background:rgba(34,197,94,0.82);color:#fff}
.pblock-red{background:rgba(239,68,68,0.82);color:#fff}
.pblock-purple{background:rgba(139,92,246,0.82);color:#fff}
.pblock-orange{background:rgba(249,115,22,0.82);color:#fff}
.pblock-teal{background:rgba(20,184,166,0.82);color:#fff}
.pblock-pink{background:rgba(236,72,153,0.82);color:#fff}
.pblock-gray{background:rgba(107,114,128,0.82);color:#fff}
.month-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:1px;background:var(--border);border:1px solid var(--border);border-radius:10px;overflow:hidden}
.month-header-cell{padding:8px 4px;text-align:center;font-size:0.68rem;font-weight:600;color:var(--text-muted);background:var(--nav-bg);text-transform:uppercase;letter-spacing:0.08em}
.month-cell{min-height:88px;background:var(--nav-bg);padding:4px;cursor:pointer;transition:background 0.15s}
.month-cell:hover{background:var(--hover)}
.month-cell.other-month{opacity:0.4}
.month-cell.today{background:var(--hover)}
.month-day-num{font-size:0.72rem;font-weight:600;color:var(--text);margin-bottom:3px;padding:2px 4px}
.month-cell.today .month-day-num{background:var(--accent);color:var(--bg);border-radius:50%;width:22px;height:22px;display:flex;align-items:center;justify-content:center}
.month-block-preview{font-size:0.6rem;padding:2px 4px;border-radius:3px;margin-bottom:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#fff}
.month-more{font-size:0.6rem;color:var(--text-muted);padding:1px 4px}
.month-add-btn{display:none;margin-top:3px;font-size:0.58rem;color:var(--text-muted);cursor:pointer;padding:1px 4px;border-radius:3px;transition:background 0.1s}
.month-cell:hover .month-add-btn{display:block}
.month-add-btn:hover{background:var(--hover)}
.drop-indicator{position:absolute;left:3px;right:3px;height:20px;border-radius:4px;border:2px dashed var(--accent);opacity:0;pointer-events:none;transition:opacity 0.1s;z-index:10}
.drop-indicator.visible{opacity:1}
.planner-grid-wrap{flex:1;overflow:auto;position:relative}

/* ═══════════════════════════════════════
HABITS STYLES
═══════════════════════════════════════ */
.habits-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:24px;flex-wrap:wrap;gap:12px}
.habits-header h2{font-size:1.4rem;font-weight:600;color:var(--text)}
.habits-today-card{background:var(--nav-bg);border:1px solid var(--border);border-radius:14px;padding:20px;margin-bottom:28px;transition:background 0.3s,border-color 0.3s}
.image-theme .habits-today-card{backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.habits-today-label{font-size:0.7rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:14px}
.habits-today-progress{display:flex;align-items:center;gap:12px;margin-bottom:16px}
.habits-progress-bar{flex:1;height:6px;border-radius:3px;background:var(--border);overflow:hidden}
.habits-progress-fill{height:100%;border-radius:3px;background:var(--success);transition:width 0.4s ease}
.habits-progress-text{font-size:0.75rem;font-weight:600;color:var(--text-muted);white-space:nowrap}
.habit-row{display:flex;align-items:center;gap:12px;padding:12px 14px;border-radius:10px;margin-bottom:6px;background:var(--bg);border:1px solid var(--border);transition:all 0.15s}
.habit-row:hover{box-shadow:0 2px 8px rgba(0,0,0,0.05)}
.habit-row.done{opacity:0.6}
.habit-row.done .habit-name{text-decoration:line-through}
.habit-check{width:22px;height:22px;border-radius:6px;border:2px solid var(--border);cursor:pointer;flex-shrink:0;display:flex;align-items:center;justify-content:center;transition:all 0.2s}
.habit-check:hover{border-color:var(--success)}
.habit-check.checked{background:var(--success);border-color:var(--success)}
.habit-check.checked::after{content:'';width:6px;height:10px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg);margin-top:-2px}
.habit-icon{width:28px;height:28px;border-radius:8px;display:flex;align-items:center;justify-content:center;font-size:0.82rem;flex-shrink:0}
.habit-body{flex:1;min-width:0}
.habit-name{font-size:0.86rem;font-weight:500;color:var(--text)}
.habit-streak{display:flex;align-items:center;gap:4px;font-size:0.7rem;color:var(--text-muted);margin-top:2px}
.habit-streak .fire{color:var(--warning)}
.habit-actions{display:flex;gap:2px;opacity:0;transition:opacity 0.15s;flex-shrink:0}
.habit-row:hover .habit-actions{opacity:1}

/* Habits Calendar */
.habits-calendar-section{margin-top:32px}
.habits-cal-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:14px;flex-wrap:wrap;gap:8px}
.habits-cal-header-left{display:flex;align-items:center;gap:8px}
.habits-cal-title{font-size:0.92rem;font-weight:600;color:var(--text)}
.habits-cal-filter{display:flex;align-items:center;gap:4px;overflow-x:auto}
.habit-cal-chip{padding:4px 10px;border-radius:14px;font-size:0.7rem;font-weight:500;cursor:pointer;white-space:nowrap;border:1px solid var(--border);background:var(--nav-bg);color:var(--text-muted);transition:all 0.15s}
.habit-cal-chip:hover{border-color:var(--accent);color:var(--text)}
.habit-cal-chip.active{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.habits-cal-nav{display:flex;align-items:center;gap:6px}
.habits-cal-month{font-size:0.82rem;font-weight:600;color:var(--text);min-width:120px;text-align:center}
.habits-cal-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:2px;background:var(--nav-bg);border:1px solid var(--border);border-radius:12px;padding:10px;transition:background 0.3s,border-color 0.3s}
.image-theme .habits-cal-grid{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.hcal-header{text-align:center;font-size:0.62rem;font-weight:600;color:var(--text-muted);padding:4px 0;text-transform:uppercase;letter-spacing:0.06em}
.hcal-day{position:relative;aspect-ratio:1;display:flex;align-items:center;justify-content:center;border-radius:8px;font-size:0.7rem;color:var(--text-muted);cursor:default;transition:background 0.15s}
.hcal-day.other{opacity:0.3}
.hcal-day.today{font-weight:700;color:var(--accent)}
.hcal-day.today::after{content:'';position:absolute;bottom:2px;width:4px;height:4px;border-radius:50%;background:var(--accent)}
.hcal-day .hcal-fill{position:absolute;inset:3px;border-radius:6px;z-index:0;transition:opacity 0.2s}
.hcal-day .hcal-num{position:relative;z-index:1}
.hcal-fill.level-0{opacity:0}
.hcal-fill.level-1{background:var(--success);opacity:0.2}
.hcal-fill.level-2{background:var(--success);opacity:0.4}
.hcal-fill.level-3{background:var(--success);opacity:0.6}
.hcal-fill.level-4{background:var(--success);opacity:0.8}
.hcal-fill.level-full{background:var(--success);opacity:0.9}
.hcal-day.has-full .hcal-num{color:#fff}
.habits-legend{display:flex;align-items:center;gap:8px;margin-top:10px;justify-content:flex-end}
.habits-legend-label{font-size:0.62rem;color:var(--text-muted)}
.habits-legend-blocks{display:flex;gap:3px}
.habits-legend-block{width:14px;height:14px;border-radius:3px}
/* ═══════════════════════════════════════
JOURNAL STYLES
═══════════════════════════════════════ */
#page-journal.active{display:block;padding:0;max-width:none;margin:0}
.journal-wrap{display:flex;height:calc(100vh - 56px);overflow:hidden}
.journal-toc{width:280px;min-width:280px;border-right:1px solid var(--border);background:var(--nav-bg);display:flex;flex-direction:column;transition:background 0.3s,border-color 0.3s,margin-left 0.3s;overflow:hidden}
.image-theme .journal-toc{backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
.journal-toc.collapsed{margin-left:-280px}
.journal-toc-header{padding:14px 16px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--border);flex-shrink:0}
.journal-toc-header span{font-size:0.72rem;font-weight:600;letter-spacing:0.12em;text-transform:uppercase;color:var(--text-muted)}
.journal-toc-actions{display:flex;align-items:center;gap:4px}
.journal-toc-toggle{background:none;border:none;cursor:pointer;width:28px;height:28px;display:flex;align-items:center;justify-content:center;border-radius:6px;transition:background 0.15s}
.journal-toc-toggle:hover{background:var(--hover)}
.journal-toc-toggle svg{width:16px;height:16px;stroke:var(--text-muted);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.journal-search-wrap{padding:10px 12px;border-bottom:1px solid var(--border);flex-shrink:0}
.journal-search{width:100%;padding:7px 10px;border-radius:7px;border:1px solid var(--border);background:transparent;font-size:0.78rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s}
.journal-search:focus{border-color:var(--accent)}
.journal-search::placeholder{color:var(--text-muted)}
.journal-filter-row{padding:8px 12px;display:flex;gap:4px;overflow-x:auto;flex-shrink:0;border-bottom:1px solid var(--border)}
.journal-filter-chip{padding:3px 9px;border-radius:12px;font-size:0.68rem;font-weight:500;cursor:pointer;white-space:nowrap;border:1px solid var(--border);background:transparent;color:var(--text-muted);transition:all 0.15s;font-family:'Inter',sans-serif}
.journal-filter-chip:hover{border-color:var(--accent);color:var(--text)}
.journal-filter-chip.active{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.journal-toc-list{flex:1;overflow-y:auto;padding:8px}
.journal-toc-group{margin-bottom:12px}
.journal-toc-group-label{font-size:0.62rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);padding:4px 8px;margin-bottom:4px}
.journal-toc-item{display:flex;align-items:flex-start;gap:8px;padding:10px 10px;border-radius:8px;cursor:pointer;transition:background 0.15s;margin-bottom:2px}
.journal-toc-item:hover{background:var(--hover)}
.journal-toc-item.active{background:var(--hover);border-left:3px solid var(--accent)}
.journal-toc-item .jt-icon{width:8px;height:8px;border-radius:50%;flex-shrink:0;margin-top:5px}
.jt-icon.type-journal{background:var(--accent)}
.jt-icon.type-daily_log{background:var(--success)}
.jt-icon.type-pomodoro{background:var(--danger)}
.jt-icon.type-project_note{background:var(--warning)}
.journal-toc-item .jt-body{flex:1;min-width:0}
.journal-toc-item .jt-title{font-size:0.78rem;font-weight:500;color:var(--text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.journal-toc-item .jt-date{font-size:0.64rem;color:var(--text-muted);margin-top:2px}
.journal-toc-item .jt-pin{font-size:0.64rem;color:var(--warning)}
.journal-toc-empty{padding:24px 12px;text-align:center;font-size:0.78rem;color:var(--text-muted)}
.journal-main{flex:1;display:flex;flex-direction:column;overflow:hidden}
.journal-main-toolbar{display:flex;align-items:center;justify-content:space-between;padding:10px 16px;border-bottom:1px solid var(--border);flex-shrink:0;gap:8px;background:var(--nav-bg);transition:background 0.3s,border-color 0.3s}
.image-theme .journal-main-toolbar{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.journal-toolbar-left{display:flex;align-items:center;gap:8px}
.journal-toolbar-right{display:flex;align-items:center;gap:6px}
.journal-expand-btn{background:none;border:1px solid var(--border);width:30px;height:30px;border-radius:6px;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:all 0.15s}
.journal-expand-btn:hover{background:var(--hover)}
.journal-expand-btn svg{width:16px;height:16px;stroke:var(--text-muted);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.journal-main-body{flex:1;overflow-y:auto;padding:28px 32px;max-width:760px;margin:0 auto;width:100%}
.journal-empty-state{display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;color:var(--text-muted);gap:12px;padding:40px}
.journal-empty-state svg{width:48px;height:48px;stroke:var(--border);stroke-width:1;fill:none;stroke-linecap:round;stroke-linejoin:round}
.journal-empty-state p{font-size:0.88rem}
.journal-entry-view{display:none}
.journal-entry-view.active{display:block}
.journal-entry-header{margin-bottom:24px;padding-bottom:16px;border-bottom:1px solid var(--border)}
.journal-entry-title-input{width:100%;font-size:1.5rem;font-weight:700;color:var(--text);border:none;background:transparent;outline:none;font-family:'Inter',sans-serif;padding:0;margin-bottom:8px}
.journal-entry-title-input::placeholder{color:var(--text-muted)}
.journal-entry-meta{display:flex;align-items:center;gap:12px;flex-wrap:wrap;font-size:0.72rem;color:var(--text-muted)}
.journal-entry-meta .je-type-badge{padding:2px 8px;border-radius:10px;font-size:0.66rem;font-weight:600;text-transform:uppercase;letter-spacing:0.06em}
.je-type-badge.type-journal{background:rgba(100,100,100,0.1);color:var(--accent)}
.je-type-badge.type-daily_log{background:rgba(40,167,69,0.1);color:var(--success)}
.je-type-badge.type-pomodoro{background:rgba(220,53,69,0.1);color:var(--danger)}
.je-type-badge.type-project_note{background:rgba(245,158,11,0.1);color:var(--warning)}
.journal-goal-section{margin-bottom:20px}
.journal-goal-label{font-size:0.7rem;font-weight:600;letter-spacing:0.08em;text-transform:uppercase;color:var(--text-muted);margin-bottom:6px}
.journal-goal-input{width:100%;padding:10px 12px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.84rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s;resize:none;min-height:40px}
.journal-goal-input:focus{border-color:var(--accent)}
.journal-goal-input::placeholder{color:var(--text-muted)}
.journal-content-section{margin-top:4px}
.journal-content-label{font-size:0.7rem;font-weight:600;letter-spacing:0.08em;text-transform:uppercase;color:var(--text-muted);margin-bottom:6px}
.journal-content-input{width:100%;padding:14px 16px;border-radius:10px;border:1px solid var(--border);background:transparent;font-size:0.86rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s;resize:vertical;min-height:260px;line-height:1.7}
.journal-content-input:focus{border-color:var(--accent)}
.journal-content-input::placeholder{color:var(--text-muted)}
.journal-save-status{font-size:0.68rem;color:var(--text-muted);padding:4px 8px;border-radius:4px;transition:all 0.3s}
.journal-save-status.saving{color:var(--warning)}
.journal-save-status.saved{color:var(--success)}
@media(max-width:700px){
.journal-toc{position:fixed;top:56px;left:0;bottom:0;z-index:50;width:280px;min-width:280px;box-shadow:4px 0 16px rgba(0,0,0,0.1)}
.journal-toc.collapsed{margin-left:0;left:-280px}
.journal-main-body{padding:20px 16px}
}
/* ═══════════════════════════════════════
POMODORO STYLES
═══════════════════════════════════════ */
#page-pomodoro.active{display:block;padding:0;max-width:none;margin:0}
.pomo-page{max-width:680px;margin:0 auto;padding:28px 20px}
.pomo-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:24px}
.pomo-header h2{font-size:1.4rem;font-weight:600;color:var(--text)}
.pomo-header-right{display:flex;align-items:center;gap:8px}
.pomo-focus-btn{display:inline-flex;align-items:center;gap:6px;padding:7px 14px;border-radius:8px;font-size:0.78rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:var(--nav-bg);color:var(--text);font-family:'Inter',sans-serif;transition:all 0.15s}
.pomo-focus-btn:hover{border-color:var(--accent);background:var(--hover)}
.pomo-focus-btn svg{width:14px;height:14px;stroke:currentColor;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.pomo-presets{display:flex;align-items:center;justify-content:center;gap:6px;margin-bottom:24px;flex-wrap:wrap}
.pomo-preset{padding:6px 14px;border-radius:20px;font-size:0.76rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:transparent;color:var(--text-muted);font-family:'Inter',sans-serif;transition:all 0.15s}
.pomo-preset:hover{border-color:var(--accent);color:var(--text)}
.pomo-preset.active{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.pomo-timer-wrap{display:flex;flex-direction:column;align-items:center;margin-bottom:24px}
.pomo-timer-ring{position:relative;width:240px;height:240px;margin-bottom:16px}
.pomo-timer-svg{width:100%;height:100%;transform:rotate(-90deg)}
.pomo-ring-bg{fill:none;stroke:var(--border);stroke-width:8}
.pomo-ring-progress{fill:none;stroke:var(--accent);stroke-width:8;stroke-linecap:round;transition:stroke-dashoffset 0.5s linear,stroke 0.3s}
.pomo-ring-progress.on-break{stroke:var(--success)}
.pomo-timer-center{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center}
.pomo-timer-time{font-size:3rem;font-weight:700;color:var(--text);font-variant-numeric:tabular-nums;letter-spacing:-0.02em}
.pomo-timer-label{font-size:0.76rem;font-weight:500;color:var(--text-muted);text-transform:uppercase;letter-spacing:0.1em;margin-top:4px}
.pomo-cycles{display:flex;align-items:center;justify-content:center;gap:8px;margin-bottom:20px;flex-wrap:wrap}
.pomo-cycle{font-size:1.3rem;opacity:0.3;transition:opacity 0.3s,transform 0.2s}
.pomo-cycle.done{opacity:1;transform:scale(1.1)}
.pomo-cycle.current{opacity:0.7;animation:pomo-pulse 1.5s ease infinite}
@keyframes pomo-pulse{0%,100%{transform:scale(1)}50%{transform:scale(1.2)}}
.pomo-add-cycle{width:28px;height:28px;border-radius:50%;border:1px dashed var(--border);background:transparent;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all 0.15s;font-size:0.7rem;color:var(--text-muted)}
.pomo-add-cycle:hover{border-color:var(--accent);color:var(--accent)}
.pomo-controls{display:flex;align-items:center;justify-content:center;gap:10px;margin-bottom:28px}
.pomo-ctrl-btn{width:44px;height:44px;border-radius:50%;border:1px solid var(--border);background:var(--nav-bg);cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all 0.15s}
.pomo-ctrl-btn:hover{background:var(--hover);border-color:var(--accent)}
.pomo-ctrl-btn svg{width:18px;height:18px;stroke:var(--text);stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.pomo-ctrl-btn.primary{width:56px;height:56px;background:var(--accent);border-color:var(--accent)}
.pomo-ctrl-btn.primary svg{stroke:var(--bg);width:22px;height:22px}
.pomo-ctrl-btn.primary:hover{opacity:0.85}
.pomo-projects-section{margin-bottom:24px;padding:16px;border-radius:12px;background:var(--nav-bg);border:1px solid var(--border);transition:background 0.3s,border-color 0.3s}
.image-theme .pomo-projects-section{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.pomo-section-label{font-size:0.7rem;font-weight:600;letter-spacing:0.1em;text-transform:uppercase;color:var(--text-muted);margin-bottom:10px}
.pomo-project-chips{display:flex;flex-wrap:wrap;gap:6px}
.pomo-project-chip{padding:5px 12px;border-radius:16px;font-size:0.74rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:transparent;color:var(--text-muted);font-family:'Inter',sans-serif;transition:all 0.15s}
.pomo-project-chip:hover{border-color:var(--accent);color:var(--text)}
.pomo-project-chip.selected{background:var(--accent);color:var(--bg);border-color:var(--accent)}
.pomo-notes-section{margin-bottom:28px;padding:16px;border-radius:12px;background:var(--nav-bg);border:1px solid var(--border);transition:background 0.3s,border-color 0.3s}
.image-theme .pomo-notes-section{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.pomo-notes-input{width:100%;padding:10px 12px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.82rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s;resize:vertical;min-height:60px;line-height:1.6}
.pomo-notes-input:focus{border-color:var(--accent)}
.pomo-notes-input::placeholder{color:var(--text-muted)}
.pomo-stats-row{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-bottom:24px}
.pomo-stat-card{padding:14px;border-radius:10px;background:var(--nav-bg);border:1px solid var(--border);text-align:center;transition:background 0.3s,border-color 0.3s}
.image-theme .pomo-stat-card{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.pomo-stat-num{font-size:1.5rem;font-weight:700;color:var(--text)}
.pomo-stat-label{font-size:0.68rem;color:var(--text-muted);margin-top:2px;text-transform:uppercase;letter-spacing:0.06em}
.pomo-streak-card{display:flex;align-items:center;gap:16px;padding:16px 20px;border-radius:12px;background:var(--nav-bg);border:1px solid var(--border);margin-bottom:24px;transition:background 0.3s,border-color 0.3s}
.image-theme .pomo-streak-card{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.pomo-streak-fire{font-size:1.8rem}
.pomo-streak-info{flex:1}
.pomo-streak-num{font-size:1.3rem;font-weight:700;color:var(--text)}
.pomo-streak-sub{font-size:0.72rem;color:var(--text-muted)}
.pomo-calendar-section{margin-top:24px}
.pomo-cal-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}
.pomo-cal-title{font-size:0.88rem;font-weight:600;color:var(--text)}
.pomo-cal-nav{display:flex;align-items:center;gap:6px}
.pomo-cal-month{font-size:0.8rem;font-weight:600;color:var(--text);min-width:110px;text-align:center}
.pomo-cal-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:2px;background:var(--nav-bg);border:1px solid var(--border);border-radius:12px;padding:10px;transition:background 0.3s,border-color 0.3s}
.image-theme .pomo-cal-grid{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.pcal-header{text-align:center;font-size:0.62rem;font-weight:600;color:var(--text-muted);padding:4px 0;text-transform:uppercase;letter-spacing:0.06em}
.pcal-day{position:relative;aspect-ratio:1;display:flex;align-items:center;justify-content:center;border-radius:8px;font-size:0.7rem;color:var(--text-muted);cursor:default;transition:background 0.15s}
.pcal-day.other{opacity:0.3}
.pcal-day.today{font-weight:700;color:var(--accent)}
.pcal-day.today::after{content:'';position:absolute;bottom:2px;width:4px;height:4px;border-radius:50%;background:var(--accent)}
.pcal-day .pcal-fill{position:absolute;inset:3px;border-radius:6px;z-index:0;transition:opacity 0.2s}
.pcal-day .pcal-num{position:relative;z-index:1}
.pcal-fill.plvl-0{opacity:0}
.pcal-fill.plvl-1{background:var(--danger);opacity:0.2}
.pcal-fill.plvl-2{background:var(--danger);opacity:0.4}
.pcal-fill.plvl-3{background:var(--danger);opacity:0.6}
.pcal-fill.plvl-4{background:var(--danger);opacity:0.85}
.pcal-day.has-pomo .pcal-num{color:#fff}
/* Focus mode */
.pomo-focus-overlay{position:fixed;inset:0;z-index:400;background:var(--bg);display:none;flex-direction:column;overflow-y:auto;transition:background 0.3s}
.pomo-focus-overlay.active{display:flex}
.pomo-focus-bar{display:flex;align-items:center;justify-content:space-between;padding:14px 20px;border-bottom:1px solid var(--border);flex-shrink:0}
.pomo-focus-bar-left{display:flex;align-items:center;gap:10px}
.pomo-focus-bar-title{font-size:0.88rem;font-weight:600;color:var(--text)}
.pomo-focus-exit{padding:6px 12px;border-radius:6px;font-size:0.76rem;font-weight:500;cursor:pointer;border:1px solid var(--border);background:transparent;color:var(--text);font-family:'Inter',sans-serif;transition:all 0.15s}
.pomo-focus-exit:hover{background:var(--hover);border-color:var(--accent)}
.pomo-focus-body{flex:1;display:flex;max-width:1100px;width:100%;margin:0 auto;padding:28px 20px;gap:32px}
.pomo-focus-left{flex:1;display:flex;flex-direction:column;align-items:center;gap:20px}
.pomo-focus-right{width:320px;display:flex;flex-direction:column;gap:16px}
.pomo-focus-tasks-card{background:var(--nav-bg);border:1px solid var(--border);border-radius:12px;padding:14px;flex:1;overflow-y:auto;transition:background 0.3s,border-color 0.3s}
.pomo-focus-task-item{display:flex;align-items:center;gap:10px;padding:8px 10px;border-radius:8px;margin-bottom:4px;cursor:pointer;transition:background 0.15s}
.pomo-focus-task-item:hover{background:var(--hover)}
.pomo-focus-task-item .pft-check{width:18px;height:18px;border-radius:50%;border:2px solid var(--border);flex-shrink:0;display:flex;align-items:center;justify-content:center;transition:all 0.2s}
.pomo-focus-task-item .pft-check.checked{background:var(--success);border-color:var(--success)}
.pomo-focus-task-item .pft-check.checked::after{content:'';width:5px;height:8px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg);margin-top:-1px}
.pomo-focus-task-item .pft-check.highlighted{border-color:var(--warning)}
.pomo-focus-task-item.highlighted{background:rgba(245,158,11,0.08);border:1px solid rgba(245,158,11,0.2)}
.pomo-focus-task-title{font-size:0.82rem;color:var(--text);flex:1}
.pomo-focus-task-title.completed-text{text-decoration:line-through;opacity:0.5}
.pomo-focus-highlight-btn{width:20px;height:20px;border-radius:4px;border:none;background:transparent;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:0.7rem;opacity:0.4;transition:opacity 0.15s}
.pomo-focus-highlight-btn:hover{opacity:1}
.pomo-focus-highlight-btn.active{opacity:1}
.pomo-focus-notes-card{background:var(--nav-bg);border:1px solid var(--border);border-radius:12px;padding:14px;transition:background 0.3s,border-color 0.3s}
.pomo-focus-notes-card textarea{width:100%;min-height:100px;padding:10px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.82rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;resize:vertical;line-height:1.6;transition:border-color 0.2s}
.pomo-focus-notes-card textarea:focus{border-color:var(--accent)}
.pomo-focus-notes-card textarea::placeholder{color:var(--text-muted)}
.pomo-custom-row{display:flex;align-items:center;justify-content:center;gap:10px;margin-bottom:16px}
.pomo-custom-input{width:60px;padding:6px 8px;border-radius:6px;border:1px solid var(--border);background:transparent;font-size:0.82rem;font-family:'Inter',sans-serif;color:var(--text);text-align:center;outline:none;transition:border-color 0.2s}
.pomo-custom-input:focus{border-color:var(--accent)}
.pomo-custom-label{font-size:0.72rem;color:var(--text-muted)}
.pomo-custom-sep{font-size:0.82rem;color:var(--text-muted)}
@media(max-width:700px){
.pomo-focus-body{flex-direction:column;gap:20px}
.pomo-focus-right{width:100%}
.pomo-stats-row{grid-template-columns:1fr}
.pomo-timer-ring{width:200px;height:200px}
.pomo-timer-time{font-size:2.4rem}
}
/* ═══════════════════════════════════════
PROJECT PAGE STYLES
═══════════════════════════════════════ */
.proj-page{max-width:720px;margin:0 auto}
.proj-title{font-size:1.6rem;font-weight:700;color:var(--text);margin-bottom:6px}
.proj-subtitle{font-size:0.78rem;color:var(--text-muted);margin-bottom:28px}
.proj-section{margin-bottom:32px}
.proj-section-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:14px}
.proj-section-title{font-size:0.92rem;font-weight:600;color:var(--text)}
.proj-section-count{font-size:0.7rem;color:var(--text-muted);margin-left:8px}
.proj-goal-card{background:var(--nav-bg);border:1px solid var(--border);border-radius:12px;padding:14px 16px;margin-bottom:8px;transition:background 0.3s,border-color 0.3s}
.image-theme .proj-goal-card{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}
.proj-goal-card:hover{box-shadow:0 2px 8px rgba(0,0,0,0.05)}
.proj-goal-top{display:flex;align-items:flex-start;gap:10px;margin-bottom:10px}
.proj-goal-body{flex:1;min-width:0}
.proj-goal-title{font-size:0.86rem;font-weight:500;color:var(--text);word-break:break-word}
.proj-goal-due{font-size:0.68rem;color:var(--text-muted);margin-top:3px;display:flex;align-items:center;gap:4px}
.proj-goal-due svg{width:10px;height:10px;stroke:currentColor;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round}
.proj-goal-due.overdue{color:var(--danger)}
.proj-goal-actions{display:flex;gap:2px;opacity:0;transition:opacity 0.15s;flex-shrink:0}
.proj-goal-card:hover .proj-goal-actions{opacity:1}
.proj-goal-progress-row{display:flex;align-items:center;gap:10px}
.proj-goal-bar{flex:1;height:6px;border-radius:3px;background:var(--border);overflow:hidden;cursor:pointer;position:relative}
.proj-goal-bar-fill{height:100%;border-radius:3px;background:var(--success);transition:width 0.3s}
.proj-goal-percent{font-size:0.7rem;font-weight:600;color:var(--text-muted);min-width:32px;text-align:right}
.proj-goal-empty{text-align:center;padding:20px;color:var(--text-muted);font-size:0.82rem;border:1px dashed var(--border);border-radius:10px}
.proj-tasks-list .task-card{margin-bottom:6px}
.proj-tasks-empty{text-align:center;padding:20px;color:var(--text-muted);font-size:0.82rem;border:1px dashed var(--border);border-radius:10px}
.proj-notes-input-wrap{display:flex;gap:8px;margin-bottom:14px}
.proj-notes-input{flex:1;padding:10px 12px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.82rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s;resize:none;min-height:40px}
.proj-notes-input:focus{border-color:var(--accent)}
.proj-notes-input::placeholder{color:var(--text-muted)}
.proj-notes-list{display:flex;flex-direction:column;gap:6px}
.proj-note-card{display:flex;align-items:flex-start;gap:10px;padding:10px 12px;border-radius:8px;background:var(--nav-bg);border:1px solid var(--border);transition:all 0.15s;cursor:pointer}
.image-theme .proj-note-card{backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px)}
.proj-note-card:hover{box-shadow:0 2px 6px rgba(0,0,0,0.05)}
.proj-note-icon{width:8px;height:8px;border-radius:50%;background:var(--warning);flex-shrink:0;margin-top:5px}
.proj-note-body{flex:1;min-width:0}
.proj-note-title{font-size:0.8rem;font-weight:500;color:var(--text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.proj-note-date{font-size:0.66rem;color:var(--text-muted);margin-top:2px}
.proj-pomo-card{display:flex;align-items:center;gap:12px;padding:12px 14px;border-radius:10px;background:var(--nav-bg);border:1px solid var(--border);margin-bottom:6px;transition:all 0.15s}
.image-theme .proj-pomo-card{backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px)}
.proj-pomo-icon{font-size:1.1rem}
.proj-pomo-body{flex:1;min-width:0}
.proj-pomo-title{font-size:0.82rem;font-weight:500;color:var(--text)}
.proj-pomo-meta{font-size:0.68rem;color:var(--text-muted);margin-top:2px}
.proj-pomo-empty{text-align:center;padding:20px;color:var(--text-muted);font-size:0.82rem;border:1px dashed var(--border);border-radius:10px}
@media(max-width:600px){
.proj-goal-actions{opacity:1}
}/* ═══════════════════════════════════════
   DAILY STACK — PLANNER PAGE REDESIGN
   ═══════════════════════════════════════ */
#page-daily-stack { max-width: 880px; padding: 24px 20px; }
.ds-planner-page { position: relative; }

/* Theme decorative accents */
.ds-planner-page::before {
  content: '';
  position: absolute;
  top: -12px; right: -12px;
  width: 80px; height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  opacity: 0.04;
  pointer-events: none;
}

/* Pink theme special */
[data-theme-active="pink"] .ds-planner-page::before {
  opacity: 0.08;
  background: radial-gradient(circle, #e0508a 0%, transparent 70%);
}
[data-theme-active="pink"] .ds-card {
  border-color: rgba(224, 80, 138, 0.15);
}
[data-theme-active="pink"] .ds-card-icon {
  color: #e0508a;
}
[data-theme-active="pink"] .ds-priorities-card { border-left: 3px solid rgba(224, 80, 138, 0.3); }
[data-theme-active="pink"] .ds-schedule-card { border-left: 3px solid rgba(224, 80, 138, 0.2); }

/* Ddeonghwa theme */
[data-theme-active="ddeonghwa"] .ds-card {
  border-color: rgba(176, 136, 48, 0.18);
}
[data-theme-active="ddeonghwa"] .ds-planner-page::before {
  opacity: 0.06;
  background: radial-gradient(circle, #c4a050 0%, transparent 70%);
}
[data-theme-active="ddeonghwa"] .ds-priorities-card { border-left: 3px solid rgba(200, 165, 90, 0.35); }
[data-theme-active="ddeonghwa"] .ds-header-left .ds-date-big { color: #c4a050; }

/* Convenience theme */
[data-theme-active="convenience"] .ds-card {
  border-color: rgba(37, 99, 235, 0.12);
}
[data-theme-active="convenience"] .ds-planner-page::before {
  opacity: 0.06;
  background: radial-gradient(circle, #2563eb 0%, transparent 70%);
}
[data-theme-active="convenience"] .ds-priorities-card { border-left: 3px solid rgba(59, 130, 246, 0.3); }

/* Ghibli theme */
[data-theme-active="ghibli"] .ds-card {
  border-color: rgba(50, 136, 56, 0.14);
}
[data-theme-active="ghibli"] .ds-planner-page::before {
  opacity: 0.06;
  background: radial-gradient(circle, #328838 0%, transparent 70%);
}
[data-theme-active="ghibli"] .ds-priorities-card { border-left: 3px solid rgba(50, 136, 56, 0.3); }

/* Modern theme — ultra clean */
[data-theme-active="modern"] .ds-planner-page::before { display: none; }
[data-theme-active="modern"] .ds-card { border-radius: 8px; }

/* ── Header ── */
.ds-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
  gap: 16px;
}
.ds-header-left { flex: 1; }
.ds-date-big {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.ds-date-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.ds-header-right { flex-shrink: 0; }
.ds-weather-mini {
  background: var(--nav-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 14px;
  min-width: 130px;
  transition: background 0.3s, border-color 0.3s;
}
.image-theme .ds-weather-mini { backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.ds-weather-mini .ds-wm-row { display: flex; align-items: center; gap: 8px; }
.ds-wm-icon { font-size: 1.4rem; }
.ds-wm-temp { font-size: 1.2rem; font-weight: 700; color: var(--text); }
.ds-wm-detail { font-size: 0.66rem; color: var(--text-muted); margin-top: 3px; }
.ds-weather-loading { font-size: 0.72rem; color: var(--text-muted); }

/* ── Quote Strip ── */
.ds-quote-strip {
  font-size: 0.76rem;
  color: var(--text-muted);
  font-style: italic;
  padding: 8px 0;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
  line-height: 1.5;
}
.ds-quote-strip .ds-qs-author {
  font-style: normal;
  font-weight: 500;
  opacity: 0.7;
}

/* ── Quick Tabs Bar ── */
.ds-quicktabs-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  padding: 8px 0;
  overflow-x: auto;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}
.ds-quicktabs-scroll {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  overflow-x: auto;
  padding-bottom: 2px;
}
.ds-quicktab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: 9px;
  font-size: 0.74rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--text);
  background: var(--nav-bg);
  border: 1px solid var(--border);
  transition: all 0.15s;
  white-space: nowrap;
  position: relative;
  flex-shrink: 0;
}
.image-theme .ds-quicktab { backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.ds-quicktab:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.ds-quicktab-del {
  position: absolute;
  top: -5px; right: -5px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--danger);
  color: #fff;
  font-size: 0.55rem;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  line-height: 1;
}
.ds-quicktab:hover .ds-quicktab-del { display: flex; }
.ds-quicktab-add-btn {
  width: 30px; height: 30px;
  border-radius: 8px;
  border: 1px dashed var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  flex-shrink: 0;
}
.ds-quicktab-add-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--hover);
}

/* ── Columns ── */
.ds-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 20px;
}

/* ── Cards ── */
.ds-card {
  background: var(--nav-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 14px;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.2s;
}
.image-theme .ds-card { backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.ds-card:hover { box-shadow: 0 2px 12px rgba(0,0,0,0.04); }
.ds-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.ds-card-icon { font-size: 0.92rem; }
.ds-card-title {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.ds-card-badge {
  margin-left: auto;
  font-size: 0.66rem;
  padding: 2px 7px;
  border-radius: 10px;
  background: var(--hover);
  color: var(--text-muted);
  font-weight: 600;
}
.ds-card-badge.ds-badge-danger { background: rgba(220,53,69,0.1); color: var(--danger); }
.ds-card-action-btn {
  margin-left: auto;
  width: 24px; height: 24px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.82rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}
.ds-card-action-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--hover); }

/* ── Priorities ── */
.ds-priorities-list { display: flex; flex-direction: column; gap: 6px; }
.ds-priority-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s;
}
.ds-priority-item:hover { background: var(--hover); }
.ds-priority-num {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg);
  font-size: 0.64rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.ds-priority-item.completed .ds-priority-num { background: var(--success); }
.ds-priority-item.completed .ds-priority-text { text-decoration: line-through; opacity: 0.5; }
.ds-priority-text {
  flex: 1;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
}
.ds-priority-del {
  width: 18px; height: 18px;
  border-radius: 4px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  transition: color 0.15s;
}
.ds-priority-item:hover .ds-priority-del { display: flex; }
.ds-priority-del:hover { color: var(--danger); }
.ds-priority-add-row { margin-top: 6px; }
.ds-inline-input {
  width: 100%;
  padding: 7px 10px;
  border-radius: 7px;
  border: 1px solid transparent;
  background: transparent;
  font-size: 0.78rem;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}
.ds-inline-input:focus {
  border-color: var(--border);
  background: var(--hover);
}
.ds-inline-input::placeholder { color: var(--text-muted); }

/* ── Tasks in DS ── */
.ds-tasks-list { display: flex; flex-direction: column; gap: 3px; max-height: 240px; overflow-y: auto; }
.ds2-task-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 8px;
  transition: background 0.15s;
}
.ds2-task-item:hover { background: var(--hover); }
.ds2-task-check {
  width: 17px; height: 17px;
  border-radius: 50%;
  border: 2px solid var(--border);
  cursor: pointer;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.ds2-task-check:hover { border-color: var(--success); }
.ds2-task-check.checked { background: var(--success); border-color: var(--success); }
.ds2-task-check.checked::after {
  content: '';
  width: 5px; height: 8px;
  border: solid #fff;
  border-width: 0 1.8px 1.8px 0;
  transform: rotate(45deg);
  margin-top: -1px;
}
.ds2-task-item.completed .ds2-task-name { text-decoration: line-through; opacity: 0.45; }
.ds2-task-name { flex: 1; font-size: 0.8rem; color: var(--text); }
.ds2-task-tag {
  font-size: 0.6rem;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--hover);
  color: var(--text-muted);
}
.ds-task-add-row { margin-top: 8px; }

/* ── Habits Grid ── */
.ds-habits-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}
.ds2-habit-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border-radius: 8px;
  transition: background 0.15s;
  cursor: pointer;
}
.ds2-habit-item:hover { background: var(--hover); }
.ds2-habit-item.done { opacity: 0.5; }
.ds2-habit-item.done .ds2-habit-name { text-decoration: line-through; }
.ds2-habit-check {
  width: 16px; height: 16px;
  border-radius: 4px;
  border: 2px solid var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.ds2-habit-check.checked { background: var(--success); border-color: var(--success); }
.ds2-habit-check.checked::after {
  content: '';
  width: 4px; height: 7px;
  border: solid #fff;
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(45deg);
  margin-top: -1px;
}
.ds2-habit-icon { font-size: 0.78rem; }
.ds2-habit-name { font-size: 0.74rem; color: var(--text); }

/* ── Mini Schedule ── */
.ds-mini-schedule {
  max-height: 320px;
  overflow-y: auto;
  position: relative;
}
.ds-sched-empty {
  text-align: center;
  padding: 20px 10px;
  font-size: 0.76rem;
  color: var(--text-muted);
}
.ds-sched-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  margin-bottom: 4px;
  transition: background 0.15s;
}
.ds-sched-item:hover { background: var(--hover); }
.ds-sched-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 4px;
}
.ds-sched-body { flex: 1; min-width: 0; }
.ds-sched-title { font-size: 0.8rem; font-weight: 500; color: var(--text); }
.ds-sched-time { font-size: 0.66rem; color: var(--text-muted); margin-top: 1px; }
.ds-sched-now {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  margin-bottom: 6px;
}
.ds-sched-now-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--danger); animation: ds-pulse 2s infinite; }
.ds-sched-now-label { font-size: 0.64rem; font-weight: 600; color: var(--danger); text-transform: uppercase; letter-spacing: 0.06em; }
@keyframes ds-pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ── Notes ── */
.ds-notes-textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  font-size: 0.8rem;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
  resize: vertical;
  min-height: 120px;
  line-height: 1.7;
}
.ds-notes-textarea:focus { border-color: var(--accent); }
.ds-notes-textarea::placeholder { color: var(--text-muted); }

/* ── Books ── */
.ds-books-list2 { display: flex; flex-direction: column; gap: 3px; }
.ds-book-item2 {
  font-size: 0.76rem;
  color: var(--text);
  padding: 3px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ds-book-item2::before { content: '·'; color: var(--text-muted); font-weight: 700; }
.ds-books-empty2 { font-size: 0.72rem; color: var(--text-muted); font-style: italic; }

/* ── Footer ── */
.ds-footer-row {
  display: flex;
  justify-content: center;
  padding: 8px 0;
}

/* ── Responsive ── */
@media(max-width: 700px) {
  .ds-columns { grid-template-columns: 1fr; }
  .ds-header-row { flex-direction: column; gap: 12px; }
  .ds-habits-grid { grid-template-columns: 1fr; }
  .ds-quicktabs-bar { flex-wrap: nowrap; }
}
/* ═══════════════════════════════════════
MODALS
═══════════════════════════════════════ */
.modal-overlay{position:fixed;inset:0;background:var(--overlay);z-index:500;display:none;align-items:center;justify-content:center;padding:20px}
.modal-overlay.active{display:flex}
.modal{background:var(--nav-bg);border:1px solid var(--border);border-radius:16px;width:100%;max-width:420px;padding:28px;box-shadow:0 16px 48px rgba(0,0,0,0.15);transition:background 0.3s,border-color 0.3s}
.image-theme .modal{backdrop-filter:blur(24px);-webkit-backdrop-filter:blur(24px)}
.modal-title{font-size:1.1rem;font-weight:600;margin-bottom:20px;color:var(--text)}
.modal p{font-size:0.88rem;color:var(--text-muted);margin-bottom:8px}
.form-group{margin-bottom:16px}
.form-group label{display:block;font-size:0.75rem;font-weight:500;color:var(--text-muted);margin-bottom:6px;letter-spacing:0.04em}
.form-input{width:100%;padding:10px 12px;border-radius:8px;border:1px solid var(--border);background:transparent;font-size:0.88rem;font-family:'Inter',sans-serif;color:var(--text);outline:none;transition:border-color 0.2s}
.form-input:focus{border-color:var(--accent)}
.form-input::placeholder{color:var(--text-muted)}
textarea.form-input{resize:vertical;min-height:60px}
select.form-input{appearance:none;-webkit-appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 12px center;padding-right:32px}
.form-row{display:flex;gap:10px}
.form-row .form-group{flex:1}
.color-picker-row{display:flex;gap:6px;flex-wrap:wrap}
.color-swatch{width:26px;height:26px;border-radius:50%;cursor:pointer;border:2px solid transparent;transition:transform 0.15s,border-color 0.15s}
.color-swatch:hover{transform:scale(1.15)}
.color-swatch.active{border-color:var(--text);transform:scale(1.15)}
.modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:24px}
::-webkit-scrollbar{width:6px;height:6px}
::-webkit-scrollbar-track{background:transparent}
::-webkit-scrollbar-thumb{background:var(--border);border-radius:3px}
@media(max-width:600px){
.planner-side{position:fixed;top:56px;left:0;bottom:0;z-index:50;width:280px;min-width:280px;box-shadow:4px 0 16px rgba(0,0,0,0.1)}
.planner-side.collapsed{margin-left:0;left:-280px}
.tasks-overview{flex-direction:column;text-align:center}
.history-tally{flex-direction:column;text-align:center}
.task-actions,.history-actions,.habit-actions{opacity:1}
.history-search-row{flex-direction:column}
.history-search{width:100%}
.planner-controls{padding:8px 10px;flex-wrap:wrap}
.planner-date-label{min-width:auto;font-size:0.7rem}
.planner-wrap{flex-direction:column}
.planner-main{height:calc(100vh - 56px)}
.time-columns{overflow-x:auto;-webkit-overflow-scrolling:touch}
.time-col{min-width:120px}
.pblock{min-height:28px;padding:8px 10px}
.pblock-actions{display:flex}
.pblock-resize{height:12px}
.planner-mobile-add{
position:fixed;bottom:20px;right:20px;
width:48px;height:48px;border-radius:50%;
background:var(--accent);color:var(--bg);
z-index:50;display:flex;align-items:center;
justify-content:center;box-shadow:0 4px 12px rgba(0,0,0,0.2);
border:none;cursor:pointer;
}
}
/* ═══════════════════════════════════════
BULK ADD TASKS
═══════════════════════════════════════ */
.bulk-format-help{margin-bottom:16px;padding:12px 14px;border-radius:10px;background:var(--hover);border:1px solid var(--border)}
.bulk-format-label{font-size:0.72rem;font-weight:600;color:var(--text-muted);margin-bottom:6px;text-transform:uppercase;letter-spacing:0.06em}
.bulk-format-example{display:block;font-size:0.78rem;color:var(--text);padding:6px 10px;background:var(--nav-bg);border-radius:6px;border:1px solid var(--border);margin-bottom:8px;font-family:'SF Mono','Fira Code',monospace}
.bulk-format-details{display:flex;flex-direction:column;gap:3px}
.bulk-format-details span{font-size:0.68rem;color:var(--text-muted)}
.bulk-format-details strong{color:var(--text);font-weight:600}
.bulk-preview{max-height:160px;overflow-y:auto;margin-bottom:8px}
.bulk-preview-item{display:flex;align-items:center;gap:8px;padding:6px 10px;border-radius:6px;margin-bottom:3px;background:var(--hover);font-size:0.76rem}
.bulk-preview-item .bp-title{flex:1;color:var(--text);font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.bulk-preview-item .bp-tag{font-size:0.64rem;padding:2px 6px;border-radius:8px;background:var(--nav-bg);color:var(--text-muted);border:1px solid var(--border)}
.bulk-preview-item .bp-date{font-size:0.64rem;color:var(--text-muted)}
.bulk-preview-item .bp-desc{font-size:0.62rem;color:var(--text-muted);font-style:italic;max-width:100px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.bulk-preview-item.bp-error{border:1px solid var(--danger);background:rgba(220,53,69,0.05)}
.bulk-preview-item.bp-error .bp-title{color:var(--danger)}
.bulk-count{font-size:0.72rem;color:var(--text-muted);margin-right:auto}
#bulk-task-input{font-family:'SF Mono','Fira Code','Inter',monospace;font-size:0.8rem;line-height:1.7;min-height:140px}


.ds-greeting-card {
background: var(--nav-bg);
border: 1px solid var(--border);
border-radius: 14px;
padding: 20px;
flex: 1;
min-width: 0;
transition: background 0.3s, border-color 0.3s;
}
.image-theme .ds-greeting-card {
backdrop-filter: blur(14px);
-webkit-backdrop-filter: blur(14px);
}

/* Bulk Schedule */
#bulk-schedule-input {
font-family: 'SF Mono', 'Fira Code', 'Inter', monospace;
font-size: 0.8rem;
line-height: 1.7;
min-height: 140px;
}
/* Journal Formatting Toolbar */
.journal-format-toolbar {
display: flex;
align-items: center;
gap: 2px;
padding: 6px 8px;
border: 1px solid var(--border);
border-bottom: none;
border-radius: 10px 10px 0 0;
background: var(--hover);
flex-wrap: wrap;
transition: background 0.3s, border-color 0.3s;
}

.jfmt-btn {
width: 30px;
height: 28px;
border: none;
background: transparent;
border-radius: 5px;
cursor: pointer;
display: flex;
align-items: center;
justify-content: center;
font-size: 0.78rem;
color: var(--text-muted);
font-family: 'Inter', sans-serif;
transition: all 0.15s;
}

.jfmt-btn:hover {
background: var(--nav-bg);
color: var(--text);
}

.jfmt-btn.active {
background: var(--accent);
color: var(--bg);
}

.jfmt-sep {
width: 1px;
height: 18px;
background: var(--border);
margin: 0 4px;
}

.journal-content-editable {
width: 100%;
padding: 14px 16px;
border-radius: 0 0 10px 10px;
border: 1px solid var(--border);
background: transparent;
font-size: 0.86rem;
font-family: 'Inter', sans-serif;
color: var(--text);
outline: none;
transition: border-color 0.2s;
min-height: 260px;
line-height: 1.7;
overflow-y: auto;
max-height: 600px;
}

.journal-content-editable:focus {
border-color: var(--accent);
}

.journal-content-editable:empty::before {
content: attr(placeholder);
color: var(--text-muted);
pointer-events: none;
}

.journal-content-editable h2 {
font-size: 1.2rem;
font-weight: 700;
margin: 12px 0 6px;
color: var(--text);
}

.journal-content-editable h3 {
font-size: 1rem;
font-weight: 600;
margin: 10px 0 4px;
color: var(--text);
}

.journal-content-editable blockquote {
border-left: 3px solid var(--accent);
padding-left: 12px;
margin: 8px 0;
color: var(--text-muted);
font-style: italic;
}

.journal-content-editable pre {
background: var(--hover);
border: 1px solid var(--border);
border-radius: 6px;
padding: 10px 12px;
font-family: 'SF Mono', 'Fira Code', monospace;
font-size: 0.8rem;
overflow-x: auto;
margin: 8px 0;
}

.journal-content-editable ul,
.journal-content-editable ol {
padding-left: 20px;
margin: 6px 0;
}

.journal-content-editable li {
margin-bottom: 3px;
}

/* ═══════════════════════════════════════
SPLIT SCREEN
═══════════════════════════════════════ */
.split-container { display: flex; height: calc(100vh - 56px); }
.split-container.split-mode .split-left { width: 50%; border-right: 1px solid var(--border); overflow-y: auto; }
.split-container.split-mode .split-right { display: block; width: 50%; overflow-y: auto; }
.split-container:not(.split-mode) .split-left { width: 100%; }
.split-container.split-mode .page { max-width: none; }
@media (max-width: 900px) {
  .split-container.split-mode .split-left { width: 100%; }
  .split-container.split-mode .split-right { display: none; }
  #split-btn { display: none; }
}

/* ═══════════════════════════════════════
GOALS PAGE
═══════════════════════════════════════ */
#page-goals.active { display: block; max-width: 800px; }
.goals-wrap { padding: 0; }
.goals-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.goals-header h2 { font-size: 1.4rem; font-weight: 600; color: var(--text); }
.goals-tabs { display: flex; gap: 4px; margin-bottom: 16px; overflow-x: auto; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.goals-tab { padding: 7px 14px; border-radius: 8px 8px 0 0; font-size: 0.78rem; font-weight: 500; cursor: pointer; border: 1px solid var(--border); border-bottom: none; background: transparent; color: var(--text-muted); font-family: 'Inter', sans-serif; transition: all 0.15s; white-space: nowrap; }
.goals-tab:hover { color: var(--text); background: var(--hover); }
.goals-tab.active { background: var(--nav-bg); color: var(--text); border-color: var(--accent); }
.goals-title-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.goals-tab-title-input { flex: 1; font-size: 1.3rem; font-weight: 700; color: var(--text); border: none; background: transparent; outline: none; font-family: 'Inter', sans-serif; }
.goals-content-editable { width: 100%; padding: 14px 16px; border-radius: 0 0 10px 10px; border: 1px solid var(--border); background: transparent; font-size: 0.86rem; font-family: 'Inter', sans-serif; color: var(--text); outline: none; min-height: 400px; line-height: 1.7; overflow-y: auto; }
.goals-content-editable:focus { border-color: var(--accent); }
.goals-content-editable:empty::before { content: attr(placeholder); color: var(--text-muted); pointer-events: none; }
.goals-content-editable table { width: 100%; border-collapse: collapse; margin: 12px 0; }
.goals-content-editable th, .goals-content-editable td { border: 1px solid var(--border); padding: 8px 10px; font-size: 0.82rem; text-align: left; }
.goals-content-editable th { background: var(--hover); font-weight: 600; }
.goals-format-toolbar {
display: flex;
align-items: center;
gap: 2px;
padding: 6px 8px;
border: 1px solid var(--border);
border-bottom: none;
border-radius: 10px 10px 0 0;
background: var(--hover);
flex-wrap: wrap;
transition: background 0.3s, border-color 0.3s;
}