/* assets/css/style.css */

:root {
  --primary: #1a1a2e;
  --secondary: #16213e;
  --accent: #f5a623;
  --accent2: #e91e63;
  --text: #2d2d2d;
  --muted: #6c757d;
  --radius: 12px;
}

* { box-sizing: border-box; }

body {
  font-family: 'Cairo', 'Tajawal', sans-serif;
  color: var(--text);
  background: #f8f9fb;
}

/* ── Navbar ── */
#mainNav {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  box-shadow: 0 2px 20px rgba(0,0,0,.3);
}
.navbar-brand { font-family: 'Cairo', sans-serif; font-weight: 900; }

/* ── Hero ── */
.hero-section {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  padding: 90px 0 80px;
  position: relative;
  overflow: hidden;
}
.hero-section::before {
  content: '';
  position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero-section .display-4 { font-weight: 900; line-height: 1.3; }
.hero-badge {
  display: inline-block;
  background: rgba(245,166,35,.15);
  border: 1px solid rgba(245,166,35,.4);
  color: var(--accent);
  padding: 6px 16px;
  border-radius: 50px;
  font-size: .85rem;
  margin-bottom: 1rem;
}

/* ── Product Card ── */
.product-card {
  border-radius: var(--radius) !important;
  transition: transform .25s ease, box-shadow .25s ease;
  overflow: hidden;
}
.product-card:hover { transform: translateY(-5px); box-shadow: 0 15px 40px rgba(0,0,0,.12) !important; }

.product-img-wrap { height: 210px; background: #f0f0f0; }
.product-img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.product-card:hover .product-img { transform: scale(1.06); }

.product-overlay {
  position: absolute; inset: 0;
  background: rgba(26,26,46,.6);
  opacity: 0;
  transition: opacity .3s;
}
.product-card:hover .product-overlay { opacity: 1; }

.product-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: .95rem;
}
.product-title:hover { color: var(--accent) !important; }

/* ── Stars ── */
.stars { font-size: .8rem; }

/* ── Section Titles ── */
.section-title {
  font-weight: 900;
  font-size: 1.8rem;
  position: relative;
  padding-bottom: .6rem;
  margin-bottom: 2rem;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: 0; right: 0;
  width: 60px; height: 3px;
  background: var(--accent);
  border-radius: 3px;
}

/* ── Category Cards ── */
.cat-card {
  border-radius: var(--radius) !important;
  transition: all .25s;
  cursor: pointer;
  border: 2px solid transparent !important;
}
.cat-card:hover {
  border-color: var(--accent) !important;
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(245,166,35,.2) !important;
}
.cat-icon {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px;
  font-size: 1.6rem; color: var(--accent);
}

/* ── Stats Bar ── */
.stats-bar {
  background: linear-gradient(135deg, var(--accent) 0%, #f7d060 100%);
}
.stat-item { text-align: center; }
.stat-number { font-size: 2rem; font-weight: 900; }

/* ── Footer ── */
.footer {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
}
.footer-link {
  color: rgba(255,255,255,.65);
  text-decoration: none;
  display: block;
  padding: 2px 0;
  transition: color .2s;
}
.footer-link:hover { color: var(--accent); }

/* ── Auth Forms ── */
.auth-card {
  border-radius: 20px !important;
  box-shadow: 0 20px 60px rgba(0,0,0,.1) !important;
}
.auth-header {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 20px 20px 0 0;
  padding: 2rem;
  text-align: center;
  color: white;
}

/* ── Dashboard Sidebar ── */
.dash-sidebar {
  background: white;
  border-radius: var(--radius);
  box-shadow: 0 4px 20px rgba(0,0,0,.06);
  overflow: hidden;
}
.dash-sidebar .nav-link {
  color: var(--text);
  padding: .75rem 1.25rem;
  border-right: 3px solid transparent;
  transition: all .2s;
}
.dash-sidebar .nav-link:hover,
.dash-sidebar .nav-link.active {
  background: rgba(245,166,35,.08);
  color: var(--accent);
  border-right-color: var(--accent);
}
.dash-sidebar .nav-link i { width: 22px; }

/* ── Tables ── */
.table-card { border-radius: var(--radius) !important; overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,.05); }
.table thead th { background: var(--primary); color: white; border: none; }

/* ── Badges ── */
.badge-pending  { background: #fff3cd; color: #856404; }
.badge-approved { background: #d1e7dd; color: #0f5132; }
.badge-rejected { background: #f8d7da; color: #842029; }

/* ── Upload Zone ── */
.upload-zone {
  border: 2px dashed #dee2e6;
  border-radius: var(--radius);
  padding: 3rem;
  text-align: center;
  transition: all .25s;
  cursor: pointer;
}
.upload-zone:hover, .upload-zone.drag-over {
  border-color: var(--accent);
  background: rgba(245,166,35,.05);
}

/* ── Filter Sidebar ── */
.filter-card { border-radius: var(--radius) !important; border: none !important; box-shadow: 0 4px 20px rgba(0,0,0,.06); }

/* ── Pagination ── */
.pagination .page-link { border-radius: 8px !important; margin: 0 3px; border: none; color: var(--text); }
.pagination .page-item.active .page-link { background: var(--accent); color: #fff; }

/* ── Product Details ── */
.product-gallery img { border-radius: var(--radius); cursor: pointer; transition: opacity .2s; }
.product-gallery img:hover { opacity: .85; }
.main-product-img { width: 100%; border-radius: var(--radius); max-height: 420px; object-fit: cover; }

/* ── Review Stars ── */
.star-rating input { display: none; }
.star-rating label { cursor: pointer; font-size: 1.8rem; color: #dee2e6; }
.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label { color: var(--accent); }

/* ── Cart ── */
.cart-item-img { width: 80px; height: 60px; object-fit: cover; border-radius: 8px; }

/* ── Toasts / Alerts ── */
.toast-container { z-index: 9999; }

/* ── Utility ── */
.fw-black { font-weight: 900; }
.text-accent { color: var(--accent); }
.bg-primary-dark { background: var(--primary); }
.rounded-xl { border-radius: var(--radius) !important; }
.shadow-soft { box-shadow: 0 4px 20px rgba(0,0,0,.07) !important; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .hero-section { padding: 50px 0; }
  .section-title { font-size: 1.4rem; }
  .stat-number { font-size: 1.5rem; }
}

/* ── Admin ── */
.admin-sidebar { min-height: 100vh; }
.admin-nav .nav-link { color: rgba(255,255,255,.75); padding: .65rem 1.25rem; }
.admin-nav .nav-link:hover, .admin-nav .nav-link.active { color: var(--accent); background: rgba(255,255,255,.08); }
