/* ==========================================================================
   JDX DIGITAL — legal & error pages
   ========================================================================== */

:root {
  --bg: #f6f7fa;
  --ink: #0d1424;
  --ink-soft: #293349;
  --muted: #5f6b7c;
  --muted-2: #8b94a6;
  --line: #e4e7ee;
  --cobalt: #335cff;
  --cobalt-wash: #eef2ff;
  --font-sans: "Inter", "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: "SFMono-Regular", "Cascadia Code", "JetBrains Mono", Consolas, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1000px 650px at 72% -12%, rgba(182, 200, 255, 0.4), transparent 64%),
    radial-gradient(700px 550px at 6% 80%, rgba(255, 255, 255, 0.8), transparent 68%),
    var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

/* 容器宽度统一交由共享样式（styles.css 的 .container / compact-footer.css）控制，
   此处不再覆盖，避免 legal 页与其余页面出现 10px 级宽度差。 */

.legal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
}

.brand-mark {
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 0;
  object-fit: contain;
  filter: drop-shadow(0 5px 10px rgba(30, 42, 78, 0.12));
}

.brand-logo {
  display: block;
  width: auto;
  height: 44px;
  max-width: 100%;
  object-fit: contain;
  filter: none;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.brand-name {
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.2;
}

.brand-sub {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.09em;
  color: var(--muted-2);
  line-height: 1.5;
}

.header-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--muted);
}

.header-back:hover {
  color: var(--cobalt);
}

.legal-main {
  padding: 48px 0 90px;
}

.legal-wrap {
  max-width: 760px;
  margin-inline: auto;
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 30px 80px -54px rgba(20, 35, 80, 0.32), 0 1px 0 rgba(255, 255, 255, 0.85) inset;
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted-2); line-height: 1.5;}

.eyebrow::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cobalt);
}

.legal-wrap h1 {
  margin: 14px 0 0;
  font-size: clamp(34px, 5vw, 48px);
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.legal-updated {
  margin-top: 14px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted-2); line-height: 1.5;}

.legal-wrap h2 {
  margin: 30px 0 8px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.legal-wrap p {
  margin: 8px 0;
  font-size: 13px;
  line-height: 1.95;
  color: var(--muted);
}

.legal-wrap ul {
  margin: 10px 0;
  padding-left: 0;
  list-style: none;
}

.legal-wrap li {
  position: relative;
  padding: 4px 0 4px 18px;
  font-size: 13px;
  line-height: 1.9;
  color: var(--muted);
}

.legal-wrap li::before {
  content: "";
  position: absolute;
  top: 15px;
  left: 2px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cobalt);
  opacity: 0.65;
}

.legal-wrap a {
  color: var(--cobalt);
  border-bottom: 1px solid rgba(51, 92, 255, 0.3);
}

.legal-wrap a:hover {
  border-bottom-color: var(--cobalt);
}

.legal-note {
  margin-top: 28px;
  padding: 16px 18px;
  border: 1px solid #e8ebf2;
  border-radius: 10px;
  background: #fafbfd;
  font-size: 12px;
  color: var(--muted);
}

.legal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0 34px;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted-2);
  flex-wrap: wrap; line-height: 1.5;}

/* 404 */

.notfound-main {
  display: flex;
  align-items: center;
  min-height: calc(100vh - 200px);
  padding: 40px 0 70px;
}

.notfound-inner {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 56px;
  align-items: center;
}

.notfound-copy h1 {
  margin: 18px 0 0;
  font-size: clamp(46px, 6.4vw, 78px);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: 0.035em;
}

.notfound-copy > p {
  max-width: 380px;
  margin-top: 22px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--muted);
}

.notfound-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  transition: background 0.25s ease, transform 0.25s ease;
}

.btn:hover {
  background: var(--cobalt);
  transform: translateY(-1px);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
}

.text-link:hover {
  color: var(--cobalt);
}

.notfound-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 380px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(rgba(51, 92, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(51, 92, 255, 0.055) 1px, transparent 1px),
    linear-gradient(150deg, #f1f5ff, #e9efff 60%, #f7f9ff);
  background-size: 40px 40px, 40px 40px, auto;
  overflow: hidden;
}

.notfound-art::before {
  content: "";
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(51, 92, 255, 0.18), transparent 66%);
  filter: blur(20px);
}

.notfound-code {
  position: relative;
  display: flex;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: clamp(86px, 13vw, 150px);
  font-weight: 500;
  letter-spacing: -0.09em;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(35, 69, 216, 0.42);
}

.notfound-code span:nth-child(2) {
  color: rgba(51, 92, 255, 0.1);
  -webkit-text-stroke-color: rgba(51, 92, 255, 0.55);
}

.notfound-label {
  position: absolute;
  bottom: 24px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.11em;
  color: rgba(51, 92, 255, 0.55); line-height: 1.5;}

@media (max-width: 760px) {
  /* .container 宽度同样交由共享样式控制，移动端不再单独收窄 */

  .legal-main {
    padding: 24px 0 56px;
  }

  .legal-wrap {
    border-radius: 18px;
  }

  .notfound-inner {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .notfound-main {
    padding-top: 20px;
  }

  .notfound-art {
    min-height: 240px;
  }

  .notfound-copy h1 {
    font-size: 48px;
  }

  .legal-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
}
/* 页脚版权横条（privacy / 404 等 legal 页）：左版权、右备案号，与站内 compact-footer 对齐 */
.legal-footer .cf-copy,
.legal-footer .cf-icp {
  white-space: nowrap;
}

.legal-footer .cf-icp {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.legal-footer .cf-icp:hover {
  color: var(--cobalt);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-footer .cf-icp[hidden] {
  display: none;
}

/* ==========================================================================
   统一页头/页脚接入（privacy.html / 404.html）
   legal.css 先于 styles.css / visual.css / compact-footer.css 加载，
   因此 .container、.brand-logo 等通用规则以共享样式为准。
   ========================================================================== */

body.legal-page {
  padding-top: 81px;
}

body.legal-page .legal-main {
  padding: 40px 0 90px;
}

body.legal-page .notfound-main {
  min-height: calc(100vh - 360px);
}

@media (max-width: 1024px) {
  body.legal-page {
    padding-top: 69px;
  }
}
