/* The game's campaign button: a 5px pixel step, 3px light top and 4px dark bottom. */
:root { --px-cut: 5px; --px-light: #ffffff59; --px-dark: #00000073; --px-button-shape: polygon(0 var(--px-cut),var(--px-cut) var(--px-cut),var(--px-cut) 0,calc(100% - var(--px-cut)) 0,calc(100% - var(--px-cut)) var(--px-cut),100% var(--px-cut),100% calc(100% - var(--px-cut)),calc(100% - var(--px-cut)) calc(100% - var(--px-cut)),calc(100% - var(--px-cut)) 100%,var(--px-cut) 100%,var(--px-cut) calc(100% - var(--px-cut)),0 calc(100% - var(--px-cut))); }
/* Navigation keeps its own flat layout; only action controls receive the bevel. */
html:root body:is(.home-page,.wiki-page,.forum-page,.legal-page,.media-page,.creators-page,.admin-page) :is(button:not(.admin-preview-mode,.intro-button,.gallery-choice,.orbit-selection,.tab,.news-art,.news-copy,.feature-tile,.guide-world,.text-link,.circle-button,.wiki-save,.post-like,.presence-more,.presence-less,.forum-search>button,.post-header-actions>button,.forum-editor-tools>button,.editor-image-picker button,.profile-cover-link,[role="tab"]):not(.main-menu *):not(.account-tabs *):not(.world-controls *):not(.red-sky-stage-controls *):not(.wiki-model-controls *):not(.engine-camera *):not(.engine-views *):not(.echo-chapters *):not(.wiki-feed-tabs *),a.pill-button,a.c-button,a.wiki-white-button,.c-pagination a,.back-to-top) {
 --px-button-shape: polygon(0 var(--px-cut),var(--px-cut) var(--px-cut),var(--px-cut) 0,calc(100% - var(--px-cut)) 0,calc(100% - var(--px-cut)) var(--px-cut),100% var(--px-cut),100% calc(100% - var(--px-cut)),calc(100% - var(--px-cut)) calc(100% - var(--px-cut)),calc(100% - var(--px-cut)) 100%,var(--px-cut) 100%,var(--px-cut) calc(100% - var(--px-cut)),0 calc(100% - var(--px-cut)));
 border-radius: 0 !important; border-width: 0 !important; clip-path: var(--px-button-shape) !important;
 box-shadow: inset 0 3px var(--px-light),inset 0 -4px var(--px-dark) !important;
 transition: background-color .18s,color .18s,filter .18s;
}
html:root body:is(.home-page,.wiki-page,.forum-page,.legal-page,.media-page,.creators-page,.admin-page) :is(button:not(.admin-preview-mode,.intro-button,.gallery-choice,.orbit-selection,.tab,.news-art,.news-copy,.feature-tile,.guide-world,.text-link,.circle-button,.wiki-save,.post-like,.presence-more,.presence-less,.forum-search>button,.post-header-actions>button,.forum-editor-tools>button,.editor-image-picker button,.profile-cover-link,[role="tab"]):not(.main-menu *):not(.account-tabs *):not(.world-controls *):not(.red-sky-stage-controls *):not(.wiki-model-controls *):not(.engine-camera *):not(.engine-views *):not(.echo-chapters *):not(.wiki-feed-tabs *),a.pill-button,a.c-button,a.wiki-white-button,.c-pagination a,.back-to-top):active:not(:disabled) { box-shadow: inset 0 4px var(--px-dark),inset 0 -2px var(--px-light) !important; }
html:root body:is(.home-page,.wiki-page,.forum-page,.legal-page,.media-page,.creators-page,.admin-page) :is(button:not(.admin-preview-mode,.intro-button,.gallery-choice,.orbit-selection,.tab,.news-art,.news-copy,.feature-tile,.guide-world,.text-link,.circle-button,.wiki-save,.post-like,.presence-more,.presence-less,.forum-search>button,.post-header-actions>button,.forum-editor-tools>button,.editor-image-picker button,.profile-cover-link,[role="tab"]):not(.main-menu *):not(.account-tabs *):not(.world-controls *):not(.red-sky-stage-controls *):not(.wiki-model-controls *):not(.engine-camera *):not(.engine-views *):not(.echo-chapters *):not(.wiki-feed-tabs *),a.pill-button,a.c-button,a.wiki-white-button):focus-visible { outline: none; filter: brightness(1.2); box-shadow: inset 0 3px var(--px-light),inset 0 -4px var(--px-dark),inset 0 0 0 2px #efccff !important; }
html:root body :is(.c-close,.circle-button,.dialog-close,.wiki-save,.red-sky-stage-controls button,.wiki-model-controls button,.c-pagination a,.forum-pagination a) { --px-cut: 3px; }
html:root body .circle-button { aspect-ratio: 1; }
html:root body .red-sky-skill-picker button { --px-cut: 3px; }
/* Shared feedback also covers flat utility buttons without changing their shape. */
@media (hover: hover) {
 body:is(.home-page,.wiki-page,.forum-page,.legal-page,.media-page,.creators-page,.admin-page) :where(button,a.c-button,a.pill-button,a.wiki-white-button,.c-pagination a,.back-to-top):hover:not(:disabled):not([aria-disabled="true"]) { filter: brightness(1.16); }
}
@media(prefers-reduced-motion:reduce) { html:root body :is(button,a.c-button,a.pill-button,a.wiki-white-button,.c-pagination a,.back-to-top) { transition: none; } }

/* Authentication tabs are navigation; the selected underline never crosses its label. */
.account-tabs button { position: relative; min-height: 40px; border: 0; padding: 6px 0 13px; }
.account-tabs button.active::after { content: ""; position: absolute; inset: auto 0 0; height: 2px; background: #ad86ec; }
.account-dialog .c-close { width: 32px; height: 32px; background: #302039; }
html:root body svg.pixel-ui-icon { fill: currentColor; stroke: none; shape-rendering: crispEdges; }

/* Tabs, whole-content targets and viewer tools are flat controls, never action buttons. */
html:root body :is(.tab,[role="tab"],.news-art,.news-copy,.feature-tile,.guide-world,.text-link,.circle-button,.wiki-save,.world-controls button,.red-sky-stage-controls button,.wiki-model-controls button,.engine-camera button,.engine-views button,.wiki-feed-tabs button,.echo-chapters button):is(:hover,:active,:focus-visible),
html:root body :is(.tab,[role="tab"],.news-art,.news-copy,.feature-tile,.guide-world,.text-link,.circle-button,.wiki-save,.world-controls button,.red-sky-stage-controls button,.wiki-model-controls button,.engine-camera button,.engine-views button,.wiki-feed-tabs button,.echo-chapters button){clip-path:none!important;box-shadow:none!important}
html:root body :is(.tab,[role="tab"],.guide-world,.news-art,.news-copy,.text-link,.circle-button,.world-controls button,.red-sky-stage-controls button,.wiki-model-controls button,.engine-camera button,.engine-views button):focus-visible{outline:2px solid #bb95f0;outline-offset:4px}
html:root body .world-controls button{display:grid;place-items:center;padding:0!important;width:42px;height:42px;min-width:42px;line-height:1;font-family:Arial,sans-serif;font-size:23px;border:0;border-radius:0;background:#30253e88;color:#d6c5eb}
html:root body .world-controls button:hover,html:root body .world-controls button[aria-pressed="true"]{background:#6e499066;color:#fff}
html:root body .world-controls button svg{margin:0;display:block;align-self:center;justify-self:center}
html:root body :is(.wiki-model-controls,.red-sky-stage-controls,.engine-camera) button{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:38px;line-height:1.2;border-radius:0}
