/* ══════════════════════════════════════════════════════
   bksmrt — "Curated Sanctuary" design system
   CSS tokens mirrored from DesignTokens.swift
   ══════════════════════════════════════════════════════ */

/* ─── Design tokens ─────────────────────────────────── */

:root {
  /* Surfaces */
  --bs-background:    #faf9f8;
  --bs-surface-low:   #f4f3f2;
  --bs-surface:       #eeeeed;
  --bs-surface-high:  #e9e8e7;
  --bs-surface-white: #ffffff;

  /* Primary — indigo-blue */
  --bs-primary:           #2346d5;
  --bs-primary-container: #4361ee;
  --bs-primary-fixed:     #dee1ff;
  --bs-primary-fixed-dim: #bac3ff;

  /* Secondary — amber */
  --bs-secondary:           #835400;
  --bs-secondary-container: #fcaf39;
  --bs-secondary-fixed:     #ffddb5;

  /* Tertiary — green */
  --bs-tertiary:       #00643d;
  --bs-tertiary-fixed: #a0f5c1;

  /* Error */
  --bs-error:           #ba1a1a;
  --bs-error-container: #ffdad6;

  /* Text */
  --bs-on-surface:         #1a1c1c;
  --bs-on-surface-variant: #444655;
  --bs-outline:            #747686;
  --bs-outline-variant:    #c4c5d7;

  /* Spacing — 4 pt base grid */
  --sp-xs:  4px;
  --sp-sm:  8px;
  --sp-md:  12px;
  --sp-lg:  16px;
  --sp-xl:  20px;
  --sp-xxl: 28px;

  /* Corner radii */
  --r-cover: 4px;
  --r-xs:    6px;
  --r-sm:    12px;
  --r-md:    16px;
  --r-lg:    22px;
  --r-xl:    28px;
  --r-pill:  999px;

  /* Layout */
  --site-max:     1120px;
  --site-padding: clamp(20px, 5vw, 80px);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bs-background:    #121312;
    --bs-surface-low:   #1e1f1e;
    --bs-surface:       #262726;
    --bs-surface-high:  #2e302e;
    --bs-surface-white: #1a1c1a;

    --bs-primary:           #a8b8ff;
    --bs-primary-container: #2346d5;
    --bs-primary-fixed:     #1a2a6b;
    --bs-primary-fixed-dim: #3855c0;

    --bs-secondary:           #ffb869;
    --bs-secondary-container: #6b4300;
    --bs-secondary-fixed:     #3d2600;

    --bs-tertiary:       #6ddfa7;
    --bs-tertiary-fixed: #003d25;

    --bs-error:           #ffb4ab;
    --bs-error-container: #690005;

    --bs-on-surface:         #e2e3e2;
    --bs-on-surface-variant: #c3c4d4;
    --bs-outline:            #8d8ea0;
    --bs-outline-variant:    #44455a;
  }
}

/* ─── Reset ──────────────────────────────────────────── */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background: var(--bs-background);
  color: var(--bs-on-surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

a:hover {
  text-decoration: underline;
}

/* ─── Layout ─────────────────────────────────────────── */

.site-container {
  max-width: var(--site-max);
  margin: 0 auto;
  padding-left: var(--site-padding);
  padding-right: var(--site-padding);
}

/* ─── Wordmark ───────────────────────────────────────── */

.wordmark {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--bs-on-surface);
  text-decoration: none;
}

.wordmark:hover {
  text-decoration: none;
}

.wordmark--sm {
  font-size: 1.125rem;
}

.wordmark-accent {
  color: var(--bs-primary-fixed-dim);
}

/* ─── Navigation ─────────────────────────────────────── */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bs-background) 88%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--bs-surface-high);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--sp-md);
}

/* ─── Language toggle ────────────────────────────────── */

.lang-btn {
  background: var(--bs-surface-low);
  border: 1px solid var(--bs-outline-variant);
  border-radius: var(--r-pill);
  color: var(--bs-on-surface-variant);
  cursor: pointer;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 5px 13px;
  transition: background 0.15s, color 0.15s;
}

.lang-btn:hover {
  background: var(--bs-surface);
  color: var(--bs-on-surface);
}

/* ─── Hero ───────────────────────────────────────────── */

.hero {
  padding: clamp(56px, 10vw, 120px) 0 clamp(64px, 10vw, 128px);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--sp-xxl), 6vw, 80px);
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero-eyebrow {
  display: inline-block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--bs-primary);
  background: var(--bs-primary-fixed);
  border-radius: var(--r-pill);
  padding: 4px 12px;
  margin-bottom: var(--sp-xl);
}

.hero h1 {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 800;
  font-size: clamp(2.5rem, 5.5vw, 4rem);
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--bs-on-surface);
  margin-bottom: var(--sp-xl);
}

.hero h1 span {
  display: block;
}

.hero-desc {
  font-size: 1.0625rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.65;
  margin-bottom: var(--sp-xxl);
  max-width: 460px;
}

.coming-soon-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-sm);
  background: var(--bs-surface-low);
  border: 1px solid var(--bs-outline-variant);
  border-radius: var(--r-pill);
  padding: 10px 20px;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--bs-on-surface-variant);
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-icon {
  width: min(260px, 55vw);
  height: auto;
  aspect-ratio: 1;
  border-radius: 22.6%;
  box-shadow:
    0 40px 100px color-mix(in srgb, var(--bs-primary-container) 22%, transparent),
    0 8px 28px rgba(0, 0, 0, 0.10);
}

/* ─── Features ───────────────────────────────────────── */

.features {
  padding: clamp(48px, 8vw, 96px) 0;
  border-top: 1px solid var(--bs-surface-high);
}

.features-headline {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(1.375rem, 3vw, 1.875rem);
  letter-spacing: -0.02em;
  color: var(--bs-on-surface);
  text-align: center;
  margin-bottom: clamp(var(--sp-xxl), 5vw, 56px);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--sp-lg);
}

.feature-card {
  background: var(--bs-surface-low);
  border-radius: var(--r-md);
  padding: var(--sp-xxl);
  display: flex;
  flex-direction: column;
  gap: var(--sp-lg);
}

.feature-icon-wrap {
  width: 48px;
  height: 48px;
  background: var(--bs-primary-fixed);
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bs-primary-container);
  flex-shrink: 0;
}

.feature-card h3 {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--bs-on-surface);
  margin-bottom: var(--sp-xs);
}

.feature-card p {
  font-size: 0.9375rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.6;
}

/* ─── Footer ─────────────────────────────────────────── */

.footer {
  padding: clamp(32px, 5vw, 56px) 0;
  border-top: 1px solid var(--bs-surface-high);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--sp-lg);
}

.footer-links {
  display: flex;
  align-items: center;
  gap: var(--sp-xl);
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--bs-outline);
  transition: color 0.15s;
}

.footer-links a:hover {
  color: var(--bs-on-surface);
  text-decoration: none;
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--bs-outline);
}

/* ─── Inner page shell (Impressum, Datenschutz) ──────── */

.page-header {
  padding: clamp(48px, 8vw, 80px) 0 clamp(28px, 4vw, 40px);
  border-bottom: 1px solid var(--bs-surface-high);
}

.page-header h1 {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 800;
  font-size: clamp(1.875rem, 4vw, 2.625rem);
  letter-spacing: -0.03em;
  color: var(--bs-on-surface);
}

.prose {
  max-width: 680px;
  padding: clamp(40px, 6vw, 64px) 0 clamp(64px, 10vw, 120px);
}

.prose h2 {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--bs-on-surface);
  margin-top: 2.25rem;
  margin-bottom: 0.625rem;
}

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

.prose p {
  font-size: 0.9375rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}

.prose address {
  font-style: normal;
  font-size: 0.9375rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.75;
  margin-bottom: 0.75rem;
}

.prose ul {
  padding-left: 1.25rem;
  margin-bottom: 0.75rem;
}

.prose li {
  font-size: 0.9375rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.75;
  margin-bottom: 0.25rem;
}

.prose a {
  color: var(--bs-primary);
}

.prose a:hover {
  text-decoration: underline;
}

.prose .meta {
  font-size: 0.8125rem;
  color: var(--bs-outline);
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--bs-surface-high);
}

/* Language-gated blocks — JS shows the correct one */
[data-lang] {
  display: none;
}

/* ─── Auth callback page ─────────────────────────────── */

.callback-page {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--sp-xxl);
  text-align: center;
}

.callback-icon {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  margin: 0 auto var(--sp-xxl);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.callback-card {
  max-width: 360px;
  width: 100%;
}

.callback-title {
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--bs-on-surface);
  margin-bottom: var(--sp-lg);
}

.callback-desc {
  font-size: 1rem;
  color: var(--bs-on-surface-variant);
  line-height: 1.65;
  margin-bottom: var(--sp-md);
}

.callback-hint {
  font-size: 0.875rem;
  color: var(--bs-outline);
  line-height: 1.6;
  margin-bottom: var(--sp-xxl);
}

.callback-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-sm);
  background: var(--bs-primary);
  color: #fff;
  border: none;
  border-radius: var(--r-pill);
  padding: 14px 32px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s;
}

.callback-btn:hover {
  opacity: 0.88;
  text-decoration: none;
  color: #fff;
}

/* ─── Responsive ─────────────────────────────────────── */

@media (max-width: 680px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    order: -1;
  }

  .hero-icon {
    width: min(180px, 50vw);
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--sp-xl);
  }
}
