/* WMDM_PackPreview — loaded explicitly via layout <css/> because WMDM/cubase
   does not load Magento's compiled styles-m/l (custom CSS set only).
   Self-contained brand palette (measured from the cubase theme): white card,
   #111 text, teal accent gradient #00b8d4->#00838f, soft glow shadow.
   Hard-coded on purpose so the card looks identical on light AND dark
   storefronts — no inherited-color surprises. */

.wmdm-pack-preview {
    max-width: 1400px;      /* match the theme content column */
    margin: 40px auto;
    padding: 24px 28px;
    border: 1px solid #ececf1;
    border-radius: 14px;
    background: #fff;
    color: #111;
    box-shadow: 0 4px 24px rgba(197, 3, 43, .06), 0 2px 8px rgba(0, 0, 0, .05);
}

.wmdm-pack-preview .wmdm-pp-heading {
    margin: 0 0 4px;
    font-size: 22px;
    font-weight: 700;
}

.wmdm-pack-preview .wmdm-pp-counts-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.wmdm-pack-preview .wmdm-pp-counts {
    color: rgba(17, 17, 17, .6);
    font-size: 13px;
}

/* format filter dropdown — right-aligned on the counts line */
.wmdm-pack-preview .wmdm-pp-filter {
    flex: 0 0 auto;
    padding: 4px 10px;
    border: 1px solid #eceff1;
    border-radius: 8px;
    font-size: 12px;
    color: #111;
    background: #fff;
}

.wmdm-pack-preview .wmdm-pp-list {
    max-height: 480px;
    overflow-y: auto;
    border: 1px solid #eceff1;
    border-radius: 10px;
    background: #fff;
}

/* sticky sortable header row — teal-tinted, readable while rows scroll under */
.wmdm-pack-preview .wmdm-pp-head {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 14px;
    border-bottom: 1px solid rgba(0, 184, 212, .25);
    background: #f2fafc;
}

.wmdm-pack-preview .wmdm-pp-col {
    display: block;
    padding: 0;
    border: 0;
    background: transparent;
    color: rgba(17, 17, 17, .55);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    cursor: pointer;
}

.wmdm-pack-preview .wmdm-pp-col:hover {
    color: #00838f;
}

.wmdm-pack-preview .wmdm-pp-col.active {
    color: #00838f;
}

.wmdm-pack-preview .wmdm-pp-sort {
    font-size: 9px;
    margin-left: 3px;
}

/* shared column template — header cells and row cells use the same spans */
.wmdm-pack-preview .wmdm-pp-cell-name {
    flex: 0 0 320px;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
}

.wmdm-pack-preview .wmdm-pp-head .wmdm-pp-cell-name {
    gap: 3px;
}

/* inline per-row mini waveform — sits between Name and Key; draws in currentColor (teal).
   Present (possibly empty) on every row/header cell so the Key/BPM/Type/Length columns
   stay aligned whether or not that row shipped a "pk" peak array. */
.wmdm-pack-preview .wmdm-pp-cell-wave {
    flex: 1 1 auto;
    min-width: 0;
    padding: 0 6px;
    color: #00838f;
}

.wmdm-pack-preview .wmdm-pp-cell-wave canvas {
    display: block;
    width: 100%;
    height: 26px;
    cursor: pointer;
}

@media (max-width: 1100px) {
    .wmdm-pack-preview .wmdm-pp-cell-name {
        flex-basis: 240px;
    }
}

@media (max-width: 900px) {
    .wmdm-pack-preview .wmdm-pp-cell-wave {
        display: none;
    }

    .wmdm-pack-preview .wmdm-pp-cell-name {
        flex: 1 1 auto;
    }
}

.wmdm-pack-preview .wmdm-pp-cell-key,
.wmdm-pack-preview .wmdm-pp-cell-bpm,
.wmdm-pack-preview .wmdm-pp-cell-type {
    flex: 0 0 56px;
}

.wmdm-pack-preview .wmdm-pp-cell-key,
.wmdm-pack-preview .wmdm-pp-cell-type {
    text-align: left;
}

.wmdm-pack-preview .wmdm-pp-cell-bpm {
    text-align: right;
}

.wmdm-pack-preview .wmdm-pp-cell-length {
    flex: 0 0 64px;
    text-align: right;
}

.wmdm-pack-preview .wmdm-pp-group {
    padding: 12px 14px 4px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #00838f;
}

.wmdm-pack-preview .wmdm-pp-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 14px;
    border-bottom: 1px solid #f5f6f8;
}

.wmdm-pack-preview .wmdm-pp-row:hover {
    background: rgba(0, 184, 212, .06);
}

.wmdm-pack-preview .wmdm-pp-row.wmdm-pp-static {
    opacity: .6;
}

.wmdm-pack-preview .wmdm-pp-row .wmdm-pp-cell-key,
.wmdm-pack-preview .wmdm-pp-row .wmdm-pp-cell-bpm,
.wmdm-pack-preview .wmdm-pp-row .wmdm-pp-cell-type,
.wmdm-pack-preview .wmdm-pp-row .wmdm-pp-cell-length {
    font-size: 12px;
    color: rgba(17, 17, 17, .55);
    white-space: nowrap;
}

/* brand play button: teal gradient circle, white glyph */
.wmdm-pack-preview .wmdm-pp-play {
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #00b8d4, #00838f);
    color: #fff;
    line-height: 0;
    cursor: pointer;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 131, 143, .3);
}

.wmdm-pack-preview .wmdm-pp-play:hover {
    background: linear-gradient(135deg, #14c4de, #00969f);
}

.wmdm-pack-preview .wmdm-pp-play::before {
    content: '';
    position: absolute;
    left: 11px;
    top: 8px;
    border-style: solid;
    border-width: 7px 0 7px 11px;
    border-color: transparent transparent transparent currentColor;
}

.wmdm-pack-preview .wmdm-pp-play.playing::before {
    left: 9px;
    top: 8px;
    width: 4px;
    height: 14px;
    border: 0;
    border-left: 4px solid currentColor;
    border-right: 4px solid currentColor;
}

.wmdm-pack-preview .wmdm-pp-namecol {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.wmdm-pack-preview .wmdm-pp-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
}

/* vocal transcript as a full-width readable box below the stem row */
.wmdm-pack-preview .wmdm-pp-row.wmdm-pp-has-lyric {
    flex-wrap: wrap;
}
.wmdm-pack-preview .wmdm-pp-lyric-box {
    flex: 0 0 100%;
    width: 100%;
    max-width: 760px;
    box-sizing: border-box;
    margin: 8px 0 4px 46px;
    padding: 10px 14px;
    background: rgba(0, 184, 212, .06);
    border-left: 3px solid #00b8d4;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.65;
    color: rgba(17, 17, 17, .82);
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    max-height: 168px;
    overflow-y: auto;
}
.wmdm-pack-preview .wmdm-pp-lyric-mark {
    color: #00b8d4;
    margin-right: 7px;
    font-style: normal;
}
.wmdm-pack-preview .wmdm-pp-lyric-text {
    font-style: italic;
}
@media (max-width: 640px) {
    .wmdm-pack-preview .wmdm-pp-lyric-box { margin-left: 0; }
}

/* "N stems from this track" note under the heading on a stems product */
.wmdm-pack-preview .wmdm-pp-stemnote {
    margin: -2px 0 12px;
    font-size: 13px;
    font-weight: 600;
    color: #00838f;
}

.wmdm-pack-preview .wmdm-pp-more {
    padding: 10px 14px;
    font-size: 13px;
    color: rgba(17, 17, 17, .6);
    font-style: italic;
}

/* SSR-only plain name list (whats-inside.phtml, data-ssr="1") — rendered server-side
   before pack-preview.js replaces it with the interactive grid on fetch success, and
   left in place if the JS enhancement fails (see abandonEnhancement() in the JS). */
.wmdm-pack-preview .wmdm-pp-ssr-list {
    list-style: none;
    margin: 0;
    padding: 4px 0 0;
}

.wmdm-pack-preview .wmdm-pp-ssr-list li {
    padding: 6px 4px;
    border-bottom: 1px solid #f5f6f8;
    font-size: 13px;
    color: #111;
}

.wmdm-pack-preview .wmdm-pp-ssr-list li:last-child {
    border-bottom: 0;
}

.wmdm-pack-preview .wmdm-pp-ssr-list li span {
    margin-left: 6px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .04em;
    color: rgba(17, 17, 17, .55);
}

@media (max-width: 640px) {
    .wmdm-pack-preview {
        padding: 16px;
        border-radius: 10px;
    }

    .wmdm-pack-preview .wmdm-pp-cell-key,
    .wmdm-pack-preview .wmdm-pp-cell-type {
        display: none;
    }
}
