/* Nunito Sans wird via vendor/fonts/nunito-sans.css geladen */

:root {
  --primary-green: #175350;
  --accent-green: #94CA32;
  --light-gray: #F1F1F1;
  --bg-gray: #F8F8F8;
  --max-content-width: 1400px;
  --cms-toolbar-height: 46px;
  --nav-height: 80px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Sticky Footer Setup */
html {
  height: 100%;
}

body {
  font-family: 'Nunito Sans', sans-serif;
  background-color: white;
  color: #333;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

/* Admin User - CMS Toolbar Offset */
body.admin-user {
  /* KEIN padding-top hier - nur die Navigation verschieben */
}

body.admin-user .main-navigation {
  top: var(--cms-toolbar-height);
}

/* Navigation */
.main-navigation {
  background-color: white;
  height: var(--nav-height);
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 999;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.nav-container {
  max-width: var(--max-content-width);
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}

.nav-logo {
  height: 50px;
  flex-shrink: 0;
}

.nav-logo img {
  height: 100%;
  width: auto;
}

/* Rechte Seite der Navigation */
.nav-right {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-menu li a,
.nav-menu li span.dropdown-toggle {
  font-size: 16pt;
  font-weight: 700;
  color: #333;
  text-decoration: none;
  transition: color 0.3s;
}

.nav-menu li a:hover,
.nav-menu li span.dropdown-toggle:hover {
  color: var(--primary-green);
}

.nav-icons {
  display: flex;
  align-items: center;
  gap: 30px;
}

.search-icon {
  cursor: pointer;
  font-size: 20px;
  color: var(--primary-green);
}

.search-icon:hover {
  color: var(--accent-green);
}

.user-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--light-gray);
  border: 2px solid var(--primary-green);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  color: var(--primary-green);
}

.user-icon:hover {
  background-color: var(--primary-green);
  color: white;
}

/* Header - direkt unter Navigation */
.page-header {
  background-color: var(--primary-green);
  height: 200px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: var(--nav-height);
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
}

body.admin-user .page-header {
  margin-top: var(--nav-height);
}

.page-header.small {
  height: 150px;
}

.header-content {
  max-width: var(--max-content-width);
  width: 100%;
  padding: 0 20px;
  text-align: center;
}

.header-content h1 {
  font-size: 36pt;
  font-weight: 700;
  color: #94CA32;
  margin-bottom: 0px;
}

/* Header Search Styling */
.header-search {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    margin-top: 15px;
}

.header-search .search-input {
    font-family: 'Nunito Sans', sans-serif;
    width: 100%;
    padding: 9px 50px 9px 20px;
    font-size: 16px;
    border: none;
    border-radius: 4px;
    background: white;
    color: #333;
}

.header-search .search-input::placeholder {
    color: #999;
}

.header-search .search-icon-inside {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 16px;
}

/* Main Content - Flex grow für Sticky Footer */
.main-wrapper {
  width: 100%;
  background-color: var(--bg-gray);
  flex: 1;
}

.content-container {
  max-width: var(--max-content-width);
  margin: 0 auto;
  padding: 20px 20px;
}

/* Footer */
.main-footer {
  background-color: white;
  width: 100%;
  padding: 60px 0 20px;
  flex-shrink: 0;
}

.footer-container {
  max-width: var(--max-content-width);
  margin: 0 auto;
  padding: 0 20px;
}

.footer-columns {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.footer-column h3 {
  font-size: 16pt;
  font-weight: 700;
  margin-bottom: 15px;
  padding-bottom: 10px;
  color: #0E7C62;
  border-bottom: 1px solid #6E6E6E;
}

.footer-column p,
.footer-column a,
.footer-column li {
  font-size: 14pt;
  font-weight: 400;
  color: #212020;
  text-decoration: none;
  line-height: 1.8;
}

.footer-column a:hover {
  color: var(--primary-green);
}

.footer-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-logo {
  max-width: 200px;
  height: auto;
}

.social-icons {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.social-icons a {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background-color: #000000;
  border: 1px solid #212020;
  color: #ffffff;
  font-size: 16px;
  transition: all 0.3s;
}

.social-icons a:hover {
  background-color: var(--primary-green);
  border-color: var(--primary-green);
  color: white;
}

.footer-bottom {
  border-top: 1px solid #ccc;
  padding-top: 20px;
  display: flex;
  gap: 40px;
  justify-content: flex-start;
}

.footer-bottom a {
  font-size: 16pt;
  font-weight: 400;
  color: #212020;
  text-decoration: none;
}

.footer-bottom a:hover {
  color: var(--primary-green);
}

/* Footer Software Liste */
.footer-software-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-software-list li {
  margin-bottom: 5px;
}

.footer-software-list a {
  font-size: 14pt;
  color: #212020;
  text-decoration: none;
  line-height: 1.8;
}

.footer-software-list a:hover {
  color: var(--primary-green);
}

.footer-more-link span {
  font-size: 12pt;
  color: #999;
  font-style: italic;
  line-height: 1.8;
}

/* Dropdown Menu */
.dropdown {
  position: relative;
}

.dropdown-toggle {
  cursor: pointer;
  font-size: 16pt;
  font-weight: 700;
  color: #333;
  text-decoration: none;
}

.dropdown-toggle::after {
  content: ' ▼';
  font-size: 10px;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  list-style: none;
  margin: 0;
  padding: 10px 0;
  min-width: 220px;
  max-height: 420px;
  overflow-y: auto;
  z-index: 9999;
  border-radius: 4px;
}

.dropdown-menu li {
  margin: 0;
}

.dropdown-menu li a {
  display: block;
  padding: 10px 20px;
  color: #333;
  text-decoration: none;
  white-space: nowrap;
  font-size: 14pt;
  font-weight: 400;
}

.dropdown-menu li a:hover {
  background: #f5f5f5;
  color: var(--primary-green);
}

/* Dropdown öffnen bei Hover */
.dropdown:hover .dropdown-menu {
  display: block;
}

/* User Dropdown */
.user-dropdown {
  position: relative;
}

.user-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  min-width: 280px;
  z-index: 9999;
  border-radius: 4px;
  padding: 20px;
}

/* Pseudo-Element als Brücke zwischen Icon und Menü */
.user-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -15px;
  right: 0;
  width: 100%;
  height: 20px;
}

.user-dropdown-menu.show {
  display: block;
}

.user-dropdown-content h4 {
  margin: 0 0 10px 0;
  color: var(--primary-green);
  font-size: 14pt;
}

.user-dropdown-content p {
  margin: 0 0 15px 0;
  font-size: 12pt;
  color: #333;
}

.user-dropdown-content input {
  width: 100%;
  padding: 8px 12px;
  margin: 5px 0 10px 0;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 12pt;
}

.user-dropdown-content button,
.user-dropdown-content .logout-btn {
  display: inline-block;
  background: var(--primary-green);
  color: white;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12pt;
  text-decoration: none;
  margin-top: 10px;
}

.user-dropdown-content button:hover,
.user-dropdown-content .logout-btn:hover {
  background: var(--accent-green);
}

.message {
  color: #d9534f;
  font-size: 11pt;
  margin-top: 10px;
}


/* Search Highlighting */
mark.search-highlight,
mark {
    background: #d5f0c6;
    color: inherit;
    padding: 0 2px;
    border-radius: 2px;
}

.search-no-results {
    text-align: center;
    color: #666;
    padding: 20px;
    background: white;
    border-radius: 6px;
    margin-bottom: 15px;
}


/* Responsive */
@media (max-width: 1440px) {
  .content-container,
  .nav-container,
  .footer-container {
    max-width: 100%;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    gap: 20px;
  }
  
  .nav-right {
    gap: 20px;
  }
  
  .nav-icons {
    gap: 20px;
  }
  
  .footer-columns {
    grid-template-columns: 1fr 1fr;
    gap: 30px;
  }
  
  .page-header {
    height: 150px;
  }
  
  .header-content h1 {
    font-size: 28pt;
  }
}

@media (max-width: 480px) {
  .footer-columns {
    grid-template-columns: 1fr;
  }
  
  .nav-menu {
    flex-direction: column;
    gap: 10px;
  }
}