/* Переменные для быстрой настройки темы */
:root {
    --bg-color: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent-color: #38bdf8;
    --radius: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    padding-bottom: 60px;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Шапка */
.header {
    text-align: center;
    padding: 60px 20px 40px;
}

.title {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 10px;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Сетка галереи */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

/* Карточка фотографии */
.gallery-item {
    position: relative;
    background: var(--card-bg);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 0.6s forwards;
    transition: var(--transition);
}

.gallery-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 35px -10px rgba(56, 189, 248, 0.2);
    border-color: rgba(56, 189, 248, 0.3);
}

.gallery-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    display: block;
    transition: var(--transition);
}

.gallery-item:hover img {
    filter: brightness(1.05);
}

.gallery-info {
    padding: 16px;
}

.gallery-caption {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.gallery-date {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Лоадер */
.loader {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
    font-size: 1.2rem;
}

/* Полноэкранный Lightbox (Модальное окно) */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    max-width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal.show .modal-content {
    transform: scale(1);
}

.modal-caption {
    margin-top: 16px;
    color: var(--text-primary);
    font-size: 1.1rem;
    text-align: center;
}

.modal-close {
    position: absolute;
    top: 24px;
    right: 32px;
    color: var(--text-secondary);
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--accent-color);
}

/* Анимация появления для сетки */
@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}