/* General Game Styles */
.slg-game-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 500px;
    margin: 20px auto 10px auto;
    padding: 0 10px;
}

.slg-user-points-display {
    font-weight: bold;
    font-size: 16px;
    white-space: nowrap;
}

.slg-return-member-area-btn {
    display: inline-block;
    padding: 8px 15px;
    background: #C39F57;
    border: 1px solid #C39F57;
    border-radius: 10px;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    text-align: center;
    transition: all 0.3s ease;
    box-sizing: border-box;
    white-space: nowrap;
}

.slg-return-member-area-btn:hover {
    background: #a8843e;
    border-color: #a8843e;
    color: #fff;
}

.slg-game-actions {
    max-width: 500px;
    margin: 10px auto;
    text-align: center;
}


/* --- Lucky Wheel Game Styles --- */
.slg-lucky-wheel-container {
    text-align: center;
    margin: 10px auto 30px auto;
    max-width: 400px;
}

.slg-lucky-wheel-game {
    position: relative;
    display: inline-block;
    margin-bottom: 20px;
}

#slg-lucky-canvas {
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(0,0,0,0.3);
    transition: transform 0.1s ease;
}

.slg-lucky-pointer {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 15px solid transparent;
    border-right: 15px solid transparent;
    border-top: 25px solid #e74c3c;
    z-index: 10;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
}

.slg-lucky-spin-btn {
    display: block;
    margin: 20px auto;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: bold;
    background: #C39F57;
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
    transition: all 0.3s ease;
    min-width: 150px;
}

.slg-lucky-spin-btn:hover {
    background: #f00 !important;
	border-color: #f00 !important;
	color: #fff !important;
}

.slg-lucky-spin-btn:active {
    transform: translateY(0);
}

.slg-lucky-spin-btn:disabled {
    background: #95a5a6;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.slg-lucky-result {
    margin-top: 20px;
    padding: 15px 20px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 15px;
    background: linear-gradient(145deg, #ecf0f1, #bdc3c7);
    border: 2px solid #95a5a6;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease;
    max-width: 350px;
}

.slg-lucky-result.winner {
    background: linear-gradient(145deg, #2ecc71, #27ae60);
    color: white;
    border-color: #2ecc71;
    animation: celebration 1s ease-in-out;
    box-shadow: 0 0 20px rgba(46, 204, 113, 0.5);
}

@keyframes celebration {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.05) rotate(-1deg); }
    75% { transform: scale(1.05) rotate(1deg); }
}

@keyframes wheelSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* --- Premium Slots Game --- */
.slg-premium-slots-container {
    max-width: 500px;
    margin: 20px auto;
    font-family: 'Arial', sans-serif;
}

.slg-premium-slots-machine {
    background: linear-gradient(145deg, #2C3E50, #34495E);
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    border: 3px solid #F39C12;
}

.slg-premium-slots-header {
    margin-bottom: 20px;
    padding: 0 10px;
}

.slg-premium-slots-header h3 {
    color: #F39C12;
    margin: 0;
    font-size: 24px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.slg-premium-cost {
    color: white;
    font-size: 18px;
    font-weight: bold;
    background: rgba(231,76,60,0.1);
    padding: 5px 15px;
    border-radius: 20px;
    border: 2px solid #E74C3C;
}

.slg-premium-slots-body {
    position: relative;
    background: linear-gradient(145deg, #1A252F, #2C3E50);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    border: 2px solid #34495E;
}

.slg-premium-reels {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.slg-premium-reel {
    width: 80px;
    height: 120px;
    background: linear-gradient(145deg, #ECF0F1, #BDC3C7);
    border: 3px solid #34495E;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.3);
}

.slg-premium-symbols {
    position: absolute;
    width: 100%;
    transition: transform 0.1s ease;
}

.slg-premium-symbol {
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    background: linear-gradient(145deg, #FFFFFF, #F8F9FA);
    border-bottom: 1px solid #DEE2E6;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.slg-premium-reel.spinning .slg-premium-symbols {
    animation: reelSpin 0.1s linear infinite;
}

.slg-premium-payline {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #E74C3C, #E74C3C, transparent);
    transform: translateY(-50%);
    box-shadow: 0 0 10px #E74C3C;
}

.slg-premium-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.slg-premium-spin-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 25px;
    font-size: 18px;
    font-weight: bold;
    background: linear-gradient(145deg, #E74C3C, #C0392B);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(231,76,60,0.4);
    transition: all 0.3s ease;
    min-width: 150px;
    justify-content: center;
    margin-left: auto;
}

.slg-premium-spin-btn:hover {
    background: linear-gradient(145deg, #C0392B, #E74C3C);
    transform: translateY(-2px);
    box-shadow: 0 7px 20px rgba(231,76,60,0.5);
}

.slg-premium-spin-btn:active {
    transform: translateY(0);
}

.slg-premium-spin-btn:disabled {
    background: #7F8C8D;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.slg-premium-lever {
    font-size: 24px;
    animation: leverBounce 2s ease-in-out infinite;
}

.slg-premium-result {
    text-align: center;
    padding: 15px 20px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 15px;
    background: linear-gradient(145deg, #34495E, #2C3E50);
    color: #ECF0F1;
    border: 2px solid #7F8C8D;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease;
}

.slg-premium-result.win {
    background: linear-gradient(145deg, #27AE60, #2ECC71);
    color: white;
    border-color: #27AE60;
    animation: premiumWin 1s ease-in-out;
    box-shadow: 0 0 25px rgba(39,174,96,0.6);
}

.slg-premium-result.jackpot {
    background: linear-gradient(145deg, #F39C12, #E67E22);
    color: white;
    border-color: #F39C12;
    animation: jackpotWin 1.5s ease-in-out;
    box-shadow: 0 0 30px rgba(243,156,18,0.8);
}

@keyframes reelSpin {
    0% { transform: translateY(0); }
    100% { transform: translateY(-80px); }
}

@keyframes leverBounce {
    0%, 100% { transform: rotate(0deg); }
    50% { transform: rotate(10deg); }
}

@keyframes premiumWin {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.05) rotate(-1deg); }
    75% { transform: scale(1.05) rotate(1deg); }
}

@keyframes jackpotWin {
    0%, 100% { transform: scale(1) rotate(0deg); }
    25% { transform: scale(1.1) rotate(-2deg); }
    50% { transform: scale(1.05) rotate(0deg); }
    75% { transform: scale(1.1) rotate(2deg); }
}

/* --- Scratch Card Game --- */
.slg-scratch-container {
    text-align: center;
    margin: 10px auto 30px auto;
    max-width: 400px;
    font-family: 'Arial', sans-serif;
}

.slg-scratch-game {
    background: linear-gradient(145deg, #f8f9fa, #e9ecef);
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 2px solid #dee2e6;
}

.slg-scratch-game h3 {
    color: #495057;
    margin: 0 0 20px 0;
    font-size: 24px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.slg-scratch-card {
    position: relative;
    margin: 0 auto 20px;
    display: inline-block;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    width: 300px;
    aspect-ratio: 3 / 2;
}

#slg-scratch-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: crosshair;
    z-index: 2;
    border-radius: 15px;
}

.slg-scratch-hidden-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #ffd700, #ffed4a);
    border-radius: 15px;
    z-index: 1;
}

#slg-scratch-prize {
    font-size: 48px;
    margin-bottom: 10px;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.3));
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

#slg-scratch-text {
    font-size: 16px;
    font-weight: bold;
    color: #8b4513;
    text-shadow: 1px 1px 2px rgba(255,255,255,0.8);
}

.slg-scratch-reset-btn {
    padding: 12px 25px;
    font-size: 16px;
    font-weight: bold;
    background: #C39F57 !important;
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
    transition: all 0.3s ease;
    margin-bottom: 15px;
}

.slg-scratch-reset-btn:hover {
    background: #f00 !important;
	border-color: #f00 !important;
	color: #fff !important;
}

.slg-scratch-reset-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.slg-scratch-result {
    padding: 15px 20px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 15px;
    background: linear-gradient(145deg, #e9ecef, #dee2e6);
    color: #495057;
    border: 2px solid #ced4da;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease;
}

.slg-scratch-result.revealed {
    background: linear-gradient(145deg, #28a745, #20c997);
    color: white;
    border-color: #28a745;
    animation: scratchReveal 1s ease-in-out;
    box-shadow: 0 0 20px rgba(40, 167, 69, 0.5);
}

@keyframes scratchReveal {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.05) rotate(-1deg); }
    75% { transform: scale(1.05) rotate(1deg); }
}


/* --- Symbol Match Scratch Game --- */
.slg-symbol-match-container {
    max-width: 500px;
    min-height: 600px;
    margin: 10px auto 20px auto;
    padding: 20px;
    font-family: Arial, sans-serif;
    background-color: #f4f7f6;
    background-size: cover;
    background-position: center;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    position: relative;
    display: flex;
    flex-direction: column;
}

.slg-symbol-match-game {
    flex-grow: 1;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slg-symbol-match-winning-area {
    display: none;
}

.slg-symbol-match-scratch-area {
    width: 90%;
    max-width: 400px;
    background: transparent;
    padding: 0;
    border: none;
    border-radius: 10px;
}

.slg-symbol-match-scratch-area h4 {
    display: none;
}

.slg-symbol-match-card {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 10px;
    background-color: transparent;
}

.slg-game-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 0;
}

#slg-symbol-match-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: crosshair;
    z-index: 2;
    border-radius: 10px;
}

#slg-symbol-match-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 10px;
    background: transparent;
    border-radius: 10px;
    box-sizing: border-box;
    z-index: 1;
}

.slg-symbol-match-grid-item {
    display: block;
    position: absolute;
    width: 50px;
    height: 50px;
    font-size: 32px;
    text-align: center;
    line-height: 50px;
}

.slg-symbol-match-btn {
    display: inline-block !important; /* Changed from block */
	/* align-items: center; */ /* Not needed for inline-block */
	/* justify-content: center; */ /* Not needed for inline-block */
	/* flex: none; */ /* Not needed for inline-block */
	margin: 10px auto !important; /* Centered horizontally with text-align: center on parent */
	width: auto !important; /* Allow content to define width, or set a specific one */
	max-width: 200px !important;
	min-width: 180px !important;
	padding: 9px 10px 11px 10px !important;
	line-height: 1.3em !important;
	background: #C39F57 !important;
	border: 1px solid #C39F57 !important;
	border-radius: 10px !important;
	color: #fff !important;
	font-size: 16px !important;
	font-weight: bold !important;
	text-decoration: none !important;
	text-align: center !important;
	transition: all 0.3s ease !important;
	box-sizing: border-box !important;
	white-space: nowrap !important;
	/* float: none; */ /* Not needed */
	position: relative !important;
	vertical-align: top !important;
}

.slg-symbol-match-btn:hover {
    background: #f00 !important;
	border-color: #f00 !important;
	color: #fff !important;
}

#slg-symbol-match-result {
    margin-top: 10px;
    padding: 15px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    border-radius: 10px;
    display: none;
}

#slg-symbol-match-result.winner {
    display: block;
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#slg-symbol-match-result.loser {
    display: block;
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}
