﻿/* final viewport + bottom-nav fix */
html, body {
  min-height: 100svh;
  height: 100svh;
  background:
    radial-gradient(circle at top, rgba(13,63,123,.55), transparent 35%),
    linear-gradient(180deg, #06152d 0%, #041022 42%, #020912 100%) fixed;
}
body { overflow: hidden; }
#games-screen .redesign-screen-head {
  align-items: center;
}
#games-screen .screen-title {
  margin-bottom: 0;
}
#games-screen .screen-subtitle,
#games-screen .screen-kicker,
#cases-screen .screen-subtitle,
#free-screen .screen-subtitle,
#tasks-screen .screen-subtitle,
#tournament-screen .screen-subtitle,
#profile-screen .section-subtext {
  display: none !important;
}
#games-screen .game-select-grid.redesign-games-grid {
  gap: 10px;
}
#games-screen .game-pick-card.game-pick-visual {
  min-height: 84px;
  border-radius: 24px;
}
#games-screen .game-pick-card .game-pick-content {
  padding: 16px 18px;
}
#games-screen .game-pick-card .game-pick-title {
  font-size: 18px;
}
#games-screen .game-pick-card .game-pick-text {
  display: none;
}
/* games cards stretch fix */
#games-screen .game-select-grid.redesign-games-grid {
  width: 100%;
}
#games-screen .game-pick-card.game-pick-visual {
  width: 100%;
}
#games-screen .cards-stack.redesign-games-stack {
  gap: 14px;
}
#games-screen .redesign-screen-head {
  margin-bottom: 14px;
}
#games-screen .chip-btn {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 34px;
  line-height: 1;
}
/* full width fix for Games and Free screens */
#games-screen,
#free-screen,
#games-screen.screen.active,
#free-screen.screen.active {
  width: 100% !important;
  max-width: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}
#games-screen .cards-stack.redesign-games-stack,
#free-screen .cards-stack.redesign-free-stack {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
}
#games-screen .game-select-grid.redesign-games-grid,
#games-screen .game-pick-card.game-pick-visual,
#free-screen .reward-card,
#free-screen .panel-card.glass-soft.redesign-promo-card,
#free-screen .promo-row,
#free-screen .promo-input {
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
}
#games-screen .game-select-grid.redesign-games-grid,
#free-screen .reward-card,
#free-screen .panel-card.glass-soft.redesign-promo-card {
  justify-self: stretch !important;
}
@media (max-width: 520px) {
  #free-screen .promo-row {
    grid-template-columns: 1fr !important;
  }
}

/* final polish patch */
#free-screen,
#free-screen.screen.active {
  overflow: hidden !important;
}
#free-screen .cards-stack.redesign-free-stack {
  height: 100%;
  justify-content: flex-start;
  gap: 14px !important;
  padding-top: 6px;
}
#free-screen .redesign-screen-head {
  display: none !important;
}
#free-screen .reward-card {
  padding: 18px !important;
}
#free-screen .panel-badge.gold {
  margin-bottom: 12px;
}
#free-screen .section-subtext {
  margin-top: 2px !important;
  font-size: 12px !important;
}
#free-screen .reward-claim-btn {
  min-height: 62px !important;
  margin-top: 14px !important;
}
#free-screen .reward-timer {
  margin-top: 10px !important;
}
#free-screen .redesign-promo-card {
  padding: 16px !important;
}
#free-screen .redesign-promo-card .panel-head {
  margin-bottom: 10px !important;
}
#free-screen .promo-row {
  gap: 12px !important;
}
#free-screen .promo-input {
  min-height: 58px !important;
}

@media (max-width: 480px) {
  #free-screen .reward-card {
    padding: 16px !important;
  }
  #free-screen .reward-claim-btn,
  #free-screen .promo-input {
    min-height: 56px !important;
  }
}


/* ===== final ios premium patch ===== */
:root{
  --ios-shell-side:10px;
  --ios-panel-radius:26px;
  --ios-card-radius:24px;
}
html,body{
  background:
    radial-gradient(circle at 50% -10%, rgba(24,86,166,.30), transparent 34%),
    linear-gradient(180deg, #071425 0%, #041022 52%, #030913 100%) fixed !important;
}
#games-screen.screen.active{
  overflow-y:auto !important;
  overflow-x:hidden !important;
  padding:4px 0 calc(var(--nav-h) + var(--safe-bottom) + 12px) !important;
}
#free-screen.screen.active{
  overflow:hidden !important;
  padding:4px 0 calc(var(--nav-h) + var(--safe-bottom) + 10px) !important;
}
#games-screen .cards-stack.redesign-games-stack,
#free-screen .cards-stack.redesign-free-stack{
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
}
#games-screen .cards-stack.redesign-games-stack{
  display:flex !important;
  flex-direction:column !important;
  align-items:stretch !important;
  gap:14px !important;
}
#free-screen .cards-stack.redesign-free-stack{
  display:flex !important;
  flex-direction:column !important;
  align-items:stretch !important;
  justify-content:flex-start !important;
  gap:12px !important;
  height:100% !important;
}
#games-screen .game-select-grid.redesign-games-grid{
  display:grid !important;
  grid-template-columns:1fr !important;
  gap:14px !important;
  width:100% !important;
}
#games-screen .game-pick-card.game-pick-visual{
  width:100% !important;
  min-height:124px !important;
  border-radius:26px !important;
  border:1px solid rgba(255,255,255,.06) !important;
  box-shadow:0 14px 34px rgba(0,0,0,.24) !important;
}
#games-screen .game-pick-art{
  background-position:center center !important;
}
#games-screen .game-pick-overlay{
  background:linear-gradient(180deg, rgba(0,0,0,.06) 0%, rgba(0,0,0,.18) 36%, rgba(0,0,0,.64) 100%) !important;
}
#games-screen .game-pick-card .game-pick-content{
  padding:18px 20px !important;
  justify-content:flex-end !important;
}
#games-screen .game-pick-card .game-pick-title{
  font-size:19px !important;
  font-weight:800 !important;
  color:#fff !important;
  text-shadow:0 1px 8px rgba(0,0,0,.32) !important;
}
#games-screen .game-pick-card .game-pick-text{display:none !important;}
#games-screen .game-pick-card.game-pick-visual[data-solo-game="plinko"] .game-pick-title{
  color:#fff !important;
}
#free-screen .reward-card,
#free-screen .panel-card.glass-soft.redesign-promo-card{
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  align-self:stretch !important;
  border-radius:26px !important;
  box-sizing:border-box !important;
}
#free-screen .reward-card{
  flex:1 1 auto !important;
  min-height:0 !important;
  padding:18px !important;
  gap:12px !important;
  background:
    radial-gradient(circle at 50% 10%, rgba(255,216,97,.14), transparent 40%),
    linear-gradient(180deg, rgba(8,28,58,.92), rgba(4,17,35,.98)) !important;
  border:1px solid rgba(255,255,255,.06) !important;
}
#free-screen .reward-glow{
  inset:auto -16% 56% -16% !important;
  height:140px !important;
  background:radial-gradient(circle, rgba(255,219,113,.22), transparent 66%) !important;
}
#free-screen .panel-badge.gold{
  align-self:flex-start !important;
  padding:7px 18px !important;
  margin:0 0 6px 0 !important;
  color:#f3f2ea !important;
  font-size:13px !important;
  font-weight:800 !important;
  background:linear-gradient(90deg, rgba(111,108,53,.76), rgba(140,128,60,.38)) !important;
  border:1px solid rgba(214,188,104,.16) !important;
}
#free-screen .section-subtext{
  display:block !important;
  font-size:12px !important;
  color:rgba(255,255,255,.74) !important;
  margin:0 !important;
}
#free-screen .reward-claim-btn{
  width:100% !important;
  min-height:64px !important;
  margin-top:auto !important;
  border-radius:18px !important;
}
#free-screen .reward-timer{
  margin-top:2px !important;
  font-size:12px !important;
}
#free-screen .redesign-promo-card{
  flex:0 0 auto !important;
  padding:16px !important;
  background:linear-gradient(180deg, rgba(7,27,58,.92), rgba(4,17,35,.98)) !important;
  border:1px solid rgba(255,255,255,.06) !important;
}
#free-screen .redesign-promo-card .panel-head{
  margin-bottom:10px !important;
}
#free-screen .redesign-promo-card .panel-title{
  font-size:28px !important;
  line-height:1 !important;
  letter-spacing:-.03em !important;
}
#free-screen .redesign-promo-card .section-subtext{
  font-size:12px !important;
}
#free-screen .promo-row{
  display:grid !important;
  grid-template-columns:1fr !important;
  gap:6px !important;
  width:100% !important;
}
#free-screen .promo-input{
  width:100% !important;
  min-height:58px !important;
  border-radius:18px !important;
}
@media (max-width:480px){
  #free-screen .reward-card{padding:16px !important;}
  #free-screen .redesign-promo-card{padding:14px !important;}
}

/* ===== premium ios motion patch ===== */
:root{
  --premium-ease:cubic-bezier(.22,.61,.36,1);
  --premium-fast:180ms;
  --premium-med:320ms;
  --premium-slow:560ms;
  --premium-gold-1:rgba(255,222,154,.16);
  --premium-gold-2:rgba(206,161,79,.08);
  --premium-line:rgba(255,255,255,.08);
  --premium-shadow:0 18px 50px rgba(0,0,0,.30);
  --premium-glow:0 10px 24px rgba(255,210,120,.08);
  --premium-inset:inset 0 1px 0 rgba(255,255,255,.10), inset 0 -1px 0 rgba(255,255,255,.02);
}

#games-screen .cards-stack,
#free-screen .cards-stack{
  gap:14px !important;
}

#games-screen .redesign-games-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  gap:14px !important;
  width:100% !important;
}

#games-screen .game-pick-card.game-pick-visual{
  width:100% !important;
  min-height:168px !important;
  border-radius:30px !important;
  justify-self:stretch !important;
  background:linear-gradient(180deg,rgba(16,22,35,.72),rgba(8,11,19,.88)) !important;
  border:1px solid rgba(255,255,255,.08) !important;
  box-shadow:0 18px 40px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.08), 0 0 0 1px rgba(255,255,255,.02) !important;
  transition:transform var(--premium-fast) var(--premium-ease), box-shadow var(--premium-med) var(--premium-ease), border-color var(--premium-fast) var(--premium-ease), filter var(--premium-fast) var(--premium-ease);
  isolation:isolate;
}

#games-screen .game-pick-card.game-pick-visual::before,
#games-screen .game-pick-card.game-pick-visual::after,
.reward-card::before,
.redesign-promo-card::before,
.redesign-bottom-nav::before,
.floating-balance-card::before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
}

#games-screen .game-pick-card.game-pick-visual::before,
.reward-card::before,
.redesign-promo-card::before,
.floating-balance-card::before{
  border-radius:inherit;
  background:linear-gradient(180deg,rgba(255,255,255,.10),rgba(255,255,255,0) 26%, rgba(255,255,255,.04) 100%);
  opacity:.9;
}

#games-screen .game-pick-card.game-pick-visual::after,
.reward-card::after,
.redesign-promo-card::after{
  content:"";
  position:absolute;
  inset:auto -20% -42% auto;
  width:58%;
  height:62%;
  border-radius:50%;
  background:radial-gradient(circle, rgba(255,220,140,.18) 0%, rgba(255,220,140,0) 72%);
  filter:blur(16px);
  opacity:.55;
  pointer-events:none;
}

#games-screen .game-pick-card .game-pick-art{
  transform:scale(1.025);
  transition:transform var(--premium-slow) var(--premium-ease), filter var(--premium-med) var(--premium-ease);
  filter:saturate(1.02) contrast(1.02);
}

#games-screen .game-pick-card .game-pick-overlay{
  background:linear-gradient(180deg,rgba(7,10,17,.10) 0%, rgba(7,10,17,.20) 34%, rgba(5,8,14,.76) 100%) !important;
  transition:background var(--premium-med) var(--premium-ease), opacity var(--premium-med) var(--premium-ease);
}

#games-screen .game-pick-card .game-pick-content{
  padding:18px !important;
  gap:4px !important;
}

#games-screen .game-pick-card .game-pick-title{
  color:#ffffff !important;
  text-shadow:0 1px 0 rgba(0,0,0,.28), 0 10px 24px rgba(0,0,0,.22);
}

#games-screen .game-pick-card .game-pick-text{
  color:rgba(244,247,255,.84) !important;
}

#games-screen .game-pick-card.active,
#games-screen .game-pick-card.game-pick-visual:focus-visible{
  border-color:rgba(255,232,188,.18) !important;
  box-shadow:0 22px 46px rgba(0,0,0,.34), 0 10px 24px rgba(255,210,120,.10), inset 0 1px 0 rgba(255,255,255,.10) !important;
}

#games-screen .game-pick-card.active .game-pick-overlay{
  background:linear-gradient(180deg,rgba(14,12,8,.06) 0%, rgba(18,14,8,.16) 34%, rgba(10,8,6,.68) 100%) !important;
}

#free-screen.screen.active{
  overflow:hidden !important;
}

#free-screen .cards-stack{
  min-height:calc(100dvh - var(--safe-top) - var(--nav-h) - 104px);
  justify-content:flex-start;
}

#free-screen .reward-card,
#free-screen .redesign-promo-card{
  position:relative;
  width:100% !important;
  max-width:none !important;
  border-radius:30px !important;
  border:1px solid rgba(255,255,255,.08) !important;
  box-shadow:var(--premium-shadow), var(--premium-glow), var(--premium-inset) !important;
  backdrop-filter:blur(18px) saturate(1.08);
  -webkit-backdrop-filter:blur(18px) saturate(1.08);
  overflow:hidden;
  transition:transform var(--premium-fast) var(--premium-ease), box-shadow var(--premium-med) var(--premium-ease), border-color var(--premium-fast) var(--premium-ease);
}

#free-screen .reward-card{
  padding:18px 18px 16px !important;
  background:linear-gradient(180deg,rgba(42,31,12,.86),rgba(19,17,12,.92)) !important;
}

#free-screen .redesign-promo-card{
  padding:16px !important;
  background:linear-gradient(180deg,rgba(10,23,42,.90),rgba(7,18,35,.95)) !important;
}

#free-screen .panel-badge.gold,
#free-screen .panel-head{
  display:none !important;
}

#free-screen .promo-row{
  display:grid !important;
  grid-template-columns:1fr auto !important;
  gap:6px !important;
  width:100% !important;
}

#free-screen .promo-input,
#free-screen .dark-btn,
#free-screen .primary-btn,
.mini-action-btn,
.bottom-nav .tab,
button,
.chip-btn,
.ton-btn{
  transition:transform var(--premium-fast) var(--premium-ease), box-shadow var(--premium-fast) var(--premium-ease), filter var(--premium-fast) var(--premium-ease), background var(--premium-med) var(--premium-ease), border-color var(--premium-fast) var(--premium-ease), opacity var(--premium-fast) var(--premium-ease);
}

#free-screen .promo-input,
#free-screen .dark-btn,
#free-screen .primary-btn,
.floating-balance-main,
.mini-action-btn,
.bottom-nav .tab,
.redesign-bottom-nav,
.floating-balance-card,
.reward-card,
.redesign-promo-card,
.game-pick-card.game-pick-visual,
.glass-soft{
  backdrop-filter:blur(18px) saturate(1.06);
  -webkit-backdrop-filter:blur(18px) saturate(1.06);
}

.primary-btn,
.dark-btn,
.ton-btn,
.chip-btn{
  position:relative;
  overflow:hidden;
}

.primary-btn::after,
.dark-btn::after,
.ton-btn::after,
.chip-btn::after,
.mini-action-btn::after,
.bottom-nav .tab::after{
  content:"";
}

.primary-btn::before,
.dark-btn::before,
.ton-btn::before,
.chip-btn::before,
.mini-action-btn::before,
.bottom-nav .tab::before{
  content:"";
  position:absolute;
  inset:0;
  border-radius:inherit;
  background:linear-gradient(110deg, transparent 0%, rgba(255,255,255,.12) 45%, transparent 70%);
  transform:translateX(-130%);
  opacity:0;
  pointer-events:none;
}

@keyframes premiumShimmer{
  0%{transform:translateX(-130%);opacity:0}
  18%{opacity:.55}
  100%{transform:translateX(130%);opacity:0}
}

@media (hover:hover){
  #games-screen .game-pick-card.game-pick-visual:hover,
  #free-screen .reward-card:hover,
  #free-screen .redesign-promo-card:hover,
  .bottom-nav .tab:hover,
  .mini-action-btn:hover,
  .primary-btn:hover,
  .dark-btn:hover,
  .ton-btn:hover,
  .chip-btn:hover{
    transform:translateY(-2px);
  }

  #games-screen .game-pick-card.game-pick-visual:hover .game-pick-art{
    transform:scale(1.045);
    filter:saturate(1.06) contrast(1.04);
  }

  #games-screen .game-pick-card.game-pick-visual:hover::before,
  #free-screen .reward-card:hover::before,
  #free-screen .redesign-promo-card:hover::before,
  .primary-btn:hover::before,
  .dark-btn:hover::before,
  .ton-btn:hover::before,
  .chip-btn:hover::before,
  .mini-action-btn:hover::before,
  .bottom-nav .tab:hover::before{
    animation:premiumShimmer 900ms var(--premium-ease) 1;
  }
}

#games-screen .game-pick-card.game-pick-visual:active,
#free-screen .reward-card:active,
#free-screen .redesign-promo-card:active,
.primary-btn:active,
.dark-btn:active,
.ton-btn:active,
.chip-btn:active,
.mini-action-btn:active,
.bottom-nav .tab:active{
  transform:scale(.985);
}

#games-screen .redesign-screen-head,
#free-screen .redesign-screen-head,
#games-screen .screen-kicker,
#games-screen .screen-title,
#games-screen .screen-subtitle{
  display:none !important;
}

@media (max-width:640px){
  #games-screen .redesign-games-grid,
  #free-screen .cards-stack{
    gap:12px !important;
  }

  #games-screen .game-pick-card.game-pick-visual{
    min-height:150px !important;
  }

  #free-screen .cards-stack{
    min-height:calc(100dvh - var(--safe-top) - var(--nav-h) - 96px);
  }

  #free-screen .promo-row{
    grid-template-columns:1fr auto !important;
  }
}


.redesign-quick-links-large{display:grid;gap:14px}
.profile-link-row-large{min-height:86px;padding:0 22px;font-size:20px;font-weight:800;border-radius:24px}
.profile-link-row-large .masked-icon{width:24px;height:24px}
.profile-action-modal{position:fixed;inset:0;z-index:120;display:grid;place-items:end center;padding:18px;background:rgba(0,0,0,.01)}
.profile-action-modal.hidden{display:none!important}
.profile-action-backdrop{position:absolute;inset:0;background:rgba(2,9,20,.72);backdrop-filter:blur(8px)}
.profile-action-card{position:relative;width:min(100%,640px);max-height:min(86vh,880px);overflow:auto;border-radius:30px;padding:18px;background:linear-gradient(180deg,rgba(9,24,54,.98),rgba(5,17,38,.98));border:1px solid rgba(255,255,255,.08);box-shadow:0 30px 90px rgba(0,0,0,.45)}
.profile-action-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:14px}
.profile-action-close{width:44px;height:44px;border:none;border-radius:13px;background:rgba(255,255,255,.08);color:#fff;font-size:20px;font-weight:800}
.profile-action-body{display:grid;gap:14px}
.profile-action-modal .panel-card{margin:0}
.profile-action-modal .finance-switcher,.profile-action-modal #finance-tab-withdraw,.profile-action-modal .withdraw-focus-card{display:none!important}
.profile-action-modal[data-mode="deposit"] .redesign-convert-card,
.profile-action-modal[data-mode="deposit"] .redesign-wallet-functions,
.profile-action-modal[data-mode="deposit"] .redesign-referral-card{display:none!important}
.profile-action-modal[data-mode="withdraw"] #finance-tab-deposit,
.profile-action-modal[data-mode="withdraw"] .redesign-referral-card{display:none!important}
.profile-action-modal .section-subtext,
.profile-action-modal .eyebrow{display:none!important}
.profile-action-modal[data-mode="withdraw"] .profile-action-card{
  width:min(100%,496px) !important;
  max-height:min(88dvh,720px) !important;
  border-radius:22px !important;
  padding:10px !important;
}
.profile-action-modal[data-mode="withdraw"] .profile-action-head{
  margin-bottom:6px !important;
}
.profile-action-modal[data-mode="withdraw"] .profile-action-body,
.profile-action-modal[data-mode="withdraw"] .wallet-layout,
.profile-action-modal[data-mode="withdraw"] .redesign-wallet-functions,
.profile-action-modal[data-mode="withdraw"] .wallet-function-grid,
.profile-action-modal[data-mode="withdraw"] .field-row,
.profile-action-modal[data-mode="withdraw"] .withdraw-summary-grid{
  gap:4px !important;
}
.profile-action-modal[data-mode="withdraw"] .redesign-convert-card,
.profile-action-modal[data-mode="withdraw"] .redesign-wallet-functions{
  padding:8px !important;
  border-radius:16px !important;
}
.profile-action-modal[data-mode="withdraw"] .compact-panel-head,
.profile-action-modal[data-mode="withdraw"] .panel-head{
  margin-bottom:4px !important;
}
.profile-action-modal[data-mode="withdraw"] .panel-title{
  font-size:15px !important;
  line-height:1.15 !important;
}
.profile-action-modal[data-mode="withdraw"] .wallet-function-grid{
  display:grid !important;
  grid-template-columns:auto auto !important;
  justify-content:start !important;
  align-items:center !important;
  margin-bottom:4px !important;
}
.profile-action-modal[data-mode="withdraw"] .field label{
  margin-bottom:2px !important;
  font-size:10px !important;
}
.profile-action-modal[data-mode="withdraw"] .field input,
.profile-action-modal[data-mode="withdraw"] .profile-info-chip{
  min-height:34px !important;
  height:34px !important;
  padding:0 10px !important;
  border-radius:12px !important;
  font-size:12px !important;
}
.profile-action-modal[data-mode="withdraw"] #convertStarsBtn,
.profile-action-modal[data-mode="withdraw"] #unbindTonWalletBtn,
.profile-action-modal[data-mode="withdraw"] .danger-btn{
  min-height:36px !important;
  height:36px !important;
  padding:0 10px !important;
  border-radius:12px !important;
  font-size:12px !important;
}
.profile-action-modal[data-mode="withdraw"] #withdrawAmount{
  min-height:34px !important;
  height:34px !important;
}
.profile-action-modal[data-mode="withdraw"] .summary-chip{
  padding:5px 8px !important;
  font-size:10px !important;
  border-radius:12px !important;
}
.profile-action-modal[data-mode="withdraw"] #walletConnectNote,
.profile-action-modal[data-mode="withdraw"] #withdrawTonHint{
  display:none !important;
}
#wallet-screen.profile-history-only{margin-top:18px}
#wallet-screen.profile-history-only .wallet-layout{display:block}
#wallet-screen.profile-history-only .finance-switcher,
#wallet-screen.profile-history-only #finance-tab-deposit,
#wallet-screen.profile-history-only .redesign-convert-card,
#wallet-screen.profile-history-only .redesign-wallet-functions,
#wallet-screen.profile-history-only #finance-tab-withdraw,
#wallet-screen.profile-history-only .redesign-referral-card{display:none!important}
#wallet-screen.profile-history-only .wallet-layout > .panel-card:last-child{margin-top:0}
@media (max-width:640px){.profile-link-row-large{min-height:78px;font-size:18px;padding:0 18px}.profile-action-card{width:min(100%,100vw);max-height:88vh;border-radius:26px 26px 0 0;padding:16px}}


