/* SZMG chat-rail + 2-koloms chat-scherm. Thema-neutraal via --rail-*-variabelen
   (standaard = SamenZorgWijzer/SZMG navy); een pagina kan ze op .szmg-chatwrap overschrijven. */

.szmg-chatwrap {
  --rail-primary: #1B2D78;
  --rail-primary-dk: #13215A;
  --rail-accent-lt: #EDF0F9;
  --rail-text: #1f2937;
  --rail-muted: #64748b;
  --rail-line: #e6e9f2;
  --rail-soft: #f5f6fb;
  --rail-card: #FBF6E9;
  --rail-card-line: #F0E6CC;

  display: flex;
  align-items: flex-start;
  gap: 26px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 22px 54px;
  box-sizing: border-box;
}
.szmg-chatwrap * { box-sizing: border-box; }

/* ── Linker-rail ── */
.szmg-rail { width: 266px; flex-shrink: 0; position: sticky; top: 14px; display: flex; flex-direction: column; gap: 14px; }

.szmg-rail-new {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; border: none; border-radius: 12px; cursor: pointer;
  background: var(--rail-primary); color: #fff; font-family: inherit; font-weight: 700; font-size: .9rem;
  padding: 12px 14px; transition: background .15s;
}
.szmg-rail-new:hover { background: var(--rail-primary-dk); }

/* Veelgestelde onderwerpen */
.szmg-rail-section { border: 1px solid var(--rail-line); border-radius: 14px; background: #fff; padding: 12px 12px 8px; }
.szmg-rail-h { font-size: .78rem; font-weight: 700; color: var(--rail-primary); margin: 2px 2px 8px; }
.szmg-rail-topic {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  border: none; background: transparent; border-radius: 9px; cursor: pointer;
  font-family: inherit; font-size: .82rem; font-weight: 600; color: var(--rail-text); padding: 8px 6px;
}
.szmg-rail-topic:hover { background: var(--rail-soft); }
.szmg-rail-topic .szmg-rail-tic { width: 26px; height: 26px; border-radius: 50%; background: var(--rail-soft); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.szmg-rail-topic .szmg-rail-tic svg { width: 15px; height: 15px; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.szmg-rail-topic span.tx { flex: 1; min-width: 0; }
.szmg-rail-topic .chev { margin-left: auto; color: var(--rail-muted); flex-shrink: 0; }
.szmg-rail-topic .chev svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; }

/* "Hulp bij jou in de buurt"-promokaart onder de onderwerpen */
.szmg-rail-promo { border: 1px solid var(--rail-line); border-radius: 14px; background: #fff; overflow: hidden; }
.szmg-rail-promo-art { height: 78px; background: linear-gradient(135deg, #EAF8FB, #D6EFF4); display: flex; align-items: flex-end; justify-content: center; }
.szmg-rail-promo-art svg { display: block; width: 100%; height: 78px; }
.szmg-rail-promo-body { padding: 12px 13px 13px; }
.szmg-rail-promo-h { font-size: .9rem; font-weight: 700; color: var(--rail-primary); margin-bottom: 4px; }
.szmg-rail-promo-tx { margin: 0 0 11px; font-size: .8rem; line-height: 1.45; color: var(--rail-muted); }
.szmg-rail-promo-btn {
  display: flex; align-items: center; justify-content: center; gap: 7px; width: 100%;
  border: none; border-radius: 10px; cursor: pointer; font-family: inherit; font-weight: 700; font-size: .84rem;
  background: #00B4CC; color: #fff; padding: 10px 12px; transition: background .15s;
}
.szmg-rail-promo-btn:hover { background: #0097AD; }
.szmg-rail-promo-btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ── Chat-kolom ── */
.szmg-chatcol { flex: 1; min-width: 0; }
.szmg-chathead { display: flex; align-items: center; gap: 13px; padding-bottom: 14px; border-bottom: 1px solid var(--rail-line); margin-bottom: 4px; }
.szmg-chathead-av { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.szmg-chathead-tx { min-width: 0; }
.szmg-chathead-name { font-weight: 700; color: var(--rail-primary); font-size: 1.05rem; line-height: 1.2; }
.szmg-chathead-sub { font-size: .84rem; color: var(--rail-muted); }
.szmg-chathead-back {
  margin-left: auto; flex-shrink: 0; border: 1.5px solid var(--rail-line); background: #fff;
  border-radius: 50px; padding: 8px 16px; font-family: inherit; font-weight: 700; font-size: .84rem;
  color: var(--rail-primary); cursor: pointer; transition: border-color .15s;
}
.szmg-chathead-back:hover { border-color: var(--rail-primary); }

/* ── Responsief: rail onder de chat-breedte verbergen ── */
@media (max-width: 960px) {
  .szmg-rail { display: none; }
  .szmg-chatwrap { padding: 14px 16px 40px; }
}
