* {
    box-sizing: border-box;
}

:root {
    --background: #282828;
    --foreground: #ebdbb2;
    --card-background: #3c3836;
    --border-color: #504945;
    --accent-color: #fabd2f;
    --hover-color: #fe8019;
    --text-color: #d5c4a1;
    --header-color: #83a598;
}

body {
    background-color: var(--background);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding-bottom: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.6;
}

.header {
    text-align: center;
    padding: 2rem 1rem;
}

.header h1 {
    font-size: 2.5rem;
    color: var(--header-color);
    margin-bottom: 0.5rem;
}

.header .subheader {
    font-size: 1.2rem;
    color: var(--text-color);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 2rem auto 0;
}

#biography {
    background-color: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.quote {
    font-style: italic;
    font-size: 1em;
    font-weight: bold;
    margin: 1.5rem auto 0.5rem auto; 
    padding: 1rem;
    border-left: 4px solid var(--accent-color);
    border-right: 4px solid var(--accent-color);
    color: var(--foreground);
    text-align: center;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 5px;
    max-width: 80%; 
}

.quote-author {
    display: block;
    margin-top: 0.5em;
    font-size: 0.9em;
    color: var(--text-color);
    font-style: normal;
    font-weight: normal;
}

.quote-disclaimer {
    font-size: 0.75em;
    color: var(--text-color);
    margin-top: 0.5rem;
    text-align: center;
}

#favorite-music {
    margin-bottom: 2rem;
}

#currently-playing {
    margin-bottom: 2rem;
}

#quote-of-the-day {
    margin-bottom: 2rem;
}

.currently-playing-link {
    text-decoration: none;
}

.currently-playing-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.currently-playing-content img {
    width: 100px;
    height: 100px;
    border-radius: 8px;
}

.currently-playing-content .song-details {
    flex-grow: 1;
    margin: 0 2rem;
    text-align: left;
}

.progress-bar-container {
    width: 100%;
    height: 6px;
    background-color: #555;
    border-radius: 3px;
    margin-top: 1rem;
}

.progress-bar {
    height: 100%;
    background-color: var(--accent-color);
    border-radius: 3px;
}

#currently-playing {
    padding: 1rem 2rem;
}

.audio-visualizer {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    height: 30px;
    gap: 4px;
    margin-top: 1rem;
}

.time-display {
    font-size: 0.8em;
    color: var(--text-color);
    margin-top: 0.5rem;
}

.visualizer-bar:nth-child(2) { animation-delay: 0.2s; }
.visualizer-bar:nth-child(3) { animation-delay: 0.4s; }
.visualizer-bar:nth-child(4) { animation-delay: 0.6s; }

@keyframes visualize {
    from { height: 5px; }
    to { height: 30px; }
}

.music-list {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.song-card {
    background-color: var(--card-background);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    flex-basis: 180px;
}

.song-card a {
    display: block;
    padding: 1rem;
    text-decoration: none;
    color: var(--text-color);
    text-align: center;
}

.song-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: var(--accent-color);
}

.song-card img {
    width: 150px;
    height: 150px;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.song-title {
    font-weight: bold;
    color: var(--foreground);
    margin: 0;
}

.artist-name {
    color: var(--text-color);
    margin: 0.25rem 0 0 0;
}

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.full-width-card {
    grid-column: 1 / -1;
    background: linear-gradient(145deg, #45413e, #3c3836);
    border: 1px solid var(--accent-color);
}

.card {
    background-color: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 15px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {

}

#favorite-music:hover,
#currently-playing:hover,
#favorite-youtubers:hover {
    transform: none;
    box-shadow: none;
}

.card h2 {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.click-info {
    font-size: 0.85rem;
    color: #a0a0a0; /* A slightly lighter gray */
    text-align: left;
    margin-top: 0.5rem; /* Adjust as needed to position below albums */
    margin-bottom: 1rem;
}

.current-song-box {
    background-color: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1rem;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    position: relative; /* Added for absolute positioning of button */
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.current-song-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: var(--accent-color);
}

.current-song-top-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    width: 100%;
}

.progress-and-visualizer {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.preview-button {
    background-color: var(--accent-color);
    color: var(--background);
    border: none;
    border-radius: 5px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
    position: absolute; /* Position absolutely */
    top: 1rem; /* Adjust as needed */
    right: 1rem; /* Adjust as needed */
}

.preview-button:hover {
    background-color: var(--hover-color);
}

.preview-button i {
    margin-right: 0.5rem;
}

ul {
    list-style-type: none;
    padding: 0;
}

li {
    margin: 0.5rem 0;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--hover-color);
    text-decoration: none;
}

i {
    margin-right: 0.5rem;
}

/* Footer Styles */
.footer {
    width: 100%;
    text-align: center;
    padding: 1.5rem 1rem;
    background-color: var(--card-background);
    color: var(--text-color);
    margin-top: 4rem;
    border-top: 1px solid var(--border-color);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .header h1 {
        font-size: 2rem;
    }

    .header .subheader {
        font-size: 1rem;
    }

    .container {
        width: 95%;
    }

    .card-container {
        grid-template-columns: 1fr; /* Stack cards on small screens */
    }

    .full-width-card {
        grid-column: auto; /* Remove full-width on small screens */
    }

    .music-list {
        gap: 1rem;
    }

    .youtuber-list {
        gap: 1rem;
    }

    .song-card {
        flex-basis: 150px; /* Adjust size of song cards */
    }

    .song-card img {
        width: 120px;
        height: 120px;
    }

    .currently-playing-content {
        flex-direction: column;
        text-align: center;
    }

    .currently-playing-content img {
        margin-bottom: 1rem;
    }

    .currently-playing-content .song-details {
        margin: 0;
    }

    .audio-visualizer {
        margin-top: 1rem;
    }

    .two-column-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header h1 {
        font-size: 1.8rem;
    }

    .header .subheader {
        font-size: 0.9rem;
    }

    .card {
        padding: 1.5rem;
    }

    .song-card {
        flex-basis: 120px;
    }

    .song-card img {
        width: 100px;
        height: 100px;
    }

    .youtuber-card {
        flex-basis: calc(50% - 2rem);
        margin: 0;
    }

    .youtuber-card img {
        width: 90px;
        height: 90px;
    }

    .click-info {
        font-size: 0.75rem;
    }
}

.profile-pic {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    display: block;
    border: 3px solid var(--accent-color);
}

.view-all-projects {
    margin-top: 1.5rem;
    text-align: right;
}

.view-all-projects a {
    color: var(--accent-color);
    font-weight: bold;
    text-decoration: none;
    transition: color 0.3s ease;
}

.view-all-projects a:hover {
    color: var(--hover-color);
}

.view-all-projects i {
    margin-left: 0.25rem;
    transition: transform 0.3s ease;
}

.view-all-projects a:hover i {
    transform: translateX(5px);
}

.two-column-container {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .two-column-container {
        grid-template-columns: 1fr;
    }
}

.visitor-counter {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-color);
    font-size: 0.9rem;
    text-align: center;
}

.visitor-counter i {
    color: var(--accent-color);
}

#visitor-count {
    font-weight: bold;
    color: var(--foreground);
}

.visitor-card {
    margin-bottom: 2rem;
}

.popup {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

.popup-content {
    background-color: var(--card-background);
    margin: 15% auto;
    padding: 20px;
    border: 1px solid var(--border-color);
    width: 80%;
    max-width: 400px;
    border-radius: 15px;
    text-align: center;
    position: relative;
}

.close-button {
    color: var(--text-color);
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
}

.close-button:hover,
.close-button:focus {
    color: var(--hover-color);
    text-decoration: none;
    cursor: pointer;
}

.discord-username {
    font-weight: bold;
    color: var(--accent-color);
    font-size: 1.2rem;
}


#view-counter-container {
    text-align: center;
    padding: 1.5rem 2rem; 
}

#view-counter-container h2 {
    margin-bottom: 0.5rem; 
}

#view-count {
    font-size: 2rem;
    font-weight: bold;
    color: var(--foreground);
    margin: 0;
}

#favorite-youtubers {
    margin-bottom: 2rem;
}

.youtuber-list {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.youtuber-card {
    background-color: var(--card-background);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    flex-basis: 180px;
}

.youtuber-card a {
    display: block;
    padding: 1rem;
    text-decoration: none;
    color: var(--text-color);
    text-align: center;
}


.youtuber-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    border-color: var(--accent-color);
}
.youtuber-card img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    margin-bottom: 1rem;
}

.youtuber-name {
    font-weight: bold;
    color: var(--foreground);
    margin: 0;
}