/* 遊戲總表 */
.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5em;
    margin-top: 1em;
}

.game-card {
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    text-align: center;
    padding: 1em;
    transition: box-shadow 0.3s;
}

.game-card:hover {
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.placeholder {
    height: 150px;
    background: #eee;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #777;
    font-size: 0.9em;
}

.game-en {
    font-weight: normal;
    font-size: 0.9em;
    color: #666;
}

/* 遊戲資訊頁 */
.game-info {
}

.game-banner {
    text-align: center;
    margin-bottom: 1.5em;
}

.game-banner img {
    width: 100%;
    max-height: 250px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid #ccc;
}

.banner-placeholder {
    width: 100%;
    height: 250px;
    background: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: 1.2em;
    border-radius: 10px;
    border: 1px dashed #aaa;
}

.game-details h1 {
    font-size: 2em;
    text-align: center;
    margin-bottom: 1em;
}

.game-sections {
    display: flex;
    flex-direction: column;
    gap: 2em;
}

.game-sections .section h2 {
    font-size: 1.4em;
    margin-bottom: 0.5em;
    border-left: 4px solid #2a7;
    padding-left: 0.5em;
    color: #2a7;
}

.game-sections .section-content {
    padding-left: 1em;
    color: #444;
    line-height: 1.6;
}
.tournament-count {
    font-size: 0.9em;
    color: #444;
    margin-top: 0.5em;
}

.event-indicator {
    position: absolute;
    bottom: 4px;
    right: 4px;
    background: #555;
    padding: 2px 4px;
    font-size: 0.75em;
    border-radius: 3px;
}
.game-list{
	margin: 0 1em;
	}
        .filter-bar, .search-bar { margin-bottom: 1em; }
        .filter-bar select,
        .search-bar input {
            padding: 0.5em;
            font-size: 1em;
        }
        .search-bar input { width: 250px; }

        .suggest-box {
            position: absolute;
            background: #fff;
            border: 1px solid #ccc;
            max-height: 200px;
            overflow-y: auto;
            z-index: 99;
            width: 250px;
            display: none;
        }
        .suggest-box div {
            padding: 8px;
            cursor: pointer;
        }
        .suggest-box div:hover {
            background-color: #f0f0f0;
        }

        .game-grid {
            display: flex;
            flex-wrap: wrap;
            gap: 1rem;
        }
        .game-card {
            width: calc(25% - 1rem);
            border: 1px solid #ccc;
            border-radius: 8px;
            padding: 2px;
            background: #fff;
        }
        .game-card img {
			object-fit: cover;
			border-radius: 6px;
			margin-bottom: 0.5em;
			aspect-ratio: 16 / 9;
			width: 100%;
			height: auto;
        }

        .filter-bar.filter-row {
            display: flex;
            align-items: center;
            flex-wrap: nowrap;
        }
        .filter-bar.filter-row label {
            margin: 0;
        }
        .filter-bar.filter-row select {
            min-width: 150px;
    margin: 0 0.5em 0 0;
        }

        @media (max-width: 768px) {
            .game-card {
                width: calc(50% - 0.5rem);
            }
        }
        .game-banner {
            background: url('<?= $image_path ?>') center/cover no-repeat;
            height: 240px;
        }
        .game-title {
            font-size: 1.5em;
            font-weight: bold;
			margin: 1em;
        }
		.game-nav{
			display: flex;
			flex-wrap: wrap;
			margin:1em;
			}
        .game-nav a {
			padding: 0.5em 1em;
			display: inline-block;
			text-decoration: none;
			background: #eee;
			color: #333;
			border-radius: 5px;
			margin: 0 5px;
        }
		@media (max-width: 768px) {
			.game-nav a {
			margin: 0 1px;
        }
			}
		
        .game-nav a.active {
            background: #333;
            color: #fff;
        }
        .game-content {
            padding: 1em;
        }
        .section-title {
			font-weight: bold;
			font-size: 1.2em;
			display: inline-grid;
			border-bottom: 2px solid #ccc;
        }
        .info-list {
            margin-left: 1em;
        }
		
		.calendar-controls{
			text-align:center;
			}
.ranking-tabs{margin: -1em 0em 1em 0;}
.ranking-tabs button{
	font-weight: normal;
    line-height: 0.5em;
    padding: 0.8em 1em;
    background: #333;
    color: #ffffff;
    border-radius: 3px;
	margin: 0 0 0 1em;}
.ranking-tabs button.active{
	background: #e10;
    color: #fff;}
.floating-button {
	position: fixed;
    right: 20px;
    bottom: 20px;
    background-color: #ee1100;
    color: #fff;
    border: none;
    padding: 10px 14px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
}
.floating-button:hover {
    background-color: #000;
}
        .hot-game-btn {
			cursor: pointer;
			line-height: 2em;
			font-weight: inherit;
			padding: 0.1em 0.5em;
			background: #eee;
			border-radius: 5px;
			text-decoration: none;
			color: #333;
			margin-bottom: 0.5em;
        }
        .hot-game-btn:hover {
			background: #555;
			color: #fff;
        }
.section_calendar{
	margin: 1em;
    width: 90%;
    display: inline-grid;
	}		