/* =========================================================
   site.css  —  Spiral Networks shared header & footer
   ---------------------------------------------------------
   This file is the SINGLE SOURCE OF TRUTH for the site
   header, navigation, dropdowns and footer.
   The markup itself is injected by site-nav.js, so to add a
   nav link or change the footer you edit ONE file (site-nav.js)
   and the styling here — every page updates automatically.
   ========================================================= */

/* ---- Header & Navbar ---- */
header.site-header {
  background: #003049;
  color: #ffffff;
  position: relative;
  z-index: 9999;
}
header.site-header .container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.7rem 0;
}
.navbar {
  display: flex;
  align-items: center;
  padding: 0.7rem 0;
}
.logo-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-right: 1rem;
  flex-shrink: 0;
}
.logo-img {
  height: 50px;
  width: auto;
  vertical-align: middle;
}
.nav-menu {
  list-style: none;
  display: flex;
  justify-content: flex-start;
  gap: 3rem;
  margin-left: 12rem;
  align-items: center;
  position: relative;
  padding: 0;
}
.nav-menu li a {
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  padding: 0;
  background: transparent;
  border-radius: 0;
  transition: opacity 0.3s ease;
  display: inline-block;
  text-align: center;
}
.nav-menu li a:hover {
  opacity: 0.8;
}

/* ---- Dropdowns (Services + Solutions share this) ---- */
.services-dropdown {
  position: relative;
}
.services-dropdown:hover .services-submenu {
  display: block;
}
.services-submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #003049;
  padding: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  z-index: 9999;
  min-width: 220px;
  border-radius: 6px;
}
.services-submenu li {
  list-style: none;
  margin-bottom: 0.5rem;
}
.services-submenu li:last-child {
  margin-bottom: 0;
}
.services-submenu li a {
  display: block;
  color: #fff;
  text-decoration: none;
  padding: 0.55rem 1rem;
  background: #0a9396;
  border-radius: 4px;
  white-space: nowrap;
  transition: background 0.3s ease;
}
.services-submenu li a:hover {
  background: #087478;
}

/* ---- Footer ---- */
footer.site-footer {
  flex-shrink: 0;
  background: #003049;
  color: #fff;
  padding: 2rem 1rem;
}
footer.site-footer .container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0;
}
.footer-top {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2rem;
  align-items: start;
}
.footer-col h4 {
  margin-bottom: 0.75rem;
  font-size: 1rem;
  color: #fff;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-col li {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}
.footer-col a {
  color: #fff;
  text-decoration: none;
}
.footer-col a:hover {
  text-decoration: underline;
}
.footer-logo img {
  height: 60px;
  width: auto;
  max-width: 100%;
  display: block;
}
.footer-col.footer-logo {
  justify-self: start;
  align-self: start;
  margin-left: -24px;
}
.footer-bottom {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-bottom p {
  margin: 0;
  font-size: 0.95rem;
}
.footer-links a {
  color: #fff;
  margin-left: 1.5rem;
  font-size: 0.95rem;
  text-decoration: underline;
}
.footer-links a:first-child {
  margin-left: 0;
}

/* ---- Mobile hamburger + responsive nav/footer ---- */
.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 0.5rem;
  margin-left: auto;
  cursor: pointer;
  width: 44px;
  height: 44px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
}

@media (max-width: 1000px) {
  .footer-top { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .navbar { flex-wrap: wrap; }
  .nav-toggle { display: flex; }
  .nav-menu {
    display: none;
    flex-direction: column;
    width: 100%;
    margin: 0 !important;
    padding: 0.5rem 0;
    gap: 0;
    background: #003049;
    flex-basis: 100%;
    align-items: stretch;
  }
  .nav-menu.is-open { display: flex; }
  .nav-menu > li { width: 100%; }
  .nav-menu li a { display: block; padding: 0.85rem 0.25rem; }
  .services-submenu {
    position: static;
    box-shadow: none;
    min-width: 0;
    width: 100%;
    padding-left: 0.75rem;
  }
  .services-dropdown.is-open .services-submenu { display: block; }
}
@media (max-width: 720px) {
  .footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 520px) {
  .footer-top { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  footer.site-footer .footer-top {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) !important;
  }
  .footer-col { min-width: 0; }
  .footer-col a { overflow-wrap: anywhere; word-break: break-word; }
}
