/* 字体引入 - 极客风格 */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

/* 全局样式 */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #0a0a0a;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'JetBrains Mono', 'Inter', monospace;
  font-weight: 600;
  letter-spacing: -0.02em;
}

button, input, select, textarea {
  font-family: 'Inter', sans-serif;
}

.terminal-body {
  font-family: 'JetBrains Mono', 'Monaco', 'Menlo', 'Consolas', monospace !important;
  font-size: 13px;
  line-height: 1.6;
  color: #d4d4d4;
  font-weight: 400;
}

.terminal-prompt {
  font-family: 'JetBrains Mono', monospace !important;
  color: #4ec9b0;
  user-select: none;
  font-weight: 500;
}

.terminal-command {
  font-family: 'JetBrains Mono', monospace !important;
  color: #dcdcaa;
  font-weight: 400;
}

.version-select {
  font-family: 'JetBrains Mono', monospace !important;
}

/* 渐变背景 - 极客深色风格 */
.gradient-bg {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  position: relative;
  overflow: hidden;
}

.gradient-bg::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.03) 0px,
      transparent 1px,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 3px
    ),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.03) 0px,
      transparent 1px,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 3px
    );
  pointer-events: none;
}

.gradient-bg::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, transparent 60%);
  animation: gradient-pulse 12s ease-in-out infinite;
  pointer-events: none;
}

@keyframes gradient-pulse {
  0%, 100% {
    transform: translate(0, 0);
    opacity: 0.5;
  }
  50% {
    transform: translate(-25%, -25%);
    opacity: 0.8;
  }
}

/* 卡片悬停效果 */
.card-hover {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.card-hover::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
  transition: left 0.6s ease;
}

.card-hover:hover::before {
  left: 100%;
}

.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.3);
  border-color: rgba(59, 130, 246, 0.3);
}

/* 徽章样式 */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.875rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: none;
  transition: all 0.2s ease;
  font-family: 'JetBrains Mono', monospace;
}

.badge-blue {
  background: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.badge-blue:hover {
  background: rgba(59, 130, 246, 0.25);
  border-color: rgba(59, 130, 246, 0.5);
  transform: translateY(-1px);
}

.badge-green {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-green:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: rgba(16, 185, 129, 0.5);
  transform: translateY(-1px);
}

/* 骨架屏动画 */
.skeleton {
  background: linear-gradient(90deg, #1a1a1a 25%, #2a2a2a 50%, #1a1a1a 75%);
  background-size: 200% 100%;
  animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* 搜索框样式 */
.search-input {
  background: rgba(0, 0, 0, 0.5);
  border: 2px solid rgba(255, 255, 255, 0.1);
  color: #e5e7eb;
  font-size: 0.95rem;
  font-weight: 400;
  transition: all 0.2s ease;
}

.search-input::placeholder {
  color: #6b7280;
}

.search-input:hover {
  border-color: rgba(255, 255, 255, 0.2);
}

.search-input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
  outline: none;
}

/* 终端窗口样式 */
.terminal-window {
  background: linear-gradient(180deg, #1e1e1e 0%, #1a1a1a 100%);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 
    0 0 0 1px rgba(255, 255, 255, 0.05),
    0 10px 40px -10px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.3s ease;
}

.terminal-window:hover {
  box-shadow: 
    0 0 0 1px rgba(59, 130, 246, 0.2),
    0 20px 50px -10px rgba(0, 0, 0, 0.6);
  border-color: rgba(59, 130, 246, 0.3);
}

.terminal-header {
  background: linear-gradient(90deg, #252525 0%, #2a2a2a 100%);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.terminal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  transition: all 0.2s ease;
  opacity: 0.8;
}

.terminal-dot:hover {
  transform: scale(1.15);
  opacity: 1;
}

.dot-red {
  background: #ff5f57;
  box-shadow: 0 0 8px rgba(255, 95, 87, 0.4);
}

.dot-yellow {
  background: #ffbd2e;
  box-shadow: 0 0 8px rgba(255, 189, 46, 0.4);
}

.dot-green {
  background: #28ca42;
  box-shadow: 0 0 8px rgba(40, 202, 66, 0.4);
}

.terminal-body {
  padding: 18px;
  font-family: 'JetBrains Mono', 'Monaco', 'Menlo', monospace;
  font-size: 13px;
  line-height: 1.7;
  color: #d4d4d4;
  background: rgba(0, 0, 0, 0.3);
}

/* 复制按钮样式 */
.copy-button {
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  padding: 4px 10px;
  font-weight: 500;
  letter-spacing: 0.5px;
}

.copy-button:hover {
  background: rgba(59, 130, 246, 0.2);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.copy-button:active {
  transform: translateY(0);
}

.copy-button.copied {
  color: #10b981;
  background: rgba(16, 185, 129, 0.15);
}

/* 版本选择器样式 */
.version-select {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e5e7eb;
  padding: 0.375rem 0.75rem;
  border-radius: 6px;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: all 0.2s ease;
  min-width: 100px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%239ca3af' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 10px center;
  background-repeat: no-repeat;
  background-size: 14px;
  padding-right: 32px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.version-select:hover {
  background: rgba(59, 130, 246, 0.15);
  border-color: rgba(59, 130, 246, 0.4);
}

.version-select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.version-select option {
  background: #1a1a1a;
  color: #e5e7eb;
  padding: 8px 12px;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 500;
}

/* 烟花效果 */
.firework {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  pointer-events: none;
  animation: firework 0.6s ease-out forwards;
}

@keyframes firework {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(0);
    opacity: 0;
  }
}

/* 复制成功提示 */
.copy-feedback {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #10b981;
  font-size: 12px;
  font-weight: 500;
  animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-2px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Docker Logo 样式 */
.docker-logo {
  display: inline-block;
  width: 32px;
  height: 32px;
  transition: all 0.3s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.docker-logo:hover {
  transform: rotate(10deg) scale(1.1);
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

/* GitHub 角标样式 */
.github-corner-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.github-corner-link:hover {
  transform: translateY(-6px) scale(1.05);
  box-shadow: 0 20px 25px -5px rgba(59, 130, 246, 0.5);
}

.github-corner-link::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.github-corner-link:hover::before {
  opacity: 1;
  animation: shimmer 1.5s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% {
    transform: translate(-50%, -50%) scale(0);
  }
  50% {
    transform: translate(-50%, -50%) scale(1);
  }
}

.github-corner-link::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(255, 255, 255, 0.1) 50%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.github-corner-link:hover::after {
  opacity: 1;
}

.github-corner-icon {
  width: 28px;
  height: 28px;
  color: white;
  transition: all 0.3s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.github-corner-link:hover .github-corner-icon {
  transform: rotate(360deg) scale(1.1);
}

/* Footer 样式 */
footer {
  position: relative;
}

footer a {
  position: relative;
  overflow: hidden;
}

footer a::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #3b82f6, #2563eb);
  transition: width 0.3s ease;
}

footer a:hover::before {
  width: 100%;
}