:root {
  color-scheme: light;
  --paper: #f5f3ef;
  --white: #fffefa;
  --ink: #182332;
  --muted: #596472;
  --navy: #172236;
  --navy-2: #21314b;
  --line: #dedbd3;
  --gold: #e0bb80;
  --gold-dark: #704819;
  --wash: #ede8dd;
  --red: #9b302b;
  --radius: 11px;
  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: Georgia, "Times New Roman", serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.6 var(--sans); }
button, input, textarea, select { font: inherit; }
a { color: inherit; }
a, button { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #367ea4; outline-offset: 4px; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
h1, h2 { font: 400 clamp(2.9rem, 6.3vw, 5.65rem)/1.08 var(--serif); letter-spacing: -.045em; }
h2 { font-size: clamp(1.95rem, 4vw, 2.9rem); }
h3 { font-size: 1.05rem; line-height: 1.3; }
svg { flex-shrink: 0; vertical-align: middle; }
.wrap { width: min(100% - 3rem, 75rem); margin-inline: auto; }
.narrow { width: min(100% - 3rem, 54rem); margin-inline: auto; }
.skip-link { position: fixed; z-index: 10; top: 12px; left: 12px; translate: 0 -160%; background: #fff; padding: .5rem .8rem; border: 2px solid; }
.skip-link:focus { translate: none; }
#content:focus { outline: none; }
.site-header { background: var(--white); border-bottom: 1px solid var(--line); }
.site-header .wrap, .footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.1rem; }
.site-header .wrap { min-height: 5rem; }
.brand { display: inline-flex; align-items: center; gap: .75rem; text-decoration: none; white-space: nowrap; }
.brand-mark { width: 41px; height: 41px; }
.brand strong { display: block; font-size: .94rem; line-height: 1.35; font-weight: 680; }
.brand small { display: block; color: var(--muted); font-size: .81rem; font-weight: 500; }
.top-nav { display: flex; align-items: center; gap: clamp(.65rem, 3vw, 2rem); }
.nav-link { text-decoration: none; font-weight: 620; font-size: .92rem; white-space: nowrap; padding: .45rem 0; }
.nav-link:hover, .nav-link[aria-current="page"] { text-decoration: underline; text-decoration-color: #ae8553; text-underline-offset: .35rem; }
.nav-staff { border: 1px solid var(--line); border-radius: 6px; padding: .42rem .76rem; }
.demo-banner { background: #f4e1ba; color: #432e18; text-align: center; padding: .48rem 1rem; font-size: .9rem; }
.demo-banner strong { margin-right: .35rem; }
.hero { position: relative; isolation: isolate; color: var(--white); background: radial-gradient(ellipse at 78% 52%, #263a58 0%, var(--navy) 63%); overflow: hidden; }
.hero::before { content: ""; position: absolute; z-index: -1; inset: 0; background: repeating-linear-gradient(120deg, transparent 0 143px, #fff1 144px, transparent 145px); mask-image: linear-gradient(90deg, transparent 30%, #000); opacity: .48; }
.hero-inner { display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.3rem; align-items: center; min-height: 30rem; padding-block: clamp(3.2rem, 7vw, 5rem); }
.eyebrow { display: flex; align-items: center; gap: .55rem; color: var(--gold-dark); font-size: .81rem; font-weight: 720; letter-spacing: .12em; text-transform: uppercase; }
.hero .eyebrow { color: var(--gold); }
.hero h1 { margin-top: 1.1rem; max-width: 13ch; }
.hero-copy { max-width: 33rem; margin-top: 1.25rem; color: #d7dfeb; font-size: clamp(1rem, 1.8vw, 1.145rem); }
.hero-actions, .actions { display: flex; align-items: center; flex-wrap: wrap; gap: .72rem; }
.hero-actions { margin-top: 1.75rem; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: .55rem; padding: .65rem 1.05rem; min-height: 2.8rem; border: 1px solid transparent; border-radius: 6px; text-decoration: none; line-height: 1.25; font-weight: 690; color: inherit; }
.button-primary { background: var(--navy); color: #fff; }
.button-primary:hover { background: var(--navy-2); }
.button-gold { background: var(--gold); color: #252218; }
.button-gold:hover { background: #ebcb98; }
.button-ghost { background: transparent; border-color: #a5b3c6; color: #fff; }
.button-ghost:hover { background: #fff1; }
.button-outline { background: var(--white); border-color: var(--line); }
.button-outline:hover { background: var(--wash); }
button:disabled { cursor: wait; opacity: .64; }
.hero-art { position: relative; display: grid; place-items: center; min-height: 19rem; }
.orbit { width: min(95%, 22rem); aspect-ratio: 1; position: absolute; border: 1px solid #d6b98638; border-radius: 50%; }
.orbit-inner { width: min(100%, 18rem); border-color: #e2bb8126; }
.paper { width: clamp(8rem, 15vw, 11.5rem); height: clamp(10rem, 19vw, 14.5rem); position: absolute; border-radius: 7px 18px 7px 7px; }
.paper-shadow { transform: translate(.9rem,.15rem) rotate(15deg); background: #2d415d; border: 1px solid #b7a38670; }
.paper-face { transform: translate(-.85rem,-.15rem) rotate(-9deg); padding: 1.45rem 1.25rem; background: #f4efdf; border: 1px solid #fff6de; box-shadow: 0 18px 44px #050e20aa; color: #70512c; }
.paper-face svg { width: 32px; height: 32px; }
.paper-line { display: block; height: 2px; width: 100%; margin-top: 12px; background: #aa9881; }
.paper-line:nth-of-type(3) { width: 71%; }
.paper-line:nth-of-type(4) { width: 40%; }
.art-seal { position: absolute; display: grid; place-items: center; left: 60%; top: 62%; width: 4.25rem; height: 4.25rem; border-radius: 50%; border: 1px solid #efcc92; background: var(--navy); color: var(--gold); box-shadow: 0 6px 30px #050c19ac; }
.art-seal svg { width: 25px; height: 25px; }
.entry { padding-block: clamp(2.7rem, 5vw, 4.3rem) 4.4rem; }
.entry h2 { margin-bottom: 1.35rem; }
.entry-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.entry-card { display: flex; align-items: flex-start; gap: .95rem; padding: clamp(1.15rem, 2.5vw, 1.6rem); border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); text-decoration: none; }
.entry-card:hover { border-color: #ab8a5d; }
.entry-card h3 { margin-bottom: .25rem; }
.entry-card p { color: var(--muted); }
.entry-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 8px; background: var(--wash); color: var(--gold-dark); flex: 0 0 auto; }
.footer { background: #eeeae3; border-top: 1px solid var(--line); color: var(--muted); }
.footer-inner { min-height: 4.4rem; padding-block: .8rem; font-size: .87rem; }
.footer-inner a { text-underline-offset: .23rem; }
.loading { min-height: 55vh; display: grid; place-content: center; }
.page { min-height: 65vh; padding-block: 2.9rem 4.8rem; }
.page-head { margin-bottom: 1.65rem; }
.page-head h1 { margin: .35rem 0 .6rem; font-size: clamp(2.45rem, 5.5vw, 4.1rem); }
.page-head p { max-width: 48rem; color: var(--muted); }
.panel { padding: clamp(1rem, 3vw, 1.65rem); background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.panel + .panel { margin-top: 1rem; }
.panel h2 { margin-bottom: .45rem; font-size: clamp(1.5rem, 3vw, 2rem); }
.panel > p { margin-bottom: .9rem; color: var(--muted); }
.panel .hint:last-child { margin-bottom: 0; }
.stack { display: grid; gap: 1rem; }
.stack > .panel { margin: 0; }
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem 1rem; }
.field { display: grid; min-width: 0; gap: .36rem; align-content: start; }
.field-wide { grid-column: 1 / -1; }
.field > label, .field-label { font-size: .94rem; font-weight: 680; }
.optional { color: var(--muted); font-weight: 475; font-size: .83rem; }
.field input, .field textarea, .field select { min-width: 0; width: 100%; border: 1px solid #aab0b7; border-radius: 6px; background: #fff; color: var(--ink); padding: .57rem .68rem; }
.field input:read-only, .field textarea:read-only, .field select:disabled { background: #f3f3ef; }
.field textarea { resize: vertical; min-height: 6.4rem; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, #495968 50%), linear-gradient(135deg, #495968 50%, transparent 50%); background-position: right 1.04rem center, right .76rem center; background-size: .3rem .3rem; background-repeat: no-repeat; padding-right: 2rem; }
.hint, .meta { color: var(--muted); font-size: .88rem; }
.file-box { border: 1px dashed #9ba2a9; padding: .9rem; border-radius: 8px; background: #f7f8f7; }
.file-box input { padding: .36rem; background: transparent; border: 0; }
.file-box input::file-selector-button { border: 1px solid var(--line); background: var(--white); border-radius: 4px; padding: .36rem .65rem; font: inherit; font-size: .9rem; cursor: pointer; margin-right: .6rem; }
.checkbox { display: grid; grid-template-columns: auto 1fr; align-items: start; gap: .65rem; }
.checkbox input { width: 1.1rem; height: 1.1rem; accent-color: var(--navy); margin: .25rem 0 0; }
.alert { padding: .75rem .9rem; color: var(--red); background: #fdf1ef; border: 1px solid #e4afaa; border-radius: 6px; overflow-wrap: anywhere; }
.notice { padding: .8rem .9rem; background: #f2ede2; border-radius: 6px; color: #52412c; }
.receipt { margin-top: 1.1rem; display: grid; gap: .7rem; }
.credential { display: grid; gap: .18rem; padding: .66rem .8rem; border: 1px solid var(--line); border-radius: 6px; background: #f5f5f2; }
.credential code { word-break: break-all; font-size: 1rem; color: var(--ink); }
.login { width: min(100% - 3rem, 30rem); margin: auto; }
.login .panel { padding: clamp(1rem, 5vw, 1.8rem); }
.login .actions { margin-top: .3rem; }
.bar { display: flex; align-items: flex-start; flex-wrap: wrap; justify-content: space-between; gap: .8rem; }
.bar h2 { margin-bottom: 0; }
.status { display: inline-block; padding: .24rem .62rem; font-size: .83rem; font-weight: 690; border-radius: 30px; border: 1px solid #d9dbd5; color: #3d4952; background: #f0f0ed; white-space: nowrap; }
.status.in_review { background: #f6ead2; color: #664411; border-color: #eadabd; }
.status.completed, .status.released { background: #e6efe9; color: #2e5744; border-color: #d0e0d7; }
.detail-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 1rem; align-items: start; }
.details { display: grid; gap: .75rem; margin: .9rem 0 0; }
.details dt { font-weight: 680; font-size: .89rem; }
.details dd { margin: .12rem 0 0; color: var(--muted); white-space: pre-wrap; overflow-wrap: anywhere; }
.list { margin: .55rem 0 0; padding: 0; list-style: none; }
.list li { border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding-block: .7rem; }
.list li:first-child { border-top: none; }
.list li > div { min-width: 0; overflow-wrap: anywhere; }
.list .button { font-size: .86rem; padding: .45rem .65rem; min-height: 2.25rem; white-space: nowrap; }
.back-link { display: inline-block; font-weight: 650; text-underline-offset: .22rem; margin-bottom: .75rem; }
.case-list { display: grid; margin: 0; padding: 0; list-style: none; }
.case-list li + li { border-top: 1px solid var(--line); }
.case-list a { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) auto; align-items: center; gap: .8rem; padding: .8rem .3rem; text-decoration: none; }
.case-list a:hover { background: #f5f2eb; }
.case-list strong { display: block; overflow-wrap: anywhere; }
.draft-form { margin-top: .8rem; }
.draft-card { border-top: 1px solid var(--line); margin-top: 1rem; padding-top: 1rem; }
.draft-card .field textarea { min-height: 15rem; }
.draft-content { margin-top: .65rem; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 24rem; overflow: auto; }
.release-confirm { position: fixed; max-width: min(31rem, calc(100% - 2rem)); border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); background: var(--white); padding: 1.5rem; }
.release-confirm::backdrop { background: #0f182caa; }
.release-confirm p { color: var(--muted); margin: .65rem 0 1rem; }
.status-form { margin-top: .9rem; }
.status-form .actions { align-items: end; }
.status-form .field { flex: 1; max-width: 17rem; }
@media (max-width: 740px) {
  .wrap, .narrow, .login { width: calc(100% - 2rem); }
  .hero-inner { grid-template-columns: 1fr; gap: .8rem; padding-top: 3rem; padding-bottom: 2.2rem; }
  .hero-art { min-height: 13.5rem; margin-inline: auto; width: 100%; }
  .orbit { width: min(80%, 14rem); }
  .orbit-inner { width: min(72%, 11rem); }
  .art-seal { left: calc(50% + 2.4rem); top: 59%; width: 3.4rem; height: 3.4rem; }
  .detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 525px) {
  .site-header .wrap { display: grid; gap: .4rem; padding-block: .55rem .45rem; }
  .top-nav { flex-wrap: wrap; gap: .25rem .75rem; }
  .nav-link { font-size: .875rem; }
  .nav-staff { padding: .24rem .54rem; }
  .brand-mark { width: 35px; height: 35px; }
  .entry-grid, .field-grid { grid-template-columns: 1fr; }
  .case-list a { grid-template-columns: minmax(0, 1fr) auto; }
  .case-list a .case-date { display: none; }
  .footer-inner { align-items: flex-start; flex-direction: column; gap: .2rem; }
  .page { padding-top: 2rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .button, .entry-card, .case-list a { transition: background-color .14s, border-color .14s; }
}