/* fcmobile.shop shell tokens. EA profile panels and card canvases keep their
   native textures, typography and semantic colors in native-profile.css. */
@font-face{font-family:ShopInter;src:url('fonts/inter-4.1-variable.woff2') format('woff2');font-style:normal;font-weight:100 900;font-display:swap}
:root{--shop-bg:#09111f;--shop-card:rgba(20,30,54,.88);--shop-stroke:rgba(255,255,255,.08);--shop-glass-bg:rgba(10,17,31,.62);--shop-glass-filter:blur(16px);--shop-text:#f7fbff;--shop-muted:#93a4c7;--shop-blue:#46a6ff;--shop-blue-2:#6f7cff}
/* Shop viewport gradient plus its two fixed, 80px-blurred edge glows.
   One surface is shared by every section and the player dialog's backdrop. */
:root{--shop-page-background:url('shop-background-glows.svg') center/100% 100% no-repeat,radial-gradient(circle at top,#12264d 0%,var(--shop-bg) 40%,#070d19 100%) center/cover no-repeat,var(--shop-bg)}
/* Same fixed paint surface as newdesign/styles.css. iOS must not size a
   fixed-attachment root gradient against the full scrolling document. */
html{min-height:100%;isolation:isolate;background:var(--shop-bg)}
html::before{content:'';position:fixed;inset:0;z-index:-1;pointer-events:none;background:var(--shop-page-background)}
body{font-family:ShopInter,system-ui,sans-serif;background:transparent;box-shadow:none;color:var(--shop-text)}
/* Safari may restore :focus-visible to a tapped link after closing a dialog.
   Keep real keyboard focus; do not paint a keyboard ring for a touch return. */
html[data-input-modality="pointer"] :is(a,button,summary):focus-visible{outline:none!important}
body>main{padding-inline:14px;background:none}
/* One top inset for Database utilities, including the spinner heading and sound control. */
body>main>:is(.redeem-page,.playstyles-page,.events-page,.compare-page,.squad-page,.spinner-page,.rankings-page,.best-page){padding-top:12px}
.database-header{position:sticky;top:calc(10px + env(safe-area-inset-top,0px));z-index:1000;height:auto;min-height:0;margin:calc(10px + env(safe-area-inset-top,0px)) 14px 16px;padding:10px 12px;background:var(--shop-glass-bg);border:1px solid var(--shop-stroke);border-radius:18px;backdrop-filter:var(--shop-glass-filter);-webkit-backdrop-filter:var(--shop-glass-filter)}
.database-header .brand{gap:10px;font-family:ShopInter,system-ui,sans-serif;letter-spacing:0}
.database-header .shop-brand-logo{display:block;flex:none;width:34px;height:34px;object-fit:contain}
.database-header .brand{min-width:0;max-width:calc(100% - 86px)}
.database-header.has-guest-profile .brand{max-width:calc(100% - 130px)}
.database-header .brand>span{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:linear-gradient(135deg,#ffffff,#8fa3c7);background-clip:text;-webkit-background-clip:text;color:transparent}
.header-actions{position:absolute;top:50%;right:12px;transform:translateY(-50%);display:flex;align-items:center;gap:8px;margin-left:auto;flex:none}
.database-header .header-action{display:flex;align-items:center;justify-content:center;flex:none;width:34px;height:34px;padding:0;border:1px solid var(--shop-stroke);border-radius:12px;background:#ffffff05;color:var(--shop-text);text-decoration:none;cursor:pointer}
.database-header .header-action:hover{background:#46a6ff14;border-color:#46a6ff66}
.database-header .header-action:focus-visible{outline:2px solid var(--shop-blue);outline-offset:2px}
.database-header .header-action svg{display:block;flex:none;width:18px;height:18px}
.database-header .header-profile{position:relative;overflow:hidden;border:0;background:linear-gradient(135deg,#ffffff,#8fa3c7);box-shadow:none;color:#03111f;font-size:14px;font-weight:900}
.database-header .header-profile:hover{background:linear-gradient(135deg,#ffffff,#8fa3c7)}
.database-header .header-profile.has-avatar{background:transparent;box-shadow:none}
.database-header .header-profile .header-profile-image{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:cover;border-radius:inherit}
/* Буква базовой аватарки: обрезаем строку до высоты заглавной, чтобы flex ставил её ровно по центру. */
.database-header .header-profile-initial{display:block;line-height:1;text-box:trim-both cap alphabetic}
/* Match the shop's auth-login-btn without importing shop styles into Database. */
.database-header .header-profile.is-guest{width:auto;padding:0 16px 1px;border-radius:12px;background:rgba(255,255,255,.06);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border:1px solid rgba(255,255,255,.15);box-shadow:none;color:#fff;font-size:13px;font-weight:700;line-height:1;letter-spacing:.3px;text-shadow:0 0 4px rgba(255,255,255,.2);transition:transform .2s ease}
.database-header .header-profile.is-guest:hover{background:rgba(255,255,255,.06);border-color:rgba(255,255,255,.15)}
.database-header .header-profile.is-guest:active{transform:scale(.97)}
.database-header .brand-icon{clip-path:none;border-radius:10px;background:linear-gradient(135deg,var(--shop-blue),var(--shop-blue-2));color:white}
.database-header .local{color:var(--shop-muted)}
body>main .intro{padding-top:12px;background:none;border-color:var(--shop-stroke)}
body>main h1{font-family:ShopInter,system-ui,sans-serif;font-weight:800}
/* Same 135deg blue-to-violet gradient as shop2 primary buttons. */
body>main h1 em,body>main .eyebrow{color:var(--shop-blue);background-image:linear-gradient(135deg,var(--shop-blue),var(--shop-blue-2));background-clip:text;-webkit-background-clip:text;-webkit-text-fill-color:transparent}
body>main .eyebrow{width:fit-content;max-width:100%}
body>main .intro p,body>main .counts span,:is(body>main,.squad-dialog) .results-line,body>main .muted{color:var(--shop-muted)}
body>main .counts{display:flex;flex-direction:row;justify-content:space-between;width:100%;gap:12px}
body>main .counts>div{min-width:0;align-items:center;text-align:center}
body>main .counts strong{white-space:nowrap}
@media(max-width:360px){body>main .counts{gap:8px}body>main .counts strong{font-size:18px}body>main .counts span{font-size:10px}}
:is(body>main,.squad-dialog) .search{background:linear-gradient(#0f172a,#0f172a) padding-box,linear-gradient(135deg,var(--shop-blue),var(--shop-blue-2)) border-box;border:1px solid transparent;border-radius:16px;box-shadow:none}
:is(body>main,.squad-dialog) .search:focus-within{border-color:transparent;box-shadow:0 0 0 3px #6f7cff1a}
:is(body>main,.squad-dialog) .search span{color:var(--shop-blue)}
:is(body>main,.squad-dialog) .search>span{display:flex;align-items:center;justify-content:center}
:is(body>main,.squad-dialog) .search>span svg{display:block;flex:none}
:is(body>main,.squad-dialog) :is(.search input,.squad-formation-search .squad-search){font-family:ShopInter,system-ui,sans-serif;font-size:16px;color:var(--shop-text)}
:is(body>main,.squad-dialog) .search input:focus-visible{outline:none;box-shadow:none}
:is(body>main,.squad-dialog) :is(.search input,.squad-formation-search .squad-search)::placeholder{color:var(--shop-muted);font-size:12px}
/* Match select chevrons: 16px glyph, 14px right inset, same neutral color. */
:is(body>main,.squad-dialog) .search :is(#clear,[data-search-clear]){display:flex;align-items:center;justify-content:center;flex:0 0 32px;width:32px;height:32px;margin:0 -8px 0 0;padding:0;border:0;background:none;color:var(--shop-muted);line-height:0}
:is(body>main,.squad-dialog) .search :is(#clear,[data-search-clear]) svg{display:block;width:16px;height:16px;flex:none}
body>main select{font-family:ShopInter,system-ui,sans-serif;border:1px solid var(--shop-stroke);border-radius:12px;background:rgba(15,23,42,.96);color:var(--shop-text)}
body>main select:focus{outline:2px solid var(--shop-blue);outline-offset:1px}
:is(body>main,.squad-dialog) .player{border:1px solid var(--shop-stroke);border-image:none;border-radius:16px;background:var(--shop-card);box-shadow:0 8px 24px #0002}
:is(body>main,.squad-dialog) .player:hover{border-color:#46a6ff80}
:is(body>main,.squad-dialog) .player-name{font-family:ShopInter,system-ui,sans-serif}
:is(body>main,.squad-dialog) .catalog-price-slot{height:38px;display:flex;justify-content:center;align-items:flex-start}
:is(body>main,.squad-dialog) .catalog-shard-price{display:flex;align-items:center;justify-content:center;gap:5px;width:fit-content;max-width:100%;padding:4px 7px;margin:2px auto 10px;border:1px solid #46a6ff38;border-radius:7px;background:#46a6ff0d;color:var(--shop-text);vertical-align:top}
.catalog-shard-price img{display:block;width:16px;height:16px;flex:none;object-fit:contain}
.catalog-shard-price b{font:600 12px/1.3 ShopInter,system-ui,sans-serif;font-variant-numeric:proportional-nums;white-space:nowrap}
:is(body>main,.squad-dialog) .player-meta b{color:var(--shop-blue)}
:is(body>main,.squad-dialog) .player-meta>span{min-width:0;line-height:1.5}
:is(body>main,.squad-dialog) .player-meta b{flex-shrink:0;align-self:center}
:is(body>main,.squad-dialog) .pagination button{font-family:ShopInter,system-ui,sans-serif;border:1px solid var(--shop-stroke);border-radius:12px;background:var(--shop-card);color:var(--shop-text)}
:is(body>main,.squad-dialog) .pagination button:not(:disabled):hover{border-color:var(--shop-blue);background:#152744}
body>main button:focus-visible,body>main a:focus-visible{outline-color:var(--shop-blue)}
body>main footer{border-color:var(--shop-stroke);color:var(--shop-muted)}
/* Original shop navigation surface and glass selection, including in modal. */
.db-bottom-nav{background:linear-gradient(180deg,rgba(7,13,25,0),rgba(7,13,25,.5) 20%,rgba(7,13,25,.92))}
.db-nav-shell{background:rgba(8,14,26,.82);border-color:rgba(255,255,255,.06);box-shadow:0 16px 32px #0006}
.db-nav-item{font-family:ShopInter,system-ui,sans-serif;font-size:9.5px;font-weight:600;color:#8fa3c7;opacity:.7;overflow:hidden}
.db-nav-item.is-active{color:#fff;opacity:1;background:linear-gradient(135deg,#ffffff2e 0%,#ffffff08 45%,#ffffff14);box-shadow:inset 0 0 0 1px #ffffff1f,0 4px 12px #0002}
.db-nav-item.is-active::after{inset:0;left:-150%;right:auto;bottom:auto;width:100%;height:100%;border-radius:0;box-shadow:none;background:linear-gradient(90deg,transparent 30%,#ffffff26 50%,transparent 70%);transform:skewX(-20deg);animation:shop-nav-glint 6s infinite ease-in-out;pointer-events:none}
.db-nav-item>svg,.db-nav-item>span{position:relative;z-index:1}
.db-nav-item:hover{color:#fff;opacity:1}
.db-nav-item:focus-visible{outline-color:var(--shop-blue)}
@keyframes shop-nav-glint{0%{left:-150%;opacity:0}15%{opacity:.6}45%,100%{left:150%;opacity:0}}
@media(prefers-reduced-motion:reduce){.db-nav-item.is-active::after{animation:none;display:none}}
:is(body>main,.squad-dialog) .db-pagination{display:flex;justify-content:center;align-items:center;gap:6px}
:is(body>main,.squad-dialog) :is(.pagination,.db-pagination)[hidden]{display:none}
:is(body>main,.squad-dialog) .db-pagination button{min-width:34px;height:36px;padding:0 8px;border:1px solid var(--shop-stroke);border-radius:10px;background:var(--shop-card);color:var(--shop-text);font:500 12px ShopInter,system-ui,sans-serif}
:is(body>main,.squad-dialog) .db-pagination button[aria-current=page]{border-color:#77aaff88;background:#499bff26;color:#edf4ff}
:is(body>main,.squad-dialog) .db-pagination button:disabled{opacity:.35;cursor:default}
/* One bottom clearance, matching the header-to-content gap. The body's nav
   allowance already includes this space; sections must not add it again. */
body>main :is(.catalog,.events-page,.account-page,.squad-page,.compare-page,.redeem-page,.home-shortcuts,.spinner-page,.rankings-page,.best-page){padding-bottom:0}
body>main .pagination{padding-bottom:0}
body>main .compare-scroll:not(.is-static){padding-bottom:8px}
body>main .compare-table>.compare-stat-row:last-child{margin-bottom:0}
#detail .profile-panels{padding-bottom:0}

.database-header{transition:transform 440ms cubic-bezier(.22,1,.36,1);will-change:transform}
.database-header.is-scroll-hidden{transform:translateY(calc(-100% - 24px - env(safe-area-inset-top,0px)));transition-timing-function:cubic-bezier(.4,0,.6,1)}
@media (prefers-reduced-motion:reduce){.database-header{transition:none}}

/* Двойной тап нигде не увеличивает страницу, щипок двумя пальцами остаётся (как в приложении). */
:where(html,body,body *){touch-action:manipulation}
/* Экраны-инструменты без зума: редактор, сравнение, спиннер, страница игрока. Только прокрутка.
   Нулевая специфичность: явные правила элементов (перетаскивание карточек, ползунки) важнее. */
:where(html[data-page=squad],html[data-page=compare],html[data-page=spinner],#detail[open]),:where(html[data-page=squad],html[data-page=compare],html[data-page=spinner],#detail[open]) :where(*){touch-action:pan-x pan-y}
html[data-page=compare] .compare-scroll{touch-action:pan-x pan-y}
