:root {
  --egl-navy: #07111f;
  --egl-blue: #00a2fd;
  --egl-border: #dce5ed;
  --egl-text: #111827;
  --egl-muted: #5b6573;
}

*, *::before, *::after { box-sizing: border-box; }
html { overflow-x: clip; -webkit-text-size-adjust: 100%; }
body { min-width: 0; overflow-x: clip; }
img, svg, video, canvas { max-width: 100%; }
button, input, select, textarea { font: inherit; }
a, button { touch-action: manipulation; }
[data-screen-label] { width: 100%; min-width: 0 !important; overflow-x: clip; }
[data-screen-label] h1,
[data-screen-label] h2,
[data-screen-label] h3 { overflow-wrap: anywhere; text-wrap: balance; }
[data-screen-label] p,
[data-screen-label] li { text-wrap: pretty; }
[data-screen-label] input,
[data-screen-label] select,
[data-screen-label] textarea { min-width: 0; max-width: 100%; }
[data-screen-label] a[style*="display: inline-flex"],
[data-screen-label] button { min-height: 44px; }

.egl-menu-toggle,
.egl-mobile-panel { display: none; }

@media (max-width: 1023px) {
  .egl-desktop-nav,
  .egl-desktop-cta { display: none !important; }
  .egl-menu-toggle {
    min-width: 88px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 14px;
    border: 1px solid var(--egl-border);
    border-radius: 8px;
    color: var(--egl-text);
    background: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
  }
  .egl-menu-icon { width: 18px; display: inline-grid; gap: 4px; }
  .egl-menu-icon span { width: 18px; height: 2px; display: block; background: var(--egl-navy); border-radius: 2px; }
  .egl-header-main { padding: 12px 24px !important; flex-wrap: nowrap !important; }
  .egl-header-logo img { height: 42px !important; }
  .egl-mobile-panel {
    display: grid;
    gap: 2px;
    max-width: 1240px;
    margin: 0 auto;
    padding: 8px 24px 24px;
    border-top: 1px solid var(--egl-border);
    background: #fff;
  }
  .egl-mobile-panel > a,
  .egl-mobile-section-label {
    min-height: 46px;
    display: flex;
    align-items: center;
    padding: 11px 12px;
    color: var(--egl-text);
    border-radius: 7px;
    font-size: 15px;
    font-weight: 700;
  }
  .egl-mobile-services { display: grid; gap: 2px; padding: 4px 0 8px; }
  .egl-mobile-section-label { min-height: 38px; color: var(--egl-muted); font-family: 'IBM Plex Mono', monospace; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
  .egl-mobile-services a {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px 8px 18px;
    color: var(--egl-text);
    border-radius: 7px;
    font-size: 14px;
    font-weight: 600;
  }
  .egl-mobile-services a > span:first-child { width: 30px; color: #3881b7; font-family: 'IBM Plex Mono', monospace; font-size: 11px; }
  .egl-mobile-services .egl-mobile-all-services { color: #3881b7; }
  .egl-mobile-quote { justify-content: space-between; margin-top: 8px; color: var(--egl-navy) !important; background: var(--egl-blue); }

  [data-screen-label] [style*="max-width: 1240px"],
  [data-screen-label] [style*="max-width: 1200px"],
  [data-screen-label] [style*="max-width: 1180px"],
  [data-screen-label] [style*="max-width: 1120px"] { padding-left: 24px !important; padding-right: 24px !important; }
  [data-screen-label] [style*="grid-template-columns: repeat(4"],
  [data-screen-label] [style*="grid-template-columns: repeat(6"] { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
  [data-screen-label] [style*="grid-template-columns: repeat(3"],
  [data-screen-label] [style*="grid-template-columns: 1fr 1fr 1fr"] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  [data-screen-label] [style*="grid-template-columns: 220px 1fr auto"] { grid-template-columns: 160px minmax(0, 1fr) auto !important; }
  [data-screen-label] [style*="grid-template-columns: 1.15fr 0.85fr"],
  [data-screen-label] [style*="grid-template-columns: 1.1fr 0.9fr"],
  [data-screen-label] [style*="grid-template-columns: 0.95fr 1.05fr"],
  [data-screen-label] [style*="grid-template-columns: 0.9fr 1.1fr"] { gap: 36px !important; }
  [data-screen-label] h1[style*="font-size: 56px"],
  [data-screen-label] h1[style*="font-size: 52px"],
  [data-screen-label] h1[style*="font-size: 48px"],
  [data-screen-label] h1[style*="font-size: 46px"] { font-size: clamp(38px, 5vw, 48px) !important; }

  footer > div[style*="grid-template-columns"] { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 40px !important; padding-left: 24px !important; padding-right: 24px !important; }
}

@media (max-width: 850px) {
  [data-screen-label] [style*="grid-template-columns: 1.15fr 0.85fr"],
  [data-screen-label] [style*="grid-template-columns: 1.1fr 0.9fr"],
  [data-screen-label] [style*="grid-template-columns: 0.95fr 1.05fr"],
  [data-screen-label] [style*="grid-template-columns: 0.9fr 1.1fr"] { grid-template-columns: minmax(0, 1fr) !important; gap: 34px !important; }
  [data-screen-label] [style*="height: 460px"],
  [data-screen-label] [style*="height: 440px"],
  [data-screen-label] [style*="height: 420px"],
  [data-screen-label] [style*="height: 400px"] { height: 360px !important; }
}

@media (max-width: 767px) {
  .egl-topbar { display: none; }
  .egl-header-main { padding: 10px max(16px, env(safe-area-inset-right)) 10px max(16px, env(safe-area-inset-left)) !important; }
  .egl-header-logo img { height: 38px !important; }
  .egl-menu-toggle { min-width: 80px; padding: 9px 11px; }
  .egl-mobile-panel { max-height: calc(100dvh - 64px); overflow-y: auto; padding: 8px max(16px, env(safe-area-inset-right)) calc(20px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); }

  [data-screen-label] [style*="max-width: 1240px"],
  [data-screen-label] [style*="max-width: 1200px"],
  [data-screen-label] [style*="max-width: 1180px"],
  [data-screen-label] [style*="max-width: 1120px"],
  [data-screen-label] [style*="max-width: 900px"],
  [data-screen-label] [style*="max-width: 820px"],
  [data-screen-label] [style*="max-width: 760px"] { padding-left: max(18px, env(safe-area-inset-left)) !important; padding-right: max(18px, env(safe-area-inset-right)) !important; }

  [data-screen-label] [style*="grid-template-columns: repeat(4"],
  [data-screen-label] [style*="grid-template-columns: repeat(6"],
  [data-screen-label] [style*="grid-template-columns: repeat(3"],
  [data-screen-label] [style*="grid-template-columns: repeat(2"],
  [data-screen-label] [style*="grid-template-columns: 1fr 1fr 1fr"],
  [data-screen-label] [style*="grid-template-columns: 1.15fr 0.85fr"],
  [data-screen-label] [style*="grid-template-columns: 1.1fr 0.9fr"],
  [data-screen-label] [style*="grid-template-columns: 0.95fr 1.05fr"],
  [data-screen-label] [style*="grid-template-columns: 0.9fr 1.1fr"],
  [data-screen-label] [style*="grid-template-columns: 1fr 1fr"],
  [data-screen-label] [style*="grid-template-columns: 220px 1fr"],
  [data-screen-label] [style*="grid-template-columns: 220px 1fr auto"],
  [data-screen-label] [style*="grid-template-columns: minmax(260px,1.3fr) 1fr 1fr 1.2fr"] { grid-template-columns: minmax(0, 1fr) !important; }

  [data-screen-label] [style*="display: grid"][style*="grid-template-columns"] { gap: 24px !important; }
  [data-screen-label] .egl-quote-progress { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 6px !important; }
  [data-screen-label] .egl-comparison-table { overflow-x: auto !important; -webkit-overflow-scrolling: touch; }
  [data-screen-label] .egl-comparison-table > div { min-width: 620px; }

  [data-screen-label] [style*="grid-column: span 3"],
  [data-screen-label] [style*="grid-column: span 2"] { grid-column: 1 !important; }

  [data-screen-label] [style*="padding: 96px 32px"] { padding: 58px 18px !important; }
  [data-screen-label] [style*="padding: 88px 32px"] { padding: 56px 18px !important; }
  [data-screen-label] [style*="padding: 80px 32px"] { padding: 52px 18px !important; }
  [data-screen-label] [style*="padding: 72px 32px"] { padding: 48px 18px !important; }
  [data-screen-label] [style*="padding: 64px 32px"] { padding: 44px 18px !important; }
  [data-screen-label] [style*="padding: 56px 32px"] { padding: 40px 18px !important; }
  [data-screen-label] [style*="padding: 48px 32px"] { padding: 36px 18px !important; }
  [data-screen-label] [style*="padding: 96px 32px 104px"] { padding: 58px 18px 64px !important; }
  [data-screen-label] [style*="padding: 112px 32px"] { padding: 72px 18px !important; }
  [data-screen-label] [style*="padding: 38px 40px"] { padding: 26px 20px !important; }
  [data-screen-label] [style*="padding: 32px 36px"] { padding: 24px 20px !important; }
  [data-screen-label] [style*="padding: 28px 30px"] { padding: 24px 20px !important; }

  [data-screen-label] h1[style*="font-size: 56px"],
  [data-screen-label] h1[style*="font-size: 52px"],
  [data-screen-label] h1[style*="font-size: 48px"],
  [data-screen-label] h1[style*="font-size: 46px"],
  [data-screen-label] h1[style*="font-size: 44px"] { font-size: clamp(32px, 10vw, 42px) !important; line-height: 1.08 !important; }
  [data-screen-label] h2[style*="font-size: 42px"],
  [data-screen-label] h2[style*="font-size: 40px"],
  [data-screen-label] h2[style*="font-size: 38px"],
  [data-screen-label] h2[style*="font-size: 36px"] { font-size: clamp(27px, 8vw, 34px) !important; line-height: 1.15 !important; }

  [data-screen-label] [style*="height: 440px"] { height: 300px !important; }
  [data-screen-label] [style*="height: 460px"] { height: 300px !important; }
  [data-screen-label] [style*="height: 420px"],
  [data-screen-label] [style*="height: 400px"],
  [data-screen-label] [style*="height: 380px"] { height: 270px !important; }
  [data-screen-label] [style*="height: 360px"],
  [data-screen-label] [style*="height: 340px"],
  [data-screen-label] [style*="height: 320px"],
  [data-screen-label] [style*="height: 300px"] { height: 240px !important; }
  [data-screen-label] [style*="left: -28px"] { left: 16px !important; right: 16px !important; }

  [data-screen-label] div[style*="flex-wrap: wrap"] > a[style*="display: inline-flex"] { flex: 1 1 100% !important; justify-content: center; }
  [data-screen-label] button[type="submit"] { width: 100%; justify-content: center; }
  [data-screen-label] table { display: block; width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  [data-screen-label] div[style*="padding: 12px 32px"][style*="gap: 10px"] { overflow-x: auto; white-space: nowrap; }
  [data-screen-label] div[style*="justify-content: space-between"][style*="gap: 12px"] { flex-wrap: wrap; }

  footer > div[style*="grid-template-columns"] { grid-template-columns: minmax(0, 1fr) !important; gap: 34px !important; padding: 52px 18px 34px !important; }
  footer > div[style*="max-width: 1240px"],
  footer > div > div[style*="max-width: 1240px"] { padding-left: max(18px, env(safe-area-inset-left)) !important; padding-right: max(18px, env(safe-area-inset-right)) !important; }
  footer a { min-height: 40px; display: inline-flex; align-items: center; }
  footer div[style*="min-width: 240px"],
  footer div[style*="min-width: 220px"] { min-width: 0 !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
