/*
  Custom styles for krankenversicherung.club
  Palette: warm blues and greens for trust and security.
  Responsive, accessible and minimal CSS framework inspired by Bulma.
  
  NOTE: To comply with EU data-privacy requirements and avoid potential
  Abmahnungen (legal warnings) from loading resources via external
  CDNs, all font files are hosted locally. The Inter font is loaded
  using @font-face declarations below and does not rely on Google
  Fonts. If additional weights or styles are required, place the
  corresponding .woff2 files in the `fonts` directory and add another
  @font-face rule.
*/

/*
  Local font-face declarations for the Inter typeface. Only normal
  styles for weights 300–600 are defined here to keep the bundle
  lightweight. The `font-display: swap` property ensures that text
  remains visible while the fonts load and improves performance.
*/
@font-face {
  font-family: 'Inter';
  src: url('fonts/inter-latin-300-normal.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('fonts/inter-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('fonts/inter-latin-500-normal.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('fonts/inter-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* CSS Variables for easy theme changes */
:root {
  --primary-color: #1c77c3;
  --primary-dark: #155a92;
  --secondary-color: #20a68f;
  --light-bg: #f7fafc;
  --light: #ffffff;
  --text-color: #2b2f3a;
  --muted-color: #6c757d;
  --border-radius: 8px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', Arial, sans-serif;
  font-weight: 400;
  color: var(--text-color);
  background-color: var(--light-bg);
  line-height: 1.6;
}

/* Container utility */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Header */
.site-header {
  background-color: var(--light);
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  position: sticky;
  top: 0;
  z-index: 10;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
}

.primary-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.5rem;
}

.primary-nav a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  transition: color 0.2s ease;
}

.primary-nav a:hover,
.primary-nav a:focus {
  color: var(--primary-color);
}

/* Hero Section */
.hero {
  background-color: var(--light);
  padding: 4rem 0 3rem;
}

.hero-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}

.hero-text {
  flex: 1 1 420px;
  padding-right: 2rem;
}

.hero-text h1 {
  font-size: 2.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.hero-text p {
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
}

.hero-image {
  flex: 0 1 480px;
  text-align: center;
}
.hero-image img {
  max-width: 100%;
  height: auto;
}

/* CTA buttons */
.cta-button,
.cta-inline {
  display: inline-block;
  background-color: var(--primary-color);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.2s ease;
}
.cta-button:hover,
.cta-inline:hover,
.cta-button:focus,
.cta-inline:focus {
  background-color: var(--primary-dark);
}
.cta-inline {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  margin-top: 1rem;
  padding: 0.5rem 1rem;
}
.cta-inline:hover,
.cta-inline:focus {
  background-color: var(--primary-color);
  color: #fff;
}

/* Features Section */
.features {
  background-color: var(--light-bg);
  padding: 3rem 0;
}

.features h2 {
  text-align: center;
  font-size: 1.75rem;
  margin-bottom: 2rem;
  color: var(--primary-color);
}

.features-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.feature-item {
  background-color: var(--light);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.feature-item img {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

/* Inline SVG icons within feature items */
.feature-item .icon {
  margin-bottom: 1rem;
  display: inline-block;
  color: var(--primary-color);
  width: 48px;
  height: 48px;
}

/* Ensure inline SVG paths inherit current color */
.feature-item .icon path,
.feature-item .icon line,
.feature-item .icon polyline {
  stroke: currentColor;
  fill: currentColor;
}

.feature-item h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.feature-item p {
  font-size: 0.95rem;
  color: var(--text-color);
}

/* Self-employed & Family Sections */
.self-employed,
.family {
  background-color: var(--light);
  padding: 3rem 0;
}

.self-employed h2,
.family h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.self-employed p,
.family p {
  font-size: 1rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

/* CTA Block */
.cta-block {
  background-color: var(--primary-color);
  color: #fff;
  padding: 3rem 0;
  text-align: center;
}

.cta-block h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.cta-block p {
  font-size: 1rem;
  margin-bottom: 1.5rem;
}

.cta-block .cta-button {
  background-color: #fff;
  color: var(--primary-color);
  font-weight: 600;
}
.cta-block .cta-button:hover,
.cta-block .cta-button:focus {
  background-color: var(--light-bg);
}

/* FAQ Section */
.faq {
  background-color: var(--light-bg);
  padding: 3rem 0;
}

.faq h2 {
  text-align: center;
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
}

.faq-item {
  margin-bottom: 1rem;
}
.faq-item details {
  background-color: var(--light);
  border-radius: var(--border-radius);
  padding: 1rem 1.25rem;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  cursor: pointer;
}
.faq-item summary {
  font-weight: 500;
  color: var(--primary-color);
  outline: none;
}
.faq-item p {
  margin-top: 0.5rem;
  font-size: 0.95rem;
  color: var(--text-color);
}

/* Footer */
.site-footer {
  background-color: var(--light);
  padding: 2rem 0;
  border-top: 1px solid #eaeaea;
}
.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  font-size: 0.875rem;
}
.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 1rem;
}
.footer-nav a {
  color: var(--primary-color);
  text-decoration: none;
}
.footer-nav a:hover,
.footer-nav a:focus {
  text-decoration: underline;
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--light);
  box-shadow: 0 -2px 6px rgba(0,0,0,0.1);
  padding: 1rem;
  z-index: 999;
  display: none;
}
.cookie-banner.active {
  display: block;
}
.cookie-banner h4 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
  color: var(--primary-color);
}
.cookie-banner p {
  margin: 0 0 1rem;
  font-size: 0.875rem;
  color: var(--text-color);
}
.cookie-options {
  margin-bottom: 1rem;
}
.cookie-options label {
  display: block;
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}
.cookie-actions {
  display: flex;
  gap: 0.5rem;
}
.cookie-actions button {
  flex: 1 1 auto;
  padding: 0.5rem 1rem;
  border: none;
  border-radius: var(--border-radius);
  font-size: 0.875rem;
  cursor: pointer;
}
.cookie-actions .accept-all {
  background-color: var(--primary-color);
  color: #fff;
}
.cookie-actions .accept-all:hover,
.cookie-actions .accept-all:focus {
  background-color: var(--primary-dark);
}
.cookie-actions .save-settings {
  background-color: transparent;
  color: var(--primary-color);
  border: 1px solid var(--primary-color);
}
.cookie-actions .save-settings:hover,
.cookie-actions .save-settings:focus {
  background-color: var(--primary-color);
  color: #fff;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .hero-content {
    flex-direction: column;
  }
  .hero-text {
    padding-right: 0;
    margin-bottom: 1.5rem;
  }
  .primary-nav ul {
    gap: 1rem;
  }
  .footer-container {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}