* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 1200px;
    width: 100%;
    padding: 30px;
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

h1 {
    color: #333;
    font-size: 2.5em;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.control-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.control-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.control-btn:active {
    transform: translateY(0);
}

.speed-control {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #333;
}

#speedSelect {
    padding: 8px 12px;
    border: 2px solid #667eea;
    border-radius: 6px;
    font-size: 16px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

#speedSelect:hover {
    border-color: #764ba2;
}

main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.image-container {
    position: relative;
    width: 100%;
    background: #ffffff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    aspect-ratio: 16 / 9;
}

#currentImage {
    position: relative;
    z-index: 1;
    /* Keep on top of blur */
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: opacity 0.5s ease-in-out;
}

.image-info {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

.bottom-section {
    display: flex;
    gap: 20px;
}

.music-player,
.donation-panel {
    flex: 1;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.donation-panel {
    background: linear-gradient(135deg, #fff1eb 0%, #ace0f9 100%);
    align-items: center;
    text-align: center;
    position: relative;
    min-height: 280px;
    overflow: hidden;
    /* Prevent iframe from breaking rounded corners */
    padding: 25px;
    /* Default padding for text */
}

/* Ensure the iframe fills the entire panel when active */
#paypal_iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Iframe container */
#iframeContainer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 10;
    border-radius: 15px;
    overflow: hidden;
}

/* Specific class to remove padding when iframe is shown */
.donation-panel.iframe-active {
    padding: 0;
}

/* Close button styling */
#closeIframeBtn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 11;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: all 0.3s ease;
}

#closeIframeBtn:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

/* Error message styling */
#iframeError {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #fff1eb 0%, #ace0f9 100%);
    padding: 25px;
    box-sizing: border-box;
}

#iframeError p {
    color: #666;
    margin-bottom: 15px;
    font-size: 1em;
}

#openPayPalWindow {
    margin-top: 10px;
}

#donationContent {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.donation-info {
    text-align: center;
    width: 100%;
}

.donation-info h3 {
    color: #333;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.donation-info p {
    color: #666;
    margin-bottom: 20px;
}

.donation-btn {
    background: linear-gradient(135deg, #FF9966 0%, #FF5E62 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 94, 98, 0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.donation-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.donation-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 94, 98, 0.6);
}

.donation-btn:active {
    transform: translateY(0);
}

.paypal-donate-form {
    display: flex;
    justify-content: center;
    align-items: center;
}

.paypal-donate-btn {
    margin-top: 24px;
    width: auto;
    height: auto;
    min-width: 60px;
    transform: scale(2);
    transition: all 0.3s ease;
    cursor: pointer;
    filter: drop-shadow(0 4px 15px rgba(255, 94, 98, 0.4));
}

.paypal-donate-btn:hover {
    transform: scale(2.1);
    filter: drop-shadow(0 6px 20px rgba(255, 94, 98, 0.6));
}

.paypal-donate-btn:active {
    transform: scale(1.95);
}


.music-info {
    text-align: center;
    margin-bottom: 20px;
}

.music-info h3 {
    color: #333;
    margin-bottom: 10px;
    font-size: 1.3em;
}

#currentTrack {
    color: #666;
    font-size: 1.1em;
    font-weight: 500;
}

#audioPlayer {
    width: 100%;
    margin-bottom: 15px;
    border-radius: 8px;
}

.music-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.music-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.music-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.music-btn:active {
    transform: translateY(0);
}

/* Social Buttons Section */
.social-buttons {
    margin-top: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #e0c3fc 0%, #8ec5fc 100%);
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.social-buttons h3 {
    color: #333;
    font-size: 1.2em;
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.5);
}

.social-icons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.social-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.social-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transform: scale(0);
    transition: transform 0.3s ease;
    border-radius: 50%;
}

.social-btn:hover::before {
    transform: scale(1);
}

.social-btn svg {
    width: 18px;
    height: 18px;
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.social-btn:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.social-btn:hover svg {
    transform: rotate(360deg);
}

.social-btn:active {
    transform: translateY(-2px) scale(1.05);
}

.social-btn.facebook {
    background: linear-gradient(135deg, #1877f2 0%, #0d5dbf 100%);
    color: white;
}

.social-btn.facebook:hover {
    box-shadow: 0 8px 25px rgba(24, 119, 242, 0.5);
}

.social-btn.x-twitter {
    background: linear-gradient(135deg, #000000 0%, #14171a 100%);
    color: white;
}

.social-btn.x-twitter:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
}

.social-btn.instagram {
    background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: white;
}

.social-btn.instagram:hover {
    box-shadow: 0 8px 25px rgba(225, 48, 108, 0.5);
}

.social-btn.youtube {
    background: linear-gradient(135deg, #ff0000 0%, #cc0000 100%);
    color: white;
}

.social-btn.youtube:hover {
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.5);
}

.social-btn.github {
    background: linear-gradient(135deg, #333 0%, #1a1a1a 100%);
    color: white;
}

.social-btn.github:hover {
    box-shadow: 0 8px 25px rgba(51, 51, 51, 0.5);
}

.social-btn.linkedin {
    background: linear-gradient(135deg, #0077b5 0%, #005885 100%);
    color: white;
}

.social-btn.linkedin:hover {
    box-shadow: 0 8px 25px rgba(0, 119, 181, 0.5);
}


/* Footer Navigation */
.footer-nav {
    padding: 10px;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.footer-link {
    color: #333;
    text-decoration: none;
    font-size: 1.1em;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.footer-link::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 80%;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: transform 0.3s ease;
}

.footer-link:hover {
    color: #667eea;
    background: rgba(255, 255, 255, 0.3);
}

.footer-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

.footer-link:active {
    transform: scale(0.95);
}

@media (max-width: 768px) {
    h1 {
        font-size: 2em;
    }

    .controls {
        flex-direction: column;
    }

    .control-btn {
        width: 100%;
        max-width: 200px;
    }

    .bottom-section {
        flex-direction: column;
    }

    .music-controls {
        flex-direction: column;
    }

    .music-btn {
        width: 100%;
    }

    .footer-nav {
        gap: 15px;
    }

    .footer-link {
        font-size: 1em;
        padding: 8px 15px;
    }
}
