* {
    box-sizing: border-box;
}

:root {
    --overlay-left: 19%;
    --overlay-right: 19%;
    --overlay-top: 58.8%;
    --text-color: #4b4b4b;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    font-family: "Microsoft YaHei", "MicrosoftYaHei", Arial, sans-serif;
    background: #ffffff;
    color: #2d2d2d;
}

body {
    background: #ffffff;
    overflow: hidden;
    overscroll-behavior: none;
}

body.is-booting .boot-overlay {
    opacity: 1;
    visibility: visible;
}

body.is-booting .query-panel {
    opacity: 0;
    visibility: hidden;
}

.page-shell {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    height: 100svh;
    height: 100dvh;
}

.boot-overlay {
    position: absolute;
    inset: 0;
    background: #ffffff;
    color: #7a7a7a;
    font-size: 13px;
    line-height: 1;
    padding: 18px 16px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.16s ease;
    z-index: 3;
    text-align: left;
    user-select: none;
}

.query-panel {
    position: absolute;
    inset: 0;
    text-align: center;
    line-height: 0;
    overflow: hidden;
    background: #b61d22 url("../images/prkd/ok.jpg") top center / 100% 100% no-repeat;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.16s ease;
}

.result-template-image {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 0;
    margin: 0;
    box-shadow: none;
    object-fit: fill;
    object-position: top center;
}

.image-overlay {
    position: absolute;
    left: var(--overlay-left);
    right: var(--overlay-right);
    top: var(--overlay-top);
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    line-height: 1.72;
    gap: clamp(3px, 0.7vw, 7px);
}

.status-block {
    width: 100%;
    max-width: 100%;
    line-height: 1.72;
    font-size: clamp(13px, 2.2vw, 15px);
    color: var(--text-color);
    font-weight: 400;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.status-block::before {
    content: "";
    display: block;
    height: clamp(14px, 2.8vw, 22px);
}

.status-block .status-label-line,
.status-block .status-code-line,
.status-block .status-product-line {
    display: block;
}

.status-block .status-label-line {
    font-size: clamp(15px, 2.5vw, 18px);
    line-height: 1.35;
    font-weight: 700;
}

.status-block .status-code-line {
    margin-top: clamp(4px, 0.9vw, 8px);
    max-width: 100%;
    font-size: clamp(19px, 3.8vw, 28px);
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: 0.2px;
    color: #4e4e4e;
    overflow-wrap: anywhere;
    word-break: break-all;
}

.status-block .status-product-line {
    margin: clamp(6px, 1vw, 10px) auto 0;
    max-width: 88%;
    font-size: clamp(15px, 2.5vw, 18px);
    line-height: 1.45;
}

.status-block--first .status-code-line {
    margin-top: 0;
}

.status-block--first .status-product-line {
    margin-top: clamp(1px, 0.3vw, 4px);
}

.query-form {
    margin: 0;
    padding: 0;
}

.query-form--hidden {
    position: fixed;
    left: -9999px;
    top: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.query-label {
    display: block;
    font-size: 16px;
    margin-bottom: 10px;
    color: #7d1e23;
    font-weight: 700;
}

.query-row {
    display: flex;
    gap: 10px;
}

.query-row input {
    flex: 1;
    min-width: 0;
    height: 46px;
    border: 1px solid #d9d9d9;
    border-radius: 12px;
    padding: 0 14px;
    font-size: 16px;
    background: #ffffff;
}

.query-row button {
    border: 0;
    border-radius: 12px;
    padding: 0 20px;
    background: #a1161c;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
}

.query-tips {
    margin-top: 10px;
    color: #757575;
    font-size: 13px;
}

@media (max-width: 420px) {
    .image-overlay {
        left: 18.5%;
        right: 18.5%;
        top: 58.7%;
    }
}

@media (max-width: 360px) {
    .image-overlay {
        left: 18%;
        right: 18%;
        top: 58.3%;
    }

    .status-block {
        font-size: clamp(12px, 3.2vw, 14px);
    }

    .status-block .status-label-line,
    .status-block .status-product-line {
        font-size: clamp(13px, 3.7vw, 16px);
    }

    .status-block .status-code-line {
        font-size: clamp(17px, 5vw, 24px);
    }

}

@media (min-width: 641px) {
    .image-overlay {
        left: 19%;
        right: 19%;
        top: 58.1%;
    }
}
