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

:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --text-color: #333;
    --light-bg: #f8f9fa;
    --border-color: #e0e0e0;
    --bg-color: #fff;
}

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

/* Dark Mode */
body.dark-mode {
    --text-color: #e0e0e0;
    --light-bg: #2a2a2a;
    --border-color: #444;
    --bg-color: #1a1a1a;
    background-color: var(--bg-color);
}

body.dark-mode .navbar {
    background: linear-gradient(135deg, #5568d3 0%, #6a3a8a 100%);
}

body.dark-mode .article-card,
body.dark-mode .guide-card,
body.dark-mode .checklist,
body.dark-mode .resource-card,
body.dark-mode .contact-form,
body.dark-mode .info-card,
body.dark-mode .tool-card,
body.dark-mode .blog-post,
body.dark-mode .sidebar-widget,
body.dark-mode .testimonial-card,
body.dark-mode .case-study-card {
    background-color: #2a2a2a;
    border-color: #444;
}

body.dark-mode .article-card:hover,
body.dark-mode .guide-card:hover,
body.dark-mode .resource-card:hover {
    background-color: #333;
}

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

/* Navigation */
.navbar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s;
}

.nav-links a:hover {
    opacity: 0.8;
}

.navbar-icons {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.dark-mode-toggle,
.search-toggle {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s;
}

.dark-mode-toggle:hover,
.search-toggle:hover {
    background: rgba(255,255,255,0.3);
}

/* Search Bar */
.search-bar {
    background: var(--light-bg);
    padding: 1rem 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.search-bar.active {
    max-height: 80px;
}

.search-bar .container {
    display: flex;
    gap: 0.5rem;
}

.search-bar input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
}

.search-bar button {
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.cta-button {
    display: inline-block;
    background-color: white;
    color: var(--primary-color);
    padding: 12px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: transform 0.3s, box-shadow 0.3s;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.cta-button.secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
    margin-left: 1rem;
}

.cta-button.secondary:hover {
    background-color: rgba(255,255,255,0.1);
}

/* Ad Spaces */
.ad-space {
    background-color: var(--light-bg);
    padding: 30px 0;
    margin: 30px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.ad-space ins {
    display: block;
}

/* Featured Articles */
.featured-articles {
    margin: 60px 0;
}

.featured-articles h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--text-color);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.article-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.article-image {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
}

.article-card h3 {
    padding: 1.5rem 1.5rem 0;
    font-size: 1.3rem;
    color: var(--text-color);
}

.article-card p {
    padding: 0 1.5rem 1rem;
    color: #666;
    font-size: 0.95rem;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #999;
    padding: 0 1.5rem;
}

.social-share {
    display: flex;
    gap: 1rem;
    padding: 0 1.5rem;
    margin-bottom: 1rem;
}

.social-share a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s;
}

.social-share a:hover {
    color: var(--secondary-color);
}

.read-more {
    display: inline-block;
    padding: 0 1.5rem 1.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s;
}

.read-more:hover {
    color: var(--secondary-color);
}

/* Categories */
.categories {
    background-color: var(--light-bg);
    padding: 60px 0;
    margin: 60px 0;
    border-radius: 8px;
}

.categories h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.category-card:hover {
    transform: translateY(-3px);
}

.category-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.category-card p {
    color: #666;
}

/* Newsletter */
.newsletter {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 60px 0;
    margin: 60px 0;
}

.newsletter h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.newsletter p {
    text-align: center;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    gap: 0.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
}

.newsletter-form button {
    padding: 12px 30px;
    background-color: white;
    color: var(--primary-color);
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
}

.newsletter-form button:hover {
    background-color: #f0f0f0;
}

/* Footer */
.footer {
    background-color: #333;
    color: white;
    padding: 40px 0;
    margin-top: 60px;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.footer-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

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

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

/* Responsive Design */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }

    .nav-links {
        gap: 1rem;
    }

    .featured-articles h2,
    .categories h2 {
        font-size: 1.8rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .footer .container {
        flex-direction: column;
        text-align: center;
    }
}

/* Testimonials */
.testimonials {
    background-color: var(--light-bg);
    padding: 60px 0;
    margin: 60px 0;
}

.testimonials h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.testimonial-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.testimonial-card .stars {
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.testimonial-card .quote {
    font-style: italic;
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.testimonial-card .author {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.testimonial-card .avatar {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.testimonial-card .name {
    margin: 0;
    font-weight: bold;
    color: var(--text-color);
}

.testimonial-card .role {
    margin: 0;
    font-size: 0.9rem;
    color: #999;
}

/* FAQ */
.faq {
    padding: 60px 0;
    background-color: var(--light-bg);
    margin: 60px 0;
}

.faq h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    margin-bottom: 1rem;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.faq-question {
    width: 100%;
    padding: 1.5rem;
    border: none;
    background: white;
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1rem;
    font-weight: bold;
    color: var(--text-color);
    transition: background 0.3s;
}

.faq-question:hover {
    background: var(--light-bg);
}

.faq-item.open .faq-question {
    background: var(--primary-color);
    color: white;
}

.toggle {
    font-size: 1.5rem;
    font-weight: bold;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0 1.5rem;
    background: white;
}

.faq-item.open .faq-answer {
    padding: 1.5rem;
}

.faq-answer p {
    color: #666;
    line-height: 1.8;
}

/* Exit Intent Popup */
.exit-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.exit-popup-content {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-popup {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #999;
}

.exit-popup-content h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.exit-popup-content p {
    color: #666;
    margin-bottom: 1.5rem;
}

.exit-popup-content form {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.exit-popup-content input {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
}

.exit-popup-content button {
    padding: 0.75rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
}

.popup-note {
    font-size: 0.85rem;
    color: #999;
    text-align: center;
}

/* Footer Sections */
.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.footer-section p {
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    transition: background 0.3s;
}

.social-links a:hover {
    background: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
    text-align: center;
}
