/* ==========================================================================
   智宇接发 - 全站主样式
   主题色：深红/酒红（参考色调）
   行业：美发接发
   ========================================================================== */

/* ---------- 设计变量 ---------- */
:root {
    --color-primary: #8B0000;          /* 主色 - 深红 */
    --color-primary-dark: #5C0000;     /* 深红-深 */
    --color-primary-light: #B22222;    /* 深红-浅 */
    --color-accent: #C41E3A;           /* 强调色 - 绯红 */
    --color-gold: #C9A66B;             /* 金色点缀 */
    --color-gold-light: #E5C98A;
    --color-cream: #FDF6F1;            /* 米色背景 */
    --color-light: #FFF8F6;            /* 浅背景 */
    --color-pink-soft: #FCE9E7;        /* 软粉背景 */
    --color-text: #2C2C2C;             /* 主文本 */
    --color-text-2: #5A5A5A;           /* 次要文本 */
    --color-text-3: #8A8A8A;           /* 辅助文本 */
    --color-border: #E8D4D2;           /* 边框 */
    --color-white: #FFFFFF;

    --shadow-sm: 0 2px 8px rgba(139, 0, 0, 0.08);
    --shadow-md: 0 8px 24px rgba(139, 0, 0, 0.12);
    --shadow-lg: 0 20px 50px rgba(139, 0, 0, 0.18);

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 24px;
    --radius-pill: 999px;

    --container: 1280px;
    --font-cn: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Source Han Sans SC", system-ui, sans-serif;
    --font-en: "Cormorant Garamond", "Playfair Display", Georgia, serif;
    --font-num: "DIN Alternate", "Bahnschrift", sans-serif;

    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- 重置 ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: var(--font-cn);
    color: var(--color-text);
    background: var(--color-white);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    word-break: break-word;
    word-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: all 0.3s var(--ease); }
a:hover { color: var(--color-primary); }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, h5, h6 { margin: 0; font-weight: 600; line-height: 1.3; }
p { margin: 0 0 1em; }

/* ---------- 中文排版优化 ----------
   正文段落两端对齐 + 严格断行，减少中文单字成行与行首标点 */
p, li, .article-content p, .case-real p { text-align: justify; text-justify: inter-ideograph; }
.section-head p, .hero-sub, .page-banner p { text-align: center; }

/* ---------- 容器 ---------- */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
}

/* ---------- 顶部条 ---------- */
.topbar {
    background: var(--color-primary-dark);
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
    padding: 8px 0;
}
.topbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}
.topbar-info span { margin-right: 20px; }
.topbar-info i { color: var(--color-gold-light); margin-right: 6px; }
.topbar-links a {
    color: rgba(255, 255, 255, 0.85);
    margin-left: 16px;
    font-size: 13px;
}
.topbar-links a:hover { color: var(--color-gold-light); }

/* ---------- 导航栏 ---------- */
.navbar {
    background: var(--color-white);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid var(--color-border);
}
.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 88px;
    gap: 24px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    flex-shrink: 0;
}
.brand-logo {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: var(--color-white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-en);
    font-size: 26px;
    font-style: italic;
    font-weight: 700;
    box-shadow: var(--shadow-sm);
}
.brand-name {
    font-size: 22px;
    font-weight: 700;
    color: var(--color-primary-dark);
    letter-spacing: 1px;
    line-height: 1.2;
}
.brand-sub {
    font-size: 11px;
    letter-spacing: 4px;
    color: var(--color-text-3);
    text-transform: uppercase;
}
.nav-menu {
    display: flex;
    gap: 4px;
    align-items: center;
    flex-wrap: nowrap;
    flex-shrink: 0;
}
.nav-menu > li > a {
    display: block;
    padding: 10px 18px;
    font-size: 15px;
    font-weight: 500;
    color: var(--color-text);
    border-radius: var(--radius-sm);
    position: relative;
    white-space: nowrap;
}
.nav-menu > li > a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 24px;
    height: 2px;
    background: var(--color-primary);
    transition: transform 0.3s var(--ease);
}
.nav-menu > li > a:hover,
.nav-menu > li > a.active {
    color: var(--color-primary);
}
.nav-menu > li > a:hover::after,
.nav-menu > li > a.active::after { transform: translateX(-50%) scaleX(1); }

.nav-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    flex-shrink: 0;
    white-space: nowrap;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: var(--color-white) !important;
    border-radius: var(--radius-pill);
    font-size: 14px;
    font-weight: 500;
    box-shadow: var(--shadow-sm);
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); color: var(--color-white) !important; }
.nav-cta::after { display: none !important; }

.nav-toggle {
    display: none;
    width: 44px; height: 44px;
    border-radius: var(--radius-sm);
    background: var(--color-light);
    align-items: center;
    justify-content: center;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
    content: '';
    width: 22px; height: 2px;
    background: var(--color-primary);
    position: relative;
    transition: all 0.3s var(--ease);
}
.nav-toggle span::before { position: absolute; top: -7px; }
.nav-toggle span::after { position: absolute; top: 7px; }

/* ---------- 通用按钮 ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: var(--radius-pill);
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s var(--ease);
    cursor: pointer;
}
.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: var(--color-white);
    box-shadow: var(--shadow-md);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--color-white);
}
.btn-outline {
    background: var(--color-white);
    color: var(--color-primary);
    border: 1.5px solid var(--color-primary);
}
.btn-outline:hover {
    background: var(--color-primary);
    color: var(--color-white);
}
.btn-ghost {
    background: rgba(255, 255, 255, 0.15);
    color: var(--color-white);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}
.btn-ghost:hover {
    background: var(--color-white);
    color: var(--color-primary);
}

/* ---------- 章节标题 ---------- */
.section { padding: 96px 0; position: relative; }
.section-light { background: var(--color-light); }
.section-cream { background: var(--color-cream); }
.section-dark {
    background: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-primary) 100%);
    color: var(--color-white);
}
.section-head {
    text-align: center;
    margin-bottom: 64px;
}
.section-head .eyebrow {
    display: inline-block;
    font-family: var(--font-en);
    font-style: italic;
    font-size: 16px;
    color: var(--color-gold);
    letter-spacing: 4px;
    margin-bottom: 12px;
    text-transform: uppercase;
}
.section-dark .section-head .eyebrow { color: var(--color-gold-light); }
.section-head h2 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 14px;
    color: inherit;
}
.section-head h2 .accent { color: var(--color-primary); font-style: normal; }
.section-head .lead {
    max-width: 680px;
    margin: 0 auto;
    color: var(--color-text-2);
    font-size: 15px;
}
/* 单行展示的 lead(桌面整行一行,避免末尾单字占行) */
.section-head .lead-oneline { max-width: none; white-space: nowrap; }
.section-head .lead .keep { white-space: nowrap; }
@media (max-width: 768px) {
    .section-head .lead-oneline { white-space: normal; }
}
.section-dark .section-head .lead { color: rgba(255, 255, 255, 0.75); }
.section-head .deco {
    margin: 20px auto 0;
    width: 50px; height: 2px;
    background: var(--color-primary);
}
.section-head.left { text-align: left; }
.section-head.left .deco { margin-left: 0; }

/* ---------- 通用卡片 ---------- */
.card {
    background: var(--color-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.4s var(--ease);
    box-shadow: var(--shadow-sm);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }

/* ---------- 页脚 ---------- */
.footer {
    background: var(--color-primary-dark);
    color: rgba(255, 255, 255, 0.7);
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}
.footer::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background:
        radial-gradient(circle at 10% 20%, rgba(201, 166, 107, 0.06) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(196, 30, 58, 0.1) 0%, transparent 40%);
    pointer-events: none;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.3fr;
    gap: 48px;
    padding-bottom: 56px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
}
.footer-brand .brand-name { color: var(--color-white); }
.footer-brand .brand-sub { color: var(--color-gold-light); }
.footer-brand p {
    margin: 20px 0;
    font-size: 14px;
    line-height: 1.8;
}
.footer h5 {
    color: var(--color-white);
    font-size: 16px;
    margin-bottom: 20px;
    font-weight: 500;
    letter-spacing: 1px;
    position: relative;
    padding-bottom: 12px;
}
.footer h5::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 28px; height: 2px;
    background: var(--color-gold);
}
.footer-links li { margin-bottom: 12px; }
.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.footer-links a::before {
    content: '›';
    color: var(--color-gold);
    opacity: 0.6;
    transition: opacity 0.3s;
}
.footer-links a:hover {
    color: var(--color-gold-light);
    padding-left: 4px;
}
.footer-contact li {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    align-items: flex-start;
}
.footer-contact i {
    color: var(--color-gold);
    width: 16px;
    flex-shrink: 0;
    margin-top: 4px;
}
.footer-bottom {
    padding: 24px 0;
    margin-top: 32px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    position: relative;
}
.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.6);
    margin: 0 12px;
    font-size: 13px;
    white-space: nowrap;
}
.footer-bottom-links a:hover { color: var(--color-gold-light); }
.footer-copyright { width: 100%; text-align: center; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, 0.05); }

/* ---------- 浮动工具栏 ---------- */
.float-tools {
    position: fixed;
    right: 24px;
    bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 99;
}
.float-tools a {
    width: 52px; height: 52px;
    border-radius: 50%;
    background: var(--color-white);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
    font-size: 22px;
    transition: all 0.3s var(--ease);
}
.float-tools a:hover {
    background: var(--color-primary);
    color: var(--color-white);
    transform: translateY(-3px);
}
.float-tools a.privacy {
    font-size: 11px;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
    padding: 4px;
}

/* ---------- 面包屑 ---------- */
.breadcrumb {
    background: var(--color-cream);
    padding: 16px 0;
    font-size: 13px;
    color: var(--color-text-2);
    border-bottom: 1px solid var(--color-border);
}
.breadcrumb .container {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--color-text-3); }
.breadcrumb a:hover { color: var(--color-primary); }
.breadcrumb .sep { color: var(--color-text-3); }
.breadcrumb .current { color: var(--color-primary); font-weight: 500; }

/* ---------- 页面 Banner ---------- */
.page-banner {
    position: relative;
    min-height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    overflow: hidden;
    text-align: center;
}
.page-banner .bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background-size: cover;
    background-position: center;
    z-index: -2;
}
.page-banner .overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background:
        linear-gradient(135deg, rgba(92, 0, 0, 0.85) 0%, rgba(139, 0, 0, 0.7) 50%, rgba(196, 30, 58, 0.6) 100%);
    z-index: -1;
}
.page-banner h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 14px;
    letter-spacing: 2px;
}
.page-banner .en-title {
    font-family: var(--font-en);
    font-style: italic;
    font-size: 22px;
    color: var(--color-gold-light);
    letter-spacing: 6px;
    text-transform: uppercase;
}
.page-banner p {
    margin-top: 16px;
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
    color: rgba(255, 255, 255, 0.85);
}

/* ---------- 工具动画 ---------- */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.in {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- 响应式 ---------- */
/* 中等屏幕:紧凑导航,保证菜单单行 */
@media (max-width: 1280px) {
    .nav-wrap { gap: 14px; }
    .brand { gap: 10px; }
    .brand-logo { width: 44px; height: 44px; font-size: 22px; }
    .brand-name { font-size: 19px; letter-spacing: 0.5px; }
    .brand-sub { font-size: 10px; letter-spacing: 2px; }
    .nav-menu { gap: 2px; }
    .nav-menu > li > a { padding: 10px 12px; font-size: 14px; }
    .nav-cta { padding: 9px 16px; font-size: 13px; }
}
/* 窄屏:切换汉堡菜单,避免导航挤压换行 */
@media (max-width: 1100px) {
    .nav-menu {
        position: fixed;
        top: 88px; left: 0; right: 0;
        background: var(--color-white);
        flex-direction: column;
        flex-wrap: nowrap;
        padding: 16px;
        box-shadow: var(--shadow-md);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s var(--ease);
        align-items: stretch;
        gap: 0;
        border-top: 1px solid var(--color-border);
    }
    .nav-menu.open { max-height: calc(100vh - 88px); overflow-y: auto; }
    .nav-menu > li > a { padding: 14px 16px; border-radius: 0; border-bottom: 1px solid var(--color-border); }
    .nav-toggle { display: flex; }
    .nav-wrap { height: 72px; }
    .nav-menu { top: 72px; }
}
@media (max-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
    .nav-cta { padding: 8px 16px; font-size: 13px; }
}
@media (max-width: 768px) {
    .topbar-info span { display: block; margin-bottom: 4px; line-height: 1.5; }
    .topbar .container { flex-direction: column; align-items: flex-start; gap: 4px; }
    .topbar { padding: 10px 0; }
    .topbar-links { line-height: 1.5; }
    .section { padding: 64px 0; }
    .section-head h2 { font-size: 30px; }
    .page-banner { min-height: 260px; }
    .page-banner h1 { font-size: 32px; }
    .page-banner .en-title { font-size: 16px; letter-spacing: 4px; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; padding-bottom: 36px; }
    .footer-bottom { flex-direction: column; }
    .footer-bottom-links a { margin: 0 8px; }
    .float-tools { right: 12px; bottom: 12px; gap: 8px; }
    .float-tools a { width: 42px; height: 42px; font-size: 17px; opacity: 0.9; }
    .float-tools a.privacy { font-size: 10px; width: 42px; height: 42px; }
}
@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .section-head h2 { font-size: 26px; }
    .btn { padding: 12px 24px; font-size: 14px; }
    .float-tools { right: 12px; bottom: 12px; }
    .float-tools a { width: 46px; height: 46px; font-size: 18px; }
}
