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

:root {
    --primary-color: #667eea;
    --primary-dark: #5568d3;
    --secondary-color: #764ba2;
    --accent-pink: #ff6b9d;
    --accent-orange: #ffa726;
    --text-color: #1a1a1a;
    --text-light: #666;
    --text-lighter: #999;
    --border-color: #e0e0e0;
    --bg-light: #fafafa;
    --bg-white: #fff;
    --success-color: #4caf50;
    --danger-color: #f44336;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.12);
    --shadow-large: 0 10px 40px rgba(0, 0, 0, 0.15);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background: var(--bg-light);
    font-size: 16px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s;
}
/* Container */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container.narrow {
    max-width: 800px;
    margin: 20px auto 40px;
    padding: 40px 30px 60px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Header */
.header {
    background: var(--bg-white);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    position: relative;
    min-height: 70px;
}

.header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 70px;
}

/* Move search container to the right on desktop */
.header .search-container {
    margin-left: auto;
    order: 2;
    flex-shrink: 0;
}

/* Navigation should take available space */
.header .nav {
    margin-left: 0;
    margin-right: auto;
    flex-grow: 1;
    flex-shrink: 1;
    min-width: 0;
}

.logo {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-color);
    text-decoration: none;
    letter-spacing: -0.4px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
}

.logo-mark {
    position: relative;
    width: 150px;
    height: 40px;
    background-image: url('/assets/Logo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform: rotate(0deg);
    flex-shrink: 0;
}

.logo-text {
    font-weight: 700;
    color: #111827;
}

/* Burger Menu */
.burger-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    gap: 4px;
    margin-left: auto;
}

.burger-line {
    width: 24px;
    height: 2px;
    background: #111827;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.burger-menu-toggle.active .burger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.burger-menu-toggle.active .burger-line:nth-child(2) {
    opacity: 0;
}

.burger-menu-toggle.active .burger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

.nav {
    display: flex;
    gap: 28px;
    align-items: center;
    margin-left: auto;
    font-size: 15px;
    justify-content: flex-end;
}

.nav a {
    color: #1f2933;
    font-weight: 600;
    padding: 0;
    position: relative;
    transition: color 0.2s ease;
    white-space: nowrap;
}

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

.nav a.active {
    color: var(--primary-color);
}

.nav a.active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 2px;
    background: var(--primary-color);
}

/* Search */
.search-container {
    position: relative;
    margin-left: 24px;
}

.search-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #111827;
    transition: all 0.2s ease;
    border-radius: 50%;
}

.search-toggle:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--primary-color);
}

.search-toggle svg {
    width: 18px;
    height: 18px;
    display: block;
}

.search-form {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: var(--bg-white);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 15px;
    min-width: 300px;
    z-index: 1000;
    transform: translateY(10px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.search-form.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.search-form input {
    width: 100%;
    padding: 10px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s;
}

.search-form input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

/* Hero */
.hero {
    position: relative;
    height: 336px;
    margin: 40px 0;
    border-radius: 24px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    padding: 60px;
    background: #0f172a;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('/assets/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.45) 45%, rgba(0,0,0,0.15) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 620px;
    color: white;
}

.hero h1 {
    font-size: 44px;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.35);
}

.hero h1 span {
    display: block;
    white-space: nowrap;
}

.hero p {
    font-size: 16px;
    line-height: 1.6;
    opacity: 0.95;
    font-weight: 500;
    text-shadow: 0 1px 12px rgba(0,0,0,0.4);
}

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

.articles-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 40px;
}

.articles-header h2 {
    font-size: 34px;
    font-weight: 800;
    margin-bottom: 12px;
}

.articles-header p {
    color: var(--text-light);
    font-size: 16px;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.article-card {
    background: var(--bg-white);
    border-radius: 24px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.18);
}

.article-media {
    display: block;
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.article-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
    display: block;
}

.article-card:hover .article-media img {
    transform: scale(1.06);
}

.article-content {
    padding: 24px 26px 28px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--text-lighter);
}

.category-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(99, 102, 241, 0.14);
    color: var(--primary-color);
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 12px;
}

.category-chip::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary-color);
}

.date {
    color: var(--text-lighter);
    font-weight: 500;
}

.article-card h2 {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--text-color);
}

.article-card h2 a {
    color: inherit;
    transition: color 0.2s ease;
}

.article-card h2 a:hover {
    color: var(--primary-color);
}

.article-excerpt {
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.6;
}

.pagination {
    margin-top: 40px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.pagination-link {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(15, 23, 42, 0.18);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    font-weight: 600;
    transition: all 0.2s ease;
}

.pagination-link:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination-link.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    box-shadow: 0 12px 30px rgba(99, 102, 241, 0.35);
}

/* Article Detail */
.article-detail {
    margin: 20px auto 40px;
}

.article-header {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--bg-light);
}

.article-header h1 {
    font-size: 48px;
    line-height: 1.1;
    margin: 20px 0 18px;
    font-weight: 800;
    letter-spacing: -1px;
    color: var(--text-color);
}

.article-header .lead {
    font-size: 20px;
    color: var(--text-light);
    line-height: 1.6;
    font-weight: 400;
    max-width: 720px;
}

.article-body {
    font-size: 19px;
    line-height: 1.8;
    color: var(--text-color);
}

.article-body .article-table {
    width: 100%;
    border-collapse: collapse;
    margin: 28px 0;
    font-size: 16px;
    background: var(--bg-white);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.1);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.article-body .article-table thead {
    background: rgba(99, 102, 241, 0.1);
}

.article-body .article-table th,
.article-body .article-table td {
    padding: 16px 20px;
    border-right: 1px solid rgba(15, 23, 42, 0.08);
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    text-align: left;
    vertical-align: top;
}

.article-body .article-table th:last-child,
.article-body .article-table td:last-child {
    border-right: none;
}

.article-body .article-table tbody tr:last-child td {
    border-bottom: none;
}

.article-body .article-table tbody tr:nth-child(odd) {
    background: rgba(15, 23, 42, 0.02);
}

.article-body h2 {
    font-size: 34px;
    margin: 45px 0 22px;
    color: var(--text-color);
    font-weight: 800;
    letter-spacing: -0.4px;
    line-height: 1.2;
}

.article-body h3 {
    font-size: 26px;
    margin: 30px 0 18px;
    color: var(--text-color);
    font-weight: 700;
    line-height: 1.25;
}

.article-body p {
    margin-bottom: 25px;
}

.article-body ul,
.article-body ol {
    margin: 25px 0;
    padding-left: 35px;
}

.article-body li {
    margin-bottom: 12px;
    line-height: 1.7;
}

.article-body strong {
    font-weight: 700;
    color: var(--text-color);
}

.article-body figure.article-image {
    margin: 20px 0 30px;
    text-align: center;
}

.article-body figure.article-image.article-hero {
    margin: 10px 0 30px;
}

.article-body figure.article-image img {
    border-radius: 16px;
    box-shadow: var(--shadow-large);
    margin: 0 auto;
}

.article-body figcaption {
    margin-top: 15px;
    font-size: 15px;
    color: var(--text-lighter);
    font-style: italic;
    font-weight: 500;
}

.article-tags {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 2px solid var(--bg-light);
}

.tag {
    display: inline-block;
    background: var(--bg-light);
    padding: 8px 16px;
    border-radius: 20px;
    margin: 5px 8px 5px 0;
    font-size: 14px;
    color: var(--text-color);
    font-weight: 600;
    transition: all 0.3s;
}

.tag:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* Breadcrumb */
.breadcrumb {
    padding: 25px 0;
    font-size: 14px;
    color: var(--text-lighter);
    font-weight: 500;
}

.breadcrumb a {
    color: var(--text-light);
    transition: color 0.3s;
}

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

/* Page Title */
.page-title {
    font-size: 32px;
    margin: 15px 0 25px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -1px;
    color: var(--text-color);
}

/* Search Page Styles */
.search-results-count {
    color: #4a5568;
    font-size: 1.1em;
    margin-bottom: 30px;
    font-weight: 500;
}

.query.highlight-text {
    color: #677feb;
    font-weight: 600;
}

.no-results {
    text-align: center;
    padding: 60px 20px;
    max-width: 600px;
    margin: 0 auto;
}

.no-results-icon {
    font-size: 4rem;
    color: #cbd5e0;
    margin-bottom: 20px;
}

.no-results h2 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 2em;
}

.no-results p {
    color: #4a5568;
    font-size: 1.1em;
    margin-bottom: 30px;
    line-height: 1.6;
}

.suggestions {
    background: #f7fafc;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: left;
}

.suggestions h3 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.suggestions ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.suggestions li {
    margin-bottom: 8px;
    color: #4a5568;
    padding-left: 20px;
    position: relative;
}

.suggestions li::before {
    content: "→";
    color: #677feb;
    position: absolute;
    left: 0;
    font-weight: bold;
}

.search-prompt {
    text-align: center;
    padding: 60px 20px;
    max-width: 600px;
    margin: 0 auto;
}

.search-prompt-icon {
    font-size: 4rem;
    color: #cbd5e0;
    margin-bottom: 20px;
}

.search-prompt h2 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 2em;
}

.search-prompt p {
    color: #4a5568;
    font-size: 1.1em;
    margin-bottom: 15px;
    line-height: 1.6;
}

.search-tips {
    font-size: 0.95em;
    color: #718096;
    font-style: italic;
}

.read-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #677feb;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.read-more-btn:hover {
    color: #4d6be6;
    gap: 12px;
}

.read-more-btn i {
    transition: transform 0.3s ease;
}

.read-more-btn:hover i {
    transform: translateX(3px);
}

/* Breadcrumb */
.breadcrumb {
    margin-bottom: 20px;
    font-size: 0.9em;
    color: #718096;
}

.breadcrumb a {
    color: #677feb;
    text-decoration: none;
    transition: color 0.2s;
}

.breadcrumb a:hover {
    color: #4d6be6;
}

/* Enhanced article cards for search results */
.articles-grid .article-card {
    margin-bottom: 30px;
}

.articles-grid .article-title {
    font-size: 1.25em;
    margin-bottom: 10px;
}

.articles-grid .article-title a {
    color: #2d3748;
    text-decoration: none;
    transition: color 0.2s;
}

.articles-grid .article-title a:hover {
    color: #677feb;
}

.articles-grid .article-excerpt {
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 15px;
}

.articles-grid .article-meta {
    margin-bottom: 12px;
}

.articles-grid .category-chip {
    font-size: 0.8em;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 500;
    margin-right: 10px;
}

.articles-grid .article-date {
    font-size: 0.9em;
    color: #718096;
}

.articles-grid .article-date i {
    margin-right: 5px;
}

.page-content {
    flex: 1;
    padding: 40px 0;
}

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

/* Related Articles Section */
.related-articles-section {
    margin: 60px 0 80px 0;
}

/* --- Newsletter Section Styles --- */
.newsletter-section {
    padding: 0 0 60px 0; /* Bottom padding to separate from the main footer */
}

.newsletter-content {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), 
                url('/assets/subs.jpg') center/cover no-repeat;
    border-radius: 15px;
    padding: 50px 70px;
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.newsletter-title {
    font-size: 2.2em;
    font-weight: 600;
    margin: 0;
}

.newsletter-description {
    font-size: 1.1em;
    font-weight: 300;
    line-height: 1.5;
    max-width: 60%; 
    margin: 0;
}

.newsletter-form-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: auto; /* Allow form to take natural width */
    margin-top: 10px;
}

.newsletter-form {
    display: flex;
    gap: 10px; 
}

.email-input {
    flex-grow: 1;
    min-width: 250px;
    padding: 15px 20px;
    border: 1px solid rgba(255, 255, 255, 0.3); 
    background-color: rgba(255, 255, 255, 0.3); /* Semi-transparent white */
    border-radius: 8px;
    color: #ffffff;
    font-size: 1em;
    outline: none;
    transition: all 0.3s ease;
}

.email-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.email-input:focus {
    background-color: rgba(255, 255, 255, 0.4);
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.2);
}

.email-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.subscribe-button {
    background-color: #677feb;
    color: #ffffff;
    padding: 15px 30px;
    border: 2px solid #677feb;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.subscribe-button:hover {
    background-color: #4d6be6;
    border-color: #4d6be6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.privacy-text {
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

.privacy-link {
    color: #ffffff; 
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.5);
}

.privacy-link:hover {
    color: #677feb;
    border-bottom-color: #677feb;
    text-decoration: none;
    opacity: 1;
}


/* --- Main Footer Styles --- */
.main-footer {
    padding: 60px 0;
    background-color: #ffffff; 
    color: #333;
}

.footer-grid {
    display: grid;
    /* Defines 5 columns: 2.5 parts for "about", and 4 equal parts for the link columns */
    grid-template-columns: 2.5fr repeat(4, 1fr); 
    gap: 40px;
}

.footer-about {
    text-align: left;
    width: 100%;
}

.logoipsum-brand {
    display: flex;
    justify-content: flex-start;
    font-size: 1.2em;
    font-weight: 700;
    margin-bottom: 15px;
    color: #000;
}

.logo-mark {
    color: #38a169;
    font-size: 1.5em; 
    margin-right: 8px;
    display: block;
}

.about-text {
    font-size: 0.95em;
    line-height: 1.6;
    color: #555;
    text-align: left;
    margin: 15px 0 0;
    max-width: 340px; /* Reduced from 100% to make text wrap to two lines */
}

.footer-links {
    grid-column: span 4; 
    display: grid;
    grid-template-columns: repeat(4, 1fr); 
    gap: 30px;
}

.column-title {
    font-size: 1.1em;
    font-weight: 600;
    margin-bottom: 15px;
    color: #000; 
}

.footer-column {
    text-align: left; /* Left align by default for desktop */
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left; /* Left align list items for desktop */
}

.footer-column li {
    margin-bottom: 8px;
}

.footer-column a {
    color: #555; 
    text-decoration: none;
    font-size: 0.95em;
    transition: color 0.2s;
    display: inline-block; /* Ensure proper alignment */
}

.footer-column a:hover {
    color: #677feb;
    text-decoration: none;
}


/* --- Responsive Adjustments --- */
@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: 1fr; /* Stack columns */
        gap: 30px;
    }
    
    .footer-links {
        grid-column: span 1;
        grid-template-columns: repeat(2, 1fr); /* 2 link columns side-by-side */
    }

    .newsletter-description {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .newsletter-content {
        padding: 40px;
    }

    .newsletter-title {
        font-size: 1.8em;
        line-height: 1.1;
    }

    .newsletter-form {
        flex-direction: column;
    }
    
    .subscribe-button {
        width: 100%;
    }
}

@media (max-width: 550px) {
    .footer-links {
        grid-template-columns: 1fr; /* Stack all link columns */
    }
    
    .footer-about {
        text-align: left;
        width: 100%;
    }

    .footer-about .logo {
        justify-content: flex-start !important;
        margin-left: 0;
        margin-right: auto;
        display: block;
    }

    .footer-about .logo .logo-mark {
        margin-left: 0;
    }

    .footer-about p.about-text {
        text-align: left;
        margin: 15px 0 0 0;
        max-width: 100%;
        text-align-last: left;
    }
    
    .logoipsum-brand {
        justify-content: center;
    }
}

/* Responsive */
@media (max-width: 1200px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
    }

    .article-media {
        height: 200px;
    }
}

@media (max-width: 1024px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 28px;
    }

    .article-media {
        height: 200px;
    }
}

@media (max-width: 768px) {
    .articles-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .article-media {
        height: 240px;
    }

    .hero h1 span {
        white-space: normal;
    }

    .hero p {
        font-size: 15px;
    }

    .articles-grid {
        grid-template-columns: 1fr;
        gap: 25px;
        margin: 30px 0;
    }

    .article-card .article-image {
        height: 300px;
    }

    .article-card h2 {
        font-size: 20px;
    }

    .article-content {
        padding: 20px;
    }

    .article-header h1 {
        font-size: 30px;
    }

    .article-body {
        font-size: 16px;
    }

    .article-body h2 {
        font-size: 24px;
    }

    .article-body h3 {
        font-size: 20px;
    }

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

@media (max-width: 480px) {
    .hero {
        height: 280px;
        padding: 30px 20px;
        margin: 20px 0;
        border-radius: 16px;
    }
    
    .hero h1 {
        font-size: 24px;
    }
    
    .hero p {
        font-size: 14px;
    }
    
    .article-card .article-image {
        height: 250px;
    }

    .article-media {
        height: 200px;
    }
    
    .article-card h2 {
        font-size: 18px;
    }
    
    .article-content {
        padding: 18px;
    }
    
    .article-header h1 {
        font-size: 24px;
    }
}

@media (max-width: 768px) {
    .pagination {
        margin-top: 30px;
    }
    
    .article-navigation {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-button {
        width: 100%;
    }
    
    .nav-placeholder {
        display: none;
    }
}


/* Article Navigation */
.article-navigation {
    display: flex;
    justify-content: space-between;
    margin: 50px 0;
    gap: 20px;
}

.nav-button {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    transition: all 0.3s ease;
    text-decoration: none;
    color: var(--text-color);
    min-width: 0;
    font-size: 14px;
    line-height: 1.2;
    height: auto;
}

.nav-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.nav-button.prev {
    text-align: left;
}

.nav-button.next {
    text-align: left;
    justify-content: space-between;
    flex-direction: row;
}

.nav-button .nav-arrow {
    margin-left: 15px;
    flex-shrink: 0;
}

.nav-button.prev .nav-arrow {
    margin-right: 15px;
    margin-left: 0;
}

.nav-arrow {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 15px;
    flex-shrink: 0;
}

.nav-text {
    flex: 1;
    min-width: 0;
}

.nav-label {
    display: block;
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 4px;
}

.nav-title {
    display: block;
    font-weight: 600;
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-placeholder {
    flex: 1 1 300px;
    min-width: 0;
}

/* Responsive styles */
@media (max-width: 768px) {
    .article-navigation {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-button {
        width: 100%;
    }
    
    .nav-placeholder {
        display: none;
    }
}

/* Giveaway button */
.giveaway-btn {
    background-color: #677feb;
    color: #ffffff;
    padding: 15px 30px;
    border: 2px solid #677feb;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
    text-decoration: none;
    display: inline-block;
    margin-left: 20px;
    flex-shrink: 0;
}

.giveaway-btn:hover {
    background-color: #4d6be6;
    border-color: #4d6be6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 70px; /* Высота header */
    left: 0;
    right: 0;
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

.mobile-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.mobile-menu-content {
    padding: 20px;
    max-width: 400px;
    margin: 0 auto;
}

.mobile-menu-link {
    display: block;
    padding: 15px 20px;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    border-radius: 8px;
    transition: all 0.3s ease;
    margin-bottom: 8px;
    border: 1px solid transparent;
}

.mobile-menu-link:hover {
    background: rgba(103, 127, 235, 0.1);
    color: #677feb;
    border-color: #677feb;
    transform: translateX(5px);
}

.mobile-menu-link.active {
    background: #677feb;
    color: white;
    border-color: #677feb;
}

.mobile-menu-link:last-child {
    margin-bottom: 0;
}

/* Mobile Search */
.mobile-search {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.mobile-search-form {
    display: flex;
    gap: 10px;
    align-items: center;
    background: var(--bg-light);
    border-radius: 12px;
    padding: 4px;
    border: 1px solid var(--border-color);
}

.mobile-search-input {
    flex: 1;
    padding: 12px 16px;
    border: none;
    background: transparent;
    font-size: 16px;
    color: var(--text-color);
    outline: none;
}

.mobile-search-input::placeholder {
    color: var(--text-light);
}

.mobile-search-btn {
    background: #677feb;
    border: none;
    border-radius: 8px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.mobile-search-btn:hover {
    background: #5a67d8;
    transform: scale(1.05);
}

.mobile-search-btn svg {
    width: 18px;
    height: 18px;
}

/* Mobile Header (<1024px) */
@media (max-width: 1023px) {
    .header .container {
        position: relative;
        justify-content: space-between;
        align-items: center;
        padding: 15px 10px;
        min-height: 60px;
    }

    /* Бургер-меню слева */
    .burger-menu-toggle {
        display: flex;
        position: static;
        order: unset;
        margin-left: 0;
        flex-shrink: 0;
    }

    /* Логотип справа от бургер-меню */
    .logo {
        position: static;
        order: unset;
        flex: unset;
        justify-content: flex-start;
        display: flex;
        margin-left: 10px;
        transform: none;
        left: auto;
        top: auto;
    }

    /* Кнопка Giveaway справа */
    .giveaway-btn {
        order: unset;
        margin-left: auto;
        margin-right: 0;
        flex-shrink: 0;
    }

    /* Скрываем текущую мобильную навигацию */
    .nav {
        display: none;
    }

    /* Скрываем поиск на мобильных */
    .search-container {
        display: none;
    }

    /* Размеры элементов */
    .burger-line {
        width: 20px;
        height: 2px;
    }

    .logo-mark {
        width: 120px;
        height: 30px;
    }

    .giveaway-btn {
        padding: 10px 16px;
        font-size: 0.9em;
    }
}

/* Thank You Page */
.thank-you-section {
    padding: 100px 0;
    background: var(--bg-light);
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thank-you-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.thank-you-title {
    font-size: 2.5em;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 20px;
    line-height: 1.2;
}

.thank-you-subtitle {
    font-size: 1.1em;
    color: var(--text-light);
    margin-bottom: 40px;
    line-height: 1.6;
}

.home-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 15px 30px;
    background: #677feb;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1em;
    transition: all 0.3s ease;
    border: 2px solid #677feb;
    min-width: 120px;
}

.home-btn:hover {
    background: #5a67d8;
    border-color: #5a67d8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(103, 127, 235, 0.3);
}

/* Mobile responsive for thank you page */
@media (max-width: 768px) {
    .thank-you-section {
        padding: 60px 0;
    }

    .thank-you-title {
        font-size: 2em;
    }

    .thank-you-subtitle {
        font-size: 1em;
    }

    .home-btn {
        padding: 12px 24px;
        font-size: 0.9em;
    }
}
