/* General Styling */
:root {
    --primary-color: #007bff;
    --primary-hover: #0056b3;
    --secondary-color: #6c757d;
    --background-color: #ffffff;
    --dark-background: #f8f9fa;
    --text-color: #333;
    --light-text-color: #f8f9fa;
    --heading-font: 'Noto Sans SC', sans-serif;
    --body-font: 'Noto Sans SC', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--body-font);
    color: var(--text-color);
    margin: 0;
    line-height: 1.6;
    background-color: var(--background-color);
}

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

h1, h2, h3 {
    font-family: var(--heading-font);
    font-weight: 700;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('./img/photo-1519681393784-d120267933ba.webp') no-repeat center center/cover;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--light-text-color);
}

.hero-content {
    max-width: 800px;
    animation: fadeIn 2s ease-in-out;
    padding: 0 20px;
    box-sizing: border-box;
}

.hero .logo {
    max-width: 200px;
    margin-bottom: 1rem;
}

.hero .title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.hero .subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    font-weight: 400;
}

.cta-button {
    display: inline-block;
    padding: 15px 35px;
    background-color: var(--primary-color);
    color: #fff;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    border-radius: 50px;
    transition: background-color 0.3s, transform 0.3s;
}

.cta-button:hover {
    background-color: var(--primary-hover);
    transform: translateY(-3px);
}

/* Features Section */
.features {
    padding: 80px 0;
    background-color: var(--dark-background);
}

.features .container {
    display: flex;
    justify-content: space-around;
    text-align: center;
    gap: 20px;
}

.feature-item {
    max-width: 300px;
}

.feature-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Showcase Section */
.showcase {
    padding: 80px 0;
    text-align: center;
}

.showcase h2 {
    font-size: 2.5rem;
}

.section-subtitle {
    color: var(--secondary-color);
    max-width: 600px;
    margin: 0 auto 40px auto;
}

/* Showcase Section - NEW PURE CSS PHONE (Redmi K40S Style) */
.showcase {
    padding: 80px 0;
    text-align: center;
    background: linear-gradient(180deg, #ffffff 0%, #f7f7f7 100%);
}

.phone-mockup {
    /* 1. 绘制手机外壳 - K40S风格 */
    position: relative;
    width: 310px; /* 调整宽度以匹配安卓手机比例 */
    height: 650px; /* 调整高度 */
    margin: 40px auto 0;
    background: #333; /* 深空灰外壳 */
    border-radius: 28px; /* 减小圆角，使其更硬朗 */
    padding: 10px; /* 调整边框厚度 */
    box-sizing: border-box;
    box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.3), /* 调整阴影 */
    inset 0 1px 2px rgba(255, 255, 255, 0.1);
}

.phone-mockup::before {
    /* 2. 绘制居中打孔摄像头 (the punch-hole camera) */
    content: '';
    position: absolute;
    top: 22px; /* 定位在屏幕顶部偏下位置 */
    left: 50%;
    transform: translateX(-50%);
    width: 12px; /* 摄像头小圆点的尺寸 */
    height: 12px;
    background: #111; /* 模拟摄像头镜头的深色 */
    border-radius: 50%; /* 设置为圆形 */
    border: 1px solid #444; /* 添加一个细微的镜头圈 */
    z-index: 2; /* 确保在轮播图之上 */
}

.phone-mockup::after {
    /* 3. 绘制右侧按键 (side buttons on the right) */
    content: '';
    position: absolute;
    right: -3px; /* 移动到机身右侧 */
    top: 120px;
    width: 3px;
    height: 90px;
    background: #aaa;
    border-top-right-radius: 3px;
    border-bottom-right-radius: 3px;
}

.phone-slider {
    width: 100%;
    height: 100%;
    border-radius: 18px; /* 配合外壳调整屏幕圆角 */
    overflow: hidden; /* 保持内容裁切 */
    position: relative;
    z-index: 1;
}
/*.phone-slider img {*/
/* border-radius: 20px; !* Rounded corners for the screenshot *!*/
/*}*/


/* Download Section */
.download {
    padding: 80px 0;
    background-color: var(--dark-background);
    text-align: center;
}

.download h2 {
    font-size: 2.5rem;
}

.download-grid {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.platform-card {
    background-color: #fff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    width: 100%; /* 将固定宽度改为100% */
    max-width: 350px; /* 用最大宽度来限制它在桌面端不要变得过宽 */
    box-sizing: border-box; /* 确保 padding 不会撑大元素的总宽度 */
}

.platform-icon {
    font-size: 4rem;
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.download-button {
    display: block;
    width: 100%;
    padding: 15px 20px;
    text-decoration: none;
    font-weight: 500;
    border-radius: 8px;
    margin: 20px 0 10px 0;
    transition: background-color 0.3s, transform 0.3s;
    box-sizing: border-box;
}

.download-button.primary {
    background-color: var(--primary-color);
    color: #fff;
}

.download-button.primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-3px);
}

.other-versions {
    margin-top: 15px;
}
.other-versions a:nth-child(3) {
    /* 让第三个链接元素以块级形式显示，从而占据一整行 */
    display: block;
    /* (可选) 您还可以为它增加一点上边距，让它和上面的链接分开一些 */
    margin-top: 8px;
}
.version-link {
    color: var(--secondary-color);
    text-decoration: none;
    margin: 0 10px;
    font-size: 0.9rem;
}

.version-link:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

.support-links {
    margin-top: 50px;
    font-size: 1rem;
}

.support-links a {
    color: var(--secondary-color);
    text-decoration: none;
}

.support-links a:hover {
    color: var(--primary-color);
}

/* Footer */
.footer {
    padding: 20px;
    text-align: center;
    background-color: #333;
    color: #aaa;
}

.footer a {
    color: #fff;
    text-decoration: none;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .hero .title {
        font-size: 2.5rem;
    }
    .features .container {
        flex-direction: column;
        align-items: center;
    }
    .download-grid {
        flex-direction: column;
        align-items: center;
    }
}

/* Added media query for better mobile adaptability */
@media (max-width: 480px) {
    .phone-mockup {
        /* Reduce size to fit smaller screens, maintaining aspect ratio */
        width: 280px;
        height: 587px;
    }

    /* Optional: Proportionally adjust the pseudo-elements (camera and buttons) */
    .phone-mockup::before {
        top: 18px;
        width: 11px;
        height: 11px;
    }

    .phone-mockup::after {
        top: 100px;
        height: 85px;
    }
}