<template>
  <div class="not-found-page page-content">
    <div class="content-wrapper">
      <main class="main-content">
        <div class="error-content">
          <div class="error-code">404</div>
          <h1>页面未找到</h1>
          <p>抱歉，您访问的页面不存在或已被移除</p>
          <div class="actions">
            <button class="back-btn" @click="goBack">返回上一页</button>
            <button class="home-btn" @click="goHome">返回首页</button>
          </div>
        </div>
      </main>
    </div>
  </div>
</template>

<script setup>
import { useRouter } from 'vue-router'

const router = useRouter()

const goBack = () => {
  router.go(-1)
}

const goHome = () => {
  router.push('/')
}
</script>

<style scoped>
.not-found-page {
  font-family: 'Microsoft YaHei', Arial, sans-serif;
  margin: 0;
  padding: 0;
}

.content-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.main-content {
  text-align: center;
  min-height: calc(100vh - 60px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 20px;
}

.error-content {
  max-width: 600px;
}

.error-code {
  font-size: 8rem;
  font-weight: bold;
  color: #ff6b35;
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.error-content h1 {
  font-size: 2.5rem;
  color: #333;
  margin-bottom: 1rem;
}

.error-content p {
  font-size: 1.2rem;
  color: #666;
  margin-bottom: 40px;
  line-height: 1.6;
}

.actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.back-btn, .home-btn {
  padding: 12px 24px;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.back-btn {
  background: #f8f9fa;
  color: #333;
  border: 1px solid #e8e8e8;
}

.back-btn:hover {
  background: #e9ecef;
  transform: translateY(-2px);
}

.home-btn {
  background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
  color: #ffffff;
}

.home-btn:hover {
  background: linear-gradient(135deg, #f7931e 0%, #ff6b35 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(255, 107, 53, 0.3);
}

@media (max-width: 768px) {
  .error-code {
    font-size: 6rem;
  }
  
  .error-content h1 {
    font-size: 2rem;
  }
  
  .actions {
    flex-direction: column;
    align-items: center;
  }
}
</style> 