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

:root {
    --primary-color: #8B5CF6;
    --secondary-color: #A78BFA;
    --purple-dark: #6D28D9;
    --purple-light: #C4B5FD;
    --gold: #F59E0B;
    --text-dark: #1d1d1f;
    --text-light: #6e6e73;
    --bg-light: #f5f5f7;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #8B5CF6 0%, #EC4899 50%, #F59E0B 100%);
    --gradient-purple: linear-gradient(135deg, #6D28D9 0%, #8B5CF6 50%, #A78BFA 100%);
    --gradient-gold: linear-gradient(135deg, #F59E0B 0%, #FBBF24 50%, #FCD34D 100%);
    --shadow: 0 10px 40px rgba(139, 92, 246, 0.3);
    --shadow-hover: 0 20px 60px rgba(139, 92, 246, 0.5);
    --glow: 0 0 20px rgba(139, 92, 246, 0.5);
}

body {
    font-family: 'Noto Sans TC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    background: #0f0f1e;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(236, 72, 153, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(245, 158, 11, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

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

/* 導航欄 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 15, 30, 0.95);
    backdrop-filter: blur(20px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(139, 92, 246, 0.3);
    border-bottom: 1px solid rgba(139, 92, 246, 0.2);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(139, 92, 246, 0.5);
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

/* 語言選擇器 */
.language-selector {
    position: relative;
}

.language-button {
    background: rgba(139, 92, 246, 0.2);
    border: 1px solid rgba(139, 92, 246, 0.4);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.language-button:hover {
    background: rgba(139, 92, 246, 0.3);
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.4);
}

.language-button .arrow {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.language-button.active .arrow {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: rgba(15, 15, 30, 0.98);
    border: 1px solid rgba(139, 92, 246, 0.4);
    border-radius: 12px;
    min-width: 180px;
    box-shadow: 0 10px 40px rgba(139, 92, 246, 0.5);
    backdrop-filter: blur(20px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    overflow: hidden;
}

.language-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.lang-option:hover {
    background: rgba(139, 92, 246, 0.2);
    color: var(--white);
    border-left-color: var(--primary-color);
}

.lang-option.active {
    background: rgba(139, 92, 246, 0.3);
    color: var(--white);
    border-left-color: var(--primary-color);
}

.lang-option .flag {
    font-size: 20px;
}


.nav-links a {
    text-decoration: none;
    color: var(--white);
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--secondary-color);
}

.nav-links .cta-button {
    background: var(--gradient);
    color: var(--white);
    padding: 10px 25px;
    border-radius: 25px;
    transition: all 0.3s ease;
    box-shadow: var(--glow);
}

.nav-links .cta-button::after {
    display: none;
}

.nav-links .cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 40px rgba(139, 92, 246, 0.6);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--white);
    margin: 3px 0;
    border-radius: 3px;
    transition: all 0.3s ease;
}

/* 浮動動畫 */
@keyframes float {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg); 
    }
    25% {
        transform: translateY(-20px) rotate(1deg);
    }
    50% { 
        transform: translateY(-15px) rotate(-1deg); 
    }
    75% {
        transform: translateY(-25px) rotate(0.5deg);
    }
}

/* 主視覺區 */
.hero {
    padding: 150px 0 100px;
    background: linear-gradient(180deg, #1a1a2e 0%, #0f0f1e 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 8s ease-in-out infinite;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 6s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 56px;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 20px;
    color: var(--white);
    text-shadow: 0 0 40px rgba(139, 92, 246, 0.5);
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8));
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% { filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8)) brightness(1); }
    50% { filter: drop-shadow(0 0 30px rgba(236, 72, 153, 0.8)) brightness(1.2); }
}

.hero-description {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
    line-height: 1.8;
}

.app-store-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: var(--gradient);
    color: var(--white);
    padding: 12px 24px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.app-store-button::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.app-store-button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.app-store-button.large {
    padding: 16px 32px;
    font-size: 18px;
}

.app-store-icon {
    width: 120px;
    height: auto;
}

.button-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.button-subtitle {
    font-size: 11px;
    opacity: 0.8;
}

.button-title {
    font-size: 20px;
    font-weight: 600;
}

/* 球員卡展示 */
.cards-showcase {
    perspective: 1000px;
    width: 100%;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-stack {
    position: relative;
    width: 300px;
    height: 420px;
}

.player-card {
    position: absolute;
    width: 280px;
    height: 400px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.9) 0%, rgba(109, 40, 217, 0.9) 100%);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 
        0 20px 60px rgba(139, 92, 246, 0.5),
        inset 0 0 40px rgba(255, 255, 255, 0.1),
        0 0 0 1px rgba(255, 255, 255, 0.2);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.player-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent 30%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 70%
    );
    animation: cardRotate 4s linear infinite;
}

@keyframes cardRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.card-shine {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 215, 0, 0.3) 100%
    );
    opacity: 0.5;
    animation: shine 3s ease-in-out infinite;
}

.card-content {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.5));
}

.card-1 {
    transform: translateX(-40px) translateY(20px) rotate(-8deg);
    z-index: 1;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.95) 0%, rgba(251, 191, 36, 0.95) 100%);
    animation: float 6s ease-in-out infinite;
}

.card-2 {
    z-index: 2;
    transform: translateY(-10px);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.95) 0%, rgba(167, 139, 250, 0.95) 100%);
    animation: float 6s ease-in-out 0.5s infinite;
    box-shadow: 
        0 30px 80px rgba(139, 92, 246, 0.6),
        inset 0 0 40px rgba(255, 255, 255, 0.15),
        0 0 0 2px rgba(255, 255, 255, 0.3);
}

.card-3 {
    transform: translateX(40px) translateY(20px) rotate(8deg);
    z-index: 1;
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.95) 0%, rgba(244, 114, 182, 0.95) 100%);
    animation: float 6s ease-in-out 1s infinite;
}

.card-stack:hover .card-1 {
    transform: translateX(-60px) translateY(30px) rotate(-12deg);
}

.card-stack:hover .card-2 {
    transform: translateY(-20px) scale(1.05);
}

.card-stack:hover .card-3 {
    transform: translateX(60px) translateY(30px) rotate(12deg);
}

/* 功能特色 */
.features {
    padding: 100px 0;
    background: linear-gradient(180deg, #0f0f1e 0%, #1a1a2e 100%);
    position: relative;
}

.section-title {
    font-size: 48px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 20px;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 20px;
    color: rgba(255, 255, 255, 0.7);
    text-align: center;
    margin-bottom: 60px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.feature-card {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(109, 40, 217, 0.05) 100%);
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid rgba(139, 92, 246, 0.2);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 
        0 20px 60px rgba(139, 92, 246, 0.4),
        inset 0 0 40px rgba(139, 92, 246, 0.1);
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.2) 0%, rgba(109, 40, 217, 0.1) 100%);
}

.feature-icon {
    font-size: 64px;
    margin-bottom: 20px;
    filter: drop-shadow(0 5px 15px rgba(139, 92, 246, 0.5));
    animation: iconFloat 3s ease-in-out infinite;
}

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

.feature-card h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--white);
}

.feature-card p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
    line-height: 1.7;
}

/* 關於我們 */
.about {
    padding: 100px 0;
    background: linear-gradient(180deg, #1a1a2e 0%, #0f0f1e 100%);
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text {
    text-align: center;
}

.about-description {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 30px;
    line-height: 1.8;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 60px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 48px;
    font-weight: 900;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.5));
}

.stat-label {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.6);
}

/* 下載區 */
.download-section {
    padding: 100px 0;
    background: var(--gradient);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.download-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 4s ease-in-out infinite;
}

.download-section::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 5s ease-in-out infinite;
}

.download-section .section-title,
.download-section .section-subtitle {
    color: var(--white);
}

.download-content {
    text-align: center;
    position: relative;
    z-index: 1;
}

/* 頁尾 */
.footer {
    background: #0a0a15;
    color: var(--white);
    padding: 60px 0 20px;
    border-top: 1px solid rgba(139, 92, 246, 0.2);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 20px;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
}

/* 響應式設計 */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-title {
        font-size: 42px;
    }

    .hero-description {
        font-size: 18px;
    }

    .cards-showcase {
        height: 400px;
    }

    .card-stack {
        transform: scale(0.8);
    }

    .stats {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(15, 15, 30, 0.98);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 40px rgba(139, 92, 246, 0.5);
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        border: 1px solid rgba(139, 92, 246, 0.3);
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .hero {
        padding: 100px 0 60px;
    }

    .hero-title {
        font-size: 36px;
    }

    .section-title {
        font-size: 36px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .card-stack {
        transform: scale(0.7);
    }
}

/* 動畫效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-text,
.hero-image {
    animation: fadeIn 1s ease-out;
}

.feature-card {
    animation: fadeIn 1s ease-out;
}

.feature-card:nth-child(1) { animation-delay: 0.1s; }
.feature-card:nth-child(2) { animation-delay: 0.2s; }
.feature-card:nth-child(3) { animation-delay: 0.3s; }
.feature-card:nth-child(4) { animation-delay: 0.4s; }
.feature-card:nth-child(5) { animation-delay: 0.5s; }
.feature-card:nth-child(6) { animation-delay: 0.6s; }

/* 星星背景效果 */
@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

.hero::after,
.features::before,
.about::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background-image: 
        radial-gradient(2px 2px at 20% 30%, rgba(139, 92, 246, 0.8), transparent),
        radial-gradient(2px 2px at 60% 70%, rgba(236, 72, 153, 0.8), transparent),
        radial-gradient(1px 1px at 50% 50%, rgba(245, 158, 11, 0.8), transparent),
        radial-gradient(1px 1px at 80% 10%, rgba(167, 139, 250, 0.8), transparent),
        radial-gradient(2px 2px at 90% 60%, rgba(139, 92, 246, 0.6), transparent),
        radial-gradient(1px 1px at 33% 80%, rgba(236, 72, 153, 0.6), transparent);
    background-size: 200% 200%;
    animation: twinkle 3s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}
