body{margin:0;background:#10151e;color:#fff;font-family:Arial,sans-serif}*{box-sizing:border-box}.lobby{max-width:900px;margin:auto;padding:20px}.header{display:flex;justify-content:space-between;align-items:center;padding:18px 0;border-bottom:1px solid #303846}.logo{color:#f5c76b;font-size:26px;font-weight:bold}.panel{background:#1c2430;border:1px solid #343e4d;border-radius:16px;padding:20px;margin-top:20px}.btn{background:linear-gradient(135deg,#f7d37d,#c58a32);color:#181818;border:0;border-radius:10px;padding:14px 22px;font-size:16px;font-weight:bold;cursor:pointer}.room{background:#252f3e;border-radius:12px;padding:16px;margin:12px 0;display:flex;align-items:center;justify-content:space-between;gap:12px}.muted{color:#aab4c3}@media(max-width:600px){.lobby{padding:12px}.room{flex-direction:column;align-items:stretch}.btn{width:100%}}

.game-select {
  display: block;
  width: 100%;
  padding: 14px;
  margin: 8px 0 18px;
  border: 1px solid #455066;
  border-radius: 10px;
  background: #252f3e;
  color: white;
  font-size: 16px;
  box-sizing: border-box;
}

.private-option {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0 22px;
  color: white;
  font-size: 16px;
}

.private-option input {
  width: 22px;
  height: 22px;
  accent-color: #e5b653;
}

#throwInBlock[hidden],
#current[hidden] {
  display: none;
}

.room {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid #455066;
}

.room .btn {
  width: 100%;
}

/* PREMIUM LOBBY */
body {
  background: radial-gradient(ellipse at 50% -15%, #283044 0%, #111722 48%, #090d15 100%);
  color: #f5f2ea;
}

.lobby {
  max-width: 720px;
  margin: 0 auto;
  padding: 20px 18px 50px;
}





.lobby-hero {
  position: relative;
  overflow: hidden;
  margin: 26px 0 34px;
  padding: 34px 24px;
  border: 1px solid rgba(239,195,107,.22);
  border-radius: 24px;
  background: linear-gradient(135deg,#252d3d 0%,#141b29 65%,#1c2230 100%);
  box-shadow: 0 18px 50px rgba(0,0,0,.22), inset 0 1px rgba(255,255,255,.07);
  animation: riseIn .65s ease both;
}

.lobby-hero::after {
  content: "♠";
  position: absolute;
  right: -18px;
  top: -50px;
  font-size: 230px;
  line-height: 1;
  color: rgba(240,194,99,.07);
  transform: rotate(-18deg);
  pointer-events: none;
}

.hero-symbol {
  color: #f3c979;
  font-size: 32px;
  filter: drop-shadow(0 0 15px rgba(242,194,94,.3));
  animation: gentleGlow 3s ease-in-out infinite;
}

.hero-subtitle, .section-eyebrow {
  color: #c6a76a;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2.4px;
  text-transform: uppercase;
}

.hero-subtitle { margin-top: 14px; }

.lobby-hero h1 {
  font-size: clamp(26px,7vw,36px);
  letter-spacing: -.8px;
  margin: 10px 0;
  color: #fff8e9;
}

.lobby-hero p {
  color: #aeb8c9;
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
  max-width: 260px;
}

.tables-section {
  animation: riseIn .8s .12s ease both;
}

.tables-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 20px;
}

.tables-heading h2 {
  font-size: clamp(19px,5vw,25px);
  margin: 7px 0 0;
  color: #fff;
}

.create-trigger {
  flex-shrink: 0;
  padding: 13px 14px;
  border: 1px solid rgba(255,224,157,.5);
  border-radius: 12px;
  background: linear-gradient(135deg,#f7d98b,#c88d35);
  color: #17140f;
  font-weight: 800;
  font-size: 12px;
  box-shadow: 0 5px 24px rgba(211,154,59,.17);
  cursor: pointer;
  transition: transform .2s, box-shadow .2s;
}

.create-trigger:active {
  transform: scale(.96);
}

.rooms-list {
  min-height: 100px;
  color: #aeb8c9;
}

.create-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(3,6,12,.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn .25s ease;
}

.create-overlay[hidden] {
  display: none !important;
}

.create-sheet {
  width: 100%;
  max-width: 720px;
  max-height: 91dvh;
  overflow-y: auto;
  box-sizing: border-box;
  padding: 26px 22px calc(24px + env(safe-area-inset-bottom));
  border: 1px solid rgba(245,203,120,.26);
  border-bottom: none;
  border-radius: 26px 26px 0 0;
  background: linear-gradient(160deg,#252d3c,#131a26 75%);
  box-shadow: 0 -20px 80px rgba(0,0,0,.55);
  animation: sheetUp .35s cubic-bezier(.2,.8,.2,1);
}

.sheet-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 26px;
}

.sheet-top h2 {
  margin: 8px 0 0;
  color: #fff;
  font-size: 27px;
}

.close-sheet {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 50%;
  background: rgba(255,255,255,.06);
  color: #fff;
  font-size: 27px;
  cursor: pointer;
}

.sheet-content .btn {
  width: 100%;
  margin-top: 8px;
  background: linear-gradient(120deg,#f6d58a,#c9913d);
  color: #1b160e;
  border: 0;
  border-radius: 13px;
  font-weight: 800;
  padding: 16px;
}

@keyframes riseIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes sheetUp {
  from { opacity: 0; transform: translateY(70px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes gentleGlow {
  0%,100% { filter: drop-shadow(0 0 8px rgba(242,194,94,.2)); }
  50% { filter: drop-shadow(0 0 22px rgba(242,194,94,.65)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

/* PREMIUM ROOM CARDS */
.premium-room {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin: 0 0 16px;
  padding: 20px;
  border: 1px solid rgba(231,191,112,.22);
  border-radius: 20px;
  background: linear-gradient(145deg,#252d3c,#161d2b);
  box-shadow: 0 12px 35px rgba(0,0,0,.22),
              inset 0 1px rgba(255,255,255,.045);
  animation: riseIn .45s ease both;
  transition: border-color .25s, transform .25s, box-shadow .25s;
}

.premium-room:active {
  transform: scale(.99);
}

.room-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.room-top strong {
  color: #f7e5bf;
  font-size: 16px;
  letter-spacing: .2px;
}

.room-status {
  flex-shrink: 0;
  color: #8be0ad;
  background: rgba(71,181,117,.10);
  border: 1px solid rgba(112,222,157,.18);
  border-radius: 30px;
  padding: 6px 9px;
  font-size: 11px;
  font-weight: 600;
}

.room-owner {
  color: #b8c2d3;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.room-details {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.room-tag {
  padding: 9px 11px;
  border: 1px solid rgba(221,194,139,.13);
  border-radius: 9px;
  background: rgba(255,255,255,.045);
  color: #dce1e9;
  font-size: 12px;
  line-height: 1.3;
}

.premium-room .join-room {
  width: 100%;
  padding: 14px;
  border: 1px solid rgba(244,207,137,.45);
  border-radius: 12px;
  background: linear-gradient(120deg,#f3d38d,#c9913d);
  color: #1c170f;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform .2s, filter .2s;
}

.premium-room .join-room:active {
  transform: scale(.97);
}

.premium-room .join-room:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.empty-rooms {
  padding: 40px 20px;
  text-align: center;
  border: 1px dashed rgba(224,188,112,.25);
  border-radius: 20px;
  background: rgba(255,255,255,.025);
}

.empty-icon {
  font-size: 46px;
  color: #d5ad65;
  margin-bottom: 15px;
  animation: gentleGlow 3s infinite;
}

.empty-rooms strong {
  display: block;
  color: #f4e9d5;
  font-size: 16px;
}

.empty-rooms p {
  color: #8995a9;
  font-size: 13px;
  margin: 10px 0 0;
}

@media (hover: hover) {
  .premium-room:hover {
    border-color: rgba(242,201,121,.48);
    box-shadow: 0 18px 42px rgba(0,0,0,.3);
  }
}


/* Личный профиль игрока */
.profile-trigger {
  display: flex;
  align-items: center;
  gap: 9px;
  background: transparent;
  border: 0;
  color: #f5e8d1;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  max-width: 48%;
}
.profile-avatar {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 2px solid #d8ae58;
  background: #273243;
  display: grid;
  place-items: center;
  color: #eac573;
  overflow: hidden;
}
.profile-avatar img,
.profile-big-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.profile-status {
  color: #35d483;
  font-size: 13px;
}
.profile-sheet {
  max-width: 460px;
}
.profile-details {
  padding: 12px 22px 28px;
  text-align: center;
}
.profile-big-avatar {
  width: 110px;
  height: 110px;
  margin: 5px auto 12px;
  border-radius: 50%;
  border: 3px solid #e6bc66;
  background: #273243;
  display: grid;
  place-items: center;
  font-size: 44px;
  color: #e6bc66;
  overflow: hidden;
}
#profileName {
  margin: 0 0 22px;
  font-size: 27px;
  color: #fff5e5;
}
.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 24px;
}
.profile-stats > div {
  min-width: 0;
  padding: 17px 5px;
  border: 1px solid #354252;
  border-radius: 14px;
  background: #172331;
}
.profile-stats span {
  display: block;
  font-size: 27px;
  font-weight: 800;
  color: #eac573;
}
.profile-stats small {
  display: block;
  margin-top: 7px;
  color: #b9c3d2;
  font-size: 11px;
}
#languageLabel {
  display: block;
  text-align: left;
  margin-bottom: 8px;
  color: #c6cfda;
}

/* Компактное оформление лобби */


.section-eyebrow {
  margin-top: 10px;
  letter-spacing: 4px;
  line-height: 1.6;
}

.tables-heading h2 {
  font-size: 24px;
  line-height: 1.2;
}

.premium-room {
  padding: 18px !important;
  gap: 12px !important;
}

.room-top {
  margin-bottom: 4px;
}

.room-details {
  gap: 6px;
}

.room-tag {
  padding: 7px 9px !important;
  font-size: 12px;
}

.join-room {
  padding: 12px !important;
  min-height: 42px;
}

.room-owner {
  font-size: 13px;
}

/* Более компактная и аккуратная верхняя шапка */




.profile-trigger {
  flex-shrink: 0;
}

.tables-section {
  margin-top: 8px !important;
}

/* Кнопки столов в стиле выбранного макета */
.premium-room .join-room {
  width: 100%;
  min-height: 46px;
  border-radius: 13px;
  font-size: 15px;
  font-weight: 700;
  color: #fff !important;
  transition: background 0.2s, transform 0.2s;
}

.premium-room .delete-room {
  background: linear-gradient(135deg, #f04444, #c91e2a) !important;
  border: 1px solid #ff6666 !important;
}

.premium-room .play-room {
  background: linear-gradient(135deg, #36c978, #148b49) !important;
  border: 1px solid #55e69a !important;
}

.premium-room .play-room:disabled {
  background: #444b57 !important;
  border-color: #555d69 !important;
  color: #aeb4be !important;
}

.premium-room .join-room:active:not(:disabled) {
  transform: scale(0.98);
}

/* Компактные игровые столы — как на утверждённом макете */
.premium-room {
  position: relative;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) 155px;
  grid-template-rows: auto auto;
  column-gap: 10px !important;
  row-gap: 8px !important;
  padding: 12px !important;
  border-radius: 17px !important;
  align-items: center;
}

.premium-room .room-top {
  display: contents !important;
}

.premium-room .room-top strong {
  grid-column: 1;
  grid-row: 1;
  font-size: 15px !important;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.premium-room .room-status {
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
  font-size: 11px !important;
  white-space: nowrap;
}

.premium-room .room-owner {
  grid-column: 1;
  grid-row: 2;
  align-self: start;
  font-size: 12px !important;
  margin-top: -4px;
}

.premium-room .room-details {
  grid-column: 1;
  grid-row: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 5px !important;
}

.premium-room .room-tag {
  padding: 6px 7px !important;
  font-size: 10px !important;
  white-space: nowrap;
}

.premium-room .join-room {
  grid-column: 2;
  grid-row: 2 / 4;
  align-self: end;
  width: 100% !important;
  min-height: 42px !important;
  padding: 7px !important;
  font-size: 12px !important;
  border-radius: 10px !important;
}

.premium-room:has(.delete-room) {
  border-color: #e9b84e !important;
  box-shadow: 0 0 13px rgba(232, 175, 55, 0.18) !important;
}

@media (max-width: 390px) {
  .premium-room {
    grid-template-columns: minmax(0, 1fr) 125px;
  }

  .premium-room .room-tag {
    font-size: 9px !important;
    padding: 5px !important;
  }
}

/* Золотая шапка в стиле утверждённого макета */





















/* Шаг 251: точная настройка компактной шапки */


















/* Единая шапка лобби */
.header {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  height: 52px;
  min-height: 52px;
  padding: 5px 8px 0;
  border-bottom: 1px solid rgba(224,188,112,.25);
  overflow: hidden;
  background: radial-gradient(ellipse at 72% 100%, rgba(205,148,43,.19), transparent 60%);
}
.brand {
  position: relative;
  z-index: 2;
  padding-top: 0;
}
.brand .logo {
  color: #f3c66a;
  font-size: clamp(15px, 4vw, 19px);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: .2px;
  white-space: nowrap;
  transform: none;
}
.brand-subtitle {
  margin-top: 3px;
  padding-left: 17px;
  color: #e7bf77;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 1px;
  white-space: nowrap;
}
.header-cards {
  position: absolute;
  right: 112px;
  bottom: 2px;
  width: 58px;
  height: 51px;
  pointer-events: none;
  opacity: .85;
}
.header-card {
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 32px;
  height: 46px;
  padding: 5px;
  border: 2px solid #d8ad55;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 0 17px rgba(227,171,67,.2);
}
.header-card span {
  font-size: 15px;
  align-self: center;
}
.header-card-black {
  left: 0;
  top: 5px;
  transform: rotate(-20deg);
  color: #e9bb65;
  background: #111722;
}
.header-card-red {
  left: 21px;
  top: 10px;
  transform: rotate(17deg);
  color: #b92837;
  background: #f2e8d5;
}
.header .profile-trigger {
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  margin-top: 0;
}

/* Единый размер кнопок в списке столов */
.rooms-list .room .join-room,
.rooms-list .room .play-room,
.rooms-list .room .watch-room {
  box-sizing: border-box;
  width: 132px;
  min-width: 132px;
  height: 48px;
  min-height: 48px;
  padding: 0 10px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
}

/* Компактные одинаковые кнопки столов */
.rooms-list .room .join-room,
.rooms-list .room .play-room,
.rooms-list .room .watch-room {
  box-sizing: border-box;
  width: 108px;
  min-width: 108px;
  max-width: 108px;
  height: 42px;
  min-height: 42px;
  padding: 0 8px;
  flex: 0 0 108px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
}

/* Экран ожидания за игровым столом */
.room-screen {
  min-height: 100dvh;
  padding: 18px 16px 32px;
  box-sizing: border-box;
  background: linear-gradient(180deg, #101b30, #080d17);
  color: #f6e8c2;
}

.room-screen[hidden] {
  display: none !important;
}

.room-screen-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
}

.room-screen-header strong {
  font-size: 19px;
  color: #f3d38b;
}

#roomBack {
  padding: 10px 14px;
  border: 1px solid #a88749;
  border-radius: 12px;
  background: #17243a;
  color: #f3d38b;
  font-size: 14px;
}

.room-screen-table {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-around;
  gap: 28px;
  min-height: 420px;
  padding: 25px 15px;
  border: 7px solid #64451f;
  border-radius: 90px;
  background: radial-gradient(ellipse, #196c46, #06412b);
  box-shadow: inset 0 0 0 3px #c49a50, 0 15px 35px #0008;
  text-align: center;
}

.room-screen-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  font-size: 14px;
}

.room-screen-player strong {
  color: #fff4d6;
  font-size: 17px;
}

.room-screen-player span {
  color: #d3e9d9;
}

.room-screen-avatar {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border: 2px solid #e0bd70;
  border-radius: 50%;
  background: #15253b;
  color: #f0cd80;
  font-size: 30px;
}

.room-screen-center {
  color: #fff6df;
}

.room-screen-cards {
  font-size: 42px;
  letter-spacing: 4px;
}

#roomCountdown {
  margin-top: 12px;
  color: #ffdf88;
  font-size: 22px;
  font-weight: 700;
}

.room-screen-settings {
  margin: 20px 0;
  padding: 14px;
  border: 1px solid #79613c;
  border-radius: 12px;
  background: #17243a;
  color: #e8d5ac;
  text-align: center;
}

#roomJoinButton,
#roomDeleteButton {
  display: block;
  width: 100%;
  margin-top: 12px;
  min-height: 48px;
}

#roomJoinButton[hidden],
#roomDeleteButton[hidden],
#roomCountdown[hidden] {
  display: none !important;
}

/* Подтверждение начала партии на экране ожидания */
.room-confirmation-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.room-confirmation-actions[hidden] {
  display: none !important;
}

#roomConfirmStart,
#roomConfirmDecline {
  width: 100%;
  min-height: 50px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

#roomConfirmStart {
  border: 1px solid #f0cd80;
  background: linear-gradient(180deg, #f1d38c, #bd8c3b);
  color: #172033;
}

#roomConfirmDecline {
  border: 1px solid #8b6d53;
  background: #1c293b;
  color: #f1d7bb;
}

#roomConfirmStart:disabled,
#roomConfirmDecline:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.premium-room .join-room { background: linear-gradient(135deg,#ffe49a,#d69a35) !important; border: 1px solid #f6d078 !important; color: #17130c !important; }

.room-filters{display:flex;gap:8px;overflow-x:auto;padding:12px 0 16px;scrollbar-width:none}.room-filters::-webkit-scrollbar{display:none}.room-filters button{flex:0 0 auto;padding:11px 13px;border:1px solid #394768;border-radius:12px;background:#17233c;color:#e3e9f5;font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap}.room-filters button.active{background:linear-gradient(135deg,#ffe39a,#d69a35);border-color:#f6d078;color:#17130c;box-shadow:0 3px 14px #d69a3533}

.tables-heading{display:flex;flex-direction:column;align-items:stretch;gap:14px}.tables-heading>div{width:100%}.tables-heading .create-trigger{width:100%;min-height:52px;padding:14px 18px;border:1px solid #f6d078;border-radius:14px;background:linear-gradient(135deg,#ffe49a,#d69a35);color:#17130c;font-size:16px;font-weight:800;box-shadow:0 5px 18px #d69a3533}

.room-bottom-actions{display:flex;gap:8px;margin:12px 0 8px;padding:9px;background:#07141e;border:1px solid #9c7830;border-radius:12px}.room-bottom-actions button{flex:1;min-width:0;padding:12px 6px;border:1px solid #365060;border-radius:8px;background:#10232e;color:#e7edf0;font-size:13px;font-weight:600}.room-bottom-actions #roomExitButton{border-color:#66343b;color:#f2dfe1}

.table-chat[hidden]{display:none}.table-chat{position:fixed;left:12px;right:12px;bottom:12px;z-index:1000;max-width:440px;margin:auto;background:#091923;border:1px solid #b89448;border-radius:14px;box-shadow:0 8px 35px #000b;color:#f4ebd6;overflow:hidden}.table-chat-header{display:flex;align-items:center;justify-content:space-between;padding:13px 15px;background:#10232e;border-bottom:1px solid #8d7139}.table-chat-header button{background:transparent;border:0;color:#e7edf0;font-size:20px}.table-chat-messages{height:230px;overflow-y:auto;padding:12px;display:flex;flex-direction:column;gap:9px}.table-chat-message{background:#142b36;border:1px solid #304653;border-radius:10px;padding:8px 10px;overflow-wrap:anywhere;font-size:13px}.table-chat-message strong{display:block;color:#d5b56e;margin-bottom:4px}.table-chat-form{display:flex;gap:8px;padding:10px;border-top:1px solid #304653}.table-chat-form input{flex:1;min-width:0;padding:11px;border-radius:8px;background:#07141e;color:white;border:1px solid #49616c}.table-chat-form button{padding:9px 15px;background:#b89448;border:0;border-radius:8px;color:#091923;font-size:18px}.table-chat-reactions{display:flex;justify-content:center;gap:12px;padding:12px}.table-chat-reactions[hidden]{display:none}.table-chat-reactions button{font-size:23px;padding:8px;background:#142b36;border:1px solid #8d7139;border-radius:9px}

.table-chat-message{position:relative;cursor:pointer}.reaction-picker[hidden]{display:none}.reaction-picker:not([hidden]){display:flex;position:absolute;bottom:calc(100% + 5px);left:8px;z-index:20;gap:6px;padding:7px;background:#10232e;border:1px solid #b89448;border-radius:12px;box-shadow:0 5px 18px #0009}.reaction-picker button{font-size:23px;padding:6px 9px;background:transparent;border:0;border-radius:8px;cursor:pointer}.reaction-picker button:active{background:#304653}.message-reactions:not(:empty){display:flex;flex-wrap:wrap;gap:5px;margin-top:6px}.message-reactions span{padding:3px 7px;border-radius:12px;background:#233d49;color:#f4ebd6;font-size:12px}

.table-chat-form[hidden]{display:none!important}

.table-chat-readonly[hidden]{display:none!important}.table-chat-readonly{padding:13px;text-align:center;background:#10232e;color:#d5b56e;border-top:1px solid #8d7139;font-size:13px;font-weight:600}

.reaction-picker.reaction-picker-below:not([hidden]){bottom:auto;top:calc(100% + 5px)}

.room-bottom-actions[hidden] { display: none !important; }

/* Редактирование игрового профиля */
.profile-edit-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  max-width: 290px;
  margin: 12px auto 18px;
}

.profile-edit-controls button {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid #c9a65c;
  border-radius: 12px;
  background: #102b37;
  color: #f6e8c2;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.profile-edit-controls button:active {
  background: #1d4350;
}

#profileNameEditor:not([hidden]) {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#profileNameInput {
  box-sizing: border-box;
  width: 100%;
  padding: 11px 12px;
  border: 1px solid #c9a65c;
  border-radius: 10px;
  background: #071b26;
  color: #ffffff;
  font-size: 16px;
}

#profileDeleteAvatar {
  border-color: #9c6868;
  color: #f0b4b4;
}


/* GameHub: кошелёк игровых монет */
.coin-wallet {
  box-sizing: border-box;
  width: 100%;
  margin: 18px auto;
  padding: 18px;
  border: 1px solid #b89448;
  border-radius: 16px;
  background: linear-gradient(145deg, #102b37, #091923);
  color: #f4ebd6;
  box-shadow: 0 8px 24px #0005;
}
.coin-wallet h3 {
  margin: 0 0 16px;
  color: #f1d38c;
  font-size: 18px;
  text-align: center;
}
.coin-wallet-balance {
  padding: 16px;
  border: 1px solid #725e37;
  border-radius: 12px;
  background: #071b26;
  text-align: center;
}
.coin-wallet-balance small {
  display: block;
  margin-bottom: 8px;
  color: #bfcbd0;
  font-size: 13px;
}
.coin-wallet-balance strong {
  display: block;
  color: #ffe49a;
  font-size: 30px;
  overflow-wrap: anywhere;
}
.coin-wallet-details {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 16px 0;
  font-size: 13px;
}
.coin-wallet-details span { flex: 1; }
.coin-wallet-details b { color: #ffe49a; }
.coin-wallet-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.coin-wallet-actions button {
  min-width: 0;
  padding: 12px 5px;
  border: 1px solid #c9a65c;
  border-radius: 10px;
  background: #173443;
  color: #f6e8c2;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.coin-wallet-actions button:disabled {
  opacity: .45;
  cursor: not-allowed;
}
#coinWallet #walletHistory:not([hidden]) {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid #365060;
  border-radius: 10px;
  background: #071b26;
  font-size: 13px;
}
@media (max-width: 360px) {
  .coin-wallet { padding: 12px; }
  .coin-wallet-details { flex-direction: column; }
}


/* GameHub: настройки профиля под шестерёнкой */
.profile-top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.profile-settings-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(245,203,120,.38);
  border-radius: 12px;
  background: #102b37;
  color: #f5cb78;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.profile-settings-button:active,
.profile-settings-button[aria-expanded="true"] {
  background: #24404a;
  border-color: #f5cb78;
}

.profile-settings[hidden] {
  display: none !important;
}

.profile-settings {
  box-sizing: border-box;
  width: 100%;
  margin: 16px auto 20px;
  padding: 18px 14px;
  border: 1px solid rgba(245,203,120,.25);
  border-radius: 18px;
  background: linear-gradient(160deg,#182d38,#101b29);
  text-align: center;
}

.profile-settings h3 {
  margin: 0 0 12px;
  color: #f5cb78;
  font-size: 17px;
  font-weight: 700;
}

.profile-settings .profile-edit-controls {
  margin: 12px auto 18px;
}

.profile-settings #languageLabel {
  display: block;
  margin-bottom: 9px;
  color: #e5d6b7;
  font-size: 13px;
}

/* GameHub: крупные суммы кошелька */
.coin-wallet-rate {
  margin: -5px 0 18px;
  color: #c7d2d8;
  font-size: 14px;
  text-align: center;
}
.coin-wallet-details {
  align-items: center;
  font-size: 17px;
}
.coin-wallet-details span {
  min-width: 0;
  line-height: 1.5;
}
.coin-wallet-details b {
  font-size: 23px;
  font-weight: 800;
  color: #ffe49a;
}
@media (max-width: 360px) {
  .coin-wallet-details { align-items: stretch; }
}
