/* ====== 视频号收益查询页 - 响应式样式 ====== */

/* 基础变量 */
:root {
    --primary: #409EFF;
    --success: #67C23A;
    --warning: #E6A23C;
    --danger: #F56C6C;
    --info: #909399;
    --text-primary: #303133;
    --text-regular: #606266;
    --text-secondary: #909399;
    --border-color: #DCDFE6;
    --bg-page: #f5f7fa;
    --bg-card: #ffffff;
    --shadow-card: 0 2px 12px 0 rgba(0, 0, 0, 0.06);
    --radius: 8px;
}

/* 页面基础 */
.query-body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: var(--bg-page);
    font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    color: var(--text-primary);
    display: flex;
    flex-direction: column;
}

.query-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 16px;
    width: 100%;
    box-sizing: border-box;
}

/* ====== 头部 ====== */
.query-header {
    background: linear-gradient(135deg, #409EFF 0%, #337ecc 100%);
    color: #fff;
    padding: 20px 0;
    box-shadow: 0 2px 8px rgba(64, 158, 255, 0.3);
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-brand .brand-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.3em;
}

.header-brand .brand-text {
    font-size: 1.4em;
    font-weight: 600;
    letter-spacing: 1px;
}

/* ====== 主内容区 ====== */
.query-main {
    flex: 1;
    padding: 24px 0 40px;
}

/* ====== 查询表单卡片 ====== */
.query-form-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    padding: 24px;
    margin-bottom: 20px;
}

.form-title {
    margin: 0 0 16px;
    font-size: 1.1em;
    font-weight: 600;
    color: var(--text-primary);
}

.query-form .form-row {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    flex-wrap: wrap;
}

.form-field {
    flex: 1;
    min-width: 140px;
}

.form-field-main {
    flex: 2;
    min-width: 200px;
}

.form-field-btn {
    flex: 0 0 auto;
    min-width: auto;
}

.form-field label {
    display: block;
    font-size: 0.85em;
    color: var(--text-regular);
    margin-bottom: 6px;
    font-weight: 500;
}

.form-field input[type="text"],
.form-field input[type="date"] {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    color: var(--text-primary);
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.form-field input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.15);
}

.btn-query {
    height: 40px;
    padding: 0 28px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 0.95em;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    white-space: nowrap;
}

.btn-query:hover {
    background: #337ecc;
}

.btn-query:active {
    background: #2d6eb3;
}

/* ====== 提示消息 ====== */
.alert {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 4px;
    margin-bottom: 16px;
    font-size: 0.9em;
}

.alert-error {
    background: #fef0f0;
    color: #f56c6c;
    border: 1px solid #fde2e2;
}

.alert-warning {
    background: #fdf6ec;
    color: #e6a23c;
    border: 1px solid #faecd8;
}

.alert-success {
    background: #f0f9eb;
    color: #67c23a;
    border: 1px solid #e1f3d8;
}

.alert-icon {
    font-size: 1.1em;
    flex-shrink: 0;
}

/* ====== 账号信息 ====== */
.account-info {
    margin-bottom: 16px;
    font-size: 0.9em;
    color: var(--text-regular);
}

.account-label {
    color: var(--text-secondary);
}

.account-name {
    font-weight: 600;
    color: var(--text-primary);
}

.account-id {
    color: var(--text-secondary);
    margin-left: 4px;
}

/* ====== 统计卡片 ====== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3em;
    flex-shrink: 0;
}

.stat-card-primary .stat-icon {
    background: rgba(64, 158, 255, 0.1);
    color: var(--primary);
}

.stat-card-success .stat-icon {
    background: rgba(103, 194, 58, 0.1);
    color: var(--success);
}

.stat-card-warning .stat-icon {
    background: rgba(230, 162, 60, 0.1);
    color: var(--warning);
}

.stat-card-info .stat-icon {
    background: rgba(144, 147, 153, 0.1);
    color: var(--info);
}

.stat-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.stat-value {
    font-size: 1.25em;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.stat-label {
    font-size: 0.78em;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ====== 结果卡片 ====== */
.result-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    margin-bottom: 20px;
}

.result-header {
    padding: 16px 20px;
    border-bottom: 1px solid #ebeef5;
}

.result-header h3 {
    margin: 0;
    font-size: 1em;
    font-weight: 600;
    color: var(--text-primary);
}

/* ====== 表格 ====== */
.table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 400px;
}

.data-table th,
.data-table td {
    padding: 12px 20px;
    text-align: left;
    font-size: 0.9em;
    border-bottom: 1px solid #ebeef5;
}

.data-table th {
    background: #fafafa;
    color: var(--text-secondary);
    font-weight: 600;
    white-space: nowrap;
}

.data-table td {
    color: var(--text-regular);
}

.data-table tbody tr:hover {
    background: #f5f7fa;
}

.amount-cell {
    font-weight: 600;
    color: var(--primary);
    font-family: "SF Mono", "Monaco", "Menlo", monospace;
}

.empty-cell {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px 20px !important;
}

/* ====== 分页 ====== */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 0;
}

.page-btn {
    display: inline-block;
    padding: 6px 14px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-regular);
    text-decoration: none;
    font-size: 0.85em;
    transition: all 0.2s;
    background: #fff;
}

.page-btn:hover:not(.disabled) {
    border-color: var(--primary);
    color: var(--primary);
}

.page-btn.disabled {
    color: #c0c4cc;
    cursor: not-allowed;
    background: #f5f7fa;
}

.page-info {
    font-size: 0.85em;
    color: var(--text-secondary);
    padding: 0 8px;
}

/* ====== 页脚 ====== */
.query-footer {
    padding: 20px 0;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.8em;
    border-top: 1px solid #ebeef5;
    background: #fff;
}

.query-footer p {
    margin: 0;
}

/* ====== 提现登记表单 ====== */
.withdrawal-form .form-group {
    margin-bottom: 16px;
}

.withdrawal-form .form-group label {
    display: block;
    font-size: 0.9em;
    font-weight: 500;
    color: var(--text-regular);
    margin-bottom: 6px;
}

.withdrawal-form .form-group .required {
    color: var(--danger);
    margin-left: 2px;
}

.withdrawal-form .form-group input,
.withdrawal-form .form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.95em;
    color: var(--text-primary);
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s;
    font-family: inherit;
}

.withdrawal-form .form-group input:focus,
.withdrawal-form .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.15);
}

/* 字段级错误状态 */
.withdrawal-form .form-group input.input-error {
    border-color: var(--danger);
    box-shadow: 0 0 0 2px rgba(245, 108, 108, 0.12);
}

.withdrawal-form .form-group input.input-error:focus {
    border-color: var(--danger);
    box-shadow: 0 0 0 2px rgba(245, 108, 108, 0.2);
}

.field-error {
    font-size: 0.82em;
    color: var(--danger);
    margin-top: 4px;
    min-height: 0;
    line-height: 1.4;
    transition: all 0.2s;
}

.field-error:empty {
    display: none;
}

.withdrawal-form .form-group textarea {
    resize: vertical;
    min-height: 70px;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.btn-submit {
    flex: 1;
    height: 44px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 1em;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-submit:hover {
    background: #337ecc;
}

.btn-submit:active {
    background: #2d6eb3;
}

.btn-cancel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 24px;
    height: 44px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-regular);
    text-decoration: none;
    font-size: 0.95em;
    transition: all 0.2s;
    background: #fff;
}

.btn-cancel:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* ====== 头部返回链接 ====== */
.header-back {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.9em;
    margin-left: auto;
    transition: color 0.2s;
}

.header-back:hover {
    color: #fff;
}

.query-header .query-container {
    display: flex;
    align-items: center;
}

/* ====== 底部快捷入口 ====== */
.quick-entry {
    padding: 16px 0 8px;
}

.quick-entry-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #409EFF 0%, #337ecc 100%);
    color: #fff;
    border-radius: var(--radius);
    text-decoration: none;
    font-size: 1em;
    font-weight: 500;
    box-shadow: 0 2px 8px rgba(64, 158, 255, 0.3);
    transition: all 0.2s;
}

.quick-entry-btn:hover {
    box-shadow: 0 4px 14px rgba(64, 158, 255, 0.4);
    transform: translateY(-1px);
}

.quick-entry-row {
    display: flex;
    gap: 12px;
}

.quick-entry-row .quick-entry-btn {
    flex: 1;
}

.quick-entry-btn-outline {
    background: #fff;
    color: var(--primary);
    border: 1px solid var(--primary);
    box-shadow: none;
}

.quick-entry-btn-outline:hover {
    background: rgba(64, 158, 255, 0.05);
    box-shadow: none;
    transform: none;
}

.quick-entry-icon {
    font-size: 1.2em;
}

/* ====== 徽章 ====== */
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.78em;
    font-weight: 500;
}

.badge-success {
    background: rgba(103, 194, 58, 0.12);
    color: var(--success);
}

.badge-warning {
    background: rgba(230, 162, 60, 0.12);
    color: var(--warning);
}

/* ====== 响应式断点 ====== */

/* 平板 (768px - 1023px) */
@media (max-width: 1023px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* 手机 (< 768px) */
@media (max-width: 767px) {
    .query-header {
        padding: 16px 0;
    }

    .header-brand .brand-text {
        font-size: 1.15em;
    }

    .query-main {
        padding: 16px 0 32px;
    }

    .query-form-card {
        padding: 16px;
    }

    .query-form .form-row {
        flex-direction: column;
        gap: 10px;
    }

    .form-field,
    .form-field-main {
        min-width: 100%;
        flex: none;
    }

    .form-field-btn {
        width: 100%;
    }

    .form-field-btn .btn-query {
        width: 100%;
    }

    .form-field label {
        display: none;
    }

    .form-field input[type="text"],
    .form-field input[type="date"] {
        height: 44px;
        font-size: 1em;
    }

    .form-field-btn label {
        display: block;
    }

    .btn-query {
        height: 44px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .stat-card {
        padding: 14px;
    }

    .stat-value {
        font-size: 1.15em;
    }

    .result-header {
        padding: 14px 16px;
    }

    .data-table th,
    .data-table td {
        padding: 10px 14px;
        font-size: 0.85em;
    }

    .pagination {
        flex-wrap: wrap;
        gap: 6px;
    }

    .page-btn {
        padding: 5px 10px;
        font-size: 0.8em;
    }
}

/* 小屏手机 (< 480px) */
@media (max-width: 479px) {
    .query-container {
        padding: 0 12px;
    }

    .header-brand .brand-icon {
        width: 34px;
        height: 34px;
        font-size: 1.1em;
    }

    .header-brand .brand-text {
        font-size: 1em;
    }

    .stat-icon {
        width: 38px;
        height: 38px;
        font-size: 1.1em;
    }

    .stat-value {
        font-size: 1.05em;
    }
}

/* ====== 提现状态查询 ====== */

/* 状态统计 */
.status-summary {
    text-align: center;
    margin-bottom: 20px;
    font-size: 0.95em;
}

.status-summary-label {
    color: var(--text-secondary);
}

.status-summary-count {
    color: var(--primary);
    font-weight: 700;
    font-size: 1.2em;
    margin: 0 4px;
}

/* 提现卡片 */
.withdrawal-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
    margin-bottom: 16px;
    overflow: hidden;
}

.wcard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px 12px;
}

.wcard-name {
    font-size: 1.05em;
    font-weight: 600;
    color: var(--text-primary);
}

.wcard-status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.82em;
    font-weight: 500;
}

.wcard-status-pending {
    background: rgba(230, 162, 60, 0.1);
    color: var(--warning);
}

.wcard-status-done {
    background: rgba(103, 194, 58, 0.1);
    color: var(--success);
}

/* 进度条 */
.wcard-progress {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 8px 24px 16px;
    gap: 0;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 60px;
    position: relative;
}

.progress-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #dcdfe6;
    border: 2px solid #dcdfe6;
    transition: all 0.3s;
}

.progress-step-active .progress-dot {
    background: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(64, 158, 255, 0.15);
}

.progress-label {
    font-size: 0.78em;
    color: var(--text-secondary);
    margin-top: 6px;
    white-space: nowrap;
}

.progress-step-active .progress-label {
    color: var(--primary);
    font-weight: 500;
}

.progress-time {
    font-size: 0.72em;
    color: var(--text-secondary);
    margin-top: 2px;
    white-space: nowrap;
}

.progress-line {
    flex: 1;
    height: 2px;
    background: #dcdfe6;
    margin-top: 7px;
    min-width: 30px;
    transition: background 0.3s;
}

.progress-line-active {
    background: var(--primary);
}

/* 卡片内容 */
.wcard-body {
    padding: 0 20px 16px;
    border-top: 1px solid #ebeef5;
    margin-top: 4px;
    padding-top: 12px;
}

.wcard-row {
    display: flex;
    align-items: baseline;
    margin-bottom: 8px;
    font-size: 0.88em;
}

.wcard-row:last-child {
    margin-bottom: 0;
}

.wcard-label {
    color: var(--text-secondary);
    width: 70px;
    flex-shrink: 0;
}

.wcard-value {
    color: var(--text-primary);
    word-break: break-all;
}

/* 底部操作按钮 */
.status-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    padding-bottom: 8px;
}

.status-action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 44px;
    background: linear-gradient(135deg, #409EFF 0%, #337ecc 100%);
    color: #fff;
    border-radius: var(--radius);
    text-decoration: none;
    font-size: 0.95em;
    font-weight: 500;
    box-shadow: 0 2px 8px rgba(64, 158, 255, 0.3);
    transition: all 0.2s;
}

.status-action-btn:hover {
    box-shadow: 0 4px 14px rgba(64, 158, 255, 0.4);
    transform: translateY(-1px);
}

.status-action-btn-secondary {
    background: #fff;
    color: var(--text-regular);
    border: 1px solid var(--border-color);
    box-shadow: none;
}

.status-action-btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: none;
    transform: none;
}

/* 查看状态入口 */
.status-entry {
    text-align: center;
    margin-top: 20px;
    padding: 16px;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow-card);
}

.status-entry-text {
    color: var(--text-secondary);
    font-size: 0.9em;
    margin-right: 8px;
}

.status-entry-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9em;
    font-weight: 500;
    transition: color 0.2s;
}

.status-entry-link:hover {
    color: #337ecc;
    text-decoration: underline;
}

/* 手机响应式补充 */
@media (max-width: 767px) {
    .wcard-header {
        padding: 14px 16px 10px;
    }

    .wcard-progress {
        padding: 6px 16px 14px;
    }

    .wcard-body {
        padding: 0 16px 14px;
    }

    .progress-step {
        min-width: 50px;
    }

    .progress-line {
        min-width: 20px;
    }

    .status-actions {
        flex-direction: column;
    }

    .quick-entry-row {
        flex-direction: column;
        gap: 10px;
    }
}
