/* assets/css/styles.css */
:root {
  --primary-color: #4f46e5;
  --primary-hover: #4338ca;
  --secondary-color: #f9fafb;
  --text-dark: #111827;
  --text-gray: #6b7280;
  --text-light: #9ca3af;
  --bg-light: #ffffff;
  --bg-gray: #f9fafb;
  --bg-dark: #111827;
  --border-color: #f3f4f6;
  --font-family: 'Inter', system-ui, -apple-system, sans-serif;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-light);
  color: var(--text-dark);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .container { padding: 0 1.5rem; }
}

@media (min-width: 1024px) {
  .container { padding: 0 2rem; }
}

/* Utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.space-x-4 > * + * { margin-left: 1rem; }
.space-x-8 > * + * { margin-left: 2rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.text-center { text-align: center; }
.hidden { display: none !important; }
.relative { position: relative; }
.absolute { position: absolute; }
.w-full { width: 100%; }
.h-full { height: 100%; }

/* Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
}

.navbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 4rem;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(to right, #4f46e5, #9333ea);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.search-bar {
  flex: 1;
  max-width: 36rem;
  margin: 0 2rem;
  position: relative;
}

.search-input {
  width: 100%;
  padding: 0.5rem 1rem 0.5rem 2.5rem;
  border: 1px solid #e5e7eb;
  border-radius: 9999px;
  background-color: var(--bg-gray);
  font-size: 0.875rem;
  transition: all 0.2s;
}

.search-input:focus {
  outline: none;
  background-color: #fff;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.2);
}

.search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  width: 1.25rem;
  height: 1.25rem;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-gray);
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--primary-color);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-left: 1rem;
  border-left: 1px solid var(--border-color);
}

.nav-btn {
  color: var(--text-gray);
  transition: color 0.2s;
}

.nav-btn:hover {
  color: var(--primary-color);
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  background-color: var(--primary-color);
  color: #fff;
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 9999px;
  transition: all 0.2s;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  background-color: #fff;
  color: var(--primary-color);
  border: 1px solid #e5e7eb;
  font-weight: 500;
  font-size: 0.875rem;
  border-radius: 9999px;
  transition: all 0.2s;
}

.btn-outline:hover {
  background-color: var(--bg-gray);
  transform: translateY(-1px);
}

/* Hero Section */
.hero {
  padding: 5rem 0;
  overflow: hidden;
  background-color: #fff;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.hero-text {
  flex: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  background-color: #e0e7ff;
  color: #4338ca;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: 9999px;
  margin-bottom: 1.5rem;
}

.hero-badge-dot {
  width: 0.5rem;
  height: 0.5rem;
  background-color: #4f46e5;
  border-radius: 50%;
  margin-right: 0.5rem;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-title span:last-child {
  color: var(--primary-color);
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--text-gray);
  margin-bottom: 2rem;
  max-width: 36rem;
}

.hero-btns {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.hero-visual {
  flex: 1;
  display: none;
}

@media (min-width: 1024px) {
  .hero-content {
    flex-direction: row;
    align-items: center;
  }
  .hero-title { font-size: 3.75rem; }
  .hero-btns { flex-direction: row; }
  .hero-visual { display: block; }
}

/* How It Works */
.features {
  padding: 3rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  background-color: #fff;
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.feature-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.5rem;
  transition: transform 0.3s;
}

.feature-card:hover {
  transform: translateY(-5px);
}

.feature-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.feature-icon svg {
  width: 2rem;
  height: 2rem;
}

.feature-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.feature-desc {
  color: var(--text-gray);
}

@media (min-width: 768px) {
  .features-grid { grid-template-columns: repeat(3, 1fr); gap: 0; }
  .feature-card:not(:last-child) { border-right: 1px solid var(--border-color); }
}

/* Section Headers */
.section-header {
  display: flex;
  flex-direction: column;
  margin-bottom: 2.5rem;
}

.section-title {
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-gray);
}

.section-link {
  color: var(--primary-color);
  font-weight: 600;
  font-size: 0.875rem;
  display: inline-flex;
  align-items: center;
}

.section-link:hover { color: var(--primary-hover); }
.section-link svg { transition: transform 0.2s; margin-left: 0.25rem; }
.section-link:hover svg { transform: translateX(4px); }

@media (min-width: 640px) {
  .section-header { flex-direction: row; justify-content: space-between; align-items: flex-end; }
}

/* Categories */
.categories {
  padding: 4rem 0;
  background-color: var(--bg-gray);
}

.cat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem;
  background-color: #fff;
  border-radius: 1rem;
  border: 1px solid var(--border-color);
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}

.cat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #e0e7ff;
}

.cat-icon-wrap {
  padding: 1rem;
  border-radius: 0.75rem;
  margin-bottom: 1rem;
  transition: transform 0.2s;
}

.cat-card:hover .cat-icon-wrap {
  transform: scale(1.1);
}

.cat-icon-wrap svg {
  width: 1.5rem;
  height: 1.5rem;
}

.cat-title {
  font-size: 0.875rem;
  font-weight: 500;
  text-align: center;
}

@media (min-width: 640px) { .cat-grid { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1024px) { .cat-grid { grid-template-columns: repeat(8, 1fr); } }

/* Products */
.products { padding: 5rem 0; background-color: #fff; }

.product-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.product-card {
  display: flex;
  flex-direction: column;
  border-radius: 1rem;
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: all 0.3s;
  background-color: #fff;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.product-img-wrap {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background-color: var(--bg-gray);
}

.product-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.product-card:hover .product-img {
  transform: scale(1.05);
}

.product-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: rgba(255, 255, 255, 0.9);
  padding: 0.125rem 0.625rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  backdrop-filter: blur(4px);
}

.product-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
}

.product-card:hover .product-overlay { opacity: 1; }

.btn-add-cart {
  background: #fff;
  color: var(--text-dark);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transform: translateY(1rem);
  transition: all 0.3s;
}

.product-card:hover .btn-add-cart { transform: translateY(0); }
.btn-add-cart:hover { background: var(--bg-gray); }

.product-info {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-rating {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  font-size: 0.875rem;
}

.star-icon {
  color: #fbbf24;
  width: 1rem;
  height: 1rem;
  fill: currentColor;
}

.rating-val { font-weight: 500; margin-left: 0.25rem; }
.rating-dot { color: #d1d5db; margin: 0 0.5rem; }
.rating-rev { color: var(--text-gray); }

.product-meta {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vendor-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.vendor-avatar-sm {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  background: linear-gradient(to bottom right, #e0e7ff, #f3e8ff);
  color: #4338ca;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
}

.vendor-name-sm {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-gray);
  max-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-price {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--primary-color);
}

@media (min-width: 640px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .product-grid { grid-template-columns: repeat(4, 1fr); } }

/* Vendors */
.vendors { padding: 5rem 0; background-color: var(--bg-gray); }

.vendor-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.vendor-card {
  background: #fff;
  border-radius: 1rem;
  border: 1px solid var(--border-color);
  overflow: hidden;
  transition: all 0.3s;
}

.vendor-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.vendor-cover-wrap {
  height: 8rem;
  position: relative;
  overflow: hidden;
}

.vendor-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.vendor-card:hover .vendor-cover { transform: scale(1.05); }

.vendor-cover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.2);
  transition: background 0.3s;
}

.vendor-card:hover .vendor-cover-overlay { background: rgba(0,0,0,0.1); }

.vendor-body {
  padding: 0 1.5rem 1.5rem;
  position: relative;
}

.vendor-avatar-lg {
  position: absolute;
  top: -2.5rem;
  left: 1.5rem;
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  border: 4px solid #fff;
  background: linear-gradient(to bottom right, #6366f1, #9333ea);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  box-shadow: var(--shadow-md);
}

.vendor-details {
  padding-top: 3rem;
}

.vendor-header-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vendor-name-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.vendor-name {
  font-size: 1.25rem;
  font-weight: 700;
}

.vendor-badge {
  color: #6366f1;
  width: 1.25rem;
  height: 1.25rem;
}

.vendor-rating-box {
  display: flex;
  align-items: center;
  background: #fffbeb;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
}

.vendor-rating-box span {
  font-weight: 700;
  color: #b45309;
  font-size: 0.875rem;
  margin-left: 0.25rem;
}

.vendor-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.stat-box { text-align: center; }
.stat-box.bordered {
  border-left: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
}

.stat-val {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
}

.stat-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-gray);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
}

.btn-visit {
  width: 100%;
  margin-top: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid #e0e7ff;
  border-radius: 0.75rem;
  background: #eef2ff;
  color: #4338ca;
  font-weight: 500;
  font-size: 0.875rem;
  transition: all 0.3s;
}

.btn-visit:hover {
  background: #4f46e5;
  color: #fff;
}

@media (min-width: 768px) { .vendor-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .vendor-grid { grid-template-columns: repeat(3, 1fr); } }

/* CTA */
.cta-section {
  background-color: var(--primary-color);
  position: relative;
  overflow: hidden;
}

.cta-bg-1 {
  position: absolute;
  top: -5rem;
  right: -5rem;
  width: 16rem;
  height: 16rem;
  border-radius: 50%;
  background: #6366f1;
  opacity: 0.5;
  filter: blur(40px);
}

.cta-bg-2 {
  position: absolute;
  bottom: -5rem;
  left: -5rem;
  width: 20rem;
  height: 20rem;
  border-radius: 50%;
  background: #a855f7;
  opacity: 0.5;
  filter: blur(40px);
}

.cta-container {
  padding: 4rem 1rem;
  position: relative;
  z-index: 10;
}

.cta-card {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 1.5rem;
  padding: 2rem;
  box-shadow: var(--shadow-xl);
}

.cta-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  background: rgba(99, 102, 241, 0.3);
  border: 1px solid rgba(129, 140, 248, 0.3);
  color: #e0e7ff;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: 9999px;
  margin-bottom: 1.5rem;
  gap: 0.5rem;
}

.cta-title {
  font-size: 1.875rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1rem;
}

.cta-title span:last-child { color: #c7d2fe; display: block; }
.cta-desc { color: #e0e7ff; font-size: 1.125rem; margin-bottom: 2rem; }

.cta-btns {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.btn-cta-primary {
  background: #fff;
  color: var(--primary-color);
  padding: 1rem 2rem;
  border-radius: 9999px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s;
}

.btn-cta-primary:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
  background: #eef2ff;
}

.btn-cta-secondary {
  border: 2px solid rgba(255,255,255,0.3);
  color: #fff;
  padding: 1rem 2rem;
  border-radius: 9999px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}

.btn-cta-secondary:hover {
  background: rgba(255,255,255,0.1);
}

@media (min-width: 1024px) {
  .cta-container { padding: 5rem 2rem; }
  .cta-card { display: flex; align-items: center; justify-content: space-between; padding: 3rem; }
  .cta-text-area { width: 50%; }
  .cta-btns { flex-direction: row; margin-top: 0; }
  .cta-title { font-size: 2.25rem; }
}

/* Footer */
.footer {
  background: var(--bg-dark);
  color: var(--text-light);
  padding: 3rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand .logo {
  margin-bottom: 1rem;
  display: inline-block;
}

.footer-desc {
  max-width: 20rem;
  margin-bottom: 1.5rem;
}

.social-links {
  display: flex;
  gap: 1.5rem;
}

.social-links a { transition: color 0.2s; }
.social-links a:hover { color: #d1d5db; }
.social-links svg { width: 1.5rem; height: 1.5rem; }

.footer-links-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.footer-col h3 {
  color: #d1d5db;
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-col a { transition: color 0.2s; }
.footer-col a:hover { color: #fff; }

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid #1f2937;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.payment-methods {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.pay-card {
  padding: 0.25rem 0.5rem;
  background: #1f2937;
  border: 1px solid #374151;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 700;
}

@media (min-width: 768px) {
  .footer-links-grid { grid-template-columns: repeat(4, 1fr); }
  .footer-bottom { flex-direction: row; justify-content: space-between; }
}
@media (min-width: 1280px) {
  .footer-grid { grid-template-columns: 1fr 2fr; }
}
