body {
    margin: 0;
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: #eef4fa;
    color: #102a43;
    font: 1rem/1.5 system-ui, sans-serif;
}
main {
    box-sizing: border-box;
    width: min(90%, 46rem);
    padding: clamp(1rem, 4vw, 3rem);
    border: 1px solid #a7b9ca;
    border-radius: 1rem;
    background: white;
    text-align: center;
}
img { max-width: 100%; height: auto; }
main > form { margin-top: .75rem; }
.action {
    display: inline-block;
    padding: .7rem 1rem;
    border: 1px solid #083b66;
    border-radius: .35rem;
    background: #083b66;
    color: white;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}
.action:hover { background: #102a43; }
.action:focus-visible { outline: 3px solid #0075be; outline-offset: 3px; }
.admin-page { display: block; }
.admin-panel { width: min(95%, 69rem); margin: 1.5rem auto; text-align: left; }
.admin-panel section { margin-top: 2rem; }
.admin-panel a { color: #083b66; }
.portal-brand { display: inline-flex; align-items: center; gap: .5rem; margin-bottom: .9rem; font-weight: 700; text-decoration: none; }
.portal-brand img { flex: 0 0 auto; height: 36px; }
.portal-brand:hover span { text-decoration: underline; }
.account-fields { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.account-fields label { display: grid; gap: .25rem; max-width: 100%; font-weight: 600; }
.account-fields input, .account-fields select {
    box-sizing: border-box;
    max-width: 100%;
    padding: .6rem;
    border: 1px solid #6a839a;
    border-radius: .35rem;
    color: #102a43;
    background: white;
    font: inherit;
    font-weight: 400;
}
.account-fields input:focus-visible, .account-fields select:focus-visible, .admin-panel a:focus-visible {
    outline: 3px solid #0075be;
    outline-offset: 2px;
}
.account-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; border-top: 1px solid #a7b9ca; padding: .8rem 0; }
.account-identity { min-width: 0; overflow-wrap: anywhere; }
.account-identity h3, .account-identity p { margin: .2rem 0; }
.account-pages { display: flex; flex-wrap: wrap; gap: 1rem; }
.account-audit { padding-left: 1.4rem; overflow-wrap: anywhere; }
.account-audit li { margin-bottom: .5rem; }
.account-notice, .account-error { padding: .75rem; border-radius: .35rem; }
.account-notice { background: #e0f3e8; color: #184a30; }
.account-error { background: #fee9e9; color: #6b1515; }
.workspace-actions { display: flex; flex-wrap: wrap; gap: .6rem; justify-content: center; }
.draft-panel { overflow-wrap: anywhere; }
.draft-panel summary { cursor: pointer; color: #083b66; font-weight: 600; }
.draft-panel details[open] > form { margin-top: .75rem; }
.draft-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .8rem; margin: .75rem 0; }
.draft-fields label, .draft-parent { display: grid; gap: .25rem; font-weight: 600; }
.draft-fields .full-field { grid-column: 1 / -1; }
.draft-fields .checkbox-field { display: flex; align-items: center; gap: .45rem; }
.draft-fields input:not([type=checkbox]), .draft-fields select, .draft-fields textarea, .draft-parent select {
    box-sizing: border-box; width: 100%; min-width: 0; padding: .6rem;
    border: 1px solid #6a839a; border-radius: .35rem;
    color: #102a43; background: white; font: inherit; font-weight: 400;
}
.draft-panel :is(summary, input, select, textarea, button):focus-visible { outline: 3px solid #0075be; outline-offset: 3px; }
.draft-list { padding-left: 1.5rem; }
.draft-list li { margin-bottom: .7rem; }
.draft-meta { color: #35516c; }
.draft-text { white-space: pre-wrap; }
.draft-section { border-top: 1px solid #a7b9ca; padding: .9rem 0; }
.draft-item { border-left: .16rem solid #a7b9ca; margin: .8rem 0 .8rem 1rem; padding-left: .85rem; }
.draft-entry-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .4rem; }
.draft-entry-heading :is(h3, h4) { margin: .3rem 0; }
.draft-order { display: flex; flex-wrap: wrap; gap: .35rem; }
.draft-order button { padding: .38rem .6rem; border: 1px solid #527391; border-radius: .35rem; background: #eef4fa; color: #102a43; font: inherit; cursor: pointer; }
.draft-order button:disabled { opacity: .5; cursor: default; }
@media (max-width: 40rem) { .draft-fields { grid-template-columns: minmax(0, 1fr); } }
