/* Base Styles */
:root {
    --primary-color: #0066cc;
    --primary-hover: #0055aa;
    --secondary-color: #f0f4f8;
    --text-color: #333;
    --text-muted: #6c757d;
    --background-color: #fff;
    --border-color: #ddd;
    --card-bg: #fff;
    --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --header-height: 170px;
    --section-padding: 80px 0;
    --transition: all 0.3s ease;
    --radius: 8px;
}

.dark-theme {
    --primary-color: #3399ff;
    --primary-hover: #66b3ff;
    --secondary-color: #2a2d3e;
    --text-color: #f0f4f8;
    --text-muted: #a0aec0;
    --background-color: #1a1c2a;
    --border-color: #2d3748;
    --card-bg: #2a2d3e;
    --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    transition: var(--transition);
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    width: 100%;
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 16px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    color: white;
}

.btn-outline {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.btn-block {
    display: block;
    width: 100%;
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--background-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

header.scrolled {
    padding: 10px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    height: var(--header-height);
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    width: 150px;
    height: 150px;
    margin-right: 10px;
}

.site-name {
    font-weight: bold;
    font-size: 22px;
    display: none;
}

@media (min-width: 768px) {
    .site-name {
        display: inline;
    }
}

.nav-links {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: none; /* Changed from flex to none for mobile */
    gap: 20px;
}

@media (min-width: 768px) {
    .nav-links {
        display: flex;
        gap: 20px;
    }
}

.nav-link {
    color: var(--text-color);
    font-size: 20px;
    font-weight: 500;
}

.nav-link:hover {
    color: var(--primary-color);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.profile-pic {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid var(--primary-color);
}

.profile-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--text-color);
    cursor: pointer;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    transition: var(--transition);
}

.theme-toggle:hover {
    background-color: var(--secondary-color);
}

.theme-toggle .fa-sun {
    display: none;
}

.theme-toggle .fa-moon {
    display: block;
}

.dark-theme .theme-toggle .fa-sun {
    display: block;
}

.dark-theme .theme-toggle .fa-moon {
    display: none;
}

.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 20px;
    cursor: pointer;
}

@media (min-width: 768px) {
    .mobile-menu-toggle {
        display: none;
    }
}

/* Mobile Navigation */
.mobile-nav {
    display: none;
    background-color: var(--background-color);
    border-top: 1px solid var(--border-color);
    padding: 20px 0;
}

.mobile-nav.active {
    display: block;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mobile-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 66vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    margin-top: var(--header-height);
    overflow: hidden;
}

.hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 0 20px;
}

.hero-content h1 {
    font-size: 2.5rem; /* Reduced for mobile */
    margin-bottom: 20px;
    font-weight: 700;
}

@media (min-width: 768px) {
    .hero-content h1 {
        font-size: 3.5rem;
    }
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

@media (min-width: 576px) {
    .hero-buttons {
        flex-direction: row;
    }
}

.scroll-down {
    position: absolute;
    bottom: 30px;
    justify-content: center;
    transform: translateX(-50%);
    z-index: 1;
    animation: bounce 2s infinite;
}

.scroll-down a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    font-size: 20px;
    backdrop-filter: blur(5px);
}

.scroll-down a:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

/* Section Styles */
.section {
    padding: var(--section-padding);
}

.section-alt {
    background-color: var(--secondary-color);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2rem;
    margin-bottom: 15px;
    color: var(--text-color);
}

.section-divider {
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    margin: 0 auto 20px;
}

.section-description {
    max-width: 800px;
    margin: 0 auto;
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 30px;
    margin-top: 40px;
}

@media (min-width: 576px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.feature-card {
    background-color: var(--card-bg);
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    cursor: pointer; /* Added to indicate clickable */
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    background-color: rgba(0, 102, 204, 0.1);
    border-radius: 50%;
    font-size: 30px;
    color: var(--primary-color);
}

.feature-card h3 {
    margin-bottom: 15px;
    font-size: 1.25rem;
}

.feature-card p {
    color: var(--text-muted);
}

/* Press Section */
.press-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 768px) {
    .press-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.press-card {
    background-color: var(--card-bg);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
}

.press-card:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.press-logo {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--secondary-color);
    padding: 20px;
}

.press-logo img {
    max-height: 60px;
    max-width: 80%;
}

.press-content {
    padding: 20px;
}

.press-meta {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.press-card h3 {
    margin-bottom: 10px;
    font-size: 1.25rem;
}

.press-card p {
    color: var(--text-muted);
    margin-bottom: 15px;
}

.read-more {
    display: inline-flex;
    align-items: center;
    font-weight: 500;
    color: var(--primary-color);
}

.read-more i {
    margin-left: 5px;
    transition: var(--transition);
}

.read-more:hover i {
    transform: translateX(3px);
}

/* Blog Section */
.blog-tabs {
    margin-top: 30px;
}

.tabs-header {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    flex-wrap: wrap;
    gap: 10px;
}

.tab-btn {
    padding: 8px 16px;
    background: none;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-color);
    transition: var(--transition);
}

.tab-btn:hover {
    color: var(--primary-color);
}

.tab-btn.active {
    background-color: var(--primary-color);
    color: white;
}

.blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 576px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .blog-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.blog-card {
    background-color: var(--card-bg);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    height: 100%;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.blog-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--primary-color);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.blog-content {
    padding: 20px;
}

.blog-date {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.blog-card h3 {
    margin-bottom: 10px;
    font-size: 1.25rem;
    line-height: 1.4;/* Multi-browser support for line clamping */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2; /* Standard property for compatibility */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: var(--transition);
    max-height: 2.8em; /* Fallback for non-supporting browsers */
}

.blog-card:hover h3 {
    color: var(--primary-color);
}

.blog-card p {
    color: var(--text-muted);
    margin-bottom: 15px; /* Multi-browser support for line clamping */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3; /* Standard property for compatibility */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    max-height: 4.8em; /* Fallback for non-supporting browsers */
}

.blog-meta {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.blog-author, .blog-read-time {
    display: flex;
    align-items: center;
}

.blog-author i, .blog-read-time i {
    margin-right: 5px;
    font-size: 0.8rem;
}

.blog-more {
    text-align: center;
    margin-top: 40px;
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

@media (min-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr 2fr;
    }
}

.contact-card {
    background-color: var(--card-bg);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--card-shadow);
    height: 100%;
}

.contact-card h3 {
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.contact-card > p {
    color: var(--text-muted);
    margin-bottom: 25px;
}

.contact-item {
    display: flex;
    margin-bottom: 20px;
}

.contact-item i {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-right: 15px;
    margin-top: 5px;
}

.contact-item h4 {
    margin-bottom: 5px;
    font-weight: 600;
}

.contact-item p {
    color: var(--text-muted);
}

/* Form Styles */
.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

@media (min-width: 576px) {
    .form-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    background-color: var(--background-color);
    color: var(--text-color);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.2);
}

.form-success {
    display: none;
    text-align: center;
    padding: 30px 0;
}

.success-icon {
    font-size: 4rem;
    color: #28a745;
    margin-bottom: 20px;
}

.form-success h3 {
    margin-bottom: 10px;
}

.form-success p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

/* Footer */
.footer {
    padding: 60px 0 30px;
    position: relative;
    background-color: var(--secondary-color);
    padding: 100px 0 40px;
    color: var(--text-color);
}

.footer-grid {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-bottom: 40px;
    justify-content: center;
    align-items: center;
    text-align: center;
}

@media (min-width: 768px) {
    .footer {
        padding: 100px 0 40px;
    }

    .footer-grid {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        text-align: left;
    }
    
    .footer-links {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-about, .footer-links, .communication {
        text-align: left;
        width: auto;
        max-width: none;
    }
    
    .footer-links ul {
        align-items: flex-start;
    }
    
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
    }
    
    .footer-bottom-links {
        flex-direction: row;
    }

}

.communication p {
    margin-bottom: 10px;
    line-height: 1.6;
}

.footer-about, .footer-links, .communication {
    width: 100%;
    max-width: 300px;
    text-align: center;
    position: static;
    left: auto;
    transform: none;
    margin-bottom: 30px;
}

.footer-logo {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.footer-logo img {
    width: 60px;
    height: 60px;
    margin-right: 10px;
}

.footer-logo span {
    font-weight: bold;
    font-size: 22px;
}

.footer-about p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 10px;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--background-color);
    color: var(--text-color);
    transition: var(--transition);
}

.social-link:hover {
    background-color: var(--primary-color);
    color: white;
}

.footer h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
}

@media (min-width: 768px) {
    .footer h3 {
        font-size: 1.2rem;
        margin-bottom: 20px;
    }
}

.footer h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height:2px;
    background-color: var(--primary-color);
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--text-muted);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-newsletter p {
    margin-bottom: 20px;
    color: var(--text-muted);
}

.newsletter-form {
    display: flex;
    gap: 10px;
}

.newsletter-form input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    background-color: var(--background-color);
    color: var(--text-color);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.newsletter-form button {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background-color: var(--primary-hover);
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    text-align: center;
    gap: 15px;
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        text-align: left;
    }
}

.footer-bottom p {
    flex-direction: column;
    text-align: center;
    gap: 15px;
}


.footer-bottom-links {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-bottom-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-bottom-links a:hover {
    color: var(--primary-color);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 99;
    border: none;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-hover);
    transform: translateY(-3px);
}

/* Animation Classes */
.animate-item {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-item.active {
    opacity: 1;
    transform: translateY(0);
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.active {
    opacity: 1;
    transform: translateY(0);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background-color: var(--secondary-color);
}

::-webkit-scrollbar-thumb {
    background-color: var(--primary-color);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--primary-hover);
}

/*--------------------------------------------------*/

.extra-content {
    padding: 40px 0;
    background-color: var(--secondary-color);
    text-align: left; /* Changed from center to left for better readability */
    transition: max-height 0.3s ease;
    border-radius: var(--radius);
    margin-top: 20px;
    overflow-y: auto; /* Added for scrollable content */
    max-height: 500px; /* Added max height with scrolling */
}

.extra-content p {
    margin-bottom: 15px;
    padding: 0 15px;
}

.hidden {
    display: none;
}

/* Responsive improvements for the extra content sections */
@media (max-width: 768px) {
    .section-description {
        font-size: 1rem;
        padding: 0 10px;
    }
    
    .extra-content {
        padding: 20px 0;
    }
}

/* Improved whitespace for lists in the about section */
.section-description {
    white-space: pre-line; /* Preserves line breaks in text */
}