@import url("https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@400;600;700&family=Caveat:wght@700&display=swap");

:root {
  --navy:      #1b365d;
  --amber:     #eab308;
  --bg:        #f8fafc;
  --panel:     #ffffff;
  --text:      #0f172a;
  --muted-clr: #64748b;
  --border:    #e2e8f0;
  --slate:     #334155;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
}

/* ── Top nav bar ─────────────────────────────────────────── */
.mm-nav {
  background: var(--navy);
  padding: 0 20px;
  display: flex;
  align-items: center;
  height: 56px;
  gap: 12px;
}

.mm-nav-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  border-left: 1px solid rgba(255,255,255,0.18);
  padding-left: 12px;
  line-height: 1;
  align-self: center;
  padding-top: 2px;
}

/* ── Page body ───────────────────────────────────────────── */
.shell {
  max-width: 960px;
  margin: 24px auto;
  padding: 0 16px 40px;
}

h1 {
  margin: 0 0 10px;
  color: var(--navy);
  font-size: 22px;
}

h2 {
  margin: 0 0 6px;
  color: var(--navy);
  font-size: 16px;
  font-weight: 700;
}

/* ── Cards ───────────────────────────────────────────────── */
.card {
  background: var(--panel);
  border-radius: 14px;
  padding: 18px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  margin-bottom: 14px;
}

/* ── Buttons ─────────────────────────────────────────────── */
button, select, input {
  font: inherit;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

button {
  background: var(--navy);
  color: #fff;
  border: none;
  cursor: pointer;
  font-weight: 600;
}

button.accent {
  background: var(--amber);
  color: var(--navy);
}

button.secondary {
  background: #64748b;
  color: #fff;
}

button.danger {
  background: #ef4444;
  color: #fff;
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ── Row layout ──────────────────────────────────────────── */
.row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

/* ── KPI grid ────────────────────────────────────────────── */
.kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.kpi {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
}

.kpi .label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--muted-clr);
}

.kpi .value {
  font-size: 20px;
  font-weight: 700;
  color: var(--navy);
  margin-top: 4px;
}

/* ── Health dot ──────────────────────────────────────────── */
.health-dot {
  width: 13px;
  height: 13px;
  border-radius: 999px;
  display: inline-block;
  box-shadow: 0 0 0 3px rgba(0,0,0,0.08);
  flex-shrink: 0;
}
.health-red   { background: #ef4444; }
.health-amber { background: #f59e0b; }
.health-green { background: #10b981; }

/* ── Badges ──────────────────────────────────────────────── */
.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 3px 10px;
  background: #e2e8f0;
  font-size: 12px;
  font-weight: 600;
  color: var(--slate);
}

.badge.live {
  background: #dcfce7;
  color: #166534;
}

/* ── Operator input feed ─────────────────────────────────── */
#inputCurrent {
  min-height: 60px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  font-size: 22px;
  line-height: 1.35;
  color: var(--text);
  margin-bottom: 10px;
}

#inputFeed {
  max-height: 28vh;
  overflow-y: auto;
  padding-right: 6px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--slate);
}

/* ── Listener replay list ────────────────────────────────── */
#replayList {
  max-height: 64vh;
  overflow-y: auto;
  padding-right: 6px;
}

.replay-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.replay-source {
  font-size: 12px;
  color: var(--muted-clr);
  margin-bottom: 2px;
}

.replay-translated {
  font-size: 20px;
  line-height: 1.5;
  color: var(--text);
}

.bible-text {
  color: #b91c1c;
}

/* ── Misc ────────────────────────────────────────────────── */
.muted {
  color: var(--muted-clr);
  font-size: 13px;
}

.privacy {
  font-size: 12px;
  color: var(--muted-clr);
  line-height: 1.5;
}

/* ── Footer ──────────────────────────────────────────────── */
.mm-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.45);
  font-size: 11px;
  text-align: center;
  padding: 14px;
  margin-top: 32px;
}

.mm-footer a {
  color: rgba(255,255,255,0.55);
  text-decoration: none;
}

.mm-footer a:hover {
  color: rgba(255,255,255,0.8);
}
