/* schedule.css — notebook-tab schedule screen (classes prefixed sch2-) */
.sch2-panel .pbody { display: flex; flex-direction: row; align-items: stretch; overflow: hidden; padding: 6px 6px 0 6px; }
.sch2-panel .pfoot { padding-top: 2px; gap: 8px; }
.sch2-panel .pfoot .btn { min-height: 50px; border-width: 12px; border-image-width: 12px; font-size: 19px; padding: 0 4px; }
.sch2-panel .pfoot .btn.primary { min-height: 54px; font-size: 21px; }
.sch2-cwrap { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; }
.sch2-count { text-align: center; font: 900 17px/1.2 var(--font); color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.sch2-keys { font: 700 12px/1.1 var(--font); color: var(--ink-soft); opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }

/* vertical index tabs */
.sch2-tabs { flex: none; width: 130px; box-sizing: border-box; display: flex; flex-direction: column; gap: 6px; padding: 8px 0 8px; margin-bottom: 4px;
  overflow-x: hidden; overflow-y: auto; scrollbar-width: none; touch-action: pan-y; -webkit-overflow-scrolling: touch; min-height: 0; }
.sch2-tabs::-webkit-scrollbar { display: none; }
.sch2-tab { position: relative; flex: none; display: flex; align-items: center; gap: 5px; box-sizing: border-box; width: calc(100% - 12px); min-height: 66px; padding: 4px 6px 9px 6px;
  border: 0; border-radius: 16px 0 0 16px; background: #f1dfcd; color: var(--ink-soft); font: 800 14px/1.1 var(--font); text-align: left; cursor: pointer;
  outline: none; -webkit-tap-highlight-color: transparent; transition: transform .12s, filter .12s, background .12s, margin .12s, width .12s; opacity: .92; }
.sch2-tab .face { flex: none; width: 36px; height: 36px; border-radius: 12px; pointer-events: none; }
.sch2-tab .nm { flex: 1; min-width: 0; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-height: 1.12; word-break: normal; overflow-wrap: anywhere; padding-right: 10px; }
.sch2-tab .bar2 { position: absolute; left: 8px; right: 10px; bottom: 3px; height: 4px; border-radius: 3px; background: var(--kc, #9a9aa6); }
.sch2-tab .bang { display: none; position: absolute; right: 4px; top: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--coral); color: #fff;
  font: 900 14px/20px var(--font); text-align: center; font-style: normal; animation: schPulse 1.6s ease-in-out infinite; }
.sch2-tab.un .bang { display: block; }
.sch2-tab.un .bar2 { opacity: .35; }
.sch2-tab.on { margin-left: 6px; width: calc(100% - 6px); background: var(--cream, #fff8ee); color: var(--ink); font-size: 15px; opacity: 1; box-shadow: inset 5px 0 0 var(--coral); }
.sch2-tab.on .nm { color: var(--ink); }
.sch2-tab.focus { filter: brightness(1.06); outline: 3px solid var(--mint-d, #3fa592); outline-offset: -3px; }
.sch2-tab:active { transform: scale(.96); }

/* the page the selected tab joins */
.sch2-page { flex: 1; min-width: 0; min-height: 0; display: flex; gap: 6px; box-sizing: border-box; padding: 6px; margin-bottom: 4px; background: var(--cream, #fff8ee);
  border-radius: 0 18px 18px 18px; box-shadow: 0 3px 10px rgba(74,47,63,.2); }
.sch2-card { flex: none; width: 194px; box-sizing: border-box; padding: 6px 10px; border-radius: 16px; background: rgba(255,255,255,.85); border: 2px solid var(--peach);
  font: 800 15px/1.2 var(--font); display: flex; flex-direction: column; gap: 2px; min-height: 0; overflow-y: auto; scrollbar-width: thin; }
.sch2-card > * { flex: none; }
.sch2-top { order: 0; display: flex; gap: 8px; align-items: center; }
.sch2-pill { order: 1; }
.sch2-st { order: 2; }
.sch2-st.sta { order: 3; }
.sch2-meta { order: 4; }
.sch2-drink { order: 5; }
.sch2-pic { flex: none; width: 54px; height: 70px; border-radius: 12px; overflow: hidden; background: linear-gradient(160deg, var(--peach), var(--mint)); box-shadow: inset 0 0 0 2px #fff; }
.sch2-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sch2-who { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.sch2-name { font: 900 19px/1.15 var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sch2-who .badge { line-height: 20px; font-size: 15px; }
.sch2-sm { font: 700 14px/1.15 var(--font); color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sch2-who .sch2-sm:last-child { display: none; }
.sch2-st { display: flex; align-items: center; gap: 6px; height: 18px; }
.sch2-st > span { flex: none; width: 56px; font: 800 14px/1 var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sch2-st .bar { flex: 1; height: 9px; }
.sch2-st > b { flex: none; width: 30px; text-align: right; font: 900 16px/1 var(--font); }
.sch2-st.spec > span { color: #d0881a; }
.sch2-meta { display: flex; justify-content: space-between; align-items: center; font: 900 15px/1.2 var(--font); }
.sch2-meta .bd { color: #e0517a; }
.sch2-pill { display: flex; align-items: center; gap: 6px; box-sizing: border-box; min-height: 34px; padding: 2px 12px 2px 6px; border-radius: 20px; background: var(--kc); color: #fff;
  font: 900 17px/1.15 var(--font); text-shadow: 0 1px 0 rgba(0,0,0,.3); border: 2px solid #fff; box-shadow: 0 2px 0 rgba(74,47,63,.25); margin: 2px 0; }
.sch2-pill img { width: 24px; height: 24px; object-fit: contain; flex: none; }
.sch2-pill span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sch2-pill.none { flex-direction: column; align-items: flex-start; gap: 0; background: #fff; color: var(--coral); text-shadow: none; border: 2px dashed var(--coral); padding: 2px 12px; }
.sch2-pill.none small { font: 700 14px/1.15 var(--font); color: var(--ink-soft); max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sch2-drink { margin-top: 4px; min-height: 48px; width: 100%; }

.sch2-right { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.sch2-seg { flex: none; display: flex; gap: 4px; padding: 3px; border-radius: 28px; background: rgba(74,47,63,.12); }
.sch2-sg { flex: 1; min-height: 62px; min-width: 66px; border: 0; border-radius: 24px; background: transparent; color: var(--ink); font: 900 17px/1 var(--font); cursor: pointer; outline: none;
  -webkit-tap-highlight-color: transparent; transition: transform .12s, filter .12s; }
.sch2-sg.on { color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.3); }
.sch2-sg.lesson.on { background: #5b9bff; } .sch2-sg.job.on { background: #ff9f43; } .sch2-sg.promo.on { background: #ff6fae; }
.sch2-sg:active { transform: scale(.94); }
.sch2-grid { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-auto-rows: min-content; gap: 6px; align-content: start; padding: 4px; touch-action: pan-y; }
.sch2-grid.one { grid-template-columns: minmax(0, 1fr); }   /* when a number row cannot fit half the width */
.sch2-grid.one .sch2-act { height: 58px; }

/* one-line chips */
.sch2-act { position: relative; box-sizing: border-box; height: 66px; min-width: 0; padding: 4px 5px 4px 11px; display: flex; flex-direction: column; justify-content: center; align-items: stretch; gap: 3px; text-align: left;
  border-radius: 14px; border: 2px solid var(--bc, #ccc); background: var(--bg, #fff); color: var(--ink); font: 800 16px/1.15 var(--font); cursor: pointer; outline: none; overflow: hidden;
  -webkit-tap-highlight-color: transparent; transition: transform .12s, filter .12s; }
.sch2-act::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--kc); }
.sch2-act:active { transform: scale(.96); }
.sch2-act.c-lesson { --bc: #a9c9ff; --bg: #eef4ff; --kc: #5b9bff; }
.sch2-act.c-job { --bc: #ffcf9f; --bg: #fff4e8; --kc: #ff9f43; }
.sch2-act.c-promo { --bc: #ffb6d6; --bg: #fff0f7; --kc: #ff6fae; }
.sch2-act.c-rest { --bc: #c9c9d2; --bg: #f4f4f7; --kc: #9a9aa6; }
.sch2-act.on { border-color: var(--kc); box-shadow: 0 0 0 3px var(--kc), 0 3px 0 rgba(74,47,63,.2); background: #fff; }
.sch2-act.carry { border-style: dashed; border-color: var(--kc); }
.sch2-act.locked { background: #ece6e6; border-color: #c9bec2; color: #9a8a92; filter: grayscale(1); cursor: default; }
.sch2-ah { display: flex; align-items: center; gap: 5px; min-width: 0; }
.sch2-ah img { width: 22px; height: 22px; object-fit: contain; flex: none; }
.sch2-ah .an { flex: 1; min-width: 0; font: 900 16px/1.15 var(--font); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sch2-ah .ck { flex: none; width: 20px; height: 20px; border-radius: 50%; background: var(--kc); color: #fff; font: 900 13px/20px var(--font); text-align: center; font-style: normal; }
.sch2-nums { display: flex; align-items: center; gap: 5px; white-space: nowrap; overflow: hidden; font: 800 14px/1.2 var(--font); }
.sch2-nums .n { flex: none; }
.sch2-nums em { font-style: normal; color: var(--ink); border-bottom: 2px solid #ccc; margin-right: 1px; }
.sch2-nums .gain { color: #2e9e5b; }
.sch2-nums .loss { color: #d9534f; }
.sch2-nums .sta { color: #e8a33d; }
.sch2-nums .sta.up, .sch2-nums .up { color: #2e9e5b; }
.sch2-nums .pay { color: #b07d12; }
.sch2-nums .cost { color: #b0585e; }
.sch2-nums .fan { color: #e0517a; }
.sch2-nums .lk { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: #d9534f; }
.sch2-empty { margin: auto; text-align: center; font: 800 22px/1.4 var(--font); display: flex; flex-direction: column; gap: 14px; align-items: center; }
@keyframes schPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(255,122,107,.45); } 50% { box-shadow: 0 0 0 5px rgba(255,122,107,0); } }

/* estimate panel extras */
.estpanel .est-pay { color: var(--coral); font-weight: 900; }
.estpanel .est-short { margin-top: 4px; font: 900 13px/1.25 var(--font); color: #e0362c; }
