/* NOSIG website — styled like the app's aviation chart: chart paper, sea blue, FIR teal,
   route magenta and the flight-category colours. Light and dark follow the visitor's system.
   Fonts are served from this site (SIL Open Font License), so visitors make no third-party requests. */

@font-face {
  font-family: 'Sofia Sans';
  src: url('fonts/sofia-sans.woff') format('woff');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Sofia Sans Extra Condensed';
  src: url('fonts/sofia-sans-extra-condensed.woff') format('woff');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Chivo Mono';
  src: url('fonts/chivo-mono.woff') format('woff');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --paper: #f3f6f9;
  --sea: #cbdae8;
  --land: #f8fafb;
  --ink: #13202e;
  --muted: #55657a;
  --line: #c9d3de;
  --fir: #1f6f6c;
  --route: #c2187a;
  --route-band: rgb(194 24 122 / 0.09);
  --vfr: #1f9d55;
  --mvfr: #2f6fe0;
  --ifr: #d93636;
  --lifr: #a045d8;
  --panel: #ffffff;
  --button-ink: #ffffff;
  --display: 'Sofia Sans Extra Condensed', 'Arial Narrow', sans-serif;
  --text: 'Sofia Sans', system-ui, sans-serif;
  --mono: 'Chivo Mono', ui-monospace, monospace;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #08111d;
    --sea: #08111d;
    --land: #182540;
    --ink: #e3eaf2;
    --muted: #93a3b8;
    --line: #26364f;
    --fir: #5cc2bc;
    --route: #ff5db8;
    --route-band: rgb(255 93 184 / 0.1);
    --vfr: #3fb950;
    --mvfr: #4c8dff;
    --ifr: #f0524f;
    --lifr: #c27bf2;
    --panel: #111d2e;
    --button-ink: #08111d;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--text);
  font-size: 1.0625rem;
  line-height: 1.55;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--route);
  text-underline-offset: 0.15em;
}

a:focus-visible,
.button:focus-visible {
  outline: 3px solid var(--mvfr);
  outline-offset: 3px;
}

.wrap {
  width: min(72rem, 100% - 2rem);
  margin-inline: auto;
}

/* ---------------------------------------------------------------- header */

.site-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.9rem;
  letter-spacing: 0.04em;
}

.brand img {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 0.6rem;
}

.site-head nav {
  display: flex;
  gap: 1.25rem;
  font-weight: 500;
}

.site-head nav a {
  color: var(--ink);
  text-decoration: none;
}

.site-head nav a:hover {
  color: var(--route);
}

/* ---------------------------------------------------------------- hero: the route on a chart */

.hero {
  position: relative;
  overflow: hidden;
  padding-block: 0;
  background: var(--sea);
  border-block: 1px solid var(--line);
}

.chart {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.chart .sea {
  fill: var(--sea);
}
.chart .land {
  fill: var(--land);
  stroke: var(--line);
  stroke-width: 0.8;
}
.chart .fir {
  fill: none;
  stroke: var(--fir);
  stroke-width: 1.2;
  stroke-dasharray: 7 5;
  opacity: 0.75;
}
.chart .fir-label {
  fill: var(--fir);
  font-family: var(--display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.12em;
  text-anchor: middle;
  opacity: 0.9;
}
.chart .band {
  fill: var(--route-band);
  stroke: var(--route);
  stroke-width: 1;
  stroke-dasharray: 3 5;
  stroke-opacity: 0.55;
}
.chart .route {
  fill: none;
  stroke: var(--route);
  stroke-width: 4.5;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  animation: fly 2.4s cubic-bezier(0.45, 0, 0.2, 1) 0.3s both;
}
.chart .ring {
  fill: none;
  stroke: var(--route);
  stroke-width: 3;
}
.chart .apt {
  stroke: var(--land);
  stroke-width: 1.5;
}
.chart .apt.v {
  fill: var(--vfr);
}
.chart .apt.m {
  fill: var(--mvfr);
}
.chart .apt.i {
  fill: var(--ifr);
}
.chart .apt.faint {
  opacity: 0.55;
}
.chart .apt-label {
  fill: var(--ink);
  font-family: var(--text);
  font-weight: 700;
  font-size: 13px;
  paint-order: stroke;
  stroke: var(--land);
  stroke-width: 3px;
}
.chart .apt-label.end {
  font-size: 22px;
}

@keyframes fly {
  from {
    stroke-dashoffset: 1;
  }
  to {
    stroke-dashoffset: 0;
  }
}

.hero-inner {
  position: relative;
  display: flex;
  align-items: center;
  min-height: min(44rem, 88vh);
  padding-block: 3rem;
}

/* Like the boxed legends on a SIGWX chart. */
.legend-box {
  align-self: start;
  max-width: 34rem;
  background: var(--panel);
  border: 1.5px solid var(--ink);
  padding: 1.75rem 1.75rem 1.5rem;
}

.hero h1 {
  margin: 0 0 1rem;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.9rem, 6.4vw, 5.2rem);
  line-height: 0.92;
  letter-spacing: -0.005em;
}

.hero p {
  margin: 0 0 1.5rem;
  max-width: 30rem;
  color: var(--muted);
  font-size: 1.125rem;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.3rem;
  border-radius: 0.6rem;
  background: var(--route);
  color: var(--button-ink);
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
}

.button svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.button:hover {
  filter: brightness(1.08);
}

.small {
  display: block;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  color: var(--muted);
}

/* A cropped part of an app screen, not a whole (very tall) phone: each image says which part to show. */
.phone {
  width: clamp(16rem, 30vw, 22rem);
  aspect-ratio: 4 / 5;
  border-radius: 1.6rem;
  border: 0.45rem solid #0e1726;
  background: #0e1726;
  box-shadow: 0 1.5rem 3rem -1rem rgb(8 17 29 / 0.45);
  overflow: hidden;
}

.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--focus, 50% 0%);
  border-radius: 1.2rem;
}


/* ---------------------------------------------------------------- content sections */

section {
  padding-block: 5.5rem;
}


h2 {
  margin: 0 0 1rem;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.2rem, 4.2vw, 3.3rem);
  line-height: 1;
}

h3 {
  margin: 0 0 0.35rem;
  font-size: 1.2rem;
  line-height: 1.3;
}

.split {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}

.split.reverse {
  grid-template-columns: minmax(0, 1fr) auto;
}

.prose {
  max-width: 36rem;
}

.prose p {
  margin: 0 0 1rem;
}

/* A real METAR, as it appears in the app. */
.metar {
  margin: 1.5rem 0;
  padding: 1rem 1.15rem;
  background: var(--panel);
  border-left: 4px solid var(--vfr);
  font-family: var(--mono);
  font-size: 0.95rem;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.metar .nosig {
  background: var(--route-band);
  color: var(--route);
  font-weight: 500;
}

.metar small {
  display: block;
  margin-top: 0.4rem;
  font-family: var(--text);
  font-size: 0.85rem;
  color: var(--muted);
}

.features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.5rem 3.5rem;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
}

.features li {
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.features p {
  margin: 0;
  color: var(--muted);
}

.mark {
  width: 2.25rem;
  height: 2.25rem;
}

.mark-dots {
  display: grid;
  grid-template-columns: repeat(2, 0.8rem);
  gap: 0.3rem;
  padding: 0.15rem;
}

.mark-dots span {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
}

.symbols {
  display: flex;
  gap: 0.4rem;
}

.symbols img {
  width: 1.6rem;
  height: 1.6rem;
}

.dark-only {
  display: none;
}

@media (prefers-color-scheme: dark) {
  .light-only {
    display: none;
  }
  .dark-only {
    display: block;
  }
}

.status-line {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.5rem 0 1.25rem;
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: var(--panel);
  font-size: 0.95rem;
}

.status-line i {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--mvfr);
}

.sources {
  border-top: 1px solid var(--line);
}

.sources ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

/* ---------------------------------------------------------------- footer */

.site-foot {
  padding-block: 2.5rem 3rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
}

.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.site-foot nav {
  display: flex;
  gap: 1.25rem;
}

.site-foot p {
  margin: 0;
  max-width: 38rem;
}

/* ---------------------------------------------------------------- text pages (privacy, support) */

.page {
  padding-block: 3rem 5rem;
}

.page article {
  max-width: 42rem;
}

.page h1 {
  margin: 0 0 0.5rem;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.6rem, 6vw, 3.8rem);
  line-height: 1;
}

.page h2 {
  margin-top: 2.5rem;
  font-size: 1.9rem;
}

.page .updated {
  color: var(--muted);
  margin: 0 0 2rem;
}

.page dt {
  font-weight: 700;
  margin-top: 1.25rem;
}

.page dd {
  margin: 0.25rem 0 0;
  color: var(--muted);
}

/* ---------------------------------------------------------------- small screens */

@media (max-width: 52rem) {
  .split,
  .split.reverse {
    grid-template-columns: minmax(0, 1fr);
  }
  /* On phones the chart goes under the headline box instead of behind it. */
  .hero {
    display: flex;
    flex-direction: column-reverse;
  }
  .chart {
    position: static;
    height: auto;
    /* Taller than the drawing: it is cropped from the left, so the route fills the width. */
    aspect-ratio: 1.1;
  }
  .hero-inner {
    min-height: 0;
    padding-block: 1.5rem 0;
  }
  .legend-box {
    padding: 1.25rem;
  }
  .split .phone {
    justify-self: center;
    order: 2;
  }
  .features {
    grid-template-columns: minmax(0, 1fr);
  }
  section {
    padding-block: 3.5rem;
  }
  .site-head nav {
    gap: 0.9rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .chart .route {
    animation: none;
  }
}
