/* GRUNDLÄGGANDE STYLING & MÖRKT TEMA */
:root {
    --bg-color: #121212;
    --surface-color: #1e1e1e;
    --primary-color: #a971f5;
    --text-color: #e0e0e0;
    --text-muted-color: #888;
    --glass-bg: rgba(40, 40, 40, 0.6);
    --glass-border: rgba(255, 255, 255, 0.1);
    --shadow-color: rgba(0, 0, 0, 0.3);
    --hue-on-color: #ffdd8a;
    --hue-on-glow: #e0b445;
}

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

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    overscroll-behavior: none;
}

#app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

/* SIDOMENY (RUM-LISTA) */
#sidebar {
    background-color: var(--surface-color);
    padding: 1.5rem 1rem;
    display: flex;
    flex-direction: column;
    border-bottom: 1px solid var(--glass-border);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

#room-list h2 {
    font-size: 0.9rem;
    text-transform: uppercase;
    color: var(--text-muted-color);
    margin-bottom: 1rem;
}

.room-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem;
    border-radius: 12px;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
    font-weight: 600;
}

.room-item:hover {
    background-color: var(--glass-bg);
}

.room-item.active {
    background-color: var(--primary-color);
    color: #fff;
}

.sidebar-footer {
    margin-top: auto;
}

/* HUVUDINNEHÅLL */
#main-view {
    flex-grow: 1;
    padding: 1.5rem;
    overflow-y: auto;
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

#main-view-title {
    font-size: 1.8rem;
    font-weight: 700;
}

.content-section {
    margin-bottom: 2.5rem;
}

.content-section h3 {
    margin-bottom: 1rem;
    color: var(--text-muted-color);
    font-size: 1rem;
}

/* RUTNÄT FÖR LAMPOR OCH SCENER */
#lights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
}

.horizontal-scroll {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 1rem; /* För skuggor */
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */
}
.horizontal-scroll::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera
