:root {
    --bg-primary: #0a0a0b;
    --bg-secondary: #121214;
    --bg-card: #1a1a1d;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a5;
    --accent-red: #dc3545;
    --accent-red-glow: rgba(220, 53, 69, 0.5);
    --border-color: #2a2a2d;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    position: relative;
}

/* 背景网格效果 */
.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    pointer-events: none;
    z-index: 0;
}

/* 主布局：单屏左右分栏 */
.layout {
    position: relative;
    z-index: 1;
    display: flex;
    height: 100vh;
    width: 100%;
}

/* ============ 左侧 Hero ============ */
.hero {
    position: relative;
    flex: 0 0 45%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
}

.hero-badge {
    display: inline-block;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.1rem;
    color: var(--accent-red);
    letter-spacing: 0.3em;
    margin-bottom: 1.5rem;
    padding: 0.5rem 1.5rem;
    border: 1px solid var(--accent-red);
    border-radius: 2px;
    background: rgba(220, 53, 69, 0.08);
}

.hero-avatar {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    border: 6px solid var(--accent-red);
    box-shadow: 0 0 25px rgba(220, 53, 69, 0.4), 0 0 50px rgba(220, 53, 69, 0.15);
    margin-bottom: 1.5rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.hero-name {
    font-size: 3.5rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: var(--accent-red);
    text-shadow: 0 0 10px rgba(220, 53, 69, 0.5), 0 0 40px rgba(220, 53, 69, 0.2);
    margin-bottom: 1rem;
    line-height: 1.1;
}

.hero-slogan {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 300;
    letter-spacing: 0.05em;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ============ 右侧内容面板 ============ */
.content-panel {
    flex: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 2rem 2.5rem;
    gap: 1.5rem;
    overflow: hidden;
}

/* 关于我 */
.about {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    position: relative;
    overflow: hidden;
}

.about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: var(--accent-red);
}

.about-header {
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.75rem;
}

.about-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.about-subtitle {
    font-size: 0.75rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.about-text {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1rem;
    font-weight: 300;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.05em;
}

.tag:hover {
    border-color: var(--accent-red);
    color: var(--accent-red);
    box-shadow: 0 0 10px rgba(220, 53, 69, 0.3);
    transform: translateY(-2px);
}

/* 外站跳转 */
.links-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.section-label {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem;
    color: var(--accent-red);
    letter-spacing: 0.15em;
    margin-bottom: 0.75rem;
}

/* 终端卡片 */
.terminal-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.terminal-header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.terminal-title {
    margin-left: auto;
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.05em;
}

.terminal-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 1rem;
    gap: 0.5rem;
}

.link-item {
    display: flex;
    align-items: center;
    padding: 0.9rem 1rem;
    border: 1px solid var(--border-color);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
    background: var(--bg-secondary);
}

.link-item:hover {
    border-color: var(--accent-red);
    background: rgba(220, 53, 69, 0.05);
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.2);
    transform: translateX(4px);
}

.link-icon {
    width: 40px;
    height: 40px;
    background: var(--bg-primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    flex-shrink: 0;
}

.link-icon i {
    background: linear-gradient(135deg, var(--accent-red), #ff6b7a);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.link-item:hover .link-icon {
    border-color: var(--accent-red);
}

.link-info {
    flex: 1;
    min-width: 0;
}

.link-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.1rem;
    letter-spacing: 0.03em;
    transition: color 0.3s ease;
}

.link-description {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 300;
}

.link-item:hover .link-title {
    color: var(--accent-red);
}

.link-cmd {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.7rem;
    color: var(--text-secondary);
    margin-right: 0.75rem;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.link-item:hover .link-cmd {
    color: var(--accent-red);
    opacity: 1;
}

.link-arrow {
    font-size: 1rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    opacity: 0.5;
}

.link-item:hover .link-arrow {
    color: var(--accent-red);
    transform: translateX(6px);
    opacity: 1;
}

/* 未上线项目：敬请期待提示 */
.link-item.coming-soon {
    position: relative;
    cursor: not-allowed;
    opacity: 0.55;
    filter: grayscale(0.5);
}

.link-item.coming-soon::after {
    content: '敬请期待';
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translate(0, -50%) scale(0.9);
    padding: 0.3rem 0.9rem;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    color: var(--accent-red);
    background: var(--bg-primary);
    border: 1px solid var(--accent-red);
    border-radius: 3px;
    box-shadow: 0 0 12px rgba(220, 53, 69, 0.55), 0 0 30px rgba(220, 53, 69, 0.25);
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
    z-index: 2;
}

.link-item.coming-soon:hover {
    opacity: 1;
    filter: none;
    border-color: var(--accent-red);
    background: rgba(220, 53, 69, 0.05);
    box-shadow: 0 0 15px rgba(220, 53, 69, 0.2);
    transform: translateX(4px);
}

.link-item.coming-soon:hover::after {
    opacity: 1;
    transform: translate(0, -50%) scale(1);
}

.link-item.coming-soon:hover .link-cmd,
.link-item.coming-soon:hover .link-arrow {
    opacity: 0;
}

/* ============ 加载动画 ============ */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    pointer-events: none;
}

.loader-content {
    text-align: center;
}

.loader-spinner {
    width: 60px;
    height: 60px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-red);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-text {
    font-family: 'Orbitron', sans-serif;
    color: var(--accent-red);
    letter-spacing: 0.2em;
    animation: blink 1.5s ease-in-out infinite;
}

/* ============ 滚动条（仅内部容器，页面级已禁用） ============ */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-red);
}

/* ============ 响应式 ============ */
@media (max-width: 768px) {
    .layout {
        flex-direction: column;
    }

    .hero {
        flex: 0 0 32%;
    }

    .hero-name {
        font-size: 2.5rem;
    }

    .hero-slogan {
        font-size: 0.9rem;
    }

    .content-panel {
        padding: 1rem 1.25rem;
        gap: 1rem;
    }

    .about {
        padding: 1rem;
    }

    .hero-avatar {
        width: 90px;
        height: 90px;
        margin-bottom: 1rem;
    }

    .about-title {
        font-size: 1.1rem;
    }

    .about-text {
        font-size: 0.85rem;
        line-height: 1.6;
    }

    .tag {
        font-size: 0.7rem;
        padding: 0.2rem 0.6rem;
    }

    .link-item {
        padding: 0.7rem 0.8rem;
    }

    .link-icon {
        width: 34px;
        height: 34px;
        font-size: 0.95rem;
        margin-right: 0.7rem;
    }

    .link-title {
        font-size: 0.9rem;
    }

    .link-cmd {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero-name {
        font-size: 2rem;
    }

    .about-text {
        font-size: 0.8rem;
    }

    .tech-tags {
        gap: 0.35rem;
    }
}
