/* ==========================================================================
   CVBuilderKit Website Stylesheet
   Apple-inspired design system for App Store metadata & marketing
   ========================================================================== */

:root {
  /* Color Palette - Light Mode Default */
  --font-sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Monaco, Consolas, monospace;

  --color-primary: #0071e3;
  --color-primary-hover: #0077ed;
  --color-primary-rgb: 0, 113, 227;
  --color-accent-emerald: #059669;
  
  --bg-body: #fbfbfd;
  --bg-nav: rgba(251, 251, 253, 0.82);
  --bg-card: #ffffff;
  --bg-card-subtle: #f5f5f7;
  --bg-badge: #e8f2fe;
  --text-badge: #0071e3;

  --text-main: #1d1d1f;
  --text-secondary: #6e6e73;
  --text-muted: #86868b;
  --text-inverse: #ffffff;

  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-card: rgba(0, 0, 0, 0.06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 20px 48px rgba(0, 0, 0, 0.12);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-pill: 9999px;

  --nav-height: 64px;
  --max-width: 1120px;
  --max-width-narrow: 840px;
  
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg-body: #0a0a0c;
    --bg-nav: rgba(10, 10, 12, 0.82);
    --bg-card: #151518;
    --bg-card-subtle: #1c1c20;
    --bg-badge: rgba(0, 113, 227, 0.2);
    --text-badge: #2997ff;

    --color-primary: #2997ff;
    --color-primary-hover: #3ca2ff;
    --color-primary-rgb: 41, 151, 255;

    --text-main: #f5f5f7;
    --text-secondary: #a1a1a6;
    --text-muted: #6e6e73;

    --border-subtle: rgba(255, 255, 255, 0.1);
    --border-card: rgba(255, 255, 255, 0.08);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.25);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.45);
    --shadow-hover: 0 20px 48px rgba(0, 0, 0, 0.55);
  }
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  text-decoration: none;
  opacity: 0.85;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Layout Utilities */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.container-narrow {
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.section {
  padding: 96px 0;
}

.section-alt {
  background-color: var(--bg-card-subtle);
}

/* Navigation */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-height);
  background: var(--bg-nav);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
}

.navbar-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--text-main);
}

.nav-logo {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.nav-links {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 28px;
}

.nav-link {
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text-main);
}

.mobile-toggle svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--color-primary);
  color: #ffffff !important;
}

.btn-primary:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(var(--color-primary-rgb), 0.35);
}

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-main);
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background-color: var(--bg-card-subtle);
  border-color: var(--border-card);
  transform: translateY(-1px);
}

.btn-appstore {
  background: #000000;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 10px 20px;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.btn-appstore:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn-appstore svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.btn-appstore-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.1;
}

.btn-appstore-sub {
  font-size: 0.65rem;
  font-weight: 400;
  opacity: 0.8;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.btn-appstore-title {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.2px;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  background-color: var(--bg-badge);
  color: var(--text-badge);
  letter-spacing: 0.2px;
  text-transform: uppercase;
}

.badge-privacy {
  background-color: rgba(5, 150, 105, 0.12);
  color: var(--color-accent-emerald);
}

/* Typography & Section Headers */
.section-header {
  text-align: center;
  margin-bottom: 56px;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin: 16px 0 12px;
  line-height: 1.2;
}

.section-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.5;
}

/* Hero Section */
.hero {
  padding: 80px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-content {
  max-width: 820px;
  margin: 0 auto 50px;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.1;
  margin: 20px 0;
}

.hero-title-gradient {
  background: linear-gradient(135deg, var(--text-main) 30%, var(--color-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto 32px;
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.hero-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  font-size: 0.85rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-meta-item svg {
  width: 16px;
  height: 16px;
  color: var(--color-accent-emerald);
}

/* Hero Visual Showcase */
.hero-mockup-wrap {
  position: relative;
  max-width: 980px;
  margin: 0 auto;
  padding-top: 20px;
}

.hero-device-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 32px;
  align-items: center;
}

.mockup-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-lg);
  padding: 16px;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

.mockup-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.mockup-caption {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mockup-tag {
  font-size: 0.75rem;
  color: var(--color-primary);
  background: var(--bg-badge);
  padding: 2px 8px;
  border-radius: 6px;
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.feature-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-subtle);
}

.feature-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--bg-badge);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.feature-icon-box.emerald {
  background: rgba(5, 150, 105, 0.12);
  color: var(--color-accent-emerald);
}

.feature-icon-box svg {
  width: 26px;
  height: 26px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.feature-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.015em;
}

.feature-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* Template Showcase Interactive Section */
.template-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.tab-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: var(--transition);
}

.tab-btn:hover {
  color: var(--text-main);
  background: var(--bg-card-subtle);
}

.tab-btn.active {
  background: var(--text-main);
  color: var(--bg-body);
  border-color: var(--text-main);
}

.template-display {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  align-items: center;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-md);
  padding: 40px;
}

.template-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.template-badge {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--color-primary);
  letter-spacing: 0.5px;
}

.template-name {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.template-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.template-traits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 10px 0;
}

.template-traits li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--text-main);
}

.template-traits svg {
  width: 18px;
  height: 18px;
  color: var(--color-accent-emerald);
  flex-shrink: 0;
}

.template-preview-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-subtle);
  background: #ffffff;
}

.template-preview-card img {
  width: 100%;
  height: auto;
  display: block;
  transition: opacity 0.2s ease-in-out;
}

/* How It Works Steps */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  counter-reset: step-counter;
}

.step-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
  padding: 36px 30px;
  position: relative;
  box-shadow: var(--shadow-sm);
}

.step-number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--color-primary);
  opacity: 0.85;
  margin-bottom: 16px;
  font-feature-settings: "tnum";
}

.step-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.step-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* Comparison Table */
.comparison-table-wrap {
  overflow-x: auto;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-card);
  box-shadow: var(--shadow-md);
  margin-top: 32px;
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  min-width: 600px;
}

.comparison-table th, .comparison-table td {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-subtle);
}

.comparison-table th {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  background: var(--bg-card-subtle);
}

.comparison-table th.highlight, .comparison-table td.highlight {
  background: rgba(var(--color-primary-rgb), 0.05);
  font-weight: 600;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-check {
  color: var(--color-accent-emerald);
  font-weight: bold;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.comparison-cross {
  color: #ef4444;
  font-weight: bold;
}

/* FAQ Accordion */
.faq-grid {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.faq-item {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-card);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.faq-question {
  width: 100%;
  padding: 20px 24px;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.faq-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.25s ease;
  color: var(--text-secondary);
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
  padding: 0 24px;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding-bottom: 20px;
  transition: max-height 0.35s ease-in-out;
}

/* CTA Card / Banner */
.cta-banner {
  background: linear-gradient(135deg, #1d1d1f 0%, #000000 100%);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 64px 40px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.cta-banner-title {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 16px;
  color: #ffffff;
}

.cta-banner-desc {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.75);
  max-width: 600px;
  margin: 0 auto 32px;
  line-height: 1.5;
}

/* Content Pages (Privacy, Support, Terms) */
.page-header {
  padding: 64px 0 32px;
  text-align: center;
}

.page-title {
  font-size: 2.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.page-meta {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.article-content {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-card);
  padding: 48px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 64px;
}

.article-content h2 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 36px 0 14px;
  color: var(--text-main);
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 8px;
}

.article-content h2:first-child {
  margin-top: 0;
}

.article-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 24px 0 10px;
  color: var(--text-main);
}

.article-content p {
  margin-bottom: 16px;
  color: var(--text-main);
  line-height: 1.7;
}

.article-content ul, .article-content ol {
  margin: 0 0 20px 24px;
  color: var(--text-main);
  line-height: 1.7;
}

.article-content li {
  margin-bottom: 8px;
}

.article-content strong {
  color: var(--text-main);
}

.article-callout {
  background: var(--bg-card-subtle);
  border-left: 4px solid var(--color-primary);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 18px 22px;
  margin: 24px 0;
}

.article-callout.emerald {
  border-left-color: var(--color-accent-emerald);
}

.article-callout p:last-child {
  margin-bottom: 0;
}

/* Contact / Support Cards */
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin: 32px 0 48px;
}

.support-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-card);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.support-card-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.support-card p {
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.email-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-card-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  gap: 12px;
}

.copy-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-primary);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 4px;
  transition: var(--transition);
}

.copy-btn:hover {
  background: var(--border-subtle);
}

/* Footer */
.footer {
  margin-top: auto;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  padding: 56px 0 40px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-brand-header {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-main);
}

.footer-logo {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.footer-col-title {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-main);
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: var(--text-secondary);
}

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

.footer-bottom {
  border-top: 1px solid var(--border-subtle);
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Responsive Media Queries */
@media (max-width: 900px) {
  .hero-title {
    font-size: 2.75rem;
  }

  .hero-device-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .template-display {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 24px;
  }

  .steps-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .support-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .section {
    padding: 64px 0;
  }

  .hero-title {
    font-size: 2.25rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
  }

  .nav-links.mobile-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-subtle);
    padding: 20px 24px;
    gap: 18px;
    box-shadow: var(--shadow-lg);
  }

  .mobile-toggle {
    display: block;
  }

  .article-content {
    padding: 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .comparison-table th, .comparison-table td {
    padding: 12px 14px;
  }
}
