/*
Theme Name: Web Design News Theme (Magazine Edition)
Description: A highly structured, image-rich news magazine theme for web design agencies.
Author: Antigravity
Version: 3.0.0
*/

@import url('https://fonts.googleapis.com/css2?family=Assistant:wght@300;400;600;700;800&display=swap');

:root {
    /* Category Tag Colors (User requested colors applied professionally) */
    --cat-red: #ff4d4d;
    --cat-purple: #b33939; /* Deepened for readability */
    --cat-blue: #227093;
    --cat-yellow: #ffb142;
    
    --bg-color: #f4f6f8;
    --white: #ffffff;
    --text-dark: #1e272e;
    --text-muted: #808e9b;
    --border-color: #d2dae2;
    
    /* Accent for links inside posts */
    --anchor-red: #c0392b;
    --anchor-bg: #fff200;
}

* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
    font-family: 'Assistant', sans-serif; 
}

body {
    background-color: var(--bg-color);
    color: var(--text-dark);
    line-height: 1.6;
    direction: rtl;
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Top Header */
header {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo { 
    font-size: 2rem; 
    font-weight: 800; 
    color: var(--text-dark); 
    text-decoration: none; 
}
.logo span { color: var(--cat-red); }

.main-nav {
    display: flex;
}

.main-nav ul { 
    list-style: none; 
    display: flex; 
    gap: 30px; 
}
.main-nav a { 
    text-decoration: none; 
    color: var(--text-dark); 
    font-weight: 600; 
    font-size: 1.1rem; 
    transition: color 0.2s; 
}
.main-nav a:hover { color: var(--cat-red); }

/* Magazine Layout - Top News */
.top-news {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-top: 40px;
    margin-bottom: 40px;
}

.news-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}
.news-card:hover { box-shadow: 0 10px 20px rgba(0,0,0,0.05); }

.news-card img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
    transition: transform 0.5s;
}

.img-wrapper { overflow: hidden; }
.news-card:hover .img-wrapper img { transform: scale(1.05); }

.card-content { 
    padding: 25px; 
    flex-grow: 1; 
    display: flex; 
    flex-direction: column; 
    justify-content: center; 
}

/* Category Tags */
.cat-tag {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 4px 10px;
    color: var(--white);
    border-radius: 2px;
    margin-bottom: 15px;
    text-transform: uppercase;
    align-self: flex-start;
}
.tag-red { background-color: var(--cat-red); }
.tag-purple { background-color: var(--cat-purple); }
.tag-blue { background-color: var(--cat-blue); }
.tag-yellow { background-color: var(--cat-yellow); color: #000; }

.news-card h2 { font-size: 1.8rem; line-height: 1.2; margin-bottom: 10px; }
.news-card h2 a { color: var(--text-dark); text-decoration: none; }
.news-card h2 a:hover { color: var(--cat-blue); }

.main-article h2 { font-size: 2.8rem; }
.main-article p { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 15px; }

.meta { font-size: 0.9rem; color: #a4b0be; font-weight: 600; }

/* Side Articles (Stacked) */
.side-news { display: flex; flex-direction: column; gap: 20px; }
.side-news .news-card { flex-direction: row; height: 100%; }
.side-news .img-wrapper { width: 40%; }
.side-news .img-wrapper img { height: 100%; }
.side-news .card-content { width: 60%; padding: 20px; }
.side-news h2 { font-size: 1.3rem; }

/* Grid Layout for remaining posts */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 50px;
}
.news-grid .news-card h2 {
    font-size: 1.4rem;
}

/* Main Content (Articles / Pages) */
.article-page { 
    background: var(--white); 
    padding: 50px; 
    border: 1px solid var(--border-color); 
    margin-bottom: 50px; 
    border-top: 4px solid var(--cat-blue);
}
.article-page h1 { font-size: 2.5rem; margin-bottom: 30px; border-bottom: 2px solid var(--border-color); padding-bottom: 10px; }
.article-page h2 { font-size: 1.8rem; margin-top: 40px; margin-bottom: 15px; }
.article-page p { font-size: 1.15rem; margin-bottom: 20px; line-height: 1.8; color: #34495e; }
.article-page img { max-width: 100%; height: auto; margin-bottom: 20px; }

/* EXTREMELY PROMINENT ANCHOR TEXT (Requested by User) */
.article-page p a, .post-content p a {
    color: var(--anchor-red);
    background-color: var(--anchor-bg);
    text-decoration: none;
    font-weight: 800;
    padding: 2px 6px;
    border-bottom: 3px solid var(--anchor-red);
    transition: all 0.2s;
}
.article-page p a:hover, .post-content p a:hover {
    color: var(--white);
    background-color: var(--anchor-red);
}

footer { 
    background-color: var(--text-dark); 
    color: var(--white); 
    padding: 40px 0; 
    text-align: center; 
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--cat-red);
}

@media (max-width: 900px) {
    .top-news { grid-template-columns: 1fr; }
    .side-news { flex-direction: row; }
    .side-news .news-card { flex-direction: column; }
    .side-news .img-wrapper { width: 100%; height: 200px; }
    .side-news .card-content { width: 100%; }
}

@media (max-width: 600px) {
    .side-news { flex-direction: column; }
}
