/* Meeting window + meeting cards (docs/telephony/MEETINGS.md). Midnight
   Graphite tokens from tokens.css; no inline styles anywhere (strict CSP). */

.meeting-page { margin: 0; min-height: 100vh; background: var(--page-bg, var(--bg)); color: var(--text); font-family: var(--font); }
.meeting.boot { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.meeting-card { width: min(560px, 100%); }
.meeting-card h1 { font-size: var(--t-xl); margin: 0; letter-spacing: -.015em; }
.meeting-card .eyebrow { color: var(--accent-text); font-size: var(--t-xs); font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.meeting-people { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.meeting-people li { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--radius-sm); background: var(--surface-2); }
.meeting-warn { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm);
  background: var(--warn-soft); color: var(--warn); font-size: var(--t-sm); }
.meeting-pick { max-height: 50vh; overflow: auto; }

/* Live room: everything fits the window (no page scroll); videos are
   positioned absolutely so their intrinsic size never grows the grid. */
.meeting.in-room { height: 100vh; display: flex; flex-direction: column; gap: 10px;
  padding: 12px 16px 14px; box-sizing: border-box; overflow: hidden; }
.meeting-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.meeting-title { display: flex; align-items: baseline; gap: 12px; min-width: 0; flex-wrap: wrap; }
.meeting-title strong { font-size: var(--t-lg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 60vw; }
.meeting-banners { display: grid; gap: 6px; }
.meeting-banners:empty { display: none; }
.meeting-banner { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 9px 12px; border-radius: var(--radius-sm);
  background: var(--accent-soft); color: var(--accent-soft-ink, var(--text)); font-size: var(--t-sm);
  box-shadow: inset 0 0 0 1px var(--accent-line, transparent); }
.meeting-banner[data-banner="call"] { background: var(--warn-soft); color: var(--warn); box-shadow: none; }
.meeting-body { flex: 1 1 auto; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: minmax(0, 1fr);
  gap: 12px; min-height: 0; overflow: hidden; }
.meeting-panel { width: 300px; overflow: auto; }
.meeting-panel[hidden] { display: none; }
.meeting-stage { min-height: 0; min-width: 0; height: 100%; display: grid; gap: 10px; overflow: hidden; }
.meeting-stage.mode-grid { grid-template-rows: minmax(0, 1fr); }
.meeting-stage.mode-presenter { grid-template-rows: minmax(0, 1fr) 112px; }
.meeting-audio { display: none; }

.meeting .grid { display: grid; gap: 10px; min-height: 0; height: 100%; grid-auto-rows: minmax(0, 1fr); }
.meeting .grid.cols-1 { grid-template-columns: minmax(0, 1fr); }
.meeting .grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.meeting .grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.meeting .grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.meeting .grid.cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }

.meeting .tile { position: relative; min-width: 0; min-height: 0; height: 100%; border-radius: var(--radius); overflow: hidden;
  display: grid; place-items: center; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--border);
  transition: box-shadow .15s ease; }
.meeting .tile.speaking { box-shadow: inset 0 0 0 2px var(--ok), 0 0 18px -6px var(--ok); }
.meeting .tile.hand { box-shadow: inset 0 0 0 2px var(--warn); }
.meeting .tile-avatar { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent-text); font-weight: 600; font-size: var(--t-xl); }
.meeting .tile-video, .meeting .presenter-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }
.meeting .presenter-video { object-fit: contain; }
.meeting .tile-name { position: absolute; left: 8px; bottom: 8px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  font-size: var(--t-xs); padding: 4px 8px; border-radius: var(--pill); background: var(--overlay); color: var(--text);
  max-width: calc(100% - 16px); }
.meeting .tile-hand { color: var(--warn); display: inline-flex; }

.meeting .presenter { position: relative; min-height: 0; height: 100%; border-radius: var(--radius); overflow: hidden; background: #000; }
.meeting .presenter-label { position: absolute; left: 10px; top: 10px; display: flex; gap: 6px; align-items: center; padding: 4px 10px;
  border-radius: var(--pill); background: var(--overlay); font-size: var(--t-xs); z-index: 1; }
.meeting .strip { display: grid; grid-auto-flow: column; grid-auto-columns: 180px; gap: 8px; overflow-x: auto; overflow-y: hidden; min-height: 0; }
.meeting .strip .tile-avatar { width: 40px; height: 40px; font-size: var(--t-sm); }
.meeting .strip .tile-name { left: 6px; bottom: 6px; }

.meeting-controls { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.meeting .ctl { display: inline-grid; justify-items: center; gap: 4px; min-width: 76px; padding: 8px 10px; border: 0; border-radius: var(--radius-sm);
  background: var(--surface-2); color: var(--text); font: inherit; font-size: var(--t-2xs, 11px); cursor: pointer; }
.meeting .ctl:hover { background: var(--surface-3); }
.meeting .ctl.active { background: var(--accent-soft); color: var(--accent-text); }
.meeting .ctl.danger { background: var(--danger-soft); color: var(--danger); }
.meeting .ctl:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.meeting .ctl .icon { width: 20px; height: 20px; }

@media (max-width: 720px) {
  .meeting.in-room { padding: 8px; }
  .meeting-body { grid-template-columns: 1fr; }
  .meeting-panel { width: auto; }
  .meeting .grid.cols-3, .meeting .grid.cols-4, .meeting .grid.cols-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meeting .ctl { min-width: 56px; }
  .meeting .ctl span { display: none; }
}

/* Chat + console: the meeting card ("Anna start een gesprek — Deelnemen") */
.meeting-card-msg { display: flex; gap: 12px; align-items: center; padding: 10px 12px; margin-top: 6px; border-radius: var(--radius-sm);
  background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--border); max-width: 520px; }
.meeting-card-msg.is-live { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ok) 40%, transparent); }
.meeting-card-msg .mc-icon { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); flex: none; }
.meeting-list { display: grid; gap: 10px; }
.meeting-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
.meeting-row .who { color: var(--muted); font-size: var(--t-sm); }

/* Presence dots in the meeting window (same look as the team chat, chat.css). */
.meeting .pdot { width: 9px; height: 9px; border-radius: 50%; flex: none; display: inline-block; background: var(--muted); opacity: .55; }
.meeting .pdot.p-beschikbaar { background: var(--ok); opacity: 1; }
.meeting .pdot.p-online { background: transparent; opacity: 1; box-shadow: inset 0 0 0 2px var(--ok); }
.meeting .pdot.p-in_gesprek { background: var(--accent); opacity: 1; }
.meeting .pdot.p-pauze, .meeting .pdot.p-nawerk { background: var(--warn); opacity: 1; }

/* Screen sharing from a call (meeting_share.js): screen only, no tiles. */
.meeting.share-mode .share-note { margin: 0; }
.meeting.share-mode .share-stage { grid-template-rows: minmax(0, 1fr); }
.meeting.share-mode .share-stage .empty, .meeting.share-mode .share-ended { display: grid; place-items: center; height: 100%;
  text-align: center; color: var(--muted); padding: 24px; border-radius: var(--radius); background: var(--surface-2); }
.meeting.share-mode .meeting-controls .btn { display: inline-flex; align-items: center; gap: 6px; }
.meeting.share-mode .meeting-controls .icon { width: 18px; height: 18px; }

/* ---------------------------------------------------------------- planner (views/meetings.js) */
.agenda-group h3 { margin: 0 0 8px; font-size: var(--t-sm); color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.agenda-list { display: grid; gap: 8px; }
.agenda-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 10px 12px; border-radius: var(--radius-sm);
  background: var(--surface-2); }
.agenda-row.is-past { opacity: .6; }
.agenda-row.is-cancelled .agenda-title strong { text-decoration: line-through; }
.agenda-when { display: grid; min-width: 110px; }
.agenda-title { display: grid; min-width: 0; color: var(--text); text-decoration: none; }
.agenda-title:hover strong, .agenda-title:focus-visible strong { text-decoration: underline; }
.agenda-text p { margin: 0 0 4px; }
.answer-row { gap: 6px; flex-wrap: wrap; }
.meeting-card-msg.planned { align-items: flex-start; }
.meeting-card-msg.is-cancelled strong { text-decoration: line-through; }
.meeting-alert { display: grid; gap: 6px; }
.facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; margin: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.plain-list { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
.row.wrap { flex-wrap: wrap; }
.week-view { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 6px; overflow-x: auto; }
.week-hours { display: grid; grid-auto-rows: 1fr; padding-top: 28px; min-height: 480px; font-size: var(--t-xs); color: var(--muted); }
.week-days { display: grid; grid-template-columns: repeat(7, minmax(92px, 1fr)); gap: 6px; min-width: 660px; }
.week-day { display: grid; grid-template-rows: 22px minmax(480px, 1fr); gap: 6px; }
.week-day-head { font-size: var(--t-xs); font-weight: 600; color: var(--muted); text-align: center; }
.week-day.is-today .week-day-head { color: var(--accent-text); }
.week-day-body { position: relative; border-radius: var(--radius-xs); background: var(--surface-2); }
.week-item { position: absolute; left: 3px; right: 3px; display: grid; align-content: start; gap: 1px; overflow: hidden;
  padding: 3px 6px; border-radius: var(--radius-xs); background: var(--accent-soft); color: var(--text); font-size: var(--t-xs);
  box-shadow: inset 2px 0 0 var(--accent); text-decoration: none; }
.week-item:hover, .week-item:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.week-item.is-cancelled { opacity: .55; text-decoration: line-through; }
.week-item strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 720px) {
  .agenda-when { min-width: 0; }
  .agenda-row { gap: 8px; }
}
.week-item.top-0 { top: 0%; }
.week-item.h-0 { height: 0%; }
.week-item.top-2 { top: 2%; }
.week-item.h-2 { height: 2%; }
.week-item.top-4 { top: 4%; }
.week-item.h-4 { height: 4%; }
.week-item.top-6 { top: 6%; }
.week-item.h-6 { height: 6%; }
.week-item.top-8 { top: 8%; }
.week-item.h-8 { height: 8%; }
.week-item.top-10 { top: 10%; }
.week-item.h-10 { height: 10%; }
.week-item.top-12 { top: 12%; }
.week-item.h-12 { height: 12%; }
.week-item.top-14 { top: 14%; }
.week-item.h-14 { height: 14%; }
.week-item.top-16 { top: 16%; }
.week-item.h-16 { height: 16%; }
.week-item.top-18 { top: 18%; }
.week-item.h-18 { height: 18%; }
.week-item.top-20 { top: 20%; }
.week-item.h-20 { height: 20%; }
.week-item.top-22 { top: 22%; }
.week-item.h-22 { height: 22%; }
.week-item.top-24 { top: 24%; }
.week-item.h-24 { height: 24%; }
.week-item.top-26 { top: 26%; }
.week-item.h-26 { height: 26%; }
.week-item.top-28 { top: 28%; }
.week-item.h-28 { height: 28%; }
.week-item.top-30 { top: 30%; }
.week-item.h-30 { height: 30%; }
.week-item.top-32 { top: 32%; }
.week-item.h-32 { height: 32%; }
.week-item.top-34 { top: 34%; }
.week-item.h-34 { height: 34%; }
.week-item.top-36 { top: 36%; }
.week-item.h-36 { height: 36%; }
.week-item.top-38 { top: 38%; }
.week-item.h-38 { height: 38%; }
.week-item.top-40 { top: 40%; }
.week-item.h-40 { height: 40%; }
.week-item.top-42 { top: 42%; }
.week-item.h-42 { height: 42%; }
.week-item.top-44 { top: 44%; }
.week-item.h-44 { height: 44%; }
.week-item.top-46 { top: 46%; }
.week-item.h-46 { height: 46%; }
.week-item.top-48 { top: 48%; }
.week-item.h-48 { height: 48%; }
.week-item.top-50 { top: 50%; }
.week-item.h-50 { height: 50%; }
.week-item.top-52 { top: 52%; }
.week-item.h-52 { height: 52%; }
.week-item.top-54 { top: 54%; }
.week-item.h-54 { height: 54%; }
.week-item.top-56 { top: 56%; }
.week-item.h-56 { height: 56%; }
.week-item.top-58 { top: 58%; }
.week-item.h-58 { height: 58%; }
.week-item.top-60 { top: 60%; }
.week-item.h-60 { height: 60%; }
.week-item.top-62 { top: 62%; }
.week-item.h-62 { height: 62%; }
.week-item.top-64 { top: 64%; }
.week-item.h-64 { height: 64%; }
.week-item.top-66 { top: 66%; }
.week-item.h-66 { height: 66%; }
.week-item.top-68 { top: 68%; }
.week-item.h-68 { height: 68%; }
.week-item.top-70 { top: 70%; }
.week-item.h-70 { height: 70%; }
.week-item.top-72 { top: 72%; }
.week-item.h-72 { height: 72%; }
.week-item.top-74 { top: 74%; }
.week-item.h-74 { height: 74%; }
.week-item.top-76 { top: 76%; }
.week-item.h-76 { height: 76%; }
.week-item.top-78 { top: 78%; }
.week-item.h-78 { height: 78%; }
.week-item.top-80 { top: 80%; }
.week-item.h-80 { height: 80%; }
.week-item.top-82 { top: 82%; }
.week-item.h-82 { height: 82%; }
.week-item.top-84 { top: 84%; }
.week-item.h-84 { height: 84%; }
.week-item.top-86 { top: 86%; }
.week-item.h-86 { height: 86%; }
.week-item.top-88 { top: 88%; }
.week-item.h-88 { height: 88%; }
.week-item.top-90 { top: 90%; }
.week-item.h-90 { height: 90%; }
.week-item.top-92 { top: 92%; }
.week-item.h-92 { height: 92%; }
.week-item.top-94 { top: 94%; }
.week-item.h-94 { height: 94%; }
.week-item.top-96 { top: 96%; }
.week-item.h-96 { height: 96%; }
.week-item.top-98 { top: 98%; }
.week-item.h-98 { height: 98%; }
.week-item.top-100 { top: 100%; }
.week-item.h-100 { height: 100%; }

/* the plan form toggles fields with [hidden] */
.field[hidden], .agenda-row[hidden], .check[hidden] { display: none; }
