/* ============================================================
   Love365 每日主题系统 · Daily Theme System
   基于日期种子，每天轮换 6 套视觉主题 + 布局 + 动效
   ============================================================ */

/* —— 主题容器锚点 —— */
#today-page {
  --theme-bg-start: #2A1240;
  --theme-bg-end: #3E1E5A;
  --theme-accent: #D4AF7A;
  --theme-accent-2: #C77BA8;
  --theme-glow: rgba(212, 175, 122, 0.35);
  --theme-text: #FFFFFF;
  --theme-card: rgba(255, 255, 255, 0.06);
  --theme-card-border: rgba(255, 255, 255, 0.12);
  transition: background 0.8s var(--ease);
}

/* 主题 1 —— 德芙深紫（经典礼盒） */
.theme-dove {
  --theme-bg-start: #2A1240;
  --theme-bg-end: #3E1E5A;
  --theme-accent: #D4AF7A;
  --theme-accent-2: #C77BA8;
  --theme-glow: rgba(212, 175, 122, 0.35);
}

/* 主题 2 —— 鸢尾蓝紫（丝绒夜蓝） */
.theme-iris {
  --theme-bg-start: #141B4D;
  --theme-bg-end: #4A5FCC;
  --theme-accent: #E8C97A;
  --theme-accent-2: #8FA8FF;
  --theme-glow: rgba(143, 168, 255, 0.35);
}

/* 主题 3 —— 玫瑰石英（粉紫缎面） */
.theme-rose {
  --theme-bg-start: #3A1E3E;
  --theme-bg-end: #8A4A76;
  --theme-accent: #F0DFB6;
  --theme-accent-2: #E8A0C0;
  --theme-glow: rgba(232, 160, 192, 0.35);
}

/* 主题 4 —— 午夜梅紫（神秘深邃） */
.theme-plum {
  --theme-bg-start: #1A0B2E;
  --theme-bg-end: #5B3A8A;
  --theme-accent: #D4AF7A;
  --theme-accent-2: #B08CFF;
  --theme-glow: rgba(176, 140, 255, 0.35);
}

/* 主题 5 —— 香槟金暮（暖金晚霞） */
.theme-champagne {
  --theme-bg-start: #2E1A40;
  --theme-bg-end: #7A4A6E;
  --theme-accent: #F5E9D8;
  --theme-accent-2: #E8C97A;
  --theme-glow: rgba(245, 233, 216, 0.4);
}

/* 主题 6 —— 雾紫薰衣草（清新晨雾） */
.theme-lavender {
  --theme-bg-start: #241A3E;
  --theme-bg-end: #6B5B8A;
  --theme-accent: #E8C97A;
  --theme-accent-2: #C9A6E8;
  --theme-glow: rgba(201, 166, 232, 0.35);
}

/* ============ 每日主界面 ============ */
.today-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 120px 20px 80px;
  background: linear-gradient(165deg, var(--theme-bg-start) 0%, var(--theme-bg-end) 100%);
  color: var(--theme-text);
  overflow: hidden;
}

/* —— 背景装饰粒子 —— */
.today-hero__particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.particle {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, var(--theme-glow) 0%, transparent 70%);
  animation: float 8s ease-in-out infinite;
}

/* —— 顶部装饰眉 —— */
.today-hero__eyebrow {
  color: var(--theme-accent);
  letter-spacing: 6px;
  font-size: 11px;
  text-transform: uppercase;
  margin-bottom: 28px;
  animation: fadeUp 0.8s var(--ease);
}

/* —— 金句 —— */
.today-hero__quote {
  font-family: var(--font-serif);
  font-size: var(--fs-lg);
  line-height: 1.6;
  max-width: 760px;
  letter-spacing: 1px;
  font-weight: var(--w-light);
  animation: fadeUp 0.8s var(--ease) 0.2s both;
}
@media (min-width: 768px)  { .today-hero__quote { font-size: var(--fs-2xl); } }
@media (min-width: 1280px) { .today-hero__quote { font-size: 42px; } }

.today-hero__quote .quote-mark {
  color: var(--theme-accent);
  font-size: 1.6em;
  line-height: 0;
  vertical-align: middle;
}
.today-hero__source {
  color: var(--theme-accent-2);
  font-size: var(--fs-sm);
  letter-spacing: 2px;
  margin-top: 20px;
  animation: fadeUp 0.8s var(--ease) 0.3s both;
}

/* —— 日期 —— */
.today-hero__date {
  margin-top: 16px;
  font-size: var(--fs-sm);
  letter-spacing: 3px;
  color: rgba(255, 255, 255, 0.6);
  animation: fadeUp 0.8s var(--ease) 0.35s both;
}

/* —— 分隔 —— */
.today-hero__divider {
  width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--theme-accent), transparent);
  margin: 32px auto;
  animation: fadeIn 1s var(--ease) 0.4s both;
}

/* —— 主题标签 —— */
.today-hero__theme {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 18px;
  border: 1px solid var(--theme-card-border);
  border-radius: var(--radius-full);
  font-size: var(--fs-xs);
  letter-spacing: 2px;
  color: var(--theme-accent);
  background: var(--theme-card);
  margin-bottom: 28px;
  animation: fadeUp 0.8s var(--ease) 0.15s both;
}

/* —— 解读 + 练习卡片 —— */
.today-cards {
  display: grid;
  gap: 20px;
  width: 100%;
  max-width: 860px;
  margin-top: 16px;
  animation: fadeUp 0.8s var(--ease) 0.5s both;
}
@media (min-width: 768px) {
  .today-cards { grid-template-columns: 1fr 1fr; }
}
.today-card {
  background: var(--theme-card);
  border: 1px solid var(--theme-card-border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  text-align: left;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease);
}
.today-card:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.1);
}
.today-card__label {
  font-size: 11px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--theme-accent);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.today-card__label::before {
  content: "";
  width: 18px;
  height: 1px;
  background: var(--theme-accent);
}
.today-card__body {
  color: rgba(255, 255, 255, 0.9);
  font-size: var(--fs-base);
  line-height: 1.9;
  font-weight: var(--w-light);
}

/* —— CTA —— */
.today-hero__cta {
  margin-top: 40px;
  animation: fadeUp 0.8s var(--ease) 0.6s both;
}
.today-hero__cta-note {
  color: rgba(255, 255, 255, 0.55);
  font-size: var(--fs-xs);
  margin-top: 14px;
  letter-spacing: 1px;
}

/* ============ 布局变体 ============ */
/* 布局 A：居中聚焦（默认） */
.layout-centered .today-hero__quote { text-align: center; }

/* 布局 B：左对齐诗篇 */
.layout-left .today-hero { align-items: flex-start; text-align: left; }
.layout-left .today-hero__quote { text-align: left; }
.layout-left .today-hero__divider { margin: 32px 0; }
.layout-left .today-hero__source { text-align: left; }

/* 布局 C：金句放大居中 + 卡片堆叠 */
.layout-stack .today-hero__quote { font-size: calc(var(--fs-2xl) * 1.15); }
.layout-stack .today-cards { grid-template-columns: 1fr; }

/* ============ 动效变体 ============ */
@keyframes fadeUpStrong {
  from { opacity: 0; transform: translateY(40px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.92); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes slideLeft {
  from { opacity: 0; transform: translateX(-30px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* 动效 1：上浮（默认） */
.motion-up .today-hero__quote,
.motion-up .today-card,
.motion-up .today-hero__cta { animation-name: fadeUpStrong; }

/* 动效 2：缩放 */
.motion-scale .today-hero__quote,
.motion-scale .today-card { animation-name: scaleIn; }

/* 动效 3：左滑 */
.motion-slide .today-hero__quote,
.motion-slide .today-card { animation-name: slideLeft; }

/* ============ 日历组件 ============ */
.calendar {
  background: #fff;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  padding: 28px;
  max-width: 720px;
  margin: 0 auto;
}
.calendar__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.calendar__month {
  font-size: var(--fs-md);
  font-weight: var(--w-medium);
  color: var(--deep-plum);
  letter-spacing: 2px;
}
.calendar__nav-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid #E8E0F0;
  color: var(--brand-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--dur) var(--ease);
}
.calendar__nav-btn:hover { background: var(--brand-purple); color: #fff; }
.calendar__weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}
.calendar__weekdays span {
  text-align: center;
  font-size: var(--fs-xs);
  color: var(--text-light);
  padding: 6px 0;
}
.calendar__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.calendar__day {
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-sm);
  color: var(--text);
  cursor: pointer;
  position: relative;
  transition: all 0.2s var(--ease);
}
.calendar__day:hover { background: var(--bg-soft); }
.calendar__day.today {
  background: var(--gradient-brand);
  color: #fff;
  font-weight: var(--w-semibold);
  box-shadow: var(--shadow-glow);
}
.calendar__day.selected {
  background: var(--brand-purple);
  color: #fff;
}
.calendar__day.has-content::after {
  content: "";
  position: absolute;
  bottom: 4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--champagne);
}
.calendar__day.empty { cursor: default; }
.calendar__day.empty:hover { background: transparent; }

/* ============ 每日内容弹层 ============ */
.day-modal {
  position: fixed;
  inset: 0;
  z-index: 2500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--dur) var(--ease);
}
.day-modal.open { opacity: 1; pointer-events: auto; }
.day-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(20, 8, 34, 0.7);
  backdrop-filter: blur(4px);
}
.day-modal__panel {
  position: relative;
  background: #fff;
  border-radius: var(--radius-xl);
  max-width: 560px;
  width: 100%;
  max-height: 82vh;
  overflow-y: auto;
  padding: 36px 28px;
  transform: translateY(20px);
  transition: transform var(--dur) var(--ease);
  box-shadow: var(--shadow-elevated);
}
.day-modal.open .day-modal__panel { transform: translateY(0); }
.day-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-soft);
  color: var(--text-secondary);
  font-size: 20px;
  line-height: 1;
}
.day-modal__date { color: var(--brand-purple); letter-spacing: 2px; font-size: var(--fs-sm); margin-bottom: 8px; }
.day-modal__quote {
  font-family: var(--font-serif);
  font-size: var(--fs-lg);
  color: var(--deep-plum);
  line-height: 1.6;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid #F0EAF6;
}
.day-modal__section { margin-bottom: 20px; }
.day-modal__section h4 {
  font-size: 12px;
  letter-spacing: 3px;
  color: var(--champagne);
  text-transform: uppercase;
  margin-bottom: 10px;
}
.day-modal__section p {
  color: var(--text);
  font-size: var(--fs-sm);
  line-height: 1.8;
}
