/* ===========================
   layout.css
   Shared chrome — header & footer.
   =========================== */

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 72px;
}

.logo { display: flex; align-items: center; }
.logo img { height: 38px; width: auto; }
.logo .custom-logo { height: 38px; width: auto; }

/* Primary navigation pushed to the right */
.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-left: auto;
}

/* Strip list styling from the menu output only (wp_nav_menu <ul>/<li>);
   other lists across the theme are unaffected. */
.main-nav ul,
.main-nav li {
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-nav ul {
  display: flex;
  align-items: center;
  gap: 32px;
}

.main-nav a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  position: relative;
}

.main-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width var(--transition);
}

.main-nav a:hover::after,
.main-nav a.active::after,
.main-nav .current-menu-item > a::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Highlighted contact call-to-action in the header */
.header-cta {
  padding: 10px 22px;
  font-size: 14px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background var(--transition);
  color: var(--text);
}

.icon-btn:hover {
  background: var(--bg);
  color: var(--primary);
}

.menu-toggle { display: none; }

/* ---------- Footer ---------- */
.site-footer {
  background: linear-gradient(180deg, #1A1F2E, #0F1320);
  color: #CBD5E1;
  padding: 64px 0 24px;
  margin-top: 96px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand p {
  margin-top: 16px;
  color: #94A3B8;
  font-size: 14px;
  line-height: 1.7;
  max-width: 320px;
}

/* Brand highlight beneath the logo */
.footer-brand .footer-highlight {
  margin-top: 20px;
  color: #F1F5F9;
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.65;
  max-width: 360px;
  padding-left: 14px;
  border-left: 3px solid;
  border-image: linear-gradient(180deg, var(--primary), var(--secondary)) 1;
}

.footer-brand .footer-tagline {
  margin-top: 14px;
}

.footer-brand .logo img,
.footer-brand .logo .custom-logo {
  filter: brightness(0) invert(1);
  opacity: 0.95;
}

.footer-col h4 {
  color: var(--white);
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 18px;
  letter-spacing: 0.4px;
}

.footer-col ul,
.footer-col .menu {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.footer-col a {
  color: #94A3B8;
  font-size: 14px;
}

.footer-col a:hover { color: var(--white); }

.social-row {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.social-row a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.social-row a:hover {
  background: var(--primary);
  transform: translateY(-2px);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: #64748B;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 768px) {
  .menu-toggle { display: inline-flex; }

  .main-nav {
    position: fixed;
    top: 64px;
    left: 0;
    right: 0;
    margin-left: 0;
    background: var(--white);
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
    gap: 18px;
    border-bottom: 1px solid var(--border);
    transform: translateY(-150%);
    transition: transform var(--transition);
    box-shadow: var(--shadow-md);
  }

  .main-nav.open { transform: translateY(0); }

  .header-inner { height: 64px; }

  /* Nav is fixed/out of flow on mobile — keep the CTA + toggle right-aligned */
  .header-actions { margin-left: auto; }
  .header-cta { padding: 9px 16px; }

  .site-footer {
    padding: 48px 0 24px;
    margin-top: 64px;
  }
}

@media (max-width: 520px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
}
