@charset "UTF-8";

:root {
  --wine: #8b2b32;
  --wine-deep: #641d23;
  --wine-soft: #f0e4e3;
  --ink: #1d1d1b;
  --ink-soft: #343330;
  --muted: #716d66;
  --paper: #f5f2ed;
  --paper-deep: #ebe6df;
  --white: #fffefb;
  --line: #d9d3ca;
  --line-dark: rgba(255, 255, 255, 0.18);
  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", SimSun, serif;
  --sans: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  --shadow: 0 24px 70px rgba(37, 28, 24, 0.13);
  --radius: 2px;
}

* {
  box-sizing: border-box;
}

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

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

body.dialog-open {
  overflow: hidden;
}

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

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

button,
input,
select,
textarea {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--wine);
  outline-offset: 4px;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote {
  margin: 0;
}

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

::selection {
  color: var(--white);
  background: var(--wine);
}

.container {
  width: min(1240px, calc(100% - 96px));
  margin-inline: auto;
}

.logo {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.logo img {
  width: auto;
  height: 40px;
  mix-blend-mode: multiply;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--wine);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.2em;
  line-height: 1.4;
  text-transform: uppercase;
}

.eyebrow::before {
  width: 28px;
  height: 1px;
  background: currentColor;
  content: "";
}

.eyebrow.light {
  color: #d9b9b9;
}

.display-title {
  font-family: var(--serif);
  font-size: clamp(36px, 4vw, 58px);
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.section-title {
  margin-top: 18px;
  font-family: var(--serif);
  font-size: clamp(32px, 3.4vw, 50px);
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.section-lead {
  max-width: 600px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.95;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.75fr);
  gap: 64px;
  align-items: end;
  margin-bottom: 56px;
}

.section-heading .section-lead {
  margin: 0;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--wine);
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.text-link::after {
  content: "→";
  font-size: 18px;
  transition: transform 180ms ease;
}

.text-link:hover::after {
  transform: translateX(4px);
}

.btn {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  line-height: 1;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: var(--white);
  background: var(--wine);
}

.btn-primary:hover {
  background: var(--wine-deep);
}

.btn-outline {
  border-color: var(--line);
  background: transparent;
}

.btn-outline:hover {
  border-color: var(--wine);
  color: var(--wine);
}

.btn-light {
  color: var(--wine-deep);
  background: var(--white);
}

.btn-ghost-light {
  border-color: rgba(255, 255, 255, 0.42);
  color: var(--white);
  background: transparent;
}

.btn svg,
.icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.identity-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  align-items: center;
  color: var(--muted);
  font-size: 14px;
}

.identity-line strong {
  color: var(--ink);
  font-weight: 600;
}

.practice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.practice-card {
  position: relative;
  min-height: 260px;
  padding: 34px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.22);
  transition: background 200ms ease, transform 200ms ease;
}

.practice-card:hover {
  z-index: 1;
  background: var(--white);
  transform: translateY(-3px);
}

.practice-number {
  color: var(--wine);
  font-family: Georgia, serif;
  font-size: 13px;
  font-style: italic;
}

.practice-card h3 {
  margin-top: 38px;
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.45;
}

.practice-en {
  margin-top: 8px;
  color: #979087;
  font-size: 9px;
  letter-spacing: 0.14em;
  line-height: 1.5;
}

.practice-description {
  margin-top: 20px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.9;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-item {
  padding: 32px 40px;
  border-right: 1px solid var(--line);
}

.stat-item:first-child {
  padding-left: 0;
}

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

.stat-value {
  color: var(--wine);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(36px, 4.2vw, 58px);
  line-height: 1.1;
}

.stat-label {
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.08em;
}

.experience-list {
  border-top: 1px solid var(--line);
}

.experience-item {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 36px;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
}

.experience-label {
  padding-top: 5px;
  color: var(--wine);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.12em;
}

.experience-item h3 {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.55;
}

.experience-item p {
  max-width: 690px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.9;
}

.matters-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.matter-card {
  display: flex;
  min-height: 380px;
  flex-direction: column;
  padding: 32px;
  border: 1px solid var(--line);
  background: var(--white);
}

.matter-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.matter-number {
  color: var(--wine);
  font-family: Georgia, serif;
  font-size: 36px;
  font-style: italic;
  line-height: 1;
}

.matter-category,
.case-category {
  color: var(--wine);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.08em;
}

.matter-card h3 {
  margin-top: 34px;
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 600;
  line-height: 1.55;
}

.matter-client {
  margin-top: 16px;
  color: var(--muted);
  font-size: 12px;
}

.matter-result {
  margin-top: auto;
  padding-top: 28px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.9;
}

.cases-list {
  border-top: 1px solid var(--line);
}

.case-item {
  border-bottom: 1px solid var(--line);
}

.case-item summary {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  padding: 30px 0;
  cursor: pointer;
  list-style: none;
}

.case-item summary::-webkit-details-marker {
  display: none;
}

.case-item summary::after {
  display: grid;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  content: "+";
  font-size: 20px;
  font-weight: 300;
  line-height: 1;
  place-items: center;
  transition: transform 180ms ease, color 180ms ease, border-color 180ms ease;
}

.case-item[open] summary::after {
  border-color: var(--wine);
  color: var(--wine);
  content: "−";
  transform: rotate(180deg);
}

.case-number {
  color: var(--wine);
  font-family: Georgia, serif;
  font-size: 15px;
  font-style: italic;
}

.case-summary-title {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  line-height: 1.55;
}

.case-summary-subtitle {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.case-content {
  max-width: 940px;
  padding: 0 0 38px 88px;
}

.case-content p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 14px;
  line-height: 2;
}

.case-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.case-tag {
  padding: 5px 12px;
  color: var(--wine);
  background: var(--wine-soft);
  font-size: 11px;
  letter-spacing: 0.06em;
}

.client-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}

.client-item {
  display: flex;
  gap: 18px;
  align-items: baseline;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.client-item:nth-child(odd) {
  padding-right: 32px;
}

.client-item:nth-child(even) {
  padding-left: 32px;
  border-left: 1px solid var(--line);
}

.client-index {
  flex: 0 0 auto;
  color: var(--wine);
  font-family: Georgia, serif;
  font-size: 12px;
  font-style: italic;
}

.consult-panel {
  position: relative;
  overflow: hidden;
  padding: 72px;
  color: var(--white);
  background: var(--ink);
}

.consult-panel::after {
  position: absolute;
  right: -120px;
  bottom: -240px;
  width: 480px;
  height: 480px;
  border: 1px solid rgba(139, 43, 50, 0.5);
  border-radius: 50%;
  box-shadow: 0 0 0 70px rgba(139, 43, 50, 0.09), 0 0 0 140px rgba(139, 43, 50, 0.06);
  content: "";
  pointer-events: none;
}

.consult-panel > * {
  position: relative;
  z-index: 1;
}

.consult-panel h2 {
  max-width: 760px;
  margin-top: 20px;
  font-family: var(--serif);
  font-size: clamp(34px, 4.4vw, 56px);
  font-weight: 500;
  line-height: 1.4;
}

.consult-panel p {
  max-width: 600px;
  margin-top: 22px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 14px;
}

.consult-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.consult-phone {
  display: inline-block;
  margin-top: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  font-family: Georgia, serif;
  font-size: clamp(25px, 3vw, 36px);
  letter-spacing: 0.05em;
  line-height: 1.5;
}

.legal-note {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.8;
}

.site-footer {
  padding: 30px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
}

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

.footer-inner p {
  max-width: 820px;
}

.version-link {
  flex: 0 0 auto;
  color: var(--wine);
  letter-spacing: 0.08em;
}

.mobile-contact-bar {
  display: none;
}

.consult-dialog {
  width: min(1040px, calc(100% - 40px));
  max-height: min(880px, calc(100dvh - 40px));
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 3px;
  color: var(--ink);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.consult-dialog::backdrop {
  background: rgba(15, 14, 13, 0.72);
  backdrop-filter: blur(5px);
}

.dialog-shell {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  min-height: 620px;
}

.dialog-contact {
  position: relative;
  padding: 46px 40px;
  color: var(--white);
  background: var(--ink);
}

.dialog-contact h2 {
  margin-top: 14px;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 500;
}

.dialog-contact > p {
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
}

.dialog-phone {
  display: block;
  margin-top: 28px;
  font-family: Georgia, serif;
  font-size: 25px;
  letter-spacing: 0.04em;
}

.dialog-phone-label {
  margin-top: 32px;
  color: #d9b9b9;
  font-size: 10px;
  letter-spacing: 0.14em;
}

.wechat-block {
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--line-dark);
}

.wechat-block h3 {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
}

.wechat-block p {
  margin-top: 5px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 11px;
}

.wechat-image {
  width: 152px;
  height: auto;
  aspect-ratio: 1;
  margin-top: 16px;
  object-fit: contain;
  background: white;
}

.dialog-form-wrap {
  padding: 46px 44px 36px;
  overflow-y: auto;
}

.dialog-form-wrap h3 {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 600;
}

.dialog-form-wrap > p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.dialog-close {
  position: absolute;
  z-index: 3;
  top: 14px;
  right: 14px;
  display: grid;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  cursor: pointer;
  color: var(--ink);
  background: var(--paper);
  font-size: 23px;
  font-weight: 300;
  line-height: 1;
  place-items: center;
}

.consult-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 16px;
  margin-top: 28px;
}

.form-field {
  display: grid;
  gap: 7px;
}

.form-field.full,
.form-consent,
.form-submit,
.form-result {
  grid-column: 1 / -1;
}

.form-field label {
  font-size: 12px;
  font-weight: 600;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 0;
  outline: 0;
  background: var(--white);
  font-size: 13px;
  transition: border-color 160ms ease;
}

.form-field textarea {
  min-height: 92px;
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--wine);
}

.form-consent {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}

.form-consent input {
  width: 15px;
  height: 15px;
  margin: 2px 0 0;
  accent-color: var(--wine);
}

.form-submit {
  width: 100%;
}

.form-disclaimer {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 10px;
  text-align: center;
}

.form-result {
  display: none;
  padding: 18px;
  border: 1px solid #bfc9b8;
  background: #f0f4ed;
}

.form-result.visible {
  display: block;
}

.form-result strong {
  display: block;
  font-size: 13px;
}

.form-result p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
}

.form-result pre {
  max-height: 150px;
  margin: 12px 0;
  padding: 12px;
  overflow: auto;
  white-space: pre-wrap;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.72);
  font-family: var(--sans);
  font-size: 11px;
  line-height: 1.7;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.result-actions .btn {
  min-height: 38px;
  padding: 0 15px;
  font-size: 11px;
}

.toast {
  position: fixed;
  z-index: 100;
  bottom: 28px;
  left: 50%;
  max-width: calc(100% - 40px);
  padding: 12px 20px;
  border-radius: 2px;
  color: var(--white);
  background: var(--ink);
  box-shadow: var(--shadow);
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 15px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 900px) {
  .container {
    width: min(100% - 48px, 720px);
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 22px;
    margin-bottom: 38px;
  }

  .section-heading .section-lead {
    margin-top: 0;
  }

  .matters-grid {
    grid-template-columns: 1fr;
  }

  .matter-card {
    min-height: 0;
  }

  .matter-result {
    margin-top: 20px;
  }

  .consult-panel {
    padding: 48px 36px;
  }

  .dialog-shell {
    grid-template-columns: 0.75fr 1.25fr;
  }

  .dialog-contact {
    padding: 40px 28px;
  }

  .dialog-form-wrap {
    padding: 42px 30px 30px;
  }
}

@media (max-width: 680px) {
  html {
    scroll-padding-top: 76px;
  }

  body {
    padding-bottom: 66px;
    font-size: 15px;
  }

  .container {
    width: calc(100% - 40px);
  }

  .logo img {
    height: 30px;
  }

  .section-title {
    font-size: 32px;
  }

  .section-lead {
    font-size: 13px;
  }

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

  .practice-card {
    min-height: 0;
    padding: 26px;
  }

  .practice-card h3 {
    margin-top: 22px;
    font-size: 22px;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .stat-item,
  .stat-item:first-child {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    padding: 22px 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .stat-item:last-child {
    border-bottom: 0;
  }

  .stat-value {
    font-size: 38px;
  }

  .stat-label {
    margin-top: 0;
    text-align: right;
  }

  .experience-item {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 26px 0;
  }

  .experience-item h3 {
    font-size: 20px;
  }

  .case-item summary {
    grid-template-columns: 32px minmax(0, 1fr) auto;
    gap: 10px;
    padding: 24px 0;
  }

  .case-summary-title {
    font-size: 18px;
  }

  .case-summary-subtitle {
    font-size: 11px;
  }

  .case-item summary::after {
    width: 30px;
    height: 30px;
  }

  .case-content {
    padding: 0 0 30px 42px;
  }

  .client-list {
    grid-template-columns: 1fr;
  }

  .client-item:nth-child(odd),
  .client-item:nth-child(even) {
    padding: 18px 0;
    border-left: 0;
  }

  .consult-panel {
    padding: 40px 26px;
  }

  .consult-panel h2 {
    font-size: 32px;
  }

  .consult-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .consult-actions .btn {
    width: 100%;
  }

  .footer-inner {
    display: grid;
    gap: 12px;
  }

  .mobile-contact-bar {
    position: fixed;
    z-index: 40;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    min-height: 64px;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgba(245, 242, 237, 0.96);
    backdrop-filter: blur(14px);
  }

  .mobile-contact-bar .btn {
    min-height: 46px;
  }

  .consult-dialog {
    width: 100%;
    max-width: none;
    max-height: 92dvh;
    margin: auto 0 0;
    border-radius: 8px 8px 0 0;
  }

  .dialog-shell {
    display: block;
    min-height: 0;
  }

  .dialog-contact {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px 20px;
    padding: 28px 24px;
  }

  .dialog-contact .eyebrow,
  .dialog-contact h2,
  .dialog-contact > p,
  .dialog-phone-label,
  .dialog-phone {
    grid-column: 1;
  }

  .dialog-contact h2 {
    font-size: 26px;
  }

  .dialog-contact > p {
    display: none;
  }

  .dialog-phone-label {
    margin-top: 12px;
  }

  .dialog-phone {
    margin-top: 0;
    font-size: 21px;
  }

  .wechat-block {
    grid-row: 1 / 6;
    grid-column: 2;
    margin: 0;
    padding: 0;
    border: 0;
  }

  .wechat-block h3,
  .wechat-block p {
    display: none;
  }

  .wechat-image {
    width: 92px;
    height: auto;
    margin: 0;
  }

  .dialog-form-wrap {
    max-height: calc(92dvh - 190px);
    padding: 28px 24px 30px;
    overflow-y: auto;
  }

  .dialog-form-wrap h3 {
    font-size: 23px;
  }

  .consult-form {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .form-field.full,
  .form-consent,
  .form-submit,
  .form-result,
  .form-disclaimer {
    grid-column: 1;
  }

  .dialog-close {
    top: 10px;
    right: 10px;
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.25);
    background: var(--ink);
  }

  .toast {
    bottom: 82px;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
