/* css/style.css */
/* ========== 基础变量与重置 ========== */
:root{
  --bg: #0b1020;              /* 背景（深色） */
  --panel: #0f172a;           /* 面板底色 */
  --card: #111827;            /* 卡片底色 */
  --text: #e5e7eb;            /* 主文本 */
  --muted: #a6adbb;           /* 次级文本 */
  --brand: #60a5fa;           /* 品牌高亮 */
  --brand-2: #34d399;         /* 辅助高亮 */
  --danger: #ef4444;

  --radius: 14px;
  --radius-sm: 4px;
  --shadow: 0 10px 30px rgba(0,0,0,.25);
  --w: 1120px;
  --nav-h: 64px;
  --gap: 20px;
  
  /* 浅色模式变量 */
  --bg-light: #f5f7fa;
  --panel-light: #ffffff;
  --card-light: #f8fafc;
  --text-light: #1f2937;
  --muted-light: #6b7280;
  --brand-light: #3b82f6;
  --brand-2-light: #10b981;
  --danger-light: #ef4444;
}

/* 深浅色模式切换容器样式 */
#dark-mode-container {
  position: relative;
  width: 60px;
  height: 30px;
  display: flex;
  align-items: center;
}

#day, #night {
  width: 60px;
  height: 26px;
  background: white;
  position: absolute;
  z-index: 1;
  cursor: pointer;
  border-radius: 100px;
  background: #9cd6ef;
  border: 6px solid #65c0e7;
}

#night {
  pointer-events: none;
}

#background {
  width: 100%;
  height: 100vh;
  position: absolute;
  background: #d3edf8;
  z-index: -1;
}

#dark-mode-container svg {
  transform: scale(0.4);
  z-index: 2;
  pointer-events: none;
}

@media (max-width: 720px) {
  #day, #night {
    width: 320px;
    height: 150px;
  }
  #dark-mode-container svg {
    transform: scale(0.95);
  }
}

/* 深浅色模式切换动画 */
body.dark #night {
  pointer-events: none;
}

body.light #day {
  pointer-events: none;
}

/* 语言选择器样式 */
.language-selector {
  background: var(--panel);
  color: var(--text);
  border: 1px solid #223359;
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  font-size: 14px;
}

/* 深浅色模式下的语言选择器 */
body:not(.light) .language-selector {
  background: var(--panel);
  color: var(--text);
  border: 1px solid #223359;
}

body.light .language-selector {
  background: var(--panel-light);
  color: var(--text-light);
  border: 1px solid #ccc;
}

/* 深浅色模式切换按钮样式 */
.dark-mode-toggle {
  background: var(--panel);
  border: 1px solid #223359;
  border-radius: 20px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: all 0.3s ease;
}

body.light .dark-mode-toggle {
  background: var(--panel-light);
  border: 1px solid #ccc;
}

.dark-mode-toggle .sun-icon,
.dark-mode-toggle .moon-icon {
  position: absolute;
  transition: opacity 0.3s ease;
}

.dark-mode-toggle .sun-icon {
  opacity: 1;
}

.dark-mode-toggle .moon-icon {
  opacity: 0;
}

body.dark .dark-mode-toggle .sun-icon {
  opacity: 0;
}

body.dark .dark-mode-toggle .moon-icon {
  opacity: 1;
}

/* 深色模式下的一些默认样式 */
body {
  background: radial-gradient(1200px 600px at 10% -10%, #1a2240 0%, transparent 60%) ,
              radial-gradient(900px 400px at 90% -20%, #0e3448 0%, transparent 60%) ,
              var(--bg);
  background-attachment: fixed;
  color: var(--text);
  transition: background 0.3s ease, color 0.3s ease;
}

/* 深浅色模式切换 */
body.light {
  background: radial-gradient(1200px 600px at 10% -10%, #d1e0ef 0%, transparent 60%) ,
              radial-gradient(900px 400px at 90% -20%, #c1d9e9 0%, transparent 60%) ,
              var(--bg-light);
  color: var(--text-light);
  transition: background 0.3s ease, color 0.3s ease;
}

/* 深浅色模式对应的样式 */
body:not(.light) .btn {
  background: linear-gradient(135deg, var(--brand), #7c3aed);
  color: #fff;
  border: none;
}

body.light .btn {
  background: linear-gradient(135deg, var(--brand-light), #7c3aed);
  color: #000;
  border: 1px solid #ccc;
}

body:not(.light) .btn.ghost {
  background: transparent;
  border: 1px solid #32405b;
  color: var(--text);
}

body.light .btn.ghost {
  background: transparent;
  border: 1px solid #ccc;
  color: var(--text-light);
}

body:not(.light) .pill {
  background: #16233f;
  color: #b7c3d7;
  border: 1px solid #223359;
}

body.light .pill {
  background: #e2e8f0;
  color: var(--text-light);
  border: 1px solid #ccc;
}

body:not(.light) .nav-links a {
  color: var(--muted);
}

body.light .nav-links a {
  color: var(--muted-light);
}

body:not(.light) .nav-links a.active, 
body:not(.light) .nav-links a:hover {
  color: #fff;
  background: #1a243a;
}

body.light .nav-links a.active,
body.light .nav-links a:hover {
  color: #000;
  background: #e2e8f0;
}

body:not(.light) .hero-visual {
  background: linear-gradient(180deg, #0f1b34, #0b1326);
  border: 1px solid #1f2d4a;
}

body.light .hero-visual {
  background: linear-gradient(180deg, #e2e8f0, #f1f5f9);
  border: 1px solid #ccc;
}

body:not(.light) .card {
  background: linear-gradient(180deg, #0e162b, #0b1326);
  border: 1px solid #1f2d4a;
  transition: background 0.3s ease, border 0.3s ease;
}

body.light .card {
  background: linear-gradient(180deg, #ffffff, #f8fafc);
  border: 1px solid #ccc;
  transition: background 0.3s ease, border 0.3s ease;
}

body:not(.light) .avatar {
  border: 1px solid #1f2d4a;
  background: #0d1324;
}

body.light .avatar {
  border: 1px solid #ccc;
  background: #f1f5f9;
}

body:not(.light) footer {
  color: #9da7bb;
  border-top: 1px solid #1f2937;
}

body.light footer {
  color: var(--muted-light);
  border-top: 1px solid #ccc;
}

body:not(.light) .site-header {
  background: color-mix(in oklab, var(--panel) 90%, transparent);
  border-bottom: 1px solid #1f2937;
}

body.light .site-header {
  background: color-mix(in oklab, var(--panel-light) 90%, transparent);
  border-bottom: 1px solid #ccc;
}

body:not(.light) .brand {
  color: var(--brand);
}

body.light .brand {
  color: var(--brand-light);
}

body:not(.light) .muted {
  color: var(--muted);
}

body.light .muted {
  color: var(--muted-light);
}

body:not(.light) .menu-btn {
  background: #1a243a;
  border: 1px solid #25324a;
  color: #cdd5e1;
}

body.light .menu-btn {
  background: #e2e8f0;
  border: 1px solid #ccc;
  color: var(--text-light);
}
*{box-sizing:border-box}
html,body{height:100%}
html{scroll-behavior:smooth}
body{
  margin:0;
  padding-top: calc(var(--nav-h) + 1px); 
  font: 16px/1.6 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Inter,
        "PingFang SC","Hiragino Sans GB","Microsoft YaHei","Noto Sans CJK SC",
        "Helvetica Neue",Arial,sans-serif;
  color:var(--text);
  background: radial-gradient(1200px 600px at 10% -10%, #1a2240 0%, transparent 60%) ,
              radial-gradient(900px 400px at 90% -20%, #0e3448 0%, transparent 60%) ,
              var(--bg);
  background-attachment: fixed;
}
img{max-width:100%;height:auto;display:block}

/* ========== 统一圆角渲染（所有用户/项目图片） ========== */
img, .rounded { border-radius: var(--radius-sm); }

/* ========== 布局与容器 ========== */
.container{max-width:var(--w);padding:0 20px;margin:0 auto}
section{padding:72px 0; scroll-margin-top: calc(var(--nav-h) + 12px);}
.muted{color:var(--muted)}
.brand{color:var(--brand)}
.accent{color:var(--brand-2)}
.btn{
  display:inline-flex;align-items:center;gap:.5rem;
  background:linear-gradient(135deg,var(--brand),#7c3aed);
  color:#fff;border:none;border-radius:12px;padding:12px 16px;
  font-weight:600;text-decoration:none;box-shadow:var(--shadow);
  transition:transform .15s ease, filter .2s ease;
}
.btn:hover{transform:translateY(-1px);filter:saturate(1.1)}
.btn.ghost{
  background:transparent;border:1px solid #32405b;color:var(--text);
  box-shadow:none;
}
.pill{
  display:inline-block;padding:4px 10px;border-radius:999px;
  background:#16233f;color:#b7c3d7;font-size:12px;border:1px solid #223359;
}

/* ========== 顶部导航 ========== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 20;
  height: var(--nav-h);
  backdrop-filter: saturate(1.2) blur(10px);
  background: color-mix(in oklab, var(--panel) 90%, transparent);
  border-bottom: 1px solid #1f2937;
}
.nav{
  height:var(--nav-h);display:flex;align-items:center;justify-content:space-between;
  gap:16px;
}
.brandmark{display:flex;align-items:center;gap:10px;text-decoration:none;color:var(--text)}
.brandmark .logo{
  width:28px;height:28px;border-radius:8px;display:grid;place-items:center;
  box-shadow:color-mix(in oklab, var(--panel) 90%, transparent);
  font-weight:900;
  color: #0b1020;
  font-size:14px;
}
.brandmark .title{font-weight:800;letter-spacing:.2px}

/* 深浅色模式下的brandmark */
body:not(.light) .brandmark {
  color: var(--text);
}

body.light .brandmark {
  color: var(--text-light);
}

body:not(.light) .brandmark .logo {
  color: #0b1020;
}

body.light .brandmark .logo {
  color: #f0f0f0;
}
.nav-links{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.nav-links a{
  color:var(--muted);text-decoration:none;padding:8px 10px;border-radius:10px;
  transition:color .2s ease, background .2s ease;
}
.nav-links a.active, .nav-links a:hover{color:#fff;background:#1a243a}
.menu-btn{display:none}

/* ========== 区域（首页） ========== */
.hero{
  display:grid;gap:28px;align-items:center;
  grid-template-columns: 1.25fr 1fr;
}
.hero h1{margin:0 0 10px;font-size:40px;line-height:1.15}
.hero p{margin:0 0 18px;color:#cdd5e1}
.hero .cta{display:flex;gap:12px;flex-wrap:wrap}
.hero-visual{
  padding:16px;background:linear-gradient(180deg,#0f1b34,#0b1326);
  border:1px solid #1f2d4a;border-radius:var(--radius);box-shadow:var(--shadow);
}
.hero-visual img{width:100%;height:auto}

/* ========== 卡片与网格 ========== */
.grid{
  display:grid;gap:18px;
  grid-template-columns: repeat(12, 1fr);
}
.col-12{grid-column: span 12}
.col-6{grid-column: span 12}
.col-12{grid-column: span 12}
.fade-in {
  opacity: 0;
  animation: fadeIn 0.5s ease-in forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
@media (min-width: 640px) {
  .col-6{grid-column: span 6}
  .col-12{grid-column: span 12}
}
@media (min-width: 768px) {
  .col-6{grid-column: span 6}
  .col-12{grid-column: span 12}
}
@media (min-width: 960px) {
  .col-6{grid-column: span 6}
  .col-12{grid-column: span 12}
}
.card{
  background:linear-gradient(180deg,#0e162b,#0b1326);
  border:1px solid #1f2d4a;border-radius:var(--radius);padding:18px;
  box-shadow: var(--shadow);
  transition: background 0.3s ease, border 0.3s ease;
}
.card h3{margin:0 0 6px}
.card .meta{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:8px}

/* ========== 团队头像卡片 ========== */
.member{
  display:flex;gap:14px;align-items:center
}
.avatar{
  width:64px;height:64px;flex:0 0 auto;border-radius:12px;overflow:hidden;
  border:1px solid #1f2d4a;background:#0d1324;
}
.avatar img{width:100%;height:100%;object-fit:cover}

/* ========== 模态框样式 ========== */
.modal {
  display: none; /* 默认隐藏 */
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.8);
}

.modal-content {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  margin-top: 5%;
}

.close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f5f9;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 1001;
  transition: color 0.3s ease;
}

.close:hover,
.close:focus {
  color: #bbb;
}

/* 深浅色模式下的close按钮 */
body.light .close {
  color: #333;
}

body.light .close:hover {
  color: #666;
}

/* ========== 底部与杂项 ========== */
footer{padding:28px 0;color:#9da7bb;border-top:1px solid #1f2937;margin-top:20px}

/* ========== 响应式 ========== */
