/* --- CSS VARIABLES & RESET --- */
:root {
  --primary-blue: #0056a6;
  --dark-blue: #003d7a;
  --accent-red: #d32f2f;
  --text-black: #1a1a1a;
  --text-grey: #666666;
  --bg-light: #f4f7f6;
  --white: #ffffff;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Poppins", sans-serif;
  background-color: var(--bg-light);
  color: var(--text-black);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}
ul {
  list-style: none;
}
img {
  width: 100%;
  display: block;
  object-fit: cover;
}

/* --- STICKY NAVIGATION --- */
.navbar {
  background-color: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 0 5%;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-blue);
  letter-spacing: -0.5px;
}

.logo span {
  color: var(--text-black);
}

.nav-links {
  display: flex;
  gap: 25px;
}

.nav-links a {
  font-weight: 500;
  font-size: 14px;
  color: var(--text-black);
  text-transform: uppercase;
}

.nav-links a:hover {
  color: var(--primary-blue);
}

.menu-toggle {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* --- BREAKING NEWS TICKER --- */
.ticker-wrap {
  width: 100%;
  background-color: var(--primary-blue);
  color: white;
  display: flex;
  height: 40px;
  overflow: hidden;
}

.ticker-label {
  background-color: var(--dark-blue);
  padding: 0 20px;
  font-weight: 700;
  font-size: 12px;
  display: flex;
  align-items: center;
  text-transform: uppercase;
  z-index: 2;
  white-space: nowrap;
}

.ticker-move {
  display: flex;
  align-items: center;
  animation: ticker 25s linear infinite;
  white-space: nowrap;
  padding-left: 100%;
}

.ticker-item {
  display: inline-block;
  padding: 0 2rem;
  font-size: 14px;
}

@keyframes ticker {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-100%, 0, 0);
  }
}

/* --- HERO SECTION --- */
.hero {
  max-width: 1200px;
  margin: 30px auto;
  padding: 0 20px;
  position: relative;
}

.hero-card {
  position: relative;
  height: 450px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-img {
  height: 100%;
  width: 100%;
  transition: transform 0.5s ease;
}

.hero-card:hover .hero-img {
  transform: scale(1.05);
}

.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
  padding: 40px 30px;
  color: white;
}

.badge {
  background-color: var(--primary-blue);
  color: white;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 10px;
}

.hero-title {
  font-size: 32px;
  margin-bottom: 10px;
  line-height: 1.2;
}

.hero-desc {
  font-size: 16px;
  opacity: 0.9;
  max-width: 800px;
}

/* --- MAIN LAYOUT (GRID) --- */
.main-content {
  max-width: 1200px;
  margin: 0 auto 50px auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 2.5fr 1fr; /* News 2.5 : Sidebar 1 */
  gap: 30px;
}

/* --- LATEST NEWS GRID --- */
.section-header {
  border-left: 5px solid var(--primary-blue);
  padding-left: 15px;
  margin-bottom: 20px;
  font-size: 22px;
  font-weight: 700;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.news-card {
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-img-wrap {
  height: 180px;
  overflow: hidden;
  position: relative;
}

.news-card .category-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--primary-blue);
  color: white;
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 3px;
  text-transform: uppercase;
}

.card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.4;
}

.card-meta {
  font-size: 12px;
  color: var(--text-grey);
  margin-top: auto;
  display: flex;
  justify-content: space-between;
}

/* --- SIDEBAR --- */
.sidebar-widget {
  background: var(--white);
  padding: 20px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  margin-bottom: 30px;
}

.widget-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #eee;
}

/* Trending List */
.trending-list li {
  margin-bottom: 15px;
  padding-bottom: 15px;
  border-bottom: 1px solid #f4f4f4;
  display: flex;
  align-items: flex-start;
}

.trending-list li:last-child {
  border: none;
  margin: 0;
}

.trending-number {
  font-size: 24px;
  font-weight: 700;
  color: #ddd;
  margin-right: 15px;
  line-height: 1;
}

.trending-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}

/* Weather Widget */
.weather-box {
  background: linear-gradient(135deg, var(--primary-blue), #4fa3eb);
  color: white;
  border-radius: 8px;
  padding: 20px;
  text-align: center;
}
.weather-location {
  font-size: 18px;
  font-weight: 600;
}
.weather-temp {
  font-size: 48px;
  font-weight: 700;
  margin: 10px 0;
}
.weather-icon {
  font-size: 40px;
  margin-bottom: 10px;
}
.weather-desc {
  font-size: 14px;
  text-transform: capitalize;
}

/* Social Icons */
.social-links {
  display: flex;
  gap: 10px;
}
.social-btn {
  flex: 1;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  color: white;
  font-size: 18px;
}
.fb {
  background: #3b5998;
}
.tw {
  background: #1da1f2;
}
.ig {
  background: #e1306c;
}
.yt {
  background: #ff0000;
}

/* --- FOOTER --- */
footer {
  background-color: #111;
  color: #bbb;
  padding: 60px 0 20px;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  padding: 0 20px;
  margin-bottom: 40px;
}

.footer-col h3 {
  color: white;
  margin-bottom: 20px;
}
.footer-col h3 span {
  color: var(--primary-blue);
}
.footer-col p {
  font-size: 14px;
  margin-bottom: 15px;
}
.footer-links li {
  margin-bottom: 10px;
}
.footer-links a:hover {
  color: var(--primary-blue);
  padding-left: 5px;
}

.copyright {
  text-align: center;
  border-top: 1px solid #333;
  padding-top: 20px;
  font-size: 13px;
}

/* --- RESPONSIVE MEDIA QUERIES --- */
@media (max-width: 900px) {
  .main-content {
    grid-template-columns: 1fr;
  }
  .hero-card {
    height: 350px;
  }
  .hero-title {
    font-size: 24px;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  } /* Simplified for code snippet, usually toggle */
  .menu-toggle {
    display: block;
  }
  .hero-card {
    height: 300px;
  }
  .footer-grid {
    text-align: center;
  }
}
