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

:root {
    --primary-color: #bb1919;
    --secondary-color: #222222;
    --text-color: #333333;
    --text-light: #666666;
    --background-color: #ffffff;
    --background-gray: #f4f4f4;
    --border-color: #e0e0e0;
    --link-color: #222222;
    --link-hover: #bb1919;
    --header-bg: #bb1919;
    --nav-bg: #222222;
}

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

a {
    text-decoration: none;
    color: inherit;
}

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

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Top Banner */
.top-banner {
    background-color: var(--secondary-color);
    padding: 8px 0;
}

.top-banner .container {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
}

.sign-in {
    color: #ffffff;
    font-size: 14px;
    padding: 6px 16px;
    border: 1px solid #ffffff;
    border-radius: 3px;
    transition: background-color 0.2s;
}

.sign-in:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.notification-bell {
    color: #ffffff;
    cursor: pointer;
}

/* Main Header */
.main-header {
    background-color: var(--header-bg);
    padding: 12px 0;
}

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

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

.logo-text {
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -1px;
    background-color: var(--secondary-color);
    padding: 4px 12px;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 4px;
}

.main-nav a {
    color: #ffffff;
    padding: 8px 16px;
    font-size: 15px;
    font-weight: 500;
    transition: background-color 0.2s;
    border-radius: 3px;
}

.main-nav a:hover,
.main-nav a.active {
    background-color: rgba(0, 0, 0, 0.2);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 24px;
    cursor: pointer;
}

/* Secondary Nav */
.secondary-nav {
    background-color: var(--nav-bg);
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}

.secondary-nav ul {
    display: flex;
    list-style: none;
    gap: 4px;
    overflow-x: auto;
}

.secondary-nav a {
    color: #ffffff;
    padding: 6px 12px;
    font-size: 14px;
    white-space: nowrap;
    transition: color 0.2s;
}

.secondary-nav a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Main Content */
.main-content {
    padding: 24px 0;
}

/* Hero Section */
.hero-section {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

.hero-main {
    position: relative;
}

.hero-main a {
    display: block;
}

.hero-image {
    position: relative;
    overflow: hidden;
}

.hero-image img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    transition: transform 0.3s;
}

.hero-main:hover .hero-image img {
    transform: scale(1.02);
}

.hero-content {
    padding: 20px 0;
}

.category-tag {
    display: inline-block;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.hero-content h1 {
    font-size: 32px;
    line-height: 1.2;
    margin-bottom: 12px;
    color: var(--link-color);
}

.hero-main:hover .hero-content h1 {
    color: var(--link-hover);
}

.hero-content p {
    font-size: 16px;
    color: var(--text-light);
    margin-bottom: 12px;
}

.timestamp {
    font-size: 13px;
    color: var(--text-light);
}

/* Hero Sidebar */
.hero-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.sidebar-story a {
    display: flex;
    gap: 12px;
    padding: 12px;
    background-color: var(--background-gray);
    transition: background-color 0.2s;
}

.sidebar-story:hover a {
    background-color: #e8e8e8;
}

.sidebar-story img {
    width: 120px;
    height: 80px;
    object-fit: cover;
    flex-shrink: 0;
}

.sidebar-content h3 {
    font-size: 15px;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--link-color);
}

.sidebar-story:hover .sidebar-content h3 {
    color: var(--link-hover);
}

/* Section Styles */
.section {
    margin-bottom: 40px;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 4px solid var(--primary-color);
    margin-bottom: 20px;
}

/* Stories Grid */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.story-card a {
    display: block;
}

.story-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.3s;
}

.story-card:hover img {
    transform: scale(1.02);
}

.story-content {
    padding: 16px 0;
}

.story-content .category-tag {
    font-size: 11px;
    padding: 3px 8px;
}

.story-content h3 {
    font-size: 16px;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--link-color);
}

.story-card:hover .story-content h3 {
    color: var(--link-hover);
}

.story-content p {
    font-size: 14px;
    color: var(--text-light);
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Two Column Layout */
.two-column-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

/* Story List */
.story-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.list-story a {
    display: flex;
    gap: 16px;
    padding: 12px;
    background-color: var(--background-gray);
    transition: background-color 0.2s;
}

.list-story:hover a {
    background-color: #e8e8e8;
}

.list-story img {
    width: 120px;
    height: 80px;
    object-fit: cover;
    flex-shrink: 0;
}

.list-content h4 {
    font-size: 15px;
    line-height: 1.3;
    margin-bottom: 8px;
    color: var(--link-color);
}

.list-story:hover .list-content h4 {
    color: var(--link-hover);
}

/* Entertainment Section */
.entertainment-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 24px;
}

.entertainment-card.featured {
    grid-column: 1;
    grid-row: 1 / 3;
}

.entertainment-card a {
    display: block;
    height: 100%;
}

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

.entertainment-card.featured img {
    height: 100%;
    min-height: 300px;
}

.entertainment-content {
    padding: 16px 0;
}

.entertainment-content h3 {
    font-size: 16px;
    line-height: 1.3;
    color: var(--link-color);
    margin-bottom: 8px;
}

.entertainment-card:hover .entertainment-content h3 {
    color: var(--link-hover);
}

.entertainment-content p {
    font-size: 14px;
    color: var(--text-light);
}

/* Most Read Section */
.most-read-list {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.most-read-list li {
    border-bottom: 1px solid var(--border-color);
}

.most-read-list li:nth-child(odd) {
    border-right: 1px solid var(--border-color);
    padding-right: 20px;
}

.most-read-list li:nth-child(even) {
    padding-left: 20px;
}

.most-read-list a {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px 0;
    transition: color 0.2s;
}

.most-read-list a:hover {
    color: var(--link-hover);
}

.rank {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1;
}

.headline {
    font-size: 15px;
    line-height: 1.4;
}

/* Footer */
.main-footer {
    background-color: var(--secondary-color);
    color: #ffffff;
    padding: 40px 0 20px;
    margin-top: 40px;
}

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

.footer-section h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    color: #ffffff;
}

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

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

.footer-section a {
    color: #cccccc;
    font-size: 14px;
    transition: color 0.2s;
}

.footer-section a:hover {
    color: #ffffff;
    text-decoration: underline;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444444;
}

.footer-bottom p {
    font-size: 13px;
    color: #888888;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .entertainment-card.featured {
        grid-column: 1 / 3;
        grid-row: auto;
    }

    .entertainment-card.featured img {
        height: 300px;
    }
}

@media (max-width: 768px) {
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--header-bg);
        padding: 16px;
        z-index: 1000;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 0;
    }

    .main-nav a {
        display: block;
        padding: 12px 16px;
    }

    .menu-toggle {
        display: block;
    }

    .hero-section {
        grid-template-columns: 1fr;
    }

    .hero-image img {
        height: 300px;
    }

    .hero-content h1 {
        font-size: 24px;
    }

    .two-column-layout {
        grid-template-columns: 1fr;
    }

    .most-read-list {
        grid-template-columns: 1fr;
    }

    .most-read-list li:nth-child(odd) {
        border-right: none;
        padding-right: 0;
    }

    .most-read-list li:nth-child(even) {
        padding-left: 0;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .secondary-nav ul {
        padding-bottom: 8px;
    }
}

@media (max-width: 480px) {
    .stories-grid {
        grid-template-columns: 1fr;
    }

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

    .entertainment-card.featured {
        grid-column: 1;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .sidebar-story a {
        flex-direction: column;
    }

    .sidebar-story img {
        width: 100%;
        height: 150px;
    }

    .list-story a {
        flex-direction: column;
    }

    .list-story img {
        width: 100%;
        height: 150px;
    }

    .logo-text {
        font-size: 24px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.story-card,
.list-story,
.entertainment-card {
    animation: fadeIn 0.3s ease-out;
}

/* Utility Classes */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
