*, *::before, *::after { box-sizing: border-box; }
:root { --bg:#fff; --muted:#666; --card:#f6f7f8; --border:#e1e3e6; --radius:14px; }
body { font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial; margin: 24px; background: var(--bg); color:#111; }
a { color: inherit; }
.topbar { display:flex; gap:12px; flex-wrap:wrap; align-items:center; margin-bottom:16px; }
.btn { display:inline-flex; align-items:center; gap:8px; padding:10px 12px; border:1px solid var(--border); background:#fff; border-radius:12px; cursor:pointer; text-decoration:none; }
.btn.primary { font-weight:600; }
.card { border:1px solid var(--border); background: var(--card); border-radius: var(--radius); padding: 14px; margin-bottom: 14px; }
.row { display:grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.muted { color: var(--muted); }
table { width:100%; border-collapse: collapse; background:#fff; border-radius: 12px; overflow:hidden; border:1px solid var(--border); }
th, td { padding:10px; border-bottom:1px solid var(--border); text-align:left; vertical-align:top; }
th { background:#fafbfc; }
input, textarea, select { width:100%; padding:10px; border-radius:12px; border:1px solid var(--border); background:#fff; }
textarea { min-height: 84px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }
.grid2 { display:grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.actions { display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
.badge { display:inline-block; padding:2px 8px; border-radius:999px; border:1px solid var(--border); background:#fff; font-size:12px; }
.imgthumb { width:72px; height:72px; object-fit:cover; border-radius:12px; border:1px solid var(--border); background:#fff; }
hr { border:0; border-top:1px solid var(--border); margin:12px 0; }
/* --- Visual refresh (desktop) --- */
:root{
  --bg:#f6f7fb;
  --card:#ffffff;
  --text:#111827;
  --muted:#6b7280;
  --border:#e5e7eb;
  --shadow:0 8px 24px rgba(17,24,39,.08);
  --radius:14px;
}

body{
  background: var(--bg);
  color: var(--text);
}

.wrap{
  max-width: 1200px;
  margin: 22px auto;
  padding: 18px;
}

.card{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

h1,h2,h3{
  letter-spacing: -0.02em;
}

label{
  color: var(--muted);
  font-weight: 600;
}

input, select, textarea{
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  background: #fff;
}

input:focus, select:focus, textarea:focus{
  outline: none;
  border-color: #c7d2fe;
  box-shadow: 0 0 0 4px rgba(99,102,241,.15);
}

.btn{
  border-radius: 12px;
  padding: 10px 14px;
  border: 1px solid var(--border);
}

.btn.primary{
  background: #4f46e5;
  border-color: #4f46e5;
}

.btn.primary:hover{
  filter: brightness(0.96);
}

.table{
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
/* --- Fix primary button text + make layout denser --- */
.btn.primary { color: #fff !important; }
a.btn.primary { color: #fff !important; text-decoration: none; }

/* чуть меньше воздуха */
body { margin: 16px !important; }
.card { padding: 12px !important; margin-bottom: 12px !important; }
.row { gap: 10px !important; margin-bottom: 10px !important; }
.grid2 { gap: 10px !important; }

h1 { margin: 10px 0 14px; }
h2 { margin: 0 0 10px; }
label { gap: 5px; }
input, select, textarea { padding: 10px 12px; }

