/* ==============
   GLOBAL RESET
   ============== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f4f6f9;
  color: #1f2937;
  margin: 0;
}

/* Links */
a {
  color: inherit;
  text-decoration: none;
  transition: 0.2s;
}

a:hover {
  opacity: 0.8;
}

/* Containers */
.container {
  width: 100%;
  max-width: 1150px;
  margin: 0 auto;
  padding: 0 16px;
}

/* =====================
   HEADER (User Site)
   ===================== */
.site-header {
  background: #111827;
  color: #fff;
  padding: 12px 0;
  border-bottom: 1px solid #1f2937;
}

.logo {
  font-size: 1.25rem;
  font-weight: 700;
}

.nav a {
  margin-left: 14px;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.95rem;
  color: #e5e7eb;
}

.nav .btn-primary {
  background: #2563eb;
  color: #fff !important;
  border-radius: 999px;
  padding: 6px 14px;
}

/* Flex */
.flex-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ================
   FOOTER
   ================ */
.site-footer {
  background: #111827;
  color: #9ca3af;
  padding: 20px 0;
  text-align: center;
  margin-top: 40px;
}

/* =====================
   COMMON BUTTONS
   ===================== */
.btn-primary,
.btn-outline {
  display: inline-block;
  padding: 8px 15px;
  border-radius: 999px;
  cursor: pointer;
  border: 1px solid transparent;
  font-size: 0.9rem;
  transition: 0.2s;
}

.btn-primary {
  background: #2563eb;
  color: #fff;
}

.btn-outline {
  background: #fff;
  border-color: #2563eb;
  color: #2563eb;
}

.btn-outline:hover,
.btn-primary:hover {
  opacity: 0.85;
}

/* =====================
   CARDS + GRID
   ===================== */
.card {
  background: #fff;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.06);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px,1fr));
  gap: 18px;
  margin-top: 20px;
}

/* Price */
.price {
  color: #16a34a;
  font-size: 1.3rem;
  font-weight: 700;
  margin: 6px 0;
}

/* ===========================
   FORMS
   =========================== */
.form-card {
  background: #fff;
  padding: 22px;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
  max-width: 550px;
  margin-bottom: 30px;
}

.form-card label {
  display: block;
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 10px;
}

.form-card input,
.form-card textarea,
.form-card select {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #d1d5db;
  margin-top: 5px;
  font-size: 0.95rem;
  background: #fff;
}

textarea {
  resize: vertical;
}

/* ==========================
   MESSAGES (chat)
   ========================== */
.messages {
  max-height: 260px;
  overflow-y: auto;
  padding-right: 5px;
  margin-bottom: 10px;
}

.msg {
  background: #f3f4f6;
  padding: 10px;
  border-radius: 10px;
  margin-bottom: 8px;
}

.msg strong {
  color: #111827;
}

.msg small {
  display: block;
  margin-top: 6px;
  color: #6b7280;
  font-size: 0.75rem;
}

/* ==========================
   ALERT BOXES
   ========================== */
.error-box,
.info,
.success {
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
  font-size: 0.9rem;
}

.error-box {
  background: #fee2e2;
  color: #b91c1c;
}

.info {
  background: #dbeafe;
  color: #1d4ed8;
}

.success {
  background: #dcfce7;
  color: #15803d;
}

/* ==========================
   TABLES (Admin Panel)
   ========================== */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
}

table th,
table td {
  padding: 10px 8px;
  font-size: 0.9rem;
}

table thead {
  background: #e5e7eb;
}

table tbody tr {
  border-bottom: 1px solid #e5e7eb;
}

table tr:hover {
  background: #f3f4f6;
}

/* =============================
   ADMIN HEADER
   ============================= */
.admin-header {
  background: #0f172a;
  color: #fff;
  padding: 14px 0;
  margin-bottom: 20px;
}

.admin-header nav a {
  margin-left: 14px;
  color: #e5e7eb;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.9rem;
}

/* =============================
   RESPONSIVE DESIGN
   ============================= */
@media (max-width: 640px) {
  .flex-between {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
  }

  .nav a {
    margin: 5px 10px 0 0;
  }

  table th, table td {
    font-size: 0.8rem;
    padding: 8px;
  }
}

html, body {
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* যেই <main> তুমি ব্যবহার করছো, ওটা ফুল হাইট নিতে পারবে */
main {
  flex: 1 0 auto;
}

/* Footer অটোমেটিক নিচে ঠেলে যাবে */
.site-footer {
  margin-top: auto;
}
