:root {
  --bg: #f5efe2;
  --panel: rgba(255, 255, 255, 0.74);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --text: #1f1a17;
  --muted: #6c6257;
  --accent: #845b36;
  --accent-2: #c89f73;
  --line: rgba(31, 26, 23, 0.1);
  --shadow: 0 24px 60px rgba(26, 18, 12, 0.12);
  --title-font: "Noto Serif SC", "Songti SC", serif;
  --body-font: "Noto Sans SC", "PingFang SC", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.14) 0, rgba(255, 255, 255, 0.14) 1px, transparent 1px, transparent 72px),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.1) 0, rgba(255, 255, 255, 0.1) 1px, transparent 1px, transparent 72px),
    linear-gradient(135deg, var(--bg), color-mix(in srgb, var(--bg) 78%, #ffffff));
  font-family: var(--body-font);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.12) 0, rgba(255, 255, 255, 0.12) 1px, transparent 1px, transparent 6rem),
    linear-gradient(0deg, rgba(255, 255, 255, 0.1) 0, rgba(255, 255, 255, 0.1) 1px, transparent 1px, transparent 6rem);
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.35), transparent 75%);
  opacity: 0.32;
}

a {
  color: inherit;
}

.page {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 36px 0 72px;
  position: relative;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
  font-size: 14px;
}

.topbar a {
  text-decoration: none;
}

.back-link,
.tag {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.45);
  padding: 10px 14px;
  border-radius: 8px;
  backdrop-filter: blur(12px);
}

.hero {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 34px;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.3)),
    linear-gradient(135deg, color-mix(in srgb, var(--accent-2) 20%, transparent), transparent 42%);
  box-shadow: var(--shadow);
}

.eyebrow {
  letter-spacing: 0.18em;
  font-size: 12px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}

.title-row {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: end;
}

.title {
  font-family: var(--title-font);
  font-size: clamp(38px, 7vw, 74px);
  line-height: 0.98;
  margin: 0;
  letter-spacing: 0.03em;
}

.subtitle {
  margin: 12px 0 0;
  max-width: 720px;
  font-size: 16px;
  line-height: 1.8;
  color: color-mix(in srgb, var(--text) 84%, var(--muted));
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.metric {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.54);
}

.metric-label {
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.metric-value {
  font-size: 15px;
  line-height: 1.7;
}

.method {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.method-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.45);
}

.method-card h2 {
  margin: 0 0 10px;
  font-size: 14px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.method-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin: 34px 0 18px;
}

.section-title {
  margin: 0;
  font-size: 26px;
  font-family: var(--title-font);
}

.section-note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 20px;
}

.card {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  animation: rise 0.75s ease both;
}

.card[hidden] {
  display: none;
}

.card:nth-child(2n) {
  animation-delay: 0.08s;
}

.card:nth-child(3n) {
  animation-delay: 0.16s;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 22px 10px;
}

.index-badge {
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--muted);
  text-transform: uppercase;
}

.card-title {
  margin: 8px 0 0;
  font-size: 20px;
  font-family: var(--title-font);
}

.mood {
  align-self: start;
  padding: 8px 10px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--accent) 10%, white);
  color: color-mix(in srgb, var(--accent) 78%, black);
  font-size: 12px;
  white-space: nowrap;
}

.placeholder {
  margin: 0 22px;
  min-height: 210px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  display: flex;
  align-items: end;
  justify-content: flex-start;
  padding: 18px;
  color: rgba(255, 255, 255, 0.95);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.visual {
  margin: 0 22px;
  min-height: 210px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.32);
  background: rgba(255, 255, 255, 0.4);
}

.visual img {
  display: block;
  width: 100%;
  aspect-ratio: 2 / 1;
  object-fit: cover;
}

.card-body {
  padding: 18px 22px 22px;
}

.quote {
  margin: 0;
  font-size: 18px;
  font-family: var(--title-font);
  line-height: 1.7;
}

.note {
  margin: 12px 0 0;
  font-size: 14px;
  line-height: 1.9;
  color: var(--muted);
}


.footer {
  margin-top: 28px;
  padding: 18px 20px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.42);
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.index-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.index-card {
  display: block;
  text-decoration: none;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.toolbar {
  position: sticky;
  top: 12px;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 260px) auto;
  gap: 12px;
  align-items: end;
  margin: 24px 0 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--panel-strong) 84%, white);
  box-shadow: 0 16px 36px rgba(26, 18, 12, 0.08);
  backdrop-filter: blur(14px);
}

.toolbar label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.08em;
}

.toolbar input,
.toolbar select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  letter-spacing: 0;
  padding: 8px 10px;
  outline: none;
}

.toolbar input:focus,
.toolbar select:focus {
  border-color: color-mix(in srgb, var(--accent) 56%, var(--line));
}

.counter {
  display: grid;
  place-items: center;
  min-height: 40px;
  min-width: 86px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  font-size: 14px;
  color: var(--muted);
}

.fulltext {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
}

.fulltext summary {
  cursor: pointer;
  padding: 12px 14px;
  color: color-mix(in srgb, var(--accent) 78%, black);
  font-size: 13px;
}

.fulltext-body {
  max-height: 420px;
  overflow: auto;
  padding: 0 14px 14px;
  border-top: 1px solid var(--line);
}

.fulltext-body p {
  margin: 12px 0 0;
  font-size: 14px;
  line-height: 1.9;
  color: color-mix(in srgb, var(--text) 88%, var(--muted));
}

.index-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--accent) 34%, transparent);
}

.index-swatch {
  height: 140px;
}

.index-copy {
  padding: 18px 20px 22px;
}

.index-copy h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-family: var(--title-font);
}

.index-copy p {
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
}

@media (max-width: 980px) {
  .title-row,
  .method,
  .index-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 24px;
  }

  .title {
    font-size: clamp(34px, 14vw, 56px);
  }
}

@media (max-width: 640px) {
  .page {
    width: min(100% - 24px, 1180px);
    padding-top: 24px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .card-head {
    flex-direction: column;
  }

  .mood {
    width: fit-content;
  }

  .placeholder {
    min-height: 180px;
  }

  .visual {
    min-height: 180px;
  }

  .toolbar {
    position: static;
    grid-template-columns: 1fr;
  }
}
