/* Gallery Page Specific Styles */

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #000 0%, #2a2a2a 100%);
    color: #FFD700;
    padding: 70px 20px;
    text-align: center;
}

.hero h1 {
    font-size: 56px;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero p {
    font-size: 20px;
    color: #FFF;
}

/* Content Container */
.content-container {
    max-width: 1600px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Filters Bar */
.filters-bar {
    background-color: #1a1a1a;
    padding: 25px 30px;
    margin-bottom: 40px;
    border-radius: 8px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.filter-group {
    display: flex;
    flex-direction: column;
}

.filter-label {
    color: #FFD700;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-select {
    padding: 10px 12px;
    font-size: 15px;
    background-color: #2a2a2a;
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 5px;
    color: #e0e0e0;
    font-family: 'Georgia', serif;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-select:focus {
    outline: none;
    border-color: #FFD700;
    background-color: #333;
}

.filter-select:hover {
    border-color: rgba(255, 215, 0, 0.6);
}

.filter-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 10px;
}

.filter-button {
    padding: 10px 25px;
    font-size: 14px;
    font-weight: bold;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Georgia', serif;
}

.apply-filter {
    background-color: #FFD700;
    color: #000;
}

.apply-filter:hover {
    background-color: #FFF;
    transform: scale(1.05);
}

.clear-filter {
    background-color: transparent;
    color: #e0e0e0;
    border: 1px solid rgba(255, 215, 0, 0.3);
}

.clear-filter:hover {
    background-color: #2a2a2a;
    border-color: rgba(255, 215, 0, 0.6);
    transform: scale(1.05);
}

.results-info {
    text-align: center;
    color: #c0c0c0;
    font-size: 16px;
    margin-bottom: 30px;
    padding: 12px;
    background-color: transparent;
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 1;
    border: 1px solid rgba(255, 215, 0, 0.3);
    transition: all 0.3s;
    background-color: #1a1a1a;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
    border-color: #FFD700;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0;
    transition: opacity 0.3s ease-in;
}

.gallery-item img.loaded {
    opacity: 1;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 20px 15px 15px 15px;
}

.gallery-title {
    color: #FFD700;
    font-size: 18px;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin: 40px 0;
}

.page-button {
    background-color: #FFD700;
    color: #000;
    padding: 12px 20px;
    font-size: 16px;
    font-weight: bold;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Georgia', serif;
}

.page-button:hover:not(:disabled) {
    background-color: #FFF;
    transform: scale(1.05);
}

.page-button:disabled {
    background-color: #555;
    color: #888;
    cursor: not-allowed;
}

.page-info {
    color: #FFD700;
    font-size: 18px;
    font-weight: bold;
}

/* Photo Viewer */
.photo-viewer {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.98);
    z-index: 3000;
}

.photo-viewer.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.viewer-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background-color: #FFD700;
    color: #000;
    border: none;
    width: 50px;
    height: 50px;
    font-size: 32px;
    font-weight: bold;
    border-radius: 50%;
    cursor: pointer;
    z-index: 3001;
    transition: all 0.3s;
}

.viewer-close:hover {
    background-color: #FFF;
    transform: scale(1.1);
}

.viewer-main {
    display: flex;
    gap: 20px;
    width: 95%;
    height: 95%;
    max-width: 1800px;
}

.viewer-image-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.viewer-image-container {
    background-color: #000;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 2px solid #FFD700;
}

.viewer-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s;
}

.viewer-image.zoomed {
    cursor: move;
}

.viewer-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    background-color: #2a2a2a;
    padding: 15px;
    border-radius: 50px;
}

.control-btn {
    background-color: #FFD700;
    color: #000;
    border: none;
    width: 45px;
    height: 45px;
    font-size: 20px;
    font-weight: bold;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
}

.control-btn:hover {
    background-color: #FFF;
    transform: scale(1.1);
}

.zoom-display {
    background-color: #333;
    color: #FFD700;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 18px;
    font-weight: bold;
    min-width: 80px;
    text-align: center;
}

.viewer-sidebar {
    width: 350px;
    background-color: #2a2a2a;
    padding: 30px;
    border: 2px solid #FFD700;
    border-radius: 8px;
    overflow-y: auto;
}

.viewer-title {
    color: #FFD700;
    font-size: 28px;
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.3;
}

.viewer-meta {
    margin-bottom: 25px;
}

.meta-row {
    color: #e0e0e0;
    font-size: 16px;
    margin-bottom: 10px;
}

.meta-row strong {
    color: #FFD700;
}

.viewer-description {
    color: #e0e0e0;
    font-size: 16px;
    line-height: 1.8;
    padding-top: 20px;
    border-top: 2px solid #FFD700;
}

.description-toggle {
    display: none;
    background-color: #FFD700;
    color: #000;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 15px;
    width: 100%;
    transition: all 0.3s;
    font-family: 'Georgia', serif;
}

.description-toggle:hover {
    background-color: #FFF;
}

/* Tutorial Modal */
.tutorial-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 3001;
    justify-content: center;
    align-items: center;
}

.tutorial-content {
    background-color: #2a2a2a;
    border: 3px solid #FFD700;
    border-radius: 12px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.tutorial-title {
    color: #FFD700;
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
    font-weight: bold;
}

.tutorial-section {
    margin-bottom: 30px;
}

.tutorial-section h3 {
    color: #FFD700;
    font-size: 22px;
    margin-bottom: 15px;
    font-weight: bold;
}

.tutorial-section p {
    color: #e0e0e0;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 10px;
}

.tutorial-section p strong {
    color: #FFF;
    font-weight: bold;
}

.tutorial-section .symbol {
    font-size: 24px;
    font-weight: 900;
    color: #FFD700;
}

.tutorial-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-top: 35px;
    padding-top: 25px;
    border-top: 2px solid #FFD700;
}

.tutorial-checkbox {
    color: #e0e0e0;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.tutorial-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #FFD700;
}

.tutorial-btn {
    background-color: #FFD700;
    color: #000;
    border: none;
    padding: 15px 40px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Georgia', serif;
}

.tutorial-btn:hover {
    background-color: #FFF;
    transform: scale(1.05);
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .filter-row {
        grid-template-columns: 1fr;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    .viewer-main {
        flex-direction: column;
        width: 100%;
        height: 100%;
        gap: 0;
    }

    .viewer-image-wrapper {
        flex: 1;
        min-height: 0;
    }

    .viewer-sidebar {
        width: 100%;
        max-height: none;
        height: auto;
        padding: 20px;
        border-top: 3px solid #FFD700;
        border-left: none;
        border-right: none;
        border-bottom: none;
        border-radius: 0;
        overflow-y: visible;
    }

    .viewer-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 24px;
    }

    .control-btn {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }

    .viewer-title {
        font-size: 20px;
        margin-bottom: 12px;
    }

    .viewer-meta {
        margin-bottom: 12px;
    }

    .meta-row {
        font-size: 14px;
        margin-bottom: 6px;
    }

    .viewer-description {
        font-size: 14px;
        line-height: 1.6;
        padding-top: 12px;
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        border-top: none;
        padding-top: 0;
        transition: all 0.3s ease;
    }

    .viewer-description.expanded {
        max-height: 500px;
        opacity: 1;
        padding-top: 12px;
        margin-top: 12px;
        border-top: 2px solid #FFD700;
    }

    .description-toggle {
        display: block;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 38px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .viewer-controls {
        padding: 10px;
        gap: 8px;
    }

    .zoom-display {
        min-width: 60px;
        font-size: 14px;
        padding: 8px 15px;
    }

    .tutorial-content {
        padding: 25px;
        width: 95%;
    }

    .tutorial-title {
        font-size: 26px;
    }

    .tutorial-section h3 {
        font-size: 20px;
    }
}
