/* Dwelliant Legal Pages - Shared Styles */

/*
 * Plus Jakarta Sans — matches the Flutter app's typography for brand
 * consistency across landing, legal, and in-app surfaces. Loaded from
 * jsdelivr (not Google Fonts) for GDPR compliance — German court rulings
 * have established that Google Fonts loaded directly may require explicit
 * consent. font-display: swap shows fallback text immediately.
 */
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-ext-400-normal.woff2') format('woff2');
  unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-ext-600-normal.woff2') format('woff2');
  unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('https://cdn.jsdelivr.net/npm/@fontsource/plus-jakarta-sans@5/files/plus-jakarta-sans-latin-ext-700-normal.woff2') format('woff2');
  unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --primary: #2E7D32;
  --primary-dark: #1B5E20;
  --primary-light: #388E3C;
  --secondary: #B8860B;
  --bg: #F8F9FA;
  --surface: #FFFFFF;
  --text: #1A1A1A;
  --text-secondary: #6B7280;
  --border: #E5E7EB;
  --radius: 12px;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

/* Skip-to-content link — visible only when focused via keyboard.
   Lets screen-reader and keyboard users jump past the header
   straight to the page content. */
.skip-link {
  position: absolute;
  top: -40px;
  left: 8px;
  z-index: 10000;
  padding: 8px 16px;
  background: var(--primary);
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 600;
}
.skip-link:focus {
  top: 8px;
}

/* Visible focus indicator on every interactive element.
   :focus-visible scopes this to keyboard navigation only —
   mouse clicks still get the default (no outline). */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 2px;
}

body {
  font-family: var(--font-sans);
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
}

.legal-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px 24px 80px;
}

/* Header */
.legal-header {
  text-align: center;
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--primary);
}

.legal-header .brand-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  display: inline-block;
  margin-bottom: 16px;
}

.legal-header h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.legal-header .effective-date {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.lang-btn {
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
}

.lang-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.lang-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

/* Content sections */
.lang-content {
  display: none;
}

.lang-content.active {
  display: block;
}

h2 {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--primary-dark);
  margin-top: 32px;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-top: 20px;
  margin-bottom: 8px;
}

p {
  margin-bottom: 12px;
  color: var(--text);
}

ul, ol {
  margin: 8px 0 16px 24px;
}

li {
  margin-bottom: 6px;
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Footer */
.legal-footer {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.legal-footer a {
  color: var(--primary);
}

/* Responsive */
@media (max-width: 600px) {
  .legal-page {
    padding: 24px 16px 60px;
  }
  .legal-header h1 {
    font-size: 1.5rem;
  }
  h2 {
    font-size: 1.2rem;
  }
}
