@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Outfit:wght@700;800&family=Space+Grotesk:wght@700;800&family=Roboto:wght@600&display=swap');

:root {
  --color-page-bg: #f8fafc;
  --color-card-bg: #ffffff;
  --color-page-dark: #050508;
  --color-primary: #2563eb;
  --color-primary-bright: #60a5fa;
  --color-text-title: #374151;
  --color-text-body: #4b5563;
  --color-border: rgba(148, 163, 184, 0.12);
  --font-heading: "Inter", system-ui, sans-serif;
  --font-ui: "Roboto", system-ui, sans-serif;
  --radius-btn: 10px;
  --header-height: 72px;
  --header-height-scrolled: 62px;
  --content-max: 1200px;
}

.theme-dark {
  --color-page-bg: #050508;
  --color-card-bg: #0f172a;
  --color-text-title: #f8fafc;
  --color-text-body: #94a3b8;
  --color-border: rgba(255, 255, 255, 0.08);
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--color-page-bg);
  color: var(--color-text-body);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.band__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ——— Button Base ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: var(--radius-btn);
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  transition: opacity 0.15s ease, background-color 0.15s ease,
    border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.btn--primary {
  background: #2563eb;
  color: #ffffff;
  border: 1px solid #2563eb;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn--outline {
  background: transparent;
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
}

/* ——— Header ——— */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 400;
  will-change: transform;
  font-family: var(--font-heading);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);

  /* Persistent premium background */
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);

  /* Premium transition for hide/show and shrinking */
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* When classes are merged into the header tag, ensure background is full width */
.header.band__inner {
  max-width: 100% !important;
  margin: 0 !important;
  padding-left: max(24px, calc((100% - var(--content-max)) / 2)) !important;
  padding-right: max(24px, calc((100% - var(--content-max)) / 2)) !important;
}

.header.header--hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.header.header--scrolled {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: var(--header-height);
  transition: min-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  /* Removed padding here to rely on band__inner only and prevent double spacing */
}

.header.header--scrolled .header__inner {
  min-height: var(--header-height-scrolled);
}

.logo {
  display: flex;
  align-items: center;
  line-height: 0;
  flex-shrink: 0;
  position: relative;
  z-index: 420;
}

.logo img {
  width: 154px;
  height: auto;
  max-height: 34px;
  object-fit: contain;
  display: block;
}

.header__toggle {
  display: none;
  position: relative;
  z-index: 420;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #f1f5f9;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.header__toggle:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.header.header--scrolled .header__toggle {
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
}

.header__toggle-bars {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 18px;
}

.header__toggle-bar {
  display: block;
  height: 2px;
  width: 100%;
  border-radius: 1px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease;
  transform-origin: center;
}

.header__toggle[aria-expanded="true"] .header__toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header__toggle[aria-expanded="true"] .header__toggle-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.header__toggle[aria-expanded="true"] .header__toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.header__collapse {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
  position: relative;
  z-index: 350;
}

.header__panel {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-width: 0;
}

.nav-main {
  flex: 1;
  display: flex;
  justify-content: center;
  min-width: 0;
}

.nav-main__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2px 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-main__item {
  position: relative;
}

.nav-main__link,
.nav-main__trigger {
  color: rgba(248, 250, 252, 0.78);
}

.nav-main__link:hover,
.nav-main__link:focus-visible,
.nav-main__trigger:hover,
.nav-main__trigger:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  outline: none;
}

.header.header--scrolled .nav-main__link,
.header.header--scrolled .nav-main__trigger {
  color: rgba(226, 232, 240, 0.9);
}

.header.header--scrolled .nav-main__link:hover,
.header.header--scrolled .nav-main__link:focus-visible,
.header.header--scrolled .nav-main__link:hover,
.header.header--scrolled .nav-main__trigger:hover,
.header.header--scrolled .nav-main__trigger:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.nav-main__link {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  border-radius: 8px;
  transition: color 0.15s ease, background 0.15s ease;
}

.nav-main__trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 12px;
  margin: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease;
}

.header .nav-main__link.is-active,
.header .nav-main__trigger.is-active,
.header .nav-main__sublink.is-active {
  color: #3b82f6 !important;
  background: rgba(59, 130, 246, 0.12) !important;
  font-weight: 700 !important;
}

.nav-main__sublink.is-active {
  border-left: 3px solid #3b82f6;
  padding-left: 10px !important;
}

.nav-main__chevron {
  flex-shrink: 0;
  opacity: 0.75;
  transition: transform 0.2s ease;
}

.nav-main__sub {
  list-style: none;
  margin: 0;
  padding: 6px;
  min-width: 188px;
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease;
}

.nav-main__item--dropdown:hover .nav-main__sub,
.nav-main__item--dropdown:focus-within .nav-main__sub {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.nav-main__item--dropdown:hover .nav-main__chevron,
.nav-main__item--dropdown:focus-within .nav-main__chevron {
  transform: rotate(180deg);
}

.nav-main__sublink {
  display: block;
  padding: 9px 11px;
  font-size: 13px;
  font-weight: 500;
  color: #cbd5e1;
  text-decoration: none;
  border-radius: 8px;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav-main__sublink:hover,
.nav-main__sublink:focus-visible {
  color: #fff;
  background: rgba(59, 130, 246, 0.2);
  outline: none;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn--header {
  min-width: auto;
  min-height: 34px;
  padding: 7px 14px;
  font-size: 13px;
  border-radius: 999px;
}

.btn--header.btn--outline {
  color: rgba(248, 250, 252, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: transparent;
}

.btn--header.btn--outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  opacity: 1;
}

.btn--header.btn--primary {
  background: #2563eb;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn--header.btn--primary:hover {
  background: #1d4ed8;
  opacity: 1;
  transform: translateY(-1px);
}

.header.header--scrolled .btn--header.btn--outline {
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.25);
}

.header.header--scrolled .btn--header.btn--primary {
  box-shadow: 0 2px 12px rgba(37, 99, 235, 0.25);
}

@media (min-width: 992px) {
  .nav-main__sub {
    position: absolute;
    top: 100%;
    left: 50%;
    margin-top: 4px;
    transform: translate(-50%, -6px);
  }

  .nav-main__item--dropdown:hover .nav-main__sub,
  .nav-main__item--dropdown:focus-within .nav-main__sub,
  .nav-main__item--dropdown.dropdown--grace .nav-main__sub {
    transform: translate(-50%, 0);
  }

  .nav-main__item--dropdown.dropdown--grace .nav-main__sub {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-main__item--dropdown.dropdown--grace .nav-main__chevron {
    transform: rotate(180deg);
  }
}

@media (max-width: 991px) {
  .header__toggle {
    display: inline-flex;
  }

  .logo {
    z-index: 0;
  }

  .header__collapse {
    position: fixed;
    inset: 0;
    z-index: 360;
    flex: none;
    display: flex;
    justify-content: flex-end;
    align-items: stretch;
    padding: 0;
    min-height: 100vh;
    min-height: 100dvh;
    background: rgba(2, 6, 23, 0.55);
    backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.22s ease, visibility 0.22s ease;
  }

  .header__collapse.header__collapse--open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .header__panel {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    width: 60%;
    max-width: 70%;
    align-self: stretch;
    min-height: 100vh;
    min-height: 100dvh;
    height: 100%;
    margin: 0;
    padding: 24px 18px 28px;
    gap: 20px;
    background: linear-gradient(180deg, #0f172a 0%, #020617 100%);
    border-left: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: -16px 0 48px rgba(0, 0, 0, 0.45);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .header__collapse.header__collapse--open .header__panel {
    transform: translateX(0);
  }

  .nav-main {
    flex: 0;
    justify-content: flex-start;
  }

  .nav-main__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 30px;
  }

  .nav-main__link,
  .nav-main__trigger {
    width: 100%;
    justify-content: space-between;
    padding: 12px 10px;
    border-radius: 10px;
    font-size: 15px;
    color: rgba(248, 250, 252, 0.92);
  }

  .nav-main__link:hover,
  .nav-main__trigger:hover {
    background: rgba(255, 255, 255, 0.06);
  }

  .nav-main__sub {
    position: static;
    display: none;
    margin: 4px 0 10px;
    padding: 8px 10px 10px 12px;
    min-width: unset;
    background: rgba(15, 23, 42, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
    border-left: 2px solid rgba(59, 130, 246, 0.35);
  }

  .nav-main__item--dropdown.is-open .nav-main__sub {
    display: block;
  }

  .nav-main__item--dropdown:hover .nav-main__chevron,
  .nav-main__item--dropdown:focus-within .nav-main__chevron {
    transform: none;
  }

  .nav-main__item--dropdown.is-open .nav-main__chevron {
    transform: rotate(180deg);
  }

  .nav-main__sublink {
    padding: 10px 12px;
    color: #94a3b8;
  }

  .nav-main__sublink:hover {
    color: #fff;
  }

  .header__actions {
    flex-direction: column;
    align-items: stretch;
    padding-top: 12px;
    margin-top: auto;
    border-top: 1px solid rgba(148, 163, 184, 0.15);
    gap: 10px;
  }

  .header__actions .btn--header {
    width: 100%;
    min-height: 40px;
    justify-content: center;
    font-size: 14px;
  }
}

/* ——— Footer ——— */
.site-footer {
  position: relative;
  flex-shrink: 0;
  margin-top: auto;
  overflow: hidden;
  background: #020617;
  color: #94a3b8;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
  font-family: var(--font-heading);
  padding-top: 56px;
  padding-bottom: 32px;
}

/* When classes are merged into the footer tag, ensure background is full width */
.site-footer.band__inner {
  max-width: 100% !important;
  margin: 0 !important;
  padding-left: max(24px, calc((100% - var(--content-max)) / 2)) !important;
  padding-right: max(24px, calc((100% - var(--content-max)) / 2)) !important;
}

.site-footer__glow {
  position: absolute;
  top: 0;
  left: 50%;
  width: 80%;
  max-width: 800px;
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg,
      transparent,
      rgba(59, 130, 246, 0.6),
      rgba(251, 191, 36, 0.4),
      transparent);
  opacity: 1;
  z-index: 5;
  pointer-events: none;
}

.site-footer__inner {
  position: relative;
  z-index: 1;
}

.site-footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 2fr);
  gap: 48px 40px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.site-footer__brand {
  max-width: 260px;
}

.site-footer__logo {
  display: inline-block;
  line-height: 0;
  margin-bottom: 16px;
}

.site-footer__logo img {
  width: 148px;
  height: auto;
  max-height: 32px;
  object-fit: contain;
}

.site-footer__tagline {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: #94a3b8;
}

.site-footer__social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.site-footer__social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(148, 163, 184, 0.12);
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease,
    transform 0.15s ease;
}

.site-footer__social-link:hover {
  color: #f8fafc;
  background: rgba(59, 130, 246, 0.18);
  border-color: rgba(96, 165, 250, 0.35);
  transform: translateY(-1px);
}

.site-footer__social-link svg {
  flex-shrink: 0;
}

.site-footer__cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 32px;
  align-items: start;
}

.site-footer__heading {
  margin: 0 0 16px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #e2e8f0;
}

.site-footer__col .site-footer__heading {
  position: relative;
  margin: 0 0 12px;
  padding-bottom: 14px;
  border-bottom: none;
}

.site-footer__col .site-footer__heading::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40%;
  height: 1px;
  background: rgba(148, 163, 184, 0.22);
}

.site-footer__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer__col .site-footer__list {
  list-style: disc;
  padding-left: 1.2rem;
}

.site-footer__col .site-footer__list li::marker {
  color: #64748b;
}

.site-footer__list li {
  margin-bottom: 11px;
}

.site-footer__col .site-footer__list li {
  padding-left: 0.35rem;
}

.site-footer__list a {
  font-size: 14px;
  font-weight: 450;
  color: #94a3b8;
  text-decoration: none;
  transition: color 0.15s ease;
}

.site-footer__list a:hover {
  color: #f1f5f9;
}

.site-footer__spotlight {
  margin: 0;
  padding: 18px 18px 20px;
  max-width: 22rem;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(148, 163, 184, 0.14);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.site-footer__spotlight-title {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.35;
  color: #f1f5f9;
}

.site-footer__spotlight-text {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
  color: #94a3b8;
}

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding-top: 28px;
  width: 100%;
  text-align: center;
}

.site-footer__copy {
  margin: 0;
  font-size: 13px;
  color: #64748b;
  text-align: center;
}

@media (max-width: 900px) {
  .site-footer__top {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .site-footer__cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .site-footer__spotlight {
    grid-column: 1 / -1;
    max-width: none;
  }
}

@media (max-width: 520px) {
  .site-footer__cols {
    grid-template-columns: 1fr;
  }

  .site-footer__spotlight {
    grid-column: auto;
  }
}
