/* DrainBrain: operations module styles (booking, diary, follow-ups, call log). */

/* ---------- dispatch ---------- */
.more-toggle { display: flex; align-items: center; flex-wrap: wrap; gap: .25rem .75rem; width: 100%; padding: .85rem 1.1rem; border: 0; border-radius: .875rem; background: transparent; text-align: left; color: inherit; }
.more-toggle:hover { background: #F7F8FC; }
.more-toggle > i { width: 1rem; color: var(--db-navy); }
.daycheck-list { max-height: 32rem; overflow-y: auto; }
.table-tight > :not(caption) > * > * { padding: .5rem .6rem; }

/* ---------- booking stepper and form ---------- */
.book-steps { display: flex; gap: .5rem; flex-wrap: wrap; }
.book-step { flex: 1 1 140px; display: flex; align-items: center; gap: .6rem; padding: .6rem .9rem; background: #fff; border: 1px solid #E3E6EF; border-radius: .75rem; color: #4B5563; font-weight: 600; }
.book-step .n { width: 26px; height: 26px; border-radius: 50%; background: #EEF0F6; color: var(--db-navy); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; flex: none; }
.book-step.active { border-color: var(--db-navy); color: var(--db-navy); box-shadow: 0 0 0 .15rem rgba(var(--db-navy-rgb), .1); }
.book-step.active .n { background: var(--db-navy); color: #fff; }
.book-step.done .n { background: var(--db-green-state); color: #fff; }
.book-step.locked { opacity: .55; cursor: default; }
.book-chosen { display: flex; align-items: center; gap: .85rem; padding: .85rem 1rem; border: 1px solid #C9CFDF; border-radius: .75rem; background: var(--db-sky); }
.suggest-list { border: 1px solid #E3E6EF; border-radius: .6rem; overflow: hidden; min-height: 2.5rem; }
.suggest { display: flex; align-items: center; gap: .65rem; padding: .55rem .75rem; color: inherit; border-bottom: 1px solid #F1F3F8; }
.suggest:last-child { border-bottom: 0; }
.suggest.active, .suggest:hover { background: var(--db-sky); color: inherit; }
.source-chip { display: flex; align-items: center; min-height: 38px; }
.opt-row { display: flex; gap: .5rem; flex-wrap: wrap; }
.opt-card { flex: 1 1 140px; display: flex; align-items: center; gap: .6rem; padding: .6rem .85rem; border: 1px solid #DCE0EA; border-radius: .6rem; cursor: pointer; font-weight: 600; background: #fff; margin: 0; }
.opt-card.wide { flex-basis: 280px; align-items: flex-start; }
.opt-card.wide small { display: block; font-weight: 400; color: #6B7280; font-size: 12px; }
.opt-card:hover { border-color: #A9B2DB; }
.opt-card.on { border-color: var(--db-navy); background: #F1F3FB; color: var(--db-navy); box-shadow: 0 0 0 .12rem rgba(var(--db-navy-rgb), .1); }
.opt-card.on.red { border-color: #D92D20; background: #FDECEA; color: #B42318; box-shadow: none; }
.avail-grid thead th { text-align: center; }
.avail-grid thead th:first-child { text-align: left; }
.avail-grid td { padding: .4rem .5rem !important; }
.slot-btn { width: 100%; min-height: 44px; border-radius: .5rem; border: 1px dashed #B8DEC8; background: #F3FBF6; color: var(--db-green-state); font-weight: 600; font-size: 12.5px; display: flex; align-items: center; justify-content: center; gap: .35rem; }
.slot-btn.free:hover { background: #DDF5E7; border-style: solid; }
.slot-btn.sel { background: var(--db-navy); border-color: var(--db-navy); color: #fff; border-style: solid; }
.slot-btn.busy { background: #F3F4F6; border: 1px solid #E3E6EF; color: #6B7280; flex-direction: column; gap: 0; padding: .2rem; line-height: 1.2; }
.slot-btn.busy small { font-size: 11px; }
.book-foot { position: sticky; bottom: 0; background: #fff; border-radius: 0 0 .875rem .875rem; z-index: 2; }

/* ---------- diary ---------- */
.daybefore-switch { display: flex; align-items: center; gap: .5rem; padding: .35rem .75rem .35rem 2.5rem; background: #fff; border: 1px solid #DCE0EA; border-radius: .5rem; }
.daybefore-card { border-color: #BFE6CF; background: #F4FBF7; }
.date-pick { width: 160px; }
.eng-select { width: 220px; max-width: 100%; }
.diary-grid { table-layout: fixed; min-width: 880px; }
.diary-grid thead th { text-align: center; vertical-align: middle; }
.diary-grid thead th:first-child, .diary-grid th.who { text-align: left; width: 200px; }
.diary-grid thead th.today { color: var(--db-green); }
.diary-grid th.who { background: #fff; font-weight: 400; text-transform: none; letter-spacing: 0; font-size: inherit; color: inherit; }
.dj-cell { vertical-align: top; height: 104px; padding: .35rem !important; border-left: 1px solid #EEF0F6; }
.dj-cell.today { background: #FAFBFE; }
.dj-cell.weekend { background: #F8F9FC; }
.dj-cell.over-ok { background: #E4F6EB; outline: 2px dashed var(--db-green-state); outline-offset: -3px; }
.dj-cell.over-bad { background: #FDE8EA; outline: 2px dashed #D92D20; outline-offset: -3px; }
.dj-card { border: 1px solid #E3E6EF; border-left-width: 4px; border-radius: .55rem; padding: .35rem .5rem; font-size: 12px; line-height: 1.35; cursor: grab; margin-bottom: .3rem; background: #fff; }
.dj-card:last-child { margin-bottom: 0; }
.dj-card:hover { box-shadow: 0 4px 12px rgba(11, 15, 45, .12); }
.dj-card.blue { border-color: #C5D6F8; border-left-color: var(--db-blue-state); background: #F1F6FE; }
.dj-card.green { border-color: #C2E6D1; border-left-color: var(--db-green-state); background: #F0FAF4; }
.dj-card.fixed { cursor: pointer; }
.dj-card.check.blue { box-shadow: 0 0 0 2px rgba(30, 91, 216, .35); animation: dbpulse 2s infinite; }
.dj-card .cust { font-weight: 600; }
.dj-card .cust a { color: inherit; pointer-events: none; }
.dj-card .meta { color: #6B7280; }
.pool-panel.pool-over { outline: 2px dashed var(--db-navy); outline-offset: 2px; }
.pool-item { border: 1px solid #E3E6EF; border-radius: .55rem; padding: .45rem .6rem; margin-bottom: .45rem; background: #fff; cursor: grab; }
.pool-item.static { cursor: default; }
.pool-item:hover { border-color: #A9B2DB; }
.dj-menu-backdrop { position: fixed; inset: 0; z-index: 1055; }
.dj-menu { position: fixed; z-index: 1056; min-width: 230px; background: #fff; border-radius: .7rem; box-shadow: 0 16px 40px rgba(11, 15, 45, .25); border: 1px solid #E3E6EF; overflow: hidden; }
.dj-menu .head { padding: .55rem .85rem; background: var(--db-sky); font-weight: 600; }
.dj-menu a { display: flex; align-items: center; gap: .6rem; padding: .5rem .85rem; color: #1F2937; }
.dj-menu a i { width: 16px; text-align: center; color: var(--db-navy); }
.dj-menu a.text-success i { color: inherit; }
.dj-menu a:hover { background: #F4F6FB; }
.dj-card .badge { white-space: normal; max-width: 100%; }

/* ---------- follow-ups and call log ---------- */
.col-source { min-width: 12rem; }
.table tbody tr.row-sat > td { background: #FFF8E6; }
.table tbody tr.row-sat > td:first-child { box-shadow: inset 3px 0 0 var(--db-gold); }
.quote-text { max-width: 260px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.quote-last { max-width: 150px; }
