/* Page-level mode navigation stays in the header on both game pages. */
.mode-switch{display:inline-flex;flex:none;align-items:center;gap:3px;padding:3px;border:1px solid #d8e5d8;border-radius:10px;background:#f2f7ef}
.mode-switch>a,.mode-switch>span{display:block;padding:8px 11px;border-radius:7px;color:#486b56;font:700 12px/1.15 Arial,sans-serif;text-decoration:none;white-space:nowrap}
.mode-switch>a:hover{background:#e1eddd;color:#234e37}
.mode-switch>a:focus-visible{outline:3px solid #cb865c;outline-offset:2px}
.mode-switch>[aria-current="page"]{background:#275c40;color:#fff;box-shadow:0 1px 3px #173f2930}
.mode-chooser{grid-template-columns:minmax(0,1fr)}
@media(max-width:1050px){body>header:has(.mode-switch)>small{display:none}body>header:has(.mode-switch){gap:12px}}
@media(max-width:700px){
 body>header:has(.mode-switch),body.in-match>header.site-header:has(.mode-switch){height:auto;min-height:70px;flex-wrap:wrap;gap:8px;padding-top:9px;padding-bottom:9px}
 body>header:has(.mode-switch)>.brand{order:0}
 body>header:has(.mode-switch)>.header-actions,body>header:has(.mode-switch)>.mp-header-actions{order:1;margin-left:auto}
 body>header:has(.mode-switch)>.mode-switch{order:2;flex:1 0 100%;justify-content:center}
 .mode-switch>a,.mode-switch>span{flex:1;text-align:center}
}

/* A signed-in player's own landmark and earned frame appear in the account button. */
header #profile-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap}
header #profile-button .gp-header-avatar{display:inline-grid;place-items:center;width:23px;height:23px;min-width:23px;margin:0 3px 0 0;border-radius:50%;background:#edf4e9;vertical-align:middle;flex:none}
header #profile-button .gp-header-avatar>svg{display:block;width:100%;height:100%}
@media(max-width:380px){header #profile-button:has(.gp-header-avatar){padding-inline:7px;min-width:39px}header #profile-button:has(.gp-header-avatar) .gp-profile-label{display:none}header #profile-button .gp-header-avatar{margin-right:0}}

/* Keep the account control the same size as its neighboring header buttons. */
body header #profile-button,body header.site-header #profile-button{box-sizing:border-box;position:relative;display:grid;place-items:center;width:42px;height:42px;min-width:42px;min-height:42px;max-width:42px;padding:0;font-size:0;overflow:visible}
header #profile-button .gp-profile-label{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
body header #profile-button .gp-header-avatar{width:23px;height:23px;min-width:23px;margin:0}
header #profile-button:not(:has(.gp-header-avatar))::before{content:'';display:block;width:21px;height:21px;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21a8 8 0 0 1 16 0Z'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21a8 8 0 0 1 16 0Z'/%3E%3C/svg%3E") center/contain no-repeat}
@media(max-width:500px){body header.site-header #profile-button{width:39px;height:39px;min-width:39px;min-height:39px;max-width:39px}}
@media(max-width:380px){body header:not(.site-header) #profile-button{width:38px;height:38px;min-width:38px;min-height:38px;max-width:38px}}
@media(max-width:350px){body header.site-header #profile-button{width:36px;height:36px;min-width:36px;min-height:36px;max-width:36px}}

/* Keep each player's earned frame visible at account-button size. */
header #profile-button .gp-header-avatar.geo-frame:not(.gp-frame-classic){outline:0!important;box-shadow:0 0 0 1px #fffdf7,0 0 0 3px var(--rim),0 0 0 5px var(--glow)!important}
header #profile-button .gp-header-avatar.geo-frame:not(.gp-frame-classic):not([class*="gp-frame-daily_"])::before{inset:-6px!important;opacity:1}
header #profile-button .gp-header-avatar.geo-frame:not(.gp-frame-classic)::after{width:9px;height:9px;top:-4px;right:-4px;font-size:6px;line-height:8px}
header #profile-button .gp-header-avatar.geo-frame[class*="gp-frame-daily_"]::before{inset:auto auto -5px 50%!important;width:11px;height:11px;font-size:7px;line-height:13px}
header #profile-button .gp-header-avatar.geo-frame>.geo-favorite-flag{top:-3px;right:-4px;width:14px;height:10px;border-width:1px;border-radius:2px}
