/* Amerikano: genel ve masa stilleri. Menu / kariyer / form stilleri Poker'den gelir (css/poker-ui.css). */
:root {
  --felt: #12402c; --felt2: #0c2e1f; --ink: #f4f1e8; --card: #fbf8ef;
  --red: #c0392b; --black: #1d1d1d; --sel: #ffd54a; --bad: #ff8a80;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: radial-gradient(circle at 50% 0%, #0f2a1d, #0b1f16); color: var(--ink); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }

/* Menu ekranlari (Poker gibi koyu zemin, ortada dar kolon) */
.screen { min-height: 100dvh; padding: calc(10px + env(safe-area-inset-top)) 14px calc(24px + env(safe-area-inset-bottom)); }
.screen-inner { padding-top: 6px; }
.screen[data-screen="table"] { display: flex; flex-direction: column; height: 100dvh; min-height: 0; padding: env(safe-area-inset-top) 8px env(safe-area-inset-bottom); background: radial-gradient(ellipse at center, var(--felt), var(--felt2)); overflow: hidden; }

/* Genel dugme (masa dugmeleri); menulerde .btn kullanilir */
button { font: inherit; padding: 9px 14px; border: 0; border-radius: 10px; background: var(--gold); color: #1c1500; font-weight: 700; cursor: pointer; }
button:disabled { opacity: .4; cursor: default; }
button.ghost { background: #fff2; color: var(--ink); }
button.small { padding: 4px 10px; font-size: 13px; }
.lang-top { display: flex; justify-content: flex-end; padding: 4px 0 6px; }
.lang-top select { background: var(--bg-0); color: var(--text); border: 1px solid var(--card-border); border-radius: 10px; padding: 8px 10px; font-size: 14px; max-width: 70%; }
.brand { font-weight: 700; color: var(--gold); }

/* Poker'in sol ustteki Garden Lantern donus dugmesine yer birak (js/portal-back.js) */
html:not(.on-home) #portalBackBtn { display: none !important; }
.on-home.has-portal-back .screen-inner { padding-top: 40px; }
.has-portal-back .lang-top { padding-left: 0; }

/* ---------- Masa ---------- */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 6px 4px; gap: 8px; min-height: 48px; }
.hand-title { font-size: 15px; display: flex; align-items: center; gap: 8px; min-width: 0; flex: 1 1 auto; line-height: 1.25; } .hand-title b { color: var(--gold); } #hand-rule { font-weight: 700; }
#table-flag { flex: none; height: 22px; width: 33px; object-fit: contain; border-radius: 2px; box-shadow: 0 1px 3px #0008; } /* sabit boyut: yuklenirken baslik genisligi oynamasin */

.felt { position: relative; flex: 1; min-height: 0; }
#seats { position: absolute; inset: 0; pointer-events: none; }
.seat { position: absolute; width: 84px; transform: translateX(-50%); text-align: center; font-size: 11px; background: #0007; border: 2px solid #fff1; border-radius: 12px; padding: 14px 3px 3px; pointer-events: auto; }
.seat .av { position: absolute; top: -16px; left: 50%; transform: translateX(-50%); width: 34px; height: 34px; border-radius: 50%; background: #123524; border: 2px solid #e3b34188; display: flex; align-items: center; justify-content: center; font-size: 20px; line-height: 1; }
.seat .nm { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 4px; }
.seat .nm i { font-style: normal; font-weight: 500; opacity: .75; }
.seat .pn { color: #ffb4a8; min-height: 13px; }
.seat .pn.has { font-weight: 700; }
.seat .ct { opacity: .9; }
.seat .ok { color: #8be78b; }
.seat.active { border-color: var(--gold); box-shadow: 0 0 10px #e3b34166; }
.turn-arrow { position: absolute; top: -34px; left: 50%; transform: translateX(-50%); color: var(--gold); font-size: 16px; line-height: 1; animation: arrow-bob .9s ease-in-out infinite; text-shadow: 0 1px 4px #000; pointer-events: none; }
@keyframes arrow-bob { 0%, 100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 5px); } }

.center-stack { position: absolute; inset: calc(4% + 118px) 90px 2px 90px; display: flex; flex-direction: column; min-height: 0; gap: 3px; }
.piles { display: flex; justify-content: center; gap: 22px; align-items: center; padding-bottom: 12px; flex: 0 0 auto; }
.pile { width: 56px; height: 80px; border-radius: 8px; position: relative; display: flex; align-items: center; justify-content: center; font-size: 13px; }
.pile.stock { background: repeating-linear-gradient(45deg, #1e4f9c, #1e4f9c 6px, #1a4388 6px, #1a4388 12px); border: 2px solid #fff6; color: #fff; cursor: pointer; padding: 0; }
.pile.discard { border: 2px dashed #fff4; cursor: pointer; }
.pile.discard > span { position: absolute; bottom: -17px; font-size: 11px; opacity: .8; }
.pile.stock span { background: #0008; border-radius: 8px; padding: 1px 7px; }
.pile.can { box-shadow: 0 0 0 3px var(--sel); }

/* Kimin ne yaptigi: her oyuncuya bir satir; o oyuncu kendi sirasinda yeniden oynayana kadar kalir */
.turnlog { font-size: 11px; line-height: 1.35; flex: 0 0 auto; max-height: 38%; overflow-y: auto; }
.turnlog .tl-row { display: flex; justify-content: center; gap: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: .92; }
.turnlog .tl-row b { color: var(--gold); flex: 0 0 auto; max-width: 42%; overflow: hidden; text-overflow: ellipsis; }
.turnlog .tl-row span { overflow: hidden; text-overflow: ellipsis; }

.melds-area { flex: 1; min-height: 40px; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; margin-top: 3px; }
.owner-row { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.owner-row .on { font-size: 10px; opacity: .75; min-width: 40px; max-width: 60px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.meld { display: flex; background: #0004; border: 2px solid transparent; border-radius: 8px; padding: 3px; position: relative; }
.meld.mine { border-color: #e3b34155; }
.meld.target:hover { border-color: var(--sel); cursor: pointer; }
.meld .c { margin-left: -8px; } .meld .c:first-child { margin-left: 0; }
.meld .c.joker { cursor: pointer; }
.meld .rep { position: absolute; bottom: -2px; right: 2px; font-size: 9px; color: var(--gold); }
/* Artik islenemeyen (kapanmis) dizilimin kartlari solar */
.meld.dead .c { opacity: .42; }

/* ---------- Kartlar ---------- */
.c { width: 44px; height: 62px; background: var(--card); color: var(--black); border-radius: 6px; border: 1px solid #0003; display: inline-block; font-weight: 700; line-height: 1; user-select: none; box-shadow: 0 1px 3px #0006; position: relative; overflow: hidden; }
.c .r { position: absolute; left: 4px; top: 3px; font-size: 22px; letter-spacing: -1px; }
.c .s { position: absolute; left: 5px; top: 28px; font-size: 14px; }
.c .m { position: absolute; right: 4px; bottom: 3px; font-size: 20px; }
.c.red { color: var(--red); }
.c.cb0 { color: #167a3d; } .c.cb1 { color: #1a1a1a; } .c.cb2 { color: #c0293a; } .c.cb3 { color: #1d6fd6; } /* renk kory: sinek yesil, maca siyah, kupa kirmizi, karo mavi */
.pile.stock span.round { position: absolute; bottom: -17px; left: 0; right: 0; background: none; padding: 0; font-size: 11px; opacity: .85; }
.c.joker { color: #6a1b9a; font-size: 11px; background: linear-gradient(135deg, #fbf8ef, #f3d9ff); display: inline-flex; align-items: center; justify-content: center; }
.pile .c { width: 54px; height: 78px; }
.pile .c .r { font-size: 27px; top: 4px; left: 5px; } .pile .c .s { font-size: 17px; top: 35px; } .pile .c .m { font-size: 25px; }
.staged .grp .c { width: 34px; height: 48px; }
.staged .grp .c .r { font-size: 16px; top: 2px; left: 3px; } .staged .grp .c .s { font-size: 10px; top: 20px; left: 3px; } .staged .grp .c .m { font-size: 14px; }

.status { text-align: center; min-height: 20px; font-size: 14px; padding: 2px 4px; }
.status.err { color: var(--bad); }
.claimbar { display: flex; gap: 8px; justify-content: center; padding: 4px 0; flex-wrap: wrap; }
.staged { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; min-height: 0; padding: 2px; }
.staged .grp { display: flex; background: #0006; border: 1px dashed var(--gold); border-radius: 8px; padding: 3px; cursor: pointer; }
.staged .grp .c { margin-left: -12px; } .staged .grp .c:first-child { margin-left: 0; }

/* Benim koltugum: avatar, ad (toplam puan), bu eldeki ceza */
.me-strip { position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 6px 0; font-size: 13px; }
.me-strip .av { width: 32px; height: 32px; border-radius: 50%; background: #123524; border: 2px solid #e3b34188; display: flex; align-items: center; justify-content: center; font-size: 19px; }
.me-strip.active .av { border-color: var(--gold); box-shadow: 0 0 10px #e3b34188; }
.me-strip .nm { font-weight: 700; } .me-strip .nm i { font-style: normal; font-weight: 500; opacity: .75; }
.me-strip .pn { color: #ffb4a8; } .me-strip .pn.has { font-weight: 700; }
.me-strip .turn-arrow { top: -4px; left: calc(50% - 74px); }

.hand { display: flex; justify-content: center; flex-wrap: wrap; gap: 2px; padding: 10px 2px 4px; min-height: 84px; }
.hand .c { margin-left: -12px; cursor: pointer; transition: transform .08s; }
.hand .c:first-child { margin-left: 0; }
.hand .c.sel { transform: translateY(-14px); outline: 3px solid var(--sel); z-index: 2; }
/* Yeni gelen kart (desteden ya da yerden): tek bakista gorunsun */
.hand .c.fresh { outline: 2px solid #f2c230; outline-offset: -2px; box-shadow: 0 0 4px #f2c230; z-index: 1; }
.hand .c.fresh.sel { transform: translateY(-14px); }
.actions { display: flex; gap: 6px; justify-content: center; padding: 6px 0 10px; flex-wrap: wrap; }

/* Kartin ucusu: oyuncudan yere, yerden oyuncuya */
.fly-card { position: fixed; z-index: 80; pointer-events: none; margin: 0; }
.fly-card.back { border-radius: 6px; border: 2px solid #fff6; background: repeating-linear-gradient(45deg, #1e4f9c, #1e4f9c 6px, #1a4388 6px, #1a4388 12px); box-shadow: 0 2px 6px #0008; }

/* ---------- Ust katmanlar ---------- */
.overlay { position: fixed; inset: 0; background: #000b; display: flex; align-items: center; justify-content: center; padding: 14px; z-index: 100; }
.card-box { background: #17261d; border: 1px solid #fff3; border-radius: 14px; padding: 18px; max-width: 480px; width: 100%; max-height: 90dvh; overflow: auto; }
.card-box h2 { margin: 0 0 10px; color: var(--gold); }
.card-box h3 { margin: 14px 0 4px; font-size: 15px; color: var(--ink); }
.card-box .fine { margin: 0 0 6px; font-size: 12px; opacity: .7; }
.card-box .opts { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.card-box .vol { display: flex; align-items: center; gap: 8px; margin: 6px 0 10px; }
.card-box select { background: var(--bg-0); color: var(--text); border: 1px solid var(--card-border); border-radius: 10px; padding: 8px 10px; font-size: 14px; }
.card-box table { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.card-box td, .card-box th { padding: 4px 6px; text-align: right; border-bottom: 1px solid #fff2; }
.card-box td:first-child, .card-box th:first-child { text-align: left; }
.card-box tr.win td { color: var(--gold); font-weight: 700; }
button.danger { color: var(--bad); }
.account-box { margin-top: 6px; }
.legal-link { color: var(--gold); }
.home-disclaimer a { color: var(--gold); }
@media (max-width: 520px) {
  .c { width: 40px; height: 57px; } .c .r { font-size: 20px; } .c .s { font-size: 12px; top: 26px; } .c .m { font-size: 17px; }
  .hand .c { margin-left: -14px; } .meld .c { margin-left: -10px; }
  .seat { width: 76px; font-size: 10px; }
  .center-stack { inset: 70px 82px 2px 82px; }
}

/* ---------- Reklam arasi (interlude.js) ---------- */
#breakOverlay { position: fixed; z-index: 1500; }
#breakSkipBtn { margin-top: 8px; }
.break-card { position: relative; display: flex; flex-direction: column; gap: 10px; width: min(94vw, 1100px); max-width: none; height: min(88vh, 900px); }
.break-card .break-slot { flex: 1; min-height: 0; }
.break-x { position: fixed; top: calc(12px + env(safe-area-inset-top, 0px)); right: 12px; width: 44px; height: 44px; padding: 0; border-radius: 50%; border: 2px solid #fff; background: #d32f2f; color: #fff; font-size: 20px; font-weight: 700; line-height: 1; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .5); z-index: 1; }
.break-x:hover, .break-x:focus-visible { background: #b71c1c; }
.break-slot { display: flex; align-items: center; justify-content: center; min-height: 220px; border: 2px dashed #e3b34188; border-radius: 10px; background: #e3b3410f; font-size: 16px; font-weight: 600; }

/* ---------- Kazaninca yagan "Küt" kartlari (mac sonu) ---------- */
.chip-rain { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 120; }
.chip-rain-chip { position: absolute; top: -90px; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.45)); animation-name: chip-fall; animation-timing-function: cubic-bezier(0.35, 0.1, 0.7, 1); animation-fill-mode: both; }
@keyframes chip-fall {
  0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  85% { opacity: 1; }
  100% { transform: translate(var(--drift), 115vh) rotate(var(--spin)); opacity: 0; }
}

.hand .c { touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.hand .c.dragging { cursor: grabbing; box-shadow: 0 6px 14px #0009; }

/* Olu (uzerine kart islenemeyen) diziliserin tek kartlik soluk satiri */
.c.dead { opacity: .38; filter: grayscale(.5); pointer-events: none; display: inline-block; vertical-align: top; margin: 0 0 4px 3px; }
.seat .info { min-width: 0; }
.seat .sub { display: block; }

/* ---------- Telefon: oyuncular solda alt alta, ortada deste/yer, acilan kartlar sagda; hamle satirlari yok ---------- */
/* ---------- Masa yerlesimi (web ve telefon): oyuncular solda alt alta, altlarinda hamle satirlari, kalan alan acilan kartlar ---------- */
.felt { display: block; overflow-y: auto; }
#seats { position: relative; inset: auto; float: left; width: 200px; padding: 6px 0 6px 6px; display: flex; flex-direction: column; gap: 6px; }
.seat { position: relative; left: auto !important; top: auto !important; transform: none; width: auto; display: flex; align-items: center; gap: 8px; text-align: left; padding: 4px 8px 4px 6px; font-size: 13px; border-radius: 10px; }
.seat .av { position: static; transform: none; flex: none; width: 34px; height: 34px; font-size: 20px; }
.seat .nm { margin-top: 0; }
.seat .sub { display: flex; gap: 8px; white-space: nowrap; }
.seat .turn-arrow { top: 50%; left: -14px; animation: none; transform: translateY(-50%) rotate(-90deg); }
.center-stack { display: contents; }
.piles { float: right; display: flex; align-items: flex-start; gap: 16px; margin: 0 10px 8px 8px; padding: 6px 0 14px; }
.turnlog { float: left; clear: left; width: 200px; max-height: none; overflow: visible; padding: 4px 8px; font-size: 12px; }
.turnlog .tl-row { justify-content: flex-start; }
.melds-area { display: block; overflow: visible; flex: none; padding: 4px 10px 0 0; text-align: right; }
.c.dead { width: 30px; height: 43px; }
.c.dead .r { font-size: 15px; left: 3px; } .c.dead .s { font-size: 9px; top: 19px; left: 3px; } .c.dead .m { font-size: 12px; }
.meld { display: inline-flex; vertical-align: top; margin: 0 0 6px 8px; }

@media (max-width: 600px), (orientation: landscape) and (max-height: 600px) {
  .turnlog { display: none; }
  /* Oyuncu kutulari solda yuzer; acilan kartlar yaninda akar, yana sigmayan (uzun) dizilis oyuncu kutularinin bittigi yerden tam genislikte devam eder */
  .felt { display: block; overflow-y: auto; }
  #seats { position: relative; inset: auto; float: left; width: 150px; padding: 4px 0 4px 4px; display: flex; flex-direction: column; gap: 5px; }
  .seat { position: relative; left: auto !important; top: auto !important; transform: none; width: auto; display: flex; align-items: center; gap: 6px; text-align: left; padding: 3px 6px 3px 4px; font-size: 11px; border-radius: 10px; }
  .seat .av { position: static; transform: none; flex: none; width: 28px; height: 28px; font-size: 17px; }
  .seat .nm { margin-top: 0; }
  .seat .sub { display: flex; gap: 6px; white-space: nowrap; }
  .seat .turn-arrow { top: 50%; left: -13px; animation: none; transform: translateY(-50%) rotate(-90deg); }
  .center-stack { display: contents; }
  .piles { gap: 12px; margin: 0 6px 6px 6px; padding: 4px 0 14px; }
  .pile { width: 46px; height: 66px; }
  .pile .c { width: 42px; height: 60px; } .pile .c .r { font-size: 21px; top: 3px; left: 4px; } .pile .c .s { font-size: 13px; top: 27px; } .pile .c .m { font-size: 19px; }
  .melds-area { display: block; overflow: visible; flex: none; padding: 4px 6px 0 0; text-align: right; }
  .meld { display: inline-flex; vertical-align: top; margin: 0 0 4px 6px; }
  .meld .c { width: 26px; height: 37px; margin-left: -9px; } .meld .c .r { font-size: 13px; left: 3px; } .meld .c .s { font-size: 8px; top: 17px; left: 3px; } .meld .c .m { font-size: 11px; }
  .c.dead { width: 24px; height: 34px; } .c.dead .r { font-size: 12px; left: 3px; } .c.dead .s { font-size: 8px; top: 16px; left: 3px; } .c.dead .m { font-size: 10px; }
}

.pile.discard.locked { opacity: .55; cursor: not-allowed; }
.pile.discard.locked::after { content: "🔒"; position: absolute; top: 4px; right: 4px; font-size: 16px; }

#customList { max-height: 52dvh; }

.lang-field select { width: 100%; }

/* Joker hangi kart icin? penceresi */
.joker-choice { display: flex; justify-content: center; gap: 28px; margin: 14px 0 18px; }
.joker-choice-btn { background: none; border: 2px solid #fff3; border-radius: 12px; padding: 10px; cursor: pointer; }
.joker-choice-btn:hover, .joker-choice-btn:focus-visible { border-color: var(--sel); }
.joker-choice-btn .c { width: 84px; height: 120px; }
.joker-choice-btn .c .r { font-size: 42px; top: 8px; left: 9px; } .joker-choice-btn .c .s { font-size: 26px; top: 56px; left: 10px; } .joker-choice-btn .c .m { font-size: 38px; right: 9px; bottom: 7px; }

/* Ana sayfa dugmesi: yalniz simge, rahat basilacak buyuklukte */
.home-btn { flex: none; width: 52px; height: 44px; padding: 0; border: 1px solid #fff3; border-radius: 12px; background: #ffffff14; color: var(--ink); font-size: 24px; line-height: 1; cursor: pointer; }
.home-btn:active { background: #ffffff30; }

/* ---------- Yatay telefon (kisa ekran), 2026-10-25 yerlesim: ----------
   ust satir: baslik | deste + yerdeki kart | ana sayfa; orta: oyuncu isimleri (soldaki sutun) + yerde acilan kartlar;
   alt satir: el (2 sira) | dugmeler | gruplanan kartlar. Hicbir yerde kaydirma yok: kartlar alana gore kuculur (table-ui.js fitLandscape). */
@media (orientation: landscape) and (max-height: 600px) {
  .screen[data-screen="table"] {
    --bot: 34dvh;
    display: grid;
    grid-template-columns: clamp(135px, 17vw, 200px) minmax(0, 1fr) clamp(140px, 17vw, 210px) clamp(150px, 24vw, 300px);
    grid-template-rows: auto minmax(0, 1fr) auto var(--bot);
    column-gap: 6px; row-gap: 3px;
    padding: env(safe-area-inset-top) 6px 3px;
    overflow: hidden;
  }
  .topbar, .felt, .center-stack { display: contents; }
  .turnlog { display: none; }
  .hand-title { grid-area: 1 / 1 / 2 / 3; font-size: 13px; align-self: center; min-width: 0; }
  .home-btn { grid-area: 1 / 4 / 2 / 5; justify-self: end; align-self: center; width: 46px; height: 40px; }
  .piles { grid-area: 1 / 3 / 2 / 5; justify-self: end; margin: 0 56px 0 0; padding: 2px 0 16px; gap: 12px; align-items: center; float: none; }
  .pile { width: 40px; height: 56px; }
  .pile .c { width: 36px; height: 52px; } .pile .c .r { font-size: 18px; top: 3px; left: 3px; } .pile .c .s { font-size: 11px; top: 23px; } .pile .c .m { font-size: 16px; }
  /* 1/3 (deste turu) ve yerdeki kart sayisi kartin altinda yazilir; destedeki kart sayisi destenin ustunde kalir */
  .pile.discard > span, .pile.stock span.round { bottom: -15px; left: 0; right: 0; background: none; padding: 0; font-size: 11px; opacity: .9; text-align: center; }
  .pile.stock > span:not(.round) { position: absolute; top: 3px; padding: 0 5px; font-size: 12px; }

  #seats { grid-area: 2 / 1 / 3 / 2; width: auto; float: none; padding: 2px 0 0 4px; gap: 3px; align-self: start; min-height: 0; }
  .screen[data-screen="table"] .seat { padding: 1px 4px 1px 3px; font-size: 10px; gap: 4px; min-width: 0; overflow: hidden; }
  .screen[data-screen="table"] .seat .av { width: 22px; height: 22px; font-size: 14px; }
  .screen[data-screen="table"] .seat { border-width: 1px; line-height: 1.1; }
  .screen[data-screen="table"] .seat .pn { min-height: 0; }
  .screen[data-screen="table"] .seat .info { min-width: 0; flex: 1 1 auto; }
  .screen[data-screen="table"] .seat .nm { font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .screen[data-screen="table"] .seat .sub { flex-wrap: wrap; gap: 0 5px; white-space: normal; font-size: 9px; line-height: 1.25; }

  .dead-row { grid-area: 1 / 2 / 2 / 5; display: flex; align-items: center; justify-content: flex-end; justify-self: end; min-width: 0; max-width: calc(100% - 160px); overflow: hidden; margin-right: 160px; padding: 2px 6px 2px 0; }
  .dead-row .c.dead { width: 30px; height: 43px; margin: 0 0 0 -9px; }
  .dead-row .c.dead:first-child { margin-left: 0; }
  .dead-row .c.dead .r { font-size: 15px; left: 3px; } .dead-row .c.dead .s { font-size: 9px; top: 19px; left: 3px; } .dead-row .c.dead .m { font-size: 12px; }
  .melds-area { grid-area: 2 / 2 / 3 / 5; overflow: hidden; padding: 2px 4px 0 0; min-height: 0; text-align: left; }
  .meld { margin: 0 6px 5px 0; }
  .meld .c { width: var(--mw, 30px); height: calc(var(--mw, 30px) * 1.41); margin-left: calc(var(--mw, 30px) * -.3); }
  .meld .c:first-child { margin-left: 0; }
  .meld .c .r { font-size: calc(var(--mw, 30px) * .5); left: calc(var(--mw, 30px) * .09); top: calc(var(--mw, 30px) * .06); }
  .meld .c .s { font-size: calc(var(--mw, 30px) * .32); left: calc(var(--mw, 30px) * .1); top: calc(var(--mw, 30px) * .62); }
  .meld .c .m { font-size: calc(var(--mw, 30px) * .45); right: calc(var(--mw, 30px) * .09); bottom: calc(var(--mw, 30px) * .06); }
  .c.dead { width: calc(var(--mw, 30px) * .9); height: calc(var(--mw, 30px) * 1.27); }
  .c.dead .r { font-size: calc(var(--mw, 30px) * .45); } .c.dead .s { font-size: calc(var(--mw, 30px) * .28); top: calc(var(--mw, 30px) * .56); } .c.dead .m { font-size: calc(var(--mw, 30px) * .4); }

  .me-strip { grid-area: 3 / 1 / 4 / 3; justify-content: flex-start; padding: 0 4px 0 18px; font-size: 12px; gap: 6px; min-height: 0; }
  .me-strip .av { width: 22px; height: 22px; font-size: 14px; }
  .me-strip .turn-arrow { left: 0; top: 50%; animation: none; transform: translateY(-50%) rotate(-90deg); }
  .status { grid-area: 3 / 3 / 4 / 5; font-size: 12px; min-height: 0; padding: 0 4px; align-self: center; }
  .claimbar { grid-area: 3 / 3 / 4 / 5; z-index: 3; background: var(--felt, #0f3a28); padding: 0; flex-wrap: nowrap; align-items: center; }
  .claimbar button { padding: 4px 12px; font-size: 13px; }

  .hand { grid-area: 4 / 1 / 5 / 3; display: flex; flex-wrap: wrap; align-content: flex-start; justify-content: flex-start; gap: 3px 0; padding: 8px 4px 2px calc(var(--hw, 40px) * .3 + 6px); min-height: 0; overflow: hidden; background: #0003; border-radius: 10px; }
  .hand .c { width: var(--hw, 40px); height: calc(var(--hw, 40px) * 1.41); margin-left: calc(var(--hw, 40px) * -.3); }
  .hand .c:first-child { margin-left: 0; }
  .hand .c .r { font-size: calc(var(--hw, 40px) * .5); left: calc(var(--hw, 40px) * .09); top: calc(var(--hw, 40px) * .06); }
  .hand .c .s { font-size: calc(var(--hw, 40px) * .32); left: calc(var(--hw, 40px) * .1); top: calc(var(--hw, 40px) * .62); }
  .hand .c .m { font-size: calc(var(--hw, 40px) * .45); right: calc(var(--hw, 40px) * .09); bottom: calc(var(--hw, 40px) * .06); }
  .hand .c.sel, .hand .c.fresh.sel { transform: translateY(calc(var(--hw, 40px) * -.25)); }

  .actions { grid-area: 4 / 3 / 5 / 4; display: grid; grid-template-columns: 1fr 1fr; grid-auto-rows: 1fr; gap: 6px; padding: 0; align-content: stretch; min-height: 0; }
  .actions button { padding: 0 4px; font-size: clamp(12px, 3.6dvh, 17px); min-height: 0; min-width: 0; line-height: 1.1; }
  .actions button[hidden] { display: none; }

  .staged { grid-area: 4 / 4 / 5 / 5; display: flex; flex-wrap: wrap; align-content: flex-start; justify-content: flex-start; gap: 6px; padding: 4px; min-height: 0; overflow: hidden; background: #0003; border-radius: 10px; }
  .staged .grp .c { width: var(--sw, 30px); height: calc(var(--sw, 30px) * 1.41); margin-left: calc(var(--sw, 30px) * -.3); }
  .staged .grp .c:first-child { margin-left: 0; }
  .staged .grp .c .r { font-size: calc(var(--sw, 30px) * .5); left: calc(var(--sw, 30px) * .09); top: calc(var(--sw, 30px) * .06); }
  .staged .grp .c .s { font-size: calc(var(--sw, 30px) * .32); left: calc(var(--sw, 30px) * .1); top: calc(var(--sw, 30px) * .62); }
  .staged .grp .c .m { font-size: calc(var(--sw, 30px) * .45); right: calc(var(--sw, 30px) * .09); bottom: calc(var(--sw, 30px) * .06); }
}

.mode-pending { margin-top: 6px; color: var(--gold); font-weight: 700; font-size: 13px; }

/* Gruptaki jokerin yerini sorma penceresi: her secenek grubun o halini gosterir */
.joker-vars { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 12px 0 16px; }
.joker-var { display: flex; padding: 8px 14px 8px 8px; }
.joker-var .c { width: 44px; height: 62px; margin-left: -14px; } .joker-var .c:first-child { margin-left: 0; }
.joker-var .c .r { font-size: 20px; top: 3px; left: 4px; } .joker-var .c .s { font-size: 12px; top: 25px; left: 4px; } .joker-var .c .m { font-size: 18px; right: 4px; bottom: 2px; }

.dead-row { display: none; }
@media (orientation: landscape) and (max-height: 600px) { .dead-row { display: flex; } }
