/* --- Manages Very Long Link Heavy Indexes --- */
/* --- 1. Root Variables --- */
:root {
    --blue-primary: #2e82bc;
    --blue-dark: #295788;
    --orange-primary: #f99e24;
    --border-light: #d2d2d7;
    --premium-bg: #f5f5f7;
}
/* --- 2. Typography --- */
.row-content h2 {
    margin: 0 0 5px 0;
    line-height: 1.1;
    font-size: 1.75rem;
}
/* --- 3. Expanding Rows (Gold Standard 376px) --- */
.expanding-row {
    display: flex !important;
    margin-bottom: 20px !important;
    background: #fff !important;
    width: 100% !important;
    max-height: 390px !important;
    min-height: 390px !important;  /* ← Increased from 150px – restores consistent tall rows */
    position: relative !important;
    overflow: hidden !important;
    border: none !important;
    transition: max-height 0.5s ease-in-out 0.2s !important;
    transform: translateZ(0) !important;
    will-change: max-height;
}
.expanding-row:hover {
    max-height: 1200px !important;
    transition: max-height 0.6s ease-in-out 1s !important;
}
.expanding-row.premium-row {
    background-color: var(--premium-bg) !important;
}
/* --- 4. Vertical Badge --- */
.premium-badge-margin {
    background: var(--blue-dark) !important;
    color: #fff !important;
    flex: 0 0 30px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    order: 2 !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    writing-mode: vertical-rl !important;
    transform: rotate(180deg) !important;
    white-space: nowrap !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase !important;
}
/* --- 5. Content Layout --- */
.row-thumb-container {
    width: 171px !important;
    flex-shrink: 0 !important;
    margin: 15px 25px 0 15px !important;
}
.row-thumb-container img {
    width: 100% !important;
    height: auto !important;
    border-radius: 4px !important;
    display: block !important;
}
.row-content {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    padding-top: 15px !important;
    padding-bottom: 20px !important;
    justify-content: flex-start !important;
}
/* --- 6. Modern Dropdown (Clean Design & Focus Fix) --- */
.selectdiv {
    position: relative !important;
    border: 1.5px solid #d2d2d7 !important;
    border-radius: 6px !important;
    background-color: #ffffff !important;
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    margin-bottom: 20px !important;
    overflow: hidden !important;
    width: 250px !important;
}
.musicPopular {
    font-size: 16px !important;
    font-weight: 400 !important;
    padding-left: 15px !important;
    border: none !important;
    background: transparent !important;
    width: 100% !important;
    height: 100% !important;
    cursor: pointer !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    outline: none !important;
    box-shadow: none !important;
}
.musicPopular:focus,
.musicPopular:active,
.musicPopular:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}
.selectdiv:after {
    content: '\f107' !important;
    font-family: 'FontAwesome' !important;
    background-color: transparent !important;
    color: #295788 !important;
    border-left: 1.5px solid #d2d2d7 !important;
    position: absolute !important;
    right: 0 !important;
    top: 0 !important;
    width: 42px !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    pointer-events: none !important;
}
/* --- 7. Indicator (Updated for Chevron) --- */
.more-indicator {
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: absolute !important;
    bottom: 7px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    opacity: 1 !important;
    z-index: 10 !important;
    pointer-events: none !important;
    transition: opacity 0.3s ease-in 0.7s !important;
}
.more-indicator svg {
    width: 50px !important;
    height: 50px !important;
    display: block !important;
}
.expanding-row:hover .more-indicator {
    opacity: 0 !important;
    transition: opacity 0.2s ease-out 0.8s !important;
}
/* --- 8. Link Reveal Logic --- */
.links-container .comp-link:nth-of-type(n+6) {
    visibility: hidden;
    opacity: 0;
    max-height: 0;
    margin-bottom: 0 !important;
    padding: 0 !important;
    overflow: hidden;
    transition: opacity 0.3s ease, max-height 0.3s ease;
}
.expanding-row:hover .links-container .comp-link:nth-of-type(n+6) {
    visibility: visible;
    opacity: 1;
    max-height: 50px;
    margin-bottom: 12px !important;
    padding: 0 !important;
    transition: opacity 0.4s ease 0.8s, max-height 0.4s ease 0.8s;
}
/* --- 9. Filtering Helper Classes --- */
/* Forces filtered links to be visible, but we use nth-of-type to cap them at 5 */
.comp-link.filter-show {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    max-height: none !important;
}
/* Hide extra links during Brahms/Long filters unless hovered */
.row-standard-filter .comp-link.filter-show:nth-of-type(n+6) {
    visibility: hidden !important;
    opacity: 0 !important;
    max-height: 0 !important;
}
/* Reveal extra filtered links on hover */
.expanding-row.row-standard-filter:hover .comp-link.filter-show:nth-of-type(n+6) {
    visibility: visible !important;
    opacity: 1 !important;
    max-height: 50px !important;
}
.comp-link.filter-hide {
    display: none !important;
}
/* --- 10. Height Control Classes --- */
/* Shrink for short lists (1-5 links) */
.row-collapsed-filter {
    max-height: none !important;
    /* Removed forced low min-height – now inherits strong 376px base */
}
/* Maintain Gold Standard for long lists (6+ links) */
.row-standard-filter {
    max-height: 376px !important;
    min-height: 376px !important;
}
/* Global hover priority */
.expanding-row.row-standard-filter:hover,
.expanding-row.row-collapsed-filter:hover {
    max-height: 1200px !important;
}
/* --- 11. Global Link Styling --- */
.comp-link {
    text-decoration: none !important;
    display: inline-block;
    margin-bottom: 12px !important;
    line-height: 1.6 !important;
}
.expanding-row:not(:hover) .comp-link {
    color: #000000 !important;
}
/* --- 12. Badges & Extras --- */
.popular-badge,
.female-composer-badge,
.best-seller-badge {
    color: white !important;
    font-size: 11px !important;
    padding: 3px 10px !important;
    border-radius: 12px !important;
    margin-left: 8px !important;
    vertical-align: middle !important;
    display: inline-block !important;
    white-space: nowrap !important;
    font-weight: 500 !important; /* Numeric weight for more control */
    text-transform: uppercase !important;
}

.popular-badge { background-color: #2e82bc !important; }
.female-composer-badge { background-color: #f99e24 !important; }
.best-seller-badge { background-color: #5266dd !important; }

.text-silver-gray,
.text-silver-gray p,
.text-silver-gray span {
    color: #A9A9B2 !important;
    -webkit-text-fill-color: #A9A9B2 !important;
}






/* --- START UNIFORM LINK SPACING --- */


/* --- START - DELETE THIS CODE IN BETWEEN "START AND END" AFTER LAST BR IS REMOVED --- */
/* 1) Hide the breaks so they don't take up any space */
.links-container br {
    display: none;
}
/* --- END - DELETE AFTER LAST BR IS REMOVE --- */


/* 2) Make links stack perfectly and add uniform spacing */
.links-container a {
    display: block;      /* Makes each link start on a new line */
    text-align: left;    /* Ensures they stay left-aligned */
    margin-bottom: 8px;  /* This creates the uniform vertical gap */
    width: fit-content;  /* Prevents the link from stretching the full width */
}

/* 3) Fix for the "Popular" badge so it doesn't jump around */
.popular-badge {
    display: inline-block;
    vertical-align: middle;
    margin-left: 8px;
}

/* --- END UNIFORM LINK SPACING --- */







/* --- 13. Mobile Responsiveness --- */
@media (max-width: 768px) {
    /* Force the main container to grow to fit every link */
    .expanding-row, 
    .expanding-row.premium-row,
    .expanding-row.row-standard-filter,
    .expanding-row.row-collapsed-filter {
        display: flex !important;
        flex-direction: column !important;
        height: auto !important; /* Forces box to follow content length */
        min-height: 0 !important; 
        max-height: none !important; /* Removes the 376px limit */
        overflow: visible !important; /* Prevents clipping of link bottoms */
        position: relative !important;
        padding-right: 35px !important;
        padding-bottom: 50px !important; /* Extra room so the last link isn't on the edge */
        transition: none !important;
    }

    /* Force all links to stay inside the layout flow so the gray box sees them */
    .links-container .comp-link:nth-of-type(n+6),
    .row-standard-filter .comp-link.filter-show:nth-of-type(n+6) {
        visibility: visible !important;
        opacity: 1 !important;
        max-height: none !important;
        display: block !important; /* Stacking them makes the container taller */
        position: relative !important;
    }

    /* Keep the badge pinned top-to-bottom of the now-taller box */
    .premium-badge-margin {
        position: absolute !important;
        top: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 30px !important;
        height: 100% !important;
        flex: none !important;
        order: unset !important;
        z-index: 5 !important;
    }

    .row-thumb-container {
        width: 171px !important;
        margin: 20px 0 10px 15px !important;
        flex-shrink: 0 !important;
    }

    .row-content {
        width: 100% !important;
        padding: 0 15px 10px 15px !important;
        box-sizing: border-box !important;
        display: block !important;
        height: auto !important;
    }

    .row-content h2 {
        font-size: 1.5rem !important;
    }

    .more-indicator { 
        display: none !important; 
    }
}