@import url('https://fonts.googleapis.com/css2?family=Righteous&family=Poppins:wght@300;400;500;600;700&display=swap');

/* ===== DESIGN TOKENS ===== */
:root {
  --color-primary: #1e293b;
  --color-primary-dark: #0f172a;
  --color-secondary: #334155;
  --color-cta: #dc2626;
  --color-cta-dark: #b91c1c;
  --color-bg: #f1f5f9;
  --color-surface: #ffffff;
  --color-text: #0f172a;
  --color-text-muted: #64748b;
  --color-border: #e2e8f0;
  --color-border-strong: #1e293b;
  --color-accent: #3b82f6;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.1);
  --shadow-lg: 0 10px 24px rgba(15, 23, 42, 0.12);
  --shadow-xl: 0 20px 40px rgba(15, 23, 42, 0.15);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;

  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;

  --font-ui: 'Poppins', system-ui, sans-serif;
  --font-heading: 'Righteous', system-ui, sans-serif;
  --max-width: 1000px;
  --z-header: 100;
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-ui);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; }

/* ===== LAYOUT ===== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

/* ===== ANNOUNCEMENT BAR ===== */
.announcement-bar {
  background: var(--color-primary);
  color: white;
  text-align: center;
  padding: 0.5rem var(--spacing-md);
  font-size: 0.88rem;
  font-weight: 500;
}
.announcement-bar a {
  color: #93c5fd;
  font-weight: 700;
  text-decoration: underline;
  margin-left: 0.5rem;
}

/* ===== HEADER / NAV ===== */
header {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  box-shadow: var(--shadow-sm);
}
.nav-bar {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.75rem var(--spacing-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-md);
  position: relative;
}
.logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 400;
  color: var(--color-primary);
  text-decoration: none;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}
.logo:hover { text-decoration: none; opacity: 0.85; }
.logo-dot { color: var(--color-cta); }

.nav-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
  background: none;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all 200ms ease;
}
.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav-panel {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-surface);
  flex-direction: column;
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  gap: var(--spacing-xs);
  z-index: calc(var(--z-header) - 1);
}
.nav-panel.nav-open { display: flex; }
.nav-panel a {
  color: var(--color-text);
  padding: 0.4rem 0;
  font-weight: 500;
  border-bottom: 1px solid var(--color-border);
  transition: color 150ms ease;
}
.nav-panel a:last-child { border-bottom: none; }
.nav-panel a:hover { color: var(--color-cta); text-decoration: none; }
.nav-cta-link {
  display: inline-block;
  margin-top: var(--spacing-sm);
  background: var(--color-cta);
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-align: center;
  transition: background 150ms ease;
}
.nav-cta-link:hover { background: var(--color-cta-dark) !important; }

/* ===== SKIP LINK ===== */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--color-primary);
  color: white;
  padding: 0.5rem 1rem;
  z-index: 200;
}
.skip-link:focus { top: 0; }

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  background: var(--color-cta);
  color: white;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  transition: all 200ms ease;
  text-decoration: none;
  font-family: var(--font-ui);
}
.btn-primary:hover {
  background: var(--color-cta-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  text-decoration: none;
}

.btn-secondary {
  display: inline-block;
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 200ms ease;
  text-decoration: none;
}
.btn-secondary:hover {
  background: var(--color-primary);
  color: white;
  text-decoration: none;
}

/* ===== HERO ===== */
.hero {
  background: var(--color-primary);
  padding: var(--spacing-3xl) var(--spacing-lg);
  text-align: center;
  color: white;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 40px,
    rgba(255,255,255,0.02) 40px,
    rgba(255,255,255,0.02) 41px
  );
}
.hero-badge {
  display: inline-block;
  background: rgba(220, 38, 38, 0.9);
  color: white;
  padding: 0.25rem 0.85rem;
  border-radius: 100px;
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: var(--spacing-lg);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  position: relative;
}
.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.4rem, 7vw, 4.5rem);
  color: white;
  line-height: 1.1;
  margin-bottom: var(--spacing-lg);
  font-weight: 400;
  letter-spacing: 0.01em;
  position: relative;
}
.hero h1 span { color: #f87171; }
.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: rgba(255,255,255,0.75);
  max-width: 600px;
  margin: 0 auto var(--spacing-xl);
  line-height: 1.65;
  position: relative;
}
.hero-actions {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--spacing-xl);
  position: relative;
}
.hero-proof {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.55);
  position: relative;
}
.btn-hero-secondary {
  display: inline-block;
  background: rgba(255,255,255,0.12);
  color: white;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 200ms ease;
  text-decoration: none;
}
.btn-hero-secondary:hover {
  background: rgba(255,255,255,0.2);
  text-decoration: none;
}

/* ===== SECTION HEADINGS ===== */
.section {
  padding: var(--spacing-3xl) var(--spacing-lg);
}
.section-alt {
  background: var(--color-surface);
}
.section-center { text-align: center; }
.section-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-cta);
  margin-bottom: var(--spacing-sm);
}
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
  color: var(--color-text);
  margin-bottom: var(--spacing-md);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.01em;
}
.section-subtitle {
  font-size: 1rem;
  color: var(--color-text-muted);
  max-width: 580px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ===== DESIGN COLLECTION CARDS ===== */
.collections-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--spacing-md);
  margin-top: var(--spacing-2xl);
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
}
.collection-card {
  background: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
  transition: all 200ms ease;
  text-decoration: none;
  color: inherit;
  display: block;
}
.collection-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
  text-decoration: none;
}
.collection-swatch-bar {
  height: 80px;
  display: flex;
}
.collection-swatch-color { flex: 1; }
.collection-card-info {
  padding: var(--spacing-md);
}
.collection-card-info h3 {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: 4px;
  letter-spacing: 0.01em;
}
.collection-card-info p {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

/* ===== HOW IT WORKS ===== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-2xl);
  margin-top: var(--spacing-2xl);
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
}
.step { text-align: center; }
.step-number {
  width: 48px;
  height: 48px;
  background: var(--color-primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  margin: 0 auto var(--spacing-md);
  font-family: var(--font-heading);
}
.step h3 { font-size: 1.05rem; font-weight: 600; margin-bottom: var(--spacing-sm); }
.step p { font-size: 0.92rem; color: var(--color-text-muted); line-height: 1.6; }

/* ===== PRICING ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-2xl);
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}
.pricing-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  border: 2px solid var(--color-border);
  text-align: center;
}
.pricing-card.featured {
  border-color: var(--color-cta);
  position: relative;
}
.pricing-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-cta);
  color: white;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.8rem;
  border-radius: 100px;
  white-space: nowrap;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.pricing-tier { font-size: 1rem; font-weight: 700; margin-bottom: var(--spacing-sm); text-transform: uppercase; letter-spacing: 0.05em; }
.pricing-price {
  font-family: var(--font-heading);
  font-size: 3rem;
  color: var(--color-text);
  line-height: 1;
  margin-bottom: var(--spacing-xs);
}
.pricing-price-note { font-size: 0.82rem; color: var(--color-text-muted); margin-bottom: var(--spacing-md); }
.pricing-features { list-style: none; text-align: left; margin-bottom: var(--spacing-lg); }
.pricing-features li {
  padding: 0.4rem 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm);
  border-bottom: 1px solid var(--color-bg);
}
.pricing-features li:last-child { border-bottom: none; }
.check-icon { color: var(--color-primary); flex-shrink: 0; font-weight: 700; }
.pricing-features .muted { opacity: 0.5; }

/* ===== DESIGNER PAGE ===== */
.designer-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: var(--spacing-xl);
  max-width: 1100px;
  margin: 0 auto;
  padding: var(--spacing-xl) var(--spacing-lg);
  align-items: start;
}
@media (max-width: 768px) {
  .designer-layout { grid-template-columns: 1fr; }
  .preview-panel { order: -1; }
}

.controls-panel {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
}
.control-group h3 {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
  margin-bottom: var(--spacing-md);
}
.field { display: flex; flex-direction: column; gap: 0.3rem; margin-bottom: var(--spacing-sm); }
.field:last-child { margin-bottom: 0; }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--color-text); }
.field input {
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-bg);
  transition: border-color 150ms ease;
}
.field input:focus {
  border-color: var(--color-primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(30, 41, 59, 0.1);
  background: white;
}
.field input::placeholder { color: var(--color-text-muted); opacity: 0.6; }

/* Collection picker */
.collection-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.collection-btn {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: 0.45rem 0.6rem;
  border-radius: var(--radius-sm);
  border: 2px solid var(--color-border);
  background: var(--color-bg);
  cursor: pointer;
  transition: all 150ms ease;
  font-family: inherit;
  text-align: left;
}
.collection-btn:hover { border-color: var(--color-primary); }
.collection-btn.active { border-color: var(--color-primary); background: rgba(30, 41, 59, 0.05); }
.collection-swatches {
  display: flex;
  gap: 2px;
  flex-shrink: 0;
}
.collection-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.1);
  display: block;
}
.collection-name { font-size: 0.82rem; font-weight: 600; color: var(--color-text); }

/* Clothing type */
.merch-buttons {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}
.merch-btn {
  padding: 0.6rem var(--spacing-md);
  border-radius: var(--radius-sm);
  border: 2px solid var(--color-border);
  background: var(--color-bg);
  color: var(--color-text);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 150ms ease;
  text-align: left;
  font-family: inherit;
}
.merch-btn:hover { border-color: var(--color-primary); color: var(--color-primary); }
.merch-btn.active {
  border-color: var(--color-primary);
  background: rgba(30, 41, 59, 0.05);
  color: var(--color-primary);
}
.merch-dims-inline {
  display: block;
  font-size: 0.72rem;
  color: var(--color-text-muted);
  font-weight: 400;
  margin-top: 1px;
}

.btn-download {
  width: 100%;
  padding: 0.85rem;
  background: var(--color-primary);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 200ms ease;
  font-family: inherit;
}
.btn-download:hover {
  background: var(--color-primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.upgrade-cta {
  background: rgba(220, 38, 38, 0.05);
  border: 1px solid rgba(220, 38, 38, 0.2);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  text-align: center;
}
.upgrade-cta p {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin-bottom: var(--spacing-sm);
  line-height: 1.5;
}
.upgrade-cta a, .buy-btn {
  display: block;
  background: var(--color-cta);
  color: white;
  padding: 0.65rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: all 150ms ease;
}
.upgrade-cta a:hover, .buy-btn:hover { background: var(--color-cta-dark); text-decoration: none; }

.preview-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-md);
}
.canvas-container {
  width: 100%;
  overflow: auto;
  background: #e5e7eb;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--color-border);
  padding: var(--spacing-xl);
  display: flex;
  align-items: center;
  justify-content: center;
}
.merch-canvas {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}
.preview-label {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-align: center;
  font-style: italic;
  max-width: 400px;
}
.merch-dims-display {
  display: flex;
  gap: var(--spacing-md);
  font-size: 0.82rem;
  color: var(--color-text-muted);
  text-align: center;
  flex-wrap: wrap;
  justify-content: center;
}
.dim-tag {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 100px;
  padding: 0.2rem 0.7rem;
  font-weight: 500;
}

/* ===== FOOTER ===== */
footer {
  background: var(--color-primary);
  color: rgba(255,255,255,0.7);
  padding: var(--spacing-2xl) var(--spacing-lg) var(--spacing-xl);
  text-align: center;
  margin-top: auto;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-md);
  justify-content: center;
  margin-bottom: var(--spacing-lg);
}
.footer-nav a {
  color: rgba(255,255,255,0.6);
  font-size: 0.88rem;
  transition: color 150ms ease;
}
.footer-nav a:hover { color: white; text-decoration: none; }
.disclaimer {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.45);
  max-width: 600px;
  margin: 0 auto var(--spacing-lg);
  line-height: 1.5;
}
.footer-copy {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  margin-bottom: var(--spacing-md);
}
.footer-author {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
}
.footer-author a { color: rgba(255,255,255,0.7); }
.footer-author a:hover { color: white; }
.footer-products {
  margin-top: var(--spacing-lg);
}

/* ===== CTA SECTION ===== */
.cta-section {
  background: var(--color-cta);
  padding: var(--spacing-3xl) var(--spacing-lg);
  text-align: center;
  color: white;
}
.cta-section h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 5vw, 3rem);
  margin-bottom: var(--spacing-md);
  font-weight: 400;
  letter-spacing: 0.01em;
}
.cta-section p { font-size: 1.05rem; opacity: 0.9; margin-bottom: var(--spacing-xl); }
.cta-section .btn-primary {
  background: white;
  color: var(--color-cta);
}
.cta-section .btn-primary:hover {
  background: #fef2f2;
}

/* ===== DESIGNER HEADER ===== */
.designer-header {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: var(--spacing-lg) var(--spacing-lg) var(--spacing-md);
}
.designer-header h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  color: var(--color-primary);
  margin-bottom: var(--spacing-xs);
  font-weight: 400;
  letter-spacing: 0.01em;
}
.designer-header p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

/* ===== UTILITIES ===== */
.text-center { text-align: center; }
.mt-sm { margin-top: var(--spacing-sm); }
.mt-md { margin-top: var(--spacing-md); }
.mt-lg { margin-top: var(--spacing-lg); }
.mt-xl { margin-top: var(--spacing-xl); }
.mb-lg { margin-bottom: var(--spacing-lg); }

/* ===== RESPONSIVE ===== */
@media (max-width: 640px) {
  .hero { padding: var(--spacing-2xl) var(--spacing-md); }
  .section { padding: var(--spacing-2xl) var(--spacing-md); }
  .nav-bar { padding: 0.65rem var(--spacing-md); }
  .container { padding: 0 var(--spacing-md); }
  .collections-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
