/*
 * Pro-Mi Admin-UI – önálló, offline téma (12.27 váz)
 * Nincs Node/Vite; a tényleges AdminLTE 4 dist a 12.29-ben kerül a public/vendor/ alá.
 * Cél: áttekinthető, jól használható admin-shell rendszer-fontokkal, build nélkül.
 */
:root {
  --bg: #f4f6f9;
  --sidebar-bg: #1f2d3d;
  --sidebar-fg: #c2c7d0;
  --sidebar-fg-active: #ffffff;
  --sidebar-active: #2a3f54;
  --topbar-bg: #ffffff;
  --border: #e3e6ea;
  --card-bg: #ffffff;
  --text: #2b3441;
  --muted: #6c757d;
  --brand: #2b6cb0;
  --brand-fg: #ffffff;
  --ok: #2f855a;
  --warn: #b7791f;
  --err: #c53030;
  --shadow: 0 1px 3px rgba(0, 0, 0, .08);
  --radius: 8px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
    Arial, "Noto Sans", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Layout váz ─────────────────────────────── */
.layout {
  display: grid;
  grid-template-columns: 250px 1fr;
  grid-template-rows: 56px 1fr;
  grid-template-areas:
    "sidebar topbar"
    "sidebar main";
  min-height: 100vh;
}

/* ── Oldalsáv ───────────────────────────────── */
.sidebar {
  grid-area: sidebar;
  background: var(--sidebar-bg);
  color: var(--sidebar-fg);
  display: flex;
  flex-direction: column;
}
.sidebar__brand {
  height: 56px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 18px;
  font-weight: 700;
  font-size: 1.05rem;
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  white-space: nowrap;
}
.sidebar__brand .logo {
  width: 28px; height: 28px;
  border-radius: 6px;
  background: var(--brand);
  display: grid; place-items: center;
  font-size: .85rem; font-weight: 800; color: #fff;
}
.sidebar__section {
  padding: 14px 18px 6px;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #8a94a6;
}
.sidebar__nav { list-style: none; margin: 0; padding: 0; }
.sidebar__nav a {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 18px;
  color: var(--sidebar-fg);
  border-left: 3px solid transparent;
}
.sidebar__nav a:hover { background: rgba(255, 255, 255, .04); text-decoration: none; }
.sidebar__nav a.active {
  background: var(--sidebar-active);
  color: var(--sidebar-fg-active);
  border-left-color: var(--brand);
}
.sidebar__nav .ico { width: 18px; text-align: center; opacity: .9; }
.sidebar__foot {
  margin-top: auto;
  padding: 14px 18px;
  font-size: .75rem;
  color: #8a94a6;
  border-top: 1px solid rgba(255, 255, 255, .06);
}

/* ── Felső sáv ──────────────────────────────── */
.topbar {
  grid-area: topbar;
  background: var(--topbar-bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  box-shadow: var(--shadow);
}
.topbar__title { font-weight: 600; }
.topbar__user { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .9rem; }
.topbar__user .avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--brand); color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: .8rem;
}

/* ── Fő tartalom ────────────────────────────── */
.main { grid-area: main; padding: 24px; }
.page-head { margin: 0 0 18px; }
.page-head h1 { margin: 0 0 4px; font-size: 1.4rem; }
.page-head p { margin: 0; color: var(--muted); }

/* ── Kártyák / rács ─────────────────────────── */
.grid { display: grid; gap: 18px; }
.grid--stats { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card__body { padding: 18px 20px; }
.card__head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  font-weight: 600;
}
.stat { display: flex; align-items: center; gap: 16px; }
.stat__icon {
  width: 46px; height: 46px; border-radius: 10px;
  display: grid; place-items: center; font-size: 1.25rem; color: #fff;
  flex: none;
}
.stat__value { font-size: 1.6rem; font-weight: 700; line-height: 1; }
.stat__label { color: var(--muted); font-size: .85rem; margin-top: 4px; }
.bg-brand { background: var(--brand); }
.bg-ok { background: var(--ok); }
.bg-warn { background: var(--warn); }
.bg-err { background: var(--err); }

/* ── Badge / állapotjelző ───────────────────── */
.badge {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
}
.badge--soon { background: #edf2f7; color: var(--muted); }
.badge--f4 { background: #fed7d7; color: var(--err); }

/* ── Egyszerű tábla ─────────────────────────── */
table.tbl { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.tbl th, table.tbl td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--border); }
table.tbl th { color: var(--muted); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; }
table.tbl tbody tr:hover { background: #fafbfc; }

/* ── Info-sáv ───────────────────────────────── */
.note {
  background: #ebf8ff;
  border: 1px solid #bee3f8;
  color: #2c5282;
  border-radius: var(--radius);
  padding: 14px 18px;
  font-size: .9rem;
}
.note strong { color: #2a4365; }

/* ── Reszponzív ─────────────────────────────── */
@media (max-width: 820px) {
  .layout {
    grid-template-columns: 1fr;
    grid-template-rows: 56px auto 1fr;
    grid-template-areas: "topbar" "sidebar" "main";
  }
  .sidebar { flex-direction: row; flex-wrap: wrap; align-items: center; }
  .sidebar__section, .sidebar__foot { display: none; }
  .sidebar__nav { display: flex; }
  .sidebar__nav a { border-left: none; border-bottom: 3px solid transparent; }
  .sidebar__nav a.active { border-left: none; border-bottom-color: var(--brand); }
}
