/* Time Champ Scheduling - additions on top of the shared Time Champ base styles */
.grid.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.grid.g-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.grid.g-21 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; }
.grid.g-12 { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 16px; }
.stack-16 { display: flex; flex-direction: column; gap: 16px; }
.row-gap { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ok-t { color: var(--ok); font-weight: 600; } .warn-t { color: var(--warn); font-weight: 600; } .bad-t { color: var(--bad); font-weight: 600; }

/* header week switcher */
.wk { display: inline-flex; border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; background: var(--panel); }
.wk button { font: inherit; font-size: 12.5px; font-weight: 650; border: 0; background: none; padding: 5px 12px; cursor: pointer; color: var(--ink-2); display: flex; flex-direction: column; align-items: center; line-height: 1.2; }
.wk button small { font-size: 10.5px; font-weight: 500; color: var(--ink-3); }
.wk button + button { border-left: 1px solid var(--line-2); }
.wk button.on { background: var(--tc); color: #fff; }
.wk button.on small { color: #DCE4FF; }
.wk-meta { font-size: 12px; color: var(--ink-2); }
.ai-btn { background: linear-gradient(135deg, #0030DB, #7A3FD1); border: 0; }
.ai-btn:hover { background: linear-gradient(135deg, #2B55E8, #8B5CF6); }
button:disabled { opacity: .5; cursor: default; }

/* shift bars and gantt */
.sbar { position: relative; height: 22px; border-radius: 5px; background: #F3F5FA; overflow: hidden; }
.sbar.empty { background: repeating-linear-gradient(135deg, #F7F8FB 0 6px, #F1F3F8 6px 12px); }
.sb { position: absolute; top: 0; bottom: 0; display: flex; align-items: center; overflow: hidden; }
.sb span { font-size: 10px; font-weight: 650; color: #fff; padding: 0 4px; white-space: nowrap; text-shadow: 0 0 2px rgba(0,0,0,.25); }
.sb-break, .sb-lunch { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.35) 0 3px, transparent 3px 6px); }
.sb-break span, .sb-lunch span { color: #5B3B00; text-shadow: none; }
.sb-leave { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.45) 0 4px, transparent 4px 8px); }
.sb-gap { background: transparent !important; }
.sb-ot { box-shadow: inset 0 0 0 2px #0E1630; }
.sb-lock, .sb-note { position: absolute; right: 3px; top: 3px; font-style: normal; font-size: 10px; line-height: 1; z-index: 2; }
.sb-note { right: 16px; color: #0E1630; }
.lv-tag { position: absolute; inset: 0; display: grid; place-items: center; font-size: 11px; font-weight: 600; color: #475569; }
.t-axis { position: relative; height: 16px; margin-bottom: 2px; }
.t-axis span { position: absolute; transform: translateX(-50%); font-size: 10.5px; color: var(--ink-3); white-space: nowrap; }
.adot { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.lg { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 11.5px; color: var(--ink-2); margin-top: 8px; }
.emp-days { display: flex; flex-direction: column; gap: 6px; }
.emp-day { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 10px; align-items: center; }
.emp-day .ed-l b { display: block; font-size: 12.5px; font-weight: 600; }
.emp-day .ed-l small { color: var(--ink-3); font-size: 11px; }
.mini-kpis .kv { font-size: 20px; }
.kvlist { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; }
.kvlist div { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px dashed var(--line); padding-bottom: 4px; }
.kvlist span { color: var(--ink-3); }
.skill-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; font-size: 12.5px; padding: 3px 0; }
.skill-row .adot { display: none; }
.stars { color: #E8A317; letter-spacing: 1px; font-size: 12px; white-space: nowrap; }
.stars i { color: #D9DEE8; font-style: normal; }
.emp-link { color: var(--ink); font-weight: 550; border-bottom: 1px dotted var(--line-2); }
.emp-link:hover { color: var(--tc); border-bottom-color: var(--tc); }
.tbl tr.click { cursor: pointer; }
.tbl th.sortable { cursor: pointer; user-select: none; }
.tbl th.sortable:hover { color: var(--ink); }
.tbl tfoot td { border-top: 2px solid var(--line-2); background: var(--panel-2); }
.more-btn { margin-top: 8px; }

/* forms */
.f-form { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
.f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.f .inp { width: 100%; background-image: none; }
.f textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--line-2); border-radius: 8px; }
.inp.plain { background-image: none; padding-right: 10px; min-width: 0; }

/* alerts list */
.alerts { display: flex; flex-direction: column; gap: 8px; }
.al { display: grid; grid-template-columns: 4px minmax(0, 1fr) auto; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px 10px 0; background: var(--panel); overflow: hidden; }
.al > i { align-self: stretch; border-radius: 0 3px 3px 0; }
.al.bad > i { background: var(--bad); } .al.warn > i { background: #E8A317; } .al.info > i { background: var(--info); } .al.ok > i { background: var(--ok); }
.al b { font-size: 13px; } .al p { margin: 1px 0 0; font-size: 12.5px; color: var(--ink-2); }

/* workflow stepper */
.flow { display: flex; align-items: center; gap: 0; flex-wrap: wrap; }
.flow .st { display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; font-size: 12.5px; font-weight: 600; color: var(--ink-3); }
.flow .st i { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 11px; background: #EEF1F6; color: var(--ink-3); }
.flow .st.done i { background: var(--ok); color: #fff; } .flow .st.done { color: var(--ink-2); }
.flow .st.cur i { background: var(--tc); color: #fff; box-shadow: 0 0 0 4px var(--tc-bg); } .flow .st.cur { color: var(--ink); }
.flow .st.mod i { background: var(--bad); color: #fff; }
.flow .ln { width: 26px; height: 2px; background: var(--line-2); }

/* chat */
.chat { display: flex; flex-direction: column; gap: 12px; }
.msg { max-width: 88%; padding: 10px 14px; border-radius: 12px; font-size: 13.5px; line-height: 1.55; }
.msg.me { align-self: flex-end; background: var(--tc); color: #fff; border-bottom-right-radius: 4px; }
.msg.ai { align-self: flex-start; background: var(--panel); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.msg.ai ul { margin: 6px 0; padding-left: 18px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { font: inherit; font-size: 12px; border: 1px solid var(--line-2); background: var(--panel); border-radius: 16px; padding: 4px 10px; cursor: pointer; color: var(--ink-2); }
.chip:hover { border-color: var(--tc); color: var(--tc); }
.chip.on { background: var(--tc-bg); border-color: var(--tc); color: var(--tc-ink); }

/* phone frame (self-service portal) */
.phone { width: 380px; max-width: 100%; border: 10px solid #0E1630; border-radius: 34px; background: var(--bg); overflow: hidden; box-shadow: 0 18px 40px rgba(14,22,48,.18); }
.phone .ph-top { background: var(--tc); color: #fff; padding: 14px 16px 12px; }
.phone .ph-body { padding: 12px; display: flex; flex-direction: column; gap: 10px; max-height: 660px; overflow-y: auto; }

.splash { position: fixed; inset: 0; display: grid; place-items: center; background: var(--bg); z-index: 90; font-weight: 600; color: var(--ink-2); }
.splash i { display: block; width: 36px; height: 36px; border: 3px solid var(--tc-bg); border-top-color: var(--tc); border-radius: 50%; margin: 0 auto 12px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
#view.static *, #view.static *::before { animation: none !important; }
#view.static .ch-line { stroke-dashoffset: 0; }
#view.static .ch-area, #view.static .ch-dash { opacity: 1; }

@media (max-width: 1180px) { .grid.g-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grid.g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid.g-21, .grid.g-12 { grid-template-columns: minmax(0, 1fr); } .wk-meta { display: none; } }
@media (max-width: 640px) { .grid.g-6, .grid.g-4 { grid-template-columns: minmax(0, 1fr); } .emp-day { grid-template-columns: 96px minmax(0, 1fr); } .top .who, .top .avatar { display: none; } .wk button small { display: none; } }
