/* ===========================
FEATURED NEWS
=========================== */

.featured-news{
    background:#fff;
    border-radius:18px;
    overflow:hidden;
    box-shadow:0 8px 20px rgba(0,0,0,.08);
}

.featured-image{
    width:100%;
    height:430px;
    object-fit:cover;
}

.featured-overlay{
    padding:28px;
}

.featured-overlay h2{
    font-size:32px;
    line-height:1.35;
    margin:15px 0;
}

.featured-overlay p{
    color:#666;
    line-height:1.8;
    margin-top:15px;
}

.news-meta{

display:flex;
align-items:center;
gap:20px;

font-size:13px;
color:#666;

margin:10px 0;

}


.read-btn{
    margin-top:22px;
    background:#d60000;
    color:#fff;
    border:none;
    padding:12px 28px;
    border-radius:40px;
    cursor:pointer;
    font-weight:600;
    transition:.3s;
}

.read-btn:hover{
    background:#b60000;
}

/* ===========================
WIDGET
=========================== */

.widget{
    background:#fff;
    border-radius:15px;
    padding:20px;
    box-shadow:0 8px 20px rgba(0,0,0,.08);
}

.widget h2,
.widget h3{
    font-size:22px;
    margin-bottom:18px;
}


/* ===========================
GLOBAL
=========================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    font-family:"Poppins",sans-serif;
    background:#f5f6fa;
    color:#222;
}

.container{
    width:95%;
    max-width:1400px;
    margin:auto;
}

/* ==========================
TOP HEADER
========================== */

.page-header{

    background:#0b1d3a;

    padding:18px 0;

}

.top-header{

    display:flex;

    align-items:center;

    gap:30px;

}

.logo img{

    width:170px;

}

.header-text{

    flex:1;

}

.header-text h1{

    margin:0;

    color:#fff;

    font-size:42px;

    font-weight:800;

}

.header-text p{

    margin-top:8px;

    color:#ddd;

    font-size:17px;

}

/* NAV */
#navbar{

    margin-top:0;

}

/* ===========================
SEARCH
=========================== */

.search-section{

    background:#fff;
    padding:25px 0;
    box-shadow:0 3px 10px rgba(0,0,0,.08);

}

.search-box{

    max-width:700px;
    margin:auto;
    position:relative;

}

.search-box input{

    width:100%;
    border:none;
    background:#f1f2f6;
    border-radius:40px;
    padding:16px 20px 16px 50px;
    font-size:15px;

}

.search-box i{

    position:absolute;
    top:50%;
    left:18px;
    transform:translateY(-50%);
    color:#777;

}

/* ===========================
LAYOUT
=========================== */

.category-page{

     background:#f5f5f5;

    padding:40px 0;

}

.page-layout{

    display:grid;

    grid-template-columns:2fr 1fr;

    gap:30px;

    align-items:start;

    background:#ffffff;

}

.page-main{

    display:flex;
    flex-direction:column;
    gap:25px;

}

.page-sidebar{

    display:flex;
    flex-direction:column;
    gap:25px;

}

/* ===========================
SECTION TITLE
=========================== */

.section-title{

    font-size:28px;
    font-weight:700;

}

/* ===========================
BADGE
=========================== */

.badge{

    display:inline-block;
    background:#d60000;
    color:#fff;
    padding:5px 14px;
    border-radius:30px;
    font-size:12px;
    font-weight:700;

}

/* ===========================
MOST READ
=========================== */

.most-read-item{

    display:flex;
    gap:14px;

    margin-bottom:18px;
    padding-bottom:18px;

    border-bottom:1px solid #ececec;

    cursor:pointer;

    transition:.25s;

}

.most-read-item:hover{

    transform:translateX(5px);

}

.most-read-item:last-child{

    border-bottom:none;
    margin-bottom:0;
    padding-bottom:0;

}

.most-read-item img{

    width:110px;
    height:75px;

    object-fit:cover;

    border-radius:10px;

    flex-shrink:0;

}

.most-read-content{

    flex:1;

}

.most-read-content h4{

    font-size:15px;

    line-height:1.45;

    margin-top:8px;

    display:-webkit-box;

    -webkit-line-clamp:2;

    -webkit-box-orient:vertical;

    overflow:hidden;
    

}

.most-read-content small{

    display:block;

    margin-top:8px;

    font-size:12px;

    color:#888;

}

.most-read-content small i{

    color:#d60000;

    margin-right:5px;

}

.news-meta{
    margin-top:10px;
    display:flex;
    align-items:center;
    gap:15px;
    font-size:9px;
    color:#666;
}

.news-meta i{
    color:#d60000;
    margin-right:4px;
}

.most-read-content small{
    display:block;
    margin-top:6px;
    line-height:1.6;
}

.news-meta span{

display:flex;
align-items:center;
gap:6px;
    font-size: 9px;

}

/* ==========================
TYPE BADGE
========================== */

.typeBadge{
    display:inline-flex;
    align-items:center;
    gap:6px;
    padding:5px 10px;
    border-radius:20px;
    font-size:11px;
    font-weight:700;
    color:#fff;
    margin-bottom:8px;
}

.typeBadge.news{
    background:#1e40af;
}

.typeBadge.video{
    background:#dc2626;
}

.headlineText{
    font-weight:600;
    line-height:1.4;
}


/* ===========================
RESPONSIVE
=========================== */

@media(max-width:991px){

.page-layout{

grid-template-columns:1fr;

}

}

.weather-api{
padding:40px 0;
}

.weather-api-grid{
display:grid;
grid-template-columns:1fr 2fr;
gap:25px;
}

.weather-card,
.forecast-card{

background:#fff;
padding:25px;
border-radius:15px;
box-shadow:0 5px 20px rgba(0,0,0,.08);

}

.weather-card h1{

font-size:55px;
color:#0077ff;

}

#forecastContainer{

display:grid;
grid-template-columns:repeat(7,1fr);
gap:15px;

}

.forecast-item{

text-align:center;

}

.forecast-item img{

width:70px;

}

/* =========================================
   CATEGORY NAVIGATION
   ========================================= */

#navbar{
    position:relative;
}

.category-menu{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:25px;
}

.category-menu a{
    color:#222;
    text-decoration:none;
    font-weight:600;
}


/* =========================================
   MOBILE SEARCH + CATEGORIES
   ========================================= */

.search-mobile-wrapper{
    position:relative;
}


/* HIDE HAMBURGER ON DESKTOP */

.menu-toggle{
    display:none;
}


/* =========================================
   MOBILE
   ========================================= */

@media(max-width:767px){

    .search-section{
        padding:10px 0;
    }

    .search-mobile-wrapper{
        display:flex;
        align-items:center;
        gap:8px;
    }


    /* CATEGORIES BUTTON */

    .menu-toggle{
        display:flex;
        align-items:center;
        justify-content:center;
        gap:6px;

        flex:0 0 105px;

        height:45px;

        padding:0 10px;

        border:none;
        border-radius:10px;

        background:#0b1d3a;
        color:#fff;

        font-family:"Poppins",sans-serif;

        font-size:11px;
        font-weight:600;

        cursor:pointer;
    }

    .menu-toggle i{
        font-size:14px;
    }


    /* SEARCH */

    .search-box{
        flex:1;
        width:auto;
    }

    .search-box input{
        height:45px;
        padding:12px 12px 12px 40px;
        font-size:12px;
    }

    .search-box i{
        left:14px;
        font-size:12px;
    }


    /* CATEGORY DROPDOWN */

    .nav{
        position:relative;
    }

    .nav-links{
    display:none !important;

    position:absolute;

    top:calc(100% + 8px);
    left:0;

    width:230px;

    padding:5px 0;
    margin:0;

    background:#0b1d3a;

    border-radius:10px;

    box-shadow:0 8px 25px rgba(0,0,0,.35);

    z-index:9999;

    list-style:none;
}

.nav-links.active{
    display:block !important;
}

.nav-links li{
    width:100%;
}

.nav-links li a{
    display:block;

    padding:12px 15px;

    font-size:12px;
    font-weight:500;

    color:#fff;

    text-decoration:none;

    border-bottom:1px solid rgba(255,255,255,.10);
}

.nav-links li:last-child a{
    border-bottom:none;
}

/* ACTIVE CATEGORY */

.nav-links li a.active{
    background:#d60000;
    color:#fff;
    font-weight:600;
}

/* HOVER */

.nav-links li a:hover{
    background:#122b50;
}

.nav-links li a.active:hover{
    background:#b90000;
}


/* =========================================
   VERY SMALL PHONES
   ========================================= */

@media(max-width:380px){

    .menu-toggle{
        flex:0 0 95px;
        font-size:10px;
    }

    .menu-toggle i{
        font-size:13px;
    }

    .search-box input{
        font-size:11px;
    }

}

}

/* =========================================
   MOST READ - MOBILE
   REMOVE UNDERLINE
   ========================================= */

@media (max-width: 767px){

    .most-read-item,
    .most-read-item a,
    .most-read-content a,
    .most-read-content h4 a{
        text-decoration: none !important;
        border-bottom: none !important;
    }

    .most-read-content h4{
        text-decoration: none !important;
    }

}
.most-read-content a{
    text-decoration:none !important;
}

/* =========================================
   MOST READ - CATEGORY PAGES
========================================= */

.most-read a,
#mostRead a,
#mostReadList a {
    text-decoration: none !important;
    color: inherit !important;
}

.most-read a:hover,
#mostRead a:hover,
#mostReadList a:hover {
    text-decoration: none !important;
}


/* Most Read item */
.most-read-item,
.most-read li,
#mostReadList li {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}


/* Thumbnail */
.most-read-item img,
.most-read li img,
#mostReadList img {
    width: 65px !important;
    height: 45px !important;
    object-fit: cover !important;
    flex-shrink: 0;
    border-radius: 4px;
}


/* Headline */
.most-read-item h3,
.most-read-item h4,
.most-read li h3,
.most-read li h4,
#mostReadList h3,
#mostReadList h4 {
    margin: 0 !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    font-weight: 600 !important;
}


/* MOST READ - NO UNDERLINE */

.most-read-item,
.most-read-item:hover,
.most-read-item:visited {
    text-decoration: none !important;
}

.most-read-content h4 {
    text-decoration: none !important;
}

@media (max-width: 768px) {

    .most-read-item {
        gap: 8px !important;
        margin-bottom: 10px !important;
        padding-bottom: 10px !important;
    }

    .most-read-item img {
        width: 65px !important;
        height: 45px !important;
        border-radius: 5px !important;
        object-fit: cover !important;
        flex-shrink: 0 !important;
    }

    .most-read-content h4 {
        font-size: 11px !important;
        line-height: 1.3 !important;
        margin: 3px 0 !important;
    }

    .most-read-content small {
        font-size: 9px !important;
    }
}

@media (max-width: 480px) {

    .most-read-item img {
        width: 58px !important;
        height: 40px !important;
    }

    .most-read-content h4 {
        font-size: 10.5px !important;
    }
}












/* =========================== CATEGORY PAGE - GAWING KOPYA NG MOST READ =========================== */
/* I-FORCE NATIN YUNG .news-card PARA MAGING TULAD NG .most-read-item */

/* BUONG CARD */
#contentList .news-card{
  display: flex !important;
  gap: 14px !important;
  padding: 18px 0 !important;
  border-bottom: 1px solid #ececec;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  cursor: pointer;
  transition: .25s;
  margin-bottom: 0 !important;
}
#contentList .news-card:hover{ transform: translateX(5px); }
#contentList .news-card:last-child{ border-bottom: none; padding-bottom: 0; }

/* IMAGE */
#contentList .news-card img{
  width: 110px !important;
  height: 75px !important;
  object-fit: cover;
  border-radius: 10px;
  flex-shrink: 0;
}

/* CONTENT WRAPPER */
#contentList .news-info{
  flex: 1;
  padding: 0 !important;
}

/* TANGGALIN YUNG BADGE NA PULA */
#contentList .news-info .badge{ display: none !important; }

/* TITLE */
#contentList .news-info h3{
  font-family: 'Merriweather', Georgia, serif !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  line-height: 1.45 !important;
  color: #222;
  margin: 8px 0 !important;
  display: -webkit-box;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* TANGGALIN YUNG SUMMARY/P */
#contentList .news-info p{ display: none !important; }

/* META */
#contentList .news-info .news-meta{
  margin-top: 8px !important;
  font-size: 12px !important;
  font-weight: 600;
  color: #888;
  gap: 12px !important;
}
#contentList .news-info .news-meta i{ color: #d60000; margin-right: 4px; }

/* =========================== DARK MODE =========================== */
body.dark-mode #contentList .news-card{ border-bottom-color: #2a3b57 !important; }
body.dark-mode #contentList .news-info h3{ color: #e9eef7 !important; }
body.dark-mode #contentList .news-info .news-meta{ color: #aebbd0 !important; }

/* =========================== MOBILE =========================== */
@media(max-width:768px){
  #contentList .news-card img{ 
    width: 65px !important; 
    height: 45px !important; 
    border-radius: 5px !important;
  }
  #contentList .news-info h3{ 
    font-size: 11px !important; 
    line-height: 1.3 !important;
    margin: 3px 0 !important;
  }
  #contentList .news-info .news-meta{ 
    font-size: 9px !important; 
  }
}









/* =========================== CATEGORY PAGE - GAWING KOPYA NG ARTICLE =========================== */

/* BUONG GRID NG NEWS */
#contentList{
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important; /* 2 COLUMNS SA DESKTOP */
  gap: 25px !important;
}

/* BUONG CARD - GAYA NG FEATURED CARD */
#contentList .news-card{
  display: block !important; /* HINDI NA FLEX LIST */
  background: #fff !important;
  border-radius: 18px !important;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0,0,0,.08) !important;
  padding: 0 !important;
  border: none !important;
  cursor: pointer;
  transition: .3s;
}
#contentList .news-card:hover{
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0,0,0,.12);
}
#contentList .news-card:last-child{ border-bottom: none; }

/* IMAGE - MALAKI GAYA SA ARTICLE */
#contentList .news-card img{
  width: 100% !important;
  height: 220px !important; /* KAPAREHO NG FEATURED */
  object-fit: cover;
  border-radius: 0 !important;
}

/* CONTENT WRAPPER */
#contentList .news-info{
  padding: 20px 24px !important; /* KAPAREHO NG .featured-overlay */
}

/* BADGE - IPAPAKITA NATIN GAYA SA FEATURED */
#contentList .news-info .badge{
  display: inline-block !important; 
  background: #d60000;
  color: #fff;
  padding: 5px 14px;
  border-radius: 30px;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 12px;
}

/* TITLE - GAYA NG .featured-overlay h2 */
#contentList .news-info h3{
  font-family: "Poppins", sans-serif !important; /* SAME FONT */
  font-size: 20px !important; /* MALAKI GAYA SA ARTICLE */
  font-weight: 700 !important;
  line-height: 1.35 !important;
  color: #222;
  margin: 0 0 12px 0 !important;
  display: -webkit-box;
  -webkit-line-clamp: 2 !important; /* 2 LINES LANG */
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* SUMMARY/P - IPAPAKITA NATIN */
#contentList .news-info p{
  display: block !important; /* WAG ITAGO */
  color: #666 !important;
  font-size: 14px !important;
  line-height: 1.8 !important;
  margin-bottom: 12px !important;
  display: -webkit-box;
  -webkit-line-clamp: 2 !important; /* 2 LINES LANG */
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* META - GAYA SA FEATURED */
#contentList .news-info .news-meta{
  margin-top: 10px !important;
  font-size: 13px !important;
  color: #666 !important;
  gap: 20px !important;
  font-weight: 500 !important;
}
#contentList .news-info .news-meta i{ 
  color: #d60000; 
  margin-right: 4px; 
}

/* =========================== DARK MODE =========================== */
body.dark-mode #contentList .news-card{ background: #1e2a3a !important; }
body.dark-mode #contentList .news-info h3{ color: #e9eef7 !important; }
body.dark-mode #contentList .news-info p{ color: #aebbd0 !important; }
body.dark-mode #contentList .news-info .news-meta{ color: #aebbd0 !important; }

/* =========================== RESPONSIVE =========================== */
@media(max-width:991px){
  #contentList{ grid-template-columns: 1fr !important; } /* 1 COLUMN SA TABLET */
}

@media(max-width:768px){
  #contentList .news-card img{ height: 180px !important; }
  #contentList .news-info{ padding: 16px !important; }
  #contentList .news-info h3{ font-size: 17px !important; }
  #contentList .news-info p{ font-size: 13px !important; }
    }














/* =========================== DESKTOP FIX LANG - 992PX PATAAS =========================== */
@media (min-width: 992px){

  /* LAYOUT: 2/3 + 1/3 GAYA NG ARTICLE PAGE */
  .page-layout{
    display: grid !important;
    grid-template-columns: 2fr 1fr !important;
    gap: 30px !important;
    align-items: start !important;
  }
  .page-main{ grid-column: 1; }
  .page-sidebar{ grid-column: 2; }

  /* LATEST NEWS GRID - 2 COLUMNS NA CARD */
  #contentList{
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 25px !important;
  }

  /* CARD STYLE - GAYA NG FEATURED */
  #contentList .news-card{
    display: block !important;
    background: #fff !important;
    border-radius: 18px !important;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,.08) !important;
    padding: 0 !important;
    border: none !important;
    transition: .3s;
  }
  #contentList .news-card:hover{
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0,0,0,.12);
  }

  /* MALAKING IMAGE */
  #contentList .news-card img{
    width: 100% !important;
    height: 220px !important;
    object-fit: cover;
    border-radius: 0 !important;
  }

  /* CONTENT */
  #contentList .news-info{
    padding: 24px !important;
  }

  /* TITLE - GAYA SA ARTICLE */
  #contentList .news-info h3{
    font-size: 20px !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    margin-bottom: 12px !important;
    display: -webkit-box;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* IPAPAKITA YUNG SUMMARY */
  #contentList .news-info p{
    display: -webkit-box !important;
    color: #666 !important;
    font-size: 14px !important;
    line-height: 1.8 !important;
    margin-bottom: 12px !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* META */
  #contentList .news-info .news-meta{
    font-size: 13px !important;
    color: #666 !important;
    gap: 20px !important;
  }
}

/* =========================== MOBILE HAYAAN LANG =========================== */
/* LAHAT NG @media max-width:991px MO DATI WAG GALAWIN */








/* =========================== MOST READ - GAWING KOPYA NG ARTICLE =========================== */

/* DESKTOP: 992PX PATAAS */
@media (min-width: 992px){
  #sidebarContent .widget h3{
    font-size: 24px !important; /* MALAKI NA TITLE */
    font-weight: 700 !important;
    margin-bottom: 20px !important;
  }

  .most-read-item{
    display: flex !important;
    gap: 16px !important;
    padding: 18px 0 !important;
    border-bottom: 1px solid #ececec !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    margin-bottom: 0 !important;
    transition: .25s;
  }
  .most-read-item:hover{
    transform: translateX(5px);
  }
  .most-read-item:last-child{
    border-bottom: none !important;
    padding-bottom: 0 !important;
  }

  /* IMAGE - MEDYO MALAKI */
  .most-read-item img{
    width: 120px !important;  /* NARROW PERO MALAKI */
    height: 85px !important;
    border-radius: 12px !important;
    object-fit: cover;
    flex-shrink: 0;
  }

  /* CONTENT */
  .most-read-content{
    flex: 1;
  }

  /* TITLE - NARROW NA MALAKI GAYA SA ARTICLE */
  .most-read-content h4{
    font-family: "Poppins", sans-serif !important;
    font-size: 16px !important; /* MALAKI SA DESKTOP */
    font-weight: 700 !important;
    line-height: 1.4 !important;
    color: #222 !important;
    margin: 0 0 8px 0 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  /* META - DATE/VIEWS */
  .most-read-content small{
    font-size: 12px !important;
    color: #666 !important;
    font-weight: 500 !important;
  }
  .most-read-content small i{
    color: #d60000 !important;
    margin-right: 5px;
  }
}

/* =========================== MOBILE: 991PX PABABA =========================== */
@media (max-width: 991px){
  .most-read-item{
    display: flex !important;
    gap: 12px !important;
    padding: 14px 0 !important;
    border-bottom: 1px solid #ececec !important;
  }

  /* IMAGE - NARROW SA MOBILE */
  .most-read-item img{
    width: 90px !important;  /* NARROW */
    height: 65px !important;
    border-radius: 10px !important;
  }

  /* TITLE - MEDYO MALAKI PA RIN */
  .most-read-content h4{
    font-size: 14px !important; /* HINDI SOBRANG LIIT */
    font-weight: 700 !important;
    line-height: 1.4 !important;
    -webkit-line-clamp: 2 !important;
  }

  .most-read-content small{
    font-size: 11px !important;
  }
}

/* =========================== DARK MODE =========================== */
body.dark-mode .most-read-item{ border-bottom-color: #2a3b57 !important; }
body.dark-mode .most-read-content h4{ color: #e9eef7 !important; }
body.dark-mode .most-read-content small{ color: #aebbd0 !important; }



















/* =========================== FEATURED IMAGE FIX - DESKTOP =========================== */
@media (min-width: 992px){
  .featured-image{
    height: 480px !important; /* MAS MALAKI SA DESKTOP */
    border-radius: 18px 18px 0 0;
  }
  .featured-news{
    border-radius: 18px;
  }
  .featured-overlay h2{
    font-size: 34px !important; /* MAS MALAKI TITLE */
    line-height: 1.3 !important;
  }
}

/* =========================== RELATED NEWS SA CATEGORY PAGE =========================== */
.related-category-widget{
  background: #fff;
  border-radius: 18px;
  padding: 28px;
  box-shadow: 0 8px 20px rgba(0,0,0,.08);
  margin: 40px 0;
}
.related-category-widget h3{
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
}
.related-category-widget h3 i{
  color: #d60000;
  margin-right: 8px;
}

.related-category-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 COLUMNS */
  gap: 20px;
}

.related-category-card{
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0,0,0,.08);
  transition: .3s;
  cursor: pointer;
}
.related-category-card:hover{
  transform: translateY(-5px);
}

.related-category-card img{
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.related-category-content{
  padding: 15px;
}
.related-category-content .badge{
  margin-bottom: 8px;
}
.related-category-content h4{
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* MOBILE */
@media(max-width: 991px){
  .related-category-grid{ grid-template-columns: repeat(2, 1fr); }
}
@media(max-width: 600px){
  .related-category-grid{ grid-template-columns: 1fr; }
  .related-category-card img{ height: 200px; }
}

/* DARK MODE */
body.dark-mode .related-category-widget{ background: #1e2a3a; }
body.dark-mode .related-category-card{ background: #223047; }
body.dark-mode .related-category-content h4{ color: #e9eef7; }











/* ========== LIITAN SA MOBILE ========== */
@media (max-width: 991px) {
  .featured-overlay {
    padding: 15px; /* LIITAN PADDING */
  }

  .featured-overlay .badge {
    font-size: 10px; /* LIITAN BADGE */
    padding: 4px 10px;
    margin-bottom: 10px;
  }

  .featured-overlay .news-meta {
    gap: 10px; /* LIITAN GAP */
    font-size: 11px; /* LIITAN FONT */
    margin: 8px 0 12px 0;
  }
  
  .featured-overlay .news-meta i {
    font-size: 11px;
  }

  .featured-overlay h2 {
    font-size: 16px; /* LIITAN TITLE */
    line-height: 1.3;
    margin: 0 0 12px 0;
  }

  .read-btn {
    padding: 10px 16px; /* LIITAN BUTTON */
    font-size: 13px;
  }
}

/* ========== DESKTOP MANANATILING MALAKI ========== */
@media (min-width: 992px) {
  .featured-overlay .badge {
    font-size: 12px;
    padding: 6px 12px;
  }
  .featured-overlay .news-meta {
    font-size: 13px;
  }
  .featured-overlay h2 {
    font-size: 28px;
  }
}










/* ========== VERTICAL AUTO SLIDE - FINAL FIX ========== */
#contentList {
  height: 560px !important; /* 4 cards x 140px */
  overflow-y: hidden !important;
  display: block !important;
}

#contentList .news-card {
  height: 125px !important; /* tinaasan ng konti */
  display: flex !important;
  gap: 12px;
  background: #1e2a3a;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #2a3a52;
  margin-bottom: 15px !important; /* 125 + 15 = 140px total */
}

#contentList .news-card img {
  width: 160px !important;
  height: 100% !important;
  object-fit: cover;
}

#contentList .news-info {
  padding: 12px 12px 12px 0;
  flex: 1;
  display: flex;
  flex-direction: column;
}

#contentList .news-info .badge {
  display: inline-block;
  background: #dc2626;
  color: white;
  padding: 4px 10px;
  border-radius: 15px;
  font-size: 10px;
  font-weight: 700;
  margin-bottom: 6px;
  width: fit-content;
}

#contentList .news-info h3 { 
    font-size: 14px; 
    color: #ffffff !important; 
    font-weight: 700;
    margin: 8px 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2; 
    -webkit-box-orient: vertical;
    overflow: hidden;
}

#contentList .news-info p {
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 1; 
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
}

#contentList .news-meta {
  font-size: 11px;
  color: #94a3b8;
  margin-top: auto; /* itulak pababa yung views */
}

#contentList .news-meta {
  font-size: 11px;
  color: #94a3b8;
}












/* ========== VERTICAL AUTO SLIDE CONTAINER ========== */
#contentList {
  height: 860px !important; /* 215 x 4 */
  overflow-y: auto !important; /* hidden -> auto para ma scroll */
  display: block !important;
  scroll-behavior: smooth; /* smooth pag nag click */
}

/* ITAGO NATIN YUNG SCROLLBAR PARA MALINIS */
#contentList::-webkit-scrollbar {
  width: 0px;
  background: transparent;
}
#contentList {
  -ms-overflow-style: none;  /* IE */
  scrollbar-width: none;  /* Firefox */
}

#contentList .news-card {
  height:200px !important; /* 145 -> 160. +15px para sa views */
  display: flex !important;
  gap: 12px;
  background: #1e2a3a !important;
  border-radius: 0px;
  overflow: hidden;
  border: 1px solid #2a3a52;
  margin-bottom: 15px !important; /* 160 + 15 = 175 */
  cursor: pointer;
}

#contentList .news-card img {
  width: 160px !important;
  height: 160px !important; /* TUGMA SA CARD HEIGHT */
  object-fit: cover;
  flex-shrink: 0;
}



#contentList .news-info h3 {
  font-size: 14px !important; 
  color: #ffffff !important; 
  margin: 0 !important;
  line-height: 1.5 !important;
  font-weight: 700 !important; 
  font-family: 'Poppins', sans-serif !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 4 !important; /* 3 LINES PA RIN */
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  min-height: 90px;
}

#contentList .news-meta {
  font-size: 4px !important;
  color: #94a3b8 !important;
  margin-top: 14px !important; /*  auto -> 4px para laging kita */
  font-weight: 500 !important;
  display: flex;
  align-items: center;
  gap: 4px;
}

#contentList .news-info .badge {
  background: #dc2626 !important;
  color: white !important;
  padding: 2px 8px !important;
  border-radius: 20px !important;
  font-size: 6px !important;
  font-weight: 600 !important;
  letter-spacing: 0.3px !important;
  width: fit-content !important;
  text-transform: uppercase !important;
  flex-shrink: 0;
}





/* ========== LIGHT MODE ========== */
body.light-mode #contentList .news-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05) !important;
}

body.light-mode #contentList .news-info h3 {
  color: #0f172a !important; /* DILIM PARA SA LIGHT */
}

body.light-mode #contentList .news-info p,
body.light-mode #contentList .news-meta {
  color: #64748b !important;
}










/* ========== LIITAN ANG DATE AT VIEWS - FINAL ========== */
#contentList .news-meta {
  font-size: 9px !important; /* 10 -> 9px. Mas maliit pa */
  gap: 10px !important;
  margin-top: 4px !important;
  font-weight: 400 !important;
  line-height: 1 !important;
}

#contentList .news-meta span {
  display: inline-flex !important; /* inline-flex para di mag break */
  align-items: center !important;
  gap: 3px !important;
  font-size: 9px !important; /* ITO KULANG KANINA */
  font-weight: 400 !important;
  color: #94a3b8 !important; /* DARK MODE */
}

#contentList .news-meta i {
  font-size: 8px !important; /* 9 -> 8px */
  color: #FF0000 !important;
}

/* LIGHT MODE */
body.light-mode #contentList .news-meta span {
  color: #64748b !important;
  font-size: 9px !important;
}
body.light-mode #contentList .news-meta i {
  color: #94a3b8 !important;
}

















/* ================= MOST READ ================= */
.most-read-title{
    font-size: 16px;
    font-weight: 800;
    color: #000; /* BLACK SA LIGHT MODE */
    padding: 12px 14px;
    border-left: 3px solid #ff0000;
    background: #fff; /* WHITE SA LIGHT MODE */
    margin-bottom: 0;
}

.most-read-item{
    display: flex;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid #e5e7eb; /* LIGHT BORDER */
    background: #fff; /* WHITE BG */
    text-decoration: none;
    transition: background .3s;
}

.most-read-item:hover{
    background: #f9fafb;
}

.most-read-content h4{
    font-size: 14px;
    font-weight: 700;
    color: #000; /* BLACK TEXT SA LIGHT MODE */
    margin: 4px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.most-read-content .badge{
    font-size: 8px;
    font-weight: 600;
    background: #ef4444;
    color: #fff;
    padding: 2px 6px;
    border-radius: 2px;
    text-transform: uppercase;
}


.most-read-content small{
    font-size: 12px;
    color: #6b7280; /* GRAY */
}

/* ============ DARK MODE ============ */
body:not(.light-mode) .most-read-title{
    background: #111827; /* DARK BG TULAD NG IBA */
    color: #fff; /* WHITE TEXT */
    border-bottom: 1px solid #1f2937;
}

body:not(.light-mode) .most-read-item{
    background: #111827; /* DARK BG */
    border-bottom: 1px solid #1f2937; /* DARK BORDER */
}

body:not(.light-mode) .most-read-item:hover{
    background: #1f2937;
}

body:not(.light-mode) .most-read-content h4{
    color: #fff; /* WHITE TEXT SA DARK MODE */
}

body:not(.light-mode) .most-read-content small{
    color: #9ca3af; /* LIGHT GRAY SA DARK */
}






/* ================= FILTER BUTTON ================= */
.section-header{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    border-left: 3px solid #ff0000;
}

.filter-btn{
    background: #1f2937;
    border: 1px solid #374151;
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-btn:hover{
    background: #374151;
}

/* ================= FILTER POPUP ================= */
.filter-overlay{
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 99;
    display: none;
}

.filter-popup{
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #111827;
    border: 1px solid #374151;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    z-index: 100;
    display: none;
}

.filter-popup.show,
.filter-overlay.show{
    display: block;
}

.filter-popup-header{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid #374151;
}

.filter-popup-header h4{
    margin: 0;
    font-size: 18px;
    color: #fff;
}

.filter-popup-header button{
    background: transparent;
    border: none;
    color: #9ca3af;
    font-size: 20px;
    cursor: pointer;
}

.filter-popup-body{
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-popup-body label{
    font-size: 14px;
    color: #9ca3af;
    font-weight: 600;
}

.filter-popup-body input[type="date"]{
    background: #1f2937;
    border: 1px solid #374151;
    border-radius: 8px;
    padding: 10px;
    color: #fff;
    font-size: 15px;
}

.filter-popup-body input[type="date"]::-webkit-calendar-picker-indicator{
    filter: invert(1);
    cursor: pointer;
}

.filter-popup-footer{
    padding: 16px;
    border-top: 1px solid #374151;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.filter-popup-footer button{
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    font-weight: 700;
    cursor: pointer;
}

#clearDate{
    background: #374151;
    color: #fff;
}

#applyFilter{
    background: #ff0000;
    color: #fff;
}

#applyFilter:hover{
    background: #dc2626;
}

/* LIGHT MODE */
body.light-mode.filter-btn{
    background: #f3f4f6;
    color: #000;
    border: 1px solid #d1d5db;
}

body.light-mode.filter-popup{
    background: #fff;
}

body.light-mode.filter-popup-body input[type="date"]{
    background: #f9fafb;
    color: #000;
}








/* ========== SECTION HEADER ALIGNED SA CONTENT ========== */
@media screen and (min-width: 1024px){
    .search-section .section-header{
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        max-width: 1400px !important; /* SAME WIDTH SA .container */
        margin: 0 auto 20px auto !important; /* CENTER */
        padding: 0 15px !important; /* SAME PADDING SA .container */
    }

    .search-section .section-header h3{
        font-size: 20px !important;
        margin: 0 !important;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .search-section .section-header .filter-btn{
        font-size: 12px !important;
        padding: 7px 16px !important;
        background: #374151 !important;
        color: #9ca3af !important;
        border: none !important;
        border-radius: 6px !important;
        cursor: pointer;
        transition: 0.3s;
    }
    
    .search-section .section-header .filter-btn:hover{
        background: #ff0000 !important;
        color: #fff !important;
    }
}

/* ========== MOBILE ========== */
@media screen and (max-width: 1023px){
    .search-section .section-header{
        justify-content: space-between !important;
        padding: 0 15px !important;
    }
}


/* =========================================================
   CATEGORY PAGES — DESKTOP LAYOUT ONLY
   MOBILE RULES ABOVE ARE LEFT UNCHANGED
   ========================================================= */
@media (min-width: 992px){

    /* PAGE WIDTH */
    body[data-page] .category-page{
        width:100%;
        padding:30px 0 45px;
        background:#f5f6fa;
    }

    body[data-page] .category-page > .container{
        width:95%;
        max-width:1400px;
        margin:0 auto;
    }

    /* MAIN CONTENT + SIDEBAR */
    body[data-page] .page-layout{
        width:100%;
        display:grid !important;
        grid-template-columns:minmax(0, 2fr) minmax(280px, 1fr) !important;
        gap:28px !important;
        align-items:start !important;
        background:transparent !important;
    }

    body[data-page] .page-main,
    body[data-page] .page-sidebar{
        min-width:0;
        width:100%;
    }

    body[data-page] .page-main{
        grid-column:1 !important;
    }

    body[data-page] .page-sidebar{
        grid-column:2 !important;
    }

    /* CATEGORY HEADER / NAV */
    body[data-page] #navbar .nav{
        width:95%;
        max-width:1400px;
        margin:0 auto;
        min-height:42px;
    }

    body[data-page] #navbar .nav-links{
        display:flex !important;
        align-items:stretch;
        flex-wrap:nowrap;
        width:100%;
    }

    body[data-page] #navbar .nav-links li{
        flex:0 0 auto;
    }

    body[data-page] #navbar .nav-links li a{
        padding:11px 13px;
        font-size:11px;
        line-height:1.2;
        white-space:nowrap;
    }

    /* SEARCH AREA */
    body[data-page] .search-section{
        padding:18px 0 12px;
    }

    body[data-page] .search-mobile-wrapper{
        width:95%;
        max-width:1400px;
        margin:0 auto;
    }

    body[data-page] .search-box{
        max-width:620px;
    }

    /* SECTION HEADER MUST NOT FLOAT OUTSIDE THE PAGE WIDTH */
    body[data-page] .search-section .section-header{
        width:95%;
        max-width:1400px;
        margin:0 auto 15px;
    }

    /* FEATURED CONTENT — CONTAIN ANY SHARED HERO STYLES */
    body[data-page] .page-main #featuredContent{
        width:100%;
        min-width:0;
    }

    body[data-page] .page-main #featuredContent .hero{
        width:100%;
        margin:0 0 25px;
    }

    body[data-page] .page-main #featuredContent .hero-grid{
        width:100%;
        display:grid;
        grid-template-columns:minmax(0, 2.3fr) minmax(220px, .9fr);
        gap:18px;
    }

    /* KEEP HERO INSIDE ITS COLUMN */
    body[data-page] .page-main #featuredContent .hero-left,
    body[data-page] .page-main #featuredContent .hero-right{
        min-width:0;
        max-width:100%;
    }

    /* RELATED NEWS */
    body[data-page] .section-title{
        margin:0 0 18px;
        font-size:24px;
        line-height:1.3;
    }

    /* CONTENT LIST — DESKTOP TWO-COLUMN CARDS
       This overrides only the desktop vertical-card rules. */
    body[data-page] #contentList{
        width:100%;
        min-width:0;
        height:auto !important;
        max-height:none !important;
        overflow:visible !important;
        display:grid !important;
        grid-template-columns:repeat(2, minmax(0, 1fr)) !important;
        gap:20px !important;
        scroll-behavior:auto;
    }

    body[data-page] #contentList .news-card{
        width:100%;
        min-width:0;
        height:auto !important;
        min-height:0;
        display:flex !important;
        flex-direction:column !important;
        gap:0;
        margin:0 !important;
        padding:0 !important;
        overflow:hidden;
        border-radius:14px;
    }

    body[data-page] #contentList .news-card img{
        width:100% !important;
        height:210px !important;
        min-height:210px;
        object-fit:cover;
        flex-shrink:0;
        border-radius:0 !important;
    }

    body[data-page] #contentList .news-info{
        width:100%;
        min-width:0;
        padding:16px !important;
        display:flex;
        flex-direction:column;
    }

    body[data-page] #contentList .news-info h3{
        font-size:16px !important;
        line-height:1.4 !important;
        min-height:auto;
        margin:0 0 9px !important;
        -webkit-line-clamp:2 !important;
    }

    body[data-page] #contentList .news-info p{
        font-size:12px !important;
        line-height:1.55 !important;
        margin:0 0 10px !important;
        -webkit-line-clamp:2 !important;
    }

    body[data-page] #contentList .news-meta{
        margin-top:auto !important;
        font-size:9px !important;
    }

    /* SIDEBAR */
    body[data-page] .page-sidebar{
        position:relative;
    }

    body[data-page] .page-sidebar .widget{
        width:100%;
        min-width:0;
        margin:0 0 20px;
        padding:18px;
    }

    body[data-page] #sidebarContent{
        width:100%;
        min-width:0;
    }

    body[data-page] #sidebarContent .most-read-item{
        width:100%;
        min-width:0;
    }

    body[data-page] #sidebarContent .most-read-item img{
        width:105px !important;
        height:72px !important;
    }

    body[data-page] #sidebarContent .most-read-content{
        min-width:0;
    }

    body[data-page] #sidebarContent .most-read-content h4{
        font-size:13px !important;
        line-height:1.4 !important;
    }

    /* PREVENT ANY SHARED HOMEPAGE GRID FROM ESCAPING */
    body[data-page] .page-main .news-grid{
        width:100%;
        min-width:0;
    }
}
