/* Visszafogott, munkára szabott admin: egy határozott kék, meleg semleges háttér, IBM Plex. */
:root {
  --app-ink: #1b2430;
  --app-muted: #5b6573;
  --app-bg: #f4f5f2;
  --app-surface: #ffffff;
  --app-line: #e1e3dc;
  --app-primary: #1f4e8c;
  --app-primary-dark: #173d6e;
  --app-attention: #b8620a;
  --bs-body-font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --bs-body-color: var(--app-ink);
  --bs-body-bg: var(--app-bg);
  --bs-border-color: var(--app-line);
  --bs-link-color: var(--app-primary);
  --bs-link-color-rgb: 31, 78, 140;
  --bs-link-hover-color: var(--app-primary-dark);
  --bs-primary: var(--app-primary);
  --bs-primary-rgb: 31, 78, 140;
}

.btn-primary {
  --bs-btn-bg: var(--app-primary);
  --bs-btn-border-color: var(--app-primary);
  --bs-btn-hover-bg: var(--app-primary-dark);
  --bs-btn-hover-border-color: var(--app-primary-dark);
  --bs-btn-active-bg: var(--app-primary-dark);
  --bs-btn-disabled-bg: var(--app-primary);
}
.form-check-input:checked { background-color: var(--app-primary); border-color: var(--app-primary); }
.progress-bar { background-color: var(--app-primary); }
a { text-decoration: none; }
a:hover { text-decoration: underline; }
.font-mono, code { font-family: "IBM Plex Mono", ui-monospace, monospace; }
.min-w-0 { min-width: 0; }
:focus-visible { outline: 2px solid var(--app-primary); outline-offset: 2px; }

/* Keret */
.app-shell { display: flex; flex-wrap: wrap; min-height: 100vh; }
.app-sidebar {
  flex: 1 1 220px; max-width: 240px; background: var(--app-surface); border-right: 1px solid var(--app-line);
  display: flex; flex-direction: column; padding: 1rem .75rem;
}
.app-brand { font-weight: 600; font-size: 1.05rem; color: var(--app-ink); padding: .25rem .75rem 1rem; }
.app-sidebar .nav-link {
  display: flex; align-items: center; gap: .6rem; color: var(--app-muted); border-radius: .375rem; padding: .5rem .75rem;
}
.app-sidebar .nav-link:hover { background: var(--app-bg); color: var(--app-ink); text-decoration: none; }
.app-sidebar .nav-link.active { background: #e8eef7; color: var(--app-primary); font-weight: 500; }
.app-user { margin-top: auto; padding: 1rem .75rem 0; border-top: 1px solid var(--app-line); }
.app-main { flex: 999 1 560px; min-width: 0; padding: 1.5rem 2rem 3rem; max-width: 1480px; }
@media (max-width: 768px) {
  .app-sidebar { max-width: none; flex-basis: 100%; border-right: 0; border-bottom: 1px solid var(--app-line); }
  .app-sidebar .nav { flex-direction: row !important; flex-wrap: wrap; }
  .app-user { display: none; }
  .app-main { padding: 1rem; }
}

.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 1rem; margin-bottom: 1.25rem; }
.card { border-color: var(--app-line); box-shadow: none; }
.card-header { background: transparent; border-bottom-color: var(--app-line); }
.table > :not(caption) > * > * { padding: .6rem .75rem; }
.table thead th { font-weight: 500; font-size: .8rem; color: var(--app-muted); background: #fafaf8; }

/* Teendők sáv: ez az egyetlen hangsúlyos elem az áttekintésen */
.todo-strip { display: flex; flex-wrap: wrap; gap: .75rem; }
.todo-item {
  display: flex; align-items: baseline; gap: .5rem; padding: .75rem 1rem; border-radius: .5rem;
  border: 1px solid var(--app-line); background: var(--app-surface); color: var(--app-ink);
}
.todo-item strong { font-size: 1.4rem; }
.todo-item:hover { text-decoration: none; border-color: var(--app-primary); }
.todo-primary { border-color: var(--app-attention); background: #fdf6ee; }
.todo-primary strong { color: var(--app-attention); }

/* Mutatók */
.kpi-label { font-size: .8rem; color: var(--app-muted); }
.kpi-value { font-size: 1.35rem; font-weight: 500; }
.kpi-big { font-size: 3rem; font-weight: 600; line-height: 1.1; color: var(--app-primary); letter-spacing: -0.02em; }
.funnel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
@media (min-width: 1200px) { .funnel { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

.daychart { display: flex; align-items: flex-end; gap: 3px; height: 120px; }
.daychart-col { flex: 1 1 0; height: 100%; display: flex; align-items: flex-end; }
.daychart-bar { width: 100%; background: #c9d6ea; border-radius: 2px 2px 0 0; display: flex; align-items: flex-end; min-height: 1px; }
.daychart-reply { width: 100%; background: var(--app-primary); border-radius: 2px 2px 0 0; }
.legend { display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: middle; }
.legend-sent { background: #c9d6ea; }
.legend-reply { background: var(--app-primary); }

.notif-critical { border-left: 3px solid #b42318; }
.notif-warning { border-left: 3px solid var(--app-attention); }

/* Jóváhagyás */
.review-card.is-done { opacity: .45; pointer-events: none; }
.score { font-weight: 600; font-size: .85rem; padding: .1rem .5rem; border-radius: 1rem; }
.score-high { background: #e3f1e6; color: #1e6b34; }
.score-mid { background: #eef1f6; color: #33435a; }
.score-low { background: #fbeee4; color: #8a4708; }
.mail-preview { background: #fbfbf9; border: 1px solid var(--app-line); border-radius: .375rem; padding: 1rem; font-size: .9rem; }
.mail-subject { font-weight: 500; padding-bottom: .5rem; margin-bottom: .75rem; border-bottom: 1px solid var(--app-line); }
.mail-body { white-space: normal; line-height: 1.55; max-height: 420px; overflow: auto; }
.mail-frame { width: 100%; height: 480px; border: 1px solid var(--app-line); border-radius: .375rem; background: #fff; }
.empty-state { padding: 3rem 1rem; text-align: center; border: 1px dashed var(--app-line); border-radius: .5rem; background: var(--app-surface); }
.bulk-bar { position: sticky; top: 0; z-index: 5; background: var(--app-bg); padding: .5rem 0; }

/* Kampány űrlap */
.country-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .75rem 1.25rem; }

/* Bejelentkezés */
.auth-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 1rem; }
.auth-card { width: 100%; max-width: 420px; background: var(--app-surface); border: 1px solid var(--app-line); border-radius: .5rem; padding: 2rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
