/* Bittly 官网现代化样式 */

/* 全局变量 */
:root {
  --primary-color: #667eea;
  --secondary-color: #764ba2;
  --accent-color: #f093fb;
  --success-color: #4ecdc4;
  --warning-color: #ff6b6b;
  --info-color: #45b7d1;
  --dark-color: #2c3e50;
  --light-color: #f5f7fa;
  --gradient-primary: linear-gradient(45deg, #667eea, #764ba2);
  --gradient-secondary: linear-gradient(45deg, #f093fb, #f5576c);
  --gradient-success: linear-gradient(45deg, #4ecdc4, #44a08d);
  --shadow-light: 0 5px 15px rgba(0,0,0,0.1);
  --shadow-medium: 0 10px 25px rgba(0,0,0,0.15);
  --shadow-heavy: 0 20px 40px rgba(0,0,0,0.2);
  --border-radius: 0.75rem;
  --transition: all 0.3s ease;
}

/* 全局样式重置 */
* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  overflow-x: hidden;
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

/* 通用动画类 */
.fade-in-up {
  animation: fadeInUp 0.8s ease-out;
}

.slide-in-left {
  animation: slideInLeft 0.8s ease-out;
}

.slide-in-right {
  animation: slideInRight 0.8s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* 悬停效果 */
.hover-lift {
  transition: var(--transition);
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

/* 渐变背景 */
.gradient-bg {
  background: var(--gradient-primary);
}

.gradient-bg-secondary {
  background: var(--gradient-secondary);
}

/* 卡片样式 */
.feature-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--border-radius);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
  transition: left 0.5s;
}

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

.feature-card:hover {
  background: rgba(255, 255, 255, 1);
  transform: translateY(-5px);
  box-shadow: var(--shadow-medium);
}

/* 按钮样式 */
.btn-modern {
  background: var(--gradient-primary);
  border: none;
  color: white;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  font-weight: 500;
}

.btn-modern:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
  color: white;
}

.btn-modern::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: left 0.5s;
}

.btn-modern:hover::before {
  left: 100%;
}

/* 徽章样式 */
.badge {
  font-size: 0.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: 20px;
  font-weight: 500;
}

/* 分隔线样式 */
.section-divider {
  height: 4px;
  background: linear-gradient(90deg, #667eea, #764ba2, #f093fb, #f5576c);
  margin: 0;
  border: none;
}

/* 响应式工具类 */
@media (max-width: 768px) {
  .section-padding {
    padding: 3rem 0;
  }
  
  .hero-section {
    min-height: 80vh;
  }
}

@media (max-width: 576px) {
  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* 加载动画 */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* 文字渐变效果 */
.text-gradient {
  background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientShift 3s ease-in-out infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* 浮动动画 */
@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33% { transform: translateY(-20px) rotate(120deg); }
  66% { transform: translateY(10px) rotate(240deg); }
}

/* 脉冲动画 */
@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.1); opacity: 0.7; }
  100% { transform: scale(1); opacity: 1; }
}

/* 工具提示样式 */
.tooltip-custom {
  position: relative;
  cursor: help;
}

.tooltip-custom::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
  z-index: 1000;
}

.tooltip-custom:hover::after {
  opacity: 1;
}

/* 进度条样式 */
.progress-modern {
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  overflow: hidden;
}

.progress-modern .progress-bar {
  background: var(--gradient-primary);
  transition: width 0.6s ease;
}

/* 模态框样式增强 */
.modal-content {
  border-radius: var(--border-radius);
  border: none;
  box-shadow: var(--shadow-heavy);
}

.modal-header {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  background: var(--light-color);
}

/* 表格样式增强 */
.table-modern {
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-light);
}

.table-modern th {
  background: var(--gradient-primary);
  color: white;
  border: none;
  font-weight: 600;
}

.table-modern td {
  border-color: rgba(0, 0, 0, 0.05);
}

/* 表单样式增强 */
.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

/* 导航栏样式增强 */
.navbar {
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.95) !important;
}

.navbar-brand {
  font-weight: 700;
  color: var(--primary-color) !important;
}

.nav-link {
  font-weight: 500;
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--primary-color) !important;
  transform: translateY(-1px);
}

/* 页脚样式增强 */
.footer {
  background: var(--dark-color);
  color: white;
  padding: 3rem 0 1rem;
}

.footer a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: var(--transition);
}

.footer a:hover {
  color: white;
  text-decoration: none;
}

/* 打印样式 */
@media print {
  .no-print {
    display: none !important;
  }
  
  .print-break {
    page-break-before: always;
  }
}