/* ===== 全局重置 & 字体 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #0c0e14;
    background-image: radial-gradient(circle at 20% 30%, #1a1f2e, #050608 90%);
    padding: 20px;
}

/* ===== 主容器卡片 + 淡入动画 ===== */
.card {
    max-width: 860px;
    width: 100%;
    background: rgba(16, 22, 34, 0.75);
    backdrop-filter: blur(16px);
    border-radius: 48px;
    padding: 40px 35px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8), 0 0 60px rgba(0, 180, 255, 0.02);
    transition: 0.4s ease;
    /* ★★★ 页面加载淡入动画 ★★★ */
    animation: fadeInUp 0.7s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== 顶部头像 & ID ===== */
.header {
    display: flex;
    align-items: center;
    gap: 25px;
    flex-wrap: wrap;
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.avatar {
    width: 80px;
    height: 80px;
    border-radius: 28px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 0 40px rgba(45, 156, 219, 0.25);
    border: 2px solid rgba(255, 255, 255, 0.1);
}
.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.id-group h1 {
    color: #eef5ff;
    font-size: 32px;
    font-weight: 800;
    letter-spacing: 1px;
    line-height: 1.2;
}
.id-group h1 .highlight {
    background: linear-gradient(135deg, #6ab0fe, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.alias {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    margin-top: 6px;
}
.alias span {
    color: #8899bb;
    font-size: 15px;
    letter-spacing: 0.5px;
}
.alias span::before {
    content: "✦ ";
    color: #4a6a8a;
}

/* ===== 游戏偏好 ===== */
.games-section {
    margin-bottom: 35px;
}
.section-label {
    color: #5a7a9a;
    font-size: 13px;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.section-label::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05), transparent);
}

.game-duo {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.game-card {
    padding: 20px 22px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.3s ease;
    cursor: default;
    position: relative;
    overflow: hidden;
}
.game-card:hover {
    transform: translateY(-4px);
}

.game-mc {
    border-left: 4px solid #4ade80;
}
.game-mc:hover {
    background: rgba(74, 222, 128, 0.05);
    border-color: #4ade80;
    box-shadow: 0 10px 30px rgba(74, 222, 128, 0.08);
}
.game-mc .g-icon { color: #4ade80; }
.game-mc .g-tag { background: rgba(74, 222, 128, 0.12); color: #86efac; }

.game-cs {
    border-left: 4px solid #fb923c;
}
.game-cs:hover {
    background: rgba(251, 146, 60, 0.05);
    border-color: #fb923c;
    box-shadow: 0 10px 30px rgba(251, 146, 60, 0.08);
}
.game-cs .g-icon { color: #fb923c; }
.game-cs .g-tag { background: rgba(251, 146, 60, 0.12); color: #fdba74; }

.game-card .g-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}
.game-card .g-icon {
    font-size: 28px;
}
.game-card .g-name {
    font-size: 20px;
    font-weight: 700;
    color: #e8f0fa;
}
.game-card .g-desc {
    color: #9ab0cc;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 12px;
}
.game-card .g-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.game-card .g-tag {
    padding: 2px 14px;
    border-radius: 30px;
    font-size: 12px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

/* ===== MC服务器状态卡片 ===== */
.server-card {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 24px;
    padding: 20px 22px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.server-input-group {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    align-items: center;
}

.btn-mc {
    padding: 12px 30px;
    background: #2d6b2d;
    border: none;
    border-radius: 40px;
    color: white;
    font-size: 15px;
    font-weight: 700;
    text-shadow: 0 2px 0 #1a3f1a;
    box-shadow: 0 5px 0 #1a3f1a;
    cursor: pointer;
    transition: all 0.08s linear;
    white-space: nowrap;
}
.btn-mc:hover {
    background: #3a8a3a;
    transform: translateY(-2px);
    box-shadow: 0 7px 0 #1a3f1a;
}
.btn-mc:active {
    transform: translateY(4px);
    box-shadow: 0 2px 0 #1a3f1a;
}

#status-panel {
    min-height: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    transition: 0.3s;
}

.status-badge {
    display: inline-block;
    padding: 4px 16px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 700;
    margin: 0 auto 6px auto;
}
.status-online {
    background: #1a5a1a;
    color: #8fff8f;
    border: 1px solid #5f9f5f;
}
.status-offline {
    background: #5a1a1a;
    color: #ff8f8f;
    border: 1px solid #9f5f5f;
}
.status-loading {
    background: #3a3a1a;
    color: #ffff8f;
    border: 1px solid #9f9f5f;
}

.player-count {
    font-size: 32px;
    font-weight: 900;
    color: #7cfc9e;
    text-shadow: 0 0 30px rgba(124, 252, 158, 0.3);
}
.player-count span {
    font-size: 18px;
    color: #8a9a8a;
}
.motd-text {
    color: #aab8c8;
    font-style: italic;
    margin-top: 4px;
    font-size: 13px;
}
.error-text {
    color: #ff7a7a;
    font-weight: 600;
}

/* ===== 联系区域 ===== */
.contact-section {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 28px;
    padding: 22px 28px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}
.contact-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    padding: 8px 0;
}
.contact-row:first-child {
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    padding-bottom: 16px;
    margin-bottom: 12px;
}

.contact-label {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #7a9aba;
    font-size: 15px;
    font-weight: 500;
    min-width: 60px;
}
.contact-label .c-icon {
    font-size: 20px;
}

.contact-value {
    color: #d0def0;
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 0.5px;
    font-family: 'Courier New', monospace;
    background: rgba(0,0,0,0.3);
    padding: 4px 16px;
    border-radius: 40px;
    border: 1px solid rgba(255,255,255,0.03);
    word-break: break-all;
    flex: 1;
    min-width: 150px;
}

.btn-copy {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: #aac0da;
    padding: 8px 22px;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.btn-copy:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
    color: #fff;
}
.btn-copy:active {
    transform: scale(0.95);
}
.btn-copy.copied {
    background: rgba(74, 222, 128, 0.15);
    border-color: #4ade80;
    color: #86efac;
}

/* ===== 底部 ===== */
.footer {
    margin-top: 30px;
    text-align: center;
    color: #3a4a5a;
    font-size: 12px;
    letter-spacing: 2px;
    line-height: 1.8;
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
    .card { padding: 30px 24px; }
}

@media (max-width: 650px) {
    .card { padding: 24px 16px; border-radius: 32px; }
    .header { flex-direction: column; align-items: center; text-align: center; gap: 15px; }
    .id-group h1 { font-size: 26px; }
    .alias { justify-content: center; }
    .alias span { font-size: 14px; }
    .game-duo { grid-template-columns: 1fr; gap: 14px; }
    .game-card { padding: 16px 18px; }
    .game-card .g-name { font-size: 18px; }
    .game-card .g-desc { font-size: 13px; }
    .contact-section { padding: 16px; border-radius: 20px; }
    .contact-row { flex-wrap: wrap; gap: 10px 8px; padding: 8px 0; }
    .contact-label { font-size: 14px; min-width: 40px; }
    .contact-label .c-icon { font-size: 18px; }
    .contact-value { font-size: 15px; padding: 6px 12px; min-width: 100px; flex: 1 1 auto; text-align: center; }
    .btn-copy, .contact-row a.btn-copy { padding: 10px 18px; font-size: 14px; min-height: 44px; min-width: 80px; justify-content: center; }
    .contact-row a.btn-copy { flex: 0 0 auto; }
    .footer { font-size: 11px; margin-top: 20px; }
    .server-input-group { flex-direction: column; }
    .btn-mc { width: 100%; justify-content: center; padding: 14px; }
    .player-count { font-size: 26px; }
}

@media (max-width: 400px) {
    .id-group h1 { font-size: 22px; }
    .alias span { font-size: 12px; }
    .contact-value { font-size: 13px; padding: 4px 8px; min-width: 80px; }
    .btn-copy, .contact-row a.btn-copy { padding: 8px 12px; font-size: 12px; min-height: 38px; min-width: 60px; }
    .game-card .g-name { font-size: 16px; }
}