/*
Theme Name: LND Ingenieure
Theme URI: https://www.lnd-ingenieure.de
Author: AKARA Solutions GmbH
Author URI: https://akara-solutions.de
Description: Custom WordPress theme für LND Ingenieure GmbH (Hamburg). Drei Page-Templates: Editorial, Cinematic, Bauhaus. Auf LND-Brand (Marineblau #22327D + Stahlblau #4C7EAE) abgestimmt.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.1
License: Proprietary — © AKARA Solutions GmbH
Text Domain: lnd-ingenieure
Tags: engineering, editorial, b2b, multi-template
*/

/* Theme root tokens — global Brand-CSS für alle 3 Templates */
:root{
  --lnd-marine: #22327D;
  --lnd-marine-deep: #1a2761;
  --lnd-stahl: #4C7EAE;
  --lnd-paper: #ffffff;
  --lnd-paper-warm: #f4f2ea;
  --lnd-ink: #0a0e22;
  --lnd-line: rgba(10,14,34,.10);
}

/* WordPress-Reset für Body+Admin-Bar */
html { scroll-behavior: smooth; }
body { margin: 0; }
body.admin-bar .nav,
body.admin-bar header[role="banner"] { top: 32px !important; }
@media (max-width:782px){
  body.admin-bar .nav,
  body.admin-bar header[role="banner"] { top: 46px !important; }
}

/* Common WordPress block compatibility */
.wp-block-image img { display: block; max-width: 100%; height: auto; }
.alignwide { max-width: 1440px; margin-left: auto; margin-right: auto; }
.alignfull { width: 100%; }

/* =========================================================================
 * Schwebende Glass-Pill-Navigation (rsmarine-Stil, LND-branded)
 * Alle Regeln #lnd-nav-geprefixt → ID-Specificity (1,x,0) schlägt die
 * Inline-.nav-Regeln der Page-Templates, ohne diese anzufassen.
 * ====================================================================== */
#lnd-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: auto; background: transparent; box-shadow: none;
  /* Blur NUR auf der Pill — die alte .nav-Regel der Page-Templates blurrt sonst
     die volle Header-Breite (verschwommener Schleier rings um die Pill). */
  -webkit-backdrop-filter: none; backdrop-filter: none;
}

#lnd-nav .nav-pill-wrap {
  max-width: 1440px; margin: 0 auto;
  padding: clamp(14px,2vw,20px) clamp(16px,4vw,40px) 0;
}
#lnd-nav .nav-pill {
  display: flex; align-items: center; justify-content: space-between;
  gap: clamp(16px,3vw,40px);
  padding: 10px 12px 10px clamp(18px,2vw,26px);
  border-radius: 999px;
  background: color-mix(in srgb, #0a0e22 96%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid rgba(255,255,255,.22);
  box-shadow: 0 18px 50px -22px rgba(8,10,28,.75);
  transition: background-color .3s ease, box-shadow .3s ease, border-color .3s ease, transform .35s cubic-bezier(.22,1,.36,1);
}
#lnd-nav.is-scrolled .nav-pill {
  background: color-mix(in srgb, #0a0e22 99%, transparent);
  border-color: rgba(255,255,255,.16);
  box-shadow: 0 22px 60px -20px rgba(8,10,28,.85);
  transform: scale(.985);
}

#lnd-nav .brand { display: inline-flex; align-items: center; flex-shrink: 0; }
#lnd-nav .brand img { height: clamp(26px,2.6vw,32px); width: auto; }
@media (max-width: 400px){ #lnd-nav .brand img { max-width: 148px; } }

#lnd-nav .nav-links {
  display: flex; align-items: center; gap: clamp(22px,2.4vw,36px);
  list-style: none; margin: 0; padding: 0;
}
#lnd-nav .nav-link {
  position: relative; font-size: .92rem; font-weight: 500; letter-spacing: .01em;
  color: rgba(255,255,255,.82); padding: 6px 0; transition: color .25s ease;
}
#lnd-nav .nav-link::after {
  content: ""; position: absolute; left: 50%; bottom: -3px; width: 0; height: 1.5px;
  background: #6f9fcb; transition: width .28s ease, left .28s ease;
}
#lnd-nav .nav-link:hover { color: #fff; }
#lnd-nav .nav-link:hover::after,
#lnd-nav .nav-link.is-active::after { left: 0; width: 100%; }
#lnd-nav .nav-link.is-active { color: #fff; }

#lnd-nav .nav-actions { display: flex; align-items: center; gap: 10px; }
#lnd-nav .nav-cta {
  display: inline-flex; align-items: center; justify-content: center;
  font-size: .9rem; font-weight: 600; padding: 11px 22px; border-radius: 999px;
  background: var(--lnd-stahl, #4C7EAE); color: #fff; transition: background .25s ease, transform .25s ease;
}
#lnd-nav .nav-cta:hover { background: #5d92c4; transform: translateY(-1px); }

#lnd-nav .nav-burger {
  display: none; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 999px;
  background: rgba(255,255,255,.10); color: #fff; transition: background .25s ease;
}
#lnd-nav .nav-burger:hover { background: rgba(255,255,255,.18); }
#lnd-nav .is-hidden { display: none; }

/* Mobile slide-in panel */
#lnd-nav .nav-mobile { position: fixed; inset: 0; z-index: 200; pointer-events: none; overflow: hidden; }
#lnd-nav .nav-mobile-backdrop {
  position: absolute; inset: 0; background: rgba(8,10,28,.6);
  opacity: 0; transition: opacity .3s ease;
}
#lnd-nav .nav-mobile-panel {
  position: absolute; top: 0; right: 0; height: 100%;
  width: min(86%, 360px); display: flex; flex-direction: column;
  background: #0a0e22; color: #fff; box-shadow: -24px 0 60px -20px rgba(0,0,0,.7);
  transform: translateX(100%);
  transition: transform .4s cubic-bezier(.32,.72,0,1);
}
#lnd-nav .nav-mobile.is-open { pointer-events: auto; }
#lnd-nav .nav-mobile.is-open .nav-mobile-backdrop { opacity: 1; }
#lnd-nav .nav-mobile.is-open .nav-mobile-panel { transform: translateX(0); }
#lnd-nav .nav-mobile-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 24px; border-bottom: 1px solid rgba(255,255,255,.10);
}
#lnd-nav .nav-mobile-head .brand { min-width: 0; flex: 0 1 auto; overflow: hidden; }
#lnd-nav .nav-mobile-head .brand img { height: auto; width: auto; max-width: 200px; max-height: 32px; }
#lnd-nav .nav-mobile-close { color: #fff; padding: 4px; flex: 0 0 auto; margin-left: 12px; }
#lnd-nav .nav-mobile-links {
  display: flex; flex-direction: column; gap: 4px;
  padding: 28px 24px; flex: 1;
}
#lnd-nav .nav-mobile-links a {
  font-family: var(--serif, 'Merriweather', Georgia, serif);
  font-size: 1.6rem; font-weight: 600; color: #fff; padding: 10px 0;
  transition: color .2s ease, transform .2s ease;
}
#lnd-nav .nav-mobile-links a:hover { color: #6f9fcb; transform: translateX(4px); }
#lnd-nav .nav-mobile-links a.is-active { color: #6f9fcb; }
#lnd-nav .nav-mobile-foot { padding: 0 24px 32px; border-top: 1px solid rgba(255,255,255,.10); padding-top: 24px; }
#lnd-nav .nav-mobile-foot .nav-cta { width: 100%; padding: 15px; font-size: 1rem; }

/* Sprach-Switcher (Dropdown mit Flaggen) */
#lnd-nav .lnd-lang { position: relative; }
#lnd-nav .lnd-flag { display: inline-flex; line-height: 0; }
#lnd-nav .lnd-flag img { width: 20px; height: 14px; border-radius: 2px; display: block; object-fit: cover; box-shadow: 0 0 0 1px rgba(255,255,255,.2); }
#lnd-nav .lnd-lang-toggle { align-items: center; }
#lnd-nav .lnd-lang-toggle .lnd-flag { transform: translateY(-1px); } /* Caps "DE" sitzen optisch hoeher als die Box-Mitte -> Flagge 1px rauf */
#lnd-nav .lnd-lang-toggle .lnd-lang-code { transform: translateY(1px); } /* Caps optisch nach unten ausgleichen */
#lnd-nav .lnd-lang-toggle {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 10px; border-radius: 999px; cursor: pointer;
  background: rgba(255,255,255,.08); color: rgba(255,255,255,.85);
  font-size: .8rem; font-weight: 600; letter-spacing: .04em;
  transition: background .2s ease, color .2s ease;
}
#lnd-nav .lnd-lang-toggle:hover { background: rgba(255,255,255,.16); color: #fff; }
#lnd-nav .lnd-lang-caret { transition: transform .25s ease; opacity: .7; }
#lnd-nav .lnd-lang.is-open .lnd-lang-caret { transform: rotate(180deg); }
#lnd-nav .lnd-lang-menu {
  position: absolute; top: calc(100% + 10px); right: 0; z-index: 50;
  min-width: 172px; padding: 6px; display: flex; flex-direction: column; gap: 2px;
  background: color-mix(in srgb, #0a0e22 92%, transparent);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,.14); border-radius: 14px;
  box-shadow: 0 18px 50px -18px rgba(8,10,28,.8);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .2s ease, transform .2s ease, visibility .2s;
}
#lnd-nav .lnd-lang.is-open .lnd-lang-menu { opacity: 1; visibility: visible; transform: none; }
#lnd-nav .lnd-lang-opt {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 9px;
  font-size: .9rem; font-weight: 500; color: rgba(255,255,255,.8);
  transition: background .18s ease, color .18s ease;
}
#lnd-nav .lnd-lang-opt:hover { background: rgba(255,255,255,.1); color: #fff; }
#lnd-nav .lnd-lang-opt.is-active { color: #fff; background: rgba(255,255,255,.14); }

/* Switcher im Mobile-Panel: vertikale Flaggen-Liste */
#lnd-nav .lnd-lang--mobile { display: flex; flex-direction: column; gap: 4px; margin-bottom: 18px; }
#lnd-nav .lnd-lang--mobile .lnd-lang-opt { font-size: 1rem; padding: 10px 12px; }

@media (max-width: 880px) {
  #lnd-nav .nav-links { display: none; }
  #lnd-nav .nav-actions .nav-cta { display: none; }
  #lnd-nav .nav-actions .lnd-lang { display: none; } /* Desktop-Switcher aus, Mobile nutzt Panel */
  #lnd-nav .nav-burger { display: inline-flex; }
}

/* Footer Social-Icons (Instagram etc.) */
.footer-social { display: flex; gap: 12px; margin-top: 18px; }
.footer-social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 9px;
  border: 1px solid rgba(255,255,255,.18); color: rgba(255,255,255,.75);
  transition: color .2s, border-color .2s, background .2s;
}
.footer-social a:hover { color: #fff; border-color: rgba(255,255,255,.4); background: rgba(255,255,255,.06); }
.footer-social svg { display: block; }
