/* ---------- CSS Custom Properties ---------- */
:root {
  /* Light mode (default) */
  --color-bg: #fafafa;
  --color-bg-alt: #f0f0f0;
  --color-text: #1a1a1a;
  --color-text-muted: #555;
  --color-link: #2a6496;
  --color-link-hover: #1a4060;
  --color-border: #ddd;
  --color-accent: #2a6496;
  --color-header-bg: #ffffff;
  --color-header-shadow: rgba(0, 0, 0, 0.06);
  --color-footer-bg: #f5f5f5;
  --color-supporters-bg: #f7f9fb;
  --color-demands-border: #2a6496;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --max-width: 720px;
  --header-height: 72px;
  --header-height-scrolled: 56px;
}

[data-theme="dark"] {
  --color-bg: #1a1a1a;
  --color-bg-alt: #252525;
  --color-text: #e0e0e0;
  --color-text-muted: #aaa;
  --color-link: #6db3f2;
  --color-link-hover: #a0d0ff;
  --color-border: #333;
  --color-accent: #6db3f2;
  --color-header-bg: #222;
  --color-header-shadow: rgba(0, 0, 0, 0.3);
  --color-footer-bg: #222;
  --color-supporters-bg: #222;
  --color-demands-border: #6db3f2;
}

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

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

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  transition: background-color 0.25s ease, color 0.25s ease;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-anchor: none;
}

a {
  color: var(--color-link);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover,
a:focus {
  color: var(--color-link-hover);
  text-decoration: underline;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--color-header-bg);
  box-shadow: 0 1px 3px var(--color-header-shadow);
  transition: all 0.3s ease;
}

.site-header.scrolled {
  box-shadow: 0 2px 8px var(--color-header-shadow);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  transition: height 0.3s ease;
}

.site-header.scrolled .header-inner {
  height: var(--header-height-scrolled);
}

.site-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
  white-space: nowrap;
  transition: font-size 0.3s ease;
}

.site-header.scrolled .site-title {
  font-size: 1.1rem;
}

.site-title:hover {
  color: var(--color-accent);
  text-decoration: none;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-link {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  white-space: nowrap;
}

.nav-link--cta {
  color: var(--color-accent);
  font-weight: 600;
}

.nav-link:hover {
  color: var(--color-link-hover);
}

/* ---------- Theme Toggle ---------- */
.theme-toggle {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  cursor: pointer;
  padding: 0.3rem 0.5rem;
  font-size: 1rem;
  line-height: 1;
  color: var(--color-text);
  transition: border-color 0.2s ease, background-color 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle:hover {
  border-color: var(--color-accent);
  background-color: var(--color-bg-alt);
}

/* Show/hide sun/moon based on theme */
[data-theme="light"] .theme-toggle__icon--light { display: none; }
[data-theme="light"] .theme-toggle__icon--dark { display: inline; }
[data-theme="dark"] .theme-toggle__icon--light { display: inline; }
[data-theme="dark"] .theme-toggle__icon--dark { display: none; }

/* ---------- Main Content ---------- */
.site-main {
  flex: 1;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1rem;
  overflow-anchor: none;
}

/* ---------- Landing Page ---------- */
.landing__content h1 {
  font-size: 1.6rem;
  line-height: 1.3;
  margin-bottom: 1.5rem;
  color: var(--color-text);
  font-weight: 700;
}

.landing__content h2 {
  font-size: 1.2rem;
  line-height: 1.35;
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
  font-weight: 600;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid var(--color-border);
  position: relative;
  scroll-margin-top: calc(var(--header-height) + 1rem);
}

.landing__content h2::before {
  content: "#";
  position: absolute;
  left: -1.5rem;
  color: var(--color-accent);
  opacity: 0;
  transition: opacity 0.2s ease;
  font-weight: 400;
}

.landing__content h2:hover::before {
  opacity: 0.6;
}

.landing__content h2:hover {
  color: var(--color-accent);
  cursor: pointer;
}

.landing__content p {
  margin-bottom: 1.25rem;
  text-align: left;
  hyphens: auto;
  -webkit-hyphens: auto;
  -moz-hyphens: auto;
  hyphenate-limit-chars: 6 3 3;
  text-rendering: optimizeLegibility;
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: normal;
  orphans: 3;
  widows: 3;
}

.landing__content strong {
  font-weight: 600;
}

/* Demands list — the three bullet points */
.landing__content ul {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.landing__content ul li {
  position: relative;
  padding: 0.75rem 1rem 0.75rem 1.25rem;
  margin-bottom: 0.5rem;
  border-left: 3px solid var(--color-demands-border);
  background-color: var(--color-bg-alt);
  border-radius: 0 4px 4px 0;
  transition: background-color 0.25s ease;
}

/* Lead paragraph styling */
.landing__content > p:first-of-type {
  font-size: 1.05rem;
}

/* ---------- Supporters Section ---------- */
.supporters {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
  scroll-margin-top: calc(var(--header-height) + 1rem);
}

.supporters h2 {
  font-size: 1.4rem;
  margin-bottom: 1.25rem;
  color: var(--color-text);
}

.supporters__count {
  margin-bottom: 1.5rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  font-style: italic;
}

.supporters__list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.5rem;
  overflow: hidden;
}

.supporters__item {
  padding: 0.85rem 1rem;
  background-color: var(--color-supporters-bg);
  border-radius: 6px;
  border: 1px solid var(--color-border);
  transition: all 0.2s ease;
  position: relative;
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
  -webkit-hyphens: auto;
  min-width: 0;
}

[data-theme="light"] .supporters__item {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .supporters__item:hover {
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
  border-color: var(--color-accent);
  transform: translateY(-1px);
}

[data-theme="dark"] .supporters__item:hover {
  background-color: var(--color-bg-alt);
  border-color: var(--color-accent);
}

.supporters__name {
  font-weight: 600;
  color: var(--color-text);
  display: block;
}

.supporters__title {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  line-height: 1.4;
  display: block;
}

/* ---------- Call to Action ---------- */
.cta {
  margin-top: 3rem;
}

.cta__box {
  background-color: var(--color-bg-alt);
  border: 2px solid var(--color-accent);
  border-radius: 6px;
  padding: 1.75rem 1.5rem;
  text-align: center;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.cta__box:hover {
  border-color: var(--color-link-hover);
  background-color: var(--color-supporters-bg);
}

.cta__text {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--color-text);
  line-height: 1.5;
}

.cta__link {
  color: var(--color-accent);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  transition: color 0.2s ease;
}

.cta__link:hover {
  color: var(--color-link-hover);
  text-decoration: underline;
}

/* ---------- Single Page (Impressum) ---------- */
.page__title {
  font-size: 1.6rem;
  margin-bottom: 1.5rem;
  line-height: 1.3;
}

.page__content h2 {
  font-size: 1.2rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--color-text);
}

.page__content h3 {
  font-size: 1.05rem;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

.page__content p {
  margin-bottom: 1rem;
}

.page__content ul {
  margin: 0.5rem 0 1rem 1.5rem;
}

.page__content ul li {
  margin-bottom: 0.25rem;
}

/* ---------- Footer ---------- */
.site-footer {
  background-color: var(--color-footer-bg);
  border-top: 1px solid var(--color-border);
  transition: background-color 0.25s ease, border-color 0.25s ease;
  margin-top: auto;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.25rem 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: wrap;
}

.footer-sep {
  margin: 0 0.5rem;
}

/* ---------- Responsive: Tablet (≥ 768px) ---------- */
@media (min-width: 768px) {
  html {
    font-size: 17px;
  }

  .header-inner {
    padding: 0 1.5rem;
  }

  .site-main {
    padding: 3rem 1.5rem;
  }

  .landing__content h1 {
    font-size: 1.9rem;
  }

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

  .cta__box {
    padding: 2rem 2rem;
  }

  .cta__text {
    font-size: 1.1rem;
  }
}

/* ---------- Responsive: Desktop (≥ 1024px) ---------- */
@media (min-width: 1024px) {
  html {
    font-size: 18px;
  }

  :root {
    --max-width: 780px;
  }

  .site-main {
    padding: 3.5rem 2rem;
  }

  .landing__content h1 {
    font-size: 2rem;
  }

  .cta__box {
    padding: 2rem 2.5rem;
  }

  .cta__text {
    font-size: 1.15rem;
  }
}

/* ---------- Print ---------- */
@media print {
  .site-header,
  .site-footer,
  .theme-toggle {
    display: none;
  }

  body {
    color: #000;
    background: #fff;
  }

  .site-main {
    max-width: 100%;
    padding: 0;
  }
}
