/* Variables */
:root {
    --primary-color: #ea580c;
    --primary-color-dark: #c2410c;
    --secondary-color: #1b1b18;
    --light-color: #FDFDFC;
    --dark-color: #0a0a0a;
    --gray-color: #706f6c;
    --text-color: #374151;
    --heading-color: #111827;
    --border-color: #e5e7eb;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
}

/* Header Styles */
.header {
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #111827;
}

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

.logo-subtitle {
    margin-left: 0.5rem;
    font-size: 0.875rem;
    color: #6b7280;
}

.back-arrow {
    margin-right: 0.5rem;
    font-size: 1.25rem;
}

/* Search Styles */
.search-container {
    flex: 1;
    max-width: 400px;
    margin: 0 2rem;
}

.search-form {
    position: relative;
    width: 100%;
}

.search-input {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-right: 3rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: border-color 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: #ea580c;
    box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.1);
}

.search-button {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: #ea580c;
    color: white;
    border: none;
    padding: 0.5rem;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.search-button:hover {
    background: #c2410c;
}

/* Navigation */
.nav {
    display: flex;
    gap: 2rem;
}

.nav a {
    text-decoration: none;
    color: #374151;
    font-weight: 500;
    transition: color 0.2s;
}

.nav a:hover {
    color: #ea580c;
}

/* Hero Section */
.hero {
    position: relative;
    height: 400px;
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 400"><rect fill="%23374151" width="1200" height="400"/><polygon fill="%234b5563" points="0,400 300,200 600,300 900,100 1200,250 1200,400"/><polygon fill="%236b7280" points="0,400 200,250 500,350 800,150 1200,300 1200,400"/></svg>');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    color: white;
}

.hero-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1rem;
}

.hero h1 {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    background: #ea580c;
    color: white;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 500;
    transition: background-color 0.2s;
}

.cta-button:hover {
    background: #c2410c;
}

/* Main Content */
.main-content {
    max-width: 1280px;
    margin: 0 auto;
    padding: 4rem 1rem;
}

.section-title {
    font-size: 2rem;
    font-weight: bold;
    color: #111827;
    margin-bottom: 2rem;
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.article-card {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.article-card:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.article-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(45deg, #f3f4f6, #e5e7eb);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    font-size: 0.875rem;
}

.article-content {
    padding: 1.5rem;
}

.article-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.article-excerpt {
    color: #6b7280;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.article-meta {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1rem;
}

.article-meta span {
    margin-right: 1rem;
}

.read-more {
    color: #ea580c;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
}

.read-more:hover {
    color: #c2410c;
}

/* Recent Posts */
.recent-posts {
    background: #f9fafb;
    padding: 4rem 1rem;
}

.recent-container {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
}

.recent-list {
    list-style: none;
}

.recent-item {
    padding: 1.5rem 0;
    border-bottom: 1px solid #e5e7eb;
}

.recent-item:last-child {
    border-bottom: none;
}

.recent-date {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.recent-title {
    font-size: 1.125rem;
    font-weight: 600;
}

.recent-title a {
    color: #111827;
    text-decoration: none;
    transition: color 0.2s;
}

.recent-title a:hover {
    color: #ea580c;
}

/* Sidebar */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.sidebar-card {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.sidebar-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 1rem;
}

.newsletter-card {
    background: #fef3e2;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.newsletter-input {
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

.newsletter-button {
    background: #ea580c;
    color: white;
    padding: 0.75rem;
    border: none;
    border-radius: 0.375rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.newsletter-button:hover {
    background: #c2410c;
}

/* Footer */
.footer {
    background: #111827;
    color: white;
    padding: 3rem 1rem;
}

.footer-container {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-section h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-section p {
    color: #9ca3af;
    line-height: 1.6;
}

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

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

.footer-links a {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid #374151;
    margin-top: 2rem;
    padding-top: 2rem;
    text-align: center;
    color: #9ca3af;
}

/* Article Container */
.article-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Article Header */
.article-header {
    margin-bottom: 2rem;
}

.article-category {
    display: inline-block;
    background: #3b82f6;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.article-title {
    font-size: 2.5rem;
    font-weight: bold;
    color: #111827;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Featured Image */
.featured-image {
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
    border-radius: 0.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.125rem;
    position: relative;
    overflow: hidden;
}

.image-caption {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

/* Article Content */
.article-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #374151;
}

.article-content h2 {
    font-size: 1.75rem;
    font-weight: bold;
    color: #111827;
    margin: 2rem 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #3b82f6;
}

.article-content h3 {
    font-size: 1.375rem;
    font-weight: 600;
    color: #111827;
    margin: 1.5rem 0 0.75rem 0;
}

.article-content p {
    margin-bottom: 1.5rem;
}

.article-content ul, .article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content blockquote {
    border-left: 4px solid #3b82f6;
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: #6b7280;
    background: #f0f9ff;
    padding: 1.5rem;
    border-radius: 0 0.5rem 0.5rem 0;
}

.article-content a {
    color: #3b82f6;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.article-content a:hover {
    border-bottom-color: #3b82f6;
}

/* Info Box */
.info-box {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin: 2rem 0;
}

.info-box h4 {
    color: #3b82f6;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Safety Box */
.safety-box {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin: 2rem 0;
}

.safety-box h4 {
    color: #dc2626;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Author Bio */
.author-bio {
    background: #f9fafb;
    border-radius: 0.5rem;
    padding: 2rem;
    margin: 3rem 0;
    border-top: 1px solid #e5e7eb;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar {
    width: 60px;
    height: 60px;
    background: #3b82f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
}

.author-details h4 {
    color: #111827;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.author-details p {
    color: #6b7280;
    font-size: 0.875rem;
}

/* Navigation */
.article-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.nav-link {
    display: flex;
    align-items: center;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #1d4ed8;
}

/* Share Button */
.share-button {
    display: flex;
    align-items: center;
    color: #374151;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    transition: all 0.2s;
}

.share-button:hover {
    color: #ea580c;
    border-color: #ea580c;
}

/* Search Results */
.search-results {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.search-info {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.search-query {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.5rem;
}

.search-meta {
    color: #6b7280;
    font-size: 0.875rem;
}

.result-item {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.2s;
    margin-bottom: 1.5rem;
}

.result-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.result-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.result-title a {
    color: #111827;
    text-decoration: none;
    transition: color 0.2s;
}

.result-title a:hover {
    color: #ea580c;
}

.result-excerpt {
    color: #6b7280;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.result-meta {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: #6b7280;
    gap: 1rem;
}

.result-url {
    color: #ea580c;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.no-results {
    text-align: center;
    padding: 4rem 1rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.no-results h2 {
    font-size: 1.5rem;
    color: #111827;
    margin-bottom: 1rem;
}

.no-results p {
    color: #6b7280;
    margin-bottom: 2rem;
}

.suggestions {
    background: #f3f4f6;
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin-top: 2rem;
}

.suggestions h3 {
    color: #111827;
    margin-bottom: 1rem;
}

.suggestions ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.suggestion-tag {
    background: #ea580c;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    text-decoration: none;
    transition: background-color 0.2s;
}

.suggestion-tag:hover {
    background: #c2410c;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        height: auto;
        padding: 1rem;
        gap: 1rem;
    }

    .search-container {
        margin: 0;
        max-width: none;
        width: 100%;
    }

    .nav {
        gap: 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .recent-container {
        grid-template-columns: 1fr;
    }

    .articles-grid {
        grid-template-columns: 1fr;
    }

    .article-title {
        font-size: 2rem;
    }

    .article-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .featured-image {
        height: 250px;
    }

    .article-content {
        font-size: 1rem;
    }

    .author-info {
        flex-direction: column;
        text-align: center;
    }

    .article-navigation {
        flex-direction: column;
        gap: 1rem;
    }
}
