:root {
    --bg-color: #0f0f13;
    --text-color: #e0e0e0;
    --accent-color: #5865F2; /* Discord Blurple */
    --secondary-color: #ff005c; /* アクセント用のピンク */
    --card-bg: rgba(30, 30, 35, 0.8);
    --font-jp: 'Noto Sans JP', sans-serif;
    --font-en: 'Poppins', sans-serif;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-jp);
    line-height: 1.8;
    overflow-x: hidden;
}

/* 動く背景 */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(45deg, #0f0f13, #1a1a2e, #2b1a2e);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

.animated-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(88, 101, 242, 0.1) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.5;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

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

/* ヒーローセクション */
.hero {
    text-align: center;
    padding: 100px 20px 60px;
}

/* グリッチ風タイトル */
.glitch-title {
    font-family: var(--font-en);
    font-size: 3.5rem;
    font-weight: 700;
    position: relative;
    color: var(--text-color);
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.glitch-title::before,
.glitch-title::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    opacity: 0.8;
}

.glitch-title::before {
    color: var(--secondary-color);
    z-index: -1;
    animation: glitch 3s infinite alternate-reverse;
}

.glitch-title::after {
    color: var(--accent-color);
    z-index: -2;
    animation: glitch 2s infinite alternate;
}

@keyframes glitch {
    0% { clip-path: inset(10% 0 80% 0); transform: translate(-2px, -2px); }
    20% { clip-path: inset(60% 0 20% 0); transform: translate(2px, 2px); }
    40% { clip-path: inset(30% 0 50% 0); transform: translate(-1px, 1px); }
    60% { clip-path: inset(70% 0 10% 0); transform: translate(3px, -3px); }
    80% { clip-path: inset(20% 0 60% 0); transform: translate(1px, 3px); }
    100% { clip-path: inset(50% 0 30% 0); transform: translate(-3px, 1px); }
}

.subtitle {
    font-size: 1.1rem;
    color: #aaa;
    margin-bottom: 40px;
}

/* オーナーカード */
.owner-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.owner-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(88, 101, 242, 0.2);
}

.owner-info {
    display: flex;
    align-items: center;
    gap: 15px;
    text-align: left;
}

.owner-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--accent-color);
}

/* アイコンの浮遊アニメーション */
.floating {
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.owner-label {
    font-size: 0.8rem;
    color: var(--accent-color);
    font-family: var(--font-en);
    letter-spacing: 1px;
}

.owner-name {
    font-family: var(--font-en);
    font-size: 1.8rem;
}

.discord-tag {
    font-size: 1rem;
    color: #777;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-btn {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.social-btn img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    z-index: 2;
    transition: transform 0.3s ease;
}

/* ホバー時のエフェクト */
.social-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--accent-color);
    z-index: 1;
    opacity: 0;
    transform: translateY(100%);
    transition: all 0.3s ease;
}

.social-btn.x::before {
    background: #000000; /* Xのブランドカラー */
}

.social-btn:hover::before {
    opacity: 1;
    transform: translateY(0);
}

.social-btn:hover {
    transform: scale(1.1);
}

.social-btn:hover img {
    transform: scale(1.1) rotate(-5deg);
    filter: brightness(1.2);
}

/* コンテンツセクション */
.content-section {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 20px;
    margin-bottom: 40px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.content-section h2 {
    font-family: var(--font-en);
    font-size: 2rem;
    margin-bottom: 25px;
    color: var(--accent-color);
    display: flex;
    align-items: center;
}

.content-section h2::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 30px;
    background: var(--secondary-color);
    margin-right: 15px;
    border-radius: 4px;
}

.text-block h3 {
    margin-top: 30px;
    margin-bottom: 15px;
    font-size: 1.3rem;
    border-bottom: 2px solid rgba(88, 101, 242, 0.3);
    padding-bottom: 5px;
    display: inline-block;
}

.text-block ul {
    padding-left: 25px;
    margin: 15px 0;
}

.text-block li {
    margin-bottom: 8px;
}

/* スクロール連動アニメーションの初期状態 */
.scroll-trigger {
    opacity: 0;
    transform: translateY(50px) scale(0.95);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* スクロールで表示された時の状態 */
.scroll-trigger.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* 遅延表示 */
.hero.is-visible { transition-delay: 0.1s; }
.owner-card.is-visible { transition-delay: 0.3s; }
#terms.is-visible { transition-delay: 0.2s; }
#privacy.is-visible { transition-delay: 0.2s; }


footer {
    text-align: center;
    padding: 40px 20px;
    color: #777;
    font-size: 0.9rem;
    font-family: var(--font-en);
}

/* モバイル対応 */
@media (max-width: 768px) {
    .glitch-title {
        font-size: 2.5rem;
    }
    .owner-card {
        flex-direction: column;
        gap: 20px;
        padding: 25px;
    }
    .owner-info {
        flex-direction: column;
        text-align: center;
    }
    .content-section {
        padding: 25px;
    }
    .content-section h2 {
        font-size: 1.6rem;
    }
}
/* --- BOT招待ボタン用 --- */
.bot-invite-section {
    margin-top: 40px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.invite-btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* メインボタン (Macha's BOT) */
.invite-btn.primary {
    background: linear-gradient(135deg, #5865F2, #4752c4);
    color: white;
}

/* サブボタン (メア変BOT) */
.invite-btn.secondary {
    background: linear-gradient(135deg, #2b2d31, #232529);
    color: #e0e0e0;
    border: 1px solid #5865F2;
}

/* ホバー時の動き */
.invite-btn:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 25px rgba(88, 101, 242, 0.4);
}

.invite-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.invite-btn:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}
/* --- BGMコントローラー --- */
.bgm-controls {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.bgm-btn {
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-family: var(--font-en);
    font-size: 0.9rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.bgm-btn:hover {
    background: rgba(88, 101, 242, 0.8);
    transform: scale(1.05);
}

.bgm-btn.playing {
    background: rgba(88, 101, 242, 0.8);
    box-shadow: 0 0 15px rgba(88, 101, 242, 0.5);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(88, 101, 242, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(88, 101, 242, 0); }
    100% { box-shadow: 0 0 0 0 rgba(88, 101, 242, 0); }
}

/* プレーヤーは隠す（音だけ流すため） */
#player {
    position: absolute;
    top: -9999px;
    left: -9999px;
}