/* レトロゲームポータルサイトのスタイル */
@font-face {
    font-family: 'DotGothic16';
    src: url('public/DotGothic16-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'DotGothic16', 'MS PGothic', 'MS Gothic', monospace;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40"><rect width="40" height="40" fill="%23d4a574"/><rect width="20" height="20" fill="%23c19a6b"/><rect x="20" y="20" width="20" height="20" fill="%23c19a6b"/></svg>');
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* ヘッダー部分 */
header {
    text-align: center;
    margin-bottom: 30px;
}

.ai-banner {
    background: #4CAF50;
    color: white;
    padding: 10px;
    font-weight: bold;
    margin-bottom: 20px;
}

.title-section {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-bottom: 20px;
}

.main-title {
    font-size: 3.5em;
    font-weight: bold;
    color: #333;
    text-shadow: 3px 3px 0px rgba(0,0,0,0.3);
    letter-spacing: 2px;
}

.counter {
    font-size: 2em;
    font-weight: bold;
    color: #333;
    background: #f0f0f0;
    padding: 10px 20px;
    border: 3px solid #333;
    font-family: 'DotGothic16', 'MS PGothic', 'MS Gothic', monospace;
}

.info-box {
    position: absolute;
    top: 20px;
    left: 20px;
    background: white;
    border: 3px solid #ff0000;
    padding: 10px;
    font-size: 0.9em;
    font-weight: bold;
}

.visitor-banner {
    background: #8B0000;
    color: white;
    padding: 15px;
    font-weight: bold;
    overflow: hidden;
    position: relative;
}

.visitor-text {
    white-space: nowrap;
    display: inline-block;
    animation: scrollText 15s linear infinite;
}

@keyframes scrollText {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

.visitor-count {
    color: #FFA500;
    font-size: 1.2em;
    font-weight: bold;
}

/* メインコンテンツ */
main {
    display: flex;
    gap: 30px;
}

/* サイドメニュー */
.side-menu {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 150px;
}

.menu-btn {
    background: #FF69B4;
    color: white;
    border: 3px solid #4CAF50;
    padding: 12px 15px;
    font-weight: bold;
    cursor: pointer;
    font-family: 'DotGothic16', 'MS PGothic', 'MS Gothic', monospace;
}

.menu-btn:hover {
    background: #FF1493;
}

/* ゲームセクション */
.games-section {
    flex: 1;
    padding: 20px;
}

/* ソート機能 */
.sort-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sort-controls label {
    font-weight: bold;
    color: #333;
}

.sort-dropdown {
    padding: 8px 12px;
    border: 2px solid #333;
    background: white;
    font-family: inherit;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
}

.sort-dropdown:hover {
    border-color: #333;
    background: #f8f8f8;
}

.sort-dropdown:focus {
    outline: none;
    border-color: #333;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

.filter-dropdown {
    padding: 8px 12px;
    border: 2px solid #333;
    background: white;
    font-family: inherit;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-dropdown:hover {
    border-color: #333;
    background: #f8f8f8;
}

.filter-dropdown:focus {
    outline: none;
    border-color: #333;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
    justify-content: center;
}

.game-card {
    background: white;
    border: 3px solid #333;
    overflow: hidden;
    transition: transform 0.3s ease;
    cursor: pointer;
    max-width: 400px;
    justify-self: center;
}

.game-card:hover {
    transform: translateY(-5px);
}

.game-title {
    background: #4A90E2;
    color: white;
    padding: 10px;
    font-weight: bold;
    text-align: center;
    font-size: 1.1em;
}

.game-preview {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.game-description {
    padding: 15px;
    background: #f9f9f9;
    font-size: 0.9em;
    line-height: 1.4;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .title-section {
        flex-direction: column;
        gap: 15px;
    }
    
    .main-title {
        font-size: 2.5em;
    }
    
    main {
        flex-direction: column;
    }
    
    .side-menu {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .games-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .info-box {
        position: static;
        margin-bottom: 20px;
    }
}

/* アニメーション */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.game-card {
    animation: fadeIn 0.6s ease-out;
} 