/* ============================================
   搜遇酷图 — 文章详情页静态样式
   用于 /post/{id}.html 静态页面
   ============================================ */

/* ============================================
   1. Page Variables（与 static-common.css 互补）
   ============================================ */
:root {
  --accent: #6D28D9;
  --accent-soft: #8B5CF6;
  --accent-bg: rgba(109, 40, 217, 0.06);
  --r: 16px;
  --r-sm: 10px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04);
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

/* ============================================
   2. Layout
   ============================================ */
.main {
  max-width: 1140px;
  margin: 0 auto;
  padding: 24px 24px 56px;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 36px;
  align-items: start;
}

.content {
  min-width: 0;
}

.side {
  position: sticky;
  top: 80px;
}

@media (max-width: 960px) {
  .main {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .side {
    position: static;
  }
}

/* ============================================
   3. Article Header
   ============================================ */
.art-hd {
  margin-bottom: 32px;
}

.kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
  padding: 3px 10px;
  background: var(--accent-bg);
  border-radius: 4px;
}

.art-hd h1 {
  font-family: var(--font-serif);
  font-size: clamp(22px, 3.5vw, 34px);
  font-weight: 800;
  color: var(--text);
  line-height: 1.3;
  letter-spacing: -0.4px;
  margin-bottom: 16px;
  text-wrap: balance;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-soft);
}

.meta .avt {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  flex-shrink: 0;
}

.meta .aname {
  font-weight: 600;
  color: var(--text);
}

.meta .dsep {
  color: #d4d4d8;
}

.meta .like {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: #e54d4d;
  font-weight: 600;
  margin-left: auto;
}

/* ============================================
   4. Hero Image + Params
   ============================================ */
.hero-wrap {
  margin-bottom: 28px;
  position: relative;
}

.hero-img {
  border-radius: var(--r);
  overflow: hidden;
  background: #f0f0ec;
  position: relative;
}

.hero-img img {
  display: block;
  width: 100%;
  max-height: 680px;
  object-fit: contain;
  border-radius: var(--r);
}

.params-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 18px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0));
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  border-radius: 0 0 var(--r) var(--r);
}

.params-strip .ps-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  font-size: 11.5px;
  font-weight: 500;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.params-strip .ps-badge svg {
  flex-shrink: 0;
}

.ps-prompt-box {
  width: 100%;
  margin-top: 4px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.7;
}

.ps-prompt-box .ps-plab {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  margin-bottom: 3px;
}

/* ============================================
   5. Prev/Next Navigation
   ============================================ */
.pn {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 32px;
}

.pn a {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 16px 18px;
  background: var(--surface);
  border-radius: var(--r-sm);
  border: 1px solid var(--border-soft);
  text-decoration: none;
  transition: all 0.2s;
  min-width: 0;
}

.pn a:hover {
  border-color: var(--accent);
  background: var(--accent-bg);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.pn .pn-l {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.pn .pn-t {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pn .pn-prev {
  text-align: left;
}

.pn .pn-next {
  text-align: right;
}

.pn .pn-off {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 16px 18px;
  background: var(--surface);
  border-radius: var(--r-sm);
  border: 1px solid var(--border-soft);
  opacity: 0.35;
  pointer-events: none;
  min-width: 0;
}

.pn .pn-off .pn-t {
  color: var(--text-muted);
}

@media (max-width: 640px) {
  .pn {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   6. Cards
   ============================================ */
.card {
  background: var(--surface);
  border-radius: var(--r-sm);
  padding: 24px;
  margin-bottom: 16px;
  border: 1px solid var(--border-soft);
  transition: box-shadow 0.25s;
}

.card:hover {
  box-shadow: var(--shadow-sm);
}

.card h2 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-soft);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ============================================
   7. Article Body
   ============================================ */
.art-body {
  font-size: 15.5px;
  color: var(--text-sub);
  line-height: 2;
  word-break: break-word;
  margin-bottom: 32px;
}

.art-body p {
  margin-bottom: 16px;
}

.art-body p:last-child {
  margin-bottom: 0;
}

.art-body p:first-child {
  font-size: 17px;
  color: var(--text);
  line-height: 1.9;
  font-weight: 400;
}

/* ============================================
   8. Prompt Quote
   ============================================ */
.pq {
  position: relative;
  margin-bottom: 32px;
  padding: 20px 24px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--r-sm);
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.9;
}

.pq::before {
  content: "\201C";
  position: absolute;
  top: -4px;
  left: 14px;
  font-family: var(--font-serif);
  font-size: 48px;
  color: var(--accent-bg);
  line-height: 1;
  pointer-events: none;
}

.pq-lab {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 6px;
  font-style: normal;
}

/* ============================================
   9. Tags
   ============================================ */
.tg-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 28px;
}

.tg-col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tg-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.tg-dim {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-right: 2px;
  white-space: nowrap;
}

.tg-pill {
  display: inline-block;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 100px;
  background: var(--accent-bg);
  color: var(--accent);
  text-decoration: none;
  transition: all 0.2s;
  border: 1px solid transparent;
}

.tg-pill:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
}

@media (max-width: 600px) {
  .tg-wrap {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

/* ============================================
   10. Prompt Code Block
   ============================================ */
.pmt {
  background: var(--accent-bg);
  padding: 14px 18px;
  border-radius: var(--r-sm);
  font-size: 13.5px;
  color: var(--text-sub);
  line-height: 1.75;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  word-break: break-all;
}

/* ============================================
   11. Sidebar
   ============================================ */
.sw {
  background: var(--surface);
  border-radius: var(--r-sm);
  padding: 20px;
  margin-bottom: 14px;
  border: 1px solid var(--border-soft);
}

.sw h3 {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-soft);
  display: flex;
  align-items: center;
  gap: 6px;
}

.sw h3 .sw-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.sw-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sw-it a {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-sub);
  padding: 5px 6px;
  border-radius: 6px;
  transition: all 0.2s;
}

.sw-it a:hover {
  background: var(--accent-bg);
  color: var(--accent);
}

.sw-thumb {
  width: 44px;
  height: 44px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  background: #f0f0ec;
}

.sw-info {
  flex: 1;
  min-width: 0;
}

.sw-tt {
  font-size: 12.5px;
  font-weight: 500;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.sw-st {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ============================================
   12. Related Posts
   ============================================ */
.rel-g {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
}

.rel-it {
  background: var(--surface);
  border-radius: var(--r-sm);
  overflow: hidden;
  border: 1px solid var(--border-soft);
  transition: all 0.2s;
}

.rel-it:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent-bg);
}

.rel-it a {
  display: block;
  text-decoration: none;
  color: inherit;
}

.rel-it img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.rel-info {
  padding: 8px 10px;
}

.rel-tt {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-sub);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================
   13. Animations
   ============================================ */
@keyframes fu {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.af {
  animation: fu 0.5s ease both;
}

.ad1 { animation-delay: 0.04s; }
.ad2 { animation-delay: 0.1s; }
.ad3 { animation-delay: 0.16s; }
.ad4 { animation-delay: 0.22s; }
.ad5 { animation-delay: 0.28s; }

@media (prefers-reduced-motion: reduce) {
  .af {
    animation: none;
    opacity: 1;
  }
}

/* ============================================
   14. Responsive
   ============================================ */
@media (max-width: 768px) {
  .main {
    padding: 16px 16px 40px;
  }
  .card {
    padding: 18px 16px;
  }
  .rel-g {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .art-hd h1 {
    font-size: 20px;
  }
  .hero-img {
    border-radius: 10px;
  }
  .hero-img img {
    border-radius: 10px;
  }
  .params-strip {
    padding: 10px 12px;
  }
  .hero-wrap {
    margin-bottom: 20px;
  }
}
