/* 
 * 科技感与机械朋克风格UI样式
 * 烨小白创业圈UI优化项目
 */

/* 全局CSS变量定义 */
:root {
  /* 主色调 */
  --mech-black: #0a0a0a;
  --neon-blue: #00f0ff;
  --neon-pink: #ff00ff;
  --neon-green: #00ff88;
  --warning-orange: #ff8800;
  
  /* 辅助色 */
  --dark-gray: #1a1a1a;
  --medium-gray: #333333;
  --light-gray: #666666;
  --neon-yellow: #ffff00;
  
  /* 阴影效果 */
  --neon-blue-shadow: rgba(0, 240, 255, 0.5);
  --neon-pink-shadow: rgba(255, 0, 255, 0.5);
  --neon-green-shadow: rgba(0, 255, 136, 0.5);
  --warning-orange-shadow: rgba(255, 136, 0, 0.5);
}

/* 故障艺术效果 */
.glitch-effect {
  position: relative;
  display: inline-block;
}

.glitch-effect::before,
.glitch-effect::after {
  content: attr(data-text);
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.glitch-effect::before {
  left: 2px;
  text-shadow: -2px 0 #ff00ff;
  clip: rect(44px, 450px, 56px, 0);
  animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch-effect::after {
  left: -2px;
  text-shadow: -2px 0 #00f0ff;
  clip: rect(44px, 450px, 56px, 0);
  animation: glitch-anim2 5s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
  0% {
    clip: rect(42px, 9999px, 44px, 0);
  }
  5% {
    clip: rect(12px, 9999px, 59px, 0);
  }
  10% {
    clip: rect(48px, 9999px, 29px, 0);
  }
  15% {
    clip: rect(42px, 9999px, 73px, 0);
  }
  20% {
    clip: rect(63px, 9999px, 27px, 0);
  }
  25% {
    clip: rect(34px, 9999px, 55px, 0);
  }
  30% {
    clip: rect(86px, 9999px, 73px, 0);
  }
  35% {
    clip: rect(20px, 9999px, 20px, 0);
  }
  40% {
    clip: rect(26px, 9999px, 60px, 0);
  }
  45% {
    clip: rect(25px, 9999px, 66px, 0);
  }
  50% {
    clip: rect(57px, 9999px, 98px, 0);
  }
  55% {
    clip: rect(5px, 9999px, 46px, 0);
  }
  60% {
    clip: rect(82px, 9999px, 31px, 0);
  }
  65% {
    clip: rect(54px, 9999px, 27px, 0);
  }
  70% {
    clip: rect(28px, 9999px, 99px, 0);
  }
  75% {
    clip: rect(45px, 9999px, 69px, 0);
  }
  80% {
    clip: rect(23px, 9999px, 85px, 0);
  }
  85% {
    clip: rect(1px, 9999px, 83px, 0);
  }
  90% {
    clip: rect(72px, 9999px, 11px, 0);
  }
  95% {
    clip: rect(60px, 9999px, 83px, 0);
  }
  100% {
    clip: rect(93px, 9999px, 98px, 0);
  }
}

@keyframes glitch-anim2 {
  0% {
    clip: rect(65px, 9999px, 100px, 0);
  }
  5% {
    clip: rect(52px, 9999px, 74px, 0);
  }
  10% {
    clip: rect(79px, 9999px, 85px, 0);
  }
  15% {
    clip: rect(75px, 9999px, 5px, 0);
  }
  20% {
    clip: rect(67px, 9999px, 61px, 0);
  }
  25% {
    clip: rect(14px, 9999px, 79px, 0);
  }
  30% {
    clip: rect(1px, 9999px, 66px, 0);
  }
  35% {
    clip: rect(86px, 9999px, 30px, 0);
  }
  40% {
    clip: rect(23px, 9999px, 98px, 0);
  }
  45% {
    clip: rect(85px, 9999px, 72px, 0);
  }
  50% {
    clip: rect(71px, 9999px, 75px, 0);
  }
  55% {
    clip: rect(2px, 9999px, 48px, 0);
  }
  60% {
    clip: rect(30px, 9999px, 16px, 0);
  }
  65% {
    clip: rect(59px, 9999px, 50px, 0);
  }
  70% {
    clip: rect(41px, 9999px, 62px, 0);
  }
  75% {
    clip: rect(2px, 9999px, 82px, 0);
  }
  80% {
    clip: rect(47px, 9999px, 73px, 0);
  }
  85% {
    clip: rect(3px, 9999px, 27px, 0);
  }
  90% {
    clip: rect(26px, 9999px, 55px, 0);
  }
  95% {
    clip: rect(42px, 9999px, 97px, 0);
  }
  100% {
    clip: rect(38px, 9999px, 49px, 0);
  }
}

/* 字体导入 */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;600;700&family=Rajdhani:wght@300;400;500;600;700&family=Roboto+Mono:wght@300;400;500;600&display=swap');

/* 全局样式重置与基础设置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Roboto Mono', monospace;
  background: var(--mech-black);
  color: #e0e0e0;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* 背景效果 */
.tech-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 50%, rgba(0, 240, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 0, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(0, 255, 136, 0.1) 0%, transparent 50%);
  z-index: -1;
}

.grid-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(0, 240, 255, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.1) 1px, transparent 1px);
  background-size: 50px 50px;
  z-index: -2;
}

.scan-lines {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.15),
    rgba(0, 0, 0, 0.15) 1px,
    transparent 1px,
    transparent 2px
  );
  z-index: 999;
  pointer-events: none;
  animation: scan 10s linear infinite;
}

@keyframes scan {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 0 100%;
  }
}

/* 标题字体 */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--neon-blue);
  text-shadow: 0 0 10px var(--neon-blue-shadow);
}

/* 段落文本 */
p {
  font-family: 'Rajdhani', sans-serif;
  margin-bottom: 1rem;
  line-height: 1.6;
}

/* 霓虹发光效果 */
.neon-text {
  color: var(--neon-blue);
  text-shadow: 0 0 10px var(--neon-blue-shadow);
}

.neon-text-pink {
  color: var(--neon-pink);
  text-shadow: 0 0 10px var(--neon-pink-shadow);
}

.neon-text-green {
  color: var(--neon-green);
  text-shadow: 0 0 10px var(--neon-green-shadow);
}

.neon-text-orange {
  color: var(--warning-orange);
  text-shadow: 0 0 10px var(--warning-orange-shadow);
}

/* 科技感按钮组件 */
.tech-button {
  position: relative;
  padding: 12px 24px;
  font-size: 1rem;
  font-weight: 600;
  font-family: 'Orbitron', sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  overflow: hidden;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
}

.tech-button::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: all 0.5s ease;
}

.tech-button:hover::before {
  left: 100%;
}

/* 主要按钮 */
.tech-button-primary {
  background: linear-gradient(45deg, var(--neon-blue), var(--neon-pink));
  color: var(--mech-black);
}

.tech-button-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px var(--neon-blue-shadow);
}

/* 次要按钮 */
.tech-button-secondary {
  background: transparent;
  color: var(--neon-blue);
  border: 1px solid var(--neon-blue);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.tech-button-secondary:hover {
  background: rgba(0, 240, 255, 0.1);
  box-shadow: 0 0 15px var(--neon-blue-shadow);
}

/* 成功按钮 */
.tech-button-success {
  background: linear-gradient(45deg, var(--neon-green), var(--neon-blue));
  color: var(--mech-black);
  box-shadow: 0 0 10px var(--neon-green-shadow);
}

.tech-button-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px var(--neon-green-shadow);
}

/* 警告按钮 */
.tech-button-warning {
  background: linear-gradient(45deg, var(--warning-orange), var(--neon-pink));
  color: var(--mech-black);
  box-shadow: 0 0 10px var(--warning-orange-shadow);
}

.tech-button-warning:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px var(--warning-orange-shadow);
}

/* 按钮大小 */
.tech-button-sm {
  padding: 8px 16px;
  font-size: 0.875rem;
}

.tech-button-lg {
  padding: 16px 32px;
  font-size: 1.25rem;
}

/* 禁用状态 */
.tech-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.tech-button:disabled:hover {
  box-shadow: none;
}

/* 科技感卡片组件 */
.tech-card {
  background: rgba(26, 26, 26, 0.95);
  border-radius: 8px;
  box-shadow: 
    0 0 20px rgba(0, 240, 255, 0.3),
    inset 0 0 20px rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.3);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
  margin-bottom: 1rem;
}

.tech-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--neon-blue), var(--neon-pink));
}

.tech-card-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid rgba(0, 240, 255, 0.2);
}

.tech-card-body {
  padding: 1.5rem;
}

.tech-card-title {
  font-family: 'Orbitron', sans-serif;
  color: var(--neon-blue);
  font-weight: 700;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 10px var(--neon-blue-shadow);
}

/* 输入框组件 */
.tech-input {
  padding: 12px 16px;
  font-size: 1rem;
  border-radius: 4px;
  border: 1px solid rgba(0, 240, 255, 0.3);
  background: rgba(0, 0, 0, 0.3);
  color: #e0e0e0;
  transition: all 0.3s ease;
  font-family: 'Roboto Mono', monospace;
  width: 100%;
}

.tech-input:focus {
  border-color: var(--neon-blue);
  box-shadow: 0 0 10px var(--neon-blue-shadow);
  background: rgba(0, 0, 0, 0.5);
  outline: none;
}

.tech-input-group {
  position: relative;
  margin-bottom: 1rem;
}

.tech-input-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--neon-blue);
  z-index: 2;
  transition: all 0.3s ease;
}

.tech-input-with-icon {
  padding-left: 2.5rem;
}

/* 复选框组件 */
.tech-checkbox {
  appearance: none;
  width: 20px;
  height: 20px;
  border: 1px solid rgba(0, 240, 255, 0.3);
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 4px;
  position: relative;
  cursor: pointer;
  transition: all 0.3s ease;
}

.tech-checkbox:checked {
  background-color: var(--neon-blue);
  border-color: var(--neon-blue);
  box-shadow: 0 0 10px var(--neon-blue-shadow);
}

.tech-checkbox:checked::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 2px;
  width: 6px;
  height: 12px;
  border: solid var(--mech-black);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* 进度条组件 */
.tech-progress {
  height: 10px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 5px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(0, 240, 255, 0.2);
}

.tech-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--neon-blue), var(--neon-green));
  border-radius: 5px;
  position: relative;
  animation: progressFlow 2s linear infinite;
  background-size: 200% 100%;
}

@keyframes progressFlow {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 200% 50%;
  }
}

/* 脉冲动画 */
.pulse-animation {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 240, 255, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(0, 240, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(0, 240, 255, 0);
  }
}

/* 淡入动画 */
.fade-in {
  animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 悬浮动画 */
.float-animation {
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}

/* 响应式设计 */
@media (max-width: 768px) {
  .tech-card {
    margin-bottom: 0.75rem;
  }
  
  .tech-card-body {
    padding: 1rem;
  }
  
  .tech-button {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
  
  h1 {
    font-size: 1.8rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
}

@media (max-width: 576px) {
  .tech-card-body {
    padding: 0.75rem;
  }
  
  .tech-button {
    padding: 8px 16px;
    font-size: 0.8rem;
  }
  
  h1 {
    font-size: 1.5rem;
  }
  
  h2 {
    font-size: 1.3rem;
  }
  
  p {
    font-size: 0.9rem;
  }
}