/* The website of intrepid (intrepid-studio.eu): one page, light and dark as
   the system says, the navy and the teal of the Formal Methods logo. No web
   fonts: the system's, so that nothing is loaded from elsewhere. */

:root {
  --navy: #102b46;
  --navy-2: #16284d;
  --teal: #38d8bd;
  --bg: #ffffff;
  --bg-alt: #f3f6fa;
  --fg: #1b2330;
  --muted: #566173;
  --line: #dbe2ea;
  --card: #ffffff;
  --link: #1a5fb4;
  --accent: #0f8f7a;
  --code-bg: #0f1d2e;
  --code-fg: #e6edf5;
  --shadow: 0 1px 2px rgb(16 43 70 / 8%), 0 8px 24px rgb(16 43 70 / 10%);
  --radius: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1622;
    --bg-alt: #131e2d;
    --fg: #e3e9f1;
    --muted: #9aa7b8;
    --line: #26354a;
    --card: #162334;
    --link: #8ab4f8;
    --accent: #38d8bd;
    --code-bg: #0a121c;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px rgb(0 0 0 / 35%);
    color-scheme: dark;
  }
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--link);
  text-underline-offset: 2px;
}

code,
pre {
  font-family: var(--mono);
  font-size: 0.88em;
}

p code {
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 4px;
}

h1,
h2,
h3 {
  line-height: 1.2;
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(1.6rem, 3.2vw, 2.2rem);
  margin: 0 0 12px;
}

h3 {
  font-size: 1.2rem;
  margin: 0 0 8px;
}

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

.wrap {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

.wrap.narrow > * {
  max-width: 760px;
}

/* --- the bar ------------------------------------------------------------- */

.bar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}

.bar-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--fg);
  font-weight: 700;
  font-size: 1.15rem;
  text-decoration: none;
}

.links {
  display: flex;
  gap: 20px;
  margin-left: auto;
}

.links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
}

.links a:hover {
  color: var(--fg);
}

/* --- buttons ------------------------------------------------------------- */

.button {
  display: inline-block;
  background: var(--navy);
  color: #fff;
  border: 1px solid var(--navy);
  border-radius: 8px;
  padding: 11px 20px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.button:hover {
  background: var(--navy-2);
}

.button:focus-visible,
.links a:focus-visible,
.card a:focus-visible,
.link-card:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
}

.button.small {
  padding: 7px 14px;
  font-size: 0.92rem;
}

.button.ghost {
  background: transparent;
  color: inherit;
  border-color: currentColor;
}

@media (prefers-color-scheme: dark) {
  .button {
    background: var(--teal);
    border-color: var(--teal);
    color: #062a24;
  }
  .button:hover {
    background: #5fe3cc;
  }
  .button.ghost {
    background: transparent;
    color: var(--fg);
    border-color: var(--line);
  }
}

/* --- the hero ------------------------------------------------------------ */

.hero {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgb(56 216 189 / 22%), transparent 60%),
    linear-gradient(180deg, var(--navy) 0%, #0b2038 100%);
  color: #fff;
  padding: 72px 0 80px;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 48px;
  align-items: center;
}

.eyebrow {
  color: var(--teal);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.82rem;
  margin: 0 0 12px;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 0 0 18px;
}

.lead {
  font-size: 1.12rem;
  color: #d3deeb;
  margin: 0 0 28px;
}

.lead strong {
  color: #fff;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero .button {
  background: var(--teal);
  border-color: var(--teal);
  color: #062a24;
}

.hero .button:hover {
  background: #5fe3cc;
}

.hero .button.ghost {
  background: transparent;
  color: #fff;
  border-color: rgb(255 255 255 / 45%);
}

.hero .button.ghost:hover {
  border-color: #fff;
}

.note {
  color: #9fb3c8;
  font-size: 0.92rem;
  margin: 18px 0 0;
}

.shot {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--card);
}

.hero-shot {
  border-color: rgb(255 255 255 / 14%);
  box-shadow: 0 20px 60px rgb(0 0 0 / 40%);
}

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

.section {
  padding: 88px 0;
}

.section.alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-lead {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 720px;
  margin: 0 0 48px;
}

.feature {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 6fr);
  gap: 48px;
  align-items: center;
  margin: 0 0 80px;
}

.feature:last-child {
  margin-bottom: 0;
}

.feature.flip {
  grid-template-columns: minmax(0, 6fr) minmax(0, 4fr);
}

.feature.flip .feature-text {
  order: 2;
}

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

.feature-text h3 {
  font-size: 1.45rem;
}

.code {
  margin: 0;
  background: var(--code-bg);
  color: var(--code-fg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow-x: auto;
}

.code pre {
  margin: 0;
  padding: 24px 26px;
  line-height: 1.7;
}

.code .c {
  color: #8fa3ba;
}

/* --- cards --------------------------------------------------------------- */

.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}

.card h3 {
  margin: 0;
}

.card p {
  color: var(--muted);
  margin: 0;
  flex: 1;
}

.card pre {
  margin: 0;
  background: var(--code-bg);
  color: var(--code-fg);
  border-radius: 8px;
  padding: 12px 14px;
  overflow-x: auto;
}

.card > a {
  font-weight: 600;
  text-decoration: none;
}

.card > a::after,
.more::after {
  content: " →";
}

.link-card {
  color: inherit;
  text-decoration: none;
  transition: border-color 0.15s, transform 0.15s;
}

.link-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.more {
  color: var(--link);
  font-weight: 600;
}

.facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin-top: 32px;
}

.fact {
  border-top: 3px solid var(--accent);
  padding-top: 18px;
}

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

#license p {
  color: var(--muted);
}

#license strong {
  color: var(--fg);
}

#license .button {
  margin-top: 12px;
}

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

.footer {
  border-top: 1px solid var(--line);
  padding: 32px 0 40px;
  color: var(--muted);
  font-size: 0.92rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 32px;
}

.footer p {
  margin: 0;
}

/* --- narrow screens ------------------------------------------------------ */

@media (max-width: 860px) {
  .hero-inner,
  .feature,
  .feature.flip {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }
  .feature.flip .feature-text {
    order: 0;
  }
  .facts {
    grid-template-columns: minmax(0, 1fr);
  }
  .links {
    display: none;
  }
  .button.small {
    margin-left: auto;
  }
  .hero {
    padding: 48px 0 56px;
  }
  .section {
    padding: 64px 0;
  }
  .feature {
    margin-bottom: 56px;
  }
}

@media (max-width: 600px) {
  .wrap {
    padding: 0 16px;
  }
  .cards {
    grid-template-columns: minmax(0, 1fr);
  }
  body {
    font-size: 16px;
  }
}
