/* Global resets and typography */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, Helvetica, sans-serif;
}

body {
  overflow-x: hidden;
  position: relative;
  color: #fff;
  min-height: 100vh;
}

/* ------------------------------------------------------------------ */
/* Navigation Bar Styles */
/* The navbar sits on top of pages and contains the logo and navigation items. */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1.5rem;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  z-index: 1000;
  backdrop-filter: blur(6px);
}

/* Logo styling */
.navbar .logo {
  font-weight: bold;
  font-size: 1.25rem;
}

/* Main navigation list */
.navbar .nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Individual navigation item */
.navbar .nav-menu > li {
  position: relative;
}

.navbar .nav-menu > li > a {
  color: #fff;
  text-decoration: none;
  padding: 0.5rem 0.75rem;
  transition: background-color 0.2s ease;
}

.navbar .nav-menu > li > a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

/* Dropdown menu */
.navbar .dropdown-menu {
  position: absolute;
  left: 0;
  top: 100%;
  min-width: 200px;
  background: rgba(0, 0, 0, 0.8);
  list-style: none;
  padding: 0.5rem 0;
  display: none;
  flex-direction: column;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  border-radius: 4px;
  z-index: 1001;
}

.navbar .dropdown-menu li a {
  color: #fff;
  padding: 0.5rem 1rem;
  display: block;
  text-decoration: none;
}

.navbar .dropdown-menu li a:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

/* Show dropdown on hover for desktop */
.navbar .dropdown:hover > .dropdown-menu {
  display: flex;
}

/* Menu toggle button for mobile */
.menu-toggle {
  font-size: 1.5rem;
  cursor: pointer;
  display: none;
}

/* Mobile menu styles */
@media (max-width: 768px) {
  .navbar .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.9);
    flex-direction: column;
    gap: 0;
    display: none;
  }
  .navbar .nav-menu.active {
    display: flex;
  }
  .navbar .nav-menu li {
    width: 100%;
  }
  .navbar .dropdown-menu {
    position: relative;
    top: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.8);
    box-shadow: none;
    padding-left: 1rem;
  }
  .navbar .dropdown:hover > .dropdown-menu {
    display: none;
  }
  .navbar .menu-toggle {
    display: block;
  }
}

/* ------------------------------------------------------------------ */
/* Hero Section Styles */
/* The hero section appears on individual pages with a background image */
.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  filter: brightness(55%);
}

.hero::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.4);
}

.hero h1 {
  position: relative;
  font-size: 2.5rem;
  z-index: 1;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

/* ------------------------------------------------------------------ */
/* Content Section Styles */
.content-section {
  padding: 2rem;
  background-color: #f7f7f7;
  color: #333;
}

.content-section h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.content-section p {
  line-height: 1.6;
  margin-bottom: 1rem;
}

/* Form styles used in tools pages */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
  box-sizing: border-box;
}

.form-group textarea {
  resize: vertical;
}

.btn {
  display: inline-block;
  padding: 0.6rem 1.2rem;
  background-color: #ff9500;
  color: #fff;
  text-decoration: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.btn:hover {
  background-color: #e08700;
}

/* ------------------------------------------------------------------ */
/* Team Grid Styles */
/* Used on the Team page to arrange team members neatly. */
.team-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
}

.team-member {
  flex: 1 1 200px;
  max-width: 240px;
  text-align: center;
  color: #333;
}

.team-member img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 0.5rem;
}

.team-member h3 {
  margin: 0.5rem 0 0.25rem;
  font-size: 1.1rem;
}

.team-member p {
  margin: 0;
  font-size: 0.9rem;
  color: #666;
}

/* ------------------------------------------------------------------ */
/* FAQ & News Styles */
.faq-item {
  margin-bottom: 1.5rem;
}

.faq-item h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

article {
  margin-bottom: 2rem;
}

article h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

article p {
  color: #555;
  line-height: 1.6;
}

/* ------------------------------------------------------------------ */
/* Chat Widget Styles */
.chat-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 300px;
  max-height: 400px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-size: 0.9rem;
  z-index: 2000;
}

.chat-header {
  background: #ff9500;
  color: #fff;
  padding: 0.5rem;
  font-weight: bold;
}

.chat-messages {
  flex: 1;
  padding: 0.5rem;
  overflow-y: auto;
  background: #f7f7f7;
}

.chat-input {
  display: flex;
  border-top: 1px solid #ddd;
}

.chat-input input {
  flex: 1;
  border: none;
  padding: 0.5rem;
  outline: none;
}

.chat-input button {
  background: #ff9500;
  color: #fff;
  border: none;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
}

.chat-toggle {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: #ff9500;
  color: #fff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  font-size: 1.5rem;
  z-index: 2000;
}

/* Hide chat widget by default */
.chat-widget.hidden {
  display: none;
}

/* Background video styling */
#background-video {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  z-index: -1;
}

/* Overlay containing content */
.overlay {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  min-height: 100vh;
  background: rgba(0, 0, 0, 0.4);
  padding: 2rem;
}

.overlay h1 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

/* Button container layout */
.button-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  align-items: center;
}

/* Individual navigation buttons */
.nav-button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.15);
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  text-decoration: none;
  color: #fff;
  transition: transform 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
  backdrop-filter: blur(5px);
}

.nav-button:hover,
.nav-button:focus {
  transform: scale(1.05);
  background-color: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.6);
}

/* Icon styling inside buttons */
.icon {
  font-size: 1.2rem;
}

/* Media queries for responsiveness */
@media (max-width: 600px) {
  .overlay h1 {
    font-size: 1.8rem;
  }
  .nav-button {
    width: 100%;
    justify-content: center;
  }
  .button-container {
    flex-direction: column;
  }
}