/* WebVigil site, ported in shape from the WhatDay site. Its colours are the application's own dark
   tokens (frontend/src/theme.css), sampled from application-icon.png: navy surfaces, the cyan glow
   as the accent and the traffic-light colours of the status lights. */

:root {
    color-scheme: dark;
    --bg: #061229;
    --bg-deep: #040c1c;
    --surface: rgba(11, 31, 69, 0.78);
    --surface-alt: #10295a;
    --border: #1e3a70;
    --text: #e6f1ff;
    --muted: #9db3d6;
    --faint: #6f86ad;
    --accent: #2ee5fd;
    --accent-strong: #0282fb;
    --on-accent: #032a61;
    --ok: #04dc07;
    --warn: #fc9c01;
    --fail: #ff4d52;
    --idle: #8193b5;

    --radius: 14px;
    --gutter: 16px;
    --max: 1100px;
    --font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, sans-serif;
    --font-display: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background:
        radial-gradient(1200px 600px at 80% -10%, rgba(46, 229, 253, 0.12), transparent 60%),
        radial-gradient(900px 500px at -10% 30%, rgba(2, 130, 251, 0.12), transparent 60%),
        var(--bg);
    color: var(--text);
    font: 17px/1.6 var(--font);
    overflow-x: hidden;
}

a { color: var(--accent); text-underline-offset: 3px; }

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

.wrap {
    width: 100%;
    max-width: var(--max);
    margin: 0 auto;
    /* Sides only: a shorthand here outranks `section`'s vertical padding. */
    padding-inline: var(--gutter);
}

/* Header */

.site-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 20px;
    padding-bottom: 20px;
}

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

.brand img { width: 34px; height: 34px; }

.site-head nav { display: flex; gap: 18px; flex-wrap: wrap; justify-content: flex-end; }

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

.site-head nav a:hover,
.site-head nav a:focus-visible { color: var(--text); }

/* Hero: the words, then the window itself at full width. */

.hero { padding-top: 40px; padding-bottom: 24px; }

.eyebrow {
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 0 0 18px;
}

.pill {
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
    border-radius: 999px;
    padding: 3px 12px;
    font-size: 0.8rem;
    color: var(--muted);
}

h1 {
    font-family: var(--font-display);
    font-size: clamp(2.3rem, 6vw, 4rem);
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin: 0 0 20px;
    max-width: 16em;
}

h1 .accent { color: var(--accent); }

.lead { font-size: 1.2rem; color: var(--muted); margin: 0 0 28px; max-width: 38em; }

.lead strong { color: var(--text); font-weight: 600; }

.cta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 22px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.btn:hover,
.btn:focus-visible { border-color: var(--accent); transform: translateY(-1px); }

.btn-primary {
    background: var(--accent);
    border-color: transparent;
    color: var(--on-accent);
}

.btn-primary:hover,
.btn-primary:focus-visible { background: #7af0ff; border-color: transparent; }

/* Screenshots */

.shot { margin: 0; }

.shot img {
    display: block;
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

.shot-hero { margin-top: 44px; }

.shot figcaption { margin-top: 12px; color: var(--faint); font-size: 0.9rem; }

/* Sections */

section { padding-top: 72px; padding-bottom: 24px; }

h2 {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    letter-spacing: -0.015em;
    line-height: 1.12;
    margin: 0 0 16px;
}

.kicker {
    color: var(--accent);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.78rem;
    margin: 0 0 10px;
}

.prose { max-width: 40em; color: var(--muted); }

.prose p { margin: 0 0 16px; }

.prose strong { color: var(--text); }

/* How it works: the steps beside the Edit dialog. */

.how {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
    margin-top: 24px;
}

.steps { margin: 0; padding-left: 22px; color: var(--muted); }

.steps li { margin-bottom: 14px; padding-left: 4px; }

.steps li::marker { color: var(--accent); font-weight: 700; }

.steps strong { color: var(--text); }

/* The status lights, drawn as the application draws them: shape, word and colour. */

.lights {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.light-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
}

.light-card h3 { margin: 12px 0 4px; font-size: 1.1rem; }

.light-card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.mark { display: block; width: 22px; height: 22px; }

.mark.ring { border-radius: 50%; border: 3px solid var(--idle); }

.mark.circle { border-radius: 50%; background: var(--ok); }

.mark.diamond { background: var(--warn); transform: rotate(45deg) scale(0.85); }

.mark.square { border-radius: 3px; background: var(--fail); }

/* Lists */

.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 24px;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 24px;
}

.card h3 { margin: 0 0 12px; font-size: 1.15rem; }

.card ul { margin: 0; padding-left: 20px; color: var(--muted); }

.card li { margin-bottom: 8px; }

.card li strong { color: var(--text); }

/* Downloads: the house card per platform. WebVigil is Windows only, so there is one card,
   centred at a card's width. */

.dl-version {
    display: inline-block;
    margin-top: 4px;
    font-size: 0.85rem;
    color: var(--accent);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 4px 14px;
}

.downloads {
    display: grid;
    /* Three platforms side by side; one column at the phone breakpoint below, never two and one. */
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 28px;
}

.dl-card code { font-size: 0.8rem; overflow-wrap: anywhere; }

.dl-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dl-card .ico img { display: block; margin: 0 auto; }

.dl-card h3 { margin: 4px 0 0; }

.dl-card .req { color: var(--muted); font-size: 0.85rem; margin: 0; }

.dl-card .btn { align-self: center; margin: 14px 0 4px; }

.dl-card .meta { color: var(--muted); font-size: 0.8rem; min-height: 1.2em; margin: 0; }

.dl-card .how-to { color: var(--muted); font-size: 0.85rem; margin: 8px 0 0; }

.dl-links { text-align: center; margin-top: 20px; font-size: 0.9rem; }

/* Support: the house donate section, last before the footer. */

.support .cta { margin-top: 20px; }

.btn-donate img {
    display: block;
    height: 2.7em;
    width: auto;
}

/* What's New: one card per release, newest first, in a single column so the
   history reads top to bottom. The version sits in a pill above each
   headline. */

.changelog {
    display: grid;
    gap: 16px;
    margin-top: 24px;
}

.changelog .card { overflow-wrap: break-word; }

.ver-tag {
    display: inline-block;
    margin-bottom: 10px;
    border: 1px solid var(--border);
    background: var(--surface-alt);
    border-radius: 999px;
    padding: 3px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
}

.changelog .card li:last-child { margin-bottom: 0; }

.changelog-more {
    margin-top: 32px;
    justify-content: center;
}

/* Footer */

.site-foot {
    margin-top: 72px;
    padding-top: 28px;
    padding-bottom: 40px;
    border-top: 1px solid var(--border);
    color: var(--faint);
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.site-foot a { color: var(--muted); }

/* Phones */

@media (max-width: 820px) {
    .how { grid-template-columns: 1fr; gap: 28px; }
    .two-col { grid-template-columns: 1fr; }
    .downloads { grid-template-columns: minmax(0, 440px); justify-content: center; }
    .site-head nav { gap: 12px; }
}

@media (max-width: 480px) {
    body { font-size: 16px; }
    .site-head nav a.hide-sm { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; scroll-behavior: auto !important; }
}
