/* V27 · Rankings, History, sidebar rhythm and community (non-destructive overrides).
   Loaded last so all new components share the site's current midnight-blue surfaces. */

/* Sidebar: same breathing room for public sections as the Admin tools. */
.sidebar{overflow-y:auto;scrollbar-width:thin;scrollbar-color:#37495d transparent}
.sidebar .side-nav{gap:9px;flex-shrink:0}
.sidebar .side-nav + .aside-caption{margin-top:21px}
.sidebar .aside-caption.admin-label{margin-top:24px}
.sidebar .sidebar-bottom{flex-shrink:0;padding-top:22px}

/* Rankings now use the same heading, panels, and blue-gray surface palette as Records. */
.rankings-page{width:100%;min-width:0}
.rankings-page .records-title-row{margin-bottom:25px}
.rankings-page .records-hero-icon{object-fit:contain;image-rendering:pixelated}
.rankings-toolbar{display:grid;grid-template-columns:minmax(200px,1.25fr) minmax(128px,.7fr) minmax(154px,.77fr) minmax(185px,.94fr);gap:13px;margin:0 0 20px;align-items:end}
.rankings-search{display:flex;align-items:center;gap:10px;height:47px;padding:0 14px;border:1px solid #3a4b5e;border-radius:9px;background:#1b2430;color:#a0b6d1;min-width:0}
.rankings-search:focus-within{border-color:#83b5ef;outline:2px solid rgba(131,181,239,.13)}
.rankings-search>span{font-size:24px;line-height:1}
.rankings-search input{background:transparent;border:0;outline:0;width:100%;min-width:0;font:inherit;font-size:13px;color:#f2f6fb}
.rankings-search input::placeholder{color:#899db4}
.rankings-filter{display:grid;gap:7px;min-width:0}
.rankings-filter label{color:#96abc2;font-size:10px;font-weight:760;letter-spacing:.055em;text-transform:uppercase}
.rankings-filter .dropdown{height:47px;width:100%;min-width:0;padding:9px 30px 9px 12px;border:1px solid #3a4b5e;border-radius:9px;background:#1b2430;color:#eaf2fc;font-size:13px}
.rankings-panel{padding:0;overflow:hidden;background:#141b23;border:1px solid #334253}
.rankings-panel .rankings-panel-heading{padding:23px 25px;display:flex;align-items:center;gap:18px;justify-content:space-between;margin:0;border-bottom:1px solid #334253;background:#1b2430}
.rankings-panel-heading>div:first-child{display:flex;align-items:center;gap:12px;min-width:0}
.rankings-panel-heading h2{font-size:21px;color:#f2f7ff;margin:0 0 5px;line-height:1.25;letter-spacing:-.35px}
.rankings-panel-heading p{color:#a0b2c8;font-size:12px;margin:0;line-height:1.5}
.rankings-challenge-title-icon{width:46px;height:46px;flex:0 0 46px;display:grid;place-items:center;background:#26364a;border:1px solid #3f5672;border-radius:10px}
.rankings-challenge-title-icon .pixel-icon{width:35px;height:35px;image-rendering:pixelated;object-fit:contain}
.rankings-summary{display:flex;gap:9px;flex-wrap:wrap;justify-content:flex-end;flex-shrink:0}
.rankings-summary span{display:inline-flex;align-items:center;gap:6px;padding:9px 11px;border:1px solid #3a4d63;border-radius:8px;background:#202e3e;color:#aebfd4;font-size:12px;white-space:nowrap}
.rankings-summary b{font-size:15px;color:#eaf2ff;font-variant-numeric:tabular-nums}
.rankings-table-scroll{overflow-x:auto;max-width:100%}
.rankings-table{min-width:620px}
.rankings-columns,.rankings-row{display:grid;grid-template-columns:74px minmax(155px,1fr) repeat(3,minmax(90px,128px));column-gap:16px;align-items:center}
.rankings-columns{min-height:46px;padding:0 24px;background:#141b23;color:#97aabe;letter-spacing:.08em;font-size:10px;font-weight:800}
.rankings-columns>span:not(:first-child){text-align:center}
.rankings-row{width:100%;min-height:73px;text-align:left;padding:9px 24px;border:0;border-top:1px solid #2d3948;color:#eaf2fc;background:#1b222a;cursor:pointer;font:inherit;transition:background .13s,border-color .13s}
.rankings-row:nth-child(2n){background:#19212a}
.rankings-row.dc-medal-1{background:#25354a}
.rankings-row.dc-medal-2{background:#202932}
.rankings-row.dc-medal-3{background:#272329}
.rankings-row:hover,.rankings-row:focus-visible,.rankings-row.dc-medal-1:hover,.rankings-row.dc-medal-2:hover,.rankings-row.dc-medal-3:hover{background:#2b4055;outline:none;box-shadow:inset 3px 0 0 #83b5ef}
.rankings-row:focus-visible{outline:2px solid #83b5ef;outline-offset:-2px}
.rankings-place{display:flex;justify-content:center;align-items:center;min-height:44px;font-weight:800;color:#dce9fa}
.rankings-place .dc-podium-art{width:43px;height:48px;object-fit:contain;image-rendering:pixelated}
.rankings-place .dc-rank-digit{font-size:18px;color:#c4d2e4}
.rankings-name{display:block;text-align:center;font-size:16px;font-weight:740;line-height:1.3;min-width:0;overflow-wrap:anywhere;color:#f3f7ff}
.rankings-row.dc-medal-1 .rankings-name{color:#f4c86f}
.rankings-row.dc-medal-2 .rankings-name{color:#cad7e8}
.rankings-row.dc-medal-3 .rankings-name{color:#e7a17c}
.rankings-stat{text-align:center;font-size:16px;font-weight:680;font-variant-numeric:tabular-nums;color:#c3d5e9}
.rankings-main-stat{font-size:19px;color:#e6f1ff;font-weight:800}
.rankings-footnote{font-size:11px;color:#95aabd;margin:13px 2px 0;line-height:1.6}

/* History shows both personal and guild Top 5 directly, in balanced scoreboard panels. */
.history-timeline{display:grid;gap:18px}
.history-timeline .dc-history-card{overflow:hidden;background:#141b23;border:1px solid #334253;border-radius:13px}
.history-timeline .dc-history-card .result-head{padding:17px 22px;background:#1b2430;border-bottom:1px solid #334253}
.history-scores-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:15px;padding:18px}
.history-scores{min-width:0;border:1px solid #334253;background:#171e26;border-radius:11px;overflow:hidden}
.history-scores-title{display:flex;justify-content:space-between;align-items:center;gap:8px;padding:14px 16px;border-bottom:1px solid #2d3948}
.history-scores-title h3{color:#f1f6fc;font-size:14px;font-weight:760;margin:0}
.history-scores-title span{font-size:10px;font-weight:800;letter-spacing:.06em;color:#93a8c0}
.history-scores-columns,.history-score-row{display:grid;grid-template-columns:55px minmax(95px,1fr) minmax(75px,100px);gap:12px;align-items:center;padding:0 13px}
.history-scores-columns{min-height:33px;color:#90a5bd;background:#141b23;font-weight:800;font-size:9px;letter-spacing:.08em}
.history-scores-columns span:last-child{text-align:right}
.history-score-row{min-height:54px;border-top:1px solid #2b3949;background:#1b222a}
.history-score-row:nth-child(2n){background:#19212a}
.history-score-row.dc-medal-1{background:#25354a}
.history-score-row.dc-medal-2{background:#202932}
.history-score-row.dc-medal-3{background:#272329}
.history-score-rank{display:flex;justify-content:center;align-items:center;color:#d6e3f2}
.history-score-rank .dc-podium-art{width:35px;height:38px;object-fit:contain;image-rendering:pixelated}
.history-score-rank .dc-rank-digit{font-size:15px;color:#b6c9df}
.history-score-name{border:0;background:none;color:#eaf2fc;text-align:left;font:inherit;font-size:13px;font-weight:690;cursor:pointer;min-width:0;overflow-wrap:anywhere;padding:9px 0}
.history-score-name:hover{color:#a0caff;text-decoration:underline;text-underline-offset:3px}
.history-score-row.dc-medal-1 .history-score-name{color:#f4c86f}
.history-score-row.dc-medal-2 .history-score-name{color:#cad7e8}
.history-score-row.dc-medal-3 .history-score-name{color:#e7a17c}
.history-score-value{text-align:right;white-space:nowrap;font-size:14px;font-weight:780;color:#e6f0ff;font-variant-numeric:tabular-nums}
.history-scores-empty{padding:30px 12px;color:#8ca1b8;text-align:center;font-size:12px}

/* Only the user-supplied four original pixel icons are used in the community modal. */
.community-modal .community-perks span{display:flex;align-items:center;gap:13px;min-height:74px;background:#1d2835;border:1px solid #3b4c60;padding:12px 15px;color:#e9f1ff}
.community-perks img{display:block;width:48px;height:48px;flex:0 0 48px;object-fit:contain;image-rendering:pixelated}

/* Overview Discord shortcut floats over the viewport; no calendar/heading grid reflow. */
.dcx-discord-shortcut{position:fixed;bottom:26px;right:29px;z-index:35;display:flex;align-items:center;gap:11px;border:1px solid #6381b9;border-radius:11px;padding:12px 16px;background:#263851;color:#e8f0ff;box-shadow:0 10px 28px rgba(4,8,19,.45);font:inherit;font-size:12px;font-weight:740;cursor:pointer;transition:background .17s,transform .17s}
.dcx-discord-shortcut svg{color:#bbcfff;flex-shrink:0}
.dcx-discord-shortcut:hover{background:#324b6b;transform:translateY(-2px)}
.dcx-discord-shortcut:focus-visible{outline:2px solid #9bc4ff;outline-offset:3px}

@media(max-width:1100px){
 .rankings-toolbar{grid-template-columns:repeat(3,minmax(0,1fr))}
 .rankings-search{grid-column:1/-1}
 .rankings-panel .rankings-panel-heading{flex-wrap:wrap}
 .rankings-summary{justify-content:flex-start}
}
@media(max-width:800px){
 .history-scores-grid{grid-template-columns:minmax(0,1fr);gap:12px;padding:12px}
 .rankings-columns,.rankings-row{grid-template-columns:58px minmax(155px,1fr) repeat(3,minmax(75px,1fr));gap:10px;padding-left:14px;padding-right:14px}
 .rankings-name{font-size:14px}
 .rankings-stat{font-size:14px}
 .rankings-main-stat{font-size:16px}
}
@media(max-width:620px){
 .rankings-toolbar{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
 .rankings-search,.rankings-challenge-filter{grid-column:1/-1}
 .rankings-panel .rankings-panel-heading{padding:15px}
 .rankings-panel-heading h2{font-size:18px}
 .history-timeline .dc-history-card .result-head{padding:14px 12px;gap:8px;flex-wrap:wrap}
 .history-scores-columns,.history-score-row{grid-template-columns:47px minmax(70px,1fr) minmax(75px,100px);gap:6px;padding:0 10px}
 .history-scores-title{padding:12px}
 .community-perks img{width:38px;height:38px;flex-basis:38px}
 .dcx-discord-shortcut{bottom:15px;right:15px;padding:12px 13px}
 .dcx-discord-shortcut span:last-child{display:none}
}
@media(max-width:380px){
 .rankings-filter label{font-size:9px}
 .rankings-filter .dropdown{font-size:11px}
 .dcx-discord-shortcut span:nth-child(2){display:none}
}

/* Keep a five-year history responsive without hiding old records. */
.history-load-more{display:flex;align-items:center;justify-content:center;gap:20px;flex-wrap:wrap;padding:20px;color:#91a9c3;font-size:12px}
.history-load-more .btn{padding:11px 16px}

/* V33: unified Coming soon placeholder for all four public Event Archives. */
.archive-coming-page{width:100%}
.archive-coming-card{min-height:330px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;text-align:center;background:#191f27;border:1px solid #344354;border-radius:13px;padding:38px 24px}
.archive-coming-icon{display:grid;place-items:center;width:76px;height:76px;margin-bottom:6px;border:1px solid #3b5068;border-radius:15px;background:#233143}
.archive-coming-icon img{width:58px;height:58px;object-fit:contain;image-rendering:pixelated}
.archive-coming-card .section-eyebrow{color:#94c3fa;font-size:10px;letter-spacing:1.5px}
.archive-coming-card h2{font-size:clamp(27px,4vw,35px);font-weight:800;letter-spacing:-.8px;color:#f0f5ff;margin:0}
.archive-coming-card p{max-width:430px;color:#a4b4c7;font-size:13px;line-height:1.65;margin:0}
@media(max-width:620px){.archive-coming-card{min-height:270px;padding:30px 18px}.archive-coming-icon{width:65px;height:65px}.archive-coming-icon img{width:50px;height:50px}}
