/* ============================================================
   VIEW-VIDEO.CSS - 视频详情页
   播放器 + 视频信息 + 相关视频
   ============================================================ */

:root {
    --primary: #e63946;
    --primary-dark: #c1121f;
    --secondary: #1d3557;
    --accent: #f4a261;
    --white: #ffffff;
    --light: #f8f9fa;
    --light-blue: #e0f2fe;
    --dark: #0f172a;
    --border: #e5e7eb;
    --text: #1a1a2e;
    --text-muted: #6c757d;
    --radius: 8px;
    --radius-lg: 12px;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-hover: 0 8px 24px rgba(0,0,0,0.12);
    --transition: 0.3s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Segoe UI', sans-serif; line-height: 1.6; color: var(--text); background: var(--light); }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ==================== HEADER ==================== */
.header { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: var(--white); box-shadow: var(--shadow); }
.header-container { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; max-width: 1200px; margin: 0 auto; }
.logo img { height: 36px; }
.nav-toggle { display: flex; flex-direction: column; justify-content: center; align-items: center; width: 44px; height: 44px; background: var(--primary); border: none; border-radius: var(--radius); cursor: pointer; z-index: 101; }
.hamburger { width: 20px; height: 2px; background: var(--white); position: relative; }
.hamburger::before, .hamburger::after { content: ''; position: absolute; width: 20px; height: 2px; background: var(--white); }
.hamburger::before { top: -6px; }
.hamburger::after { top: 6px; }
.nav-toggle.active .hamburger { background: transparent; }
.nav-toggle.active .hamburger::before { transform: rotate(45deg); top: 0; }
.nav-toggle.active .hamburger::after { transform: rotate(-45deg); top: 0; }
.nav-menu { position: fixed; top: 0; right: -280px; width: 280px; height: 100vh; background: var(--white); box-shadow: var(--shadow-hover); padding: 70px 16px 24px; transition: right var(--transition); }
.nav-menu.active { right: 0; }
.nav-list { display: flex; flex-direction: column; gap: 4px; }
.nav-link { display: block; padding: 12px 16px; font-size: 15px; font-weight: 500; border-radius: var(--radius); }
.nav-link:hover, .nav-link.active { background: var(--light-blue); color: var(--primary); }
.nav-link.nav-cta { background: var(--primary); color: var(--white); text-align: center; margin-top: 8px; }

/* ==================== BREADCRUMB ==================== */
.breadcrumb-bar { padding: 70px 0 12px; background: var(--dark); }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 12px; color: rgba(255,255,255,0.6); }
.breadcrumb a:hover { color: var(--white); }
.breadcrumb span { color: rgba(255,255,255,0.4); }
.breadcrumb .current { color: var(--white); }

/* ==================== VIDEO PLAYER ==================== */
.video-player-section { background: var(--dark); padding: 0 0 24px; }
.player-wrapper { max-width: 1000px; margin: 0 auto; }
.video-frame { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: #000; }
.video-placeholder { position: relative; aspect-ratio: 16/9; }
.video-placeholder img { width: 100%; height: 100%; object-fit: cover; }
.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: var(--primary);
    border: none;
    border-radius: 50%;
    color: var(--white);
    font-size: 28px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 8px 32px rgba(230,57,70,0.5);
}
.play-btn:hover { transform: translate(-50%, -50%) scale(1.1); background: var(--primary-dark); }
.play-btn i { margin-left: 4px; }

/* ==================== VIDEO INFO ==================== */
.video-info { padding: 32px 0; background: var(--white); }
.info-grid { display: grid; gap: 32px; }
.info-main {}
.video-title { font-size: 22px; font-weight: 700; color: var(--secondary); line-height: 1.3; margin-bottom: 16px; }
.video-meta { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 16px; }
.video-meta .meta-item { font-size: 13px; color: var(--text-muted); }
.video-meta i { margin-right: 6px; color: var(--accent); }
.video-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.tag { padding: 4px 12px; font-size: 12px; color: var(--primary); background: rgba(230,57,70,0.1); border-radius: 20px; transition: var(--transition); }
.tag:hover { background: var(--primary); color: var(--white); }

.video-description { margin-bottom: 10px; }
.video-description h3 { font-size: 18px; margin-bottom: 12px; }
.video-description h4 { font-size: 15px; margin: 16px 0 8px; }
.video-description p { font-size: 18px; line-height: 1.8; margin-bottom: 12px; }
.video-description ul { margin-left: 20px; }
.video-description li { font-size: 16px; margin-bottom: 6px; list-style: disc; }

.video-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.action-btn { display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; font-size: 14px; font-weight: 500; color: var(--secondary); background: var(--light); border-radius: var(--radius); transition: var(--transition); }
.action-btn:hover { background: var(--border); }
.action-btn.primary { background: var(--primary); color: var(--white); }
.action-btn.primary:hover { background: var(--primary-dark); }

/* Sidebar */
.info-sidebar { display: flex; flex-direction: column; gap: 16px; }
.sidebar-card { padding: 16px; background: var(--light); border-radius: var(--radius-lg); }
.sidebar-card h4 { font-size: 14px; color: var(--secondary); margin-bottom: 12px; }
.equipment-link, .project-link { display: flex; gap: 12px; align-items: center; padding: 8px; background: var(--white); border-radius: var(--radius); transition: var(--transition); }
.equipment-link:hover, .project-link:hover { box-shadow: var(--shadow); }
.equipment-link img, .project-link img { width: 60px; height: 60px; border-radius: var(--radius); object-fit: cover; }
.equipment-link strong, .project-link strong { display: block; font-size: 13px; color: var(--secondary); }
.equipment-link span, .project-link span { font-size: 12px; color: var(--text-muted); }

/* ==================== RELATED VIDEOS ==================== */
.related-videos { padding: 40px 0; background: var(--light); }
.section-title { font-size: 22px; color: var(--secondary); margin-bottom: 24px; }
.videos-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.video-card { background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); transition: var(--transition); }
.video-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.card-thumb { position: relative; aspect-ratio: 16/9; overflow: hidden; }
.card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.video-card:hover .card-thumb img { transform: scale(1.05); }
.duration { position: absolute; bottom: 8px; right: 8px; padding: 2px 6px; font-size: 11px; font-weight: 600; color: var(--white); background: rgba(0,0,0,0.8); border-radius: 4px; }
.play-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.3); display: flex; justify-content: center; align-items: center; opacity: 0; transition: var(--transition); }
.video-card:hover .play-overlay { opacity: 1; }
.play-overlay i { width: 50px; height: 50px; background: var(--primary); border-radius: 50%; display: flex; justify-content: center; align-items: center; color: var(--white); font-size: 18px; }
.card-info { padding: 12px; }
.card-info h4 { font-size: 14px; color: var(--secondary); margin-bottom: 4px; line-height: 1.4; }
.card-info .views { font-size: 12px; color: var(--text-muted); }

/* ==================== CTA ==================== */
.cta-section { padding: 48px 0; background: var(--white); }
.cta-box { text-align: center; padding: 40px 24px; background: linear-gradient(135deg, var(--light-blue) 0%, #bae6fd 100%); border-radius: var(--radius-lg); }
.cta-box h2 { font-size: 22px; color: var(--secondary); margin-bottom: 8px; }
.cta-box p { font-size: 14px; color: var(--text-muted); margin-bottom: 20px; }
.cta-btn { display: inline-block; padding: 14px 32px; font-size: 15px; font-weight: 600; color: var(--white); background: var(--primary); border-radius: 24px; transition: var(--transition); }
.cta-btn:hover { background: var(--primary-dark); }

/* ==================== FOOTER ==================== */
.footer { background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 50%, #90caf9 100%); color: var(--text-dark); padding: 48px 0 24px; }
.footer-grid { display: grid; gap: 32px; margin-bottom: 32px; }
.footer-col h4 { font-size: 15px; margin-bottom: 16px; color: var(--primary); font-weight: 700; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--text-dark); font-weight: 700; font-size: 14px; }
.footer-col a:hover { color: var(--primary); }
.contact-list li { display: flex; align-items: center; gap: 8px; color: var(--text-dark); font-weight: 700; font-size: 13px; }
.contact-list i { color: var(--primary); width: 16px; }
.footer-bottom { text-align: center; padding-top: 24px; border-top: 1px solid rgba(0,0,0,0.08); }
.footer-bottom p { font-size: 13px; color: var(--text-dark); font-weight: 700; }

.back-to-top { position: fixed; bottom: 20px; right: 20px; width: 44px; height: 44px; background: var(--primary); color: var(--white); border: none; border-radius: 50%; cursor: pointer; opacity: 0; visibility: hidden; transition: var(--transition); z-index: 99; }
.back-to-top.visible { opacity: 1; visibility: visible; }

/* ==================== TABLET (768px) ==================== */
@media (min-width: 768px) {
    .header-container { padding: 8px 24px; }
    .logo img { height: 32px; }
    .nav-toggle { display: none; }
    .nav-menu { position: static; width: auto; height: auto; background: none; box-shadow: none; padding: 0; }
    .nav-list { flex-direction: row; gap: 0; }
    .nav-link { padding: 6px 8px; font-size: 13px; }
    .nav-link:hover, .nav-link.active { background: none; }
    .nav-link.nav-cta { padding: 6px 12px; margin-top: 0; margin-left: 4px; background: var(--primary); color: var(--white); }
    .nav-link.nav-cta:hover, .nav-link.nav-cta.active { background: var(--primary-dark); color: var(--white); }
    
    .breadcrumb-bar { padding: 80px 0 16px; }
    
    .video-title { font-size: 26px; }
    .info-grid { grid-template-columns: 2fr 1fr; gap: 40px; }
    
    .videos-grid { grid-template-columns: repeat(4, 1fr); }
    
    .footer-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ==================== DESKTOP (1024px) ==================== */
@media (min-width: 1024px) {
    .header-container { padding: 10px 32px; gap: 32px; justify-content: flex-start; }
    .logo img { height: 42px; }
    .nav-link { padding: 8px 14px; font-size: 15px; }
    .nav-link.nav-cta { padding: 8px 20px; font-size: 15px; }
    
    .breadcrumb-bar { padding: 90px 0 20px; }
    .play-btn { width: 100px; height: 100px; font-size: 36px; }
    
    .video-title { font-size: 30px; }
    .video-description h3 { font-size: 20px; }
    
    .section-title { font-size: 26px; }
    .card-info h4 { font-size: 15px; }
}
