/* ==========================================================================
   义乌AI圈 · YIWU AI CIRCLE — design system
   Direction: editorial trade ledger. Paper, ink, vermilion. Rules, seals,
   monospace manifests. Dense but quiet.
   ========================================================================== */

/* ---------- tokens ---------- */
/* 设计方向：SaaS 社区的干净与易读 × 义乌账本的朱印与铺位号。
   暖白底、白卡片、柔和阴影、圆角；朱红只用在关键动作与印章上。 */
:root {
  --paper: #f6f3ec;
  --paper-2: #efe9dd;
  --paper-3: #e4dccb;
  --card: #ffffff;
  --ink: #17150f;
  --ink-90: rgba(23, 21, 15, 0.9);
  --ink-70: rgba(23, 21, 15, 0.72);
  --ink-55: rgba(23, 21, 15, 0.66);
  --ink-40: rgba(23, 21, 15, 0.62);
  --ink-20: rgba(23, 21, 15, 0.16);
  --ink-12: rgba(23, 21, 15, 0.1);
  --ink-06: rgba(23, 21, 15, 0.05);
  --line: rgba(23, 21, 15, 0.08);
  --line-strong: rgba(23, 21, 15, 0.12);
  --red: #bb321a;
  --red-deep: #a02a14;
  --red-soft: rgba(187, 50, 26, 0.08);
  --red-tint: #fbefe9;
  --teal: #14625a;
  --gold: #86651f;
  --ok: #1f7a43;

  --f-sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC",
    "Noto Sans SC", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --f-serif: "Songti SC", "Source Han Serif SC", "Noto Serif SC", "STSong", "Bodoni MT",
    Georgia, "Times New Roman", serif;
  --f-kai: "Kaiti SC", "STKaiti", "KaiTi", "楷体", var(--f-serif);
  --f-mono: "SF Mono", "JetBrains Mono", "IBM Plex Mono", "Consolas", ui-monospace, monospace;

  --wrap: 1240px;
  --gut: 24px;
  --hdr: 68px;
  --r: 16px;
  --r-sm: 8px;
  --r-btn: 10px;
  --shadow-soft: 0 1px 2px rgba(23, 21, 15, 0.04), 0 8px 24px -12px rgba(23, 21, 15, 0.14);
  --shadow-lift: 0 2px 6px rgba(23, 21, 15, 0.05), 0 24px 48px -20px rgba(23, 21, 15, 0.26);
  --shadow-hard: var(--shadow-lift);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.42'/%3E%3C/svg%3E");
  --hatch: repeating-linear-gradient(
    -45deg,
    var(--ink-06) 0 1px,
    transparent 1px 7px
  );
}

/* ---------- reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-sans);
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background-image: var(--grain);
  opacity: 0.05;
  mix-blend-mode: multiply;
}

img { max-width: 100%; display: block; }
svg { display: block; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4, p, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--red); color: var(--paper); }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

/* ---------- layout ---------- */
.wrap {
  width: min(var(--wrap), 100% - var(--gut) * 2);
  margin-inline: auto;
}

.mono {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 400;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- top ticker ---------- */
.ticker {
  background: var(--ink);
  color: var(--paper);
  height: 34px;
  display: flex;
  align-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line-strong);
}

.ticker__track {
  display: flex;
  flex: 0 0 auto;
  gap: 0;
  white-space: nowrap;
  animation: ticker 52s linear infinite;
}

@media (hover: hover) { .ticker:hover .ticker__track { animation-play-state: paused; } }

.ticker__item {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgba(242, 236, 221, 0.78);
}

.ticker__item b { color: var(--paper); font-weight: 600; }
.ticker__item .up { color: #e8836d; }
.ticker__item .dot {
  width: 5px; height: 5px;
  background: var(--red);
  border-radius: 50%;
  flex: 0 0 auto;
}

@keyframes ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- masthead ---------- */
.masthead {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(242, 236, 221, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-strong);
}

.masthead__inner {
  height: var(--hdr);
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex: 0 0 auto;
}

.brand__logo {
  display: block;
  height: 44px;
  width: auto;
  transition: transform 0.35s var(--ease);
}

@media (hover: hover) { .brand:hover .brand__logo { transform: translateY(-1px); } }

.brand__seal {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: var(--red);
  color: var(--paper);
  font-family: var(--f-serif);
  font-size: 23px;
  font-weight: 700;
  line-height: 1;
  border-radius: var(--r-sm);
  position: relative;
  transition: transform 0.35s var(--ease);
}

@media (hover: hover) { .brand:hover .brand__seal { transform: rotate(-6deg); } }

.brand__seal::after {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(242, 236, 221, 0.42);
  pointer-events: none;
}

.brand__text { display: grid; gap: 2px; }

.brand__text strong {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
}

.brand__text em {
  font-family: var(--f-mono);
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.24em;
  color: var(--ink-55);
  line-height: 1;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav::-webkit-scrollbar { display: none; }

.nav a {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  padding: 8px 13px;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  color: var(--ink-70);
  transition: color 0.2s;
}

.nav a i {
  font-family: var(--f-mono);
  font-style: normal;
  font-size: 12px;
  color: var(--ink-40);
  transition: color 0.2s;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 13px; right: 13px; bottom: 2px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.32s var(--ease);
}

@media (hover: hover) { .nav a:hover { color: var(--ink); } }
.nav a.is-active::after { transform: scaleX(1); }
@media (hover: hover) { .nav a:hover::after { transform: scaleX(1); } }
.nav a.is-active { color: var(--ink); font-weight: 600; }
.nav a.is-active i { color: var(--red); }

.head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

/* ---------- buttons ---------- */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
  --btn-bd: var(--ink);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 46px;
  padding: 0 22px;
  border: 1px solid var(--btn-bd);
  background: var(--btn-bg);
  color: var(--btn-fg);
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease),
    background 0.18s, color 0.18s, border-color 0.18s;
}

@media (hover: hover) { .btn:hover { transform: translate(-1px, -1px); box-shadow: var(--shadow-soft); } }
.btn:active { transform: translate(0, 0); box-shadow: none; }

.btn--red { --btn-bg: var(--red); --btn-bd: var(--red); --btn-fg: var(--paper); }
@media (hover: hover) { .btn--red:hover { box-shadow: var(--shadow-soft); } }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-bd: var(--ink);
}
@media (hover: hover) { .btn--ghost:hover { box-shadow: var(--shadow-soft); } }

.btn--paper {
  --btn-bg: var(--card);
  --btn-fg: var(--ink);
  --btn-bd: var(--ink);
}

.btn--sm { height: 36px; padding: 0 15px; font-size: 13px; gap: 7px; }
.btn--lg { height: 54px; padding: 0 30px; font-size: 15px; }
.btn--block { display: flex; width: 100%; }

.btn .arrow {
  font-family: var(--f-mono);
  transition: transform 0.28s var(--ease);
}
@media (hover: hover) { .btn:hover .arrow { transform: translateX(4px); } }

.btn[disabled],
.btn.is-busy {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--line-strong);
  transition: gap 0.25s var(--ease), color 0.2s;
}
@media (hover: hover) { .link-arrow:hover { gap: 13px; color: var(--red); border-color: var(--red); } }

/* ---------- section header ---------- */
.sec { padding: 84px 0; border-top: 1px solid var(--line-strong); position: relative; }
.sec--tight { padding: 56px 0; }
.sec--flush { border-top: 0; }

.sec-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 24px;
  margin-bottom: 44px;
}

.sec-head__idx {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  color: var(--ink-55);
}

.sec-head__idx b {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--red);
}

.sec-head__idx span::before {
  content: "";
  display: inline-block;
  width: 26px;
  height: 1px;
  background: var(--ink-40);
  margin-right: 12px;
  vertical-align: middle;
}

.sec-title {
  font-size: clamp(28px, 3.6vw, 46px);
  line-height: 1.14;
  letter-spacing: -0.02em;
  font-weight: 700;
}

.sec-title em {
  font-style: normal;
  color: var(--red);
  font-weight: 700;
}

.sec-sub {
  color: var(--ink-70);
  max-width: 46em;
  margin-top: 12px;
  font-size: 14.5px;
  text-wrap: pretty;
}

.sec-foot-note {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--ink-40);
  text-transform: uppercase;
}

/* ---------- tags / stamps / chips ---------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 22px;
  padding: 0 8px;
  border: 1px solid var(--ink-20);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-70);
  background: transparent;
  white-space: nowrap;
}

.tag--red { border-color: var(--red); color: var(--red); background: var(--red-soft); }
.tag--ink { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.tag--teal { border-color: var(--teal); color: var(--teal); }

.stamp {
  display: inline-grid;
  place-items: center;
  gap: 0;
  width: 62px;
  height: 62px;
  border: 1.5px solid var(--red);
  border-radius: 50%;
  color: var(--red);
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  line-height: 1.35;
  text-align: center;
  text-transform: uppercase;
  transform: rotate(-11deg);
  opacity: 0.9;
  background: rgba(242, 236, 221, 0.4);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--ink-20);
  border-radius: 999px;
  background: transparent;
  font-size: 13px;
  color: var(--ink-70);
  cursor: pointer;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
  white-space: nowrap;
}

@media (hover: hover) { .chip:hover { border-color: var(--ink); color: var(--ink); } }
.chip.is-on {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
  font-weight: 500;
}

.chip__n {
  font-family: var(--f-mono);
  font-size: 12px;
  opacity: 0.55;
}

/* ---------- cards ---------- */
.card {
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: var(--r);
  position: relative;
}

.card--hover {
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
@media (hover: hover) { .card--hover:hover {
  transform: translate(-3px, -3px);
  box-shadow: var(--shadow-hard);
} }

/* ---------- forms (shared with auth) ---------- */
.field { display: grid; gap: 7px; }

.label {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-55);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.input,
.textarea {
  width: 100%;
  background: transparent;
  border: 1px solid var(--ink-20);
  border-radius: var(--r);
  padding: 12px 13px;
  color: var(--ink);
  font-family: var(--f-sans);
  font-size: 15px;
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}

.input::placeholder,
.textarea::placeholder { color: var(--ink-40); }

@media (hover: hover) { .input:hover,
.textarea:hover { border-color: var(--ink-40); } }

.input:focus,
.textarea:focus {
  outline: none;
  border-color: var(--ink);
  background: var(--card);
  box-shadow: 0 0 0 3px rgba(20, 18, 10, 0.08);
}

.input.has-error,
.textarea.has-error { border-color: var(--red); box-shadow: 0 0 0 3px rgba(196, 53, 28, 0.1); }

.input:disabled { opacity: 0.55; cursor: not-allowed; }

.field-error {
  font-size: 12px;
  line-height: 1.5;
  color: var(--red);
  display: none;
  align-items: flex-start;
  gap: 5px;
}
.field-error.is-on { display: flex; }
.field-error::before {
  content: "!";
  font-family: var(--f-mono);
  font-weight: 700;
  flex: 0 0 auto;
}

.shake { animation: shake 0.4s var(--ease); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  18% { transform: translateX(-6px); }
  38% { transform: translateX(5px); }
  58% { transform: translateX(-3px); }
  78% { transform: translateX(2px); }
}

.checkline {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--ink-70);
  cursor: pointer;
  user-select: none;
}

.checkline input { position: absolute; opacity: 0; width: 1px; height: 1px; }

.checkline__box {
  flex: 0 0 auto;
  width: 16px; height: 16px;
  margin-top: 2px;
  border: 1px solid var(--ink-40);
  border-radius: var(--r-sm);
  background: var(--card);
  display: grid;
  place-items: center;
  transition: background-color 0.18s, border-color 0.18s;
}

.checkline__box::after {
  content: "";
  width: 8px; height: 4px;
  border-left: 1.5px solid var(--paper);
  border-bottom: 1.5px solid var(--paper);
  transform: rotate(-45deg) scale(0);
  transition: transform 0.16s var(--ease);
  margin-top: -2px;
}

.checkline input:checked + .checkline__box { background: var(--ink); border-color: var(--ink); }
.checkline input:checked + .checkline__box::after { transform: rotate(-45deg) scale(1); }
.checkline input:focus-visible + .checkline__box { outline: 2px solid var(--red); outline-offset: 2px; }
.checkline a { border-bottom: 1px solid var(--ink-40); }
@media (hover: hover) { .checkline a:hover { color: var(--red); border-color: var(--red); } }

/* ---------- avatar ---------- */
.avatar {
  flex: 0 0 auto;
  width: 40px; height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--f-serif);
  font-size: 17px;
  line-height: 1;
  border: 1px solid var(--line-strong);
  overflow: hidden;
  user-select: none;
}

.avatar--red { background: var(--red); }
.avatar--teal { background: var(--teal); }
.avatar--gold { background: var(--gold); }
.avatar--sm { width: 30px; height: 30px; font-size: 13px; }
.avatar--lg { width: 50px; height: 50px; font-size: 21px; }

/* ---------- user menu ---------- */
.user-menu { position: relative; }

.user-menu__btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 1px solid transparent;
  padding: 3px 4px 3px 3px;
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
@media (hover: hover) { .user-menu__btn:hover { border-color: var(--ink-20); background: var(--card); } }

.user-menu__name {
  font-size: 13px;
  font-weight: 500;
  max-width: 84px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-menu__panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: 232px;
  background: var(--card);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-soft);
  padding: 6px;
  display: none;
  z-index: 80;
}

.user-menu.is-open .user-menu__panel { display: block; animation: popIn 0.18s var(--ease); }

@keyframes popIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

.user-menu__head {
  padding: 10px 10px 12px;
  border-bottom: 1px dashed var(--ink-20);
  margin-bottom: 5px;
}

.user-menu__head strong { display: block; font-size: 14px; }
.user-menu__head span {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--ink-55);
}

.user-menu__panel a,
.user-menu__panel button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 9px 10px;
  font-size: 13px;
  background: none;
  border: 0;
  text-align: left;
  cursor: pointer;
  color: var(--ink-70);
}
@media (hover: hover) { .user-menu__panel a:hover,
.user-menu__panel button:hover { background: var(--paper-2); color: var(--ink); } }
.user-menu__panel .is-danger { color: var(--red); }

/* ---------- modal ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal.is-open { display: flex; }

.modal__veil {
  position: absolute;
  inset: 0;
  background: rgba(14, 12, 6, 0.55);
  backdrop-filter: blur(3px);
  animation: fadeIn 0.2s ease;
}

.modal__sheet {
  position: relative;
  width: min(440px, 100%);
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overscroll-behavior: contain;
  overflow-y: auto;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-soft);
  padding: 30px;
  animation: sheetIn 0.28s var(--ease);
}

@keyframes fadeIn { from { opacity: 0; } }
@keyframes sheetIn {
  from { opacity: 0; transform: translateY(14px) scale(0.985); }
  to { opacity: 1; transform: none; }
}

.modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 30px; height: 30px;
  display: grid;
  place-items: center;
  background: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--f-mono);
  font-size: 15px;
  color: var(--ink-55);
  border-radius: 50%;
}
@media (hover: hover) { .modal__close:hover { border-color: var(--ink-20); color: var(--ink); background: var(--card); } }

/* ---------- toast ---------- */
.toast-stack {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  z-index: 300;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  pointer-events: none;
  width: max-content;
  max-width: calc(100vw - 32px);
}

.toast {
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--line-strong);
  padding: 10px 18px;
  font-size: 13px;
  line-height: 1.55;
  display: flex;
  align-items: center;
  gap: 9px;
  box-shadow: var(--shadow-soft);
  animation: toastIn 0.26s var(--ease);
  max-width: 100%;
}

.toast::before {
  content: "";
  width: 5px; height: 5px;
  background: var(--red);
  border-radius: 50%;
  flex: 0 0 auto;
}

.toast.is-out { animation: toastOut 0.22s var(--ease) forwards; }

@keyframes toastIn {
  from { opacity: 0; transform: translateY(10px); }
}
@keyframes toastOut {
  to { opacity: 0; transform: translateY(6px); }
}

/* ---------- reveal ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
[data-reveal].is-in { opacity: 1; transform: none; }

.rise {
  opacity: 0;
  animation: rise 0.85s var(--ease) forwards;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

/* ---------- footer ---------- */
.site-foot {
  background: var(--ink);
  color: var(--paper);
  padding: 66px 0 26px;
  position: relative;
  overflow: hidden;
}

.site-foot::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--grain);
  opacity: 0.2;
  pointer-events: none;
}

.foot__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  position: relative;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(242, 236, 221, 0.16);
}

.foot__brand .brand__logo { height: 44px; width: auto; }
.foot__brand .brand__cta { margin-top: 20px; }

.foot__slogan {
  margin-top: 18px;
  font-family: var(--f-serif);
  font-size: 15px;
  letter-spacing: 0.14em;
  color: var(--paper);
}

.foot__tagline {
  margin-top: 8px;
  color: rgba(242, 236, 221, 0.6);
  font-size: 13.5px;
  max-width: 30ch;
  line-height: 1.75;
}

.foot__col h4 {
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(242, 236, 221, 0.62);
  margin-bottom: 16px;
}

.foot__col li { margin-bottom: 9px; }
.foot__col a {
  font-size: 13.5px;
  color: rgba(242, 236, 221, 0.78);
  transition: color 0.2s, padding-left 0.2s;
  display: inline-block;
}
@media (hover: hover) { .foot__col a:hover { color: var(--paper); padding-left: 4px; } }

.foot__bar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding-top: 22px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: rgba(242, 236, 221, 0.62);
  position: relative;
}

.foot__legal {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.foot__legal a { color: rgba(242, 236, 221, 0.62); }
@media (hover: hover) { .foot__legal a:hover { color: var(--paper); } }

.foot__mark {
  font-family: var(--f-serif);
  font-size: clamp(42px, 10vw, 126px);
  line-height: 0.8;
  letter-spacing: -0.03em;
  color: rgba(242, 236, 221, 0.07);
  margin-top: 34px;
  white-space: nowrap;
  overflow: hidden;
  position: relative;
  user-select: none;
}

/* ---------- page head ---------- */
.page-head {
  border-bottom: 1px solid var(--line-strong);
  padding: 46px 0 38px;
  position: relative;
  overflow: hidden;
}

.page-head__bg {
  position: absolute;
  right: -1%;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--f-serif);
  font-size: 300px;
  line-height: 0.8;
  color: var(--ink);
  opacity: 0.04;
  pointer-events: none;
  user-select: none;
}

.page-head__inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
  position: relative;
}

.page-head h1 {
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.025em;
  font-weight: 700;
}

.page-head h1 em {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
}

.page-head__sub {
  color: var(--ink-70);
  margin-top: 10px;
  font-size: 14.5px;
  max-width: 40em;
  text-wrap: pretty;
}

.page-head__stats {
  display: flex;
  gap: 30px;
  flex-wrap: wrap;
}

.pstat { display: grid; gap: 2px; }
.pstat b {
  font-family: var(--f-mono);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.pstat b i { font-style: normal; color: var(--red); }
.pstat span {
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-55);
}

/* ---------- empty state ---------- */
.empty {
  border: 1px dashed var(--ink-20);
  padding: 54px 24px;
  text-align: center;
  color: var(--ink-55);
  background: var(--hatch);
}
.empty strong { display: block; color: var(--ink); font-size: 15px; margin-bottom: 6px; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .sec { padding: 64px 0; }
  .foot__top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  :root { --hdr: 62px; }
  .masthead__inner { gap: 14px; }
  .brand__text em { display: none; }
  .nav { gap: 0; }
  .nav a { padding: 8px 9px; font-size: 13px; }
  .nav a i { display: none; }
  .head-actions .btn { padding: 0 12px; }
  .user-menu__name { display: none; }
  .sec-head { grid-template-columns: 1fr; align-items: start; }
  .sec-head > *:last-child { justify-self: start; }
}

@media (max-width: 560px) {
  .brand__logo { height: 36px; }
  .brand__text strong { font-size: 14px; }
  .brand__seal { width: 33px; height: 33px; font-size: 20px; }
  .page-head { padding: 32px 0 28px; }
  .page-head__stats { gap: 20px; }
  .foot__top { grid-template-columns: 1fr; gap: 30px; }
  .modal__sheet { padding: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal], .rise { opacity: 1; transform: none; }
}
