/*
==================================================
CATEGORY SECTION
D-Tech AMP News Pro (MOBILE STRETCH & AMP FIX)
==================================================
*/

/*------------------------------------
Homepage & Layout
------------------------------------*/
.homepage-sections {
    margin: 40px 0;
    direction: rtl;
}

.category-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 35px;
}

/*------------------------------------
Category Box
------------------------------------*/
.category-section {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow .3s ease;
}

.category-section:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, .06);
}

/*------------------------------------
Header
------------------------------------*/
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 3px solid #d60000;
}

.section-title {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
}

.section-title a {
    color: #d60000;
    text-decoration: none;
}

.section-title a:hover {
    color: #111;
}

.section-more {
    color: #666;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
}

.section-more:hover {
    color: #d60000;
}

.category-grid {
    padding: 15px;
}

/*
==================================================
FEATURED MAIN POST (مین کارڈ تصویر فکس)
==================================================
*/
.category-main {
    display: block;
    margin-bottom: 15px;
}

.category-main-thumb,
.category-main-thumb amp-img {
    display: block;
    position: relative;
    width: 100% !important;
    aspect-ratio: 16 / 9 !important;
    overflow: hidden;
    background: #f5f5f5;
    border-radius: 3px;
}

.category-main-thumb img,
.category-main-thumb amp-img img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
    transition: transform .35s ease;
}

.category-main:hover .category-main-thumb img {
    transform: scale(1.03);
}

.category-main-content {
    padding-top: 10px;
    text-align: right;
}

/* ===============================
CATEGORY MAIN TITLE
=============================== */

.category-main-title{
    margin:0 0 8px;
    font-size:22px;
    font-weight:700;
    line-height:1.55;
}

.category-main-title a{
    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:2;

    overflow:hidden;
    text-overflow:ellipsis;

    color:#111;
    text-decoration:none;

    line-height:1.55;
    min-height:3.1em;
}

.category-main-title a:hover{
    color:#d60000;
}

.category-main-meta{
    font-size:11px;
    color:#888;
    margin-bottom:8px;
}

.category-main-excerpt{
    font-size:13px;
    line-height:1.7;
    color:#555;
    margin:0;

    display:-webkit-box;
    -webkit-box-orient:vertical;
    -webkit-line-clamp:2;
    overflow:hidden;
}

/*
==================================================
LIST CARDS (چھوٹے کارڈز)
==================================================
*/
.category-list {
    display: flex;
    flex-direction: column;
}

.category-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-top: 1px solid #ececec;
}

.category-card:first-child {
    border-top: 1px solid #ececec;
}

.category-card-thumb,
.category-card-thumb amp-img {
    flex: 0 0 75px !important;
    width: 75px !important;
    height: 55px !important;
    display: block;
    overflow: hidden;
    border-radius: 3px;
    background: #f5f5f5;
}

.category-card-thumb img,
.category-card-thumb amp-img img {
    width: 75px !important;
    height: 55px !important;
    object-fit: cover !important;
    display: block !important;
}

.category-card-content {
    flex: 1;
    min-width: 0;
    text-align: right;
}

.category-card-title {
    margin: 0 0 4px;
    font-size: 13px;
    line-height: 1.4;
    font-weight: 600;
}

.category-card-title a {
    color: #111;
    text-decoration: none;
    display: block !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
}

.category-card-title a:hover {
    color: #d60000;
}

.category-card-meta {
    font-size: 11px;
    color: #888;
}

/*
==================================================
RESPONSIVE (موبائل اور ٹیبلیٹ)
==================================================
*/
@media(max-width: 1200px) {
    .category-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width: 768px) {
    .category-row {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .category-main-thumb,
    .category-main-thumb amp-img {
        aspect-ratio: 16 / 9 !important;
        height: auto !important;
    }
}
/* ======================================
Hide Date on Homepage
====================================== */

.home .category-main-meta,
.home .category-card-meta,
.home .entry-meta,
.home .post-date,
.home time{
    display:none !important;
}