/* 上海积分落户服务网站 - 现代简约深蓝科技风格 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 全局变量定义 - 深蓝科技配色 */
:root {
    --bg-primary: #f8fafc;
    --bg-white: #ffffff;
    --bg-light: #f1f5f9;
    --text-dark: #0f172a;
    --text-gray: #475569;
    --text-light: #64748b;
    --primary-blue: #2563eb;
    --primary-indigo: #4f46e5;
    --primary-cyan: #0891b2;
    --accent-green: #10b981;
    --border-light: #e2e8f0;
    --shadow-soft: 0 1px 2px rgba(15, 23, 42, 0.05);
    --shadow-medium: 0 4px 6px -1px rgba(15, 23, 42, 0.1);
    --shadow-large: 0 10px 15px -3px rgba(15, 23, 42, 0.1);
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* 头部样式 */
header {
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 50%, #0891b2 100%);
    color: white;
    padding: 32px 0;
    box-shadow: var(--shadow-medium);
    position: relative;
}

header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: 32px;
    font-weight: 700;
    letter-spacing: 1px;
    color: white;
}

header p {
    font-size: 15px;
    color: #94a3b8;
    margin-top: 6px;
    font-weight: 400;
}

header .contact-info {
    text-align: right;
    font-size: 15px;
}

header .contact-info p {
    margin: 6px 0;
    color: #60a5fa;
    font-weight: 600;
}

/* 导航菜单 */
nav {
    background: var(--bg-white);
    box-shadow: var(--shadow-soft);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-light);
}

nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

nav ul li {
    position: relative;
}

nav ul li a {
    display: block;
    padding: 20px 28px;
    text-decoration: none;
    color: var(--text-gray);
    font-weight: 500;
    font-size: 15px;
    letter-spacing: 0.3px;
    transition: all 0.3s ease;
    position: relative;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-blue), var(--primary-indigo));
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

nav ul li a:hover,
nav ul li a.active {
    color: var(--primary-blue);
    background-color: var(--bg-light);
}

nav ul li a:hover::after,
nav ul li a.active::after {
    width: 70%;
}

/* 下拉菜单 */
nav ul li .dropdown {
    display: none;
    position: absolute;
    background: var(--bg-white);
    min-width: 300px;
    box-shadow: var(--shadow-large);
    z-index: 1001;
    border-top: 3px solid var(--primary-blue);
    border-radius: 0 0 12px 12px;
    margin-top: 0;
    border: 1px solid var(--border-light);
    border-top: 3px solid var(--primary-blue);
}

nav ul li:hover .dropdown {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

nav ul li .dropdown a {
    padding: 15px 24px;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-gray);
    font-size: 14px;
    font-weight: 400;
}

nav ul li .dropdown a:hover {
    background-color: var(--bg-light);
    color: var(--primary-blue);
    padding-left: 30px;
}

nav ul li .dropdown a:last-child {
    border-bottom: none;
    border-radius: 0 0 12px 12px;
}

/* 主要内容区域 */
.main-content {
    padding: 56px 0;
}

/* 英雄区域 */
.hero-section {
    background: linear-gradient(135deg, #1e3a8a 0%, #312e81 50%, #1e40af 100%);
    color: white;
    padding: 80px 0;
    margin-bottom: 56px;
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-large);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="40" height="40" patternUnits="userSpaceOnUse"><path d="M 40 0 L 0 0 0 40" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.hero-section .container {
    position: relative;
    z-index: 1;
}

.hero-section h2 {
    font-size: 42px;
    margin-bottom: 24px;
    font-weight: 700;
    letter-spacing: 1px;
    color: white;
}

.hero-section p {
    font-size: 18px;
    margin-bottom: 36px;
    color: #cbd5e1;
    line-height: 1.8;
    max-width: 700px;
}

.hero-btn {
    display: inline-block;
    padding: 16px 48px;
    background: linear-gradient(135deg, var(--primary-cyan) 0%, var(--primary-blue) 100%);
    color: white;
    text-decoration: none;
    border-radius: 100px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(8, 145, 178, 0.4);
    transition: all 0.3s ease;
}

.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(8, 145, 178, 0.5);
}

/* 卡片样式 */
.card {
    background: var(--bg-white);
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-light);
}

.card h2 {
    color: var(--text-dark);
    margin-bottom: 28px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--border-light);
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.card h3 {
    color: var(--primary-blue);
    margin: 28px 0 16px;
    font-size: 20px;
    font-weight: 600;
}

/* 特色服务网格 */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 28px;
    margin: 36px 0;
}

.service-card {
    background: var(--bg-white);
    padding: 36px 28px;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-blue);
}

.service-card .icon {
    font-size: 56px;
    margin-bottom: 20px;
    display: block;
}

.service-card h4 {
    color: var(--text-dark);
    margin-bottom: 12px;
    font-size: 19px;
    font-weight: 600;
}

.service-card p {
    color: var(--text-gray);
    font-size: 15px;
    line-height: 1.7;
}

/* 区县列表 */
.district-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    margin: 28px 0;
}

.district-item {
    background: var(--bg-white);
    padding: 20px 24px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.district-item:hover {
    background: var(--bg-light);
    transform: translateX(6px);
    border-color: var(--primary-blue);
}

.district-item a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 16px;
    display: block;
    transition: color 0.3s ease;
}

.district-item a:hover {
    color: var(--primary-blue);
}

/* 文章内容 */
.article-content {
    font-size: 16px;
}

.article-content p {
    margin-bottom: 22px;
    text-align: justify;
    color: var(--text-gray);
}

.article-content ul,
.article-content ol {
    margin: 28px 0;
    padding-left: 36px;
}

.article-content li {
    margin-bottom: 12px;
    color: var(--text-gray);
    line-height: 1.7;
}

.article-content a {
    color: var(--primary-blue);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
    font-weight: 500;
}

.article-content a:hover {
    color: var(--primary-indigo);
    border-bottom-color: var(--primary-blue);
}

.article-content blockquote {
    background: var(--bg-light);
    border-left: 4px solid var(--primary-blue);
    padding: 28px 32px;
    margin: 36px 0;
    border-radius: 0 12px 12px 0;
}

.article-content blockquote strong {
    color: var(--primary-blue);
}

/* FAQ样式 */
.faq-item {
    border-bottom: 1px solid var(--border-light);
    padding: 28px 0;
}

.faq-question {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 12px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.faq-question:hover {
    color: var(--primary-blue);
}

.faq-answer {
    color: var(--text-gray);
    line-height: 1.8;
}

/* 联系表单 */
.contact-form {
    max-width: 700px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 28px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 15px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border-light);
    border-radius: 10px;
    font-size: 15px;
    background: var(--bg-white);
    color: var(--text-dark);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-blue);
    background: var(--bg-white);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.btn {
    display: inline-block;
    padding: 14px 36px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-indigo) 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn:hover {
    background: linear-gradient(135deg, var(--primary-indigo) 0%, var(--primary-blue) 100%);
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.btn-primary {
    background: var(--primary-cyan);
}

.btn-primary:hover {
    background: #0e7490;
}

/* 面包屑导航 */
.breadcrumb {
    margin: 28px 0;
    padding: 16px 24px;
    font-size: 14px;
    color: var(--text-light);
    background: var(--bg-white);
    border-radius: 12px;
    border: 1px solid var(--border-light);
}

.breadcrumb a {
    color: var(--primary-blue);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.breadcrumb a:hover {
    color: var(--primary-indigo);
    text-decoration: underline;
}

.breadcrumb span {
    margin: 0 10px;
    color: var(--text-light);
}

/* 页脚 - 4列布局 */
footer {
    background: linear-gradient(135deg, #2563eb 0%, #4f46e5 50%, #0891b2 100%);
    color: white;
    padding: 64px 0 32px;
    margin-top: 72px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-bottom: 48px;
}

.footer-section h4 {
    font-size: 17px;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-cyan);
    color: white;
    font-weight: 700;
    display: inline-block;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 12px;
}

.footer-section ul li a {
    color: #94a3b8;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
    font-weight: 400;
    font-size: 14px;
}

.footer-section ul li a:hover {
    color: var(--primary-cyan);
    transform: translateX(4px);
}

.footer-bottom {
    text-align: center;
    padding-top: 32px;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
    color: #94a3b8;
    font-size: 14px;
}

.footer-bottom a {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom a:hover {
    color: var(--primary-cyan);
}

/* 表格样式 */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 28px 0;
    background: var(--bg-white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-light);
}

table th {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-indigo) 100%);
    color: white;
    padding: 16px 18px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
}

table td {
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-gray);
}

table tr:hover td {
    background: var(--bg-light);
    color: var(--text-dark);
}

table tr:last-child td {
    border-bottom: none;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    header .header-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    header .contact-info {
        text-align: center;
    }
    
    header h1 {
        font-size: 28px;
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    header h1 {
        font-size: 24px;
    }
    
    nav ul {
        justify-content: flex-start;
    }
    
    nav ul li a {
        padding: 16px 18px;
        font-size: 14px;
    }
    
    .hero-section {
        padding: 48px 0;
    }
    
    .hero-section h2 {
        font-size: 32px;
    }
    
    .hero-section p {
        font-size: 16px;
    }
    
    .card {
        padding: 28px 24px;
    }
    
    .card h2 {
        font-size: 22px;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .district-list {
        grid-template-columns: repeat(2, 1fr);
    }
    
    table {
        font-size: 14px;
    }
    
    table th,
    table td {
        padding: 12px;
    }
}

@media (max-width: 480px) {
    .district-list {
        grid-template-columns: 1fr;
    }
    
    .hero-btn {
        padding: 14px 36px;
        font-size: 15px;
    }
    
    .hero-section h2 {
        font-size: 26px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}
