/* ========================================
   RESPONSIVE UTILITIES
   Shared responsive styles for layout
   ======================================== */

/* Desktop styles - default */
.header-toggle-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-label {
    font-size: 1.2rem;
    font-weight: bold;
}

.header-stack {
    justify-content: space-between;
}

.footer-stack {
    display: flex;
    width: 100%;
}

.footer-text {
    flex: 1;
}

.footer-left {
    text-align: left;
}

.footer-center {
    text-align: center;
}

.footer-right {
    text-align: right;
}

.body-content {
    padding: 1rem;
}

/* Tablet styles */
@media (max-width: 1024px) {
    .header-label {
        font-size: 1rem;
    }

    .footer-stack {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 0.5rem !important;
    }

    .footer-text {
        text-align: left !important;
    }
}

/* Mobile styles */
@media (max-width: 768px) {
    .header-label {
        font-size: 0.9rem;
    }

    .body-content {
        padding: 0.5rem;
    }

    .mobile-sidebar {
        position: fixed !important;
        z-index: 1001;
        height: 100vh;
        box-shadow: 2px 0 5px rgba(0,0,0,0.3);
    }

    /* Overlay to close sidebar when clicking outside */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 1000;
        cursor: pointer;
    }

    /* Ensure toggle button stays above sidebar */
    .sidebar-toggle {
        position: relative;
        z-index: 1002;
    }

    /* Mobile menu header with close button */
    .mobile-menu-header {
        display: flex;
        justify-content: flex-end;
        padding: 0.5rem;
        background-color: #000;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .mobile-close-button {
        color: #fff !important;
    }

    .mobile-close-button:hover {
        color: #FFD700 !important;
        background-color: rgba(255, 255, 255, 0.1) !important;
    }

    .footer-stack {
        padding: 0.5rem !important;
    }

    .footer-text {
        font-size: 0.75rem;
    }
}

/* Small mobile styles */
@media (max-width: 480px) {
    .header-label {
        font-size: 0.8rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 200px;
    }

    .footer-center {
        display: none;
    }

    .footer-text {
        font-size: 0.7rem;
    }
}

/* ========================================
   HOME PAGE STYLES
   Hero section with rotating text
   ======================================== */

.nss-style {
    height: 800px;
    background-image: url(/images/nssworldmainpage.jpg);
    background-position-x: left;
    background-position-y: 1rem;
    background-repeat: no-repeat;
    background-size: cover;
}

.title-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
}

.nss-main-title {
    margin: 0;
    flex-shrink: 0;
}

.text-rotator {
    min-height: 2em;
    display: flex;
    align-items: center;
    overflow: hidden;
    position: relative;
    flex-grow: 1;
}

    .text-rotator h3 {
        margin: 0;
        white-space: nowrap;
        position: absolute;
    }

/* Animation classes */
.slide-in {
    animation: slideIn 2s ease-out forwards;
}

.pause {
    opacity: 1;
    left: 0;
}

.fade-out {
    animation: fadeOut 0.8s ease-out forwards;
}

@keyframes slideIn {
    from {
        left: 100%;
        opacity: 0;
    }

    to {
        left: 0;
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

/* Home page responsive styles */
@media (max-width: 768px) {
    .nss-style {
        height: 500px;
        background-size: cover;
        background-position: center center;
    }

    .title-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .nss-main-title {
        font-size: 2rem;
    }

    .text-rotator h3 {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .nss-style {
        height: 400px;
    }

    .nss-main-title {
        font-size: 1.5rem;
    }

    .text-rotator h3 {
        font-size: 1rem;
    }
}

/* ========================================
   FLIPPER PAGE STYLES
   Generic styles for pages with navigation and content flipping
   Used by: ArtistDiscography, WeddingsPerformed, YouTubeVideos, SpotifyPlaylists
   ======================================== */

.flipper-panel {
    margin-top: 20px;
}

.flipper-navigation {
    margin-bottom: 20px;
}

.flipper-card {
    margin-bottom: 20px;
    padding: 1rem;
    box-shadow: none;
}

.flipper-image {
    margin: auto;
    max-width: 100%;
}

/* Flipper responsive styles */
@media (max-width: 768px) {
    .flipper-card {
        padding: 0.75rem;
    }

    .flipper-image {
        max-width: 100%;
        margin-bottom: 1rem;
    }
}

@media (max-width: 480px) {
    .flipper-card {
        padding: 0.5rem;
    }

    .flipper-panel {
        margin-top: 10px;
    }

    .flipper-navigation {
        margin-bottom: 10px;
    }
}

/* ========================================
   DATA GRID PAGE STYLES
   Generic styles for pages with data grids and filters
   Used by: CDCollection, ConcertsAttended, ShowsAppearances
   ======================================== */

.data-grid-filter-container {
    margin-bottom: 20px;
}

.data-grid-filter-label {
    margin-right: 10px;
}

.data-grid-filter-dropdown {
    width: 500px;
}

.data-grid-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.data-grid-loading-content {
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
    min-width: 300px;
}

.data-grid-loading-progress {
    margin-bottom: 15px;
}

.data-grid-loading-text {
    margin-top: 10px;
}

.data-grid-no-data-text {
    font-size: 12px;
    opacity: 0.5;
}

.data-grid-modal-content {
    display: flex;
    flex-direction: column;
    min-height: 400px;
}

.data-grid-modal-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 10px;
}

.data-grid-modal-text {
    white-space: pre-wrap;
    font-family: monospace;
}

.data-grid-modal-footer {
    flex: 0 0 auto;
    padding: 10px;
    text-align: right;
    margin-top: auto;
}

/* Data grid cell content alignment */
.data-grid-cell-center {
    text-align: center;
    vertical-align: top;
}

.data-grid-cell-justified {
    text-align: justify;
    vertical-align: top;
    word-wrap: break-word;
    white-space: normal;
    overflow-wrap: break-word;
}

.data-grid-cancelled-indicator {
    margin-bottom: 5px;
}

    .data-grid-cancelled-indicator img {
        display: block;
        margin: 0 auto;
    }

.data-grid-cancelled-notes {
    font-style: italic;
}

/* Data Grid responsive styles */
@media (max-width: 1024px) {
    .data-grid-filter-dropdown {
        width: 400px;
    }
}

@media (max-width: 768px) {
    .data-grid-filter-container {
        margin-bottom: 15px;
    }

    .data-grid-filter-dropdown {
        width: 100%;
        max-width: 350px;
    }

    .data-grid-loading-content {
        padding: 20px;
        min-width: 250px;
    }

    .data-grid-modal-content {
        min-height: 300px;
    }
}

@media (max-width: 480px) {
    .data-grid-filter-container {
        margin-bottom: 10px;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .data-grid-filter-label {
        margin-right: 0;
        margin-bottom: 0.25rem;
    }

    .data-grid-filter-dropdown {
        width: 100%;
        max-width: 100%;
    }

    .data-grid-loading-content {
        padding: 15px;
        min-width: 200px;
    }

    .data-grid-no-data-text {
        font-size: 11px;
    }

    .data-grid-modal-content {
        min-height: 250px;
    }

    .data-grid-modal-body {
        padding: 5px;
    }

    .data-grid-modal-footer {
        padding: 5px;
    }

    .data-grid-modal-text {
        font-size: 0.85rem;
    }
}

/* ========================================
   COMMON RESPONSIVE UTILITIES
   Reusable classes for any component
   ======================================== */

/* Responsive containers */
.container-responsive {
    width: 100%;
    padding: 1rem;
}

@media (max-width: 768px) {
    .container-responsive {
        padding: 0.5rem;
    }
}

/* Responsive text sizes */
.text-responsive-large {
    font-size: 1.5rem;
}

.text-responsive-medium {
    font-size: 1.2rem;
}

.text-responsive-small {
    font-size: 1rem;
}

@media (max-width: 768px) {
    .text-responsive-large {
        font-size: 1.2rem;
    }

    .text-responsive-medium {
        font-size: 1rem;
    }

    .text-responsive-small {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .text-responsive-large {
        font-size: 1rem;
    }

    .text-responsive-medium {
        font-size: 0.9rem;
    }

    .text-responsive-small {
        font-size: 0.8rem;
    }
}

/* Responsive spacing */
.gap-responsive {
    gap: 1rem;
}

@media (max-width: 768px) {
    .gap-responsive {
        gap: 0.5rem;
    }
}

/* Hide on mobile */
.hide-mobile {
    display: block;
}

@media (max-width: 768px) {
    .hide-mobile {
        display: none;
    }
}

/* Show only on mobile */
.show-mobile {
    display: none;
}

@media (max-width: 768px) {
    .show-mobile {
        display: block;
    }
}
