/**
 * Hamster Brain Studio - For all your royatly free music needs
 */

/* ========================================
   GLOBAL STYLES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #000000;
    font-family: 'Ubuntu', Arial, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: hidden;
}

/* ========================================
   HEADER & FOOTER
   ======================================== */
.header-image {
    width: 600px;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.banner-image {
    width: 800px;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 20px auto;
}

.footer-image {
    width: 800px;
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Footer Text */
.footer-text {
    width: 600;
    max-width: 100%;
    margin: 0px auto;
    margin-bottom: 25px;
    text-align: center;
    color: #cccccc;
    font-size: 14px;
    line-height: 1.8;
}

.footer-text a {
    color: #999999;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-text a:hover {
    color: #bfbfbf;  /* Your brand color */
}

.footer-text span {
    margin: 0 10px;
    color: #666;
}

.footer-text p {
    margin: 2px 0;
}

/* ========================================
   MAIN CONTENT WRAPPER
   ======================================== */
.content-wrapper {
    /*flex: 1;*/
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
    width: 100%;
    height: 550px;
}

/* ========================================
   CAROUSEL CONTAINER
   ======================================== */
.carousel-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    height: 350px;
    /*padding-top: 20px;*/
    margin-bottom: 0px;
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1500px;
}

.carousel-nav-button {
    position: absolute;
    top: 80%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    cursor: pointer;
    z-index: 100;
    opacity: 0.8;
    transition: opacity 0.5s ease-in-out;
}


.carousel-nav-button-left {
    left: 160px;  /* 20px from left edge of carousel */
}

.carousel-nav-button-right {
    right: 160px;  /* 20px from right edge of carousel */
}

/* Show arrows when hovering over carousel */
.carousel-container:hover .carousel-nav-button {
    opacity: 1.0;
}

.carousel-nav-button img {
    width: 100%;
    height: 100%;
    pointer-events: none;
}


/* ========================================
   SONG CARDS (ALBUM ART)
   ======================================== */
.song-card {
    position: absolute;
    width: 200px;
    height: auto;
    cursor: pointer;
    transition: transform 0.5s ease-in-out, box-shadow 0.2s ease-out, visibility 0.1s;
    transform-style: preserve-3d;
    /*border-radius: 15px;*/
    overflow: visible;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: block;
}

.song-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(200, 200, 200, 0.15) 0%, rgba(180, 180, 180, 0.15) 100%);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 1;
    pointer-events: none;
    border-radius: 15px;
}

.song-card:hover::before {
    opacity: 1;
}

.song-card:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1), 
                0 0 10px rgba(0, 0, 0, 0.1);
}

.song-card.hero::before {
    opacity: 0;
}

.song-card img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    /*border-radius: 15px;*/
}

/* ========================================
   HERO CARD (CENTER/DISPLAYED)
   ======================================== */
.song-card.hero {
    width: 300px;
    z-index: 100 !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), 
                0 0 10px rgba(200, 200, 200, 0.1);
    transform: translate(0, -30px) scale(1.125) translateZ(50px) !important;
    position: relative;
}

/* Hero Card Play/Pause Overlay */
.hero-play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100px;
    height: 100px;
    background: transparent;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.3s;
    z-index: 10;
}
/*
.hero-play-overlay:hover {
    background: transparent;
    opacity: 0.2;
}
*/
.hero-play-overlay img {
    width: 150px;
    height: 150px;
    opacity: 0.2;
    transition: opacity 0.5s ease-in-out;
}

.song-card:hover .hero-play-overlay img {
    opacity: 0.8;
}

/* ========================================
   CAROUSEL POSITION CLASSES
   ======================================== */
.pos-center {
    transform: translate(0, 0) scale(1) translateZ(0px);
    z-index: 50;
}

.pos-left-1 {
    transform: translate(-140px, -30px) scale(1.0) translateZ(-100px);
    z-index: 40;
}

.pos-right-1 {
    transform: translate(140px, -30px) scale(1.0) translateZ(-100px);
    z-index: 40;
}

.pos-left-2 {
    transform: translate(-230px, -30px) scale(0.85) translateZ(-200px);
    z-index: 30;
}

.pos-right-2 {
    transform: translate(230px, -30px) scale(0.85) translateZ(-200px);
    z-index: 30;
}

.pos-left-3 {
    transform: translate(-320px, -30px) scale(0.70) translateZ(-300px);
    z-index: 20;
}

.pos-right-3 {
    transform: translate(320px, -30px) scale(0.70) translateZ(-300px);
    z-index: 20;
}

/* ========================================
   PLAYLIST TITLE (Below Carousel)
   ======================================== */
.jukebox-playlist-title {
    font-family: 'Ubuntu', Arial, sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: #cccccc;
    text-align: center;
    width: 100%;
    max-width: 500px;
    margin-top: -22px;
    margin-bottom: 0px;
	opacity: 0.6;
}

.jukebox-playlist-title .playlist-label {
    font-weight: 400;
}

.jukebox-playlist-title .playlist-name {
    font-weight: 400;
}

/* ========================================
   SONG INFO SECTION
   ======================================== */
.song-info-section {
    font-family: 'Ubuntu', Arial, sans-serif;
    margin-top: 5px;
    min-height: 80px;
    display: flex;              /* ADD THIS */
    align-items: center;        /* ADD THIS */
    justify-content: space-between;  /* ADD THIS */
    gap: 20px;                  /* ADD THIS */
    width: 100%;
    max-width: 500px;
}

/* Left column - Text stacks vertically */
.song-info-text {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 8px;
    text-align: left;  /* Override the center alignment */
	margin-left: 14px;
}

.song-title {
    font-weight: bold;
    color: #ffffff;
    font-size: 18px;
    margin-bottom: 3px;
}

.song-artist {
    color: #cccccc;
    font-weight: bold;
    font-size: 16px;
}

/* Right column - Download & Share buttons */
.song-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-action {
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
    opacity: 0.70;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    padding: 0;
}

.btn-action:hover {
    opacity: 1.0;
    transform: translateY(-2px) scale(1.1);
}

.btn-action img {
    width: 100%;
    height: 100%;
    display: block;
}


/* ========================================
   PLAYER CONTROLS
   ======================================== */
.player-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
    width: 100%;
    max-width: 600px;
}

.control-row {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 500px;
}

/* Play/Pause Button */
.btn-play-pause {
    width: 36px;
    height: 36px;
    background: #333;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}

.btn-play-pause:hover {
    background: #444;
    transform: translateY(-1px) scale(1.2);
}

.btn-play-pause img {
    width: 28px;
    height: 28px;
}

/* Progress Container */
.progress-container-custom {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.time-display {
    font-size: 12px;
    color: #ffffff;
    min-width: 35px;
}

.progress-bar-custom {
    flex: 1;
    height: 6px;
    background: #333;
    border-radius: 3px;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.progress-fill-custom {
    height: 100%;
    background: #7c1749;
    width: 0%;
    transition: width 0.2s linear;
    border-radius: 3px;
}

/* Volume Controls */
.btn-volume {
    width: 36px;
    height: 36px;
    background: #333;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}

.btn-volume:hover {
    background: #444;
}

.btn-volume img {
    width: 28px;
    height: 28px;
}

.volume-slider-custom {
    width: 80px;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: #333;
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

.volume-slider-custom::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: #7c1749;
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider-custom::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #7c1749;
    border-radius: 50%;
    border: none;
    cursor: pointer;
}


/* ========================================
   ERROR MESSAGE
   ======================================== */
.error-message {
    color: #d32f2f;
    text-align: center;
    padding: 40px 20px;
    font-size: 16px;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 900px) {
    .pos-left-3, .pos-right-3 {
        display: none;
    }
}

@media (max-width: 800px) {
    .header-image,
    .banner-image,
    .footer-image {
        width: 100%;
    }

    .pos-left-2, .pos-right-2 {
        display: none;
    }
    
    .song-card {
        width: 300px;
    }

    .song-card.hero {
        width: 350px;
    }

    .pos-left-1 {
        transform: translate(-210px, 45px) scale(0.78) translateZ(-100px);
    }

    .pos-right-1 {
        transform: translate(210px, 45px) scale(0.78) translateZ(-100px);
    }
}

@media (max-width: 480px) {
    .song-title {
        font-size: 24px;
    }

    .song-artist {
        font-size: 1em;
    }

    .control-row {
        gap: 10px;
    }

    .volume-slider-custom {
        width: 60px;
    }
}

/* ========================================
   LOADING SPINNER (Hero Card)
   ======================================== */
.hero-loading-spinner {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 200;
    
}

.hero-loading-spinner.active {
    display: flex;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========================================
   SHARE CONFIRMATION POPUP
   ======================================== */
.share-confirmation {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(124, 23, 73, 0.95);
    color: #fff;
    padding: 12px 24px;
    border-radius: 8px;
    font-family: 'Ubuntu', Arial, sans-serif;
    font-size: 14px;
    font-weight: bold;
    z-index: 1000;
    opacity: 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
    pointer-events: none;
}

.share-confirmation.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ========================================
   SHARE POPOVER (MadDog Style)
   ======================================== */

.share-popover {
    position: fixed;
    width: min(340px, calc(100vw - 24px));
    background: #1a1a1a;
    border: 1px solid #444;
    border-radius: 14px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    padding: 16px;
    z-index: 99999;
    font-family: inherit;
    opacity: 0;
    transform: translateY(-8px);
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.share-popover[aria-hidden="false"] {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.share-popover[aria-hidden="true"] {
    display: block; /* Override the old display:none */
    opacity: 0;
    pointer-events: none;
}

.share-popover__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    padding-bottom: 10px;
    border-bottom: 1px solid #333;
}

.share-popover__title {
    font-weight: 700;
    font-size: 16px;
    color: #f9cd00;
}

.share-popover__close {
    border: 0;
    background: transparent;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    color: #888;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
}

.share-popover__close:hover {
    background: #333;
    color: #fff;
}

.share-popover__song {
    font-size: 13px;
    color: #aaa;
    margin-bottom: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.share-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.share-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid #333;
    border-radius: 10px;
    text-decoration: none;
    color: #fff;
    font-size: 13px;
    transition: background 0.15s, border-color 0.15s;
}

.share-option:hover {
    background: #2a2a2a;
    border-color: #f9cd00;
}

.share-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    overflow: hidden;
    flex-shrink: 0;
}

.share-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

/* No colored backgrounds when using PNG icons */
.share-icon--email,
.share-icon--whatsapp,
.share-icon--telegram,
.share-icon--messenger,
.share-icon--twitter,
.share-icon--facebook {
    background: transparent;
}

.share-copy {
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    border: 1px solid #f9cd00;
    background: transparent;
    color: #f9cd00;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.share-copy:hover {
    background: #f9cd00;
    color: #000;
}

.share-toast {
    margin-top: 10px;
    min-height: 20px;
    font-size: 13px;
    color: #4ade80;
    text-align: center;
}
