/**
 * 摩洛哥风格设计样式
 * 融合传统摩洛哥色彩和现代简约设计
 */

:root {
    /* 摩洛哥传统色彩 */
    --moroccan-red: #C41E3A;
    --moroccan-gold: #DAA520;
    --moroccan-green: #006233;
    --moroccan-orange: #FF8C00;
    --moroccan-blue: #002868;
    --moroccan-cream: #F5F5DC;
    --moroccan-sand: #F4A460;
    
    /* 现代化调色板 */
    --primary-gradient: linear-gradient(135deg, #C41E3A 0%, #FF8C00 100%);
    --secondary-gradient: linear-gradient(135deg, #DAA520 0%, #F4A460 100%);
    --accent-gradient: linear-gradient(135deg, #006233 0%, #002868 100%);
    
    /* 阴影和效果 */
    --shadow-soft: 0 8px 32px rgba(196, 30, 58, 0.15);
    --shadow-medium: 0 12px 48px rgba(196, 30, 58, 0.25);
    --shadow-strong: 0 16px 64px rgba(196, 30, 58, 0.35);
}

/* 全局样式重置 */
body.moroccan-theme {
    font-family: 'Noto Sans Arabic', 'Roboto', 'Segoe UI', sans-serif;
    background: var(--primary-gradient);
    color: #333;
}

/* 摩洛哥风格容器 */
.moroccan-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
}

/* 装饰性几何图案 */
.moroccan-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(218, 165, 32, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(196, 30, 58, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}

/* 主要内容区域 */
.content-area {
    position: relative;
    z-index: 2;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 40px 30px;
    margin: 20px 0;
    box-shadow: var(--shadow-medium);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* 摩洛哥风格标题 */
.moroccan-title {
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

.moroccan-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--secondary-gradient);
    border-radius: 2px;
}

/* 摩洛哥风格按钮 - 超大显眼版本 */
.btn-moroccan {
    background: linear-gradient(135deg, #d4af37 0%, #b8860b 100%);
    border: 3px solid #8b4513;
    color: white;
    padding: 20px 50px;
    border-radius: 15px;
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    min-width: 200px;
    text-align: center;
}

.btn-moroccan:hover {
    background: linear-gradient(135deg, #b8860b 0%, #d4af37 100%);
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(212, 175, 55, 0.6);
    color: white;
    text-decoration: none;
}

.btn-moroccan::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s;
}

.btn-moroccan:hover::before {
    left: 100%;
}

/* 超大下载按钮容器 */
.hero-download-section {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15) 0%, rgba(139, 69, 19, 0.15) 100%);
    padding: 50px 20px;
    text-align: center;
    margin: 30px 0;
    border-radius: 25px;
    border: 3px solid rgba(212, 175, 55, 0.4);
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(212, 175, 55, 0.2);
    backdrop-filter: blur(10px);
}

.hero-download-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hero-download-title {
    font-size: 3rem;
    font-weight: bold;
    color: #8b4513;
    margin-bottom: 25px;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.15);
    position: relative;
    z-index: 2;
    background: linear-gradient(45deg, #8b4513, #d4af37);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-download-subtitle {
    font-size: 1.4rem;
    color: #666;
    margin-bottom: 35px;
    position: relative;
    z-index: 2;
    font-weight: 500;
}

/* 主下载按钮增强样式 */
#main-download-btn {
    font-size: 1.8rem !important;
    padding: 20px 50px !important;
    margin: 25px auto !important;
    min-height: 70px !important;
    border-radius: 35px !important;
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.4) !important;
    position: relative;
    z-index: 3;
    font-weight: 700 !important;
    letter-spacing: 1px;
    text-transform: uppercase;
    border: 3px solid rgba(212, 175, 55, 0.3) !important;
}

#main-download-btn:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 20px 45px rgba(212, 175, 55, 0.6) !important;
}

/* 检测信息样式 */
.detection-info {
    background: rgba(255, 255, 255, 0.8);
    padding: 15px 25px;
    border-radius: 20px;
    margin-bottom: 25px;
    font-size: 1rem;
    color: #8b4513;
    font-weight: 600;
    position: relative;
    z-index: 2;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(212, 175, 55, 0.2);
}

/* 脉冲动画增强 */
@keyframes pulse {
    0% { 
        transform: scale(1);
        box-shadow: 0 15px 35px rgba(212, 175, 55, 0.4);
    }
    50% { 
        transform: scale(1.08);
        box-shadow: 0 20px 45px rgba(212, 175, 55, 0.6);
    }
    100% { 
        transform: scale(1);
        box-shadow: 0 15px 35px rgba(212, 175, 55, 0.4);
    }
}

.btn-moroccan.pulse {
    animation: pulse 2.5s infinite;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .hero-download-section {
        padding: 40px 20px;
        margin: 20px 10px;
        border-radius: 20px;
    }
    
    .hero-download-title {
        font-size: 2.2rem;
        margin-bottom: 20px;
    }
    
    .hero-download-subtitle {
        font-size: 1.2rem;
        margin-bottom: 30px;
    }
    
    #main-download-btn {
        font-size: 1.5rem !important;
        padding: 18px 40px !important;
        min-height: 60px !important;
        width: 90% !important;
        max-width: 350px !important;
    }
    
    .detection-info {
        padding: 12px 20px;
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
}

@media (max-width: 480px) {
    .hero-download-section {
        padding: 30px 15px;
        margin: 15px 5px;
        border-radius: 16px;
    }
    
    .hero-download-title {
        font-size: 1.8rem;
        margin-bottom: 15px;
    }
    
    .hero-download-subtitle {
        font-size: 1rem;
        margin-bottom: 25px;
    }
    
    #main-download-btn {
        font-size: 1.3rem !important;
        padding: 15px 30px !important;
        min-height: 55px !important;
        width: 95% !important;
        max-width: 300px !important;
    }
    
    .detection-info {
        padding: 10px 15px;
        font-size: 0.8rem;
        margin-bottom: 18px;
    }
}

/* 摩洛哥风格卡片 */
.moroccan-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    padding: 30px;
    margin: 20px 0;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(218, 165, 32, 0.2);
    position: relative;
    overflow: hidden;
}

.moroccan-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--secondary-gradient);
}

/* 应用卡片 */
.app-card-moroccan {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
    border: 1px solid rgba(218, 165, 32, 0.1);
}

.app-card-moroccan:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-medium);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .moroccan-container {
        padding: 10px;
    }
    
    .content-area {
        padding: 20px 15px;
        margin: 10px 0;
        border-radius: 16px;
    }
    
    .moroccan-title {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }
    
    .hero-download-section {
        padding: 30px 15px;
        margin: 15px 0;
    }
    
    .hero-download-title {
        font-size: 2rem;
    }
    
    .btn-moroccan {
        padding: 18px 40px;
        font-size: 1.3rem;
        width: 90%;
        max-width: 300px;
    }
    
    .moroccan-card {
        padding: 20px;
        margin: 15px 0;
        border-radius: 16px;
    }
    
    .app-card-moroccan {
        padding: 16px;
        border-radius: 16px;
    }
}

@media (max-width: 480px) {
    .moroccan-container {
        padding: 8px;
    }
    
    .content-area {
        padding: 16px 12px;
        margin: 8px 0;
        border-radius: 12px;
    }
    
    .moroccan-title {
        font-size: 1.5rem;
        margin-bottom: 16px;
    }
    
    .btn-moroccan {
        padding: 12px 20px;
        font-size: 15px;
        min-height: 44px;
        margin: 10px auto;
        max-width: 280px;
    }
    
    .moroccan-card {
        padding: 16px;
        margin: 10px 0;
        border-radius: 12px;
    }
    
    .app-card-moroccan {
        padding: 12px;
        border-radius: 12px;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* 触摸友好的交互 */
@media (hover: none) and (pointer: coarse) {
    .btn-moroccan:hover {
        transform: none;
    }
    
    .btn-moroccan:active {
        transform: scale(0.95);
        transition: transform 0.1s ease;
    }
    
    .app-card-moroccan:hover {
        transform: none;
    }
    
    .app-card-moroccan:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}

/* 改进的触摸目标 */
.language-switch {
    min-height: 44px;
    min-width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 优化的滚动体验 */
.content-area {
    -webkit-overflow-scrolling: touch;
}

/* 防止文本选择在触摸设备上 */
.btn-moroccan,
.app-card-moroccan {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}