/* ========== Variables ========== */
:root {
  --color-primary: #0a2540; /* Dark blue for navbar, headings */
  --color-accent: #d4af37; /* Gold accent for highlights and hover */
  --color-bg: #ffffff; /* Page background */
  --color-text: #0a2540; /* Main text color */
  --color-muted: #555; /* Subtle text (SEBI info, etc.) */
  --color-card-bg: #f8f9fb; /* Card background */
  --color-footer-bg: #0a2540; /* Footer background */
  --color-footer-text: #fff; /* Footer text */
  --color-dropdown-bg: #fff; /* Dropdown background */
  --color-dropdown-hover: #f8f9fb; /* Dropdown hover background */
  --font-family: "Poppins", sans-serif;
  --font-size-base: 16px;
  --font-size-h1: 2.2rem;
  --font-size-h2: 1.8rem;
  --font-size-h3: 1.2rem;
  --font-size-small: 0.9rem;
  --line-height: 1.6;
  --transition: 0.3s ease;
  --border-radius: 4px;
  --box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* ========== Global Styles ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: var(--font-size-base);
}

body {
  font-family: var(--font-family);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: var(--line-height);
  overflow-x: hidden; /* prevent horizontal scroll */
}

.section {
  padding: 80px 0;
}

/* ========== Navbar ========== */
#menu-placeholder {
  position: sticky;
  top: 0;
}
.navbar {
  background: var(--color-primary);
  color: #fff;
  z-index: 1000;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  position: relative;
}

.logo {
  font-size: 1.4rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--color-accent);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  position: relative;
  padding: 16px;
}

.nav-links li {
  position: relative;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition);
  padding: 8px 0;
  display: inline-block;
}

.nav-links a:hover {
  color: var(--color-accent);
}

/* Hamburger Menu */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 25px;
  height: 20px;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  height: 3px;
  background: #fff;
  border-radius: 2px;
}

/* ========== Dropdown Menu ========== */
.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--color-dropdown-bg);
  color: var(--color-text);
  min-width: 180px;
  max-width: 90vw;
  word-wrap: break-word;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  z-index: 999;
}

.dropdown-menu li {
  border-bottom: 1px solid #eee;
}

.dropdown-menu li:last-child {
  border-bottom: none;
}

.dropdown-menu a {
  display: block;
  color: var(--color-text);
  padding: 8px 16px;
  transition: background 0.2s ease, color 0.2s ease;
}

.dropdown-menu a:hover {
  background: var(--color-dropdown-hover);
  color: var(--color-accent);
}

/* Desktop hover */
.dropdown:hover > .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown,
.dropdown-menu {
  pointer-events: auto;
}

/* ========== Hero Section ========== */
.hero {
  background: linear-gradient(to right, var(--color-primary), #183b63);
  color: #fff;
  text-align: center;
  padding: 120px 20px;
  /* height: 100dvh; */
}

.hero h1 {
  font-size: var(--font-size-h1);
  margin-bottom: 20px;
}

.hero p {
  font-size: 1.1rem;
  margin-bottom: 30px;
}

.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 10px 25px;
  border-radius: var(--border-radius);
  text-decoration: none;
  font-weight: 500;
  transition: all var(--transition);
}

.btn.primary {
  background: var(--color-accent);
  color: var(--color-primary);
}

.btn.secondary {
  border: 2px solid var(--color-accent);
  color: var(--color-accent);
}

.btn:hover {
  opacity: 0.9;
}

/* ========== Sections ========== */
h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: var(--font-size-h2);
  color: var(--color-text);
}

/* Philosophy */
.philosophy p {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

/* Services Overview */
.service-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: center;
}

.card {
  background: var(--color-card-bg);
  padding: 25px;
  border-radius: 8px;
  /* text-align: center; */
  transition: transform var(--transition);
  max-width: 100%;
}

.card:hover {
  transform: translateY(-5px);
}

.card h3 {
  color: var(--color-text);
  margin-bottom: 8px;
}

/* About */
.about p {
  margin-bottom: 16px;
}

.approach-list {
  list-style: disc;
  padding-left: 16px;
}

.sebi-info {
  margin-bottom: 8px;
}

/* Contact */
.contact-content {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
}

.contact-info {
  flex: 1;
  display: flex;
  align-items: start;
  flex-direction: column;
  justify-content: center;
}

.contact-button {
  margin-top: 24px;
  display: flex;
  justify-content: center;
  align-items: start; 
}

/* Footer */
.footer {
  background: var(--color-footer-bg);
  color: var(--color-footer-text);
  text-align: center;
  padding: 40px 24px;
  font-size: var(--font-size-small);
}

.footer .disclaimer {
  font-size: 0.8rem;
  opacity: 0.8;
  margin-top: 8px;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  color: var(--color-text);
}

table th,
table td {
  border: 1px solid var(--color-text); /* use primary text color for borders */
  padding: 8px 12px;
  text-align: left;
}

table th {
  background-color: var(--color-card-bg); /* light background for headers */
  font-weight: 600;
  color: var(--color-text);
}

table tr:nth-child(even) td {
  background-color: var(--color-dropdown-hover); /* subtle alternate row bg */
}

/* ========== Responsive Styles ========== */
@media (max-width: 768px) {
  /* Cards & contact */
  .service-cards,
  .contact-content {
    flex-direction: column;
  }

  /* Hamburger menu */
  .menu-toggle {
    display: flex;
  }

  /* Mobile nav links */
  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    gap: 0;
    background: var(--color-primary);
    position: absolute;
    top: 60px;
    left: 0;
    padding-bottom: 20px;
    z-index: 999;
  }

  .nav-links.show {
    display: flex;
  }

  .nav-links li {
    width: 100%;
  }

  /* Mobile dropdown */
  .dropdown-menu {
    display: none;
    position: static;
    background: var(--color-primary);
    padding-left: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .dropdown-menu.show {
    display: block;
  }

  .dropdown-menu a {
    color: #fff;
    padding: 12px 20px;
  }

  .dropdown-menu a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-accent);
  }

  .hero {
    padding: 64px 24px;
  }

  .section {
    padding: 48px 24px;
  }
}

@media screen and (min-width: 768px) {
  .card {
    flex: 1 1 280px;
  }
  .container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
  }
}

@media (max-width: 768px) {
  table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
  .nav-content { 
    padding: 16px; 
  }
}
