/* 自定义样式 */
* {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
}

/* 导航栏平滑过渡 */
.nav-link {
    position: relative;
    transition: all 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #1e3a8a;
    transition: width 0.3s ease;
}

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

/* 表单输入框焦点效果 */
input:focus,
textarea:focus {
    transform: translateY(-2px);
    transition: all 0.3s ease;
}

/* 按钮悬停效果 */
button {
    transition: all 0.3s ease;
}

button:hover {
    transform: translateY(-2px);
}

/* 卡片悬停效果 */
.hover\:shadow-2xl {
    transition: all 0.3s ease;
}

/* 图片悬停效果 */
img {
    transition: transform 0.3s ease;
}

img:hover {
    transform: scale(1.05);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .text-5xl {
        font-size: 2.5rem;
    }
    
    .text-4xl {
        font-size: 2rem;
    }
    
    .text-3xl {
        font-size: 1.75rem;
    }

    /* 手机端导航栏紧凑 */
    nav .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Hero区域手机适配 */
    #home .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    #home h1 {
        font-size: 2rem;
        line-height: 1.3;
    }

    /* 案例卡片手机端图片在下方 */
    .case-card .grid {
        grid-template-columns: 1fr;
    }

    .case-img-container {
        order: 2;
    }

    /* 服务卡片手机端间距 */
    #services .grid {
        gap: 1rem;
    }
}

@media (max-width: 480px) {
    .text-5xl {
        font-size: 2rem;
    }

    .text-4xl {
        font-size: 1.5rem;
    }

    .text-3xl {
        font-size: 1.25rem;
    }

    .text-2xl {
        font-size: 1.125rem;
    }

    /* 超小屏按钮全宽 */
    #home a.inline-block {
        display: block;
        text-align: center;
    }
}

/* 案例卡片样式 */
.case-card {
    transition: all 0.3s ease;
}

.case-card:hover {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    transform: translateY(-4px);
}

.case-img {
    transition: transform 0.3s ease;
}

.case-card:hover .case-img {
    transform: scale(1.02);
}

/* 案例图片容器不影响卡片悬停 */
.case-img-container img:hover {
    transform: none;
}

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

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* 成功/错误消息样式 */
.success-message {
    background-color: #10b981;
    color: white;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

.error-message {
    background-color: #ef4444;
    color: white;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 10px;
}

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

::-webkit-scrollbar-thumb {
    background: #1e3a8a;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1e40af;
}