/* Minimalist Gallery - Prototype 1: Pure Masonry */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #000;
    color: #fff;
    overflow-x: hidden;
}

/* Gallery Layout with Sidebar */
.gallery-layout {
    display: flex;
    min-height: 100vh;
}

.gallery-sidebar {
    width: 280px;
    background: rgba(10, 10, 10, 0.95);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    transition: transform 0.3s ease;
    z-index: 100;
}

.sidebar-header {
    padding: 1rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-header h2 {
    font-size: 0.95rem;
    font-weight: 500;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.header-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.admin-toggle {
    background: none;
    border: none;
    color: #666;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.admin-toggle:hover {
    color: #fff;
}

.admin-toggle.active {
    color: rgba(45, 90, 45, 1);
}

.sidebar-minimize {
    background: none;
    border: none;
    color: #666;
    font-size: 1.3rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.sidebar-minimize:hover {
    color: #fff;
}

.sidebar-content {
    padding: 0.5rem 0;
}

.search-container {
    padding: 0.5rem 0;
    position: relative;
    margin-bottom: 0;
}

.search-input {
    width: 100%;
    padding: 0.4rem 1.8rem 0.4rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: none;
    border-radius: 2px;
    color: #fff;
    font-size: 0.8rem;
    font-family: inherit;
    transition: background 0.2s ease;
}

.search-input::placeholder {
    color: #666;
}

.search-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
}

.search-clear {
    position: absolute;
    right: 0.3rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.search-clear:hover {
    color: #fff;
}

.tree-item {
    padding: 0.4rem 1rem;
    margin: 0;
    cursor: pointer;
    color: #aaa;
    font-size: 0.85rem;
    transition: all 0.15s ease;
    user-select: none;
    font-weight: 400;
    letter-spacing: 0.2px;
}

.tree-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.tree-item.active {
    background: rgba(45, 90, 45, 0.4);
    color: #fff;
    border-left: 2px solid rgba(45, 90, 45, 1);
}

.tree-section {
    margin-top: 0.5rem;
}

.tree-section-header {
    padding: 0.5rem 1rem;
    font-weight: 600;
    color: #888;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tree-group {
    margin-left: 0;
}

.tree-parent {
    font-weight: 500;
    position: relative;
    color: #ddd;
}

.tree-expand {
    display: inline-block;
    transition: transform 0.2s ease;
    margin-right: 0.4rem;
    font-size: 0.9rem;
    color: #666;
    cursor: pointer;
    user-select: none;
}

.tree-expand:hover {
    color: #aaa;
}

.tree-expand.expanded {
    transform: rotate(90deg);
}

.tree-children {
    margin-left: 0.8rem;
}

.tree-child {
    font-size: 0.85rem;
    padding-left: 1.8rem;
    font-weight: 400;
}

.gallery-main {
    flex: 1;
    margin-left: 280px;
    transition: margin-left 0.3s ease;
}

.gallery-main.sidebar-closed {
    margin-left: 0;
}

.gallery-sidebar:not(.open) {
    transform: translateX(-100%);
}

.sidebar-expand-btn {
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 99;
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #666;
    width: 36px;
    height: 36px;
    border-radius: 4px;
    font-size: 1.2rem;
    cursor: pointer;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.sidebar-expand-btn:hover {
    background: rgba(20, 20, 20, 0.95);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

/* Masonry Grid using CSS Columns */
.masonry-grid {
    column-count: 4;
    column-gap: 8px;
    padding: 8px;
}

@media (max-width: 1200px) {
    .masonry-grid { column-count: 3; }
}

@media (max-width: 768px) {
    .masonry-grid { column-count: 2; }

    .gallery-sidebar:not(.open) {
        transform: translateX(-100%);
    }

    .gallery-main {
        margin-left: 0 !important;
    }
}

@media (max-width: 480px) {
    .masonry-grid { column-count: 1; }
}

.photo-item {
    break-inside: avoid;
    margin-bottom: 8px;
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border-radius: 2px;
}

.photo-item img {
    width: 100%;
    display: block;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.photo-item:hover img {
    transform: scale(1.02);
    filter: brightness(0.9);
}

/* Hover overlay with minimal info */
.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.photo-item:hover .photo-overlay {
    opacity: 1;
}

.photo-title {
    font-size: 0.9rem;
    font-weight: 400;
    margin-bottom: 0.2rem;
}

.photo-album {
    font-size: 0.75rem;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Floating filter chips */
.filter-bar {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    display: flex;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(10, 10, 10, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.filter-bar.hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
    pointer-events: none;
}

.filter-chip {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ccc;
    padding: 0.4rem 0.8rem;
    border-radius: 12px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.filter-chip:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    color: #fff;
}

.filter-chip.active {
    background: rgba(45, 90, 45, 0.5);
    border-color: rgba(45, 90, 45, 0.8);
    color: #fff;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-image {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.lightbox-close {
    position: fixed;
    top: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-close:hover {
    background: rgba(180, 30, 30, 0.5);
    border-color: rgba(180, 30, 30, 0.8);
    transform: scale(1.05);
}

.lightbox-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.05);
}

.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
.lightbox-next.with-sidebar { right: calc(350px + 1rem); }

.lightbox-info {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
}

.lightbox-title {
    font-size: 1.2rem;
    margin-bottom: 0.3rem;
}

.lightbox-album {
    font-size: 0.85rem;
    color: #999;
}

/* Lightbox Info Sidebar */
.lightbox-info-toggle {
    position: fixed;
    top: 1rem;
    right: 4.25rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-info-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.lightbox-share-btn {
    position: fixed;
    top: 1rem;
    right: 13.5rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-share-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.lightbox-fullscreen-btn {
    position: fixed;
    top: 1rem;
    right: 10.25rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-fullscreen-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.lightbox-slideshow-btn {
    position: fixed;
    top: 1rem;
    right: 7rem;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    backdrop-filter: blur(10px);
}

.lightbox-slideshow-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.lightbox-slideshow-btn.active {
    background: rgba(45, 90, 45, 0.4);
    border-color: rgba(45, 90, 45, 0.7);
}

.slideshow-speed-menu {
    position: fixed;
    top: 3.75rem;
    right: 7rem;
    background: rgba(10, 10, 10, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    padding: 0.5rem;
    z-index: 1003;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 80px;
}

.speed-label {
    font-size: 0.65rem;
    font-weight: 600;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
    padding: 0.2rem 0.3rem;
}

.speed-option {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ccc;
    padding: 0.35rem 0.5rem;
    border-radius: 2px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.speed-option:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.speed-option.active {
    background: rgba(45, 90, 45, 0.5);
    border-color: rgba(45, 90, 45, 0.8);
    color: #fff;
}

.share-feedback {
    position: fixed;
    top: 5rem;
    right: 1rem;
    z-index: 1003;
    background: rgba(45, 90, 45, 0.95);
    color: #fff;
    padding: 0.8rem 1.2rem;
    border-radius: 4px;
    font-size: 0.85rem;
    animation: slideInFade 0.3s ease;
    border: 1px solid rgba(45, 90, 45, 1);
}

@keyframes slideInFade {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.lightbox-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: 350px;
    height: 100vh;
    background: rgba(10, 10, 10, 0.98);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    z-index: 1001;
    overflow-y: auto;
}

.lightbox-sidebar.open {
    transform: translateX(0);
}

.lightbox-sidebar-content {
    padding: 4rem 1.5rem 1.5rem;
}

.lightbox-sidebar-content h3 {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 1.5rem;
    color: #fff;
}

.info-section {
    margin-bottom: 1.5rem;
}

.info-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.info-value {
    font-size: 0.9rem;
    color: #ccc;
    line-height: 1.5;
}

.info-item {
    padding: 0.4rem 0;
    color: #ddd;
}

.info-tag {
    display: inline-block;
    background: rgba(45, 90, 45, 0.3);
    border: 1px solid rgba(45, 90, 45, 0.5);
    padding: 0.3rem 0.7rem;
    border-radius: 2px;
    font-size: 0.8rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    color: #a8d5a8;
}

.lightbox-image.with-sidebar {
    max-width: calc(100% - 350px);
    margin-right: 350px;
}

/* Related Photos */
.related-photos-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.related-photos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.related-photo-item {
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 2px;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
    position: relative;
}

.related-photo-item:hover {
    transform: scale(1.05);
    opacity: 0.8;
}

.related-photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 768px) {
    .related-photos-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Lightbox Admin/Edit Controls */
.edit-input,
.edit-textarea {
    width: 100%;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    color: #fff;
    font-size: 0.85rem;
    font-family: inherit;
    resize: vertical;
}

.edit-input:focus,
.edit-textarea:focus {
    outline: none;
    border-color: rgba(45, 90, 45, 0.8);
    background: rgba(255, 255, 255, 0.08);
}

.edit-actions,
.admin-actions {
    margin-top: 1.5rem;
    display: flex;
    gap: 0.4rem;
}

.btn-edit-save,
.btn-admin-edit {
    flex: 1;
    padding: 0.5rem 0.75rem;
    background: rgba(45, 90, 45, 0.3);
    border: 1px solid rgba(45, 90, 45, 0.6);
    color: #a8d5a8;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-edit-save:hover,
.btn-admin-edit:hover {
    background: rgba(45, 90, 45, 0.5);
    border-color: rgba(45, 90, 45, 0.8);
    color: #fff;
    transform: translateY(-1px);
}

.btn-edit-cancel {
    flex: 1;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #888;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-edit-cancel:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.25);
    color: #ccc;
    transform: translateY(-1px);
}

.btn-admin-delete {
    flex: 1;
    padding: 0.5rem 0.75rem;
    background: rgba(180, 30, 30, 0.2);
    border: 1px solid rgba(180, 30, 30, 0.5);
    color: #d5a8a8;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-admin-delete:hover {
    background: rgba(180, 30, 30, 0.4);
    border-color: rgba(180, 30, 30, 0.8);
    color: #fff;
    transform: translateY(-1px);
}

.delete-confirm {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(10, 10, 10, 0.98);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 1.75rem;
    z-index: 1004;
    min-width: 280px;
    backdrop-filter: blur(10px);
}

.delete-confirm p {
    margin: 0 0 1.25rem 0;
    color: #ddd;
    font-size: 0.95rem;
    text-align: center;
    font-weight: 400;
}

.delete-confirm-actions {
    display: flex;
    gap: 0.4rem;
}

.btn-delete-yes {
    flex: 1;
    padding: 0.55rem 0.75rem;
    background: rgba(180, 30, 30, 0.3);
    border: 1px solid rgba(180, 30, 30, 0.6);
    color: #d5a8a8;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-delete-yes:hover {
    background: rgba(180, 30, 30, 0.5);
    border-color: rgba(180, 30, 30, 0.9);
    color: #fff;
    transform: translateY(-1px);
}

.btn-delete-no {
    flex: 1;
    padding: 0.55rem 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #aaa;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-delete-no:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    color: #fff;
    transform: translateY(-1px);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: #666;
}

.empty-state a {
    color: rgba(45, 90, 45, 0.8);
    text-decoration: none;
}

.empty-state a:hover {
    color: rgba(45, 90, 45, 1);
    text-decoration: underline;
}

/* Admin Login */
.admin-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
}

.login-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 2.5rem;
    width: 100%;
    max-width: 400px;
    margin: 1rem;
}

.login-card h2 {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 1.5rem;
    text-align: center;
}

/* Admin Page Styles */
.admin-header {
    background: rgba(10, 10, 10, 0.95);
    padding: 1rem 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    font-size: 1.3rem;
    font-weight: 300;
}

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

.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.2rem;
    font-weight: 300;
    margin-bottom: 1.5rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 300;
    color: rgba(45, 90, 45, 0.8);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.85rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    color: #ccc;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input,
.form-select,
.file-input-styled,
textarea.form-input {
    width: 100%;
    padding: 0.8rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: #fff;
    font-size: 0.95rem;
    font-family: inherit;
}

.form-input:focus,
.form-select:focus,
textarea.form-input:focus {
    outline: none;
    border-color: rgba(45, 90, 45, 0.8);
}

textarea.form-input {
    resize: vertical;
    min-height: 60px;
}

/* MudBlazor Autocomplete Dark Theme */
.mud-autocomplete-dark .mud-input {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #fff !important;
}

.mud-autocomplete-dark .mud-input-outlined {
    border-color: rgba(255, 255, 255, 0.1) !important;
}

.mud-autocomplete-dark .mud-input-outlined:hover {
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.mud-autocomplete-dark .mud-input-outlined.mud-input-focused {
    border-color: rgba(45, 90, 45, 0.8) !important;
}

.mud-autocomplete-dark input::placeholder {
    color: #666 !important;
}

/* Autocomplete dropdown */
.mud-popover-provider .mud-popover {
    background: rgba(20, 20, 20, 0.98) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(10px);
}

.mud-list-item {
    color: #ccc !important;
}

.mud-list-item:hover {
    background: rgba(45, 90, 45, 0.3) !important;
    color: #fff !important;
}

.mud-list-item.mud-selected-item {
    background: rgba(45, 90, 45, 0.5) !important;
    color: #fff !important;
}

.input-group {
    display: flex;
    gap: 0.5rem;
}

/* Buttons */
.btn {
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: rgba(45, 90, 45, 0.8);
    color: #fff;
}

.btn-primary:hover {
    background: rgba(45, 90, 45, 1);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #ccc;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.btn-danger {
    background: rgba(180, 30, 30, 0.8);
    color: #fff;
}

.btn-danger:hover {
    background: rgba(200, 40, 40, 1);
}

.btn-small {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Photo Editor List */
.photo-editor-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.photo-editor-item {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 1rem;
    position: relative;
}

.photo-editor-preview {
    width: 200px;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: #000;
    border-radius: 4px;
}

.photo-editor-fields {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: relative;
}

.photo-editor-fields .preview-remove {
    position: absolute;
    top: -0.5rem;
    right: -0.5rem;
    background: rgba(180, 30, 30, 0.9);
    border: none;
    color: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.photo-editor-fields .preview-remove:hover {
    background: rgba(200, 40, 40, 1);
    transform: rotate(90deg);
}

.photo-editor-fields .form-group {
    margin-bottom: 0;
}

/* Responsive photo editor */
@media (max-width: 768px) {
    .photo-editor-item {
        grid-template-columns: 1fr;
    }

    .photo-editor-preview {
        width: 100%;
        height: 200px;
    }
}

/* Album List */
.album-list {
    display: grid;
    gap: 0.8rem;
}

.album-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.album-info {
    flex: 1;
}

.album-name {
    font-size: 1rem;
    color: #fff;
    margin-bottom: 0.2rem;
}

.album-count {
    font-size: 0.85rem;
    color: #666;
}

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

.form-actions {
    margin-top: 1.5rem;
}

/* Messages */
.message {
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
}

.message.success {
    background: rgba(45, 90, 45, 0.3);
    border: 1px solid rgba(45, 90, 45, 0.8);
    color: #a8d5a8;
}

.message.error {
    background: rgba(90, 45, 45, 0.3);
    border: 1px solid rgba(90, 45, 45, 0.8);
    color: #d5a8a8;
}

/* Migration UI */
.migration-status {
    margin-top: 1rem;
}

.migration-progress {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 1.5rem;
}

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

.migration-header h3 {
    margin: 0;
    color: #fff;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: #86b510;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.migration-stats {
    margin-bottom: 1rem;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.stat-row span:first-child {
    color: #999;
}

.stat-row span:last-child {
    color: #fff;
    font-weight: 500;
}

.stat-row .success {
    color: #86b510;
}

.stat-row .error {
    color: #d5a8a8;
}

.progress-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin: 1rem 0;
}

.progress-fill {
    height: 100%;
    background: #86b510;
    transition: width 0.3s ease;
}

.status-log {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    max-height: 300px;
    overflow-y: auto;
}

.status-message {
    color: #999;
    font-size: 0.85rem;
    padding: 0.3rem 0;
    font-family: monospace;
}

.migration-complete {
    background: rgba(45, 90, 45, 0.1);
    border: 1px solid rgba(45, 90, 45, 0.3);
    border-radius: 4px;
    padding: 1.5rem;
    margin-top: 1rem;
}

.migration-complete h3 {
    margin-top: 0;
}

/* Blazor Error Boundary */
#blazor-error-ui {
    background: rgba(180, 30, 30, 0.95);
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
    position: fixed;
    bottom: 0;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .reload {
    color: #fff;
    text-decoration: underline;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 1rem;
    top: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .lightbox-prev {
        left: 0.5rem;
    }

    .lightbox-next {
        right: 0.5rem;
    }

    .lightbox-next.with-sidebar {
        right: 0.5rem;
        bottom: 1rem;
        top: auto;
        transform: none;
    }

    .lightbox-sidebar {
        width: 100%;
    }

    .lightbox-image.with-sidebar {
        max-width: 90%;
        margin-right: 0;
        max-height: 60vh;
    }

    .lightbox-info-toggle {
        right: 3.25rem;
        width: 32px;
        height: 32px;
        font-size: 0.85rem;
    }

    .lightbox-share-btn {
        top: 4rem;
        right: 0.5rem;
        width: 32px;
        height: 32px;
    }

    .lightbox-share-btn svg {
        width: 16px;
        height: 16px;
    }

    .lightbox-fullscreen-btn {
        top: 4rem;
        right: 3.25rem;
        width: 32px;
        height: 32px;
    }

    .lightbox-fullscreen-btn svg {
        width: 16px;
        height: 16px;
    }

    .lightbox-slideshow-btn {
        top: 4rem;
        right: 6rem;
        width: 32px;
        height: 32px;
    }

    .lightbox-slideshow-btn svg {
        width: 16px;
        height: 16px;
    }

    .slideshow-speed-menu {
        top: 7.5rem;
        right: 0.5rem;
    }

    .share-feedback {
        top: 8rem;
        right: 0.5rem;
        left: 0.5rem;
        width: auto;
        font-size: 0.8rem;
    }

    .lightbox-close {
        width: 32px;
        height: 32px;
        font-size: 1.2rem;
    }

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

    .admin-header {
        flex-direction: column;
        gap: 1rem;
    }
}
