/* 윷 던지기 */
.yt-layout { display: grid; gap: 24px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 860px) { .yt-layout { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); } }

/* 멍석 */
.yt-mat {
  --sw: 30px; --sh: 150px;
  display: flex; justify-content: center; align-items: center; gap: clamp(16px, 6vw, 34px);
  min-height: 250px; padding: 44px 12px 32px; border-radius: var(--radius-lg); cursor: pointer;
  background:
    repeating-linear-gradient(90deg, rgba(120, 80, 30, .10) 0 2px, transparent 2px 9px),
    repeating-linear-gradient(0deg, rgba(120, 80, 30, .08) 0 2px, transparent 2px 9px),
    radial-gradient(ellipse at 50% 40%, #ead3a3 0%, #c99c60 100%);
  box-shadow: inset 0 0 0 6px #a8773f, inset 0 0 0 8px #8a5e2e, inset 0 0 28px rgba(80, 45, 10, .35);
  user-select: none; -webkit-tap-highlight-color: transparent;
}
.yt-mat:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }
@media (max-width: 420px) { .yt-mat { --sw: 25px; --sh: 125px; min-height: 220px; } }
.game-shell.is-full .yt-mat { --sw: 36px; --sh: 180px; min-height: 300px; }

.yt-slot { position: relative; width: var(--sw); height: var(--sh); flex: none; }
.yt-pose { position: absolute; inset: 0; transition: transform 1.15s cubic-bezier(.2, .75, .25, 1); }
.yt-fly { position: absolute; inset: 0; perspective: 600px; z-index: 1; }
.yt-stick { position: absolute; inset: 0; transform-style: preserve-3d; transition: transform 1.15s cubic-bezier(.2, .75, .25, 1); }
.yt-face { position: absolute; inset: 0; border-radius: 999px; overflow: hidden; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.yt-face svg { display: block; width: 100%; height: 100%; }
.yt-flat { background: linear-gradient(90deg, #e6c68b 0%, #f8e7c2 50%, #e6c68b 100%); box-shadow: inset 0 0 0 1.5px #c0915a; }
.yt-round {
  transform: rotateX(180deg);
  background: linear-gradient(90deg, #6f4520 0%, #b27a41 28%, #dca66b 50%, #b27a41 72%, #6f4520 100%);
  box-shadow: inset 0 0 0 1px #5e3915;
}
.yt-shadow {
  position: absolute; left: 4px; right: -4px; top: 6px; bottom: -6px; border-radius: 999px;
  background: rgba(60, 30, 5, .32); filter: blur(3px);
}
.yt-slot.is-flying .yt-fly { animation: yt-fly 1.15s cubic-bezier(.3, .6, .35, 1) var(--delay, 0ms) both; }
.yt-slot.is-flying .yt-shadow { animation: yt-shadow 1.15s cubic-bezier(.3, .6, .35, 1) var(--delay, 0ms) both; }
@keyframes yt-fly {
  0% { transform: translateY(0) scale(1); }
  35% { transform: translateY(-64px) scale(1.14); }
  72% { transform: translateY(0) scale(1); }
  84% { transform: translateY(-7px) scale(1); }
  100% { transform: translateY(0) scale(1); }
}
@keyframes yt-shadow {
  0% { transform: translate(0, 0) scale(1); opacity: 1; }
  35% { transform: translate(10px, 18px) scale(.8); opacity: .35; }
  72%, 100% { transform: translate(0, 0) scale(1); opacity: 1; }
}

/* 결과 */
.yt-result { text-align: center; min-height: 104px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.yt-big { font-size: clamp(32px, 9vw, 52px); font-weight: 900; letter-spacing: -0.03em; line-height: 1.15; }
.yt-sub { color: var(--text-2); font-weight: 700; font-size: 15.5px; min-height: 1.4em; }
.yt-again {
  display: inline-block; margin-top: 2px; padding: 4px 14px; border-radius: 999px;
  background: var(--accent-soft); color: var(--text); font-weight: 900; animation: bb-pulse 1s ease-in-out infinite;
}

/* 팀 */
.yt-teams { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.yt-team {
  --c: var(--primary);
  display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 12px;
  background: var(--surface); border: 2px solid var(--border); transition: border-color .2s, box-shadow .2s;
}
.yt-team.is-turn { border-color: var(--c); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 25%, transparent); }
.yt-team-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.yt-team-n { font-weight: 900; color: var(--c); }
.yt-team-t { font-family: var(--font-num); font-size: 16px; white-space: nowrap; }
.yt-prog { height: 8px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.yt-prog span { display: block; height: 100%; background: var(--c); border-radius: inherit; transition: width .4s ease; }
.yt-log { margin: 0; padding-left: 1.3em; font-size: 13.5px; line-height: 1.5; color: var(--text-2); display: grid; gap: 2px; }
.yt-log:empty { display: none; }
.yt-log li:first-child { color: var(--text); font-weight: 700; }

/* 통계·기록 */
.yt-table-wrap { overflow-x: auto; margin: 8px 0 6px; }
.yt-stats { width: 100%; border-collapse: collapse; font-size: 14px; }
.yt-stats th, .yt-stats td { padding: 6px 8px; text-align: right; border-bottom: 1px solid var(--border); white-space: nowrap; }
.yt-stats td { font-family: var(--font-num); }
.yt-stats th:first-child, .yt-stats td:first-child { text-align: left; }
.yt-stats th { font-size: 12.5px; color: var(--text-3); font-weight: 700; }
.yt-stats td .muted { font-size: 12px; }
.yt-hist { display: flex; flex-wrap: wrap; gap: 6px; }
.yt-h {
  --c: var(--border-strong);
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  font-weight: 800; font-size: 13px; background: var(--surface); border: 1px solid var(--border);
}
.yt-h-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.yt-h-yut, .yt-h-mo { background: var(--accent-soft); }
.yt-h-backdo { color: var(--red); }
.yt-h:first-child { border-color: var(--primary); }
