/* The schedule's day plan. The day bar (.tabs / .tab) and the notes page keep the old
   schedule's look from chrome.css; everything here is the new, larger layout. */

#schedulePage{--hr:64px;}

/* ---------- header ---------- */
.sched-head{
  display:flex; flex-wrap:wrap; align-items:center; gap:12px 24px;
  padding:14px 18px;
  background:var(--bg-tabbar); border-bottom:1px solid var(--border);
}
.sched-day{
  font-family:var(--font-display); font-weight:var(--type-weight); font-size:40px; line-height:.95;
  color:var(--green-bright); text-shadow:0 0 10px var(--glow); text-transform:lowercase;
}
.sched-day small{display:block; margin-top:4px; font-family:var(--font); font-size:12.5px; color:var(--text-dim); text-shadow:none; text-transform:none;}
.sched-clock{display:flex; flex-direction:column; gap:2px; font-size:12px; color:var(--text-dim);}
.sched-clock b{font-family:var(--font-display); font-weight:var(--type-weight); font-size:28px; line-height:1; color:var(--string, var(--green-bright)); text-shadow:0 0 8px var(--glow);}
.sched-progress{flex:1 1 220px; display:flex; flex-direction:column; gap:6px; min-width:0;}
.sched-progress-label{display:flex; justify-content:space-between; font-size:12.5px; color:var(--text-dim);}
.sched-progress-label b{font-weight:400; color:var(--green);}
.sched-track{position:relative; height:10px; background:var(--border-soft);}
.sched-fill{position:absolute; inset:0 auto 0 0; width:0; background:var(--done, var(--green)); box-shadow:0 0 8px var(--glow); transition:width .3s ease;}
.sched-tools{display:flex; flex-wrap:wrap; gap:8px 14px; align-items:center;}
.sched-tools .loadout-inline{padding-left:0; border-left:0; flex:0 1 auto; font-size:12px;}
.loadout-sq{
  width:16px; height:16px; border-radius:3px; padding:0; cursor:pointer;
  border:1px solid var(--sq); background:color-mix(in srgb, var(--sq) 40%, transparent);
}
.loadout-sq:hover{background:color-mix(in srgb, var(--sq) 65%, transparent);}
.loadout-sq.is-active{background:var(--sq);}
.loadout-add{background:none; border:0; font-family:var(--font); font-size:14px; padding:0 4px;}
.loadout-delete.is-armed{color:var(--red-fail); border-color:var(--red-fail);}

/* ---------- day bar: same as before, now buttons ---------- */
#tabs .tab{border:0; border-right:1px solid var(--border); font-family:inherit; font-size:12.5px;}
#tabs .tab:focus-visible{outline:1px solid var(--green); outline-offset:-3px;}

/* ---------- body ---------- */
.sched-body{display:grid; grid-template-columns:minmax(0,1fr) minmax(280px,360px);}
.timeline-wrap{padding:16px 18px 20px; border-right:1px solid var(--border); min-width:0;}
.timeline-head{display:flex; flex-wrap:wrap; align-items:baseline; gap:6px 12px; margin-bottom:10px;}
.timeline-head h3{margin:0; font-family:var(--font-display); font-weight:var(--type-weight); font-size:26px; line-height:1; color:var(--green-bright);}
.timeline-head span{font-size:12.5px; color:var(--text-dim);}
.sched-solid{margin-left:auto;}
.sched-solid[aria-pressed="true"]{color:var(--green-bright); background:var(--hover-focus);}
.sched-hint{margin:0 0 12px; padding:10px 12px; border:1px dashed var(--line); color:var(--text-body); font-size:13px;}
.sched-hint[hidden]{display:none;}

.hour-btn{
  font-family:var(--font); font-size:12.5px;
  padding:4px 10px; cursor:pointer;
  background:none; border:1px solid var(--line); color:var(--green-dim);
}
.hour-btn:hover{color:var(--green-bright); border-color:var(--green-dim);}
.hour-btn:disabled{opacity:.4; cursor:default;}
.hour-more{display:flex; flex-wrap:wrap; gap:6px; margin:0 0 16px 84px;}
.hour-more.is-end{margin:10px 0 0 84px;}

.timeline{position:relative; display:grid; grid-template-columns:84px minmax(0,1fr);}
.timeline-hours{display:flex; flex-direction:column;}
.timeline-hours span{
  position:relative; height:var(--hr);
  padding-right:12px; text-align:right; white-space:nowrap;
  transform:translateY(-10px);
  font-family:var(--font-display); font-weight:var(--type-weight); font-size:22px; line-height:1;
  color:var(--green-bright); text-shadow:0 0 6px var(--glow);
  font-variant-numeric:tabular-nums;
}
.timeline-hours span::after{
  content:attr(data-half);
  position:absolute; right:12px; top:calc(50% + 2px);
  font-family:var(--font); font-size:12px; color:var(--green-dim); text-shadow:none;
}
html[data-theme-name]:not([data-theme-name="matrix"]) .timeline-hours span{font-family:var(--font);}
.timeline-slots{position:relative; border-left:1px solid var(--border);}
.slot{position:relative; height:var(--hr); border-top:1px solid var(--line); cursor:copy;}
.slot::after{content:""; position:absolute; left:0; right:0; top:50%; border-top:1px dashed var(--border-soft);}
.slot:hover{background:var(--hover-soft);}
.slot:hover::before{content:"+ click to add an activity"; position:absolute; left:12px; top:8px; font-size:12px; color:var(--text-dim);}
.drop-ghost{position:absolute; left:6px; right:6px; z-index:1; pointer-events:none; padding:4px 8px; font-size:12px; color:var(--green); border:1px dashed var(--green); background:var(--hover-focus);}
.drop-ghost[hidden]{display:none;}
.now-line{position:absolute; left:0; right:0; z-index:30; pointer-events:none; border-top:2px solid #FFC24D;}
.now-line::before{content:"now"; position:absolute; left:-46px; top:-10px; padding:0 4px; font-size:11px; color:#FFC24D; background:var(--void);}

/* blocks */
.blk{
  position:absolute; z-index:2; min-height:28px; overflow:hidden;
  display:flex; flex-direction:column; gap:3px;
  padding:7px 10px 10px;
  border:1px solid var(--green-dim);
  background:color-mix(in srgb, var(--green) 16%, transparent);
  cursor:grab;
}
.blk.is-card{background:var(--card-fill); border-left:4px solid var(--cyan);}
.timeline-slots.is-solid .blk{background:linear-gradient(color-mix(in srgb, var(--green) 16%, transparent), color-mix(in srgb, var(--green) 16%, transparent)), var(--void);}
.timeline-slots.is-solid .blk.is-card{background:linear-gradient(var(--card-fill), var(--card-fill)), var(--void);}
.blk.is-lifted{box-shadow:-6px 6px 14px var(--overlay), 0 0 0 1px var(--void);}
.blk:hover,.blk:focus-within,.blk:focus{z-index:60 !important; border-color:var(--green); box-shadow:0 8px 22px var(--overlay), 0 0 0 1px var(--green);}
.blk:focus-visible{outline:none;}
.blk.is-dragging{opacity:.4;}
.blk.is-done{opacity:.55;}
.blk.is-done .blk-title{text-decoration:line-through;}
.blk-top{display:flex; align-items:center; gap:8px; min-width:0;}
.blk.is-narrow .blk-top{flex-wrap:wrap;}
.blk.is-narrow .blk-when{flex-basis:100%; order:3;}
.blk-title{flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:15px; color:var(--text-body); outline:none;}
.blk-title[contenteditable]{cursor:text;}
.blk-title[contenteditable]:focus{white-space:normal; background:var(--hover-focus);}
.blk-when{font-size:14px; color:var(--green-bright); white-space:nowrap; font-variant-numeric:tabular-nums;}
.blk-src{font-size:11.5px; color:var(--text-dim);}
.blk-check{width:16px; height:16px; flex:none; display:grid; place-items:center; padding:0; background:none; border:1px solid var(--green-dim); color:var(--green); font-size:11px; cursor:pointer;}
.blk-tools{display:flex; gap:2px; opacity:0;}
.blk:hover .blk-tools,.blk:focus-within .blk-tools,.blk:focus .blk-tools{opacity:1;}
.blk-tools button{background:none; border:0; padding:0 3px; color:var(--text-dim); font-size:12px; cursor:pointer;}
.blk-tools button:hover{color:var(--green-bright);}
.blk-tools [data-remove]:hover{color:var(--red-fail);}
.blk-resize{position:absolute; left:0; right:0; bottom:0; height:8px; cursor:ns-resize;}
.blk-resize::after{content:""; position:absolute; left:50%; bottom:2px; width:28px; margin-left:-14px; border-top:2px solid var(--line);}
.blk:hover .blk-resize::after{border-color:var(--green-dim);}
@media (hover:none){ .blk-tools{opacity:1;} }

/* side: cards from the boards, to-dos */
.sched-side{display:flex; flex-direction:column; min-width:0;}
.side-sec{display:flex; flex-direction:column; gap:10px; padding:16px 18px; border-bottom:1px solid var(--border);}
.side-sec h3{display:flex; justify-content:space-between; align-items:baseline; margin:0; font-family:var(--font-display); font-weight:var(--type-weight); font-size:24px; line-height:1; color:var(--green-bright);}
.side-sec h3 span{font-family:var(--font); font-size:12px; color:var(--text-dim);}
.side-sec > p,.sched-empty{margin:0; font-size:12.5px; color:var(--text-dim);}
.tray{display:flex; flex-direction:column; gap:8px;}
.tray-group{margin-top:4px; font-size:11.5px; letter-spacing:.08em; text-transform:uppercase; color:var(--text-dim);}
.tray-card{display:flex; align-items:center; gap:10px; padding:9px 10px; border:1px solid var(--border-soft); background:var(--card-fill); cursor:grab; user-select:none;}
.tray-card:hover{border-color:var(--green-dim);}
.tray-card.is-placed{opacity:.65;}
.tray-title{flex:1; min-width:0; font-size:14px; color:var(--text-body); overflow-wrap:anywhere;}
.tray-title small{display:block; font-size:11.5px; color:var(--text-dim);}
.tray-card.is-placed .tray-title small{color:var(--text-me);}
.tray-today{font-family:var(--font); font-size:12px; padding:2px 8px; white-space:nowrap; background:none; border:1px solid var(--line); color:var(--green-dim); cursor:pointer;}
.tray-today:hover{color:var(--green-bright); border-color:var(--green-dim);}
#todoList{display:flex; flex-direction:column; gap:6px;}
.todo-row{display:flex; align-items:center; gap:10px; font-size:14px; color:var(--text-body);}
.todo-row.is-done .todo-text{color:var(--text-dim); text-decoration:line-through;}
.todo-text{flex:1; min-width:0; outline:none; overflow-wrap:anywhere;}
.todo-text:focus{background:var(--hover-focus);}
.todo-x{background:none; border:0; color:var(--text-dim); cursor:pointer; font-size:15px;}
.todo-x:hover{color:var(--red-fail);}
.todo-add{display:flex; gap:6px;}
.todo-add input{flex:1; min-width:0; font-family:var(--font); font-size:13px; color:var(--text-body); background:var(--panel-input); border:1px solid var(--line); padding:6px 8px;}
#schedulePage footer{margin:0; padding:12px 16px; border-top:1px solid var(--border); font-size:12px;}

@media (max-width:900px){
  .sched-body{grid-template-columns:1fr;}
  .timeline-wrap{border-right:0; border-bottom:1px solid var(--border);}
}
@media (max-width:760px){
  .timeline{grid-template-columns:58px minmax(0,1fr);}
  .hour-more,.hour-more.is-end{margin-left:58px;}
  .now-line::before{left:-40px;}
  .timeline-hours span{font-size:18px;}
}
