:root {
  --bg: #FAF7F2;
  --bg-alt: #F0EBE3;
  --fg: #1A1A1A;
  --fg-muted: #6B5E4E;
  --accent: #C8973B;
  --accent-dark: #A07828;
  --card-bg: #FFFFFF;
  --card-border: #E5DED4;
  --hero-card-1: #F5E6C8;
  --hero-card-2: #E8DDD0;
  --hero-card-3: #1A1A1A;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: 'DM Sans', sans-serif;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 3px; }

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  background: rgba(250, 247, 242, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(229, 222, 212, 0.5);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--fg);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--fg-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--fg); }

/* Hero */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem 2rem 5rem;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 50%;
  right: -5%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  opacity: 0.9;
}

.hero-card {
  display: flex;
  gap: 0.75rem;
  transform: rotate(-3deg);
  filter: drop-shadow(0 8px 32px rgba(0,0,0,0.12));
}

.hero-card-1 { transform: rotate(-4deg) translateX(20px); }
.hero-card-2 { transform: rotate(2deg) translateX(-10px); }
.hero-card-3 { transform: rotate(-1deg) translateX(5px); }

.card-face {
  width: 90px;
  height: 54px;
  border-radius: 6px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-recto { background: var(--hero-card-1); }
.card-verso { background: #EDE4D3; }

.card-logo {
  width: 20px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
}
.card-logo-alt { background: #A07040; }
.card-logo-dark { background: var(--accent); }
.card-logo-w { background: rgba(255,255,255,0.6); }
.card-logo-c { background: rgba(200, 151, 59, 0.7); }

.card-lines { display: flex; flex-direction: column; gap: 3px; }
.card-line { height: 2px; background: rgba(0,0,0,0.12); border-radius: 1px; }
.card-line-1 { width: 70%; }
.card-line-2 { width: 85%; }
.card-line-3 { width: 60%; }
.card-line-4 { width: 75%; }
.card-line-accent { background: rgba(200,151,59,0.3); }
.card-line-dark { background: rgba(255,255,255,0.2); }
.card-line-w { background: rgba(255,255,255,0.3); }

.card-qr {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 8px;
  color: rgba(0,0,0,0.25);
  font-weight: 600;
  letter-spacing: -1px;
}
.card-qr::before {
  content: "QR";
  font-size: 7px;
  font-weight: 700;
  letter-spacing: 0;
}
.card-qr-alt::before { content: "QR"; }
.card-qr-w::before { content: "QR"; color: rgba(255,255,255,0.3); }

.hero-content {
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 1.5rem;
  background: rgba(200, 151, 59, 0.1);
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
}

.eyebrow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.2); }
}

.hero-title {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 1.5rem;
  max-width: 600px;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--fg-muted);
  max-width: 520px;
  line-height: 1.7;
  font-weight: 400;
}

/* How Section */
.how {
  padding: 6rem 2rem;
  background: var(--bg-alt);
}

.how-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.section-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  letter-spacing: -0.025em;
  color: var(--fg);
  margin-bottom: 3rem;
  line-height: 1.2;
}

.how-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.how-step {
  position: relative;
}

.step-number {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 3rem;
  color: var(--card-border);
  line-height: 1;
  margin-bottom: 1rem;
  letter-spacing: -0.04em;
}

.how-step h3 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
  letter-spacing: -0.01em;
}

.how-step p {
  color: var(--fg-muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

/* Features */
.features {
  padding: 6rem 2rem;
  background: var(--bg);
}

.features-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 1.75rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
}

.feature-icon {
  width: 44px;
  height: 44px;
  background: rgba(200, 151, 59, 0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-dark);
  margin-bottom: 1.25rem;
}

.feature-card h3 {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.feature-card p {
  color: var(--fg-muted);
  font-size: 0.875rem;
  line-height: 1.6;
}

/* Templates */
.templates {
  padding: 6rem 2rem;
  background: var(--bg-alt);
}

.templates-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.templates-desc {
  color: var(--fg-muted);
  font-size: 1rem;
  max-width: 560px;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.template-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 3rem;
}

.category-pill {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--fg-muted);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.4rem 1rem;
  border-radius: 20px;
  letter-spacing: 0.02em;
}

/* When category pills are links */
a.category-pill-link {
  text-decoration: none;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  cursor: pointer;
}
a.category-pill-link:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.template-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.template-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s;
}

.template-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.08);
}

.template-preview {
  display: flex;
  gap: 0.5rem;
  padding: 1rem;
  background: var(--bg);
}

.tp-face {
  flex: 1;
  aspect-ratio: 1.586;
  border-radius: 5px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.tp-face-a { background: #F5E6C8; }
.tp-face-b { background: #EDE4D3; }
.tp-face-dark .tp-face-a, .tp-face-dark .tp-face-b { background: #1A1A1A; }
.tp-face-pattern .tp-face-a { background: repeating-linear-gradient(45deg, #F5E6C8, #F5E6C8 4px, #EDE4D3 4px, #EDE4D3 8px); }
.tp-face-corp .tp-face-a { background: #FFFFFF; border: 1px solid #E5DED4; }

.tp-logo {
  width: 24px;
  height: 6px;
  background: var(--accent);
  border-radius: 2px;
}
.tp-logo-w { background: rgba(255,255,255,0.4); }
.tp-logo-c { background: rgba(200,151,59,0.5); }

.tp-line {
  height: 2px;
  background: rgba(0,0,0,0.12);
  border-radius: 1px;
  width: 85%;
}
.tp-line-sm { width: 55%; }
.tp-line-w { background: rgba(255,255,255,0.2); }
.tp-line-accent { background: rgba(200,151,59,0.4); }

.tp-qr {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tp-qr::before {
  content: "QR";
  font-size: 6px;
  font-weight: 700;
  color: rgba(0,0,0,0.2);
}
.tp-qr-w::before { color: rgba(255,255,255,0.2); }

.template-meta {
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.template-cat {
  font-size: 0.7rem;
  color: var(--accent-dark);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.template-name {
  font-family: 'Syne', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--fg);
}

/* Closing */
.closing {
  padding: 8rem 2rem;
  background: var(--fg);
  text-align: center;
}

.closing-inner {
  max-width: 680px;
  margin: 0 auto;
}

.closing-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 2rem;
}

.closing-title {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--bg);
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.closing-sub {
  color: rgba(250,247,242,0.6);
  font-size: 1rem;
  line-height: 1.7;
  max-width: 500px;
  margin: 0 auto;
}

/* Footer */
.footer {
  padding: 2.5rem 2rem;
  background: var(--fg);
  border-top: 1px solid rgba(255,255,255,0.06);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--bg);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
}

.footer-copy {
  color: rgba(250,247,242,0.4);
  font-size: 0.8rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: rgba(250,247,242,0.5);
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--bg); }

/* Responsive */
@media (max-width: 900px) {
  .hero-bg { display: none; }
  .hero-content { max-width: 100%; }
  .how-steps { grid-template-columns: 1fr; gap: 2.5rem; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .template-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .hero { padding: 7rem 1.5rem 4rem; }
  .how, .features, .templates { padding: 4rem 1.5rem; }
  .closing { padding: 5rem 1.5rem; }
  .features-grid { grid-template-columns: 1fr; }
  .template-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { flex-direction: column; text-align: center; gap: 1rem; }
  .nav-links { display: none; }
}