/*
Theme Name: Mountain Aerospace
Theme URI: https://mountainaerospace.ca/
Author: Mountain Aerospace
Description: Minimal theme for Mountain Aerospace with an animated radar map background and automatic day and night modes.
Version: 1.2.0
Requires at least: 6.0
Requires PHP: 7.4
License: All rights reserved
Text Domain: mountain-aerospace
*/

[hidden] { display: none !important; }
body.admin-bar .gnav { top: 32px; }
@media (max-width: 782px) { body.admin-bar .gnav { top: 46px; } }
/* Layout: Apple-minimal, white. Behind everything, a light version of the SkyPlanes first level:
   London city map layers (water, rivers, rail, roads), runways, fixes and airways, radar sweep, traffic.
   Content floats on frosted-glass panels so each app reads as its own object.
   Single deliberate light look. System font = SF Pro on Apple devices. */
:root {
  color-scheme: light;
  --white: #FFFFFF;
  --grey: #F5F5F7;
  --ink: #1D1D1F;
  --ink-2: #6E6E73;
  --hair: rgba(0,0,0,.08);
  --blue: #0071E3;
  --link: #0066CC;
  --glass: rgba(255,255,255,.74);
  --sw: #00A651;   /* SkyWatch */
  --sc: #E3002B;   /* SkyCommand, the logo red */
  --sn: #FF8A00;   /* SkyNav */
  --link-btn: #0071E3;
  --band: rgba(250,250,252,.92);
  --nav-bg: rgba(250,250,252,.76);
  --nav-link: rgba(29,29,31,.8);
  --pill-bg: rgba(255,255,255,.7);
  --glow-1: rgba(255,255,255,.7);
  --glow-2: rgba(255,255,255,.35);
  --body-2: #424245;
  --footer-bg: rgba(245,245,247,.9);
  --rule: #D2D2D7;
  --field-bg: rgba(255,255,255,.95);
  --field-border: #86868B;
  --doc-bg: rgba(255,255,255,.94);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
}
:root[data-mode="night"] {
  color-scheme: dark;
  --white: #000000; --grey: #161617; --ink: #F5F5F7; --ink-2: #A1A1A6;
  --hair: rgba(255,255,255,.12); --link: #2997FF; --link-btn: #2997FF;
  --glass: rgba(28,28,30,.7);
  --band: rgba(22,22,23,.92); --nav-bg: rgba(22,22,23,.72); --nav-link: rgba(245,245,247,.8);
  --pill-bg: rgba(0,0,0,.35); --glow-1: rgba(0,0,0,.55); --glow-2: rgba(0,0,0,.25);
  --body-2: #C7C7CC; --footer-bg: rgba(22,22,23,.9); --rule: #424245;
  --field-bg: rgba(28,28,30,.95); --field-border: #6E6E73; --doc-bg: rgba(12,12,13,.92);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { transition: background-color .6s ease, color .6s ease; background: var(--white); color: var(--ink); font: 400 17px/1.47 var(--font); letter-spacing: -0.022em; -webkit-font-smoothing: antialiased; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--band); }
h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
.gutter { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.container { max-width: 1080px; margin-inline: auto; }

#scope { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; display: block; }
.gnav, main, footer { position: relative; z-index: 1; }

.glass {
  background: var(--glass);
  -webkit-backdrop-filter: saturate(180%) blur(22px); backdrop-filter: saturate(180%) blur(22px);
  border: 1px solid var(--hair);
  border-radius: 28px;
}

/* ---------- Global nav ---------- */
.gnav {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: var(--nav-bg);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--hair);
}
.gnav .row { max-width: 1024px; margin-inline: auto; height: 44px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.gnav a { font-size: 12px; letter-spacing: -0.01em; color: var(--nav-link); padding: 0 8px; white-space: nowrap; transition: color .2s; }
.gnav a:hover, .gnav a[aria-current="page"] { color: var(--ink); }
.gnav .brand { font-size: 14px; font-weight: 600; color: var(--ink); padding-left: 0; }
@media (max-width: 640px) { .gnav .hide-small { display: none; } }

/* ---------- Shared type ---------- */
.eyebrow { font-size: 17px; font-weight: 600; color: var(--ink-2); letter-spacing: -0.01em; }
.section-title { font-size: clamp(40px, 5.6vw, 56px); line-height: 1.07; font-weight: 600; letter-spacing: -0.005em; text-align: center; }
.section-sub { font-size: clamp(19px, 2.2vw, 24px); line-height: 1.2; color: var(--ink-2); text-align: center; margin-top: 10px; }
.ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.pill { font: 400 17px/1 var(--font); letter-spacing: -0.022em; padding: 12px 22px; border-radius: 980px; border: 1px solid var(--blue); transition: background .2s, color .2s; cursor: pointer; }
.pill.fill { background: var(--blue); color: #fff; }
.pill.fill:hover { background: #0077ED; }
.pill.line { color: var(--link-btn); border-color: var(--link-btn); background: var(--pill-bg); }
.pill.line:hover { background: var(--link-btn); color: #fff; }
.tlink { color: var(--link); font-size: 17px; }
.tlink:hover { text-decoration: underline; }
.tlink::after { content: " ›"; }

/* ---------- Hero ---------- */
.hero { position: relative; text-align: center; padding-block: clamp(112px, 16vw, 184px) clamp(88px, 12vw, 136px); }
.hero::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: min(820px, 110%); height: 80%;
  transform: translate(-50%, -50%); z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, var(--glow-1), var(--glow-2) 60%, transparent);
}
.hero .copy { display: grid; justify-items: center; gap: 14px; }
.hero h1 { font-size: clamp(48px, 8vw, 96px); line-height: 1.02; font-weight: 600; letter-spacing: -0.02em; max-width: 12ch; text-wrap: balance; }
.hero .sub { font-size: clamp(20px, 2.4vw, 28px); line-height: 1.18; color: var(--ink-2); max-width: 30ch; text-wrap: balance; }
.hero .ctas { margin-top: 18px; }

/* ---------- Apps ---------- */
.apps { padding-block: 48px 120px; }
.app-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.app { --c: var(--blue); padding: 32px 28px 28px; display: grid; gap: 14px; align-content: start; min-width: 0; transition: transform .3s ease, box-shadow .3s ease; }
.app:hover { transform: translateY(-3px); box-shadow: 0 24px 48px -28px rgba(0,0,0,.25); }
.app-icon { width: 60px; height: 60px; border-radius: 15px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 82%, #fff), var(--c)); box-shadow: 0 8px 20px -10px var(--c); }
.app-icon svg { width: 32px; height: 32px; }
.app .kind { font-size: 14px; font-weight: 600; color: var(--ink-2); letter-spacing: -0.005em; }
.app h3 { font-size: 32px; line-height: 1.1; font-weight: 600; letter-spacing: -0.01em; }
.app .tag { font-size: 19px; line-height: 1.3; color: var(--ink-2); }
.app ul { list-style: none; margin: 6px 0 0; padding: 16px 0 0; border-top: 1px solid var(--hair); display: grid; gap: 10px; font-size: 15px; line-height: 1.35; }
.app li { display: flex; gap: 10px; align-items: baseline; }
.app li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--c); flex: none; transform: translateY(-2px); }
.app .links { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 10px; padding-top: 16px; border-top: 1px solid var(--hair); }
@media (max-width: 900px) { .app-grid { grid-template-columns: 1fr; max-width: 560px; margin-inline: auto; } }

/* ---------- Services ---------- */
.services { padding-block: 40px 120px; }
.svc-cta { margin-top: 18px; }
.svc-panel { margin-top: 40px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.svc { padding: 32px 28px; display: grid; gap: 6px; min-width: 0; border-left: 1px solid var(--hair); }
.svc:first-child { border-left: 0; }
.svc h3 { font-size: 21px; font-weight: 600; letter-spacing: -0.01em; }
.svc p { color: var(--ink-2); font-size: 15px; line-height: 1.4; }
@media (max-width: 900px) {
  .svc-panel { grid-template-columns: 1fr 1fr; }
  .svc:nth-child(3) { border-left: 0; }
  .svc:nth-child(n+3) { border-top: 1px solid var(--hair); }
}
@media (max-width: 520px) {
  .svc-panel { grid-template-columns: 1fr; }
  .svc { border-left: 0; }
  .svc:nth-child(n+2) { border-top: 1px solid var(--hair); }
}

/* ---------- About ---------- */
.about { padding-block: 40px 120px; }
.about-panel { display: grid; justify-items: center; text-align: center; gap: 22px; padding: clamp(40px, 6vw, 80px) clamp(24px, 5vw, 72px); }
.about-panel h2 { font-size: clamp(34px, 4.6vw, 48px); line-height: 1.08; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; max-width: 20ch; }
.about-body { display: grid; gap: 16px; max-width: 60ch; font-size: 19px; line-height: 1.55; color: var(--body-2); }
.facts { display: grid; justify-items: center; width: 100%; max-width: 420px; margin-top: 18px; padding-top: 30px; border-top: 1px solid var(--hair); }
.fact { display: grid; gap: 8px; justify-items: center; align-content: start; padding: 4px 16px; min-width: 0; }
.fact + .fact { border-left: 1px solid var(--hair); }
.fact strong { font-size: clamp(24px, 3vw, 32px); line-height: 1.1; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.fact span { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.about-note { font-size: 13px; color: var(--ink-2); letter-spacing: .01em; margin-top: 6px; }
@media (max-width: 640px) {
  .facts { grid-template-columns: 1fr; gap: 0; }
  .fact { padding: 18px 0; }
  .fact + .fact { border-left: 0; border-top: 1px solid var(--hair); }
}

/* ---------- CTA ---------- */
.cta { text-align: center; padding-block: 40px 140px; }
.cta .ctas { margin-top: 28px; }

/* ---------- Footer ---------- */
footer { background: var(--footer-bg); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); color: var(--ink-2); font-size: 12px; line-height: 1.33; letter-spacing: -0.01em; border-top: 1px solid var(--hair); }
footer .inner { max-width: 980px; margin-inline: auto; padding-block: 28px 96px; display: grid; gap: 18px; justify-items: center; text-align: center; }
.foot-links { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px 26px; font-size: 13px; }
.foot-links a { color: var(--ink); opacity: .85; }
.foot-links .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--ink-2); opacity: .6; }
.foot-legal { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; padding-top: 18px; border-top: 1px solid var(--rule); width: 100%; }
.foot-legal nav { display: flex; }
.foot-legal nav a { padding: 0 10px; border-left: 1px solid var(--rule); }
.foot-legal nav a:first-child { border-left: 0; }
footer a:hover { text-decoration: underline; color: var(--ink); opacity: 1; }

/* ---------- Legal documents ---------- */
.doc-wrap { padding-block: 72px 120px; }
.doc { max-width: 760px; margin-inline: auto; padding: clamp(28px, 5vw, 64px); background: var(--doc-bg); }
.doc .eyebrow { font-size: 14px; }
.doc h1 { font-size: clamp(36px, 5vw, 48px); line-height: 1.08; font-weight: 600; letter-spacing: -0.015em; margin-top: 6px; }
.doc .updated { color: var(--ink-2); font-size: 15px; margin-top: 10px; }
.doc .summary { margin: 32px 0 8px; padding: 20px 22px; border-radius: 16px; background: var(--grey); font-size: 17px; }
.doc h2 { font-size: 21px; line-height: 1.25; font-weight: 600; letter-spacing: -0.01em; margin: 36px 0 10px; }
.doc h3 { font-size: 17px; font-weight: 600; margin: 20px 0 6px; }
.doc p, .doc li { font-size: 17px; line-height: 1.6; color: var(--body-2); }
.doc p + p { margin-top: 10px; }
.doc ul { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 6px; }
.doc .review { margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--hair); font-size: 13px; color: var(--ink-2); }
.doc a { color: var(--link); }

/* ---------- Contact ---------- */
.contact-card { display: grid; justify-items: center; gap: 10px; text-align: center; padding: clamp(32px, 5vw, 56px); }
.contact-card .email { font-size: clamp(16px, 4.6vw, 32px); font-weight: 600; letter-spacing: -0.01em; overflow-wrap: normal; word-break: normal; max-width: 100%; }
.contact-card .ctas { margin-top: 14px; }
.contact { max-width: 640px; margin-inline: auto; padding-block: 96px 128px; display: grid; gap: 36px; }
.contact-head { text-align: center; }
.contact h1 { font-size: clamp(48px, 7vw, 80px); line-height: 1.05; font-weight: 600; letter-spacing: -0.015em; }
.contact .sub { font-size: 24px; color: var(--ink-2); margin-top: 8px; }
form { display: grid; gap: 14px; padding: clamp(24px, 4vw, 40px); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { position: relative; }
.field input, .field select, .field textarea {
  width: 100%; font: 400 17px/1.3 var(--font); letter-spacing: -0.022em; color: var(--ink);
  background: var(--field-bg); border: 1px solid var(--field-border); border-radius: 12px;
  padding: 26px 16px 10px; appearance: none; -webkit-appearance: none;
}
.field textarea { min-height: 150px; resize: vertical; }
.field label { position: absolute; left: 17px; top: 9px; font-size: 12px; color: var(--ink-2); pointer-events: none; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0,113,227,.18); }
.field select { background-image: linear-gradient(45deg, transparent 50%, #6E6E73 50%), linear-gradient(135deg, #6E6E73 50%, transparent 50%); background-position: calc(100% - 22px) 26px, calc(100% - 16px) 26px; background-size: 6px 6px; background-repeat: no-repeat; }
form .pill { justify-self: center; margin-top: 10px; padding: 14px 32px; }
.note { font-size: 12px; color: var(--ink-2); text-align: center; }
@media (max-width: 560px) { .two { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .app, .app:hover { transition: none; transform: none; }
}

/* ---------- Standard pages (Support, Legal and others) ---------- */
.doc-body > * + * { margin-top: 14px; }
.doc-body h2 { font-size: 24px; line-height: 1.25; font-weight: 600; margin-top: 36px; }
.doc-body h3 { font-size: 19px; font-weight: 600; margin-top: 24px; }
.doc-body p, .doc-body li { font-size: 17px; line-height: 1.6; color: var(--body-2); }
.doc-body a { color: var(--link); }
.doc-body img { height: auto; border-radius: 12px; }
.doc-body .wp-block-button__link { border-radius: 980px; background: var(--blue); color: #fff; padding: 12px 22px; text-decoration: none; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }

/* ---------- Layout guards ---------- */
#scope { max-width: 100%; }
main section[id], #products, #services, #about { scroll-margin-top: 64px; }

/* ---------- Phone menu ---------- */
.menu-btn { display: none; width: 44px; height: 44px; margin-right: -12px; border: 0; background: none; color: var(--ink); cursor: pointer; align-items: center; justify-content: center; }
.menu-btn span { position: relative; display: block; width: 18px; height: 1.5px; background: currentColor; transition: transform .25s ease; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; width: 18px; height: 1.5px; background: currentColor; transition: transform .25s ease, top .25s ease; }
.menu-btn span { background: transparent; }
.menu-btn span::before { top: -4px; }
.menu-btn span::after { top: 4px; }
.menu-btn[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }
.mobile-menu { position: fixed; left: 0; right: 0; top: calc(44px + env(safe-area-inset-top, 0px)); bottom: 0; z-index: 19;
  background: var(--nav-bg); -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px);
  padding: 24px max(28px, env(safe-area-inset-left, 0px)) 40px; display: grid; align-content: start; gap: 4px; }
.mobile-menu a { font-size: 28px; line-height: 1.5; font-weight: 600; letter-spacing: -0.015em; color: var(--ink); }
.mobile-menu .small { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.mobile-menu .small a { font-size: 14px; font-weight: 400; color: var(--ink-2); }
body.admin-bar .mobile-menu { top: calc(44px + 46px); }
@media (max-width: 640px) { .menu-btn { display: inline-flex; } }
@media (min-width: 641px) { .mobile-menu { display: none !important; } }

/* ---------- Skip link ---------- */
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: 980px; background: var(--blue); color: #fff; font-size: 14px; transition: top .2s; }
.skip-link:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }
