/* Mobile-first responsive adjustments */
@media (max-width: 767px) {
  .top-bar {
    padding: 6px 0;
    font-size: 12px;
  }

  .top-bar .container {
    flex-direction: column;
    gap: 8px;
    padding: 5px 15px;
  }

  .top-bar .social-icons {
    order: -1;
    /* Move social icons above date on mobile */
    margin-bottom: 5px;
  }

  .top-bar .social-icons a {
    width: 22px;
    height: 22px;
    font-size: 14px;
  }

  .top-nav {
    padding: 10px 0;
  }

  .single .post-actions {
    justify-content: space-between;
  }
}

/* Tablet and small desktop */
@media (min-width: 768px) and (max-width: 991px) {
  .top-bar {
    padding: 8px 0;
    font-size: 13px;
  }
}

/* Large devices */
@media (min-width: 992px) {
  .top-bar .container {
    max-width: 1200px;
    margin: 0 auto;
  }
}

/* Hide mobile menu elements on desktop */
@media (min-width: 769px) {
  .menu-toggle {
    display: none !important;
  }

  .mobile-cancel {
    display: none !important;
  }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .news-sections-grid {
    grid-template-columns: 1fr;
  }

  .most-read-section {
    padding-left: 0;
  }
}

@media (max-width: 767px) {
  .news-sections-grid {
    display: flex;
    flex-direction: column;
  }

  .latest-news-grid {
    grid-template-columns: 1fr;
  }

  /* .news-list-item {
    flex-direction: column;
  } */
  .news-list-item,
  .news-list-item1 {
    flex-direction: column-reverse;
  }

  .news-list-image,
  .news-list-image1 {
    width: 100%;
    height: auto;
  }
  .latest-news-grid .divider {
    display: none;
  }
}

@media (max-width: 480px) {
  .section-title {
    font-size: 18px;
  }

  .latest-news-item .news-image {
    width: 100%;
    height: auto;
  }

  .category {
    font-size: 12px;
    padding: 3px 8px;
  }

  .dark-mode-toggle-btn {
    flex-shrink: 0;
  }
  .header-mobile-elements .menu-toggle {
    margin-inline-end: auto;
    flex-shrink: 0;
  }
}



@media (max-width: 992px) {
  .news-sections-grid {
    grid-template-columns: 1fr;
  }

  .featured-news-card .news-img-container img {
    height: 250px;
  }
}

@media (max-width: 768px) {
  .news-img-container img {
    height: 200px;
  }

  .news-title {
    font-size: 14px;
  }
}

@media (max-width: 576px) {
  .news-img-container img {
    height: 180px;
  }

  .news-title {
    font-size: 13px;
  }

  .navbar-nav .nav-link {
    font-size: 14px;
  }
}

/* Swiper Adjustments */
.swiper {
  width: 100%;
  padding-bottom: 40px;
}

.swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background-color: #ccc;
}

.swiper-pagination-bullet-active {
  background-color: #b30000;
}

/* Responsive Advertisement */

.ad-banner {
  padding: 30px 0;
  background-color: #ffffff;
}

@media (max-width: 768px) {
  .ad-banner {
    font-size: 16px;
  }
}



/* Responsive Styles */
@media (max-width: 768px) {
  .social-icons {
    text-align: center;
  }
  
  .store-button {
    display: block;
    margin: 10px auto;
  }

  .footer-links {
    text-align: center;
  }
}



/* Responsive Styles */
@media (max-width: 768px) {
  .site-footer__social {
    justify-content: center;
  }
  .footer-heading {
    font-size: 1rem;
    /* Slightly reduce font size for better readability */
    margin-bottom: 0.5rem;
    /* Reduce margin to save space */
  }
  .site-footer .footer-menu {
    align-items: center;
  }
}





/* Responsive Styles */
@media (max-width: 1024px) {
  .news-card {
    flex: 1 1 calc(50% - 15px);
    max-width: calc(50% - 15px);
  }
}

@media (max-width: 768px) {
  .news-row {
    flex-direction: column;
  }

  .news-card {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .header-row {
    flex-direction: column;
    align-items: center;
  }

  .culture-header,
  .tech-header {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .category-header {
    font-size: 18px;
  }

  .news-card h3 {
    font-size: 17px;
  }

  .news-card p {
    font-size: 12px;
  }
}


/* ********************************************** */
@media (max-width: 991px) {
  .navbar-collapse {
    background-color: white;
    padding: 15px;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
  }

  .navbar-nav {
    flex-direction: column;
    align-items: center;
  }

  .navbar-nav .nav-item {
    width: 100%;
    text-align: center;
  }

  .navbar-toggler {
    border: none;
    background: transparent;
    font-size: 1.5rem;
  }
}


@media (max-width: 768px) {

  .nav-icon {
    margin: 5px 8px;
  }

}



/*******************************/


@media (max-width: 767px) {
  .news-cards {
    flex-direction: column-reverse;
  }

  .news-image-container {
    width: 100%;
    height: auto;
  }

  .news-image {
    height: auto;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .news-title {
    font-size: 14px;
  }

  .timestamp {
    font-size: 12px;
  }

  .news-content {
    padding: 8px;
  }
}

@media (max-width: 768px) {
  .featured-card img {
    height: auto;
    aspect-ratio: 19 / 10;
    width: 100%;
    border-radius: 15px;
  }
}

/* Optional responsiveness tweaks */
@media (max-width: 768px) {
  .news-list-image {
    border-radius: 6px;
  }

  .news-list-image img {
    border-radius: 6px;
    aspect-ratio: 19 / 9;
    width: 100%;

  }
}

@media (max-width: 480px) {
  .news-list-image {
    border-radius: 4px;
  }

  .news-list-image img {
    border-radius: 6px;
    aspect-ratio: 19 / 9;
    width: 100%;
  }
}



/* Tablet and below */
@media (max-width: 768px) {
  .news-list-image1 {
    width: 100%;
    height: auto;
  }

  .news-list-image1 img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

/* Mobile */
@media (max-width: 480px) {
  .news-list-image1 {
    border-radius: 6px;
  }

  .news-list-image1 img {
    border-radius: 6px;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 20px;
}

.small-play-button {
  width: 20px;
  height: 20px;
  bottom: 15px;
  left: 15px;
}

.small-play-button i {
  font-size: 9px;
}


@media (max-width: 480px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 16px;
}

.small-play-button {
  width: 18px;
  height: 18px;
  bottom: 12px;
  left: 12px;
}

.small-play-button i {
  font-size: 8px;
}

/* -------- Responsive Tweaks -------- */

@media (max-width: 768px) {
  .main-content {
    height: 300px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 12px;
  }

  .content-overlay h2 {
    font-size: 16px;
  }

  .content-overlay p {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .main-content {
    height: 240px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 10px;
  }
}




/*******************************/


@media (max-width: 767px) {
  .section-title {
    margin-top: 20px;
  }

  .news-image-container {
    width: 100%;
    height: auto;
  }

  .news-image {
    height: auto;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .news-title {
    font-size: 14px;
  }

  .timestamp {
    font-size: 12px;
  }

  .news-content {
    padding: 8px;
  }
}

@media (max-width: 768px) {
  .featured-card img {
    height: auto;
    aspect-ratio: 19 / 10;
    width: 100%;
    border-radius: 15px;
  }
}

/* Optional responsiveness tweaks */
@media (max-width: 768px) {
  .news-list-image {
    border-radius: 6px;
  }

  .news-list-image img {
    border-radius: 6px;
    aspect-ratio: 19 / 9;
    width: 100%;

  }
}

@media (max-width: 480px) {
  .news-list-image {
    border-radius: 4px;
  }

  .news-list-image img {
    border-radius: 6px;
    aspect-ratio: 19 / 9;
    width: 100%;
  }
}



/* Tablet and below */
@media (max-width: 768px) {
  .news-list-image1 {
    width: 100%;
    height: auto;
  }

  .news-list-image1 img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

/* Mobile */
@media (max-width: 480px) {
  .news-list-image1 {
    border-radius: 6px;
  }

  .news-list-image1 img {
    border-radius: 6px;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 20px;
}

.small-play-button {
  width: 20px;
  height: 20px;
  bottom: 15px;
  left: 15px;
}

.small-play-button i {
  font-size: 9px;
}


@media (max-width: 480px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 16px;
}

.small-play-button {
  width: 18px;
  height: 18px;
  bottom: 12px;
  left: 12px;
}

.small-play-button i {
  font-size: 8px;
}

/* -------- Responsive Tweaks -------- */

@media (max-width: 768px) {
  .main-content {
    height: 300px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 12px;
  }

  .content-overlay h2 {
    font-size: 16px;
  }

  .content-overlay p {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .main-content {
    height: 240px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 10px;
  }

  .content-overlay h2 {
    font-size: 14px;
  }

  .content-overlay p {
    font-size: 11px;
  }
}


/* Hide mobile controls on desktop */
@media (min-width: 769px) {

  .menu-toggle,
  .mobile-cancel {
    display: none !important;
  }
}

@media (max-width: 768px) {


  .secondary-nav-list {
    display: none !important;
  }

  .menu-toggle {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 44px !important;
    height: 44px !important;
    padding: 0 !important;
    cursor: pointer;
  }

  .menu-toggle span {
    height: 2.5px !important;
    width: 22px !important;
    margin: 0 !important;
    background: #ff6600;
    border-radius: 4px;
    flex-shrink: 0;
  }

  .mobile-cancel {
    display: none;
    /* hidden by default */
    font-size: 26px;
    color: #ff6600;
    width: 100%;
    padding: 12px 20px;
    text-align: left;
    cursor: pointer;
    background: #fff;
    border-bottom: 1px solid #eee;
    position: relative;
    z-index: 99999;
  }

  .secondary-nav.show .secondary-nav-list {
    display: flex !important;
    flex-direction: column;
    width: 100%;
    padding-top: 10px;
  }

  .secondary-nav.show .secondary-nav-list li {
    width: 100%;
    padding: 14px 0;
    border-bottom: 1px solid #eee;
    font-size: 16px;
  }

  .secondary-nav.show .menu-toggle {
    display: none !important;
  }

}

.news-list-image1 img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

/* Mobile */
@media (max-width: 480px) {
  .news-list-image1 {
    border-radius: 6px;
  }

  .news-list-image1 img {
    border-radius: 6px;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 20px;
}

.small-play-button {
  width: 20px;
  height: 20px;
  bottom: 15px;
  left: 15px;
}

.small-play-button i {
  font-size: 9px;
}


@media (max-width: 480px) {
  .play-button {
    width: 50px;
    height: 50px;
    transform: translate(-50%, -200%);
  }
}

.play-button i {
  font-size: 16px;
}

.small-play-button {
  width: 18px;
  height: 18px;
  bottom: 12px;
  left: 12px;
}

.small-play-button i {
  font-size: 8px;
}

/* -------- Responsive Tweaks -------- */

@media (max-width: 768px) {
  .main-content {
    height: 300px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 12px;
  }

  .content-overlay h2 {
    font-size: 16px;
  }

  .content-overlay p {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .main-content {
    height: 240px;
  }

  .main-content img {
    height: 50%;
    width: 100%;
    object-fit: cover;
  }

  .content-overlay {
    padding: 10px;
  }

  .content-overlay h2 {
    font-size: 14px;
  }

  .content-overlay p {
    font-size: 11px;
  }
}


@media (min-width: 769px) {

  .menu-toggle,
  .mobile-cancel {
    display: none !important;
  }
}

@media (max-width: 768px) {

  .secondary-nav-list {
    display: none !important;
  }

  .menu-toggle {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 44px !important;
    height: 44px !important;
    padding: 0 !important;
    cursor: pointer;
    margin: 0;
  }

  .menu-toggle span {
    height: 2.5px !important;
    width: 22px !important;
    margin: 0 !important;
    background: #ff6600;
    border-radius: 4px;
    flex-shrink: 0;
  }

  .mobile-cancel {
    display: none !important;
    /* Hide cancel by default */
    font-size: 24px;
    color: #ff6600;
    cursor: pointer;
    padding: 10px 0;
  }

  /* 2. Open State (.show class added by JS) */
  .secondary-nav.show .secondary-nav-list {
    display: flex !important;
    /* Show list */
    flex-direction: column;
    width: 100%;
    padding-top: 10px;
  }

  .secondary-nav.show .secondary-nav-list li {
    margin: 10px 0;
    width: 100%;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
  }

  .secondary-nav.show .menu-toggle {
    display: none !important;
    /* Hide hamburger when open */
  }

  .secondary-nav.show .mobile-cancel {
    display: block !important;
  }

  .secondary-nav.show .col-md-3 {
    display: none !important;
  }
}

@media (max-width: 992px) {

  #mainNavbar {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 100vw;
    height: 100vh;
    background: #ffffff;
    z-index: 9999;
    padding: 90px 20px 40px;
    overflow-y: auto;
    direction: rtl;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.2);
  }

  .main-nav .container {
    width: 100vw !important;
    max-width: 100vw !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  #mainNavbar.open {
    display: block !important;
  }

  .navbar-nav {
    flex-direction: column;
    gap: 0;
  }

  .navbar-nav .nav-item {
    width: 100%;
    border-bottom: 1px solid #f0f0f0;
  }

  .navbar-nav .nav-link {
    padding: 18px 20px !important;
    font-size: 19px;
    font-weight: 600;
    color: #222;
    display: block;
  }

  .navbar-nav .nav-link:hover,
  .navbar-nav .nav-link.active {
    background: #fdf2f5;
    color: #ff6600;
  }

  body.menu-open .mobile-cancel {
    opacity: 1 !important;
    visibility: visible !important;
  }

  .mobile-cancel {
    position: fixed;
    top: 18px;
    right: 18px;
    width: 56px;
    height: 56px;
    background: #ff6600;
    color: white;
    border-radius: 50%;
    display: flex !important;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
    z-index: 99999;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(100, 12, 34, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }

  .menu-toggle {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 44px !important;
    height: 44px !important;
    padding: 0 !important;
    cursor: pointer;
  }

  .menu-toggle span {
    height: 2.5px !important;
    width: 22px !important;
    margin: 0 !important;
    background: #ff6600;
    border-radius: 4px;
    transition: all 0.3s;
    flex-shrink: 0;
  }

  /* Hamburger open-state handled in styles.css (.site-header__menu-toggle) */
}

@media (max-width: 992px) {
  .secondary-nav-list {
    display: none !important;
  }

  body.secondary-menu-open .secondary-nav-list {
    display: flex !important;
    flex-direction: column;
    width: 100%;
    background: #fff9fb;
    padding: 18px 20px;
    border-bottom: 3px solid #ff6600;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 9998;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
  }

  body.secondary-menu-open .secondary-nav-list li {
    padding: 14px 0;
    text-align: center;
    font-size: 17px;
    font-weight: 500;
    border-bottom: 1px solid #eee;
  }

  body.secondary-menu-open .secondary-nav-list .nav-divider {
    display: none !important;
  }

  .secondary-toggle::after {
    content: "Down Arrow";
    font-size: 12px;
    margin-right: 6px;
    transition: transform 0.3s;
  }

  body.secondary-menu-open .secondary-toggle::after {
    content: "Up Arrow";
  }
}

.news-list-image1 img {
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
}

@media (max-width: 480px) {
  .news-list-image1 {
    border-radius: 6px;
  }

  .news-list-image1 img {
    border-radius: 6px;
  }
}

.dark-mode-toggle-btn {
  width: 40px;
  height: 40px;
  background: #ffffff;
  border-radius: 59%;
  border: 1px solid #050505;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: all 0.4s ease;
  margin: 0 8px;
}

.dark-mode-toggle-btn i {
  font-size: 21px;
  position: absolute;
  transition: all 0.4s ease;
  color: #000;
}

.dark-mode-toggle-btn .moon {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}

.dark-mode-toggle-btn .sun {
  opacity: 0;
  transform: rotate(90deg) scale(0);
  color: #ffd700;
}

body.dark .dark-mode-toggle-btn {
  background: #1e1e1e;
}

body.dark .dark-mode-toggle-btn .moon {
  opacity: 0;
  transform: rotate(-90deg) scale(0);
  color: #fff;
}

body.dark .dark-mode-toggle-btn .sun {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}
@media (max-width: 767px) {
  .top-bar {
    display: none;
  }
  .header-mobile-elements {
    width: 100%;
    flex-direction: row-reverse;
    padding: 10px;
  }
  .header-mobile-elements .logo-container {
    margin-left: auto;
    margin-right: auto;
  }
  .header-mobile-elements .dark-mode-toggle-btn, 
  .header-mobile-elements .nav-icon {
    margin: 0 5px;
  }
  .header-mobile-elements .nav-icon {
    margin-inline-end: 0;
  }
  .header-mobile-elements .dark-mode-toggle-btn {
    margin-inline-start: 0;
    margin-inline-end: 0;
  }
  /* .header-mobile-elements .menu-toggle {
    margin-inline-end: 40px;
  } */
}

@media (min-width: 768px) {
  .menu-toggle {
    display: none;
  }
}

/* Search Form Mobile Styles */
@media (max-width: 768px) {
  .search-form {
    margin: 15px 0;
  }

  .search-input-group {
    border-radius: 4px;
  }

  .search-field {
    padding: 10px 12px;
    font-size: 14px;
  }

  .search-submit {
    padding: 10px 15px;
  }

  .search-submit svg {
    width: 16px;
    height: 16px;
  }
}

@media (max-width: 480px) {
  .search-field {
    padding: 10px;
    font-size: 14px;
  }

  .search-submit {
    padding: 10px 12px;
  }
  .footer-menu {
    flex-direction: column;
    gap: 10px;
  }
}

.dark-mode-toggle-btn,
.header-mobile-elements .nav-icon {
  border-color: var(--primary-color);
}
.dark-mode-toggle-btn i,
.header-mobile-elements .nav-icon i {
  color: var(--primary-color);
}

/* ========================================
   Legacy mobile header overrides
   (new .site-header / .offcanvas-nav take over)
   ======================================== */
.mobile-cancel:not(.offcanvas-nav__close) {
  display: none !important;
}

@media (max-width: 991.98px) {
  #mainNavbar {
    display: none !important;
  }

  .header-mobile-elements {
    width: auto;
    flex-direction: unset;
    padding: 0;
  }
}

@media (min-width: 992px) {
  .site-header__menu-toggle,
  .menu-toggle {
    display: none !important;
  }
}

/* ========================================
   Mobile homepage feed (stacked latest cards)
   ======================================== */
.home-mobile {
  display: none;
  padding-block: 1rem 2rem;
}

.home-mobile__list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.home-mobile__item .news-card {
  margin-bottom: 0;
  background: var(--surface);
  transition: background-color var(--transition-base), box-shadow var(--transition-base);
}

.home-mobile__item .news-card:hover {
  background-color: var(--surface-muted);
}

.home-mobile__item .featured-card img {
  aspect-ratio: 16 / 9;
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: var(--card-border-radius);
}

.home-mobile__item .news-card h3,
.home-mobile__item .news-card .excerpt,
.home-mobile__item .news-card .timestamp {
  padding-inline: 0.75rem;
}

.home-mobile__item .news-card h3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 0.75rem;
}

.home-mobile__item .news-card .excerpt {
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

body.dark-theme .home-mobile__item .news-card {
  background: #11162f;
}

body.dark-theme .home-mobile__item .news-card:hover {
  background-color: #1a2040;
}

@media (max-width: 991.98px) {
  .home-desktop {
    display: none;
  }

  .home-mobile {
    display: block;
  }
}

body.mobile-home .home-mobile {
  display: block;
}

@media (min-width: 992px) {
  body:not(.mobile-home) .home-mobile {
    display: none;
  }
}

