:root {
    --navy: #0b1c2d;
    --navy-2: #12263a;
    --navy-3: #1b3a5a;
    --ink: #e8eef4;
    --muted: #9aacbc;
    --gold: #c5a572;
    --gold-2: #e0c48a;
    --line: rgba(197, 165, 114, 0.28);
    --card: #112233;
    --danger: #d46a6a;
    --ok: #7dbe8a;
    --font: "IBM Plex Sans", "Segoe UI", sans-serif;
    --serif: "IBM Plex Serif", Georgia, serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: var(--font);
    background: var(--navy);
    color: var(--ink);
    min-height: 100vh;
    line-height: 1.55;
}
a { color: var(--gold-2); text-decoration: none; }
a:hover { color: #fff; }
img { max-width: 100%; display: block; }

.wrap { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }

.site-header {
    border-bottom: 1px solid var(--line);
    background: rgba(11, 28, 45, 0.92);
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(10px);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 0; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.mark {
    width: 36px; height: 36px;
    border: 1px solid var(--gold);
    display: grid; place-items: center;
    font-family: var(--serif);
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 0.04em;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { letter-spacing: 0.08em; font-size: 14px; text-transform: uppercase; }
.brand-text span { color: var(--muted); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; }

nav { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
nav a { color: var(--muted); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; }
nav a.active, nav a:hover { color: var(--ink); }
.cart-link { border: 1px solid var(--line); padding: 6px 10px; }

.hero { padding: 84px 0 56px; border-bottom: 1px solid var(--line); background:
    radial-gradient(900px 320px at 80% 0%, rgba(27, 58, 90, 0.7), transparent 60%),
    linear-gradient(180deg, #0e2438, var(--navy));
}
.kicker { color: var(--gold); letter-spacing: 0.18em; text-transform: uppercase; font-size: 12px; margin: 0 0 14px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.02em; margin: 0 0 12px; }
h1 { font-size: clamp(36px, 6vw, 64px); line-height: 1.08; max-width: 16ch; }
h2 { font-size: 32px; }
.lede { max-width: 62ch; color: var(--muted); font-size: 18px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.btn {
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--gold);
    background: var(--gold);
    color: var(--navy);
    padding: 11px 16px;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
}
.btn:hover { background: var(--gold-2); color: var(--navy); }
.btn.ghost { background: transparent; color: var(--gold-2); }
.btn.ghost:hover { color: #fff; border-color: #fff; }
.btn.wide { width: 100%; }

.section { padding: 64px 0; }
.section.alt { background: var(--navy-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.grid-3, .grid-2 { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
    background: var(--card);
    border: 1px solid var(--line);
    padding: 22px;
}
.card h2 { font-size: 28px; max-width: none; }
.card h3 { font-size: 22px; }
.card p, .muted { color: var(--muted); }
.meta { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--gold); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600; }

.form { display: grid; gap: 12px; }
label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
input, textarea, select {
    background: #0b1c2d;
    border: 1px solid var(--line);
    color: var(--ink);
    padding: 10px 12px;
    font: inherit;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* Moved off the edge rather than hidden. A bot that reads the stylesheet
   skips anything set to display:none, and this field has to look real. */
.offscreen { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Whatever gets typed into a page in the admin panel lands here, so every tag
   the editor can produce needs to look like the rest of the site. */
.page-body { max-width: 76ch; }
.page-body > *:first-child { margin-top: 0; }
.page-body p, .page-body ul, .page-body ol { color: var(--muted); font-size: 16px; margin: 0 0 18px; }
.page-body h2 { font-size: 28px; margin: 36px 0 12px; }
.page-body h3 { font-size: 20px; margin: 28px 0 10px; }
.page-body ul, .page-body ol { padding-left: 22px; }
.page-body li { margin-bottom: 8px; }
.page-body img { margin: 24px 0; border: 1px solid var(--line); }
.page-body blockquote {
    margin: 24px 0; padding: 4px 0 4px 18px;
    border-left: 2px solid var(--gold);
    color: var(--ink); font-family: var(--serif); font-size: 18px;
}
.page-body hr { border: 0; border-top: 1px solid var(--line); margin: 32px 0; }
.page-body code { background: var(--navy-2); border: 1px solid var(--line); padding: 1px 5px; font-size: 14px; }
.page-body table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 15px; }
.page-body th, .page-body td { border: 1px solid var(--line); padding: 9px 12px; text-align: left; }
.page-body th { color: var(--ink); background: var(--navy-2); }
.page-body td { color: var(--muted); }

.flash { padding: 12px 14px; border: 1px solid var(--ok); color: var(--ok); margin-bottom: 18px; }
.flash.error { border-color: var(--danger); color: var(--danger); }
.errors { color: var(--danger); font-size: 14px; }

.filters { display: flex; gap: 10px; flex-wrap: wrap; margin: 24px 0; }
.filters input, .filters select { min-width: 180px; }

.price { font-family: var(--serif); font-size: 28px; color: var(--gold-2); }
.empty { color: var(--muted); padding: 40px 0; }

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.gallery figure { margin: 0; border: 1px solid var(--line); background: var(--card); }
.gallery img { width: 100%; height: 220px; object-fit: cover; }
.gallery figcaption { padding: 12px; color: var(--muted); font-size: 14px; }

.site-footer { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 13px; }
.footer-inner { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 16px; }

/* Screenshots of the software. The first one runs the full width: it is the
   screen a repair station recognises as its own working day, so it earns the
   room, and the two beneath it fill in the rest of the story. */
.shots {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    margin-top: 22px;
}

.shots figure {
    margin: 0;
}

.shots figure:first-child {
    grid-column: 1 / -1;
}

.shots img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid #1d3247;
    border-radius: 5px;
}

.shots figcaption {
    margin-top: 10px;
    color: #8fa1b3;
    font-size: 0.84rem;
    line-height: 1.55;
}

/* The yearly price, sitting under the monthly one it is an alternative to. */
.price-alt {
    margin: -10px 0 14px;
    color: #9aacbc;
    font-size: 0.86rem;
}

/* Reassurance under a form button: quieter than body copy, still readable. */
.fine {
    margin: 10px 0 0;
    color: #7e91a4;
    font-size: 0.78rem;
    line-height: 1.5;
}

/* The boxed product at the top of each subscription plan. Cut out on
   transparency, so the shadow is drawn from its actual shape. */
.plan-shot {
    width: 58%;
    max-width: 185px;
    height: auto;
    margin: 0 auto 18px;
    filter: drop-shadow(0 16px 22px rgba(0, 0, 0, 0.45));
}

/* The home page hero, dressed as a drafting sheet: graph paper, then the
   engine drawing bleeding off the right edge. Both sit above the gradient and
   below the words, which is what the z-index on .wrap is for. */
.hero-blueprint { position: relative; overflow: hidden; }
.hero-blueprint::before,
.hero-blueprint::after { content: ""; position: absolute; inset: 0; pointer-events: none; }
.hero-blueprint::before {
    background:
        repeating-linear-gradient(to right, rgba(197, 165, 114, 0.055) 0 1px, transparent 1px 68px),
        repeating-linear-gradient(to bottom, rgba(197, 165, 114, 0.055) 0 1px, transparent 1px 68px);
}
.hero-blueprint::after {
    background: url("/images/hero-engine.png") no-repeat right -60px center / auto 175%;
    opacity: 0.3;
}
.hero-blueprint > .wrap { position: relative; z-index: 1; }

@media (max-width: 860px) {
    .grid-3, .grid-2, .gallery, .form-row { grid-template-columns: 1fr; }
    .header-inner { flex-direction: column; align-items: flex-start; }
    h1 { max-width: none; }
    /* Pushed down behind the buttons and faded, so it never fights the
       headline on a phone. */
    .hero-blueprint::before { display: none; }
    .hero-blueprint::after {
        background-size: auto 105%;
        background-position: right -120px bottom -40px;
        opacity: 0.18;
    }
}
