/* Application-specific styles for authenticated users */

.app-body {
    background-color: #f8f9fa;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Navigation */
.main-nav {
    display: flex;
    gap: 1rem;
    margin-right: 2rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #495057;
    background-color: rgba(0, 0, 0, 0.05);
}

/* Main Application Layout */
.app-main {
    flex: 1;
    padding: 1rem 0;
}

.app-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    gap: 1rem;
}

.toolbar-left {
    display: flex;
    gap: 0.5rem;
}

.toolbar-right {
    display: flex;
    gap: 0.5rem;
}

.icon-btn {
    background: none;
    border: 1px solid #dee2e6;
    padding: 0.5rem;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.icon-btn:hover {
    background-color: #f8f9fa;
    border-color: #adb5bd;
}

/* Application Content Layout */
.app-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    height: calc(100vh - 200px);
    min-height: 600px;
}

.left-pane,
.right-pane {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.pane-header {
    padding: 1rem;
    border-bottom: 1px solid #dee2e6;
    background-color: #f8f9fa;
}

.pane-header h3 {
    margin: 0 0 1rem 0;
    color: #495057;
    font-size: 1.25rem;
}

/* Library Search */
.library-search {
    margin-bottom: 1rem;
}

.library-search-input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ced4da;
    border-radius: 0.25rem;
    font-size: 0.9rem;
}

/* View Controls */
.view-controls {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.view-btn {
    flex: 1;
    padding: 0.375rem 0.5rem;
    border: 1px solid #dee2e6;
    background: white;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 0.875rem;
    transition: all 0.2s ease;
}

.view-btn:hover {
    background-color: #f8f9fa;
}

.view-btn.active {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
}

/* Add Song button specific styling */
#addSongBtn {
    flex: none;
    width: auto;
    padding: 0.375rem 1rem;
    min-width: 100px;
}

/* Filter Controls */
.filter-controls {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.setlist-filter {
    width: 100%;
}

.setlist-dropdown {
    width: 100%;
    padding: 0.375rem 0.5rem;
    border: 1px solid #ced4da;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}

.filter-checkbox {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    cursor: pointer;
}

.filter-checkbox input[type="checkbox"] {
    margin-right: 0.5rem;
}

/* Song Explorer */
.song-explorer {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
}

.song-details {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
}

/* Empty States */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #6c757d;
    text-align: center;
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
}

.empty-state p {
    margin: 0;
    font-size: 0.9rem;
}

/* Song Groups */
.song-group {
    border-bottom: 1px solid #f1f3f4;
}

.group-header {
    padding: 0.75rem;
    background-color: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    cursor: pointer;
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #495057;
    transition: background-color 0.2s ease;
}

.group-header:hover {
    background-color: #e9ecef;
}

.group-toggle {
    margin-right: 0.5rem;
    font-size: 0.8rem;
    color: #6c757d;
}

.group-name {
    flex: 1;
}

.group-count {
    font-size: 0.875rem;
    color: #6c757d;
    font-weight: normal;
}

.group-content {
    background-color: white;
}

/* Song List Items */
.song-item {
    padding: 0.75rem;
    border-bottom: 1px solid #f1f3f4;
    cursor: pointer;
    transition: background-color 0.2s ease;
    position: relative;
}

.song-item:hover {
    background-color: #f8f9fa;
}

.song-item.selected {
    background-color: #e3f2fd;
    border-left: 3px solid #2196f3;
}

.song-item-content {
    display: flex;
    align-items: center;
}

.song-item-title {
    font-weight: 600;
    color: #212529;
    margin-bottom: 0.25rem;
}

.song-item-artist {
    color: #6c757d;
    font-size: 0.9rem;
    flex: 1;
}

.song-item-indicator {
    font-size: 0.875rem;
    margin-left: 0.5rem;
    opacity: 0.7;
}

/* Song Details View */
.song-details-content {
    padding: 1rem;
}

.song-details-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #dee2e6;
}

.song-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #212529;
    margin: 0 0 0.5rem 0;
}

.song-artist {
    font-size: 1.1rem;
    color: #6c757d;
    margin: 0 0 0.25rem 0;
}

.song-album {
    font-size: 1rem;
    color: #6c757d;
    margin: 0;
    font-style: italic;
}

.song-details-sections {
    margin-bottom: 2rem;
}

.song-details-section {
    margin-bottom: 1.5rem;
}

.song-details-section h4 {
    margin: 0 0 0.75rem 0;
    color: #495057;
    font-size: 1rem;
    font-weight: 600;
}

.song-details-section p {
    margin: 0;
    color: #6c757d;
}

.info-item, .resource-item {
    margin-bottom: 0.75rem;
    padding: 0.5rem;
    background-color: #f8f9fa;
    border-radius: 0.25rem;
}

.resource-item a {
    color: #007bff;
    text-decoration: none;
    margin-left: 0.5rem;
}

.resource-item a:hover {
    text-decoration: underline;
}

.song-lyrics {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 0.25rem;
    border: 1px solid #dee2e6;
    white-space: pre-wrap;
    font-family: inherit;
    font-size: 0.9rem;
    line-height: 1.4;
    max-height: 300px;
    overflow-y: auto;
}

.song-actions {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.song-metadata {
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
    text-align: center;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.btn-icon {
    margin-right: 0.25rem;
}

/* Edit Form Styles */
.edit-song-form {
    max-width: 100%;
}

.edit-song-form .form-group {
    margin-bottom: 1rem;
}

.edit-song-form label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: 600;
    color: #495057;
}

.edit-song-form input,
.edit-song-form textarea {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ced4da;
    border-radius: 0.25rem;
    font-size: 0.9rem;
}

.edit-song-form textarea {
    resize: vertical;
    font-family: inherit;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1rem;
    color: #6c757d;
}

.loading-spinner {
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

/* Modal Enhancements for App */
.modal-content {
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}

.form-help {
    display: block;
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
}

/* Resource Search Modal */
.resource-search-content .modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.5rem;
}

.resource-url-input {
    margin: 1rem 0;
}

.resource-url-field {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}

.resource-url-field:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.resource-save-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Chord Definition Editor */
.chord-definitions {
    display: table;
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.chord-definition-row {
    display: table-row;
}

.chord-definition-row label {
    display: table-cell;
    padding: 0.5rem 1rem 0.5rem 0;
    text-align: left;
    font-weight: 500;
    width: 60px;
    vertical-align: middle;
}

.chord-definition-row .chord-frets {
    display: table-cell;
    padding: 0.5rem;
    text-align: left;
    width: 100%;
    max-width: 300px;
}

.resource-search-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 1rem 0;
}

.resource-search-link {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    text-decoration: none;
    color: #007bff;
    transition: all 0.2s ease;
}

.resource-search-link:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
    text-decoration: none;
}

/* YouTube Player Styles */
.youtube-player-view {
    padding: 1rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.youtube-player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-shrink: 0;
}

.youtube-player-back-btn {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    transition: background-color 0.2s ease;
}

.youtube-player-back-btn:hover {
    background-color: #5a6268;
}

.youtube-player-title {
    text-align: right;
    flex: 1;
    margin-left: 1rem;
}

.youtube-player-title h3 {
    margin: 0;
    font-size: 1.25rem;
    color: #495057;
}

.youtube-player-artist {
    margin: 0.25rem 0 0 0;
    color: #6c757d;
    font-size: 0.875rem;
}

.youtube-player-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    min-height: 0;
}

.youtube-player-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: #6c757d;
    font-size: 1.1rem;
}

#youtube-iframe-container {
    width: 100%;
    max-width: 800px;
    display: flex;
    justify-content: center;
}

#youtube-player-iframe {
    width: 100%;
    max-width: 800px;
    height: 450px;
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.speed-controls {
    text-align: center;
    width: 100%;
    max-width: 600px;
}

.speed-controls h4 {
    margin: 0 0 1rem 0;
    color: #495057;
    font-size: 1.1rem;
}

.speed-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}

.speed-btn {
    background-color: #f8f9fa;
    border: 2px solid #dee2e6;
    color: #495057;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.2s ease;
    min-width: 80px;
}

.speed-btn:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
}

.speed-btn.active {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.speed-btn.active:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.youtube-player-error {
    text-align: center;
    padding: 3rem 2rem;
    color: #6c757d;
}

.youtube-player-error .error-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.youtube-player-error h4 {
    margin: 0 0 0.5rem 0;
    color: #dc3545;
    font-size: 1.25rem;
}

.youtube-player-error p {
    margin: 0 0 1.5rem 0;
    font-size: 1rem;
}

.error-fallback {
    margin-top: 1rem;
}

/* Responsive Design for YouTube Player */
@media (max-width: 768px) {
    .youtube-player-view {
        padding: 0.75rem;
    }

    .youtube-player-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        margin-bottom: 1rem;
    }

    .youtube-player-title {
        text-align: left;
        margin-left: 0;
        order: -1;
        width: 100%;
    }

    .youtube-player-back-btn {
        align-self: flex-start;
    }

    #youtube-player-iframe {
        height: 250px;
    }

    .speed-buttons {
        gap: 0.5rem;
    }

    .speed-btn {
        padding: 0.6rem 1rem;
        font-size: 0.875rem;
        min-width: 60px;
    }

    .youtube-player-error {
        padding: 2rem 1rem;
    }
}

@media (max-width: 480px) {
    #youtube-player-iframe {
        height: 200px;
    }

    .speed-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.8rem;
        min-width: 50px;
    }
}

/* Settings Modal */
.settings-content {
    padding: 1rem 0;
}

.setting-group {
    margin-bottom: 2rem;
}

.setting-group h3 {
    margin: 0 0 1rem 0;
    color: #495057;
    font-size: 1.1rem;
}

.setting-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    cursor: pointer;
}

.setting-item input[type="checkbox"] {
    margin-right: 0.5rem;
}

.setting-help {
    font-size: 0.875rem;
    color: #6c757d;
    margin: 0.5rem 0 0 0;
}

/* Setlist Items in Settings */
.setlists-list {
    margin: 1rem 0;
}

.setlist-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    transition: background-color 0.2s ease;
}

.setlist-item:hover {
    background-color: #e9ecef;
}

.setlist-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
}

.setlist-name {
    font-weight: 500;
    color: #495057;
}

.setlist-count {
    color: #6c757d;
    font-size: 0.875rem;
}

.setlist-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn.small {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.no-setlists {
    text-align: center;
    color: #6c757d;
    padding: 2rem;
    font-style: italic;
}

.loading-setlists {
    text-align: center;
    color: #6c757d;
    padding: 1rem;
}

/* Profile Section */
.profile-info {
    margin-bottom: 1rem;
}

.profile-info p {
    margin: 0.5rem 0;
    color: #495057;
}

.profile-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Setting Description */
.setting-description {
    color: #6c757d;
    font-size: 0.9rem;
    margin: 0 0 1rem 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .app-content {
        grid-template-columns: 1fr;
        height: auto;
        min-height: auto;
    }

    .left-pane {
        order: 1;
        height: 300px;
    }

    .right-pane {
        order: 2;
        height: 400px;
    }

    .main-nav {
        display: none;
    }

    .app-toolbar {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }

    .toolbar-right {
        justify-content: center;
    }
}

/* Loading States */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    color: #6c757d;
}

.loading::before {
    content: "";
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 0.5rem;
}

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

/* Modern song explorer using HTML5 details/summary */

.song-group {
    margin-bottom: 0.25rem;
    border: 1px solid #e9ecef;
    border-radius: 0.375rem;
    overflow: hidden;
    background: white;
}

.song-group[open] {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.group-header {
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: #495057;
    transition: all 0.2s ease;
    border: none;
    outline: none;
    user-select: none;
}

.group-header:hover {
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    color: #212529;
}

.group-header::-webkit-details-marker {
    display: none;
}

.group-header::before {
    content: "▶";
    font-size: 0.75rem;
    color: #6c757d;
    transition: transform 0.2s ease;
    width: 1rem;
    text-align: center;
}

.song-group[open] .group-header::before {
    transform: rotate(90deg);
}

.group-icon {
    font-size: 1rem;
    opacity: 0.7;
}

.group-name {
    flex: 1;
    font-size: 0.9rem;
}

.group-count {
    font-size: 0.8rem;
    color: #6c757d;
    background: rgba(108, 117, 125, 0.1);
    padding: 0.2rem 0.5rem;
    border-radius: 1rem;
    font-weight: normal;
}

.group-content {
    padding: 0;
    background: white;
    border-top: 1px solid #f1f3f4;
}

/* Updated song item styles */
.song-item {
    padding: 0.6rem 1rem;
    border-bottom: 1px solid #f8f9fa;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: all 0.15s ease;
    background: white;
}

.song-item:last-child {
    border-bottom: none;
}

.song-item:hover {
    background: #f8f9fa;
    padding-left: 1.25rem;
}

.song-item.selected {
    background: #e3f2fd;
    border-left: 3px solid #2196f3;
    color: #1565c0;
}

.song-item.selected:hover {
    background: #e3f2fd;
}

.song-item-content {
    flex: 1;
    min-width: 0; /* Allow text truncation */
}

.song-item-title {
    font-weight: 500;
    font-size: 0.9rem;
    color: #212529;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
}

.song-item-indicator {
    font-size: 0.9rem;
    opacity: 0.7;
    flex-shrink: 0;
}

/* Flat list for "All" view */
.flat-song-list {
    background: white;
    border-radius: 0.375rem;
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.flat-song-list .song-item {
    border-bottom: 1px solid #f1f3f4;
}

.flat-song-list .song-item:last-child {
    border-bottom: none;
}

/* Focus states for accessibility */
.group-header:focus {
    outline: 2px solid #2196f3;
    outline-offset: -2px;
}

.song-item:focus {
    outline: 2px solid #2196f3;
    outline-offset: -2px;
}

/* Animation for smooth expand/collapse */
.song-group {
    transition: box-shadow 0.2s ease;
}

.group-content {
    animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Tree View Styles - Matching Desktop App */
.song-tree {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tree-node {
    margin-bottom: 5px;
}

.tree-item {
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.tree-item:hover {
    background: #f8f9fa;
}

.tree-item.selected {
    background: #e3f2fd;
    color: #1565c0;
    font-weight: 500;
}

.tree-item.artist {
    font-weight: 600;
    color: #495057;
}

.tree-item.song {
    padding-left: 30px;
    color: #6c757d;
    cursor: pointer;
}

.tree-item.folder {
    color: #856404;
}

.tree-icon {
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.tree-expand {
    cursor: pointer;
    font-size: 12px;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
    transition: all 0.2s;
}

.tree-expand:hover {
    background: #dee2e6;
}

.tree-children {
    margin-left: 20px;
    margin-top: 5px;
}

.tree-children.collapsed {
    display: none;
}

.tree-label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tree-item.song .tree-label {
    font-size: 13px;
}

.resource-indicator {
    font-size: 0.8rem;
    opacity: 0.7;
    margin-left: auto;
}

/* Lyrics Header and Expand Button */
.lyrics-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.lyrics-header h4 {
    margin: 0;
}

.lyrics-expand-btn {
    background: none;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 6px;
    cursor: pointer;
    color: #6c757d;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lyrics-expand-btn:hover {
    background: #f8f9fa;
    color: #2c5aa0;
    border-color: #2c5aa0;
}

.lyrics-expand-btn svg {
    display: block;
}

/* Fullscreen Lyrics Modal */
.fullscreen-lyrics-modal {
    z-index: 10000;
}

.fullscreen-lyrics-content {
    max-width: 900px;
    width: 95vw;
    max-height: 95vh;
    height: 95vh;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.fullscreen-lyrics-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px 30px;
    border-bottom: 1px solid #dee2e6;
    background: #f8f9fa;
}

.fullscreen-lyrics-title h2 {
    margin: 0;
    color: #2c5aa0;
    font-size: 1.5rem;
}

.fullscreen-lyrics-title p {
    margin: 5px 0 0 0;
    color: #6c757d;
    font-size: 1rem;
}

.fullscreen-close-btn {
    background: none;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 8px;
    cursor: pointer;
    color: #6c757d;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fullscreen-close-btn:hover {
    background: #e9ecef;
    color: #dc3545;
    border-color: #dc3545;
}

.fullscreen-lyrics-body {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}

.fullscreen-lyrics-text {
    font-family: 'Courier New', Courier, monospace;
    font-size: 16px;
    line-height: 1.8;
    color: #212529;
    white-space: pre-wrap;
    word-wrap: break-word;
    margin: 0;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .fullscreen-lyrics-content {
        width: 100vw;
        height: 100vh;
        max-width: 100vw;
        max-height: 100vh;
        border-radius: 0;
    }

    .fullscreen-lyrics-header {
        padding: 15px 20px;
    }

    .fullscreen-lyrics-title h2 {
        font-size: 1.25rem;
    }

    .fullscreen-lyrics-body {
        padding: 20px;
    }

    .fullscreen-lyrics-text {
        font-size: 14px;
        line-height: 1.6;
    }
}

/* Help Modal Styles */
.help-modal {
    z-index: 10000;
}

.help-content {
    max-width: 800px;
    width: 90vw;
    max-height: 90vh;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.help-header {
    padding: 20px 30px;
    border-bottom: 1px solid #dee2e6;
    background: linear-gradient(135deg, #2c5aa0 0%, #1e3a70 100%);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.help-header h2 {
    margin: 0;
    color: white;
}

.help-header .close {
    color: white;
    opacity: 0.9;
}

.help-header .close:hover {
    opacity: 1;
}

.help-body {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
    background: #ffffff;
}

.help-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9ecef;
}

.help-section:last-child {
    border-bottom: none;
}

.help-section h3 {
    color: #2c5aa0;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.25rem;
}

.help-section p {
    margin: 10px 0;
    line-height: 1.6;
    color: #495057;
}

.help-section ul,
.help-section ol {
    margin: 10px 0;
    padding-left: 25px;
    line-height: 1.8;
    color: #495057;
}

.help-section li {
    margin: 8px 0;
}

.help-section ul ul,
.help-section ol ul {
    margin-top: 5px;
    margin-bottom: 5px;
}

.help-section strong {
    color: #212529;
    font-weight: 600;
}

.help-section kbd {
    display: inline-block;
    padding: 3px 8px;
    font-family: monospace;
    font-size: 0.9em;
    color: #212529;
    background-color: #f1f3f5;
    border: 1px solid #adb5bd;
    border-radius: 4px;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.1);
}

.help-section a {
    color: #2c5aa0;
    text-decoration: none;
}

.help-section a:hover {
    text-decoration: underline;
}

.help-footer {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 0;
}

.help-version {
    margin-top: 10px;
    font-size: 0.9rem;
    color: #6c757d;
    font-style: italic;
}

/* Mobile adjustments for help */
@media (max-width: 768px) {
    .help-content {
        width: 100vw;
        max-width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .help-header {
        padding: 15px 20px;
    }

    .help-header h2 {
        font-size: 1.25rem;
    }

    .help-body {
        padding: 20px;
    }

    .help-section h3 {
        font-size: 1.1rem;
    }

    .help-section ul,
    .help-section ol {
        padding-left: 20px;
    }
}

/* Guest Signup Modal */
.guest-signup-modal {
    z-index: 10000;
}

.guest-signup-modal .modal-content {
    max-width: 600px;
    width: 90vw;
}

.guest-signup-modal .modal-header {
    background: linear-gradient(135deg, #2c5aa0 0%, #1e3a70 100%);
    color: white;
    padding: 1.5rem 2rem;
    border-radius: 8px 8px 0 0;
}

.guest-signup-modal .modal-header h2 {
    margin: 0;
    color: white;
    font-size: 1.5rem;
}

.guest-signup-modal .modal-header .close {
    color: white;
    font-size: 2rem;
    font-weight: 300;
    opacity: 0.8;
    cursor: pointer;
    transition: opacity 0.2s;
}

.guest-signup-modal .modal-header .close:hover {
    opacity: 1;
}

.guest-signup-modal .modal-body {
    padding: 2rem;
}

.signup-intro {
    font-size: 1.1rem;
    color: #495057;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.signup-benefits {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.signup-benefits li {
    padding: 0.75rem 0;
    margin-bottom: 0.5rem;
    color: #495057;
    font-size: 1rem;
    line-height: 1.6;
    display: flex;
    align-items: flex-start;
}

.signup-benefits li::before {
    content: "✓";
    color: #28a745;
    font-size: 1.25rem;
    font-weight: bold;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

.signup-benefits li strong {
    color: #2c5aa0;
}

.signup-cta {
    font-size: 1rem;
    color: #6c757d;
    text-align: center;
    margin: 1.5rem 0;
    font-style: italic;
}

.signup-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.btn-large {
    padding: 0.75rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
}

/* Mobile adjustments for guest signup modal */
@media (max-width: 768px) {
    .guest-signup-modal .modal-content {
        width: 95vw;
    }

    .guest-signup-modal .modal-header {
        padding: 1rem 1.5rem;
    }

    .guest-signup-modal .modal-header h2 {
        font-size: 1.25rem;
    }

    .guest-signup-modal .modal-body {
        padding: 1.5rem;
    }

    .signup-intro {
        font-size: 1rem;
    }

    .signup-benefits li {
        font-size: 0.95rem;
    }

    .signup-actions {
        flex-direction: column;
        gap: 0.75rem;
    }

    .btn-large {
        width: 100%;
        padding: 0.65rem 1.5rem;
        font-size: 1rem;
    }
}

/* Import Demo Songs Modal */
.import-demo-modal {
    z-index: 10000;
}

.import-demo-modal .modal-content {
    max-width: 600px;
    width: 90vw;
}

.import-demo-modal .modal-header {
    background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
    color: white;
    padding: 1.5rem 2rem;
    border-radius: 8px 8px 0 0;
    text-align: center;
}

.import-demo-modal .modal-header h2 {
    margin: 0;
    color: white;
    font-size: 1.75rem;
}

.import-demo-modal .modal-body {
    padding: 2rem;
}

.import-intro {
    font-size: 1.1rem;
    color: #495057;
    margin-bottom: 1.5rem;
    line-height: 1.6;
    text-align: center;
}

.import-benefits {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1.5rem 0;
    border-left: 4px solid #28a745;
}

.import-benefits h4 {
    margin: 0 0 1rem 0;
    color: #28a745;
    font-size: 1.1rem;
}

.import-benefits ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.import-benefits li {
    padding: 0.5rem 0;
    color: #495057;
    font-size: 1rem;
    line-height: 1.6;
    display: flex;
    align-items: flex-start;
}

.import-benefits li::before {
    content: "•";
    color: #28a745;
    font-size: 1.5rem;
    font-weight: bold;
    margin-right: 0.75rem;
    flex-shrink: 0;
    line-height: 1.2;
}

.import-benefits li strong {
    color: #212529;
}

.import-note {
    font-size: 0.95rem;
    color: #6c757d;
    text-align: center;
    margin: 1.5rem 0;
    font-style: italic;
}

.import-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-direction: column;
    align-items: center;
}

.import-actions .btn {
    min-width: 200px;
}

/* Mobile adjustments for import demo modal */
@media (max-width: 768px) {
    .import-demo-modal .modal-content {
        width: 95vw;
    }

    .import-demo-modal .modal-header {
        padding: 1rem 1.5rem;
    }

    .import-demo-modal .modal-header h2 {
        font-size: 1.35rem;
    }

    .import-demo-modal .modal-body {
        padding: 1.5rem;
    }

    .import-intro {
        font-size: 1rem;
    }

    .import-benefits {
        padding: 1rem;
    }

    .import-benefits li {
        font-size: 0.95rem;
    }

    .import-actions .btn {
        width: 100%;
        min-width: 0;
    }
}

/* Demo Mode Welcome Modal */
.demo-welcome-modal {
    z-index: 10001; /* Higher than other modals */
}

.demo-welcome-content {
    max-width: 650px;
    width: 90vw;
}

.demo-welcome-header {
    background: linear-gradient(135deg, #2c5aa0 0%, #1e3a70 100%);
    color: white;
    padding: 1.5rem 2rem;
    border-radius: 8px 8px 0 0;
    text-align: center;
}

.demo-welcome-header h2 {
    margin: 0;
    color: white;
    font-size: 1.75rem;
}

.demo-welcome-modal .modal-body {
    padding: 2rem;
}

.demo-notice {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 1.25rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
}

.demo-intro {
    font-size: 1.1rem;
    color: #856404;
    margin: 0 0 0.75rem 0;
}

.demo-notice p:last-child {
    margin: 0;
    color: #856404;
}

.demo-features {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.demo-features h4 {
    margin: 0 0 1rem 0;
    color: #495057;
    font-size: 1.1rem;
}

.demo-features ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.demo-features li {
    padding: 0.5rem 0;
    color: #495057;
    font-size: 1rem;
    line-height: 1.6;
    display: flex;
    align-items: flex-start;
}

.demo-features li::before {
    content: "✓";
    color: #28a745;
    font-size: 1.25rem;
    font-weight: bold;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

.demo-continue {
    text-align: center;
    margin: 1.5rem 0;
}

.demo-cta {
    text-align: center;
    margin: 1.5rem 0;
}

.demo-cta h4 {
    margin: 0 0 0.75rem 0;
    color: #2c5aa0;
    font-size: 1.2rem;
}

.demo-cta p {
    margin: 0;
    color: #495057;
    line-height: 1.6;
}

.demo-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-direction: column;
    align-items: center;
}

.demo-continue {
    display: flex;
    justify-content: center;
    margin: 1.5rem 0;
}

.demo-continue .btn {
    width: 100%;
}

.demo-actions .btn {
    width: 100%;
}

.btn-tertiary {
    background: linear-gradient(135deg, #90ee90, #7ec97e);
    color: white;
}

.btn-tertiary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(144, 238, 144, 0.3);
}

/* Mobile adjustments for demo welcome modal */
@media (max-width: 768px) {
    .demo-welcome-content {
        width: 95vw;
    }

    .demo-welcome-header {
        padding: 1rem 1.5rem;
    }

    .demo-welcome-header h2 {
        font-size: 1.35rem;
    }

    .demo-welcome-modal .modal-body {
        padding: 1.5rem;
    }

    .demo-intro {
        font-size: 1rem;
    }

    .demo-features {
        padding: 1rem;
    }

    .demo-features li {
        font-size: 0.95rem;
    }

    .demo-actions .btn {
        width: 100%;
        min-width: 0;
    }
}

/* Spotify Import Dialog */
.spotify-import-content {
    max-width: 500px;
}

.spotify-source {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.spotify-source input[type="checkbox"] {
    margin-right: 0.5rem;
    cursor: pointer;
}

.spotify-source label {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin: 0;
}

.spotify-count {
    color: #6c757d;
    font-size: 0.9rem;
    font-weight: normal;
    margin-left: 0.5rem;
}

.spotify-sublist {
    margin-top: 1rem;
    padding: 0.75rem;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    max-height: 200px;
    overflow-y: auto;
}

.spotify-playlist-item {
    padding: 0.5rem;
    border-bottom: 1px solid #e9ecef;
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
}

.spotify-playlist-item:last-child {
    border-bottom: none;
}

.spotify-options {
    margin-top: 0.75rem;
    padding: 0.75rem;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
}

.spotify-option-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.spotify-option-group label {
    margin: 0;
    font-size: 0.9rem;
    min-width: 60px;
}

.spotify-option-group input[type="number"],
.spotify-option-group select {
    padding: 0.375rem 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 0.9rem;
}

.spotify-progress-bar {
    width: 100%;
    height: 24px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin: 1rem 0;
}

.spotify-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #1DB954, #1ed760);
    transition: width 0.3s ease;
}

#spotifyResults {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 1.5rem;
    text-align: center;
}

#spotifyResults .result-number {
    font-size: 2rem;
    font-weight: bold;
    color: #1DB954;
}

#spotifyResults .result-label {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

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