:root {
  --bg: #faf6f0;
  --bg-subtle: #f3ede4;
  --card: rgba(255, 255, 255, 0.65);
  --card-hover: rgba(255, 255, 255, 0.85);
  --accent: #c4943a;
  --accent-soft: #d4ab5e;
  --text: #3a3228;
  --text-secondary: #8a7e6e;
  --border: #e8dece;
  --glow: rgba(196, 148, 58, 0.08);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a150e;
    --bg-subtle: #221b12;
    --card: #2a2118;
    --card-hover: #342a1e;
    --accent: #d4a84a;
    --accent-soft: #e0be72;
    --text: #f0ebe4;
    --text-secondary: #a89880;
    --border: #3a2e22;
    --glow: rgba(212, 168, 74, 0.08);
  }
}
:root[data-theme="dark"] {
  --bg: #1a150e;
  --bg-subtle: #221b12;
  --card: #2a2118;
  --card-hover: #342a1e;
  --accent: #d4a84a;
  --accent-soft: #e0be72;
  --text: #f0ebe4;
  --text-secondary: #a89880;
  --border: #3a2e22;
  --glow: rgba(212, 168, 74, 0.08);
}
:root[data-theme="light"] {
  --bg: #faf6f0;
  --bg-subtle: #f3ede4;
  --card: rgba(255, 255, 255, 0.65);
  --card-hover: rgba(255, 255, 255, 0.85);
  --accent: #c4943a;
  --accent-soft: #d4ab5e;
  --text: #3a3228;
  --text-secondary: #8a7e6e;
  --border: #e8dece;
  --glow: rgba(196, 148, 58, 0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Cormorant Garamond", "LXGW WenKai", "PingFang SC", serif;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ---- Dust motes (light particles) ---- */
.dust {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* ---- Layout ---- */
.page {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem;
}

/* ---- Header ---- */
.header {
  text-align: center;
  margin-bottom: 2.5rem;
  transition: opacity 0.3s ease;
}

.header-icon {
  font-size: 4rem;
  margin-bottom: 0.4rem;
  display: block;
  opacity: 0.8;
  filter: drop-shadow(0 0 12px rgba(196, 148, 58, 0.3));
}

.header h1 {
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--text);
  margin-bottom: 0.3rem;
}

.header .subtitle {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.5;
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0.03em;
  opacity: 0.82;
}

/* ---- Empty state ---- */
.empty-state {
  text-align: center;
  padding: 4rem 1rem;
  color: var(--text-secondary);
  font-style: italic;
  font-size: 0.92rem;
  line-height: 1.8;
}

/* ---- Timeline ---- */
.timeline {
  position: relative;
  padding-left: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 3px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--accent) 10%, var(--accent) 90%, transparent);
  opacity: 0.3;
}

.timeline-node {
  position: relative;
  margin-bottom: 3rem;
}

.timeline-dot {
  position: absolute;
  left: -2rem;
  top: 0.3rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent), 0 0 20px rgba(196, 148, 58, 0.2);
}

.timeline-date {
  font-size: 0.75rem;
  color: var(--accent-soft);
  letter-spacing: 0.1em;
  margin-bottom: 0.8rem;
  font-family: "SF Mono", "Fira Code", monospace;
}

/* ---- Card ---- */
.ft-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.8rem;
  cursor: pointer;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}

.ft-card:hover {
  background: var(--card-hover);
  border-color: var(--accent);
  box-shadow: 0 0 30px var(--glow);
}

.ft-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.ft-card-title {
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--text);
}

.ft-card-excerpt {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 1.2rem;
  font-style: italic;
}

.ft-card-meta {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.ft-card-mood {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.mood-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.ft-card-read {
  margin-left: auto;
  color: var(--accent-soft);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
}

/* ---- Activities tag ---- */
.ft-card-activities {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.activity-tag {
  font-size: 0.7rem;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  background: var(--glow);
  border: 1px solid var(--border);
  color: var(--accent);
  letter-spacing: 0.03em;
}

/* ---- Detail View ---- */
.ft-detail {
  display: none;
}

.ft-detail.active {
  display: block;
}

.ft-detail.active > * {
  opacity: 0;
  transform: translateY(16px);
  animation: blockReveal 0.5s ease forwards;
}

.ft-detail.active > *:nth-child(1) { animation-delay: 0.05s; }
.ft-detail.active > *:nth-child(2) { animation-delay: 0.15s; }
.ft-detail.active > *:nth-child(3) { animation-delay: 0.25s; }
.ft-detail.active > *:nth-child(4) { animation-delay: 0.35s; }
.ft-detail.active > *:nth-child(5) { animation-delay: 0.45s; }
.ft-detail.active > *:nth-child(6) { animation-delay: 0.55s; }
.ft-detail.active > *:nth-child(7) { animation-delay: 0.65s; }

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

.ft-detail-back {
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  margin-bottom: 2rem;
  display: inline-block;
  transition: color 0.2s;
}

.ft-detail-back:hover {
  color: var(--accent);
}

.ft-detail-header {
  text-align: center;
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.ft-detail-header h2 {
  font-size: 1.3rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  margin-bottom: 0.8rem;
}

.ft-detail-meta {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.ft-section {
  margin-bottom: 2.5rem;
}

.ft-section-label {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 0.8rem;
}

.ft-section-content {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.5rem 1.8rem;
  font-size: 0.92rem;
  line-height: 2;
  color: var(--text);
}

.ft-section-content p {
  margin-bottom: 1rem;
}
.ft-section-content p:last-child {
  margin-bottom: 0;
}

.ft-thinking {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.5rem 1.8rem;
  font-size: 0.88rem;
  line-height: 2;
  color: var(--text-secondary);
}

.ft-thinking p {
  margin-bottom: 1rem;
}
.ft-thinking p:last-child {
  margin-bottom: 0;
}

.ft-excerpt {
  border-left: 2px solid var(--accent);
  padding: 1rem 1.5rem;
  color: var(--text-secondary);
  font-style: italic;
  font-size: 0.88rem;
  line-height: 1.9;
  background: var(--glow);
  border-radius: 0 6px 6px 0;
}

/* ---- Footer ---- */
.footer {
  text-align: center;
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.footer .signature {
  color: var(--accent-soft);
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
}

.footer .tagline {
  font-size: 0.75rem;
  color: var(--text-secondary);
  opacity: 0.6;
  letter-spacing: 0.05em;
}

@media (max-width: 600px) {
  .page { padding: 3rem 1.2rem 4rem; }
  .header h1 { font-size: 1.3rem; }
  .timeline { padding-left: 1.5rem; }
  .timeline-dot { left: -1.5rem; }
}
