/* 雄安OPC 前台样式 */
:root {
    --primary: #4f46e5;
    --primary-dark: #4338ca;
    --primary-light: #eef2ff;
    --accent: #06b6d4;
    --dark: #0f172a;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-500: #64748b;
    --gray-700: #334155;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 1px 3px rgba(0,0,0,.08), 0 4px 12px rgba(0,0,0,.04);
    --shadow-lg: 0 8px 30px rgba(0,0,0,.1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--dark);
    background: var(--gray-50);
    line-height: 1.6;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ========== Header ========== */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--gray-200);
    position: sticky; top: 0; z-index: 100;
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 64px; gap: 24px;
}
.logo { display: flex; flex-direction: column; text-decoration: none; }
.logo-text { font-size: 24px; font-weight: 800; color: var(--dark); line-height: 1.1; }
.logo-accent { color: var(--primary); }
.logo small { font-size: 11px; color: var(--gray-500); }
.main-nav { display: flex; gap: 28px; flex: 1; justify-content: center; }
.main-nav a {
    color: var(--gray-700); font-weight: 500; font-size: 15px;
    padding: 6px 0; border-bottom: 2px solid transparent;
}
.main-nav a:hover, .main-nav a.active { color: var(--primary); border-color: var(--primary); text-decoration: none; }

/* ========== Buttons ========== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 10px 22px; border-radius: var(--radius-sm); font-size: 15px; font-weight: 600;
    border: none; cursor: pointer; transition: all .2s; text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); text-decoration: none; }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary-light); text-decoration: none; }
.btn-sm { padding: 7px 16px; font-size: 13px; }
.btn-lg { padding: 14px 36px; font-size: 17px; }

/* ========== Hero ========== */
.hero {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #06b6d4 100%);
    color: #fff; text-align: center; padding: 80px 20px 100px;
}
.hero h1 { font-size: 42px; font-weight: 800; margin-bottom: 12px; }
.hero p { font-size: 18px; opacity: .9; margin-bottom: 32px; }
.hero .btn { background: #fff; color: var(--primary); }
.hero .btn:hover { background: var(--gray-100); }

/* ========== Stats ========== */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; max-width: 900px; margin: -60px auto 0; position: relative; z-index: 10; }
.stat-card {
    background: #fff; border-radius: var(--radius); padding: 28px 20px; text-align: center;
    box-shadow: var(--shadow-lg);
}
.stat-num { font-size: 36px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 14px; color: var(--gray-500); margin-top: 4px; }

/* ========== Section ========== */
.section { padding: 64px 0; }
.section-title { text-align: center; font-size: 30px; font-weight: 800; margin-bottom: 8px; }
.section-subtitle { text-align: center; color: var(--gray-500); margin-bottom: 40px; font-size: 16px; }

/* ========== Service Cards ========== */
.service-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.service-card {
    background: #fff; border-radius: var(--radius); padding: 32px 24px;
    box-shadow: var(--shadow); border: 1px solid var(--gray-200);
    transition: transform .2s, box-shadow .2s; text-decoration: none; color: inherit;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); text-decoration: none; }
.service-icon { font-size: 32px; margin-bottom: 16px; }
.service-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; color: var(--dark); }
.service-card p { font-size: 14px; color: var(--gray-500); }

/* ========== CTA ========== */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #fff; text-align: center; padding: 56px 20px; border-radius: 0;
}
.cta-section h2 { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.cta-section p { opacity: .9; margin-bottom: 24px; }
.cta-section .btn { background: #fff; color: var(--primary); }

/* ========== Community List ========== */
.community-filter {
    display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px;
    padding: 20px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
}
.community-filter a {
    padding: 6px 16px; border-radius: 20px; font-size: 14px; font-weight: 500;
    background: var(--gray-100); color: var(--gray-700);
}
.community-filter a:hover, .community-filter a.active { background: var(--primary); color: #fff; text-decoration: none; }

.community-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.community-card {
    background: #fff; border-radius: var(--radius); padding: 24px;
    box-shadow: var(--shadow); border: 1px solid var(--gray-200);
}
.community-region { font-size: 13px; color: var(--accent); font-weight: 600; margin-bottom: 6px; }
.community-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.community-addr { font-size: 13px; color: var(--gray-500); margin-bottom: 10px; }
.community-desc { font-size: 14px; color: var(--gray-700); margin-bottom: 14px; }
.community-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.tag {
    padding: 3px 12px; border-radius: 16px; font-size: 12px; font-weight: 500;
}
.tag-seat { background: #ecfdf5; color: #059669; }
.tag-compute { background: #eff6ff; color: #2563eb; }
.tag-invest { background: #fef3c7; color: #d97706; }

/* ========== Marketplace ========== */
.marketplace-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.order-card {
    background: #fff; border-radius: var(--radius); padding: 24px;
    box-shadow: var(--shadow); border: 1px solid var(--gray-200);
    display: flex; flex-direction: column;
}
.order-cat { font-size: 13px; color: var(--accent); font-weight: 600; margin-bottom: 6px; }
.order-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.order-desc { font-size: 14px; color: var(--gray-700); margin-bottom: 14px; flex: 1; }
.order-meta { display: flex; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--gray-500); margin-bottom: 14px; }
.order-meta span { display: inline-flex; align-items: center; gap: 4px; }
.order-price { color: var(--primary); font-weight: 700; font-size: 15px; }

/* ========== About ========== */
.about-content { max-width: 800px; margin: 0 auto; background: #fff; padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow); }
.about-content h2 { font-size: 24px; margin: 24px 0 12px; }
.about-content p { color: var(--gray-700); margin-bottom: 16px; }

/* ========== Footer ========== */
.site-footer { background: var(--dark); color: #94a3b8; padding: 48px 0 24px; margin-top: 64px; }
.footer-top { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 32px; }
.footer-col h4 { color: #fff; font-size: 16px; margin-bottom: 12px; }
.footer-col p { font-size: 14px; line-height: 1.6; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { color: #94a3b8; font-size: 14px; }
.footer-col ul li a:hover { color: #fff; }
.footer-bottom { border-top: 1px solid #1e293b; padding-top: 20px; text-align: center; font-size: 13px; }
.footer-bottom a { color: #94a3b8; }

/* ========== Auth ========== */
.auth-wrap { max-width: 420px; margin: 60px auto; }
.auth-card { background: #fff; border-radius: var(--radius); padding: 40px; box-shadow: var(--shadow-lg); }
.auth-card h2 { text-align: center; margin-bottom: 24px; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; color: var(--gray-700); }
.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 10px 14px; border: 1px solid var(--gray-300);
    border-radius: var(--radius-sm); font-size: 15px; font-family: inherit;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.form-group textarea { min-height: 100px; resize: vertical; }
.form-check { display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.form-check input { width: auto; }
.auth-link { text-align: center; margin-top: 16px; font-size: 14px; }

/* ========== Alert ========== */
.alert { padding: 12px 18px; border-radius: var(--radius-sm); margin-bottom: 20px; font-size: 14px; }
.alert-error { background: #fef2f2; color: #dc2626; }
.alert-success { background: #f0fdf4; color: #16a34a; }

/* ========== Community Card Link ========== */
.community-card {
    cursor: pointer; transition: transform .2s, box-shadow .2s, border-color .2s;
    display: block; text-decoration: none; color: inherit;
}
.community-card:hover {
    transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--primary);
    text-decoration: none;
}
.community-card a { color: inherit; text-decoration: none; }

/* ========== Search Bar ========== */
.search-bar {
    display: flex; gap: 12px; margin-bottom: 20px; padding: 20px;
    background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
}
.search-bar input {
    flex: 1; padding: 10px 16px; border: 1px solid var(--gray-300);
    border-radius: var(--radius-sm); font-size: 15px; font-family: inherit;
}
.search-bar input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.search-bar .btn { white-space: nowrap; }

/* ========== Breadcrumb ========== */
.breadcrumb {
    display: flex; align-items: center; gap: 8px; font-size: 14px;
    color: var(--gray-500); margin-bottom: 24px;
}
.breadcrumb a { color: var(--gray-500); }
.breadcrumb a:hover { color: var(--primary); text-decoration: none; }
.breadcrumb .sep { color: var(--gray-300); }
.breadcrumb .current { color: var(--gray-700); font-weight: 500; }

/* ========== Community Detail ========== */
.detail-header {
    background: #fff; border-radius: var(--radius); padding: 32px;
    box-shadow: var(--shadow); border: 1px solid var(--gray-200); margin-bottom: 24px;
}
.detail-header .region-tag {
    display: inline-block; font-size: 13px; color: var(--accent); font-weight: 600;
    background: #ecfeff; padding: 4px 14px; border-radius: 16px; margin-bottom: 12px;
}
.detail-header h1 { font-size: 28px; font-weight: 800; margin-bottom: 12px; }
.detail-header .detail-addr { font-size: 15px; color: var(--gray-500); margin-bottom: 16px; }
.detail-tags { display: flex; gap: 8px; flex-wrap: wrap; }

.detail-grid { display: grid; grid-template-columns: 1fr 320px; gap: 24px; align-items: start; }
.detail-main { min-width: 0; }
.detail-sidebar { position: sticky; top: 84px; }

.detail-section {
    background: #fff; border-radius: var(--radius); padding: 28px;
    box-shadow: var(--shadow); border: 1px solid var(--gray-200); margin-bottom: 20px;
}
.detail-section h2 { font-size: 18px; font-weight: 700; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 2px solid var(--gray-100); }
.detail-section p { font-size: 15px; color: var(--gray-700); line-height: 1.8; margin-bottom: 12px; }

.policy-item {
    display: flex; gap: 14px; padding: 16px; border-radius: var(--radius-sm);
    background: var(--gray-50); margin-bottom: 12px;
}
.policy-item .policy-icon { font-size: 24px; flex-shrink: 0; }
.policy-item .policy-body h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.policy-item .policy-body p { font-size: 13px; color: var(--gray-500); margin: 0; }

.apply-card {
    background: #fff; border-radius: var(--radius); padding: 28px;
    box-shadow: var(--shadow-lg); border: 1px solid var(--gray-200); text-align: center;
}
.apply-card h3 { font-size: 20px; font-weight: 700; margin-bottom: 8px; }
.apply-card p { font-size: 14px; color: var(--gray-500); margin-bottom: 20px; }
.apply-card .btn { width: 100%; margin-bottom: 10px; }
.apply-card .contact-info { font-size: 13px; color: var(--gray-500); margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--gray-100); }

.detail-meta-list { list-style: none; margin-bottom: 0; }
.detail-meta-list li {
    display: flex; justify-content: space-between; padding: 10px 0;
    border-bottom: 1px solid var(--gray-100); font-size: 14px;
}
.detail-meta-list li:last-child { border-bottom: none; }
.detail-meta-list li .label { color: var(--gray-500); }
.detail-meta-list li .value { color: var(--gray-700); font-weight: 500; }

/* ========== Related Communities ========== */
.related-list { display: grid; grid-template-columns: 1fr; gap: 12px; }
.related-card {
    display: flex; align-items: center; gap: 12px; padding: 14px;
    border-radius: var(--radius-sm); background: var(--gray-50); transition: background .2s;
    text-decoration: none; color: inherit;
}
.related-card:hover { background: var(--primary-light); text-decoration: none; }
.related-card .r-region { font-size: 12px; color: var(--gray-500); }
.related-card .r-name { font-size: 14px; font-weight: 600; color: var(--gray-700); }

/* ========== FAQ ========== */
.faq-section { max-width: 800px; margin: 40px auto 0; }
.faq-section h2 { text-align: center; font-size: 24px; font-weight: 800; margin-bottom: 28px; }
.faq-item {
    background: #fff; border-radius: var(--radius-sm); margin-bottom: 12px;
    border: 1px solid var(--gray-200); overflow: hidden;
}
.faq-item summary {
    padding: 16px 20px; font-size: 15px; font-weight: 600; cursor: pointer;
    list-style: none; display: flex; align-items: center; justify-content: space-between;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-size: 20px; color: var(--gray-400); transition: transform .2s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { padding: 0 20px 16px; font-size: 14px; color: var(--gray-700); line-height: 1.7; }

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .header-inner { flex-wrap: wrap; height: auto; padding: 12px 0; }
    .main-nav { order: 3; width: 100%; justify-content: flex-start; overflow-x: auto; }
    .hero h1 { font-size: 28px; }
    .hero { padding: 48px 20px 80px; }
    .stats { grid-template-columns: repeat(2, 1fr); margin-top: -40px; }
    .stat-num { font-size: 28px; }
    .service-grid { grid-template-columns: 1fr; }
    .community-list, .marketplace-list { grid-template-columns: 1fr; }
    .detail-grid { grid-template-columns: 1fr; }
    .detail-sidebar { position: static; }
    .footer-top { grid-template-columns: 1fr; gap: 24px; }
}
