/* CSS Variables for theming */
:root {
    --primary-color: #233c2b; /* мшисто-зелёный */
    --secondary-color: #b7b08a; /* древесно-бежевый */
    --accent-color: #7a5c2e; /* древесный акцент */
    --text-color: #1a2a1a;
    --background-color: #f6f5ee; /* светло-бежевый */
    --card-background: #e7e5d1;
    --gradient: linear-gradient(120deg, #e7e5d1 0%, #b7b08a 100%);
    --sunlight-glow: rgba(183, 176, 138, 0.25);
    --transition: all 0.3s ease;
    --mobile-bottom-nav-height: 56px;
    --image-placeholder-background: #b7b08a;
}

[data-theme="light"] {
    --primary-color: #233c2b;
    --secondary-color: #b7b08a;
    --accent-color: #7a5c2e;
    --text-color: #1a2a1a;
    --background-color: #f6f5ee;
    --card-background: #e7e5d1;
    --gradient: linear-gradient(120deg, #e7e5d1 0%, #b7b08a 100%);
    --sunlight-glow: rgba(183, 176, 138, 0.25);
}

[data-theme="dark"] {
    --primary-color: #2d2116; /* тёплый коричневый */
    --secondary-color: #4b2e1e; /* кирпичный */
    --accent-color: #ffb347; /* янтарный */
    --text-color: #f6e7c1;
    --background-color: #18120b; /* глубокий тёмный */
    --card-background: #24190f;
    --gradient: linear-gradient(120deg, #24190f 0%, #4b2e1e 100%);
    --lamp-glow: 0 0 32px 8px rgba(255,179,71,0.25), 0 0 8px 2px #ffb347;
    --transition: all 0.3s ease;
    --mobile-bottom-nav-height: 56px;
    --image-placeholder-background: #4b2e1e;
}

/* Базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    overflow-x: hidden;
    position: relative;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    transition: var(--transition);
    min-height: 100vh;
    padding-bottom: var(--mobile-bottom-nav-height);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* Секции */
section {
    padding: 6rem 0;
}

section h2 {
    font-size: 2rem;
    margin-bottom: 3rem;
    text-align: center;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Анимации */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes waveEffect {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

@keyframes gradientMove {
    0% { background-position: 0% 0%; }
    100% { background-position: 100% 100%; }
}

@keyframes loading-pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 0.2; }
}

/* Общие элементы интерфейса */
button, a {
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

button::after, a::after {
    content: '';
    display: block;
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, rgba(255, 255, 255, 0.4) 10%, transparent 10.01%);
    background-repeat: no-repeat;
    background-position: 50%;
    transform: scale(10, 10);
    opacity: 0;
    transition: transform 0.5s, opacity 1s;
}

button:active::after, a:active::after {
    transform: scale(0, 0);
    opacity: 0.3;
    transition: 0s;
}

/* Эффекты */
.section-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

.glow-effect {
    position: relative;
    overflow: hidden;
}

.glow-effect::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0) 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.glow-effect:hover::after {
    opacity: 1;
}

/* Изображения и лоадеры */
.music-cover img, .resident-image, #track-cover {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.music-cover img.loaded, .resident-image.loaded, #track-cover.loaded {
    opacity: 1;
}

.music-cover, .resident-image-container, .track-cover-container {
    background-color: var(--image-placeholder-background);
    position: relative;
}

.music-cover::before, .resident-image-container::before, .track-cover-container::before {
    content: '';
    display: block;
}

img.error-img {
    opacity: 0.5;
}

/* Общие медиа-запросы */
@media (max-width: 768px) {
    section {
        padding: 4rem 0;
    }
    
    section h2 {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .hero-section {
        padding: 2rem 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    section {
        padding: 3rem 0;
    }
    
    section h2 {
        font-size: 1.6rem;
        margin-bottom: 1.5rem;
    }
}

[data-theme="light"] section, [data-theme="light"] .card-background, [data-theme="light"] .resident-card, [data-theme="light"] .news-card {
    background: linear-gradient(120deg, var(--card-background) 80%, var(--secondary-color) 100%);
    box-shadow: 0 4px 32px 0 var(--sunlight-glow);
    border-radius: 18px;
    border: 1px solid rgba(35, 60, 43, 0.06);
    backdrop-filter: blur(2px);
}
[data-theme="dark"] section, [data-theme="dark"] .card-background, [data-theme="dark"] .resident-card, [data-theme="dark"] .news-card {
    background: linear-gradient(120deg, #24190f 80%, #4b2e1e 100%);
    box-shadow: 0 4px 32px 0 rgba(255,179,71,0.10), 0 1px 8px 0 #24190f;
    border-radius: 18px;
    border: 1px solid rgba(75, 46, 30, 0.12);
    backdrop-filter: blur(2px);
} 