/* CMPROM mobile/tablet premium correction layer */
html, body {
  max-width: 100%;
  overflow-x: hidden;
}

img, svg, video, canvas {
  max-width: 100%;
}

.section.invert,
.module-hero,
.page-hero,
.hero {
  color: #edf3ff;
}

.section.invert h1,
.section.invert h2,
.section.invert h3,
.section.invert h4,
.section.invert .section-title,
.section.invert .display-1,
.section.invert .display-2,
.section.invert .display-3,
.section.invert .display-4 {
  color: #ffffff !important;
  opacity: 1 !important;
}

.section.invert p,
.section.invert li,
.section.invert .lead-soft,
.section.invert .section-sub,
.section.invert .rich-content,
.section.invert .rich-content p,
.module-hero p,
.page-hero p {
  color: #d9e4f6 !important;
  opacity: 1 !important;
}

.section.invert .eyebrow {
  color: #ffffff !important;
}

.rich-content,
.post-body,
.feature-card,
.project-card,
.module-card,
.service-depth,
.service-proof-card {
  overflow-wrap: break-word;
  word-break: normal;
}

@media (max-width: 1199px) {
  body {
    background: #070b13;
  }

  .site-header {
    z-index: 2000 !important;
  }

  .navbar {
    background: linear-gradient(135deg, rgba(6,10,18,.98), rgba(10,26,55,.98)) !important;
    border-bottom: 1px solid rgba(255,255,255,.10) !important;
    padding: .82rem 0 !important;
  }

  .nav-shell {
    min-height: 64px !important;
    align-items: center !important;
  }

  .brand-logo {
    height: 40px !important;
    max-width: min(56vw, 210px) !important;
    object-fit: contain !important;
  }

  .navbar-toggler {
    width: 58px !important;
    height: 52px !important;
    display: inline-grid !important;
    place-items: center !important;
    border-radius: 14px !important;
    border: 1px solid rgba(255,255,255,.28) !important;
    background: rgba(255,255,255,.055) !important;
    box-shadow: none !important;
  }

  .navbar-collapse.show,
  .navbar-collapse.collapsing {
    position: fixed !important;
    left: 14px !important;
    right: 14px !important;
    top: 86px !important;
    z-index: 2100 !important;
    max-height: calc(100dvh - 108px) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    padding: .8rem !important;
    border-radius: 18px !important;
    border: 1px solid rgba(255,255,255,.13) !important;
    background:
      radial-gradient(90% 70% at 100% 0%, rgba(226,29,47,.18), transparent 42%),
      linear-gradient(180deg, #081020, #060a12) !important;
    box-shadow: 0 30px 90px rgba(0,0,0,.55) !important;
  }

  .navbar-nav {
    display: grid !important;
    gap: .55rem !important;
    width: 100% !important;
  }

  .navbar-nav .nav-item {
    width: 100% !important;
  }

  .navbar-nav .nav-link {
    width: 100% !important;
    min-height: 48px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: .76rem .9rem !important;
    border-radius: 14px !important;
    color: #f4f7ff !important;
    background: rgba(255,255,255,.065) !important;
    border: 1px solid rgba(255,255,255,.11) !important;
    font-size: 1rem !important;
    line-height: 1.2 !important;
    font-weight: 800 !important;
  }

  .navbar-nav .nav-link.show,
  .navbar-nav .nav-link:focus,
  .navbar-nav .nav-link:hover {
    color: #fff !important;
    background: linear-gradient(135deg, rgba(226,29,47,.26), rgba(39,95,190,.15)) !important;
    border-color: rgba(255,255,255,.20) !important;
  }

  .navbar-collapse .dropdown-menu,
  .navbar-collapse .dropdown-menu.show,
  .navbar-collapse .mega-menu,
  .navbar-collapse .mega-menu.show,
  .navbar-collapse .mega-menu--wide,
  .navbar-collapse .mega-menu--company {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    max-height: none !important;
    margin: .48rem 0 .75rem !important;
    padding: .55rem !important;
    border-radius: 16px !important;
    border: 1px solid rgba(255,255,255,.12) !important;
    background: rgba(255,255,255,.045) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06) !important;
    overflow: visible !important;
    color: #fff !important;
  }

  .mega-menu__layout,
  .mega-menu__content,
  .mega-menu__grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: .5rem !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  /* On mobile the dropdown must be tabs, not a text-heavy sales card. */
  .mega-menu__intro,
  .mega-menu__promo,
  .mega-menu__trust {
    display: none !important;
  }

  .mega-link {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    display: grid !important;
    grid-template-columns: 38px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: .72rem !important;
    padding: .72rem .78rem !important;
    border-radius: 14px !important;
    color: #fff !important;
    background: linear-gradient(135deg, rgba(255,255,255,.09), rgba(255,255,255,.045)) !important;
    border: 1px solid rgba(255,255,255,.12) !important;
    box-shadow: none !important;
    text-decoration: none !important;
  }

  .mega-link__icon {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 12px !important;
    color: #fff !important;
    background: linear-gradient(135deg, #e21d2f, #6b1018) !important;
  }

  .mega-link__copy {
    min-width: 0 !important;
    display: block !important;
  }

  .mega-link__copy strong {
    display: block !important;
    margin: 0 0 .12rem !important;
    color: #fff !important;
    font-size: .96rem !important;
    line-height: 1.18 !important;
    font-weight: 900 !important;
    letter-spacing: 0 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    word-break: normal !important;
  }

  .mega-link__copy small {
    display: none !important;
    margin: 0 !important;
    color: #b8c7e4 !important;
    font-size: .78rem !important;
    line-height: 1.35 !important;
    white-space: normal !important;
    overflow-wrap: anywhere !important;
    word-break: normal !important;
  }

  .nav-actions {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: .55rem !important;
    margin: .75rem 0 0 !important;
    padding-top: .75rem !important;
    border-top: 1px solid rgba(255,255,255,.10) !important;
  }

  .nav-actions .btn,
  .account-menu,
  .account-menu__button {
    width: 100% !important;
  }

  .lang-switch {
    width: max-content !important;
  }
}

@media (max-width: 767px) {
  .container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  body.is-home .hero {
    padding-top: 8.4rem !important;
    padding-bottom: 3rem !important;
    min-height: auto !important;
  }

  .hero-emblem,
  .hero-arc {
    display: none !important;
  }

  .hero__title {
    max-width: 12ch !important;
    font-size: clamp(2.15rem, 11vw, 3rem) !important;
    line-height: 1.02 !important;
    letter-spacing: 0 !important;
  }

  .hero__sub {
    max-width: 33ch !important;
    font-size: 1rem !important;
    line-height: 1.56 !important;
  }

  .hero__actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    max-width: 290px !important;
  }

  .hero__actions .btn,
  .footer-cta__actions .btn {
    width: 100% !important;
  }

  .section,
  .module-band {
    padding: 3rem 0 !important;
  }

  .section.invert {
    background: linear-gradient(180deg, #070c15, #0b1322) !important;
  }

  .section.invert .section-title,
  .section.invert h2 {
    font-size: clamp(1.9rem, 9vw, 2.45rem) !important;
    line-height: 1.08 !important;
  }

  .section.invert p,
  .section.invert .lead-soft,
  .section.invert .section-sub {
    font-size: 1rem !important;
    line-height: 1.62 !important;
  }

  .page-hero,
  .module-hero {
    padding: 7rem 0 3rem !important;
  }

  .section-title,
  .module-hero .display-4,
  .page-hero__title {
    font-size: clamp(1.8rem, 9vw, 2.35rem) !important;
    line-height: 1.04 !important;
  }

  .feature-card,
  .module-card,
  .form-card,
  .portal-panel,
  .service-premium-intro,
  .service-depth,
  .service-proof-card {
    border-radius: 16px !important;
    padding: 1.05rem !important;
  }

  .feature-card h3,
  .project-card__title,
  .module-card h3,
  .service-proof-card h3 {
    font-size: 1.08rem !important;
    line-height: 1.24 !important;
  }

  .feature-card p,
  .module-card p,
  .project-card__sum,
  .post-body p,
  .rich-content p,
  .service-depth p,
  .service-proof-card p {
    font-size: .98rem !important;
    line-height: 1.58 !important;
  }

  .check-list li,
  .process-step {
    align-items: flex-start !important;
  }

  .check-list li span,
  .process-step p {
    min-width: 0 !important;
  }
}

@media (max-width: 420px) {
  .brand-logo {
    max-width: 46vw !important;
  }

  .navbar-toggler {
    width: 54px !important;
    height: 48px !important;
  }

  .navbar-collapse.show,
  .navbar-collapse.collapsing {
    left: 10px !important;
    right: 10px !important;
    top: 82px !important;
    border-radius: 16px !important;
  }

  .hero__title,
  .page-hero__title,
  .section-title,
  .module-hero .display-4 {
    font-size: clamp(1.85rem, 10vw, 2.45rem) !important;
  }

  .hero__sub,
  .page-hero__sub,
  .lead-soft,
  .section-sub {
    font-size: .98rem !important;
  }
}

/* Final mobile readability guard for public/legal/about/contact/resources/support. */
@media (max-width: 1199px) {
  .public-readable-section,
  .legal-content-section,
  .about-mission-section,
  .about-enterprise-section,
  .contact-premium-section,
  .resources-premium-section,
  .support-public-section {
    background: #ffffff !important;
    color: #15171b !important;
  }

  .public-readable-section h1,
  .public-readable-section h2,
  .public-readable-section h3,
  .legal-content-section h1,
  .legal-content-section h2,
  .legal-content-section h3,
  .about-mission-section h1,
  .about-mission-section h2,
  .about-mission-section h3,
  .about-enterprise-section h1,
  .about-enterprise-section h2,
  .about-enterprise-section h3,
  .contact-premium-section h1,
  .contact-premium-section h2,
  .contact-premium-section h3,
  .resources-premium-section h1,
  .resources-premium-section h2,
  .resources-premium-section h3,
  .support-public-section h1,
  .support-public-section h2,
  .support-public-section h3 {
    color: #101317 !important;
    opacity: 1 !important;
  }

  .public-readable-section p,
  .public-readable-section li,
  .public-readable-section .lead-soft,
  .legal-content-section p,
  .legal-content-section li,
  .legal-content-section .post-body,
  .legal-content-section .post-body p,
  .legal-content-section .post-body li,
  .about-mission-section p,
  .about-mission-section .lead-soft,
  .about-enterprise-section p,
  .about-enterprise-section .lead-soft,
  .contact-premium-section p,
  .contact-premium-section li,
  .resources-premium-section p,
  .resources-premium-section li,
  .support-public-section p,
  .support-public-section li {
    color: #3f4856 !important;
    opacity: 1 !important;
  }

  .legal-content-section .post-body,
  .contact-info-panel,
  .about-capability-card,
  .resource-category-card,
  .resource-card-premium,
  .support-ticket-form,
  .support-ticket-list {
    background: #ffffff !important;
    color: #15171b !important;
  }
}
