/* ========================================================
   AASC / SHARED LAYOUT: HEADER, DRAWER & FOOTER
   Modern, responsive, glassmorphism layout components.
   ======================================================== */

app-header {
  display: block;
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
}

app-footer {
  display: block;
  width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
  background: rgba(244, 245, 242, 0.85);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid rgba(18, 35, 43, 0.08);
  box-shadow: none;
  transition:
    background 0.25s ease,
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.site-header.scrolled,
.site-header.menu-open {
  background: rgba(244, 245, 242, 0.94);
  border-bottom-color: transparent;
  box-shadow:
    0 6px 20px -3px rgba(18, 35, 43, 0.08),
    0 3px 8px -2px rgba(18, 35, 43, 0.04);
}

.header-inner {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 18px;
}

.site-header .nav {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: none;
  padding: 0;
}

.site-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--ink);
  flex-shrink: 0;
  transition: opacity 0.18s ease;
}

.site-header .brand:hover {
  opacity: 0.88;
}

.site-header .mark {
  width: 52px;
  height: 52px;
  background: transparent;
  border: none;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: none;
}

.site-header .mark-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: scale(1.35);
  display: block;
}

.site-header .brand-title {
  display: block;
  font: 700 19.5px/1.15 var(--font-display);
  letter-spacing: -0.035em;
  color: var(--ink);
}

.site-header .brand-sub {
  display: block;
  font: 700 11px/1.2 var(--font-body);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--blue);
  margin-top: 2px;
}

/* Desktop Navigation Links */
.site-header .navlinks {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  border-top: none;
}

.site-header .navlinks a {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  font: 600 13px/1.2 var(--font-body);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #334155;
  text-decoration: none;
  background: transparent;
  transition: color 0.2s ease;
  white-space: nowrap;
  min-height: auto;
}

.site-header .navlinks a::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 14px;
  right: 14px;
  height: 1px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: center;
  opacity: 0;
  transition:
    transform 0.15s ease-out,
    opacity 0.12s ease-out;
}

.site-header .navlinks a:hover {
  color: var(--blue);
  background: transparent;
}

.site-header .navlinks a:hover::after {
  transform: scaleX(1);
  opacity: 1;
  transition:
    transform 0.2s cubic-bezier(0.16, 1, 0.3, 1) 0.04s,
    opacity 0.16s ease 0.04s;
}

.site-header .navlinks a:focus-visible::after,
.site-header .navlinks a.active::after {
  transform: scaleX(1);
  opacity: 1;
  transition:
    transform 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.18s ease;
}

.site-header .navlinks:hover a.active:not(:hover)::after {
  transform: scaleX(0);
  opacity: 0;
}

.site-header .navlinks a.active {
  color: var(--blue);
  font-weight: 600;
}

/* Action Buttons (Login & CTA) */
.site-header .nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.site-header .nav-login {
  font: 600 14.5px/1 var(--font-body);
  color: var(--ink);
  padding: 12px 22px;
  border: 1px solid rgba(18, 35, 43, 0.18);
  border-radius: 8px;
  background: transparent;
  text-decoration: none;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: none !important;
  transition:
    background-color 0.18s ease,
    color 0.18s ease,
    border-color 0.18s ease;
}

.site-header .nav-login:hover {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  box-shadow: none !important;
}

.site-header .navcta {
  background: var(--blue);
  color: #fff;
  border: 1px solid var(--blue);
  border-radius: 8px;
  padding: 12px 22px;
  font: 700 14.5px/1 var(--font-body);
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  cursor: pointer;
  box-shadow: none !important;
  white-space: nowrap;
  min-height: auto;
  transition:
    background-color 0.18s ease,
    border-color 0.18s ease;
}

.site-header .navcta:hover {
  background: var(--blue2);
  border-color: var(--blue2);
  color: #fff;
  transform: none;
  box-shadow: none !important;
}

/* Hamburger Toggle Button */
.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  padding: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: none;
  outline: none;
}

.nav-toggle:hover,
.nav-toggle:active,
.nav-toggle.open {
  background: transparent;
  border: none;
  box-shadow: none;
}

.nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition:
    transform 0.25s ease,
    opacity 0.2s ease;
  transform-origin: center;
}

.nav-toggle.open .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.nav-toggle.open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Glass Drawer */
.mobile-drawer {
  display: none;
  width: 100%;
  max-height: calc(100dvh - 70px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-top: 1px solid rgba(18, 35, 43, 0.06);
  box-shadow: none;
}

.mobile-drawer.open {
  display: block;
  animation: mobileDrawerSlide 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes mobileDrawerSlide {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-drawer-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 16px 20px 22px;
}

.mobile-navlinks {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 18px;
}

.mobile-navlink {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 4px;
  border-radius: 0;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(18, 35, 43, 0.07);
  text-decoration: none;
  color: var(--ink);
  transition: color 0.18s ease;
}

.mobile-navlink:last-child {
  border-bottom: none;
}

.mobile-navlink:hover,
.mobile-navlink:active,
.mobile-navlink.active {
  background: transparent;
  transform: none;
  color: var(--blue);
}

.mobile-navlink:hover .mnav-text strong,
.mobile-navlink.active .mnav-text strong {
  color: var(--blue);
}

.mobile-navlink.active .mnav-text strong::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
  margin-left: 8px;
  vertical-align: middle;
  box-shadow: 0 0 0 3px rgba(8, 117, 166, 0.18);
}

.mobile-navlink.active .mnav-icon {
  color: var(--blue);
}

.mnav-icon {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--blue);
  transition:
    transform 0.2s ease,
    color 0.2s ease;
}

.mnav-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  display: block;
}

.mnav-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.mnav-text strong {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  transition: color 0.18s ease;
}

.mnav-text small {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 2px;
}

.mnav-arrow {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  transition:
    color 0.18s ease,
    transform 0.18s ease;
  flex-shrink: 0;
}

.mnav-arrow svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  display: block;
}

.mobile-navlink:hover .mnav-arrow,
.mobile-navlink.active .mnav-arrow {
  color: var(--blue);
  transform: translateX(3px);
}

.mobile-drawer-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding-top: 16px;
  border-top: 1px solid rgba(18, 35, 43, 0.08);
}

.mobile-btn-login {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 18px;
  border-radius: 8px;
  background: transparent;
  border: 1px solid rgba(18, 35, 43, 0.18);
  font: 700 13.5px var(--font-body);
  color: var(--ink);
  text-decoration: none;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.mobile-btn-login:hover {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.mobile-btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 18px;
  border-radius: 8px;
  background: var(--blue);
  border: 1px solid var(--blue);
  font: 700 13.5px var(--font-body);
  color: #fff;
  text-decoration: none;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.mobile-btn-cta:hover {
  background: var(--blue2);
  border-color: var(--blue2);
}

/* ========================================================
   SHARED FOOTER STYLES
   ======================================================== */
footer.site-footer {
  width: 100%;
  margin-top: clamp(64px, 5vw + 40px, 100px);
  background: #0b2233;
  border-top: none;
  border-radius: 0;
  padding: 56px 0 max(32px, env(safe-area-inset-bottom, 32px));
  display: block;
}

footer.site-footer .footer-inner {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 18px;
  box-sizing: border-box;
}

footer.site-footer .footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.85fr 1.45fr;
  gap: clamp(28px, 3.5vw, 52px);
  align-items: stretch;
}

footer.site-footer .brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  padding: 0;
}

footer.site-footer .mark {
  width: 52px;
  height: 52px;
  background: transparent;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
}

footer.site-footer .mark-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: scale(1.35);
}

footer.site-footer .brand-title {
  display: block;
  font: 700 19.5px/1.15 var(--font-display);
  letter-spacing: -0.035em;
  color: #fff;
}

footer.site-footer .brand-sub {
  display: block;
  font: 700 11px/1.2 var(--font-body);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--blue);
  margin-top: 2px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-brand p {
  margin: 0;
  font: 400 14.5px/1.65 var(--font-body);
  color: rgba(255, 255, 255, 0.6);
  letter-spacing: -0.01em;
  max-width: 380px;
}

.footer-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  font: 600 10.5px/1.2 var(--font-display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 5px 10px;
  border-radius: 5px;
  user-select: none;
}

.footer-col h3,
.footer-col h4 {
  margin: 0 0 16px;
  font: 700 13px/1.2 var(--font-display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.footer-links a {
  font: 500 13.5px/1.4 var(--font-body);
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: var(--blue);
  text-decoration: none;
}

.footer-map-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.footer-map-head h3,
.footer-map-head h4 {
  margin: 0;
  font: 700 13px/1.2 var(--font-display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.92);
}

.footer-map-link {
  font: 600 12px/1.2 var(--font-display);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--blue);
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.footer-map-link:hover {
  opacity: 0.8;
  text-decoration: none;
}

.footer-col-map {
  display: flex;
  flex-direction: column;
}

.footer-map-frame {
  width: 100%;
  flex: 1 1 0;
  min-height: 140px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #0d2b40;
}

.footer-map-frame iframe {
  width: 100%;
  height: 100%;
  min-height: 140px;
  border: 0;
  display: block;
}

.footer-sub {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font: 500 12px/1 var(--font-body);
  color: rgba(255, 255, 255, 0.4);
}

.footer-sub span {
  display: block;
}

.footer-tagline {
  color: rgba(255, 255, 255, 0.35);
}

/* ========================================================
   RESPONSIVE LAYOUT
   ======================================================== */
@media (max-width: 980px) {
  .site-header .navlinks {
    display: none !important;
  }
  .site-header .navcta {
    display: none !important;
  }
  .nav-toggle {
    display: flex !important;
  }
  footer.site-footer .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  footer.site-footer .footer-brand {
    grid-column: span 2;
  }
  footer.site-footer .footer-col-map {
    grid-column: span 2;
  }
  footer.site-footer .footer-map-frame {
    flex: none;
    height: 190px;
  }
  footer.site-footer .footer-sub {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
  }
  footer.site-footer .footer-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 20px;
  }
}

@media (max-width: 560px) {
  .header-inner,
  footer.site-footer .footer-inner {
    padding: 0 16px;
  }
  .site-header .nav {
    min-height: 74px;
    gap: 12px;
  }
  .site-header .brand {
    gap: 12px;
  }
  .site-header .mark {
    width: 48px;
    height: 48px;
  }
  .site-header .brand-title {
    font-size: 19px;
  }
  .site-header .brand-sub {
    font-size: 11px;
    letter-spacing: 0.13em;
  }
  .site-header .nav-login {
    display: none !important;
  }
  .mobile-drawer-inner {
    padding: 12px 16px 20px;
  }
  .mobile-drawer-footer {
    grid-template-columns: 1fr;
  }
}

/* ========================================================
   PRINT STYLES
   ======================================================== */
@media print {
  app-header,
  app-footer,
  .site-header,
  footer.site-footer {
    display: none !important;
  }
}
