:root{
  --bg-1:#031816;
  --bg-2:#052f2a;
  --panel:rgba(8, 34, 31, 0.84);
  --panel-strong:rgba(8, 34, 31, 0.96);
  --panel-soft:rgba(255, 255, 255, 0.08);
  --line:rgba(255, 255, 255, 0.1);
  --text:#f6f0df;
  --muted:#d5dfd7;
  --accent:#f7a81b;
  --accent-strong:#ffca67;
  --accent-ink:#1d1808;
  --shadow:0 18px 40px rgba(0, 0, 0, 0.34);
  --card-width:clamp(56px, 16vw, 82px);
  --card-overlap:clamp(12px, 3vw, 20px);
  --human-card-width:clamp(68px, 20vw, 104px);
  --human-card-overlap:clamp(20px, 5vw, 34px);
  --side-card-width:clamp(42px, 9vw, 56px);
  --side-card-overlap:clamp(12px, 2.8vw, 18px);
  --slot-width:clamp(64px, 18vw, 90px);
  --chip-radius:22px;
  --card-radius:10px;
  --safe-top:env(safe-area-inset-top, 0px);
  --safe-bottom:env(safe-area-inset-bottom, 0px);
  font-family:"Trebuchet MS", "Avenir Next", "Segoe UI", sans-serif;
  -webkit-tap-highlight-color:transparent;
}

#app[data-card-size="comfortable"]{
  --card-width:clamp(50px, 14vw, 74px);
  --card-overlap:clamp(10px, 2.4vw, 16px);
  --human-card-width:clamp(62px, 18vw, 92px);
  --human-card-overlap:clamp(16px, 4vw, 28px);
  --side-card-width:clamp(40px, 8vw, 50px);
}

#app[data-card-size="large"]{
  --card-width:clamp(56px, 16vw, 82px);
  --card-overlap:clamp(12px, 3vw, 20px);
  --human-card-width:clamp(68px, 20vw, 104px);
  --human-card-overlap:clamp(20px, 5vw, 34px);
  --side-card-width:clamp(42px, 9vw, 56px);
}

#app[data-card-size="oversized"]{
  --card-width:clamp(60px, 18vw, 90px);
  --card-overlap:clamp(14px, 3.2vw, 22px);
  --human-card-width:clamp(74px, 22vw, 116px);
  --human-card-overlap:clamp(22px, 5.4vw, 38px);
  --side-card-width:clamp(46px, 10vw, 60px);
}

#app[data-theme="midnight"]{
  --bg-1:#0b1120;
  --bg-2:#132646;
  --panel:rgba(18, 27, 49, 0.84);
  --panel-strong:rgba(18, 27, 49, 0.96);
  --panel-soft:rgba(255, 255, 255, 0.08);
  --accent:#78d0ff;
  --accent-strong:#b7ebff;
  --accent-ink:#07111b;
}

#app[data-theme="sunset"]{
  --bg-1:#25130d;
  --bg-2:#5b2510;
  --panel:rgba(52, 23, 14, 0.84);
  --panel-strong:rgba(52, 23, 14, 0.96);
  --panel-soft:rgba(255, 255, 255, 0.09);
  --accent:#ffb34d;
  --accent-strong:#ffe1a4;
  --accent-ink:#2d1609;
}

*{
  box-sizing:border-box;
}

.hidden{
  display:none !important;
}

html,
body{
  width:100%;
  height:100%;
  margin:0;
}

body{
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.08), transparent 22%),
    linear-gradient(180deg, var(--bg-2), var(--bg-1));
  color:var(--text);
}

#app{
  height:100dvh;
  min-height:0;
  display:flex;
  flex-direction:column;
  padding:calc(10px + var(--safe-top)) clamp(10px, 3vw, 22px) calc(10px + var(--safe-bottom));
  gap:12px;
  position:relative;
  overflow:hidden;
}

.topbar,
.bottom-bar,
.menu-shell,
.dialog-panel{
  border:1px solid var(--line);
  backdrop-filter:blur(16px);
}

.topbar{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
  padding:14px 16px;
  background:var(--panel);
  border-radius:26px;
  box-shadow:var(--shadow);
}

.brand{
  display:flex;
  align-items:center;
  gap:12px;
  min-width:0;
}

.brand-logo,
.menu-logo{
  display:grid;
  place-items:center;
  flex:0 0 auto;
  border-radius:16px;
  box-shadow:0 10px 24px rgba(0, 0, 0, 0.28);
}

.logo-mark{
  color:#10201c;
  background:linear-gradient(135deg, #ffdf8a, #f7a81b);
  font-family:Georgia, "Times New Roman", serif;
  font-weight:900;
  letter-spacing:0;
}

.brand-logo{
  width:44px;
  height:44px;
  font-size:1.5rem;
}

.brand-copy h1,
.menu-copy h1,
.dialog-header h2{
  margin:0;
  font-family:Georgia, "Times New Roman", serif;
  letter-spacing:0.02em;
}

.brand-copy p,
.menu-copy p,
.footer-note{
  margin:0;
}

.brand-copy p,
.player-role,
.info-chip,
.preview-chip span,
.stat-card span,
.kitty-caption,
.footer-note,
.menu-text{
  color:var(--muted);
}

.scoreboard{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:10px;
}

.score-pill,
.preview-chip,
.info-chip{
  background:var(--panel-soft);
  border:1px solid rgba(255, 255, 255, 0.06);
  border-radius:var(--chip-radius);
}

.score-pill{
  min-width:112px;
  padding:10px 14px;
  display:flex;
  flex-direction:column;
  gap:4px;
  text-align:center;
}

.score-pill span{
  font-size:0.76rem;
  color:var(--muted);
}

.score-pill strong{
  font-size:1.15rem;
}

#table-area{
  flex:1;
  min-height:0;
  display:flex;
}

#table{
  position:relative;
  flex:1;
  min-height:620px;
  border-radius:34px;
  overflow:hidden;
  padding:20px;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.04), transparent 28%),
    linear-gradient(180deg, rgba(3, 18, 16, 0.7), rgba(2, 12, 11, 0.86)),
    linear-gradient(135deg, var(--bg-2), var(--bg-1));
  box-shadow:var(--shadow);
  border:1px solid rgba(255, 255, 255, 0.08);
}

#table::before{
  content:"";
  position:absolute;
  inset:16px;
  border-radius:28px;
  border:1px solid rgba(255, 255, 255, 0.04);
  pointer-events:none;
}

.player{
  position:absolute;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:10px;
}

.player-top{
  top:18px;
  left:50%;
  transform:translateX(-50%);
}

.player-bottom{
  bottom:18px;
  left:50%;
  transform:translateX(-50%);
  width:min(calc(100% - 24px), 560px);
}

.player-left{
  left:14px;
  top:50%;
  transform:translateY(-50%);
}

.player-right{
  right:14px;
  top:50%;
  transform:translateY(-50%);
}

.player-chip{
  display:flex;
  align-items:center;
  gap:10px;
  padding:8px 12px;
  min-width:132px;
  background:rgba(0, 0, 0, 0.22);
  border-radius:18px;
  border:1px solid rgba(255, 255, 255, 0.08);
}

.avatar{
  width:38px;
  height:38px;
  border-radius:50%;
  display:grid;
  place-items:center;
  font-weight:700;
  color:var(--accent-ink);
  background:linear-gradient(135deg, var(--accent-strong), var(--accent));
  box-shadow:0 10px 22px rgba(0, 0, 0, 0.24);
}

.hero-avatar{
  width:42px;
  height:42px;
}

.player-text{
  display:flex;
  flex-direction:column;
  gap:2px;
  min-width:0;
}

.player-name{
  font-size:0.95rem;
  font-weight:700;
}

.player-role{
  font-size:0.72rem;
  letter-spacing:0.02em;
}

.hand{
  display:flex;
  align-items:flex-end;
  gap:0;
}

.hand .card{
  margin-left:calc(var(--card-overlap) * -1);
}

.hand .card:first-child{
  margin-left:0;
}

.hand-vertical{
  display:flex;
  flex-direction:column;
  gap:0;
}

.hand-vertical .card{
  width:var(--side-card-width);
  margin-top:calc(var(--side-card-overlap) * -1);
}

.hand-vertical .card:first-child{
  margin-top:0;
}

.hand-bottom{
  width:100%;
  justify-content:center;
  padding:16px 14px 12px;
  border-radius:28px;
  background:linear-gradient(180deg, rgba(15, 22, 46, 0.86), rgba(8, 14, 28, 0.94));
  border:1px solid rgba(255, 255, 255, 0.08);
  box-shadow:0 14px 28px rgba(0, 0, 0, 0.3);
}

.hand-bottom .card{
  width:var(--human-card-width);
  margin-left:calc(var(--human-card-overlap) * -1);
}

.hand-bottom .card:first-child{
  margin-left:0;
}

.card{
  position:relative;
  width:var(--card-width);
  aspect-ratio:0.68;
  display:grid;
  place-items:center;
  overflow:hidden;
  border:1px solid rgba(16, 27, 34, 0.2);
  border-radius:var(--card-radius);
  color:#17202a;
  background:linear-gradient(145deg, #fffdf7, #e9edf2);
  box-shadow:0 10px 24px rgba(0, 0, 0, 0.25);
  user-select:none;
  touch-action:manipulation;
  transition:transform 140ms ease, box-shadow 140ms ease, opacity 140ms ease, filter 140ms ease;
}

.card::before{
  content:"";
  position:absolute;
  inset:5px;
  border:1px solid rgba(19, 30, 40, 0.12);
  border-radius:calc(var(--card-radius) - 4px);
  pointer-events:none;
}

.card.red-suit{
  color:#d4314b;
}

.card.black-suit{
  color:#1f2933;
}

.card-corner{
  position:absolute;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:0;
  font-weight:900;
  line-height:0.9;
}

.card-corner strong{
  font-size:0.86rem;
}

.card-corner span{
  font-size:0.9rem;
}

.card-corner-top{
  left:7px;
  top:7px;
}

.card-corner-bottom{
  right:7px;
  bottom:7px;
  transform:rotate(180deg);
}

.card-center{
  font-size:clamp(1.55rem, 4.8vw, 2.4rem);
  line-height:1;
}

.card.touch{
  cursor:pointer;
}

.card.playable{
  transform:translateY(-8px);
  box-shadow:0 16px 28px rgba(0, 0, 0, 0.32);
}

.card.touch:active,
.card.playable:active{
  transform:translateY(-8px) scale(1.02);
}

.card.locked{
  opacity:0.48;
  filter:saturate(0.55);
}

.card.face-down,
.card.card-back{
  color:#f7fbff;
  background:linear-gradient(135deg, #26435b, #8aa5c0);
  border-color:rgba(255, 255, 255, 0.35);
}

.card.face-down::before,
.card.card-back::before{
  border-color:rgba(255, 255, 255, 0.35);
  background:repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.16) 0 4px, transparent 4px 9px);
}

.card-back-mark{
  position:relative;
  z-index:1;
  display:grid;
  place-items:center;
  width:50%;
  aspect-ratio:1;
  border-radius:999px;
  color:#1d3448;
  background:rgba(255, 255, 255, 0.82);
  font-family:Georgia, "Times New Roman", serif;
  font-size:0.72rem;
  font-weight:900;
}

#center{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%, -50%);
  width:min(100%, 360px);
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
}

#round-summary{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:8px;
}

.info-chip{
  padding:8px 12px;
  font-size:0.8rem;
}

#kitty{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:8px;
}

.upcard-stack{
  position:relative;
  width:calc(var(--card-width) + 24px);
  height:calc(var(--card-width) * 1.52);
}

.deck-card{
  position:absolute;
  left:0;
  top:8px;
  width:calc(var(--card-width) * 0.9);
}

.upcard-slot{
  position:absolute;
  right:0;
  top:0;
  min-width:calc(var(--card-width) * 0.9);
  min-height:calc(var(--card-width) * 1.35);
  display:flex;
  align-items:center;
  justify-content:center;
}

.upcard-slot .card,
.deck-card{
  width:calc(var(--card-width) * 0.92);
}

#trick{
  width:min(78vw, 280px);
  aspect-ratio:1 / 1;
  position:relative;
}

.trick-slot{
  position:absolute;
  width:var(--slot-width);
  height:calc(var(--slot-width) * 1.35);
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:20px;
  background:rgba(255, 255, 255, 0.05);
  border:1px solid rgba(255, 255, 255, 0.05);
}

.trick-slot .card{
  width:calc(var(--slot-width) * 0.88);
}

#slot-north{
  left:50%;
  top:0;
  transform:translateX(-50%);
}

#slot-east{
  right:0;
  top:50%;
  transform:translateY(-50%);
}

#slot-south{
  left:50%;
  bottom:0;
  transform:translateX(-50%);
}

#slot-west{
  left:0;
  top:50%;
  transform:translateY(-50%);
}

#controls{
  width:min(100%, 340px);
  display:flex;
  flex-direction:column;
  gap:10px;
}

#status{
  min-height:78px;
  padding:16px 18px;
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  border-radius:22px;
  border:1px solid rgba(255, 255, 255, 0.14);
  background:linear-gradient(180deg, rgba(8, 22, 20, 0.98), rgba(7, 17, 16, 0.96));
  box-shadow:var(--shadow);
  color:#fffef7;
  font-size:1.08rem;
  font-weight:800;
  line-height:1.45;
  letter-spacing:0.01em;
  text-shadow:0 1px 2px rgba(0, 0, 0, 0.5);
}

#status.priority{
  background:linear-gradient(180deg, rgba(255, 226, 132, 0.98), rgba(247, 168, 27, 0.96));
  color:#1f1606;
  border-color:rgba(255, 235, 175, 0.72);
  text-shadow:none;
}

#actions{
  display:flex;
  justify-content:center;
  flex-wrap:wrap;
  gap:10px;
}

.bottom-bar{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:12px 16px;
  background:var(--panel);
  border-radius:26px;
  box-shadow:var(--shadow);
}

.footer-actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

button,
input,
select{
  font:inherit;
}

button{
  min-height:48px;
  border:none;
  border-radius:16px;
  padding:12px 18px;
  font-weight:700;
  color:var(--accent-ink);
  background:linear-gradient(180deg, var(--accent-strong), var(--accent));
  box-shadow:0 12px 24px rgba(0, 0, 0, 0.18);
  cursor:pointer;
  transition:transform 120ms ease, filter 120ms ease;
}

button:active{
  transform:translateY(1px) scale(0.99);
}

button.secondary,
button.ghost,
.icon-button{
  color:var(--text);
}

button.secondary{
  background:rgba(255, 255, 255, 0.12);
}

button.ghost{
  background:rgba(255, 255, 255, 0.08);
}

.icon-button{
  min-height:42px;
  padding:10px 14px;
  background:rgba(255, 255, 255, 0.08);
}

.overlay-screen{
  position:fixed;
  inset:0;
  z-index:20;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:20px;
  background:rgba(2, 8, 7, 0.7);
  backdrop-filter:blur(12px);
}

.overlay-screen.hidden{
  display:none;
}

.menu-shell,
.dialog-panel{
  width:min(100%, 440px);
  background:var(--panel-strong);
  border-radius:30px;
  box-shadow:var(--shadow);
}

.menu-shell{
  padding:24px;
  display:flex;
  flex-direction:column;
  gap:18px;
}

.menu-hero{
  display:flex;
  align-items:center;
  gap:16px;
}

.menu-logo{
  width:76px;
  height:76px;
}

.eyebrow{
  margin:0 0 4px;
  color:var(--accent-strong);
  font-size:0.74rem;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:0.14em;
}

.menu-preview{
  display:grid;
  grid-template-columns:repeat(3, minmax(0, 1fr));
  gap:10px;
}

.preview-chip{
  padding:12px;
  display:flex;
  flex-direction:column;
  gap:6px;
}

.preview-chip strong{
  font-size:1.05rem;
}

.menu-actions,
.dialog-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.menu-actions button,
.dialog-actions button{
  flex:1 1 140px;
}

.dialog-panel{
  padding:22px;
  display:flex;
  flex-direction:column;
  gap:16px;
  max-height:calc(100vh - 40px);
  overflow:auto;
}

.dialog-header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:10px;
}

.field{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.field span{
  font-weight:700;
}

input,
select{
  width:100%;
  min-height:48px;
  padding:12px 14px;
  border:none;
  border-radius:16px;
  background:rgba(255, 255, 255, 0.1);
  color:var(--text);
}

select option{
  color:#111;
}

.stats-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:10px;
}

.stat-card{
  min-height:92px;
  padding:14px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  gap:8px;
  border-radius:20px;
  background:var(--panel-soft);
}

.stat-card strong{
  font-size:1.35rem;
}

@media (max-width:900px){
  #table{
    min-height:560px;
    padding:18px 16px;
  }

  .player-chip{
    min-width:116px;
    padding:7px 10px;
  }

  .player-name{
    font-size:0.9rem;
  }
}

@media (max-width:720px){
  #app{
    padding:calc(8px + var(--safe-top)) 8px calc(8px + var(--safe-bottom));
  }

  .topbar,
  .bottom-bar{
    border-radius:22px;
  }

  .topbar,
  .bottom-bar{
    flex-wrap:wrap;
  }

  .scoreboard{
    width:100%;
    justify-content:stretch;
  }

  .score-pill{
    flex:1 1 140px;
  }

  #table{
    min-height:640px;
    padding:16px 10px;
    border-radius:28px;
  }

  .player-top{
    top:12px;
  }

  .player-bottom{
    bottom:12px;
  }

  .player-left,
  .player-right{
    top:52%;
  }

  .player-chip{
    min-width:0;
    padding:6px 8px;
  }

  .player-role{
    display:none;
  }

  .avatar{
    width:34px;
    height:34px;
  }

  #center{
    width:min(100%, 290px);
    top:51%;
  }

  #controls{
    width:100%;
  }

  #status{
    min-height:84px;
    font-size:1rem;
  }

  .menu-preview{
    grid-template-columns:1fr;
  }

  .stats-grid{
    grid-template-columns:1fr 1fr;
  }

  .footer-note{
    font-size:0.78rem;
  }
}

@media (max-width:420px){
  .brand-copy p,
  .footer-note{
    display:none;
  }

  #table{
    min-height:600px;
    padding:14px 8px;
  }

  .player-left{
    left:8px;
  }

  .player-right{
    right:8px;
  }

  .player-chip{
    gap:6px;
  }

  .player-text{
    display:none;
  }

  #center{
    width:min(100%, 260px);
  }

  .hand-bottom{
    padding:12px 10px 10px;
  }

  .info-chip{
    font-size:0.74rem;
    padding:7px 10px;
  }

  .stats-grid{
    grid-template-columns:1fr;
  }
}

/* Round clarity layout: keep prompts out of the card table and expose key Euchre state. */
#app{
  overflow-x:hidden;
  overflow-y:auto;
}

#round-hud{
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:10px;
  position:relative;
  z-index:4;
}

.hud-card{
  min-height:86px;
  padding:12px 14px;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  gap:6px;
  border-radius:22px;
  background:linear-gradient(180deg, rgba(7, 23, 21, 0.94), rgba(4, 15, 14, 0.9));
  border:1px solid rgba(255, 255, 255, 0.1);
  box-shadow:0 14px 30px rgba(0, 0, 0, 0.24);
}

.hud-card span,
.hud-card small{
  color:var(--muted);
  font-size:0.74rem;
  line-height:1.25;
}

.hud-card span{
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:0.12em;
}

.hud-card strong{
  color:#fffef8;
  font-size:1.08rem;
  line-height:1.15;
}

.hud-card.priority,
.hud-trump{
  border-color:rgba(255, 202, 103, 0.46);
}

.hud-card.priority{
  background:linear-gradient(180deg, rgba(255, 226, 132, 0.98), rgba(247, 168, 27, 0.95));
}

.hud-card.priority span,
.hud-card.priority small,
.hud-card.priority strong{
  color:#1f1606;
}

#table-area{
  flex:1;
  min-height:0;
  display:flex;
  flex-direction:column;
  gap:12px;
}

#table{
  flex:1 1 auto;
  min-height:560px;
}

#center{
  width:min(100%, 320px);
  gap:10px;
  z-index:2;
}

#table-context{
  max-width:100%;
  padding:8px 12px;
  border-radius:18px;
  border:1px solid rgba(255, 255, 255, 0.12);
  background:rgba(0, 0, 0, 0.32);
  color:var(--accent-strong);
  font-weight:800;
  text-align:center;
  box-shadow:0 10px 22px rgba(0, 0, 0, 0.22);
}

.table-context-line{
  font-size:0.85rem;
  line-height:1.25;
}

#controls.action-panel{
  width:min(100%, 760px);
  margin:0 auto;
  padding:12px;
  display:grid;
  gap:10px;
  border-radius:24px;
  border:1px solid rgba(255, 255, 255, 0.14);
  background:linear-gradient(180deg, rgba(7, 23, 21, 0.98), rgba(4, 14, 13, 0.96));
  box-shadow:var(--shadow);
  position:relative;
  z-index:5;
}

#controls.action-panel #status{
  min-height:auto;
  padding:12px 14px;
  border-radius:18px;
  box-shadow:none;
  font-size:1rem;
}

#controls.action-panel #actions{
  gap:8px;
}

#controls.action-panel #actions button{
  flex:1 1 150px;
}

.player.active-player .player-chip{
  outline:2px solid var(--accent-strong);
  box-shadow:0 0 0 5px rgba(247, 168, 27, 0.16), 0 12px 24px rgba(0, 0, 0, 0.28);
}

.player.active-player .avatar{
  transform:scale(1.08);
}


@media (max-width:720px){
  #round-hud{
    grid-template-columns:repeat(2, minmax(0, 1fr));
    gap:8px;
  }

  .hud-card{
    min-height:78px;
    padding:10px 12px;
    border-radius:18px;
  }

  .hud-card strong{
    font-size:0.98rem;
  }

  #table{
    min-height:540px;
  }

  #center{
    width:min(100%, 270px);
    top:50%;
  }

  #trick{
    width:min(70vw, 236px);
  }

  #controls.action-panel{
    border-radius:20px;
  }
}

@media (max-width:420px){
  #round-hud{
    grid-template-columns:1fr 1fr;
  }

  .hud-card{
    min-height:70px;
  }

  .hud-card small{
    font-size:0.68rem;
  }

  #table{
    min-height:520px;
  }

  #controls.action-panel #status{
    font-size:0.95rem;
  }
}

/* Portfolio iframe fit: keep the full Euchre table and action panel visible in the phone frame. */
body{
  height:100dvh;
  overflow:hidden;
}

#app{
  height:100dvh;
  min-height:0;
  overflow:hidden;
}

#table{
  min-height:0;
}

@media (max-height:760px){
  #app{
    padding:calc(7px + var(--safe-top)) 8px calc(7px + var(--safe-bottom));
    gap:7px;
  }

  .topbar{
    padding:8px 10px;
    border-radius:20px;
  }

  .brand-logo{
    width:34px;
    height:34px;
    font-size:1.15rem;
  }

  .brand-copy p,
  .footer-note,
  .player-role,
  .player-text{
    display:none;
  }

  .scoreboard{
    gap:6px;
  }

  .score-pill{
    min-width:86px;
    padding:6px 8px;
  }

  #round-hud{
    grid-template-columns:repeat(4, minmax(0, 1fr));
    gap:6px;
  }

  .hud-card{
    min-height:56px;
    padding:7px 8px;
    border-radius:16px;
  }

  .hud-card small{
    display:none;
  }

  .hud-card strong{
    font-size:0.88rem;
  }

  #table-area{
    gap:6px;
  }

  #table{
    min-height:0;
    padding:8px;
    border-radius:24px;
  }

  #center{
    width:min(100%, 236px);
    gap:6px;
    top:50%;
  }

  #trick{
    width:min(58vw, 188px);
  }

  .player-chip{
    min-width:0;
    gap:5px;
    padding:4px 6px;
  }

  .avatar{
    width:30px;
    height:30px;
  }

  .hand-bottom{
    padding:8px 8px 7px;
  }

  #controls.action-panel{
    padding:8px;
    gap:6px;
    border-radius:18px;
  }

  #controls.action-panel #status{
    padding:8px 10px;
    font-size:0.86rem;
    line-height:1.28;
  }

  #controls.action-panel #actions{
    gap:6px;
  }

  #controls.action-panel #actions button,
  button{
    min-height:40px;
    padding:8px 10px;
  }
}

@media (max-height:620px){
  #round-hud{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }

  .hud-card{
    min-height:48px;
  }

  .topbar{
    gap:8px;
  }

  #trick{
    width:min(52vw, 168px);
  }
}
