* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #ffffff;
    background-image: radial-gradient(ellipse at top, #eeeeee 0%, #ffffff 60%);
    color: #111111;
    font-family: Arial, sans-serif;
    min-height: 100vh;
}

/* --- Header --- */
header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 30px;
    border-bottom: 1px solid #dddddd;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img { height: 44px; width: auto; }

#page-tabs { display: flex; gap: 4px; flex: 1; }
.page-tab {
    background: transparent;
    border: none;
    color: #666;
    padding: 6px 14px;
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px;
    text-decoration: none;
    font-family: Arial, sans-serif;
    transition: color 0.15s, background 0.15s;
}
.page-tab:hover { color: #111; background: #f0f0f0; }
.page-tab.active { color: #111; font-weight: 600; }

.auth-buttons { display: flex; gap: 10px; margin-left: auto; }

.back-link { color: #555555; text-decoration: none; font-size: 0.85rem; }
.back-link:hover { color: #000000; }

/* --- Auth Header --- */
.auth-buttons { display: flex; gap: 10px; }

.btn-signup {
    background: #000000;
    color: #ffffff;
    border: 1px solid #000000;
    border-radius: 6px;
    padding: 8px 18px;
    font-size: 0.85rem;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
}

.btn-signup:hover { background: #333333; }

.header-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #e5e5e5;
    border: 1px solid #000000;
    font-size: 0.65rem;
    font-weight: bold;
    color: #000000;
    margin-right: 6px;
    vertical-align: middle;
    background-size: cover;
    background-position: center;
}

.user-menu { position: relative; }

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 5px 12px 5px 6px;
    color: #333333;
    font-size: 0.85rem;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.user-menu-trigger:hover { border-color: #555; color: #000000; }

.user-menu-name {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: #e1e1e1;
    border: 1px solid #ccc;
    border-radius: 8px;
    overflow: hidden;
    min-width: 150px;
    z-index: 1000;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
}

.user-dropdown.open { display: block; }

.user-dropdown-item {
    display: block;
    width: 100%;
    padding: 10px 16px;
    background: transparent;
    border: none;
    color: #333333;
    font-size: 0.85rem;
    text-align: left;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}

.user-dropdown-item:hover { background: #d5d5d5; color: #000000; }

.user-dropdown-logout { border-top: 1px solid #d5d5d5; color: #555555; }
.user-dropdown-logout:hover { background: #e5e5e5; color: #333333; }

/* --- Follow Button --- */
#follow-btn {
    margin-top: 10px;
    padding: 7px 20px;
    border: 1.5px solid #555;
    border-radius: 20px;
    background: transparent;
    color: #555;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.15s;
}
#follow-btn:hover { border-color: #111; color: #111; }
#follow-btn.follow-active { background: #111; color: #fff; border-color: #111; }
.follow-count { display: block; font-size: 0.78rem; color: #888; margin-top: 6px; }

/* --- Composer Hero --- */
#composer-hero {
    display: flex;
    align-items: center;
    gap: 30px;
    max-width: 1100px;
    margin: 40px auto 30px;
    padding: 0 30px;
}

#composer-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d5d5d5, #bbbbbb);
    background-size: cover;
    background-position: center;
    border: 2px solid #cccccc;
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: #555555;
}

#composer-name {
    font-size: 2.2rem;
    color: #000000;
    margin-bottom: 8px;
}

#composer-description {
    font-size: 0.9rem;
    color: #555555;
    line-height: 1.6;
}

/* --- Main Layout --- */
#layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 30px;
    max-width: 1100px;
    margin: 0 auto 60px;
    padding: 0 30px;
    align-items: start;
}

/* --- Sidebar --- */
#sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-box {
    background: #e5e5e5;
    border: 1px solid #d5d5d5;
    border-radius: 10px;
    padding: 16px;
}

.info-box h3 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #555555;
    margin-bottom: 14px;
    padding-bottom: 8px;
    border-bottom: 1px solid #dddddd;
}

#info-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#info-list li {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.info-label {
    font-size: 0.65rem;
    color: #555555;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#info-list span:not(.info-label),
#info-list a {
    font-size: 0.8rem;
    color: #333333;
}

#info-list a {
    color: #000000;
    text-decoration: none;
}

#info-list a:hover { text-decoration: underline; }

#appears-on-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

#appears-on-list li a {
    font-size: 0.8rem;
    color: #000000;
    text-decoration: none;
}

#appears-on-list li a:hover { text-decoration: underline; }

/* --- Main Content --- */
#main-content {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.bio-section h2 {
    font-size: 1rem;
    color: #000000;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 8px;
    border-bottom: 1px solid #dddddd;
    margin-bottom: 16px;
}

.section-sub {
    font-size: 0.75rem;
    color: #555555;
    margin-bottom: 16px;
}

#biography-text {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

#biography-text p {
    font-size: 0.875rem;
    color: #444444;
    line-height: 1.85;
}

.source-line {
    margin-top: 12px;
    font-size: 0.75rem;
    color: #555555;
}

.source-line a {
    color: #555555;
    text-decoration: none;
}

.source-line a:hover {
    color: #555555;
    text-decoration: underline;
}

/* --- Discography Sort Tabs --- */
#disc-sort-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.disc-sort-btn {
    background: #e5e5e5;
    border: 1px solid #d5d5d5;
    color: #555;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.disc-sort-btn:hover {
    border-color: #bbb;
    color: #000;
}

.disc-sort-btn.active {
    background: #000000;
    color: #ffffff;
    border-color: #000000;
}

/* --- Discography Grid --- */
#discography-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px;
}

.disc-card {
    background: #e5e5e5;
    border: 1px solid #d5d5d5;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.2s, transform 0.2s;
    text-decoration: none;
    display: block;
    color: inherit;
}

.disc-card:hover {
    border-color: #bbbbbb;
    transform: translateY(-3px);
}

.disc-art {
    width: 100%;
    aspect-ratio: 1;
    background: #d5d5d5;
    background-size: cover;
    background-position: center;
}

.disc-art-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    color: #555;
    text-transform: uppercase;
}

.disc-info {
    padding: 10px;
}

.disc-title {
    font-size: 0.75rem;
    color: #000000;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.disc-year {
    font-size: 0.65rem;
    color: #555555;
}

.disc-hidden {
    display: none;
}

.view-all-btn {
    margin-top: 16px;
    background: transparent;
    color: #555555;
    border: 1px solid #cccccc;
    border-radius: 6px;
    padding: 8px 20px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.view-all-btn:hover {
    border-color: #000000;
    color: #000000;
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 30px;
    font-size: 0.75rem;
    color: #444444;
    border-top: 1px solid #dddddd;
}

/* --- Dark Mode --- */
.theme-toggle {
    background: transparent;
    border: 1px solid #cccccc;
    border-radius: 6px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    color: #555555;
    transition: border-color 0.2s, color 0.2s;
    display: flex;
    align-items: center;
}

.theme-toggle:hover {
    border-color: #000000;
    color: #000000;
}

html.dark {
    filter: invert(1);
}

html.dark img,
html.dark .header-avatar,
html.dark .disc-art {
    filter: invert(1);
}
