/* Bookings: tabs, timetable, requests, working hours */
.nav-badge { margin-left: auto; background: #25d366; color: #0b3d22; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; }
.nav-badge[hidden] { display: none; }

.bk-tabs { display: flex; gap: 4px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.bk-tabs > a { padding: 9px 14px; text-decoration: none; color: var(--ink-2); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; display: inline-flex; gap: 6px; align-items: center; }
.bk-tabs > a:hover { color: var(--ink); }
.bk-tabs > a.on { color: var(--ink); border-bottom-color: var(--ink); font-weight: 600; }
.bk-tabs .badge { background: #25d366; color: #0b3d22; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 0 7px; }
.bk-tabs .btn { margin-bottom: 6px; }

.bk-bar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
.bk-nav { display: flex; align-items: center; gap: 2px; }
.bk-nav .icon-btn { font-size: 22px; line-height: 1; padding: 2px 10px; }
.bk-date { margin: 0; font-size: 18px; font-weight: 600; }
.bk-pick { width: auto !important; padding: 5px 8px !important; font-size: 13px; }
.bk-legend { display: flex; gap: 6px; flex-wrap: wrap; }
.bk-stats { margin: 0 0 12px; }

.chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); background: var(--surface); border-radius: 99px; padding: 4px 10px; font-size: 12.5px; cursor: pointer; color: var(--ink-2); white-space: nowrap; }
.chip i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.chip:hover { border-color: var(--ink-3); }
.chip.on { background: var(--dark); color: #fff; border-color: var(--dark); }
.chip.off { opacity: .45; text-decoration: line-through; }
.chip .x { border: 0; background: none; color: inherit; cursor: pointer; padding: 0 0 0 2px; font-size: 11px; opacity: .7; }
.chips input[type=date] { width: auto; padding: 3px 8px; font-size: 12.5px; }
.btn-link { border: 0; background: none; color: var(--accent-ink); cursor: pointer; padding: 2px 4px; text-decoration: underline; }

/* timetable */
.tt-wrap { overflow: auto; max-height: calc(100vh - 250px); min-height: 360px; position: relative; }
.tt { display: grid; min-width: min-content; }
.tt-corner, .tt-head { position: sticky; top: 0; z-index: 4; background: var(--surface); border-bottom: 1px solid var(--line); }
.tt-corner { left: 0; z-index: 5; }
.tt-head { display: flex; gap: 9px; align-items: center; padding: 10px 10px; border-left: 1px solid var(--line); min-width: 0; text-decoration: none; color: var(--ink); }
.tt-head .av { width: 30px; height: 30px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-size: 11.5px; font-weight: 700; flex: none; }
.tt-head b { display: block; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tt-head span { display: block; font-size: 11.5px; color: var(--ink-3); white-space: nowrap; }
.tt-head div { min-width: 0; }
.tt-head.day:hover { background: var(--surface-2); }
.tt-head.today b { color: var(--accent-ink); }
.tt-head.today { box-shadow: inset 0 -3px 0 var(--accent); }
.tt-times { position: sticky; left: 0; z-index: 3; background: var(--surface); }
.tt-hour { position: absolute; right: 8px; transform: translateY(-50%); font-size: 11px; color: var(--ink-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.tt-hour:first-child { transform: none; margin-top: 3px; }
.tt-col { position: relative; border-left: 1px solid var(--line); cursor: copy;
  background: repeating-linear-gradient(135deg, #f4efe9 0 6px, #efe9e1 6px 12px); }
.tt.week .tt-col { background: var(--surface); }
.tt.week .tt-col:not(.open) { background: repeating-linear-gradient(135deg, #f4efe9 0 6px, #efe9e1 6px 12px); }
.tt-work { position: absolute; left: 0; right: 0; background: var(--surface); }
.tt-break { position: absolute; left: 0; right: 0; background: repeating-linear-gradient(135deg, #f4efe9 0 6px, #efe9e1 6px 12px); display: grid; place-items: center; }
.tt-break span, .tt-off-label { font-size: 11px; color: var(--ink-3); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.tt-off-label { position: absolute; top: 40px; left: 0; right: 0; text-align: center; }
.tt-lines { position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(to bottom, var(--line) 1px, transparent 1px), linear-gradient(to bottom, #f1ebe4 1px, transparent 1px);
  background-size: 100% 75px, 100% 37.5px; }
.tt-ghost { display: none; position: absolute; left: 3px; right: 3px; height: 36px; border: 1.5px dashed var(--accent); border-radius: 8px; background: rgba(154, 106, 69, .06); color: var(--accent-ink); font-size: 12px; font-weight: 600; padding: 3px 8px; pointer-events: none; z-index: 1; }
.tt-now { position: absolute; left: 0; right: 0; border-top: 2px solid #e5534b; z-index: 3; pointer-events: none; }
.tt-now::before { content: ''; position: absolute; left: -5px; top: -6px; width: 10px; height: 10px; border-radius: 50%; background: #e5534b; }
.tt-now span { position: absolute; right: 4px; top: -18px; font-size: 10.5px; font-weight: 700; color: #e5534b; background: rgba(255, 255, 255, .85); padding: 0 4px; border-radius: 4px; }

.bk-block { position: absolute; z-index: 2; text-align: left; border: 0; cursor: pointer; overflow: hidden; border-radius: 8px; padding: 4px 8px 4px 9px; font-size: 12px; line-height: 1.3; color: var(--ink);
  background: color-mix(in srgb, var(--c) 14%, white); border-left: 4px solid var(--c); box-shadow: 0 1px 2px rgba(35, 28, 23, .08); display: flex; flex-direction: column; gap: 1px; }
.bk-block:hover { box-shadow: 0 4px 14px rgba(35, 28, 23, .18); z-index: 3; }
.bk-block .l1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bk-block .l2 { color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11.5px; }
.bk-block .tm { color: var(--ink-3); font-size: 11px; font-weight: 500; }
.bk-block.small { padding-top: 2px; padding-bottom: 2px; justify-content: center; }
.bk-block.st-requested { background: #fff; border: 1.5px dashed var(--c); border-left: 4px solid var(--c); }
.bk-block.st-done { opacity: .62; }
.bk-block.st-no-show { opacity: .5; background: #f3eeea; }
.bk-block.st-no-show b { text-decoration: line-through; }
.bk-block.st-cancelled { opacity: .45; background: #f6f2ed; border-left-color: #bbb; }
.bk-block.st-cancelled b { text-decoration: line-through; }
.bk-block.problem { box-shadow: 0 0 0 2px #e5534b; }
.wa-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #25d366; margin-right: 4px; box-shadow: 0 0 0 2px rgba(37, 211, 102, .25); vertical-align: 1px; }

/* requests */
.bk-req { display: grid; grid-template-columns: 96px 1fr auto; gap: 16px; align-items: center; padding: 14px 18px; margin-bottom: 10px; }
.bk-req .when { display: flex; flex-direction: column; align-items: center; background: var(--accent-soft); color: var(--accent-ink); border-radius: 12px; padding: 10px 6px; text-align: center; }
.bk-req .when b { font-size: 13px; }
.bk-req .when span { font-size: 18px; font-weight: 700; }
.bk-req .who { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.bk-req .acts { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin: 0 4px 0 2px; }
.warn { color: var(--bad); font-weight: 500; }
.ok { color: var(--good); font-weight: 600; }

/* doctors & hours */
.bk-team { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 16px; }
.bk-person { padding: 16px 18px; }
.bk-person-head { display: flex; gap: 12px; align-items: center; margin-bottom: 6px; }
.bk-person-head .color { width: 34px; height: 34px; border-radius: 50%; flex: none; cursor: pointer; position: relative; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .5); }
.bk-person-head .color input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.bk-person-head .nm { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.bk-person-head .nm input { padding: 4px 8px; border-color: transparent; }
.bk-person-head .nm input:hover { border-color: var(--line-2); }
.bk-person-head .nm input:first-child { font-weight: 600; font-size: 15px; }
.bk-hours { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.bk-day { display: flex; align-items: center; gap: 8px; padding: 6px 10px; min-height: 40px; flex-wrap: wrap; }
.bk-day + .bk-day { border-top: 1px solid var(--line); }
.bk-day.off { background: var(--surface-2); }
.bk-day .check { width: 64px; }
.bk-day input[type=time] { width: 118px; padding: 4px 6px; font-size: 13px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface); }
.bk-day .brk { display: inline-flex; gap: 4px; align-items: center; color: var(--ink-3); font-size: 12px; }
.bk-day .brk input[type=time] { width: 112px; }

/* booking form */
.bk-modal { width: min(640px, 100%); }
.bk-modal #bkFree { max-height: 104px; overflow: auto; margin-top: 6px; }
.bk-check { margin-top: 8px; font-size: 13px; min-height: 18px; }
.bk-history { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); line-height: 1.7; }
.modal-foot .spacer { flex: 1; }

/* inbox side panel */
.conv-booking { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); text-decoration: none; color: var(--ink); align-items: flex-start; }
.conv-booking:hover { border-color: var(--ink-3); }
.conv-booking span:not(.pill) { color: var(--ink-2); font-size: 12.5px; }

/* prices: appointment length */
.details-row .dur { gap: 6px; color: var(--ink-2); }
.details-row .dur input { width: 76px; padding: 4px 8px; }

@media (max-width: 860px) {
  .tt-wrap { max-height: calc(100vh - 220px); }
  .bk-req { grid-template-columns: 78px 1fr; }
  .bk-req .acts { grid-column: 1 / -1; justify-content: flex-start; }
  .bk-team { grid-template-columns: 1fr; }
  .bk-legend { order: 5; width: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; }
  .bk-tabs { overflow-x: auto; flex-wrap: nowrap; }
  .bk-tabs > a { white-space: nowrap; }
}

/* inbox: summary + doctor filter */
.inbox-list .search { display: flex; flex-direction: column; gap: 6px; }
.inbox-list .search select { font-size: 13px; padding: 6px 8px; }
.sum-mini { margin-top: 8px; font-size: 12.5px; }
.sum-mini > span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); font-weight: 600; margin-bottom: 2px; }
.sum-mini.med { background: var(--bad-soft); color: var(--bad); border-radius: 8px; padding: 6px 8px; }
.sum-mini.med > span { color: var(--bad); }
/* logins on the Doctors & hours cards */
.bk-login { margin-top: 14px; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; }
.bk-login code { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; font-size: 12.5px; }
.bk-login .secret { font-family: ui-monospace, Menlo, monospace; background: #fff8e6; border: 1px dashed #e0c27a; padding: 2px 8px; border-radius: 6px; user-select: all; }

/* files: read → find → check */
.drop-big { padding: 28px 20px 30px; }
.drop-steps { display: flex; justify-content: center; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; color: var(--ink-2); font-size: 13px; }
.drop-steps div { display: inline-flex; gap: 7px; align-items: center; font-weight: 500; }
.drop-steps i, .job-steps i { width: 22px; height: 22px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-ink); display: inline-grid; place-items: center; font-style: normal; font-size: 12px; font-weight: 700; flex: none; }
.drop-steps span { color: var(--ink-3); }
.job { padding: 14px 16px; margin-bottom: 10px; }
.job-steps { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 10px; font-size: 13px; color: var(--ink-3); }
.job-steps div { display: inline-flex; gap: 7px; align-items: center; }
.job-steps .done { color: var(--good); }
.job-steps .done i { background: var(--good-soft); color: var(--good); }
.job-steps .now { color: var(--ink); font-weight: 600; }
.job-steps .now i { background: var(--dark); color: #fff; animation: pulse-dot 1.2s ease-in-out infinite; }
@keyframes pulse-dot { 50% { box-shadow: 0 0 0 5px rgba(35, 28, 23, .12); } }
.job.err .job-steps .now i { animation: none; background: var(--bad); }
.learn-review { margin-bottom: 22px; border: 2px solid var(--accent); overflow: hidden; }
.lr-head { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; background: var(--accent-soft); }
.lr-head > div { flex: 1; }
.lr-head h2 { margin: 0 0 3px; }
.lr-group { padding: 8px 0; border-top: 1px solid var(--line); }
.lr-title { padding: 6px 18px; }
.lr-row { display: grid; grid-template-columns: 22px minmax(0, 1fr) minmax(0, 1.1fr); gap: 10px; align-items: start; padding: 8px 18px; cursor: pointer; }
.lr-row:hover { background: var(--surface-2); }
.lr-row input { margin-top: 3px; }
.lr-row .nm { display: flex; flex-direction: column; font-weight: 500; }
.lr-row small { font-weight: 400; color: var(--ink-3); font-size: 12px; }
.lr-row .chg { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.lr-row .chg s { color: var(--ink-3); }
.lr-row .chg b { color: var(--good); }
.lr-row .chg small { width: 100%; }
.lr-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--surface-2); position: sticky; bottom: 0; }
.files-h { font-size: 15px; margin: 6px 0 10px; }
@media (max-width: 640px) { .lr-row { grid-template-columns: 22px 1fr; } .lr-row .chg { grid-column: 2; } .drop-steps span { display: none; } }

/* results photos */
.ph-top { margin-bottom: 18px; }
.ph-drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; aspect-ratio: 3 / 4; border: 2px dashed var(--line-2); border-radius: 12px; cursor: pointer; position: relative; overflow: hidden; background: var(--surface-2); }
.ph-drop:hover { border-color: var(--accent); }
.ph-drop .ph-prev { position: absolute; inset: 0; background-size: cover; background-position: center; }
.ph-drop.has b, .ph-drop.has span.muted { position: relative; background: rgba(35, 28, 23, .7); color: #fff; padding: 1px 8px; border-radius: 99px; }
.ph-rules { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; padding: 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.ph-rules .check { align-items: flex-start; }
.ph-list { margin: 10px 0 12px; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; color: var(--ink-2); }
.ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.ph-card { overflow: hidden; }
.ph-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--line); }
.ph-pair img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; display: block; background: var(--surface-2); }
.ph-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
