/* ============================================================
   古冶三点半单招陪学中心 - 共享样式表
   版本: 2.0 | 优化日期: 2026-07-05
   ============================================================ */

/* ===== CSS Reset ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ===== 设计令牌 (Design Tokens) ===== */
:root {
    /* 主色系 */
    --primary: #0F3460;
    --primary-dark: #0a2540;
    --primary-light: #1a4b8c;
    --primary-50: #e8eef6;
    --primary-100: #c5d4e8;
    
    /* 强调色 */
    --accent: #FF7D00;
    --accent-light: #FF9500;
    --accent-dark: #E06E00;
    --accent-50: #fff7ed;
    --accent-100: #ffedd5;
    
    /* 中性色 */
    --white: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* 语义色 */
    --success: #059669;
    --success-light: #d1fae5;
    --warning: #d97706;
    --warning-light: #fef3c7;
    --danger: #dc2626;
    --danger-light: #fee2e2;
    --info: #2563eb;
    --info-light: #dbeafe;
    
    /* 阴影 */
    --shadow-xs: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-md: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
    --shadow-xl: 0 25px 50px -12px rgba(0,0,0,0.25);
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    /* 字体 */
    --font-sans: 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'WenQuanYi Micro Hei', -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans SC, sans-serif;
    --font-mono: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Menlo', 'Consolas', monospace;
    
    /* 字号层级 */
    --text-xs: 0.75rem;    /* 12px */
    --text-sm: 0.875rem;   /* 14px */
    --text-base: 1rem;     /* 16px */
    --text-lg: 1.125rem;   /* 18px */
    --text-xl: 1.25rem;    /* 20px */
    --text-2xl: 1.5rem;    /* 24px */
    --text-3xl: 1.875rem;  /* 30px */
    --text-4xl: 2.25rem;   /* 36px */
    
    /* 间距 */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    
    /* 行高 */
    --leading-tight: 1.25;
    --leading-snug: 1.375;
    --leading-normal: 1.6;
    --leading-relaxed: 1.75;
    --leading-loose: 2;
    
    /* 过渡 */
    --transition-fast: 150ms ease;
    --transition: 300ms ease;
    --transition-slow: 500ms ease;
    
    /* 层级 */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 1000;
    --z-modal: 1050;
    --z-popover: 1100;
    --z-tooltip: 1200;
}

/* ===== 基础排版 ===== */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: var(--leading-normal);
    color: var(--gray-800);
    background: var(--gray-50);
    overflow-x: hidden;
    word-break: break-word;
}

/* 优化中文排版 */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-sans);
    font-weight: 700;
    line-height: var(--leading-tight);
    letter-spacing: 0.02em;
    color: var(--gray-900);
}

h1 { font-size: var(--text-4xl); margin-bottom: var(--space-6); }
h2 { font-size: var(--text-3xl); margin-bottom: var(--space-5); }
h3 { font-size: var(--text-2xl); margin-bottom: var(--space-4); }
h4 { font-size: var(--text-xl); margin-bottom: var(--space-3); }
h5 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
h6 { font-size: var(--text-base); margin-bottom: var(--space-2); }

p {
    margin-bottom: var(--space-4);
    line-height: var(--leading-relaxed);
    letter-spacing: 0.01em;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--accent);
}

a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 2px;
}

/* ===== 容器 ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5);
}

.container-narrow {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 var(--space-5);
}

/* ===== 导航栏 ===== */
.navbar,
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-fixed);
    background: rgba(15, 52, 96, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 14px 0;
    transition: all var(--transition);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.navbar.scrolled,
.nav.scrolled {
    padding: 10px 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo,
.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--white);
    text-decoration: none;
    font-size: var(--text-lg);
    font-weight: 700;
    letter-spacing: 0.02em;
}

.nav-logo img {
    height: 40px;
    width: auto;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 24px;
    align-items: center;
}

.nav-links a {
    color: rgba(255,255,255,0.85);
    font-size: var(--text-sm);
    font-weight: 500;
    transition: color var(--transition-fast);
    padding: 6px 2px;
    position: relative;
}

.nav-links a:hover {
    color: var(--accent);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width var(--transition);
}

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

/* 汉堡菜单 */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 8px;
    border: none;
    background: none;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    border-radius: 1px;
    transition: all var(--transition);
}

/* ===== 页面头部横幅 ===== */
.page-header {
    position: relative;
    padding: 120px 0 60px;
    text-align: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    overflow: hidden;
}

.page-header .header-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    opacity: 0.06;
    background: url(data:image/svg+xml,%3Csvg xmlns=http://www.w3.org/2000/svg viewBox=0 0 1440 320%3E%3Cpath fill=white d=M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,154.7C960,171,1056,181,1152,170.7C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z/%3E%3C/svg%3E) no-repeat bottom center;
    background-size: cover;
}

.page-header h1 {
    font-size: var(--text-4xl);
    font-weight: 700;
    margin-bottom: var(--space-3);
    position: relative;
    letter-spacing: 0.03em;
}

.page-header .subtitle {
    font-size: var(--text-lg);
    opacity: 0.85;
    position: relative;
    font-weight: 400;
}

/* ===== 区块/卡片 ===== */
.section-box {
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
    margin: var(--space-8) auto;
    max-width: 1200px;
    overflow: hidden;
    transition: box-shadow var(--transition);
}

.section-box:hover {
    box-shadow: var(--shadow-md);
}

.section-title {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 18px 28px;
    font-size: var(--text-xl);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: 0.02em;
}

.section-body {
    padding: var(--space-8);
}

.info-card {
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
    padding: var(--space-8);
    margin: var(--space-8) auto;
    max-width: 1200px;
    transition: box-shadow var(--transition);
}

.info-card:hover {
    box-shadow: var(--shadow-md);
}

.info-card h2 {
    color: var(--primary);
    font-size: var(--text-2xl);
    margin-bottom: var(--space-4);
    padding-bottom: var(--space-3);
    border-bottom: 3px solid var(--accent);
}

/* ===== 数据表格 ===== */
.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: var(--text-sm);
}

.data-table thead th {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    white-space: nowrap;
    font-size: var(--text-sm);
    letter-spacing: 0.02em;
    position: sticky;
    top: 0;
    z-index: 1;
}

.data-table thead th:first-child {
    border-radius: var(--radius-sm) 0 0 0;
}

.data-table thead th:last-child {
    border-radius: 0 var(--radius-sm) 0 0;
}

.data-table tbody td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--gray-100);
    color: var(--gray-700);
    font-size: var(--text-sm);
    transition: background var(--transition-fast);
}

.data-table tbody tr:nth-child(even) {
    background: var(--gray-50);
}

.data-table tbody tr:hover {
    background: var(--primary-50);
}

.data-table a {
    color: var(--primary);
    font-weight: 500;
}

.data-table a:hover {
    color: var(--accent);
}

/* ===== 标签 ===== */
.tag {
    display: inline-flex;
    align-items: center;
    padding: 3px 12px;
    border-radius: 100px;
    font-size: var(--text-xs);
    font-weight: 600;
    letter-spacing: 0.02em;
}

.tag-gb {
    background: var(--success-light);
    color: var(--success);
}

.tag-mb {
    background: var(--warning-light);
    color: var(--warning);
}

/* ===== 按钮 ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-size: var(--text-base);
    font-weight: 600;
    font-family: var(--font-sans);
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
    text-decoration: none;
    line-height: 1.5;
    letter-spacing: 0.02em;
    min-height: 48px;
}

.btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(255,125,0,0.35);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-light) 0%, var(--accent) 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(255,125,0,0.45);
    color: var(--white);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-secondary:hover {
    background: var(--primary-50);
    border-color: var(--primary-light);
    color: var(--primary);
}

/* ===== 页脚 ===== */
footer {
    background: var(--primary-dark);
    color: rgba(255,255,255,0.8);
    padding: 60px 0 20px;
    margin-top: 60px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-5);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-8);
}

.footer-section h3 {
    color: var(--white);
    font-size: var(--text-lg);
    margin-bottom: var(--space-4);
    font-weight: 600;
}

.footer-section a {
    color: rgba(255,255,255,0.7);
    transition: color var(--transition-fast);
}

.footer-section a:hover {
    color: var(--accent);
}

.footer-bottom {
    text-align: center;
    margin-top: var(--space-8);
    padding-top: var(--space-6);
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: var(--text-sm);
    color: rgba(255,255,255,0.5);
}

/* ===== 返回顶部 ===== */

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    font-size: var(--text-xl);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
    box-shadow: var(--shadow-md);
    z-index: var(--z-fixed);
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--accent);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* ===== 手机端悬浮栏 ===== */
.mobile-cta-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    padding: 8px 12px;
    padding-bottom: calc(8px + env(safe-area-inset-bottom));
    z-index: calc(var(--z-fixed) - 2);
    box-shadow: 0 -2px 12px rgba(0,0,0,0.2);
    justify-content: space-around;
    align-items: center;
}

.mobile-cta-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--white);
    font-size: var(--text-xs);
    gap: 2px;
    flex: 1;
    min-height: 44px;
    justify-content: center;
}

.mobile-cta-icon { font-size: 1.2rem; }
.mobile-cta-text { white-space: nowrap; }
.mobile-cta-call { color: #4ade80; }
.mobile-cta-consult { color: #60a5fa; }
.mobile-cta-signup {
    background: var(--accent);
    border-radius: 20px;
    padding: 8px 12px;
    color: var(--white) !important;
    min-height: 44px;
}

/* ===== 动画 ===== */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* ===== 选择与滚动条美化 ===== */
::selection {
    background: var(--accent);
    color: var(--white);
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gray-400);
}

/* ===== 图片优化 ===== */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ===== 表格容器（移动端滚动） ===== */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-responsive .data-table {
    min-width: 600px;
}

/* ===== 响应式断点 ===== */

/* 平板竖屏 */
@media (max-width: 1024px) {
    h1 { font-size: var(--text-3xl); }
    h2 { font-size: var(--text-2xl); }
    
    .page-header {
        padding: 100px 0 50px;
    }
    
    .page-header h1 {
        font-size: var(--text-3xl);
    }
}

/* 手机横屏/小平板 */
@media (max-width: 768px) {
    :root {
        --text-4xl: 1.875rem;
        --text-3xl: 1.5rem;
        --text-2xl: 1.25rem;
    }
    
    .hamburger {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--primary-dark);
        flex-direction: column;
        padding: 80px 30px 30px;
        gap: 0;
        transition: right var(--transition);
        box-shadow: -5px 0 20px rgba(0,0,0,0.2);
        overflow-y: auto;
    }
    
    .nav-links.active {
        right: 0;
    }
    
    .nav-links li {
        width: 100%;
    }
    
    .nav-links a {
        display: block;
        padding: 14px 0;
        font-size: var(--text-base);
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    
    .nav-links a::after {
        display: none;
    }
    
    .page-header {
        padding: 90px 0 40px;
    }
    
    .page-header h1 {
        font-size: var(--text-2xl);
    }
    
    .page-header .subtitle {
        font-size: var(--text-base);
    }
    
    .section-body {
        padding: var(--space-4);
    }
    
    .section-title {
        padding: 14px 20px;
        font-size: var(--text-lg);
    }
    
    .info-card {
        padding: var(--space-4);
    }
    
    .data-table {
        font-size: var(--text-xs);
    }
    
    .data-table thead th,
    .data-table tbody td {
        padding: 10px 8px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }
    
    
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.back-to-top {
        bottom: 80px;
        right: 16px;
        width: 44px;
        height: 44px;
    }
    
    .mobile-cta-bar {
        display: flex;
    }
    
    body {
        padding-bottom: 70px !important;
    }
    
    .container {
        padding: 0 var(--space-4);
    }
    
    .container-narrow {
        padding: 0 var(--space-4);
    }
}

/* 手机竖屏 */
@media (max-width: 480px) {
    :root {
        --text-4xl: 1.5rem;
        --text-3xl: 1.25rem;
        --text-2xl: 1.125rem;
    }
    
    .page-header {
        padding: 80px 0 30px;
    }
    
    .section-body {
        padding: var(--space-3);
    }
    
    .btn {
        padding: 10px 20px;
        font-size: var(--text-sm);
        min-height: 44px;
    }
}

/* 打印样式 */
@media print {
    .nav, .navbar, .mobile-cta-bar, 
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.back-to-top {
        display: none !important;
    }
    
    body {
        padding-bottom: 0 !important;
    }
    
    .page-header {
        padding: 20px 0;
        background: none;
        color: #000;
    }
    
    .section-box, .info-card {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

