/* ========== 全局变量与重置 ========== */
:root {
  /* 明亮模式 */
  --bg-gradient-start: #f8fafc;
  --bg-gradient-end: #eef2ff;
  --card-bg: rgba(255, 255, 255, 0.95);
  --card-border: rgba(255, 255, 255, 0.5);
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --shadow-sm: 0 4px 6px -2px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
  --shadow-md: 0 12px 24px -8px rgba(0, 0, 0, 0.1), 0 4px 8px -4px rgba(0, 0, 0, 0.02);
  --shadow-lg: 0 20px 32px -12px rgba(0, 0, 0, 0.15);
  --shadow-hover: 0 24px 40px -16px rgba(0, 0, 0, 0.2);
  --notice-bg: #fffbeb;
  --notice-border: #fde68a;
  --notice-text: #b45309;
  --btn-primary: #3b82f6;
  --btn-hover: #2563eb;
  --btn-success: #10b981;
  --card-radius: 28px;
  --transition-default: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg-gradient-start: #0f172a;
    --bg-gradient-end: #1e293b;
    --card-bg: rgba(30, 41, 59, 0.92);
    --card-border: rgba(71, 85, 105, 0.5);
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --shadow-sm: 0 4px 6px -2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 12px 24px -8px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 32px -12px rgba(0, 0, 0, 0.5);
    --shadow-hover: 0 28px 44px -16px rgba(0, 0, 0, 0.6);
    --notice-bg: #1e293b;
    --notice-border: #334155;
    --notice-text: #facc15;
    --btn-primary: #4f46e5;
    --btn-hover: #6366f1;
    --btn-success: #059669;
  }
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
  color: var(--text-primary);
  padding: 24px;
}

/* 动态玻璃背景装饰 */
.glass-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.glass-bg::before,
.glass-bg::after {
  content: '';
  position: absolute;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.15), transparent 70%);
  filter: blur(60px);
  animation: float 20s ease-in-out infinite;
}

.glass-bg::before {
  top: -100px;
  left: -100px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.2), transparent 70%);
  animation-delay: -5s;
}

.glass-bg::after {
  bottom: -80px;
  right: -80px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.15), transparent 70%);
  animation-delay: -10s;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(40px, -30px) scale(1.1);
  }
  66% {
    transform: translate(-20px, 40px) scale(0.95);
  }
}

.container {
  max-width: 1100px;
  width: 100%;
  position: relative;
  z-index: 2;
}

/* ========== 通知卡片样式（优雅升级） ========== */
.notice-card {
  background: var(--card-bg);
  backdrop-filter: blur(12px);
  border-radius: 20px;
  padding: 20px 28px;
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow-md);
  transition: var(--transition-default);
}

.notice-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.notice-content {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
}

.notice-icon {
  font-size: 28px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.notice-content p {
  font-size: 1rem;
  font-weight: 500;
  color: var(--notice-text);
  margin: 0;
  line-height: 1.5;
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--btn-primary);
  color: white;
  border: none;
  padding: 12px 28px;
  border-radius: 40px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-default);
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
  backdrop-filter: blur(4px);
  letter-spacing: 0.3px;
}

.copy-btn svg {
  transition: transform 0.2s ease;
}

.copy-btn:hover {
  background: var(--btn-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
}

.copy-btn:hover svg {
  transform: scale(1.05);
}

.copy-btn:active {
  transform: translateY(1px);
}

.copy-btn.copied-feedback {
  background: var(--btn-success);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

/* ========== 网格卡片区域 ========== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  margin-bottom: 48px;
}

.card {
  position: relative;
  background: var(--card-bg);
  backdrop-filter: blur(12px);
  border-radius: var(--card-radius);
  padding: 2rem 1.5rem;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow-md);
  transition: var(--transition-default);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  overflow: hidden;
  isolation: isolate;
}

/* 微光悬停特效 (动态跟随鼠标) */
.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), 
              rgba(255, 255, 255, 0.2) 0%, 
              transparent 70%);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
  z-index: 0;
  border-radius: inherit;
}

@media (prefers-color-scheme: dark) {
  .card::before {
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), 
                rgba(255, 255, 255, 0.08) 0%, 
                transparent 70%);
  }
}

.card:hover::before {
  opacity: 1;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(59, 130, 246, 0.4);
}

.card-icon-wrapper {
  width: 96px;
  height: 96px;
  background: rgba(59, 130, 246, 0.08);
  border-radius: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: var(--transition-default);
  backdrop-filter: blur(4px);
}

.card:hover .card-icon-wrapper {
  transform: scale(1.02);
  background: rgba(59, 130, 246, 0.15);
}

.icon {
  width: 56px;
  height: 56px;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.card:hover .icon {
  transform: scale(1.05);
}

.card-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  letter-spacing: -0.3px;
}

@media (prefers-color-scheme: dark) {
  .card-title {
    background: linear-gradient(135deg, #f0f9ff, #cbd5e6);
    background-clip: text;
    -webkit-background-clip: text;
  }
}

.card-subtitle {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 4px;
  font-weight: 500;
  opacity: 0.8;
}

.card-arrow {
  position: absolute;
  bottom: 24px;
  right: 28px;
  font-size: 1.4rem;
  opacity: 0;
  transform: translateX(-8px);
  transition: var(--transition-default);
  color: var(--btn-primary);
}

.card:hover .card-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* 卡片内优雅分割感 */
.card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  width: 80%;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--btn-primary), transparent);
  border-radius: 4px;
  transform: scaleX(0);
  transition: transform 0.4s ease;
}

.card:hover::after {
  transform: scaleX(1);
}

/* ========== 页脚 ========== */
.footer {
  text-align: center;
  padding: 24px 0 8px;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.footer:hover {
  opacity: 1;
}

/* ========== 响应式设计 ========== */
@media (max-width: 768px) {
  body {
    padding: 16px;
  }
  
  .notice-card {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    padding: 20px;
  }
  
  .notice-content {
    justify-content: center;
  }
  
  .copy-btn {
    justify-content: center;
    width: 100%;
  }
  
  .grid {
    gap: 20px;
    grid-template-columns: 1fr;
  }
  
  .card {
    padding: 1.5rem;
  }
  
  .card-icon-wrapper {
    width: 80px;
    height: 80px;
  }
  
  .icon {
    width: 48px;
    height: 48px;
  }
  
  .card-title {
    font-size: 1.3rem;
  }
  
  .card-arrow {
    bottom: 18px;
    right: 20px;
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .notice-icon {
    font-size: 24px;
  }
  
  .notice-content p {
    font-size: 0.9rem;
  }
  
  .card-icon-wrapper {
    width: 70px;
    height: 70px;
  }
  
  .icon {
    width: 42px;
    height: 42px;
  }
}

/* ========== 加载平滑动画 ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.container {
  animation: fadeInUp 0.6s ease-out;
}

.card {
  animation: fadeInUp 0.5s ease-out backwards;
}

.card:nth-child(1) {
  animation-delay: 0.05s;
}

.card:nth-child(2) {
  animation-delay: 0.15s;
}

.card:nth-child(3) {
  animation-delay: 0.25s;
}

/* 自定义滚动条 (可选) */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.05);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: rgba(59, 130, 246, 0.4);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(59, 130, 246, 0.6);
}

@media (prefers-color-scheme: dark) {
  ::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
  }
  ::-webkit-scrollbar-thumb {
    background: rgba(79, 70, 229, 0.5);
  }
}

/* 打印样式优化 */
@media print {
  .glass-bg,
  .copy-btn,
  .card-arrow,
  .card::before,
  .card::after {
    display: none;
  }
  
  body {
    background: white;
    padding: 0;
  }
  
  .card {
    break-inside: avoid;
    border: 1px solid #ddd;
    box-shadow: none;
  }
}