@font-face { font-family: "Bree Serif"; src: url("../../shared/fonts/bree-serif.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: Alegreya; src: url("../../shared/fonts/alegreya.ttf") format("truetype"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: Alegreya; src: url("../../shared/fonts/alegreya-italic.ttf") format("truetype"); font-weight: 400 900; font-style: italic; font-display: swap; }
@font-face { font-family: Montserrat; src: url("../../shared/fonts/montserrat.ttf") format("truetype"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: Rye; src: url("../../shared/fonts/rye.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: "Special Elite"; src: url("../../shared/fonts/special-elite.ttf") format("truetype"); font-display: swap; }

:root {
    --ink: #30281f;
    --blue: #24465c;
    --slate: #365f79;
    --paper: #fcf6e5;
    --parchment: #ead9b7;
    --brass: #b18a4e;
    --mist: #e5ebed;
    --red: #bf4230;
    --deep-red: #963226;
    --ivory: #f5efe3;
    --green: #234537;
    --resident-blue: #426b89;
    --reading: Alegreya, Georgia, serif;
    --typewriter: "Special Elite", "Courier New", monospace;
    --utility: Montserrat, system-ui, sans-serif;
    font-family: var(--reading);
    background: var(--mist);
}
body { font-size: 1.15rem; line-height: 1.48; }
.lodge-icon { display: inline-block; width: 1.25em; height: 1.25em; flex: none; vertical-align: -.22em; }
.button { gap: .48em; border-radius: .25rem; }
.button:focus-visible, .outline-button:focus-visible { outline-offset: 4px; }
.hub { background: var(--ivory); }
.hub h1, .hub h2 { font-family: "Bree Serif", Georgia, serif; font-weight: 400; }
.hub-intro { background: var(--red); color: #fff9ec; padding-block: clamp(1.3rem, 5vw, 3rem); }
.hub .eyebrow { font-family: var(--utility); color: inherit; letter-spacing: .105em; }
.hub-intro h1 { margin: .6rem auto .8rem; width: min(100%, 48rem); }
.hub-intro h1 img { width: 100%; filter: drop-shadow(0 1px 1px #70221780); }
.tagline { color: inherit; }
.hub .button { background: var(--red); border-color: var(--red); color: #fff9ec; font: 700 .92rem/1.3 var(--utility); }
.hub .button:hover { background: var(--deep-red); border-color: var(--deep-red); }
.hub .scan-trigger { background: #fff9ec; border-color: #fff9ec; color: var(--deep-red); }
.hub .scan-trigger:hover { background: #f1e1c5; border-color: #f1e1c5; }
.hub :focus-visible { outline-color: var(--green); }
.hub-intro :focus-visible, .hub footer :focus-visible, .reward :focus-visible, .paper-header :focus-visible, .residents footer :focus-visible { outline-color: #f9d99c; }
.adventure-selection { position: relative; max-width: 60rem; margin: auto; padding: 1.8rem 1rem 2.35rem; }
.adventure-selection > h2 { text-align: center; color: var(--deep-red); font-size: clamp(1.75rem, 5vw, 2.55rem); margin-bottom: 1rem; }
.quest-trail { position: absolute; right: 1.5rem; top: 1.3rem; color: var(--deep-red); width: 5.5rem; }
@media(max-width: 40rem) { .quest-trail { display: none; } }
.feature { width: 100%; margin: 0 auto; box-shadow: none; }
.feature-art { background: transparent; }
.qr-color { color: var(--resident-blue); font: 700 .89rem/1.4 var(--utility); }
.qr-color .lodge-icon { width: 1.6rem; height: 1.6rem; }
.hub footer { background: var(--red); color: #fff9ec; }
.hub footer a { color: inherit; font: 650 .88rem/1.4 var(--utility); }
.hub footer p { margin-bottom: .35rem; }

.residents { background: var(--mist); }
.residents h1, .residents h2 { font-family: Rye, Georgia, serif; font-weight: 400; color: var(--blue); }
.residents h1 { font-size: clamp(1.85rem, 6vw, 3.45rem); }
.residents h2 { font-size: clamp(1.28rem, 4.2vw, 1.83rem); }
.residents .button { font-weight: 700; }
.paper-header { background: var(--blue); color: var(--paper); padding-block: clamp(.9rem, 3vw, 1.55rem); }
.paper-header nav, .paper-header [data-progress] { color: var(--paper); font: 400 .97rem/1.35 var(--typewriter); }
.paper-header nav { padding-top: .8rem; row-gap: .5rem; }
.paper-header .outline-button { color: var(--paper); border: 1px solid #d8c5a0; border-radius: .25rem; padding: .15rem .65rem 0; text-decoration: none; }
.outline-button:hover { background: var(--slate); }
.paper { margin-block: clamp(.75rem, 3vw, 1.6rem); box-shadow: none; border-color: #c5c9c6; }
.residents footer { background: var(--blue); color: var(--paper); border-top: .2rem double var(--brass); }
.residents footer a { color: inherit; }
.editorial { display: flex; align-items: center; justify-content: center; gap: .4em; font: 400 .84rem/1.4 var(--typewriter); letter-spacing: .035em; color: var(--blue); margin-bottom: .65rem; }
.assignment { border: 1px solid #bac9ce; border-left: .25rem solid var(--slate); background: var(--mist); }
.assignment .editorial, .notebook .editorial { justify-content: start; }
.scanner-action { margin-top: 1rem; }
.scanner-action > p { margin: .4rem 0 0; }
.hub .scanner-action > p { margin-inline: auto; }
.scanner-fallback:empty { display: none; }
.scanner-dialog { width: min(32rem, calc(100% - 1.5rem)); max-height: calc(100% - 1.5rem); padding: clamp(1rem, 4vw, 1.65rem); border: 2px solid var(--brass); border-radius: .35rem; color: var(--ink); background: var(--paper); text-align: start; }
.scanner-dialog::backdrop { background: #1a2836bb; }
.scanner-dialog video { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #141a20; margin-bottom: .65rem; }
.progress-label { font: 400 .97rem/1.4 var(--typewriter); }
progress { background: var(--parchment); margin-bottom: .65rem; }
progress::-webkit-progress-bar { background: var(--parchment); }
progress::-webkit-progress-value { background: var(--slate); }
progress::-moz-progress-bar { background: var(--slate); }
.encouragement { margin: 0 0 1.15rem; }
.card-found { text-decoration: none; }
.card-found:hover > span:last-child { text-decoration: underline; }
.card-found:focus-visible { outline-offset: 2px; }
.card-unknown, .card-found { font-size: clamp(.97rem, 2.2vw, 1.2rem); }
.portrait-frame { padding: 13% 12%; }
.hero-portrait { padding: 0; margin: .8rem auto; }
.hero-portrait img { inset: 12% 11%; width: 78%; height: 76%; }
.reward { background: var(--blue); color: var(--paper); border: 1px solid var(--brass); }
.residents .reward h2 { color: var(--paper); }
.reward .editorial { color: #f5d69b; }
.completion-label { font-size: 1.4375rem; line-height: 1.25; }
.reward .button { background: var(--paper); color: var(--blue); border-color: #e6c68d; }
.reward .button:hover { background: #f1daa8; }
.reward-badge { width: clamp(7rem, 22vw, 10.5rem); margin: 0 auto .7rem; }
.privacy { max-width: 46rem; }
.investigator-note { padding: .85rem 1rem; background: #f2e8d2; border: 1px solid #dac6a0; }
.residents .investigator-note h2 { font-size: clamp(1.13rem, 3.5vw, 1.4rem); }
.privacy .text-button { margin-top: .15rem; }

.resident-heading h1 { margin-bottom: .2em; }
.resident-heading .subtitle { margin-bottom: .55em; }
.subtitle { font-size: clamp(1.17rem, 3vw, 1.42rem); }
.discovery { background: var(--mist); border-color: var(--slate); }
.discovery strong { display: block; font: 400 1rem/1.4 var(--typewriter); margin-bottom: .15rem; }
.discovery-new { background: var(--blue); color: var(--paper); border-color: var(--brass); }
.discovery-new strong { color: #f6dca9; }
.discovery-new strong::before { content: "✓"; font-family: system-ui, sans-serif; margin-right: .45em; }
.answer h3, .story-question { font: 400 clamp(1.04rem, 3vw, 1.23rem)/1.35 var(--typewriter); }
.story-question { margin-bottom: 1em; }
.interview .reward progress::-webkit-progress-value { background: var(--brass); }
.interview .reward progress::-moz-progress-bar { background: var(--brass); }
.ruled { border-color: #c6ac80; }
.notebook { background: #f0e4cb; padding: .8rem 1rem; }
.notebook .editorial { font-style: normal; }
.photo-frame { border: 3px double var(--blue); background: var(--mist); }
figcaption { font: 400 .97rem/1.45 var(--typewriter); }
.story-text { --story-line: 1.65rem; line-height: var(--story-line); }
.illuminated-initial {
    float: left;
    box-sizing: border-box;
    margin: 0 .36rem 0 0;
    padding: 0 .24em;
    height: calc(3 * var(--story-line));
    line-height: calc(3 * var(--story-line) - 2px);
    font-family: Rye, Georgia, serif;
    font-size: clamp(2rem, 8vw, 2.85rem);
    color: #e4bc75;
    background:
        radial-gradient(circle at 5px 5px, #dfbb78 1px, transparent 2px) top left,
        radial-gradient(circle at 5px 5px, #dfbb78 1px, transparent 2px) top right,
        radial-gradient(circle at 5px 5px, #dfbb78 1px, transparent 2px) bottom right,
        radial-gradient(circle at 5px 5px, #dfbb78 1px, transparent 2px) bottom left,
        var(--blue);
    background-size: 10px 10px;
    background-repeat: no-repeat;
    border: 1px solid var(--brass);
    outline: 1px dashed #dfbb7866;
    outline-offset: -4px;
}

.certificate-celebration { text-align: center; margin: 0 auto 1.4rem; max-width: 52rem; }
.certificate-celebration > p:not(.editorial) { max-width: 36rem; margin-inline: auto; }
.printing-tips { padding: .75rem 1rem; margin-top: 1rem; background: var(--mist); }
.residents .printing-tips h2 { font-size: 1.14rem; }
.printing-tips ul { padding-left: 1.15em; margin: 0; }
.certificate-copy { font-family: var(--reading); inset: 10% 11% 27%; font-size: 2.13cqw; }
.cert-title { font: 400 4.55cqw/1.1 Rye, Georgia, serif; }
.cert-honor { color: #214057; font: 400 2.85cqw/1.15 Rye, Georgia, serif; }
.cert-honor strong { font-weight: inherit; }
#certificate-name { font-size: 5cqw; }
#certificate-name[data-length="medium"] { font-size: 3.1cqw; }
#certificate-name[data-length="long"] { font-size: 2.1cqw; }
@media print {
    .certificate .paper { margin: 0; }
    @supports (page: lodge-certificate) {
        @page lodge-certificate { size: letter landscape; margin: 0; }
        .certificate .paper { page: lodge-certificate; padding-top: .35in; }
    }
    .certificate .certificate-celebration, .certificate [data-locked] { display: none !important; }
}

