/* Shared sizing keeps content inside its own grid at narrow widths and zoom. */
body :is(.rank-content,.rank-identity,.member-name,.profile-display-name,
 .signup-invite-name,.journey-row-copy,.option-ticket,.option-market-header>div){min-width:0}
body :is(.member-name,.profile-display-name,.signup-invite-name,.rank-name){align-items:center;gap:6px;overflow-wrap:anywhere}
body .custom-badges{display:inline-flex;align-items:center;justify-content:flex-start;gap:6px;max-width:100%;vertical-align:middle}
body .custom-badges>:is(.chapter-badge,.stock-badge,.owner-badge){flex-shrink:0}
body :is(.auth-mode-tabs,.option-ticket-fields,.option-setup)>*{min-width:0}
body :is(.option-chain-caption,.option-market-header){flex-wrap:wrap}
body .option-chain-caption>span{white-space:normal;text-align:end;line-height:1.5}
body .option-chain-head{overflow-wrap:anywhere;line-height:1.5}
body #journeyOptions .journey-menu-heading{flex-wrap:wrap;row-gap:4px}
body #journeyOptions :is(.journey-row-copy>span,.journey-menu-heading small){white-space:normal;overflow-wrap:anywhere}
body #journeyOptions .journey-menu-row{height:auto}
body :is(.academy-welcome .welcome-milestones small,.academy-welcome .welcome-milestones span:not(.chapter-badge)){white-space:normal;overflow-wrap:anywhere;text-align:center;line-height:1.5}
body #accountPanel :is(.auth-mode-tabs button,.auth-switch button){white-space:normal;overflow-wrap:anywhere;line-height:1.5}
body #accountPanel .auth-introduction>.auth-instagram{gap:4px}
body #accountPanel .auth-instagram>svg{flex-shrink:0}
body dialog{box-sizing:border-box;max-width:calc(100vw - 24px);max-height:calc(100vh - 24px);max-height:calc(100dvh - 24px);overscroll-behavior:contain;scroll-padding-block:16px}
body #languageDialog .language-heading>div{min-width:0}
body #languageDialog .language-close{flex:0 0 44px}
body #languageDialog .language-grid button{overflow-wrap:anywhere}
/* Localized table cards use translated data-label attributes. */
html[dir=rtl] body :is(#lab,#simulator) table tbody :is(td,th){text-align:start}
html[dir=rtl] body #journeyOptions :is(.journey-menu-row,.journey-menu-heading){text-align:start}
body #leaderboard .rank-podium-card .rank-name{overflow-wrap:anywhere}
body #leaderboard .rank-podium-1 .rank-person{text-align:start}
body #leaderboard .rank-podium-1 .rank-name{text-align:start}
body #leaderboard .rank-podium-1 .rank-score{border-left:0;border-inline-start:1px solid #ffffff18;padding-inline-start:14px;padding-inline-end:0}
@media(max-width:760px){
 body :is(#account,#fitness,#lab,#simulator,#options-lab) :is(input:not([type=checkbox]):not([type=radio]):not([type=range]),select,textarea){font-size:16px}
 body :is(.auth-switch,.option-actions){gap:8px;flex-wrap:wrap}
 body :is(.stock-dialog-body,.welcome-bubble){overflow-wrap:anywhere}
 body>header{padding-inline-start:max(12px,env(safe-area-inset-left));padding-inline-end:max(12px,env(safe-area-inset-right))}
 body #journeyOptions{max-width:calc(100vw - max(12px,env(safe-area-inset-left)) - max(12px,env(safe-area-inset-right)))}
}
@media(max-width:480px){
 body #leaderboard .rank-podium-1 .rank-score{border:0;padding-inline:0;flex-wrap:wrap;row-gap:5px}
 body #leaderboard .rank-podium-1 .invite-score-label{text-align:start}
 body .academy-welcome .welcome-milestones{grid-template-columns:repeat(2,minmax(0,1fr))}
 body #lab .chart-controls #showAll{white-space:normal;overflow-wrap:anywhere;line-height:1.4}
}
@media(max-width:360px){
 body #leaderboard .rank-podium-1 .rank-content{padding-inline:36px}
 body #leaderboard .rank-podium-1 .rank-person{flex-direction:column;text-align:center}
 body #leaderboard .rank-podium-1 .rank-name{justify-content:center;text-align:center}
 body #leaderboard .rank-podium-1 .rank-score{justify-content:center}
 body .option-ticket-fields{grid-template-columns:minmax(0,1fr)}
}
@media(hover:none){body :is(button,a,input,select,summary){-webkit-tap-highlight-color:transparent;touch-action:manipulation}}

body .stock-completion{flex-direction:column;align-items:center;gap:12px;text-align:center}
body #stockPracticeCount{margin:0;max-width:100%;font-size:12px;line-height:1.6;color:#aaa;overflow-wrap:anywhere}
/* Weekly day cards and daily routines share a compact, legible progress layout. */
body #fitnessTabs{display:grid;grid-template-columns:minmax(0,1fr);gap:8px;top:16px}
body #fitnessTabs button{min-width:0;min-height:86px;padding:12px;border:1px solid #333;background:#131313;color:#bbb;border-radius:9px;text-align:start;transition:background .2s,border-color .2s}
body #fitnessTabs button.active{background:#272727;color:#eee;border-color:#888}
body #fitnessTabs button.is-complete{border-color:#646d66;background:#1b211e}
body #fitnessTabs button.active.is-complete{border-color:#a0aaa3;background:#252d28}
body #fitnessTabs :is(span,small){white-space:normal;overflow-wrap:anywhere}
body #fitnessTabs button>span{font-size:13px;line-height:1.4}
body #fitnessTabs button>small{font-size:10px;letter-spacing:0;line-height:1.5;margin-top:5px}
body #fitness .fit-day-completed{display:inline-flex;align-items:center;gap:5px;margin-top:8px;font-size:11px;line-height:1.4;color:#bac9bf}
body #fitness .fit-day-completed>span:first-child{display:grid;place-items:center;flex:none;width:20px;height:20px;border:1px solid #69756d;border-radius:5px;background:#303b34;font-size:12px}
body #fitness .fit-period{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:6px 12px;margin:0 0 18px;padding:12px 14px;border:1px solid #333;border-radius:8px;background:#121212;font-size:12px;line-height:1.6;color:#aaa}
body #fitness .fit-period time{font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
body #fitness .fit-routine-heading{align-items:center;gap:12px;margin-bottom:16px}
body #fitness .fit-routine-heading>div{min-width:0}
body #fitness .fit-routine-heading h3{overflow-wrap:anywhere;margin-top:8px}
body #fitness .fit-count{flex-shrink:0;white-space:nowrap}
body #fitness .fit-card.is-complete{border-color:#5b685f;background:#171c19}
body #fitness .fit-set span{white-space:normal;overflow-wrap:anywhere;text-align:start;line-height:1.4}
body #fitness .fit-grid,body #fitness .fit-card,body #fitness .fit-card-body{min-width:0}
@media(max-width:900px){body #fitness .fitness-layout{grid-template-columns:minmax(0,1fr);gap:20px}body #fitnessTabs{position:static;grid-template-columns:repeat(4,minmax(0,1fr))}body #fitnessTabs button{padding:10px}}
@media(max-width:480px){body #fitnessTabs{grid-template-columns:repeat(2,minmax(0,1fr))}body #fitness .fit-period{align-items:start;flex-direction:column}body #fitness .fit-routine-heading{flex-wrap:wrap}body #fitness .fit-card-body{padding:18px}body #fitness .fit-sets{gap:8px}}
@media(prefers-reduced-motion:reduce){body #fitnessTabs button{transition:none}}

/* Compact welcome and completion dialogs. Keep text readable instead of scaling it. */
body dialog.academy-welcome,body #academyCongratulations{
 width:min(560px,calc(100% - 20px));max-width:calc(100% - 20px);
 max-height:calc(100dvh - 20px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));
 margin:auto;overflow:auto;scrollbar-width:thin;
}
body dialog.academy-welcome{padding:0 16px 12px}
body .academy-welcome .welcome-bird{width:calc(100% + 32px);height:72px;min-height:72px;margin:0 -16px}
body .academy-welcome .welcome-bird svg.welcome-scholar{width:90px;height:70px}
body .academy-welcome .welcome-bubble{padding:10px 0 8px;min-width:0}
body .academy-welcome .welcome-eyebrow{font-size:8px;line-height:1.4;letter-spacing:.06em}
body .academy-welcome #academyWelcomeTitle{font-size:clamp(17px,4vw,22px);line-height:1.35;margin:8px auto;overflow-wrap:anywhere}
body .academy-welcome .welcome-bubble>p{font-size:12px;line-height:1.5;max-width:60ch;margin:8px auto 10px;text-wrap:pretty}
body .academy-welcome .welcome-course-label{font-size:11px;line-height:1.4;margin:10px 0 5px}
body .academy-welcome .welcome-milestones{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;padding:0;margin:0;border:0}
body .academy-welcome .welcome-milestones>div{padding:7px 3px;gap:4px;border-radius:5px}
body .academy-welcome .welcome-milestones span:not(.chapter-badge){font-size:10px;line-height:1.3;white-space:normal;overflow-wrap:anywhere}
body .academy-welcome .welcome-milestones small{font-size:10px;line-height:1.3;white-space:normal;overflow-wrap:anywhere}
body :is(.academy-welcome,#academyCongratulations) .chapter-badge,
body #academyCongratulations .owner-badge{
 box-sizing:border-box;width:22px;height:22px;min-width:22px;min-height:22px;max-width:22px;max-height:22px;flex:0 0 22px;border-radius:5px;margin:0;
}
body :is(.academy-welcome,#academyCongratulations) :is(.chapter-badge,.owner-badge) svg{width:15px;height:15px}
body .academy-welcome .welcome-start{width:56px;height:44px;min-height:44px;margin:0 auto}
body .academy-welcome .welcome-close,body #academyCongratulations .celebration-close{width:44px;height:44px;top:6px;right:auto;inset-inline-end:6px;z-index:4}
body #academyCongratulations{padding:44px 16px 14px;border-radius:12px}
body #academyCongratulations .celebration-body{gap:8px;min-width:0}
body #academyCongratulations .clapping-cat{width:52px;height:52px;flex:none}
body #academyCongratulations .celebration-body :is(h2,p){margin:0;overflow-wrap:anywhere}
body #academyCongratulations .celebration-body h2{font-size:clamp(22px,5vw,30px);line-height:1.25}
body #academyCongratulations .celebration-body>p{font-size:12px;line-height:1.45}
body #academyCongratulations .celebration-body>.eyebrow{font-size:9px;line-height:1.4;letter-spacing:.06em;overflow-wrap:anywhere}
body #academyCongratulations .celebration-profile{padding:0 0 10px;border-radius:8px}
body #academyCongratulations .celebration-profile>.member-banner{height:48px;min-height:48px;max-height:48px}
body #academyCongratulations .celebration-profile>.celebration-avatar{--avatar-size:52px;width:52px;height:52px;margin:10px 0 8px}
body #academyCongratulations .celebration-name{padding:0 10px;font-size:16px;gap:6px;line-height:1.35}
body #academyCongratulations .celebration-profile>.custom-badges{padding:0 10px;margin:6px 0 0;gap:4px}
body #academyCongratulations .celebration-role{margin:6px 0 0;font-size:11px;line-height:1.35}
body #academyCongratulations .celebration-caption{max-width:54ch}
/* Short landscape screens use the available width for both courses. */
@media(min-width:600px) and (max-height:600px){
 body dialog.academy-welcome,body #academyCongratulations{width:min(800px,calc(100% - 24px))}
 body .academy-welcome .welcome-bird{height:40px;min-height:40px}
 body .academy-welcome .welcome-bird svg.welcome-scholar{width:58px;height:44px}
 body .academy-welcome .welcome-bubble{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:12px;padding-top:4px}
 body .academy-welcome .welcome-bubble>:is(.welcome-eyebrow,h2,p){grid-column:1/-1}
 body .academy-welcome .welcome-course-label{grid-row:4;margin:4px 0}
 body .academy-welcome .welcome-milestones{grid-row:5}
 body .academy-welcome #academyWelcomeTitle{margin:4px auto;font-size:18px}
 body .academy-welcome .welcome-bubble>p{max-width:90ch;margin:4px auto;font-size:12px;line-height:1.4}
 body #academyCongratulations .celebration-body{display:grid;grid-template-columns:1fr 1fr;column-gap:20px;align-items:center}
 body #academyCongratulations .celebration-body>:not(.celebration-profile){grid-column:1;justify-self:center}
 body #academyCongratulations .celebration-profile{grid-column:2;grid-row:1/6;align-self:center}
}
@media(max-height:650px) and (max-width:599px){
 body .academy-welcome .welcome-bird{height:44px;min-height:44px}
 body .academy-welcome .welcome-bird svg.welcome-scholar{width:64px;height:48px}
 body .academy-welcome .welcome-bubble{padding-top:6px}
 body .academy-welcome .welcome-milestones>div{padding-block:5px;gap:3px}
 body .academy-welcome .welcome-course-label{margin-top:7px}
 body #academyCongratulations .clapping-cat{width:40px;height:40px}
}

/* Desktop shows the complete academy, without changing the mobile crop. */
@media(min-width:1025px) and (hover:hover) and (pointer:fine){
 body.home-view .academy-night-art{object-fit:contain;object-position:50% 50%}
 body #leaderboard .rank-podium[hidden]{display:none}
}

/* Reserve the same bio frame even when no biography has been supplied. */
body .profile-bio-section{min-width:0}
body .profile-bio-section :is(.member-bio,.public-profile-bio,.profile-summary-bio){min-height:3.6em;text-align:start}
body #members .member-card-bio>p{min-height:3.5em;text-align:start}

/* Three clear destinations, with a stable panel while rankings load. */
body #leaderboard .ranking-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:min(100%,760px);gap:4px;padding:5px;margin:0 auto 22px;border-radius:12px;background:#0b0b0b}
body #leaderboard .ranking-tabs button{position:relative;min-width:0;min-height:50px;padding:10px 12px;font-size:13px;line-height:1.4;white-space:normal;overflow-wrap:anywhere;transition:background .18s,color .18s,box-shadow .18s}
body #leaderboard .ranking-tabs button[aria-selected=true]{background:#dedede;color:#111;box-shadow:0 2px 10px #0006}
body #leaderboard .ranking-tabs button:not([aria-selected=true]):hover{background:#232323;color:#fff}
body #leaderboardList{min-height:340px}
body #leaderboardList[aria-busy=true]{display:grid;place-items:center}
.ranking-enter{animation:ranking-reveal .22s ease-out}
@keyframes ranking-reveal{from{opacity:.35;transform:translateY(5px)}to{opacity:1;transform:none}}
.tournament-empty{grid-column:1/-1;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:clamp(300px,48svh,480px);width:100%;padding:28px 16px;box-sizing:border-box;border:1px solid #333;border-radius:16px;background:radial-gradient(ellipse at center,#202020,#090909 72%);text-align:center}
.tournament-empty h2{font:clamp(17px,3vw,26px)/1.5 'Academy Pixel',monospace;margin:0 0 24px;color:#eee;overflow-wrap:anywhere;max-width:100%}
.tournament-bird{width:100px;height:76px;animation:tournament-hover 3s ease-in-out infinite}
.tournament-bird svg{width:100%;height:100%}
.tournament-wing{transform-origin:32px 26px;animation:tournament-wingbeat 1s steps(3,end) infinite}
.tournament-bubble{position:relative;max-width:90%;margin:18px 0 0;padding:12px 18px;border:1px solid #888;border-radius:8px;background:#dedede;color:#111;font-size:14px;line-height:1.5;overflow-wrap:anywhere}
.tournament-bubble:before{content:'';position:absolute;top:-6px;left:calc(50% - 5px);width:10px;height:10px;background:#dedede;border-top:1px solid #888;border-left:1px solid #888;transform:rotate(45deg)}
@keyframes tournament-hover{50%{transform:translateY(-8px)}}
@keyframes tournament-wingbeat{50%{transform:scaleY(.45)}}
body:not(.member-view) .tournament-bird{animation-play-state:paused}
@media(max-width:480px){body #leaderboard .ranking-tabs button{padding:9px 5px;font-size:11px}.tournament-empty{padding:24px 12px}}
@media(prefers-reduced-motion:reduce){.ranking-enter,.tournament-bird,.tournament-wing{animation:none}body #leaderboard .ranking-tabs button{transition:none}}
/* A dedicated rank rail avoids collisions with names, avatars and scores. */
@media(min-width:1025px) and (hover:hover) and (pointer:fine){
 body #leaderboard #leaderboardList{gap:24px;padding-top:8px}
 body #leaderboard #leaderboardList>.rank-row{grid-template-columns:58px minmax(0,1fr)}
 body #leaderboard #leaderboardList>.rank-row>.rank-position{position:static;grid-column:1;grid-row:1/4;display:flex;align-items:center;justify-content:center;align-self:stretch;width:auto;height:auto;min-width:0;margin:0;padding:0 6px;font-variant-numeric:tabular-nums;border-right:0;border-inline-end:1px solid #ffffff20;border-radius:12px 0 0 12px}
 body #leaderboard #leaderboardList>.rank-row>.rank-content{grid-column:2;grid-row:2;display:grid;grid-template-columns:minmax(0,1fr) 130px;align-items:center;gap:20px}
 body #leaderboard #leaderboardList>.rank-row .rank-person{grid-column:1;grid-row:1;min-width:0}
 body #leaderboard #leaderboardList>.rank-row .rank-score{grid-column:2;grid-row:1;display:block;align-self:center;border:0;padding:0;margin:0;text-align:end}
 body #leaderboard #leaderboardList>.rank-row .rank-score :is(b,.invite-score-label){text-align:end;white-space:normal;overflow-wrap:anywhere}
 html[dir=rtl] body #leaderboard #leaderboardList>.rank-row>.rank-position{border-radius:0 12px 12px 0}
}
body #leaderboard #leaderboardList[aria-busy=true]{padding-top:0;place-items:center}
body #leaderboard .rank-admin-status:empty{display:none}

/* Let desktop scenery extend vertically instead of letterboxing or cropping it. */
@media(min-width:1025px) and (hover:hover) and (pointer:fine){
 body.home-view #home.academy-night-home{width:100%;height:auto;min-height:0;max-height:none;aspect-ratio:1482 / 1061}
 body.home-view .academy-night-art{width:100%;height:100%;object-fit:contain;object-position:50% 50%}
}

/* Hanging charcoal signs travel with the birds, including translated labels. */
#home .academy-raven{width:156px;height:132px;gap:15px;padding:6px;justify-content:flex-start}
#home .academy-raven>svg{order:0;flex:0 0 40px}
#home .raven-sign{order:1;position:relative;display:block;width:100%;box-sizing:border-box;padding:9px 7px;border:1px solid #aaa;border-radius:2px;background:linear-gradient(135deg,#292929,#0c0c0c);color:#eee;font:11px/1.4 'Academy Pixel',monospace;text-align:center;overflow-wrap:anywhere;box-shadow:inset 0 0 0 3px #111,0 4px 0 #0008;transform-origin:50% -16px;animation:raven-sign-sway 3.8s ease-in-out infinite}
#home .raven-sign:before,#home .raven-sign:after{content:'';position:absolute;bottom:100%;width:1px;height:17px;background:#a2a2a2;box-shadow:1px 0 #000}
#home .raven-sign:before{left:26%}#home .raven-sign:after{right:26%}
#home .raven-1 .raven-sign{animation-delay:-1.2s}#home .raven-2 .raven-sign{animation-delay:-2.4s}
#home .academy-raven:hover .raven-sign,#home .academy-raven:focus-visible .raven-sign{animation-play-state:paused;border-color:#fff;background:#282828}
@keyframes raven-sign-sway{0%,100%{transform:rotate(-3deg)}50%{transform:rotate(3deg)}}
/* A quiet tournament hall, with scenery, an orbiting light and one status. */
body #leaderboard .tournament-empty{position:relative;isolation:isolate;overflow:hidden;min-height:clamp(380px,62svh,620px);padding:28px clamp(16px,4vw,48px);gap:0;border:1px solid #555;border-radius:16px;background:#090909;box-shadow:inset 0 0 0 5px #ffffff03,0 20px 60px #0005}
.tournament-empty:before{content:'';position:absolute;inset:0;z-index:-2;background:url('academy-night-hd.png') 50% 45%/cover;filter:grayscale(1) brightness(.24);opacity:.65;image-rendering:pixelated;pointer-events:none}
.tournament-empty:after{content:'';position:absolute;inset:0;z-index:-1;background:linear-gradient(#09090988,#09090944 40%,#090909),radial-gradient(ellipse at center,#ffffff10,transparent 60%);pointer-events:none}
.tournament-heading{width:100%;display:flex;align-items:center;justify-content:center;gap:12px;padding-bottom:22px;border-bottom:1px solid #ffffff20}
.tournament-mark{display:grid;place-items:center;flex:none;width:32px;height:32px;border:1px solid #777;border-radius:8px;color:#ddd;font-size:23px;background:#161616}
body #leaderboard .tournament-heading h2{margin:0;font:clamp(16px,3vw,25px)/1.5 'Academy Pixel',monospace;text-wrap:balance}
.tournament-stage{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;width:100%;min-height:240px;flex:1;padding:32px 0;box-sizing:border-box}
.tournament-orbit{position:absolute;top:50%;left:50%;width:min(230px,80%);aspect-ratio:1;transform:translate(-50%,-50%);border:1px solid #ffffff0d;border-radius:50%;box-shadow:0 0 0 22px #ffffff02,inset 0 0 45px #ffffff04;pointer-events:none}
.tournament-orbit:after{content:'';position:absolute;inset:-1px;border:1px solid transparent;border-top-color:#ffffff55;border-radius:50%;animation:tournament-orbit-turn 18s linear infinite}
.tournament-stage .tournament-bird{position:relative;width:116px;height:88px;filter:drop-shadow(0 8px 12px #0008)}
body #leaderboard .tournament-bubble{z-index:1;background:#151515;color:#eee;border-color:#686868;box-shadow:inset 0 0 0 3px #ffffff03,0 8px 24px #0008;max-width:100%;font-size:14px;letter-spacing:.02em}
body #leaderboard .tournament-bubble:before{background:#151515;border-color:#686868}
.tournament-academy-link{display:inline-flex;align-items:center;justify-content:center;gap:14px;min-height:44px;padding:10px 22px;max-width:100%;box-sizing:border-box;border:1px solid #666;border-radius:7px;background:#181818;color:#eee;text-decoration:none;font-size:13px;line-height:1.5;text-align:center}
.tournament-academy-link span{overflow-wrap:anywhere;min-width:0}.tournament-academy-link svg{width:18px;height:18px;flex:none;fill:none;stroke:currentColor;stroke-width:1.5}
.tournament-academy-link:hover{background:#303030;border-color:#aaa}.tournament-academy-link:focus-visible{outline:2px solid white;outline-offset:4px}
@keyframes tournament-orbit-turn{to{transform:rotate(360deg)}}
@media(max-width:480px){#home .academy-raven{width:132px;height:124px}#home .raven-sign{font-size:10px;padding:8px 5px}.tournament-heading{gap:8px}.tournament-mark{width:26px;height:26px;font-size:19px}body #leaderboard .tournament-empty{padding:20px 14px;border-radius:12px}.tournament-stage{min-height:230px}}
@media(prefers-reduced-motion:reduce){#home .raven-sign,.tournament-orbit:after{animation:none}}
html[dir=rtl] .tournament-academy-link svg{transform:scaleX(-1)}
@media(prefers-reduced-motion:reduce){#home .academy-raven.raven-1{left:auto;right:6%}}

/* A fifth drifting cloud uses the clock's shared playback-rate controller. */
.academy-clouds i:nth-child(5){top:16%;width:160px;height:28px;animation-duration:88s;animation-delay:-54s;opacity:.28}
.chimney-puff{fill:#929292;opacity:0;animation:chimney-rise var(--smoke-duration,9s) linear var(--smoke-delay,0s) infinite;transform-box:view-box;transform-origin:0 0}
@keyframes chimney-rise{0%{opacity:0;transform:translate(0,0) scale(.6)}12%{opacity:.3}48%{opacity:.22;transform:translate(8px,-38px) scale(1.1)}80%{opacity:.1}100%{opacity:0;transform:translate(26px,-92px) scale(1.6)}}
.academy-lights.is-paused *{animation-play-state:paused!important}
@media(prefers-reduced-motion:reduce){.academy-clouds i:nth-child(5){left:42%}.chimney-puff{animation:none;opacity:.15;transform:translate(0,-8px)}.chimney-puff:not(:first-child){display:none}}

/* Small pixel residents open the shutters, wave, then retreat. */
.academy-window-interactions{position:absolute;inset:0;z-index:1;pointer-events:none;overflow:hidden}
#home .academy-window{position:absolute;display:block;min-width:0;min-height:0;transform:translate(-50%,-50%);padding:0;border:0;border-radius:0;background:transparent;pointer-events:auto;cursor:pointer;touch-action:manipulation}
.academy-window svg{display:block;width:100%;height:100%;overflow:visible;opacity:0}
.academy-window:hover{box-shadow:0 0 5px #fff8}
#home .academy-window:focus-visible{outline:1px solid #fff;outline-offset:3px;box-shadow:0 0 9px #fff8}
.academy-window.is-open svg{opacity:1;filter:drop-shadow(0 0 2px #ffffff44)}
.academy-window.is-open .window-shutter{animation:window-open-close 4.4s ease-in-out both}
.shutter-left{transform-origin:1px 14px}.shutter-right{transform-origin:19px 14px}
.academy-window.is-open .window-resident{animation:resident-appear 4.4s ease-in-out both}
.resident-arm{transform-origin:14px 17px}
.academy-window.is-open .resident-arm{animation:resident-wave .45s steps(3,end) .75s 6 alternate}
@keyframes window-open-close{0%,100%{transform:scaleX(1)}15%,80%{transform:scaleX(.08)}}
@keyframes resident-appear{0%,12%,100%{opacity:0;transform:translateY(6px)}22%,80%{opacity:1;transform:translateY(0)}92%{opacity:0;transform:translateY(6px)}}
@keyframes resident-wave{from{transform:rotate(-18deg)}to{transform:rotate(25deg)}}
@media(prefers-reduced-motion:reduce){.academy-window.is-open :is(.window-shutter,.window-resident,.resident-arm){animation:none}.academy-window.is-open .window-shutter{transform:scaleX(.08)}}

/* Staggered silver window light: a crisp core with a soft outer bloom. */
#home .academy-window{isolation:isolate}
.academy-window:before{content:'';position:absolute;inset:0;z-index:-1;background:#f3f3f3;box-shadow:0 0 3px 1px #ffffffb3,0 0 10px 3px #ffffff66,0 0 22px 5px #ffffff1f;opacity:.12;pointer-events:none;animation:window-light-breathe 7s ease-in-out infinite}
.academy-window:nth-child(4n+1):before{animation-duration:7.8s;animation-delay:-2.2s}
.academy-window:nth-child(4n+2):before{animation-duration:6.6s;animation-delay:-4.1s}
.academy-window:nth-child(4n+3):before{animation-duration:8.6s;animation-delay:-6s}
.academy-window.is-open:before{animation:none;opacity:.3}
@keyframes window-light-breathe{0%,100%{opacity:.12}45%,55%{opacity:.62}}
body:not(.home-view) .academy-window:before{animation-play-state:paused}
body.home-view .academy-all-windowlight{animation:none;opacity:.45}
@media(prefers-reduced-motion:reduce){.academy-window:before{animation:none;opacity:.32}}

/* Two guides, each carrying a single-cord silver-lit sign. */
#home .academy-raven{width:220px;left:-240px}
#home .raven-sign{width:max-content;min-width:110px;max-width:calc(100vw - 32px);white-space:nowrap;overflow-wrap:normal;padding:10px 12px;font-size:10px;line-height:1.5;border-color:#bcbcbc;color:#f2f2f2;animation:raven-sign-sway 3.8s ease-in-out infinite,raven-sign-glow 5s ease-in-out infinite}
#home .raven-sign:before{left:50%;right:auto;width:1px;height:17px;background:#bdbdbd;box-shadow:0 0 3px #ffffff40}
#home .raven-sign:after{display:none}
#home .raven-1 .raven-sign{animation-delay:-1.4s,-2.5s}
@keyframes raven-sign-glow{0%,100%{border-color:#858585;text-shadow:0 0 3px #ffffff30;box-shadow:inset 0 0 0 3px #111,0 3px 0 #0008,0 0 5px #ffffff12}50%{border-color:#eee;text-shadow:0 0 7px #ffffff70;box-shadow:inset 0 0 0 3px #191919,0 3px 0 #0008,0 0 12px #ffffff36,0 0 24px #ffffff12}}
@media(max-width:480px){#home .academy-raven{width:200px}#home .raven-sign{font-size:9px;padding:9px 10px}}
@media(prefers-reduced-motion:reduce){#home .academy-raven{left:6%;animation:none}#home .academy-raven.raven-1{left:auto;right:6%;top:40%}#home .raven-sign{animation:none;border-color:#bbb;text-shadow:0 0 4px #ffffff40;box-shadow:inset 0 0 0 3px #111,0 0 8px #ffffff24}}

/* Keep the prize above the tournament name across signs, tabs and headings. */
.tournament-label{display:inline-flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;max-width:100%;vertical-align:middle;text-align:center;line-height:1.35}
.tournament-amount{display:block;font-variant-numeric:tabular-nums;letter-spacing:.03em}
#home .raven-sign .tournament-label{display:flex;gap:4px}
#home .raven-sign .tournament-amount{font-size:14px;line-height:1.2}
body #leaderboard .ranking-tabs .tournament-label{gap:1px}
body #leaderboard .ranking-tabs .tournament-amount{font-size:14px;line-height:1.2}
body #leaderboard .tournament-heading .tournament-label{gap:6px}
body #leaderboard .tournament-heading .tournament-amount{font-size:clamp(28px,5vw,44px);line-height:1.2}
.tournament-academy-link{gap:0}
@media(max-width:480px){#home .raven-sign .tournament-amount{font-size:13px}body #leaderboard .ranking-tabs .tournament-amount{font-size:13px}}

/* Glow follows each measured opening instead of a fixed screen-sized halo. */
.academy-window:before{box-shadow:0 0 .35em .1em #ffffffa6,0 0 .9em .2em #ffffff52,0 0 1.6em .3em #ffffff14}
#home .academy-window{box-sizing:border-box;line-height:0;appearance:none;-webkit-appearance:none}
.academy-window svg{position:relative}
@media(max-width:1024px){.academy-window:before{box-shadow:0 0 .3em .05em #ffffff99,0 0 .75em .15em #ffffff42}.academy-window.is-open svg{filter:drop-shadow(0 0 1px #ffffff44)}}

/* Center the tournament identity independently of label length or direction. */
body #leaderboard .ranking-tabs{align-items:stretch}
body #leaderboard .ranking-tabs button{display:flex;align-items:center;justify-content:center;text-align:center;min-height:64px;box-sizing:border-box}
body #leaderboard #tournamentRankingTab .tournament-label{width:100%;align-items:center;justify-content:center;gap:3px;line-height:1.3}
body #leaderboard #tournamentRankingTab .tournament-label>span{display:block;max-width:100%;text-align:center;overflow-wrap:anywhere}
body #leaderboard .tournament-heading{flex-direction:column;gap:12px;text-align:center}
body #leaderboard .tournament-heading h2{width:100%;min-width:0;text-align:center}
body #leaderboard .tournament-heading .tournament-label{display:flex;width:100%;align-items:center;gap:8px}
body #leaderboard .tournament-heading .tournament-mark{margin:0 auto}
@media(max-width:480px){body #leaderboard .ranking-tabs button{min-height:62px;padding:8px 5px}body #leaderboard .tournament-heading{gap:10px;padding-bottom:20px}}


/* An academy tournament hall: engraved frame, academic shield, silver prize. */
body #leaderboard .tournament-empty{min-height:clamp(390px,64svh,650px);border-color:#686868;border-radius:8px;background:#080808;box-shadow:inset 0 0 0 4px #111,inset 0 0 0 5px #ffffff0b,0 24px 80px #0007}
body #leaderboard .tournament-empty:before{background-position:58% 35%;filter:grayscale(1) brightness(.3);opacity:.75}
body #leaderboard .tournament-empty:after{background:linear-gradient(90deg,#050505cc,transparent 35%,transparent 65%,#050505cc),linear-gradient(#07070799,transparent 45%,#070707),radial-gradient(ellipse at 50% 32%,#ffffff12,transparent 60%)}
.tournament-engraving{position:absolute;inset:12px;pointer-events:none;border:1px solid #ffffff0c;border-radius:2px}
.tournament-engraving i{position:absolute;width:22px;height:22px;border-color:#a5a5a5;opacity:.65}
.tournament-engraving i:nth-child(1){top:-1px;left:-1px;border-top:2px solid;border-left:2px solid}
.tournament-engraving i:nth-child(2){top:-1px;right:-1px;border-top:2px solid;border-right:2px solid}
.tournament-engraving i:nth-child(3){bottom:-1px;left:-1px;border-bottom:2px solid;border-left:2px solid}
.tournament-engraving i:nth-child(4){bottom:-1px;right:-1px;border-bottom:2px solid;border-right:2px solid}
body #leaderboard .tournament-heading{gap:14px;width:min(100%,420px);padding:10px 0 24px;border:0;position:relative}
.tournament-heading:after{content:'';position:absolute;bottom:0;left:12%;right:12%;height:1px;background:linear-gradient(90deg,transparent,#bcbcbc80,transparent)}
body #leaderboard .tournament-heading .tournament-mark{display:block;width:64px;height:72px;padding:0;border:0;border-radius:0;background:none;filter:drop-shadow(0 0 10px #ffffff15)}
.tournament-mark svg{display:block;width:100%;height:100%}
body #leaderboard .tournament-heading .tournament-amount{font-size:clamp(34px,6vw,58px);line-height:1.2;letter-spacing:.04em;color:#eee;text-shadow:0 2px 0 #555,0 0 24px #ffffff16;animation:tournament-prize-glow 6s ease-in-out infinite}
body #leaderboard .tournament-stage{padding:30px 0 20px;min-height:210px}
body #leaderboard .tournament-orbit{width:min(200px,65%);border-color:#ffffff16;box-shadow:0 0 0 16px #ffffff02,0 0 0 44px #ffffff01,inset 0 0 50px #ffffff04}
body #leaderboard .tournament-stage .tournament-bird{width:110px;height:84px}
body #leaderboard #tournamentRankingTab .tournament-amount{font-size:16px;letter-spacing:.03em}
@keyframes tournament-prize-glow{0%,100%{text-shadow:0 2px 0 #555,0 0 15px #ffffff16}50%{text-shadow:0 2px 0 #666,0 0 28px #ffffff35}}
@media(max-width:480px){body #leaderboard .tournament-empty{padding:24px 20px;min-height:380px}body #leaderboard .tournament-heading .tournament-mark{width:52px;height:58px}.tournament-engraving{inset:9px}body #leaderboard #tournamentRankingTab .tournament-amount{font-size:15px}}
@media(prefers-reduced-motion:reduce){body #leaderboard .tournament-heading .tournament-amount{animation:none}}

/* A little more vertical scenery on phones and touch tablets; stable browser-chrome sizing. */
@media(max-width:767px),(pointer:coarse){
 body.home-view #home.academy-night-home{height:calc(max(820px,150vh - var(--academy-header-height,140px) + env(safe-area-inset-bottom,0px)) + clamp(64px,10vh,100px));min-height:0;max-height:none}
 @supports(height:100svh){body.home-view #home.academy-night-home{height:calc(max(820px,150svh - var(--academy-header-height,140px) + env(safe-area-inset-bottom,0px)) + clamp(64px,10svh,100px))}}
}
@media(pointer:coarse) and (orientation:landscape){
 body.home-view #home.academy-night-home{height:calc(max(580px,145vh - var(--academy-header-height,90px)) + 48px)}
 @supports(height:100svh){body.home-view #home.academy-night-home{height:calc(max(580px,145svh - var(--academy-header-height,90px)) + 48px)}}
}

/* Plain black tournament backdrop. */
body #leaderboard .tournament-empty{background:#000}
body #leaderboard .tournament-empty:before,body #leaderboard .tournament-empty:after{display:none;background:none}

/* Light charcoal glass signs let the scenery show through. */
#home .raven-sign{background:linear-gradient(145deg,#272727a8,#080808a3);border-color:#bdbdbd99;color:#f2f2f2;border-radius:3px;box-shadow:inset 0 0 0 2px #ffffff05,0 3px 8px #0005;animation-name:raven-sign-sway,raven-sign-glass-glow}
#home .academy-raven:hover .raven-sign,#home .academy-raven:focus-visible .raven-sign{background:linear-gradient(145deg,#303030bd,#111111b8);border-color:#eeeeeecc}
#home .raven-sign:before{background:#c4c4c499;box-shadow:0 0 3px #ffffff26}
@keyframes raven-sign-glass-glow{0%,100%{border-color:#aaaaaa80;text-shadow:0 1px 2px #000,0 0 3px #ffffff26;box-shadow:inset 0 0 0 2px #ffffff04,0 3px 8px #0005,0 0 5px #ffffff10}50%{border-color:#eeeeeecc;text-shadow:0 1px 2px #000,0 0 6px #ffffff55;box-shadow:inset 0 0 0 2px #ffffff08,0 3px 8px #0005,0 0 12px #ffffff28}}
@media(prefers-reduced-motion:reduce){#home .raven-sign{animation:none;border-color:#bdbdbd99;text-shadow:0 1px 2px #000;box-shadow:inset 0 0 0 2px #ffffff05,0 3px 8px #0005,0 0 6px #ffffff18}}

/* Calm, animated account entry without falling particles. */
body.auth-gated .ethereum-shard-canvas,body #accountPanel .auth-header-pixels{display:none!important}
body.auth-gated #account:has(.auth-layout):before{background:linear-gradient(110deg,#000b,#0007 50%,#000c),url('academy-buildings-clean.png') 58% 42%/cover;filter:grayscale(1);animation:auth-scene-light 12s ease-in-out infinite}
body #accountPanel:has(.auth-layout){max-width:1000px}
body #accountPanel .auth-layout{position:relative;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);border:1px solid #ffffff30;border-radius:14px;background:#0a0a0abf;box-shadow:0 24px 80px #0009,inset 0 1px #ffffff12;backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px);animation:auth-panel-arrive .4s ease-out both}
body #accountPanel .auth-layout>.auth-academy-header{gap:0;padding:26px 24px 24px;border-bottom:1px solid #ffffff14;background:linear-gradient(#ffffff06,transparent);position:relative}
body #accountPanel .auth-academy-header:after{content:'';position:absolute;bottom:-1px;left:25%;right:25%;height:1px;background:linear-gradient(90deg,transparent,#ffffff60,transparent);pointer-events:none}
body #accountPanel .auth-academy-header h2{white-space:normal;text-wrap:balance;font-size:clamp(21px,3vw,30px);line-height:1.5;letter-spacing:.02em;overflow-wrap:anywhere}
body #accountPanel .auth-layout>.auth-introduction{justify-content:center;padding:30px;border-inline-end:1px solid #ffffff14;border-right:0;background:linear-gradient(160deg,#ffffff03,transparent);overflow:hidden}
body #accountPanel .auth-scholar-stage{width:100%;min-height:220px;margin:0 0 16px;border:0;border-radius:50%;background:radial-gradient(ellipse,#ffffff09,transparent 67%)}
body #accountPanel .auth-scholar-stage:before{display:none}
body #accountPanel .auth-scholar-stage:after{inset:15%;border:1px solid #ffffff0b;border-radius:50%;background:none}
body #accountPanel .auth-scholar-stage svg{width:168px;height:140px;filter:drop-shadow(0 8px 12px #0008)}
body #accountPanel .auth-introduction>h3{font-size:clamp(18px,2.1vw,24px);line-height:1.55;margin-top:12px;max-width:22ch;text-wrap:balance;overflow-wrap:anywhere}
body #accountPanel .auth-introduction>.auth-instagram{color:#bdbdbd;min-height:44px;padding:8px 4px}
body #accountPanel .auth-layout>form,body #accountPanel .auth-layout>.auth-verification-card{padding:30px clamp(22px,4vw,42px);gap:17px;background:#0c0c0c66}
body #accountPanel .auth-mode-tabs{padding:4px;border-radius:8px;background:#0005;border-color:#ffffff20;margin-bottom:4px}
body #accountPanel .auth-mode-tabs button{border-radius:5px;white-space:normal;line-height:1.4;transition:background .18s,border-color .18s,color .18s}
body #accountPanel .auth-mode-tabs button[aria-pressed=true]{background:#ffffff17;border-color:#ffffff38;color:#fff;box-shadow:0 2px 6px #0004}
body #accountPanel #authForm>label{color:#c6c6c6;font-size:12px;letter-spacing:.01em}
body #accountPanel #authForm input{border-radius:7px;border-color:#ffffff28;background:#0c0c0ca8;min-height:50px;transition:border-color .18s,box-shadow .18s}
body #accountPanel #authForm input:focus{outline:none;border-color:#bcbcbc;box-shadow:0 0 0 3px #ffffff0e}
body #accountPanel #authForm input[aria-invalid=true]{border-style:dashed;border-color:#bbb}
body #accountPanel #authForm>.button{min-height:50px;border-radius:7px;border-color:#ccc;background:linear-gradient(135deg,#e7e7e7,#b8b8b8);color:#111;font-weight:600;box-shadow:inset 0 1px #fff8,0 4px 14px #0004;transition:filter .18s,box-shadow .18s}
body #accountPanel #authForm>.button:hover{background:linear-gradient(135deg,#fff,#d4d4d4);border-color:#eee;box-shadow:0 4px 18px #ffffff0e}
body #accountPanel #authForm>.button:disabled{opacity:.55;cursor:wait}
body #accountPanel .auth-switch{justify-content:center;gap:4px 20px}
body #accountPanel .auth-switch button{text-align:center;color:#aaa}
body #accountPanel .auth-switch button:hover{color:#eee}
body #accountPanel .auth-stay-note{padding-top:12px;text-align:center;border-color:#ffffff12;line-height:1.6}
body #accountPanel #signupInviteCard{border-radius:8px;border-color:#ffffff25;background:#14141470}
html[dir=rtl] body #accountPanel .auth-password-field input{padding-left:50px;padding-right:14px}
html[dir=rtl] body #accountPanel .auth-password-toggle{right:auto;left:2px}
@keyframes auth-panel-arrive{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes auth-scene-light{0%,100%{opacity:.6}50%{opacity:.88}}
@media(max-width:760px){
 body #accountPanel:has(.auth-layout){max-width:500px}
 body #accountPanel .auth-layout{grid-template-columns:minmax(0,1fr);border-radius:11px}
 body #accountPanel .auth-layout>.auth-academy-header{padding:20px 18px 18px}
 body #accountPanel .auth-layout>.auth-introduction{padding:14px 22px 20px;border-inline-end:0;border-bottom:1px solid #ffffff12}
 body #accountPanel .auth-scholar-stage{min-height:108px;margin:0 0 2px}
 body #accountPanel .auth-scholar-stage svg{width:126px;height:100px}
 body #accountPanel .auth-scholar-stage:after{inset:4% 25%}
 body #accountPanel .auth-introduction>h3{margin-top:2px;max-width:100%;font-size:19px}
 body #accountPanel .auth-layout>form,body #accountPanel .auth-layout>.auth-verification-card{padding:22px;gap:15px}
 body.auth-gated #account:has(.auth-layout){scroll-padding-block:20px}
}
@media(max-width:360px){body #accountPanel .auth-layout>form{padding:18px}body #accountPanel .auth-academy-header h2{font-size:19px}}
@media(max-height:650px) and (min-width:761px){body #accountPanel .auth-scholar-stage{min-height:150px}body #accountPanel .auth-layout>.auth-academy-header{padding-block:18px}}
@media(prefers-reduced-motion:reduce){body #accountPanel .auth-layout,body.auth-gated #account:has(.auth-layout):before{animation:none}body #accountPanel .auth-mode-tabs button,body #accountPanel #authForm input,body #accountPanel #authForm>.button{transition:none}}

/* Silver prize lettering stays legible through a gentle white glow. */
body #leaderboard #tournamentRankingTab .tournament-amount,body #leaderboard .tournament-heading .tournament-amount{animation:tournament-silver-glow 4.8s ease-in-out infinite;color:#f5f5f5}
body #leaderboard #tournamentRankingTab[aria-selected=true] .tournament-amount{color:#161616;animation:tournament-selected-glow 4.8s ease-in-out infinite}
@keyframes tournament-silver-glow{0%,100%{text-shadow:0 0 4px #ffffff55,0 0 12px #ffffff26}50%{text-shadow:0 0 7px #ffffffb3,0 0 20px #ffffff66,0 0 36px #ffffff2e}}
@keyframes tournament-selected-glow{0%,100%{text-shadow:0 0 3px #fff8}50%{text-shadow:0 0 6px #fff,0 0 12px #ffffffb3}}
@media(prefers-reduced-motion:reduce){body #leaderboard #tournamentRankingTab .tournament-amount,body #leaderboard #tournamentRankingTab[aria-selected=true] .tournament-amount,body #leaderboard .tournament-heading .tournament-amount{animation:none;text-shadow:0 0 8px #ffffff55}}

/* Separate flight lanes and matching speeds keep both carrying signs apart. */
#home .academy-raven.raven-0{top:12%;animation-duration:30s;animation-delay:-3s}
#home .academy-raven.raven-1{top:calc(12% + clamp(180px,18vw,260px));animation-duration:30s;animation-delay:-18s}

/* Three individual ranking cards with equal spacing and clear selected states. */
body #leaderboard .ranking-tabs{position:relative;isolation:isolate;gap:clamp(8px,1.8vw,16px);padding:0;border:0;border-radius:0;background:none;box-shadow:none;width:min(100%,820px);margin:0 auto 28px;box-sizing:border-box;align-items:stretch}
body #leaderboard .ranking-tabs:before{display:none}
body #leaderboard .ranking-tabs button{display:grid;grid-template-rows:28px 1fr;justify-items:center;align-items:center;gap:12px;min-height:114px;padding:18px 12px;border:1px solid #383838;border-radius:12px;background:linear-gradient(155deg,#181818,#090909);color:#a9a9a9;box-shadow:inset 0 1px #ffffff05;letter-spacing:.01em;transition:color .22s,background .22s,border-color .22s,box-shadow .22s,transform .22s}
body #leaderboard .ranking-tabs button[aria-selected=true]{background:linear-gradient(155deg,#ededed,#c6c6c6);border-color:#eee;color:#111;box-shadow:inset 0 1px #fff,0 5px 24px #ffffff0f}
body #leaderboard .ranking-tabs button:not([aria-selected=true]):hover{background:linear-gradient(155deg,#262626,#111);border-color:#777;color:#fff;transform:translateY(-2px)}
body #leaderboard .ranking-tabs .ranking-tab-icon{display:block;width:26px;height:26px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
body #leaderboard .ranking-tabs .ranking-tab-title{display:flex;align-items:center;justify-content:center;min-width:0;max-width:100%;height:100%;line-height:1.45;text-align:center;text-wrap:balance;overflow-wrap:anywhere}
body #leaderboard .ranking-tabs button:focus-visible{outline:2px solid #fff;outline-offset:4px;z-index:1}
body #leaderboard .ranking-tabs button:disabled{opacity:.6;cursor:wait}
body #leaderboard .rank-admin-status:empty{display:none}
body #leaderboardList[aria-busy=true]{min-height:clamp(390px,64svh,650px)}
body #leaderboardList.ranking-enter{animation:ranking-panel-reveal .3s ease-out both}
@keyframes ranking-panel-reveal{from{opacity:0;transform:translateY(7px)}to{opacity:1;transform:translateY(0)}}
/* The ring and bird share one grid cell, without asymmetric flex padding. */
body #leaderboard .tournament-stage{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:1fr;place-items:center;padding:28px 0;min-height:270px;width:100%;margin-inline:auto;flex:1}
body #leaderboard .tournament-orbit{position:relative;grid-area:1/1;inset:auto;transform:none;width:min(200px,65%);aspect-ratio:1;box-sizing:border-box;margin:0}
body #leaderboard .tournament-stage .tournament-bird{grid-area:1/1;align-self:center;justify-self:center;margin:0;width:110px;height:82.5px;animation:tournament-centered-hover 3s ease-in-out infinite}
body #leaderboard .tournament-bird svg{display:block}
@keyframes tournament-centered-hover{0%,100%{transform:translateY(4px)}50%{transform:translateY(-4px)}}
@media(max-width:480px){body #leaderboard .ranking-tabs{margin-bottom:18px}body #leaderboard .ranking-tabs button{font-size:11px;min-height:104px;padding:14px 7px;gap:10px;border-radius:10px}body #leaderboard .tournament-stage{min-height:250px}}
@media(prefers-reduced-motion:reduce){body #leaderboard .ranking-tabs:before,body #leaderboard .ranking-tabs button{transition:none}body #leaderboardList.ranking-enter,body #leaderboard .tournament-stage .tournament-bird,body #leaderboard .tournament-orbit:after{animation:none}}

/* Illuminate just the initial M; keep the smaller wordmark crisp. */
body>header .header-wordmark .brand{color:#f5f5f5;animation:header-m-glow 4.8s ease-in-out infinite}
body>header .header-wordmark .brand>span{text-shadow:none}
@keyframes header-m-glow{0%,100%{text-shadow:0 0 4px #ffffff55,0 0 12px #ffffff22}50%{text-shadow:0 0 7px #ffffffaa,0 0 19px #ffffff66,0 0 30px #ffffff25}}
@media(prefers-reduced-motion:reduce){body>header .header-wordmark .brand{animation:none;text-shadow:0 0 6px #ffffff66,0 0 15px #ffffff33}}

/* Reserve the prize glow for the tournament page, not its navigation card. */
body #leaderboard #tournamentRankingTab .tournament-amount,
body #leaderboard #tournamentRankingTab[aria-selected=true] .tournament-amount{animation:none;text-shadow:none;color:inherit}

/* Match the tournament page emblem to its trophy selector. */
body #leaderboard .tournament-heading .tournament-mark{width:64px;height:64px;color:#c7c7c7}
@media(max-width:480px){body #leaderboard .tournament-heading .tournament-mark{width:52px;height:52px}}

/* A stone academy amphitheater, lit in silver against the black page. */
body #leaderboard .tournament-empty{padding:30px clamp(12px,3vw,36px) 20px;min-height:0;border-color:#414141;border-radius:14px;box-shadow:inset 0 0 0 5px #ffffff02,0 20px 60px #0005}
body #leaderboard .tournament-heading{gap:8px;padding:0 0 22px;width:min(100%,380px)}
body #leaderboard .tournament-heading .tournament-mark{width:58px;height:58px;color:#cfcfcf;filter:drop-shadow(0 0 8px #ffffff12)}
body #leaderboard .tournament-heading .tournament-amount{font-size:clamp(36px,6vw,58px);letter-spacing:.02em}
body #leaderboard .tournament-stage{display:flex;flex-direction:column;gap:12px;min-height:0;flex:none;padding:24px 0 4px;width:100%}
body #leaderboard .tournament-arena{position:relative;display:block;width:min(100%,800px);padding:0;margin:0;border:0;border-radius:12px;background:transparent;color:#ddd;box-shadow:none;cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent}
body #leaderboard .tournament-arena:focus-visible{outline:2px solid #ccc;outline-offset:6px;background:#ffffff03}
body #leaderboard .stadium-art{display:block;width:100%;height:auto;overflow:visible}
body #leaderboard .tournament-stage .tournament-bird{position:absolute;left:50%;top:55.58%;width:12%;max-width:82px;height:auto;margin:0;transform:translate(-50%,-50%);animation:none;pointer-events:none;filter:drop-shadow(0 5px 6px #000)}
body #leaderboard .tournament-bird svg{display:block;width:100%;height:auto;animation:stadium-bird-float 3.6s ease-in-out infinite}
.stadium-cheer-hint{font-size:11px;line-height:1.5;letter-spacing:.04em;color:#969696;text-align:center;max-width:100%;overflow-wrap:anywhere}
.stadium-fan{animation:stadium-crowd 5s ease-in-out infinite;animation-delay:var(--fan-delay);transform-box:fill-box;transform-origin:center bottom}
.fan-arms{transform-box:fill-box;transform-origin:center bottom;animation:stadium-arms 5s ease-in-out infinite;animation-delay:var(--fan-delay)}
.stadium-pennant{transform-box:fill-box;transform-origin:left center;animation:stadium-flag 3.8s ease-in-out infinite}
.stadium-light{opacity:.55;transition:opacity .4s}
.arena-ring{transition:stroke .3s,fill .3s}
.tournament-arena.is-cheering .stadium-fan{animation:stadium-cheer .45s ease-in-out infinite;animation-delay:var(--fan-delay)}
.tournament-arena.is-cheering .fan-arms{animation:stadium-arms .55s ease-in-out infinite;animation-delay:var(--fan-delay)}
.tournament-arena.is-cheering .stadium-light{opacity:1}
.tournament-arena.is-cheering .arena-ring{stroke:#fff;fill:#303030}
@keyframes stadium-crowd{0%,60%,100%{transform:translateY(0)}70%,85%{transform:translateY(-2px)}}
@keyframes stadium-cheer{0%,100%{transform:translateY(0)}50%{transform:translateY(-6px)}}
@keyframes stadium-arms{0%,50%,100%{transform:scaleY(.72)}70%,85%{transform:scaleY(1.2)}}
@keyframes stadium-flag{50%{transform:skewY(5deg) scaleX(.92)}}
@keyframes stadium-bird-float{0%,100%{transform:translateY(3px)}50%{transform:translateY(-3px)}}
body #leaderboard .stadium-paused *,body:not(.member-view) .stadium-fan,body:not(.member-view) .fan-arms,body:not(.member-view) .stadium-pennant{animation-play-state:paused!important}
@media(max-width:480px){body #leaderboard .tournament-empty{padding:22px 10px 18px}body #leaderboard .tournament-heading{padding-bottom:18px;width:80%}body #leaderboard .tournament-heading .tournament-mark{width:50px;height:50px}body #leaderboard .tournament-stage{padding-top:22px;gap:18px}.stadium-cheer-hint{font-size:10px}}
@media(prefers-reduced-motion:reduce){body #leaderboard .tournament-arena *,body #leaderboard .tournament-arena.is-cheering *{animation:none!important;transition:none!important}}

/* Keep the language control in the academy frame's right-hand header slot. */
body #accountPanel .auth-layout>.auth-academy-header{display:grid;grid-template-columns:46px minmax(0,1fr) 46px;align-items:center;gap:12px}
body #accountPanel .auth-academy-header h2{grid-column:2;grid-row:1;min-width:0}
body.auth-gated #authLanguageButton{position:static;grid-column:3;grid-row:1;justify-self:end;display:grid!important;place-items:center;width:46px;height:46px;padding:11px;margin:0;border:1px solid #ffffff38;border-radius:12px;background:linear-gradient(145deg,#222e,#0b0b0bee);color:#d5d5d5;box-shadow:inset 0 1px #ffffff0a,0 6px 20px #0005;cursor:pointer;transition:background .2s,border-color .2s;color-scheme:dark;box-sizing:border-box}
body.auth-gated>#authLanguageButton{display:none!important}
body.auth-gated #authLanguageButton svg{display:block;width:22px;height:22px;margin:0;fill:none;stroke:currentColor;stroke-width:1.5}
body.auth-gated #authLanguageButton:hover{border-color:#aaa;background:#262626}
body.auth-gated #authLanguageButton:focus-visible{outline:2px solid #eee;outline-offset:4px}
html[dir=rtl] body #accountPanel .auth-academy-header{direction:ltr}
html[dir=rtl] body #accountPanel .auth-academy-header h2{direction:rtl}
@media(max-width:480px){body #accountPanel .auth-layout>.auth-academy-header{grid-template-columns:minmax(0,1fr) 44px;gap:10px;padding:18px 14px}body #accountPanel .auth-academy-header h2{grid-column:1;text-align:start;font-size:clamp(16px,4.6vw,21px)}body.auth-gated #authLanguageButton{grid-column:2;width:44px;height:44px;padding:10px}}
@media(prefers-reduced-motion:reduce){body.auth-gated #authLanguageButton{transition:none}}

/* Normalize native button geometry so the globe stays centered in every browser. */
body.auth-gated #authLanguageButton{display:flex!important;align-items:center;justify-content:center;align-self:center;justify-self:end;gap:0;padding:0;min-width:44px;min-height:44px;max-width:46px;max-height:46px;aspect-ratio:1;line-height:1;font-size:0;text-indent:0;vertical-align:middle;appearance:none;-webkit-appearance:none;inset:auto;transform:none;overflow:hidden}
body.auth-gated #authLanguageButton svg{position:static;display:block;flex:0 0 22px;width:22px;height:22px;min-width:22px;max-width:22px;min-height:22px;max-height:22px;margin:0;padding:0;transform:none;vertical-align:middle;stroke-linecap:round;stroke-linejoin:round}
body #accountPanel .auth-academy-header h2{align-self:center;margin:0;padding:0}

/* Light breathes through the academy windows and across the arena floor. */
.stadium-light{animation:stadium-light-breathe 5s ease-in-out infinite;transform-box:fill-box;transform-origin:center top}
.stadium-window-light{animation:stadium-window-glow 4s ease-in-out infinite}
.stadium-window-light:nth-of-type(3n){animation-delay:-1.4s}
.stadium-window-light:nth-of-type(3n+1){animation-delay:-2.7s}
.tournament-arena.is-cheering .stadium-light{animation:stadium-light-breathe 1s ease-in-out infinite}
@keyframes stadium-light-breathe{0%,100%{opacity:.32}50%{opacity:1}}
@keyframes stadium-window-glow{0%,100%{opacity:.35}50%{opacity:.95}}
body #leaderboard .stadium-door-sign{position:absolute;left:50%;bottom:8%;transform:translateX(-50%);display:block;width:24%;max-width:150px;box-sizing:border-box;padding:3px 5px;border:1px solid #7778;border-radius:3px;background:linear-gradient(#292929ee,#111e);color:#d2d2d2;font-size:clamp(8px,1.1vw,11px);line-height:1.25;font-family:inherit;letter-spacing:.02em;text-align:center;text-wrap:balance;overflow-wrap:anywhere;box-shadow:0 2px 5px #0008,inset 0 1px #ffffff12;pointer-events:none}
/* Anchor the bird to the arena's exact SVG center; only its wings move. */
body #leaderboard .tournament-stage .tournament-bird{left:50%;top:55.581395%;transform:translate(-50%,-50%)}
body #leaderboard .tournament-bird>svg{animation:none;transform:none}
body #leaderboard .stadium-art>ellipse{animation:stadium-ring-glow 5s ease-in-out infinite}
body #leaderboard .stadium-art>ellipse:nth-of-type(2n){animation-delay:-1.5s}
body #leaderboard .stadium-art>ellipse:nth-of-type(3n){animation-delay:-3s}
@keyframes stadium-ring-glow{0%,100%{stroke:#565656;filter:none}50%{stroke:#999;filter:drop-shadow(0 0 2px #ffffff30)}}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-art>ellipse{animation:none;filter:none}}

/* Stagger the pennants so they ripple independently from their fixed poles. */
body #leaderboard .stadium-pennant{transform-box:fill-box;transform-origin:left center;animation:academy-pennant-wave 2.8s ease-in-out infinite}
body #leaderboard .stadium-tower:nth-of-type(2) .stadium-pennant{animation-duration:3.4s;animation-delay:-1.3s}
@keyframes academy-pennant-wave{0%,100%{transform:skewY(-5deg) scaleX(.96)}25%{transform:skewY(7deg) scaleX(.88)}50%{transform:skewY(-2deg) scaleX(1)}75%{transform:skewY(-8deg) scaleX(.91)}}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-pennant{animation:none;transform:none}}

/* Let the stadium keep its natural proportions instead of shrinking inside a height-contained grid. */
body #leaderboard:has(.tournament-empty){display:flex;flex-direction:column;gap:16px;height:auto;min-height:0;padding:16px clamp(8px,2vw,28px) 20px;margin:0;box-sizing:border-box}
body #leaderboard:has(.tournament-empty) .ranking-tabs{flex:none;margin:0 auto;width:min(100%,820px)}
body #leaderboard:has(.tournament-empty) .ranking-tabs button{min-height:66px;padding:9px 12px;gap:7px;display:flex;flex-direction:row}
body #leaderboard:has(.tournament-empty) .ranking-tab-icon{width:22px;height:22px;flex:none}
body #leaderboard:has(.tournament-empty) #leaderboardList{display:block;flex:none;min-height:0;width:100%;padding:0;margin:0}
body #leaderboard .tournament-empty{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:12px;width:100%;max-width:1240px;height:auto;min-height:0;padding:14px 8px 8px;margin:0 auto;border:1px solid #ffffff15;border-radius:12px;box-shadow:none;box-sizing:border-box}
body #leaderboard .tournament-engraving{display:none}
body #leaderboard .tournament-heading{padding:0;gap:0;width:100%;align-self:center}
body #leaderboard .tournament-heading:after{display:none}
body #leaderboard .tournament-heading .tournament-amount{font-size:clamp(34px,4vw,48px);line-height:1.2}
body #leaderboard .tournament-stage{display:flex;container-type:normal;align-items:center;justify-content:center;width:100%;height:auto;min-height:0;flex:none;gap:0;padding:0}
body #leaderboard .tournament-arena{display:block;width:100%;max-width:1150px;height:auto;min-height:0;aspect-ratio:800/430;padding:0;border:0;overflow:visible}
body #leaderboard .stadium-art{display:block;width:100%;height:auto;aspect-ratio:800/430}
body #leaderboard .tournament-stage .tournament-bird{width:12%;max-width:96px}
body:has(#leaderboard:not([hidden]) .tournament-empty)>footer,body:has(#leaderboard:not([hidden]) .tournament-empty)>.back-to-top{display:none!important}
@media(min-width:761px){
 body #leaderboard .tournament-arena{width:min(100%,max(520px,calc((100vh - var(--academy-header-height,100px) - 196px) * 1.860465)))}
 @supports(height:100dvh){body #leaderboard .tournament-arena{width:min(100%,max(520px,calc((100dvh - var(--academy-header-height,100px) - 196px) * 1.860465)))}}
}
@media(max-width:760px){
 body #leaderboard:has(.tournament-empty){padding:12px 6px 18px;gap:14px}
 body #leaderboard:has(.tournament-empty) .ranking-tabs{gap:7px}
 body #leaderboard:has(.tournament-empty) .ranking-tabs button{flex-direction:column;min-height:70px;padding:8px 5px;gap:5px}
 body #leaderboard .tournament-empty{padding:16px 0 10px;border:0;border-radius:0;gap:20px}
 body #leaderboard .tournament-arena{width:100%;max-width:none;aspect-ratio:704/430}
 body #leaderboard .stadium-art{aspect-ratio:704/430}
 body #leaderboard .tournament-stage .tournament-bird{width:13.64%}
 body #leaderboard .tournament-heading .tournament-amount{font-size:40px}
}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-light,body #leaderboard .stadium-window-light{animation:none;opacity:.7}}

/* The silver prize is engraved directly into the entrance's coordinate system. */
body #leaderboard .stadium-prize{animation:stadium-prize-light 4.8s ease-in-out infinite;pointer-events:none}
@keyframes stadium-prize-light{0%,100%{fill:#d5d5d5;filter:drop-shadow(0 0 1px #ffffff55)}50%{fill:#fff;filter:drop-shadow(0 0 4px #ffffff99)}}
body #leaderboard .tournament-empty{gap:0;padding:18px 8px 14px;border-color:#ffffff10;background:#000}
body #leaderboard .tournament-stage{margin-inline:auto}
body #leaderboard .tournament-arena{margin-inline:auto}
@media(min-width:761px){body #leaderboard .tournament-arena{width:min(100%,max(520px,calc((100vh - var(--academy-header-height,100px) - 142px) * 1.860465)))}@supports(height:100dvh){body #leaderboard .tournament-arena{width:min(100%,max(520px,calc((100dvh - var(--academy-header-height,100px) - 142px) * 1.860465)))}}}
@media(max-width:760px){
 body #leaderboard:has(.tournament-empty){padding:12px 6px max(12px,env(safe-area-inset-bottom,0px));gap:10px}
 body #leaderboard .tournament-empty{justify-content:center;min-height:calc(100svh - var(--academy-header-height,100px) - 116px);padding:12px 0 20px;border:0;gap:0}
 body #leaderboard .tournament-stage{align-items:center;justify-content:center}
 body #leaderboard .stadium-prize{font-size:27px;letter-spacing:.5px}
}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-prize{animation:none;filter:none}}

/* The animated prize shares the exact center of the arena's inner ring. */
body #leaderboard .stadium-prize{font-size:32px;letter-spacing:1px;text-anchor:middle;dominant-baseline:middle;animation:stadium-prize-light 4.8s ease-in-out infinite}
@media(max-width:760px){body #leaderboard .stadium-prize{font-size:34px;letter-spacing:.8px}}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-prize{animation:none;filter:none}}

/* Pixel-cut silver lettering belongs to the same world as the academy scenery. */
body #leaderboard .stadium-prize{font-family:'Academy Pixel',monospace;font-size:24px;font-weight:400;letter-spacing:0;fill:#dedede;stroke:#858585;stroke-width:.25px;paint-order:stroke fill;animation:academy-prize-silver 5s ease-in-out infinite}
@keyframes academy-prize-silver{0%,100%{fill:#d6d6d6;filter:drop-shadow(0 0 2px #ffffff55)}50%{fill:#fafafa;filter:drop-shadow(0 0 5px #ffffffb3) drop-shadow(0 0 10px #ffffff30)}}
/* Muted feather tones, smaller silhouettes, and softly lit hanging signs. */
#home .academy-raven{gap:12px}
#home .academy-raven>svg{width:56px;height:35px;flex:0 0 35px;opacity:.88;filter:none}
#home .academy-raven>svg path{fill:#171717}
#home .academy-raven>svg .raven-wing path{fill:#202020}
#home .academy-raven>svg>path:last-child{fill:#777;opacity:.65}
#home .raven-wing{animation:academy-feather-beat 1.05s steps(3,end) infinite}
#home .raven-1 .raven-wing{animation-delay:-.45s;animation-duration:1.15s}
#home .raven-sign{min-width:100px;padding:8px 10px;border:1px solid #70707080;border-radius:1px;background:linear-gradient(160deg,#2828289e,#101010b3);color:#c2c2c2;font-size:9px;line-height:1.5;box-shadow:0 2px 3px #0004,inset 0 1px #ffffff06;animation:academy-sign-drift 5s ease-in-out infinite,academy-sign-light 7s ease-in-out infinite;text-shadow:0 1px 1px #000}
#home .raven-sign:before{height:14px;background:#737373a6;box-shadow:none}
#home .raven-sign .tournament-amount{font-size:12px;color:#d0d0d0}
#home .raven-sign .tournament-label{gap:3px}
#home .raven-1 .raven-sign{animation-delay:-1.8s,-3.5s}
#home .academy-raven:hover .raven-sign,#home .academy-raven:focus-visible .raven-sign{color:#eee;border-color:#b2b2b2;background:linear-gradient(160deg,#303030d9,#151515d9)}
@keyframes academy-feather-beat{0%,100%{transform:scaleY(1)}50%{transform:scaleY(.28)}}
@keyframes academy-sign-drift{0%,100%{transform:rotate(-1.2deg)}50%{transform:rotate(1.2deg)}}
@keyframes academy-sign-light{0%,100%{text-shadow:0 1px 1px #000;box-shadow:0 2px 3px #0004,inset 0 1px #ffffff06}50%{text-shadow:0 1px 1px #000,0 0 3px #ffffff24;box-shadow:0 2px 3px #0004,inset 0 1px #ffffff0c,0 0 5px #ffffff0a}}
@media(max-width:480px){#home .academy-raven>svg{width:50px;height:32px;flex-basis:32px}#home .raven-sign{font-size:9px;padding:7px 9px}#home .raven-sign .tournament-amount{font-size:12px}}
@media(prefers-reduced-motion:reduce){body #leaderboard .stadium-prize,#home .raven-wing,#home .raven-sign{animation:none}body #leaderboard .stadium-prize{filter:drop-shadow(0 0 3px #ffffff55)}}

/* Separate the academy door from the larger cheer interaction. */
body #leaderboard .stadium-cheer-control{position:absolute;inset:0;display:block;width:100%;height:100%;padding:0;border:0;border-radius:10px;background:transparent;cursor:pointer;box-shadow:none}
body #leaderboard .tournament-door-trigger{position:absolute;left:50%;top:89%;transform:translate(-50%,-50%);display:grid;place-items:center;width:44px;height:44px;padding:10px;border:0;background:transparent;color:#c9c9c9;box-shadow:none;cursor:pointer;z-index:2;touch-action:manipulation}
body #leaderboard .tournament-door-trigger svg{width:24px;height:24px;filter:drop-shadow(0 0 3px #ffffff35);animation:academy-door-invite 3s ease-in-out infinite}
body #leaderboard .tournament-door-trigger:hover{color:#fff}
body #leaderboard .stadium-cheer-control:focus-visible,body #leaderboard .tournament-door-trigger:focus-visible{outline:2px solid #ccc;outline-offset:2px;border-radius:5px}
@keyframes academy-door-invite{0%,100%{opacity:.65;transform:translateY(1px)}50%{opacity:1;transform:translateY(-1px)}}
body dialog.tournament-details{width:min(440px,calc(100vw - 32px));max-height:calc(100svh - 32px);box-sizing:border-box;padding:36px 24px 28px;border:1px solid #666;border-radius:14px;background:linear-gradient(155deg,#202020,#080808 70%);box-shadow:0 25px 90px #000c,inset 0 0 0 4px #ffffff03;overflow:auto;text-align:center;color:#ddd}
body dialog.tournament-details[open]{animation:ranking-panel-reveal .28s ease-out}
body dialog.tournament-details::backdrop{background:#000b;backdrop-filter:blur(5px)}
.tournament-details-emblem{width:70px;height:70px;margin:8px auto 22px;color:#b9b9b9;filter:drop-shadow(0 0 10px #ffffff15)}
.tournament-details-emblem svg{display:block;width:100%;height:100%}
body .tournament-details .welcome-bubble{padding:20px 12px 8px;border:0;box-shadow:none;background:none}
body .tournament-details .welcome-bubble:before,body .tournament-details .welcome-bubble:after{display:none}
body .tournament-details #tournamentDetailsTitle{font:30px/1.5 'Academy Pixel',monospace;margin:14px 0 18px;color:#eee;text-shadow:0 0 12px #ffffff30}
body .tournament-details #tournamentDetailsMessage{margin:0;font:15px/1.8 Manrope,Arial,sans-serif;color:#b5b5b5;text-wrap:balance;overflow-wrap:anywhere}
@media(prefers-reduced-motion:reduce){body #leaderboard .tournament-door-trigger svg,body dialog.tournament-details[open]{animation:none}}

/* A translucent academy tournament invitation, with its own animated scholar. */
body dialog.tournament-details{width:min(480px,calc(100vw - 28px));max-height:calc(100svh - 28px - env(safe-area-inset-top,0px) - env(safe-area-inset-bottom,0px));padding:36px 28px 30px;border:1px solid #bcbcbc55;border-radius:20px;background:linear-gradient(150deg,#353535c4,#0b0b0be0 58%,#1c1c1cc9);backdrop-filter:blur(18px) saturate(.2);-webkit-backdrop-filter:blur(18px) saturate(.2);box-shadow:0 30px 100px #0009,inset 0 1px #ffffff26,inset 0 0 0 5px #ffffff03;isolation:isolate}
body dialog.tournament-details::backdrop{background:#0006;backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px)}
body .tournament-details .welcome-close{top:12px;right:12px;inset-inline-end:12px;width:44px;height:44px;background:#15151580;border:1px solid #ffffff24;border-radius:12px;color:#ccc;display:grid;place-items:center;padding:12px}
body .tournament-details .welcome-close:hover{background:#ffffff15;border-color:#aaa}
body .tournament-details .welcome-close:focus-visible{outline:2px solid #ddd;outline-offset:3px}
.tournament-mascot{position:relative;display:grid;place-items:center;width:min(100%,280px);height:190px;margin:4px auto 10px;pointer-events:none}
.tournament-mascot-halo{position:absolute;width:142px;height:142px;border:1px solid #ffffff20;border-radius:50%;background:radial-gradient(circle,#ffffff0b,transparent 65%);box-shadow:0 0 0 12px #ffffff02,0 0 28px #ffffff05;animation:tournament-halo-breathe 5s ease-in-out infinite}
.tournament-laurels{position:absolute;inset:0;width:100%;height:100%;color:#929292;opacity:.45}
body .tournament-details .tournament-scholar{position:relative;display:block;width:180px;height:140px;max-width:70%;overflow:visible;filter:drop-shadow(0 8px 8px #0005);animation:tournament-scholar-hover 4s ease-in-out infinite}
body .tournament-details .welcome-flight-wing{transform-origin:48px 42px;animation:tournament-scholar-wings 1.6s ease-in-out infinite}
body .tournament-details .welcome-flight-wing.wing-far{animation-delay:-.12s}
.tournament-mascot-plinth{position:absolute;bottom:9px;width:95px;height:9px;border:1px solid #bcbcbc30;border-radius:50%;background:#0003;animation:tournament-plinth-breathe 4s ease-in-out infinite}
body .tournament-details .welcome-bubble{padding:12px 0 0;background:none}
body .tournament-details .welcome-eyebrow{font-size:10px;line-height:1.8;letter-spacing:.16em;color:#b0b0b0}
body .tournament-details #tournamentDetailsTitle{font-size:clamp(28px,7vw,38px);margin:12px 0 24px;line-height:1.35;letter-spacing:0;animation:tournament-silver-glow 5s ease-in-out infinite}
body .tournament-details #tournamentDetailsMessage{display:flex;align-items:center;justify-content:center;gap:10px;padding:14px 16px;border:1px solid #ffffff18;border-radius:10px;background:#05050538;color:#c3c3c3;box-shadow:inset 0 1px #ffffff05;font-size:14px;line-height:1.6}
.tournament-status-dot{display:block;flex:0 0 5px;width:5px;height:5px;border-radius:50%;background:#bcbcbc;box-shadow:0 0 6px #ffffff35;animation:tournament-status-breathe 3s ease-in-out infinite}
@keyframes tournament-scholar-hover{0%,100%{transform:translateY(3px)}50%{transform:translateY(-5px)}}
@keyframes tournament-scholar-wings{0%,100%{transform:rotate(-3deg) scaleY(.94)}50%{transform:rotate(2deg) scaleY(.78)}}
@keyframes tournament-halo-breathe{0%,100%{opacity:.55}50%{opacity:1}}
@keyframes tournament-plinth-breathe{0%,100%{transform:scaleX(1);opacity:.6}50%{transform:scaleX(.8);opacity:.35}}
@keyframes tournament-status-breathe{0%,100%{opacity:.45}50%{opacity:1}}
@media(max-width:380px),(max-height:620px){body dialog.tournament-details{padding:28px 18px 22px;border-radius:16px}.tournament-mascot{height:150px;width:min(100%,230px)}.tournament-mascot-halo{width:112px;height:112px}body .tournament-details .tournament-scholar{width:150px;height:116px}body .tournament-details #tournamentDetailsTitle{margin-bottom:18px}}
@media(prefers-reduced-motion:reduce){body dialog.tournament-details *,body dialog.tournament-details[open]{animation:none!important}}

/* Slow, sparse snowfall is clipped to the sky, never painted over the buildings. */
.academy-snow{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:-1;contain:strict}
.academy-snow[hidden]{display:none!important}
.academy-snow>svg{position:absolute;display:block;max-width:none;overflow:hidden}
.academy-snowflake{fill:#d5d5d5;opacity:var(--snow-opacity);animation:academy-snowfall var(--snow-duration) linear infinite;animation-delay:var(--snow-delay)}
@keyframes academy-snowfall{from{transform:translate(-12px,-20px)}to{transform:translate(22px,680px)}}
body.auth-gated #account>.auth-snow{position:fixed;z-index:0;opacity:.65}
body.auth-gated #accountPanel{position:relative;z-index:1}
.snow-paused .academy-snowflake{animation-play-state:paused}
@media(prefers-reduced-motion:reduce){.academy-snow{display:none!important}}

/* Equal side slots keep the auth title centered independently of the language button. */
@media(max-width:480px){
 body #accountPanel .auth-layout>.auth-academy-header{grid-template-columns:44px minmax(0,1fr) 44px;gap:6px;padding:18px 12px}
 body #accountPanel .auth-academy-header h2{grid-column:2;grid-row:1;width:100%;text-align:center;text-wrap:balance;font-size:clamp(16px,4.6vw,21px);line-height:1.5;justify-self:center;align-self:center;margin:0}
 body.auth-gated #authLanguageButton{grid-column:3;grid-row:1;justify-self:end;align-self:center}
}

/* Dedicated upper sky lane clears the clock-tower spire on every screen. */
body.home-view #home.academy-night-home{--tournament-sky:clamp(132px,10vw,160px)}
body.home-view #home .academy-night-art{top:var(--tournament-sky);bottom:auto;height:calc(100% - var(--tournament-sky))}
#home .academy-raven.raven-0{top:18px}
@media(prefers-reduced-motion:reduce){#home .academy-raven.raven-0{top:18px}}

/* Keep the Academy bird's entire wingbeat below the clock face at every crop. */
#home .academy-raven.raven-1{top:var(--academy-bird-lane,52%)}
@media(prefers-reduced-motion:reduce){#home .academy-raven.raven-1{top:var(--academy-bird-lane,52%)}}

/* A focused Crypto path with readable progress and a direct lesson entry. */
body #academy .academy-layout>aside{padding:24px;border:1px solid #ffffff20;border-radius:14px;background:linear-gradient(150deg,#1c1c1c,#0b0b0b);align-self:start;box-sizing:border-box;min-width:0}
body #academy #progressText{margin:16px 0 12px;font-size:14px;line-height:1.6;color:#ddd}
body #academy .progress{height:5px;border-radius:5px;overflow:hidden;background:#ffffff12;margin:0 0 18px}
body #academy .progress i{height:100%;background:linear-gradient(90deg,#737373,#eee);border-radius:inherit}
.crypto-continue{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:46px;width:100%;padding:12px 16px;margin:0 0 20px;border:1px solid #888;border-radius:8px;background:linear-gradient(145deg,#e6e6e6,#bbb);color:#111;font:inherit;font-size:13px;cursor:pointer}
.crypto-continue svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.5;flex:none}
.crypto-continue:focus-visible{outline:2px solid #fff;outline-offset:4px}
body #academy #filters{display:grid;grid-template-columns:1fr;gap:8px}
body #academy #filters button{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:46px;padding:12px;border:1px solid #ffffff14;border-radius:8px;background:#ffffff03;color:#aaa;font-size:12px;line-height:1.5;text-align:start;overflow-wrap:anywhere}
body #academy #filters button span{display:block;flex:none;font-variant-numeric:tabular-nums;color:#888}
body #academy #filters button.active{border-color:#aaa;background:#ffffff0c;color:#eee}
body #academy .academy-layout>aside .small{display:block;line-height:1.6;font-size:11px;margin-bottom:0;color:#888}
@media(max-width:760px){body #academy .academy-layout>aside{padding:18px;margin-bottom:22px}body #academy #filters{grid-template-columns:repeat(2,minmax(0,1fr))}body #academy #filters button{font-size:11px;padding:10px}}
@media(max-width:340px){body #academy #filters{grid-template-columns:1fr}}
body dialog.academy-welcome[data-course=crypto],body dialog.academy-welcome[data-course=stocks]{width:min(500px,calc(100% - 24px))}
body .academy-welcome[data-course=crypto] .welcome-bird,body .academy-welcome[data-course=stocks] .welcome-bird{height:150px;min-height:150px}
body .academy-welcome[data-course=crypto] .welcome-milestones,body .academy-welcome[data-course=stocks] .welcome-milestones{margin-bottom:12px}

/* Community directory: consistent outlined cards, quiet glass and accessible search. */
body #members .member-directory-toolbar{display:flex;align-items:end;justify-content:space-between;gap:24px;margin:10px 0 22px}
body #members .member-directory-toolbar h3{font-size:clamp(22px,3vw,32px);font-weight:500;letter-spacing:-.035em;margin:6px 0 0}
body #members .member-search-label{display:grid;gap:8px;width:min(100%,360px);font-size:12px;color:#aeb0b6}
body #members .member-search-field{display:flex;align-items:center;gap:10px;min-height:48px;border:1px solid #41434a;border-radius:14px;background:linear-gradient(120deg,#191a1e,#0c0d10);padding:0 14px;transition:border-color .2s,box-shadow .2s}
body #members .member-search-field:focus-within{border-color:#b8bac2;box-shadow:0 0 0 3px #ffffff0d}
body #members .member-search-field svg{width:19px;height:19px;flex:none;fill:none;stroke:#b7bac1;stroke-width:1.5}
body #members #memberSearch{min-width:0;width:100%;border:0;background:transparent;color:#eee;padding:13px 0;outline:0;font-size:16px;box-shadow:none}
body #memberSearchStatus{font-size:12px;color:#a2a5ae;min-height:18px;margin:0 0 16px}
body #members #memberGrid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px;align-items:stretch}
body #members .member-card{min-width:0;border:1px solid #414249;border-radius:18px;background:linear-gradient(160deg,#141518,#08090b 60%);box-shadow:inset 0 1px 0 #ffffff0b,0 12px 30px #0004;overflow:hidden}
body #members .member-card .member-banner{box-sizing:border-box;border:1px solid #595b64;border-radius:12px;overflow:hidden;background-color:#17181d;box-shadow:inset 0 0 26px #ffffff08;min-height:90px}
body #members .member-banner .banner-empty-mark{color:#777b85;opacity:.3}
body #members .member-framed-avatar{border:0;border-radius:0;background:transparent;box-shadow:none}
body #members .member-card-bio{border:1px solid #35373f;border-radius:10px;background:#ffffff03;min-height:70px;padding:12px}
body #members .member-card-footer{margin-top:auto}
body #members .member-name{overflow-wrap:anywhere}
body #members .more-members-veil{position:relative;isolation:isolate;overflow:hidden;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:190px;margin-top:24px;padding:26px 18px;text-align:center;border:1px solid #42444d;border-radius:20px;background:linear-gradient(180deg,#111216,#08090c);box-shadow:inset 0 1px 0 #ffffff0c}
body #members .more-members-veil[hidden]{display:none}
.more-members-veil>svg{width:24px;height:24px;fill:none;stroke:#d0d3da;stroke-width:1.3;margin-bottom:8px}
.more-members-veil h3{font-size:20px;font-weight:500;letter-spacing:.02em;margin:4px 0 8px}.more-members-veil p{color:#a0a4ae;font-size:12px;margin:0}
.member-veil-clouds{position:absolute;inset:0;z-index:-1;filter:blur(20px);opacity:.4;pointer-events:none}
.member-veil-clouds i{position:absolute;width:55%;height:80px;border-radius:50%;background:radial-gradient(ellipse,#9297a244,transparent 70%);left:-5%;top:14%;animation:member-cloud-drift 12s ease-in-out infinite alternate}
.member-veil-clouds i:nth-child(2){left:45%;top:45%;animation-delay:-5s}.member-veil-clouds i:nth-child(3){left:20%;top:72%;animation-delay:-8s}
@keyframes member-cloud-drift{to{transform:translate(20%,12px) scale(1.25);opacity:.6}}
body .rank-top-ten{margin:18px 0;color:#a8aab4;font-size:12px;letter-spacing:.08em;text-align:start}
body .rank-top-ten[hidden]{display:none}
body #inviteRankingTab{position:relative;padding-inline-end:30px}
body .invite-tab-lock{position:absolute;inset-inline-end:10px;top:10px;display:grid;place-items:center;width:18px;height:18px;color:#9da0a8}
body .invite-tab-lock[hidden]{display:none}body .invite-tab-lock svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.5}
.invite-maintenance{box-sizing:border-box;position:fixed;width:min(380px,calc(100vw - 32px));max-height:calc(100dvh - 32px);padding:44px 24px 38px;border:1px solid #ffffff30;border-radius:24px;background:linear-gradient(145deg,#22242be8,#090a0fe8);color:#f0f0f3;text-align:center;box-shadow:0 30px 100px #000b,inset 0 1px 0 #ffffff12;backdrop-filter:blur(22px);-webkit-backdrop-filter:blur(22px);overflow:auto}
.invite-maintenance[open]{animation:maintenance-enter .35s ease-out}
.invite-maintenance::backdrop{background:#020306a8;backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}
.invite-maintenance .welcome-close{position:absolute;top:10px;inset-inline-end:10px;min-width:44px;min-height:44px;color:#c9cbd2;background:transparent;border:0;font-size:25px;cursor:pointer}
.invite-maintenance h2{font-family:Georgia,serif;font-size:clamp(26px,7vw,36px);font-weight:400;letter-spacing:.01em;margin:10px 0 0;overflow-wrap:anywhere}
.maintenance-orbit{position:relative;display:grid;place-items:center;width:110px;height:110px;margin:0 auto 22px;border:1px solid #ffffff20;border-radius:50%;background:radial-gradient(circle,#ffffff0c,transparent 70%)}
.maintenance-orbit>svg{width:44px;height:44px;fill:#ffffff05;stroke:#d1d5df;stroke-width:1.3;filter:drop-shadow(0 0 8px #b3bed23d);animation:maintenance-breathe 3s ease-in-out infinite alternate}
.maintenance-orbit>span{position:absolute;inset:-7px;border:1px solid transparent;border-top-color:#d7dce482;border-bottom-color:#d7dce424;border-radius:50%;animation:maintenance-turn 12s linear infinite}
.ranking-maintenance-state{padding:64px 24px;text-align:center;border:1px solid #ffffff20;border-radius:18px;background:#ffffff04}.ranking-maintenance-state h3{font:28px Georgia,serif}
@keyframes maintenance-enter{from{opacity:0;transform:translateY(10px) scale(.97)}to{opacity:1;transform:none}}
@keyframes maintenance-turn{to{transform:rotate(360deg)}}@keyframes maintenance-breathe{to{opacity:.6;transform:translateY(-3px)}}
@media(max-width:1000px){body #members #memberGrid{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}}
@media(max-width:600px){body #members .member-directory-toolbar{align-items:stretch;flex-direction:column;gap:18px}body #members .member-search-label{width:100%}body #members #memberGrid{grid-template-columns:minmax(0,1fr);gap:18px}body #members .member-card{width:100%;max-width:440px;justify-self:center}body #members .more-members-veil{min-height:170px}body .rank-top-ten{font-size:11px;letter-spacing:.04em}}
@media(prefers-reduced-motion:reduce){.member-veil-clouds i,.maintenance-orbit>span,.maintenance-orbit>svg,.invite-maintenance[open]{animation:none!important}}

/* Centered ranking caption; balanced ornaments keep every translation centered. */
body #leaderboard .rank-top-ten{display:flex;align-items:center;justify-content:center;gap:14px;width:fit-content;max-width:100%;margin:22px auto 26px;padding:10px 20px;border:1px solid #ffffff20;border-radius:999px;background:linear-gradient(110deg,#ffffff03,#ffffff08,#ffffff03);color:#c9ccd4;font-size:11px;font-weight:500;line-height:1.6;letter-spacing:.08em;text-align:center;box-shadow:inset 0 1px 0 #ffffff07}
body #leaderboard .rank-top-ten[hidden]{display:none}
body #leaderboard .rank-top-ten::before,body #leaderboard .rank-top-ten::after{content:"";width:4px;height:4px;flex:0 0 4px;transform:rotate(45deg);border:1px solid #c2c9d077;box-shadow:0 0 8px #cad5e21a}
/* Universal diamond perimeter is decoration, independent of earned badges. */
body .milestone-framed.milestone-diamond{--milestone-tone:#9caab8;--milestone-light:#edf5ff}
body .milestone-framed>.milestone-decoration{inset:0;border-radius:inherit}
body .milestone-framed>.milestone-decoration>.milestone-edge{padding:1.5px;opacity:.85;background-size:250% 250%;animation:milestone-shimmer 8s ease-in-out infinite}
body #members .member-card.milestone-framed{margin-top:0}
body #members #memberSearchStatus[hidden]{display:none}
/* Layered mist and a floating lock: no hidden profiles are loaded behind this veil. */
body #members .more-members-veil{min-height:224px;margin-top:28px;padding:34px 20px;border-color:#b4bcc52e;border-radius:22px;background:radial-gradient(ellipse at 50% 40%,#262d394d,transparent 65%),linear-gradient(145deg,#15171ccc,#08090ce6);box-shadow:inset 0 1px 0 #ffffff0d,0 18px 48px #0005}
body #members .more-members-veil::before{content:"";position:absolute;inset:9px;z-index:-1;border:1px solid #ffffff09;border-radius:15px;pointer-events:none}
body #members .more-members-veil>svg{position:relative;z-index:1;width:27px;height:27px;margin:8px 0 25px;stroke:#d4dce7;filter:drop-shadow(0 0 8px #d3e2ff33);animation:veil-lock-float 5s ease-in-out infinite}
body #members .more-members-veil h3{font-family:Georgia,'Times New Roman',serif;font-size:clamp(23px,4vw,29px);font-weight:400;color:#e1e4eb;letter-spacing:.025em;line-height:1.35;margin:0 0 10px;text-shadow:0 0 22px #dbe5ff18}
body #members .more-members-veil p{max-width:30em;font-size:12px;line-height:1.6;color:#a3a9b6}
body #members .member-veil-clouds{filter:blur(14px);opacity:.8;inset:-20px;overflow:hidden}
body #members .member-veil-clouds i{width:65%;height:130px;top:15%;background:radial-gradient(ellipse,#9aa8be38 0%,#77849c1a 38%,transparent 70%);animation:member-cloud-drift 14s ease-in-out infinite alternate}
body #members .member-veil-clouds i:nth-child(2){left:48%;top:36%;animation-delay:-6s;animation-duration:19s}
body #members .member-veil-clouds i:nth-child(3){left:10%;top:60%;animation-delay:-11s;animation-duration:17s}
body #members .member-veil-clouds i:nth-child(4){left:55%;top:-20%;animation-delay:-4s;animation-duration:22s}
.member-veil-orbit{position:absolute;top:29px;left:50%;width:64px;height:64px;margin-left:-32px;border:1px solid #c1ccd62b;border-radius:50%;box-shadow:inset 0 0 20px #bbcaff08,0 0 30px #bbcaff05;pointer-events:none}
@keyframes veil-lock-float{0%,100%{transform:translateY(0);opacity:.75}50%{transform:translateY(-3px);opacity:1}}
/* The same recovery component handles slow boots and temporary account failures. */
body #accountPanel .session-reconnect{box-sizing:border-box;position:relative;isolation:isolate;width:min(100%,500px);max-width:500px;margin:clamp(20px,6vh,64px) auto;padding:clamp(28px,5vw,48px);border:1px solid #aab6c435;border-radius:24px;background:radial-gradient(ellipse at 50% 0,#353e4d40,transparent 65%),linear-gradient(150deg,#191c22e8,#0a0c10ed);color:#edf0f5;text-align:center;box-shadow:0 24px 70px #0005,inset 0 1px 0 #ffffff0c;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);animation:maintenance-enter .4s ease-out}
body .session-reconnect .eyebrow{font-size:10px;letter-spacing:.16em;line-height:1.6;color:#aab3c1}
body #accountPanel .session-reconnect h3{font-family:Georgia,'Times New Roman',serif;font-weight:400;font-size:clamp(25px,5vw,33px);letter-spacing:-.025em;line-height:1.25;margin:12px 0 0;text-wrap:balance;overflow-wrap:anywhere}
body #accountPanel .session-reconnect p{max-width:32em;margin:20px auto 26px;font-size:14px;line-height:1.8;color:#aeb6c4;text-wrap:pretty}
body #accountPanel .session-reconnect button{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;min-height:48px;padding:13px 20px;border:1px solid #d3d9e052;border-radius:12px;background:linear-gradient(135deg,#e5e9f0,#bcc5d2);color:#10141a;font-family:inherit;font-size:14px;font-weight:500;line-height:1.5;cursor:pointer;box-shadow:inset 0 1px 0 #ffffff80,0 8px 20px #0003;transition:transform .2s,filter .2s}
body #accountPanel .session-reconnect button svg{width:18px;height:18px;flex:none;fill:none;stroke:currentColor;stroke-width:1.5}
body #accountPanel .session-reconnect button:hover{filter:brightness(1.08);transform:translateY(-1px)}
body #accountPanel .session-reconnect button:focus-visible{outline:2px solid #e9f3ff;outline-offset:5px}
body #accountPanel .session-reconnect button:disabled{opacity:.6;cursor:wait;transform:none}
.reconnect-signal{position:relative;display:grid;place-items:center;width:96px;height:96px;margin:0 auto 28px;border:1px solid #b9c9e125;border-radius:50%;background:radial-gradient(circle,#c1d5f410,transparent 70%)}
.reconnect-signal>svg{width:40px;height:40px;fill:none;stroke:#c9d6e8;stroke-width:1.4;stroke-linecap:round;filter:drop-shadow(0 0 8px #bfd5f530)}
.reconnect-signal>span{position:absolute;inset:0;border:1px solid #b8cde039;border-radius:50%;animation:reconnect-signal 4s ease-out infinite;pointer-events:none}.reconnect-signal>span:nth-child(2){animation-delay:2s}
@keyframes reconnect-signal{0%{transform:scale(.85);opacity:0}25%{opacity:.6}100%{transform:scale(1.35);opacity:0}}
@media(max-width:600px){body #leaderboard .rank-top-ten{margin:18px auto 22px;padding:9px 15px;font-size:10px;letter-spacing:.045em;gap:11px}body #members .more-members-veil{min-height:216px}body #accountPanel .session-reconnect{border-radius:20px;padding:30px 22px;margin:20px auto}}
@media(prefers-reduced-motion:reduce){body .milestone-framed>.milestone-decoration>.milestone-edge,body #members .more-members-veil>svg,body #members .member-veil-clouds i,body #accountPanel .session-reconnect,.reconnect-signal>span{animation:none!important}.reconnect-signal>span{opacity:0}}

body #leaderboard .rank-top-ten{letter-spacing:.2em;font-weight:600;color:#e0e5ed;animation:top-ten-glow 4s ease-in-out infinite}
@keyframes top-ten-glow{0%,100%{text-shadow:0 0 6px #d8e6ff22;box-shadow:inset 0 1px 0 #ffffff07,0 0 12px #bbcfff04;border-color:#ffffff20}50%{text-shadow:0 0 12px #d8e6ff66;box-shadow:inset 0 1px 0 #ffffff13,0 0 20px #bbcfff12;border-color:#dae7ff45}}
@media(prefers-reduced-motion:reduce){body #leaderboard .rank-top-ten{animation:none}}

/* Match the closing ranking marker to the centered animated heading. */
body #leaderboard .rank-top-ten-bottom{margin:28px auto 12px}
body .framed-avatar{background:transparent;border-radius:0;box-shadow:none}
/* Deep charcoal mist; a single centered lock anchors the content stack. */
body #members .more-members-veil{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:0;min-height:224px;padding:32px 20px;background:radial-gradient(ellipse at 50% 40%,#14171c80,transparent 66%),linear-gradient(145deg,#08090b,#020304);border-color:#ffffff1a;box-shadow:inset 0 1px 0 #ffffff06,0 16px 40px #0006;text-align:center}
body #members .more-members-veil>svg{display:block;flex:none;width:30px;height:30px;margin:0 0 20px;stroke:#c7cdd6;filter:drop-shadow(0 0 5px #cbd5e524);animation:members-lock-breathe 4.5s ease-in-out infinite}
body #members .more-members-veil h3{margin:0 0 10px;color:#d6d9df;text-shadow:none}
body #members .more-members-veil p{margin:0;color:#858b96}
body #members .member-veil-clouds{opacity:.35;filter:blur(18px)}
body #members .member-veil-clouds i{background:radial-gradient(ellipse,#737c8c24,transparent 70%)}
@keyframes members-lock-breathe{0%,100%{transform:translateY(0);opacity:.65;filter:drop-shadow(0 0 3px #cbd5e514)}50%{transform:translateY(-3px);opacity:1;filter:drop-shadow(0 0 8px #cbd5e53d)}}
@media(max-width:600px){body #members .more-members-veil{min-height:210px;padding:30px 18px}}
@media(prefers-reduced-motion:reduce){body #members .more-members-veil>svg{animation:none}}

/* Community navigation: equal, responsive segments with clear selected state. */
body #friends .community-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;width:min(100%,560px);max-width:100%;box-sizing:border-box;margin:0 auto 30px;padding:6px;border:1px solid #ffffff1c;border-radius:19px;background:linear-gradient(135deg,#121316,#060708);box-shadow:inset 0 1px 0 #ffffff05,0 8px 28px #0003}
body #friends .community-tabs>a{display:flex;position:relative;align-items:center;justify-content:center;gap:12px;min-width:0;min-height:66px;padding:12px 18px;border:1px solid transparent;border-radius:13px;background:transparent;color:#858a94;font-size:14px;font-weight:500;line-height:1.4;text-decoration:none;transition:background .25s,border-color .25s,color .25s,box-shadow .25s}
body #friends .community-tabs>a::after{display:none}
body #friends .community-tabs>a[aria-current]{color:#edf0f6;background:linear-gradient(135deg,#2a2d35a8,#15171de6);border-color:#b2bccd38;box-shadow:inset 0 1px 0 #ffffff0b,0 4px 12px #0003}
body #friends .community-tab-icon{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;border:1px solid #ffffff0c;border-radius:9px;background:#ffffff03;color:#7c8491;transition:color .25s,background .25s}
body #friends .community-tab-icon svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:round}
body #friends .community-tabs>a[aria-current] .community-tab-icon{color:#d5dfed;background:#ffffff06;border-color:#ffffff19}
body #friends .community-tab-label{min-width:0;overflow-wrap:anywhere;text-align:center}
body #friends .community-tab-indicator{flex:0 0 4px;width:4px;height:4px;margin-inline-start:4px;border-radius:50%;background:#bfcde2;opacity:0;transition:opacity .25s;box-shadow:0 0 9px #cfdefa66}
body #friends .community-tabs>a[aria-current] .community-tab-indicator{opacity:.85}
body #friends .community-tabs>a:focus-visible{outline:2px solid #d7e2f4;outline-offset:3px}
@media(hover:hover){body #friends .community-tabs>a:hover{color:#edf0f6;border-color:#ffffff25;background-color:#ffffff06}}
@media(max-width:600px){body #friends .community-tabs{width:100%;margin-bottom:22px;border-radius:16px;padding:5px;gap:5px}body #friends .community-tabs>a{min-height:60px;gap:8px;padding:10px 9px;font-size:12px;border-radius:11px}body #friends .community-tab-icon{flex-basis:28px;width:28px;height:28px}body #friends .community-tab-icon svg{width:17px;height:17px}body #friends .community-tab-indicator{margin-inline-start:0}}
@media(prefers-reduced-motion:reduce){body #friends .community-tabs>a,body #friends .community-tab-icon,body #friends .community-tab-indicator{transition:none}}

/* Compact invitation strip keeps the profile editor close to its heading. */
body #accountPanel #personalInvite{box-sizing:border-box;display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:10px 22px;width:100%;max-width:100%;padding:14px 18px;margin:0 0 18px;border:1px solid #ffffff1c;border-radius:13px;background:linear-gradient(130deg,#121418,#08090b);box-shadow:inset 0 1px 0 #ffffff05}
body #accountPanel #personalInvite>.eyebrow{grid-column:1/-1;margin:0;padding:0;font-size:9px;line-height:1.4;letter-spacing:.14em;color:#a5abb7}
body #accountPanel #personalInvite .invite-link-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:stretch;gap:7px;min-width:0;width:100%;margin:0}
body #accountPanel #personalInvite .invite-link-row input{box-sizing:border-box;width:100%;min-width:0;min-height:44px;height:44px;margin:0;padding:10px 12px!important;font-size:13px!important;line-height:1.4;border-color:#ffffff1c!important;border-radius:8px;background:#050608!important;text-overflow:ellipsis}
body #accountPanel #personalInvite .invite-link-row button{box-sizing:border-box;display:flex;align-items:center;justify-content:center;width:auto;min-width:78px;min-height:44px;margin:0;padding:10px 13px;border:1px solid #bdc5d240;border-radius:8px;background:#242830;color:#e2e7ef;font-size:11px;line-height:1.4;white-space:normal;max-width:150px}
body #accountPanel #personalInvite .invite-link-row button:focus-visible{outline:2px solid #d8e4f5;outline-offset:3px}
body #accountPanel #personalInvite .invite-stats{display:flex;flex-wrap:wrap;align-items:center;gap:8px 18px;max-width:340px;margin:0;color:#9098a6;font-size:10px;line-height:1.5}
body #accountPanel #personalInvite .invite-stats>span{display:flex;align-items:center;gap:7px;min-width:0;max-width:100%}
body #accountPanel #personalInvite .invite-stats b{display:inline;flex:none;margin:0;color:#e0e5ed;font-size:16px;font-weight:500;line-height:1.3;font-variant-numeric:tabular-nums}
body #accountPanel #personalInvite .invite-copy-status{grid-column:1/-1;margin:0;font-size:11px;line-height:1.5;color:#b5bfcd}
body #accountPanel #personalInvite .invite-copy-status:empty{display:none}
body #accountPanel #personalInvite:has(>.ethereum-loading:only-child){display:grid;place-items:center;min-height:66px;padding:12px}
body #accountPanel #personalInvite>.ethereum-loading:only-child{width:26px;height:36px;margin:0}
body #accountPanel #personalInvite>.ethereum-loading:only-child svg{width:24px;height:36px}
@media(max-width:900px){body #accountPanel #personalInvite{grid-template-columns:minmax(0,1fr);gap:10px;padding:13px 14px}body #accountPanel #personalInvite .invite-stats{max-width:none;gap:6px 16px}}
@media(max-width:400px){body #accountPanel #personalInvite{padding:12px;border-radius:11px}body #accountPanel #personalInvite .invite-link-row button{min-width:70px;max-width:110px;padding:10px;font-size:10px}body #accountPanel #personalInvite .invite-stats{font-size:9px}body #accountPanel #personalInvite .invite-stats b{font-size:14px}}
