/*
 * Hier liegen alle Styles für die Lobb-Ansicht (nach dem Login)
 * Das umfasst die Top-Bar, Dropdowns, der Footer und die Sektor-Karten
 */

 #lobby-ui {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    pointer-events: none; 
    z-index: 15;
}

#top-bar {
    width: 100%; height: 50px;
    background: transparent; 
    border-bottom: none;
    box-shadow: none;
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 20px; box-sizing: border-box;
    pointer-events: auto; 
}

.top-bar-right {
    display: flex; align-items: center; gap: 20px;
}

.custom-dropdown {
    position: relative;
    font-family: var(--font-main);
    color: var(--color-text-main);
}

.dropdown-toggle {
    display: flex; align-items: center; gap: 8px;
    cursor: pointer;
    padding: 5px 10px;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    user-select: none;
}

.dropdown-toggle:hover {
    border: 1px solid var(--color-cyan-dark);
    background: rgba(0, 240, 255, 0.05);
}

.dropdown-arrow {
    font-size: 10px;
    color: var(--color-cyan-dark);
}

.flag-icon { font-size: 16px; }

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: rgba(11, 25, 44, 0.95);
    border: 1px solid var(--color-cyan-dark);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    list-style: none;
    padding: 5px 0;
    min-width: 150px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: all 0.2s ease;
}

.dropdown-menu.show {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.user-menu { min-width: 220px; }

.dropdown-item {
    padding: 10px 15px;
    cursor: pointer;
    display: flex; 
    align-items: center; 
    gap: 10px;
    font-size: 14px;
    transition: background 0.2s ease, color 0.2s ease;
}

.dropdown-item:hover:not(.disabled) {
    background: rgba(0, 240, 255, 0.1);
    color: var(--color-cyan-bright);
}

.dropdown-item.disabled, .dropdown-header.disabled {
    color: var(--color-text-inactive);
    cursor: not-allowed;
}

.dropdown-header {
    padding: 10px 15px;
    font-size: 14px;
    line-height: 1.4;
}

.premium-text {
    color: var(--color-cyan-bright);
    font-weight: bold;
}

.dropdown-divider {
    height: 1px;
    background: var(--color-cyan-dark);
    margin: 5px 0;
    opacity: 0.5;
}

.logout-item {
    color: var(--color-error);
    font-weight: bold;
}

.logout-item:hover {
    background: rgba(255, 68, 68, 0.1) !important;
    color: var(--color-error) !important;
}

#game-footer {
    position: absolute; bottom: 0; left: 0; width: 100%;
    height: 40px; 
    z-index: 20; 
    pointer-events: none; 
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 40px; box-sizing: border-box;
    color: var(--color-text-inactive);
    font-size: 12px;
    font-family: inherit; 
    border-top: 1px solid var(--color-text-inactive);
    background: transparent; 
}

.footer-left { flex: 1; text-align: left; }
.footer-center { flex: 1; text-align: center; }
.footer-right { flex: 1; text-align: right; }

#game-footer a {
    color: var(--color-text-inactive); text-decoration: none;
    transition: color 0.2s ease, text-shadow 0.2s ease;
    pointer-events: auto;
}

#game-footer a:hover {
    color: var(--color-cyan-bright);
    text-shadow: 0 0 8px var(--color-cyan-bright);
}

#sector-browser-layer {
    position: absolute;
    width: 1240px;
    height: 650px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%); 
    pointer-events: auto; 
    transition: opacity 0.3s ease; 
}
#sector-tab-container {
    position: absolute;
    top: 20px;
    width: 100%;
    height: 40px;
    display: flex;
    justify-content: center;
    gap: 20px; 
}

#sector-tab-container .tab-btn {
    position: relative; 
    left: 0 !important;
    top: 0 !important;
}

#tab-my-sectors { left: 45px; }
#tab-new-sectors { left: 235px; }

#sector-list-container {
    position: absolute;
    top: 80px;
    width: 100%;
    height: 540px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px 40px; /* Zurück zu den perfekten 40px */
    box-sizing: border-box;
    
    /* Zurück zum Grid für eine saubere Matrix-Optik */
    display: grid;
    grid-template-columns: repeat(4, 270px); 
    grid-auto-rows: 90px;
    row-gap: 20px;
    column-gap: 25px;
    align-content: start;
    
    /* Zentriert den gesamten Grid-Block (inkl. Lücken) mittig im Container */
    justify-content: center; 
}

.sector-card-link {
    display: block;
    width: 270px;
    height: 90px;
    text-decoration: none;
    color: var(--color-text-main);
    position: relative;
    cursor: pointer;
    box-sizing: border-box;
}

.sector-card-content {
    position: relative;
    width: 100%;
    height: 100%;
    padding: 15px 25px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.sector-row-top {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 18px;
    font-weight: bold;
    letter-spacing: 1px;
}

.sector-details-icon {
    font-size: 14px;
    color: var(--color-text-inactive);
    transition: transform 0.2s ease, color 0.2s ease;
}

.sector-card-link:hover .sector-details-icon {
    color: var(--color-cyan-bright);
    transform: scale(1.2) rotate(10deg);
}

.sector-status {
    margin-left: auto;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.status-online {
    color: var(--color-green-bright);
    text-shadow: 0 0 8px rgba(0, 255, 0, 0.6);
}

.status-maintenance {
    color: var(--color-error);
    text-shadow: 0 0 8px rgba(255, 68, 68, 0.6);
}

.sector-row-mid {
    display: flex;
    gap: 30px;
    font-size: 13px;
    color: var(--color-text-placeholder);
    margin-top: 5px;
}

.sector-row-bottom {
    font-size: 12px;
    color: var(--color-cyan-bright);
    margin-top: 4px;
    font-style: italic;
}

#sector-list-container::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

#sector-list-container::-webkit-scrollbar-track {
    background: rgba(11, 25, 44, 0.3);
}

#sector-list-container::-webkit-scrollbar-thumb {
    background: var(--color-cyan-dark);
    border-radius: 3px;
}