/* Single download page – clean white layout matching homepage (SonicEngine).
   Extends .pd-wrapper from frontend.css for light theme. */

body:has(.pd-single-wrapper),
body.single-pd_item {
    font-family: 'Space Grotesk', sans-serif;
}

.pd-single-wrapper {
    padding: 0 0 3rem;
    width: 100%;
    max-width: none;
    overflow-x: visible;
    background: transparent;
}

.pd-single-container {
    width: 100%;
    margin: 0 auto;
    padding-top: 1.25rem;
}

.pd-single-wrapper *,
.pd-single-wrapper *::before,
.pd-single-wrapper *::after {
    box-sizing: border-box;
}

.pd-single-main {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

/* Quick stats strip */
.pd-single-quickstats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
    margin-bottom: 2rem;
    padding: 1rem 1.25rem;
    background: var(--card-dark);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
}

.pd-single-quickstat {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 0.875rem;
    background: rgba(37, 106, 244, 0.06);
    border: 1px solid rgba(37, 106, 244, 0.14);
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-light);
    line-height: 1.3;
}

.pd-single-quickstat .material-symbols-outlined {
    font-size: 1.125rem;
    color: var(--accent-blue, #256af4);
}

/* Content split — description left, media right on desktop */
.pd-single-split {
    display: grid;
    gap: 1.5rem;
    align-items: start;
}

.pd-single-split-main,
.pd-single-split-aside {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-width: 0;
}

.pd-single-media-panel .pd-single-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

/* Product details bento grid */
.pd-single-details-zone {
    width: 100%;
}

.pd-single-details-heading {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: clamp(1.375rem, 2vw, 1.625rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0 0 1.5rem;
    color: var(--text-light);
}

.pd-single-bento {
    display: grid;
    gap: 1.25rem;
    grid-template-columns: 1fr;
}

.pd-single-bento-tile {
    margin-bottom: 0;
    height: 100%;
}

.pd-single-bento .pd-single-section-title {
    font-size: 1.125rem;
    margin-bottom: 1rem;
}

.pd-single-bento .pd-single-card {
    padding: 1.25rem;
    height: 100%;
}

.pd-single-bento .pd-single-classification-grid,
.pd-single-bento .pd-single-compat-grid,
.pd-single-bento .pd-single-filedetails-grid {
    grid-template-columns: 1fr;
    gap: 0.625rem;
}

.pd-single-bento .pd-single-license-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pd-single-audio-featured {
    border-left: 3px solid var(--accent-blue, #256af4);
}

.pd-single-main > .pd-single-section {
    padding-top: 0;
    border-top: none;
}

.pd-single-main > .pd-single-section.pd-single-related-section,
.pd-single-main > .pd-single-section:last-child {
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

/* Unified hero panel */
.pd-single-hero-panel {
    background: var(--card-dark);
    border: 1px solid var(--border-color);
    border-radius: 1.25rem;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 40px rgba(15, 23, 42, 0.07);
    border-bottom: none;
}

/* Product hero — contained, theme-aware */
.pd-single-hero {
    position: relative;
    width: 100%;
    margin: 0;
    padding-bottom: 0;
    border-bottom: none;
    background: transparent;
    box-shadow: none;
}

.pd-single-hero-grid {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    align-items: stretch;
}

.pd-single-hero-left {
    flex-shrink: 0;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 0.875rem;
    padding: 0.75rem;
    box-shadow: none;
}

.pd-single-hero-thumb {
    position: relative;
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    aspect-ratio: 1 / 1;
    border-radius: 0.625rem;
    overflow: hidden;
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
}

.pd-single-hero-thumb-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.pd-single-hero-thumb-fallback {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    background: linear-gradient(145deg, #0f172a 0%, #1e293b 55%, #334155 100%);
}

.pd-single-hero-thumb-fallback .material-symbols-outlined {
    font-size: 5rem;
    opacity: 0.22;
    color: rgba(255, 255, 255, 0.9);
}

.pd-single-hero-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    border: none;
    cursor: pointer;
    color: white;
    text-decoration: none;
    transition: background 0.25s;
}

.pd-single-hero-play:hover {
    background: rgba(0, 0, 0, 0.5);
}

.pd-single-hero-play .material-symbols-outlined {
    font-size: 5rem;
}

.pd-single-hero-right {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    min-width: 0;
    justify-content: center;
}

.pd-single-hero-title {
    font-size: clamp(1.75rem, 2.5vw, 2.75rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 0;
    color: var(--text-light);
}

.pd-single-hero-price-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.pd-single-hero-price {
    font-size: clamp(1.375rem, 2vw, 2rem);
    font-weight: 700;
    color: var(--text-light);
    letter-spacing: -0.01em;
}

.pd-single-hero-price-free {
    color: var(--accent-purple);
}

.pd-single-hero-badge {
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: none;
    white-space: nowrap;
}

.pd-single-hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-top: 0.25rem;
}

.pd-single-hero-cta .pd-btn {
    min-height: 52px;
    padding: 0.9375rem 1.75rem;
    font-size: 1.0625rem;
}

.pd-single-hero-meta {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-top: 1.25rem;
    margin-top: 0.25rem;
    border-top: 1px solid var(--border-color);
}

.pd-single-hero-meta-row {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pd-single-hero-meta-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-muted);
}

.pd-single-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pd-single-pill {
    display: inline-block;
    padding: 0.35rem 0.875rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    font-weight: 600;
    background: var(--border-light);
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.2s;
}

.pd-single-pill:hover {
    background: var(--primary);
    color: white;
}

.pd-single-badge-premium {
    background: linear-gradient(135deg, var(--primary), #1e5dd4);
    color: white;
    box-shadow: 0 2px 8px rgba(37, 106, 244, 0.4);
}

.pd-single-badge-free {
    background: linear-gradient(135deg, var(--accent-purple), #6d28d9);
    color: white;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.4);
}

/* Card base - inherits from pd-wrapper */
.pd-single-card {
    background: var(--card-dark);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 0;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
}

/* Classification grid */
.pd-single-classification-grid,
.pd-single-compat-grid,
.pd-single-filedetails-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.pd-single-class-item,
.pd-single-compat-item,
.pd-single-filedetail-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--border-light);
    border-radius: 0.75rem;
}

.pd-single-class-item .material-symbols-outlined,
.pd-single-compat-item .material-symbols-outlined,
.pd-single-filedetail-item .material-symbols-outlined {
    font-size: 1.25rem;
    color: var(--primary);
    flex-shrink: 0;
}

.pd-single-class-label,
.pd-single-compat-label,
.pd-single-filedetail-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    font-weight: 600;
}

.pd-single-class-value,
.pd-single-compat-value,
.pd-single-filedetail-value {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-light);
}

.pd-single-class-item > span:not(.material-symbols-outlined),
.pd-single-compat-item > span:not(.material-symbols-outlined),
.pd-single-filedetail-item > span:not(.material-symbols-outlined) {
    display: block;
}

/* Creator profile card */
.pd-single-creator-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--border-light);
    border-radius: 1rem;
}

.pd-single-creator-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
}

.pd-single-creator-name {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-light);
}

.pd-single-creator-bio {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0;
    text-align: center;
}

/* YouTube embed */
.pd-single-youtube-wrap {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    margin-bottom: 1rem;
}

.pd-single-youtube-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border-radius: 0.75rem;
}

/* Buttons */
.pd-single-wrapper .pd-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    background: var(--primary);
    color: white;
    box-shadow: 0 10px 15px -3px rgba(37, 106, 244, 0.2);
    text-decoration: none;
    min-height: 48px;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
    width: 100%;
}

.pd-single-wrapper .pd-btn:hover {
    background: #1e5dd4;
    transform: translateY(-1px);
    box-shadow: 0 15px 20px -3px rgba(37, 106, 244, 0.3);
}

.pd-single-wrapper .pd-btn:active {
    transform: translateY(0);
    transition-duration: 0.1s;
}

.pd-single-wrapper .pd-btn:disabled,
.pd-single-wrapper .pd-btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.pd-single-wrapper .pd-btn .material-symbols-outlined {
    font-size: 1.25rem;
    flex-shrink: 0;
}

/* Breadcrumb */
.pd-single-breadcrumb {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    line-height: 1.4;
}

.pd-single-breadcrumb a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    white-space: nowrap;
}

.pd-single-breadcrumb a:hover {
    color: var(--primary);
}

.pd-single-breadcrumb span {
    opacity: 0.7;
}

.pd-single-breadcrumb-current {
    color: var(--text-light);
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 12rem;
}

/* Secondary button */
.pd-single-secondary-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-color);
    padding: 0.875rem 1.25rem;
    background: var(--card-dark);
    color: var(--text-light);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    min-height: 48px;
}

.pd-single-secondary-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* Section titles */
.pd-single-section {
    margin-bottom: 0;
    width: 100%;
}

.pd-single-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    color: var(--text-light);
    padding-left: 0.5rem;
    flex-wrap: wrap;
    width: 100%;
}

.pd-single-section-title.pd-section-title {
    margin-bottom: 1.5rem;
}

.pd-single-section-title .material-symbols-outlined {
    font-size: 1.25rem;
    color: var(--primary);
    flex-shrink: 0;
}

.pd-single-description {
    font-size: 1rem;
    color: var(--text-muted);
    line-height: 1.7;
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
    max-width: 72rem;
}

.pd-single-description p {
    margin-bottom: 1.5rem;
    width: 100%;
}

.pd-single-excerpt {
    font-weight: 500;
    margin-bottom: 1.5rem;
    color: var(--text-light);
    font-size: 1.125rem;
    line-height: 1.6;
    padding: 1rem;
    background: var(--border-light);
    border-radius: 0.75rem;
    border-left: 4px solid var(--primary);
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
}

/* Audio section */
.pd-single-audio-section audio {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.pd-single-audio-player {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: var(--card-dark);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    width: 100%;
}

.pd-single-audio-player:hover {
    border-color: rgba(37, 106, 244, 0.35);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
}

/* Professional play button */
.pd-single-audio-play-btn {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, #1e5dd4 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(37, 106, 244, 0.45);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
}

.pd-single-audio-play-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 24px rgba(37, 106, 244, 0.55);
    background: linear-gradient(135deg, #1e5dd4 0%, var(--primary) 100%);
}

.pd-single-audio-play-btn:active {
    transform: scale(0.98);
}

.pd-single-audio-play-btn .material-symbols-outlined {
    font-size: 28px;
    margin-left: 2px;
}

.pd-single-audio-pause-icon .material-symbols-outlined {
    font-size: 28px;
    margin-left: 0;
}

.pd-single-audio-play-icon[hidden],
.pd-single-audio-pause-icon[hidden] {
    display: none !important;
}

/* Progress area */
.pd-single-audio-controls {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.pd-single-audio-progress-wrap {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.pd-single-audio-progress {
    position: relative;
    height: 6px;
    border-radius: 9999px;
    background: var(--border-color);
    cursor: pointer;
    overflow: hidden;
    outline: none;
    touch-action: none;
    width: 100%;
}

.pd-single-audio-progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0%;
    border-radius: 9999px;
    background: linear-gradient(90deg, var(--primary), var(--accent-purple));
    transition: width 0.1s linear;
}

.pd-single-audio-time {
    font-size: 0.8125rem;
    font-variant-numeric: tabular-nums;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex-wrap: wrap;
}

.pd-single-audio-current {
    color: var(--text-light);
    font-weight: 600;
}

/* Quick info */
.pd-single-quick-info {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 2rem;
    width: 100%;
}

.pd-single-quick-info-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border-radius: 1rem;
    background: var(--card-dark);
    align-items: center;
    border: 1px solid var(--border-color);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    width: 100%;
}

.pd-single-quick-info-item:hover {
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border-color: rgba(37, 106, 244, 0.35);
}

.pd-single-quick-info-item .material-symbols-outlined {
    font-size: 1.25rem;
    color: var(--primary);
    background: rgba(37, 106, 244, 0.15);
    padding: 0.75rem;
    border-radius: 0.5rem;
    flex-shrink: 0;
}

.pd-single-quick-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin: 0 0 0.25rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pd-single-quick-value {
    font-size: 1rem;
    color: var(--text-light);
    margin: 0;
    font-weight: 600;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* Included grid */
.pd-single-included-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    width: 100%;
}

.pd-single-included-card {
    background: var(--card-dark);
    border-radius: 1rem;
    padding: 1rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    border: 1px solid var(--border-color);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    width: 100%;
}

.pd-single-included-card:hover {
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border-color: rgba(37, 106, 244, 0.35);
    transform: translateY(-2px);
}

.pd-single-included-count {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: var(--primary);
    line-height: 1;
}

.pd-single-included-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin: 0;
    word-break: break-word;
    text-align: center;
}

.pd-single-included-card .material-symbols-outlined {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
    flex-shrink: 0;
}

/* Table */
.pd-single-table-wrapper {
    overflow-x: auto;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    -webkit-overflow-scrolling: touch;
    width: 100%;
    margin: 0;
    background: var(--card-dark);
}

.pd-single-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    min-width: 500px;
}

.pd-single-table thead {
    background: var(--border-light);
}

.pd-single-table th,
.pd-single-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    word-break: break-word;
    overflow-wrap: break-word;
}

.pd-single-table th {
    color: var(--text-muted);
    font-weight: 600;
    white-space: nowrap;
}

.pd-single-table td {
    color: var(--text-light);
    font-weight: 500;
}

.pd-single-table tbody tr:last-child th,
.pd-single-table tbody tr:last-child td {
    border-bottom: none;
}

.pd-single-table tbody tr:hover {
    background: rgba(37, 106, 244, 0.08);
}

/* Gallery */
.pd-single-gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    width: 100%;
}

.pd-single-gallery-item {
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid var(--border-color);
    padding: 0;
    cursor: pointer;
    background: var(--card-dark);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    aspect-ratio: 4/3;
    touch-action: manipulation;
    width: 100%;
}

.pd-single-gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
    border-color: rgba(37, 106, 244, 0.35);
}

.pd-single-gallery-item:active {
    transform: translateY(-2px);
    transition-duration: 0.1s;
}

.pd-single-gallery-item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.pd-single-gallery-item:hover img {
    transform: scale(1.05);
}

.pd-single-gallery-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 1rem;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.pd-single-gallery-overlay img {
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 1.25rem;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    object-fit: contain;
    -webkit-user-select: none;
    user-select: none;
}

.pd-single-gallery-overlay button {
    position: absolute;
    top: max(1.5rem, env(safe-area-inset-top, 1.5rem));
    right: max(1.5rem, env(safe-area-inset-right, 1.5rem));
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
    touch-action: manipulation;
}

.pd-single-gallery-overlay button:hover {
    background: var(--primary);
}

/* License list */
.pd-single-license-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
}

.pd-single-license-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--card-dark);
    padding: 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    width: 100%;
}

.pd-single-license-list li:hover {
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border-color: rgba(37, 106, 244, 0.35);
}

.pd-single-license-list .material-symbols-outlined {
    font-size: 1.25rem;
    color: var(--primary);
    flex-shrink: 0;
}

/* Accordion */
.pd-single-accordion {
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    overflow: hidden;
    background: var(--card-dark);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    width: 100%;
}

.pd-single-accordion-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-light);
    transition: background 0.2s;
    touch-action: manipulation;
    text-align: left;
}

.pd-single-accordion-toggle:hover {
    background: var(--border-light);
}

.pd-single-accordion-body {
    padding: 0;
    background: var(--border-light);
    border-top: 1px solid var(--border-color);
}

.pd-single-installation-text {
    margin: 0;
    padding: 1rem;
    font-size: 0.875rem;
    white-space: pre-wrap;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    color: var(--text-muted);
    line-height: 1.6;
    background: transparent;
    border-radius: 0;
    overflow-x: auto;
    word-wrap: break-word;
    width: 100%;
}

.pd-single-accordion-icon {
    transition: transform 0.3s ease;
    color: var(--text-muted);
    flex-shrink: 0;
}

.pd-single-accordion-toggle[aria-expanded="true"] .pd-single-accordion-icon {
    transform: rotate(180deg);
    color: var(--primary);
}

/* Producer card */
.pd-single-producer-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    text-align: center;
    background: var(--card-dark);
    padding: 1.5rem;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
    width: 100%;
}

.pd-single-producer-avatar-large {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border-color);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
    flex-shrink: 0;
}

.pd-single-producer-name-large {
    margin: 0 0 0.5rem;
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--text-light);
    word-wrap: break-word;
    width: 100%;
}

.pd-single-producer-bio {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.6;
    word-wrap: break-word;
    width: 100%;
}

/* Related cards — columns from .pd-item-grid; overrides below */
.pd-single-related-grid {
    width: 100%;
}

/* Related section cards (.pd-card) — same hover as category / product cards */
.pd-single-related-grid .pd-card {
    position: relative;
    height: 100%;
    transition: all 0.25s ease;
    border: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
}

.pd-single-related-grid .pd-card:hover {
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.12);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.pd-single-wrapper .pd-single-related-grid .pd-card-thumbnail img {
    transition: none;
}

.pd-single-related-grid .pd-card:hover .pd-card-thumbnail img {
    transform: none;
}

.pd-single-related-grid .pd-card h3 a {
    transition: none;
}

.pd-single-related-grid .pd-card .pd-btn {
    transition: background-color 0.25s ease;
}

.pd-single-related-grid .pd-card .pd-btn-premium:hover,
.pd-single-related-grid .pd-card .pd-btn-free:hover {
    transform: none;
    box-shadow: none;
}


@media (max-width: 640px) {
    .pd-single-related-grid .pd-card-price-wrapper {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    .pd-single-related-grid .pd-card-price-wrapper .pd-btn {
        width: 100%;
        justify-content: center;
        font-size: 0.8125rem;
        padding: 0.5rem 0.75rem;
        min-height: 40px;
    }

    .pd-single-related-grid .pd-card h3 {
        font-size: 0.8125rem;
    }
}

.pd-single-related-card {
    background: linear-gradient(180deg, rgba(28, 33, 42, 0.98) 0%, var(--card-dark) 100%);
    border-radius: 1rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.3s ease;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(255, 255, 255, 0.03) inset;
    width: 100%;
}

.pd-single-related-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(37, 106, 244, 0.15);
    border-color: rgba(37, 106, 244, 0.25);
}

.pd-single-related-thumb {
    display: block;
    position: relative;
    padding-top: 62%;
    overflow: hidden;
    background: linear-gradient(145deg, rgb(25, 32, 45) 0%, rgb(30, 41, 59) 100%);
    width: 100%;
}

.pd-single-related-thumb img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pd-single-related-card:hover .pd-single-related-thumb img {
    transform: scale(1.08);
}

.pd-single-related-thumb-fallback {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--accent-purple));
    color: white;
}

.pd-single-related-thumb-fallback .material-symbols-outlined {
    font-size: 2.5rem;
}

.pd-single-related-body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
}

.pd-single-related-body h3 {
    font-size: 1rem;
    margin: 0;
    line-height: 1.3;
    font-weight: 700;
    color: var(--text-light);
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.pd-single-related-body h3 a {
    text-decoration: none;
    color: var(--text-light);
    font-weight: 700;
    transition: color 0.2s;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.pd-single-related-body h3 a:hover {
    color: var(--primary);
}

.pd-single-related-price {
    margin: 0.25rem 0;
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 600;
    word-wrap: break-word;
}

.pd-single-related-link {
    margin-top: auto;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: all 0.2s;
    white-space: nowrap;
}

.pd-single-related-link:hover {
    color: #1e5dd4;
    gap: 0.5rem;
}

/* Trust badges */
.pd-single-trust-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    width: 100%;
}

.pd-single-trust-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    flex-wrap: wrap;
}

.pd-single-trust-badge .material-symbols-outlined {
    color: #34d399;
    font-size: 1.25rem;
    flex-shrink: 0;
}

/* Material Symbols */
.pd-single-wrapper .material-symbols-outlined {
    font-family: 'Material Symbols Outlined';
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
    flex-shrink: 0;
}

/* ====== TABLET STYLES (768px and up) ====== */
@media (min-width: 768px) {
    .pd-single-hero-panel {
        padding: 1.75rem 2rem;
    }

    .pd-single-hero-grid {
        flex-direction: row;
        align-items: center;
        gap: 2.5rem;
    }
    
    .pd-single-hero-left {
        flex: 0 0 min(38%, 320px);
        padding: 1.25rem;
    }

    .pd-single-hero-thumb {
        max-width: none;
        margin: 0;
    }
    
    .pd-single-hero-right {
        flex: 1;
    }
    
    .pd-single-wrapper .pd-btn {
        min-width: 160px;
    }
    
    .pd-single-secondary-btn {
        min-width: 160px;
    }
    
    .pd-single-classification-grid,
    .pd-single-compat-grid,
    .pd-single-filedetails-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .pd-single-included-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
    
    .pd-single-included-card {
        padding: 1.5rem;
    }
    
    .pd-single-included-count {
        font-size: 1.75rem;
    }
    
    .pd-single-gallery-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
    
    .pd-single-license-list {
        grid-template-columns: repeat(2, 1fr);
        display: grid;
    }
    
    .pd-single-creator-card {
        flex-direction: row;
        text-align: left;
    }
    
    .pd-single-creator-avatar {
        width: 80px;
        height: 80px;
    }
    
    .pd-single-creator-bio {
        text-align: left;
    }
    
    .pd-single-hero-cta .pd-btn,
    .pd-single-hero-cta .pd-single-secondary-btn {
        width: auto;
    }

    .pd-single-hero-meta-row {
        flex-direction: row;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .pd-single-hero-meta-label {
        flex: 0 0 5.5rem;
        padding-top: 0.35rem;
    }
    
    .pd-single-audio-player {
        flex-direction: row;
        align-items: center;
    }
    
    .pd-single-audio-controls {
        flex-direction: row;
        align-items: center;
    }

    .pd-single-bento {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pd-single-bento-tile--wide {
        grid-column: span 2;
    }

    .pd-single-bento-tile--full {
        grid-column: 1 / -1;
    }
}

/* ====== DESKTOP STYLES (1024px and up) ====== */
@media (min-width: 1024px) {
    .pd-single-split {
        grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
        gap: 2rem;
    }

    .pd-single-split-aside {
        position: sticky;
        top: 1.5rem;
    }

    .pd-single-hero-panel {
        padding: 2rem 2.5rem;
        margin-bottom: 2rem;
    }

    .pd-single-hero-left {
        flex: 0 0 min(36%, 380px);
        padding: 1.5rem;
    }

    .pd-single-hero-grid {
        gap: 3rem;
    }

    .pd-single-bento {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 1.5rem;
    }

    .pd-single-bento-tile--wide {
        grid-column: span 2;
    }

    .pd-single-bento-tile--full {
        grid-column: 1 / -1;
    }

    .pd-single-bento .pd-single-included-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    }
    
    .pd-single-section-title {
        font-size: 1.5rem;
    }
    
    .pd-single-classification-grid,
    .pd-single-compat-grid,
    .pd-single-filedetails-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .pd-single-included-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
    
    .pd-single-gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
    
    .pd-single-license-list {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .pd-item-grid.pd-single-related-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.25rem;
    }

    .pd-single-card {
        padding: 1.75rem;
    }
    
    .pd-single-audio-play-btn {
        width: 56px;
        height: 56px;
    }
    
    .pd-single-audio-play-btn .material-symbols-outlined {
        font-size: 32px;
    }
    
    .pd-single-audio-pause-icon .material-symbols-outlined {
        font-size: 32px;
    }
}

/* ====== LARGE DESKTOP STYLES (1200px and up) ====== */
@media (min-width: 1200px) {
    .pd-single-container {
        padding-left: 2rem;
        padding-right: 2rem;
    }

    .pd-single-split {
        grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
        gap: 2.5rem;
    }

    .pd-single-hero-left {
        flex: 0 0 min(34%, 420px);
    }

    .pd-single-hero-grid {
        gap: 3.5rem;
    }
}

/* ====== WIDE DESKTOP — 5 related cards per row ====== */
@media (min-width: 1280px) {
    .pd-item-grid.pd-single-related-grid {
        grid-template-columns: repeat(5, 1fr);
    }

    .pd-single-breadcrumb-current {
        max-width: 24rem;
    }

    .pd-single-wrapper {
        padding: 0 0 3.5rem;
    }

    .pd-single-main {
        gap: 3rem;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .pd-single-quick-info-item:hover,
    .pd-single-included-card:hover,
    .pd-single-license-list li:hover,
    .pd-single-related-card:hover,
    .pd-single-related-grid .pd-card:hover {
        transform: none;
        box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
        border-color: var(--border-color);
    }

    .pd-single-related-grid .pd-card .pd-btn:hover {
        transform: none;
        box-shadow: none;
    }
    
    .pd-single-gallery-item:hover,
    .pd-single-audio-player:hover {
        transform: none;
        box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
        border-color: var(--border-color);
    }
    
    .pd-single-wrapper .pd-btn:hover,
    .pd-single-secondary-btn:hover,
    .pd-single-btn:hover {
        transform: none;
    }
    
    .pd-single-audio-play-btn:hover {
        transform: none;
    }
    
    
    .pd-single-wrapper .pd-btn:active,
    .pd-single-secondary-btn:active,
    .pd-single-btn:active {
        transform: scale(0.98);
        transition-duration: 0.1s;
    }
    
    .pd-single-audio-play-btn:active {
        transform: scale(0.98);
    }
    
    .pd-single-gallery-item:active {
        transform: translateY(-2px);
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .pd-single-wrapper *,
    .pd-single-wrapper *::before,
    .pd-single-wrapper *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .pd-single-main,
    .pd-single-included-card,
    .pd-single-license-list li,
    .pd-single-gallery-item,
    .pd-single-wrapper .pd-btn,
    .pd-single-secondary-btn,
    .pd-single-btn,
    .pd-single-audio-play-btn,
    .pd-single-audio-progress-fill,
    .pd-single-accordion-icon {
        transition: none !important;
    }
    
    .pd-single-gallery-item:hover,
    .pd-single-related-grid .pd-card:hover,
    .pd-single-wrapper .pd-btn:hover,
    .pd-single-secondary-btn:hover,
    .pd-single-btn:hover,
    .pd-single-audio-play-btn:hover {
        transform: none !important;
    }
    
}

/* Print */
@media print {
    .pd-single-wrapper {
        background: white;
        padding: 0;
        color: #111;
    }

    .pd-single-hero-cta,
    .pd-single-related-grid .pd-btn,
    .pd-single-gallery-item,
    .pd-single-wrapper .pd-btn,
    .pd-single-secondary-btn {
        display: none !important;
    }
}