:root {
    --hk-bg: #07111f;
    --hk-panel: rgba(15, 23, 42, 0.84);
    --hk-panel-strong: rgba(15, 23, 42, 0.96);
    --hk-border: rgba(148, 163, 184, 0.18);
    --hk-text: #e2e8f0;
    --hk-muted: #94a3b8;
    --hk-info: #22d3ee;
    --hk-info-dark: #0891b2;
}

body {
    font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 30%),
        radial-gradient(circle at right center, rgba(245, 158, 11, 0.12), transparent 28%),
        linear-gradient(135deg, #020617 0%, #0f172a 55%, #111827 100%);
    color: var(--hk-text);
}

.login-shell,
.admin-shell {
    min-height: 100vh;
}

.admin-gradient {
    position: fixed;
    inset: 0;
    background-image: linear-gradient(to bottom right, rgba(34, 211, 238, 0.08), transparent 35%, rgba(251, 191, 36, 0.04));
    pointer-events: none;
}

.glass-card,
.panel-card,
.metric-card,
.sidebar-panel {
    background: var(--hk-panel);
    border: 1px solid var(--hk-border);
    border-radius: 1.5rem;
    box-shadow: 0 25px 80px rgba(2, 6, 23, 0.35);
    backdrop-filter: blur(18px);
}

.glass-card {
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(34, 211, 238, 0.14), transparent 45%, rgba(59, 130, 246, 0.08));
    pointer-events: none;
}

.hero-copy {
    max-width: 34rem;
}

.login-portrait-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 32rem;
    padding: 1rem 0;
}

.login-portrait-stage {
    position: relative;
    width: min(100%, 30rem);
    aspect-ratio: 1 / 1;
    margin: 0 auto;
    border-radius: 2rem;
    background:
        radial-gradient(circle at 50% 35%, rgba(125, 211, 252, 0.24), transparent 22%),
        radial-gradient(circle at 50% 100%, rgba(34, 211, 238, 0.16), transparent 42%),
        linear-gradient(180deg, rgba(15, 23, 42, 0.18) 0%, rgba(15, 23, 42, 0.04) 100%);
    overflow: hidden;
}

.login-portrait-stage::before {
    content: "";
    position: absolute;
    inset: 8% 12%;
    border-radius: 50%;
    border: 1px solid rgba(148, 163, 184, 0.18);
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.06), transparent 58%);
    filter: blur(0.2px);
}

.login-portrait-orbit {
    position: absolute;
    border-radius: 999px;
    border: 1px solid rgba(103, 232, 249, 0.24);
}

.orbit-one {
    inset: 10% 18%;
}

.orbit-two {
    inset: 19% 9%;
    transform: rotate(-18deg);
}

.orbit-three {
    inset: 19% 9%;
    transform: rotate(18deg);
}

.login-robot {
    position: absolute;
    inset: 0;
}

.login-robot-glow {
    position: absolute;
    left: 50%;
    top: 14%;
    width: 38%;
    aspect-ratio: 1 / 1;
    transform: translateX(-50%);
    border-radius: 50%;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.62) 0%, rgba(56, 189, 248, 0.16) 42%, transparent 72%);
    filter: blur(26px);
}

.login-robot-shadow {
    position: absolute;
    left: 50%;
    bottom: 12%;
    width: 42%;
    height: 8%;
    transform: translateX(-50%);
    border-radius: 50%;
    background: rgba(2, 6, 23, 0.62);
    filter: blur(16px);
}

.login-robot-body {
    position: absolute;
    left: 50%;
    bottom: 16%;
    width: 42%;
    height: 25%;
    transform: translateX(-50%);
    border-radius: 1.6rem 1.6rem 2.4rem 2.4rem;
    background:
        linear-gradient(180deg, #d7e3f4 0%, #9aa9bd 28%, #4a5870 78%, #111827 100%);
    border: 1px solid rgba(148, 163, 184, 0.34);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.44),
        inset 0 -14px 24px rgba(8, 15, 30, 0.42);
}

.robot-body-line {
    position: absolute;
    top: 18%;
    width: 2px;
    height: 48%;
    background: linear-gradient(180deg, transparent, rgba(34, 211, 238, 0.72), transparent);
}

.line-left {
    left: 24%;
}

.line-right {
    right: 24%;
}

.robot-core {
    position: absolute;
    left: 50%;
    top: 28%;
    width: 22%;
    aspect-ratio: 1 / 1;
    transform: translateX(-50%);
    border-radius: 1rem;
    background:
        radial-gradient(circle, rgba(125, 211, 252, 0.88) 0%, rgba(34, 211, 238, 0.52) 38%, rgba(8, 145, 178, 0.22) 70%, transparent 78%),
        linear-gradient(180deg, rgba(15, 23, 42, 0.84), rgba(30, 41, 59, 0.9));
    border: 1px solid rgba(103, 232, 249, 0.48);
    box-shadow: 0 0 22px rgba(34, 211, 238, 0.34);
}

.login-robot-neck {
    position: absolute;
    left: 50%;
    bottom: 33%;
    width: 12%;
    height: 8%;
    transform: translateX(-50%);
    border-radius: 0.8rem;
    background:
        repeating-linear-gradient(
            90deg,
            #475569 0,
            #475569 12%,
            #cbd5e1 12%,
            #cbd5e1 24%
        );
    border: 1px solid rgba(148, 163, 184, 0.3);
}

.login-robot-head {
    position: absolute;
    left: 50%;
    top: 20%;
    width: 34%;
    height: 34%;
    transform: translateX(-50%);
}

.robot-head-shell {
    position: absolute;
    inset: 4% 6% 0;
    border-radius: 1.8rem;
    background:
        linear-gradient(180deg, #f8fbff 0%, #d6e0ee 16%, #7b8ca4 52%, #263446 100%);
    border: 1px solid rgba(226, 232, 240, 0.42);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.78),
        inset 0 -18px 24px rgba(15, 23, 42, 0.24);
}

.robot-head-panel {
    position: absolute;
    inset: 22% 18% 24%;
    border-radius: 1.25rem;
    background:
        radial-gradient(circle at 50% 50%, rgba(34, 211, 238, 0.18), transparent 70%),
        linear-gradient(180deg, #0f172a 0%, #111827 100%);
    border: 1px solid rgba(34, 211, 238, 0.3);
    box-shadow:
        inset 0 0 18px rgba(34, 211, 238, 0.12),
        0 0 24px rgba(34, 211, 238, 0.08);
}

.robot-antenna {
    position: absolute;
    left: 50%;
    top: 0;
    width: 6%;
    height: 24%;
    transform: translateX(-50%);
    background: linear-gradient(180deg, #cbd5e1 0%, #475569 100%);
    border-radius: 999px;
}

.robot-antenna::before {
    content: "";
    position: absolute;
    left: 50%;
    top: -18%;
    width: 170%;
    aspect-ratio: 1 / 1;
    transform: translateX(-50%);
    border-radius: 50%;
    background: radial-gradient(circle, #67e8f9 0%, rgba(34, 211, 238, 0.42) 45%, rgba(34, 211, 238, 0.06) 76%, transparent 82%);
    box-shadow: 0 0 18px rgba(34, 211, 238, 0.56);
}

.robot-ear {
    position: absolute;
    top: 40%;
    width: 11%;
    height: 18%;
    border-radius: 0.9rem;
    background: linear-gradient(180deg, #d8e3f2 0%, #64748b 100%);
    border: 1px solid rgba(226, 232, 240, 0.28);
}

.robot-ear::before {
    content: "";
    position: absolute;
    inset: 24%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.84) 0%, rgba(8, 145, 178, 0.2) 62%, transparent 76%);
}

.robot-ear.ear-left {
    left: 0;
}

.robot-ear.ear-right {
    right: 0;
}

.robot-eye,
.robot-sensor,
.robot-mouth {
    position: absolute;
}

.robot-eye {
    top: 30%;
    width: 21%;
    height: 18%;
    border-radius: 999px;
    background:
        linear-gradient(180deg, rgba(125, 211, 252, 0.98), rgba(34, 211, 238, 0.68));
    box-shadow:
        0 0 14px rgba(34, 211, 238, 0.68),
        inset 0 0 10px rgba(255, 255, 255, 0.42);
}

.robot-eye::before {
    content: "";
    position: absolute;
    inset: 22% 18%;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.3);
}

.robot-eye.eye-left {
    left: 15%;
}

.robot-eye.eye-right {
    right: 15%;
}

.robot-sensor {
    left: 50%;
    top: 48%;
    width: 10%;
    aspect-ratio: 1 / 1;
    transform: translateX(-50%);
    border-radius: 50%;
    background: radial-gradient(circle, #67e8f9 0%, #06b6d4 48%, rgba(8, 145, 178, 0.2) 70%, transparent 78%);
    box-shadow: 0 0 14px rgba(34, 211, 238, 0.5);
}

.robot-mouth {
    left: 50%;
    bottom: 18%;
    width: 38%;
    height: 10%;
    transform: translateX(-50%);
    border-radius: 999px;
    background:
        repeating-linear-gradient(
            90deg,
            rgba(34, 211, 238, 0.08) 0,
            rgba(34, 211, 238, 0.08) 8%,
            rgba(125, 211, 252, 0.75) 8%,
            rgba(125, 211, 252, 0.75) 16%
        );
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.28);
}

.login-eyebrow,
.page-eyebrow,
.panel-eyebrow,
.sidebar-eyebrow {
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #67e8f9;
    font-size: 0.78rem;
}

.sidebar-panel {
    background: var(--hk-panel-strong);
    position: sticky;
    top: 1rem;
    margin: 1rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.9rem 1rem;
    color: var(--hk-text);
    text-decoration: none;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.02);
    transition: all 0.2s ease;
}

.sidebar-link:hover,
.sidebar-link.active {
    background: rgba(34, 211, 238, 0.14);
    color: white;
    transform: translateX(2px);
}

.sidebar-user {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--hk-border);
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 1rem;
}

.panel-card,
.metric-card {
    padding: 1.5rem;
}

.metric-card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.metric-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.metric-label {
    color: var(--hk-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.85rem;
}

.metric-value {
    color: white;
    font-size: 2rem;
    font-weight: 700;
}

.region-row,
.api-note,
.login-tip,
.detail-card {
    border: 1px solid var(--hk-border);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem 1.15rem;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.detail-label {
    color: var(--hk-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

.detail-value {
    color: #fff;
    font-weight: 600;
    word-break: break-word;
}

.preview-image {
    max-height: 70vh;
    object-fit: contain;
    border-radius: 1rem;
}

.result-detail-image {
    max-height: 28rem;
    width: auto;
    border-radius: 1rem;
    border: 1px solid var(--hk-border);
    box-shadow: 0 18px 40px rgba(2, 6, 23, 0.28);
    background: rgba(255, 255, 255, 0.03);
}

.result-thumb-button {
    padding: 0;
    border: 0;
    background: transparent;
    line-height: 0;
}

.result-thumbnail {
    width: 56px;
    height: 42px;
    object-fit: cover;
    border-radius: 0.6rem;
    border: 1px solid var(--hk-border);
    box-shadow: 0 6px 16px rgba(2, 6, 23, 0.22);
}

.result-thumb-button:hover .result-thumbnail,
.result-thumb-button:focus-visible .result-thumbnail {
    border-color: rgba(34, 211, 238, 0.7);
    transform: translateY(-1px);
}

.bulk-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 0.9rem 1rem;
    border: 1px solid var(--hk-border);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.03);
}

.table-dark {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: rgba(255, 255, 255, 0.02);
    --bs-table-hover-bg: rgba(34, 211, 238, 0.08);
    --bs-table-border-color: var(--hk-border);
}

.form-control,
.form-select,
.input-group-text {
    background-color: rgba(255, 255, 255, 0.06);
    border-color: rgba(148, 163, 184, 0.18);
    color: white;
}

.form-control:focus,
.form-select:focus {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(34, 211, 238, 0.7);
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(34, 211, 238, 0.18);
}

.form-control::placeholder {
    color: rgba(226, 232, 240, 0.55);
}

.form-select option {
    color: #111827;
}

.btn-info {
    background: linear-gradient(135deg, var(--hk-info) 0%, var(--hk-info-dark) 100%);
    border-color: transparent;
    color: #02131a;
}

.btn-info:hover,
.btn-info:focus {
    background: linear-gradient(135deg, #67e8f9 0%, #06b6d4 100%);
    color: #02131a;
}

.pagination-dark .page-link {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--hk-border);
    color: white;
}

.pagination-dark .page-item.active .page-link {
    background: rgba(34, 211, 238, 0.2);
    border-color: rgba(34, 211, 238, 0.35);
}

.pagination-dark .page-item.disabled .page-link {
    background: rgba(255, 255, 255, 0.02);
    color: rgba(255, 255, 255, 0.35);
}

code {
    display: inline-block;
    color: #67e8f9;
}

@media (max-width: 991.98px) {
    .sidebar-panel {
        position: static;
        margin: 1rem 0 0;
    }

    .page-header {
        flex-direction: column;
        align-items: start;
    }
}
