/**
 * 个人中心 / 会员登录 — 响应式布局（手机 + 电脑）
 */

body.member-page {
    background: #f4f5f7;
    min-height: 100vh;
}

body.member-page.member-auth-page {
    background: linear-gradient(160deg, #fef2f2 0%, #fff7ed 45%, #f8fafc 100%);
}

.member-shell {
    width: 100%;
    margin: 0 auto;
    padding: 1rem 1rem 2.5rem;
}

.member-shell--auth {
    max-width: 28rem;
    padding-top: 1.5rem;
}

.member-shell--standard {
    max-width: 48rem;
}

.member-shell--wide {
    max-width: 72rem;
}

.member-shell--dashboard {
    max-width: 80rem;
    padding: 1.25rem 1.25rem 3rem;
}

@media (min-width: 768px) {
    .member-shell {
        padding-left: 1.75rem;
        padding-right: 1.75rem;
    }
    .member-shell--auth {
        padding-top: 2.5rem;
    }
}

/* ---------- 个人中心：侧栏 + 主区 ---------- */
.member-center-layout {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 992px) {
    .member-center-layout {
        flex-direction: row;
        align-items: flex-start;
        gap: 1.75rem;
    }
}

.member-sidebar {
    flex-shrink: 0;
}

@media (min-width: 992px) {
    .member-sidebar {
        width: 15.5rem;
        position: sticky;
        top: 1rem;
    }
}

.member-sidebar-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
    overflow: hidden;
}

.member-sidebar-head {
    padding: 1.15rem 1.25rem;
    background: linear-gradient(135deg, #991b1b 0%, #dc2626 55%, #b91c1c 100%);
    color: #fff;
}

.member-sidebar-head h2 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.member-sidebar-head p {
    margin: 0.35rem 0 0;
    font-size: 0.78rem;
    opacity: 0.88;
    line-height: 1.4;
}

.member-nav {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 0.35rem;
    padding: 0.65rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.member-nav::-webkit-scrollbar {
    display: none;
}

@media (min-width: 992px) {
    .member-nav {
        flex-direction: column;
        overflow: visible;
        padding: 0.5rem;
        gap: 0.15rem;
    }
}

.member-nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.55rem 0.85rem;
    border-radius: 0.55rem;
    text-decoration: none;
    color: #4b5563;
    font-size: 0.88rem;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s;
}

@media (min-width: 992px) {
    .member-nav a {
        font-size: 0.92rem;
        padding: 0.65rem 0.9rem;
    }
}

.member-nav a:hover {
    background: #f9fafb;
    color: #c41e3a;
}

.member-nav a.is-active {
    background: #fef2f2;
    color: #c41e3a;
    font-weight: 600;
}

.member-nav-badge {
    display: inline-flex;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.35rem;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #dc2626;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
}

.member-sidebar-foot {
    border-top: 1px solid #f3f4f6;
    padding: 0.65rem 0.75rem;
}

.member-sidebar-foot a {
    display: block;
    text-align: center;
    padding: 0.55rem;
    font-size: 0.85rem;
    color: #6b7280;
    text-decoration: none;
    border-radius: 0.5rem;
}

.member-sidebar-foot a:hover {
    background: #fef2f2;
    color: #b91c1c;
}

.member-main {
    flex: 1;
    min-width: 0;
}

.member-page-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #111827;
    margin: 0 0 1rem;
    letter-spacing: 0.01em;
}

@media (min-width: 992px) {
    .member-page-title {
        font-size: 1.55rem;
        margin-bottom: 1.25rem;
    }
}

/* ---------- 卡片 / 表单（个人中心内覆盖全站偏大样式） ---------- */
.member-page .card {
    border: 1px solid #e5e7eb;
    border-radius: 0.85rem;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
    padding: 1.25rem 1.35rem;
    margin-bottom: 1rem;
}

.member-page .card:last-child {
    margin-bottom: 0;
}

.member-page .card-title {
    font-size: 1.15rem;
    margin-bottom: 1rem;
}

.member-page .form-label {
    font-size: 0.88rem;
    margin-bottom: 0.35rem;
}

.member-page .form-input,
.member-page .form-select {
    font-size: 0.95rem;
    padding: 0.65rem 0.85rem;
    border-width: 1px;
    border-radius: 0.5rem;
}

.member-page .btn-primary {
    font-size: 0.95rem;
    padding: 0.7rem 1.25rem;
    width: auto;
    min-width: 8rem;
}

.member-page .btn-primary.btn-block {
    width: 100%;
}

.member-page .text-muted {
    color: #6b7280;
    font-size: 0.88rem;
    line-height: 1.55;
}

.member-page .text-hint {
    color: #9ca3af;
    font-size: 0.82rem;
}

/* ---------- 提示条 ---------- */
.member-page .alert {
    padding: 0.75rem 1rem;
    border-radius: 0.55rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

.member-page .alert-error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.member-page .alert-success {
    background: #ecfdf5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

.member-page .alert-warn {
    background: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
}

.member-banner {
    border: 1px solid #fde68a;
    background: #fffbeb;
    border-radius: 0.75rem;
    padding: 0.85rem 1.1rem;
    margin-bottom: 1rem;
    font-size: 0.92rem;
    line-height: 1.5;
}

.member-banner a {
    color: #c41e3a;
    font-weight: 600;
    text-decoration: none;
}

.member-banner a:hover {
    text-decoration: underline;
}

/* ---------- 首页仪表盘 ---------- */
.mc-hero {
    background: linear-gradient(135deg, #991b1b 0%, #dc2626 50%, #b91c1c 100%);
    color: #fff;
    border-radius: 1rem;
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.25rem;
    box-shadow: 0 12px 32px rgba(185, 28, 28, 0.22);
}

@media (min-width: 992px) {
    .mc-hero {
        padding: 2rem 2.25rem;
    }
    .mc-hero-name {
        font-size: 1.75rem !important;
    }
}

.mc-hero-greet {
    font-size: 0.85rem;
    opacity: 0.9;
    margin-bottom: 0.25rem;
}

.mc-hero-name {
    font-size: 1.45rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 0.35rem;
}

.mc-hero-meta {
    font-size: 0.82rem;
    opacity: 0.88;
}

.mc-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

@media (min-width: 640px) {
    .mc-stats {
        grid-template-columns: repeat(4, 1fr);
    }
}

.mc-stat {
    background: #fff;
    border: 1px solid #fecaca;
    border-radius: 0.75rem;
    padding: 0.85rem 1rem;
    text-align: center;
}

.mc-stat-num {
    font-size: 1.5rem;
    font-weight: 700;
    color: #c41e3a;
    line-height: 1.2;
}

.mc-stat-label {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 0.2rem;
}

.mc-sections {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

@media (min-width: 768px) {
    .mc-sections {
        grid-template-columns: 1fr 1fr;
    }
    .mc-section-wide {
        grid-column: 1 / -1;
    }
}

@media (min-width: 1200px) {
    .mc-sections {
        grid-template-columns: repeat(3, 1fr);
    }
    .mc-section-wide {
        grid-column: 1 / -1;
    }
}

.mc-section-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.85rem;
    padding: 1rem 1.15rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    height: 100%;
}

.mc-section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #f3f4f6;
}

.mc-section-head h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
}

.mc-section-link {
    font-size: 0.78rem;
    color: #c41e3a;
    text-decoration: none;
    white-space: nowrap;
    font-weight: 600;
}

.mc-section-link:hover {
    text-decoration: underline;
}

.mc-kv {
    display: grid;
    grid-template-columns: 4.5rem 1fr;
    gap: 0.25rem 0.5rem;
    font-size: 0.82rem;
    margin-bottom: 0.35rem;
}

.mc-kv dt {
    color: #9ca3af;
}

.mc-kv dd {
    color: #374151;
    margin: 0;
    word-break: break-all;
}

.mc-mini-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid #f9fafb;
    font-size: 0.82rem;
}

.mc-mini-row:last-child {
    border-bottom: none;
}

.mc-mini-title {
    flex: 1;
    color: #374151;
    line-height: 1.35;
}

.mc-mini-status {
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.mc-level-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    background: #f9fafb;
    font-size: 0.75rem;
    margin: 0.2rem 0.25rem 0.2rem 0;
}

.mc-empty {
    font-size: 0.82rem;
    color: #9ca3af;
}

/* ---------- 登录 / 注册 Tab ---------- */
.member-page .auth-mode-tabs {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 0.5rem;
    flex-wrap: wrap;
}

.member-page .auth-mode-tabs button,
.member-page .auth-mode-tabs a {
    border: none;
    background: none;
    padding: 0.45rem 0.75rem;
    cursor: pointer;
    color: #6b7280;
    font-size: 0.9rem;
    border-radius: 0.35rem;
    text-decoration: none;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.member-page .auth-mode-tabs button.active,
.member-page .auth-mode-tabs a.active {
    color: #c41e3a;
    background: #fef2f2;
    font-weight: 600;
}

.member-page .sms-row {
    display: flex;
    gap: 0.5rem;
}

.member-page .sms-row .form-input {
    flex: 1;
}

.member-page .btn-sms {
    flex-shrink: 0;
    white-space: nowrap;
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
    border-radius: 0.5rem;
    border: 1px solid #c41e3a;
    background: #fff;
    color: #c41e3a;
    cursor: pointer;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.member-page .btn-sms:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.member-auth-links {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.9rem;
}

.member-auth-links a {
    color: #c41e3a;
    text-decoration: none;
}

.member-auth-links a:hover {
    text-decoration: underline;
}

/* ---------- 表格 ---------- */
.member-table {
    width: 100%;
    font-size: 0.88rem;
    border-collapse: collapse;
}

.member-table th,
.member-table td {
    padding: 0.55rem 0.65rem;
    text-align: left;
    border-bottom: 1px solid #f3f4f6;
}

.member-table thead th {
    background: #fafafa;
    font-weight: 600;
    color: #374151;
}

@media (min-width: 768px) {
    .member-table {
        font-size: 0.92rem;
    }
    .member-table th,
    .member-table td {
        padding: 0.65rem 0.85rem;
    }
}

/* ---------- 等级荣誉块 ---------- */
.mc-achievement-block {
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 1rem 1.15rem;
    margin-bottom: 1rem;
}

.mc-achievement-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    gap: 0.5rem;
}

.mc-medal-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 0.5rem 0;
}

.mc-medal-item {
    text-align: center;
    width: 4.5rem;
}

.mc-medal-item img {
    width: 3rem;
    height: 3rem;
    object-fit: contain;
}

.mc-medal-item span {
    display: block;
    font-size: 0.7rem;
    color: #6b7280;
    margin-top: 0.2rem;
    line-height: 1.2;
}

.sync-badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.sync-synced {
    background: #d1fae5;
    color: #065f46;
}

.sync-failed {
    background: #fee2e2;
    color: #991b1b;
}

.sync-pending {
    background: #fef3c7;
    color: #92400e;
}

/* ---------- 论坛记录卡片 ---------- */
.zscx-review-record {
    border: 1px solid #e5e7eb;
    border-radius: 0.65rem;
    padding: 0.85rem 1rem;
    margin-bottom: 0.75rem;
    background: #fff;
}

.zscx-review-record--title-only {
    background: #fafafa;
    padding: 0.55rem 0.85rem;
    margin-bottom: 0.5rem;
}

.zscx-review-record--title-only a {
    color: #374151;
    text-decoration: none;
    font-size: 0.92rem;
    line-height: 1.4;
}

.zscx-review-record--title-only a:hover {
    color: #c41e3a;
}

.zscx-review-record-head {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    align-items: flex-start;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.zscx-review-record-title {
    font-weight: 600;
    font-size: 0.95rem;
    line-height: 1.35;
    color: #111827;
}

.zscx-review-record-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
    gap: 0.35rem 0.75rem;
    margin: 0.5rem 0;
    font-size: 0.82rem;
    color: #4b5563;
}

.zscx-review-progress {
    height: 6px;
    background: #f3f4f6;
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 0.35rem;
}

.zscx-review-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #fecaca, #c41e3a);
    border-radius: 999px;
}

.zscx-forum-records-panel h3 {
    font-size: 1rem;
    margin-bottom: 0.35rem;
}

.zscx-rev-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 1rem;
}

.zscx-rev-tabs a {
    text-decoration: none;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    font-size: 0.82rem;
    background: #f3f4f6;
    color: #4b5563;
}

.zscx-rev-tabs a.is-active {
    background: #c41e3a;
    color: #fff;
}

/* ---------- 审核中心 ---------- */
.member-review-wrap {
    max-width: 100%;
}

.member-review-wrap .review-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.member-review-wrap .review-tabs a {
    padding: 0.4rem 0.85rem;
    background: #fff;
    border-radius: 6px;
    text-decoration: none;
    color: #374151;
    border: 1px solid #e5e7eb;
    font-size: 0.9rem;
}

.member-review-wrap .review-tabs a.active {
    background: #fef2f2;
    color: #c41e3a;
    border-color: #fecaca;
}

.member-review-wrap .review-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    font-size: 0.9rem;
}

.member-review-wrap .review-table th,
.member-review-wrap .review-table td {
    padding: 0.65rem 0.75rem;
    border-bottom: 1px solid #f3f4f6;
    text-align: left;
}

.member-review-wrap .review-table th {
    background: #fafafa;
}

.member-review-wrap pre.snap {
    background: #f9fafb;
    padding: 0.75rem;
    overflow: auto;
    max-height: 240px;
    font-size: 0.8rem;
    border-radius: 0.5rem;
}

.member-review-wrap .btn-ok {
    background: #059669;
    color: #fff;
    border: none;
    padding: 0.45rem 0.9rem;
    border-radius: 6px;
    cursor: pointer;
    margin-right: 0.35rem;
}

.member-review-wrap .btn-no {
    background: #dc2626;
    color: #fff;
    border: none;
    padding: 0.45rem 0.9rem;
    border-radius: 6px;
    cursor: pointer;
}

.badge-st {
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.st-reviewing, .st-submitted {
    background: #fef3c7;
    color: #92400e;
}

.st-passed {
    background: #d1fae5;
    color: #065f46;
}

.st-rejected {
    background: #fee2e2;
    color: #991b1b;
}

.member-notify-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
}

.member-notify-list li {
    padding: 0.65rem 0;
    border-bottom: 1px solid #f3f4f6;
}

.member-notify-list li.is-unread {
    background: #fffbeb;
    margin: 0 -1rem;
    padding-left: 1rem;
    padding-right: 1rem;
}

.mc-ecert-share {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 0.5rem;
}

.mc-ecert-share-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.mc-ecert-share-row .form-input {
    flex: 1 1 12rem;
    min-width: 0;
    font-size: 0.85rem;
    padding: 0.45rem 0.65rem;
}

.mc-ecert-share-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.5rem;
}

.mc-ecert-share .btn-sm {
    font-size: 0.78rem;
    padding: 0.35rem 0.65rem;
}
