/* Styles for plain.html, the static no-JavaScript version of the site
   (generated by tools/build-plain.js). Kept in its own file rather than
   inline so the page works under a strict Content-Security-Policy. */

:root{
    --background:#000000;
    --foreground:#e8e8e8;
    --accent:#66ff99;      /* headings - same green as the terminal prompt */
    --link:#8ab4ff;        /* 9:1 contrast on black */
    --rule:#333333;
}

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

body{
    margin:0;
    padding:24px 16px 48px;
    background:var(--background);
    color:var(--foreground);
    font-family:monospace;
    font-size:16px;
    line-height:1.55;
    /* Long unbroken text (URLs) wraps instead of pushing the page wider
       than a phone screen. */
    overflow-wrap:anywhere;
}

header,
main{
    max-width:76ch;
    margin:0 auto;
}

h1,
h2,
h3,
h4{
    color:var(--accent);
    line-height:1.25;
}

h1{
    font-size:1.7rem;
    margin:0 0 8px;
}

h2{
    font-size:1.3rem;
    margin:40px 0 12px;
    padding-top:20px;
    border-top:1px solid var(--rule);
}

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

h4{
    font-size:1rem;
    margin:20px 0 4px;
}

p{
    margin:0 0 12px;
}

ul{
    margin:0 0 12px;
    padding-left:22px;
}

li{
    margin-bottom:4px;
}

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

a:focus-visible{
    outline:2px solid var(--accent);
    outline-offset:2px;
}

nav{
    display:flex;
    flex-wrap:wrap;
    gap:16px;
}

/* Printed (or saved as PDF) it should look like a normal document. */
@media print{
    :root{
        --background:#ffffff;
        --foreground:#000000;
        --accent:#000000;
        --link:#000000;
        --rule:#999999;
    }

    body{
        padding:0;
        font-size:11pt;
    }

    nav,
    header p{
        display:none;
    }

    h4,
    h3{
        break-after:avoid;
    }
}
