@font-face {
    font-family: "Lexend";
    src: url("lexend.ttf") format("truetype");
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
}

:root {
    color-scheme: light;
    --ink: #493d30;
    --heading: #6c5a3d;
    --muted: #6b665b;
    --paper: #f3f2ed;
    --rule: #d4d1c7;
    --accent: #435e58;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: "Lexend", sans-serif;
    font-weight: 350;
    letter-spacing: 0;
    line-height: 1.8;
}
a { color: inherit; text-underline-offset: 5px; }
a:hover { color: var(--accent); }
a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 5px;
}
.skip-link {
    position: fixed;
    z-index: 5;
    top: 12px;
    left: 12px;
    padding: 8px 16px;
    background: var(--paper);
    transform: translateY(-180%);
}
.skip-link:focus { transform: translateY(0); }
.room {
    position: relative;
    isolation: isolate;
    display: grid;
    align-items: center;
    min-height: 590px;
    height: 90svh;
    max-height: 1100px;
    background: #c5c2b9;
}
.room::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background: url("library-room.jpg") center / cover no-repeat;
    filter: saturate(0.48) brightness(0.94);
}
.room::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: rgb(200 198 188 / 27%);
}
.room-menu {
    width: min(350px, calc(100% - 48px));
    margin-left: calc(46% - 175px);
    padding-bottom: 35px;
    text-align: center;
    animation: arrive 900ms ease-out both;
}
.studio-signature {
    display: inline-block;
    margin-bottom: 26px;
    font-size: 13px;
    text-decoration: none;
}
h1 {
    margin: 0;
    color: var(--heading);
    font-size: 38px;
    font-weight: 450;
    line-height: 1.3;
}
.game-subtitle {
    margin: 9px 0 30px;
    font-size: 14px;
}
.menu-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
}
.menu-links a {
    display: grid;
    place-items: center;
    min-height: 44px;
    padding: 5px 18px;
    font-size: 16px;
    text-decoration: none;
    transition: color 180ms ease;
}
.menu-links a:hover { text-decoration: underline; }
.room-caption {
    position: absolute;
    bottom: 23px;
    left: 24px;
    right: 24px;
    text-align: center;
    font-size: 12px;
    text-decoration: none;
}
.room-caption span { display: block; font-size: 20px; line-height: 1.5; }
.journal { max-width: 1040px; margin: 0 auto; padding: 0 48px; }
.journal-section {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 48px;
    padding: 64px 0;
    border-bottom: 1px solid var(--rule);
    scroll-margin-top: 28px;
}
.section-label { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
h2 {
    margin: 0 0 20px;
    color: var(--heading);
    font-size: 24px;
    font-weight: 450;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
.section-content p { margin: 0 0 18px; max-width: 620px; }
.section-content p:last-child { margin-bottom: 0; }
.section-content .quiet-note { color: var(--muted); font-size: 13px; }
.studio-motto { color: var(--accent); }
.contact-link { display: inline-block; margin-top: 6px; overflow-wrap: anywhere; }
.site-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 28px 0;
    color: var(--muted);
    font-size: 11px;
}
.site-footer p { margin: 0; }
.policy-page .page { max-width: 800px; margin: 0 auto; padding: 40px 28px; }
.policy-page .header { border-bottom: 1px solid var(--rule); margin-bottom: 40px; padding-bottom: 24px; }
.policy-page .title { color: var(--muted); font-size: 13px; }
.policy-page h1 { font-size: 32px; margin-bottom: 20px; }
.policy-page h2 { margin-top: 40px; }
.policy-page h3, .policy-page h4 { font-weight: 500; line-height: 1.5; }
.policy-page p, .policy-page li { overflow-wrap: anywhere; }
.policy-page ul { padding-left: 24px; }
.policy-page .footer { border-top: 1px solid var(--rule); margin-top: 40px; padding-top: 20px; font-size: 12px; }
.back-link { display: inline-block; min-height: 44px; font-size: 14px; }

@keyframes arrive {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 700px) {
    .room { min-height: 540px; height: 88svh; max-height: 860px; }
    .room::before { background-position: 48% center; }
    .room::after { background: rgb(218 216 205 / 65%); }
    .room-menu { margin: 0 auto; padding-bottom: 32px; }
    h1 { font-size: 32px; }
    .room-caption { font-size: 11px; }
    .journal { padding: 0 26px; }
    .journal-section { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 38px 0; }
    h2 { font-size: 21px; }
    .section-content { font-size: 14px; }
    .site-footer { flex-direction: column; align-items: flex-start; gap: 10px; }
}

@media (max-height: 620px) {
    .room { min-height: 390px; height: 90svh; }
    .room-menu { padding-bottom: 44px; }
    .studio-signature { margin-bottom: 8px; }
    .game-subtitle { margin: 5px 0 12px; }
    .menu-links { gap: 0; }
    .room-caption { bottom: 12px; }
    .journal-section { padding-top: 24px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .room-menu { animation: none; }
    .menu-links a { transition: none; }
}