/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #818cf8;
  --accent: #8b5cf6;
  --dark: #0f0f1a;
  --dark-2: #1a1a2e;
  --dark-3: #242438;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --border: rgba(255,255,255,0.08);
  --card-bg: #16162a;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 48px rgba(0,0,0,0.5);
  --transition: 0.2s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--dark);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-lg { padding: 14px 32px; font-size: 16px; border-radius: 10px; }
.btn-full { width: 100%; }

.btn-primary {
  background: var(--primary);
  color: #fff;
}
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 20px rgba(99,102,241,0.4); }

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}
.btn-ghost:hover { color: var(--text); }

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-outline:hover { border-color: var(--primary-light); color: var(--primary-light); transform: translateY(-1px); }

.btn-white {
  background: #fff;
  color: var(--dark);
}
.btn-white:hover { background: #f1f5f9; transform: translateY(-1px); }

.btn-outline-white {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,0.4);
}
.btn-outline-white:hover { border-color: #fff; background: rgba(255,255,255,0.1); }

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(15,15,26,0.8);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}
.nav.scrolled { background: rgba(15,15,26,0.95); }

.nav-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 64px;
  padding: 0 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.5px;
  flex-shrink: 0;
}
.logo span { color: var(--primary); }

.nav-links {
  display: flex;
  gap: 4px;
  margin-left: auto;
}
.nav-links a {
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all var(--transition);
}
.nav-links a:hover { color: var(--text); background: rgba(255,255,255,0.06); }

.nav-actions { display: flex; gap: 8px; align-items: center; }

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

.mobile-menu {
  display: none;
  flex-direction: column;
  padding: 12px 24px 20px;
  gap: 4px;
  border-top: 1px solid var(--border);
}
.mobile-menu a {
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-muted);
}
.mobile-menu a:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.mobile-menu.open { display: flex; }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 0 80px;
  overflow: hidden;
  text-align: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.15;
}
.blob-1 { width: 600px; height: 600px; background: var(--primary); top: -200px; left: -100px; animation: float 8s ease-in-out infinite; }
.blob-2 { width: 500px; height: 500px; background: var(--accent); bottom: -100px; right: -100px; animation: float 10s ease-in-out infinite reverse; }
.blob-3 { width: 300px; height: 300px; background: #06b6d4; top: 40%; left: 50%; transform: translate(-50%,-50%); animation: float 6s ease-in-out infinite 2s; }

@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  33% { transform: translate(20px, -20px); }
  66% { transform: translate(-15px, 15px); }
}

.hero .container { position: relative; z-index: 1; }

.hero-badge {
  display: inline-block;
  background: rgba(99,102,241,0.15);
  border: 1px solid rgba(99,102,241,0.3);
  color: var(--primary-light);
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.3px;
}

.hero-title {
  font-size: clamp(40px, 7vw, 72px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -2px;
  margin-bottom: 20px;
}
.hero-title span {
  background: linear-gradient(135deg, var(--primary-light), #a78bfa, #67e8f9);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(16px, 2vw, 19px);
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 36px;
  line-height: 1.65;
}

.hero-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 56px; }

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}
.stat { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.stat strong { font-size: 28px; font-weight: 800; color: #fff; }
.stat span { font-size: 13px; color: var(--text-muted); font-weight: 500; }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

/* ===== PROOF STRIP ===== */
.proof-strip {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--dark-2);
  padding: 20px 24px;
  overflow: hidden;
}
.proof-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
  justify-content: center;
}
.proof-inner > span {
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
  font-weight: 500;
}
.proof-logos { display: flex; gap: 32px; align-items: center; flex-wrap: wrap; justify-content: center; }
.proof-logo {
  font-size: 14px;
  font-weight: 700;
  color: rgba(148,163,184,0.5);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 12px;
  transition: color var(--transition);
}
.proof-logo:hover { color: var(--text-muted); }

/* ===== SECTIONS ===== */
.section { padding: 96px 0; }
.section-alt { background: var(--dark-2); }

.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-header h2 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800;
  letter-spacing: -1.5px;
  margin-bottom: 12px;
}
.section-header p {
  color: var(--text-muted);
  font-size: 17px;
  max-width: 500px;
  margin: 0 auto;
}

/* ===== CATEGORIES ===== */
.categories-grid {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 20px 24px;
  background: var(--dark-3);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
  min-width: 120px;
  color: var(--text-muted);
  font-family: inherit;
}
.cat-card:hover { border-color: var(--primary); color: var(--text); transform: translateY(-2px); }
.cat-card.active { border-color: var(--primary); background: rgba(99,102,241,0.1); color: var(--primary-light); }
.cat-icon { font-size: 22px; margin-bottom: 4px; color: currentColor; }
.cat-card span { font-size: 13px; font-weight: 600; }
.cat-card small { font-size: 12px; opacity: 0.6; }

/* ===== FILTER BAR ===== */
.filter-bar {
  display: flex;
  gap: 12px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}
.search-wrap {
  flex: 1;
  min-width: 220px;
  position: relative;
}
.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  pointer-events: none;
}
.search-input {
  width: 100%;
  background: var(--dark-3);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 11px 14px 11px 42px;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  transition: border-color var(--transition);
  outline: none;
}
.search-input::placeholder { color: var(--text-muted); }
.search-input:focus { border-color: var(--primary); }

.sort-select {
  background: var(--dark-3);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 11px 16px;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  outline: none;
  transition: border-color var(--transition);
}
.sort-select:focus { border-color: var(--primary); }

/* ===== TEMPLATE CARDS ===== */
.templates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.template-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.25s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.template-card:hover { transform: translateY(-4px); box-shadow: 0 12px 48px rgba(0,0,0,0.5); border-color: rgba(255,255,255,0.12); }

.template-preview {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
}
.template-preview-inner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  position: relative;
  overflow: hidden;
}
.template-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
  opacity: 0;
  transition: opacity 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.template-card:hover .template-overlay { opacity: 1; }

.template-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.template-badge.new { background: rgba(16,185,129,0.8); border-color: rgba(16,185,129,0.5); }
.template-badge.sale { background: rgba(239,68,68,0.8); border-color: rgba(239,68,68,0.5); }
.template-badge.free { background: rgba(99,102,241,0.8); border-color: rgba(99,102,241,0.5); }

.template-body { padding: 20px; display: flex; flex-direction: column; gap: 12px; flex: 1; }

.template-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.template-name { font-size: 16px; font-weight: 700; color: #fff; }
.template-cat {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary-light);
  background: rgba(99,102,241,0.12);
  padding: 3px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.template-desc { font-size: 13px; color: var(--text-muted); line-height: 1.55; }

.template-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.template-price { font-size: 20px; font-weight: 800; color: #fff; }
.template-price .original {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-right: 4px;
}
.template-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--text-muted);
}
.template-rating .star { color: #f59e0b; }

.load-more-wrap { text-align: center; }

/* ===== FEATURES ===== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}
.feature-card {
  background: var(--dark-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all var(--transition);
}
.feature-card:hover { border-color: rgba(255,255,255,0.12); transform: translateY(-2px); }

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}
.feature-icon svg { width: 24px; height: 24px; }
.feature-icon-blue  { background: rgba(99,102,241,0.15); color: #818cf8; }
.feature-icon-purple { background: rgba(139,92,246,0.15); color: #a78bfa; }
.feature-icon-green  { background: rgba(16,185,129,0.15); color: #34d399; }
.feature-icon-orange { background: rgba(245,158,11,0.15); color: #fbbf24; }
.feature-icon-pink   { background: rgba(236,72,153,0.15); color: #f472b6; }
.feature-icon-teal   { background: rgba(6,182,212,0.15);  color: #22d3ee; }

.feature-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 10px; }
.feature-card p  { font-size: 14px; color: var(--text-muted); line-height: 1.6; }

/* ===== PRICING ===== */
.pricing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-bottom: 40px;
  background: var(--dark-3);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 4px;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}
.toggle-btn {
  padding: 8px 20px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 8px;
}
.toggle-btn.active { background: var(--primary); color: #fff; }
.badge-save {
  background: rgba(16,185,129,0.2);
  color: #34d399;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 100px;
  font-weight: 700;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  align-items: start;
}
.pricing-card {
  background: var(--dark-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  position: relative;
  transition: all var(--transition);
}
.pricing-card:hover { transform: translateY(-4px); }
.pricing-card-featured {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(139,92,246,0.05));
  box-shadow: 0 0 0 1px var(--primary), 0 8px 32px rgba(99,102,241,0.2);
}

.pricing-popular {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  padding: 4px 16px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.pricing-label { font-size: 14px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 12px; }
.pricing-price { display: flex; align-items: flex-start; gap: 2px; margin-bottom: 4px; }
.currency { font-size: 22px; font-weight: 700; margin-top: 8px; }
.amount { font-size: 56px; font-weight: 800; line-height: 1; letter-spacing: -2px; }
.pricing-period { font-size: 13px; color: var(--text-muted); margin-bottom: 28px; font-weight: 500; }

.pricing-features { display: flex; flex-direction: column; gap: 12px; margin-bottom: 28px; }
.pricing-features li { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.pricing-features li.disabled { color: var(--text-muted); }
.check { color: #34d399; font-weight: 700; }
.cross { color: #475569; }

/* ===== TESTIMONIALS ===== */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
.testimonial-card {
  background: var(--dark-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: all var(--transition);
}
.testimonial-card:hover { transform: translateY(-2px); border-color: rgba(255,255,255,0.12); }
.testimonial-featured {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(99,102,241,0.06), transparent);
}
.stars { color: #f59e0b; font-size: 15px; letter-spacing: 2px; }
.testimonial-card p { font-size: 14px; color: var(--text-muted); line-height: 1.65; flex: 1; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff;
  flex-shrink: 0;
}
.testimonial-author strong { font-size: 14px; font-weight: 700; display: block; }
.testimonial-author span { font-size: 12px; color: var(--text-muted); }

/* ===== CTA BANNER ===== */
.cta-banner {
  background: linear-gradient(135deg, var(--primary-dark), var(--accent));
  padding: 96px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::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%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.cta-banner .container { position: relative; }
.cta-banner h2 { font-size: clamp(28px, 4vw, 44px); font-weight: 800; letter-spacing: -1.5px; margin-bottom: 12px; }
.cta-banner p { font-size: 17px; opacity: 0.85; margin-bottom: 36px; }
.cta-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ===== FOOTER ===== */
.footer {
  background: var(--dark-2);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand p { font-size: 14px; color: var(--text-muted); margin-top: 12px; line-height: 1.65; max-width: 260px; }
.social-links { display: flex; gap: 12px; margin-top: 20px; }
.social-links a {
  width: 36px; height: 36px;
  border-radius: 8px;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  color: var(--text-muted);
  transition: all var(--transition);
}
.social-links a:hover { border-color: var(--primary); color: var(--primary-light); }

.footer-col h4 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px; color: var(--text); }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 14px; color: var(--text-muted); transition: color var(--transition); }
.footer-col a:hover { color: var(--text); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--text-muted);
}
.footer-legal { display: flex; gap: 24px; }
.footer-legal a:hover { color: var(--text); }

/* ===== MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }

.modal {
  background: var(--dark-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 780px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: translateY(20px);
  transition: transform 0.25s;
}
.modal-overlay.open .modal { transform: translateY(0); }

.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 32px; height: 32px;
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
  border: none;
  color: var(--text);
  font-size: 20px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  z-index: 1;
  transition: background var(--transition);
}
.modal-close:hover { background: rgba(255,255,255,0.14); }

.modal-preview {
  aspect-ratio: 16/9;
  overflow: hidden;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
.modal-info { padding: 28px; }
.modal-info h2 { font-size: 24px; font-weight: 800; margin-bottom: 8px; }
.modal-info p { color: var(--text-muted); font-size: 15px; line-height: 1.6; margin-bottom: 20px; }
.modal-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.modal-price { font-size: 28px; font-weight: 800; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .nav-links, .nav-actions { display: none; }
  .hamburger { display: flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 600px) {
  .hero { padding: 100px 0 60px; }
  .hero-stats { gap: 24px; }
  .stat-divider { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .templates-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .testimonials-grid { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
}

/* ===== PORTFOLIO SHOWCASE ===== */
.portfolio-showcase-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}

.pf-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  flex-direction: column;
}
.pf-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(0,0,0,0.5);
  border-color: rgba(255,255,255,0.14);
}

.pf-thumb {
  aspect-ratio: 3/4;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  position: relative;
  overflow: hidden;
}
.pf-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, transparent 60%);
}
.pf-thumb-content {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 16px;
}
.pf-name {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 4px;
  letter-spacing: -0.3px;
}
.pf-style {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.pf-actions {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  opacity: 0;
  transition: opacity 0.2s;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px);
}
.pf-card:hover .pf-actions { opacity: 1; }

.pf-price-tag {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 100px;
}

@media (max-width: 1024px) {
  .portfolio-showcase-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 640px) {
  .portfolio-showcase-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== ANIMATIONS ===== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== CART BUTTON ===== */
.cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  border: 1.5px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
}
.cart-btn:hover { color: var(--text); border-color: var(--primary); background: rgba(99,102,241,0.1); }

.cart-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ===== CART OVERLAY ===== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.cart-overlay.open { opacity: 1; pointer-events: all; }

/* ===== CART DRAWER ===== */
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 420px;
  max-width: 100vw;
  background: var(--dark-2);
  border-left: 1px solid var(--border);
  z-index: 200;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  overflow: hidden;
}
.cart-drawer.open { transform: translateX(0); }

.cart-view {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
}

/* ===== CART HEADER ===== */
.cart-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.cart-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  flex: 1;
}
.cart-close, .cart-back {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  padding: 4px 6px;
  border-radius: 6px;
  transition: color var(--transition), background var(--transition);
}
.cart-close:hover, .cart-back:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.cart-back { font-size: 13px; font-weight: 600; }

/* ===== CART BODY ===== */
.cart-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--dark-3) transparent;
}
.cart-body::-webkit-scrollbar { width: 4px; }
.cart-body::-webkit-scrollbar-track { background: transparent; }
.cart-body::-webkit-scrollbar-thumb { background: var(--dark-3); border-radius: 4px; }

/* ===== EMPTY STATE ===== */
.cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 12px;
  color: var(--text-muted);
  text-align: center;
  padding: 40px 0;
}
.cart-empty-icon { font-size: 48px; opacity: 0.4; }
.cart-empty h3 { font-size: 16px; font-weight: 600; color: var(--text); }
.cart-empty p { font-size: 14px; line-height: 1.5; }

/* ===== CART ITEM ===== */
.cart-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  animation: slideIn 0.2s ease;
}
.cart-item:last-child { border-bottom: none; }

@keyframes slideIn {
  from { opacity: 0; transform: translateX(16px); }
  to   { opacity: 1; transform: translateX(0); }
}

.cart-item-thumb {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name { font-size: 14px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cart-item-cat { font-size: 12px; color: var(--text-muted); margin-top: 2px; text-transform: capitalize; }
.cart-item-price { font-size: 15px; font-weight: 700; color: var(--primary-light); flex-shrink: 0; }
.cart-item-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 16px;
  padding: 4px;
  border-radius: 4px;
  transition: color var(--transition);
  flex-shrink: 0;
  line-height: 1;
}
.cart-item-remove:hover { color: #f87171; }

/* ===== CART FOOTER ===== */
.cart-footer {
  padding: 16px 24px 24px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.cart-summary { margin-bottom: 16px; }
.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text-muted);
  padding: 4px 0;
}
.cart-summary-total {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  border-top: 1px solid var(--border);
  margin-top: 8px;
  padding-top: 12px;
}
.cart-secure {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 10px;
}

/* ===== CHECKOUT FORM ===== */
.checkout-order-summary {
  background: var(--dark-3);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 20px;
}
.checkout-order-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  padding: 5px 0;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}
.checkout-order-item:last-child { border-bottom: none; }
.checkout-order-item strong { color: var(--text); }
.checkout-order-item span { color: var(--primary-light); font-weight: 600; }

.checkout-section-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.form-row { display: flex; gap: 12px; }
.form-row .form-group { flex: 1; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}
.form-group label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}
.form-group input {
  padding: 10px 14px;
  background: var(--dark-3);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  outline: none;
  transition: border-color var(--transition);
  width: 100%;
}
.form-group input:focus { border-color: var(--primary); }
.form-group input.error { border-color: #f87171; }
.form-group input::placeholder { color: var(--text-muted); }

.checkout-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  border-top: 1px solid var(--border);
  margin-top: 4px;
}
.checkout-total-row strong { color: var(--primary-light); font-size: 18px; }

/* ===== SUCCESS VIEW ===== */
.success-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 0;
  gap: 12px;
}
.success-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(16,185,129,0.15);
  border: 2px solid #10b981;
  color: #10b981;
  font-size: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}
.success-title { font-size: 22px; font-weight: 700; color: var(--text); }
.success-msg { font-size: 14px; color: var(--text-muted); max-width: 280px; line-height: 1.6; }
.success-items {
  width: 100%;
  background: var(--dark-3);
  border-radius: var(--radius);
  padding: 12px 16px;
  margin: 8px 0 16px;
}
.success-item {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 4px 0;
  color: var(--text-muted);
}
.success-item strong { color: var(--text); }

@media (max-width: 480px) {
  .cart-drawer { width: 100vw; }
}

/* ===== STRIPE PAYMENT ELEMENT ===== */
#payment-element-wrap {
  position: relative;
  min-height: 60px;
  margin-bottom: 4px;
}
#payment-element { margin-bottom: 4px; }

.payment-error-msg {
  font-size: 13px;
  color: #f87171;
  min-height: 18px;
  margin-bottom: 8px;
}

/* Loading dots shown while Stripe element initialises */
.stripe-loader {
  display: flex;
  gap: 6px;
  justify-content: center;
  align-items: center;
  padding: 20px 0;
}
.stripe-loader.hidden { display: none; }
.stripe-loader-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  animation: stripePulse 1.2s ease-in-out infinite;
}
.stripe-loader-dot:nth-child(2) { animation-delay: 0.2s; }
.stripe-loader-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes stripePulse {
  0%, 80%, 100% { opacity: 0.2; transform: scale(0.85); }
  40%           { opacity: 1;   transform: scale(1); }
}
