/* ============================================================
   site.css — Shared styles for janekbehrens.de
   Injected by every page; nav + footer are written by components.js
   ============================================================ */

/* ── Self-hosted DM Sans (no third-party requests) ── */
/* latin-ext — italic 400 */
@font-face {
  font-family: 'DM Sans';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-sans-italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin — italic 400 */
@font-face {
  font-family: 'DM Sans';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-sans-italic-latin.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+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* latin-ext — normal 400–800 */
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/fonts/dm-sans-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin — normal 400–800 */
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/fonts/dm-sans-latin.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+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: #172B4D;
  background: #FAFBFC;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── CSS variables ── */
:root {
  --blue:      #0052CC;
  --blue-dark: #0747A6;
  --blue-lite: #DEEBFF;
  --text:      #172B4D;
  --text-2:    #505F79;
  --text-3:    #344563;
  --text-faint:#97A0AF;
  --border:    #DFE1E6;
  --border-2:  #EBECF0;
  --bg:        #FAFBFC;
  --bg-card:   #F4F5F7;
  --white:     #fff;
  --green:     #00875A;
  --nav-h:     56px;
}

/* ============================================================
   NAV
   ============================================================ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: var(--nav-h);
  transition: box-shadow 0.2s;
}
.site-nav.scrolled {
  box-shadow: 0 2px 12px rgba(23,43,77,0.08);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 600;
  flex-shrink: 0;
  white-space: nowrap;
}
.nav-brand:hover { color: var(--blue); }
.nav-logo {
  height: 28px;
  width: auto;
  flex-shrink: 0;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.nav-link {
  color: var(--text-2);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 6px 10px;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}
.nav-link:hover { color: var(--blue); background: var(--blue-lite); }

/* Docs dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 8px 32px rgba(23,43,77,0.12);
  min-width: 220px;
  padding: 6px;
  z-index: 300;
}
.nav-dropdown-menu.open { display: block; }
.nav-dropdown-menu a {
  display: block;
  padding: 8px 12px;
  color: var(--text-3);
  text-decoration: none;
  font-size: 0.875rem;
  border-radius: 6px;
}
.nav-dropdown-menu a:hover { background: var(--blue-lite); color: var(--blue); }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 6px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
  border-radius: 6px;
}
.nav-toggle:hover { background: var(--bg-card); }
.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text-2);
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}
.nav-toggle.open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav */
@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 10px 16px 16px;
    box-shadow: 0 8px 24px rgba(23,43,77,0.1);
  }
  .nav-links.open { display: flex; }
  .nav-link { justify-content: flex-start; border-radius: 8px; padding: 10px 12px; }
  .nav-dropdown { width: 100%; }
  .nav-dropdown-toggle { width: 100%; justify-content: space-between; }
  .nav-dropdown-menu {
    position: static;
    box-shadow: none;
    border: 1px solid var(--border);
    margin-top: 4px;
    border-radius: 8px;
  }
}

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 18px 24px;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.footer-copy { font-size: 0.82rem; color: var(--text-faint); }
.footer-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
.footer-links a {
  font-size: 0.82rem;
  color: var(--text-2);
  text-decoration: none;
  padding: 2px 6px;
}
.footer-links a:hover { color: var(--blue); text-decoration: underline; }
.footer-links span { color: var(--border); font-size: 0.82rem; }
@media (max-width: 640px) {
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* ============================================================
   COMMON BUTTONS
   ============================================================ */
.btn-primary {
  background: var(--blue);
  color: #fff;
  padding: 13px 26px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-block;
  transition: background 0.15s;
  white-space: nowrap;
}
.btn-primary:hover { background: var(--blue-dark); color: #fff; }
.btn-secondary {
  background: #fff;
  color: var(--blue);
  padding: 12px 26px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid var(--blue);
  display: inline-block;
  transition: background 0.15s;
  white-space: nowrap;
}
.btn-secondary:hover { background: var(--blue-lite); }
.btn-white {
  background: #fff;
  color: var(--blue);
  padding: 13px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  display: inline-block;
  transition: box-shadow 0.15s, transform 0.15s;
}
.btn-white:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.18); transform: translateY(-1px); }

/* ============================================================
   COMMON SECTION UTILITIES
   ============================================================ */
.section-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 24px;
}
.section-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 10px;
}
.section-title {
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  background: var(--blue-lite);
  color: var(--blue);
  border: 1px solid #BAD6FB;
}
.badge-green {
  background: #E3FCEF;
  color: var(--green);
  border-color: #ABF5D1;
}
.badge-neutral {
  background: var(--bg-card);
  color: var(--text-2);
  border-color: var(--border);
}
