:root {
    --ink: #1e302b; --pine: #19382f; --dark: #172f29; --accent: #f7af79; --terra: #a64e2c;
    --paper: #f7f6f1; --white: #fffefa; --line: #dcded4; --muted: #647069; --sage: #e5eee4;
    font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    color: var(--ink); background: var(--paper); font-synthesis: none;
}
* { box-sizing: border-box }
body { margin: 0 }
a { color: inherit; text-decoration: none }
button, input, select, textarea { font: inherit }
button, summary { cursor: pointer }
:focus-visible { outline: 3px solid #c36c37; outline-offset: 3px }
.shell { min-height: 100vh; display: grid; grid-template-columns: 230px minmax(0, 1fr) }
aside { background: var(--dark); color: #e7eee8; padding: 37px 20px 21px; display: flex; flex-direction: column; min-height: 100vh; position: sticky; top: 0; height: 100vh }
.brand { display: inline-flex; gap: 10px; align-items: center; width: fit-content }
aside .brand { margin: 0 7px 40px }
.brandmark { display: inline-flex; width: 31px; height: 31px; flex-direction: column; justify-content: center; gap: 3px; transform: skewX(-12deg); color: var(--accent) }
.brandmark i { display: block; height: 5px; width: 24px; background: currentColor }
.brandmark i:nth-child(2) { width: 29px }
.brandmark i:last-child { width: 18px }
.brandname { font: bold 29px/.95 Georgia, serif; letter-spacing: -1.6px }
.brandname span { color: var(--accent) }
.project-switch { position: relative; margin-bottom: 25px; background: #254137; border: 1px solid #456052; border-radius: 10px }
summary { list-style: none }
summary::-webkit-details-marker { display:none }
.project-switch summary { display: flex; align-items: center; padding: 11px 10px; gap: 9px }
.project-switch summary>span:nth-child(2) { flex: 1; min-width: 0 }
.project-switch summary b, .project-switch summary small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.project-switch summary small { color: #c3d0c6; font-size: 10px }
.project-switch summary b { font-size: 14px; font-weight: 620 }
.avatar { background: #ebdec4; color: #314537; border-radius: 6px; min-width: 31px; height: 33px; display: grid; place-content: center; font: bold 20px Georgia, serif }
.project-menu { position: absolute; z-index: 4; left: 0; right: 0; margin-top: 6px; background: #254137; border: 1px solid #52695d; border-radius: 7px; padding: 5px; box-shadow: 0 8px 14px #0002 }
.project-menu a { display: flex; align-items: center; gap: 6px; padding: 7px 10px; overflow-wrap: anywhere }
.project-menu a:hover { background:#355247 }
nav { display: grid; gap: 4px }
nav a, .logout button { display:flex; align-items: center; gap:13px; font-size: 14px; color: #cfdbd0; width:100%; padding: 11px 13px; border-radius: 7px; font-weight: 550 }
nav a.active { background: #345043; color: #fff9ee; box-shadow: inset 3px 0 var(--accent) }
nav a.active svg { color:var(--accent) }
nav a:hover, .logout button:hover { background: #29463a }
nav a:last-child { margin-top: 17px }
.logout { margin-top: auto; padding-top: 25px }
.logout button { border:0; background:none; color: #becac1 }
.stage { min-width:0 }
.topline { display:flex; justify-content:space-between; align-items:center; min-height:65px; padding: 0 clamp(20px,4vw,70px); border-bottom:1px solid var(--line); font-size:12px; color:var(--muted); gap:12px }
.topline span { display:inline-flex; align-items:center; gap:9px }
.topline span:first-child { flex-wrap:wrap }
.topline i { font-style:normal; color:#aaaea6 }
.topline b { font-weight:600; color:var(--ink) }
.account i, .tag i { width:6px; height:6px; background:#688a6d; display:inline-block; border-radius:50% }
main { max-width:1510px; margin:auto; padding:42px clamp(20px,4vw,70px) 65px }
.pagehead { display:flex; justify-content:space-between; align-items:center; gap:20px; margin-bottom:29px }
h1,h2,h3,p { margin:0 }
h1,h2 { text-wrap:pretty }
h1 { font:500 clamp(36px,4.2vw,68px)/1.07 Georgia,"Times New Roman",serif; letter-spacing:-.052em; overflow-wrap:anywhere }
h2 { font:500 clamp(22px,2.1vw,30px)/1.17 Georgia,"Times New Roman",serif; letter-spacing:-.035em }
h3 { font-size:17px; line-height:1.35; letter-spacing:-.02em }
.eyebrow { color:var(--terra); font-weight:750; font-size:11px; text-transform:uppercase; letter-spacing:.14em; margin-bottom:10px }
.btn { border:1px solid transparent; display:inline-flex; justify-content:center; align-items:center; gap:8px; border-radius:7px; padding:10px 15px; font-weight:650; font-size:13px; line-height:1.5; white-space:normal; text-align:center; flex-shrink:0 }
.btn.primary { background:var(--pine); color:#fffdf4; border-color:var(--pine) }
.btn.primary:hover { background:#2e5042 }
.btn.soft { background:var(--white); color:var(--ink); border-color:#cdd3c8 }
.btn.soft:hover { background:#edf0e7 }
.btn:disabled { opacity:.5; cursor:default }
.stats { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); margin-bottom:26px; border:1px solid var(--line); border-radius:12px; background:var(--white); overflow:hidden }
.stat { padding:20px 22px 18px; border-right:1px solid var(--line) }
.stat:last-child { border:0 }
.stat div { display:flex; align-items:center; gap:8px; color:var(--muted); font-size:13px }
.stat svg { color:#8d593e }
.stat strong,.reviewcount strong { display:block; font:500 40px/1.1 Georgia,serif; margin-top:8px; font-variant-numeric:tabular-nums }
.twocol,.compose { display:grid; grid-template-columns:minmax(0,1.8fr) minmax(245px,1fr); gap:20px; align-items:stretch; margin-bottom:20px }
.twocol.equal { grid-template-columns:1fr 1fr }
.compose { align-items:start; grid-template-columns:minmax(0,1.7fr) minmax(245px,1fr) }
.panel { background:var(--white); border:1px solid var(--line); border-radius:12px; min-width:0 }
main>.panel+.panel { margin-top:20px }
.panelhead { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:21px 23px; border-bottom:1px solid var(--line) }
.panelhead h2 { font-size:24px }
.panelhead h2 small { display:inline-block; vertical-align:middle; font:600 12px/1.5 -apple-system,Arial,sans-serif; background:#e9ede3; color:#445747; border-radius:20px; padding:1px 9px; margin-left:5px }
.textlink,.crumb { display:inline-flex; align-items:center; gap:6px; color:var(--pine); font-weight:650; font-size:13px }
.textlink:hover,.rowlink:hover,.crumb:hover { text-decoration:underline }
.crumb { color:var(--muted); margin-bottom:9px }
.empty { display:flex; flex-direction:column; align-items:center; justify-content:center; min-height:255px; padding:33px 25px; text-align:center }
.empty>svg { color:var(--muted); margin-bottom:15px }
.empty>p { font-size:14px; color:var(--muted); margin:7px 0 17px; max-width:350px }
.papers { width:65px; height:57px; position:relative; margin-bottom:15px }
.papers:before,.papers i,.papers b { content:""; position:absolute; width:39px; height:47px; border-radius:2px; border:1.3px solid #748272; top:4px; background:#ebd6b7 }
.papers:before { transform:rotate(-17deg); left:7px }
.papers i { transform:rotate(-4deg); left:13px; background:#ebece0 }
.papers b { transform:rotate(8deg); left:20px; background:repeating-linear-gradient(to bottom,#91a090 0 1px,transparent 1px 5px) 6px 21px/25px 17px no-repeat,linear-gradient(#6f806e,#6f806e) 6px 7px/15px 7px no-repeat,#faf8eb }
.researchcard { padding:23px; background:linear-gradient(130deg,#f3e7d2,#f4eddd); border-color:#e2d5be; display:flex; flex-direction:column; align-items:flex-start }
.lens,.symbol,.stripicon { width:38px; height:38px; display:grid; place-content:center; border-radius:9px; background:#e4e9dc; color:var(--pine) }
.lens { background:#ead4b3; color:#6b4828; margin-bottom:19px }
.researchcard h2 { max-width:320px; font-size:clamp(25px,2.7vw,34px) }
.researchcard .eyebrow { margin-bottom:5px }
.searchform { width:100% }
.researchcard .searchform { margin:16px 0 }
.researchcard .textlink { margin-top:auto }
.input-action { display:flex; gap:6px }
.input-action input { min-width:0; flex:1 }
.input-action .btn { padding:9px 12px }
.strip { display:flex; gap:15px; align-items:center; padding:20px 23px }
.strip h3 { font-size:15px }
.strip p { color:var(--muted); font-size:13px; margin-top:2px }
.strip .btn { margin-left:auto }
label { display:block; font-weight:650; font-size:13px; color:#34443a }
label input:not([type=checkbox]),label textarea,label select,.searchform .input-action { margin-top:6px }
input:not([type=checkbox]):not([type=hidden]),select,textarea { width:100%; min-width:0; padding:10px 12px; color:var(--ink); border:1px solid #cbd2c7; border-radius:6px; background:#fffeFA; font-size:14px; line-height:1.4; font-weight:400 }
input:read-only { color:#637166 }
textarea { resize:vertical }
input::placeholder, textarea::placeholder { color:#828a80 }
input[type=checkbox] { accent-color:var(--pine); width:16px; height:16px; flex-shrink:0 }
.formpanel { padding:24px; display:flex; flex-direction:column; align-items:stretch; gap:17px }
.formpanel form { display:flex; flex-direction:column; gap:13px }
.formpanel>.btn,.formpanel form>.btn { align-self:flex-start }
.fieldgrid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:15px 20px }
.check { display:flex; gap:9px; align-items:flex-start; font-weight:500 }
.check input { margin:2px 0 0 }
.help,.sub,.pager,.recipient small { color:var(--muted); font-size:13px }
.actions { display:flex; align-items:center; gap:10px; border-top:1px solid var(--line); padding-top:17px }
.scroll { overflow:auto }
table { width:100%; border-collapse:collapse; text-align:left; font-size:14px }
th { font-size:11px; text-transform:uppercase; letter-spacing:.06em; color:var(--muted); background:#f4f4ed }
td,th { padding:12px 17px; border-bottom:1px solid var(--line) }
tr:last-child td { border-bottom:0 }
td small,.recipient small { display:block; color:var(--muted); font-size:12px; margin-top:2px }
td:first-child { overflow-wrap:anywhere }
.rowlink { font-weight:600 }
.tag { display:inline-flex; gap:6px; align-items:center; color:#48564a; background:#eef0e9; border-radius:30px; padding:3px 9px; font-size:11px; font-weight:650; white-space:nowrap }
.tag.muted i { background:#888f84 }
.tag.ok { background:#e1eedf; color:#355737 }
.tag.warm { background:#f4e3c9; color:#7b5025 }
.tag.warm i { background:#ad7234 }
.filters,.pager { display:flex; align-items:center; gap:8px; padding:15px 20px; flex-wrap:wrap }
.filters>input:not([type=hidden]) { flex:2; min-width:160px }
.filters select { flex:1; min-width:120px }
.pager { justify-content:center }
.resultrow,.recipient summary { display:flex; gap:15px; justify-content:space-between; align-items:center; padding:15px 23px; border-top:1px solid var(--line) }
.resultrow b { overflow-wrap:anywhere }
.resultrow .btn { white-space:nowrap }
.resultbox { padding:13px; background:#f2f4ec; border-radius:6px }
.resultbox p { margin-top:4px }
.inset { padding:15px 23px }
.recipient summary>span:last-child { display:flex; align-items:center; gap:8px }
.recipient-body { padding:0 23px 20px; max-width:640px }
.recipient-body form { display:grid; justify-items:start; gap:10px; margin-top:12px }
.recipient-body form label { width:100% }
.original { margin-top:18px; padding:16px 22px }
.original summary { font-weight:600 }
.original p { margin-top:18px }
.message { white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.7 }
hr { border:0; border-top:1px solid var(--line); width:100%; margin:0 }
.reviewcount { display:flex; align-items:baseline; gap:10px }
.notice { padding:12px 16px; border-radius:7px; border:1px solid #b9d1b6; background:#ebf3e8; color:#2c522f; margin-bottom:18px }
.notice.error { border-color:#e0ada1; background:#fbede7; color:#873c2e }
code { background:#edeee5; border-radius:3px; padding:1px 4px }
.gate { background:var(--dark); min-height:100vh; display:grid; place-items:center; padding:24px }
.loginbox { background:var(--paper); padding:clamp(25px,5vw,47px); border-radius:13px; width:min(440px,100%); box-shadow:0 20px 100px #081c1730 }
.loginbox .brand { margin-bottom:36px }
.loginbox .brandmark { color:#a95835 }
.loginbox h1 { font-size:40px; margin-bottom:24px }
.loginbox form { display:grid; gap:12px }
.loginbox>p { margin-bottom:15px }
[hidden] { display:none!important }
@media (min-width:1600px){ .shell{grid-template-columns:255px minmax(0,1fr)} }
@media (max-width:1100px){ .shell{grid-template-columns:195px minmax(0,1fr)} aside{padding-left:12px;padding-right:12px} .stat{padding:16px 12px} main{padding-left:24px;padding-right:24px} .twocol,.compose{gap:14px} }
@media (max-width:850px){ .twocol,.compose,.twocol.equal{grid-template-columns:1fr}.researchcard h2{max-width:none}.stats{grid-template-columns:1fr 1fr}.stat:nth-child(2){border-right:0}.stat:nth-child(-n+2){border-bottom:1px solid var(--line)}.pagehead{align-items:flex-start}.pagehead .btn{max-width:155px} }
@media (max-width:680px){ .shell{display:block}aside{height:auto;min-height:0;position:relative;padding:14px 15px 10px;display:grid;grid-template-columns:1fr auto;align-items:center;gap:12px}aside .brand{margin:0}.brandname{font-size:24px}.brandmark{transform:scale(.85) skewX(-12deg)}.project-switch{margin:0}.project-switch summary{padding:4px 8px}.project-switch summary small,.avatar{display:none}.project-switch summary b{max-width:130px}nav{grid-column:1/-1;display:flex;gap:2px;overflow-x:auto}nav a{width:auto;display:inline-flex;gap:5px;padding:8px 7px;font-size:12px;flex-shrink:0}nav a:last-child{margin:0}nav a.active{box-shadow:inset 0 -2px var(--accent)}nav svg{width:15px}.logout{padding:0;position:absolute;right:13px;bottom:-37px}.logout button{font-size:11px;padding:5px;color:#516258;gap:4px}.logout button:hover{background:#e5e9dd}.topline{min-height:45px;padding:0 75px 0 16px}.topline .account{display:none}main{padding:25px 16px 50px}.pagehead{margin-bottom:20px;flex-wrap:wrap}.pagehead .btn{max-width:none}.fieldgrid{grid-template-columns:1fr}.strip{flex-wrap:wrap}.strip .btn{margin:0}.formpanel,.researchcard{padding:19px}.panelhead{padding:16px}.resultrow{align-items:flex-start;flex-wrap:wrap}.stat strong{font-size:31px}.stat div{font-size:12px}.recipient summary{padding:12px}.topline span{gap:5px} }
