.news-item {
    background: var(--dark-bg);
    border-radius: 20px;
    padding: 0;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--lighter-bg);
    cursor: default;
    display: flex;
}

.news-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--theme-dark) 0%, rgba(255, 255, 255, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.news-date {
    flex-shrink: 0;
    width: 80px;
    text-align: center;
    background: var(--gradient-primary);
    border-radius: 20px 0 0 20px;
    padding: 1.5rem 1rem;
    color: var(--white);
    font-weight: 700;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.news-date .day {
    display: block;
    font-size: 2rem;
    line-height: 1;
    font-weight: 700;
}

.news-date .month {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.3rem;
    opacity: 0.9;
}

.news-date .year {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.3rem;
    opacity: 0.9;
}

.news-content {
    flex: 1;
    padding: 2rem;
    position: relative;
    z-index: 2;
}

.news-tag {
    display: inline-block;
    background: var(--gradient-primary);
    color: var(--white);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.news-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 1rem;
    line-height: 1.3;
    position: relative;
}

.news-content p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.news-link {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--white);
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.news-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

.news-link:hover::before {
    left: 100%;
}

.news-link:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: var(--orange-shadow);
}

/* Hero Image Section - At top of content with no gaps */
.article-hero-inline {
    width: calc(100% + 6rem);
    margin: 0;
    padding: 0;
    position: relative;
    overflow: hidden;
    border-radius: 0;
    /* Remove any gap between hero and content top border */
    margin-top: -3rem;
    margin-left: -3rem;
    margin-right: -3rem;
    margin-bottom: 2rem;
}

.article-hero-inline img {
    width: calc(100% + 6rem);
    height: 300px;
    object-fit: cover;
    transition: all 0.4s ease;
    border-radius: 0;
    display: block;
    /* Ensure no gaps around image */
    vertical-align: top;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.article-content {
    max-width: 800px;
    margin: 0 auto;
    background: var(--gradient-card);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: var(--shadow-card);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--light-bg);
}

.article-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    z-index: 2;
}

.article-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-card-gloss);
    opacity: 0.3;
    transition: opacity 0.4s ease;
    z-index: 1;
    pointer-events: none;
}

/* Typography */
.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
    color: var(--white);
    font-weight: 700;
    margin: 2rem 0 1rem 0;
    line-height: 1.3;
    position: relative;
    z-index: 2;
}

.article-content h1 {
    font-size: 2.5rem;
    background: var(--gradient-primary);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
}

.article-content h2 {
    font-size: 2rem;
    color: var(--theme-primary);
    border-left: 4px solid var(--theme-primary);
    padding-left: 1rem;
}

.article-content h3 {
    font-size: 1.5rem;
    color: var(--theme-light);
}

.article-content h4,
.article-content h5,
.article-content h6 {
    font-size: 1.2rem;
    color: var(--text-primary);
}

.article-content p {
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: 1.1rem;
    position: relative;
    z-index: 2;
}

/* Links */
.article-content a {
    color: var(--theme-primary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
}

.article-content a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.article-content a:hover::after {
    width: 100%;
}

.article-content a:hover {
    color: var(--theme-light);
    text-shadow: 0 0 10px var(--theme-accent);
}

/* Lists */
.article-content ul,
.article-content ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
    position: relative;
    z-index: 2;
}

.article-content li {
    color: var(--text-secondary);
    margin-bottom: 0.8rem;
    line-height: 1.6;
    position: relative;
}

.article-content ul li::marker {
    color: var(--theme-primary);
}

.article-content ol li::marker {
    color: var(--theme-primary);
    font-weight: 600;
}

/* Blockquotes */
.article-content blockquote {
    background: var(--gradient-card-hover);
    border-left: 4px solid var(--light-bg);
    margin: 2rem 0;
    padding: 1.5rem 2rem;
    border-radius: 0 15px 15px 0;
    position: relative;
    z-index: 2;
    box-shadow: var(--shadow-sm);
}

.article-content blockquote::before {
    content: '"';
    font-size: 3.5rem;
    color: var(--theme-primary);
    position: absolute;
    top: -15px;
    left: 10px;
    opacity: 0.5;
    font-family: Georgia, serif;
}

.article-content blockquote p {
    margin: 0;
    font-style: italic;
    color: var(--text-primary);
    font-size: 1.1rem;
    position: relative;
    z-index: 1;
}

/* Code blocks */
.article-content pre,
.article-content code {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    background: var(--darker-bg);
    border-radius: 8px;
    position: relative;
    z-index: 2;
}

.article-content code {
    padding: 0.2rem 0.5rem;
    color: var(--theme-accent);
    font-size: 0.9rem;
    border: 1px solid var(--light-bg);
}

.article-content pre {
    padding: 1.5rem;
    margin: 1.5rem 0;
    overflow-x: auto;
    border: 1px solid var(--light-bg);
    box-shadow: var(--shadow-sm);
}

.article-content pre code {
    background: none;
    border: none;
    padding: 0;
    color: var(--text-primary);
    font-size: 0.95rem;
}

/* Regular content images (not hero) */
.article-content img:not(.article-hero-inline img) {
    max-width: 100%;
    height: auto;
    border-radius: 15px;
    margin: 2rem 0;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

/* Tables */
.article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    background: var(--gradient-card-hover);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    position: relative;
    z-index: 2;
}

.article-content th,
.article-content td {
    padding: 1rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid var(--light-bg);
}

.article-content th {
    background: var(--gradient-primary);
    color: var(--white);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.9rem;
}

.article-content td {
    color: var(--text-secondary);
}

.article-content tr:hover {
    background: rgba(255, 111, 0, 0.1);
}

/* Horizontal Rule */
.article-content hr {
    border: none;
    height: 2px;
    background: var(--gradient-primary);
    margin: 3rem 0;
    border-radius: 2px;
    position: relative;
    z-index: 2;
}

/* Strong and emphasis */
.article-content strong {
    color: var(--theme-primary);
    font-weight: 700;
}

.article-content em {
    color: var(--theme-light);
    font-style: italic;
}

/* Article meta information */
.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--light-bg);
    position: relative;
    z-index: 2;
}

.article-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 0 0 20px rgba(0,0,0,0.8);
}

.article-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.article-tag {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Responsive Design */
@media (max-width: 768px) {

    .news-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .news-item {
        flex-direction: column;
    }
    
    .news-date {
        width: 100%;
        border-radius: 20px 20px 0 0;
        padding: 1rem;
        flex-direction: row;
        justify-content: center;
        gap: 0.5rem;
    }
    
    .news-date .day {
        font-size: 1.5rem;
    }
    
    .news-date .month {
        font-size: 0.9rem;
        margin-top: 0;
    }
    
    .news-date .year {
        font-size: 0.7rem;
        margin-top: 0;
    }
    
    .news-content {
        padding: 1.5rem;
    }

    .article-content {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }
    
    .article-hero-inline {
        margin-top: -2rem;
        margin-left: -1.5rem;
        margin-right: -1.5rem;
    }
    
    .article-hero-inline img {
        width: calc(100% + 3rem);
        height: 250px;
    }
    
    .article-content h1 {
        font-size: 1.5rem;
    }
    
    .article-content h2 {
        font-size: 1.5rem;
    }
    
    .article-content h3 {
        font-size: 1.3rem;
    }
    
    .article-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .article-content table {
        font-size: 0.9rem;
    }
    
    .article-content th,
    .article-content td {
        padding: 0.8rem 1rem;
    }
}

@media (max-width: 480px) {

    .news-section {
        padding: 4rem 1rem;
    }
    
    .news-content {
        padding: 1.2rem;
    }
    
    .news-content h3 {
        font-size: 1.2rem;
    }

    .article-content {
        padding: 1.5rem 1rem;
        margin: 0 0.5rem;
    }
    
    .article-hero-inline {
        margin-top: -1.5rem;
        margin-left: -1rem;
        margin-right: -1rem;
    }
    
    .article-hero-inline img {
        width: calc(100% + 2rem);
        height: 200px;
    }
    
    .article-content h1 {
        font-size: 1.25rem;
    }
    
    .article-content p {
        font-size: 1rem;
    }
    
    .article-content ul,
    .article-content ol {
        padding-left: 1.5rem;
    }
    
    .article-content blockquote {
        padding: 1rem 1.5rem;
        margin: 1.5rem 0;
    }
}