@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    min-height: 100vh;
    display: block;
    font-family: 'Inter', sans-serif;
    color: #fff;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
}

.ocean-bg {
    position: fixed;
    inset: 0;
    background: linear-gradient(
        180deg,
        #020b18 0%,
        #041428 15%,
        #062040 35%,
        #083050 55%,
        #0a3d63 75%,
        #0d4f7a 100%
    );
    z-index: 0;
    overflow: hidden;
}

.stars {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.star {
    position: absolute;
    border-radius: 50%;
    background: #fff;
    animation: starTwinkle var(--dur) ease-in-out infinite var(--delay);
}

@keyframes starTwinkle {
    0%, 100% { opacity: var(--min-op); transform: scale(1); }
    50% { opacity: var(--max-op); transform: scale(1.4); }
}

.deep-glow {
    position: absolute;
    bottom: 0; left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 60%;
    background: radial-gradient(ellipse at 50% 100%,
        rgba(0, 180, 255, 0.12) 0%,
        rgba(0, 100, 200, 0.08) 40%,
        transparent 70%
    );
    pointer-events: none;
}

.caustics {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(ellipse 80px 40px at 20% 30%, rgba(0,200,255,0.04) 0%, transparent 100%),
        radial-gradient(ellipse 60px 30px at 70% 50%, rgba(0,180,255,0.05) 0%, transparent 100%),
        radial-gradient(ellipse 100px 50px at 45% 70%, rgba(0,150,220,0.04) 0%, transparent 100%);
    animation: causticsDrift 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes causticsDrift {
    0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.6; }
    33% { transform: translate(20px, -10px) scale(1.05); opacity: 1; }
    66% { transform: translate(-15px, 8px) scale(0.97); opacity: 0.7; }
}

.bubbles { position: absolute; inset: 0; pointer-events: none; }

.bubble {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.03);
    animation: bubbleRise var(--dur) ease-in infinite var(--delay);
    bottom: -20px;
}

@keyframes bubbleRise {
    0% { transform: translateX(0) translateY(0); opacity: 0; }
    10% { opacity: 0.6; }
    90% { opacity: 0.3; }
    100% { transform: translateX(var(--drift)) translateY(-110vh); opacity: 0; }
}

.waves-wrap {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 120px;
    pointer-events: none;
}

.wave {
    position: absolute;
    bottom: 0; left: 0;
    width: 100%; height: 120px;
}

.wave1 {
    fill: rgba(0, 150, 220, 0.12);
    animation: waveDrift 7s ease-in-out infinite;
}

.wave2 {
    fill: rgba(0, 120, 200, 0.08);
    animation: waveDrift 10s ease-in-out infinite reverse;
}

.wave3 {
    fill: rgba(0, 80, 160, 0.06);
    animation: waveDrift 13s ease-in-out infinite 2s;
}

@keyframes waveDrift {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-30px); }
}

.fish {
    position: absolute;
    font-size: 22px;
    pointer-events: none;
    filter: drop-shadow(0 0 6px rgba(0,200,255,0.3));
}

.fish1 {
    bottom: 18%;
    animation: fishSwim1 18s linear infinite;
}
.fish2 {
    bottom: 12%;
    animation: fishSwim2 24s linear infinite 6s;
    font-size: 16px;
}
.fish3 {
    bottom: 22%;
    animation: fishSwim1 30s linear infinite 12s;
    font-size: 14px;
    opacity: 0.7;
}

@keyframes fishSwim1 {
    0%   { left: -60px; transform: scaleX(1); }
    49%  { left: 110%; transform: scaleX(1); }
    50%  { left: 110%; transform: scaleX(-1); }
    99%  { left: -60px; transform: scaleX(-1); }
    100% { left: -60px; transform: scaleX(1); }
}

@keyframes fishSwim2 {
    0%   { right: -60px; left: auto; transform: scaleX(-1); }
    49%  { right: 110%; left: auto; transform: scaleX(-1); }
    50%  { right: 110%; left: auto; transform: scaleX(1); }
    99%  { right: -60px; left: auto; transform: scaleX(1); }
    100% { right: -60px; left: auto; transform: scaleX(-1); }
}

.jellyfish {
    position: absolute;
    font-size: 28px;
    pointer-events: none;
    filter: drop-shadow(0 0 10px rgba(150, 100, 255, 0.5));
    animation: jellyFloat var(--jdur, 6s) ease-in-out infinite var(--jdelay, 0s);
}

.jelly1 { bottom: 30%; left: 8%; --jdur: 5s; --jdelay: 0s; }
.jelly2 { bottom: 20%; right: 10%; --jdur: 7s; --jdelay: 2s; font-size: 20px; opacity: 0.7; }

@keyframes jellyFloat {
    0%, 100% { transform: translateY(0) rotate(-3deg); }
    50% { transform: translateY(-18px) rotate(3deg); }
}

.card {
    position: relative;
    z-index: 10;
    background: rgba(4, 18, 38, 0.75);
    border: 1px solid rgba(0, 180, 255, 0.18);
    border-radius: 26px;
    padding: 36px 42px 30px;
    width: 780px;
    max-width: 96vw;
    backdrop-filter: blur(28px) saturate(1.4);
    box-shadow:
        0 0 0 1px rgba(255,255,255,0.04),
        0 8px 60px rgba(0, 0, 0, 0.7),
        0 0 100px rgba(0, 120, 220, 0.1),
        inset 0 1px 0 rgba(255,255,255,0.06);
}

.card-shine {
    position: absolute;
    top: 0; left: 50%;
    transform: translateX(-50%);
    width: 55%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 200, 255, 0.7), transparent);
    border-radius: 50%;
}

.card-top {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-bottom: 28px;
}

.server-icon {
    width: 84px; height: 84px;
    background: linear-gradient(145deg, #071e3d, #0a2a50);
    border: 1px solid rgba(0, 180, 255, 0.2);
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0,0,0,0.5), inset 0 1px 0 rgba(255,255,255,0.05);
}

.server-icon img { width: 100%; height: 100%; object-fit: cover; display: none; border-radius: 22px; }
.icon-placeholder svg { width: 40px; height: 40px; color: #0ea5e9; }

.server-info { flex: 1; }

.server-name {
    font-size: 32px;
    font-weight: 900;
    letter-spacing: -1px;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #e0f2fe 0%, #7dd3fc 50%, #38bdf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.badges { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.badge-online {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #bae6fd;
    background: rgba(14, 165, 233, 0.1);
    border: 1px solid rgba(14, 165, 233, 0.2);
    border-radius: 8px;
    padding: 4px 11px;
}

.dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: #555;
    flex-shrink: 0;
    transition: all 0.4s;
}

.dot.online {
    background: #34d399;
    box-shadow: 0 0 8px #34d399, 0 0 18px rgba(52,211,153,0.4);
    animation: dotPulse 2s ease-in-out infinite;
}

.dot.offline { background: #f87171; }

@keyframes dotPulse {
    0%, 100% { box-shadow: 0 0 6px #34d399, 0 0 12px rgba(52,211,153,0.3); }
    50% { box-shadow: 0 0 12px #34d399, 0 0 24px rgba(52,211,153,0.5); }
}

.badge-version {
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.25);
    border-radius: 8px;
    padding: 4px 11px;
    font-size: 12px;
    font-weight: 600;
    color: #7dd3fc;
}

.server-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.player-count { display: flex; align-items: baseline; gap: 5px; }

.count-online {
    font-size: 50px;
    font-weight: 900;
    letter-spacing: -2px;
    line-height: 1;
    background: linear-gradient(135deg, #fff, #bae6fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.count-max { font-size: 20px; color: #334155; font-weight: 600; }

.ip-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    background: linear-gradient(135deg, #0369a1, #0ea5e9, #38bdf8);
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    padding: 9px 16px;
    cursor: pointer;
    transition: all 0.25s;
    box-shadow: 0 4px 20px rgba(14, 165, 233, 0.4);
    font-family: 'Inter', sans-serif;
}

.ip-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(14, 165, 233, 0.55);
}

.ip-btn:active { transform: translateY(0); }

.copy-hint {
    font-size: 12px;
    font-weight: 600;
    color: #34d399;
    opacity: 0;
    transition: opacity 0.3s;
    height: 16px;
}

.copy-hint.show { opacity: 1; }

.divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(56, 189, 248, 0.15), transparent);
    margin: 0 0 24px;
}

.stats-row {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
}

.stat-item {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: rgba(14, 165, 233, 0.05);
    border: 1px solid rgba(56, 189, 248, 0.1);
    border-radius: 14px;
    transition: border-color 0.3s, background 0.3s;
}

.stat-item:hover {
    border-color: rgba(56, 189, 248, 0.25);
    background: rgba(14, 165, 233, 0.09);
}

.stat-icon-wrap { font-size: 20px; line-height: 1; }

.stat-label {
    font-size: 11px;
    color: #475569;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 3px;
}

.stat-value { font-size: 14px; font-weight: 700; color: #e2e8f0; }

.chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.chart-title { font-size: 16px; font-weight: 700; color: #e0f2fe; }

.time-tabs {
    display: flex;
    gap: 3px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(56, 189, 248, 0.12);
    border-radius: 11px;
    padding: 3px;
}

.tab {
    background: transparent;
    border: none;
    color: #475569;
    font-size: 13px;
    font-weight: 600;
    padding: 5px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.tab.active {
    background: linear-gradient(135deg, #0369a1, #0ea5e9);
    color: #fff;
    box-shadow: 0 2px 12px rgba(14, 165, 233, 0.4);
}

.tab:hover:not(.active) { color: #94a3b8; }

.chart-wrap { height: 190px; position: relative; }

.chart-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 16px;
    font-size: 12.5px;
    color: #475569;
}

.peak-info { display: flex; align-items: center; gap: 6px; }
.peak-info strong { color: #f1f5f9; font-weight: 800; }

.update-info { display: flex; align-items: center; gap: 8px; }

.line-dot {
    display: inline-block;
    width: 20px; height: 3px;
    background: linear-gradient(90deg, #0ea5e9, #38bdf8);
    border-radius: 2px;
}

.back-btn {
    position: relative;
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #475569;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    background: rgba(4, 18, 38, 0.7);
    border: 1px solid rgba(56, 189, 248, 0.12);
    border-radius: 12px;
    padding: 10px 20px;
    backdrop-filter: blur(12px);
    transition: all 0.2s;
    margin-top: 16px;
    align-self: center;
}

.back-btn:hover {
    color: #38bdf8;
    border-color: rgba(56, 189, 248, 0.3);
    transform: translateX(-3px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.footer {
    margin-top: 20px;
    font-size: 14px;
    color: #475569;
    font-weight: 500;
    letter-spacing: 0.3px;
    text-align: center;
}

.footer a {
    color: #7dd3fc;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.2s;
}

.footer a:hover { color: #38bdf8; }

.detail-footer {
    width: 100%;
    max-width: 780px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(56,189,248,0.08);
    position: relative;
    z-index: 10;
}

.detail-footer .footer-legal {
    font-size: 11px;
    color: #64748b;
    line-height: 1.7;
    text-align: center;
    margin-bottom: 14px;
    display: block;
}

.detail-footer .footer-legal a {
    color: #94a3b8;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s;
}

.detail-footer .footer-legal a:hover { color: #7dd3fc; }

.detail-footer .footer-bottom { display: flex; justify-content: center; }

.detail-footer .footer-links {
    display: flex;
    align-items: center;
    gap: 12px;
}

.detail-footer .footer-link {
    color: #94a3b8;
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: color 0.2s;
}

.detail-footer .footer-link:hover { color: #38bdf8; }

.detail-footer .footer-sep { color: #1e3a5f; font-size: 16px; user-select: none; }

.detail-footer .footer-support-btn {
    background: rgba(14,165,233,0.1);
    border: 1px solid rgba(56,189,248,0.25);
    border-radius: 8px;
    color: #bae6fd;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.detail-footer .footer-support-btn:hover {
    background: rgba(14,165,233,0.18);
    border-color: rgba(56,189,248,0.4);
    color: #38bdf8;
}

.detail-footer .donate-wrap { position: relative; }

.detail-footer .donate-menu {
    position: absolute;
    bottom: calc(100% + 10px);
    right: 0;
    background: rgba(4,18,38,0.97);
    border: 1px solid rgba(56,189,248,0.2);
    border-radius: 14px;
    padding: 6px;
    min-width: 200px;
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.6);
    display: none;
    flex-direction: column;
    gap: 2px;
    z-index: 100;
}

.detail-footer .donate-menu.open { display: flex; }

.detail-footer .donate-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    text-decoration: none;
    color: #e0f2fe;
    transition: background 0.15s;
}

.detail-footer .donate-item:hover { background: rgba(56,189,248,0.08); }
.detail-footer .donate-flag { font-size: 22px; line-height: 1; }
.detail-footer .donate-name { font-size: 13px; font-weight: 700; color: #e0f2fe; margin-bottom: 2px; }
.detail-footer .donate-sub { font-size: 11px; color: #475569; font-weight: 500; }

.detail-page-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    position: relative;
    z-index: 10;
    padding: 40px 20px 60px;
}
