* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Microsoft YaHei", Arial, sans-serif;
    color: #1c293f;
}

.detect-page {
    display: grid;
    place-items: center;
    padding: 24px;
    background: #edf4ff;
}

.detect-card {
    position: relative;
    width: min(550px, 100%);
    min-height: 606px;
    padding: 44px 40px 48px;
    overflow: hidden;
    text-align: center;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 28px 80px rgba(62, 112, 219, 0.16);
}

.card-top {
    position: absolute;
    inset: 0 0 auto;
    height: 4px;
    background: linear-gradient(90deg, #4b8cff, #6c63ff);
}

.bolt {
    display: grid;
    place-items: center;
    width: 80px;
    height: 80px;
    margin: 4px auto 34px;
    color: #3d86ff;
    font-size: 42px;
    font-weight: 800;
    background: #eef2ff;
    border-radius: 50%;
}

h1 {
    margin: 0 0 10px;
    font-size: 22px;
    line-height: 1.4;
}

p {
    margin: 0;
    color: #6b778c;
    font-size: 15px;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 42px auto;
    border: 5px solid #edf4ff;
    border-top-color: #4b8cff;
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}

.route-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-height: 66px;
    margin: 0 auto 32px;
    padding: 18px 20px;
    color: #43536b;
    background: #effdf8;
    border-left: 4px solid #18d19b;
    border-radius: 8px;
    box-shadow: 0 8px 26px rgba(24, 209, 155, 0.18);
}

.route-box strong {
    color: #0fc38d;
    white-space: nowrap;
}

.progress {
    height: 10px;
    overflow: hidden;
    background: #e9effb;
    border-radius: 999px;
}

.progress span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #3f8cff, #7565f5);
    transition: width 0.28s ease;
}

.actions,
.continue-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 32px;
}

button,
a {
    min-height: 48px;
    border: 0;
    border-radius: 7px;
    padding: 0 28px;
    font: 700 15px/48px "Microsoft YaHei", Arial, sans-serif;
    text-decoration: none;
    cursor: pointer;
}

button:disabled {
    cursor: wait;
    opacity: 0.58;
}

.primary {
    color: #fff;
    background: linear-gradient(135deg, #2f8cff, #6655ed);
    box-shadow: 0 10px 24px rgba(63, 119, 243, 0.28);
}

.ghost {
    color: #44536a;
    background: #f8fafc;
}

.green {
    color: #fff;
    background: #29b466;
}

.wide {
    width: min(295px, 44vw);
}

.continue-page {
    display: grid;
    place-items: center;
    padding: 28px;
    background: #f5f8fc;
}

#networkCanvas {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
}

.continue-panel {
    position: relative;
    z-index: 1;
    width: min(672px, 100%);
    padding: 32px 32px 34px;
    overflow: hidden;
    text-align: center;
    background: rgba(255, 255, 255, 0.94);
    border-radius: 12px;
    box-shadow: 0 8px 22px rgba(38, 52, 78, 0.13);
}

.continue-panel::before,
.continue-panel::after {
    content: "";
    position: absolute;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: rgba(104, 211, 198, 0.12);
}

.continue-panel::before {
    left: -86px;
    bottom: -74px;
}

.continue-panel::after {
    right: -74px;
    top: -72px;
    background: rgba(100, 135, 255, 0.1);
}

.continue-title {
    position: relative;
    z-index: 1;
    margin: 0 0 26px;
    font-size: 22px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 620px) {
    .detect-card {
        min-height: auto;
        padding: 36px 20px;
    }

    .actions,
    .continue-actions {
        flex-direction: column;
    }

    .wide,
    button,
    a {
        width: 100%;
    }

    .route-box {
        align-items: flex-start;
        flex-direction: column;
    }
}

.nav-page {
    display: grid;
    place-items: start center;
    min-height: 100vh;
    background: #333;
}

.nav-shell {
    width: min(540px, 100%);
    min-height: 100vh;
    color: #fff;
    background: #050505;
}

.brand-poster {
    position: relative;
    min-height: 680px;
    overflow: hidden;
    padding: 92px 22px 54px;
    text-align: center;
    background:
        radial-gradient(circle at 50% 58%, rgba(255, 84, 24, 0.42), transparent 18%),
        radial-gradient(circle at 50% 38%, rgba(255, 215, 117, 0.24), transparent 21%),
        linear-gradient(180deg, #080808 0%, #111 46%, #050505 100%);
}

.brand-poster::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 22% 14%, rgba(166, 126, 70, 0.45) 0 3px, transparent 4px),
        radial-gradient(circle at 78% 20%, rgba(166, 126, 70, 0.35) 0 3px, transparent 4px),
        radial-gradient(circle at 18% 42%, rgba(166, 126, 70, 0.32) 0 5px, transparent 6px),
        radial-gradient(circle at 86% 44%, rgba(166, 126, 70, 0.28) 0 5px, transparent 6px);
    opacity: 0.8;
}

.chips {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(22deg, transparent 8%, rgba(187, 148, 87, 0.34) 9% 11%, transparent 12%) 30px 20px / 160px 130px,
        linear-gradient(-28deg, transparent 8%, rgba(187, 148, 87, 0.28) 9% 11%, transparent 12%) 70px 90px / 190px 150px;
    opacity: 0.55;
}

.ky-logo {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 220px;
    height: 220px;
    margin-bottom: 34px;
    background: linear-gradient(180deg, #2a2a2a, #b81410 62%, #f0b22e);
    border: 8px solid #ffd56d;
    border-radius: 38px;
    box-shadow: 0 0 0 4px #fff3c4, 0 0 32px rgba(255, 174, 49, 0.45);
}

.ky-logo span {
    display: grid;
    place-items: center;
    width: 78px;
    height: 92px;
    color: #fff;
    font: 900 60px/1 Georgia, serif;
    text-shadow: 0 3px 0 rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    transform: rotate(-8deg);
}

.ky-logo span:first-child {
    background: linear-gradient(160deg, #74e7ff, #156dc7);
}

.ky-logo span:last-child {
    background: linear-gradient(160deg, #ff7865, #c91610);
    transform: rotate(8deg);
}

.brand-poster h1 {
    position: relative;
    z-index: 1;
    margin: 0;
    color: #fff7d8;
    font-size: clamp(52px, 12vw, 76px);
    font-weight: 900;
    letter-spacing: 0;
    text-shadow: 0 4px 0 #8b1a12, 0 9px 18px rgba(255, 179, 70, 0.42);
}

.brand-poster h2 {
    position: relative;
    z-index: 1;
    margin: 26px 0 32px;
    color: #ffd07c;
    font-size: clamp(26px, 7vw, 40px);
    font-weight: 800;
    letter-spacing: 0;
    text-shadow: 0 0 14px rgba(255, 151, 38, 0.72);
}

.shine {
    position: relative;
    z-index: 1;
    width: 88%;
    height: 2px;
    margin: 0 auto 42px;
    background: linear-gradient(90deg, transparent, #ee8e28 42%, #fff 50%, #ee8e28 58%, transparent);
    box-shadow: 0 0 18px #ffbb4b;
}

.brand-poster strong {
    position: relative;
    z-index: 1;
    color: #ffe7b5;
    font-size: 32px;
    letter-spacing: 8px;
    text-shadow: 0 0 9px rgba(255, 142, 43, 0.8);
}

.nav-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid #202020;
}

.nav-hover-area {
    position: relative;
}

.hover-panel {
    display: none;
    position: absolute;
    z-index: 6;
}

.link-panel {
    padding: 18px 44px 20px;
    background: rgba(0, 0, 0, 0.92);
    border-top: 1px solid #9f844d;
    border-bottom: 1px solid #9f844d;
}

.official-panel {
    left: 0;
    right: 0;
    bottom: 100%;
}

.nav-hover-area:has(.nav-official:hover) .official-panel,
.nav-hover-area:has(.nav-official:focus) .official-panel,
.nav-hover-area:has(.official-panel:hover) .official-panel,
.nav-hover-area:has(.official-panel:focus-within) .official-panel,
.official-panel.is-visible {
    display: block;
}

.line-row {
    display: grid;
    grid-template-columns: 56px 28px minmax(0, 1fr) 78px;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.line-row:last-child {
    margin-bottom: 0;
}

.line-state,
.line-url,
.line-btn {
    height: 28px;
    border-radius: 0;
    text-align: center;
    line-height: 28px;
}

.line-state,
.line-url {
    color: #2f3743;
    background: #fff;
}

.line-state {
    font-size: 12px;
}

.line-arrow {
    color: #6f6f6f;
    font-size: 13px;
    text-align: center;
}

.line-url {
    overflow: hidden;
    padding: 0 10px;
    font-size: 13px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.line-btn {
    display: block;
    min-height: 28px;
    padding: 0;
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    background: #ae9262;
}

.nav-grid a {
    display: grid;
    place-items: center;
    min-height: 82px;
    padding: 14px;
    color: #fff;
    line-height: 1.25;
    background: #050505;
    border-right: 1px solid #202020;
    border-bottom: 1px solid #202020;
}

.nav-grid a:nth-child(2n) {
    border-right: 0;
}

.nav-grid span {
    display: block;
    margin-top: 8px;
    font-size: 15px;
    font-weight: 700;
}

.icon {
    position: relative;
    display: block;
    width: 24px;
    height: 24px;
    color: #b99b66;
}

.icon::before,
.icon::after {
    content: "";
    position: absolute;
    display: block;
}

.home::before {
    left: 2px;
    top: 9px;
    width: 20px;
    height: 13px;
    background: currentColor;
    clip-path: polygon(0 40%, 50% 0, 100% 40%, 86% 40%, 86% 100%, 60% 100%, 60% 64%, 40% 64%, 40% 100%, 14% 100%, 14% 40%);
}

.compass::before {
    inset: 2px;
    border: 4px solid currentColor;
    border-radius: 50%;
}

.compass::after {
    left: 9px;
    top: 5px;
    width: 8px;
    height: 14px;
    background: #050505;
    border: 3px solid currentColor;
    transform: rotate(45deg);
}

.phone::before {
    left: 5px;
    top: 1px;
    width: 14px;
    height: 22px;
    border: 4px solid currentColor;
    border-radius: 4px;
}

.phone::after {
    left: 11px;
    bottom: 4px;
    width: 3px;
    height: 3px;
    background: currentColor;
    border-radius: 50%;
}

.service::before {
    left: 3px;
    top: 5px;
    width: 18px;
    height: 15px;
    background: currentColor;
    clip-path: polygon(50% 0, 90% 18%, 100% 62%, 70% 100%, 30% 100%, 0 62%, 10% 18%);
}

.service::after {
    left: 7px;
    top: 11px;
    width: 10px;
    height: 5px;
    border-bottom: 3px solid #050505;
    border-radius: 50%;
}

.nav-shell footer {
    padding: 12px 8px 18px;
    color: #ddd;
    text-align: center;
    font-size: 11px;
}

.browser-panel {
    grid-template-columns: 1fr;
    width: 100%;
    background: #050505;
    border-top: 1px solid #9f844d;
    border-right: 1px solid #9f844d;
    border-bottom: 1px solid #9f844d;
}

.browser-flyout {
    left: 0;
    right: 0;
    bottom: 100%;
}

.nav-hover-area:has(.nav-browser:hover) .browser-flyout,
.nav-hover-area:has(.nav-browser:focus) .browser-flyout,
.nav-hover-area:has(.browser-flyout:hover) .browser-flyout,
.nav-hover-area:has(.browser-flyout:focus-within) .browser-flyout,
.browser-flyout.is-visible {
    display: grid;
}

.browser-panel a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 64px;
    color: #fff;
    border-top: 1px solid #1c1c1c;
}

.browser-panel span {
    font-size: 14px;
    font-weight: 700;
}

@media (max-width: 560px) {
    .brand-poster {
        min-height: 72vh;
        padding-top: 64px;
    }

    .ky-logo {
        width: 170px;
        height: 170px;
    }

    .ky-logo span {
        width: 58px;
        height: 70px;
        font-size: 46px;
    }

    .link-panel {
        padding: 16px 16px 18px;
    }

    .line-row {
        grid-template-columns: 54px 22px minmax(0, 1fr) 72px;
        gap: 6px;
    }

    .line-url {
        font-size: 12px;
    }
}
