:root {
  --bg-dark: #0a0b1e;
  --bg-card: #15172b;
  --bg-card-hover: #1e213a;
  --primary: #00f2ff; /* Neon Cyan */
  --secondary: #9d00ff; /* Neon Purple */
  --text-main: #ffffff;
  --text-muted: #a0a3bd;
  --accent-red: #ff3b3b;
  --accent-green: #00ff9d;
  --font-heading: "Outfit", sans-serif;
  --font-body: "Inter", sans-serif;
  --glass-border: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- SCROLLBAR HIDING & STYLING --- */
/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--bg-card-hover) var(--bg-dark);
}

/* Chrome, Edge, Safari */
*::-webkit-scrollbar {
  width: 6px;
  height: 6px; /* For horizontal scrollbars */
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 20px;
}

/* Hide scrollbar for specific horizontal containers but keep functionality */
.category-strip::-webkit-scrollbar {
  display: none;
}
.category-strip {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

/* ---------------------------------- */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: 0.3s;
}

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
header {
  background: rgba(10, 11, 30, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: var(--glass-border);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 15px 0;
}

.nav-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  background: linear-gradient(45deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -1px;
}

.main-nav ul {
  display: flex;
  gap: 30px;
}

.main-nav a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--primary);
  text-shadow: 0 0 10px rgba(0, 242, 255, 0.5);
}

.mobile-menu-btn {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: white;
    z-index: 2001; /* Above menu overlay */
}

/* Carousel Section (Home Only) */
.carousel-container {
  position: relative;
  height: 400px;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 40px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  border: var(--glass-border);
}

.carousel-track {
    display: flex;
    height: 100%;
    transition: transform 0.5s ease-in-out;
    width: 100%;
}

.carousel-slide {
  min-width: 100%; /* Take full width of container */
  height: 100%;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  /* Removed absolute positioning and opacity transition */
}
/* Removed .carousel-slide.active since we slide the track now */

.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 20px;
  z-index: 2;
  pointer-events: none; /* Let clicks pass through container */
}

.carousel-btn {
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  pointer-events: auto; /* Re-enable clicks */
  transition: all 0.3s ease;
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.carousel-btn:hover {
  background: var(--primary);
  color: var(--bg-dark);
  border-color: var(--primary);
  transform: scale(1.1);
  box-shadow: 0 0 15px rgba(0, 242, 255, 0.5);
}

/* Hero Section (Featured) */
.hero-section {
  padding: 40px 0;
}

.hero-card {
  background: var(--bg-card);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  border: var(--glass-border);
  min-height: 400px;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
}

.hero-overlay {
  background: linear-gradient(
    to top,
    rgba(10, 11, 30, 1) 0%,
    rgba(10, 11, 30, 0.6) 50%,
    rgba(10, 11, 30, 0) 100%
  );
  width: 100%;
  padding: 40px;
}

.hero-tag {
  background: linear-gradient(90deg, var(--primary), var(--secondary)); /* Neon gradient */
  color: white;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  display: inline-block;
  margin-bottom: 15px;
  letter-spacing: 1px;
  box-shadow: 0 0 10px rgba(0, 242, 255, 0.3);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  margin-bottom: 10px;
  line-height: 1.2;
}

.hero-meta {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Layouts */
.content-grid {
  display: block;
  padding-bottom: 60px;
}

.article-page-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-top: 40px;
}

/* Category Strip Redesign: Solid Chips */
.category-strip {
  display: flex;
  gap: 12px; /* Tighter gap */
  margin-bottom: 30px;
  overflow-x: auto;
  padding: 5px; /* Space for shadow */
}

.cat-pill {
  background: var(--bg-card-hover); /* Solid Dark Grey */
  border: none; /* No Border */
  padding: 10px 24px;
  border-radius: 50px; /* Full Pill */
  font-size: 0.95rem;
  font-weight: 600;
  white-space: nowrap;
  color: var(--text-muted); /* Grey Text */
  transition: all 0.2s ease;
  cursor: pointer;
}

.cat-pill:hover {
  background: #2a2d4a; /* Lighter Grey on Hover */
  color: #fff;
  transform: translateY(-1px);
}

.cat-pill.active {
  background: var(--primary) !important; /* SOLID Cyan */
  color: #000 !important; /* Dark Text */
  font-weight: 700;
  /* Removed ugly shadow as requested */
  transform: scale(1.05);
}

/* Article Cards */
.article-list {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.article-list-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
  margin-bottom: 40px;
}

.btn-primary {
  background: transparent;
  color: var(--primary);
  padding: 12px 35px;
  border-radius: 30px;
  font-weight: 600;
  display: inline-block;
  border: 1px solid var(--primary);
  cursor: pointer;
  transition: all 0.3s ease;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 0.9rem;
}

.btn-primary:hover {
  background: var(--primary);
  color: var(--bg-dark);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 242, 255, 0.2);
}

.news-card {
  display: flex;
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  border: var(--glass-border);
  transition: transform 0.2s, box-shadow 0.2s;
  flex-direction: column;
  height: 100%;
}

.news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 242, 255, 0.1);
  border-color: rgba(0, 242, 255, 0.3);
}

.news-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  flex-shrink: 0;
}

.news-content {
  padding: 20px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.news-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 10px;
  color: var(--text-main);
  line-height: 1.3;
}

.news-excerpt {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex-grow: 1;
}

.news-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  padding-top: 15px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

/* Sidebar */
.sidebar-section {
  margin-bottom: 40px;
}

.sidebar-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--primary);
  border-bottom: 1px solid var(--primary);
  padding-bottom: 10px;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.trending-item {
  padding: 15px 0;
  border-bottom: var(--glass-border);
  position: relative;
  padding-left: 20px;
}

.trending-item::before {
  content: "►";
  color: var(--text-muted);
  font-size: 0.7rem;
  position: absolute;
  left: 0;
  top: 20px;
}

.trending-item:hover::before {
  color: var(--primary);
}

/* Ads */
.ad-slot {
  background: #000;
  border: 1px dashed #333;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #444;
  font-size: 0.8rem;
  margin: 20px 0;
  border-radius: 8px;
  overflow: hidden;
}

/* Article Page */
.article-header {
  padding: 40px 0 20px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.article-h1 {
  font-family: var(--font-heading);
  font-size: 3rem;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(180deg, #fff, #ccc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.1rem;
  color: #d1d5db;
}

.article-body h2 {
  color: var(--primary);
  margin-top: 40px;
  margin-bottom: 20px;
  font-family: var(--font-heading);
}

.article-body p {
  margin-bottom: 20px;
}

.article-body ul, 
.article-body ol {
    margin-bottom: 20px;
    padding-left: 25px; /* Fix for cut-off numbers/bullets */
}

.article-body li {
    margin-bottom: 10px;
}

.highlight-box {
  background: rgba(0, 242, 255, 0.05);
  border-left: 4px solid var(--primary);
  padding: 20px;
  margin: 30px 0;
  border-radius: 0 8px 8px 0;
}

/* Footer */
footer {
  background: #050610;
  padding: 60px 0 20px;
  margin-top: 60px;
  border-top: var(--glass-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--text-main);
  margin-bottom: 20px;
  display: block;
}

.footer-col h4 {
  color: var(--primary);
  margin-bottom: 20px;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 1px;
}

.copyright {
  text-align: center;
  color: #444;
  font-size: 0.8rem;
  padding-top: 20px;
  border-top: 1px solid #111;
}

/* Search Bar */
.search-container {
  display: flex;
  align-items: center;
  margin-bottom: 30px; /* Spacing */
}

.search-form {
  position: relative;
  width: 100%;
  max-width: 600px; /* Wider search on desktop */
  margin: 0 auto; /* Center it */
}

.search-input {
  width: 100%;
  padding: 15px 25px; /* Bigger touch target */
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.05); /* Softer bg */
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  font-family: var(--font-body);
  font-size: 1rem;
  backdrop-filter: blur(5px);
  transition: 0.3s;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(0, 242, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
}


/* ----------- RESPONSIVE MOBILE ----------- */

@media (max-width: 1024px) {
}

.news-excerpt {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 15px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex-grow: 1;
}

.news-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  padding-top: 15px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

/* Sidebar */
.sidebar-section {
  margin-bottom: 40px;
}

.sidebar-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--primary);
  border-bottom: 1px solid var(--primary);
  padding-bottom: 10px;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.trending-item {
  padding: 15px 0;
  border-bottom: var(--glass-border);
  position: relative;
  padding-left: 20px;
}

.trending-item::before {
  content: "►";
  color: var(--text-muted);
  font-size: 0.7rem;
  position: absolute;
  left: 0;
  top: 20px;
}

.trending-item:hover::before {
  color: var(--primary);
}

/* Ads */
.ad-slot {
  background: #000;
  border: 1px dashed #333;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #444;
  font-size: 0.8rem;
  margin: 20px 0;
  border-radius: 8px;
  overflow: hidden;
}

/* Article Page */
.article-header {
  padding: 40px 0 20px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.article-h1 {
  font-family: var(--font-heading);
  font-size: 3rem;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(180deg, #fff, #ccc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.1rem;
  color: #d1d5db;
}

.article-body h2 {
  color: var(--primary);
  margin-top: 40px;
  margin-bottom: 20px;
  font-family: var(--font-heading);
}

.article-body p {
  margin-bottom: 20px;
}

.highlight-box {
  background: rgba(0, 242, 255, 0.05);
  border-left: 4px solid var(--primary);
  padding: 20px;
  margin: 30px 0;
  border-radius: 0 8px 8px 0;
}

/* Footer */
footer {
  background: #050610;
  padding: 60px 0 20px;
  margin-top: 60px;
  border-top: var(--glass-border);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--text-main);
  margin-bottom: 20px;
  display: block;
}

.footer-col h4 {
  color: var(--primary);
  margin-bottom: 20px;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 1px;
}

.copyright {
  text-align: center;
  color: #444;
  font-size: 0.8rem;
  padding-top: 20px;
  border-top: 1px solid #111;
}

/* Search Bar */
.search-container {
  display: flex;
  align-items: center;
  margin-bottom: 30px; /* Spacing */
}

.search-form {
  position: relative;
  width: 100%;
  max-width: 600px; /* Wider search on desktop */
  margin: 0 auto; /* Center it */
}

.search-input {
  width: 100%;
  padding: 15px 25px; /* Bigger touch target */
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.05); /* Softer bg */
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white;
  font-family: var(--font-body);
  font-size: 1rem;
  backdrop-filter: blur(5px);
  transition: 0.3s;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(0, 242, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
}


/* Breadcrumbs */
.breadcrumbs {
    padding: 15px 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}
.breadcrumbs a {
    color: var(--text-muted);
}
.breadcrumbs a:hover {
    color: var(--primary);
}
.breadcrumbs span {
    margin: 0 5px;
}
.breadcrumbs .current {
    color: var(--text-main);
    font-weight: 500;
}

/* In-Article Ads */
.ad-container {
    margin: 40px 0;
    text-align: center;
    min-height: 250px;
    background: #050610;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #333;
    border-radius: 8px;
    flex-direction: column;
}
.ad-label {
    font-size: 0.7rem;
    color: #444;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
    display: block;
}

/* ----------- RESPONSIVE MOBILE ----------- */

@media (max-width: 1024px) {
  .article-list-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
    /* Header Mobile */
    .mobile-menu-btn {
        display: block;
    }

    /* Fullscreen Mobile Menu Overlay - TramitSync Style */
    .main-nav {
        position: fixed;
        top: 80px; /* Matches loose header height to sit below it */
        left: -100%; /* Hidden to the left */
        width: 100%;
        height: calc(100vh - 80px); /* Fill rest of screen */
        background: rgba(15, 23, 42, 0.98); /* Reference Dark Navy */
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        display: flex;
        flex-direction: column;
        align-items: center; /* Center horizontally */
        padding-top: 40px;
        z-index: 999;
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1); /* Slide effect */
        overflow-y: auto;
    }

    .main-nav.active {
        left: 0; /* Slide in */
    }

    .main-nav ul {
        flex-direction: column;
        width: 100%;
        padding: 0 20px;
        gap: 0; /* Removing gap, using padding on links instead */
    }

    .main-nav li {
        width: 100%;
        text-align: center;
    }

    .main-nav a {
        display: block;
        font-family: var(--font-heading);
        font-size: 1.1rem; /* Approx 18-19px */
        font-weight: 700;
        text-transform: uppercase;
        color: #fff;
        padding: 20px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1); /* Separator line */
        letter-spacing: 1px;
    }

    .main-nav a:hover, .main-nav a.active {
        color: var(--primary);
        background: rgba(255, 255, 255, 0.02);
    }

    /* Article Page Stack */
    .article-page-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    /* Typography Adjustments */
    .hero-title, .article-h1 {
        font-size: 2rem;
    }
}

@media (max-width: 600px) {
  .article-list-grid {
    grid-template-columns: 1fr;
  }
  
  .carousel-container {
    height: 300px;
  }

  .hero-overlay {
      padding: 20px;
  }
  
  .search-input {
      padding: 12px 20px;
      font-size: 0.95rem;
  }
  
  /* Make sidebar news items cleaner on mobile */
  .trending-item {
      background: rgba(255,255,255,0.02);
      border-radius: 8px;
      margin-bottom: 10px;
      border: none;
  }

  /* Carousel: Hide arrows on mobile (Use Swipe) */
  .carousel-nav {
      display: none;
  }
}




/* --- COOKIE CONSENT --- */
.cookie-banner { position: fixed; bottom: -100%; left: 0; width: 100%; background: rgba(10, 11, 30, 0.95); backdrop-filter: blur(15px); border-top: 1px solid rgba(0, 242, 255, 0.2); padding: 20px; z-index: 9999; transition: bottom 0.5s ease-in-out; display: flex; flex-direction: column; align-items: center; gap: 15px; box-shadow: 0 -10px 30px rgba(0,0,0,0.5); }
.cookie-banner.active { bottom: 0; }
.cookie-content { max-width: 1000px; width: 100%; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; }
.cookie-text h4 { color: var(--primary); margin-bottom: 5px; font-family: var(--font-heading); }
.cookie-text p { font-size: 0.9rem; color: #ccc; max-width: 700px; }
.cookie-buttons { display: flex; gap: 10px; }
.btn-cookie-manage { background: transparent; border: 1px solid #555; color: #ccc; padding: 10px 20px; border-radius: 20px; cursor: pointer; transition: 0.3s; }
.btn-cookie-manage:hover { border-color: #fff; color: #fff; }
.btn-cookie-accept { background: var(--primary); color: #000; border: none; padding: 10px 25px; border-radius: 20px; font-weight: bold; cursor: pointer; transition: 0.3s; box-shadow: 0 0 10px rgba(0, 242, 255, 0.3); }
.btn-cookie-accept:hover { transform: scale(1.05); box-shadow: 0 0 20px rgba(0, 242, 255, 0.5); }

/* Modal Styles */
.cookie-modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.8); z-index: 10000; display: none; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.3s; }
.cookie-modal.active { display: flex; opacity: 1; }
.modal-content { background: var(--bg-card); width: 100%; max-width: 500px; padding: 30px; border-radius: 12px; border: 1px solid var(--glass-border); position: relative; box-shadow: 0 0 30px rgba(0,0,0,0.7); }
.modal-header h3 { color: var(--primary); margin-bottom: 20px; font-family: var(--font-heading); }
.cookie-option { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; padding: 10px; background: rgba(255,255,255,0.02); border-radius: 8px; }
.cookie-label span { display: block; font-weight: 600; color: #fff; }
.cookie-label small { color: #888; font-size: 0.8rem; }
.modal-actions { margin-top: 25px; display: flex; justify-content: flex-end; gap: 10px; }
.close-modal { position: absolute; top: 15px; right: 20px; font-size: 1.5rem; color: #888; cursor: pointer; background: none; border: none; }
.close-modal:hover { color: #fff; }
