position$0/* Единая компоновка города и текущей локации. Прокрутка только внутри списков. */
body:has(#view-town:not([hidden])){overflow:hidden}body:has(#view-town:not([hidden])) main{max-width:1600px;padding:12px;margin:auto;height:calc(100dvh - 64px);box-sizing:border-box}
#view-town.location-shell{display:grid!important;grid-template-columns:minmax(240px,.95fr) minmax(330px,1.5fr) minmax(270px,.9fr);grid-template-rows:minmax(230px,44%) minmax(0,1fr);gap:12px;height:100%;min-height:0}#view-town.location-shell[hidden]{display:none!important}
.location-shell>.panel{margin:0!important;min-height:0;min-width:0;padding:12px;box-sizing:border-box;overflow:hidden}.location-profile{grid-column:1;grid-row:1}.location-scene{grid-column:2;grid-row:1;position:relative}.location-games{grid-column:3;grid-row:1/3;overflow:auto!important}.location-chat{grid-column:1/3;grid-row:2;padding-right:220px!important;position:relative;display:flex;flex-direction:column}.location-members{grid-column:2;grid-row:2;justify-self:end;width:210px;z-index:2;background:#e9d3a1!important;color:#49321d;border:2px solid #917044;overflow:auto!important;margin:10px!important}
#myProfile .profile-identity-card{display:grid;grid-template-columns:100px minmax(0,1fr);padding:5px;gap:12px;background:none;box-shadow:none;border:0}#myProfile .profile-identity-avatar{width:100px;height:135px;min-width:0}#myProfile .profile-identity-avatar img{width:100%;height:100%;object-fit:cover;border-radius:45%;border:2px solid #b38c50}#myProfile .profile-identity-copy{min-width:0;font-size:11px}#myProfile .profile-identity-copy p{margin:5px 0}#myProfile .profile-identity-heading h3{font-size:17px}#daily{font-size:11px;padding:6px;margin-top:5px}#daily[hidden]{display:none}
#locationInside{height:100%;position:relative;background:#28180d;border-radius:10px;overflow:hidden}#locationInside img{width:100%;height:100%;object-fit:cover}#locationInside h2{position:absolute;bottom:0;left:0;right:0;margin:0;padding:14px;background:linear-gradient(transparent,#160e09e8);font-size:24px}#cityDestinations{height:100%;overflow:auto}#locations{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;height:100%;padding:0}#locations .loc{min-height:57px;padding:5px;position:relative;overflow:hidden;display:flex;align-items:end;text-align:left}#locations .loc img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.6}#locations .loc-copy{position:relative;z-index:1;text-shadow:0 1px 3px #000}#locations .loc b{font-size:11px}#locations 
.loc small{font-size:9px}
.location-games .game-lobby{padding:0;border:0;background:none!important;box-shadow:none;outline:0}.location-games .game-lobby>p,.location-games .game-lobby>h2{display:none}.location-games #gameModeCards{display:grid;grid-template-columns:1fr 1fr;gap:6px}.location-games .mode-card{min-height:70px;padding:8px;display:grid;grid-template-columns:20px 1fr;gap:3px;text-align:left}.location-games .mode-card b
{
    font-size: 16px;
    padding: 2px;
    margin: auto;
    padding-left: 0px;
    text-align: center;
    }.location-games .mode-card small{font-size:9px;grid-column:1/3}.location-games .mode-create-label{font-size:9px;grid-column:1/3}.location-games .mode-icon{font-size:18px}.location-games #createTable,.location-games .lobby-filters{display:none}.lobby-mode-filters{display:flex;flex-wrap:wrap;gap:5px;margin:12px 0}.lobby-mode-filters>b{width:100%}.lobby-mode-filters button{padding:4px 8px}.lobby-mode-filters label{display:flex;align-items:center;gap:4px;font-size:11px}.location-games 
    
    .lobby-table-card{
        padding:8px;
        display:grid;
        gap:5px;
        margin:6px 0;
        background:#e5c991;color:#402716
        }
        
        .location-games .lobby-table-card>div:first-child small{display:none}.location-games .lobby-seats{display:flex;justify-content:space-around}.location-games .lobby-avatar{width:33px;height:33px}.location-games .lobby-seat{min-width:0;font-size:9px}.location-games .lobby-seat span[title]{max-width:60px;overflow:hidden;text-overflow:ellipsis}.location-games .lobby-table-card button{font-size:11px;padding:5px}
.location-chat .chat-tabs{flex:0 0 auto;margin:5px 0;display:flex;gap:3px}.location-chat .chat-tabs button{font-size:11px;padding:7px}.location-chat>[id^=town-chat-]{min-height:0;flex:1;display:flex;flex-direction:column}.location-chat>[id^=town-chat-][hidden]{display:none!important}.location-chat>[id^=town-chat-]>h3{display:none}.location-chat .chat{flex:1;min-height:0;height:auto;overflow:auto;background:#ecd7a8;color:#4a321b;margin:0;border-radius:6px;padding:9px}.location-chat form{flex:0 0 auto;margin-top:6px;display:flex}.location-chat form input{min-width:0;flex:1}.location-chat #system{height:100%;max-height:none}.location-chat .news-widget{margin:0;padding:5px 9px;font-size:11px;min-height:24px}.location-chat .chat-line{display:grid;grid-template-columns:32px 1fr;gap:2px 8px;padding:5px 0}.chat-line-avatar{width:30px;height:30px;border-radius:50%;object-fit:cover;grid-row:1/3}.chat-message-body{grid-column:2;font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere}.chat-user-link{background:none!important;box-shadow:none!important;border:0!important;color:inherit!important;text-shadow:none;text-align:left;padding:0;min-width:0;overflow-wrap:anywhere;font-weight:700;font-size:12px}.location-members h3{font-size:14px;color:#49321d;margin:3px 0 10px;  text-shadow:0 0 black;}.member-row{display:grid;grid-template-columns:30px 1fr;gap:2px 7px;margin-bottom:10px}.member-row img{width:30px;height:30px;object-fit:cover;border-radius:50%;grid-row:1/3}.member-row small{font-size:10px;grid-column:2}
@media(max-width:1000px) and (min-width:761px){#view-town.location-shell{grid-template-columns:220px minmax(220px,1fr) 250px}.location-chat{padding-right:160px!important}.location-members{width:150px}#myProfile .profile-identity-card{grid-template-columns:65px 1fr}#myProfile .profile-identity-avatar{width:65px;height:95px}}
@media(max-width:760px){body:has(#view-town:not([hidden])) header.top{padding:5px;min-height:44px}body:has(#view-town:not([hidden])) main{padding:5px;height:calc(100dvh - 60px)}#view-town.location-shell{grid-template-columns:minmax(0,1fr) 100px;grid-template-rows:18% 30% minmax(0,1fr);gap:6px}.location-profile{display:none}.location-scene{grid-column:1/3;grid-row:1;padding:0!important}.location-games{grid-column:1/3;grid-row:2;overflow:auto!important;padding:6px!important;display:flex}.location-games .game-lobby{width:100%}.location-games #gameModeCards{grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.location-games .mode-card{min-height:45px;padding:5px;grid-template-columns:15px 1fr}.location-games .mode-card b{
        font-size: 16px;
        padding-left: 10px;}
    .location-games .mode-card small,.location-games .mode-create-label{display:none}.location-games .mode-icon{font-size:13px}
    
    .lobby-mode-filters{margin:5px 0}
    .lobby-mode-filters>b{display:none}
    .lobby-mode-filters button{font-size:10px;padding:3px 7px}.location-games #tables{display:flex;overflow:auto;gap:5px;min-height:55px}.location-games .lobby-table-card{min-width:150px;margin:0}.location-games .lobby-table-card>div:first-child{font-size:10px}.location-games .lobby-seats{display:none}.location-chat{grid-column:1;grid-row:3;padding:5px!important}.location-members{grid-column:2;grid-row:3;width:100%;margin:0!important;padding:6px!important}.location-members h3{font-size:10px}.member-row{grid-template-columns:22px 1fr;gap:2px 4px}.member-row img{width:22px;height:22px}.member-row button{font-size:10px}.member-row small{font-size:9px}.location-chat .chat-tabs{gap:1px}.location-chat .chat-tabs button{font-size:9px;padding:5px 3px}.location-chat form button{font-size:10px;padding:6px}.location-chat .news-widget{font-size:9px;padding:3px;min-height:15px}.location-chat .chat{padding:5px}.location-chat .chat-line{grid-template-columns:23px 1fr}.chat-line-avatar{width:22px;height:22px}.chat-message-body{font-size:11px}#cityDestinations #locations{grid-template-columns:repeat(6,minmax(55px,1fr));height:95px;overflow:auto}#locations .loc{min-height:40px}#locations .loc b{font-size:8px}#locations 
    .loc small{display:none}#locationInside h2{font-size:18px;padding:7px}body:has(#view-town:not([hidden])) .nav{flex-wrap:nowrap;overflow-x:auto}body:has(#view-town:not([hidden])) .nav>button:not([data-view=game]):not([data-view=town]):not(.nav-icon),body:has(#view-town:not([hidden])) .logo{display:none}body:has(#view-town:not([hidden])) .nav .nav-icon{min-width:30px;width:30px;font-size:16px}}

body:has(#view-town:not([hidden])) main{height:var(--lobby-height,calc(100dvh - 66px))!important}body:has(#view-town:not([hidden])) #app{height:100%;min-height:0}#view-town.location-shell{height:100%!important;margin:0!important;min-height:0!important;max-height:100%!important}#locationContext{display:none}

body:has(#view-town:not([hidden]))>footer{display:none!important}

#app>.view[hidden],#view-game.playing[hidden],#view-town.location-shell[hidden]{display:none!important}

.mobile-sections-toggle{display:none}@media(max-width:760px){.mobile-sections-toggle{display:inline-flex!important;min-width:32px}body:has(#view-town:not([hidden])) .nav.mobile-sections-open{position:relative;overflow:visible;flex-wrap:wrap;background:#25170e;padding:5px;z-index:100}body:has(#view-town:not([hidden])) .nav.mobile-sections-open>button:not([hidden]){display:inline-flex!important}body:has(#view-town:not([hidden])) .nav>#mobileSectionsToggle{display:inline-flex!important}}

#lobbyProfileToggle{
    display:none}@media(max-width:760px){#lobbyProfileToggle{display:block;position:absolute;right:20px;top:10px;z-index:4;padding:8px 10px;font-size:16px}
.location-shell{position:relative}.show-lobby-profile .location-profile{
        display: block;
        position: absolute;
        left: 7px;
        top: 52px;
        z-index: 9;
        max-height: 260px;
        overflow: auto !important;
        background: #352216 !important;
        right: 40%;
    }
}

/* r35: компактный персонаж, кликабельные режимы, единый ряд фильтров. */
.home-character{display:grid;grid-template-columns:82px minmax(0,1fr);gap:12px;align-items:start}
.home-character-avatar{
    margin: auto;
    width:120px;height:120px}
    .home-character-avatar img{
        width:100%;height:100%;object-fit:cover;border-radius:60px;border:2px solid #b38c50}
.home-character-info{
   margin-left:50px;
   margin-top:30px;
   }

        .home-character h3{
            margin:0 0 9px;font-size:19px;overflow-wrap:anywhere}
            .home-character h3 small{font-size:12px;white-space:nowrap}.home-character p{margin:5px 0;font-size:13px}.home-character-money{display:grid;gap:6px;margin-top:12px;color:#f5ce84;font-size:14px}.location-profile #daily{width:100%;min-height:33px;margin-top:12px}.create-game-heading{display:block!important;text-align:center;margin:0 0 12px!important;font-size:24px!important}.location-games .mode-create-label{display:none!important}.location-games .mode-card{align-items:center;grid-template-columns:28px minmax(0,1fr);gap:3px;padding:10px;min-height:78px}
.location-games .mode-card .mode-icon
{
    grid-column:1;grid-row:1;width: 50px;
        height: 40px;
        font-size: 18px;
    }
.location-games .mode-card>b{grid-column:2;grid-row:1;line-height:1.3;min-width:0}.location-games .mode-card small{grid-column:1/3;grid-row:2}.location-games .lobby-filters,.location-games .table-filters{display:none!important}.lobby-mode-filters{display:flex;flex-wrap:nowrap;gap:5px;width:100%;align-items:center}.lobby-mode-filters>b{display:none}.lobby-mode-filters>button{flex:1;padding:6px 3px}.lobby-mode-filters>label{font-size:10px}.location-chat .chat-line-system{display:block!important;color:#b32620!important;font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere;padding:8px 4px}.chat-line-system>span{display:block}.chat-message-time{font-size:10px;color:#88623c;white-space:nowrap;grid-column:2}.chat-line-system time{display:block;color:#a34a32}.location-chat #chatSend button{color:#fff0d3;background:#c06921 url('/assets/interface-r33/brass.webp');border:1px solid #ffd28b;box-shadow:inset 0 0 10px #fa972b55;min-width:83px}
@media(max-width:760px){
    .home-character{grid-template-columns:64px minmax(0,1fr);gap:10px}
    .home-character-avatar{width:64px;height:64px}
.home-character-info{
   margin: auto;
   
   }

    .home-character h3{font-size:16px}
    .home-character p{font-size:11px}
    .home-character-money{font-size:12px;margin-top:7px}
    .location-games .mode-card{grid-template-columns:16px minmax(0,1fr);gap:5px;min-height:47px;padding:3px}
    .location-games .mode-card .mode-icon{
    width: 35px;
        height: 35px;
        font-size: 15px;
    }
    .create-game-heading{font-size:17px!important;margin:0 0 5px!important}
    .lobby-mode-filters{gap:3px}
    .lobby-mode-filters>button{padding:4px 2px;font-size:10px}
    .location-members .member-row{
        grid-template-columns:24px minmax(0,1fr)}
        .member-row button{line-height:1.35}
        .location-chat #chatSend button{min-width:63px}}


        

/* r37: список столов занимает всю правую панель; режимы перенесены в модал. */
.location-games .game-lobby{display:flex;flex-direction:column;height:100%;width:100%}#openCreateGame{display:block;width:100%;font-size:20px;font-weight:700;min-height:46px;flex:none}#locationTablesTitle{font-size:16px;margin:13px 0 8px}.location-games #tables{overflow:auto;min-height:0;flex:1;display:block}.location-games .lobby-mode-filters{flex:none;margin:0 0 8px}.watch-eye{display:inline-flex;position:relative;cursor:pointer;padding:4px!important}.watch-eye input{position:absolute;opacity:0;width:1px;height:1px}.watch-eye svg{width:29px;height:25px;fill:none;stroke:#8b7654;stroke-width:1.8}.watch-eye:has(input:checked) svg{stroke:#ffd774;filter:drop-shadow(0 0 4px #ecb653)}.watch-eye:focus-within{outline:2px solid #ffd774}
.location-games .lobby-table-card{display:grid;gap:8px;padding:10px;margin:0 0 9px;border:1px solid #b98638;border-left:4px solid #c17d27;border-radius:13px;background:linear-gradient(125deg,#f4dfaa,#caa46a);color:#402716;box-shadow:0 3px 8px #0005}.location-games .lobby-table-card>div:first-child b{font-size:13px}.location-games .lobby-table-card>div:first-child small{display:block;font-size:9px;line-height:1.3;margin-top:3px}.location-games .lobby-seats{display:flex!important;gap:6px}.location-games .lobby-avatar{width:56px;height:56px;overflow:hidden;border-radius:50%;display:grid;place-items:center;background:#513719;flex:none}.location-games .lobby-avatar img{width:100%;height:100%;object-fit:cover}.location-games .lobby-seat span[title]{max-width:75px;font-size:10px}.location-games .lobby-table-card>button{font-weight:700;min-height:31px}
#createGameModal{z-index:95000}#createGameModal[hidden]{display:none!important}#createGameModal>.modal-card{width:min(660px,94vw);max-height:85dvh;overflow:auto}#createGameModal #gameModeCards{display:grid;grid-template-columns:1fr 1fr;gap:10px}#createGameModal .mode-card{display:grid;grid-template-columns:35px minmax(0,1fr);gap:10px;align-items:center;text-align:left;min-height:85px;padding:12px}#createGameModal .mode-card b{font-size:15px;line-height:1.3}#createGameModal .mode-card small,#createGameModal .mode-create-label{display:none}.resident-edit-row{display:grid;grid-template-columns:1.4fr 100px 1fr auto;align-items:end;gap:10px;border-bottom:1px solid #836033;padding:12px 0}.resident-edit-row small{grid-column:1/-1}.resident-edit-row input{width:100%;box-sizing:border-box}
@media(max-width:760px){#view-town.location-shell{grid-template-rows:95px 245px minmax(0,1fr)}.location-games #tables{display:block!important}.location-games .lobby-table-card{min-width:0}.location-games .lobby-avatar{width:48px;height:48px}#openCreateGame{min-height:35px;font-size:16px}#locationTablesTitle{font-size:12px;margin:6px 0}.location-games .lobby-seats{display:flex!important}.location-games .lobby-seat span[title]{max-width:60px;font-size:9px}.resident-edit-row{grid-template-columns:1fr 80px}.resident-edit-row label{min-width:0}#createGameModal .mode-card b{font-size:12px}#createGameModal .mode-card{min-height:70px;padding:9px;gap:6px;grid-template-columns:24px minmax(0,1fr)}}
