/* Gallery Page Styles */

/* Navigation */
.gallery-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 100;
}

.gallery-nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.gallery-nav-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.nav-back {
    font-family: var(--font-sans);
    color: var(--color-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.nav-back:hover {
    color: var(--color-primary);
}

.nav-admin-link {
    border: 1px solid rgba(44, 62, 80, 0.2);
    border-radius: 999px;
    padding: 0.45rem 1rem;
    font-size: 0.85rem;
    text-decoration: none;
    color: var(--color-secondary);
    background: #fff;
}

.nav-admin-link:hover {
    background: var(--color-secondary);
    color: #fff;
}

.logout-form {
    margin: 0;
}

.logout-btn {
    border: 1px solid rgba(44, 62, 80, 0.2);
    background: white;
    color: var(--color-secondary);
    border-radius: 999px;
    font-family: var(--font-sans);
    font-size: 0.85rem;
    padding: 0.45rem 1rem;
    cursor: pointer;
}

.logout-btn:hover {
    background: var(--color-secondary);
    color: white;
}

.gallery-auth {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg, #fdfbfb 0%, #f5f3f0 100%);
}

.auth-card {
    max-width: 520px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
    padding: 2.2rem;
    border: 1px solid rgba(44, 62, 80, 0.08);
}

.auth-title {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4.5vw, 2.8rem);
    color: var(--color-secondary);
    margin-bottom: 0.7rem;
}

.auth-text {
    color: var(--color-text-light);
    margin-bottom: 1.2rem;
}

.auth-form {
    display: grid;
    gap: 0.7rem;
}

.auth-label {
    font-size: 0.9rem;
    color: var(--color-secondary);
    font-weight: 500;
}

.auth-input {
    width: 100%;
    border: 1px solid #d6d8db;
    border-radius: 10px;
    padding: 0.75rem 0.9rem;
    font-size: 1rem;
    font-family: var(--font-sans);
    outline: none;
}

.auth-input:focus {
    border-color: var(--color-secondary);
    box-shadow: 0 0 0 2px rgba(44, 62, 80, 0.08);
}

.auth-submit {
    margin-top: 0.5rem;
    border: none;
    background: var(--color-secondary);
    color: white;
    border-radius: 999px;
    padding: 0.75rem 1.2rem;
    font-family: var(--font-sans);
    font-size: 1rem;
    cursor: pointer;
}

.auth-submit:hover {
    background: #1a2a39;
}

.auth-error {
    margin-top: 1rem;
    color: #9d1f1f;
    font-size: 0.95rem;
}

.auth-note {
    margin-top: 1rem;
    color: var(--color-text-light);
    font-size: 0.82rem;
}

.moderation-section {
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg, #fdfbfb 0%, #f5f3f0 100%);
    min-height: 100vh;
}

.moderation-summary {
    text-align: center;
    color: var(--color-text-light);
    margin-top: -1.5rem;
    margin-bottom: 2rem;
}

.moderation-subtitle {
    font-family: var(--font-serif);
    font-size: clamp(1.7rem, 3vw, 2.2rem);
    color: var(--color-secondary);
    margin: 1.8rem 0 1rem;
}

.moderation-empty {
    color: var(--color-text-light);
}

.moderation-flash {
    border-radius: 10px;
    padding: 0.8rem 1rem;
    margin-bottom: 1rem;
}

.moderation-flash.success {
    background: #e8f5ec;
    color: #1d6b36;
}

.moderation-flash.error {
    background: #f9e7e7;
    color: #9d1f1f;
}

.moderation-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.moderation-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.moderation-image {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

.moderation-meta {
    padding: 0.8rem 0.9rem 0.3rem;
    font-size: 0.85rem;
    color: var(--color-text-light);
    display: grid;
    gap: 0.2rem;
}

.moderation-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    padding: 0.8rem 0.9rem 1rem;
}

.moderation-approve,
.moderation-reject {
    border: none;
    border-radius: 999px;
    padding: 0.6rem 0.7rem;
    color: #fff;
    cursor: pointer;
    font-family: var(--font-sans);
    font-size: 0.9rem;
}

.moderation-approve {
    background: #1f7a3f;
}

.moderation-reject {
    background: #9d1f1f;
}

.moderation-approve:hover {
    background: #176032;
}

.moderation-reject:hover {
    background: #7a1717;
}

/* Gallery Hero */
.gallery-hero {
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg, #fdfbfb 0%, #f5f3f0 100%);
    text-align: center;
}

.gallery-title {
    font-family: var(--font-serif);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 400;
    color: var(--color-secondary);
    margin-bottom: 1rem;
}

.gallery-subtitle {
    font-family: var(--font-sans);
    font-size: 1.2rem;
    color: var(--color-text-light);
    font-weight: 300;
}

/* Upload Section */
.upload-section {
    background: var(--color-bg-white);
    padding: 5rem 0;
}

.upload-area {
    max-width: 800px;
    margin: 0 auto;
}

.upload-box {
    border: 3px dashed var(--color-primary);
    border-radius: 16px;
    padding: 4rem 2rem;
    text-align: center;
    background: var(--color-bg-light);
    transition: all 0.3s ease;
    cursor: pointer;
}

.upload-box:hover {
    background: #f5f3f0;
    border-color: var(--color-secondary);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.upload-box.drag-over {
    background: #fff;
    border-color: var(--color-secondary);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.upload-box h3 {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
    font-weight: 400;
}

.upload-box > p {
    color: var(--color-text-light);
    margin-bottom: 2rem;
}

.honeypot-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.upload-btn {
    background: var(--color-primary);
    color: white;
    border: none;
    padding: 1rem 3rem;
    font-size: 1.1rem;
    font-family: var(--font-sans);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.upload-actions {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.upload-submit-btn {
    background: var(--color-secondary);
    color: white;
    border: none;
    padding: 1rem 2.2rem;
    font-size: 1.05rem;
    font-family: var(--font-sans);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.upload-btn:hover,
.upload-submit-btn:hover {
    background: var(--color-secondary);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.upload-submit-btn:hover {
    background: #1a2a39;
}

.upload-btn:disabled,
.upload-submit-btn:disabled {
    cursor: not-allowed;
    opacity: 0.65;
    transform: none;
    box-shadow: none;
}

.upload-note {
    margin-top: 1.5rem;
    font-size: 0.85rem;
    color: var(--color-text-light);
}

.selected-files {
    margin-top: 1.2rem;
}

.selected-files-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.4rem;
}

.selected-files-list li {
    font-size: 0.9rem;
    color: var(--color-text);
}

.upload-status {
    min-height: 1.5rem;
    margin-top: 1rem;
    font-size: 0.95rem;
    color: var(--color-text);
}

.upload-status.success {
    color: #1d6b36;
}

.upload-status.warning {
    color: #9b6500;
}

.upload-status.error {
    color: #9d1f1f;
}

/* Photos Section */
.photos-section {
    background: var(--color-bg-light);
    padding: 5rem 0;
}

.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    background: white;
    border: 2px solid var(--color-primary);
    color: var(--color-secondary);
    padding: 0.7rem 2rem;
    border-radius: 50px;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: var(--color-primary);
    color: white;
}

.filter-btn.active {
    background: var(--color-primary);
    color: white;
}

.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.photo-item {
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.photo-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.uploaded-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.photo-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #faf9f7 0%, #f5f3f0 100%);
    color: var(--color-text-light);
}

.photo-placeholder span {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.photo-placeholder p {
    text-align: center;
    font-size: 0.9rem;
    line-height: 1.6;
}

.photo-empty-state {
    grid-column: 1 / -1;
    min-height: 280px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #faf9f7 0%, #f5f3f0 100%);
    color: var(--color-text-light);
    text-align: center;
    padding: 2rem;
}

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

.photo-empty-state p {
    font-size: 1rem;
    line-height: 1.6;
}

.lightbox-open {
    overflow: hidden;
}

.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.8rem;
}

.lightbox[hidden] {
    display: none;
}

.lightbox-image {
    max-width: min(94vw, 1280px);
    max-height: 88vh;
    width: auto;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
    background: #111;
}

.lightbox-close,
.lightbox-nav {
    position: absolute;
    border: none;
    background: rgba(255, 255, 255, 0.17);
    color: #fff;
    width: 48px;
    height: 48px;
    border-radius: 999px;
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
    backdrop-filter: blur(3px);
}

.lightbox-close {
    top: 1.2rem;
    right: 1.2rem;
}

.lightbox-prev {
    left: 1.2rem;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-next {
    right: 1.2rem;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-close:hover,
.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Gallery Info */
.gallery-info {
    background: var(--color-bg-white);
    padding: 4rem 0;
}

.info-box {
    max-width: 700px;
    margin: 0 auto;
    background: var(--color-bg-light);
    padding: 2.5rem;
    border-radius: 12px;
    border-left: 4px solid var(--color-primary);
}

.info-box h3 {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    color: var(--color-secondary);
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.info-box ul {
    list-style: none;
    padding: 0;
}

.info-box li {
    padding: 0.7rem 0;
    padding-left: 2rem;
    position: relative;
    color: var(--color-text);
    line-height: 1.6;
}

.info-box li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--color-primary);
    font-size: 1.5rem;
    line-height: 1.2;
}

/* Responsive */
@media (max-width: 768px) {
    .gallery-nav {
        padding: 1rem 1.5rem;
    }

    .gallery-nav-inner {
        flex-wrap: wrap;
    }

    .gallery-nav-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .gallery-hero {
        padding: 10rem 0 3rem;
    }
    
    .upload-box {
        padding: 3rem 1.5rem;
    }

    .upload-actions {
        flex-direction: column;
    }
    
    .photo-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }
    
    .gallery-filters {
        padding: 0 1rem;
    }
    
    .filter-btn {
        padding: 0.6rem 1.5rem;
        font-size: 0.85rem;
    }
    
    .info-box {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .gallery-title {
        font-size: 2rem;
    }
    
    .upload-icon {
        font-size: 3rem;
    }
    
    .upload-box h3 {
        font-size: 1.4rem;
    }
    
    .upload-btn {
        padding: 0.8rem 2rem;
        font-size: 1rem;
    }

    .upload-submit-btn {
        padding: 0.8rem 1.6rem;
        font-size: 0.95rem;
    }

    .auth-card {
        padding: 1.7rem 1.3rem;
    }

    .lightbox-close,
    .lightbox-nav {
        width: 42px;
        height: 42px;
    }
}
