/* Reset + Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', sans-serif;
}

body {
  background: #f8f9fa;
  color: #212529;
  line-height: 1.6;
}

a {
  color: #007BFF;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Layout */
.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
}

.header, .footer {
  background: #0d253f;
  color: white;
  padding: 1.5rem 0;
  text-align: center;
}

.navbar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 1rem;
}

/* Homepage Layout */
.homepage-content {
  display: grid;
  grid-template-columns: 3fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.article-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.tile {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: transform 0.2s ease;
}

.tile:hover {
  transform: translateY(-5px);
}

.tile img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.tile-content {
  padding: 1rem;
}

/* Article Page */
.article-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  justify-content: center;
  gap: 2rem;
  margin: 2rem auto;
  padding: 0 1rem;
}

.article-main {
  background: white;
  padding: 2rem 2.5rem;
  border-radius: 8px;
  line-height: 1.8;
  font-size: 1.05rem;
  max-width: 850px;
  width: 100%;
}

.article-main h2, .article-main h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.article-main p {
  margin-bottom: 1rem;
}

.article-sidebar {
  background: #fff;
  padding: 1rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.article-sidebar h3 {
  margin-bottom: 1rem;
}

.sidebar-tile {
  margin-bottom: 1rem;
  font-size: 0.9rem;
  border-bottom: 1px solid #eee;
  padding-bottom: 0.5rem;
}

.sidebar-tile:last-child {
  border: none;
}

/* Sidebar Widgets */
.sidebar {
  background: #fff;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.sidebar h3 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  border-bottom: 2px solid #ccc;
  padding-bottom: 0.5rem;
}

.sidebar ul {
  list-style: none;
  padding: 0;
}

.sidebar ul li {
  margin: 5px 0;
}

.sidebar ul li a {
  color: #000;
  text-decoration: none;
}

.sidebar ul li a:hover {
  color: #007BFF;
}

.sidebar .widget {
  margin-bottom: 1.5rem;
}

.sidebar .widget h4 {
  font-size: 1rem;
  font-weight: bold;
  margin-bottom: 10px;
}

.sidebar .widget input {
  width: 100%;
  padding: 0.5rem;
  border-radius: 5px;
  border: 1px solid #ccc;
}

.sidebar .widget ul {
  list-style: none;
  padding: 0;
}

.sidebar .widget li {
  margin-bottom: 0.5rem;
}

.sidebar .widget a {
  color: #007BFF;
  font-size: 0.95rem;
}

.footer p {
  font-size: 0.9rem;
  color: #ccc;
}

.live-rates {
  margin-top: 1rem;
  font-size: 0.85rem;
  background: #1c1c1c;
  color: #f1f1f1;
  padding: 1rem;
  border-radius: 4px;
}

/* Responsive Layout */

@media (min-width: 769px) and (max-width: 1024px) {
  .homepage-content {
    grid-template-columns: 2fr 1fr;
  }

  .article-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .article-body {
    grid-template-columns: 1fr;
  }

  .article-sidebar {
    margin-top: 2rem;
  }
}

@media (max-width: 768px) {
  .homepage-content {
    grid-template-columns: 1fr;
  }

  .article-body {
    grid-template-columns: 1fr;
  }

  .article-grid {
    grid-template-columns: 1fr;
  }

  .navbar {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }

  .article-main {
    padding: 1.5rem;
  }
}

/* Sticky Navbar */
.sticky-navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #0d253f;
  color: white;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  padding: 0.5rem 0;
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  padding: 0 1rem;
  margin: auto;
}

.logo a {
  font-size: 1.5rem;
  color: white;
  text-decoration: none;
  font-weight: bold;
}

.logo img {
  width: 50px;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: white;
  font-weight: 500;
  text-decoration: none;
}

.nav-links a:hover {
  text-decoration: underline;
}

.burger {
  display: none;
  font-size: 2rem;
  cursor: pointer;
  color: white;
}

/* Responsive Navbar */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    flex-direction: column;
    background: #0d253f;
    position: absolute;
    top: 100%;
    right: 0;
    width: 100%;
    padding: 1rem;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  }

  .nav-links.active {
    display: flex;
  }

  .burger {
    display: block;
  }
}

.tagline {
  background: #e9ecef;
  color: #0d253f;
  padding: 0.75rem 1rem;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 500;
  letter-spacing: 0.3px;
  border-bottom: 2px solid #ccc;
}

@media (max-width: 768px) {
  .tagline {
    font-size: 1rem;
    padding: 0.6rem 0.8rem;
  }
}

/* Trusted Brands Section */
.trusted-brands {
  padding: 3rem 1rem;
  text-align: center;
  background-color: #f8f9fa;
}

.trusted-brands h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #0d253f;
}

.brands-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
}

.brands-container img {
  max-width: 120px;
  height: auto;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.brands-container img:hover {
  transform: scale(1.1);
}

@media (max-width: 768px) {
  .brands-container img {
    width: 100px;  /* Resize logos for mobile */
  }
}

/* Navbar Dropdown */
.category-dropdown {
  position: relative;
  display: inline-block;
}

.category-dropdown .dropdown-content {
  display: none;
  position: absolute;
  background-color: #f1f1f1;
  min-width: 160px;
  box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
  z-index: 1;
}

.category-dropdown:hover .dropdown-content {
  display: block;
}

.category-dropdown .dropdown-content a {
  color: black;
  padding: 12px 16px;
  text-decoration: none;
  display: block;
}

.category-dropdown .dropdown-content a:hover {
  background-color: #ddd;
}
