:root {
    /* Light mode colors */
    --primary-bg: #ffffff;
    --secondary-bg: #f8f9fa;
    --primary-text: #000000;
    --secondary-text: #333333;
    --accent-color: #e53935;
    --border-color: #e0e0e0;
    --card-bg: #ffffff;
    --footer-bg: #1a1a1a;
    --footer-text: #f0f0f0;
    --shadow: rgba(0, 0, 0, 0.1);
}

.dark-mode {
    /* Dark mode colors */
    --primary-bg: #121212;
    --secondary-bg: #1e1e1e;
    --primary-text: #ffffff;
    --secondary-text: #cccccc;
    --accent-color: #ff5252;
    --border-color: #333333;
    --card-bg: #1e1e1e;
    --footer-bg: #000000;
    --footer-text: #e0e0e0;
    --shadow: rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--primary-bg);
    color: var(--primary-text);
    line-height: 1.6;
}

/* Header & Navigation */
header {
    background-color: var(--primary-bg);
    box-shadow: 0 2px 10px var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

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

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    /* color: var(--accent-color); */
}

.logo span {
    color: var(--primary-text);
}

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

.nav-links a {
    text-decoration: none;
    color: var(--primary-text);
    font-weight: 500;
    padding: 5px 0;
    position: relative;
}

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

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

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

.theme-toggle {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--primary-text);
    margin-left: 20px;
}

.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    background: none;
    border: none;
    color: var(--primary-text);
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('https://images.unsplash.com/photo-1629654291660-3c98113a0438?ixlib=rb-4.0.3&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 100px 0;
    margin-bottom: 60px;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 30px;
}

.hero-accent {
    color: var(--accent-color);
    font-weight: bold;
}

.btn {
    display: inline-block;
    background-color: var(--accent-color);
    color: white;
    padding: 12px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
}

.btn:hover {
    background-color: #c62828;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Content Sections */
.section-title {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

.section-title h2 {
    font-size: 2.5rem;
    display: inline-block;
    padding-bottom: 10px;
}

.section-title h2:after {
    content: '';
    position: absolute;
    width: 100px;
    height: 3px;
    background-color: var(--accent-color);
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.about, .services, .technology, .submetering, .sustainability, .news {
    padding: 80px 0;
}

.about {
    background-color: var(--secondary-bg);
}

.about-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-text {
    flex: 1;
}

.about-text h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--accent-color);
}

.about-image {
    flex: 1;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.service-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px var(--shadow);
    border-top: 4px solid var(--accent-color);
}

.service-icon {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

/* Technology Tabs */
.tech-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 10px 25px;
    background-color: var(--secondary-bg);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    color: var(--primary-text);
}

.tab-btn.active {
    background-color: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

.tab-content {
    display: none;
    background-color: var(--card-bg);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px var(--shadow);
}

.tab-content.active {
    display: block;
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.news-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px var(--shadow);
}

.news-image {
    height: 200px;
    background-color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}

.news-content {
    padding: 25px;
}

.news-date {
    color: var(--accent-color);
    font-weight: 500;
    margin-bottom: 10px;
}

/* Footer */
footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 60px 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-column h3 {
    color: var(--accent-color);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--footer-text);
    text-decoration: none;
    transition: color 0.3s;
}

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

.contact-info p {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icons a {
    color: var(--footer-text);
    font-size: 1.2rem;
    transition: color 0.3s;
}

.social-icons a:hover {
    color: var(--accent-color);
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #333;
    color: #aaa;
    font-size: 0.9rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 999;
    border: none;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: #c62828;
    transform: translateY(-5px);
}

/* Responsive Design */
@media (max-width: 992px) {
    .about-content {
        flex-direction: column;
    }
    
    .hero h2 {
        font-size: 2.5rem;
    }
       .hero-content{
        margin-top:20rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--primary-bg);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 10px var(--shadow);
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-toggle {
        display: block;
    }

    .hero h2 {
        font-size: 2rem;
    }
 
    .section-title h2 {
        font-size: 2rem;
    }
       .hero-content{
        margin-top:20rem;
    }
}

/* Image Slider Styles */
.image-slider {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 600px;
    overflow: hidden;
    margin-bottom: -100vh; /* Pulls the slider behind content */
    z-index: 0;
}

.slider-container {
    position: absolute;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transform: translateX(100%);
    transition: all 1s ease-in-out;
    z-index: 1;
}

.slide.active {
    opacity: 1;
    transform: translateX(0);
    z-index: 2;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 50, 100, 0.7) 0%, rgba(229, 57, 53, 0.4) 100%);
    z-index: 1;
}

/* Hero Content Positioning */
.hero-content {
    position: relative;
    z-index: 3;
    padding-top: 120px;
    color: white;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

/* Slider Navigation */
.slider-dots {
    position: absolute;
    bottom: 30px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 10px;
    z-index: 3;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.dot.active {
    background-color: var(--accent-color);
    transform: scale(1.2);
    border-color: white;
}

.dot:hover {
    background-color: white;
    transform: scale(1.1);
}

/* Slider Arrows */
.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.2);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    z-index: 3;
    backdrop-filter: blur(5px);
}

.slider-arrow:hover {
    background-color: var(--accent-color);
    transform: translateY(-50%) scale(1.1);
}

.slider-arrow:active {
    transform: translateY(-50%) scale(0.95);
}

.prev-arrow {
    left: 20px;
}

.next-arrow {
    right: 20px;
}

/* Slider Toggle Button */
.slider-toggle {
    position: absolute;
    bottom: 30px;
    right: 20px;
    background-color: rgba(255, 255, 255, 0.2);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
    z-index: 3;
    backdrop-filter: blur(5px);
}

.slider-toggle:hover {
    background-color: var(--accent-color);
    transform: scale(1.1);
}

/* Hero Section Adjustments */
.hero {
    position: relative;
    background: none !important; /* Remove any existing background */
}

.hero h2, .hero p, .hero .btn {
    position: relative;
    z-index: 4;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .image-slider {
        height: 80vh;
        min-height: 500px;
    }
    
    .slider-arrow {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .prev-arrow {
        left: 10px;
    }
    
    .next-arrow {
        right: 10px;
    }
    
    .hero-content {
        padding-top: 80px;
    }
   .hero-content{
        margin-top:20rem;
    }  
}

@media (max-width: 480px) {
    .image-slider {
        height: 70vh;
        min-height: 400px;
    }
       .hero-content{
        margin-top:20rem;
    }
    .slider-toggle {
        display: none;
    }
    
    .slider-dots {
        bottom: 15px;
    }
    
}
