.appt-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(var(--primary-rgb), 0.12);
}

.appt-section h3 {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 600;
}

.appt-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-bottom: 12px;
}

.appt-toolbar .appt-range-label {
  font-size: 13px;
  color: var(--sub-text);
}

.appt-week-grid {
  margin-bottom: 14px;
}

.appt-week-head-row,
.appt-week-day-row {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.appt-week-head-row {
  margin-bottom: 4px;
}

.appt-week-head-cell {
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--sub-text);
  padding: 2px 0;
}

.appt-week-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 4px 8px;
  border-radius: 12px;
  border: 1px solid rgba(var(--primary-rgb), 0.16);
  background: var(--panel);
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
  min-height: 72px;
}

.appt-week-day:hover {
  border-color: rgba(var(--primary-rgb), 0.4);
  background: var(--primary-surface);
}

.appt-week-day.is-today {
  border-color: var(--primary);
}

.appt-week-day.is-selected {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
  box-shadow: inset 0 0 0 1px rgba(var(--primary-rgb), 0.2);
}

.appt-week-day.is-past {
  opacity: 0.55;
}

.appt-week-day-num {
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
  color: var(--text);
}

.appt-week-day-meta {
  font-size: 10px;
  color: var(--sub-text);
  text-align: center;
  line-height: 1.3;
}

.appt-week-day-dots {
  display: flex;
  gap: 3px;
  margin-top: 2px;
}

.appt-week-dot {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #b0b7bf;
}

.appt-week-dot.is-booked {
  background: #4a90d9;
}

.appt-day-panel {
  margin-bottom: 16px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(var(--primary-rgb), 0.14);
  background: rgba(var(--primary-rgb), 0.03);
}

.appt-day-panel-head {
  margin-bottom: 12px;
}

.appt-day-title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
}

.appt-day-hint {
  margin: 0;
  font-size: 12px;
  color: var(--sub-text);
  line-height: 1.4;
}

.appt-day-section {
  margin-bottom: 12px;
}

.appt-day-section:last-child {
  margin-bottom: 0;
}

.appt-day-section-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--sub-text);
  margin-bottom: 8px;
}

.appt-day-booked-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.appt-day-booked {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  background: #eceff3;
  border: 1px solid #dfe3e8;
  font-size: 13px;
}

.appt-day-booked-time {
  font-weight: 600;
  color: #3d4650;
}

.appt-day-slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
}

.profile-page .appt-note-field {
  margin: 4px 0 18px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--primary-surface);
  border: 1px solid rgba(var(--primary-rgb), 0.14);
}

.profile-page .appt-note-field .field-label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text);
}

.profile-page .appt-note-input {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--panel);
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.45;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.profile-page .appt-note-input::placeholder {
  color: var(--sub-text);
  opacity: 0.72;
}

.profile-page .appt-note-input:hover {
  border-color: rgba(var(--primary-rgb), 0.35);
}

.profile-page .appt-note-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.18);
  background: var(--panel);
}

.profile-page .appt-note-field .field-hint {
  margin: 6px 0 0;
  font-size: 0.75rem;
  color: var(--sub-text);
  line-height: 1.4;
}

.appt-slot-btn {
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(var(--primary-rgb), 0.2);
  background: var(--primary-surface);
  color: var(--text);
  font-size: 13px;
  cursor: pointer;
  text-align: left;
  line-height: 1.35;
}

.appt-day-slot-grid .appt-slot-btn {
  text-align: center;
  font-weight: 600;
  border-color: #8bc9a0;
  background: #e8f5ec;
  color: #1e5631;
}

.appt-day-slot-grid .appt-slot-btn:hover {
  border-color: #5cb87a;
  background: #d4edda;
}

.appt-slot-btn:hover {
  border-color: rgba(var(--primary-rgb), 0.45);
  background: rgba(var(--primary-rgb), 0.08);
}

.appt-slot-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.appt-empty {
  font-size: 13px;
  color: var(--sub-text);
  margin: 0 0 12px;
}

.appt-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.appt-item {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(var(--primary-rgb), 0.14);
  background: rgba(var(--primary-rgb), 0.04);
  font-size: 13px;
}

.appt-item-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
  margin-bottom: 4px;
}

.appt-item-time {
  font-weight: 600;
}

.appt-status {
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(var(--primary-rgb), 0.12);
  white-space: nowrap;
}

.appt-status.pending { background: #fff3cd; color: #856404; }
.appt-status.accepted { background: #d4edda; color: #155724; }
.appt-status.rejected { background: #f8d7da; color: #721c24; }
.appt-status.cancelled { background: #e9ecef; color: #495057; }
.appt-status.reschedule_proposed { background: #cce5ff; color: #004085; }

.appt-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.appt-item-actions button {
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 8px;
  border: 1px solid rgba(var(--primary-rgb), 0.25);
  background: var(--panel);
  cursor: pointer;
}

.appt-item-actions .btn-primary-sm {
  background: var(--primary);
  color: #fff;
  border-color: transparent;
}

.appt-msg {
  font-size: 13px;
  color: var(--sub-text);
  margin: 8px 0 0;
}

/* 康复师端日历 */
.cal-settings-panel {
  margin-bottom: 20px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
}

.cal-settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.cal-avail-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.cal-avail-row select,
.cal-avail-row input {
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 13px;
}

.cal-month-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-top: 12px;
}

.cal-month-head {
  font-size: 12px;
  text-align: center;
  color: var(--sub-text);
  padding: 4px 0;
}

.cal-day-cell {
  min-height: 72px;
  padding: 4px;
  border-radius: 8px;
  border: 1px solid var(--border);
  font-size: 11px;
  background: var(--panel);
}

.cal-day-cell.is-today {
  border-color: var(--primary);
}

.cal-day-num {
  font-weight: 600;
  margin-bottom: 4px;
}

.cal-day-event {
  display: block;
  margin-bottom: 2px;
  padding: 2px 4px;
  border-radius: 4px;
  background: rgba(var(--primary-rgb), 0.12);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.cal-day-event.pending { background: #fff3cd; }
.cal-day-event.accepted { background: #d4edda; }

.cal-appt-detail {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
  box-shadow: var(--shadow-sm, 0 1px 4px rgba(var(--primary-rgb), 0.06));
}

.cal-appt-detail h4 {
  margin: 0 0 10px;
  font-size: 15px;
  color: var(--primary-muted, var(--primary));
}

.cal-appt-detail > p {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.45;
}

.cal-reschedule-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0;
}

.cal-reschedule-fields input {
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.cal-export-hint {
  font-size: 12px;
  color: var(--sub-text);
  word-break: break-all;
  margin-top: 6px;
}

/* 管理端日程日历 */
.cal-summary-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.cal-stat-card {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--primary-surface);
}

.cal-stat-label {
  display: block;
  font-size: 12px;
  color: var(--sub-text);
  margin-bottom: 4px;
}

.cal-stat-num {
  font-size: 1.35rem;
  color: var(--primary-muted);
}

.cal-filters-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 14px;
  margin-bottom: 16px;
}

.cal-filter-item {
  margin: 0;
  min-width: 140px;
}

.cal-pending-section {
  margin-bottom: 18px;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--panel-tint-border, var(--border));
  background: linear-gradient(180deg, var(--warning-soft, #f6efe1) 0%, var(--panel) 100%);
  box-shadow: var(--shadow-sm, 0 1px 4px rgba(var(--primary-rgb), 0.08));
}

.cal-pending-section .cal-section-head h3 {
  color: var(--text);
}

.cal-pending-user {
  font-weight: 600;
  color: var(--text);
}

.cal-pending-time-cell {
  line-height: 1.35;
}

.cal-pending-date {
  display: block;
  font-size: 12px;
  color: var(--sub-text);
}

.cal-pending-time {
  display: block;
  font-weight: 600;
  font-size: 13px;
  color: var(--primary-muted, var(--primary));
}

.cal-pending-note {
  font-size: 13px;
  color: var(--sub-text);
  max-width: 220px;
}

.cal-pending-table tbody tr {
  background: var(--panel);
}

.cal-pending-table tbody tr:hover {
  background: var(--primary-surface);
}

.cal-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  margin-bottom: 10px;
}

.cal-section-head h3,
.cal-section-head h4 {
  margin: 0;
  font-size: 15px;
}

.cal-pending-table .col-ops {
  white-space: nowrap;
  min-width: 200px;
}

/* 预约处理按钮（接受 / 拒绝 / 改期） */
.cal-decision-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.cal-decision-actions--compact {
  gap: 6px;
}

.cal-decision-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.cal-decision-btn--sm {
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 600;
}

.cal-decision-btn--accept {
  background: var(--success, #6ba89a);
  color: #fff;
  border-color: var(--success, #6ba89a);
  box-shadow: 0 1px 3px rgba(107, 168, 154, 0.28);
}

.cal-decision-btn--accept:hover {
  filter: brightness(0.95);
  box-shadow: 0 2px 6px rgba(107, 168, 154, 0.32);
}

.cal-decision-btn--reject {
  background: var(--danger-soft, #f5e8e8);
  color: #8f4a4a;
  border-color: rgba(192, 133, 133, 0.45);
}

.cal-decision-btn--reject:hover {
  background: #efd8d8;
  border-color: var(--danger, #c08585);
  color: #7a3535;
}

.cal-decision-btn--reschedule {
  background: var(--panel);
  color: var(--primary-muted, var(--primary));
  border-color: rgba(var(--primary-rgb), 0.35);
}

.cal-decision-btn--reschedule:hover,
.cal-decision-btn--reschedule.is-active {
  background: var(--primary-surface);
  border-color: var(--primary);
  color: var(--primary-strong, var(--primary));
  box-shadow: inset 0 0 0 1px rgba(var(--primary-rgb), 0.12);
}

.cal-detail-handle {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--ops-bg, var(--primary-surface));
}

.cal-detail-handle-title {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.cal-detail-note-label {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--sub-text);
}

.cal-detail-note {
  width: 100%;
  margin-top: 0;
  margin-bottom: 12px;
  box-sizing: border-box;
  min-height: 64px;
  resize: vertical;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--text);
}

.cal-detail-note:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.16);
}

.cal-reschedule-panel {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(var(--primary-rgb), 0.2);
  background: var(--panel);
}

.cal-reschedule-panel-title {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.cal-reschedule-empty {
  margin: 0;
  font-size: 12px;
  color: var(--sub-text);
}

.admin-app .appt-status {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
}

.admin-app .appt-status.pending {
  background: var(--warning-soft, #f6efe1);
  color: #7a6535;
}

.admin-app .appt-status.accepted {
  background: var(--success-soft, #e6f2ee);
  color: #3d6b5f;
}

.admin-app .appt-status.rejected {
  background: var(--danger-soft, #f5e8e8);
  color: #8f4a4a;
}

.admin-app .appt-status.cancelled {
  background: var(--ops-bg-muted, #dde4ec);
  color: var(--sub-text);
}

.admin-app .appt-status.reschedule_proposed {
  background: var(--primary-surface);
  color: var(--primary-muted);
}

.cal-settings-details {
  margin-bottom: 18px;
  padding: 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
  overflow: hidden;
}

.cal-settings-summary {
  cursor: pointer;
  padding: 12px 16px;
  font-weight: 600;
  font-size: 14px;
  list-style: none;
  background: var(--primary-surface);
}

.cal-settings-summary::-webkit-details-marker {
  display: none;
}

.cal-settings-body {
  padding: 14px 16px 16px;
}

.cal-settings-subtitle {
  margin: 0 0 6px;
  font-size: 14px;
}

.cal-settings-hint {
  margin-top: 0;
  margin-bottom: 10px;
}

.cal-settings-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.cal-settings-divider {
  margin: 16px 0;
  border: none;
  border-top: 1px solid var(--border);
}

.cal-export-url {
  font-size: 12px;
  color: var(--sub-text);
  word-break: break-all;
  margin: 6px 0 0;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: var(--ops-bg);
  border: 1px dashed var(--border);
}

.cal-main-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr);
  gap: 16px;
  align-items: start;
}

.cal-calendar-pane {
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
}

.cal-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 10px;
}

.cal-month-title {
  min-width: 120px;
  text-align: center;
  font-size: 15px;
}

.cal-day-cell {
  position: relative;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.cal-day-cell:hover {
  border-color: rgba(var(--primary-rgb), 0.45);
  background: var(--primary-surface);
}

.cal-day-cell.is-selected {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
  box-shadow: inset 0 0 0 1px rgba(var(--primary-rgb), 0.2);
}

.cal-day-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  line-height: 18px;
  text-align: center;
}

.cal-side-pane {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
  max-height: 720px;
  overflow: auto;
}

.cal-day-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.cal-day-list-empty {
  font-size: 13px;
  color: var(--sub-text);
  margin: 0;
}

.cal-day-list-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--panel);
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.cal-day-list-item:hover {
  border-color: rgba(var(--primary-rgb), 0.4);
  background: var(--primary-surface);
}

.cal-day-list-item.is-active {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
}

.cal-day-list-time {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.cal-day-list-user {
  font-size: 12px;
  color: var(--sub-text);
}

.cal-detail-label {
  color: var(--sub-text);
  font-size: 12px;
  margin-right: 4px;
}

.cal-detail-actions {
  margin-top: 12px;
}

.cal-detail-note {
  width: 100%;
  margin-top: 10px;
  box-sizing: border-box;
}

.cal-reschedule-box {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed var(--border);
}

.cal-slot-pick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(128px, 1fr));
  gap: 8px;
}

.cal-slot-pick-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 8px 10px;
  font-size: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease;
}

.cal-slot-pick-day {
  font-size: 10px;
  color: var(--sub-text);
}

.cal-slot-pick-time {
  font-size: 12px;
  font-weight: 600;
  color: var(--primary-muted, var(--primary));
}

.cal-slot-pick-btn:hover {
  border-color: var(--primary);
  background: var(--primary-surface);
  box-shadow: 0 1px 4px rgba(var(--primary-rgb), 0.12);
}

.form-msg-error {
  color: #c0392b;
}

/* 日时间轴（类 Apple Calendar） */
.cal-day-timeline-wrap {
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.cal-timeline-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 10px;
  font-size: 11px;
  color: var(--sub-text);
}

.cal-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.cal-legend-swatch {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.cal-legend-swatch.is-open-band {
  background: #eceff3;
}

.cal-legend-swatch.is-available {
  background: #c8cdd3;
}

.cal-legend-swatch.is-accepted {
  background: #4a90d9;
}

.cal-legend-swatch.is-pending {
  background: #f0c674;
}

.cal-timeline-scroll {
  max-height: 420px;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--panel);
}

.cal-timeline {
  display: grid;
  grid-template-columns: 44px 1fr;
  position: relative;
  min-height: 480px;
}

.cal-timeline-hours {
  position: relative;
  border-right: 1px solid var(--border-light);
  background: #fafbfc;
}

.cal-timeline-hour-label {
  position: absolute;
  right: 6px;
  transform: translateY(-50%);
  font-size: 10px;
  color: var(--sub-text);
  line-height: 1;
}

.cal-timeline-grid {
  position: relative;
  min-height: 100%;
}

.cal-timeline-hour-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 1px solid var(--border-light);
  pointer-events: none;
}

.cal-timeline-open-band {
  position: absolute;
  left: 4px;
  right: 4px;
  border-radius: 6px;
  background: #eceff3;
  border: 1px solid #dfe3e8;
  pointer-events: none;
  z-index: 1;
}

.cal-timeline-block {
  position: absolute;
  left: 6px;
  right: 6px;
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11px;
  line-height: 1.3;
  overflow: hidden;
  box-sizing: border-box;
  cursor: pointer;
  z-index: 2;
  border: 1px solid transparent;
}

.cal-timeline-block.is-available {
  background: #c8cdd3;
  color: #3d4650;
  border-color: #b0b7bf;
  cursor: default;
  z-index: 2;
}

.cal-timeline-block.is-accepted {
  background: linear-gradient(180deg, #5b9de0 0%, #4a90d9 100%);
  color: #fff;
  border-color: #3a7fc4;
  box-shadow: 0 1px 3px rgba(74, 144, 217, 0.35);
  z-index: 4;
}

.cal-timeline-block.is-pending {
  background: linear-gradient(180deg, #f5d78e 0%, #f0c674 100%);
  color: #5c4a12;
  border-color: #ddb84d;
  z-index: 3;
}

.cal-timeline-block.is-reschedule {
  background: linear-gradient(180deg, #b8d4f0 0%, #9ec5eb 100%);
  color: #1a4a7a;
  border-color: #7eb3e0;
  z-index: 3;
}

.cal-timeline-block-title {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cal-timeline-block-time {
  opacity: 0.92;
  font-size: 10px;
}

.cal-timeline-hint {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--sub-text);
}

.cal-color-picker-wrap {
  margin: 12px 0 4px;
  padding-top: 10px;
  border-top: 1px dashed var(--border);
}

.cal-color-picker-label {
  margin: 0 0 8px;
  font-size: 12px;
}

.cal-color-picker-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cal-color-swatch-btn {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
}

.cal-color-swatch-btn:hover {
  transform: scale(1.08);
}

.cal-color-swatch-btn.is-active {
  border-color: var(--text);
  box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--primary);
}

.cal-timeline-empty {
  padding: 24px 12px;
  text-align: center;
  font-size: 13px;
  color: var(--sub-text);
}

@media (max-width: 960px) {
  .cal-main-layout {
    grid-template-columns: 1fr;
  }

  .cal-summary-row {
    grid-template-columns: 1fr;
  }

  .cal-timeline-scroll {
    max-height: 360px;
  }
}

@media (max-width: 720px) {
  .cal-decision-actions--compact {
    flex-direction: column;
    align-items: stretch;
  }

  .cal-decision-actions--compact .cal-decision-btn {
    width: 100%;
  }

  .cal-pending-table .col-ops {
    min-width: 120px;
  }
}

@media (max-width: 640px) {
  .appt-week-head-row,
  .appt-week-day-row {
    gap: 4px;
  }

  .appt-week-day {
    min-height: 64px;
    padding: 8px 2px 6px;
  }

  .appt-week-day-num {
    font-size: 16px;
  }

  .appt-week-day-meta {
    font-size: 9px;
  }

  .appt-day-slot-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ── 积分抵现（个人资料 · 康复师预约区） ── */
.points-cash-offset-section {
  margin-top: 18px;
}

.points-cash-offset-panel {
  padding: 16px;
  border-radius: 14px;
  border: 1px solid rgba(var(--primary-rgb), 0.14);
  background: rgba(var(--primary-rgb), 0.03);
}

.points-cash-offset-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px 16px;
  margin-bottom: 14px;
}

.points-cash-offset-title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

.points-cash-offset-desc {
  margin: 0;
  font-size: 12px;
  color: var(--sub-text);
  line-height: 1.45;
}

.points-cash-offset-balance {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  min-width: 96px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(var(--primary-rgb), 0.18);
  background: var(--panel);
}

.points-cash-offset-balance.is-frozen {
  border-color: rgba(192, 57, 43, 0.28);
  background: rgba(192, 57, 43, 0.04);
}

.points-cash-offset-balance-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--sub-text);
}

.points-cash-offset-balance-value {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
}

.points-cash-offset-balance.is-frozen .points-cash-offset-balance-value {
  color: #b45309;
}

.points-cash-offset-balance-note {
  font-size: 10px;
  color: #c0392b;
  line-height: 1.3;
}

.points-cash-offset-rules {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
}

.points-cash-offset-rules li {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  color: var(--sub-text);
  background: var(--panel);
  border: 1px solid rgba(var(--primary-rgb), 0.12);
  line-height: 1.35;
}

.points-cash-offset-form {
  padding-top: 14px;
  border-top: 1px solid rgba(var(--primary-rgb), 0.1);
}

.points-cash-offset-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.points-cash-offset-fields .profile-field {
  margin-bottom: 0;
}

.points-cash-offset-fields .field-label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

.points-cash-offset-input {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--panel);
  color: var(--text);
  font-size: 14px;
  line-height: 1.45;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.points-cash-offset-input::placeholder {
  color: var(--sub-text);
  opacity: 0.72;
}

.points-cash-offset-input:hover {
  border-color: rgba(var(--primary-rgb), 0.35);
}

.points-cash-offset-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.18);
}

.points-cash-offset-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 12px;
  margin-bottom: 14px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--panel);
  border: 1px solid rgba(var(--primary-rgb), 0.1);
}

.points-cash-offset-summary-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--sub-text);
}

.points-cash-offset-summary-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.points-cash-offset-actions {
  display: flex;
  justify-content: flex-end;
}

.points-cash-offset-actions .btn-primary {
  min-width: 120px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-sm);
}

.points-cash-offset-msg {
  margin-top: 10px;
}

.appt-msg.is-ok {
  color: #2e7d4f;
}

.appt-msg.is-err {
  color: #c0392b;
}

@media (max-width: 640px) {
  .points-cash-offset-head {
    flex-direction: column;
  }

  .points-cash-offset-balance {
    align-items: flex-start;
    width: 100%;
    box-sizing: border-box;
  }

  .points-cash-offset-fields {
    grid-template-columns: 1fr;
  }

  .points-cash-offset-actions .btn-primary {
    width: 100%;
  }
}
