/* Section Base Styles */
.filter-section, 
.env-section, 
.lfo-section, 
.mod-routing-section, 
.unison-section {
    flex: 1;
    padding: 4px;
}

.filter-section {
    margin: 0 5px;
    position: relative;
}

.env-section {
    margin-top: 14px;
    margin-left: 5px;
    margin-right: 5px;
    margin-bottom: 2px;
}

.lfo-section {
    margin-top: 14px;
    margin-left: 5px;
    margin-right: 5px;
    margin-bottom: 2px;
}

.voice-ctrl-section {
    margin-top: 14px;
    margin-left: 5px;
    margin-right: 5px;
    margin-bottom: 2px;
}

/* Section Headers */
.filter-section h3, 
.env-section h3, 
.lfo-section h3, 
.voice-ctrl-section h3, 
.aux-oscs-section h3, 
.mod-routing-section h3, 
.unison-section h3, 
.arpeggiator-section h3 {
    font-family: "JetBrains Mono", "SF Mono", "Roboto Mono", Menlo, Monaco, "Courier New", monospace;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-primary);
    margin: 0;
    text-align: left;
    padding-left: var(--spacing-sm);
    position: relative;
    appearance: none;
    -webkit-appearance: none; 
    -moz-appearance: none;
}

/* Section Header Rows */
.lfo-header-row, 
.env-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    position: relative;
    margin-bottom: var(--spacing-md);
}

/* Section Header Underlines */
.lfo-header-row::after,
.env-header-row::after,
.filter-section h3::after,
.mod-matrix-header-row::after,
.effects-header::after,
.arpeggiator-header::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -8px;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.voice-ctrl-section h3::after,
.aux-oscs-section h3::after,
.mod-routing-section h3::after,
.unison-section h3::after {
    content: '';
    position: absolute;
    left: var(--spacing-sm);
    right: auto;
    width: 85%;
    bottom: -8px;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

/* Pagination Controls */
.lfo-pagination, 
.env-pagination {
    display: flex;
    gap: var(--spacing-sm);
}

/* Mod Matrix */
.mod-matrix {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    width: 100%;
    margin-top: var(--spacing-sm);
    justify-content: flex-start;
    position: relative;
}

/* Mod Rows */
.mod-row {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.mod-row label {
    flex: 0 0 90px;
}

.mod-row input[type=range], 
.mod-row select {
    flex: 1;
}

.mod-row select {
    background: var(--bg-color);
    color: var(--text-secondary);
    border: 1px solid var(--border-color-dark);
    border-radius: 2px;
    padding: 2px 4px;
    font-size: var(--text-sm);
    cursor: pointer;
    transition: border-color 0.2s;
}

.mod-row select:hover {
    border-color: var(--accent-color);
}

.mod-row select:focus {
    outline: none;
}

/* Non-knob Mod Rows */
.mod-row:not(:has(.knob-container)) {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.mod-row:not(:has(.knob-container)) label {
    flex: 0 0 90px;
    margin-right: 6px;
    text-align: left;
}

.mod-row:not(:has(.knob-container)) select,
.mod-row:not(:has(.knob-container)) button,
.mod-row:not(:has(.knob-container)) input:not([type="hidden"]) {
    flex: 1;
}

/* Mod Section */
.mod-section {
    flex: 1;
    padding: 0;
    margin: 0;
    max-width: 100%;
    min-width: 0;
}

.mod-section[style*="width: 100%"] {
    min-width: calc(100% - 20px);
    max-width: calc(100% - 20px);
    flex-basis: calc(100% - 20px);
}

/* Select styling */
select {
    font-family: "Noto Sans", sans-serif;
}

