#left-area:has(.csm-cart) {
    width: 100% !important;
    float: none !important;
    padding-right: 0 !important;
}

#left-area:has(.csm-cart) + #sidebar {
    display: none !important;
}

.container:has(.csm-cart)::before {
    display: none !important;
}

.container:has(.csm-cart) .et_pb_row {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.et_pb_section:has(.csm-cart),
.et_pb_row:has(.csm-cart),
.et_pb_column:has(.csm-cart) {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.csm-cart {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 16px 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.csm-cart-empty {
    text-align: center;
    padding: 80px 20px;
}

.csm-cart-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.csm-cart-empty h2 {
    font-size: 24px;
    color: #1f2937;
    margin: 0 0 8px;
}

.csm-cart-empty p {
    font-size: 15px;
    color: #6b7280;
    margin: 0 0 24px;
}

.csm-cart-browse-btn {
    display: inline-block;
    padding: 14px 32px;
    background: linear-gradient(135deg, #6b1d2a 0%, #8b2d3a 50%, #a33d4a 100%);
    color: #fff !important;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none !important;
    transition: opacity 0.2s;
}

.csm-cart-browse-btn:hover {
    opacity: 0.9;
}

.csm-cart-card {
    display: flex;
    gap: 20px;
    background: #fff;
    border: 1px solid #e5e1da;
    border-radius: 14px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    transition: box-shadow 0.2s;
}

.csm-cart-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.csm-cart-card-media {
    flex: 0 0 200px;
    position: relative;
}

.csm-cart-media-frame {
    position: relative;
    width: 200px;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 10px;
    touch-action: pan-y;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.csm-cart-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    -webkit-user-drag: none;
    user-select: none;
    will-change: transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    display: block;
}

@keyframes csmShimmer {
    0%   { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
@keyframes csmPulseOpacity {
    0%, 100% { opacity: 0.45; transform: scale(1); }
    50%      { opacity: 1; transform: scale(1.15); }
}

.csm-song-placeholder {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    margin-top: 4px;
    font-size: 12px;
    color: #8b5a36;
    font-style: italic;
    position: relative;
    overflow: hidden;
    background: linear-gradient(90deg,
        rgba(139, 90, 54, 0.05) 0%,
        rgba(139, 90, 54, 0.15) 50%,
        rgba(139, 90, 54, 0.05) 100%);
    background-size: 200% 100%;
    animation: csmShimmer 1.8s linear infinite;
}
.csm-song-placeholder-note {
    display: inline-block;
    font-size: 16px;
    animation: csmPulseOpacity 1.4s ease-in-out infinite;
}

.csm-candidate-dots {
    display: flex;
    gap: 5px;
    align-items: center;
    margin-top: 8px;
    padding: 2px 0;
    font-size: 10px;
    color: #9ca3af;
}
.csm-candidate-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #d4c4b0;
    transition: background 0.3s ease, transform 0.3s ease;
}
.csm-candidate-dot.ready {
    background: #8b5a36;
}
.csm-candidate-dot.loading {
    background: #c4a478;
    animation: csmPulseOpacity 1.4s ease-in-out infinite;
}
.csm-candidate-label {
    margin-left: 4px;
    font-style: italic;
    opacity: 0.8;
}

.csm-cart-media-heart-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 96px;
    height: 96px;
    margin: -48px 0 0 -48px;
    transform: scale(0.2);
    pointer-events: none;
    opacity: 0;
    z-index: 3;
    color: #fff;
    filter: drop-shadow(0 6px 20px rgba(107, 29, 42, 0.45)) drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35));
}
.csm-cart-media-heart-overlay svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
    display: block;
}
.csm-cart-media-heart-overlay.csm-heart-burst {
    animation: csmHeartBurst 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes csmHeartBurst {
    0%   { opacity: 0; transform: scale(0.2) rotate(-8deg); color: #fff; }
    12%  { opacity: 1; transform: scale(1.4) rotate(2deg); color: #fff; }
    30%  { opacity: 1; transform: scale(1.0) rotate(0deg); color: #ff3b5c; }
    45%  { opacity: 1; transform: scale(1.18) rotate(-1deg); color: #ff3b5c; }
    60%  { opacity: 1; transform: scale(1.08) rotate(0deg); color: #ff3b5c; }
    85%  { opacity: 0.8; transform: scale(1.22); color: #ff3b5c; }
    100% { opacity: 0; transform: scale(1.5); color: #ff3b5c; }
}

.csm-media-favorited-flash .csm-cart-card-img {
    box-shadow: 0 0 0 3px rgba(255, 77, 109, 0.6), 0 0 24px rgba(255, 77, 109, 0.35);
    transition: box-shadow 0.2s ease;
}

.csm-cart-card-swatch {
    width: 100%;
    height: 100%;
    border-radius: 10px;
    box-shadow: inset 0 -4px 8px rgba(0,0,0,0.12), inset 0 4px 8px rgba(255,255,255,0.15);
}

.csm-cart-media-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
}

.csm-media-btn {
    background: #f3f0ec;
    border: 1px solid #d1c4b0;
    color: #6b4226;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 8px;
    transition: all 0.15s;
    line-height: 1;
}

.csm-media-btn:hover {
    background: #6b4226;
    color: #fff;
    border-color: #6b4226;
}

.csm-media-btn.generating {
    opacity: 0.5;
    pointer-events: none;
}

.csm-img-counter {
    font-size: 11px;
    color: #9ca3af;
    min-width: 24px;
    text-align: center;
}

.csm-music-generate {
    width: 100%;
    padding: 8px 12px !important;
    margin-top: 6px;
    font-size: 13px !important;
    text-align: center;
}

.csm-video-download {
    display: block;
    width: 100%;
    padding: 8px 12px !important;
    margin-top: 6px;
    font-size: 13px !important;
    text-align: center;
    text-decoration: none;
    background: linear-gradient(135deg, #6b4226, #8b5a36);
    color: #fff !important;
    border-color: #6b4226;
}

.csm-video-download:hover {
    background: linear-gradient(135deg, #5a3620, #7a4d2e);
    color: #fff !important;
    transform: translateY(-1px);
}

.csm-hidden {
    display: none !important;
}


.csm-song-list {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.csm-song-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    background: #f9f7f5;
    border: 1px solid transparent;
    transition: all 0.15s;
}

.csm-song-item:hover {
    background: #f3f0ec;
    border-color: #e5e1da;
}

.csm-song-item.active {
    background: #f3f0ec;
    border-color: #d4c4b0;
}

.csm-song-info {
    flex: 1;
    min-width: 0;
}

.csm-song-name {
    display: block;
    color: #374151;
    font-size: 13px;
    font-weight: 500;
}

.csm-song-item.active .csm-song-name {
    color: #6b4226;
    font-weight: 600;
}

.csm-song-style {
    display: block;
    color: #9ca3af;
    font-size: 11px;
    font-style: italic;
    margin-top: 1px;
}

.csm-song-play {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #6b4226;
    border: none;
    color: #fff;
    font-size: 11px;
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.15s;
    flex-shrink: 0;
}

.csm-song-play:hover {
    background: #8b5e3c;
}

.csm-cart-card-body {
    flex: 1;
    min-width: 0;
}

.csm-cart-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 4px;
}

.csm-cart-card-name-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    flex: 1;
}

.csm-cart-card-name {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.csm-cart-cycle-btn {
    background: none;
    border: none;
    color: #c4bdb4;
    font-size: 18px;
    cursor: pointer;
    padding: 0 2px;
    flex-shrink: 0;
    transition: color 0.15s, transform 0.3s;
    line-height: 1;
}

.csm-cart-cycle-btn:hover {
    color: #6b4226;
}

.csm-cart-cycle-btn.spinning {
    transform: rotate(360deg);
}

.csm-cart-rename-btn {
    background: none;
    border: none;
    color: #c4bdb4;
    font-size: 14px;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    transition: color 0.15s;
}

.csm-cart-rename-btn:hover {
    color: #6b4226;
}

.csm-cart-rename-input {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    border: 1px solid #d4c4b0;
    border-radius: 6px;
    padding: 4px 8px;
    width: 100%;
    outline: none;
}

.csm-cart-rename-input:focus {
    border-color: #6b4226;
    box-shadow: 0 0 0 2px rgba(107,66,38,0.15);
}

.csm-cart-card-price {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
    white-space: nowrap;
    flex-shrink: 0;
}

.csm-cart-card-meta {
    font-size: 14px;
    color: #8b7355;
    font-weight: 500;
    margin-bottom: 10px;
}

.csm-cart-card-recipe {
    margin-bottom: 10px;
}

.csm-cart-recipe-row {
    padding: 2px 0;
    font-size: 14px;
}

.csm-cart-pct {
    display: inline-block;
    min-width: 34px;
    color: #8b6f47;
    font-weight: 600;
}

.csm-cart-ing {
    color: #374151;
    font-weight: 500;
}

.csm-cart-card-notes {
    font-style: italic;
    color: #7a6a5a;
    font-size: 14px;
    line-height: 1.65;
    border-left: 3px solid #d4c4b0;
    padding: 10px 14px;
    margin: 10px 0;
    background: #faf8f5;
    border-radius: 0 8px 8px 0;
}

.csm-cart-signature-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: #fff;
    background: linear-gradient(135deg, #8b5a36, #6b1d2a);
    padding: 3px 10px 3px 9px;
    border-radius: 999px;
    margin-left: 10px;
    vertical-align: middle;
    box-shadow: 0 1px 3px rgba(107, 29, 42, 0.25);
    white-space: nowrap;
}
.csm-cart-signature-note {
    margin: 2px 0 8px 0;
    padding: 6px 10px;
    font-size: 11px;
    color: #6b5344;
    font-style: italic;
    line-height: 1.5;
    background: transparent;
    border-left: 2px solid #d4c4b0;
}
.csm-cart-signature-note em {
    font-style: italic;
}

.csm-cart-lineage {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin: 2px 0 8px 0;
    padding: 6px 10px;
    background: linear-gradient(135deg, rgba(139, 90, 54, 0.07), rgba(107, 29, 42, 0.07));
    border-left: 2px solid #8b5a36;
    border-radius: 0 6px 6px 0;
    font-size: 11px;
    color: #6b5344;
    font-style: italic;
    line-height: 1.45;
}
.csm-cart-lineage-arrow {
    color: #8b5a36;
    font-size: 14px;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 1px;
}
.csm-cart-lineage-text strong {
    color: #6b1d2a;
    font-style: normal;
    font-weight: 700;
    letter-spacing: 0.4px;
}

.csm-cart-card-bars {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 10px 0 6px 0;
}
.csm-cart-bar-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr) auto;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}
.csm-cart-bar-name {
    color: #5c4232;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.csm-cart-bar-track {
    height: 9px;
    background: #f3ebe0;
    border-radius: 999px;
    overflow: hidden;
    box-shadow: inset 0 1px 2px rgba(107, 66, 38, 0.1);
}
.csm-cart-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #8b5a36, #6b1d2a);
    border-radius: 999px;
    transition: width 0.4s ease;
}
.csm-cart-bar-pct {
    color: #6b1d2a;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    min-width: 34px;
    text-align: right;
    font-size: 12px;
}
.csm-cart-bar-notes {
    font-size: 10px;
    color: #9ca3af;
    font-style: italic;
    line-height: 1.3;
    margin: -2px 0 4px 0;
    padding-left: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.csm-cart-bar-origin {
    font-style: normal;
    color: #7a6a5a;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-size: 9px;
    margin-right: 2px;
}
.csm-cart-card-profile {
    font-size: 13px;
    font-style: italic;
    color: #6b5344;
    line-height: 1.5;
    margin: 6px 0 10px 0;
    padding: 10px 12px;
    background: #faf8f5;
    border-left: 2px solid #d4c4b0;
    border-radius: 0 6px 6px 0;
}
.csm-cart-size-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 6px 0 10px 0;
    transition: opacity 0.2s;
}
.csm-cart-size-row.loading {
    opacity: 0.55;
    pointer-events: none;
}
.csm-cart-size-btn {
    flex: 1 1 auto;
    background: #fff;
    color: #5c4232;
    border: 1px solid #d4c4b0;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.12s;
    min-width: 0;
    font-family: inherit;
}
.csm-cart-size-btn:hover:not(.active) {
    border-color: #8b5a36;
    background: #faf8f5;
}
.csm-cart-size-btn.active {
    background: linear-gradient(135deg, #6b1d2a, #a33d4a);
    border-color: #6b1d2a;
    color: #fff;
}

.csm-cart-card-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.csm-cart-spacer {
    flex: 1;
}

.csm-cart-btn {
    display: inline-block;
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 16px;
    text-decoration: none !important;
    cursor: pointer;
    transition: all 0.15s;
}

.csm-cart-btn-edit {
    color: #5C3D2E !important;
    background: #F5F0EB;
    border: 1px solid #D4C5B2;
}

.csm-cart-btn-edit:hover {
    background: #5C3D2E;
    color: #fff !important;
    border-color: #5C3D2E;
}

.csm-cart-btn-share {
    background: none;
    border: none;
    color: #c4bdb4;
    font-size: 12px;
    font-family: ui-monospace, monospace;
    letter-spacing: 0.5px;
    cursor: pointer;
    padding: 0;
    transition: color 0.15s;
}

.csm-cart-btn-share:hover {
    color: #8b7355;
}

.csm-cart-btn-share.copied {
    color: #16a34a;
}

.csm-cart-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    overflow: hidden;
}

.csm-cart-qty-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: #f9fafb;
    color: #374151;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.csm-cart-qty-btn:hover {
    background: #e5e7eb;
}

.csm-cart-qty-val {
    min-width: 36px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
}

.csm-cart-btn-remove {
    background: none;
    border: none;
    color: #9ca3af;
    font-size: 13px;
    cursor: pointer;
    padding: 6px 8px;
    transition: color 0.15s;
}

.csm-cart-btn-remove:hover {
    color: #ef4444;
}

.csm-cart-btn-remove.confirming {
    color: #ef4444;
    font-weight: 600;
}

.csm-cart-card.removing {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s, transform 0.3s;
}

.csm-cart-regular {
    margin-bottom: 16px;
}

.csm-cart-regular-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: #fff;
    border: 1px solid #e5e1da;
    border-radius: 10px;
    margin-bottom: 10px;
}

.csm-cart-regular-img img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
}

.csm-cart-regular-info {
    flex: 1;
    min-width: 0;
}

.csm-cart-regular-name {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937 !important;
    text-decoration: none !important;
    margin-bottom: 2px;
}

.csm-cart-regular-price {
    font-size: 14px;
    color: #6b7280;
}

.csm-cart-totals {
    margin-top: 24px;
    background: #fff;
    border: 1px solid #e5e1da;
    border-radius: 14px;
    padding: 24px;
}

.csm-totals-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 15px;
    color: #374151;
}

.csm-totals-row.csm-totals-total {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
    border-top: 2px solid #e5e1da;
    margin-top: 8px;
    padding-top: 16px;
}

.csm-totals-coupon {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: #16a34a;
}

.csm-totals-coupon-remove {
    background: none;
    border: none;
    color: #ef4444;
    font-size: 12px;
    cursor: pointer;
    padding: 0;
}

.csm-coupon-form {
    display: flex;
    gap: 8px;
    margin: 16px 0;
}

.csm-coupon-input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
}

.csm-coupon-input:focus {
    border-color: #6b4226;
}

.csm-coupon-apply {
    padding: 10px 20px;
    background: #f3f0ec;
    color: #6b4226;
    border: 1px solid #d1c4b0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.csm-coupon-apply:hover {
    background: #6b4226;
    color: #fff;
    border-color: #6b4226;
}

.csm-cart-checkout-btn {
    display: block;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #6b1d2a 0%, #8b2d3a 50%, #a33d4a 100%);
    color: #fff !important;
    border: none;
    border-radius: 10px;
    font-size: 17px;
    font-weight: 600;
    text-align: center;
    text-decoration: none !important;
    cursor: pointer;
    transition: opacity 0.2s;
    margin-top: 8px;
}

.csm-cart-checkout-btn:hover {
    opacity: 0.9;
}

.csm-cart-notice {
    padding: 10px 16px;
    border-radius: 8px;
    margin-bottom: 12px;
    font-size: 14px;
}

.csm-cart-notice-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.csm-cart-notice-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

@media (max-width: 640px) {
    .csm-cart {
        padding: 0 12px 40px;
    }

    .csm-cart-card {
        flex-direction: column;
        gap: 12px;
        padding: 16px;
    }

    .csm-cart-card-media {
        flex: none;
        width: 100%;
    }

    .csm-cart-media-frame {
        width: 100%;
        max-width: none;
    }

    .csm-cart-card-header {
        flex-wrap: wrap;
    }

    .csm-cart-card-name {
        font-size: 16px;
    }

    .csm-cart-card-price {
        font-size: 18px;
    }

    .csm-cart-card-actions {
        gap: 8px;
    }

    .csm-cart-spacer {
        display: none;
    }

    .csm-cart-card-actions {
        justify-content: space-between;
    }
}

.csm-cart-card-price.has-discounts {
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}
.csm-cart-card-price .csm-cart-strike {
    font-size: 0.82em;
    font-weight: 400;
    color: #9a8b7a;
    text-decoration: line-through;
    margin-right: 6px;
}

.csm-tape {
    display: none;
    margin-top: 8px;
    padding: 8px 10px;
    background: #faf8f5;
    border-left: 2px solid #d4c4a8;
    font-family: "SF Mono", "Cascadia Mono", "Menlo", "Consolas", monospace;
    font-size: 11px;
    line-height: 1;
    color: #6b5c4a;
}
.csm-tape.open {
    display: block;
}
.csm-tape-line {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
}
.csm-tape-line + .csm-tape-line {
    border-top: 1px dotted #e0d5c4;
}
.csm-tape-discount span:last-child {
    color: #8b5e3c;
}
.csm-tape-total {
    font-weight: 700;
    color: #3d2e1e;
    border-top: 1px solid #c4b49a !important;
    margin-top: 2px;
    padding-top: 5px;
}

.csm-cart-media-frame {
    cursor: pointer;
}
.csm-cart-media-badge {
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(0,0,0,0.55);
    color: #fff;
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 4px;
    pointer-events: none;
    font-weight: 500;
    letter-spacing: 0.3px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.csm-artwork-modal { position: fixed; inset: 0; z-index: 99999; display: flex; align-items: flex-end; justify-content: center; }
.csm-artwork-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.csm-artwork-sheet {
    position: relative;
    z-index: 1;
    background: #fff;
    border-radius: 16px 16px 0 0;
    width: 100%;
    max-width: 560px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 0 0 20px;
    box-shadow: 0 -4px 30px rgba(0,0,0,0.15);
    animation: csmSheetUp 0.3s ease-out;
}
@keyframes csmSheetUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}
.csm-artwork-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px 12px;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    background: #fff;
    border-radius: 16px 16px 0 0;
    z-index: 1;
}
.csm-artwork-title {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
}
.csm-artwork-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
    padding: 0 4px;
    line-height: 1;
}
.csm-artwork-close:hover { color: #333; }
.csm-artwork-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    padding: 16px 20px;
}
@media (max-width: 480px) {
    .csm-artwork-grid { grid-template-columns: repeat(2, 1fr); }
    .csm-artwork-sheet { max-width: 100%; max-height: 85vh; }
}
.csm-artwork-thumb {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.15s;
}
.csm-artwork-thumb.selected {
    border-color: #5c4a32;
}
.csm-artwork-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.csm-artwork-focus {
    padding: 20px;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.csm-focus-image-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.csm-artwork-focus img {
    width: 100%;
    border-radius: 10px;
    display: block;
    max-height: 50vh;
    object-fit: contain;
    background: #f5f0ea;
    transition: opacity 0.15s ease;
    user-select: none;
    -webkit-user-select: none;
}
.csm-focus-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.85);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 22px;
    line-height: 1;
    color: #5c4a32;
    cursor: pointer;
    box-shadow: 0 1px 6px rgba(0,0,0,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: background 0.15s;
}
.csm-focus-arrow:hover { background: #fff; }
.csm-focus-prev { left: 8px; }
.csm-focus-next { right: 8px; }
.csm-focus-counter {
    text-align: center;
    font-size: 12px;
    color: #9a8b7a;
    margin-top: 8px;
    letter-spacing: 1px;
}
.csm-artwork-focus-actions {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}
.csm-focus-btn {
    flex: 1;
    padding: 10px 0;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, opacity 0.15s;
}
.csm-focus-use {
    background: #5c4a32;
    color: #fff;
}
.csm-focus-use:hover:not(:disabled) { background: #4a3a26; }
.csm-focus-use:disabled { opacity: 0.5; cursor: default; }
.csm-focus-remove {
    background: #f5f0ea;
    color: #8b5e3c;
}
.csm-focus-remove:hover { background: #ebe3d6; }
.csm-focus-remove.confirm {
    background: #c83030;
    color: #fff;
}
.csm-focus-close {
    background: #f5f0ea;
    color: #6b5c4a;
}
.csm-focus-close:hover { background: #ebe3d6; }

.csm-song-summary {
    padding: 6px 0 0;
    font-size: 12px;
    color: #8b7355;
    max-width: 200px;
    overflow: hidden;
}
.csm-song-summary-item {
    padding: 5px 0;
    max-width: 100%;
    overflow: hidden;
}
.csm-song-summary-top {
    display: flex;
    align-items: center;
    gap: 5px;
}
.csm-song-sep {
    border-top: 1px dotted #e0d5c4;
}
.csm-song-summary-vibes {
    display: flex;
    gap: 2px;
    padding: 3px 0 0 25px;
}
.csm-vibe-mini {
    border: none;
    background: none;
    padding: 0 4px;
    font-size: 14px;
    cursor: pointer;
    opacity: 0.35;
    transition: opacity 0.15s, transform 0.1s;
    display: flex;
    align-items: center;
    gap: 2px;
    color: #8b7355;
    line-height: 1;
}
.csm-vibe-mini:hover { opacity: 0.7; }
.csm-vibe-mini.active { opacity: 1; }
.csm-vibe-mini:active { transform: scale(0.88); }
.csm-vibe-mini-count {
    font-size: 9px;
    color: #9a8b7a;
}
.csm-vibe-crown.active {
    opacity: 1;
    filter: drop-shadow(0 0 2px rgba(180, 140, 60, 0.5));
}
.csm-song-summary-item.is-main {
    background: #faf8f5;
    border-radius: 6px;
    padding-left: 4px;
    padding-right: 4px;
    margin: 0 -4px;
}
.csm-song-summary-play {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: none;
    background: #5c4a32;
    color: #fff;
    font-size: 9px;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.csm-song-summary-play:hover { background: #4a3a26; }
.csm-song-summary-play.playing { background: #c7572a; }
.csm-song-summary-style {
    flex: 1;
    min-width: 0;
    font-size: 11px;
    font-style: italic;
    color: #8b7355;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.csm-song-summary-manage {
    display: block;
    text-align: center;
    font-size: 10px;
    color: #9a8b7a;
    cursor: pointer;
    padding: 4px 0 2px;
    opacity: 0.5;
    transition: opacity 0.15s;
}
.csm-song-summary:hover .csm-song-summary-manage { opacity: 1; }
@media (hover: none) { .csm-song-summary-manage { opacity: 0.7; } }

.csm-song-drawer-list {
    padding: 8px 20px;
}
.csm-song-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #f0ebe4;
    cursor: pointer;
    transition: background 0.1s;
}
.csm-song-row:last-child { border-bottom: none; }
.csm-song-row:hover { background: rgba(0,0,0,0.02); }
.csm-song-row.is-main { background: #faf8f5; }
.csm-song-row-play {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #5c4a32;
    color: #fff;
    font-size: 12px;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}
.csm-song-row-play:hover { background: #4a3a26; }
.csm-song-row-play.playing { background: #c7572a; }
.csm-song-row-info {
    flex: 1;
    min-width: 0;
}
.csm-song-row-style {
    font-size: 13px;
    font-weight: 500;
    color: #5c4a32;
    font-style: italic;
}
.csm-song-row-main {
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #5c4a32;
    font-weight: 700;
    background: #f0ebe4;
    padding: 2px 6px;
    border-radius: 3px;
}
.csm-song-row-vibes {
    display: flex;
    gap: 4px;
    margin-top: 4px;
}
.csm-vibe-btn {
    border: none;
    background: #f5f0ea;
    border-radius: 12px;
    padding: 2px 8px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
    display: flex;
    align-items: center;
    gap: 3px;
    color: #8b7355;
}
.csm-vibe-btn:hover { background: #ebe3d6; }
.csm-vibe-btn.active { background: #5c4a32; color: #fff; }
.csm-vibe-btn:active { transform: scale(0.92); }
.csm-vibe-count { font-size: 10px; }

.csm-song-row-actions {
    display: none;
    flex-direction: column;
    gap: 6px;
    padding: 8px 0 4px 42px;
    border-bottom: 1px solid #f0ebe4;
}
.csm-song-row-actions.open { display: flex; }
.csm-song-row-actions .csm-focus-btn {
    padding: 8px;
    font-size: 12px;
}

.csm-song-composing {
    animation: csmBreathe 2.4s ease-in-out infinite;
    pointer-events: none;
    opacity: 0.7;
}

.csm-song-drawer-generate {
    width: 100%;
    padding: 10px;
    background: #f5f0ea;
    border: 1px dashed #c4b49a;
    border-radius: 8px;
    color: #5c4a32;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}
.csm-song-drawer-generate:hover { background: #ebe3d6; }
.csm-song-drawer-generate:disabled { opacity: 0.5; cursor: wait; }
.csm-artwork-thumb.generating {
    background: linear-gradient(135deg, #f5f0ea 0%, #ebe3d6 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    animation: csmBreathe 2.4s ease-in-out infinite;
}
.csm-artwork-thumb.generating::before {
    content: '';
    width: 28px;
    height: 28px;
    border: 2px solid #c4b49a;
    border-top-color: transparent;
    border-radius: 50%;
    animation: csmSpin 0.8s linear infinite;
}
.csm-artwork-thumb.generating::after {
    content: 'creating...';
    font-size: 10px;
    color: #9a8b7a;
    letter-spacing: 0.3px;
}
@keyframes csmSpin { to { transform: rotate(360deg); } }
@keyframes csmBreathe {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}
@media (prefers-reduced-motion: reduce) {
    .csm-artwork-thumb.generating { animation: none; }
}
.csm-artwork-actions {
    padding: 0 20px;
}
.csm-artwork-generate {
    width: 100%;
    padding: 10px;
    background: #f5f0ea;
    border: 1px dashed #c4b49a;
    border-radius: 8px;
    color: #5c4a32;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}
.csm-artwork-generate:hover { background: #ebe3d6; }
.csm-artwork-generate:disabled { opacity: 0.5; cursor: wait; }
