/* =========================================================
   四川联一律师事务所 · 官网样式
   设计方向：静谧的高级中性色 + 编辑式宋体标题 + 朱砂红印章点缀
   ========================================================= */

:root {
  --ink: #1e1c19;
  --ink-soft: #3a3733;
  --muted: #6f6a61;
  --paper: #f7f4ed;
  --paper-2: #efeae0;
  --surface: #ffffff;
  --line: #e6e0d4;
  --line-strong: #d8d1c3;

  --cinnabar: #b6491f;
  --cinnabar-deep: #923618;
  --cinnabar-soft: #f2e2d7;
  --cinnabar-wash: #faf3ee;

  --ink-footer: #151311;
  --ink-footer-soft: #2a2724;

  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", serif;
  --sans: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;

  --container: 1200px;
  --gutter: clamp(20px, 4vw, 40px);
  --section-y: clamp(72px, 10vw, 132px);

  --shadow-soft: 0 24px 60px -30px rgba(30, 28, 25, 0.28);
  --shadow-seal: 0 18px 40px -20px rgba(146, 54, 24, 0.55);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1, h2, h3, p, dl, dd {
  margin: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 10px 18px;
  border-radius: 0 0 var(--radius-sm) 0;
  z-index: 100;
}

.skip-link:focus {
  left: 0;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.eyebrow {
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.22em;
  color: var(--cinnabar);
  text-transform: uppercase;
  margin-bottom: 20px;
}

.eyebrow--light {
  color: #e8a98c;
}

h1, h2 {
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.18;
}

.section {
  padding-top: var(--section-y);
  padding-bottom: var(--section-y);
}

.section-head {
  max-width: 760px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-head h2 {
  font-size: clamp(30px, 4.6vw, 46px);
}

.section-sub {
  color: var(--muted);
  font-size: 16px;
  max-width: 620px;
  margin-top: 18px;
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 13px 26px;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
  border: 1px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background: var(--cinnabar);
  color: #fff;
  border-color: var(--cinnabar);
}

.btn-primary:hover {
  background: var(--cinnabar-deep);
  border-color: var(--cinnabar-deep);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}

.btn-ghost:hover {
  border-color: var(--ink);
  background: rgba(30, 28, 25, 0.04);
}

.btn-sm {
  padding: 10px 20px;
  font-size: 14px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
  color: var(--cinnabar);
  border-bottom: 1px solid var(--cinnabar-soft);
  padding-bottom: 4px;
  transition: gap 0.25s ease, border-color 0.25s ease;
}

.text-link:hover {
  gap: 16px;
  border-color: var(--cinnabar);
}

/* =========================================================
   头部导航
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
  box-shadow: 0 12px 32px -24px rgba(30, 28, 25, 0.35);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 76px;
}

.brand img {
  height: 40px;
  width: auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 3vw, 34px);
}

.main-nav a {
  font-size: 15px;
  color: var(--ink-soft);
  position: relative;
  padding: 6px 0;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--cinnabar);
  transition: width 0.28s ease;
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.header-phone {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.2s ease;
}

.header-phone:hover {
  color: var(--cinnabar);
}

.header-phone svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: 0;
  padding: 8px;
  cursor: pointer;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* =========================================================
   Hero
   ========================================================= */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1200px 700px at 82% -10%, rgba(182, 73, 31, 0.08), transparent 60%),
    var(--paper);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(30, 28, 25, 0.055) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,0.8), transparent 78%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
  min-height: min(78vh, 760px);
  padding-top: clamp(56px, 8vw, 96px);
  padding-bottom: clamp(56px, 8vw, 96px);
}

.hero-copy h1 {
  font-size: clamp(44px, 7vw, 84px);
  line-height: 1.04;
  letter-spacing: 0.005em;
}

.hero-copy h1 em {
  font-style: normal;
  color: var(--cinnabar);
}

.hero-sub {
  max-width: 560px;
  color: var(--muted);
  font-size: clamp(15px, 1.6vw, 18px);
  margin: 28px 0 32px;
  font-weight: 300;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 34px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}

.hero-tags li {
  font-size: 13px;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero-tags li::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cinnabar);
}

/* Hero 视觉：印章 */
.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  max-width: 460px;
  width: 100%;
  justify-self: center;
}

.visual-ring {
  position: absolute;
  inset: 6%;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}

.visual-ring::before {
  content: "";
  position: absolute;
  inset: 7%;
  border: 1px dashed var(--line-strong);
  border-radius: 50%;
}

.visual-seal {
  position: relative;
  width: 46%;
  aspect-ratio: 1 / 1;
  background: var(--cinnabar);
  border-radius: 12px;
  box-shadow: var(--shadow-seal);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transform: rotate(-5deg);
}

.visual-seal::after {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 7px;
}

.visual-seal span {
  font-family: var(--serif);
  font-weight: 900;
  color: #fff;
  font-size: clamp(42px, 6vw, 66px);
  line-height: 1;
}

.visual-note {
  position: absolute;
  bottom: 4%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.24em;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

/* =========================================================
   信任数据条
   ========================================================= */
.trust-strip {
  background: var(--ink);
  color: #fff;
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.trust-item {
  padding: clamp(28px, 4vw, 44px) clamp(18px, 3vw, 34px);
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.trust-item:last-child {
  border-right: 0;
}

.trust-item strong {
  display: block;
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(32px, 4.5vw, 48px);
  line-height: 1;
  color: #fff;
}

.trust-item strong .unit {
  color: #e8a98c;
  font-weight: 500;
}

.trust-item span {
  display: block;
  margin-top: 10px;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.66);
  letter-spacing: 0.04em;
}

/* =========================================================
   关于联一
   ========================================================= */
.about {
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 84px);
}

.about-lead {
  font-size: clamp(16px, 1.8vw, 19px);
  line-height: 2;
  color: var(--ink-soft);
  font-weight: 300;
}

.about-lead p + p {
  margin-top: 20px;
}

.about-lead .text-link {
  margin-top: 28px;
}

.about-values {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.value {
  display: grid;
  grid-template-columns: 56px 1fr;
  grid-template-rows: auto auto;
  column-gap: 18px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.value-num {
  grid-row: 1 / 3;
  font-family: var(--serif);
  font-size: 16px;
  color: var(--cinnabar);
  letter-spacing: 0.08em;
}

.value h3 {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 700;
}

.value p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
  margin-top: 6px;
}

/* =========================================================
   业务领域
   ========================================================= */
.practice {
  background: var(--paper);
}

.practice-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.practice-card {
  background: var(--surface);
  padding: 34px 28px 30px;
  min-height: 230px;
  display: flex;
  flex-direction: column;
  transition: background 0.3s ease;
}

.practice-card:hover {
  background: var(--cinnabar-wash);
}

.practice-icon {
  font-size: 26px;
  color: var(--cinnabar);
  line-height: 1;
  margin-bottom: 22px;
}

.practice-card h3 {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.practice-card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.85;
  margin-top: 10px;
}

/* =========================================================
   专业业绩
   ========================================================= */
.matters {
  background: var(--ink);
  color: #fff;
}

.matters .eyebrow {
  color: #e8a98c;
}

.section-head--split {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  max-width: none;
}

.section-head--split .section-sub {
  color: rgba(255, 255, 255, 0.62);
  max-width: 420px;
  text-align: right;
  margin-top: 0;
}

.matters-list {
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.matter {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: clamp(20px, 4vw, 48px);
  padding: clamp(30px, 4vw, 44px) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  align-items: start;
}

.matter-year {
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.12em;
  color: #e8a98c;
  padding-top: 6px;
}

.matter-body h3 {
  font-family: var(--serif);
  font-size: clamp(21px, 2.6vw, 27px);
  font-weight: 700;
}

.matter-body p {
  color: rgba(255, 255, 255, 0.66);
  font-size: 15px;
  line-height: 1.9;
  max-width: 760px;
  margin-top: 12px;
}

/* =========================================================
   服务流程
   ========================================================= */
.process {
  background: var(--paper);
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(20px, 3vw, 32px);
  counter-reset: step;
}

.process-step {
  position: relative;
  padding-top: 26px;
  border-top: 2px solid var(--line-strong);
}

.process-step::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--cinnabar);
}

.step-num {
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.12em;
  color: var(--cinnabar);
}

.process-step h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  margin-top: 16px;
}

.process-step p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.85;
  margin-top: 10px;
}

/* =========================================================
   律师团队
   ========================================================= */
.team {
  background: var(--surface);
  border-top: 1px solid var(--line);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.team-card {
  background: var(--surface);
  padding: 38px 34px 36px;
  transition: background 0.3s ease;
}

.team-card:hover {
  background: var(--cinnabar-wash);
}

.avatar {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 24px;
}

.team-card h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
}

.team-role {
  font-size: 13px;
  color: var(--cinnabar);
  letter-spacing: 0.06em;
  margin-top: 4px;
}

.team-focus {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
  margin-top: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

/* =========================================================
   联系我们
   ========================================================= */
.contact {
  background: var(--paper);
}

.contact-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(36px, 6vw, 72px);
  align-items: center;
  background: var(--cinnabar);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: clamp(38px, 6vw, 72px);
  position: relative;
  overflow: hidden;
}

.contact-inner::after {
  content: "";
  position: absolute;
  right: -90px;
  top: -90px;
  width: 320px;
  height: 320px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
}

.contact-copy h2 {
  font-size: clamp(30px, 4.5vw, 46px);
}

.contact-sub {
  color: rgba(255, 255, 255, 0.86);
  font-size: 16px;
  line-height: 1.9;
  max-width: 520px;
  margin: 20px 0 30px;
  font-weight: 300;
}

.contact .btn-primary {
  background: #fff;
  color: var(--cinnabar-deep);
  border-color: #fff;
}

.contact .btn-primary:hover {
  background: var(--cinnabar-wash);
  border-color: var(--cinnabar-wash);
}

.contact-card {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--radius-md);
  padding: 10px 28px;
  backdrop-filter: blur(4px);
}

.contact-row {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.contact-row:last-child {
  border-bottom: 0;
}

.contact-row dt {
  font-size: 13px;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.68);
  padding-top: 2px;
}

.contact-row dd {
  font-size: 16px;
  font-weight: 400;
}

.contact-row dd a:hover {
  text-decoration: underline;
}

/* =========================================================
   页脚
   ========================================================= */
.site-footer {
  background: var(--ink-footer);
  color: rgba(255, 255, 255, 0.72);
  padding-top: clamp(48px, 7vw, 76px);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: clamp(28px, 5vw, 56px);
  padding-bottom: clamp(40px, 6vw, 56px);
}

.footer-logo {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 700;
  color: #fff;
}

.footer-tag {
  margin-top: 12px;
  font-size: 14px;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.5);
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-nav a {
  font-size: 14px;
  transition: color 0.2s ease;
}

.footer-nav a:hover {
  color: #fff;
}

.footer-contact {
  font-size: 14px;
  line-height: 2;
}

.footer-contact a:hover {
  color: #fff;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 24px;
  padding-bottom: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
}

.footer-note {
  font-size: 12px;
}

/* =========================================================
   滚动显现动画
   ========================================================= */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .btn, .main-nav a, .text-link, .visual-seal {
    transition: none;
  }
}

/* =========================================================
   响应式
   ========================================================= */
@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-visual {
    max-width: 340px;
    order: -1;
  }

  .practice-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 820px) {
  .main-nav {
    position: fixed;
    inset: 76px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    padding: 12px var(--gutter) 20px;
    transform: translateY(-130%);
    transition: transform 0.3s ease;
  }

  .main-nav.open {
    transform: translateY(0);
  }

  .main-nav a {
    padding: 16px 4px;
    border-bottom: 1px solid var(--line);
  }

  .main-nav a::after {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .header-phone span {
    display: none;
  }

  .about-grid,
  .contact-inner {
    grid-template-columns: 1fr;
  }

  .trust-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .trust-item:nth-child(2) {
    border-right: 0;
  }

  .trust-item:nth-child(1),
  .trust-item:nth-child(2) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  }

  .process-grid {
    grid-template-columns: repeat(2, 1fr);
    row-gap: 40px;
  }

  .section-head--split {
    flex-direction: column;
    align-items: flex-start;
  }

  .section-head--split .section-sub {
    text-align: left;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .header-inner {
    height: 68px;
  }

  .main-nav {
    inset: 68px 0 auto 0;
  }

  .brand img {
    height: 32px;
  }

  .header-actions .btn-primary {
    display: none;
  }

  .hero-copy h1 {
    font-size: clamp(40px, 12vw, 56px);
  }

  .hero-visual {
    max-width: 260px;
  }

  .practice-grid,
  .team-grid {
    grid-template-columns: 1fr;
  }

  .matter {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .contact-inner {
    padding: 36px 26px;
  }
}
