/* Global Styles */
:root {
    --primary-color: #2e7d32;      /* Deep green for primary elements */
    --secondary-color: #196b1d;    /* Lighter green for secondary elements */
    --accent-color: #ffffff;       /* Yellow accent for highlights */
    --warning-color: #FF1744;      /* Red for warnings */
    --weather-card-bg: #1B5E20;    /* Dark green for cards */
    --weather-card-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --weather-text-color: #ffffff;
    --background-color: #E8F5E9;   /* Light green background */
    --text-color: #1B5E20;         /* Dark green text */
    --border-color: #8BC34A;       /* Light green border */
    --gradient-start: #196b1d;     /* Green gradient start */
    --gradient-end: #196b1d;       /* Green gradient end */
    --font-family: 'Montserrat', 'Roboto', sans-serif;
    --font-weight-light: 400;
    --font-weight-medium: 600;
    --font-weight-bold: 800;
    --font-weight-extra-bold: 900;
    --line-height: 1.8;
    --paragraph-spacing: 2rem;
    --list-spacing: 1.5rem;
}

/* Navigation Styles */
.navbar {
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end)) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.navbar-dark {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end)) !important;
}

.navbar-brand {
    font-size: 1.2rem;
    padding: 0.5rem 1rem;
}

.nav-link {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    margin: 0 0.25rem;
    text-transform: uppercase;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    font-family: var(--font-family);
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.15);
}

/* Dropdown Menu Styles */
.dropdown-menu {
    font-size: 0.9rem;
    padding: 0.5rem 0;
    min-width: 150px;
}

.dropdown-item {
    padding: 0.5rem 1rem;
    text-transform: uppercase;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.5px;
    font-family: var(--font-family);
}

.dropdown-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Weather Card Styles */
.weather-card {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border: 1px solid var(--border-color);
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease-in-out;
    margin: 1rem;
}

.weather-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Kyrgyzhydromet Styles */
.card {
    background: rgba(255, 255, 255, 0.95) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: 10px !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.card-body {
    background: transparent !important;
    padding: 1.5rem;
}

.card-body h5 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: var(--font-weight-extra-bold);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: var(--font-family);
}

.card-body p {
    color: var(--text-color);
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.card-body a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
}

.card-body a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.alert-info {
    background: transparent !important;
    border: none !important;
    padding: 0;
}

.alert-info p {
    color: var(--text-color);
    margin: 0;
}

/* Dark mode text colors */
body.dark-mode .card-body h5,
body.dark-mode .card-body p,
body.dark-mode .card-body a,
body.dark-mode .alert-info p {
    color: var(--text-color);
}

.card-body a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.alert-info {
    background: transparent !important;
    border: none !important;
    padding: 0;
}

.alert-info p {
    color: white;
    margin: 0;
}

.weather-card:hover {
    transform: translateY(-5px);
}

.weather-card .card-body {
    padding: 2rem;
}

.weather-card h2 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.weather-icon {
    color: var(--accent-color);
    transition: transform 0.3s ease;
}

.weather-icon:hover {
    transform: scale(1.1);
}

.weather-info h1 {
    font-size: 4rem;
    font-weight: 700;
    color: var(--weather-text-color);
    margin-bottom: 0.5rem;
}

.weather-info p {
    margin-bottom: 0.25rem;
    font-size: 1.2rem;
    color: var(--secondary-color);
}

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

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    transition: background-color 0.3s ease;
}

.detail-item:hover {
    background: rgba(255, 255, 255, 0.2);
}

.detail-item i {
    color: var(--accent-color);
}

.detail-item span {
    color: var(--weather-text-color);
    font-size: 1rem;
}

.forecast-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.forecast-item {
    text-align: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    transition: background-color 0.3s ease;
}

.forecast-item:hover {
    background: rgba(255, 255, 255, 0.2);
}

.forecast-item h4 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.forecast-item i {
    color: var(--accent-color);
    margin-bottom: 1rem;
}

.forecast-item p {
    color: var(--weather-text-color);
    font-size: 1.5rem;
    margin: 0;
}

/* Sections */
.section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    color: #196b1d!important;
    font-weight: 600;
}

/* Dark Mode Overrides */
body.dark-mode {
    --weather-card-bg: #1e1e1e;
    --weather-card-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --weather-text-color: #ffffff;
}

body.dark-mode .weather-card {
    border: 1px solid #333;
}

body.dark-mode .weather-icon,
body.dark-mode .forecast-item i {
    color: var(--accent-color);
}

body.dark-mode .weather-info h1,
body.dark-mode .forecast-item p {
    color: #ffffff;
}

body.dark-mode .weather-info p {
    color: #ffffff;
}

body.dark-mode .detail-item,
body.dark-mode .forecast-item {
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .detail-item:hover,
body.dark-mode .forecast-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .detail-item i {
    color: var(--accent-color);
}

body.dark-mode .section {
    background-color: #121212;
    padding: 0;
    margin: 0;
}

body.dark-mode .section-title {
    color: #196b1d;
}

/* Dark mode section titles */
body.dark-mode .temp-trends-title,
body.dark-mode .precipitation-title,
body.dark-mode .climate-indices-title,
body.dark-mode .key-points-title {
    color: #196b1d !important;
}

/* Dark mode section content */
body.dark-mode .section p,
body.dark-mode .section ul li {
    color: #ffffff;
}

body.dark-mode .data-card,
body.dark-mode .chart-container,
body.dark-mode .key-points {
    background-color: #1e1e1e;
    border: 1px solid #196b1d;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

body {
    background: linear-gradient(45deg, #E8F5E9, #C8E6C9);
    color: var(--text-color);
    font-family: var(--font-family);
    min-height: 100vh;
    font-weight: var(--font-weight-medium);
}

/* Hero Section */
.hero-section {
    padding: 100px 0 50px;
    background: url('climatechange.jpg') center/cover no-repeat;
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    justify-content: center;
    background-color: transparent;
}

.hero-content {
    background-color: transparent;
}

.logos-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
    background: transparent;
    position: relative;
    z-index: 1;
}

.logo-wrapper {
    position: relative;
    background: transparent;
    display: inline-block;
}

.logo {
    max-height: 100px;
    object-fit: contain;
    opacity: 1;
    transition: opacity 0.3s ease;
    background: transparent;
}

.logo:hover {
    opacity: 0.8;
}

.hero-content {
    margin-bottom: 40px;
    padding-top: 100px;
    padding-bottom: 50px;
}

.hero-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.logos-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
    background: transparent;
}

.logo {
    max-height: 100px;
    object-fit: contain;
    opacity: 0.5;
    transition: opacity 0.3s ease;
    background: transparent;
}

.logo:hover {
    opacity: 0.8;
}

.hero-icon {
    width: 60px;
    height: 60px;
    filter: brightness(0) invert(1);
    display: block;
    margin: 0 auto;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 40px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.stat-card h3 {
    color: white;
    margin-bottom: 1rem;
}

/* Sections */
.section {
    padding: 80px 0;
    background-color: #1a1a1a; /* Dark background color */
    margin-top: 50px;
}

.section-title {
    font-size: 2.4rem;
    margin-bottom: 2.5rem;
    color: white;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: var(--font-weight-extra-bold);
    font-family: var(--font-family);
    padding-bottom: 20px;
    border-bottom: 2px solid #196b1d;
}

/* Hero Image Fade Effect */
.hero-image {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
    pointer-events: none;
}

/* Text Styles */
p {
    font-size: 1.1rem;
    line-height: var(--line-height);
    margin-bottom: var(--paragraph-spacing);
    color: #ffffff;
}

ul, ol {
    margin-bottom: var(--list-spacing);
}

li {
    margin-bottom: 1rem;
    color: #ffffff;
}

/* Add scroll-based opacity using CSS variables */
body {
    --scroll-opacity: 1;
    scroll-behavior: smooth;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -2;
    background: linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0) 100%);
}

/* Charts */
.chart-container {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Data Cards */
.data-card {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    height: 100%;
}

.data-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Key Points */
.key-points {
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.key-points h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        padding: 50px 0;
    }
    
    .stats-container {
        grid-template-columns: 1fr;
    }
    
    .section {
        padding: 40px 0;
    }
}

/* Footer */
footer {
    margin-top: 40px;
}

/* Navigation */
.navbar {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    background-color: var(--primary-color) !important;
}

.navbar-brand {
    font-weight: bold;
}

.nav-link {
    margin: 0 10px;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--accent-color) !important;
}

.dropdown-menu {
    background-color: var(--primary-color);
}

.dropdown-item {
    color: white;
}

.dropdown-item:hover {
    background-color: var(--accent-color);
    color: white;
}
