/* Zibll 渠道分销 - 前端样式 */

/* 收银台：立即支付 + 由经销商授权 并排 */
.zibll-da-pay-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.zibll-da-pay-row .flex1 {
    flex: 1 1 0;
    min-width: 0;
}

.zibll-da-auth-btn {
    white-space: nowrap;
}

/* 授权面板 */
.zibll-da-qrcode {
    width: 200px;
    height: 200px;
    max-width: 100%;
    border-radius: 8px;
    background: #fff;
}

/* 扫码授权页 */
.zibll-da-scan-page {
    max-width: 520px;
}

.zibll-da-scan-page .box-body {
    padding: 24px 20px;
}

.zibll-da-success-icon {
    width: 96px;
    height: 96px;
}

/* 授权对象信息块：头像 + 两行说明
   两行字号、字重保持一致，颜色统一用主题 CSS 变量以适配夜间/昼间模式 */
.zibll-da-user-block {
    padding: 12px;
}

.zibll-da-avatar {
    flex: 0 0 auto;
}

.zibll-da-avatar img {
    display: block;
    width: 56px;
    height: 56px;
    max-width: 56px;
    border-radius: 50%;
    object-fit: cover;
}

.zibll-da-user-text {
    min-width: 0;
}

.zibll-da-user-line1,
.zibll-da-user-line2 {
    font-size: 15px;
    font-weight: 400;
    line-height: 1.5;
    /* 固定文字：夜间白色、白天深灰 */
    color: var(--key-color);
}

.zibll-da-user-line2 {
    margin-top: 4px;
}

/* 动态内容：用户名 / 课程名 */
.zibll-da-user-line1 b,
.zibll-da-user-line2 b {
    font-weight: 600;
    color: var(--focus-color);
}

/* 用户中心：授权记录卡片 */
.zibll-da-log + .zibll-da-log {
    margin-top: 10px;
}

.zibll-da-log .box-body {
    padding: 12px 14px;
}

.zibll-da-log-avatar {
    flex: 0 0 auto;
}

.zibll-da-log-avatar img {
    display: block;
    width: 46px;
    height: 46px;
    max-width: 46px;
    border-radius: 50%;
    object-fit: cover;
}

.zibll-da-log-main {
    min-width: 0;
    margin-left: 12px;
    margin-right: 10px;
}

.zibll-da-log-course {
    min-width: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--key-color);
}

.zibll-da-log-buyer {
    margin-top: 4px;
    font-size: 14px;
    font-weight: 600;
    color: var(--focus-color);
}

.zibll-da-log-date {
    margin-top: 2px;
}

.zibll-da-log-cover img {
    display: block;
    width: 84px;
    height: 60px;
    border-radius: 6px;
    object-fit: cover;
}

@media (max-width: 480px) {
    .zibll-da-log-cover img {
        width: 64px;
        height: 46px;
    }
}

/* 用户中心：可授权项卡片 */
.zibll-da-cards {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.zibll-da-card {
    flex: 1 1 260px;
    min-width: 240px;
    background: var(--main-bg-color);
    border: 1px solid var(--main-border-color);
    border-radius: 8px;
    padding: 14px;
    box-sizing: border-box;
}

.zibll-da-card-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--key-color);
    margin-bottom: 8px;
}

.zibll-da-card-stock {
    font-size: 13px;
    color: var(--muted-2-color);
    margin-bottom: 8px;
}

.zibll-da-card-stock b {
    font-size: 16px;
}

.zibll-da-progress {
    height: 6px;
    border-radius: 3px;
    background: var(--muted-bg-color);
    overflow: hidden;
    margin-bottom: 12px;
}

.zibll-da-progress i {
    display: block;
    height: 100%;
    border-radius: 3px;
    background: var(--focus-color);
}

.zibll-da-card-buts {
    display: flex;
    gap: 8px;
}

.zibll-da-card-buts .but {
    padding: 6px 10px;
    font-size: 13px;
}

/* 用户中心：浮窗 */
.zibll-da-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zibll-da-modal-box {
    width: 420px;
    height: 520px;
    max-width: 92vw;
    max-height: 82vh;
    background: var(--main-bg-color);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.zibll-da-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    font-weight: 600;
    color: var(--key-color);
    border-bottom: 1px solid var(--main-border-color);
}

.zibll-da-modal-close {
    cursor: pointer;
    color: var(--muted-2-color);
    font-size: 20px;
    line-height: 1;
}

.zibll-da-modal-body {
    padding: 16px;
    overflow-y: auto;
    color: var(--key-color);
}

.zibll-da-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.zibll-da-filter {
    flex: 1;
    text-align: center;
    padding: 5px 0;
    border-radius: 6px;
    background: var(--muted-bg-color);
    color: var(--muted-2-color);
    font-size: 13px;
}

.zibll-da-filter.active {
    background: var(--focus-color);
    color: #fff;
}

.zibll-da-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 14px;
}

.zibll-da-tab {
    flex: 1;
    text-align: center;
    padding: 6px 0;
    border-radius: 6px;
    background: var(--muted-bg-color);
    color: var(--muted-2-color);
    font-size: 14px;
}

.zibll-da-tab.active {
    background: var(--focus-color);
    color: #fff;
}

.zibll-da-invite {
    font-size: 16px;
    font-weight: 700;
    color: var(--key-color);
    line-height: 1.5;
}

.zibll-da-qrcode {
    width: 160px;
    height: 160px;
    background: #fff;
    padding: 6px;
    border-radius: 8px;
    display: inline-block;
}

.zibll-da-pending {
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 8px;
    background: var(--muted-bg-color);
}

.zibll-da-pending:last-child {
    margin-bottom: 0;
}

/* 已解锁时去掉主题隐藏内容块的外框，只保留内部内容 */
.hidden-box.show {
    background: none !important;
    border: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.hidden-box.show > .hidden-text {
    display: none !important;
}

.zibll-da-log-card {
    display: flex;
    align-items: center;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 8px;
    background: var(--muted-bg-color);
}

.zibll-da-log-card:last-child {
    margin-bottom: 0;
}

.zibll-da-log-avatar img {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.zibll-da-log-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--key-color);
}

.zibll-da-log-contact {
    font-size: 13px;
    color: var(--key-color);
    margin-top: 3px;
}

.zibll-da-log-time {
    margin-top: 3px;
}

.zibll-da-log-row {
    padding: 10px 0;
    border-bottom: 1px solid var(--main-border-color);
}

.zibll-da-log-row:last-child {
    border-bottom: none;
}
