/* ==========================================================================
   16-maintmanage.css — THE PRODUCTION MAINTENANCE SCHEDULE

   The same bones as 📌 Speaker's Record ▸ Appearances, which is what was
   asked for: a rounded card, a sticky heading row in small cyan capitals,
   gold for the column you scan by, thin separators, the whole row clickable,
   and the detail opening underneath rather than in a second dialog.
   ========================================================================== */

.mm-note { font-size: 11px; color: var(--muted); line-height: 1.55; margin-bottom: 12px; }
.mm-note strong { color: var(--white); }
.mm-note em { color: var(--cyan); font-style: normal; }

.mm-locked {
  display: flex; align-items: center; gap: 10px;
  font-size: 11px; color: var(--gold); line-height: 1.5;
  background: rgba(201, 168, 76, .12); border: 1.5px solid rgba(201, 168, 76, .35);
  border-radius: 6px; padding: 9px 12px; margin-bottom: 12px;
}
.mm-locked strong { color: var(--white); }

/* ---- the three rooms ---------------------------------------------------- */
.mm-tabs { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.mm-tab {
  background: var(--navy2); border: 1px solid var(--c-border); color: var(--muted);
  border-radius: 5px; padding: 6px 12px; font-size: 11px; cursor: pointer;
  min-height: 32px; letter-spacing: .3px;
}
.mm-tab:hover { color: var(--white); border-color: var(--cyan); }
.mm-tab.is-on { background: rgba(0, 180, 216, .15); border-color: var(--cyan); color: var(--cyan); font-weight: bold; }

/* ---- the controls ------------------------------------------------------- */
.mm-controls {
  display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap;
}
.mm-search, .mm-select {
  background: var(--navy2); border: 1px solid var(--c-border); color: var(--white);
  border-radius: 5px; padding: 7px 10px; font-size: 11px; min-height: 34px;
}
.mm-search { flex: 1 1 240px; min-width: 0; }
.mm-select { max-width: 420px; }
.mm-count { font-size: 10px; color: var(--muted); white-space: nowrap; }
.mm-sm { padding: 6px 12px; font-size: 10.5px; min-height: 32px; }
.mm-danger { border-color: rgba(239, 68, 68, .55); color: #fca5a5; }
.mm-danger:hover { border-color: var(--red); color: #fff; }

.mm-add {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  background: var(--navy2); border: 1px solid var(--c-border);
  border-radius: 6px; padding: 8px 12px; margin-bottom: 12px;
}
.mm-add-q { font-size: 10.5px; color: var(--muted); }

/* ---- the table ---------------------------------------------------------- */
.mm-card {
  background: var(--navy); border: 1px solid var(--c-border);
  border-radius: 6px; overflow: hidden; box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}
.mm-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.mm-table { width: 100%; text-align: left; border-collapse: collapse; font-size: 11px; }

.mm-table thead th {
  position: sticky; top: 0; z-index: 3;
  background: var(--navy2); color: var(--cyan);
  font-size: 9px; text-transform: uppercase; letter-spacing: .5px;
  border-bottom: 1px solid rgba(255, 255, 255, .2);
  padding: 7px 8px; cursor: pointer; user-select: none;
  transition: color .15s;
}
.mm-table thead th:hover { color: var(--white); }
.mm-sort-mark { font-size: .85em; opacity: .9; }

.mm-tr { cursor: pointer; border-bottom: 1px solid rgba(255, 255, 255, .05); transition: background .15s; }
.mm-tr:hover { background: rgba(0, 180, 216, .07); }
.mm-tr.is-open { background: rgba(0, 180, 216, .15); }
.mm-tr td { padding: 6px 8px; vertical-align: top; }

.mm-num     { color: var(--muted); font-family: monospace; }
.mm-date    { color: var(--gold); font-weight: bold; white-space: nowrap; }
.mm-time    { font-size: 9px; color: var(--muted); margin-left: 4px; font-weight: normal; }
.mm-task    { color: var(--white); font-weight: 500; }
.mm-speaker { color: var(--cyan); }
.mm-event   { color: var(--muted); }
.mm-dim     { color: var(--muted); font-style: italic; }

/* A task whose moment has passed but which nobody has filed yet. Quieter,
   not hidden: it is still on the schedule, it is just behind. */
.mm-tr.is-done .mm-task { color: #cbd5e1; }

.mm-pill {
  display: inline-block; font-size: 9px; font-weight: bold;
  padding: 2px 7px; border-radius: 3px; white-space: nowrap;
}
.mm-pill-cyan  { background: rgba(0, 180, 216, .18); color: var(--cyan); }
.mm-pill-green { background: rgba(34, 197, 94, .18); color: #86efac; }
.mm-pill-grey  { background: rgba(148, 163, 184, .18); color: var(--muted); }
.mm-pill-red   { background: rgba(239, 68, 68, .18); color: #fca5a5; }

/* ---- the row opened out -------------------------------------------------- */
.mm-detail-row td { background: rgba(0, 0, 0, .25); padding: 0 !important; }
.mm-detail { padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.mm-whose { font-size: 10.5px; color: var(--muted); }
.mm-whose strong { color: var(--white); }

.mm-fields { display: grid; grid-template-columns: 170px 170px 1fr; gap: 10px; }
.mm-f { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mm-f span { font-size: 9.5px; color: var(--cyan); text-transform: uppercase; letter-spacing: .5px; font-weight: bold; }
.mm-f input, .mm-f textarea {
  background: var(--navy2); border: 1px solid var(--c-border); color: var(--white);
  border-radius: 4px; padding: 7px 9px; font-size: 11px; font-family: inherit; min-height: 32px;
}
.mm-f textarea { resize: vertical; }
.mm-ro { font-size: 11px; color: var(--muted); }

.mm-acts { display: flex; gap: 8px; flex-wrap: wrap; }

.mm-empty {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 28px 16px; color: var(--muted); font-size: 12px; text-align: center;
  background: var(--navy); border: 1px dashed var(--c-border); border-radius: 6px;
}
.mm-empty > :first-child { font-size: 26px; }

@media (max-width: 760px) {
  .mm-fields { grid-template-columns: 1fr; }
  .mm-select { max-width: none; width: 100%; }
}
@media print {
  .mm-table thead th { position: static; cursor: default; }
  .mm-sort-mark, .mm-acts, .mm-tabs, .mm-controls, .mm-add { display: none !important; }
}
