header {
  position: fixed;
  top: 0;
  z-index: 1000;
  width: 100%;
  background: #fff;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

header .container,
footer .container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #6a0dad;
  text-decoration: none;
}

.logo img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.logo-text {
  color: #6a0dad;
  font-size: 24px;
  font-weight: 700;
  line-height: 20px;
}

.logo .logo-text {
  color: #6a0dad;
  font-size: 24px;
}

.logo .logo-text span {
  color: #333;
  font-size: inherit;
}

nav ul {
  display: flex;
  align-items: initial;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

nav ul li {
  margin-left: 30px;
}

nav ul li a {
  position: relative;
  color: #333;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s;
}

nav ul li a::after {
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: #6a0dad;
  content: "";
  transition: width 0.3s;
}

nav ul li a:hover,
nav ul li a.active:not(.nav-cta) {
  color: #6a0dad;
}

nav ul li a.active:not(.nav-cta) {
  font-weight: 700;
}

nav ul li a.active:not(.nav-cta)::after {
  width: 100%;
}

nav ul li a:hover::after {
  width: 100%;
}

nav ul li a.nav-cta.active {
  background: #4b0082;
  box-shadow: 0 0 0 2px rgba(106, 13, 173, 0.2);
}

.nav-cta {
  padding: 8px 20px;
  border-radius: 30px;
  background: #6a0dad;
  color: #fff;
  transition: all 0.3s;
}

.nav-cta:hover {
  transform: translateY(-2px);
  background: #4b0082;
}

.nav-cta:hover::after {
  width: 0;
}

.mobile-menu-btn {
  display: none;
  border: 0;
  background: none;
  color: #6a0dad;
  font-size: 24px;
  cursor: pointer;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  z-index: 1001;
  width: 80%;
  max-width: 300px;
  height: 100vh;
  padding: 80px 30px 30px;
  overflow-y: auto;
  background: #fff;
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  transition: right 0.4s ease;
}

.mobile-menu.active {
  right: 0;
}

.mobile-menu ul {
  list-style: none;
}

.mobile-menu ul li {
  margin-bottom: 20px;
}

.mobile-menu ul li a {
  display: block;
  padding: 10px 0;
  border-bottom: 1px solid #e9ecef;
  color: #333;
  font-size: 1.1rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.3s;
}

.mobile-menu ul li a:hover,
.mobile-menu ul li a.active {
  color: #6a0dad;
}

.mobile-menu ul li a.active {
  border-bottom-color: #6a0dad;
  font-weight: 700;
}

.mobile-menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  border: 0;
  background: none;
  color: #333;
  font-size: 24px;
  cursor: pointer;
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  visibility: hidden;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: all 0.3s;
}

.overlay.active {
  visibility: visible;
  opacity: 1;
}

footer {
  padding: 70px 0 30px;
  background: #333;
  color: #fff;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 50px;
}

.footer-col h3 {
  position: relative;
  margin-bottom: 25px;
  padding-bottom: 10px;
  font-size: 1.3rem;
}

.footer-col h3::after {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: #6a0dad;
  content: "";
}

.footer-col p {
  margin-bottom: 20px;
  opacity: 0.8;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  color: #fff;
  text-decoration: none;
  opacity: 0.8;
  transition:
    opacity 0.3s,
    padding-left 0.3s;
}

.footer-links a:hover {
  padding-left: 5px;
  opacity: 1;
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 20px;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  text-decoration: none;
  transition: all 0.3s;
}

.social-links a:hover {
  transform: translateY(-3px);
  background: #6a0dad;
}

.copyright {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
  text-align: center;
  opacity: 0.7;
}

.mobile-menu-btn,
.mobile-menu-close {
  min-width: 44px;
  min-height: 44px;
}

@media (max-width: 768px) {
  nav ul {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-menu,
  .overlay,
  nav ul li a,
  .nav-cta,
  .social-links a {
    transition: none;
  }
}

/* ------------------------------------------------------------------
   Header (all pages). Frosted white bar, pill navigation, compact on scroll.
   ------------------------------------------------------------------ */
body > header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0 !important;
  background: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid rgba(29, 21, 48, 0.06);
  box-shadow: none !important;
  transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

body > header.is-scrolled {
  background: rgba(255, 255, 255, 0.98);
  border-bottom-color: transparent;
  box-shadow: 0 10px 30px rgba(29, 21, 48, 0.08) !important;
}

body > header .container.header-container {
  max-width: 1240px;
  min-height: 76px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  transition: min-height 0.3s ease;
}

body > header.is-scrolled .container.header-container {
  min-height: 64px;
}

body > header .logo,
body > header .logo:hover,
body > header .logo:focus,
body > header .logo * {
  text-decoration: none !important;
}

body > header .logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
  border-radius: 12px;
}

body > header .logo img {
  width: 46px;
  height: 46px;
  padding: 2px;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(135deg, #8a2be2, #4b0082);
  box-shadow: 0 4px 14px rgba(75, 0, 130, 0.22);
  transition: width 0.3s ease, height 0.3s ease, transform 0.3s ease;
}

body > header .logo:hover img {
  transform: rotate(-6deg) scale(1.03);
}

body > header.is-scrolled .logo img {
  width: 40px;
  height: 40px;
}

body > header .logo .logo-text {
  display: flex;
  flex-direction: column;
  padding-left: 12px;
  border-left: 1px solid rgba(29, 21, 48, 0.12);
  color: #1d1530;
  font-size: 1.3rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.08em;
}

body > header .logo .logo-text br {
  display: none;
}

body > header .logo .logo-text span {
  margin-top: 5px;
  color: #6a0dad;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

/* thin brand line along the top edge */
body > header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #4b0082, #8a2be2 50%, #4b0082);
}

body > header nav ul {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

body > header nav ul li {
  margin: 0;
}

body > header nav ul li a {
  display: inline-flex;
  align-items: center;
  padding: 9px 14px;
  border-radius: 999px;
  color: #3b3550;
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

body > header nav ul li a::after {
  display: none;
}

body > header nav ul li a:hover {
  color: #6a0dad;
  background: rgba(106, 13, 173, 0.06);
}

body > header nav ul li a.active:not(.nav-cta),
body > header nav ul li a[aria-current="page"]:not(.nav-cta) {
  color: #6a0dad;
  background: rgba(106, 13, 173, 0.09);
  font-weight: 600;
}

body > header nav ul li a.nav-cta {
  margin-left: 8px;
  padding: 11px 22px;
  background: linear-gradient(135deg, #7a1fc6, #5a0a9e);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 6px 18px rgba(106, 13, 173, 0.28);
}

body > header nav ul li a.nav-cta:hover,
body > header nav ul li a.nav-cta.active {
  background: linear-gradient(135deg, #6a0dad, #4b0082);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(106, 13, 173, 0.34);
}

body > header nav a:focus-visible,
body > header .mobile-menu-btn:focus-visible,
.mobile-menu a:focus-visible {
  outline: 2px solid #6a0dad;
  outline-offset: 2px;
}

body > header .mobile-menu-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 1px solid rgba(106, 13, 173, 0.18);
  border-radius: 12px;
  background: #fff;
  color: #6a0dad;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

body > header .mobile-menu-btn:hover {
  background: rgba(106, 13, 173, 0.06);
  border-color: rgba(106, 13, 173, 0.35);
}

/* Mobile drawer */
.mobile-menu {
  width: 86%;
  max-width: 340px;
  padding: 88px 24px 32px;
  border-radius: 20px 0 0 20px;
  box-shadow: -20px 0 50px rgba(29, 21, 48, 0.18);
  transition: right 0.35s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.mobile-menu ul {
  margin: 0;
  padding: 0;
}

.mobile-menu ul li {
  margin: 0 0 4px;
}

.mobile-menu ul li a {
  padding: 13px 16px;
  border: 0;
  border-radius: 12px;
  color: #2a2440;
  font-size: 1.05rem;
}

.mobile-menu ul li a:hover {
  background: rgba(106, 13, 173, 0.06);
}

.mobile-menu ul li a.active {
  background: rgba(106, 13, 173, 0.09);
  color: #6a0dad;
  font-weight: 600;
}

.mobile-menu-close {
  top: 22px;
  right: 22px;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: #f5f2fa;
  font-size: 1.1rem;
}

.overlay {
  background: rgba(20, 14, 34, 0.45);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

@media (max-width: 1100px) {
  body > header nav ul li a {
    padding: 9px 10px;
    font-size: 0.9rem;
  }
}

/* One breakpoint for every page: full menu above 992px, drawer below. */
@media (min-width: 993px) {
  body > header .mobile-menu-btn,
  .mobile-menu,
  .overlay {
    display: none !important;
  }
}

@media (max-width: 992px) {
  body > header nav {
    display: none !important;
  }

  body > header .mobile-menu-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
  }

  body > header .container.header-container {
    min-height: 68px;
    padding: 0 18px;
  }

  body > header .logo img {
    width: 40px;
    height: 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body > header,
  body > header *,
  .mobile-menu {
    transition: none !important;
  }
}
