/*
 * Shared skin for mon-complot.fr.
 *
 * The whole site is one investigation board: every block the visitor is shown is
 * a piece of paper pinned to it, and red string runs between the pins. The pin,
 * the paper and the footer are defined once here; each page adds only what is
 * its own.
 */

:root {
    --bg: #14110d;
    --panel: #1e1a14;
    --ink: #efe7d6;
    --accent: #c0392b;
    --accent2: #3a7d44;
    --muted: #9c917c;
    --link: #d9564a;
    /* Paper stocks: the cream of a printed sheet, the buff of a case file,
       the brown of kraft. */
    --paper: #e9e1cf;
    --paper-note: #d9cbb0;
    --paper-ink: #1a1206;
}

* { box-sizing: border-box; }

/* Positioned so the #threads overlay can be measured against the document. */
body {
    position: relative;
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.6;
}

/* --- The board --------------------------------------------------------- */

/* Red string, drawn on an overlay behind every block. */
#threads {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: visible;
}
#threads path {
    fill: none;
    stroke: #b3352a;
    stroke-width: 1.6;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .55));
}

/* One pin shape, reused wherever a sheet is fastened to the board. */
.pin {
    position: absolute;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    z-index: 3;
    background: radial-gradient(circle at 36% 32%, #e2685c 0%, #c0392b 55%, #7d2018 100%);
    box-shadow: 0 2px 5px rgba(0, 0, 0, .7);
}

/* --- The case file ------------------------------------------------------ */

/* A sheet of stamped paper, pinned by one corner and hanging slightly askew.
   Its pivot is the pin, which is why the tilt reads as weight rather than as a
   decorative rotation. */
.file {
    position: relative;
    z-index: 1;
    background: var(--paper);
    color: var(--paper-ink);
    border-radius: 2px;
    padding: 2.6rem 2rem 2rem;
    box-shadow: 0 12px 34px rgba(0, 0, 0, .7), 0 2px 6px rgba(0, 0, 0, .5);
    transform: rotate(-.5deg);
    transform-origin: 2rem 0;
}
.file .pin { top: -7px; left: 2rem; }
.file h1 {
    font-size: 1.7rem;
    margin: 0 0 .2rem;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: var(--paper-ink);
}
.file h1 .r { color: #8f2a22; }
.file h2 {
    font-size: 1.15rem;
    margin: 1.8rem 0 .5rem;
    color: #3d3020;
    border-bottom: 1px solid #c3b79c;
    padding-bottom: .25rem;
}
.file .ref {
    font-family: monospace;
    font-size: .78rem;
    color: #6d6250;
    letter-spacing: .08em;
    margin: 0 0 1.6rem;
}
.file p, .file li { color: #33291b; }
.file .lead { font-style: italic; }
.file a { color: #8f2a22; }
.file a:hover { color: var(--paper-ink); }
.file address { font-style: normal; }

/* A rubber stamp, slapped across the sheet at an angle. */
.stamp {
    position: absolute;
    top: 1.4rem;
    right: 1.4rem;
    transform: rotate(9deg);
    border: 3px solid #a8332a;
    color: #a8332a;
    border-radius: 3px;
    padding: .25rem .7rem;
    font-size: .85rem;
    font-weight: bold;
    letter-spacing: .14em;
    text-transform: uppercase;
    opacity: .72;
}

/* The way back, sitting on the sheet itself rather than on the board below,
   where the red string runs. Qualified with .file: the plain `.file a` rule is
   more specific than a bare class and would paint the label dark red on red. */
.home-row { text-align: center; margin-top: 2rem; }
.file a.home {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    text-decoration: none;
    padding: .85rem 1.8rem;
    border-radius: 6px;
    font-size: 1.05rem;
    font-weight: bold;
    letter-spacing: .01em;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .35);
}
.file a.home:hover { background: #a93226; color: #fff; }

/* --- The footer --------------------------------------------------------- */

/* Kraft paper, pinned by one corner like everything else. */
.site-footer {
    position: relative;
    z-index: 1;
    margin-top: 3.5rem;
    padding: 0 1.2rem 3rem;
    border: 0;
}
.site-footer .paper {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    padding: 2rem 1.6rem 1.8rem;
    text-align: center;
    border-radius: 2px;
    background: linear-gradient(158deg, #302819 0%, #29221a 45%, #241e15 100%);
    box-shadow: 0 8px 26px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 240, 200, .05);
    transform: rotate(.35deg);
    transform-origin: 2.2rem 0;
}
.site-footer .paper .pin-l { left: 2.2rem; top: -7px; }
.site-footer nav a {
    color: #b6a98d;
    margin: 0 .6rem;
    font-size: .9rem;
    text-decoration: none;
}
.site-footer nav a:hover { color: var(--ink); }
.site-footer .disclaimer {
    color: #8a7f68;
    font-size: .8rem;
    font-style: italic;
    max-width: 640px;
    margin: 1rem auto 0;
}
.site-footer .credits-joke {
    color: #6b6152;
    font-size: .72rem;
    letter-spacing: .06em;
    line-height: 1.7;
    text-transform: uppercase;
    max-width: 520px;
    margin: 1rem auto 0;
}
