.schedule-tool-link { display:inline-flex; align-items:center; color:#111; text-decoration:none; }
.schedule-intro { display:flex; align-items:flex-start; justify-content:space-between; gap:24px; margin-bottom:18px; }
.schedule-intro h1 { margin:5px 0; font-size:30px; }
.schedule-intro p { margin:0; color:var(--muted); }
.schedule-controls { display:flex; align-items:flex-end; flex-wrap:wrap; gap:12px; padding:16px; }
.schedule-controls label { display:grid; gap:6px; font-size:13px; font-weight:700; }
.schedule-controls select { min-width:145px; }
.schedule-print { margin-left:auto; }
.schedule-status { padding:11px 14px; border-left:4px solid #60a5fa; border-radius:7px; background:#12253e; color:#bfdbfe; }
.schedule-sheet { padding:22px; color:#132440; background:#fff; border-radius:16px; box-shadow:0 12px 30px #030a14aa; }
.schedule-sheet h2 { text-align:center; font-size:25px; }
.schedule-table-wrap { overflow-x:auto; }
.schedule-table { width:100%; min-width:970px; border-collapse:separate; border-spacing:2px; table-layout:fixed; }
.schedule-table th, .schedule-table td { height:70px; padding:7px; border-radius:5px; }
.schedule-table th { font-size:12px; text-align:center; text-transform:uppercase; }
.schedule-table th:first-child { width:22%; text-align:left; }
.schedule-table th:nth-child(2) { width:15%; text-align:left; }
.schedule-table th.actions { width:105px; }
.schedule-table th strong, .schedule-table th small { display:block; }
.schedule-table th small { font-size:9px; text-transform:none; }
.schedule-table td { position:relative; }
.schedule-table input { width:100%; box-sizing:border-box; padding:9px; border:1px solid transparent; color:#132440; background:transparent; font:inherit; font-weight:800; text-align:center; }
.schedule-table td:first-child input, .schedule-table td:nth-child(2) input { text-align:left; }
.schedule-table input:hover, .schedule-table input:focus { outline:none; border-color:#2563eb; background:#fff; }
.fasting { background:#fff5bf; }
.morning { background:#edf7d7; }
.noon { background:#fde6d6; }
.afternoon { background:#fff0bd; }
.night { background:#e7ebf3; }
.schedule-table td:first-child { background:#f8fafc; }
.schedule-table td:nth-child(2) { background:#f4eee6; }
.schedule-table tr.is-dragging { opacity:.45; }
.schedule-table tr.drag-over td { box-shadow:inset 0 3px #2563eb; }
.schedule-table .actions { white-space:nowrap; }
.drag-handle { margin-right:5px; padding:7px 6px; border:1px solid #cbd5e1; border-radius:6px; color:#475569; background:#fff; font-size:18px; font-weight:900; line-height:1; cursor:grab; touch-action:none; }
.drag-handle:hover, .drag-handle:focus-visible { border-color:#2563eb; color:#1d4ed8; outline:none; }
.drag-handle:active { cursor:grabbing; }
.empty-row td { text-align:center; color:#64748b; background:#f8fafc !important; }
.review-note { margin:16px 0 0; color:#526174; font-size:11px; text-align:center; }
.print-patient-header { display:none; grid-template-columns:1.4fr 1fr; gap:8px; }
.print-patient-header label { padding:8px; border:1px solid #dbcdbd; border-radius:10px; font-size:10px; font-weight:900; text-transform:uppercase; }
.print-patient-header span { display:block; min-height:24px; margin-top:5px; font-size:16px; }
.dose-drawing { display:grid; place-items:center; width:100%; min-height:50px; padding:3px; border:0; background:transparent; cursor:pointer; }
.dose-icons { display:flex; align-items:center; justify-content:center; flex-wrap:wrap; gap:5px; }
.dose-symbol { display:block; width:30px; height:30px; overflow:visible; fill:#fff; stroke:#173d68; stroke-width:2; vector-effect:non-scaling-stroke; }
.tablet-sector { fill:#173d68; stroke:none; }
.tablet-radius { fill:none; stroke:#173d68; stroke-width:1.5; }
.capsule-symbol { width:38px; }
.capsule-symbol rect { fill:#dbeafe; }
.puff-symbol { width:34px; height:34px; }
.puff-symbol path:first-child { fill:#dbeafe; }
.puff-air { fill:none; stroke-linecap:round; }
.dose-sos { font-size:18px; }
.empty-dose { color:#94a3b8; font-size:18px; }
.visually-hidden-dose { position:absolute !important; width:1px !important; height:1px !important; padding:0 !important; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }
.hidden { display:none !important; }

@media (max-width:760px) {
  .schedule-intro { display:block; }
  .schedule-print { margin-left:0; }
  .schedule-controls > * { flex:1 1 145px; }
  .schedule-sheet { margin:0 -10px; padding:12px; }
  .schedule-container { padding-right:10px; padding-left:10px; }
}

@media print {
  body { background:#fff; }
  .schedule-sheet, .schedule-table, .dose-symbol { print-color-adjust:exact; -webkit-print-color-adjust:exact; }
  .no-print, .qf-auth-actions { display:none !important; }
  .app, .main, .schedule-container { display:block !important; width:auto !important; max-width:none !important; margin:0 !important; padding:0 !important; }
  .schedule-sheet { padding:0; box-shadow:none; }
  .print-patient-header { display:grid; }
  .schedule-sheet h2 { margin:10px 0; }
  .schedule-table-wrap { overflow:visible; }
  .schedule-table { min-width:0; font-size:9px; }
  .schedule-table th, .schedule-table td { height:48px; padding:3px; break-inside:avoid; }
  .schedule-table th:first-child { width:20%; }
  .schedule-table th:nth-child(2) { width:16%; }
  .schedule-table th small { font-size:7px; }
  .schedule-table input { padding:2px; font-size:9px; }
  .schedule-table td:first-child input, .schedule-table td:nth-child(2) input { font-size:12px; font-weight:900; text-transform:uppercase; }
  .schedule-table .dose-input { font-size:12px; }
  .dose-symbol { width:27px; height:27px; stroke-width:2.5; }
  .capsule-symbol { width:34px; }
  .puff-symbol { width:31px; height:31px; }
  .empty-dose { visibility:hidden; }
  .review-note { margin-top:8px; }
}
