/* 科技感会议网站样式系统 */

/* 全局样式重置与基础设置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 为特定的锚点链接目标添加滚动边距，避免影响主要内容显示 */
/* 只针对speakers页面的演讲者部分添加样式 */
.speaker-container {
    scroll-margin-top: 120px;
    scroll-padding-top: 120px;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    color: #333;
    background-color: #f5f7fa;
    line-height: 1.6;
    overflow-x: hidden;
}

/* 平滑滚动效果 */
html {
    scroll-behavior: smooth;
}

/* 两端对齐样式 - 提高优先级确保生效 */
p:not(.text-center), .text-justify {
    text-align: justify !important;
    text-indent: 0 !important; /* 移除首行缩进 */
    hyphens: auto;
}

/* programcommittees页面特殊样式 */
.program-committees .text-center, .text-center {
    text-align: center !important;
    text-indent: 0 !important;
}

/* 页脚中的p元素使用左对齐 */
#footer p {
    text-align: left !important;
    text-indent: 0 !important;
}

/* 科技感颜色系统 */
:root {
    --primary: #0f172a;
    --secondary: #06b6d4;
    --accent: #10b981;
    --highlight: #8b5cf6;
    --light: #f8fafc;
    --dark: #1e293b;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
}

/* 导航链接样式 */
.nav-link {
    position: relative;
    overflow: hidden;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background: linear-gradient(90deg, var(--secondary), var(--accent));
    transition: width 0.4s ease, left 0.4s ease;
}

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

/* 科技感动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

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

@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* 工具类 */
.fade-in-up {
    animation: fadeInUp 0.8s ease forwards;
    opacity: 0;
}

.fade-in-up-delay-1 {
    animation: fadeInUp 0.8s ease 0.2s forwards;
    opacity: 0;
}

.fade-in-up-delay-2 {
    animation: fadeInUp 0.8s ease 0.4s forwards;
    opacity: 0;
}

.pulse {
    animation: pulse 2s infinite;
}

.float {
    animation: float 6s ease-in-out infinite;
}

.gradient-bg {
    background: linear-gradient(-45deg, var(--primary), #020617, var(--secondary), var(--accent));
    background-size: 400% 400%;
    animation: gradientFlow 15s ease infinite;
}

.tech-card {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
}

.tech-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.tech-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--secondary), var(--accent));
}

/* 玻璃态效果 */
.glassmorphism {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
}

/* 科技感按钮 */
.tech-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    z-index: 1;
}

.tech-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s ease;
    z-index: -1;
}

.tech-btn:hover::before {
    left: 100%;
}

.tech-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* 装饰元素 */
.decor-circle {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.1) 0%, rgba(6, 182, 212, 0) 70%);
    z-index: 0;
}

.decor-line {
    position: absolute;
    background: linear-gradient(90deg, var(--secondary), transparent);
    height: 1px;
    z-index: 0;
}

/* 针对标题元素不应用两端对齐 */
h1, h2, h3, h4, h5, h6 {
    text-align: left;
    text-indent: 0;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .fade-in-up {
        animation: fadeInUp 0.6s ease forwards;
    }
    
    .tech-card:hover {
        transform: translateY(-5px);
    }
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(var(--secondary), var(--accent));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(var(--accent), var(--secondary));
}

/* 页面加载动画 */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#page-loader.hidden {
    opacity: 0;
    visibility: hidden;
}

/* 炫酷的旋转加载器 */
.loader-spinner {
    position: relative;
    width: 80px;
    height: 80px;
}

.loader-spinner::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 60px;
    margin: -30px 0 0 -30px;
    border: 4px solid transparent;
    border-top: 4px solid var(--secondary);
    border-right: 4px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader-spinner::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 80px;
    height: 80px;
    margin: -40px 0 0 -40px;
    border: 2px solid transparent;
    border-bottom: 2px solid var(--highlight);
    border-radius: 50%;
    animation: spin 2s linear infinite reverse;
}

.loader-dots {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.loader-dot {
    position: absolute;
    width: 8px;
    height: 8px;
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    border-radius: 50%;
    opacity: 0;
    animation: pulseDot 1.5s ease-in-out infinite;
}

.loader-dot:nth-child(1) {
    top: -20px;
    left: 0;
    animation-delay: 0s;
}

.loader-dot:nth-child(2) {
    top: -14px;
    right: -14px;
    animation-delay: 0.2s;
}

.loader-dot:nth-child(3) {
    right: -20px;
    top: 0;
    animation-delay: 0.4s;
}

.loader-dot:nth-child(4) {
    bottom: -14px;
    right: -14px;
    animation-delay: 0.6s;
}

.loader-dot:nth-child(5) {
    bottom: -20px;
    left: 0;
    animation-delay: 0.8s;
}

.loader-dot:nth-child(6) {
    bottom: -14px;
    left: -14px;
    animation-delay: 1s;
}

.loader-dot:nth-child(7) {
    left: -20px;
    top: 0;
    animation-delay: 1.2s;
}

.loader-dot:nth-child(8) {
    top: -14px;
    left: -14px;
    animation-delay: 1.4s;
}

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

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

/* 页面切换淡入效果 */
.page-transition {
    animation: pageFadeIn 0.8s ease-out;
}

@keyframes pageFadeIn {
    from {
        opacity: 0.3;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}