/* V41 — Padronização visual final dos menus e homes dos jogos.
   Regras: desktop/notebook com o padrão da Batalha Naval; mobile/tablet mantêm a camada responsiva existente.
   Não altera regras, salas, Socket.IO, tabuleiros ou mesas. */
:root{
  --std-home-w:1080px;
  --std-hero-w:1000px;
  --std-hero-ratio:1672/941;
  --std-menu-h:76px;
  --std-radius:22px;
  --std-btn-h:42px;
  --std-btn-r:15px;
  --std-btn-font:.9rem;
}
body.game-batalha{--game-accent:#30d7ff;--game-accent2:#ff4d6d;--game-line:rgba(48,215,255,.42);--game-panel:rgba(4,16,30,.90);}
body.game-truco{--game-accent:#f5bd27;--game-accent2:#ffd66b;--game-line:rgba(245,189,39,.42);--game-panel:rgba(8,7,5,.90);}
body.game-xadrez{--game-accent:#e11d24;--game-accent2:#b8141b;--game-line:rgba(225,29,36,.48);--game-panel:rgba(10,4,4,.91);}
body.game-adedonha{--game-accent:#a855f7;--game-accent2:#7c2cff;--game-line:rgba(168,85,247,.45);--game-panel:rgba(12,4,20,.91);}
body.game-cidade-dorme{--game-accent:#43ff43;--game-accent2:#12b84d;--game-line:rgba(67,255,67,.38);--game-panel:rgba(4,13,6,.91);}

@media (min-width:901px){
  body.game-truco:not(.acg-mobile-game),
  body.game-xadrez:not(.acg-mobile-game),
  body.game-adedonha:not(.acg-mobile-game),
  body.game-cidade-dorme:not(.acg-mobile-game){
    font-size:16px!important;
  }

  /* Menu superior padronizado */
  body:not(.acg-mobile-game) .home-main-menu,
  body:not(.acg-mobile-game) .app-shell-header,
  body.game-xadrez:not(.acg-mobile-game) .header,
  body.game-adedonha:not(.acg-mobile-game) .topbar,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-top{
    width:min(var(--std-home-w),calc(100vw - 36px))!important;
    max-width:var(--std-home-w)!important;
    min-height:var(--std-menu-h)!important;
    margin:14px auto 18px!important;
    padding:12px 16px!important;
    border-radius:var(--std-radius)!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:16px!important;
    border:1px solid var(--game-line)!important;
    background:var(--game-panel)!important;
    box-shadow:0 18px 60px rgba(0,0,0,.42), inset 0 0 0 1px rgba(255,255,255,.03)!important;
    position:relative!important;
    top:auto!important;
    backdrop-filter:blur(10px)!important;
  }
  body:not(.acg-mobile-game) .menu-brand,
  body:not(.acg-mobile-game) .app-shell-header .brand,
  body.game-xadrez:not(.acg-mobile-game) .header .brand,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand{
    min-width:250px!important;
    width:250px!important;
    flex:0 0 250px!important;
    display:flex!important;
    align-items:center!important;
    gap:13px!important;
    text-decoration:none!important;
  }
  body:not(.acg-mobile-game) .menu-brand img,
  body:not(.acg-mobile-game) .app-shell-header .brand img,
  body.game-xadrez:not(.acg-mobile-game) .header .brand img,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand img{
    width:118px!important;
    height:52px!important;
    max-width:118px!important;
    max-height:52px!important;
    object-fit:contain!important;
    flex:0 0 118px!important;
  }
  body:not(.acg-mobile-game) .menu-brand strong,
  body:not(.acg-mobile-game) .app-shell-header .brand-title,
  body.game-xadrez:not(.acg-mobile-game) .header .brand h1,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand h1,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand h1{
    font-size:clamp(1.02rem,1.35vw,1.28rem)!important;
    line-height:1!important;
    margin:0!important;
    letter-spacing:.01em!important;
    color:#fff!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .menu-brand span,
  body:not(.acg-mobile-game) .app-shell-header .brand-sub,
  body.game-xadrez:not(.acg-mobile-game) .header .brand small,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand p{
    display:block!important;
    font-size:.78rem!important;
    line-height:1.15!important;
    margin:4px 0 0!important;
    letter-spacing:.22em!important;
    color:#d5c9b1!important;
    text-transform:uppercase!important;
    font-weight:700!important;
  }

  /* Área dos botões do menu. Mesma tipografia, altura, raio e espaçamento. */
  body:not(.acg-mobile-game) .menu-actions,
  body:not(.acg-mobile-game) .app-shell-header .nav,
  body.game-xadrez:not(.acg-mobile-game) .header .nav,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav{
    flex:1 1 auto!important;
    display:flex!important;
    justify-content:flex-end!important;
    align-items:center!important;
    gap:10px!important;
    flex-wrap:wrap!important;
  }
  body:not(.acg-mobile-game) .menu-btn,
  body:not(.acg-mobile-game) .delivery-btn,
  body:not(.acg-mobile-game) .app-shell-header .nav button,
  body:not(.acg-mobile-game) .app-shell-header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav button,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions a,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav a,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav button{
    min-height:var(--std-btn-h)!important;
    height:var(--std-btn-h)!important;
    border-radius:var(--std-btn-r)!important;
    padding:0 15px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    font-size:var(--std-btn-font)!important;
    font-weight:1000!important;
    line-height:1!important;
    white-space:nowrap!important;
    text-decoration:none!important;
    box-shadow:none!important;
    transform:none!important;
    letter-spacing:.01em!important;
    border:1px solid var(--game-line)!important;
    background:#242426!important;
    color:#fff!important;
  }
  body:not(.acg-mobile-game) .menu-btn-red,
  body:not(.acg-mobile-game) .delivery-btn.ifood,
  body.game-xadrez:not(.acg-mobile-game) .nav .delivery.ifood,
  body.game-adedonha:not(.acg-mobile-game) .topbar .ifood,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .ifood{
    background:linear-gradient(135deg,#e11d24,#ff343d)!important;
    color:#fff!important;
    border-color:rgba(255,255,255,.14)!important;
  }
  body:not(.acg-mobile-game) .menu-btn-gold,
  body:not(.acg-mobile-game) .delivery-btn.sirrus,
  body.game-xadrez:not(.acg-mobile-game) .nav .delivery.sirrus,
  body.game-adedonha:not(.acg-mobile-game) .topbar .sirrus,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .sirrus{
    background:linear-gradient(135deg,#f5bd27,#ffe07a)!important;
    color:#160e00!important;
    border-color:rgba(245,189,39,.54)!important;
  }
  body.game-xadrez:not(.acg-mobile-game) button:not(.secondary):not(.danger):not(.menu-logout),
  body.game-xadrez:not(.acg-mobile-game) .btn:not(.secondary):not(.ghost):not(.danger),
  body.game-xadrez:not(.acg-mobile-game) .nav .gold{
    background:linear-gradient(135deg,#e11d24,#b8141b)!important;
    color:#fff!important;
  }

  /* Bloco de usuário logado uniforme em todos os jogos. */
  body:not(.acg-mobile-game) .menu-logged{
    min-height:42px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:10px!important;
    border:1px solid var(--game-line)!important;
    border-radius:15px!important;
    background:rgba(255,255,255,.055)!important;
    padding:0 10px 0 14px!important;
    color:#c8d3df!important;
    font-size:.88rem!important;
    line-height:1!important;
  }
  body:not(.acg-mobile-game) .menu-logged strong{color:#86ff9a!important;font-weight:1000!important;}
  body:not(.acg-mobile-game) .menu-logout,
  body:not(.acg-mobile-game) .menu-logged .menu-logout{
    min-height:34px!important;
    height:34px!important;
    padding:0 12px!important;
    border-radius:12px!important;
    background:linear-gradient(135deg,#8b1818,#d11f1f)!important;
    color:#fff!important;
    border:1px solid rgba(255,255,255,.10)!important;
    font-size:.82rem!important;
  }

  /* Homes externas milimetricamente no padrão Batalha Naval. */
  body:not(.acg-mobile-game) .home-modern,
  body.game-truco:not(.acg-mobile-game) .landing-shell,
  body.game-xadrez:not(.acg-mobile-game) .container,
  body.game-adedonha:not(.acg-mobile-game) #app,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-app{
    width:min(var(--std-home-w),calc(100vw - 36px))!important;
    max-width:var(--std-home-w)!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }
  body.game-adedonha:not(.acg-mobile-game) #app,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-app{padding:0 0 54px!important;}

  body:not(.acg-mobile-game) .home-hero,
  body.game-truco:not(.acg-mobile-game) .landing-hero-panel,
  body.game-xadrez:not(.acg-mobile-game) .container>.hero,
  body.game-adedonha:not(.acg-mobile-game) .game-home-hero,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover{
    width:100%!important;
    max-width:var(--std-hero-w)!important;
    margin:18px auto 0!important;
    display:grid!important;
    grid-template-columns:minmax(0,1.65fr) minmax(300px,.78fr)!important;
    gap:0!important;
    align-items:stretch!important;
    border-radius:22px!important;
    overflow:hidden!important;
    border:1px solid var(--game-line)!important;
    background:rgba(5,5,7,.92)!important;
    box-shadow:0 28px 90px rgba(0,0,0,.55),0 0 32px color-mix(in srgb,var(--game-accent) 12%,transparent)!important;
    min-height:0!important;
  }
  body:not(.acg-mobile-game) .hero-cover-frame,
  body.game-truco:not(.acg-mobile-game) .landing-cover,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover,
  body.game-adedonha:not(.acg-mobile-game) .cover-card{
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:var(--std-hero-ratio)!important;
    border:0!important;
    border-radius:0!important;
    background:#020202!important;
  }
  body:not(.acg-mobile-game) .home-hero .game-cover,
  body.game-truco:not(.acg-mobile-game) .landing-cover img,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover img,
  body.game-adedonha:not(.acg-mobile-game) .cover-card img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    aspect-ratio:auto!important;
    object-fit:cover!important;
    object-position:center!important;
    display:block!important;
    border-radius:0!important;
    box-shadow:none!important;
    margin:0!important;
  }
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{aspect-ratio:var(--std-hero-ratio)!important;height:auto!important;}

  body:not(.acg-mobile-game) .hero-copy,
  body.game-truco:not(.acg-mobile-game) .landing-copy,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy,
  body.game-adedonha:not(.acg-mobile-game) .hero-side,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content{
    padding:clamp(22px,2.6vw,34px)!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:center!important;
    align-items:flex-start!important;
    text-align:left!important;
    gap:8px!important;
    background:radial-gradient(circle at 12% 12%,color-mix(in srgb,var(--game-accent) 17%,transparent),transparent 34%),rgba(4,4,5,.78)!important;
    border:0!important;
    border-radius:0!important;
  }
  body:not(.acg-mobile-game) .hero-copy .logo-wrap,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy>img,
  body.game-truco:not(.acg-mobile-game) .landing-logo,
  body.game-adedonha:not(.acg-mobile-game) .hero-side>img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content>img{
    width:64px!important;
    height:48px!important;
    max-width:64px!important;
    max-height:48px!important;
    object-fit:contain!important;
    margin:0 0 8px!important;
  }
  body:not(.acg-mobile-game) .hero-copy .eyebrow,
  body.game-xadrez:not(.acg-mobile-game) .kicker,
  body.game-truco:not(.acg-mobile-game) .landing-kicker,
  body.game-adedonha:not(.acg-mobile-game) .eyebrow{
    max-width:290px!important;
    margin:0 0 4px!important;
    font-size:.68rem!important;
    letter-spacing:.18em!important;
    line-height:1.45!important;
    color:var(--game-accent)!important;
    text-transform:uppercase!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .hero-copy h1,
  body.game-truco:not(.acg-mobile-game) .landing-copy h1,
  body.game-xadrez:not(.acg-mobile-game) .hero h2,
  body.game-adedonha:not(.acg-mobile-game) .hero-side h2,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content h2{
    max-width:340px!important;
    font-size:clamp(1.7rem,2.85vw,2.65rem)!important;
    line-height:1.05!important;
    letter-spacing:.01em!important;
    margin:0!important;
    color:#fff!important;
    text-transform:none!important;
  }
  body:not(.acg-mobile-game) .hero-copy .subtitle,
  body.game-truco:not(.acg-mobile-game) .landing-copy p,
  body.game-xadrez:not(.acg-mobile-game) .hero p,
  body.game-adedonha:not(.acg-mobile-game) .hero-side p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content p{
    max-width:300px!important;
    margin:8px 0 0!important;
    font-size:.98rem!important;
    line-height:1.42!important;
    color:#f2f2f2!important;
  }
  body.game-truco:not(.acg-mobile-game) .landing-quick-actions,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy .actions,
  body.game-adedonha:not(.acg-mobile-game) .hero-side .top-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content .cd-actions{display:none!important;}

  /* Cards de login/entrada externos no mesmo tamanho-base. */
  body:not(.acg-mobile-game) .home-grid,
  body.game-truco:not(.acg-mobile-game) .landing-forms-grid,
  body.game-xadrez:not(.acg-mobile-game) .forms,
  body.game-adedonha:not(.acg-mobile-game) .home-access-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-access-grid{
    width:100%!important;
    max-width:var(--std-hero-w)!important;
    margin:20px auto 0!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:18px!important;
    align-items:stretch!important;
  }
  body:not(.acg-mobile-game) #accessCard,
  body:not(.acg-mobile-game) #guestJoinCard,
  body.game-truco:not(.acg-mobile-game) .landing-card,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card{
    grid-column:auto!important;
    min-height:230px!important;
    padding:20px!important;
    border-radius:24px!important;
    border:1px solid var(--game-line)!important;
    background:linear-gradient(180deg,rgba(18,18,18,.92),rgba(6,6,7,.96))!important;
    box-shadow:0 20px 70px rgba(0,0,0,.35)!important;
  }
  body:not(.acg-mobile-game) .section-title h2,
  body.game-truco:not(.acg-mobile-game) .landing-card-head h2,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card h3,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title h3,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title h3{
    font-size:1.12rem!important;
    margin:0!important;
    line-height:1.15!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .section-title span,
  body.game-truco:not(.acg-mobile-game) .landing-card-head small,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title span,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title span{font-size:.76rem!important;}
  body:not(.acg-mobile-game) input,
  body:not(.acg-mobile-game) select,
  body:not(.acg-mobile-game) textarea{
    min-height:48px!important;
    border-radius:16px!important;
    font-size:.94rem!important;
  }
  body:not(.acg-mobile-game) label{font-size:.78rem!important;letter-spacing:.08em!important;}

  /* Menus internos pós-login com largura/tipografia homogênea. */
  body.game-xadrez:not(.acg-mobile-game) .container>h2,
  body.game-adedonha:not(.acg-mobile-game) .menu-screen h2,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen h2,
  body.game-truco:not(.acg-mobile-game) .screen-title{font-size:1.55rem!important;margin:8px 0 8px!important;}
  body.game-xadrez:not(.acg-mobile-game) .grid-3,
  body.game-adedonha:not(.acg-mobile-game) .quick-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid,
  body.game-truco:not(.acg-mobile-game) .container>.grid-3{
    max-width:1000px!important;
    margin:16px auto 0!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:16px!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .grid-3 .card,
  body.game-adedonha:not(.acg-mobile-game) .action-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-panel,
  body.game-truco:not(.acg-mobile-game) .menu-card{
    min-height:132px!important;
    border-radius:22px!important;
    padding:18px!important;
  }
}

@media (max-width:900px){
  body:not(.acg-desktop-game) .home-main-menu,
  body:not(.acg-desktop-game) .app-shell-header,
  body.game-xadrez .header,
  body.game-adedonha .topbar,
  body.game-cidade-dorme .cd-top{position:relative!important;top:auto!important;}
}

/* V41 — Normalização final visual: todos os jogos usam a mesma régua da Batalha Naval/Cidade Dorme.
   Mantém as cores próprias por jogo, mas fixa medidas de menu, hero, cards, botões, inputs e espaçamentos. */
@media (min-width:901px){
  /* hidden nunca pode virar pílula vazia por causa dos !important do padrão */
  body:not(.acg-mobile-game) [hidden],
  body:not(.acg-mobile-game) .menu-logged[hidden],
  body:not(.acg-mobile-game) #menuLoggedPlayerBox[hidden],
  body:not(.acg-mobile-game) #loggedPlayerBox[hidden],
  body:not(.acg-mobile-game) #loggedJoinCard[hidden],
  body:not(.acg-mobile-game) #createRoomPanel[hidden],
  body:not(.acg-mobile-game) #publicRoomsCard[hidden],
  body:not(.acg-mobile-game) #publicRoomsLockedCard[hidden]{display:none!important;}

  /* régua única de largura e centralização */
  :root{
    --std-page-w:1080px;
    --std-cover-w:1000px;
    --std-menu-h2:94px;
    --std-menu-gap:10px;
    --std-pill-h:42px;
    --std-pill-radius:15px;
    --std-pill-pad-x:16px;
    --std-card-pad:20px;
    --std-card-min-h:226px;
    --std-field-h:50px;
  }
  body:not(.acg-mobile-game) .home-modern,
  body.game-truco:not(.acg-mobile-game) .landing-shell,
  body.game-xadrez:not(.acg-mobile-game) .container,
  body.game-adedonha:not(.acg-mobile-game) #app,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-app{
    width:min(var(--std-page-w),calc(100vw - 42px))!important;
    max-width:var(--std-page-w)!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }

  /* menu/topbar: mesma caixa, mesma altura, mesma lógica de quebra */
  body:not(.acg-mobile-game) .home-main-menu,
  body:not(.acg-mobile-game) .app-shell-header,
  body.game-xadrez:not(.acg-mobile-game) .header,
  body.game-adedonha:not(.acg-mobile-game) .topbar,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-top{
    width:min(var(--std-page-w),calc(100vw - 42px))!important;
    max-width:var(--std-page-w)!important;
    min-height:var(--std-menu-h2)!important;
    margin:18px auto 20px!important;
    padding:14px 18px!important;
    border-radius:22px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:18px!important;
    overflow:visible!important;
  }
  body:not(.acg-mobile-game) .menu-brand,
  body:not(.acg-mobile-game) .app-shell-header .brand,
  body.game-xadrez:not(.acg-mobile-game) .header .brand,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand{
    min-width:252px!important;
    width:252px!important;
    flex:0 0 252px!important;
    gap:12px!important;
    cursor:pointer;
  }
  body:not(.acg-mobile-game) .menu-brand img,
  body:not(.acg-mobile-game) .app-shell-header .brand img,
  body.game-xadrez:not(.acg-mobile-game) .header .brand img,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand img{
    width:116px!important;
    height:56px!important;
    max-width:116px!important;
    max-height:56px!important;
    object-fit:contain!important;
    flex:0 0 116px!important;
  }
  body:not(.acg-mobile-game) .menu-brand strong,
  body:not(.acg-mobile-game) .app-shell-header .brand-title,
  body.game-xadrez:not(.acg-mobile-game) .header .brand h1,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand h1,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand h1{
    font-size:1.22rem!important;
    line-height:.98!important;
    letter-spacing:0!important;
    max-width:132px!important;
    word-break:normal!important;
  }
  body:not(.acg-mobile-game) .menu-brand span,
  body:not(.acg-mobile-game) .app-shell-header .brand-sub,
  body.game-xadrez:not(.acg-mobile-game) .header .brand small,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand p{
    font-size:.76rem!important;
    line-height:1.15!important;
    letter-spacing:.22em!important;
    color:#ddd2bd!important;
  }

  body:not(.acg-mobile-game) .menu-actions,
  body:not(.acg-mobile-game) .app-shell-header .nav,
  body.game-xadrez:not(.acg-mobile-game) .header .nav,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav{
    flex:1 1 auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:var(--std-menu-gap)!important;
    flex-wrap:wrap!important;
    align-content:center!important;
    min-width:0!important;
  }
  body:not(.acg-mobile-game) .delivery-links{display:contents!important;}

  /* todos os botões do menu exatamente com a mesma régua */
  body:not(.acg-mobile-game) .menu-btn,
  body:not(.acg-mobile-game) .delivery-btn,
  body:not(.acg-mobile-game) .app-shell-header .nav a,
  body:not(.acg-mobile-game) .app-shell-header .nav button,
  body.game-xadrez:not(.acg-mobile-game) .header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav button,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions a,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav a,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav button{
    box-sizing:border-box!important;
    height:var(--std-pill-h)!important;
    min-height:var(--std-pill-h)!important;
    max-height:var(--std-pill-h)!important;
    padding:0 var(--std-pill-pad-x)!important;
    border-radius:var(--std-pill-radius)!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    font-size:.90rem!important;
    font-weight:1000!important;
    line-height:1!important;
    white-space:nowrap!important;
    text-transform:none!important;
    letter-spacing:.01em!important;
    text-decoration:none!important;
    min-width:auto!important;
    width:auto!important;
    margin:0!important;
    transform:none!important;
  }
  body:not(.acg-mobile-game) .menu-btn:not(.menu-btn-red):not(.menu-btn-gold),
  body:not(.acg-mobile-game) .delivery-btn.game-link,
  body:not(.acg-mobile-game) .app-shell-header .nav a:not(.ifood):not(.sirrus),
  body:not(.acg-mobile-game) .app-shell-header .nav button:not(.menu-logout),
  body.game-xadrez:not(.acg-mobile-game) .header .nav a:not(.ifood):not(.sirrus),
  body.game-xadrez:not(.acg-mobile-game) .header .nav button:not(.menu-logout),
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions a:not(.ifood):not(.sirrus),
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions button:not(.menu-logout),
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav a:not(.ifood):not(.sirrus),
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav button:not(.menu-logout){
    background:#242426!important;
    color:#fff!important;
    border:1px solid var(--game-line)!important;
    box-shadow:inset 0 0 0 1px rgba(255,255,255,.03)!important;
  }
  body:not(.acg-mobile-game) .menu-btn-red,
  body:not(.acg-mobile-game) .delivery-btn.ifood,
  body:not(.acg-mobile-game) .app-shell-header .nav .ifood,
  body.game-xadrez:not(.acg-mobile-game) .header .nav .ifood,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions .ifood,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .ifood{
    background:#ef2b2f!important;
    color:#fff!important;
    border:1px solid rgba(255,255,255,.14)!important;
    box-shadow:0 10px 24px rgba(239,43,47,.16)!important;
  }
  body:not(.acg-mobile-game) .menu-btn-gold,
  body:not(.acg-mobile-game) .delivery-btn.sirrus,
  body:not(.acg-mobile-game) .app-shell-header .nav .sirrus,
  body.game-xadrez:not(.acg-mobile-game) .header .nav .sirrus,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions .sirrus,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .sirrus{
    background:#f6c23a!important;
    color:#130d00!important;
    border:1px solid rgba(255,234,146,.42)!important;
    box-shadow:0 10px 24px rgba(246,194,58,.14)!important;
  }

  /* hero/modal inicial: o Cidade Dorme virou a régua. */
  body:not(.acg-mobile-game) .home-hero,
  body.game-truco:not(.acg-mobile-game) .landing-hero-panel,
  body.game-xadrez:not(.acg-mobile-game) .container>.hero,
  body.game-adedonha:not(.acg-mobile-game) .game-home-hero,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover{
    width:100%!important;
    max-width:1000px!important;
    min-height:0!important;
    height:auto!important;
    margin:18px auto 0!important;
    display:grid!important;
    grid-template-columns:minmax(0,1.72fr) minmax(300px,.72fr)!important;
    border-radius:22px!important;
    overflow:hidden!important;
    gap:0!important;
  }
  body:not(.acg-mobile-game) .hero-cover-frame,
  body.game-truco:not(.acg-mobile-game) .landing-cover,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover,
  body.game-adedonha:not(.acg-mobile-game) .cover-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{
    aspect-ratio:1672/941!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    border:0!important;
  }
  body:not(.acg-mobile-game) .home-hero .game-cover,
  body.game-truco:not(.acg-mobile-game) .landing-cover img,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover img,
  body.game-adedonha:not(.acg-mobile-game) .cover-card img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{
    width:100%!important;
    height:100%!important;
    object-fit:cover!important;
    object-position:center!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .hero-cover img{object-position:center center!important;}
  body.game-adedonha:not(.acg-mobile-game) .cover-card img{object-position:center center!important;}

  body:not(.acg-mobile-game) .hero-copy,
  body.game-truco:not(.acg-mobile-game) .landing-copy,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy,
  body.game-adedonha:not(.acg-mobile-game) .hero-side,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content{
    padding:32px 34px!important;
    min-width:0!important;
    justify-content:center!important;
    gap:8px!important;
  }
  body:not(.acg-mobile-game) .hero-copy h1,
  body.game-truco:not(.acg-mobile-game) .landing-copy h1,
  body.game-xadrez:not(.acg-mobile-game) .hero h2,
  body.game-adedonha:not(.acg-mobile-game) .hero-side h2,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content h2{
    font-size:2.55rem!important;
    line-height:1.04!important;
    max-width:320px!important;
    margin:0!important;
  }
  body:not(.acg-mobile-game) .hero-copy .subtitle,
  body.game-truco:not(.acg-mobile-game) .landing-copy p,
  body.game-xadrez:not(.acg-mobile-game) .hero p,
  body.game-adedonha:not(.acg-mobile-game) .hero-side p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content p{
    font-size:1rem!important;
    line-height:1.42!important;
    max-width:300px!important;
    margin:10px 0 0!important;
  }

  /* cards inferiores: mesma largura, altura, padding e espaçamento */
  body:not(.acg-mobile-game) .home-grid,
  body.game-truco:not(.acg-mobile-game) .landing-forms-grid,
  body.game-xadrez:not(.acg-mobile-game) .forms,
  body.game-adedonha:not(.acg-mobile-game) .home-access-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-access-grid{
    width:100%!important;
    max-width:1000px!important;
    margin:20px auto 0!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:18px!important;
    align-items:stretch!important;
  }
  body:not(.acg-mobile-game) #accessCard,
  body:not(.acg-mobile-game) #guestJoinCard,
  body:not(.acg-mobile-game) #loggedJoinCard,
  body.game-truco:not(.acg-mobile-game) .landing-card,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card{
    box-sizing:border-box!important;
    min-height:var(--std-card-min-h)!important;
    height:100%!important;
    padding:var(--std-card-pad)!important;
    border-radius:22px!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    gap:12px!important;
  }
  body:not(.acg-mobile-game) .section-title,
  body.game-truco:not(.acg-mobile-game) .landing-card-head,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title{
    display:flex!important;
    align-items:flex-start!important;
    justify-content:space-between!important;
    gap:12px!important;
    margin:0 0 6px!important;
  }
  body:not(.acg-mobile-game) .section-title h2,
  body.game-truco:not(.acg-mobile-game) .landing-card-head h2,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card h3,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title h3,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title h3{
    font-size:1.14rem!important;
    line-height:1.1!important;
    margin:0!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .section-title span,
  body.game-truco:not(.acg-mobile-game) .landing-card-head small,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title span,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title span{
    font-size:.76rem!important;
    line-height:1.25!important;
    color:#c7c7c7!important;
    white-space:nowrap!important;
  }
  body:not(.acg-mobile-game) .form-grid,
  body.game-truco:not(.acg-mobile-game) .form-row,
  body.game-xadrez:not(.acg-mobile-game) .forms .row,
  body.game-adedonha:not(.acg-mobile-game) .home-form-row,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-form-row{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:12px!important;
    align-items:end!important;
  }
  body:not(.acg-mobile-game) label{display:grid!important;gap:7px!important;margin:0!important;}
  body:not(.acg-mobile-game) input,
  body:not(.acg-mobile-game) select,
  body:not(.acg-mobile-game) textarea{
    height:var(--std-field-h)!important;
    min-height:var(--std-field-h)!important;
    padding:0 14px!important;
    border-radius:15px!important;
    font-size:.94rem!important;
    line-height:1!important;
    box-sizing:border-box!important;
  }
  body:not(.acg-mobile-game) .action-row,
  body:not(.acg-mobile-game) .actions,
  body.game-truco:not(.acg-mobile-game) .landing-actions,
  body.game-adedonha:not(.acg-mobile-game) .home-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:10px!important;
    flex-wrap:wrap!important;
    margin-top:8px!important;
  }
  body:not(.acg-mobile-game) .home-card button,
  body:not(.acg-mobile-game) .landing-card button,
  body:not(.acg-mobile-game) .forms>.card button,
  body:not(.acg-mobile-game) .home-access-card button,
  body:not(.acg-mobile-game) .cd-home-card button,
  body:not(.acg-mobile-game) .link-button,
  body.game-adedonha:not(.acg-mobile-game) .btn,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-btn{
    min-height:46px!important;
    height:46px!important;
    border-radius:15px!important;
    padding:0 18px!important;
    font-size:.93rem!important;
    line-height:1!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .wide-button,
  body:not(.acg-mobile-game) .full,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card button[type="submit"],
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card button[type="submit"]{
    width:auto!important;
    min-width:210px!important;
  }

  /* corrige textos auxiliares que deixavam um card visualmente mais alto que outro */
  body:not(.acg-mobile-game) .mini-muted,
  body.game-truco:not(.acg-mobile-game) .muted,
  body.game-adedonha:not(.acg-mobile-game) .home-muted,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-muted{
    margin:0 0 6px!important;
    line-height:1.38!important;
    font-size:.92rem!important;
  }
}

@media (max-width:900px){
  body:not(.acg-desktop-game) .menu-logged[hidden],
  body:not(.acg-desktop-game) [hidden]{display:none!important;}
}

/* V41 — Ajuste fino: Truco/Batalha no padrão do Cidade Dorme/Adedonha, sem mexer nas mecânicas. */
@media (min-width:901px){
  body:not(.acg-mobile-game) [hidden],
  body:not(.acg-mobile-game) .menu-logged[hidden],
  body:not(.acg-mobile-game) #menuLoggedPlayerBox[hidden]{display:none!important;}

  body:not(.acg-mobile-game){
    --v41-page-w:1080px;
    --v41-hero-w:1000px;
    --v41-menu-h:76px;
    --v41-hero-h:360px;
    --v41-card-h:230px;
    --v41-card-pad:20px;
    --v41-field-h:48px;
    --v41-btn-h:42px;
  }

  /* Página e menus externos iguais em todos os jogos */
  body:not(.acg-mobile-game) .home-modern,
  body.game-truco:not(.acg-mobile-game) .landing-shell,
  body.game-xadrez:not(.acg-mobile-game) .container,
  body.game-adedonha:not(.acg-mobile-game) #app,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-app{
    width:min(var(--v41-page-w), calc(100vw - 36px))!important;
    max-width:var(--v41-page-w)!important;
    margin-left:auto!important;
    margin-right:auto!important;
  }

  body:not(.acg-mobile-game) .home-main-menu,
  body.game-truco:not(.acg-mobile-game) .app-shell-header,
  body.game-xadrez:not(.acg-mobile-game) .header,
  body.game-adedonha:not(.acg-mobile-game) .topbar,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-top{
    width:min(var(--v41-page-w), calc(100vw - 36px))!important;
    max-width:var(--v41-page-w)!important;
    min-height:var(--v41-menu-h)!important;
    margin:14px auto 18px!important;
    padding:12px 16px!important;
    border-radius:22px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:16px!important;
    flex-wrap:nowrap!important;
  }

  body:not(.acg-mobile-game) .menu-brand,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand,
  body.game-xadrez:not(.acg-mobile-game) .header .brand,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand{
    flex:0 0 250px!important;
    min-width:250px!important;
    width:250px!important;
    display:flex!important;
    align-items:center!important;
    gap:13px!important;
  }

  body:not(.acg-mobile-game) .menu-brand img,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand img,
  body.game-xadrez:not(.acg-mobile-game) .header .brand img,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand img{
    width:118px!important;
    height:52px!important;
    max-width:118px!important;
    max-height:52px!important;
    object-fit:contain!important;
    flex:0 0 118px!important;
  }

  body:not(.acg-mobile-game) .menu-brand strong,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand-title,
  body.game-xadrez:not(.acg-mobile-game) .header .brand h1,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand h1,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand h1{
    font-size:1.18rem!important;
    line-height:1.02!important;
    font-weight:1000!important;
    letter-spacing:.01em!important;
    margin:0!important;
  }
  body:not(.acg-mobile-game) .menu-brand span,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand-sub,
  body.game-xadrez:not(.acg-mobile-game) .header .brand small,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand p{
    font-size:.74rem!important;
    line-height:1.18!important;
    letter-spacing:.22em!important;
    margin:4px 0 0!important;
    text-transform:uppercase!important;
  }

  body:not(.acg-mobile-game) .menu-actions,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav,
  body.game-xadrez:not(.acg-mobile-game) .header .nav,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav{
    flex:1 1 auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:10px!important;
    flex-wrap:wrap!important;
  }

  body:not(.acg-mobile-game) .menu-btn,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .delivery-btn,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav button,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav button,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions a,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav a,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav button{
    height:42px!important;
    min-height:42px!important;
    padding:0 15px!important;
    border-radius:15px!important;
    font-size:.9rem!important;
    font-weight:1000!important;
    line-height:1!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    white-space:nowrap!important;
  }

  body:not(.acg-mobile-game) .menu-btn-red,
  body.game-truco:not(.acg-mobile-game) .delivery-btn.ifood,
  body.game-xadrez:not(.acg-mobile-game) .nav .ifood,
  body.game-adedonha:not(.acg-mobile-game) .topbar .ifood,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .ifood{
    background:#ef2f2f!important;color:#fff!important;border-color:rgba(255,255,255,.14)!important;
  }
  body:not(.acg-mobile-game) .menu-btn-gold,
  body.game-truco:not(.acg-mobile-game) .delivery-btn.sirrus,
  body.game-xadrez:not(.acg-mobile-game) .nav .sirrus,
  body.game-adedonha:not(.acg-mobile-game) .topbar .sirrus,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .sirrus{
    background:#f6c23a!important;color:#130d00!important;border-color:rgba(255,234,146,.42)!important;
  }

  /* Hero/capa: mesma régua visual e sem imagem preta no Truco */
  body:not(.acg-mobile-game) .home-hero,
  body.game-truco:not(.acg-mobile-game) .landing-hero-panel,
  body.game-xadrez:not(.acg-mobile-game) .container>.hero,
  body.game-adedonha:not(.acg-mobile-game) .game-home-hero,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover{
    width:100%!important;
    max-width:var(--v41-hero-w)!important;
    min-height:var(--v41-hero-h)!important;
    height:var(--v41-hero-h)!important;
    margin:18px auto 0!important;
    display:grid!important;
    grid-template-columns:minmax(0,1.72fr) minmax(300px,.72fr)!important;
    gap:0!important;
    align-items:stretch!important;
    border-radius:22px!important;
    overflow:hidden!important;
  }

  body:not(.acg-mobile-game) .hero-cover-frame,
  body.game-truco:not(.acg-mobile-game) .landing-cover,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover,
  body.game-adedonha:not(.acg-mobile-game) .cover-card{
    width:100%!important;
    height:var(--v41-hero-h)!important;
    min-height:var(--v41-hero-h)!important;
    max-height:var(--v41-hero-h)!important;
    aspect-ratio:auto!important;
    background:#050505!important;
  }
  body:not(.acg-mobile-game) .home-hero .game-cover,
  body.game-truco:not(.acg-mobile-game) .landing-cover img,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover img,
  body.game-adedonha:not(.acg-mobile-game) .cover-card img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{
    display:block!important;
    width:100%!important;
    height:var(--v41-hero-h)!important;
    min-height:var(--v41-hero-h)!important;
    object-fit:cover!important;
    object-position:center center!important;
  }
  body.game-truco:not(.acg-mobile-game) .landing-cover{background-image:url('/truco/assets/truco-cover.png?v=4400')!important;background-size:cover!important;background-position:center!important;}
  body.game-truco:not(.acg-mobile-game) .landing-cover::after{background:linear-gradient(90deg,rgba(0,0,0,.02),rgba(0,0,0,.06) 62%,rgba(0,0,0,.72) 100%)!important;}

  body:not(.acg-mobile-game) .hero-copy,
  body.game-truco:not(.acg-mobile-game) .landing-copy,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy,
  body.game-adedonha:not(.acg-mobile-game) .hero-side,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content{
    height:var(--v41-hero-h)!important;
    min-height:var(--v41-hero-h)!important;
    padding:32px 34px!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:center!important;
  }

  /* Cards externos: mesmo tamanho do Cidade Dorme/Adedonha. */
  body:not(.acg-mobile-game) .home-grid,
  body.game-truco:not(.acg-mobile-game) .landing-forms-grid,
  body.game-xadrez:not(.acg-mobile-game) .forms,
  body.game-adedonha:not(.acg-mobile-game) .home-access-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-access-grid{
    width:100%!important;
    max-width:var(--v41-hero-w)!important;
    margin:20px auto 0!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:18px!important;
    align-items:stretch!important;
  }
  body:not(.acg-mobile-game) #accessCard,
  body:not(.acg-mobile-game) #guestJoinCard,
  body:not(.acg-mobile-game) #loggedJoinCard,
  body.game-truco:not(.acg-mobile-game) .landing-card,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card{
    min-height:var(--v41-card-h)!important;
    height:var(--v41-card-h)!important;
    padding:var(--v41-card-pad)!important;
    border-radius:22px!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }

  body.game-xadrez:not(.acg-mobile-game) .standard-card-title,
  body:not(.acg-mobile-game) .section-title,
  body.game-truco:not(.acg-mobile-game) .landing-card-head,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title{
    display:flex!important;align-items:flex-start!important;justify-content:space-between!important;gap:12px!important;margin:0 0 12px!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .standard-card-title h3,
  body:not(.acg-mobile-game) .section-title h2,
  body.game-truco:not(.acg-mobile-game) .landing-card-head h2,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title h3,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title h3{
    font-size:1.12rem!important;line-height:1.1!important;margin:0!important;font-weight:1000!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .standard-card-title span,
  body:not(.acg-mobile-game) .section-title span,
  body.game-truco:not(.acg-mobile-game) .landing-card-head small,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title span,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title span{
    font-size:.76rem!important;line-height:1.25!important;white-space:nowrap!important;color:#c7c7c7!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .standard-form-row,
  body:not(.acg-mobile-game) .form-grid,
  body.game-truco:not(.acg-mobile-game) .form-row,
  body.game-adedonha:not(.acg-mobile-game) .home-form-row,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-form-row{
    display:grid!important;grid-template-columns:1fr 1fr!important;gap:12px!important;align-items:end!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .standard-form-row.one{grid-template-columns:1fr!important;max-width:260px!important;}
  body.game-xadrez:not(.acg-mobile-game) .standard-access-card .muted{margin:0 0 10px!important;font-size:.92rem!important;line-height:1.38!important;}
  body.game-xadrez:not(.acg-mobile-game) .standard-actions{margin-top:12px!important;}
  body.game-xadrez:not(.acg-mobile-game) .standard-access-card input{margin:0!important;}
}

@media (max-width:900px){
  body:not(.acg-desktop-game) [hidden],
  body:not(.acg-desktop-game) .menu-logged[hidden],
  body:not(.acg-desktop-game) #menuLoggedPlayerBox[hidden]{display:none!important;}
}

/* V41 — Home Standard Unificada
   Objetivo: eliminar variações de espaçamento, hero, menu e cards externos.
   Não altera regras, Socket.IO, backend, salas, tabuleiros ou fluxo de jogo. */
@media (min-width:901px){
  :root{
    --v41-page-w:1080px;
    --v41-hero-w:1000px;
    --v41-hero-ratio:1672/941;
    --v41-top-gap:18px;
    --v41-section-gap:20px;
    --v41-menu-min-h:94px;
    --v41-menu-pad-y:14px;
    --v41-menu-pad-x:18px;
    --v41-brand-w:250px;
    --v41-logo-w:118px;
    --v41-logo-h:52px;
    --v41-pill-h:42px;
    --v41-pill-radius:15px;
    --v41-card-pad:20px;
    --v41-card-min-h:230px;
    --v41-field-h:50px;
  }

  /* Batalha Naval tinha centralização vertical no home, gerando espaço superior diferente. */
  body.game-batalha:not(.acg-mobile-game) .app-shell{padding:var(--v41-top-gap) 0 54px!important;min-height:100vh!important;display:block!important;}
  body.game-batalha:not(.acg-mobile-game) .home-screen,
  body.game-batalha:not(.acg-mobile-game) .home-screen.is-active{display:block!important;place-items:initial!important;align-items:initial!important;justify-items:initial!important;}

  /* Truco tinha respiro extra entre menu e hero. */
  body.game-truco:not(.acg-mobile-game) .landing-naval{padding:0 0 54px!important;min-height:auto!important;}

  /* Container único para páginas externas. */
  body:not(.acg-mobile-game) .home-modern,
  body.game-truco:not(.acg-mobile-game) .landing-shell,
  body.game-xadrez:not(.acg-mobile-game) .container,
  body.game-adedonha:not(.acg-mobile-game) #app,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-app{
    width:min(var(--v41-page-w),calc(100vw - 42px))!important;
    max-width:var(--v41-page-w)!important;
    margin:0 auto 54px!important;
    padding:0!important;
  }

  /* Menu superior: mesma caixa, mesma altura e mesma régua de botões. */
  body:not(.acg-mobile-game) .home-main-menu,
  body.game-truco:not(.acg-mobile-game) .app-shell-header,
  body.game-xadrez:not(.acg-mobile-game) .header,
  body.game-adedonha:not(.acg-mobile-game) .topbar,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-top{
    box-sizing:border-box!important;
    width:min(var(--v41-page-w),calc(100vw - 42px))!important;
    max-width:var(--v41-page-w)!important;
    min-height:var(--v41-menu-min-h)!important;
    margin:0 auto var(--v41-section-gap)!important;
    padding:var(--v41-menu-pad-y) var(--v41-menu-pad-x)!important;
    border-radius:22px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:18px!important;
    overflow:visible!important;
    position:relative!important;
    top:auto!important;
  }

  body:not(.acg-mobile-game) .menu-brand,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand,
  body.game-xadrez:not(.acg-mobile-game) .header .brand,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand{
    box-sizing:border-box!important;
    flex:0 0 var(--v41-brand-w)!important;
    width:var(--v41-brand-w)!important;
    min-width:var(--v41-brand-w)!important;
    display:flex!important;
    align-items:center!important;
    gap:13px!important;
  }

  body:not(.acg-mobile-game) .menu-brand img,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand img,
  body.game-xadrez:not(.acg-mobile-game) .header .brand img,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand img,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand img{
    width:var(--v41-logo-w)!important;
    height:var(--v41-logo-h)!important;
    max-width:var(--v41-logo-w)!important;
    max-height:var(--v41-logo-h)!important;
    object-fit:contain!important;
    flex:0 0 var(--v41-logo-w)!important;
  }

  body:not(.acg-mobile-game) .menu-brand strong,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand-title,
  body.game-xadrez:not(.acg-mobile-game) .header .brand h1,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand h1,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand h1{
    font-size:1.18rem!important;
    line-height:1.02!important;
    font-weight:1000!important;
    letter-spacing:.01em!important;
    margin:0!important;
    color:#fff!important;
    max-width:132px!important;
  }

  body:not(.acg-mobile-game) .menu-brand span,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .brand-sub,
  body.game-xadrez:not(.acg-mobile-game) .header .brand small,
  body.game-adedonha:not(.acg-mobile-game) .topbar .brand p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-brand p{
    font-size:.74rem!important;
    line-height:1.18!important;
    letter-spacing:.22em!important;
    margin:4px 0 0!important;
    text-transform:uppercase!important;
    color:#ddd2bd!important;
    font-weight:800!important;
  }

  body:not(.acg-mobile-game) .menu-actions,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav,
  body.game-xadrez:not(.acg-mobile-game) .header .nav,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav{
    flex:1 1 auto!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    align-content:center!important;
    gap:10px!important;
    flex-wrap:wrap!important;
    min-width:0!important;
  }
  body:not(.acg-mobile-game) .delivery-links{display:contents!important;}

  body:not(.acg-mobile-game) .menu-btn,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .delivery-btn,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav a,
  body.game-truco:not(.acg-mobile-game) .app-shell-header .nav button,
  body.game-xadrez:not(.acg-mobile-game) .header .nav a,
  body.game-xadrez:not(.acg-mobile-game) .header .nav button,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions a,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav a,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav button{
    box-sizing:border-box!important;
    height:var(--v41-pill-h)!important;
    min-height:var(--v41-pill-h)!important;
    max-height:var(--v41-pill-h)!important;
    padding:0 16px!important;
    border-radius:var(--v41-pill-radius)!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    font-size:.90rem!important;
    font-weight:1000!important;
    line-height:1!important;
    white-space:nowrap!important;
    text-decoration:none!important;
    text-transform:none!important;
    letter-spacing:.01em!important;
    margin:0!important;
    width:auto!important;
    min-width:auto!important;
    transform:none!important;
  }

  body:not(.acg-mobile-game) .menu-btn-red,
  body.game-truco:not(.acg-mobile-game) .delivery-btn.ifood,
  body.game-xadrez:not(.acg-mobile-game) .header .nav .ifood,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions .ifood,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .ifood{
    background:#ef2f2f!important;
    color:#fff!important;
    border:1px solid rgba(255,255,255,.14)!important;
    box-shadow:0 10px 24px rgba(239,47,47,.14)!important;
  }
  body:not(.acg-mobile-game) .menu-btn-gold,
  body.game-truco:not(.acg-mobile-game) .delivery-btn.sirrus,
  body.game-xadrez:not(.acg-mobile-game) .header .nav .sirrus,
  body.game-adedonha:not(.acg-mobile-game) .topbar .top-actions .sirrus,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-nav .sirrus{
    background:#f6c23a!important;
    color:#130d00!important;
    border:1px solid rgba(255,234,146,.42)!important;
    box-shadow:0 10px 24px rgba(246,194,58,.14)!important;
  }

  /* Hero externo: altura por proporção da imagem, sem faixa preta e sem corte de botão/card. */
  body:not(.acg-mobile-game) .home-hero,
  body.game-truco:not(.acg-mobile-game) .landing-hero-panel,
  body.game-xadrez:not(.acg-mobile-game) .container>.hero,
  body.game-adedonha:not(.acg-mobile-game) .game-home-hero,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover{
    box-sizing:border-box!important;
    width:100%!important;
    max-width:var(--v41-hero-w)!important;
    margin:0 auto!important;
    display:grid!important;
    grid-template-columns:minmax(0,1.72fr) minmax(300px,.72fr)!important;
    gap:0!important;
    align-items:stretch!important;
    border-radius:22px!important;
    overflow:hidden!important;
    min-height:0!important;
    height:auto!important;
  }

  body:not(.acg-mobile-game) .hero-cover-frame,
  body.game-truco:not(.acg-mobile-game) .landing-cover,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover,
  body.game-adedonha:not(.acg-mobile-game) .cover-card{
    position:relative!important;
    box-sizing:border-box!important;
    width:100%!important;
    aspect-ratio:var(--v41-hero-ratio)!important;
    min-height:0!important;
    height:auto!important;
    max-height:none!important;
    overflow:hidden!important;
    border:0!important;
    border-radius:0!important;
    background:#050505!important;
  }
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover>img{
    box-sizing:border-box!important;
    width:100%!important;
    aspect-ratio:var(--v41-hero-ratio)!important;
    height:auto!important;
    min-height:0!important;
    max-height:none!important;
    object-fit:cover!important;
    object-position:center!important;
    display:block!important;
    align-self:stretch!important;
  }

  body:not(.acg-mobile-game) .home-hero .game-cover,
  body.game-truco:not(.acg-mobile-game) .landing-cover img,
  body.game-xadrez:not(.acg-mobile-game) .hero-cover img,
  body.game-adedonha:not(.acg-mobile-game) .cover-card img{
    position:absolute!important;
    inset:0!important;
    width:100%!important;
    height:100%!important;
    min-height:0!important;
    max-height:none!important;
    object-fit:cover!important;
    object-position:center!important;
    display:block!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
  }
  body.game-truco:not(.acg-mobile-game) .landing-cover{background-image:none!important;}
  body.game-truco:not(.acg-mobile-game) .landing-cover:after{background:linear-gradient(90deg,rgba(0,0,0,.02),rgba(0,0,0,.06) 62%,rgba(0,0,0,.62) 100%)!important;}

  body:not(.acg-mobile-game) .hero-copy,
  body.game-truco:not(.acg-mobile-game) .landing-copy,
  body.game-xadrez:not(.acg-mobile-game) .hero-copy,
  body.game-adedonha:not(.acg-mobile-game) .hero-side,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content{
    box-sizing:border-box!important;
    min-height:0!important;
    height:auto!important;
    padding:32px 34px!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:center!important;
    align-items:flex-start!important;
    gap:8px!important;
    text-align:left!important;
  }

  body:not(.acg-mobile-game) .hero-copy h1,
  body.game-truco:not(.acg-mobile-game) .landing-copy h1,
  body.game-xadrez:not(.acg-mobile-game) .hero h2,
  body.game-adedonha:not(.acg-mobile-game) .hero-side h2,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content h2{
    max-width:320px!important;
    font-size:2.55rem!important;
    line-height:1.04!important;
    margin:0!important;
  }
  body:not(.acg-mobile-game) .hero-copy .subtitle,
  body.game-truco:not(.acg-mobile-game) .landing-copy p,
  body.game-xadrez:not(.acg-mobile-game) .hero p,
  body.game-adedonha:not(.acg-mobile-game) .hero-side p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-cover-content p{
    max-width:300px!important;
    font-size:1rem!important;
    line-height:1.42!important;
    margin:10px 0 0!important;
  }

  /* Cards inferiores: sem height fixa. A altura mínima é igual, mas o card cresce se o conteúdo pedir. */
  body:not(.acg-mobile-game) .home-grid,
  body.game-truco:not(.acg-mobile-game) .landing-forms-grid,
  body.game-xadrez:not(.acg-mobile-game) .forms,
  body.game-adedonha:not(.acg-mobile-game) .home-access-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-access-grid{
    box-sizing:border-box!important;
    width:100%!important;
    max-width:var(--v41-hero-w)!important;
    margin:var(--v41-section-gap) auto 0!important;
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:18px!important;
    align-items:stretch!important;
  }

  body:not(.acg-mobile-game) #accessCard,
  body:not(.acg-mobile-game) #guestJoinCard,
  body:not(.acg-mobile-game) #loggedJoinCard,
  body.game-truco:not(.acg-mobile-game) .landing-card,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card{
    box-sizing:border-box!important;
    min-height:var(--v41-card-min-h)!important;
    height:auto!important;
    overflow:visible!important;
    padding:var(--v41-card-pad)!important;
    border-radius:22px!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    gap:12px!important;
  }

  body:not(.acg-mobile-game) .section-title,
  body.game-truco:not(.acg-mobile-game) .landing-card-head,
  body.game-xadrez:not(.acg-mobile-game) .standard-card-title,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title{
    display:flex!important;
    align-items:flex-start!important;
    justify-content:space-between!important;
    gap:12px!important;
    margin:0 0 8px!important;
  }

  body:not(.acg-mobile-game) .section-title h2,
  body.game-truco:not(.acg-mobile-game) .landing-card-head h2,
  body.game-xadrez:not(.acg-mobile-game) .standard-card-title h3,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title h3,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title h3{
    font-size:1.14rem!important;
    line-height:1.1!important;
    margin:0!important;
    font-weight:1000!important;
  }
  body:not(.acg-mobile-game) .section-title span,
  body.game-truco:not(.acg-mobile-game) .landing-card-head small,
  body.game-xadrez:not(.acg-mobile-game) .standard-card-title span,
  body.game-adedonha:not(.acg-mobile-game) .home-card-title span,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card-title span{
    font-size:.76rem!important;
    line-height:1.25!important;
    color:#c7c7c7!important;
    white-space:nowrap!important;
  }

  body:not(.acg-mobile-game) .form-grid,
  body.game-truco:not(.acg-mobile-game) .form-row,
  body.game-xadrez:not(.acg-mobile-game) .standard-form-row,
  body.game-adedonha:not(.acg-mobile-game) .home-form-row,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-form-row,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-compact-form{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:12px!important;
    align-items:end!important;
  }
  body.game-xadrez:not(.acg-mobile-game) .standard-form-row.one{grid-template-columns:1fr!important;max-width:260px!important;}
  body:not(.acg-mobile-game) label{display:grid!important;gap:7px!important;margin:0!important;}
  body:not(.acg-mobile-game) input,
  body:not(.acg-mobile-game) select,
  body:not(.acg-mobile-game) textarea{
    box-sizing:border-box!important;
    width:100%!important;
    height:var(--v41-field-h)!important;
    min-height:var(--v41-field-h)!important;
    padding:0 14px!important;
    border-radius:15px!important;
    font-size:.94rem!important;
    line-height:1!important;
    margin:0!important;
  }

  body:not(.acg-mobile-game) .action-row,
  body:not(.acg-mobile-game) .actions,
  body.game-truco:not(.acg-mobile-game) .landing-actions,
  body.game-xadrez:not(.acg-mobile-game) .standard-actions,
  body.game-adedonha:not(.acg-mobile-game) .home-actions,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:10px!important;
    flex-wrap:wrap!important;
    margin-top:8px!important;
  }

  body:not(.acg-mobile-game) .home-card button,
  body.game-truco:not(.acg-mobile-game) .landing-card button,
  body.game-xadrez:not(.acg-mobile-game) .forms>.card button,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card button,
  body:not(.acg-mobile-game) .link-button{
    box-sizing:border-box!important;
    min-height:46px!important;
    height:46px!important;
    border-radius:15px!important;
    padding:0 18px!important;
    font-size:.93rem!important;
    line-height:1!important;
    font-weight:1000!important;
    margin:0!important;
    width:auto!important;
  }
  body:not(.acg-mobile-game) .wide-button,
  body:not(.acg-mobile-game) .full,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card button[type="submit"],
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card button[type="submit"]{
    min-width:210px!important;
    max-width:100%!important;
  }

  /* Evita corte visual em cards de entrada quando o texto ocupar mais de uma linha. */
  body:not(.acg-mobile-game) .mini-muted,
  body.game-truco:not(.acg-mobile-game) .muted,
  body.game-xadrez:not(.acg-mobile-game) .standard-access-card .muted,
  body.game-adedonha:not(.acg-mobile-game) .home-access-card p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-home-card p{
    font-size:.92rem!important;
    line-height:1.38!important;
    margin:0 0 8px!important;
  }
}

/* V44 — Área logada unificada
   Separação definitiva entre home pública e menu interno pós-login.
   Não altera mecânica, Socket.IO, salas ou regras dos jogos. */
:root{
  --std-internal-w:1000px;
  --std-internal-pad:24px;
  --std-internal-gap:16px;
  --std-internal-card-h:150px;
}

@media (min-width:901px){
  /* BATALHA NAVAL: quando logado, remove completamente a home pública. */
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) .home-hero,
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #accessCard,
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #guestJoinCard,
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #publicRoomsLockedCard{
    display:none!important;
    visibility:hidden!important;
    opacity:0!important;
    pointer-events:none!important;
    height:0!important;
    min-height:0!important;
    max-height:0!important;
    padding:0!important;
    margin:0!important;
    border:0!important;
    overflow:hidden!important;
  }

  body.game-batalha.is-creator-logged:not(.acg-mobile-game) .home-modern{
    width:min(var(--std-home-w),calc(100vw - 36px))!important;
    max-width:var(--std-home-w)!important;
    margin:14px auto 54px!important;
    display:grid!important;
    gap:18px!important;
  }

  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #internalMenuPanel{
    display:block!important;
    width:100%!important;
    max-width:var(--std-internal-w)!important;
    margin:0 auto!important;
    padding:var(--std-internal-pad)!important;
    border-radius:22px!important;
    box-sizing:border-box!important;
  }
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #internalMenuPanel[hidden]{display:none!important;}

  body.game-batalha.is-creator-logged:not(.acg-mobile-game) .home-grid{
    width:100%!important;
    max-width:var(--std-internal-w)!important;
    margin:0 auto!important;
    display:block!important;
    grid-template-columns:none!important;
    gap:0!important;
  }
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #createRoomPanel[hidden],
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #loggedJoinCard[hidden],
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #publicRoomsCard[hidden],
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) .home-grid > [hidden]{
    display:none!important;
  }
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #createRoomPanel:not([hidden]),
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #loggedJoinCard:not([hidden]),
  body.game-batalha.is-creator-logged:not(.acg-mobile-game) #publicRoomsCard:not([hidden]){
    display:block!important;
    width:100%!important;
    max-width:var(--std-internal-w)!important;
    margin:0 auto 16px!important;
    min-height:auto!important;
    height:auto!important;
    padding:var(--std-internal-pad)!important;
    overflow:visible!important;
    border-radius:22px!important;
    box-sizing:border-box!important;
  }

  /* Régua única dos menus internos pós-login. */
  body.game-batalha:not(.acg-mobile-game) #internalMenuPanel,
  body.game-truco:not(.acg-mobile-game) .logged-menu-shell,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-shell,
  body.game-adedonha:not(.acg-mobile-game) .menu-screen .panel,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen{
    width:100%!important;
    max-width:var(--std-internal-w)!important;
    margin:18px auto 0!important;
    padding:var(--std-internal-pad)!important;
    border-radius:22px!important;
    box-sizing:border-box!important;
    background:rgba(5,5,7,.78)!important;
    border:1px solid var(--game-line)!important;
    box-shadow:0 24px 80px rgba(0,0,0,.38), inset 0 1px 0 rgba(255,255,255,.035)!important;
  }

  body.game-truco:not(.acg-mobile-game) .logged-menu-shell,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-shell{
    margin-top:18px!important;
  }

  body.game-truco:not(.acg-mobile-game) .logged-menu-shell .screen-title,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-shell h2,
  body.game-adedonha:not(.acg-mobile-game) .menu-screen .panel>h2,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen>h2,
  body.game-batalha:not(.acg-mobile-game) .internal-menu-head h1{
    font-size:1.52rem!important;
    line-height:1.05!important;
    margin:0 0 8px!important;
    font-weight:1000!important;
    color:#fff!important;
  }

  body.game-truco:not(.acg-mobile-game) .logged-menu-shell>.muted,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-shell>.muted,
  body.game-adedonha:not(.acg-mobile-game) .menu-screen .panel>p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen>.cd-muted,
  body.game-batalha:not(.acg-mobile-game) .internal-menu-head p{
    font-size:.94rem!important;
    line-height:1.42!important;
    color:#bcc7d2!important;
    margin:0 0 18px!important;
    max-width:760px!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-grid,
  body.game-truco:not(.acg-mobile-game) .logged-menu-grid,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-grid,
  body.game-adedonha:not(.acg-mobile-game) .quick-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:var(--std-internal-gap)!important;
    align-items:stretch!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-card,
  body.game-truco:not(.acg-mobile-game) .logged-menu-card,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-card,
  body.game-adedonha:not(.acg-mobile-game) .action-card,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel{
    min-height:var(--std-internal-card-h)!important;
    height:auto!important;
    padding:18px!important;
    border-radius:18px!important;
    box-sizing:border-box!important;
    display:flex!important;
    flex-direction:column!important;
    justify-content:flex-start!important;
    align-items:flex-start!important;
    gap:10px!important;
    overflow:visible!important;
    background:linear-gradient(145deg,rgba(255,255,255,.045),rgba(0,0,0,.28))!important;
    border:1px solid var(--game-line)!important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.04),0 16px 42px rgba(0,0,0,.20)!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-card h2,
  body.game-truco:not(.acg-mobile-game) .logged-menu-card h3,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-card h3,
  body.game-adedonha:not(.acg-mobile-game) .action-card h3,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel h3{
    font-size:1.05rem!important;
    line-height:1.1!important;
    margin:0!important;
    color:#fff!important;
    font-weight:1000!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-card p,
  body.game-truco:not(.acg-mobile-game) .logged-menu-card p,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-card p,
  body.game-adedonha:not(.acg-mobile-game) .action-card p,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel p{
    font-size:.93rem!important;
    line-height:1.38!important;
    color:#d0d0d0!important;
    margin:0!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-card button,
  body.game-truco:not(.acg-mobile-game) .logged-menu-card button,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-card button,
  body.game-adedonha:not(.acg-mobile-game) .action-card button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel button{
    margin-top:auto!important;
    min-height:42px!important;
    height:42px!important;
    border-radius:14px!important;
    padding:0 18px!important;
    font-size:.9rem!important;
    font-weight:1000!important;
    line-height:1!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:auto!important;
    min-width:0!important;
  }

  body.game-batalha:not(.acg-mobile-game) .internal-menu-card .btn.primary,
  body.game-truco:not(.acg-mobile-game) .logged-menu-card button,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-card button,
  body.game-adedonha:not(.acg-mobile-game) .action-card .btn.violet,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel .primary{
    background:var(--game-accent)!important;
    color:#fff!important;
    border-color:transparent!important;
  }
  body.game-truco:not(.acg-mobile-game) .logged-menu-card button,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid>.cd-panel .gold,
  body.game-adedonha:not(.acg-mobile-game) .action-card .btn:not(.secondary):not(.violet){
    background:#f6c23a!important;
    color:#130d00!important;
  }
}

@media (min-width:901px) and (max-width:1180px){
  body.game-batalha:not(.acg-mobile-game) .internal-menu-grid,
  body.game-truco:not(.acg-mobile-game) .logged-menu-grid,
  body.game-xadrez:not(.acg-mobile-game) .logged-menu-grid,
  body.game-adedonha:not(.acg-mobile-game) .quick-grid,
  body.game-cidade-dorme:not(.acg-mobile-game) .cd-menu-screen .cd-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
}
