/* download.css - 下载页面样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
}



body {
    /* background: #f5f7fa; */
    min-height: 100vh;
    /* display: flex;
    align-items: center;
    justify-content: center; */
    /* padding: 16px; */
}

.card {
    /* background-image: url('/img/bg2x.png'); */
    background-size: 100% 100%;
    background-repeat: no-repeat;
    /* background: #bbba8c; */
    width: 100%;
    /* height: 90vh; */
    max-width: 400px;
    position: relative;
    /* border-radius: 32px;
    box-shadow: 0 20px 40px rgba(0, 20, 40, 0.12);
    padding: 24px 20px 30px;
    border: 1px solid rgba(224, 230, 238, 0.6); */
}

.brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.brand h1 {
    font-size: 22px;
    font-weight: 600;
    background: linear-gradient(145deg, #1e2b3c, #2c3e50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.badge-domain {
    background: #eef2f6;
    padding: 6px 12px;
    border-radius: 40px;
    font-size: 13px;
    font-weight: 500;
    color: #3a4b5e;
    border: 1px solid #d9e0e8;
}

.subhead {
    font-size: 15px;
    color: #546e7a;
    margin-bottom: 28px;
    padding-bottom: 12px;
    border-bottom: 1px dashed #cfdbe8;
    display: flex;
    gap: 6px;
}

.subhead span {
    background: #dee5ed;
    padding: 4px 10px;
    border-radius: 30px;
    font-size: 12px;
    color: #1f3a4b;
}

.download-section {
    /* margin-bottom: 32px; */
    /* background: #f9fbfd; */
    border-radius: 22px;
    padding: 10px;
    /* border: 1px solid #e9eef3; */
}

.section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    font-weight: 600;
    color: #1e2f40;
    font-size: 16px;
}

.section-title .icon {
    font-size: 22px;
}

.h5-block, .apk-block {
    /* display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px; */
    /* margin-top: 10px; */
}

.qr-container {
    background: #fff;
    padding: 8px;
    border-radius: 20px;
    border: 1px solid #dbe2ea;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s;
    position: relative;
}

.qr-container:active {
    transform: scale(0.95);
}

canvas.qr-canvas {
    width: 90px;
    height: 90px;
    display: block;
    border-radius: 12px;
    pointer-events: none;
    position: relative;
    z-index: 1;
}

.qr-logo {
    position: absolute;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #fff;
    padding: 3px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    pointer-events: none;
    z-index: 2;
    /* 默认隐藏，加载完成后显示 */
    opacity: 0;
    transition: opacity 0.2s ease;
}

.qr-logo.loaded {
    opacity: 1;
}

.qr-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 6px;
    /* 图片加载时完全透明，避免显示裂图 */
    opacity: 0;
    transition: opacity 0.2s ease;
}

.qr-logo img.loaded {
    opacity: 1;
}

.link-area {
    flex: 1;
    /* min-width: 180px; */
    margin-top: 4px;
}

.link-label {
    font-size: 13px;
    color: #5c6f82;
    margin-bottom: 6px;
    display: flex;
    gap: 4px;
}

.btn-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #0b1129;
    color: #fff;
    border: none;
    border-radius: 10px;
    padding: 8px;
    font-weight: 600;
    font-size: 14px;
    width: 100%;
    text-decoration: none;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 18px rgba(20, 40, 70, 0.15);
}

.btn-outline {
    /* background: #fff; */
    /* color: #1e2f40; */
    border: 1.5px solid #b8c8da;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
}

.url-preview {
    background: #eef3f8;
    padding: 8px 14px;
    border-radius: 30px;
    font-size: 12px;
    color: #38536b;
    word-break: break-all;
    border: 1px solid #d0ddee;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    /* 隐藏显示URL预览 */
    display: none !important;
}

.url-preview .tag {
    background: #2a4359;
    color: #fff;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
}

.footer-note {
    text-align: center;
    font-size: 12px;
    color: #8a9bb0;
    margin-top: 22px;
    border-top: 1px solid #dce5f0;
    padding-top: 18px;
}

.footer-note strong {
    color: #2c3e50;
}

@media (max-width: 380px) {
    .h5-block, .apk-block {
        /* flex-direction: column;
        align-items: flex-start; */
        /* margin-top: 10px; */
    }
}

/* 二维码放大模态框 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 24px;
    max-width: 90%;
    text-align: center;
}

.qr-image-container {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0 auto;
    display: inline-block;
}

.modal-content canvas {
    width: 280px;
    height: 280px;
    max-width: 100%;
    border-radius: 16px;
    border: 2px solid #ffffff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: block;
    position: relative;
    z-index: 1;
}

.modal-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 84px;
    height: 84px;
    background: #fff;
    border-radius: 16px;
    padding: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    pointer-events: none;
    z-index: 2;
    border: none;
    /* 默认隐藏，加载完成后显示 */
    opacity: 0;
    transition: opacity 0.2s ease;
}

.modal-logo.loaded {
    opacity: 1;
}

.modal-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.modal-logo img.loaded {
    opacity: 1;
}

.modal-content p {
    margin-top: 16px;
    color: #1e2f40;
    font-size: 16px;
    font-weight: 500;
    word-break: break-all;
}

.modal-content .modal-url {    
    display: none;
    font-size: 14px;
    color: #546e7a;
    margin-top: 8px;
    padding: 8px;
    background: #f5f7fa;
    border-radius: 12px;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: #fff;
    font-size: 32px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    z-index: 1001;
}

.modal-close:active {
    background: rgba(255, 255, 255, 0.3);
}

.save-tip {
    background: #4CAF50;
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 16px;
    margin-top: 20px;
    cursor: pointer;
    font-weight: 500;
}

.save-tip:active {
    background: #45a049;
}

/* 品牌区域调整 */
.brand {
    display: flex;
    align-items: flex-start; /* 改为靠左对齐 */
    justify-content: space-between;
    margin-bottom: 20px;
    float: left;
}

/* 品牌logo样式 */
.brand-logo {
    height: 36px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    display: block;
    /* 默认隐藏，加载完成后显示 */
    opacity: 0;
    transition: opacity 0.2s ease;
}

.brand-logo.loaded {
    opacity: 1;
}

/* 品牌标题 - 默认隐藏，当logo加载失败时显示 */
.brand h1 {
    /* display: none; */
    font-size: 22px;
    font-weight: 600;
    align-items: flex-start; /* 改为靠左对齐 */
    background: linear-gradient(145deg, #1e2b3c, #2c3e50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
}

/* 当品牌logo隐藏时，显示h1 */
.brand h1.brand-title-visible {
    display: block;
}

.card_body{
    display: flex;
    justify-content: center;
    position: absolute;
    bottom: 150px;
    width: 100%;
}

.card_item{
    background-image: url(/img/card_item2x.png);
    background-size: 100% 100%;
    background-repeat: no-repeat;
    width: 45%;
    margin: 0 5px;
}

.card_item_t{
    display: flex;
    justify-content: center;
    align-items: center;
}

/* 顶部logo区域透明覆盖按钮 */
.logo-overlay {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 80px;
    height: 80px;
    background: transparent;
    cursor: pointer;
    z-index: 15;
    border-radius: 8px;
    transition: all 0.3s;
}

.logo-overlay:hover {
    background: rgba(255, 255, 255, 0.1);
}

.logo-overlay:active {
    background: rgba(255, 255, 255, 0.2);
}


