/* Offcanvas Sidebar - menu.css */
.menu-button {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 310;
  transition: background-color 0.2s ease;
}

.menu-button:hover {
  background-color: #f0f0f0;
}

.menu-button img { 
  display: block; 
  pointer-events: none; 
  width: 36px;
  height: 36px;
}

.menu-button .icon-close { display: none; }
.menu-button.active .icon-open { display: none; }
.menu-button.active .icon-close { display: block; }

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  right: -360px;
  width: 320px;
  max-width: 90%;
  height: 100vh;
  background: #fff;
  box-shadow: -8px 0 30px rgba(0,0,0,0.12);
  z-index: 300;
  padding: 0;
  overflow-y: auto;
  transition: right 0.3s ease;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
}

/* geöffnet */
.sidebar.open {
  right: 0;
}

/* Sidebar Header */
.sidebar-header {
  padding: 44px;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #f8f9fa;
}

.sidebar-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: #222;
  margin: 0;
}

.sidebar-close {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.sidebar-close:hover {
  background-color: #e9ecef;
}

/* Menü-Items Container */
.sidebar .menu-items {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* Menü-Items */
.sidebar .menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  color: #333;
  transition: all 0.2s ease;
  text-decoration: none;
}

.sidebar .menu-item:hover {
  background: #f5f5f5;
  color: #000;
  transform: translateX(4px);
}

/* Aktives Menü-Item */
.sidebar .menu-item.active {
  background: #007bff;
  color: #fff;
}

/* Sidebar Footer */
.sidebar-footer {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid #eee;
  text-align: center;
  font-size: 0.85rem;
  color: #666;
}

/* Overlay */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  z-index: 250;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.overlay.show {
  opacity: 1;
  visibility: visible;
}

/* Responsive Design */
@media (max-width: 480px) {
  .sidebar {
    width: 300px;
  }
  
  .sidebar .menu-item {
    padding: 10px 12px;
    font-size: 0.95rem;
  }
}