/* =========================================================
   GLOBAL RESET
========================================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background: #ffffff;
    color: #222;
    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.6;
}

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

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

/* =========================================================
   TOP NAVBAR
========================================================= */
.top-navbar {
    min-height: 75px;
    background: #1d1d1d;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 12px 70px;
}

.menu-btn {
    position: absolute;
    left: 25px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 27px;
    cursor: pointer;
}

.brand {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 28px;
    font-weight: normal;
    letter-spacing: 1px;
    text-align: center;
}

.nav-icons {
    position: absolute;
    right: 25px;
    display: flex;
    align-items: center;
    gap: 25px;
    font-size: 21px;
}

.nav-icons i {
    cursor: pointer;
}

/* =========================================================
   DATE AND WEATHER BAR
========================================================= */
.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 20px 30px;
    min-height: 60px;
    background: #fff;
    border-top: 5px solid #222;
    border-bottom: 1px solid #ddd;
    font-family: Georgia, "Times New Roman", serif;
}

.info-bar {
    min-height: 70px;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 10px 25px;
}

.date {
    font-size: 17px;
    color: #555;
}

.weather {
    text-align: right;
    font-size: 16px;
    line-height: 1.6;
}

.weather-main {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    font-size: 18px;
}

.weather-main img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.weather-details {
    margin-top: 5px;
    font-size: 14px;
}

.air-quality {
    font-size: 15px;
}

.air-quality b,
#air-quality {
    color: #008c69;
}

/* =========================================================
   GENERAL PAGE CONTAINER
========================================================= */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 25px;
}

/* =========================================================
   FEATURED ARTICLE / HOME PAGE
========================================================= */
.featured-article {
    padding-bottom: 25px;
    border-bottom: 1px solid #ddd;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.featured-article img {
    width: 100%;
    height: 430px;
    object-fit: cover;
    margin-bottom: 12px;
    transition: opacity 0.2s ease;
}

.featured-article h1 {
    font-size: 32px;
    line-height: 1.2;
    margin-bottom: 20px;
    color: #202020;
    transition: color 0.2s ease;
}

.featured-article:hover {
    transform: translateY(-3px);
}

.featured-article:hover img {
    opacity: 0.92;
}

.featured-article:hover h1,
.article:hover h2,
.small-article:hover h2 {
    color: #555;
}

.author {
    font-family: Arial, sans-serif;
    font-size: 14px;
    color: #555;
    margin: 0 0 16px;
}

.description {
    font-size: 19px;
    line-height: 1.65;
    color: #333;
}

/* =========================================================
   ARTICLE LIST
========================================================= */
.article {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 200px;
    gap: 25px;
    padding: 30px 0;
    border-bottom: 1px solid #ddd;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.article h2 {
    font-size: 25px;
    line-height: 1.3;
    margin-bottom: 15px;
    transition: color 0.2s ease;
}

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

.article:hover {
    transform: translateY(-3px);
}

/* =========================================================
   ARTICLE GRID / SMALL ARTICLES
========================================================= */
.article-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px;
    padding-top: 30px;
}

.small-article {
    min-width: 0;
    border-bottom: 1px solid #ddd;
    padding-bottom: 20px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.small-article img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    margin-bottom: 15px;
}

.small-article h2 {
    font-size: 22px;
    line-height: 1.3;
    margin: 8px 0 15px;
    transition: color 0.2s ease;
}

.category {
    font-family: Arial, sans-serif;
    font-size: 12px;
    font-weight: bold;
    color: #777;
    letter-spacing: 1px;
}

.featured-article:hover,
.article:hover,
.small-article:hover {
    transform: translateY(-3px);
}

/* =========================================================
   SINGLE ARTICLE PAGE
========================================================= */
.single-article {
    width: 100%;
    max-width: 1000px;
    margin: 42px auto;
    padding: 0 24px;
}

.back-button {
    display: inline-block;
    margin-bottom: 30px;
    color: #222;
    font-size: 15px;
}

.back-button:hover {
    text-decoration: underline;
}

.article-category {
    font-family: Arial, sans-serif;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 2px;
    margin-bottom: 15px;
    color: #666;
}

.article-title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.15;
    margin-bottom: 20px;
    overflow-wrap: anywhere;
}

.article-author {
    font-size: 16px;
    margin-bottom: 5px;
}

.article-date {
    color: #777;
    font-size: 14px;
    margin-bottom: 30px;
}

.article-main-image {
    width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: cover;
    display: block;
    margin-bottom: 35px;
}

/* Keep the article text at a readable width */
.article-header,
.article-content {
    width: 100%;
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

.article-header h1 {
    text-align: left;
    font-size: clamp(32px, 5vw, 46px);
    line-height: 1.15;
    margin-bottom: 24px;
}

.article-content {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
    line-height: 1.8;
    overflow-wrap: break-word;
    word-wrap: break-word;
    hyphens: auto;
}

.article-content p {
    margin: 0 0 26px;
}

.article-content h2 {
    font-size: 29px;
    line-height: 1.3;
    margin: 42px 0 18px;
}

.article-content h3 {
    font-size: 23px;
    line-height: 1.35;
    margin: 32px 0 14px;
}

.article-content ul,
.article-content ol {
    padding-left: 28px;
    margin: 0 0 26px;
}

.article-content li {
    margin-bottom: 8px;
}

.article-content blockquote {
    margin: 28px 0;
    padding: 5px 0 5px 20px;
    border-left: 4px solid #ccc;
    color: #555;
}

/* =========================================================
   FOOTER
========================================================= */
footer {
    margin-top: 50px;
    background: #1d1d1d;
    color: #fff;
    text-align: center;
    padding: 50px 20px;
}

.footer-brand {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 35px;
    margin-bottom: 15px;
}

footer p {
    color: #ccc;
    margin-bottom: 25px;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 18px 25px;
    font-family: Arial, sans-serif;
    font-size: 14px;
}

/* =========================================================
   TABLE STYLES (if used on a page)
========================================================= */
table {
    width: 100%;
    margin: 20px auto;
    border-collapse: collapse;
    table-layout: fixed;
}

th,
td {
    border: 1px solid #333;
    padding: 12px;
    text-align: center;
    vertical-align: middle;
    line-height: 1.6;
    overflow-wrap: break-word;
}

th {
    font-weight: bold;
    font-size: 18px;
}

td {
    font-size: 16px;
}

/* =========================================================
   RESPONSIVE DESIGN
========================================================= */
@media (max-width: 768px) {
    .top-navbar {
        min-height: 65px;
        padding: 10px 55px;
    }

    .brand {
        font-size: 21px;
    }

    .menu-btn {
        left: 15px;
        font-size: 23px;
    }

    .nav-icons {
        right: 15px;
        gap: 12px;
        font-size: 18px;
    }

    .top-header,
    .info-bar {
        padding: 12px 15px;
        gap: 12px;
    }

    .date {
        font-size: 14px;
    }

    .weather,
    .weather-main {
        font-size: 13px;
    }

    .weather-details,
    .air-quality {
        font-size: 12px;
    }

    .container {
        padding: 15px;
    }

    .featured-article img {
        height: 280px;
    }

    .featured-article h1 {
        font-size: 27px;
    }

    .description {
        font-size: 17px;
    }

    .article {
        grid-template-columns: minmax(0, 1fr);
        gap: 15px;
    }

    .article img {
        height: 200px;
        grid-row: 1;
    }

    .article-text {
        grid-row: 2;
    }

    .article-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 20px;
    }

    .small-article img {
        height: 180px;
    }

    .single-article {
        margin: 28px auto;
        padding: 0 20px;
    }

    .article-content {
        font-size: 18px;
        line-height: 1.8;
    }

    .article-content h2 {
        font-size: 25px;
        margin-top: 34px;
    }

    .article-content h3 {
        font-size: 21px;
    }

    th,
    td {
        padding: 8px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .top-navbar {
        padding: 10px 48px;
    }

    .brand {
        font-size: 18px;
        letter-spacing: 0.5px;
    }

    .nav-icons {
        gap: 9px;
        font-size: 16px;
    }

    .top-header,
    .info-bar {
        align-items: flex-start;
    }

    .weather {
        max-width: 55%;
    }

    .featured-article img {
        height: 220px;
    }

    .featured-article h1 {
        font-size: 24px;
    }

    .article-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .small-article img {
        height: 220px;
    }

    .single-article {
        padding: 0 16px;
    }

    .article-title,
    .article-header h1 {
        font-size: 31px;
    }

    .article-main-image {
        margin-bottom: 25px;
    }

    .article-content {
        font-size: 17px;
        line-height: 1.75;
    }

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

    .footer-brand {
        font-size: 29px;
    }

    .footer-links {
        gap: 14px;
    }
}
