/* ═══════════════════════════════════════════════════════════════
   NIUNIU GROUND — 디자인 토큰 + 공통 셸
   목업 기준: 딥레드 + 골드, 모바일 앱형(상단바 · 히어로 캐러셀 · 카테고리 그리드 · 하단 탭바).
   Tailwind CDN 없이 이 파일 하나로 스타일을 끝낸다.
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* 브랜드 — 딥레드 */
  --red-900: #4a0708;
  --red-800: #5f0d0f;
  --red-700: #7a1416;
  --red-600: #931c1e;
  --red-ink: #8b1a1a; /* 섹션 제목용 */

  /* 골드 */
  --gold-300: #f3dda6;
  --gold-400: #e6c67e;
  --gold-500: #d4a24c;
  --gold-600: #b8862f;
  --gold-line: rgba(212, 162, 76, 0.45);

  /* 표면 */
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #faf7f5;
  --border: rgba(74, 7, 8, 0.1);

  /* 텍스트 */
  --text-1: #1c0c0c;
  --text-2: #5c4444;
  --text-3: #8b7676;
  --on-red: #ffffff;

  /* 상태 */
  --danger: #c02626;
  --success: #1f7a4d;

  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 3px rgba(28, 12, 12, 0.1);
  --shadow-md: 0 4px 14px rgba(28, 12, 12, 0.12);
  --shadow-lg: 0 12px 32px rgba(28, 12, 12, 0.18);

  --topbar-h: 56px;
  --bottomnav-h: 64px;
  --container: 1200px;

  --font-brand: "Playfair Display", "Times New Roman", serif;
  --font-ui: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Malgun Gothic", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17100f;
    --surface: #201615;
    --surface-2: #2a1d1c;
    --border: rgba(230, 198, 126, 0.14);
    --text-1: #f6ecec;
    --text-2: #c9b3b3;
    --text-3: #9a8484;
    --red-ink: #e6a4a4;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text-1);
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  /* 고정 상·하단 바가 콘텐츠를 가리지 않도록 */
  padding-top: var(--topbar-h);
  padding-bottom: calc(var(--bottomnav-h) + env(safe-area-inset-bottom, 0px));
}

body.no-bottomnav {
  padding-bottom: 0;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--gold-500);
  outline-offset: 2px;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hidden {
  display: none !important;
}

/* ─── 상단바 ─────────────────────────────────────────────── */

.topbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--topbar-h);
  background: linear-gradient(180deg, var(--red-700), var(--red-900));
  border-bottom: 2px solid var(--gold-500);
  box-shadow: var(--shadow-md);
}

.topbar-inner {
  height: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.brand-logo-wide {
  height: 42px;
  width: auto;
  max-width: 60vw;
  object-fit: contain;
  flex-shrink: 0;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45));
}

.brand-title {
  font-family: var(--font-brand);
  font-size: clamp(18px, 4.5vw, 26px);
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--gold-400);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* 상단바 잔액 칩 */
.balance-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid var(--gold-line);
}

.balance-chip .amount {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--gold-300);
}

.balance-chip .unit {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--gold-500);
}

/* ─── 언어 선택기 ────────────────────────────────────────── */

.lang {
  position: relative;
}

.lang-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--gold-line);
  box-shadow: var(--shadow-sm);
  line-height: 1;
}

.lang-toggle .flag {
  font-size: 16px;
}

.lang-toggle .globe {
  width: 18px;
  height: 18px;
  color: var(--red-700);
}

.lang-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 168px;
  padding: 6px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  z-index: 60;
}

.lang-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-1);
  font-size: 14px;
  text-align: left;
}

.lang-item:hover {
  background: var(--surface-2);
}

.lang-item[aria-current="true"] {
  background: rgba(212, 162, 76, 0.16);
  font-weight: 600;
}

/* ─── 잭팟 카드(우측 고정 패널) ──────────────────────────── */

.jackpot-card {
  position: fixed;
  right: 12px;
  top: calc(var(--topbar-h) + 12px);
  z-index: 45;
  /* 높이 화면 1/2, 폭 화면 1/4 (요청) */
  height: 50vh;
  width: 25vw;
  min-width: 180px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 2px solid var(--gold-500);
  box-shadow: var(--shadow-lg);
  background: url("/assets/gen/jackpot-bg.webp") center / cover no-repeat, #fbeecb;
}

.jp-inner {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 12px;
  background: linear-gradient(180deg, rgba(255, 250, 235, 0.72) 0%, rgba(255, 248, 225, 0.35) 40%, rgba(255, 245, 210, 0.85) 100%);
}

.jp-head {
  font-family: var(--font-brand);
  font-size: clamp(15px, 1.6vw, 22px);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--gold-600);
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.6);
}

.jp-total {
  margin-top: 6px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  font-size: clamp(18px, 2.1vw, 30px);
  color: #7a4a08;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.7);
  white-space: nowrap;
}
.jp-total .jp-unit {
  font-size: 0.5em;
  color: var(--gold-600);
}

.jp-tiers {
  margin-top: auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.jp-tier {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.66);
  border: 1px solid var(--gold-line);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #6b3e05;
  font-size: clamp(11px, 1.1vw, 14px);
}
.jp-tier-name {
  padding: 2px 8px;
  border-radius: 999px;
  color: #fff;
  font-size: 0.85em;
  letter-spacing: 0.04em;
}
.jp-major { background: linear-gradient(180deg, #e0952a, #b8722a); }
.jp-minor { background: linear-gradient(180deg, #b06fd0, #7a3fd0); }
.jp-mini { background: linear-gradient(180deg, #4fa3e0, #2b6fd0); }

/* 좁은 화면(모바일)에서는 우측 고정 패널이 콘텐츠를 가리므로 숨김 */
@media (max-width: 900px) {
  .jackpot-card {
    display: none;
  }
}

/* ─── 하단 탭바 ──────────────────────────────────────────── */

.bottomnav {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 50;
  height: calc(var(--bottomnav-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: linear-gradient(180deg, var(--red-800), var(--red-900));
  border-top: 2px solid var(--gold-500);
  display: flex;
}

.bottomnav-inner {
  height: var(--bottomnav-h);
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.navtab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--gold-400);
  opacity: 0.75;
  border: 0;
  background: transparent;
}

.navtab svg {
  width: 24px;
  height: 24px;
}

.navtab .label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.navtab:hover {
  opacity: 1;
}

.navtab[aria-current="page"] {
  opacity: 1;
  color: var(--gold-300);
}

/* ─── 섹션 · 게임 그리드 ─────────────────────────────────── */

.section {
  margin: 28px 0;
}

.section-title {
  margin: 0 0 12px;
  font-size: clamp(17px, 3.4vw, 22px);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--red-ink);
}

.game-grid {
  display: grid;
  gap: 10px;
  /* 세로형(모바일): 한 줄 3열. 좁은 화면(<360px)만 2열로 완화. */
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 360px) {
  .game-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 700px) {
  .game-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1000px) {
  .game-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.game-card {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 1px solid var(--gold-line);
  border-radius: var(--radius);
  background: var(--surface-2);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.game-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.game-card:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.game-card .thumb-wrap {
  position: relative;
  display: block;
}

.game-card .thumb {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--surface-2);
  display: block;
}

/* 런치 버튼(목업) — 썸네일 위 중앙 하단, 호버 시 살짝 확대 */
.game-card .play-btn {
  position: absolute;
  left: 50%;
  bottom: 8px;
  transform: translateX(-50%);
  width: 56%;
  max-width: 120px;
  height: auto;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
  transition: transform 0.16s ease;
  pointer-events: none;
}

.game-card:hover .play-btn {
  transform: translateX(-50%) scale(1.06);
}

.game-card .meta {
  padding: 8px 10px 10px;
  text-align: left;
}

.game-card .title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-card .subtitle {
  font-size: 11px;
  color: var(--text-3);
}

/* ─── 히어로 캐러셀 ──────────────────────────────────────── */

.hero {
  margin: 16px 0 8px;
}

.carousel {
  position: relative;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  gap: 12px;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  border-radius: var(--radius-lg);
  border: 2px solid var(--gold-500);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--red-800);
}

.carousel-slide img {
  width: 100%;
  aspect-ratio: 16 / 7;
  object-fit: cover;
}

.carousel-slide[data-provider] {
  cursor: pointer;
}

/* 배너 아트가 없을 때의 텍스트 슬라이드 */
.slide-text {
  aspect-ratio: 16 / 7;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
  text-align: center;
  color: #fff;
}

.slide-text .s-title {
  font-family: var(--font-brand);
  font-size: clamp(28px, 7vw, 52px);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  color: var(--gold-300);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.slide-text .s-sub {
  font-size: clamp(12px, 2.6vw, 16px);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
}

.slide-red {
  background: radial-gradient(circle at 30% 30%, var(--red-600), var(--red-900) 70%);
}

.slide-gold {
  background: linear-gradient(135deg, #7a1416, #b8862f 55%, #4a0708);
}

.slide-dark {
  background: linear-gradient(135deg, #2a1d1c, #4a0708);
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin-top: 10px;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(140, 120, 120, 0.35);
  transition: background 0.2s ease, width 0.2s ease;
}

.carousel-dot[aria-current="true"] {
  width: 20px;
  background: var(--gold-500);
}

/* ─── 버튼 ───────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 600;
  transition: filter 0.15s ease, background 0.15s ease;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-gold {
  background: linear-gradient(180deg, var(--gold-400), var(--gold-600));
  color: #3a2408;
  border-color: var(--gold-600);
  box-shadow: var(--shadow-sm);
}

.btn-gold:hover:not(:disabled) {
  filter: brightness(1.06);
}

.btn-red {
  background: linear-gradient(180deg, var(--red-600), var(--red-800));
  color: var(--on-red);
  border-color: var(--red-900);
}

.btn-red:hover:not(:disabled) {
  filter: brightness(1.1);
}

.btn-ghost {
  background: transparent;
  color: var(--text-2);
  border-color: var(--border);
}

.btn-ghost:hover:not(:disabled) {
  background: var(--surface-2);
}

.btn-block {
  width: 100%;
}

/* ─── 카드 · 폼 ──────────────────────────────────────────── */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 20px;
}

.card-title {
  margin: 0 0 4px;
  font-family: var(--font-brand);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-1);
}

.card-sub {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--text-3);
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  margin-bottom: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-2);
}

.field input {
  width: 100%;
  padding: 11px 13px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-1);
  font-family: inherit;
  font-size: 15px;
}

.field input:focus {
  outline: none;
  border-color: var(--gold-500);
  box-shadow: 0 0 0 3px rgba(212, 162, 76, 0.2);
}

.msg {
  margin: 10px 0 0;
  font-size: 13px;
}

.msg-error {
  color: var(--danger);
}

.msg-info {
  color: var(--gold-600);
}

/* ─── 모달 ───────────────────────────────────────────────── */

.modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(28, 8, 8, 0.6);
  backdrop-filter: blur(3px);
}

.modal-box {
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--gold-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 22px;
}

/* ─── 토스트 · 오버레이 ──────────────────────────────────── */

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--bottomnav-h) + 20px);
  transform: translateX(-50%);
  z-index: 80;
  max-width: 90vw;
  padding: 10px 16px;
  border-radius: 10px;
  background: rgba(28, 8, 8, 0.92);
  color: #fff;
  font-size: 14px;
  box-shadow: var(--shadow-lg);
}

.toast.is-error {
  background: var(--danger);
}

.overlay {
  position: fixed;
  inset: 0;
  z-index: 75;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: rgba(28, 8, 8, 0.72);
  color: var(--gold-300);
  font-weight: 600;
}

.spinner {
  width: 38px;
  height: 38px;
  border: 3px solid rgba(230, 198, 126, 0.25);
  border-top-color: var(--gold-400);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ─── 목록(거래내역) ─────────────────────────────────────── */

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

.list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.list-row .left {
  min-width: 0;
}

.list-row .type {
  font-size: 14px;
  font-weight: 700;
}

.list-row .when {
  font-size: 11px;
  color: var(--text-3);
}

.list-row .right {
  text-align: right;
  flex-shrink: 0;
}

.list-row .delta {
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.delta-plus {
  color: var(--success);
}

.delta-minus {
  color: var(--danger);
}

.list-row .after {
  font-size: 11px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.empty {
  padding: 40px 16px;
  text-align: center;
  color: var(--text-3);
  font-size: 14px;
}

/* ─── 인증 페이지(로그인/가입) ───────────────────────────── */

.auth-wrap {
  min-height: calc(100vh - var(--topbar-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: linear-gradient(160deg, var(--red-900), #2a0405 60%, #140203);
}

.auth-card {
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--gold-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 28px 24px;
}

.auth-brand {
  text-align: center;
  margin-bottom: 20px;
}

.auth-brand .name {
  font-family: var(--font-brand);
  font-size: 26px;
  font-weight: 700;
  color: var(--red-ink);
}

.auth-brand .tag {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-3);
}

.auth-alt {
  margin: 16px 0 0;
  text-align: center;
  font-size: 13px;
  color: var(--text-3);
}

.auth-alt a {
  color: var(--gold-600);
  font-weight: 600;
}

/* ═══════════════════════════════════════════════════════════════
   NIUNIU GROUND 랜딩 — 가운데[설명 70% · 족보 30%] + 하단 적색 START
   ═══════════════════════════════════════════════════════════════ */

.ng-mid {
  display: grid;
  grid-template-columns: 1fr; /* 모바일: 세로 스택 */
  gap: 14px;
  margin: 14px 0 6px;
}
@media (min-width: 760px) {
  .ng-mid {
    grid-template-columns: 7fr 3fr; /* 좌 70% · 우 30% */
    align-items: start;
  }
}

/* ════════ NIUNIU 프리미엄 섹션 (How NIUNIU Works · Paytable) ════════ */
.ng-explain,
.ng-jokbo {
  position: relative;
  border-radius: 20px;
  padding: 22px 22px 24px;
  color: #f3e7d0;
  background:
    radial-gradient(130% 90% at 12% -5%, rgba(232, 178, 58, 0.16), transparent 55%),
    linear-gradient(158deg, #241318 0%, #1a0d11 46%, #110a0d 100%);
  border: 1px solid rgba(232, 178, 58, 0.4);
  box-shadow:
    0 20px 44px -20px rgba(0, 0, 0, 0.75),
    0 2px 0 rgba(255, 240, 190, 0.07) inset,
    0 0 0 1px rgba(0, 0, 0, 0.45) inset;
  overflow: hidden;
}
.ng-explain::before,
.ng-jokbo::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 236, 170, 0.75), transparent);
}
.ng-explain::after,
.ng-jokbo::after {
  content: ""; position: absolute; width: 200px; height: 200px; right: -70px; top: -80px;
  background: radial-gradient(circle, rgba(232, 178, 58, 0.2), transparent 70%);
  pointer-events: none;
}

.ng-h2, .ng-h3 {
  font-family: var(--font-brand);
  letter-spacing: 0.01em;
  background: linear-gradient(180deg, #fff6c8, #ffe07a 30%, #e8b23a 62%, #b8791e);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  margin: 0 0 4px; position: relative; display: flex; align-items: center; gap: 10px;
}
.ng-h2 { font-size: clamp(20px, 2.4vw, 28px); }
.ng-h3 { font-size: clamp(16px, 1.9vw, 21px); margin: 0 0 12px; }
.ng-h2::before, .ng-h3::before {
  content: ""; width: 15px; height: 15px; flex: 0 0 auto; transform: rotate(45deg);
  border-radius: 3px;
  background: linear-gradient(135deg, #fff6c8, #e8b23a 55%, #8a5a16);
  box-shadow: 0 0 9px rgba(232, 178, 58, 0.6), 0 1px 2px rgba(0, 0, 0, 0.5);
}
.ng-lead { color: #d8c39d; font-size: 14px; margin: 0 0 16px; }

.ng-cards { display: flex; gap: clamp(7px, 1.3vw, 13px); flex-wrap: wrap; }
.ng-card {
  position: relative; width: clamp(48px, 9vw, 68px); aspect-ratio: 5 / 7; border-radius: 9px;
  background: linear-gradient(160deg, #fffef9, #f2e8d3);
  border: 1px solid rgba(0, 0, 0, 0.15);
  box-shadow: 0 7px 15px -6px rgba(0, 0, 0, 0.65), 0 0 0 2px rgba(232, 178, 58, 0.55), 0 1px 0 #fff inset;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: #1c0c0c; font-weight: 800; line-height: 1;
}
.ng-card::after {
  content: ""; position: absolute; left: 1px; right: 1px; top: 1px; bottom: 55%;
  border-radius: 8px 8px 42% 42%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.6), transparent);
  pointer-events: none;
}
.ng-card .pip { font-size: clamp(15px, 2.5vw, 21px); position: relative; z-index: 1; }
.ng-card .suit { font-size: clamp(12px, 2vw, 17px); margin-top: 2px; position: relative; z-index: 1; }
.ng-card.red { color: #c02626; }
.ng-card.is-zero { box-shadow: 0 7px 15px -6px rgba(0,0,0,0.65), 0 0 0 2px rgba(232,178,58,0.95), 0 0 15px rgba(232,178,58,0.4); }
.ng-card.is-score { box-shadow: 0 7px 17px -6px rgba(0,0,0,0.7), 0 0 0 2.5px #c02626, 0 0 16px rgba(192,38,38,0.45); }

.ng-cards-legend { display: flex; gap: 10px; margin: 14px 0 4px; font-size: 12px; font-weight: 800; }
.ng-cards-legend .lg { padding: 5px 12px; border-radius: 999px; letter-spacing: 0.02em; }
.lg-zero { color: #3a2606; background: linear-gradient(180deg, #ffe79a, #e3ac3c); box-shadow: 0 2px 6px -2px rgba(0,0,0,0.5); border: none; }
.lg-score { color: #fff; background: linear-gradient(180deg, #c53236, #7a1416); box-shadow: 0 2px 6px -2px rgba(0,0,0,0.5); }

.ng-steps { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.ng-steps li {
  position: relative; display: flex; gap: 14px; align-items: center;
  padding: 12px 40px 12px 14px; border-radius: 14px;
  background: linear-gradient(150deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015));
  border: 1px solid rgba(232, 178, 58, 0.22);
  color: #efe2c8; font-size: 14px; line-height: 1.35;
}
.ng-steps li::before {
  content: ""; flex: 0 0 auto; width: 46px; height: 46px;
  background: center / contain no-repeat; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.5));
}
.ng-steps li:nth-child(1)::before { background-image: url(/assets/gen/hiw-deal.svg); }
.ng-steps li:nth-child(2)::before { background-image: url(/assets/gen/hiw-zero.svg); }
.ng-steps li:nth-child(3)::before { background-image: url(/assets/gen/hiw-score.svg); }
.ng-steps .n {
  position: absolute; top: 9px; right: 11px; width: 18px; height: 18px; font-size: 10px;
  background: linear-gradient(180deg, #ffe79a, #b8862f); color: #3a2606;
  border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  font-weight: 800; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}

.ng-tip {
  margin: 16px 0 0; padding: 12px 14px; border-radius: 12px;
  background: linear-gradient(180deg, rgba(232, 178, 58, 0.16), rgba(232, 178, 58, 0.05));
  border: 1px solid rgba(232, 178, 58, 0.42);
  color: #ffe9b8; font-size: 13px; font-weight: 600;
  display: flex; gap: 8px; align-items: center;
}
.ng-tip::before { content: "✦"; color: #ffd97a; font-size: 15px; }

/* ── 우: Paytable ── */
.ng-jokbo { padding: 20px 16px 20px; }
.ng-jokbo-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; font-variant-numeric: tabular-nums; }
.ng-jokbo-table th, .ng-jokbo-table td { padding: 9px 8px; text-align: center; white-space: nowrap; border-bottom: 1px solid rgba(232, 178, 58, 0.12); }
.ng-jokbo-table th {
  color: #ffdf9a; font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; font-weight: 800;
  background: linear-gradient(180deg, rgba(232, 178, 58, 0.18), rgba(232, 178, 58, 0.04));
  border-bottom: 1px solid rgba(232, 178, 58, 0.42);
}
.ng-jokbo-table td { color: #e7d7b4; }
.ng-jokbo-table td.hand { text-align: left; font-weight: 800; color: #fff2cf; }
.ng-jokbo-table .sup { color: #ffd97a; font-weight: 900; }
.ng-jokbo-table tbody tr:nth-child(even) td { background: rgba(255, 255, 255, 0.025); }
.ng-jokbo-table tbody tr:first-child td { background: linear-gradient(90deg, rgba(232, 178, 58, 0.22), rgba(232, 178, 58, 0.05)); }
.ng-jokbo-table tbody tr:first-child td.hand { color: #fff; }
.ng-jokbo-more {
  margin-top: 14px; width: 100%; padding: 11px 12px; border-radius: 12px; cursor: pointer;
  border: 1px solid rgba(232, 178, 58, 0.5);
  background: linear-gradient(180deg, rgba(232, 178, 58, 0.14), rgba(232, 178, 58, 0.04));
  color: #ffe4a6; font-weight: 800; font-size: 13px; letter-spacing: 0.02em;
  transition: transform 0.12s, box-shadow 0.12s, background 0.12s;
}
.ng-jokbo-more:hover { background: linear-gradient(180deg, rgba(232, 178, 58, 0.26), rgba(232, 178, 58, 0.09)); box-shadow: 0 6px 16px -8px rgba(232, 178, 58, 0.6); }

/* ── 전체 족보 모달 ── */
.ng-jokbo-modal { max-width: 560px; background: linear-gradient(160deg, #241318, #140a0d); border: 1px solid rgba(232, 178, 58, 0.4); color: #f3e7d0; }
.ng-jokbo-modal .card-title { background: linear-gradient(180deg, #fff6c8, #e8b23a); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.ng-jokbo-scroll { max-height: 62vh; overflow: auto; margin-top: 12px; border-radius: 12px; border: 1px solid rgba(232, 178, 58, 0.2); }
.ng-jokbo-table.full th { position: sticky; top: 0; z-index: 1; background: linear-gradient(180deg, #2a1a12, #231410); }

/* ── 하단 START ── */
.ng-start {
  display: block;
  width: 100%;
  margin: 16px 0 10px;
  padding: clamp(16px, 2.4vw, 22px);
  border: 2px solid var(--gold-500);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--red-600), var(--red-800));
  color: #fff;
  font-family: var(--font-brand);
  font-size: clamp(20px, 3vw, 30px);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
}
.ng-start:hover { filter: brightness(1.06); box-shadow: var(--shadow-lg); }
.ng-start:active { transform: translateY(1px); }
