body { background:#f3f5f9; }
.card { border-radius: .75rem; }
.navbar-brand { letter-spacing:-.2px; }
.table td, .table th { vertical-align: middle; }
.assignment-mine { background:#fff8db !important; border-left:4px solid #f0ad00; }
.meeting-section { border-left:4px solid #0d6efd; padding-left: .75rem; margin-top:1.25rem; }
.badge-soft { background:#eef2ff; color:#1d4ed8; }
.program-line { padding:.65rem .75rem; border-bottom:1px solid #e5e7eb; }
.program-line:last-child { border-bottom:0; }
@media (max-width: 768px) {
  .container-fluid { padding-left:.75rem; padding-right:.75rem; }
  .table-responsive { font-size:.95rem; }
  .program-line { padding:.75rem .25rem; }
}

.program-cleaning-groups {
  margin-top: .85rem;
  padding: .7rem .85rem;
  border-left: 4px solid #6c757d;
  background: rgba(108, 117, 125, .08);
  font-size: .95rem;
}
.program-cleaning-group { display: inline; }

/* Plan organizacyjny */
.org-plan .card-header {
  background: rgba(0,0,0,.035);
  border-bottom: 1px solid rgba(0,0,0,.08);
}
.org-plan .org-item {
  background: rgba(255,255,255,.72);
}
.theme-jw_dark .org-plan .card,
.theme-dark .org-plan .card {
  background: rgba(255,255,255,.05);
}
.theme-jw_dark .org-plan .card-header,
.theme-dark .org-plan .card-header {
  background: rgba(255,255,255,.08);
  border-bottom-color: rgba(255,255,255,.12);
}
.theme-jw_dark .org-plan .org-item,
.theme-dark .org-plan .org-item {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.14) !important;
}

/* Użytkownicy: grupowanie ról/funkcji */
.role-groups .accordion-item {
  border-color: rgba(0,0,0,.12);
}
.role-groups .accordion-button {
  padding: .55rem .75rem;
  font-weight: 700;
  font-size: .95rem;
}
.role-groups .accordion-body {
  padding: .65rem .75rem;
}
.role-checkbox-list .form-check {
  margin-bottom: .32rem;
}

.role-checkbox-list {
  display: block;
}
.role-checkbox-list .role-check-row,
.role-checkbox-list .form-check {
  display: block;
  margin-left: 0;
  margin-right: 0;
}
.role-checkbox-list .form-check-inline {
  display: block;
}

/* Fix26: bardziej dopracowany UI ról/przywilejów */
.role-groups-pro {
  --role-radius: 1rem;
  --role-border: rgba(13, 110, 253, .16);
  --role-bg: rgba(255,255,255,.78);
  --role-selected-bg: rgba(13,110,253,.08);
  --role-selected-border: rgba(13,110,253,.45);
  --role-shadow: 0 12px 28px rgba(15,23,42,.08);
}
.role-groups-pro .role-group-card {
  border: 1px solid var(--role-border);
  border-radius: var(--role-radius) !important;
  overflow: hidden;
  background: var(--role-bg);
  box-shadow: 0 5px 18px rgba(15,23,42,.04);
  margin-bottom: .85rem;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.role-groups-pro .role-group-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--role-shadow);
  border-color: rgba(13,110,253,.28);
}
.role-groups-pro .role-group-button {
  gap: .75rem;
  padding: .85rem .95rem;
  background: linear-gradient(135deg, rgba(255,255,255,.95), rgba(248,250,252,.88));
  box-shadow: none;
}
.role-groups-pro .role-group-button:not(.collapsed) {
  background: linear-gradient(135deg, rgba(13,110,253,.10), rgba(255,255,255,.88));
  color: inherit;
}
.role-groups-pro .role-group-icon {
  width: 2.25rem;
  height: 2.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: .85rem;
  background: rgba(13,110,253,.10);
  font-size: 1.1rem;
}
.role-groups-pro .role-group-title-wrap {
  min-width: 0;
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.role-groups-pro .role-group-title {
  font-weight: 800;
  letter-spacing: -.01em;
}
.role-groups-pro .role-group-subtitle {
  margin-top: .25rem;
  font-size: .78rem;
  font-weight: 500;
  color: #64748b;
}
.role-groups-pro .role-selected-count {
  margin-left: auto;
  margin-right: .35rem;
  min-width: 1.75rem;
  height: 1.75rem;
  padding: 0 .45rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #0d6efd;
  color: #fff;
  font-size: .78rem;
  font-weight: 800;
  box-shadow: 0 7px 16px rgba(13,110,253,.25);
  transition: background-color .18s ease, transform .18s ease, opacity .18s ease;
}
.role-groups-pro .role-selected-count.is-empty {
  background: #94a3b8;
  opacity: .7;
  box-shadow: none;
}
.role-groups-pro .role-group-body {
  padding: .95rem;
  animation: roleFadeIn .24s ease both;
}
.role-card-list {
  display: grid !important;
  grid-template-columns: 1fr;
  gap: .62rem;
}
.role-card-list .role-choice {
  position: relative;
  display: flex !important;
  align-items: flex-start;
  gap: .7rem;
  min-height: 3.25rem;
  margin: 0 !important;
  padding: .72rem .82rem .72rem 2.65rem;
  border: 1px solid rgba(148,163,184,.36);
  border-radius: .85rem;
  background: rgba(255,255,255,.74);
  cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .16s ease;
  animation: roleSlideIn .22s ease both;
}
.role-card-list .role-choice:hover {
  transform: translateY(-1px);
  border-color: rgba(13,110,253,.36);
  box-shadow: 0 10px 20px rgba(15,23,42,.07);
}
.role-card-list .role-choice.is-selected {
  background: var(--role-selected-bg);
  border-color: var(--role-selected-border);
  box-shadow: 0 8px 22px rgba(13,110,253,.10);
}
.role-card-list .role-choice-input {
  position: absolute;
  left: .82rem;
  top: .92rem;
  width: 1.15rem;
  height: 1.15rem;
  margin: 0;
  cursor: pointer;
}
.role-card-list .role-choice-label {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: .16rem;
  width: 100%;
}
.role-card-list .role-choice-main {
  font-weight: 750;
  color: #0f172a;
}
.role-card-list .role-choice-hint {
  font-size: .78rem;
  color: #64748b;
  line-height: 1.28;
}
.collapse .role-card-list .role-choice:nth-child(1) { animation-delay: 0ms; }
.collapse .role-card-list .role-choice:nth-child(2) { animation-delay: 20ms; }
.collapse .role-card-list .role-choice:nth-child(3) { animation-delay: 40ms; }
.collapse .role-card-list .role-choice:nth-child(4) { animation-delay: 60ms; }
.collapse .role-card-list .role-choice:nth-child(5) { animation-delay: 80ms; }
.collapse .role-card-list .role-choice:nth-child(n+6) { animation-delay: 100ms; }
tr.collapse.show td > form {
  animation: roleFadeIn .22s ease both;
}
@keyframes roleFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes roleSlideIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .role-groups-pro *,
  tr.collapse.show td > form {
    transition: none !important;
    animation: none !important;
  }
}
.theme-jw_dark .role-groups-pro,
.theme-dark .role-groups-pro {
  --role-border: rgba(255,255,255,.12);
  --role-bg: rgba(255,255,255,.055);
  --role-selected-bg: rgba(91,141,239,.18);
  --role-selected-border: rgba(91,141,239,.58);
  --role-shadow: 0 16px 32px rgba(0,0,0,.25);
}
.theme-jw_dark .role-groups-pro .role-group-button,
.theme-dark .role-groups-pro .role-group-button {
  background: linear-gradient(135deg, rgba(255,255,255,.09), rgba(255,255,255,.035));
  color: #e5e7eb;
}
.theme-jw_dark .role-groups-pro .role-group-button:not(.collapsed),
.theme-dark .role-groups-pro .role-group-button:not(.collapsed) {
  background: linear-gradient(135deg, rgba(91,141,239,.20), rgba(255,255,255,.06));
}
.theme-jw_dark .role-groups-pro .role-group-subtitle,
.theme-dark .role-groups-pro .role-group-subtitle,
.theme-jw_dark .role-card-list .role-choice-hint,
.theme-dark .role-card-list .role-choice-hint {
  color: rgba(229,231,235,.72);
}
.theme-jw_dark .role-card-list .role-choice,
.theme-dark .role-card-list .role-choice {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.12);
}
.theme-jw_dark .role-card-list .role-choice-main,
.theme-dark .role-card-list .role-choice-main {
  color: #f8fafc;
}
.theme-jw_dark tr.collapse form.bg-light,
.theme-dark tr.collapse form.bg-light {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.13) !important;
}
@media (min-width: 992px) {
  .role-card-list {
    grid-template-columns: 1fr 1fr;
  }
  .role-group-basic .role-card-list,
  .role-group-system .role-card-list {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 576px) {
  .role-groups-pro .role-group-button {
    padding: .72rem .8rem;
  }
  .role-groups-pro .role-group-subtitle,
  .role-card-list .role-choice-hint {
    display: none;
  }
  .role-card-list .role-choice {
    min-height: auto;
    padding-top: .62rem;
    padding-bottom: .62rem;
  }
}

/* Fix27 - rozbudowany moduł mówców */
.speaker-module .card { overflow: hidden; }
.speaker-filter .form-label { font-weight: 650; font-size: .82rem; }
.speaker-list { display: grid; gap: .85rem; }
.speaker-list-card {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 1rem;
  border: 1px solid rgba(0,0,0,.10);
  border-radius: 16px;
  background: rgba(255,255,255,.72);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(0,0,0,.045);
  transform: translateY(0);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}
.speaker-list-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 38px rgba(0,0,0,.09);
  border-color: rgba(73, 92, 140, .35);
  background: rgba(255,255,255,.92);
  color: inherit;
}
.speaker-list-main { display: flex; align-items: center; gap: .85rem; min-width: 0; }
.speaker-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  letter-spacing: .02em;
  background: linear-gradient(135deg, rgba(74,105,189,.18), rgba(74,105,189,.36));
  color: #263b76;
  flex: 0 0 auto;
}
.speaker-list-meta {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
  justify-content: flex-end;
  min-width: 170px;
}
.speaker-list-meta span,
.speaker-stats span {
  display: inline-flex;
  align-items: center;
  padding: .28rem .55rem;
  border-radius: 999px;
  background: rgba(0,0,0,.055);
  font-size: .78rem;
  white-space: nowrap;
}
.speaker-profile-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(66, 99, 235, .12), rgba(116, 185, 255, .10));
  border: 1px solid rgba(66, 99, 235, .12);
}
.speaker-stats { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .4rem; }
.speaker-talk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: .85rem;
}
.speaker-talk-card {
  padding: .9rem;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,.10);
  background: rgba(255,255,255,.74);
  box-shadow: 0 10px 26px rgba(0,0,0,.04);
  animation: speakerFadeIn .24s ease both;
}
.speaker-talk-no {
  display: inline-flex;
  align-items: center;
  gap: .1rem;
  padding: .15rem .45rem;
  border-radius: 999px;
  background: rgba(0,0,0,.075);
  font-weight: 800;
  margin-bottom: .45rem;
}
.speaker-talk-no input {
  width: 50px;
  border: 0;
  background: transparent;
  font-weight: 800;
  outline: none;
}
@keyframes speakerFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (max-width: 768px) {
  .speaker-list-card { align-items: flex-start; flex-direction: column; }
  .speaker-list-meta { justify-content: flex-start; min-width: 0; }
  .speaker-profile-header { flex-direction: column; }
  .speaker-stats { justify-content: flex-start; }
}
@media print {
  nav, .navbar, .btn, .speaker-filter, .speaker-list, form[action] button, .alert { display: none !important; }
  .speaker-module .card { border: 0 !important; box-shadow: none !important; }
  body { background: #fff !important; color: #000 !important; }
}
[data-theme="jw_dark"] .speaker-list-card,
[data-theme="dark"] .speaker-list-card,
.theme-jw_dark .speaker-list-card,
.theme-dark .speaker-list-card,
body.jw_dark .speaker-list-card,
body.dark .speaker-list-card {
  background: rgba(31,35,41,.72);
  border-color: rgba(255,255,255,.10);
}
[data-theme="jw_dark"] .speaker-list-card:hover,
[data-theme="dark"] .speaker-list-card:hover,
.theme-jw_dark .speaker-list-card:hover,
.theme-dark .speaker-list-card:hover,
body.jw_dark .speaker-list-card:hover,
body.dark .speaker-list-card:hover {
  background: rgba(39,44,52,.92);
  border-color: rgba(127,166,255,.35);
}
[data-theme="jw_dark"] .speaker-avatar,
[data-theme="dark"] .speaker-avatar,
.theme-jw_dark .speaker-avatar,
.theme-dark .speaker-avatar,
body.jw_dark .speaker-avatar,
body.dark .speaker-avatar {
  background: linear-gradient(135deg, rgba(118,158,255,.25), rgba(45,52,70,.65));
  color: #d9e5ff;
}
[data-theme="jw_dark"] .speaker-talk-card,
[data-theme="dark"] .speaker-talk-card,
.theme-jw_dark .speaker-talk-card,
.theme-dark .speaker-talk-card,
body.jw_dark .speaker-talk-card,
body.dark .speaker-talk-card {
  background: rgba(31,35,41,.72);
  border-color: rgba(255,255,255,.10);
}
[data-theme="jw_dark"] .speaker-profile-header,
[data-theme="dark"] .speaker-profile-header,
.theme-jw_dark .speaker-profile-header,
.theme-dark .speaker-profile-header,
body.jw_dark .speaker-profile-header,
body.dark .speaker-profile-header {
  background: linear-gradient(135deg, rgba(118,158,255,.16), rgba(45,52,70,.62));
  border-color: rgba(255,255,255,.10);
}


/* Organization plan title toolbar */
.org-title-toolbar{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:.5rem;
  flex-wrap:nowrap;
  max-width:100%;
}
.org-title-form{
  display:flex;
  align-items:center;
  gap:.5rem;
  flex-wrap:nowrap;
  min-width:0;
}
.org-title-input{
  width:min(420px, 42vw);
  min-width:280px;
}
.org-title-action,.org-title-save{
  white-space:nowrap;
}
@media (max-width: 760px){
  .org-title-toolbar{
    justify-content:flex-start;
    flex-wrap:wrap;
  }
  .org-title-form{
    flex:1 1 100%;
  }
  .org-title-input{
    width:100%;
    min-width:0;
  }
}


/* Fix38 - prostszy, czytelniejszy wybór ról bez opisów */
.role-groups-simple {
  --role-radius: .75rem;
  --role-border: rgba(108,117,125,.22);
  --role-bg: rgba(255,255,255,.84);
  --role-selected-bg: rgba(13,110,253,.07);
  --role-selected-border: rgba(13,110,253,.32);
}
.role-groups-simple .role-group-card {
  border: 1px solid var(--role-border);
  border-radius: var(--role-radius) !important;
  overflow: hidden;
  background: var(--role-bg);
  box-shadow: none;
  margin-bottom: .65rem;
}
.role-groups-simple .role-group-card:hover {
  transform: none;
  box-shadow: none;
}
.role-groups-simple .role-group-button {
  padding: .62rem .8rem;
  background: rgba(248,249,250,.78);
  box-shadow: none;
  gap: .6rem;
}
.role-groups-simple .role-group-button:not(.collapsed) {
  background: rgba(13,110,253,.055);
  color: inherit;
}
.role-groups-simple .role-group-title {
  font-weight: 650;
  font-size: .95rem;
}
.role-groups-simple .role-selected-count {
  margin-left: auto;
  margin-right: .35rem;
  min-width: 1.45rem;
  height: 1.45rem;
  padding: 0 .38rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #0d6efd;
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  box-shadow: none;
}
.role-groups-simple .role-selected-count.is-empty {
  background: #adb5bd;
  opacity: .85;
}
.role-groups-simple .role-group-body {
  padding: .6rem .75rem .75rem;
  animation: roleFadeIn .18s ease both;
}
.role-groups-simple .role-card-list {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: .35rem;
}
.role-groups-simple .role-choice {
  position: relative;
  display: flex !important;
  align-items: center;
  min-height: auto;
  margin: 0 !important;
  padding: .48rem .65rem .48rem 2.25rem;
  border: 1px solid rgba(148,163,184,.32);
  border-radius: .55rem;
  background: rgba(255,255,255,.64);
  cursor: pointer;
  box-shadow: none;
  transition: background-color .15s ease, border-color .15s ease;
  animation: roleSlideIn .16s ease both;
}
.role-groups-simple .role-choice:hover {
  transform: none;
  box-shadow: none;
  border-color: rgba(13,110,253,.28);
  background: rgba(248,250,252,.92);
}
.role-groups-simple .role-choice.is-selected {
  background: var(--role-selected-bg);
  border-color: var(--role-selected-border);
  box-shadow: none;
}
.role-groups-simple .role-choice-input {
  position: absolute;
  left: .65rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1rem;
  height: 1rem;
  margin: 0;
  cursor: pointer;
}
.role-groups-simple .role-choice-label {
  cursor: pointer;
  display: block;
  width: 100%;
}
.role-groups-simple .role-choice-main {
  font-weight: 500;
  color: #0f172a;
  line-height: 1.25;
}
.role-groups-simple .role-choice-hint,
.role-groups-simple .role-group-subtitle,
.role-groups-simple .role-group-icon,
.role-groups-simple .role-group-title-wrap {
  display: none !important;
}
.theme-jw_dark .role-groups-simple,
.theme-dark .role-groups-simple {
  --role-border: rgba(255,255,255,.12);
  --role-bg: rgba(255,255,255,.045);
  --role-selected-bg: rgba(91,141,239,.14);
  --role-selected-border: rgba(91,141,239,.42);
}
.theme-jw_dark .role-groups-simple .role-group-button,
.theme-dark .role-groups-simple .role-group-button {
  background: rgba(255,255,255,.055);
  color: #e5e7eb;
}
.theme-jw_dark .role-groups-simple .role-group-button:not(.collapsed),
.theme-dark .role-groups-simple .role-group-button:not(.collapsed) {
  background: rgba(91,141,239,.13);
}
.theme-jw_dark .role-groups-simple .role-choice,
.theme-dark .role-groups-simple .role-choice {
  background: rgba(255,255,255,.055);
  border-color: rgba(255,255,255,.12);
}
.theme-jw_dark .role-groups-simple .role-choice:hover,
.theme-dark .role-groups-simple .role-choice:hover {
  background: rgba(255,255,255,.08);
}
.theme-jw_dark .role-groups-simple .role-choice-main,
.theme-dark .role-groups-simple .role-choice-main {
  color: #f8fafc;
}

/* Fix40: wspólny, dopracowany layout Planu zebrań dla wszystkich motywów.
   jw_light/jw_dark nadal mogą nadpisywać kolory, ale pozostałe motywy dostają ten sam układ programu. */
body {
  --program-bg: #ffffff;
  --program-panel: #ffffff;
  --program-muted-panel: #f2f4f7;
  --program-border: #d7dde5;
  --program-border-strong: #8a929c;
  --program-text: #1f2937;
  --program-muted: #5f6b7a;
  --program-blue: #2f7894;
  --program-yellow: #a36a00;
  --program-red: #bb4a42;
  --program-note-bg: rgba(47,120,148,.10);
  --program-cleaning-bg: rgba(107,114,128,.08);
  --program-mine-bg: #fff8db;
  --program-mine-border: #e2ad00;
  --program-assignee-bg: #ffffff;
  --program-assignee-border: #d8dee5;
}
body.theme-dark,
body.theme-jw_dark {
  --program-bg: #111111;
  --program-panel: #161616;
  --program-muted-panel: #252525;
  --program-border: #333333;
  --program-border-strong: #6f747a;
  --program-text: #e7e7e7;
  --program-muted: #b7bec8;
  --program-blue: #85cce0;
  --program-yellow: #f0c14b;
  --program-red: #ef7c72;
  --program-note-bg: rgba(133,204,224,.14);
  --program-cleaning-bg: rgba(255,255,255,.065);
  --program-mine-bg: #3b2f11;
  --program-mine-border: #d6a900;
  --program-assignee-bg: #1e1e1e;
  --program-assignee-border: #444;
}
body.theme-admin_blue {
  --program-blue: #2563eb;
  --program-yellow: #b7791f;
  --program-red: #dc2626;
  --program-note-bg: rgba(37,99,235,.09);
}
body.theme-warm {
  --program-bg: #fffaf0;
  --program-panel: #fffdf7;
  --program-muted-panel: #f8f0df;
  --program-border: #e6dcc7;
  --program-blue: #2b6f89;
  --program-yellow: #9a6700;
  --program-red: #a8423c;
}
body.theme-compact {
  --program-muted-panel: #f5f6f8;
}
body.theme-publisher_simple {
  --program-blue: #256f8a;
  --program-yellow: #9a6700;
  --program-red: #b04740;
}

.jw-meeting-program {
  background: var(--program-bg);
  color: var(--program-text);
  border: 1px solid var(--program-border);
  box-shadow: 0 10px 28px rgba(15,23,42,.05);
  overflow: hidden;
  max-width: 980px;
  margin: 0 auto 1.25rem;
}
.program-week-header {
  padding: 1.15rem 1.55rem .9rem;
  border-bottom: 1px solid var(--program-border-strong);
  background: var(--program-panel);
}
.program-week-range {
  font-size: 1.55rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.02em;
  color: var(--program-text);
}
.program-bible-reading {
  color: var(--program-blue);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .035em;
  margin-top: .52rem;
}
.program-meta-line {
  margin-top: .55rem;
  color: var(--program-muted);
  font-size: .94rem;
  display: flex;
  flex-wrap: wrap;
  gap: .55rem;
}
.program-week-type {
  color: var(--program-text);
  background: var(--program-muted-panel);
  border: 1px solid var(--program-border);
  padding: .12rem .48rem;
  border-radius: .28rem;
  font-weight: 600;
}
.program-special-note {
  margin-top: .75rem;
  background: var(--program-note-bg);
  border-left: 4px solid var(--program-blue);
  padding: .75rem .9rem;
  color: var(--program-text);
}
.program-empty {
  padding: 1.25rem 1.55rem;
  color: var(--program-muted);
}
.program-meeting-block {
  border-bottom: 1px solid var(--program-border);
}
.program-meeting-block:last-child { border-bottom: 0; }
.program-meeting-titlebar {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  align-items: center;
  padding: .75rem 1.55rem;
  border-bottom: 1px solid var(--program-border);
  background: var(--program-panel);
  color: var(--program-text);
}
.program-meeting-titlebar span {
  color: var(--program-muted);
  margin-left: .4rem;
}
.program-cancel-badge {
  color: #fff !important;
  background: var(--program-red);
  padding: .2rem .55rem;
  border-radius: .25rem;
  font-size: .82rem;
  font-weight: 700;
}
.program-cancel-box {
  margin: 1rem 1.55rem;
  background: rgba(187,74,66,.10);
  border-left: 4px solid var(--program-red);
  padding: .85rem;
  color: var(--program-text);
}
.program-section-heading {
  display: flex;
  align-items: center;
  gap: .48rem;
  padding: .78rem 1.55rem .58rem;
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: .01em;
  border-bottom: 1px solid var(--program-border-strong);
  background: var(--program-panel);
}
.program-section-heading .section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  color: #fff;
  font-size: .78rem;
  border-radius: .14rem;
  font-weight: 900;
}
.program-section-heading.section-treasures { color: var(--program-blue); }
.program-section-heading.section-ministry { color: var(--program-yellow); }
.program-section-heading.section-living { color: var(--program-red); }
.program-section-heading.section-weekend,
.program-section-heading.section-memorial { color: var(--program-blue); }
.program-section-heading.section-treasures .section-icon { background: var(--program-blue); }
.program-section-heading.section-ministry .section-icon { background: var(--program-yellow); }
.program-section-heading.section-living .section-icon { background: var(--program-red); }
.program-section-heading.section-weekend .section-icon,
.program-section-heading.section-memorial .section-icon { background: var(--program-blue); }
.program-section-body { background: var(--program-panel); }
.program-section-body.section-treasures { background: var(--program-muted-panel); }
.program-section-body.section-no-heading .program-item:first-child { border-top: 0; }
.program-item {
  padding: 1rem 1.55rem;
  border-bottom: 1px solid var(--program-border);
  transition: background-color .16s ease;
}
.program-item:last-child { border-bottom: 0; }
.program-item:hover { background: rgba(127,127,127,.045); }
.program-section-body.section-treasures .program-item:hover { background: rgba(127,127,127,.07); }
.program-item-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 34%);
  gap: 1rem 1.25rem;
  align-items: start;
}
.program-item-title {
  font-weight: 800;
  line-height: 1.35;
}
.program-item-no { margin-right: .25rem; }
.section-treasures .program-item-title { color: var(--program-blue); }
.section-ministry .program-item-title { color: var(--program-yellow); }
.section-living .program-item-title { color: var(--program-red); }
.program-item-icon {
  color: var(--program-muted);
  margin-right: .35rem;
}
.program-item-subline {
  margin-top: .2rem;
  color: var(--program-muted);
  font-size: .92rem;
  display: flex;
  flex-wrap: wrap;
  gap: .3rem .65rem;
}
.program-note {
  margin-top: .85rem;
  color: var(--program-text);
  font-size: .94rem;
  line-height: 1.52;
}
.program-item-assignments {
  display: flex;
  flex-direction: column;
  gap: .45rem;
  align-items: stretch;
}
.program-assignee-card {
  background: var(--program-assignee-bg);
  border: 1px solid var(--program-assignee-border);
  border-left: 3px solid var(--program-border-strong);
  border-radius: .35rem;
  padding: .42rem .6rem;
  text-align: left;
  box-shadow: none;
}
.program-section-body.section-treasures .program-assignee-card { background: var(--program-assignee-bg); }
.program-assignee-role {
  color: var(--program-muted);
  font-size: .72rem;
  font-weight: 600;
  line-height: 1.15;
  margin-bottom: .12rem;
  text-transform: none;
  letter-spacing: .01em;
}
.program-assignee-name {
  color: var(--program-text);
  font-weight: 600;
  line-height: 1.25;
}
.program-assignee-extra {
  color: var(--program-muted);
  font-size: .82rem;
  font-weight: 400;
  line-height: 1.25;
  margin-top: .12rem;
}
.program-assignee-card.is-mine,
.assignment-mine .program-assignee-card.is-mine {
  background: var(--program-mine-bg);
  border-color: var(--program-mine-border);
  border-left-color: var(--program-mine-border);
}
.assignment-mine {
  background: var(--program-mine-bg) !important;
  border-left: 5px solid var(--program-mine-border) !important;
}
.program-cleaning-groups {
  margin-top: .85rem;
  padding: .7rem .85rem;
  border-left: 4px solid var(--program-border-strong);
  background: var(--program-cleaning-bg);
  font-size: .95rem;
}
.program-cleaning-group { display: inline; }

@media (max-width: 768px) {
  .jw-meeting-program { border-left: 0; border-right: 0; max-width: none; }
  .program-week-header,
  .program-meeting-titlebar,
  .program-section-heading,
  .program-item { padding-left: 1rem; padding-right: 1rem; }
  .program-week-range { font-size: 1.35rem; }
  .program-section-heading { font-size: 1.05rem; }
  .program-item-layout { grid-template-columns: 1fr; gap: .65rem; }
  .program-item-assignments { align-items: stretch; }
  .program-assignee-card { max-width: none; }
}

/* Desktop: profile/admin stay on the right side of the navbar. Mobile: they remain inside the collapsed hamburger menu. */
@media (max-width: 991.98px) {
  .nav-user-zone {
    border-top: 1px solid var(--bs-border-color);
    margin-top: .5rem;
    padding-top: .5rem;
  }
  .user-logout-zone {
    border-top: 1px solid var(--bs-border-color);
    margin-top: .5rem;
    padding-top: .75rem;
  }
}

/* Fix46: kompaktowe informacje o osobach przy punkcie programu.
   To są tylko dane przydziału, więc nie powinny wizualnie dominować nad punktem zebrania. */
.program-item-layout {
  grid-template-columns: minmax(0, 1fr) minmax(170px, 26%);
  gap: .65rem .9rem;
}
.program-item-assignments {
  gap: .28rem;
}
.program-assignee-card {
  display: inline-block;
  width: auto;
  max-width: 100%;
  padding: .28rem .46rem;
  border-left-width: 2px;
  border-radius: .28rem;
}
.program-assignee-role {
  font-size: .64rem;
  line-height: 1.08;
  margin-bottom: .05rem;
  font-weight: 650;
}
.program-assignee-name {
  font-size: .86rem;
  line-height: 1.16;
  font-weight: 650;
}
.program-assignee-extra {
  font-size: .72rem;
  line-height: 1.15;
  margin-top: .05rem;
}

@media (max-width: 768px) {
  .program-item-layout {
    grid-template-columns: 1fr;
    gap: .42rem;
  }
  .program-item-assignments {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: .32rem;
  }
  .program-assignee-card {
    flex: 0 1 auto;
    max-width: 100%;
    padding: .26rem .42rem;
  }
  .program-assignee-role {
    font-size: .62rem;
  }
  .program-assignee-name {
    font-size: .84rem;
  }
  .program-assignee-extra {
    font-size: .7rem;
  }
}


/* Fix47: przydzielone osoby zawsze po prawej stronie punktu programu.
   Poprzednia wersja na telefonie przełączała układ na jedną kolumnę, przez co osoba
   pojawiała się pod spodem na całą szerokość. Ten override utrzymuje układ 2-kolumnowy
   także na widoku mobilnym, tylko z węższą kolumną osoby. */
.program-item-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(118px, 34vw, 190px);
  gap: .45rem .55rem;
  align-items: start;
}
.program-item-main {
  min-width: 0;
}
.program-item-assignments {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: .25rem;
  min-width: 0;
}
.program-assignee-card {
  display: block;
  width: 100%;
  max-width: none;
  padding: .26rem .38rem;
  border-left-width: 2px;
  border-radius: .28rem;
  overflow-wrap: anywhere;
}
.program-assignee-role {
  font-size: .61rem;
  line-height: 1.06;
  margin-bottom: .05rem;
  font-weight: 650;
}
.program-assignee-name {
  font-size: .83rem;
  line-height: 1.12;
  font-weight: 650;
}
.program-assignee-extra {
  font-size: .68rem;
  line-height: 1.12;
  margin-top: .05rem;
}

@media (min-width: 769px) {
  .program-item-layout {
    grid-template-columns: minmax(0, 1fr) clamp(170px, 24%, 230px);
    gap: .65rem .85rem;
  }
  .program-assignee-card {
    padding: .30rem .46rem;
  }
  .program-assignee-role {
    font-size: .64rem;
  }
  .program-assignee-name {
    font-size: .88rem;
  }
}

@media (max-width: 430px) {
  .program-item {
    padding-left: .95rem;
    padding-right: .95rem;
  }
  .program-item-layout {
    grid-template-columns: minmax(0, 1fr) 126px;
    gap: .38rem .45rem;
  }
  .program-item-title {
    font-size: .98rem;
  }
  .program-item-subline {
    font-size: .88rem;
  }
  .program-assignee-card {
    padding: .24rem .34rem;
  }
  .program-assignee-role {
    font-size: .58rem;
  }
  .program-assignee-name {
    font-size: .79rem;
  }
  .program-assignee-extra {
    font-size: .66rem;
  }
}

@media (max-width: 360px) {
  .program-item-layout {
    grid-template-columns: minmax(0, 1fr) 112px;
    gap: .32rem .38rem;
  }
  .program-assignee-name {
    font-size: .76rem;
  }
}

/* Meeting service module: microphones, audio, video, attendants */
.service-meeting-card {
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 14px;
  padding: 1rem;
  background: rgba(255,255,255,.78);
}
.service-meeting-head {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  align-items: center;
  padding-bottom: .65rem;
  border-bottom: 1px solid rgba(0,0,0,.08);
  margin-bottom: .75rem;
}
.service-group-title {
  margin: 1rem 0 .45rem;
  font-weight: 700;
  color: var(--bs-primary, #0d6efd);
}
.service-assignment-row {
  padding: .35rem 0;
  border-bottom: 1px dashed rgba(0,0,0,.07);
}
.service-assignment-row:last-child { border-bottom: 0; }
.service-role-label { font-weight: 600; font-size: .92rem; }
.service-privileges-table-wrap { max-height: 70vh; }
.service-privileges-table th,
.service-privileges-table td { white-space: nowrap; }
.service-privileges-table .sticky-col {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 220px;
}
.program-service-box {
  margin: 1.25rem 0 0;
  padding: .95rem;
  border-top: 2px solid rgba(0,0,0,.12);
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0;
  background: rgba(248,249,250,.72);
}
.program-service-box-bottom {
  clear: both;
}
.program-service-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: .75rem;
  margin-bottom: .75rem;
}
.program-service-title {
  font-weight: 800;
  color: #374151;
  line-height: 1.2;
}
.program-service-subtitle {
  margin-top: .12rem;
  font-size: .82rem;
  color: #6b7280;
}
.program-service-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem;
}
.program-service-group {
  border: 1px solid rgba(0,0,0,.08);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}
.program-service-group-title {
  padding: .5rem .65rem;
  font-weight: 800;
  font-size: .9rem;
  background: rgba(0,0,0,.035);
  border-bottom: 1px solid rgba(0,0,0,.07);
}
.program-service-list {
  display: grid;
}
.program-service-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(145px, auto);
  gap: .65rem;
  align-items: center;
  padding: .48rem .65rem;
  border-bottom: 1px dashed rgba(0,0,0,.08);
}
.program-service-row:last-child {
  border-bottom: 0;
}
.program-service-row.is-mine {
  background: rgba(13,110,253,.07);
  box-shadow: inset 3px 0 0 rgba(13,110,253,.55);
}
.program-service-role {
  font-size: .84rem;
  color: #4b5563;
  line-height: 1.25;
}
.program-service-name {
  font-weight: 800;
  text-align: right;
  line-height: 1.25;
}
@media (max-width: 768px) {
  .program-service-groups {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 576px) {
  .service-meeting-head { display: block; }
  .service-role-label { margin-bottom: .15rem; }
  .program-service-box { padding: .75rem .55rem; }
  .program-service-head { display: block; }
  .program-service-head .btn { margin-top: .55rem; width: 100%; }
  .program-service-row {
    grid-template-columns: 1fr;
    gap: .15rem;
  }
  .program-service-name {
    text-align: left;
  }
}
