/* =========================
   Base & Typography
   ========================= */
:root {
  --bg: #f9fafb;
  --text: #111827;
  --muted: #6b7280;
  --border: #e5e7eb;
  --brand: #1f2937;
  --brand-dark: #111827;
  --link: #2563eb;
  --card-bg: #ffffff;
  --radius: 14px;
  --radius-sm: 10px;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  font-family: 'Noto Sans Bengali', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
}

h1 { font-size: 28px; margin: 10px 0 16px; }
h2 { font-size: 20px; margin: 12px 0; }
p  { margin: 0 0 12px; }

/* =========================
   Layout
   ========================= */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 20px;
}

/* =========================
   Top Navigation
   ========================= */
.nav {
  background: var(--brand);
  color: #fff;
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.nav a {
  color: #fff;
  margin-right: 15px;
  text-decoration: none;
}
.nav a:last-child { margin-right: 0; }
.nav strong { font-weight: 700; }

/* =========================
   Cards & Dashboard Grid
   ========================= */
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}
.card-title { font-size: 13px; color: var(--muted); }
.card-value { font-size: 28px; font-weight: 700; margin-top: 6px; }

/* =========================
   Tables
   ========================= */
table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
}
thead th {
  background: #f3f4f6;
  font-weight: 600;
}
th, td {
  padding: 10px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

/* =========================
   Forms
   ========================= */
form { margin-top: 8px; }
.form-group { margin-bottom: 12px; }
label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
}
input[type="text"],
input[type="number"],
input[type="date"],
input[type="password"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--text);
  outline: none;
}
textarea { min-height: 90px; resize: vertical; }

/* Inline form actions */
.form-actions { margin: 12px 0; }

/* =========================
   Buttons & Links
   ========================= */
.btn {
  display: inline-block;
  padding: 8px 12px;
  background: var(--brand);
  color: #fff;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background .15s ease;
}
.btn:hover { background: var(--brand-dark); }

.btn-link {
  color: var(--link);
  text-decoration: none;
}
.btn-link:hover { text-decoration: underline; }

/* =========================
   Alerts / Helpers
   ========================= */
.error {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
}

/* =========================
   Responsive
   ========================= */
@media (max-width: 900px) {
  .grid { grid-template-columns: 1fr; }
  .nav { flex-wrap: wrap; gap: 8px; }
}