/* ===== Global Styles ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ===== Header Styles ===== */
.main-header {
    background-color: #2c3e50;
    color: white;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
}

.logo h1 span {
    color: #3498db;
}

.main-nav ul {
    display: flex;
    list-style: none;
}

.main-nav a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.main-nav a:hover, 
.main-nav a.active {
    color: #3498db;
}

/* ===== Mobile Menu ===== */
.mobile-menu-btn {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: white;
}

.mobile-menu {
    display: none;
    background-color: #2c3e50;
    padding: 1rem;
}

.mobile-menu ul {
    list-style: none;
}

.mobile-menu a {
    color: white;
    text-decoration: none;
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* ===== Hero Section ===== */
.hero {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('../images/tech-bg.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 5rem 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.btn {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
}

.btn:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
}

/* ===== Featured Articles ===== */
.featured-section {
    padding: 3rem 0;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #2c3e50;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background-color: #3498db;
    margin: 0.5rem auto 0;
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.featured-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.featured-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

.card-image {
    height: 200px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-card:hover .card-image img {
    transform: scale(1.1);
}

.card-content {
    padding: 1.5rem;
}

.category-tag {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-bottom: 0.8rem;
    font-weight: 600;
}

.category-tag.ai {
    background-color: #f0f9ff;
    color: #0369a1;
}

.category-tag.programming {
    background-color: #f0fdf4;
    color: #166534;
}

.category-tag.gadgets {
    background-color: #fff7ed;
    color: #9a3412;
}

.card-content h3 {
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
}

.card-content h3 a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.card-content h3 a:hover {
    color: #3498db;
}

.card-content p {
    margin-bottom: 1rem;
    color: #666;
    font-size: 0.95rem;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #777;
    padding-top: 0.5rem;
    border-top: 1px solid #eee;
}

.card-footer a {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
}

/* ===== Newsletter ===== */
.newsletter {
    background-color: #f1f5f9;
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    margin: 3rem 0;
}

.newsletter h2 {
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.newsletter p {
    margin-bottom: 1.5rem;
    color: #666;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px 0 0 5px;
    font-size: 1rem;
}

.newsletter-form button {
    border-radius: 0 5px 5px 0;
    border: none;
    cursor: pointer;
}

/* ===== Footer ===== */
.main-footer {
    background-color: #2c3e50;
    color: white;
    padding: 2rem 0;
    text-align: center;
    margin-top: 3rem;
}

.footer-links {
    margin-bottom: 1rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
    margin: 0 0.5rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #3498db;
}

.social-icons {
    margin-bottom: 1rem;
}

.social-icons a {
    color: white;
    font-size: 1.2rem;
    margin: 0 0.5rem;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: #3498db;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .main-nav {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero h2 {
        font-size: 2rem;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        border-radius: 5px;
    }

    .newsletter-form button {
        margin-top: 0.5rem;
    }
}



/* ===== Category Hero ===== */
.category-hero {
    padding: 4rem 0;
    text-align: center;
    color: white;
    margin-bottom: 2rem;
    background-size: cover;
    background-position: center;
}

.ai-hero {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('../images/ai-banner.jpg');
}

.category-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.category-hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
}

/* ===== Breadcrumb ===== */
.breadcrumb {
    padding: 1rem 0;
    font-size: 0.9rem;
    color: #666;
}

.breadcrumb a {
    color: #3498db;
    text-decoration: none;
}

.breadcrumb span {
    color: #2c3e50;
    font-weight: 600;
}

/* ===== Featured Article ===== */
.featured-article {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 3rem 0;
    align-items: center;
}

.featured-badge {
    display: inline-block;
    background-color: #e11d48;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.featured-article h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.featured-article .meta {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.featured-article .meta a {
    color: #3498db;
    text-decoration: none;
}

.featured-article p {
    margin-bottom: 2rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

.featured-image {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

.image-credit {
    position: absolute;
    bottom: 0;
    right: 0;
    background-color: rgba(0,0,0,0.7);
    color: white;
    padding: 0.3rem 0.6rem;
    font-size: 0.7rem;
    border-radius: 4px 0 0 0;
}

/* ===== Article Grid ===== */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.article-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .card-image img {
    transform: scale(1.05);
}

.read-time {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(0,0,0,0.7);
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.card-content {
    padding: 1.5rem;
}

.card-content h3 {
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
}

.card-content h3 a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.3s ease;
}

.card-content h3 a:hover {
    color: #3498db;
}

.card-content .meta {
    color: #666;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.card-content .meta a {
    color: #3498db;
    text-decoration: none;
}

.card-content p {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.6;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    font-size: 0.85rem;
}

.comments {
    color: #666;
}

.read-more {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
}

/* ===== Pagination ===== */
.pagination {
    display: flex;
    justify-content: center;
    margin: 3rem 0;
}

.pagination a {
    color: #2c3e50;
    text-decoration: none;
    padding: 0.5rem 1rem;
    margin: 0 0.2rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.pagination a:hover, 
.pagination a.active {
    background-color: #3498db;
    color: white;
}

/* ===== Newsletter CTA ===== */
.newsletter-cta {
    background-color: #f1f5f9;
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    margin: 3rem 0;
}

.newsletter-cta h3 {
    margin-bottom: 0.5rem;
    color: #2c3e50;
}

.newsletter-cta p {
    margin-bottom: 1.5rem;
    color: #666;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px 0 0 5px;
    font-size: 1rem;
}

.newsletter-form button {
    border-radius: 0 5px 5px 0;
    border: none;
    cursor: pointer;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .featured-article {
        grid-template-columns: 1fr;
    }
    
    .featured-content {
        order: 2;
    }
    
    .featured-image {
        order: 1;
    }
    
    .article-grid {
        grid-template-columns: 1fr;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        border-radius: 5px;
    }
    
    .newsletter-form button {
        margin-top: 0.5rem;
    }
}



/* ===== Guide-Specific Styles ===== */
.guide-container {
    background: #f8fafc;
    color: #1e293b;
    line-height: 1.8;
}

.guide-hero {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.guide-hero::after {
    content: "";
    position: absolute;
    bottom: -50px;
    left: 0;
    right: 0;
    height: 100px;
    background: #f8fafc;
    transform: skewY(-2deg);
    z-index: 1;
}

.language-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.tab-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.tab-btn.active {
    background: white;
    color: #1e40af;
}

.guide-section {
    padding: 3rem 0;
    position: relative;
    z-index: 2;
}

.content-block {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.feature-list {
    columns: 2;
    margin: 1.5rem 0;
}

.code-preview {
    position: relative;
    margin: 1.5rem 0;
    border-radius: 8px;
    overflow: hidden;
}

.code-preview pre {
    margin: 0;
    padding: 1.5rem;
    background: #1e293b;
    color: #f8fafc;
    overflow-x: auto;
}

.copy-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #64748b;
    color: white;
    border: none;
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.code-preview:hover .copy-btn {
    opacity: 1;
}

.comparison-table {
    overflow-x: auto;
    margin: 1.5rem 0;
}

.comparison-table table {
    width: 100%;
    border-collapse: collapse;
}

.comparison-table th, 
.comparison-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.comparison-table th {
    background: #f1f5f9;
}

/* Quiz Styles */
.quiz-section {
    padding: 3rem 0;
    background: #f1f5f9;
}

.quiz-container {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.quiz-options {
    display: grid;
    gap: 1rem;
    margin-top: 1.5rem;
}

.quiz-options button {
    padding: 1rem;
    background: #f1f5f9;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.quiz-options button:hover {
    background: #e2e8f0;
}

/* Smart Footer */
.smart-footer {
    background: #1e293b;
    color: white;
    padding: 3rem 0 1.5rem;
    text-align: center;
}

.footer-cta {
    margin-bottom: 2rem;
}

.cta-btn {
    background: #2563eb;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.cta-btn:hover {
    background: #1e40af;
    transform: translateY(-3px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .feature-list {
        columns:  1;
    }
    
    .language-tabs {
        flex-wrap: wrap;
    }
    
    .content-block {
        padding: 1.5rem;
    }
}





