/* Original antique journal background, shared by portal and app. */
:root{--bg:#191e21;--panel:#272b2a;--border:#756c56;--gold:#e3c58b;--text:#f4eddf;--muted:#c4bba9;--accent:#a8d2bb}
html body{background:linear-gradient(#111d24b3,#172027c4),url('/assets/antique-book.png') center top/1440px auto repeat-y;background-color:#172027}
main{background:linear-gradient(#252b2ae8,#202725ed);border-left:3px double #a18459;border-right:3px double #a18459;min-height:100vh;box-shadow:0 0 70px #0008}
header{border-bottom:3px double #a18459}.mark,.badge{background:#413a2a;border-color:#a88b5a}.panel{background:linear-gradient(#30332ef5,#282e2af7),url('/assets/antique-book.png') center/1000px auto;border-color:#a18459;box-shadow:0 18px 40px #0005,inset 0 0 0 5px #c9ac7320}.mode-nav{background:#222b2b}.mode-nav button[aria-pressed=true]{background:#bda06620}.type{background:linear-gradient(125deg,#c9ac730e,transparent),#27302e}.result,.check-item{background:#232a26}.spell-guide{background:#2b2b2b;border-color:#99836b;border-top-color:#c8b397}.spell-guide>.eyebrow,.spell-effects li:before{color:#d5bea3}.spell-effects li{border-color:#8f796344}.spell-note{border-color:#bca58a;background:#ad926915}.portal .app-card{background:linear-gradient(130deg,#303b35,#292d29);border-color:#9a855f;border-top-color:#d2b47a}.portal .brand-dot{color:#dcc38f}.portal .app-open{background:#d9bd86;color:#242e28}.portal .app-open:hover{background:#efd9b0}
html[data-theme=light]{--bg:#d9c9a8;--panel:#f1e6cb;--border:#a79371;--gold:#705025;--text:#302f26;--muted:#635b4b;--accent:#285843}
html[data-theme=light] body{background:linear-gradient(#e5d4ad12,#e5d4ad12),url('/assets/antique-book.png') center top/1440px auto repeat-y;background-color:#d9c9a8}
html[data-theme=light] main{background:linear-gradient(#f5ebd3de,#eee0c2e8);border-color:#896e47;box-shadow:0 0 60px #2b211c45}
html[data-theme=light] header{border-bottom-color:#9c7e51}html[data-theme=light] .mark,html[data-theme=light] .badge{background:#f4e5c4;border-color:#9b7841;outline-color:#9b7841}
html[data-theme=light] .panel{background:linear-gradient(#f7efdbe8,#f4e8cfe8),url('/assets/antique-book.png') center/1000px auto;border-color:#9c8055;box-shadow:0 18px 42px #55422622,inset 0 0 0 5px #b5975f20}
html[data-theme=light] .mode-nav{background:#efe3c9}html[data-theme=light] .mode-nav button[aria-pressed=true],html[data-theme=light] .theme-controls button[aria-pressed=true]{background:#dfcfaa}
html[data-theme=light] button{background:#efe3c9}html[data-theme=light] button:hover{background:#e3d3af}html[data-theme=light] button:active{background:#d9c398}html[data-theme=light] .type{background:linear-gradient(125deg,#faf3e4,#eaddc0)}
html[data-theme=light] .topline{border-bottom-color:#c7b897}html[data-theme=light] .result,html[data-theme=light] .check-item{background:#faf2df}html[data-theme=light] .notice{background:#ebdab5}
html[data-theme=light] input,html[data-theme=light] select{background:#fff9eb}html[data-theme=light] th{background:#e6d6b3}html[data-theme=light] th,html[data-theme=light] td{border-bottom-color:#d0c09e}html[data-theme=light] tbody tr:nth-child(even){background:#efe2c944}html[data-theme=light] tbody tr:hover{background:#e5d1a64d}
html[data-theme=light] .spell-guide{background:#f0e4cb;border-color:#ac9773;border-top-color:#967c53}html[data-theme=light] .spell-guide>.eyebrow,html[data-theme=light] .spell-effects li:before{color:#73572e}html[data-theme=light] .spell-effects li{background:#faf2df;border-color:#c7b794}html[data-theme=light] .spell-note{background:#e6d6b5;border-color:#967c53}
html[data-theme=light] .report-dialog{background:#faf2df}html[data-theme=light] .report-dialog input,html[data-theme=light] .report-dialog textarea{background:#fff9ed}html[data-theme=light] .portal .app-card{background:linear-gradient(130deg,#f8f0dc,#e9dbbd);border-color:#ab946d;border-top-color:#37624e}html[data-theme=light] .portal .brand-dot{color:#37624e}html[data-theme=light] .portal .app-features{color:#4b5141}html[data-theme=light] .portal .app-open{background:#315e4c;color:#fff8e7}html[data-theme=light] .portal-intro p,html[data-theme=light] .section-heading span,html[data-theme=light] .app-note{color:#635b4b}
@media(max-width:550px){html body,html[data-theme=light] body{background-size:900px auto}main{margin:0 9px;padding-left:14px;padding-right:14px}.portal{margin:0 9px}}
