/* ==========================================================================
   TABLE OF CONTENTS
   ==========================================================================
   1. GLOBAL STYLES
   2. LAYOUT STRUCTURE
   3. HEADER & FOOTER
   4. NAVIGATION
   5. INTRO TEXT
   6. SIDEBAR WIDGETS
   7. MAIN CONTENT & POSTS
   8. PAGE-SPECIFIC STYLES
      - General Page Elements (Titles)
      - "About Me" Page
      - "Contact", "Links", "Creations" Pages (Shared Box Style)
      - "Albums" & "Music" Pages (Tables, Dropdowns)
      - Album/Track Detail Pages (Info Boxes, Grids)
   9. UTILITY STYLES (Highlights, Buttons etc.)
   ========================================================================== */


/* === 1. GLOBAL STYLES === */
body {
    background-color: #1a1a1a;
    background-image: url('../images/background-main.jpg');
    color: #e0e0e0;
    font-family: 'PT Sans', sans-serif;
    margin: 0;
    padding: 20px 0; /* Vertical padding only */
}

/* === 2. LAYOUT STRUCTURE === */
.container {
    max-width: 1150px;
    margin: 0 auto; /* Center the layout */
    background-color: #292929;
}

.main-content {
    display: flex;
    gap: 20px;
    padding: 20px;
}

.sidebar {
    width: 190px;
    flex-shrink: 0;
}

.content {
    width: 100%;
}

/* === 3. HEADER & FOOTER === */
header img {
    width: 100%;
    display: block; /* Removes bottom space under the image */
}

footer {
    padding: 20px;
    border-top: 1px solid #3c3c3c;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.footer-left, .footer-right {
    flex: 1;
    text-align: center;
}

footer p {
    font-size: 12px;
    color: #b3b3b3;
    line-height: 1.5;
    margin-top: 5px;
}

footer a {
    color: #87cefa;
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* === 4. NAVIGATION === */
nav {
    background-color: #3c3c3c;
    padding: 1px;
}

.nav-container {
    background-color: #333333;
    padding: 5px;
    text-align: center;
}

.nav-button, .nav-dropbtn {
    font-family: 'PT Sans', sans-serif;
    background-color: #333333;
    color: #e0e0e0;
    padding: 5px 10px;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
    text-decoration: none;
    display: inline-block;
}

.nav-dropdown {
    display: inline-block;
    position: relative;
}

.nav-dropdown-content {
    display: none;
    position: absolute;
    background-color: #292929;
    min-width: max-content;
    text-align: left;
    z-index: 10; /* Ensures dropdown is above content */
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.nav-dropdown-content a {
    color: #e0e0e0;
    padding: 10px 16px;
    text-decoration: none;
    display: block;
    transition: background-color 0.3s;
}

.nav-dropdown-content a:hover {
    background-color: #4682B4;
    color: #ffffff;
}

.nav-dropdown:hover .nav-dropdown-content {
    display: block;
}

.nav-dropdown:hover .nav-button,
.nav-dropdown:hover .nav-dropbtn,
.nav-active {
    background-color: #4682B4 !important;
    color: #ffffff !important;
}

.separator {
    color: #b3b3b3;
    margin: 0 8px;
    vertical-align: middle;
}

/* === 5. INTRO TEXT === */
.intro-text {
    text-align: center;
    padding: 20px 40px;
    border-bottom: 1px solid #3c3c3c;
}

.intro-text p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: #cccccc;
}

/* === 6. SIDEBAR WIDGETS === */
.widget {
    margin-bottom: 20px;
    border-bottom: 1px solid #3c3c3c;
    padding-bottom: 15px;
}

.widget-title {
    font-size: 14px;
    font-weight: bold;
    color: #f5f5f5;
    margin-top: 0;
    margin-bottom: 10px;
    padding-bottom: 5px;
}

.social-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.social-icons img {
    width: 25px;
    height: 25px;
    border-radius: 3px;
    transition: opacity 0.3s;
}

.social-icons img:hover {
    opacity: 0.8;
}

.text-center-widget {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}


/* === 7. MAIN CONTENT & POSTS === */
.content a {
    color: #87cefa;
    text-decoration: none;
}

.content a:hover {
    text-decoration: underline;
}

.content p {
    line-height: 1.6;
    margin-top: 0;
    margin-bottom: 1em;
}

.post {
    margin-bottom: 30px;
}

.post-date {
    font-size: 12px;
    color: #b3b3b3;
    margin-bottom: 5px;
}

.post-title {
    font-size: 22px;
    margin-top: 0;
    margin-bottom: 15px;
}

.post-title a {
    color: #e0e0e0;
    text-decoration: none;
}

.post-title a:hover {
    color: #add8e6;
}

.post-separator {
    border: 0;
    height: 1px;
    background-color: #3c3c3c;
    margin: 25px 0;
}

.post-with-image {
    display: flex;
    gap: 20px;
}

.post-with-image .post-image {
    flex-shrink: 0;
}

.post-with-image .post-image a {
    display: block;
}

.post-with-image .post-image img {
    border: 1px solid #252525;
    padding: 1px;
    background-color: #252525;
    box-shadow: 1px 1px 5px rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    transition: filter 0.3s;
}

.post-with-image .post-image a:hover img {
    filter: brightness(1.15);
}

.post-with-image .post-content h3,
.post-content h3 {
    color: #87cefa;
    font-size: 20px;
    margin-top: 0;
    margin-bottom: 10px;
}

.post-content ul {
    padding-left: 25px;
    list-style-type: disc;
}

.post-content li {
    margin-bottom: 8px;
}


/* === 8. PAGE-SPECIFIC STYLES === */

/* --- General Page Elements (Titles, Intros) --- */
.page-title, .archive-title {
    font-size: 28px;
    border-bottom: 1px solid #3c3c3c;
    padding-bottom: 10px;
    margin-bottom: 30px;
    color: #f5f5f5;
}

.page-intro {
    text-align: center;
    line-height: 1.6;
    margin: 0 20px;
}

/* --- "About Me" Page --- */
.ascii-art {
    background-color: #333333;
    border-radius: 4px;
    border: 1px solid #3c3c3c;
    color: #87cefa;
    font-family: monospace, monospace;
    overflow-x: auto;
    padding: 15px;
    white-space: pre;
    font-size: 13px;
    line-height: 1.5;
}

.profile-image-container {
    text-align: center;
    margin: 30px 0;
}

.profile-image {
    width: 200px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.profile-caption {
    color: #87cefa;
    font-style: italic;
    margin-top: 10px;
}

.info-list dt {
    color: #87cefa;
    font-weight: bold;
    margin-top: 1.5em;
}

.info-list dd {
    margin-left: 0;
    padding-left: 0;
}

/* --- "Contact", "Links", "Creations" Pages (Shared Box Style) --- */
.contact-box, .link-box, .content-box {
    background-color: #2d2d2d;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    margin-bottom: 30px;
    overflow: hidden;
}

.contact-box-title, .link-box-title, .content-box-title {
    background-color: #333333;
    color: #87cefa;
    margin: 0;
    padding: 10px 20px;
    font-size: 18px;
}

.link-box-title, .content-box-title {
    text-transform: capitalize;
}

.link-box-title a, .content-box-title a {
    text-decoration: none;
    margin-right: 10px;
}

.contact-table {
    width: 100%;
    border-collapse: collapse;
}

.contact-table td {
    padding: 8px 15px;
    border-bottom: 1px solid #3c3c3c;
}

.contact-table tr:last-child td {
    border-bottom: none;
}

.contact-table .icon-cell {
    width: 40px;
    text-align: center;
}

.contact-table .icon-cell img {
    height: 18px;
    vertical-align: middle;
}

.link-list {
    list-style-type: none;
    margin: 0;
    padding: 15px 20px;
    line-height: 1.6;
}

.link-list li {
    padding-bottom: 2px;
}

.special-note {
    background-color: #333333;
    border-radius: 8px;
    padding: 15px 20px;
}

.special-note h4 {
    color: #87cefa;
    margin: 0 0 10px 0;
}

.box-content {
    padding: 15px 20px;
}

.box-content.no-padding {
    padding: 0;
}

.box-content h4 {
    color: #87cefa;
    font-weight: bold;
    margin-bottom: 15px;
    margin-top: 25px;
}

.screenshot-grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(3, 1fr);
    margin-bottom: 20px;
}

.screenshot-grid.single {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.screenshot-card {
    background-color: #333333;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    padding: 15px;
    text-align: center;
}

.screenshot-card img {
    border-radius: 4px;
    width: 100%;
    max-width: 100%;
    height: auto;
    display: block;
}

.screenshot-card p {
    font-size: 0.9em;
    margin: 10px 0 0 0;
}

.button-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.download-button {
    background-color: #333333;
    border: 1px solid #3c3c3c;
    border-radius: 4px;
    color: #e0e0e0;
    display: inline-block;
    padding: 10px 20px;
    text-decoration: none;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.download-button:hover {
    background-color: #4682B4;
    color: #ffffff;
    border-color: #4682B4;
}

.accordion {
    margin-top: 20px;
}

.accordion summary {
    color: #87cefa;
    cursor: pointer;
    font-weight: bold;
    margin-bottom: 10px;
}

.accordion-content {
    padding-top: 10px;
    border-top: 1px solid #3c3c3c;
    margin-top: 10px;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    margin-top: 30px;
    border: 1px solid #4682B4;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.two-column-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.two-column-layout .column {
    flex: 1 1 300px; /* Allows columns to wrap on smaller screens */
}

.file-list, .tool-list {
    list-style-type: none;
    padding-left: 10px;
}
.tool-list {
    list-style-type: square;
    padding-left: 20px;
}

.tool-list li {
    padding-bottom: 5px;
}

/* --- "Albums" & "Music" Pages --- */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #3c3c3c;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.page-title.no-border {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.page-dropdown-btn {
    background-color: #3c3c3c;
    color: #e0e0e0;
    padding: 8px 20px;
    border: 1px solid #3c3c3c;
    cursor: pointer;
    border-radius: 4px;
    font-family: 'PT Sans', sans-serif;
    font-size: 14px;
}
.page-header .nav-dropdown:hover .page-dropdown-btn {
     background-color: #4682B4;
}

.year-dropdown-multi-column {
    display: none; /* Correctly hidden by default */
}
.nav-dropdown:hover .year-dropdown-multi-column {
    display: flex; /* Becomes flex only on hover */
}
.year-dropdown-multi-column .column {
    padding: 5px 15px;
    border-right: 1px solid #3c3c3c;
}
.year-dropdown-multi-column .column:last-child {
    border-right: none;
}

.album-table {
    width: 100%;
    border-collapse: collapse;
}

.album-table th {
    background-color: #333333;
    padding: 8px 10px;
    text-align: left;
    font-size: 14px;
}

.album-table td {
    padding: 8px 10px;
    vertical-align: top;
    font-size: 14px;
}

.album-table tbody tr:not(.year-separator) {
    cursor: pointer;
}
.album-table tbody tr:not(.year-separator):hover {
    background-color: #4682B4;
    color: #fff;
}
.album-table tbody tr:not(.year-separator):hover a {
    color: #fff;
}

.album-table .year-separator td {
    font-weight: bold;
    border-top: 1px solid #3c3c3c;
    border-bottom: 1px solid #3c3c3c;
    padding-top: 5px;
    padding-bottom: 5px;
    background-color: #292929;
}

/* --- Album/Track Detail Pages --- */
.bandcamp-wrapper {
    max-width: 600px;
    margin: 20px auto;
}

.track-image-link {
    display: block;
    margin: 10px auto 25px;
    max-width: 320px;
}
.track-image-link img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    display: block;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.info-card {
    background-color: #333333;
    border-radius: 4px;
    padding: 10px 15px;
}
.info-card h4 {
    color: #87cefa;
    margin: 0 0 5px 0;
    font-size: 1em;
}
.info-card p {
    margin: 0;
    word-break: break-all;
}

.info-box {
    background-color: #333333;
    border-radius: 4px;
    padding: 15px;
    margin-top: 20px;
}
.info-box.unavailable {
    text-align: center;
    color: #aaa;
}
.info-box h4 {
    margin-top: 0;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}
.info-table th {
    color: #87cefa;
    font-weight: normal;
    text-align: left;
    padding: 0 5px 5px 5px;
    border-bottom: 1px solid #3c3c3c;
}
.info-table td {
    padding: 2px 5px;
    width: 50%;
}
.info-table.single-col th { display: none; }
.info-table.single-col td { width: 100%; }
.info-table.single-col { border-top: 1px solid #3c3c3c; }


.tracklist {
    margin: 0;
    padding-left: 20px;
}
.tracklist li {
    margin-bottom: 5px;
    line-height: 1.4;
}


/* === 8. UTILITY STYLES === */

/* --- News Archive Link --- */
.archive-link {
    text-align: center;
    margin-top: 40px;
}

.archive-link a {
    font-size: 16px;
    font-weight: bold;
    color: #e0e0e0;
    text-decoration: none;
    padding: 10px 15px;
    border: 1px solid #3c3c3c;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.archive-link a:hover {
    background-color: #4682B4;
    color: #fff;
    border-color: #4682B4;
}

/* --- Text Highlights --- */
.highlight-text {
    color: #87cefa;
    font-weight: bold;
}

.highlight-yellow, .highlight-green, .highlight-red {
    color: #000;
    padding: 2px 4px;
    border-radius: 3px;
}

.highlight-yellow { background-color: #fff3a3; }
.highlight-green { background-color: #bbf7d0; }
.highlight-red { background-color: #fecacb; }

.new-tag {
    color: #87cefa;
    font-size: 12px;
    font-weight: bold;
}

.tools-header {
    text-align: center;
    color: #87cefa;
    margin-top: 25px;
}

/* --- "Back to Top" Button --- */
#myBtn {
  display: none;
  position: fixed;
  bottom: 20px;
  right: calc((100% - 1150px) / 2 - 40px);
  z-index: 99;
  border: none;
  outline: none;
  background-color: transparent;
  cursor: pointer;
  padding: 0;
  border-radius: 4px;
  transition: opacity 0.3s;
}

#myBtn:hover {
  opacity: 0.8;
}

@media (max-width: 1250px) {
  #myBtn {
    right: 20px;
  }
}