:root {
  --main-ink: #102f2b;
  --main-teal: #0c7c70;
  --main-mist: #e7efec;
  --main-paper: #f6f3e9;
}

.main-site-header {
  position: relative;
  grid-template-columns: minmax(210px, 244px) minmax(0, 1fr) auto;
  overflow: visible;
}

.main-nav-desktop {
  gap: clamp(13px, 1.35vw, 25px);
}

.main-nav-desktop > a,
.main-nav-desktop > .nav-cluster > a {
  white-space: nowrap;
}

.nav-cluster {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-cluster > a::before {
  content: "";
  position: absolute;
  top: 50%;
  right: -9px;
  width: 4px;
  height: 4px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: translateY(-70%) rotate(45deg);
  opacity: 0.55;
}

.nav-dropdown {
  position: absolute;
  z-index: 40;
  top: calc(100% + 14px);
  left: 50%;
  display: grid;
  min-width: 190px;
  padding: 10px;
  border: 1px solid rgba(16, 47, 43, 0.12);
  border-radius: 18px;
  background: rgba(249, 249, 243, 0.96);
  box-shadow: 0 24px 70px rgba(16, 47, 43, 0.16);
  backdrop-filter: blur(24px);
  transform: translate(-50%, 9px);
  visibility: hidden;
  opacity: 0;
  transition: opacity 180ms ease, transform 220ms ease, visibility 180ms ease;
}

.nav-dropdown::before {
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 18px;
}

.nav-dropdown a {
  padding: 10px 12px;
  border-radius: 11px;
  color: #244b45;
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
}

.nav-dropdown a::after {
  display: none;
}

.nav-dropdown-wide {
  grid-template-columns: repeat(2, minmax(190px, 1fr));
  min-width: 430px;
}

.nav-dropdown-right {
  right: -8px;
  left: auto;
  transform: translate(0, 9px);
}

.nav-dropdown a:hover,
.nav-dropdown a:focus-visible {
  color: var(--main-ink);
  background: rgba(104, 228, 207, 0.18);
}

.nav-cluster:hover .nav-dropdown,
.nav-cluster:focus-within .nav-dropdown {
  visibility: visible;
  opacity: 1;
  transform: translate(-50%, 0);
}

.nav-cluster:hover .nav-dropdown-right,
.nav-cluster:focus-within .nav-dropdown-right {
  transform: translate(0, 0);
}

.header-login {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 13px;
  border-radius: 999px;
  color: var(--main-ink);
  font-size: 12px;
  font-weight: 760;
  transition: background 180ms ease, transform 180ms ease;
}

.header-login:hover,
.header-login:focus-visible {
  background: rgba(255, 255, 255, 0.5);
  transform: translateY(-1px);
}

.main-site-header .header-cta {
  min-width: 62px;
  justify-content: center;
  padding: 0 16px;
}

.mobile-menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid rgba(16, 47, 43, 0.2);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.48);
}

.mobile-menu-toggle span {
  display: block;
  width: 16px;
  height: 1px;
  margin: 5px auto;
  background: currentColor;
  transition: transform 180ms ease;
}

.mobile-menu-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3px) rotate(45deg);
}

.mobile-menu-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3px) rotate(-45deg);
}

.mobile-main-menu {
  position: absolute;
  z-index: 60;
  top: calc(100% + 1px);
  right: 0;
  left: 0;
  padding: 18px;
  border: 1px solid rgba(16, 47, 43, 0.13);
  border-radius: 0 0 24px 24px;
  color: var(--main-ink);
  background: rgba(247, 248, 241, 0.97);
  box-shadow: 0 28px 75px rgba(16, 47, 43, 0.2);
  backdrop-filter: blur(26px);
  max-height: calc(100vh - 92px);
  overflow-y: auto;
}

.mobile-main-menu[hidden] {
  display: none;
}

.mobile-menu-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.mobile-menu-grid > div {
  display: grid;
  align-content: start;
  gap: 3px;
}

.mobile-menu-grid small {
  margin-bottom: 8px;
  color: #64817c;
  font-family: var(--display);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.mobile-menu-grid a {
  padding: 8px 9px;
  border-radius: 10px;
  color: var(--main-ink);
  font-size: 12px;
  font-weight: 650;
}

.mobile-menu-grid a:hover,
.mobile-menu-grid a:focus-visible {
  background: rgba(104, 228, 207, 0.18);
}

.main-site-footer {
  position: relative;
  z-index: 5;
  padding: 70px max(28px, calc((100% - 1496px) / 2)) 24px;
  color: #dfece8;
  background:
    radial-gradient(circle at 80% 20%, rgba(38, 140, 127, 0.2), transparent 30%),
    #0c2c29;
}

.main-footer-inner {
  display: grid;
  grid-template-columns: minmax(280px, 1.1fr) minmax(320px, 0.9fr) auto;
  gap: clamp(42px, 6vw, 92px);
  align-items: start;
  padding-bottom: 48px;
}

.footer-company {
  display: grid;
  justify-items: start;
  gap: 12px;
  max-width: 490px;
}

.footer-company img {
  width: min(260px, 76vw);
  filter: brightness(0) invert(1);
  opacity: 0.96;
}

.footer-company p {
  max-width: 440px;
  margin: 9px 0 3px;
  color: #a9c3bd;
  font-size: 13px;
  line-height: 1.8;
}

.footer-company a {
  color: #fff;
  font-family: var(--display);
  font-size: 18px;
  font-weight: 650;
}

.footer-company span {
  color: #a9c3bd;
  font-size: 12px;
  line-height: 1.7;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(135px, 1fr));
  gap: 34px;
}

.footer-links > div {
  display: grid;
  align-content: start;
  gap: 4px;
}

.footer-links small {
  margin-bottom: 13px;
  color: #71958d;
  font-family: var(--display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.footer-links a {
  padding: 7px 0;
  color: #dfece8;
  font-size: 12px;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: #80ead6;
}

.footer-qr {
  display: flex;
  gap: 14px;
}

.footer-qr figure {
  margin: 0;
  text-align: center;
}

.footer-qr img {
  display: block;
  width: 84px;
  height: 84px;
  padding: 4px;
  border-radius: 12px;
  object-fit: contain;
  background: #fff;
}

.footer-qr figcaption {
  margin-top: 8px;
  color: #8faea7;
  font-size: 10px;
}

.main-footer-legal {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(226, 242, 237, 0.12);
  color: #71958d;
  font-size: 11px;
}

.main-footer-legal a {
  color: inherit;
}

@media (max-width: 1380px) {
  .main-site-header {
    grid-template-columns: 210px minmax(0, 1fr) auto;
    gap: 18px;
  }

  .main-site-header .formal-brand-logo {
    width: 206px;
  }

  .main-nav-desktop {
    gap: 13px;
  }

  .main-nav-desktop a {
    font-size: 12px;
  }

  .main-site-header .sound-label {
    display: none;
  }
}

@media (max-width: 1320px) {
  .main-nav-desktop,
  .main-site-header .sound-toggle {
    display: none;
  }

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

  .main-site-header {
    grid-template-columns: 210px minmax(0, 1fr) auto;
  }

  .mobile-menu-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 1050px) {
  .main-footer-inner {
    grid-template-columns: 1fr 1fr;
  }

  .footer-qr {
    grid-column: 1 / -1;
  }
}

@media (max-width: 900px) {
  .main-site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
  }

  .main-site-header .header-actions {
    gap: 5px;
  }

  .main-site-header .header-login {
    min-height: 38px;
    padding: 0 9px;
    font-size: 11px;
  }

  .main-site-header .header-cta {
    min-width: 52px;
    min-height: 38px;
    padding: 0 11px;
  }

  .mobile-menu-toggle {
    width: 38px;
    height: 38px;
  }

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

  .main-footer-inner {
    grid-template-columns: 1fr;
    gap: 38px;
  }

  .footer-qr {
    grid-column: auto;
  }
}

@media (max-width: 620px) {
  .main-site-header .formal-brand-logo {
    width: min(150px, 38vw);
  }

  .main-site-header .header-login {
    padding: 0 6px;
  }

  .main-site-header .header-cta {
    min-width: 46px;
    padding: 0 8px;
  }

  .mobile-main-menu {
    right: -2px;
    left: -2px;
    max-height: min(74vh, 620px);
    overflow-y: auto;
    padding: 16px 13px 20px;
  }

  .mobile-menu-grid {
    gap: 15px 9px;
  }

  .mobile-menu-grid a {
    padding: 7px;
    font-size: 11px;
  }

  .main-site-footer {
    padding: 54px 18px 22px;
  }

  .footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
  }

  .footer-qr {
    gap: 9px;
    overflow-x: auto;
  }

  .footer-qr img {
    width: 76px;
    height: 76px;
  }

  .main-footer-legal {
    display: grid;
    justify-content: start;
  }
}

@media (max-width: 370px) {
  .main-site-header .header-login {
    display: none;
  }
}
