/* ==========================================================
   ZONKVM 授权查询页
   1. 查询工具页（输入域名核验授权）
   2. 授权详情页（官方核验结果）
   ========================================================== */

/* ---- 基础 ---- */
.check-page {
    background: #f4f5f7;
    min-height: 100vh;
}
.check-container {
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    padding: 48px 20px 72px;
    box-sizing: border-box;
}

/* ---- 卡片通用 ---- */
.check-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(20, 30, 55, 0.06);
    overflow: hidden;
}
.check-card-head {
    padding: 26px 40px 20px;
    border-bottom: 1px solid #eceef1;
}
.check-card-head .check-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 24px;
    padding: 0 12px;
    margin-bottom: 14px;
    border-radius: 12px;
    font-size: 12px;
    color: #00a04d;
    background: #e8f9ef;
}
.check-card-head .check-badge i { font-size: 13px; }
.check-title {
    margin: 0 0 6px;
    font-size: 22px;
    font-weight: 600;
    line-height: 1.4;
    color: #16213a;
}
.check-subtitle {
    margin: 0;
    font-size: 14px;
    color: #7a8494;
}
.check-card-body {
    padding: 30px 40px 34px;
}
.check-card-foot {
    padding: 14px 40px;
    background: #fafbfc;
    border-top: 1px solid #eceef1;
    font-size: 12px;
    color: #8a93a2;
    line-height: 1.7;
    text-align: center;
}

/* ---- 查询表单 ---- */
.check-search {
    display: flex;
    height: 50px;
    border: 1px solid #d9dee7;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.check-search:focus-within {
    border-color: #2f5bff;
    box-shadow: 0 0 0 3px rgba(47, 91, 255, 0.10);
}
.check-search-icon {
    flex: 0 0 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8a93a2;
    background: #fafbfc;
    border-right: 1px solid #eceef1;
}
.check-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: none;
    padding: 0 16px;
    font-size: 14px;
    color: #16213a;
    background: transparent;
}
.check-search input::placeholder { color: #b2bac6; }
.check-btn {
    flex: 0 0 auto;
    border: 0;
    outline: none;
    background: #2f5bff;
    color: #fff;
    min-width: 108px;
    padding: 0 24px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s ease;
}
.check-btn:hover { background: #2449d8; }
.check-btn:disabled { opacity: 0.6; cursor: default; }

/* ---- 查询结果 ---- */
.check-result {
    margin-top: 20px;
    border: 1px solid #eceef1;
    border-radius: 8px;
    background: #fafbfc;
    padding: 22px 24px;
    min-height: 86px;
    box-sizing: border-box;
    transition: border-color 0.2s ease;
}
.check-result-domain {
    font-size: 13px;
    color: #8a93a2;
    margin-bottom: 8px;
    word-break: break-all;
}
.check-result-state {
    font-size: 17px;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 6px;
}
.check-result-tips {
    font-size: 13px;
    line-height: 1.7;
    color: #6b7686;
}
.check-result.is-ok { border-color: #b7ebc8; background: #f6fdf9; }
.check-result.is-ok .check-result-state { color: #00a04d; }
.check-result.is-fail { border-color: #ffe1c4; background: #fffaf5; }
.check-result.is-fail .check-result-state { color: #e06a00; }
.check-result.is-neutral .check-result-state { color: #8a93a2; }

/* ==========================================================
   授权证书（网址参数核验结果页）
   ========================================================== */
/* 顶部深蓝横幅 */
.verify-hero {
    position: relative;
    overflow: hidden;
    padding: 44px 44px 38px;
    color: #fff;
    background: linear-gradient(130deg, #1236b3 0%, #2450e6 48%, #3d6bff 100%);
}
.verify-hero::before {
    content: "";
    position: absolute;
    right: -70px;
    top: -70px;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .06);
}
.verify-hero::after {
    content: "";
    position: absolute;
    right: 24px;
    bottom: -120px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .16);
}
.verify-hero .verify-badge {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 26px;
    padding: 0 14px;
    margin-bottom: 22px;
    border-radius: 13px;
    font-size: 13px;
    background: #fff;
    color: #00a04d;
    box-shadow: 0 2px 8px rgba(9, 30, 66, .14);
}
.verify-hero .verify-badge i { font-size: 14px; }
.verify-hero .verify-domain {
    position: relative;
    z-index: 1;
    margin: 0 0 10px;
    font-size: 30px;
    font-weight: 600;
    letter-spacing: .5px;
    color: #fff;
    word-break: break-all;
}
.verify-hero .verify-desc {
    position: relative;
    z-index: 1;
    margin: 0;
    font-size: 14px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .84);
}
/* 未授权横幅(灰调) */
.verify-hero.is-invalid {
    background: linear-gradient(130deg, #454b55 0%, #5b636e 100%);
}
.verify-hero.is-invalid .verify-badge {
    color: #d93026;
}
.verify-body {
    padding: 34px 44px 36px;
}
/* 信息网格 */
.verify-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border: 1px solid #e3e8ef;
    border-radius: 10px;
    overflow: hidden;
    background: #e3e8ef;
    gap: 1px;
}
.verify-item {
    background: #fff;
    padding: 20px 26px;
    transition: background .2s ease;
}
.verify-item:hover { background: #fafbfd; }
.verify-item .label {
    font-size: 12px;
    color: #8a93a2;
    margin-bottom: 8px;
}
.verify-item .value {
    font-size: 14px;
    font-weight: 500;
    color: #16213a;
    word-break: break-all;
}
.verify-item .value.is-valid { color: #00a04d; }
/* 底部核验信息 */
.verify-meta {
    margin-top: 26px;
    padding-top: 18px;
    border-top: 1px dashed #dfe5ec;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 32px;
    font-size: 12px;
    color: #8a93a2;
}
.verify-meta b { font-weight: 500; color: #4a5568; }

/* 未授权结果区 */
.unauth-panel {
    text-align: center;
    padding: 8px 0 4px;
}
.unauth-icon {
    width: 68px;
    height: 68px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background: #ffece8;
    color: #d93026;
    font-size: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.unauth-panel p {
    margin: 0 0 6px;
    font-size: 14px;
    color: #4a5568;
    line-height: 1.8;
}
.unauth-panel .unauth-tip {
    margin-top: 4px;
    font-size: 13px;
    color: #8a93a2;
}

/* ==========================================================
   授权证书（证书样式重设计）
   ========================================================== */
.cert-card {
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    overflow: visible;
}
.cert {
    max-width: 210mm;
    margin: 0 auto;
    padding: 16px;
    box-sizing: border-box;
}
.cert-paper {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 210mm;
    min-height: 297mm;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 18mm 20mm 16mm;
    background-color: #f7faff;
    border: 2px solid #1f5fb0;
    border-radius: 6px;
    box-shadow: 0 12px 40px rgba(20, 60, 140, .18);
    font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
    color: #1f2a44;
}
/* 内描金边框 */
.cert-paper::before {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    top: 14px;
    bottom: 14px;
    border: 1px solid #9cc0ef;
    border-radius: 3px;
    pointer-events: none;
}
/* 四角装饰 */
.cert-corner {
    position: absolute;
    width: 22px;
    height: 22px;
    border: 2px solid #1f5fb0;
    z-index: 2;
}
.cert-corner.tl { left: 20px; top: 20px; border-right: 0; border-bottom: 0; }
.cert-corner.tr { right: 20px; top: 20px; border-left: 0; border-bottom: 0; }
.cert-corner.bl { left: 20px; bottom: 20px; border-right: 0; border-top: 0; }
.cert-corner.br { right: 20px; bottom: 20px; border-left: 0; border-top: 0; }

.cert-head {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cert-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 15px;
    color: #1f2a44;
}
.cert-brand i { color: #1f5fb0; font-size: 18px; }
.cert-no {
    font-size: 12px;
    color: #1f5fb0;
    letter-spacing: .5px;
}

.cert-title {
    margin: 26px 0 6px;
    text-align: center;
    font-family: "STKaiti", "KaiTi", "Songti SC", "SimSun", serif;
    font-size: 40px;
    font-weight: 700;
    letter-spacing: 12px;
    color: #15407a;
    text-indent: 12px;
}
.cert-subtitle {
    text-align: center;
    font-size: 12px;
    letter-spacing: 4px;
    color: #3d7bd6;
    text-transform: uppercase;
}

.cert-domain-box {
    margin: 28px auto 8px;
    text-align: center;
}
.cert-domain-label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    letter-spacing: 2px;
    color: #9aa3b2;
}
.cert-domain {
    display: inline-block;
    padding: 6px 22px;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #143a78;
    border-bottom: 2px solid #1f5fb0;
}

.cert-statement {
    margin: 18px auto 26px;
    max-width: 620px;
    text-align: center;
    font-size: 15px;
    line-height: 2;
    color: #4a5568;
}
.cert-statement b { color: #1f5fb0; }

.cert-info {
    position: relative;
    z-index: 2;

    border-top: 1px solid #cfe0f5;
}
.cert-row {
    display: flex;
    padding: 13px 4px;
    border-bottom: 1px dashed #cfe0f5;
}
.shouquanzhang {
    background-image: url("/template/onezon/css/img/shouquanzhang.png");
    background-repeat: no-repeat;
    background-position: center center;
    background-size: contain;
    width: 160px;
    height: 160px;
}

.cert-k {
    flex: 0 0 150px;
    font-size: 13px;
    color: #9aa3b2;
}
.cert-v {
    flex: 1;
    font-size: 14px;
    font-weight: 600;
    color: #2a2f3a;
    word-break: break-all;
}
.cert-v.cert-valid { color: #c0392b; }

.cert-note {
    position: relative;
    z-index: 2;
    max-width: 620px;
    margin: 26px auto 0;
    padding: 14px 22px 12px;
    border: 1px dashed #9cc0ef;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, .55);
    text-align: left;
}
.cert-note-title {
    margin-bottom: 4px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #15407a;
}
.cert-note-item {
    font-size: 12.5px;
    line-height: 2;
    color: #4a5568;
}
.cert-note-item i { color: #1f5fb0; margin-right: 6px; }

.cert-sign-area {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    min-height: 118px;
    margin-top: auto;
}
.cert-sign {
    font-size: 13px;
    line-height: 2;
    color: #4a5568;
}
.cert-sign-line { white-space: nowrap; }

.cert-seal-img {
    flex: 0 0 124px;
    width: 124px;
    height: 124px;
    margin-right: 12px;
    transform: rotate(-12deg);
}

.cert-foot {
    position: relative;
    z-index: 2;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #cfe0f5;
    text-align: center;
    font-size: 12px;
    line-height: 1.9;
    color: #9aa3b2;
}
.cert-foot b { color: #6b7686; font-weight: 500; }

/* 操作栏（打印/下载） */
.cert-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    max-width: 210mm;
    margin: 0 auto 14px;
}
.cert-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 40px;
    padding: 0 20px;
    border: 1px solid #1f5fb0;
    border-radius: 8px;
    background: #fff;
    color: #1f5fb0;
    font-size: 14px;
    cursor: pointer;
    transition: all .2s ease;
}
.cert-btn:hover { background: #f0f6ff; color: #143a78; }
.cert-btn-primary {
    background: #15407a;
    border-color: #15407a;
    color: #fff;
}
.cert-btn-primary:hover { background: #0f3366; color: #fff; }

/* ==========================================================
   未授权：授权核验告知书（专门样式）
   ========================================================== */
.unauth-card {
    background: transparent;
    box-shadow: none;
    border-radius: 0;
    overflow: visible;
}
.unauth {
    max-width: 780px;
    margin: 0 auto;
    padding: 16px;
    box-sizing: border-box;
}
.unauth-paper {
    position: relative;
    padding: 52px 56px 44px;
    background-color: #fff;
    border: 2px solid #d9534f;
    border-radius: 6px;
    box-shadow: 0 12px 40px rgba(120, 30, 20, .12);
    font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
    color: #2a2f3a;
}
.unauth-paper::before {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    top: 14px;
    bottom: 14px;
    border: 1px dashed #e7b7b4;
    border-radius: 3px;
    pointer-events: none;
}
.unauth-corner {
    position: absolute;
    width: 22px;
    height: 22px;
    border: 2px solid #d9534f;
    z-index: 2;
}
.unauth-corner.tl { left: 20px; top: 20px; border-right: 0; border-bottom: 0; }
.unauth-corner.tr { right: 20px; top: 20px; border-left: 0; border-bottom: 0; }
.unauth-corner.bl { left: 20px; bottom: 20px; border-right: 0; border-top: 0; }
.unauth-corner.br { right: 20px; bottom: 20px; border-left: 0; border-top: 0; }

.unauth-head {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.unauth-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 15px;
    color: #1f2a44;
}
.unauth-brand i { color: #d9534f; font-size: 18px; }
.unauth-no {
    font-size: 12px;
    color: #c0392b;
    letter-spacing: .5px;
}

.unauth-badge {
    display: block;
    width: max-content;
    margin: 24px auto 6px;
    padding: 8px 26px;
    border-radius: 20px;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    background: #d9534f;
    box-shadow: 0 4px 14px rgba(217, 83, 79, .3);
}
.unauth-badge i { margin-right: 6px; }

.unauth-title {
    margin: 8px 0 22px;
    text-align: center;
    font-family: "STKaiti", "KaiTi", "Songti SC", "SimSun", serif;
    font-size: 34px;
    font-weight: 700;
    letter-spacing: 10px;
    color: #c0392b;
    text-indent: 10px;
}

.unauth-domain-box {
    margin: 0 auto 18px;
    text-align: center;
}
.unauth-domain-label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    letter-spacing: 2px;
    color: #9aa3b2;
}
.unauth-domain {
    display: inline-block;
    padding: 6px 22px;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #c0392b;
    border-bottom: 2px solid #d9534f;
}

.unauth-statement {
    margin: 0 auto 26px;
    max-width: 620px;
    text-align: center;
    font-size: 15px;
    line-height: 2;
    color: #4a5568;
}
.unauth-warn { color: #c0392b; font-weight: 600; }

.unauth-info {
    max-width: 620px;
    margin: 0 auto;
    border-top: 1px solid #f0d6d4;
}
.unauth-row {
    display: flex;
    padding: 13px 4px;
    border-bottom: 1px dashed #f0d6d4;
}
.unauth-k {
    flex: 0 0 150px;
    font-size: 13px;
    color: #9aa3b2;
}
.unauth-v {
    flex: 1;
    font-size: 14px;
    font-weight: 600;
    color: #2a2f3a;
    word-break: break-all;
}

.unauth-actions {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-top: 30px;
}
.unauth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0 26px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid #d9534f;
    color: #d9534f;
    background: #fff;
    transition: all .2s ease;
}
.unauth-btn:hover { background: #fff5f4; }
.unauth-btn-primary {
    background: #d9534f;
    color: #fff;
}
.unauth-btn-primary:hover { background: #c0392b; color: #fff; }

.unauth-foot {
    position: relative;
    z-index: 2;
    margin-top: 28px;
    padding-top: 16px;
    border-top: 1px solid #f0d6d4;
    text-align: center;
    font-size: 12px;
    line-height: 1.9;
    color: #9aa3b2;
}
.unauth-foot b { color: #6b7686; font-weight: 500; }

/* 打印适配 */
@page { size: A4; margin: 0; }
@media print {
    @page { size: A4; margin: 0; }

    html, body {
        margin: 0;
        padding: 0;
        background: #fff !important;
    }
    .check-container,
    .check-card,
    .cert-card,
    .cert,
    .unauth,
    .unauth-card {
        box-shadow: none;
        background: transparent !important;
        padding: 0 !important;
        max-width: none !important;
        margin: 0 !important;
    }
    /* 用 vw/vh 直接撑满整页（打印时 vw = 页面宽度 = 210mm，vh = 297mm） */
    .cert-paper,
    .unauth-paper {
        display: flex;
        flex-direction: column;
        width: 100vw !important;
        min-height: 100vh !important;
        height: 100vh !important;
        margin: 0 !important;
        box-sizing: border-box !important;
        box-shadow: none !important;
        border-color: #1f5fb0 !important;
    }
    /* 内容与纸边留出舒适留白，避免文字贴边 */
    .cert-paper {
        padding: 20mm 22mm 18mm !important;
    }
    .unauth-paper {
        padding: 22mm 24mm 20mm !important;
        border: 2px solid #d9534f !important;
        border-radius: 0 !important;
    }
    /* 打印时强制恢复桌面尺寸，防止移动端小字距样式串入 */
    .cert-title { font-size: 40px !important; letter-spacing: 12px !important; text-indent: 12px !important; }
    .cert-domain { font-size: 26px !important; padding: 6px 22px !important; }
    .cert-k { flex: 0 0 150px !important; }
    .cert-sign-area { min-height: 118px !important; margin-top: auto !important; }
    .unauth-title { font-size: 32px !important; letter-spacing: 8px !important; text-indent: 8px !important; }
    .unauth-domain { font-size: 24px !important; padding: 6px 20px !important; }
    .unauth-k { flex: 0 0 130px !important; }
    .cert-actions,
    .unauth-actions { display: none !important; }
    * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
}

/* ==========================================================
   响应式
   ========================================================== */
@media screen and (max-width: 767px) {
    .check-container { padding: 24px 12px 48px; }
    .check-card-head,
    .check-card-foot { padding-left: 20px; padding-right: 20px; }
    .check-card-body { padding: 22px 20px 26px; }
    .check-title { font-size: 19px; }
    .check-search { height: 46px; }
    .check-search-icon { flex-basis: 44px; }
    .check-btn { min-width: 88px; padding: 0 18px; }
    .verify-hero { padding: 30px 20px 26px; }
    .verify-body { padding: 24px 20px 28px; }
    .verify-hero .verify-domain { font-size: 21px; }
    .verify-grid { grid-template-columns: 1fr; }
    .cert { padding: 8px; }
    .cert-paper { padding: 32px 22px 30px; width: auto; min-height: auto; }
    .cert-title { font-size: 30px; letter-spacing: 8px; text-indent: 8px; }
    .cert-domain { font-size: 20px; padding: 4px 14px; }
    .cert-k { flex-basis: 110px; }
    .cert-seal { flex-basis: 92px; width: 92px; height: 92px; }
    .cert-sign-area { min-height: 90px; }
    .cert-actions { padding: 0 8px; }
    .cert-btn { flex: 1; justify-content: center; }
    .unauth { padding: 8px; }
    .unauth-paper { padding: 32px 22px 30px; }
    .unauth-title { font-size: 26px; letter-spacing: 6px; text-indent: 6px; }
    .unauth-domain { font-size: 20px; padding: 4px 14px; }
    .unauth-k { flex-basis: 110px; }
    .unauth-actions { flex-direction: column; }
    .unauth-btn { width: 100%; }
}
