/* DARK-GUARD */
html[data-theme="dark"] body{background:#0B0B0B!important;color:#FFFFFF!important;}
html[data-theme="dark"] .wrap,html[data-theme="dark"] main,html[data-theme="dark"] section{background:transparent!important;}
/* Theme and depth layer. Brand colours remain white, black, red and yellow;
   neutral surfaces are mixtures/alpha of white and black, not a fifth brand colour. */
:root{--x-bg:color-mix(in srgb,#FFFFFF 96%,#0B0B0B);--x-surface:rgba(255,255,255,.78);--x-card:rgba(255,255,255,.86);--x-ink:#0B0B0B;--x-muted:rgba(11,11,11,.68);--x-line:rgba(11,11,11,.12);--x-shadow:0 16px 55px rgba(11,11,11,.07);--x-red:#B3261E;--x-yellow:#FFCD05;}
html[data-theme="dark"]{color-scheme:dark;--x-bg:#0B0B0B;--x-surface:rgba(255,255,255,.045);--x-card:rgba(255,255,255,.07);--x-ink:#FFFFFF;--x-muted:rgba(255,255,255,.72);--x-line:rgba(255,255,255,.16);--x-shadow:0 24px 60px rgba(0,0,0,.22);}
html[data-theme="light"]{color-scheme:light;}
html{scroll-padding-top:110px;}
html[data-theme] body.experience-world{background:var(--x-bg)!important;color:var(--x-ink)!important;}
html[data-theme] body.experience-world :is(.ex-hero,.ed-flat,.ed-plate,.ed-interlude,.sx-close,.sx-archive,.ex-page,.page-head,#chapter-close,.admin-pane,.stat-strip,.sector-stats){background:transparent!important;color:var(--x-ink)!important;}
html[data-theme] body.experience-world :is(.ex-card,.glass-card,.glass-card-dark,.sx-glass,.rb-panel,.ra-card,.ra-card-dark,.admin-module,.glass-nav,.glass-header,.tm-tile,.orbit-screen){background:var(--x-card)!important;color:var(--x-ink)!important;border-color:var(--x-line)!important;box-shadow:var(--x-shadow);backdrop-filter:blur(18px);}
html[data-theme] body.experience-world :is(.rb-nav,.mobile-menu,.tm-dialog,.tm-player,.ex-film){background:var(--x-surface)!important;color:var(--x-ink)!important;backdrop-filter:blur(22px);border-color:var(--x-line)!important;}
html[data-theme] body.experience-world :is(footer.footer,footer.rb-footer){background:var(--x-bg)!important;color:var(--x-ink)!important;border-top:1px solid var(--x-line);}
html[data-theme] body.experience-world :is(h1,h2,h3,h4,h5,h6,p,label,summary,th,td,.ex-meta,.ex-count,.ex-stat,.sidebar-link,.logo,.ra-muted,.ra-eyebrow,.muted-xs,.ra-nav a,.nav-links a,footer a,footer p,footer span){color:var(--x-ink)!important;}
html[data-theme] body.experience-world :is(.ex-lead,.ex-meta,.ex-count,.admin-hub-toolbar p,.ex-light-label){color:var(--x-muted)!important;}
html[data-theme] body.experience-world :is(input,select,textarea,.ra-table-wrap,.ra-table th,.ra-table td){background:var(--x-card)!important;color:var(--x-ink)!important;border-color:var(--x-line)!important;}
html[data-theme] body.experience-world input::placeholder,html[data-theme] body.experience-world textarea::placeholder{color:var(--x-muted)!important;}
html[data-theme] body.experience-world .btn{background:#B3261E!important;color:#FFFFFF!important;border-color:#B3261E!important;}
html[data-theme] body.experience-world .btn.ghost{background:var(--x-surface)!important;color:var(--x-ink)!important;border-color:var(--x-line)!important;}
html[data-theme] body.experience-world :is(.ex-tag,.btn.gold,[data-county-view][aria-pressed="true"]){background:#FFCD05!important;color:#0B0B0B!important;}
html[data-theme] body.experience-world :is(.ex-tag--red,.btn-primary){background:#B3261E!important;color:#FFFFFF!important;}
html[data-theme] body.experience-world :is(.sidebar-link-active,.ra-nav a[aria-current="page"]){background:rgba(179,38,30,.16)!important;color:var(--x-ink)!important;border-left:3px solid #B3261E;}
html[data-theme] body.experience-world :is(.ra-nav,.ra-table-wrap,.ex-bar,.admin-entity){border-color:var(--x-line)!important;}
html[data-theme] body.experience-world .ex-go{color:#B3261E!important;}html[data-theme="dark"] body.experience-world .ex-go{color:#FFCD05!important;}
html[data-theme="dark"] body.experience-world :is([class*="text-zinc"],[class*="text-gray"],[class*="text-slate"],[class*="text-black"],.orbit-caption,.rb-fallback){color:var(--x-ink)!important;}
html[data-theme="dark"] body.experience-world :is([class*="bg-white"],[class*="bg-gray-"],[class*="bg-zinc-"],[class*="bg-slate-"],.ra-card,.ra-nav a,.ra-table-wrap){background:var(--x-card)!important;}
html[data-theme="dark"] body.experience-world :is(.btn,.btn-primary,.ex-tag--red),html[data-theme="dark"] body.experience-world :is(.btn,.btn-primary,.ex-tag--red) *{color:#FFFFFF!important;}
html[data-theme="dark"] body.experience-world :is(.btn.ghost,.btn.ghost *),html[data-theme="dark"] body.experience-world .nav-cta .btn.ghost{color:#FFFFFF!important;}
html[data-theme="dark"] body.experience-world :is(.ex-tag,.ex-illustration-note){color:#0B0B0B!important;}html[data-theme="dark"] body.experience-world .ex-illustration-note{background:rgba(255,255,255,.95)!important;}
html[data-theme="dark"] body.experience-world .ex-tag--red{color:#FFFFFF!important;}
html[data-theme] body.experience-world :is(.tm-dialog,.ex-film)::backdrop{background:rgba(11,11,11,.42)!important;}
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:38px;min-width:68px;border:1px solid var(--x-line);border-radius:40px;padding:7px 12px;background:var(--x-surface);color:var(--x-ink);font:600 11px/1.2 'Inter Tight',sans-serif;cursor:pointer;}
.theme-toggle[aria-pressed="true"]{border-color:rgba(255,205,5,.45);}
.nav-cta{gap:8px!important;flex-wrap:wrap;}.nav-cta form{margin:0;}.rb-nav .nav-inner{gap:14px;}.nav-links{gap:10px!important;}
.experience-world .ex-hero{padding-top:85px;padding-bottom:80px;position:relative;isolation:isolate;overflow:hidden;}.ex-hero>.wrap{position:relative;z-index:2;}.ex-hero h1{max-width:920px;}
.depth-graphic{position:absolute;right:-4%;top:0;width:min(55vw,850px);height:100%;min-height:330px;z-index:-1;pointer-events:none;opacity:.26;}
.depth-graphic canvas{display:block;width:100%;height:100%;}.depth-graphic[data-state="fallback"]{background:repeating-radial-gradient(ellipse at 70% 45%,transparent 0 34px,rgba(179,38,30,.1) 35px 36px,transparent 37px 68px);transform:perspective(900px) rotateY(-25deg);}
html[data-theme="dark"] .depth-graphic{opacity:.45;}
.depth-card{transform-style:preserve-3d;will-change:transform;transition:box-shadow .25s,transform .22s;}.depth-card .ex-shot{transform:translateZ(8px);}.depth-card .ex-body{transform:translateZ(14px);}
.depth-reveal{transition:opacity .7s ease,transform .9s cubic-bezier(.22,1,.36,1);}.depth-reveal:not(.is-visible){opacity:1;transform:none;}
.depth-progress{position:fixed;top:0;left:0;height:3px;width:100%;transform-origin:left;transform:scaleX(var(--scroll-progress,0));background:linear-gradient(90deg,#B3261E,#FFCD05);z-index:9999;pointer-events:none;}
.admin-hub{padding:24px 0 90px;}.admin-hub-toolbar{display:flex;flex-wrap:wrap;align-items:end;gap:20px;margin-bottom:24px;}.admin-hub-toolbar label{display:grid;gap:8px;min-width:min(100%,340px);}.admin-hub-toolbar p{max-width:460px;font-size:13px;line-height:1.6;}
.admin-hub input,.admin-hub select,.admin-module input,.admin-module select,.admin-module textarea{padding:12px;border:1px solid var(--x-line);border-radius:12px;width:100%;font:inherit;}
.admin-module{padding:clamp(20px,3vw,36px);border:1px solid var(--x-line);border-radius:24px;margin-bottom:25px;}.admin-module h2{font:500 clamp(22px,2.8vw,35px)/1.15 Fraunces,serif;margin:0 0 20px;}.admin-module small{font:500 11px/1.5 'Inter Tight',sans-serif;opacity:.7;}
.admin-link-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:10px;}.admin-control-link{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border:1px solid var(--x-line);border-radius:12px;color:var(--x-ink);text-decoration:none;background:var(--x-surface);font-size:13px;line-height:1.5;transition:transform .2s,border-color .2s;}.admin-control-link:hover{transform:translateY(-2px);border-color:rgba(179,38,30,.45);}
.admin-entity{padding:14px 0;border-top:1px solid var(--x-line);}.admin-entity summary{cursor:pointer;display:flex;justify-content:space-between;gap:18px;font-size:14px;}.admin-entity summary span{font-size:11px;opacity:.65;}.admin-entity>.admin-link-grid{margin-top:18px;}
.admin-hierarchy{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;}.admin-hierarchy label{display:grid;gap:8px;}.admin-hierarchy-actions,.admin-hierarchy>p{grid-column:1/-1;}.admin-hierarchy-actions{display:flex;gap:12px;flex-wrap:wrap;}
.admin-route-table{overflow:auto;max-height:500px;}.admin-route-table table{border-collapse:collapse;width:100%;font:11px/1.5 'JetBrains Mono',monospace;}.admin-route-table td,.admin-route-table th{padding:12px;border-bottom:1px solid var(--x-line);text-align:left;word-break:break-word;}
.component-control{padding:20px;margin:14px 0;border:1px solid var(--x-line);border-radius:16px;}.component-control header{display:flex;justify-content:space-between;gap:10px;}.component-control textarea{min-height:95px;margin-top:14px;}.component-control .component-actions{display:flex;gap:12px;align-items:center;margin-top:14px;}.component-control .component-source{font:11px/1.6 'JetBrains Mono',monospace;word-break:break-word;opacity:.7;}
@media(max-width:1100px){.nav-links{display:none!important}.rb-nav .burger{display:block!important}.depth-graphic{width:75vw;opacity:.16;}.nav-cta .ex-light-label{display:none;}}
@media(max-width:760px){.admin-hierarchy{grid-template-columns:1fr}.ex-hero{padding-top:65px!important;padding-bottom:55px!important}.depth-graphic{width:100%;right:-25%;opacity:.14;}.nav-cta{gap:5px!important}.nav-cta .btn.sm,.theme-toggle{padding:7px 9px!important;font-size:10px!important}.admin-hub{padding-left:15px;padding-right:15px}.admin-entity summary{display:grid;}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto!important}.depth-reveal:not(.is-visible){opacity:1;transform:none}.depth-reveal,.depth-card{transition:none!important;transform:none!important}.depth-graphic{display:none}.depth-progress{display:none}*{animation-duration:.01ms!important;}}

/* Sub-pixel ink anchor + hero heading colour per theme. */
html[data-theme] body.experience-world :is(h1,h2,h3,h4,h5,h6,p,label,summary,th,td,.ex-meta,.ex-count,.sidebar-link,.logo,.muted-xs,.ra-muted,.nav-links a,footer a){text-shadow:.02px .02px 0 var(--x-ink)!important;}
html[data-theme="light"] body.experience-world .ex-hero h1,html[data-theme="light"] body.experience-world .sx-hero h1{color:#0B0B0B!important;}
html[data-theme="dark"] body.experience-world .ex-hero h1,html[data-theme="dark"] body.experience-world .sx-hero h1{color:#FFFFFF!important;}
