:root {
	--accent: #f9e2af;
	--bg-2: hsl(220, 10%, 17%);
	--bg-3: hsl(220, 10%, 11%);
	--bg-4: hsl(220, 10%, 16%);
	--bg-t-2: hsla(220, 12%, 5%, 0.5);
	--bg-t: hsla(220, 12%, 5%, 0.25);
	--bg: hsl(220, 10%, 8%);
	--border-d: #334155;
	--border: hsl(0, 0%, 100%);
	--error: #f38ba8;
	--gradient-primary: linear-gradient(90deg, #CF5DEB 0%, #9F3DFA 100%);
	--gradient-secondary: linear-gradient(90deg, var(--txt-1) 0%, var(--txt) 100%);
	--success: #a6e3a1;
	--txt-1: hsl(220, 45%, 90%);
	--txt-2: hsl(220, 14%, 55%);
	--txt-3: hsl(220, 11%, 35%);
	--txt-4: #000000;
	--txt: hsl(220, 30%, 80%);
}

html,
body {
    background-color: var(--bg);
}

.game-container {
	background: var(--bg-2);
	border-radius: 20px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin: 0 auto;
	max-width: 400px;
	padding: 20px;
	width: 100%;
}

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

.score-display {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 15px;
	padding: 10px;
	background: var(--bg-3);
	border-radius: 10px;
}

.score {
	font-size: 20px;
	font-weight: bold;
	color: #4ECDC4;
}

.combo {
	font-size: 16px;
	color: var(--error);
	font-weight: bold;
}

.game-board {
	width: 320px;
	height: 320px;
	margin: 0 auto 20px;
	display: grid;
	grid-template-columns: repeat(8, 1fr);
	grid-template-rows: repeat(8, 1fr);
	gap: 2px;
	background: var(--bg-3);
	padding: 10px;
	border-radius: 15px;
	box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.1);
}

.cell {
	background: var(--bg-3);
	border-radius: 4px;
	transition: all 0.2s ease;
	border: 1px solid var(--border);
}

.cell.filled {
	background: #4ECDC4;
	box-shadow: 0 2px 4px rgba(78, 205, 196, 0.3);
}

.cell.highlight {
	background: #F7DC6F !important;
	transform: scale(1.1);
}

@keyframes clearEffect {
    0% {
        transform: scale(1.2);
        background: #4ECDC4;
    }
    50% {
        transform: scale(1.3);
        background: #F7DC6F;
    }
    100% {
        transform: scale(1);
        background: var(--bg-3);
    }
}

.cell.clear-animation {
    animation: clearEffect 0.5s ease-out;
    animation-fill-mode: forwards;
}

.blocks-container {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	margin-bottom: 20px;
}

.block-preview {
	flex: 1;
	min-height: 80px;
	background: var(--bg-3);
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: all 0.2s ease;
	border: 2px solid transparent;
	position: relative;
}

.block-preview:hover {
	background-color: transparent;
	box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
	transform: translateY(-2px);
}

.block-preview.selected {
	border-color: #4ECDC4;
	background: #E8F8F5;
}

.block-preview.disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.block-shape {
	display: grid;
	gap: 2px;
}

.block-cell {
	width: 12px;
	height: 12px;
	background: #4ECDC4;
	border-radius: 2px;
}

.game-over {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.8);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 1000;
}

.game-over-content {
	background: white;
	padding: 30px;
	border-radius: 20px;
	text-align: center;
	max-width: 300px;
}

.game-over-content p {
	color: var(--txt-4);
}

.game-over h2 {
	color: #FFB6B3;
	margin-bottom: 10px;
}

.final-score {
	font-size: 24px;
	color: #4ECDC4;
	font-weight: bold;
	margin-bottom: 20px;
}

.btn {
	background: #4ECDC4;
	color: white;
	border: none;
	padding: 12px 24px;
	border-radius: 10px;
	font-size: 16px;
	cursor: pointer;
	transition: all 0.2s ease;
	margin: 5px;
}

.btn:hover {
	background: #45B7AA;
	transform: translateY(-1px);
}

.power-ups {
	display: flex;
	justify-content: center;
	gap: 10px;
	margin-bottom: 15px;
}

.power-up {
	background: #C7CEEA;
	border: none;
	padding: 8px 12px;
	border-radius: 8px;
	cursor: pointer;
	font-size: 12px;
	color: var(--txt-4);
	transition: all 0.2s ease;
}

.power-up:hover {
	background: #A8B3E5;
	transform: scale(1.05);
}

.power-up:disabled {
	opacity: 0.5;
	cursor: not-allowed;
}

.coins {
	text-align: center;
	margin-bottom: 10px;
	font-size: 14px;
	color: #F7DC6F;
	font-weight: bold;
}

.drag-preview {
	position: fixed;
	pointer-events: none;
	z-index: 1000;
	opacity: 0.8;
}

.stats {
	display: flex;
	justify-content: space-between;
	font-size: 12px;
	color: #666;
	margin-top: 10px;
}

@media (max-width: 480px) {
	.game-container {
		padding: 15px;
	}

	.game-board {
		width: 280px;
		height: 280px;
	}

	.block-cell {
		width: 10px;
		height: 10px;
	}
}
