:root {
    --bg: #0f1117;
    --sidebar: #151922;
    --card: #1c2230;
    --text: #e6e6e6;
    --muted: #9ca3af;
    --accent: #ff6a00;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text);
}

/* ------------------------------------------------------------------------------------------------------ */
/* Topbar */
.topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--sidebar);
    display: flex;
    align-items: center;
    padding: 0 20px;
    z-index: 1000;
    border-bottom: 1px solid #222;
}

.logo {
    display: flex;
    align-items: center;
    margin-left: 0px;
    height: 100%; /* Nutzt die 60px der Topbar aus */
}

.logo img {
    height: 100px;  /* Perfekte Höhe für eine 60px Leiste (lässt oben/unten Platz) */
    width: auto;   /* Verhindert Verzerrungen */
    display: block;
    object-fit: contain;
}

/* Mobil-Anpassung: Falls das Logo auf dem Handy zu groß ist */
@media (max-width: 600px) {
    .logo img {
        height: 80px;
    }
}

/* ------------------------------------------------------------------------------------------------------ */
/* Sidebar */
.sidebar {
    position: fixed;
    top: 60px;
    left: 0;
    width: 300px; /* Von 250px auf 300px erhöht */
    height: calc(100vh - 60px);
    background: var(--sidebar);
    padding: 20px;
    transition: 0.3s ease;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 1000;
}

/* Optional: Verschönert die Scrollbar in der Sidebar (für Chrome/Edge/Safari) */
.sidebar::-webkit-scrollbar {
    width: 5px;
}

.sidebar::-webkit-scrollbar-track {
    background: var(--sidebar);
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--card);
    border-radius: 10px;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin-bottom: 15px;
}

.sidebar a {
    text-decoration: none;
    color: var(--muted);
    font-size: 14px;
    padding: 8px 10px;
    border-radius: 6px;
    display: block;
    transition: 0.2s;
}

.sidebar a:hover,
.sidebar a.active {
    background: var(--card);
    color: white;
}

/* Sidebar Anpassungen */
.sidebar li {
    margin-bottom: 5px; /* Etwas weniger Abstand für kompaktere Gruppen */
}

/* Sidebar Untermenü - Standardmäßig versteckt */
.sidebar .submenu {
    display: block; /* Initial geschlossen */
    list-style: none;
    padding-left: 30px; /* Stärkere Einrückung */
    margin-top: 5px;
    margin-bottom: 10px;
    border-left: 2px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.sidebar .submenu li {
    margin-bottom: 2px;
}

.sidebar .submenu a {
    font-size: 13px; /* Etwas kleinere Schrift für Unterpunkte */
    padding: 6px 12px;
    color: var(--muted);
    opacity: 0.8;
}

.sidebar .submenu a:hover {
    background: rgba(255, 255, 255, 0.05); /* Leichterer Hover-Effekt */
    color: white;
    opacity: 1;
}

/* Aktiver Unterpunkt (optional) */
.sidebar .submenu a.active-sub {
    color: var(--accent); /* Falls du eine Akzentfarbe definiert hast */
    font-weight: 600;
}

/* Klasse zum Anzeigen (wird per JS gesteuert) */
.sidebar .submenu.open {
    display: block;
}

/* Styling für den Pfeil */
.arrow {
    float: right;
    font-size: 10px;
    transition: transform 0.3s;
    opacity: 0.5;
}

/* Diese Klasse wird nun zum Schließen verwendet, falls gewünscht */
.sidebar .submenu.closed {
    display: none;
}

/* Drehung des Pfeils wenn offen */
.submenu-toggle.active {
    transform: rotate(180deg);
}
.menu-parent.active .arrow {
    transform: rotate(180px); /* Pfeil dreht sich beim Öffnen */
}

/* Container für Link + Pfeil */
.menu-item-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.main-link {
    flex-grow: 1; /* Der Link nutzt den restlichen Platz */
}

/* Der Button zum Aufklappen */
.submenu-toggle {
    background: transparent;
    border: none;
    color: var(--muted);
    padding: 8px 15px;
    cursor: pointer;
    font-size: 10px;
    transition: transform 0.3s, color 0.2s;
	transform: rotate(180deg);
}

.submenu-toggle:hover {
    color: white;
}

/* Mobil-Optimierung: Größere Klickflächen */
@media (max-width: 768px) {
    .sidebar .submenu a {
        padding: 10px 15px;
        font-size: 14px; /* Auf dem Handy besser lesbar */
    }
}

/* Mobil-Anpassung: Sidebar muss über dem Content liegen */
@media (max-width: 900px) {
    .sidebar {
        z-index: 2000;
        /* Verhindert, dass man den Hintergrund scrollt, wenn das Menü offen ist */
        -webkit-overflow-scrolling: touch; 
    }
}

/* Aktiver Unterpunkt: Dunkler Hintergrund, graue Schrift */
.sidebar .submenu a.active-sub {
    background: var(--card) !important; /* Dunkelblau/Grau Hintergrund */
    color: var(--muted) !important;     /* Graue Schrift wie bei inaktiven Links */
    opacity: 1;
    font-weight: 600;
    border-radius: 6px;
}

/* Beim Drüberfahren (Hover) darf er dann weiß werden */
.sidebar .submenu a.active-sub:hover {
    background: var(--card) !important;
    color: white !important;
}
/* ------------------------------------------------------------------------------------------------------ */
/* Main Content */
.main {
    margin-left: 300px; /* Muss dem neuen Wert der Sidebar entsprechen */
    padding: 20px 40px 40px 40px;
    max-width: 1100px; /* Optional: Max-Width etwas erhöht für das breitere Layout */
    margin-top: 80px;
    box-sizing: border-box;
}

.main h1 {
    font-size: 32px;
    margin-bottom: 20px;
}

.main h2 {
    margin-top: 40px;
    margin-bottom: 10px;
    font-size: 20px;
}

.main p {
    color: var(--muted);
    line-height: 1.6;
}

.main ul {
    margin-left: 20px;
    margin-top: 10px;
}
/* ------------------------------------------------------------------------------------------------------ */
/* Right Nav */
.right-nav {
    position: fixed;
    right: 0;
    top: 100px;
    width: 220px;
    padding: 20px;
    color: var(--muted);
}

.right-nav h4 {
    margin-bottom: 15px;
    color: white;
    font-size: 14px;
}

.right-nav a {
    display: block;
    text-decoration: none;
    color: var(--muted);
    font-size: 13px;
    margin-bottom: 8px;
}

.right-nav a:hover {
    color: var(--accent);
}
@media (max-width: 900px) {
    .sidebar {
        width: 300px; /* Auch mobil die neue Breite nutzen */
        transform: translateX(-100%);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .main {
        margin-left: 0; /* Mobil nutzt der Inhalt die volle Breite */
        padding: 100px 15px 20px 15px;
    }
}


/* Menu Button */
/* Der Button ist auf dem Desktop IMMER unsichtbar */
.menu-toggle {
    display: none; 
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 6px;
    width: 48px;
    height: 40px;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    cursor: pointer;
    outline: none;
    -webkit-tap-highlight-color: transparent;
    transition: all 0.2s ease;
}

/* NUR wenn das Menü offen ist, wird er orange */
.menu-toggle.is-open {
    background: var(--accent);
    border-color: var(--accent);
}

/* Hover-Effekt (nur für Maus-Nutzer relevant) */
.menu-toggle:hover {
    background: var(--accent);
}

/* Erst ab hier (Mobil/Tablet) wird der Button angezeigt */
@media (max-width: 900px) {
    .menu-toggle {
        display: flex; /* Erscheint nur auf kleinen Bildschirmen */
    }
}

/* ------------------------------------------------------------------------------------------------------ */
/* Responsive */
@media (max-width: 1100px) {
    .right-nav {
        display: none;
    }
}

@media (max-width: 900px) {

    .menu-toggle {
        display: block;
    }

    .sidebar {
        transform: translateX(-100%);
        z-index: 999;
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .main {
        margin-left: 0;
        padding: 100px 20px 20px 20px;
    }
}

/* ------------------------------------------------------------------------------------------------------ */

/* Basis-Zustand: Nur Links innerhalb einer Card */
.card a, 
.card a:visited {
    color: #ff7f2a; /* Dein Orange */
    background: transparent; /* Falls vorher ein Background da war, hier zurücksetzen */
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s ease;
    display: inline-block; /* Damit Transform & Padding sauber wirken */
}

/* Hover-Zustand: Etwas heller (#ff9854) */
.card a:hover {
    color: #ff9854; /* Ein etwas helleres Orange */
    background: #ffffff; 
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(255, 106, 0, 0.2);
}

/* Aktiv-Zustand: Wenn man gerade draufdrückt */
.card a:active {
    transform: translateY(0);
}

/* Basis-Style für alle Boxen */
.info-box {
    padding: 15px 20px;
    margin: 15px 0;
    border-radius: 4px;
    border-left: 6px solid; /* Der farbige Balken links */
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
}

/* ------------------------------------------------------------------------------------------------------ */
/* Farbausprägungen (Hintergrund und Balkenfarbe) */
.info-box.green {
    background-color: rgba(40, 167, 69, 0.15); /* Transparentes Grün */
    border-color: #28a745;
    color: #d4edda;
}

.info-box.red {
    background-color: rgba(220, 53, 69, 0.15); /* Transparentes Rot */
    border-color: #dc3545;
    color: #f8d7da;
}

.info-box.blue {
    background-color: rgba(0, 123, 255, 0.15); /* Transparentes Blau */
    border-color: #007bff;
    color: #cce5ff;
}

.info-box.yellow {
    background-color: rgba(255, 193, 7, 0.15); /* Transparentes Gelb */
    border-color: #ffc107;
    color: #fff3cd;
}

.info-box.orange {
    background-color: rgba(253, 126, 20, 0.15); /* Transparentes Orange */
    border-color: #fd7e14;
    color: #ffe5d0;
}

.info-box.white {
    background-color: rgba(255, 255, 255, 0.1); /* Transparentes Weiß */
    border-color: #ffffff;
    color: #ffffff;
}

/* Hervorhebung innerhalb der Boxen */
.info-box strong {
    font-weight: 700;
}

/* ------------------------------------------------------------------------------------------------------ */
/* --- Karten-Interaktion (iFrame) --- */
.map-wrapper {
    position: relative;
    padding-bottom: 75.00%; /* 4:3 Verhältnis */
	min-height: 500px; /* Die Karte ist immer mindestens 400px hoch */
    height: 0;
    overflow: hidden;
    border-radius: 12px;
    border: 2px solid var(--accent);
    margin-bottom: 30px;
    background: #f8f9fa;
}

.map-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    /* Karte reagiert standardmäßig nicht auf Scrollen/Touch */
    pointer-events: none; 
    transition: all 0.3s ease;
}

/* Karte wird aktiv, wenn man mit der Maus darüber fährt */
.map-wrapper:hover iframe {
    pointer-events: auto;
}

/* --- Optimierte Karten-Übersicht (Die Kacheln) --- */
.map-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
    gap: 20px;
    margin: 20px 0;
}

.map-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 18px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease-in-out;
    display: flex;
    flex-direction: column;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04);
    cursor: pointer;
}

.map-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.1);
    border-color: var(--accent); /* Nutzt deine globale Akzent-Farbe */
}

.map-card .map-name {
    font-weight: 700;
    font-size: 1.15em;
    color: var(--accent); /* Harmonisiert mit dem Rest der Seite */
    margin-bottom: 10px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    display: block;
}

.map-card .map-info {
    font-size: 0.9em;
    color: #555;
    background: #f1f3f5;
    padding: 10px;
    border-radius: 6px;
    margin-top: auto;
    border-left: 3px solid #dee2e6;
}

/* Spezieller Fix für sehr kleine Displays */
@media (max-width: 600px) {
    .map-wrapper {
        padding-bottom: 120%; /* Macht die Karte auf dem Handy quadratisch/hochkant */
    }
}
/* ------------------------------------------------------------------------------------------------------ */
/* Styling für die große Konfigurations-Tabelle */
.meshtastic-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 30px 0;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 1px solid #e0e0e0;
}

.meshtastic-table th {
    background-color: #f8f9fa;
    color: #333;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85em;
    letter-spacing: 1px;
    padding: 20px;
    border-bottom: 2px solid #dee2e6;
    text-align: left;
}

.meshtastic-table td {
    padding: 18px 20px; /* Viel Abstand für bessere Lesbarkeit */
    border-bottom: 1px solid #f0f0f0;
    vertical-align: top;
    color: #444;
}

/* Kategorie-Spalte hervorheben */
.meshtastic-table td:first-child {
    font-weight: 600;
    color: #007bff;
    background-color: #fcfcfc;
    width: 25%;
}

/* Einstellung-Spalte */
.meshtastic-table td:nth-child(2) {
    color: #666;
    width: 30%;
}

/* Empfehlungs-Spalte (Wichtigster Teil) */
.meshtastic-table td:last-child {
    font-weight: 500;
    color: #000;
}

/* Zeilen-Hover Effekt */
.meshtastic-table tbody tr:nth-child(even) {
    background-color: #f8f9fa; /* Ganz leichtes Grau für jede zweite Zeile */
}

.recommend-badge {
    background: #e7f3ff;
    color: #007bff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
}

.warning-text {
    color: #d9534f;
    font-weight: 700;
}

/* Trenner für Hauptkategorien */
.category-row td {
    background: #f1f3f5 !important;
    border-bottom: 2px solid #dee2e6;
}

/* Container für mobiles Scrollen */
.table-responsive {
    width: 100%;
    overflow-x: auto; /* Erlaubt horizontales Scrollen */
    -webkit-overflow-scrolling: touch; /* Sanftes Scrollen auf iOS */
    margin-bottom: 1rem;
    border-radius: 12px;
}

.meshtastic-table img {
    vertical-align: middle;
    /* Verhindert, dass Bilder zu groß werden */
    max-width: 50px; 
    max-height: 50px;
    /* Optional: Ein kleiner Rahmen, falls die Icons transparenten Hintergrund haben */
    background: white;
    border-radius: 4px;
}

/* Damit die Spalte mit dem Icon nicht zu breit wird */
.meshtastic-table th:first-child, 
.meshtastic-table td:first-child {
    width: 60px;
    text-align: center;
}

/* Visueller Hinweis für mobiles Scrollen (optional) */
@media (max-width: 768px) {
    .table-responsive::after {
        content: "↔ Wischen zum Scrollen";
        display: block;
        text-align: right;
        font-size: 0.75em;
        color: #888;
        padding: 5px 0;
    }
    
    /* Etwas schmalere Abstände auf dem Handy */
    .meshtastic-table td, 
    .meshtastic-table th {
        padding: 12px 15px;
        min-width: 140px; /* Verhindert, dass Spalten zu eng werden */
    }
    
    .meshtastic-table td:first-child {
        min-width: 120px;
    }
}

/* ------------------------------------------------------------------------------------------------------ */
/* Container für das Logo unter der H1 */
/* Der Container stellt sicher, dass nichts nach rechts ausbricht */
.hero-logo-container {
    width: 100%;
    max-width: 100%;       /* Darf niemals breiter als der Bildschirm sein */
    display: flex;
    justify-content: flex-start; /* Oder 'center', falls gewünscht */
    margin: 20px 0;
    overflow: hidden;      /* Schneidet Überstände im Notfall ab */
    padding: 0;            /* Verhindert doppeltes Padding-Problem */
}

/* Das Logo passt sich nun dynamisch an */
.hero-logo {
    display: block;
    width: auto;           /* Nimmt nur so viel Platz wie nötig */
    max-width: 100%;       /* WICHTIG: Begrenzt das Bild auf die Bildschirmbreite */
    height: auto;          /* Behält das Seitenverhältnis bei */
    
    /* Falls das Logo auf dem Desktop eine feste Maximalgröße haben soll: */
    max-height: 150px;     /* Begrenzt die Höhe, damit es nicht zu riesig wird */
}

/* Zusätzlicher Fix für das Haupt-Layout, falls .main das Problem ist */
.main {
    max-width: 100vw;      /* Verhindert horizontales Scrollen der ganzen Seite */
    overflow-x: hidden;    
    padding: 20px;         /* Standard-Abstand zum Rand */
    box-sizing: border-box; /* Rechnet Padding in die Breite ein */
}

/* Anpassung für mobile Endgeräte */
@media (max-width: 600px) {
    .hero-logo {
        max-width: 250px;    /* Etwas kleiner auf kleinen Bildschirmen */
    }
    .hero-logo-container {
        margin: 15px 0 20px 0;
    }
}

/* ------------------------------------------------------------------------------------------------------ */
/* Spezielle Formatierung für die Namens-Beispiele */
.naming-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.naming-list li {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid #333;
    padding: 12px 15px;
    margin-bottom: 10px;
    border-radius: 6px;
    line-height: 1.6;
}

/* Der rote Highlight-Stil aus dem Bild */
.node-example {
    color: #ff4d4d; /* Ein helleres Rot für dunkle Hintergründe */
    font-family: 'Courier New', Courier, monospace;
    font-weight: bold;
    background: rgba(255, 77, 77, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
}

.naming-note {
    font-size: 0.9em;
    color: #888;
    font-style: italic;
    margin-top: 10px;
}

/* ------------------------------------------------------------------------------------------------------ */
/* Filter Styling */
.node-filter {
    margin-bottom: 30px;
    display: flex;
    gap: 10px;
}

.filter-btn {
    background: var(--card);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--muted);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

.filter-btn.active, .filter-btn:hover {
    background: var(--accent);
    color: white;
}

/* Grid System */
.node-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

/* Card Styling */
.node-card {
    background: var(--card);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
}

.card-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 10px;
    text-transform: uppercase;
    font-weight: bold;
    padding: 4px 8px;
    border-radius: 4px;
}

.official .card-badge { background: var(--accent); color: white; }
.community .card-badge { background: #4b5563; color: #d1d5db; }

.card-content {
    padding: 20px;
}

.card-content h3 {
    margin-bottom: 15px;
    font-size: 18px;
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 5px;
    font-size: 13px;
    margin-bottom: 15px;
}

.info-grid span {
    color: var(--muted);
}

.info-grid strong {
    color: var(--text);
    width: 90px;
    display: inline-block;
}

.node-desc {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 15px;
}

/* Bilder ausklappen */
.node-images summary {
    font-size: 13px;
    color: var(--accent);
    cursor: pointer;
    outline: none;
    margin-top: 10px;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 10px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.gallery img {
    width: 100%;
    border-radius: 4px;
    object-fit: cover;
}

.gallery a {
    cursor: pointer;
    display: block;
    transition: transform 0.2s;
}

.gallery a:hover {
    transform: scale(1.03); /* Leichter Zoom-Effekt beim Hovern */
}

/* Styling für Partner-Links in den Kacheln */
.node-link {
    color: var(--accent); /* Nutzt dein Orange */
    text-decoration: none;
    font-weight: 500;
    transition: 0.2s;
}

.node-link:hover {
    text-decoration: underline;
    filter: brightness(1.2);
}

/* Falls der Partner kein Link hat, sondern nur Text ist */
.info-grid span a {
    display: inline-block;
}

.node-title {
    display: flex;
    align-items: center;
    gap: 10px; /* Abstand zwischen Punkt und Name */
    margin-bottom: 15px;
    font-size: 18px;
}

/* Der Status-Punkt (angepasst für die Titel-Zeile) */
.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0; /* Verhindert, dass der Punkt gequetscht wird */
}

.status-indicator.online {
    background-color: #2ecc71;
    box-shadow: 0 0 8px rgba(46, 204, 113, 0.4);
    animation: pulse-green 2s infinite;
}

.status-indicator.offline {
    background-color: #e74c3c;
    box-shadow: 0 0 8px rgba(231, 76, 60, 0.4);
}

/* Die Animation bleibt gleich */
@keyframes pulse-green {
    0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(46, 204, 113, 0.5); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 6px rgba(46, 204, 113, 0); }
    100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(46, 204, 113, 0); }
}

/* Badge Korrektur (da es jetzt alleine oben rechts steht) */
.card-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 10px;
    padding: 4px 8px;
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
    color: var(--muted);
}

/* Container für das Sponsoren-Banner */
.node-sponsor {
    display: block;
    width: calc(100% + 40px); /* Zieht das Bild über das Padding der card-content hinaus */
    margin: -20px -20px 15px -20px; /* Negatives Margin gleicht das Padding der card-content aus */
    height: 80px; /* Feste Höhe, damit die Kacheln gleichmäßig bleiben */
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.node-sponsor img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Schneidet das Bild passend zu, ohne es zu verzerren */
    transition: transform 0.3s ease;
}

/* Hover-Effekt für Interaktion */
.node-sponsor:hover img {
    transform: scale(1.05);
}

/* Falls das Banner kein Link ist, sondern nur ein Bild */
.node-sponsor-static {
    display: block;
    width: calc(100% + 40px);
    margin: -20px -20px 15px -20px;
    height: 80px;
    overflow: hidden;
}

/* ------------------------------------------------------------------------------------------------------ */

/* Inhalt der Karte */
.node-content {
    padding: 20px;
}

.node-content h3 {
    margin-bottom: 10px;
    color: var(--accent);
}

.node-content p {
    font-size: 14px;
    margin-bottom: 15px;
}

/* Info-Liste innerhalb der Karte */
.node-info {
    font-size: 13px;
    margin-bottom: 15px;
    color: var(--muted);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 10px;
}

.info-item {
    margin-bottom: 4px;
}

.card-action {
    margin-top: 20px;
    text-align: right;
}
/* Container für den Slider */
.slider-container {
    position: relative;
    height: 450px; /* Hier die gewünschte Höhe einstellen (vorher 200px) */
    width: 100%;
    background: #000; /* Schwarzer Hintergrund für Bilder, die nicht ganz füllen */
    overflow: hidden;
}

/* Der scrollbare Bereich */
.slider {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    height: 100%;
}

/* Versteckt die Scrollbar */
.slider::-webkit-scrollbar {
    display: none;
}

.slider img {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    object-fit: contain; /* 'contain' zeigt das ganze Bild, 'cover' füllt das Fenster komplett aus */
    scroll-snap-align: start;
}

/* Styling der Pfeile */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 12px;
    cursor: pointer;
    font-size: 18px;
    z-index: 10;
    transition: background 0.3s;
}

.slider-arrow:hover {
    background: var(--accent);
}

.slider-arrow.prev { left: 0; border-radius: 0 4px 4px 0; }
.slider-arrow.next { right: 0; border-radius: 4px 0 0 4px; }

/* ------------------------------------------------------------------------------------------------------ */
/* Freifunk Stats (img) */
.stats-container {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 40px; /* Abstand zwischen den Gruppen */
}

.stats-group {
    background: var(--card);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
}

.stats-group h2 {
    margin-bottom: 15px !important;
    font-size: 18px !important;
    color: var(--accent);
}

.stat-large-img {
    width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
    transition: opacity 0.2s ease;
}

.img-wrapper {
    background: #000;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
}

.stat-controls {
    display: flex;
    gap: 10px;
}

.stat-controls button {
    flex: 1;
    background: var(--sidebar);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--muted);
    padding: 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
}

.stat-controls button:hover {
    background: var(--accent);
    color: white;
}

.stat-large-img {
    width: 100%;       /* Nutzt die volle Breite des Containers */
    max-width: 100%;   /* Verhindert Überlaufen */
    height: auto;      /* Behält das Seitenverhältnis bei */
    display: block;
    border-radius: 4px;
}

@media (max-width: 768px) {
    /* Den Hauptcontainer weniger einrücken */
    .main {
        padding: 80px 10px 20px 10px !important;
    }

    /* Die Statistik-Box (Card) - Padding innen reduzieren */
.stats-group {
    background: var(--card);
    padding: 10px 15px 15px 15px !important; /* Erster Wert (Top) von 20px auf 10px reduziert */
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 20px;
}

    /* Der Wrapper um das Bild - seitliche Ränder auf 0 setzen */
    .img-wrapper {
        margin-left: -5px;
        margin-right: -5px;
        border-radius: 0; /* Optional: Ecken auf dem Handy eckig für mehr Platz */
        border-left: none;
        border-right: none;
        min-height: auto; /* Verhindert unnötige Höhe */
    }

    .stat-large-img {
        width: 100%;
        height: auto;
        transform: scale(1); /* Falls wir vorhin skaliert haben, hier zurücksetzen */
    }

    /* Die Buttons etwas kompakter machen */
    .stat-controls {
        gap: 5px;
    }
    
    .stat-controls button {
        padding: 8px 2px;
        font-size: 10px;
    }
}

.stat-controls button.active {
    background: var(--accent) !important;
    color: white !important;
    border-color: var(--accent) !important;
}

.stats-group h2 {
    margin-top: 0 !important;      /* Entfernt jeglichen Abstand nach oben */
    margin-bottom: 10px !important; /* Kleiner Abstand zum Bild */
    font-size: 16px !important;    /* Etwas kompakter für mehr Fokus auf den Graph */
    line-height: 1.2;
}

/* ------------------------------------------------------------------------------------------------------ */

/* Universeller Container für externe Einbindungen */
.embed-wrapper {
    width: 100%;
    /* Berechnet: Gesamte Höhe minus Topbar (60px) minus Padding (80px) */
    height: calc(100vh - 140px); 
    background: var(--card);
    border-radius: 12px;
    overflow: hidden; /* Sorgt dafür, dass der iframe die Rundungen nicht überlagert */
    position: relative;
}

.embed-wrapper iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* Mobil-Optimierung */
@media (max-width: 900px) {
    .embed-wrapper {
        height: calc(100vh - 160px); /* Etwas mehr Platz für die mobile Topbar */
    }
}
/* ------------------------------------------------------------------------------------------------------ */
/* Globales, kategorisiertes FAQ (Accordeon) */
.faq-category-title {
    margin-top: 40px;
    margin-bottom: 15px;
    font-size: 22px;
    color: var(--accent); /* Dein Orange als Akzent für die Kategorien */
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 5px;
}

.faq-container {
    display: flex;
    flex-direction: column;
    gap: 12px; /* Abstand zwischen den einzelnen Fragen */
    margin-bottom: 25px;
}

.faq-item {
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.faq-item[open] {
    border-color: rgba(255, 106, 0, 0.3); /* Leicht oranges Leuchten bei geöffneter Box */
    box-shadow: 0 4px 12px rgba(255, 106, 0, 0.05);
}

.faq-item summary {
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    list-style: none; /* Versteckt den Standard-Browser-Pfeil */
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    transition: background-color 0.2s ease;
}

/* Eigenen, rotierenden Pfeil via CSS-Konstrukt einbauen */
.faq-item summary::after {
    content: '▼';
    font-size: 10px;
    color: var(--muted);
    transition: transform 0.25s ease, color 0.25s ease;
}

.faq-item[open] summary::after {
    transform: rotate(180deg);
    color: var(--accent);
}

.faq-item summary:hover {
    background: rgba(255, 255, 255, 0.02);
}

.faq-content {
    padding: 0 20px 20px 20px;
    color: var(--muted);
    line-height: 1.6;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    padding-top: 15px;
    font-size: 14px;
}

.faq-content p {
    margin-bottom: 12px;
}

.faq-content p:last-child {
    margin-bottom: 0;
}

.faq-content ul {
    margin-left: 20px;
    margin-top: 5px;
    margin-bottom: 12px;
}

.faq-content ul li {
    margin-bottom: 4px;
}

/* ------------------------------------------------------------------------------------------------------ */
/* FAQ Hardware-Listen & Tabellen */
.faq-hw-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
}

.faq-hw-category {
    background: rgba(255, 255, 255, 0.02);
    border-left: 4px solid var(--accent);
    padding: 15px;
    border-radius: 0 8px 8px 0;
}

.faq-hw-category h3 {
    font-size: 16px;
    margin-bottom: 5px;
    color: #fff;
}

.faq-hw-item {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 13.5px;
}

.faq-hw-item:last-child {
    border-bottom: none;
}

.faq-hw-name {
    font-weight: 700;
    color: var(--accent);
}

.faq-hw-specs {
    display: block;
    font-size: 12px;
    color: var(--muted);
    margin-top: 2px;
}
/* ------------------------------------------------------------------------------------------------------ */
/* Neue Projekt-Kacheln für die Startseite */
/* Kachel-Container: Flexbox für saubere Abstände */

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 400px)); /* Maximal 400px breit */
    gap: 30px;
    justify-content: center; /* Zentriert die Kacheln, wenn weniger als 3 Platz haben */
}
.project-card {
    background: var(--sidebar);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column; /* Bild oben, Text/Button unten */
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: 0.3s;
}

/* Bild-Container: Verhindert Stauchung */
.project-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.project-card-content {
    padding: 20px;
    flex-grow: 1; /* Sorgt dafür, dass der Inhalt den Platz ausfüllt */
    display: flex;
    flex-direction: column;
}

/* Button-Stil für die Links */
.project-btn {
    display: inline-block;
    margin-top: auto; /* Schiebt den Button immer an das untere Ende der Kachel */
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    text-align: center;
    font-weight: 600;
    transition: 0.2s;
    width: fit-content;
}

.project-btn:hover {
    background: var(--accent);
}

/* Container, der den Zoom beschneidet */
.img-hover-zoom {
    width: 100%;
    height: 220px;
    overflow: hidden; /* WICHTIG: Hier wird das Bild abgeschnitten, wenn es zoomt */
    display: block;
}

/* Das eigentliche Bild mit Transition */
.img-hover-zoom img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease; /* Die Dauer des Zooms */
}

/* Der Zoom-Effekt beim Hover über die Karte */
.project-card:hover .img-hover-zoom img {
    transform: scale(1.1); /* Zoom auf 110% */
}
/* ------------------------------------------------------------------------------------------------------ */
/* Neue Social-Kacheln für die Startseite */
/* Kachel-Container: Flexbox für saubere Abstände */

/* Container für die Social-Cards (kompakt) */
.social-grid {
    display: grid;
    /* Zentriert die Kacheln auf maximal 280px Breite pro Stück */
    grid-template-columns: repeat(auto-fit, minmax(200px, 280px));
    gap: 20px;
    margin: 30px auto;
    justify-content: center;
    max-width: 1000px; /* Begrenzt den gesamten Block auf dem Desktop */
}

/* Icon-Box in der Karte */
.card-icon {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
    background: #f1f3f5; /* Sanftes Grau statt grellem Weiß */
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-icon img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

/* Karten-Styling */
.card {
    background: #ffffff;
    border: 1px solid #dcdfe3;
    border-radius: 12px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

/* Button-Link innerhalb der Karte */
/* Überschriften in den Kacheln: Etwas dunkler und prägnanter */
.card h3 {
    color: #111827; /* Ein sehr dunkles Graublau - besser lesbar als helles Grau */
    margin-top: 0;
    margin-bottom: 12px;
}

/* Der Fließtext in den Kacheln: Deutlicher als vorher */
.card p, .card {
    color: #374151; /* Ein kräftiges Anthrazit, perfekt für Bildschirme */
}

/* Die Konfigurations-Liste: Hier heben wir die "Werte" farblich ab */
.config-list li {
    color: #4b5563; /* Etwas dunkler für bessere Lesbarkeit */
}

.config-list li strong {
    color: #1f2937; /* Die Beschriftungen (Label) noch einen Tick dunkler */
}

/* Link-Buttons: Damit diese auch im dunklen Design gut wirken */
.card a {
    color: #2563eb; /* Ein kräftiges Blau für die Links */
    font-weight: 600;
}