/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    min-height: 100vh;
    overflow-x: hidden;
    color: #333;
    /* 3D球体变量 */
    --radius: 300px;
    --rot-x: 18deg;
    --rot-y: 22.5deg;
    --item-width: 80px;
    --item-height: 80px;
    --sphere-z-index: 1;
}

/* 容器样式 */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 300px 20px 40px;
}

/* 优化模块间距 */
.welcome-section {
    margin-top: 40px;
    margin-bottom: 15px;
}

.sphere-root {
    position: relative;
    width: 100%;
    height: 50vh;
    --radius: 520px;
    --viewer-pad: 72px;
    --circ: calc(var(--radius) * 3.14);
    --segments-x: 35;
    --segments-y: 35;
    --rot-y: calc((360deg / var(--segments-x)) / 2);
    --rot-x: calc((360deg / var(--segments-y)) / 2);
    --item-width: calc(var(--circ) / var(--segments-x));
    --item-height: calc(var(--circ) / var(--segments-y));
    --overlay-blur-color: #060010;
    --tile-radius: 50%;
    --enlarge-radius: 30px;
    --image-filter: none;
    margin: 15px auto 30px;
    overflow: visible; /* 允许内容溢出，不影响页面滚动 */
    touch-action: auto; /* 允许所有触摸行为 */
}

.footer-content {
    margin-top: 80px;
}

/* 头部样式 */
.header {
    text-align: center;
    margin-bottom: 10px;
    padding: 20px;
    animation: fadeInDown 1s ease-out;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(102, 126, 234, 0.85);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

/* 语言选择器样式 */
.language-selector {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 1001;
}

.language-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
    font-weight: 500;
    font-size: 14px;
}

.language-button:hover {
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.language-flag {
    display: flex;
    align-items: center;
}

.flag-icon {
    width: 20px;
    height: 14px;
    object-fit: cover;
    border-radius: 2px;
    margin-right: 8px;
}

.language-option .flag-icon {
    margin-right: 10px;
}

.language-arrow {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.language-selector.open .language-arrow {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    padding: 8px 0;
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.language-selector.open .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.language-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-primary);
    font-size: 14px;
}

.language-option:hover {
    background: rgba(212, 175, 55, 0.2);
}

.language-option:first-child {
    border-radius: 12px 12px 0 0;
}

.language-option:last-child {
    border-radius: 0 0 12px 12px;
}

.logo {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, #fff, #e0c3fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    line-height: 1.2;
}

.subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 300;
    line-height: 1.5;
}

/* 全球服务国旗图标样式 */
.global-flags {
    position: relative;
    margin-top: 15px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    animation: fadeIn 1s ease-out 0.3s both;
    width: 100%;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
    overflow: visible;
    box-sizing: border-box;
}

.global-services-title {
    color: white !important;
    font-size: 1.3rem !important;
    font-weight: 600 !important;
    margin: 0 0 20px !important;
    text-align: center !important;
    font-family: 'Poppins', sans-serif !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
    line-height: 1.3 !important;
    position: relative !important;
    z-index: 1 !important;
    display: block !important;
    width: 100% !important;
    white-space: normal !important;
    word-wrap: break-word !important;
}

.global-services-container {
    width: 100%;
    position: relative;
    margin-bottom: 20px;
    text-align: center;
}

.global-services-title {
    color: white;
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0 auto;
    text-align: center;
    width: 100%;
    font-family: 'Poppins', sans-serif;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    line-height: 1.3;
    position: relative;
    z-index: 1;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

/* 国旗行样式 */
.flags-row {
    position: relative;
    height: 50px;
    margin-bottom: 10px;
    overflow: hidden;
    border-radius: 8px;
}

/* 国旗容器样式 */
.flags-container {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 100%;
    white-space: nowrap;
    will-change: transform;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

/* 第一行：从右向左滚动 */
.flags-container--left {
    animation-name: scrollLeft;
    animation-duration: 20s;
}

/* 第二行：从左向右滚动 */
.flags-container--right {
    animation-name: scrollRight;
    animation-duration: 20s;
}

/* 国旗图标样式 */
.flag {
    width: 40px;
    height: 40px;
    display: inline-block;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.2));
    object-fit: contain;
    border-radius: 4px;
    flex-shrink: 0;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.9);
}

/* 滚动动画 */
@keyframes scrollLeft {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

@keyframes scrollRight {
    0% {
        transform: translateX(-50%);
    }
    100% {
        transform: translateX(0);
    }
}

/* 响应式设计 */
@media (max-width: 767px) {
    .global-flags {
        padding: 8px;
    }
    
    .flags-row {
        height: 45px;
        margin-bottom: 8px;
    }
    
    .flags-container {
        gap: 8px;
    }
    
    .flag {
        width: 35px;
        height: 35px;
    }
    
    .flags-container--left,
    .flags-container--right {
        animation-duration: 15s;
    }
}

@media (max-width: 480px) {
    .global-flags {
        padding: 6px;
    }
    
    .flags-row {
        height: 40px;
        margin-bottom: 6px;
    }
    
    .flags-container {
        gap: 6px;
    }
    
    .flag {
        width: 30px;
        height: 30px;
    }
    
    .flags-container--left,
    .flags-container--right {
        animation-duration: 12s;
    }
}

/* 提升动画性能 */
.flags-container--left,
.flags-container--right {
    backface-visibility: hidden;
    perspective: 1000px;
}

/* 平滑滚动效果 */
html {
    scroll-behavior: smooth;
}

/* 卡片式服务内容模块样式 */
.welcome-section {
    margin-top: 15px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(15px);
    animation: fadeIn 1s ease-out 0.5s both;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.welcome-title {
    color: white;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 25px;
    text-align: center;
    font-family: 'Poppins', sans-serif;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    line-height: 1.2;
    transition: all 0.3s ease;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.service-card {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 18px;
    padding: 35px 30px;
    text-align: center;
    cursor: pointer;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    min-height: 240px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea, #764ba2, #f093fb);
}

.service-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: #e0c3fc;
    z-index: 1;
    position: relative;
}

.service-card h3 {
    color: white;
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 15px;
    font-family: 'Poppins', sans-serif;
    line-height: 1.3;
    z-index: 1;
    position: relative;
}

.service-card p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    line-height: 1.8;
    font-weight: 300;
    font-family: 'Poppins', sans-serif;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    position: relative;
}

/* 响应式设计 - 服务卡片 */
@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 25px;
    }
    
    .welcome-title {
        font-size: 1.8rem;
    }
}

@media (max-width: 767px) {
    /* 容器样式调整 */
    .container {
        padding: 250px 15px 30px;
    }
    
    /* 欢迎区域样式调整 */
    .welcome-section {
        padding: 25px 20px;
        margin-top: 30px;
    }
    
    .welcome-title {
        font-size: 1.6rem;
        margin-bottom: 20px;
    }
    
    /* 服务卡片网格调整 */
    .services-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 25px;
    }
    
    /* 服务卡片样式调整 */
    .service-card {
        padding: 30px 25px;
        min-height: 220px;
    }
    
    .service-icon {
        font-size: 3rem;
        margin-bottom: 18px;
    }
    
    .service-card h3 {
        font-size: 1.3rem;
        margin-bottom: 12px;
    }
    
    .service-card p {
        font-size: 0.95rem;
        line-height: 1.7;
    }
    
    /* 头部样式调整 */
    .header {
        padding: 15px 0;
    }
    
    .logo {
        font-size: 2rem;
        margin-bottom: 8px;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    /* 全球服务样式调整 */
    .global-flags {
        padding: 15px;
        margin-top: 10px;
    }
    
    .global-services-title {
        font-size: 1.2rem;
        margin-bottom: 15px;
    }
    
    /* 3D球体样式调整 */
    .sphere-root {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    /* 容器样式调整 */
    .container {
        padding: 220px 10px 20px;
    }
    
    /* 欢迎区域样式调整 */
    .welcome-section {
        padding: 20px 15px;
        margin-top: 25px;
        margin-bottom: 20px;
    }
    
    .welcome-title {
        font-size: 1.4rem;
        margin-bottom: 18px;
    }
    
    /* 服务卡片网格调整 */
    .services-grid {
        gap: 18px;
        margin-top: 20px;
    }
    
    /* 服务卡片样式调整 */
    .service-card {
        padding: 25px 20px;
        min-height: 200px;
    }
    
    .service-icon {
        font-size: 2.5rem;
        margin-bottom: 15px;
    }
    
    .service-card h3 {
        font-size: 1.2rem;
        margin-bottom: 10px;
    }
    
    .service-card p {
        font-size: 0.9rem;
        line-height: 1.6;
    }
    
    /* 头部样式调整 */
    .header {
        padding: 12px 0;
    }
    
    .logo {
        font-size: 1.8rem;
        margin-bottom: 6px;
    }
    
    .subtitle {
        font-size: 0.95rem;
    }
    
    /* 全球服务样式调整 */
    .global-flags {
        padding: 10px;
        margin-top: 8px;
    }
    
    .global-services-title {
        font-size: 1.1rem;
        margin-bottom: 12px;
    }
    
    /* 底部悬浮按钮调整 */
    .floating-btn {
        bottom: 20px;
        right: 20px;
        padding: 15px 28px;
        font-size: 15px;
        min-width: 180px;
        gap: 10px;
    }
    
    .floating-btn__icon {
        font-size: 20px;
    }
    
    /* 3D球体样式调整 */
    .sphere-root {
        padding: 10px;
        margin: 25px auto 40px;
    }
    
    /* 页脚样式调整 */
    .footer-content {
        padding: 40px 20px;
        margin-top: 60px;
    }
    
    .footer-section {
        margin-bottom: 30px;
    }
    
    .footer-section h3 {
        font-size: 1.4rem;
        margin-bottom: 20px;
    }
    
    .footer-section p {
        font-size: 0.95rem;
        margin-bottom: 15px;
    }
    
    .footer-section ul {
        gap: 15px;
    }
    
    .footer-section li {
        font-size: 0.95rem;
        padding-left: 25px;
    }
}

/* 3D圆球画廊样式 */
.sphere-root {
    position: relative;
    width: calc(var(--radius) * 2.05);
    height: calc(var(--radius) * 2.05);
    --viewer-pad: 5px;
    overflow: hidden;
    --circ: calc(var(--radius) * 3.14);
    --segments-x: 20;
    --segments-y: 20;
    --rot-y: calc((360deg / var(--segments-x)) / 2);
    --rot-x: calc((360deg / var(--segments-y)) / 2);
    --item-width: calc(var(--circ) / var(--segments-x));
    --item-height: calc(var(--circ) / var(--segments-y));
    --overlay-blur-color: transparent;
    --tile-radius: 50%;
    --enlarge-radius: 30px;
    --image-filter: none;
    margin: 15px auto 30px;
    max-width: 100%;
    padding: 5px;
    box-sizing: content-box;
}

/* 响应式设计 - 3D球体 */
@media (max-width: 1200px) {
    .sphere-root {
        --radius: 300px;
        margin: 15px auto 30px;
    }
}

@media (max-width: 992px) {
    .sphere-root {
        --radius: 250px;
        margin: 15px auto 30px;
    }
}

@media (max-width: 767px) {
    .sphere-root {
        --radius: 200px;
        margin: 15px auto 30px;
        padding: 5px;
    }
}

@media (max-width: 480px) {
    .sphere-root {
        --radius: 150px;
        margin: 10px auto 20px;
        padding: 5px;
    }
}

@media (max-width: 360px) {
    .sphere-root {
        --radius: 120px;
        margin: 10px auto 20px;
        padding: 5px;
    }
}

.sphere-main {
    position: relative;
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    overflow: hidden;
    touch-action: unset; /* 继承默认的触摸行为，允许滚动 */
    user-select: none;
    -webkit-user-select: none;
    background: transparent;
}

.stage {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    perspective: calc(var(--radius) * 2);
    perspective-origin: 50% 50%;
    contain: layout paint size;
}

.sphere {
    transform: translateZ(calc(var(--radius) * -1));
    will-change: transform;
    transform-style: preserve-3d;
    transition: transform 0.1s ease-out;
}

.overlay,
.overlay--blur {
    display: none; /* 移除球体上方的渐变光晕效果 */
}

.item {
    width: calc(var(--item-width) * var(--item-size-x));
    height: calc(var(--item-height) * var(--item-size-y));
    position: absolute;
    top: -999px;
    bottom: -999px;
    left: -999px;
    right: -999px;
    margin: auto;
    transform-origin: 50% 50%;
    backface-visibility: hidden;
    transition: transform 300ms;
    transform: rotateY(calc(var(--rot-y) * (var(--offset-x) + ((var(--item-size-x) - 1) / 2)) + var(--rot-y-delta, 0deg)))
        rotateX(calc(var(--rot-x) * (var(--offset-y) - ((var(--item-size-y) - 1) / 2)) + var(--rot-x-delta, 0deg)))
        translateZ(var(--radius));
}

.item__image {
    position: absolute;
    display: block;
    inset: 10px;
    border-radius: var(--tile-radius, 12px);
    background: #667eea;
    overflow: hidden;
    backface-visibility: hidden;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    pointer-events: auto;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.item__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    backface-visibility: hidden;
    filter: var(--image-filter, none);
}

.viewer {
    position: absolute;
    inset: 0;
    z-index: 20;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--viewer-pad);
}

.viewer .frame {
    height: 100%;
    aspect-ratio: 1;
    border-radius: var(--enlarge-radius, 32px);
    display: flex;
}

@media (max-aspect-ratio: 1/1) {
    .viewer .frame {
        height: auto;
        width: 100%;
    }
}

.viewer .scrim {
    position: absolute;
    inset: 0;
    z-index: 10;
    background: rgba(0, 0, 0, 0.4);
    pointer-events: none;
    opacity: 0;
    transition: opacity 500ms ease;
    backdrop-filter: blur(3px);
}

.sphere-root[data-enlarging='true'] .viewer .scrim {
    opacity: 1;
    pointer-events: all;
}

.viewer .enlarge {
    position: absolute;
    z-index: 30;
    border-radius: var(--enlarge-radius, 32px);
    overflow: hidden;
    transition: transform 500ms ease, opacity 500ms ease;
    transform-origin: top left;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.viewer .enlarge img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: var(--image-filter, none);
}

.edge-fade {
    display: none; /* 移除球体上下的渐变淡出效果 */
}

.edge-fade--top {
    display: none;
}

.edge-fade--bottom {
    display: none;
}

/* 球体内部气泡发言组件样式 */
.sphere-text-bubble {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotateY(calc(var(--rot-y-delta, 0deg))) rotateX(calc(var(--rot-x-delta, 0deg)));
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 20px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    z-index: 100;
    opacity: 1;
    visibility: visible;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    pointer-events: none;
    backface-visibility: visible;
    max-width: 90%;
    overflow: visible;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.5);
    white-space: nowrap;
}

/* 移除球体光影效果和内部阴影效果 */
.sphere-main::before {
    display: none;
}

.sphere::after {
    display: none;
}

/* 动态文本大小调整 */
.sphere-text-bubble.small-text {
    font-size: 14px;
    padding: 15px 25px;
}

.sphere-text-bubble.large-text {
    font-size: 18px;
    padding: 25px 35px;
}

/* 气泡动画 */
@keyframes bubblePulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.02);
        box-shadow: 0 12px 35px rgba(0, 0, 0, 0.3);
    }
}

.sphere-text-bubble {
    animation: bubblePulse 3s ease-in-out infinite;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .sphere-text-bubble {
        font-size: 14px;
        padding: 15px 20px;
        max-width: 90%;
        max-height: 70%;
    }
    
    .sphere-text-bubble.small-text {
        font-size: 12px;
        padding: 12px 18px;
    }
    
    .sphere-text-bubble.large-text {
        font-size: 16px;
        padding: 20px 28px;
    }
}

@media (max-width: 480px) {
    .sphere-text-bubble {
        font-size: 12px;
        padding: 12px 18px;
        max-width: 95%;
        max-height: 75%;
    }
    
    .sphere-text-bubble.small-text {
        font-size: 10px;
        padding: 10px 15px;
    }
    
    .sphere-text-bubble.large-text {
        font-size: 14px;
        padding: 18px 25px;
    }
}

/* 悬浮提示框样式 */
.sphere-tooltip {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    pointer-events: none;
    backdrop-filter: blur(5px);
    border: 2px solid rgba(102, 126, 234, 0.3);
    max-width: 90%;
    white-space: nowrap;
}

.sphere-tooltip.visible {
    opacity: 1;
    visibility: visible;
}

.viewer {
    position: absolute;
    inset: 0;
    z-index: 20;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--viewer-pad);
}

.viewer .frame {
    height: 100%;
    aspect-ratio: 1;
    border-radius: var(--enlarge-radius, 32px);
    display: flex;
}

.viewer .scrim {
    position: absolute;
    inset: 0;
    z-index: 10;
    background: rgba(0, 0, 0, 0.4);
    pointer-events: none;
    opacity: 0;
    transition: opacity 500ms ease;
    backdrop-filter: blur(3px);
}

.edge-fade {
    display: none;
}

.edge-fade--top {
    display: none;
}

.edge-fade--bottom {
    display: none;
}

/* 冒泡动画 */
@keyframes bubbleUp {
    0% {
        opacity: 0;
        transform: scale(0);
    }
    70% {
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* 淡入动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 个人资料面板 */
.profile-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    backdrop-filter: blur(5px);
}

.profile-panel.active {
    opacity: 1;
    visibility: visible;
}

.profile-content {
    background: transparent;
    border-radius: 15px;
    overflow: visible;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    transform: scale(0.8);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    position: relative;
}

.profile-panel.active .profile-content {
    transform: scale(1);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.6);
}

.close-btn {
    position: absolute;
    top: -20px;
    right: -20px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: #333;
    font-size: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    font-weight: bold;
}

.close-btn:active {
    transform: scale(0.95);
}

.profile-photo {
    width: 100%;
    height: 300px;
    background-size: cover;
    background-position: center;
    position: relative;
    border-radius: 15px 15px 0 0;
    overflow: hidden;
    cursor: pointer;
}

.profile-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 15px 15px 0 0;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
}

.play-button:hover {
    transform: translate(-50%, -50%) scale(1.1);
}

/* 视频播放时隐藏播放按钮 */
.profile-photo video[controls]:not([style*="display: none"]) ~ .play-button {
    display: none;
}

/* 视频隐藏时显示播放按钮 */
.profile-photo video[controls][style*="display: none"] ~ .play-button {
    display: block;
}

.profile-info {
    padding: 25px;
    background: white;
    color: #333;
    border-radius: 0 0 15px 15px;
    text-align: center;
}

.profile-field {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.profile-label {
    font-weight: 500;
    color: #667eea;
    margin-right: 10px;
    font-size: 1rem;
    text-align: center;
}

.profile-name {
    color: #667eea;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    margin-left: 10px;
}

.age {
    color: #f093fb;
    font-weight: 600;
    margin-right: 25px;
}

.occupation {
    color: #4facfe;
    font-weight: 600;
}

.nationality {
    color: #667eea;
    font-weight: 600;
}

.nationality span {
    background: #f0f0f0;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.9rem;
    margin-right: 5px;
}

.profile-details.profile-field {
    justify-content: flex-start;
    gap: 15px;
}

.profile-details.profile-field {
    display: flex;
    gap: 25px;
    margin: 10px 0 15px;
    align-items: center;
    flex-wrap: nowrap;
    width: 100%;
    justify-content: flex-start;
    flex-direction: row;
    overflow: hidden;
}

.profile-details.profile-field > span {
    display: inline-block;
    white-space: nowrap;
}

.profile-details .profile-label {
    min-width: auto;
    margin-right: 10px;
    font-size: 0.95rem;
    white-space: nowrap;
}

.profile-details .age,
.profile-details .occupation {
    white-space: nowrap;
}

.profile-name {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0;
    color: #667eea;
    display: inline-block;
    vertical-align: middle;
}

.profile-details.profile-field {
    display: flex;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 0.95rem;
    color: #666;
    justify-content: center;
    align-items: center;
}

.age {
    font-weight: 600;
    color: #764ba2;
}

.occupation {
    font-style: italic;
}

.nationality {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    color: #555;
    margin: 0;
    flex-wrap: nowrap;
}

.nationality img {
    width: 18px;
    height: 14px;
    object-fit: cover;
    border-radius: 2px;
}

/* 加载动画 */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-gradient);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    transition: all 0.5s ease;
}

.loading.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--tertiary-color);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite, pulse 2s ease-in-out infinite;
    margin-bottom: 20px;
}

.loading p {
    color: var(--text-secondary);
    font-size: 1.2rem;
    font-weight: 600;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(212, 175, 55, 0);
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 1199px) {
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 15px;
    }
}

@media (max-width: 767px) {
    .logo {
        font-size: 2rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 10px;
        padding: 10px;
    }

    .profile-name {
        font-size: 1.5rem;
    }

    .profile-info {
        padding: 20px;
    }

    .profile-details {
        flex-direction: column;
        gap: 5px;
    }
}

@media (max-width: 480px) {
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 8px;
    }

    .logo {
        font-size: 1.8rem;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 4px;
}

/* 统一色彩变量 - 黑金主题 */
:root {
    --primary-color: #D4AF37; /* 金色 */
    --secondary-color: #0A0A0A; /* 深黑色 */
    --tertiary-color: #333333; /* 深灰色 */
    --primary-gradient: linear-gradient(135deg, #D4AF37 0%, #B8941F 100%);
    --secondary-gradient: linear-gradient(135deg, #0A0A0A 0%, #333333 100%);
    --bg-gradient: linear-gradient(135deg, #0A0A0A 0%, #1A1A1A 100%);
    --card-bg: rgba(212, 175, 55, 0.1);
    --card-hover-bg: rgba(212, 175, 55, 0.15);
    --text-primary: rgba(255, 255, 255, 0.95);
    --text-secondary: rgba(212, 175, 55, 0.9);
    --text-tertiary: rgba(255, 255, 255, 0.7);
    --border-color: rgba(212, 175, 55, 0.3);
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 8px 25px rgba(0, 0, 0, 0.5);
    --button-bg: rgba(212, 175, 55, 0.2);
    --button-hover-bg: rgba(212, 175, 55, 0.3);
    --button-active-bg: rgba(212, 175, 55, 0.4);
    --drawer-bg: rgba(10, 10, 10, 0.95);
    --drawer-text: #FFFFFF;
    --drawer-header-bg: var(--primary-gradient);
    --drawer-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    --drawer-overlay-bg: rgba(0, 0, 0, 0.8);
}

/* 优化背景和文字对比度 */
body {
    background: var(--bg-gradient);
    color: var(--text-primary);
}

/* 优化卡片色彩 */
.service-card {
    background: var(--card-bg);
    border-color: var(--border-color);
    box-shadow: var(--shadow);
}

.service-card:hover {
    background: var(--card-hover-bg);
    box-shadow: var(--shadow-hover);
}

.service-card h3 {
    color: var(--text-primary);
}

.service-card p {
    color: var(--text-secondary);
}

/* 优化标题色彩 */
.welcome-title, .global-services-title {
    color: var(--text-primary);
}

/* 优化头部色彩 */
.header {
    background: rgba(102, 126, 234, 0.85);
}

/* 底部悬浮按钮样式 */
.floating-btn {
    position: fixed;
    bottom: 40px;
    right: 40px;
    transform: none;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 35px;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(76, 175, 80, 0.4);
    z-index: 9999;
    min-width: 200px;
    justify-content: center;
    text-decoration: none;
    overflow: hidden;
    animation: bounce 2s infinite ease-in-out;
    opacity: 1;
    visibility: visible;
    pointer-events: all;
    margin: 0;
    letter-spacing: 0.5px;
}

/* 响应式设计：手机版 */
@media (max-width: 768px) {
    .floating-btn {
        bottom: 20px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        gap: 8px;
        padding: 12px 24px;
        font-size: 14px;
        min-width: 160px;
        box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
    }
}

/* 更小屏幕的调整 */
@media (max-width: 480px) {
    .floating-btn {
        bottom: 15px;
        gap: 6px;
        padding: 10px 20px;
        font-size: 12px;
        min-width: 140px;
    }
}

/* 群聊福利卡片样式 */
.group-benefit-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 30px;
    margin: 40px auto;
    max-width: 1000px;
    box-shadow: var(--shadow-hover);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.group-benefit-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    transform: translateY(-5px);
}

.group-benefit-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
}

.group-benefit-icon {
    color: var(--primary-color);
    flex-shrink: 0;
}

.group-benefit-info {
    flex: 1;
}

.group-benefit-title {
    color: var(--text-primary);
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.3;
}

.group-benefit-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 25px;
}

.group-benefit-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 28px;
    background: var(--primary-gradient);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.group-benefit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.4);
}

/* 响应式设计：群聊福利卡片 */
@media (max-width: 768px) {
    .group-benefit-card {
        padding: 20px;
        margin: 30px 20px;
    }
    
    .group-benefit-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .group-benefit-title {
        font-size: 1.5rem;
    }
    
    .group-benefit-description {
        font-size: 1rem;
    }
    
    .group-benefit-btn {
        padding: 10px 24px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .group-benefit-card {
        padding: 15px;
        margin: 20px 15px;
    }
    
    .group-benefit-title {
        font-size: 1.3rem;
    }
    
    .group-benefit-description {
        font-size: 0.95rem;
        margin-bottom: 20px;
    }
    
    .group-benefit-btn {
        padding: 8px 20px;
        font-size: 0.9rem;
    }
}

/* 滚动距离占位符 */
.scroll-placeholder {
    height: 300px;
    width: 100%;
}

/* 上下跳动动画 */
@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-15px);
    }
}

.floating-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.floating-btn:active::before {
    width: 300px;
    height: 300px;
}



.floating-btn:active {
    transform: translateY(0);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.3);
}

.floating-btn__icon {
    font-size: 24px;
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.floating-btn:hover .floating-btn__icon {
    transform: scale(1.1);
}

.floating-btn__text {
    white-space: nowrap;
    position: relative;
    z-index: 1;
    color: white;
}

/* 底部内容样式 */
.footer-content {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 60px 30px 150px;
    margin-top: 80px;
    border-radius: 20px 20px 0 0;
    color: white;
}

.footer-section {
    max-width: 1200px;
    margin: 0 auto 40px;
    text-align: center;
}

.footer-section h3 {
    font-size: 1.6rem;
    margin-bottom: 25px;
    color: #e0c3fc;
    font-weight: 600;
    line-height: 1.3;
}

.footer-section p {
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.95);
    letter-spacing: 0.5px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
}

.footer-section li {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.95);
    position: relative;
    padding-left: 30px;
    line-height: 1.6;
    letter-spacing: 0.5px;
}

.footer-section li::before {
    content: '✨';
    position: absolute;
    left: 0;
    top: 0;
    font-size: 1.2rem;
}

/* 响应式设计 - 底部内容 */
@media (max-width: 767px) {
    .footer-content {
        padding: 30px 15px;
        margin-top: 30px;
    }
    
    .footer-section h3 {
        font-size: 1.3rem;
    }
    
    .footer-section p {
        font-size: 0.95rem;
    }
    
    .footer-section ul {
        gap: 15px;
    }
    
    .footer-section li {
        font-size: 0.95rem;
    }
}

/* 响应式设计 - 底部悬浮按钮 */
@media (max-width: 767px) {
    .floating-btn {
        padding: 12px 24px;
        font-size: 14px;
        min-width: 180px;
        bottom: 20px;
        right: 20px;
    }
    
    .floating-btn__icon {
        font-size: 18px;
    }
    
    .floating-btn__text {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .floating-btn {
        padding: 10px 20px;
        font-size: 13px;
        min-width: 160px;
        gap: 8px;
        bottom: 15px;
        right: 15px;
    }
    
    .floating-btn__icon {
        font-size: 16px;
    }
    
    .floating-btn__text {
        font-size: 12px;
    }
}

/* 内容按钮容器样式 */
.content-buttons-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 30px;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

/* 内容按钮样式 */
.content-button {
    background: var(--button-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 25px;
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    font-family: 'Poppins', sans-serif;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.button-title {
    flex: 1;
    margin-right: 15px;
}

.button-arrow {
    font-size: 0.8rem;
    display: inline-block;
    width: 20px;
    text-align: center;
}

/* 抽屉遮罩样式 */
.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--drawer-overlay-bg);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.drawer-overlay-visible {
    opacity: 1;
    visibility: visible;
}

/* 抽屉组件样式 */
.drawer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 80vh;
    background: var(--drawer-bg);
    border-radius: 20px 20px 0 0;
    box-shadow: var(--drawer-shadow);
    z-index: 1001;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    color: var(--drawer-text);
}

.drawer-open {
    transform: translateY(0);
}

/* 抽屉头部样式 */
.drawer-header {
    background: var(--drawer-header-bg);
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 20px 20px 0 0;
    color: white;
}

.drawer-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
}

.drawer-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 24px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.drawer-close:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: rotate(90deg);
}

/* 抽屉内容样式 */
.drawer-content {
    padding: 25px;
    overflow-y: auto;
    flex: 1;
    font-size: 1rem;
    line-height: 1.8;
    color: var(--drawer-text);
    font-weight: 400;
    text-align: center;
}

.drawer-content ul {
    list-style-type: none !important;
    list-style-position: inside;
    padding-left: 0;
    margin-left: 0;
}

.drawer-content li {
    text-align: center;
    margin-bottom: 0.5rem;
}

/* 抽屉滚动条样式 */
.drawer-content::-webkit-scrollbar {
    width: 8px;
}

.drawer-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

.drawer-content::-webkit-scrollbar-thumb {
    background: var(--primary-gradient);
    border-radius: 4px;
}

.drawer-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

/* 响应式设计 - 内容按钮 */
@media (max-width: 767px) {
    .content-buttons-container {
        grid-template-columns: 1fr;
        gap: 15px;
        margin-top: 25px;
    }
    
    .content-button {
        padding: 18px 20px;
        font-size: 1rem;
    }
    
    .button-title {
        margin-right: 10px;
    }
    
    /* 抽屉样式调整 */
    .drawer {
        max-height: 90vh;
        border-radius: 15px 15px 0 0;
    }
    
    .drawer-header {
        padding: 18px 20px;
    }
    
    .drawer-title {
        font-size: 1.2rem;
    }
    
    .drawer-content {
        padding: 20px;
        font-size: 0.95rem;
        line-height: 1.7;
    }
}

@media (max-width: 480px) {
    .content-buttons-container {
        gap: 12px;
        margin-top: 20px;
    }
    
    .content-button {
        padding: 15px 18px;
        font-size: 0.95rem;
    }
    
    .button-arrow {
        font-size: 0.7rem;
        width: 18px;
    }
    
    /* 抽屉样式调整 */
    .drawer {
        max-height: 95vh;
        border-radius: 12px 12px 0 0;
    }
    
    .drawer-header {
        padding: 15px 18px;
    }
    
    .drawer-title {
        font-size: 1.1rem;
    }
    
    .drawer-content {
        padding: 18px;
        font-size: 0.9rem;
        line-height: 1.6;
    }
    
    .drawer-close {
        width: 35px;
        height: 35px;
        font-size: 20px;
    }
}