/* Schedule calendar (schedule.jsx dayTemplate) */
.fb-cal-cell { padding: 2px; min-height: 2.5rem; }
.fb-cal-block { background-color: #3f51b5; color: #fff; padding: 2px 4px; margin-bottom: 2px; border-radius: 3px; font-size: .7rem; line-height: 1rem;
                overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Schedule: the week ahead, a panel per day (pages/schedule.py) */
.fb-day .p-panel-header { cursor: pointer; }
.fb-day-today { border: 2px solid #3f51b5; border-radius: 6px; }
.fb-day-today > .p-panel-header { background: #e8eaf6; }
.fb-kids > div { line-height: 1.35; }
.fb-medical { color: #c62828; font-weight: 600; margin-left: .35rem; font-size: .85em; }
.fb-full { font-weight: 700; color: #2e7d32; }
.jmt-dark .fb-day-today > .p-panel-header { background: #23284a; }
.jmt-dark .fb-medical { color: #ff8a80; }
.fb-day .p-rowgroup-header td { background: #eef0fa; color: #1a237e; padding: .45rem .6rem !important; }
.fb-venue { font-size: 1rem; }
.fb-venue-sub { font-weight: 400; color: #5c6bc0; font-size: .85rem; }
.jmt-dark .fb-day .p-rowgroup-header td { background: #23284a; color: #c5cae9; }
/* the children get most of the width; time / class and places stay as narrow as their text */
.fb-day table.p-datatable-table { width: 100%; }
.fb-day .p-datatable-thead th:nth-child(1), .fb-day .p-datatable-tbody td:nth-child(1) { width: 13rem; }
.fb-day .p-datatable-thead th:nth-child(2), .fb-day .p-datatable-tbody td:nth-child(2) { width: 1%; white-space: nowrap; }
.fb-class { font-size: .85em; color: #5f6368; line-height: 1.2; }
.jmt-dark .fb-class { color: #b0b0b0; }
.fb-day .p-rowgroup-header td { width: auto !important; white-space: normal !important; }
.fb-kids { display: flex; flex-wrap: wrap; gap: 2px 18px; }

/* Comments and Students (pages/comments.py, pages/students.py) */
.fb-comments-waiting { border: 2px solid #ef6c00; border-radius: 6px; }
.fb-comments-waiting > .p-panel-header { background: #fff3e0; }
.jmt-dark .fb-comments-waiting > .p-panel-header { background: #3e2a12; }
.fb-to-comment { color: #ef6c00; font-weight: 600; }
.fb-done { color: #2e7d32; font-weight: 600; }
.fb-comment-text { white-space: pre-wrap; }
.fb-comment { border-left: 3px solid #3f51b5; padding: .25rem .6rem; margin-bottom: .5rem; }

/* Grok briefs B20-B33: help notes (P2), banners (P3), badges (P6), tabs, session cards, comment box, profile, apply */
.fb-help { background: #e8f4fd; border: 1px solid #b3dbf6; color: #0b4a75; border-radius: 6px; padding: .6rem .8rem; margin: .75rem 0; font-size: .9rem; }
.fb-help-title { font-weight: 600; margin-bottom: .25rem; }
.fb-help-list { margin: .25rem 0 .25rem 1.1rem; padding: 0; }
.fb-help-more { font-size: .85rem; }
.jmt-dark .fb-help { background: #12304a; border-color: #1f4f78; color: #cfe8fb; }
.fb-notice { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; border-radius: 6px;
             padding: .6rem .8rem; margin-bottom: .75rem; border: 1px solid; }
.fb-notice-actions .p-button { margin-bottom: 0; }
.fb-notice-error { background: #fdecea; border-color: #f5c2c0; color: #8a1c14; }
.fb-notice-warning { background: #fff4e5; border-color: #ffd8a8; color: #7a4100; }
.fb-notice-success { background: #e8f5e9; border-color: #b9dfbb; color: #1b5e20; }
.fb-notice-info { background: #e8f4fd; border-color: #b3dbf6; color: #0b4a75; }
.fb-notice-muted { background: #f1f3f4; border-color: #dadce0; color: #5f6368; }
.fb-badge { display: inline-block; padding: .1rem .5rem; border-radius: 999px; font-size: .8rem; font-weight: 600; white-space: nowrap; }
.fb-badge-green { background: #e8f5e9; color: #1b5e20; }
.fb-badge-red { background: #fdecea; color: #b71c1c; }
.fb-badge-grey { background: #eceff1; color: #546e7a; }
.fb-badge-blue { background: #e3f2fd; color: #0d47a1; }
.fb-badge-amber { background: #fff3e0; color: #8a4b00; }
.fb-tabs { display: flex; gap: .25rem; border-bottom: 2px solid #dadce0; margin-bottom: .75rem; }
.fb-tab { padding: .6rem 1rem; min-height: 44px; display: inline-flex; align-items: center; text-decoration: none; color: inherit;
          border-bottom: 3px solid transparent; margin-bottom: -2px; font-weight: 500; }
.fb-tab-active { border-bottom-color: #3f51b5; color: #3f51b5; font-weight: 700; }
.fb-filters { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin-bottom: .75rem; }
.fb-filter { display: flex; flex-direction: column; min-width: 12rem; flex: 1 1 12rem; max-width: 22rem; }
.fb-filter-caption { font-size: .8rem; font-weight: 600; margin-bottom: .2rem; }
.fb-session-waiting { border-left: 4px solid #ef6c00; }
.fb-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .25rem .75rem;
          padding: .5rem 0; border-bottom: 1px solid #eee; }
.fb-row:last-child { border-bottom: none; }
.fb-row-main { flex: 1 1 14rem; min-width: 0; }
.fb-latest { margin-top: .2rem; }
.fb-empty { padding: 1rem; text-align: center; color: #5f6368; }
.fb-student-link { color: inherit; text-decoration: underline dotted; cursor: pointer; }
.fb-inline-error { color: #c62828; font-size: .875rem; margin: .25rem 0 .5rem; font-weight: 500; }
.fb-count { text-align: right; font-size: .8rem; color: #757575; margin: -.25rem 0 .5rem; }
.fb-entry-none { font-style: italic; color: #5f6368; }
.fb-entry-hidden { color: #b71c1c; font-size: .85rem; }
.fb-comment-hidden { border-left-color: #b71c1c; opacity: .8; }
.fb-qmark { cursor: help; font-weight: 700; }
.fb-meter { margin-top: .5rem; }
.fb-meter-label { font-weight: 600; margin-bottom: .25rem; }
.fb-section .p-panel-header .fb-badge { margin-left: .5rem; }
.fb-upload { border-top: 1px dashed #ccc; padding-top: .5rem; }
.fb-file-error { color: #c62828; font-size: .85rem; }
.fb-trouble-menu > summary { list-style: none; cursor: pointer; }
.fb-trouble-menu > summary::-webkit-details-marker { display: none; }
.fb-trouble-menu[open] > .jmt-option { padding-left: 2rem; }
.fb-help-topic h3 { margin: 1rem 0 .25rem; }
/* Apply to teach (public) */
.fb-apply { padding: 1rem 0; }
.fb-ticks { display: flex; flex-wrap: wrap; gap: .25rem 1rem; }
.fb-tick { display: inline-flex; align-items: flex-start; gap: .4rem; min-height: 44px; align-items: center; }
.fb-tick input { width: 1.2rem; height: 1.2rem; }
.fb-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
/* phones: tap-sized buttons, the main button full width, dialogs fit */
@media (max-width: 640px) {
  .p-button { min-height: 44px; }
  .fb-main-button { width: 100%; }
  .fb-row-action { width: 100%; }
  .fb-row-action .p-button { width: 100%; justify-content: center; }
  .fb-filter { max-width: none; }
  .p-dialog { width: 95vw !important; max-height: 90vh; }
}
/* The Comment dialog's "No comment" / "Absent" buttons (pages/comments.py QuickButton): a button, then its question with
   Confirm / Cancel, so nothing saves on a single tap */
.fb-quick-row { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin-top: 1rem; padding-top: .75rem; border-top: 1px solid var(--surface-border, #dee2e6); }
.fb-quick { flex: 1 1 12rem; }
.fb-quick-ask { width: 100%; justify-content: center; }
.fb-quick-confirm { padding: .75rem; border: 1px solid var(--surface-border, #dee2e6); border-radius: 6px; background: var(--surface-ground, #f8f9fa); }
.fb-quick-question { font-weight: 600; }
