:root {
    --primary-color: #00f3ff;
    --secondary-color: #ff007f;
    --background-dark: #0b0f19;
    --text-light: #e0e6ed;
    --text-muted: #8b9bb4;
    --glass-bg: rgba(20, 30, 48, 0.6);
    --glass-border: rgba(255, 255, 255, 0.1);
}

body, html {
    margin: 0; padding: 0;
    width: 100%; min-height: 100vh;
    background-color: var(--background-dark);
    color: var(--text-light);
    font-family: 'Noto Sans JP', sans-serif;
    overflow-x: hidden;
}

.background-particles {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1;
    background: radial-gradient(circle at center, #1b2735 0%, #090a0f 100%);
}

.particle {
    position: absolute;
    background: rgba(0, 243, 255, 0.5);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(0, 243, 255, 0.8);
}

@keyframes float {
    0% { transform: translateY(0) translateX(0); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: translateY(-100vh) translateX(100px); opacity: 0; }
}

.hero-section {
    text-align: center; padding: 80px 20px 40px;
}

.portal-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 4rem; color: #fff;
    text-shadow: 0 0 10px var(--primary-color), 0 0 20px var(--primary-color);
    margin-bottom: 10px;
}

.portal-subtitle {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem; color: var(--primary-color);
    letter-spacing: 2px;
}

.games-showcase {
    max-width: 1200px; margin: 0 auto; padding: 20px;
    display: flex; flex-direction: column; gap: 40px;
}

.ranking-container {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 15px; padding: 30px;
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}

.section-title {
    font-family: 'Orbitron', sans-serif; font-size: 2rem; color: #fff;
    margin-bottom: 20px; border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px; display: inline-block;
}

.subtitle-jp { font-family: 'Noto Sans JP', sans-serif; font-size: 1rem; color: var(--text-muted); margin-left: 10px; }

.ranking-list { display: flex; flex-wrap: wrap; gap: 20px; list-style: none; padding: 0; margin: 0; }

.ranking-card {
    flex: 1 1 300px;
    background: rgba(0,0,0,0.4);
    border: 1px solid var(--glass-border);
    border-radius: 10px; padding: 15px;
    display: flex; align-items: center; gap: 15px;
}

.ranking-badge { font-size: 2rem; }
.ranking-icon { font-size: 2.5rem; }
.ranking-info h3 { margin: 0 0 5px; font-size: 1.2rem; }
.ranking-stats-row { display: flex; justify-content: space-between; align-items: center; }
.ranking-count { color: var(--primary-color); font-weight: bold; font-size: 0.9rem; }

.game-card {
    display: flex; flex-direction: row; gap: 30px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px; overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    backdrop-filter: blur(10px);
}

@media (max-width: 768px) {
    .game-card { flex-direction: column; gap: 0px; }
    .portal-title { font-size: 2.5rem; }
    
    /* スマホ版：ランキング部分の縦幅を削減 */
    .ranking-container { padding: 15px; border-radius: 10px; }
    .ranking-card { padding: 10px; flex-direction: row; gap: 10px; }
    .ranking-badge { font-size: 1.5rem; margin-right: 5px; }
    .ranking-icon { font-size: 1.8rem; }
    .ranking-info h3 { font-size: 1rem; margin-top: 0; }
    .games-showcase { gap: 15px; padding: 10px; }
    .section-title { font-size: 1.4rem; margin-bottom: 10px; padding-bottom: 5px; }
    
    /* スマホ版：ゲーム紹介カードの画像/アイコンエリアを大幅に縮小 */
    .card-visual { min-height: 80px; height: 80px; display: flex; align-items: center; justify-content: center; }
    .card-details { padding: 12px 15px; }
    .card-details h2 { font-size: 1.2rem; margin-bottom: 8px; }
    
    /* 概要文の行数を制限して高さを抑える */
    .game-description {
        font-size: 0.85rem;
        margin-bottom: 10px;
        line-height: 1.4;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    
    .tags { margin-bottom: 10px; gap: 5px; }
    .tag { padding: 3px 8px; font-size: 0.75rem; }
    .card-actions { gap: 10px; }
    .btn { padding: 8px 15px; font-size: 0.85rem; }
    
    /* 各種エフェクト・ロゴ文字などの縮小 */
    .glitch-text { font-size: 1.5rem; }
    .portal-hoops-img { width: 50px; margin-bottom: 5px; }
    .glow-title-portal { font-size: 1.3rem; }
    .ojisan-emoji { font-size: 1.5rem; margin-bottom: 2px; }
    .ojisan-title { font-size: 1rem; }
    .visual-content span { font-size: 1.5rem !important; } /* 直接スタイル指定されているタイトルも縮小対象にする */
    
    /* スマホ版：アップデート情報の縮小 */
    .glass-card { padding: 20px; margin-bottom: 25px; } /* 全体コンテナの余白削減 */
    .glass-card h2 { font-size: 1.4rem !important; margin-bottom: 15px !important; }
    .news-item { margin-bottom: 15px; padding-bottom: 15px; }
    .news-date { font-size: 0.85rem; margin-bottom: 5px; }
    .news-item h3 { font-size: 1.05rem; margin-bottom: 8px; line-height: 1.3; }
    .news-item p {
        font-size: 0.85rem;
        line-height: 1.5;
        /* 長すぎる場合は3行で省略表示 */
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    
    /* FAQの縮小 */
    .faq-item summary { padding: 12px 15px; font-size: 0.95rem; }
    .faq-item summary::after { top: 10px; right: 15px; font-size: 1.2rem; }
    .faq-content { padding: 0 15px 15px; font-size: 0.85rem; }
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 243, 255, 0.2);
    border-color: rgba(0, 243, 255, 0.4);
}

.card-visual {
    flex: 1; min-height: 250px; position: relative;
    overflow: hidden; display: flex; justify-content: center; align-items: center;
}

.card-details {
    flex: 2; padding: 30px; display: flex; flex-direction: column;
}

.card-details h2 { font-size: 2rem; margin-bottom: 15px; color: #fff; }

.tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.tag { background: rgba(255,255,255,0.1); color: #fff; padding: 5px 12px; border-radius: 20px; font-size: 0.85rem; font-weight: bold; }

.game-description { color: var(--text-light); line-height: 1.6; margin-bottom: 25px; flex-grow: 1; }
.game-description strong { color: var(--primary-color); }

.card-actions { display: flex; gap: 15px; flex-wrap: wrap; }

.btn {
    padding: 12px 25px; border-radius: 30px; font-weight: bold; text-decoration: none;
    text-align: center; transition: all 0.3s; border: none; cursor: pointer;
}
.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), #00eeff);
    color: #000; box-shadow: 0 0 15px rgba(0, 243, 255, 0.4);
}
.btn-primary:hover { box-shadow: 0 0 25px rgba(0, 243, 255, 0.8); transform: scale(1.05); }

.btn-secondary { background: transparent; color: #fff; border: 1px solid var(--primary-color); }
.btn-secondary:hover { background: rgba(0, 243, 255, 0.1); color: var(--primary-color); }

.play-btn-small {
    padding: 5px 15px; border-radius: 15px; background: var(--primary-color); color: #000;
    text-decoration: none; font-weight: bold; font-size: 0.9rem;
}

.glass-card {
    background: var(--glass-bg); border: 1px solid var(--glass-border);
    border-radius: 20px; padding: 40px; margin-bottom: 40px;
    backdrop-filter: blur(10px);
}

.news-item { margin-bottom: 30px; padding-bottom: 30px; border-bottom: 1px solid var(--glass-border); }
.news-item:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.news-date { color: var(--primary-color); font-family: 'Orbitron', sans-serif; font-weight: bold; margin-bottom: 10px; }
.news-item h3 { font-size: 1.3rem; margin-bottom: 15px; line-height: 1.4; color: #fff; }
.news-item p { color: var(--text-light); line-height: 1.7; }

.faq-item { margin-bottom: 15px; background: rgba(0,0,0,0.3); border-radius: 10px; border: 1px solid var(--glass-border); }
.faq-item summary { padding: 18px 20px; font-weight: bold; cursor: pointer; list-style: none; position: relative; color: #fff; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; position: absolute; right: 20px; color: var(--primary-color); font-size: 1.5rem; top: 15px; }
.faq-item[open] summary::after { content: '-'; }
.faq-content { padding: 0 20px 20px; color: var(--text-light); line-height: 1.6; }

.about-us-details h3 { font-size: 1.4rem; color: var(--primary-color); margin: 30px 0 15px; }
.about-us-details p { line-height: 1.8; margin-bottom: 20px; }

footer { text-align: center; padding: 40px 20px; margin-top: 60px; border-top: 1px solid var(--glass-border); color: var(--text-muted); }
.footer-link { color: var(--text-light); text-decoration: none; margin: 0 10px; transition: color 0.3s; }
.footer-link:hover { color: var(--primary-color); }

.ofuse-floating-btn {
    position: fixed; bottom: 30px; right: 30px; z-index: 1000;
    background: #ff5a5f; color: white; padding: 15px 25px; border-radius: 30px;
    text-decoration: none; font-weight: bold; box-shadow: 0 4px 15px rgba(255, 90, 95, 0.5);
    display: flex; align-items: center; gap: 10px; transition: transform 0.3s;
}
.ofuse-floating-btn:hover { transform: scale(1.1) translateY(-5px); }

/* --- Game Specific Visual Themes --- */
.flashback-theme { background: #000; }
.glitch-text {
    font-family: 'Orbitron', sans-serif; font-size: 2.5rem; font-weight: 900; color: #fff;
    position: relative; text-shadow: 0.05em 0 0 rgba(255,0,0,0.75), -0.025em -0.05em 0 rgba(0,255,0,0.75), 0.025em 0.05em 0 rgba(0,0,255,0.75);
    animation: glitch 500ms infinite;
}
@keyframes glitch {
  0% { text-shadow: 0.05em 0 0 rgba(255,0,0,0.75), -0.05em -0.025em 0 rgba(0,255,0,0.75), -0.025em 0.05em 0 rgba(0,0,255,0.75); }
  50% { text-shadow: 0.025em 0.05em 0 rgba(255,0,0,0.75), 0.05em 0 0 rgba(0,255,0,0.75), 0 -0.05em 0 rgba(0,0,255,0.75); }
  100% { text-shadow: -0.025em 0 0 rgba(255,0,0,0.75), -0.025em -0.025em 0 rgba(0,255,0,0.75), -0.025em -0.05em 0 rgba(0,0,255,0.75); }
}

.neon-hoops-theme { background: #110022; }
.portal-hoops-img { width: 120px; margin-bottom: 20px; filter: drop-shadow(0 0 10px #ff00ff); }
.glow-title-portal { font-family: 'Orbitron', sans-serif; font-size: 2rem; color: #fff; text-shadow: 0 0 10px #ff00ff, 0 0 20px #ff00ff, 0 0 30px #ff00ff; }

/* Ojisan Banner Styles */
.ojisan-emoji { font-size: 3rem; margin-bottom: 10px; }
.ojisan-title { font-family: 'Noto Sans JP', sans-serif; font-size: 1.5rem; font-weight: bold; color: #2c3e50; text-shadow: 1px 1px 0px #fff; }

/* --- A8.net 広告枠スタイル --- */
.a8-ad-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 40px auto 20px;
    padding: 10px;
    text-align: center;
    width: 100%;
    z-index: 5;
}

.a8-ad-wrapper .ad-pc {
    display: block;
}

.a8-ad-wrapper .ad-sp {
    display: none;
}

@media (max-width: 768px) {
    .a8-ad-wrapper .ad-pc {
        display: none;
    }
    .a8-ad-wrapper .ad-sp {
        display: block;
    }
}