/* ============================================
   创意功能样式
   ============================================ */

/* ---- 1. 天气心情卡片 ---- */
.weather-card {
  margin: 0 16px 12px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #74b9ff, #0984e3);
  border-radius: var(--radius-md);
  color: white;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  animation: fadeInUp 0.5s ease;
}

.weather-icon {
  font-size: 36px;
  line-height: 1;
}

.weather-info {
  flex: 1;
}

.weather-temp {
  font-size: 18px;
  font-weight: 700;
}

.weather-mood {
  font-size: 13px;
  opacity: 0.9;
}

.weather-clothes {
  font-size: 11px;
  opacity: 0.8;
}

/* ---- 3. 照片占位框 ---- */
.photo-frame {
  margin: 12px 16px;
  padding: 16px;
  background: #fafafa;
  border: 2px dashed #ddd;
  border-radius: var(--radius-md);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.photo-frame::before {
  content: '📷';
  font-size: 32px;
  display: block;
  margin-bottom: 8px;
}

.photo-frame-text {
  font-size: 13px;
  color: #999;
}

.photo-frame-corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid #ddd;
}

.photo-frame-corner.tl { top: 4px; left: 4px; border-right: none; border-bottom: none; }
.photo-frame-corner.tr { top: 4px; right: 4px; border-left: none; border-bottom: none; }
.photo-frame-corner.bl { bottom: 4px; left: 4px; border-right: none; border-top: none; }
.photo-frame-corner.br { bottom: 4px; right: 4px; border-left: none; border-top: none; }

/* ---- 5. 美食打卡清单 ---- */
.food-checklist {
  margin: 12px 16px;
  padding: 14px 16px;
  background: #fffbf0;
  border-radius: var(--radius-md);
  border-left: 3px solid #f39c12;
}

.food-checklist-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.food-check-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
}

.food-check-item:hover {
  background: rgba(243, 156, 18, 0.1);
  border-radius: 6px;
  padding-left: 8px;
}

.food-check-box {
  width: 18px;
  height: 18px;
  border: 2px solid #ddd;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
  transition: var(--transition);
}

.food-check-item.checked .food-check-box {
  background: #27ae60;
  border-color: #27ae60;
  color: white;
}

.food-check-item.checked .food-check-text {
  text-decoration: line-through;
  color: #999;
}

/* ---- 6. 家庭投票 ---- */
.family-vote {
  margin: 12px 16px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
  border-radius: var(--radius-md);
}

.family-vote-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 10px;
  color: #2e7d32;
}

.vote-options {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.vote-btn {
  padding: 6px 14px;
  border: 2px solid #4caf50;
  background: white;
  border-radius: 20px;
  font-size: 13px;
  cursor: pointer;
  transition: var(--transition);
}

.vote-btn:hover {
  background: #4caf50;
  color: white;
}

.vote-btn.voted {
  background: #4caf50;
  color: white;
}

/* ---- 8. 旅行弹幕 ---- */
.danmu-container {
  position: fixed;
  top: 60px;
  left: 0;
  width: 100%;
  height: 120px;
  pointer-events: none;
  z-index: 50;
  overflow: hidden;
}

.danmu-item {
  position: absolute;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 600;
  color: rgba(102, 126, 234, 0.9);
  text-shadow: 0 0 4px rgba(255,255,255,0.8);
  animation: danmuSlide 8s linear forwards;
  padding: 4px 12px;
  background: rgba(255,255,255,0.7);
  border-radius: 20px;
  backdrop-filter: blur(4px);
}

@keyframes danmuSlide {
  0% { transform: translateX(100vw); }
  100% { transform: translateX(-100%); }
}

.danmu-input-bar {
  margin: 0 16px 16px;
  display: flex;
  gap: 8px;
}

.danmu-input-bar input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid #e0e0e0;
  border-radius: 24px;
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}

.danmu-input-bar input:focus {
  border-color: #667eea;
}

.danmu-input-bar button {
  padding: 10px 20px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.danmu-input-bar button:hover {
  transform: scale(1.05);
}

/* ---- 10. 到达动画 ---- */
.arrival-celebration {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  display: none;
}

.arrival-celebration.active {
  display: block;
}

.confetti {
  position: absolute;
  font-size: 20px;
  animation: confettiFall 3s ease-out forwards;
}

@keyframes confettiFall {
  0% { transform: translateY(-100px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}

.arrival-banner {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translateX(-50%) scale(0);
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  padding: 16px 32px;
  border-radius: var(--radius-lg);
  font-size: 20px;
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  animation: arrivalPop 0.6s ease forwards 0.3s;
}

@keyframes arrivalPop {
  0% { transform: translateX(-50%) scale(0); }
  50% { transform: translateX(-50%) scale(1.1); }
  100% { transform: translateX(-50%) scale(1); }
}

/* ---- 11. 旅行天气预报员 ---- */
.weather-news {
  margin: 0 16px 16px;
  padding: 16px;
  background: linear-gradient(135deg, #2d3436, #636e72);
  border-radius: var(--radius-lg);
  color: white;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.weather-news::before {
  content: '📺';
  position: absolute;
  top: 8px;
  right: 12px;
  font-size: 24px;
  opacity: 0.3;
}

.weather-news-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,0.2);
}

.weather-news-dot {
  width: 8px;
  height: 8px;
  background: #ff4757;
  border-radius: 50%;
  animation: blink 1s ease-in-out infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.weather-news-title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
}

.weather-news-anchor {
  display: flex;
  align-items: center;
  gap: 10px;
}

.weather-news-avatar {
  font-size: 32px;
}

.weather-news-content {
  flex: 1;
}

.weather-news-name {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 2px;
}

.weather-news-role {
  font-size: 11px;
  opacity: 0.7;
}

.weather-news-forecast {
  margin-top: 10px;
  padding: 10px;
  background: rgba(255,255,255,0.1);
  border-radius: var(--radius-sm);
  font-size: 13px;
  line-height: 1.6;
}

/* ---- 14. 旅行契约 ---- */
.travel-contract {
  margin: 0 16px;
  padding: 20px;
  background: linear-gradient(135deg, #fff5f5, #fff0f6);
  border-radius: var(--radius-lg);
  border: 2px solid #ffd6d6;
  position: relative;
}

.travel-contract::before {
  content: '📜';
  position: absolute;
  top: -15px;
  left: 20px;
  font-size: 28px;
  background: white;
  padding: 0 8px;
}

.travel-contract-title {
  font-size: 16px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 16px;
  color: #e85d75;
}

.travel-contract-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  border-bottom: 1px dashed #ffd6d6;
}

.travel-contract-item:last-child {
  border-bottom: none;
}

.travel-contract-check {
  width: 20px;
  height: 20px;
  border: 2px solid #e85d75;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: #e85d75;
  flex-shrink: 0;
}

.travel-contract-item.signed .travel-contract-check {
  background: #e85d75;
  color: white;
}

.travel-contract-signatures {
  display: flex;
  justify-content: space-around;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 2px solid #ffd6d6;
}

.travel-contract-sig {
  text-align: center;
}

.travel-contract-sig-emoji {
  font-size: 24px;
}

.travel-contract-sig-name {
  font-size: 12px;
  color: #666;
  margin-top: 4px;
}

/* ---- 15. 返程礼物清单 ---- */
.gift-list {
  margin: 0 16px;
  padding: 16px;
  background: linear-gradient(135deg, #f0fff4, #e6fffa);
  border-radius: var(--radius-lg);
  border: 2px solid #c6f6d5;
}

.gift-list-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #276749;
}

.gift-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  border-bottom: 1px dashed #c6f6d5;
}

.gift-item:last-child {
  border-bottom: none;
}

.gift-checkbox {
  width: 18px;
  height: 18px;
  border: 2px solid #48bb78;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  cursor: pointer;
  flex-shrink: 0;
  transition: var(--transition);
}

.gift-checkbox.checked {
  background: #48bb78;
  color: white;
}

.gift-for {
  font-size: 12px;
  color: #718096;
  margin-left: auto;
  padding: 2px 8px;
  background: rgba(72, 187, 120, 0.1);
  border-radius: 10px;
}

/* ---- 音乐按钮 ---- */
.music-btn {
  position: fixed;
  bottom: 140px;
  right: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fd79a8, #e84393);
  color: white;
  border: none;
  font-size: 20px;
  cursor: pointer;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  transition: all 0.3s ease;
}

.music-btn:hover {
  transform: scale(1.1);
}

.music-btn.playing {
  animation: musicPulse 1s ease-in-out infinite;
}

@keyframes musicPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* ---- 里程加油站 ---- */
.gas-station {
  margin: 0 16px 16px;
  padding: 16px;
  background: linear-gradient(135deg, #00b894, #00cec9);
  border-radius: var(--radius-lg);
  color: white;
  box-shadow: var(--shadow-sm);
}

.gas-station-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.gas-station-title {
  font-size: 14px;
  font-weight: 600;
}

.gas-station-value {
  font-size: 20px;
  font-weight: 800;
}

.gas-station-bar {
  height: 10px;
  background: rgba(255,255,255,0.3);
  border-radius: 5px;
  overflow: hidden;
}

.gas-station-fill {
  height: 100%;
  background: white;
  border-radius: 5px;
  transition: width 1s ease;
  position: relative;
}

.gas-station-fill::after {
  content: '⛽';
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
}

/* ============================================
   留言板样式
   ============================================ */

/* 触发按钮 */
.message-board-trigger {
  position: fixed;
  right: 16px;
  bottom: 100px;
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
  z-index: 200;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.message-board-trigger:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(102, 126, 234, 0.5);
}

.message-board-trigger span:first-child {
  font-size: 24px;
}

.message-board-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 20px;
  height: 20px;
  background: #e74c3c;
  color: white;
  font-size: 12px;
  font-weight: 700;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  opacity: 0;
  transition: opacity 0.3s;
}

.message-board-badge.show {
  opacity: 1;
}

/* 留言板面板 */
.message-board-panel {
  position: fixed;
  right: 16px;
  bottom: 160px;
  width: 360px;
  max-width: calc(100vw - 32px);
  max-height: 70vh;
  background: white;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
  z-index: 201;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.message-board-panel.active {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* 头部 */
.message-board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #f0f0f0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.message-board-header h3 {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
}

.message-board-header button {
  background: rgba(255,255,255,0.2);
  border: none;
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.message-board-header button:hover {
  background: rgba(255,255,255,0.3);
}

/* 描述 */
.message-board-desc {
  padding: 10px 20px;
  background: #f8f9ff;
  border-bottom: 1px solid #f0f0f0;
}

.message-board-desc small {
  color: #7f8c8d;
  font-size: 12px;
}

/* 统计 */
.message-board-stats {
  display: flex;
  gap: 16px;
  padding: 10px 20px;
  background: #fafafa;
  border-bottom: 1px solid #f0f0f0;
  font-size: 13px;
  color: #666;
}

.message-board-stats b {
  color: #667eea;
}

/* 留言列表 */
.message-board-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px 16px;
  min-height: 200px;
  max-height: 400px;
}

.message-empty {
  text-align: center;
  color: #999;
  padding: 40px 20px;
  font-size: 14px;
}

.message-item {
  padding: 12px 14px;
  margin-bottom: 10px;
  background: #f8f9ff;
  border-radius: 12px;
  border-left: 3px solid #667eea;
  animation: fadeInUp 0.3s ease;
}

.message-item:last-child {
  margin-bottom: 0;
}

.message-content {
  font-size: 14px;
  color: #333;
  line-height: 1.5;
  word-break: break-word;
}

.message-time {
  font-size: 12px;
  color: #999;
  margin-top: 6px;
}

/* 输入区 */
.message-board-input {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid #f0f0f0;
  background: white;
}

.message-board-input input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid #e8e8e8;
  border-radius: 24px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}

.message-board-input input:focus {
  border-color: #667eea;
}

.message-board-input button {
  padding: 10px 20px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.message-board-input button:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.message-board-input button:active {
  transform: scale(0.95);
}

/* 移动端适配 */
@media (max-width: 480px) {
  .message-board-panel {
    right: 8px;
    left: 8px;
    width: auto;
    bottom: 140px;
  }
  
  .message-board-trigger {
    right: 12px;
    bottom: 80px;
    width: 48px;
    height: 48px;
  }
}

/* ============================================
   留言板样式
   ============================================ */

/* 触发按钮 */
.message-board-trigger {
  position: fixed;
  right: 16px;
  bottom: 100px;
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
  z-index: 200;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.message-board-trigger:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 24px rgba(102, 126, 234, 0.5);
}

.message-board-trigger span:first-child {
  font-size: 24px;
}

.message-board-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 20px;
  height: 20px;
  background: #e74c3c;
  color: white;
  font-size: 12px;
  font-weight: 700;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  opacity: 0;
  transition: opacity 0.3s;
}

.message-board-badge.show {
  opacity: 1;
}

/* 留言板面板 */
.message-board-panel {
  position: fixed;
  right: 16px;
  bottom: 160px;
  width: 380px;
  max-width: calc(100vw - 32px);
  max-height: 70vh;
  background: white;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
  z-index: 201;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.message-board-panel.active {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* 头部 */
.message-board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid #f0f0f0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.message-board-header h3 {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
}

.message-board-header button {
  background: rgba(255,255,255,0.2);
  border: none;
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.message-board-header button:hover {
  background: rgba(255,255,255,0.3);
}

/* 描述 */
.message-board-desc {
  padding: 10px 20px;
  background: #f8f9ff;
  border-bottom: 1px solid #f0f0f0;
}

.message-board-desc small {
  color: #7f8c8d;
  font-size: 12px;
}

/* 统计 */
.message-board-stats {
  display: flex;
  gap: 12px;
  padding: 10px 20px;
  background: #fafafa;
  border-bottom: 1px solid #f0f0f0;
  font-size: 12px;
  color: #666;
}

.message-board-stats b {
  color: #667eea;
}

/* 留言列表 */
.message-board-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px 16px;
  min-height: 200px;
  max-height: 400px;
}

.message-empty {
  text-align: center;
  color: #999;
  padding: 40px 20px;
  font-size: 14px;
}

/* 留言项 */
.message-item {
  padding: 12px 14px;
  margin-bottom: 10px;
  background: #f8f9ff;
  border-radius: 12px;
  border-left: 3px solid #667eea;
  animation: fadeInUp 0.3s ease;
}

.message-item:last-child {
  margin-bottom: 0;
}

.message-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.message-nickname {
  font-size: 13px;
  font-weight: 600;
  color: #667eea;
}

.message-time {
  font-size: 11px;
  color: #aaa;
}

.message-content {
  font-size: 14px;
  color: #333;
  line-height: 1.5;
  word-break: break-word;
}

/* 留言操作 */
.message-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.message-actions button {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 13px;
  padding: 4px 8px;
  border-radius: 12px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 4px;
}

.like-btn {
  color: #999;
  background: rgba(0,0,0,0.03);
}

.like-btn:hover {
  background: rgba(231, 76, 60, 0.1);
  color: #e74c3c;
}

.like-btn.liked {
  color: #e74c3c;
  background: rgba(231, 76, 60, 0.1);
}

.delete-btn {
  color: #999;
  background: rgba(0,0,0,0.03);
  margin-left: auto;
}

.delete-btn:hover {
  background: rgba(231, 76, 60, 0.1);
  color: #e74c3c;
}

/* 输入区 */
.message-board-input-area {
  padding: 12px 16px;
  border-top: 1px solid #f0f0f0;
  background: white;
}

.nickname-input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #e8e8e8;
  border-radius: 20px;
  font-size: 13px;
  outline: none;
  margin-bottom: 8px;
  transition: border-color 0.2s;
}

.nickname-input:focus {
  border-color: #667eea;
}

.message-board-input {
  display: flex;
  gap: 8px;
}

.message-board-input input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid #e8e8e8;
  border-radius: 24px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}

.message-board-input input:focus {
  border-color: #667eea;
}

.message-board-input button {
  padding: 10px 20px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.message-board-input button:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.message-board-input button:active {
  transform: scale(0.95);
}

/* 移动端适配 */
@media (max-width: 480px) {
  .message-board-panel {
    right: 8px;
    left: 8px;
    width: auto;
    bottom: 140px;
  }
  
  .message-board-trigger {
    right: 12px;
    bottom: 80px;
    width: 48px;
    height: 48px;
  }
  
  .message-board-stats {
    font-size: 11px;
    gap: 8px;
  }
}
