/*
 * cuijiamei.com 公开页面（/ 和 /about）的样式。
 * 纯静态、无依赖，颜色沿用前台主题：奶油米白 + 克制粉。
 * 私人页面（React SPA）不用这份文件。
 */

:root {
  --cream: #faf8f5;
  --paper: #fffdfb;
  --ink: #302c2b;
  --ink-soft: #4e4845;
  --muted: #7f7773;
  --blush: #d9868e;
  --blush-deep: #c2707a;
  --blush-soft: #f7e7e8;
  --line: #ede7e1;
  --footer: #9a8f8a;
  --footer-soft: #ab9f9a;

  --font-sans: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB',
    'Microsoft YaHei', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-letter: 'Songti SC', 'STSong', 'SimSun', 'Noto Serif SC', ui-serif, Georgia, serif;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--cream);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E"),
    radial-gradient(120% 80% at 50% -10%, #fdeff2 0%, rgba(250, 248, 245, 0) 58%);
  background-repeat: repeat, no-repeat;
}

a {
  color: inherit;
}

/*
 * 页面骨架：
 * .page 只负责撑满一屏和左右安全边距；
 * .stage 把「正文 + 页脚」当成一个整体，用 margin:auto 垂直居中。
 * 这样在高屏上不会出现「上半部分有内容、下半部分一大片空白」，
 * 在矮屏上内容变高时 margin:auto 自动归零，从顶部正常滚动，不会被裁掉。
 */
.page {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 600px;
  min-height: 100dvh;
  margin: 0 auto;
  padding: max(20px, env(safe-area-inset-top)) 22px max(24px, env(safe-area-inset-bottom));
  overflow: hidden;
}

.stage {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
  margin: auto;
  gap: clamp(30px, 7vh, 68px);
}

/* ---------- 漂浮的小爱心：很轻，只是背景的一点呼吸 ---------- */
.hearts {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.hearts span {
  position: absolute;
  display: block;
  color: var(--blush);
  filter: blur(0.4px);
}

.hearts span svg {
  display: block;
  width: 100%;
  height: 100%;
}

.hearts .h1 {
  top: 12%;
  right: 11%;
  width: 15px;
  height: 15px;
  opacity: 0.15;
}

.hearts .h2 {
  top: 43%;
  left: 2.5%;
  width: 11px;
  height: 11px;
  opacity: 0.11;
}

.hearts .h3 {
  top: 74%;
  right: 15%;
  width: 12px;
  height: 12px;
  opacity: 0.1;
}

/* ---------- 主体 ---------- */
.hero,
.content {
  display: flex;
  flex-direction: column;
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  letter-spacing: 0.26em;
  text-transform: lowercase;
  color: #7a726d;
}

h1 {
  margin: 0;
  font-size: clamp(34px, 10.5vw, 50px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.14;
  color: var(--ink);
}

.lead {
  margin: 20px 0 0;
  font-size: 17px;
  line-height: 1.9;
  color: var(--ink-soft);
}

.lines {
  margin: 20px 0 0;
  font-family: var(--font-letter);
  font-size: 16px;
  line-height: 2.05;
  color: var(--ink-soft);
}

.lines span {
  display: block;
}

/* 「网站还在慢慢长大。」像一句轻轻的补充，和上面拉开一点距离 */
.lines + .lines {
  margin-top: 28px;
}

.actions {
  margin-top: clamp(30px, 5vh, 44px);
}

.enter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 26px;
  border-radius: 999px;
  background: var(--blush);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
  box-shadow: 0 8px 20px -14px rgba(217, 134, 142, 0.55);
  transition: background-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.enter:hover {
  background: var(--blush-deep);
  box-shadow: 0 10px 22px -14px rgba(194, 112, 122, 0.6);
}

.enter:active {
  transform: scale(0.98);
}

.hint {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--muted);
}

/* ---------- 页脚 ---------- */
.site-footer {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
  font-size: 11.5px;
  letter-spacing: 0.1em;
  text-align: center;
  color: var(--footer);
}

.site-footer a {
  text-decoration: none;
  transition: color 0.2s ease;
}

.site-footer a:hover {
  color: var(--blush-deep);
}

.site-footer .made {
  font-family: var(--font-letter);
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--footer-soft);
}

.site-footer .beian {
  margin-top: 8px;
  font-size: 11px;
  letter-spacing: 0.1em;
}

/* ---------- 渐入动画 ---------- */
.rise {
  opacity: 0;
  animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.rise.d1 {
  animation-delay: 0.05s;
}

.rise.d2 {
  animation-delay: 0.15s;
}

.rise.d3 {
  animation-delay: 0.25s;
}

.rise.d4 {
  animation-delay: 0.35s;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- About / 404 ---------- */
.doc {
  display: flex;
  flex-direction: column;
}

.doc h1 {
  font-size: clamp(28px, 8vw, 38px);
}

.doc .lead {
  font-size: 18px;
}

.doc .lines {
  margin-top: 26px;
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 44px;
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.back:hover {
  color: var(--blush-deep);
}

@media (min-width: 768px) {
  .page {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .rise {
    opacity: 1;
  }
}
