/* CSS Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

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

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 1.5rem;
    color: #764ba2;
}

.logo-icon {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: #764ba2;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 50%;
    background: #764ba2;
    transition: width 0.3s ease, left 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
    left: 0;
}

.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    color: #333;
    cursor: pointer;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 0 50px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

.hero-text {
    color: white;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, #fff, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.btn {
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    color: #333;
    box-shadow: 0 10px 30px rgba(255, 215, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(255, 215, 0, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-3px);
}

.download-btn {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.hero-stats {
    display: flex;
    gap: 2rem;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: #ffd700;
}

.stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Hero Visual */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    perspective: 1000px;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotateY(0deg);
    }
    50% {
        transform: translateY(-20px) rotateY(5deg);
    }
}

.phone-frame {
    width: 280px;
    height: 560px;
    background: linear-gradient(135deg, #2c3e50, #34495e);
    border-radius: 40px;
    padding: 10px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
    position: relative;
}

.phone-screen {
    width: 100%;
    height: 100%;
    background: #000;
    border-radius: 30px;
    overflow: hidden;
    position: relative;
}

.app-preview {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1e3c72, #2a5298);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
}

.card-stack {
    position: absolute;
    top: 35%;
    left: 36%;
    transform: translate(-50%, -50%);
    z-index: 2;
}

.card {
    position: absolute;
    width: 90px;
    height: 130px;
    background: white;
    border-radius: 10px;
    border: 2px solid #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    font-family: 'Poppins', sans-serif;
    text-align: center;
    line-height: 1.2;
    padding: 10px;
    overflow: visible;
}

.card-1 {
    transform: translateX(-50px) rotate(-10deg);
    color: #000;
    z-index: 1;
}

.card-2 {
    transform: translateX(0px) rotate(0deg);
    z-index: 4; /* 提高到最高层级 */
    color: #e74c3c;
}

.card-3 {
    transform: translateX(50px) rotate(10deg);
    color: #e74c3c;
    z-index: 2;
}

.card .rank {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
    position: relative;
    z-index: 2;
}

.card .suit {
    font-size: 1.8rem;
    margin-top: 5px;
    position: relative;
    z-index: 2;
}

.game-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffd700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.game-tagline {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

/* Floating Cards Background */
.hero-background {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 1;
    pointer-events: none;
}

.floating-card {
    position: absolute;
    font-size: 3rem;
    font-weight: bold;
    color: rgba(255, 255, 255, 0.1);
    animation: float-random 10s ease-in-out infinite;
}

.card-1.hero-background {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.card-2.hero-background {
    top: 60%;
    right: 10%;
    animation-delay: 2s;
}

.card-3.hero-background {
    top: 80%;
    left: 20%;
    animation-delay: 4s;
}

.card-4.hero-background {
    top: 30%;
    right: 20%;
    animation-delay: 6s;
}

@keyframes float-random {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(30px, -30px) rotate(90deg);
    }
    50% {
        transform: translate(-20px, 20px) rotate(180deg);
    }
    75% {
        transform: translate(40px, 10px) rotate(270deg);
    }
}

/* Features Section */
.features {
    padding: 100px 0;
    background: white;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 2.5rem;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: white;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #333;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* Download Section */
.download {
    padding: 100px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.download::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.1)"/></svg>');
    background-size: 50px 50px;
    animation: move-background 20s linear infinite;
}

@keyframes move-background {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(50px, 50px);
    }
}

.download-content {
    text-align: center;
    color: white;
    position: relative;
    z-index: 2;
}

.download-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.download-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.download-buttons {
    margin-bottom: 3rem;
}

.btn-download {
    background: linear-gradient(45deg, #4CAF50, #8BC34A);
    color: white;
    font-size: 1.2rem;
    padding: 20px 40px;
    box-shadow: 0 15px 35px rgba(76, 175, 80, 0.3);
}

.btn-download:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 45px rgba(76, 175, 80, 0.4);
}

.btn-large {
    padding: 20px 50px;
    font-size: 1.3rem;
}

.download-features {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.download-feature {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.9);
}

.download-feature i {
    color: #4CAF50;
    font-size: 1.2rem;
}

/* Rules Section */
.rules {
    padding: 100px 0;
    background: #f8f9fa;
    position: relative;
}

.rules-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
    margin-top: 3rem;
}

.rules-text h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #667eea;
}

.rules-text ul {
    list-style: none;
    margin-bottom: 2rem;
}

.rules-text li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.8rem;
    color: #555;
}

.rules-text li::before {
    content: '♠';
    position: absolute;
    left: 0;
    color: #667eea;
    font-size: 0.9rem;
}

.rules-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.rules-board {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-width: 400px;
    width: 100%;
}

.stock-waste {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    justify-content: center;
}

.stock, .waste {
    width: 60px;
    height: 84px;
    background: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    border: 2px solid #34495e;
}

.foundations {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    justify-content: center;
}

.foundation {
    width: 50px;
    height: 70px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
}

.foundation-spades { color: #000; }
.foundation-hearts { color: #e74c3c; }
.foundation-diamonds { color: #e74c3c; }
.foundation-clubs { color: #000; }

.tableau {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.column {
    display: flex;
    flex-direction: column;
    gap: -40px;
    min-height: 120px;
}

.mini-card {
    width: 40px;
    height: 56px;
    background: white;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: 1px solid #ddd;
    position: relative;
    z-index: 1;
}

.mini-card.face-down {
    background: linear-gradient(45deg, #3498db, #2980b9);
    color: transparent;
    font-size: 1.5rem;
}

/* Footer */
.footer {
    background: #1a1a1a;
    color: white;
    padding: 50px 0 20px;
}

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

.footer-section h4 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #ffd700;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-logo-icon {
    width: 30px;
    height: 30px;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

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

.footer-section a:hover {
    color: #ffd700;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

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

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .phone-frame {
        width: 200px;
        height: 400px;
    }

    .game-title {
        font-size: 1.4rem;
        bottom: 50px;
    }

    .game-tagline {
        font-size: 0.9rem;
        bottom: 25px;
    }

    .card {
        width: 60px;
        height: 90px;
    }

    .card .rank {
        font-size: 1.5rem;
    }

    .card .suit {
        font-size: 1.3rem;
    }

    .card-1 {
        transform: translateX(-30px) rotate(-10deg);
    }

    .card-2 {
        transform: translateX(0px) rotate(0deg);
    }

    .card-3 {
        transform: translateX(30px) rotate(10deg);
    }

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

    .rules-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .rules-board {
        transform: scale(0.8);
        max-width: 300px;
    }

    .download-features {
        flex-direction: column;
        gap: 1rem;
    }

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