/* 
   ====================
   CSS ПРОМЕНЛИВИ (ТЕМИ)
   ====================
*/
:root {
    /* Светла тема */
    --bg-primary: #ffffff;
    --bg-secondary: #f5f7fa;
    --text-primary: #2c3e50;
    --text-secondary: #5a6c7d;
    --accent-color: #2a9d8f;
    --accent-dark: #1e3c72;
    --card-bg: #ffffff;
    --card-shadow: 0 10px 30px rgba(0,0,0,0.08);
    --border-color: #e2e8f0;
    --nav-bg: rgba(255, 255, 255, 0.95);
    --hero-overlay: linear-gradient(rgba(0,0,0,0.25), rgba(0,0,0,0.5));
    --footer-bg: #1e3c72;
    --footer-text: #ffffff;
}

[data-theme="dark"] {
    /* Тъмна тема */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --text-primary: #e2e8f0;
    --text-secondary: #94a3b8;
    --accent-color: #34d399;
    --accent-dark: #10b981;
    --card-bg: #1e293b;
    --card-shadow: 0 10px 30px rgba(0,0,0,0.4);
    --border-color: #334155;
    --nav-bg: rgba(15, 23, 42, 0.95);
    --hero-overlay: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.7));
    --footer-bg: #0f172a;
    --footer-text: #94a3b8;
}

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

html {
    scroll-behavior: smooth;
}

/* 
   Шрифтът Kometa се зарежда в index.html чрез @font-face
   Тук не е нужно да го декларираме отново
*/
body {
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-padding {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 16px;
    color: var(--accent-dark);
    position: relative;
    transition: color 0.3s ease;
    letter-spacing: 1px;
}

.section-title::after {
    content: '';
    width: 70px;
    height: 3px;
    background: var(--accent-color);
    display: block;
    margin: 16px auto 0;
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-size: 1.1rem;
}

/* ====================
   THEME TOGGLE
   ==================== */
.theme-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--card-bg);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    padding: 12px 20px;
    cursor: pointer;
    z-index: 1001;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    backdrop-filter: blur(8px);
}

.theme-toggle:hover {
    transform: translateY(-3px);
    border-color: var(--accent-color);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.theme-toggle i {
    font-size: 1.1rem;
    color: var(--accent-color);
}

/* ====================
   НАВИГАЦИЯ
   ==================== */
nav {
    background: var(--nav-bg);
    box-shadow: 0 2px 20px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(12px);
    transition: background 0.3s ease;
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--accent-dark);
    transition: color 0.3s ease;
    letter-spacing: 1px;
}

.logo i {
    color: var(--accent-color);
    margin-right: 8px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 36px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.3s;
    font-size: 1.05rem;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--accent-color);
}

/* ====================
   HERO СЕКЦИЯ
   ==================== */
.hero {
    height: 90vh;
    min-height: 600px;
    /* ТУК Е ТВОЯТА СНИМКА - ПРОМЕНИ ИМЕТО АКО Е РАЗЛИЧНО */
    background: url("/hero-bg.jpg") no-repeat center center/cover;
    background-attachment: fixed;
    position: relative;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--hero-overlay);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-content {
    animation: fadeInUp 1s ease;
}

.hero-badge {
    display: inline-block;
    background: var(--accent-color);
    color: white;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.hero-content h1 {
    font-size: 5.5rem;
    color: white;
    text-shadow: 2px 4px 20px rgba(0,0,0,0.3);
    letter-spacing: 8px;
    margin-bottom: 10px;
    font-weight: 600;
}

.hero-divider {
    width: 100px;
    height: 3px;
    background: var(--accent-color);
    margin: 20px auto;
}

.hero-content p {
    font-size: 1.8rem;
    color: #f0f0f0;
    margin-bottom: 40px;
    font-weight: 400;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 50px;
    color: white;
    font-size: 1.1rem;
    background: rgba(0,0,0,0.3);
    padding: 18px 40px;
    border-radius: 60px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 40px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-item i {
    color: var(--accent-color);
    font-size: 1.3rem;
}

.scroll-down {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    color: white;
    text-decoration: none;
    font-size: 0.9rem;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.scroll-down:hover {
    opacity: 1;
}

.scroll-down i {
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

/* ====================
   ЗА ГРАДА СЕКЦИЯ
   ==================== */
.about-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.about-text {
    background: var(--card-bg);
    padding: 35px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    transition: background 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color);
}

.highlight {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--accent-dark);
    margin-bottom: 20px;
    border-left: 4px solid var(--accent-color);
    padding-left: 20px;
}

.about-card {
    background: var(--card-bg);
    padding: 35px 25px;
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.about-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.12);
    border-color: var(--accent-color);
}

.about-card i {
    font-size: 2.8rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.about-card h3 {
    margin-bottom: 15px;
    color: var(--accent-dark);
}

.key-facts {
    margin-top: 25px;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.key-facts span {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.key-facts span i {
    color: var(--accent-color);
    width: 20px;
}

/* ====================
   ГАЛЕРИЯ
   ==================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 25px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    cursor: pointer;
    box-shadow: var(--card-shadow);
    aspect-ratio: 4 / 3;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.gallery-item:hover img {
    transform: scale(1.08);
}

.caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    padding: 20px 15px;
    font-weight: 500;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.gallery-item:hover .caption {
    transform: translateY(0);
}

/* ====================
   LIGHTBOX
   ==================== */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 2000;
    text-align: center;
    backdrop-filter: blur(5px);
}

.lightbox img {
    max-width: 90%;
    max-height: 85vh;
    margin-top: 5vh;
    border-radius: 12px;
    box-shadow: 0 10px 50px rgba(0,0,0,0.5);
}

.close-btn {
    position: absolute;
    top: 25px;
    right: 40px;
    color: white;
    font-size: 50px;
    font-weight: 300;
    cursor: pointer;
    transition: transform 0.3s;
}

.close-btn:hover {
    transform: scale(1.1);
    color: var(--accent-color);
}

/* ====================
   ВРЕМЕТО
   ==================== */
.weather-widget {
    display: flex;
    align-items: stretch;
    gap: 40px;
    background: var(--card-bg);
    padding: 40px;
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    border: 1px solid var(--border-color);
    transition: background 0.3s ease;
}

.weather-card {
    text-align: center;
    min-width: 220px;
    padding: 20px;
    background: var(--bg-secondary);
    border-radius: 20px;
    transition: background 0.3s ease;
}

.weather-icon {
    font-size: 4rem;
    color: var(--accent-color);
    margin-bottom: 15px;
}

.temp {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--accent-dark);
    transition: color 0.3s ease;
}

.desc {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.location {
    color: var(--text-secondary);
    margin: 15px 0;
}

.location i {
    color: var(--accent-color);
    margin-right: 6px;
}

.btn-refresh {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
}

.btn-refresh:hover {
    background: var(--accent-dark);
    transform: scale(1.02);
}

.weather-note {
    flex: 1;
    padding-left: 40px;
    border-left: 2px solid var(--border-color);
}

.weather-note h3 {
    color: var(--accent-dark);
    margin-bottom: 15px;
}

.climate-stats {
    display: flex;
    gap: 20px;
    margin-top: 25px;
}

.climate-stats div {
    background: var(--bg-secondary);
    padding: 10px 18px;
    border-radius: 40px;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.climate-stats div span {
    font-weight: 600;
    color: var(--accent-color);
}

/* ====================
   ФУТЪР
   ==================== */
footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    padding: 50px 0;
    transition: background 0.3s ease;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.footer-info h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.footer-info i {
    color: var(--accent-color);
}

.footer-links {
    text-align: center;
}

.footer-links .fa-heart {
    color: #ef4444;
}

.footer-credit {
    text-align: right;
    font-size: 0.9rem;
    opacity: 0.8;
}

/* ====================
   АНИМАЦИИ
   ==================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* ====================
   АДАПТИВНОСТ
   ==================== */
@media (max-width: 900px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .weather-widget {
        flex-direction: column;
    }
    
    .weather-note {
        border-left: none;
        border-top: 2px solid var(--border-color);
        padding-left: 0;
        padding-top: 30px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 20px;
    }
    
    .footer-credit {
        text-align: center;
    }
    
    .hero-content h1 {
        font-size: 3.5rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 15px;
    }
}

@media (max-width: 600px) {
    .nav-links {
        gap: 20px;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .hero-content h1 {
        font-size: 2.8rem;
    }
    
    .hero-content p {
        font-size: 1.3rem;
    }
    
    .theme-toggle .toggle-text {
        display: none;
    }
    
    .theme-toggle {
        padding: 12px;
        border-radius: 50%;
    }
}

//* ====================
   HERO С YOUTUBE ВИДЕО БЕКГРАУНД
   ==================== */
.hero-youtube {
    height: 90vh;
    min-height: 600px;
    position: relative;
    overflow: hidden;
    /* Тъмен фон докато зареди видеото (няма снимка) */
    background: #0a1628;
}

.youtube-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    /* Плавно появяване когато видеото зареди */
    opacity: 0;
    transition: opacity 1.5s ease;
}

/* Когато видеото се зареди - показваме го */
.youtube-background.loaded {
    opacity: 1;
}

.youtube-background iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 56.25vw;
    min-width: 100vh;
    min-height: 56.25vh;
    border: none;
}

/* Overlay върху видеото */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        rgba(0, 0, 0, 0.4) 0%,
        rgba(0, 0, 0, 0.5) 50%,
        rgba(0, 0, 0, 0.7) 100%
    );
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Адаптивност */
@media (max-width: 768px) {
    .hero-youtube {
        height: 70vh;
        min-height: 500px;
    }
}