/* ═══════════════════════════════════════════════════════════
   로비 다크그린 글래스 테마 — 맨 마지막 로드 (모든 충돌 위에서 승리)
   기존 "모드 선택 카드"와 동일한 글래스모피즘으로 통일 + 고대비.
   배경: 딥 그린 그라데이션 / 카드: 반투명 글래스 + 골드 테두리 / 텍스트: 밝게.
   범위: 로비의 랭킹/충전·환전/규칙 섹션 (게임 화면은 안 건드림).
   ═══════════════════════════════════════════════════════════ */

/* 1) 빛번짐(text-shadow) 제거 */
#lobby-screen .section,
#lobby-screen .section * {
    text-shadow: none !important;
}

/* 2) 카드/테이블 — 다크그린 글래스 (모드카드와 동일 톤) */
#rankings-section .ranking-table,
#wallet-section .wallet-card,
#rules-section .rule-card {
    background-color: rgba(255, 255, 255, 0.045) !important;
    background-image: linear-gradient(rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.02) 100%) !important;
    border: 1px solid rgba(212, 175, 55, 0.30) !important;   /* 은은한 골드 테두리 */
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.12),
                0 10px 30px rgba(0,0,0,0.35) !important;
    backdrop-filter: blur(14px) saturate(1.6) !important;
    -webkit-backdrop-filter: blur(14px) saturate(1.6) !important;
    border-radius: 16px !important;
}
#rules-section .rules-container {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
}
/* 룰 카드 — 반투명 글래스(backdrop blur) 가 흐릿/저급해 보여 솔리드 다크그린으로 교체.
   불투명 베이스 + 은은한 상단 그린 시인 + 골드 테두리 → 선명하고 고급스럽게. */
#rules-section .rule-card {
    background-color: #0F2417 !important;
    background-image: linear-gradient(165deg, rgba(36,66,46,0.60) 0%, rgba(10,26,16,0) 62%) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: 1px solid rgba(212,175,55,0.22) !important;
    box-shadow: 0 8px 26px rgba(0,0,0,0.42),
                inset 0 1px 0 rgba(255,255,255,0.05) !important;
    border-radius: 14px !important;
}

/* 3) 본문 텍스트 — 밝게 (다크 배경 대비) */
#rankings-section, #rankings-section *,
#wallet-section, #wallet-section *,
#rules-section, #rules-section * {
    color: #E6EFEA !important;
}
/* 보조 설명 — 옅은 민트그레이 */
#wallet-section [style*="var(--text2)"],
#rules-section [style*="var(--text2)"],
#wallet-section small {
    color: #9FB8AE !important;
}

/* 4) 제목·뱃지·강조 — 골드/브라이트그린 (테마 액센트) */
#rankings-section .section-header h3,
#wallet-section .section-header h3,
#rules-section .rules-container > h2 {
    color: #E8C766 !important;
    font-weight: 800 !important;
}
#rules-section h3[style*="var(--primary)"] {
    color: #5BD98A !important;        /* 카드 제목 — 브라이트 그린 (모드카드 톤) */
}
#rules-section [style*="background:var(--primary)"] {
    background: linear-gradient(135deg, #EBCE74 0%, #D4AF37 100%) !important;  /* 골드 뱃지 */
    color: #0C2A1B !important;        /* 골드 위 어두운 글자 */
    border: none !important;
}
#rules-section h3[style*="var(--danger)"] {
    color: #FF9A86 !important;        /* 경고 제목 — 밝은 코랄 */
}
#rules-section h3[style*="var(--text2)"] {
    color: #B9CFC6 !important;
}
/* 폴백: apple.css 의 #rules-section h3{color:var(--text)}(거의 검정,#1D1D1F) 를 덮어
   어떤 룰 헤더도 어둡지 않게 항상 밝은 그린화이트로. (h2 는 위 .rules-container>h2 처리) */
#rules-section h3, #rules-section h4 {
    color: #EAF2EC !important;
    -webkit-text-fill-color: currentColor !important;
}
/* 경고/순차("땡큐") 등 var(--warning) 헤더 — 따뜻한 앰버골드 강조 */
#rules-section h3[style*="var(--warning)"] {
    color: #F4C95D !important;
    -webkit-text-fill-color: #F4C95D !important;
}
#wallet-section [style*="var(--primary)"] {
    color: #FAD02C !important;        /* 포인트 등 — 골드 */
}
#wallet-section .wallet-amount {
    color: #FAD02C !important;        /* 보유금 금액 — 골드 강조 */
}

/* 5) 랭킹 테이블 — 다크그린 글래스 행 */
#rankings-section .ranking-table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    overflow: hidden !important;
}
#rankings-section .ranking-table th {
    background: rgba(212, 175, 55, 0.13) !important;   /* 골드 틴트 헤더 */
    color: #E8C766 !important;
    font-weight: 700 !important;
    font-size: 13px !important;
    padding: 14px 12px !important;
    text-align: left !important;
    border-bottom: 1px solid rgba(212,175,55,0.30) !important;
}
#rankings-section .ranking-table td {
    color: #E6EFEA !important;
    font-size: 14px !important;
    padding: 13px 12px !important;
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
    background: transparent !important;
}
#rankings-section .ranking-table tbody tr:nth-child(even) td {
    background: rgba(255,255,255,0.028) !important;
}
/* 호버: apple.css 의 tr:hover{background:var(--bg)}(흰색) 을 덮어 다크그린 하이라이트로.
   tr 을 직접 칠해 흰배경을 차단하고, td 텍스트는 밝게 유지해 내용이 항상 보이게 함. */
#rankings-section .ranking-table tbody tr:hover,
#rankings-section tbody tr:hover {
    background: rgba(40, 70, 50, 0.55) !important;
}
#rankings-section .ranking-table tbody tr:hover td {
    background: rgba(212,175,55,0.10) !important;
    color: #FFF6DC !important;
}
#rankings-section .ranking-table tbody tr:hover td:first-child {
    color: #FAD02C !important;
}

/* 6) 입력칸 — 다크 글래스 */
#wallet-section input,
#wallet-section select {
    background: rgba(255,255,255,0.06) !important;
    color: #E6EFEA !important;
    border: 1px solid rgba(255,255,255,0.16) !important;
    border-radius: 10px !important;
}
#wallet-section input::placeholder {
    color: #7E948B !important;
}

/* 7) apple.css 의 #rules-section p/li/strong (다크 #1D1D1F) 덮어쓰기.
   #rules-section li (1,0,1) 동일 구체성 + readability.css 가 나중 로드 → 승리. */
#rules-section p, #rules-section li,
#rules-section strong, #rules-section b,
#rules-section td, #rules-section th,
#wallet-section p, #wallet-section li, #wallet-section strong, #wallet-section b {
    color: #E6EFEA !important;
}

/* 8) 모드 탭 (괴물/조커) — active=골드(어두운 글자), inactive=글래스(밝은 글자) */
#rules-section .btn-option {
    color: #E6EFEA !important;
    background: rgba(255, 255, 255, 0.06) !important;
    border: 1px solid rgba(255, 255, 255, 0.20) !important;
}
#rules-section .btn-option.active,
#rules-section #tab-monster.active,
#rules-section #tab-joker.active {
    background: linear-gradient(135deg, #EBCE74 0%, #D4AF37 100%) !important;
    color: #0C2A1B !important;
    border-color: #D4AF37 !important;
}

/* 9) 지갑 "최근 7일 내역" 테이블 — apple.css 의 흰 배경 제거.
   th=var(--bg-soft)#FAFAFA, items>div=var(--bg2)#FDFDFE, td=var(--text)검정 →
   골드틴트 헤더 + 다크 행 + 밝은 글자로 통일(랭킹 테이블과 동일 톤). */
#wallet-daily table,
#wallet-items table {
    border: 1px solid rgba(212,175,55,0.20) !important;
    border-radius: 12px !important;
    overflow: hidden !important;
}
#wallet-daily table th,
#wallet-items table th {
    background: rgba(212,175,55,0.12) !important;   /* 흰색 헤더 → 골드 틴트 */
    color: #E0CB8E !important;
    border-bottom: 1px solid rgba(212,175,55,0.25) !important;
}
#wallet-daily table td,
#wallet-items table td {
    color: #E6EFEA !important;                       /* 검정 var(--text) → 밝게 */
    border-bottom: 1px solid rgba(255,255,255,0.06) !important;
}
#wallet-daily table tbody tr:nth-child(even) td,
#wallet-items table tbody tr:nth-child(even) td {
    background: rgba(255,255,255,0.022) !important;
}
/* "전체 신청 N건 (최신순)" 캡션 박스 — 흰색 var(--bg2) → 옅은 다크 글래스 */
#wallet-items > div {
    background: rgba(255,255,255,0.045) !important;
    border: 1px solid rgba(212,175,55,0.16) !important;
    box-shadow: none !important;
    color: #B7CDC2 !important;
}
/* "승인된 충환전이 없습니다" 등 안내 문구 영역 — 배경 없이 */
#wallet-daily > div {
    background: transparent !important;
}
