/* Base Styles */
:root {
    --primary-color: #0056b3;
    --secondary-color: #f8f9fa;
    --accent-color: #ffc107;
    --text-color: #333;
    --light-text: #f8f9fa;
    --dark-text: #212529;
    --border-color: #dee2e6;
    --success-color: #28a745;
    --error-color: #dc3545;
    --link-color: #0056b3;
    --link-hover-color: #003d7a;
    --box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --container-width: 1200px;
}

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

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

a {
    text-decoration: none;
    color: var(--link-color);
    transition: var(--transition);
}

a:hover {
    color: var(--link-hover-color);
}

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

ul {
    list-style: none;
}

button, input[type="submit"] {
    cursor: pointer;
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    transition: var(--transition);
}

button:hover, input[type="submit"]:hover {
    background-color: var(--link-hover-color);
}

input[type="text"], input[type="email"] {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    width: 100%;
}

.container, .header-container, .footer-container, .main-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 15px;
}

/* Header Styles */
header {
    background-color: white;
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
}

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

.search-bar {
    display: flex;
    max-width: 300px;
    width: 100%;
}

.search-bar input {
    flex-grow: 1;
    border-right: none;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.search-bar button {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    padding: 8px 12px;
}

.main-nav {
    flex-grow: 1;
    text-align: right;
}

.nav-links {
    display: flex;
    justify-content: flex-end;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 500;
    position: relative;
}

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

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

.mobile-menu-btn {
    display: none;
}

/* Breaking News */
.breaking-news {
    background-color: var(--primary-color);
    color: white;
    padding: 8px 15px;
    overflow: hidden;
    display: flex;
}

.breaking-news span {
    font-weight: bold;
    margin-right: 15px;
    white-space: nowrap;
}

.breaking-news-container {
    display: flex;
    animation: scroll-left 30s linear infinite;
    white-space: nowrap;
}

@keyframes scroll-left {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Main Content Styles */
main {
    padding: 20px 0;
}

.featured-news {
    margin-bottom: 30px;
}

h2 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--dark-text);
    position: relative;
    padding-bottom: 8px;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
}

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

.featured-article {
    background-color: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.featured-article:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.featured-article img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.featured-article-content {
    padding: 15px;
}

.article-category {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--dark-text);
    font-size: 0.8rem;
    padding: 3px 8px;
    border-radius: 3px;
    margin-bottom: 8px;
}

.featured-article h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.article-meta {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 10px;
}

.featured-article p {
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.read-more {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.9rem;
}

.main-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.news-card {
    background-color: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: var(--transition);
}

.news-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.news-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.news-card-content {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-card h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.news-card .article-meta {
    margin-bottom: 8px;
}

.news-card p {
    margin-bottom: 10px;
    font-size: 0.9rem;
    flex-grow: 1;
}

/* Sidebar Styles */
.sidebar > div {
    background-color: white;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: var(--box-shadow);
}

.sidebar h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 8px;
}

.sidebar h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--primary-color);
}

.popular-news ul li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}

.popular-news ul li:last-child {
    border-bottom: none;
}

.popular-news a {
    display: flex;
    align-items: center;
}

.popular-news .popular-image {
    width: 60px;
    height: 60px;
    margin-right: 10px;
    object-fit: cover;
    border-radius: 3px;
}

.popular-news .popular-title {
    font-size: 0.9rem;
    font-weight: 500;
}

.categories ul li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.categories ul li:last-child {
    border-bottom: none;
}

.categories a {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.categories a:hover {
    padding-left: 5px;
}

.categories .category-count {
    background-color: var(--secondary-color);
    color: var(--text-color);
    font-size: 0.8rem;
    padding: 2px 8px;
    border-radius: 10px;
}

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

.newsletter input {
    margin-bottom: 10px;
}

/* Footer Styles */
footer {
    background-color: #333;
    color: white;
    padding: 40px 0 0;
}

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

.footer-logo h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: white;
}

.footer-logo h2::after {
    display: none;
}

.footer-logo p {
    font-size: 0.9rem;
    color: #ddd;
}

footer h3 {
    font-size: 1.1rem;
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 8px;
    color: white;
}

footer h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--accent-color);
}

footer ul li {
    padding: 5px 0;
}

footer a {
    color: #ddd;
}

footer a:hover {
    color: white;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: inline-block;
    width: 36px;
    height: 36px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

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

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    margin-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Search Results */
.search-results {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1100;
}

.search-results.active {
    display: flex;
}

.search-results-container {
    background-color: white;
    border-radius: 5px;
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    padding: 20px;
}

.search-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.search-result-item {
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: flex-start;
}

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

.search-result-image {
    width: 100px;
    height: 70px;
    object-fit: cover;
    margin-right: 15px;
    border-radius: 3px;
}

.search-result-content h4 {
    margin-bottom: 5px;
}

.search-result-content p {
    font-size: 0.9rem;
    color: #666;
}

/* Article Page Styles */
.article-header {
    margin-bottom: 20px;
}

.article-title {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.article-meta-full {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-size: 0.9rem;
    color: #666;
}

.article-author {
    margin-right: 15px;
}

.article-date {
    margin-right: 15px;
}

.article-category-label {
    background-color: var(--accent-color);
    color: var(--dark-text);
    padding: 3px 8px;
    border-radius: 3px;
}

.article-featured-image {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    margin-bottom: 20px;
    border-radius: 5px;
}

.article-content {
    line-height: 1.8;
}

.article-content p {
    margin-bottom: 15px;
}

.article-tags {
    margin-top: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.article-tag {
    background-color: var(--secondary-color);
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 0.85rem;
}

.share-article {
    margin-top: 30px;
    display: flex;
    align-items: center;
}

.share-article span {
    margin-right: 15px;
    font-weight: 500;
}

.share-icons {
    display: flex;
    gap: 10px;
}

.share-icons a {
    display: inline-block;
    width: 36px;
    height: 36px;
    background-color: #f0f0f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.share-icons a:hover {
    background-color: var(--primary-color);
    color: white;
}

.related-articles {
    margin-top: 40px;
}

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

/* About Page Styles */
.about-section {
    background-color: white;
    border-radius: 5px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--box-shadow);
}

.about-image {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    margin-bottom: 20px;
    border-radius: 5px;
}

.about-content h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
}

.about-content p {
    margin-bottom: 15px;
    line-height: 1.8;
}

.team-section {
    margin-top: 40px;
}

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

.team-member {
    background-color: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    text-align: center;
}

.team-member img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.team-member-info {
    padding: 20px;
}

.team-member-info h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.team-member-position {
    color: #666;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

/* Contact Page Styles */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.contact-info, .contact-form {
    background-color: white;
    border-radius: 5px;
    padding: 30px;
    box-shadow: var(--box-shadow);
}

.contact-info h2, .contact-form h2 {
    margin-bottom: 20px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 20px;
}

.info-item i {
    margin-right: 15px;
    color: var(--primary-color);
}

.contact-form form {
    display: grid;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input, .form-group textarea {
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.submit-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.submit-btn:hover {
    background-color: var(--link-hover-color);
}

.map-container {
    height: 300px;
    margin-top: 30px;
    border-radius: 5px;
    overflow: hidden;
}

.map-container iframe {
    width: 100%;
    height: 100%;
    border: 0;
}
