/* Linked as style.css?v=N, site.js?v=N: raise N in the five pages after changing either, so that browsers reload them. */
/* The app's palette (Heliove/Support/Theme.swift): an old almanac, iron-gall ink on laid paper. */
:root {
    --paper: #F1E8D4;
    --paper-light: #F8F2E4;
    --paper-deep: #E2D3B3;
    --ink: #1E2433;
    --faded: rgba(30, 36, 51, .62);
    --vermilion: #C2412D;
    --ochre: #C9962B;
    --prussian: #24456B;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    color: var(--ink);
    background:
        repeating-linear-gradient(90deg, transparent 0 7px, rgba(30, 36, 51, .025) 7px 8px),
        var(--paper);
    font: 18px/1.6 Baskerville, "Libre Baskerville", Georgia, serif;
}

main {
    max-width: 720px;
    margin: 32px auto 64px;
    padding: 32px 28px 40px;
    background: var(--paper-light);
    border: 1px solid var(--ink);
    outline: 1px solid var(--ink);
    outline-offset: 5px;
}

header {
    display: flex;
    align-items: center;
    gap: 18px;
    padding-bottom: 18px;
    border-bottom: 3px double var(--ink);
}

header img { width: 72px; height: 72px; border-radius: 16px; }

.kicker {
    margin: 0;
    font-variant: small-caps;
    letter-spacing: .12em;
    color: var(--vermilion);
}

h1, h2 {
    font-family: "Bodoni 72", "Bodoni MT", Didot, serif;
    font-weight: 700;
    line-height: 1.15;
    margin: 0;
}

h1 { font-size: 40px; }

h2 {
    font-size: 24px;
    margin: 36px 0 8px;
    color: var(--prussian);
}

h2::before { content: "❧ "; color: var(--ochre); }

.languages { margin-left: auto; font-variant: small-caps; letter-spacing: .08em; white-space: nowrap; }

a { color: var(--vermilion); }

/* The official badges, at the same visible height: Google's image carries a transparent margin around its badge. */
.stores {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
    margin: 20px 0 0;
}

.stores a { display: block; line-height: 0; }
.stores img { display: block; }
.stores .apple { height: 46px; }
.stores .google { height: 60px; margin: -7px -9px; }

ul { padding-left: 1.2em; }
li { margin: 4px 0; }

.challenge {
    display: none;
    margin: 24px 0 8px;
    padding: 18px 22px;
    border: 1px solid var(--vermilion);
    outline: 1px solid var(--vermilion);
    outline-offset: 4px;
    background: var(--paper);
}

.challenge.received { display: block; }
.challenge h2 { margin: 0 0 6px; color: var(--vermilion); }
.challenge h2::before { content: none; }
.challenge.received ~ section > .stores { display: none; }

.updated { color: var(--faded); font-style: italic; margin-top: 36px; }

[lang]:not(html) { display: none; }
[lang].shown { display: block; }

footer {
    margin-top: 40px;
    padding-top: 14px;
    border-top: 3px double var(--ink);
    color: var(--faded);
    font-variant: small-caps;
    letter-spacing: .06em;
    text-align: center;
}

.summary {
    padding: 4px 20px;
    background: var(--paper);
    border-left: 3px solid var(--ochre);
}


/* Phones: the page fits the screen, its double frame inside, the languages on their own line. */
@media (max-width: 600px) {
    body { font-size: 17px; }
    main { margin: 14px 12px 32px; padding: 22px 18px 28px; }
    header { flex-wrap: wrap; gap: 10px 14px; }
    header img { width: 56px; height: 56px; border-radius: 13px; }
    header > div:not(.languages) { flex: 1; min-width: 0; }
    .languages { flex-basis: 100%; margin-left: 0; }
    h1 { font-size: 30px; overflow-wrap: break-word; hyphens: auto; }
    h2 { font-size: 21px; margin-top: 30px; }
    .summary { padding: 2px 14px; }
}

main a { overflow-wrap: anywhere; }
