/*
 * rpgcms.css — site-wide stylesheet for all 49+ Wagtail-hosted Sites in the
 * RPGCMS instance.  Goal: clean, readable, neutral.  Each site can layer
 * domain-specific styling on top later.
 *
 * Version: 2026.05.07-1230 Pacific
 * Author:  Hawke Robinson, hawke@dev2dev.net, www.hawkerobinson.com
 */

/* --- reset-ish ---------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 Helvetica, Arial, sans-serif, "Apple Color Emoji",
                 "Segoe UI Emoji";
    line-height: 1.55;
    color: #1c2733;
    background: #f7f8fa;
}
img { max-width: 100%; height: auto; }
a { color: #0d4d8a; text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: #082c54; }
h1, h2, h3, h4 { line-height: 1.25; color: #0c2238; }
h1 { font-size: 2rem; margin: 0 0 0.5rem; }
h2 { font-size: 1.5rem; margin: 1.6rem 0 0.6rem; }
h3 { font-size: 1.2rem; margin: 1.3rem 0 0.4rem; }
p { margin: 0 0 1rem; }

/* --- header -------------------------------------------------------------- */
.site-header {
    background: #0c2238;
    color: #f7f8fa;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.site-header__inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0.85rem 1rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 2rem;
}
.site-header__brand {
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: 600;
    text-decoration: none;
    flex: 0 1 auto;
}
.site-header__brand:hover { color: #ffd266; }

/* --- top nav ------------------------------------------------------------- */
.site-nav { flex: 1 1 auto; }
.site-nav__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.75rem;
}
.site-nav__item a {
    display: inline-block;
    padding: 0.4rem 0.75rem;
    color: #cbd6e2;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.95rem;
}
.site-nav__item a:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

/* --- main content -------------------------------------------------------- */
.site-main {
    max-width: 900px;
    margin: 1.5rem auto;
    padding: 0 1rem;
}
.page {
    background: #ffffff;
    border: 1px solid #e3e7ec;
    border-radius: 6px;
    padding: 1.5rem 1.75rem 2rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.page__header { margin-bottom: 1rem; }
.page__title { margin: 0; }
.page__body { word-wrap: break-word; }

/* Plone-imported body images often have inline width/height — keep them
   responsive without distorting their aspect ratio */
.page__body img {
    height: auto !important;
    max-width: 100% !important;
}

/* Imported Plone class hooks — make sure they don't stick out badly */
.page__body .image-richtext { display: inline-block; max-width: 100%; }
.page__body .image-left  { float: left;  margin: 0.25rem 1rem 0.5rem 0; }
.page__body .image-right { float: right; margin: 0.25rem 0 0.5rem 1rem; }
.page__body .image-inline { display: inline-block; vertical-align: middle; }
.page__body .captioned { display: inline-block; }
.page__body .documentDescription {
    font-style: italic;
    color: #4a5868;
    margin: 0.5rem 0 1.25rem;
    border-left: 3px solid #cbd6e2;
    padding-left: 0.75rem;
}

/* Migration-progress placeholder */
.migration-notice {
    background: #fffbe6;
    border: 1px solid #efd97e;
    padding: 1rem 1.25rem;
    border-radius: 4px;
}

/* Subnav inside a section page */
.page__subnav {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e3e7ec;
}
.page__subnav-heading { font-size: 1.1rem; }
.page__subnav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.page__subnav-list li { margin: 0.35rem 0; }

/* --- footer -------------------------------------------------------------- */
.site-footer {
    margin-top: 3rem;
    padding: 1.5rem 1rem 2rem;
    background: #0c2238;
    color: #cbd6e2;
}
.site-footer__inner {
    max-width: 1100px;
    margin: 0 auto;
    font-size: 0.9rem;
}
.site-footer a { color: #ffd266; }
.site-footer__credit { margin: 0 0 0.5rem; }
.site-footer__platform { margin: 0; opacity: 0.65; }

/* --- responsive tweaks --------------------------------------------------- */
@media (max-width: 720px) {
    .site-header__inner { flex-direction: column; align-items: flex-start; }
    .site-nav__list { gap: 0.25rem 0.4rem; }
    .page { padding: 1rem 1.1rem 1.5rem; }
}
