/* =====================================================
   মামুনের আড্ডা - Main Stylesheet
   ===================================================== */

/* --- CSS Variables --- */
:root {
  --primary:    #e84118;
  --primary-dk: #c0392b;
  --secondary:  #2c3e50;
  --accent:     #f39c12;
  --success:    #27ae60;
  --danger:     #e74c3c;
  --light:      #f8f9fa;
  --dark:       #212529;
  --gray:       #6c757d;
  --border:     #dee2e6;
  --white:      #ffffff;
  --shadow:     0 4px 20px rgba(0,0,0,0.08);
  --radius:     10px;
  --font:       'Segoe UI', 'Hind Siliguri', Arial, sans-serif;
  --transition: all 0.25s ease;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: #f5f5f5;
  color: var(--dark);
  min-height: 100vh;
  line-height: 1.6;
}

img { max-width: 100%; height: auto; display: block; }
a  { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* =====================================================
   HEADER
   ===================================================== */
header {
  background: linear-gradient(135deg, var(--secondary) 0%, #1a252f 100%);
  color: var(--white);
  padding: 0;
  box-shadow: 0 2px 15px rgba(0,0,0,0.3);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  max-width: 1200px;
  margin: 0 auto;
  gap: 15px;
}

.header-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-logo img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; border: 2px solid var(--primary); }

.header-brand h1 { font-size: 1.3rem; color: var(--white); line-height: 1.2; }
.header-brand .slogan { font-size: 0.78rem; color: #b0c4de; }
.header-brand .phone  { font-size: 0.82rem; color: var(--accent); margin-top: 2px; }
.header-brand .address{ font-size: 0.75rem; color: #8fa8c0; }

/* NAV */
nav {
  background: var(--primary);
}

nav ul {
  display: flex;
  max-width: 1200px;
  margin: 0 auto;
  overflow-x: auto;
  scrollbar-width: none;
}

nav ul::-webkit-scrollbar { display: none; }

nav ul li a {
  display: block;
  padding: 12px 18px;
  color: var(--white);
  font-size: 0.88rem;
  font-weight: 500;
  white-space: nowrap;
  transition: var(--transition);
}

nav ul li a:hover,
nav ul li a.active {
  background: var(--primary-dk);
}

/* =====================================================
   MAIN CONTAINER
   ===================================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 15px;
}

/* =====================================================
   PRODUCT SECTION
   ===================================================== */
.section-title {
  font-size: 1.5rem;
  color: var(--secondary);
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary);
  display: inline-block;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 18px;
  margin-bottom: 30px;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border: 2px solid transparent;
  position: relative;
}

.product-card:hover { transform: translateY(-4px); box-shadow: 0 8px 30px rgba(0,0,0,0.12); }

.product-card.selected { border-color: var(--primary); }

.product-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.product-card-body { padding: 12px; }
.product-card h3 { font-size: 0.95rem; margin-bottom: 5px; color: var(--secondary); }
.product-price { font-size: 1.1rem; font-weight: 700; color: var(--primary); margin-bottom: 5px; }
.product-desc  { font-size: 0.78rem; color: var(--gray); margin-bottom: 10px; line-height: 1.5; }

/* Quantity Controls */
.qty-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
}

.qty-btn {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: var(--primary);
  color: var(--white);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.qty-btn:hover { background: var(--primary-dk); }

.qty-input {
  width: 50px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px;
  font-size: 0.95rem;
  font-weight: 600;
}

/* Select checkbox */
.product-select {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--light);
  border-top: 1px solid var(--border);
  cursor: pointer;
}

.product-select input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--primary);
}

.product-select label { font-size: 0.85rem; cursor: pointer; font-weight: 500; }

/* =====================================================
   ORDER FORM
   ===================================================== */
.order-form-section {
  background: var(--white);
  border-radius: var(--radius);
  padding: 25px;
  box-shadow: var(--shadow);
  margin-top: 20px;
}

.order-form-section h2 { font-size: 1.2rem; margin-bottom: 20px; color: var(--secondary); }

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 0.9rem;
  color: var(--secondary);
}

.form-control {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: var(--font);
  transition: var(--transition);
  background: var(--white);
  color: var(--dark);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(232,65,24,0.15);
}

textarea.form-control { resize: vertical; min-height: 80px; }

select.form-control { cursor: pointer; }

.delivery-charge-box {
  background: #fff3cd;
  border: 1px solid #ffc107;
  border-radius: 8px;
  padding: 10px 15px;
  font-weight: 600;
  color: #856404;
  margin-bottom: 16px;
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 22px;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font);
  text-align: center;
}

.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dk); }

.btn-secondary { background: var(--secondary); color: var(--white); }
.btn-secondary:hover { background: #1a252f; }

.btn-success { background: var(--success); color: var(--white); }
.btn-success:hover { background: #219150; }

.btn-danger  { background: var(--danger); color: var(--white); }
.btn-danger:hover  { background: #c0392b; }

.btn-warning { background: var(--accent); color: var(--white); }
.btn-warning:hover { background: #d68910; }

.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: var(--white); }

.btn-full { width: 100%; justify-content: center; padding: 14px; font-size: 1.05rem; }
.btn-sm   { padding: 7px 14px; font-size: 0.82rem; }

/* =====================================================
   MODAL / POPUP
   ===================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 15px;
  animation: fadeIn 0.2s ease;
}

.modal-box {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 460px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  animation: slideUp 0.25s ease;
}

.modal-box h2 { font-size: 1.3rem; margin-bottom: 15px; color: var(--secondary); }
.modal-box p  { margin-bottom: 8px; font-size: 0.92rem; line-height: 1.7; }

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.modal-actions .btn { flex: 1; }

@keyframes fadeIn  { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(30px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* =====================================================
   FLASH MESSAGE
   ===================================================== */
.flash-message {
  padding: 13px 18px;
  border-radius: 8px;
  margin: 12px 0;
  font-weight: 600;
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: slideUp 0.3s ease;
}

/* =====================================================
   FOOTER
   ===================================================== */
footer {
  background: var(--secondary);
  color: #b0c4de;
  text-align: center;
  padding: 20px;
  margin-top: 40px;
  font-size: 0.85rem;
}

footer a { color: var(--accent); }

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 768px) {
  .header-brand h1 { font-size: 1.1rem; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .container { padding: 15px 10px; }
  .order-form-section { padding: 18px 14px; }
}

@media (max-width: 480px) {
  .header-top { padding: 10px 12px; }
  .header-logo img { width: 48px; height: 48px; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .modal-box { padding: 20px 16px; }
  .btn-full { padding: 13px; }
}

/* =====================================================
   UTILITY CLASSES
   ===================================================== */
.text-center { text-align: center; }
.text-right  { text-align: right; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.p-2  { padding: 16px; }
.hidden { display: none !important; }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  color: white;
}

/* Order tracking timeline */
.timeline { position: relative; padding-left: 30px; }
.timeline::before { content:''; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: var(--border); }
.timeline-item { position: relative; margin-bottom: 20px; }
.timeline-item::before { content:''; position: absolute; left: -24px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--gray); border: 2px solid white; }
.timeline-item.active::before { background: var(--primary); }
.timeline-item .tl-title { font-weight: 600; font-size: 0.92rem; }
.timeline-item .tl-date  { font-size: 0.78rem; color: var(--gray); }
