/* ==========================================
   校友会管理系统 - 全局样式
   品牌色：主蓝 #1B5E8A | 辅助白色
   （样式对齐 v1 主系统后台风格）
   ========================================== */

/* CSS变量定义 */
:root {
    --primary-color: #1B5E8A;
    --primary-light: #E8F1F7;
    --primary-dark: #144A6E;
    --secondary-color: #ffffff;
    --background-color: #f4f6f8;
    --card-background: #ffffff;
    --text-primary: #2c3e50;
    --text-secondary: #7f8c8d;
    --border-color: #e5e8ec;
    --shadow-light: 0 2px 12px rgba(27, 94, 138, 0.08);
    --shadow-hover: 0 4px 16px rgba(27, 94, 138, 0.15);
    --transition: all 0.3s ease;
}

/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
    color: var(--text-primary);
    background-color: var(--background-color);
    line-height: 1.6;
    font-size: 14px;
}

/* 页面全局滚动条 */
html {
    scrollbar-width: thin;
    scrollbar-color: #c0c0c0 transparent;
}

html::-webkit-scrollbar {
    width: 6px;
}

html::-webkit-scrollbar-track {
    background: transparent;
}

html::-webkit-scrollbar-thumb {
    background: #c0c0c0;
    border-radius: 10px;
}

html::-webkit-scrollbar-thumb:hover {
    background: #a0a0a0;
}

/* ==========================================
   登录页面样式
   ========================================== */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.16), transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(27, 94, 138, 0.18), transparent 45%),
        linear-gradient(160deg, #144A6E, #1B5E8A 55%, #25699a);
    padding: 20px;
}

.login-container {
    width: 100%;
    max-width: 450px;
}

.login-box {
    background: var(--card-background);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    border-top: 6px solid #1B5E8A;
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.logo {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
}

.login-header h1 {
    font-size: 24px;
    color: var(--primary-color);
    margin-bottom: 8px;
    font-weight: 700;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 14px;
}

.login-form {
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"] {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 15px;
    transition: var(--transition);
    outline: none;
}

.form-group input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 94, 138, 0.12);
}

.remember-me {
    margin-bottom: 24px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.login-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #1B5E8A, #25699a);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.login-btn:hover {
    background: linear-gradient(135deg, #144A6E, #1B5E8A);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(27, 94, 138, 0.35);
}

.login-btn:active {
    transform: translateY(0);
}

.login-footer {
    text-align: center;
    color: var(--text-secondary);
    font-size: 13px;
}

/* 提示信息样式 */
.alert {
    padding: 14px 18px;
    border-radius: 8px;
    margin-bottom: 24px;
    font-size: 14px;
    display: flex;
    align-items: center;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-error {
    background-color: #fdecea;
    color: #b3423a;
    border: 1px solid #e6a49c;
}

.alert-success {
    background-color: #e8f8ef;
    color: #1e7a46;
    border: 1px solid #b7e3c6;
}

.alert::before {
    content: '';
    width: 18px;
    height: 18px;
    margin-right: 12px;
    flex-shrink: 0;
}

.alert-error::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b3423a' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cline x1='15' y1='9' x2='9' y2='15'/%3E%3Cline x1='9' y1='9' x2='15' y2='15'/%3E%3C/svg%3E");
    background-size: cover;
}

.alert-success::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231e7a46' stroke-width='2'%3E%3Cpath d='M22 11.08V12a10 10 0 1 1-5.93-9.14'/%3E%3Cpolyline points='22 4 12 14.01 9 11.01'/%3E%3C/svg%3E");
    background-size: cover;
}

/* ==========================================
   管理后台页面样式
   ========================================== */

.admin-page {
    display: flex;
    min-height: 100vh;
}

/* 左侧导航栏 */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, var(--primary-dark), var(--primary-color) 60%, #25699a);
    color: white;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 1000;
}

.sidebar-header {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-logo {
    width: 60px;
    height: 60px;
    margin-bottom: 15px;
}

.sidebar-header h2 {
    font-size: 18px;
    font-weight: 600;
}

.sidebar-nav {
    flex: 1;
    padding: 12px 10px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.2) transparent;
}

.sidebar-nav::-webkit-scrollbar {
    width: 5px;
}

.sidebar-nav::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.2);
    border-radius: 10px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.35);
}

.nav-list {
    list-style: none;
}

.nav-item {
    margin-bottom: 5px;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 11px 14px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
    border-radius: 8px;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.12);
    color: white;
}

.nav-item.active .nav-link {
    background: rgba(255, 255, 255, 0.22);
    color: white;
    font-weight: 600;
    border-left-color: rgba(255, 255, 255, 0.9);
}

.nav-link .icon {
    width: 20px;
    height: 20px;
    margin-right: 12px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.logout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.logout-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    text-decoration: none;
}

.logout-btn .icon {
    width: 18px;
    height: 18px;
    margin-right: 8px;
}

/* 主内容区域 */
.main-content {
    flex: 1;
    margin-left: 260px;
    display: flex;
    flex-direction: column;
}

/* 顶部栏 */
.top-bar {
    background: var(--card-background);
    height: 60px;
    padding: 0 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.top-bar-left {
    display: flex;
    align-items: center;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
}

.top-bar-right {
    display: flex;
    align-items: center;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-name {
    font-size: 15px;
    color: var(--text-primary);
    font-weight: 600;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-avatar svg {
    width: 24px;
    height: 24px;
    color: white;
}

/* 内容区域 */
.content-area {
    padding: 24px;
    flex: 1;
}

/* 欢迎卡片 */
.welcome-card {
    background: var(--card-background);
    border-radius: 10px;
    padding: 40px;
    box-shadow: var(--shadow-light);
    border: 1px solid var(--border-color);
    margin-bottom: 30px;
    overflow: hidden;
    position: relative;
}

.welcome-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
}

.welcome-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.welcome-text {
    flex: 1;
}

.welcome-text h2 {
    font-size: 28px;
    color: var(--primary-color);
    margin-bottom: 20px;
    font-weight: 700;
}

.welcome-text p {
    font-size: 16px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    line-height: 1.8;
}

.welcome-text p:last-child {
    margin-bottom: 0;
}

.welcome-image {
    flex-shrink: 0;
}

.welcome-image svg {
    width: 180px;
    height: 180px;
}

/* 信息卡片 */
.info-card {
    background: var(--card-background);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow-light);
    border: 1px solid var(--border-color);
}

.info-card h3 {
    font-size: 18px;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--primary-light);
}

.info-content {
    color: var(--text-secondary);
    line-height: 1.8;
}

.info-content p {
    margin-bottom: 10px;
}

.info-content p:last-child {
    margin-bottom: 0;
}

/* ==========================================
   下拉菜单样式
   ========================================== */

/* 下拉菜单容器 */
.nav-dropdown {
    position: relative;
}

.nav-dropdown .nav-link {
    cursor: pointer;
}

.nav-dropdown .dropdown-arrow {
    width: 16px;
    height: 16px;
    margin-left: auto;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.nav-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
}

/* 下拉子菜单 */
.dropdown-menu {
    list-style: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    background: rgba(0, 0, 0, 0.15);
}

.nav-dropdown.open > .dropdown-menu {
    max-height: 600px;
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu li a {
    display: flex;
    align-items: center;
    padding: 7px 20px 7px 56px;
    color: rgba(255, 255, 255, 0.65);
    text-decoration: none;
    font-size: 13px;
    transition: all 0.2s ease;
    position: relative;
}

.dropdown-menu li a::before {
    content: '';
    position: absolute;
    left: 36px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transition: all 0.2s ease;
}

.dropdown-menu li a:hover {
    color: white;
    background: rgba(255, 255, 255, 0.08);
}

.dropdown-menu li a:hover::before {
    background: #ffffff;
}

.dropdown-menu li.active a {
    color: white;
    background: rgba(255, 255, 255, 0.12);
}

.dropdown-menu li.active a::before {
    background: #ffffff;
    width: 6px;
    height: 6px;
}

.dropdown-menu li a .icon {
    width: 13px;
    height: 13px;
    margin-right: 8px;
    flex-shrink: 0;
    opacity: 0.8;
}

.dropdown-menu li a:hover .icon,
.dropdown-menu li.active a .icon {
    opacity: 1;
}

/* 嵌套下拉菜单 */
.dropdown-menu .nav-dropdown > .dropdown-link {
    display: flex;
    align-items: center;
    padding: 7px 20px 7px 56px;
    color: rgba(255, 255, 255, 0.65);
    text-decoration: none;
    font-size: 13px;
    cursor: pointer;
    position: relative;
}
.dropdown-menu .nav-dropdown > .dropdown-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}
.dropdown-menu .nav-dropdown .nested-arrow {
    width: 14px;
    height: 14px;
    margin-left: auto;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}
.dropdown-menu .nav-dropdown.open .nested-arrow {
    transform: rotate(180deg);
}
.dropdown-menu .nav-dropdown .nested-menu {
    list-style: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    background: rgba(0, 0, 0, 0.2);
}
.dropdown-menu .nav-dropdown.open .nested-menu {
    max-height: 250px;
}
.nested-menu li a {
    padding-left: 76px !important;
}

/* ==========================================
   数据表格样式
   ========================================== */

.data-card {
    background: var(--card-background);
    border-radius: 10px;
    box-shadow: var(--shadow-light);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.data-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 24px;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(90deg, #fff, var(--primary-light));
}

.data-card-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-color);
}

.btn-primary {
    padding: 8px 18px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    transition: var(--transition);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(27, 94, 138, 0.25);
}

.btn-primary svg {
    width: 16px;
    height: 16px;
}

.btn-secondary {
    padding: 8px 18px;
    background: #fff;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    transition: var(--transition);
}

.btn-secondary:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.btn-secondary svg {
    width: 16px;
    height: 16px;
}

/* ==========================================
   筛选栏样式
   ========================================== */
.filter-bar {
    padding: 14px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}

/* 搜索框 */
.filter-search {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.filter-search-icon {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
    pointer-events: none;
    z-index: 1;
}

.filter-input-search {
    width: 100%;
    max-width: 480px;
    padding: 9px 14px 9px 42px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    color: var(--text-primary);
    background: var(--background-color);
    outline: none;
    transition: var(--transition);
}

.filter-input-search:focus {
    border-color: var(--primary-color);
    background: white;
    box-shadow: 0 0 0 3px rgba(27, 94, 138, 0.1);
}

/* 筛选按钮 */
.btn-filter-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 20px;
    background: white;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-filter-toggle svg {
    width: 16px;
    height: 16px;
}

.btn-filter-toggle:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-filter-toggle.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* 筛选弹出面板 */
.filter-popup {
    position: absolute;
    top: calc(100% - 8px);
    right: 24px;
    width: 620px;
    max-width: calc(100vw - 48px);
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    box-shadow: 0 8px 30px rgba(27, 94, 138, 0.12);
    z-index: 100;
    display: none;
}

.filter-popup.active {
    display: block;
    animation: filterSlideIn 0.2s ease;
}

@keyframes filterSlideIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.filter-popup-body {
    padding: 20px 24px 16px;
}

.filter-row {
    display: flex;
    gap: 16px;
    margin-bottom: 14px;
}

.filter-row:last-child {
    margin-bottom: 0;
}

.filter-group {
    flex: 1;
    min-width: 0;
}

.filter-label {
    display: block;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 6px;
    font-weight: 500;
}

.filter-select,
.filter-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    color: var(--text-primary);
    background: var(--background-color);
    outline: none;
    transition: var(--transition);
}

.filter-select {
    cursor: pointer;
}

.filter-input {
    cursor: text;
}

.filter-select:focus,
.filter-input:focus {
    border-color: var(--primary-color);
    background: white;
    box-shadow: 0 0 0 2px rgba(27, 94, 138, 0.1);
}

.filter-popup-footer {
    padding: 12px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.btn-filter-apply,
.btn-filter-reset {
    padding: 8px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-filter-apply {
    background: var(--primary-color);
    color: white;
}

.btn-filter-apply:hover {
    background: var(--primary-dark);
}

.btn-filter-reset {
    background: var(--background-color);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-filter-reset:hover {
    background: var(--border-color);
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .filter-bar {
        flex-wrap: wrap;
    }
    .filter-search {
        flex: 1 1 100%;
        order: 1;
    }
    .btn-filter-toggle {
        order: 2;
    }
    .filter-popup {
        left: 24px;
        right: 24px;
        width: auto;
    }
    .filter-row {
        flex-direction: column;
        gap: 10px;
    }
}

.data-table-wrap {
    overflow-x: auto;
    padding: 0 24px 24px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 700px;
}

.data-table thead th {
    padding: 11px 16px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary-color);
    background: var(--primary-light);
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.data-table tbody td {
    padding: 11px 16px;
    font-size: 14px;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.data-table tbody tr:hover {
    background: #fafcfe;
}

.data-table .actions {
    white-space: nowrap;
}

.btn-sm {
    padding: 5px 12px;
    border: none;
    border-radius: 5px;
    font-size: 12px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.btn-sm + .btn-sm {
    margin-left: 8px;
}

.btn-view {
    background: var(--primary-light);
    color: var(--primary-color);
}

.btn-view:hover { background: #d3e4f0; }

.btn-edit {
    background: #e3f2fd;
    color: #1565c0;
}

.btn-edit:hover { background: #bbdefb; }

.btn-delete {
    background: #fdecea;
    color: #c0392b;
}

.btn-delete:hover { background: #f8d7d3; }

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state svg {
    width: 80px;
    height: 80px;
    margin-bottom: 16px;
    opacity: 0.4;
}

.empty-state p {
    font-size: 15px;
}

/* ==========================================
   弹窗样式
   ========================================== */

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.2s ease;
}

.modal-overlay.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 560px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 12px 40px rgba(27, 94, 138, 0.25);
    animation: modalIn 0.3s ease;
}

@keyframes modalIn {
    from { opacity: 0; transform: translateY(-30px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 24px;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(90deg, #fff, var(--primary-light));
}

.modal-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-color);
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    cursor: pointer;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition);
}

.modal-close:hover { background: rgba(27, 94, 138, 0.08); color: var(--primary-color); }

.modal-body {
    padding: 24px;
    max-height: 60vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #c0c0c0 transparent;
}

.modal-body::-webkit-scrollbar {
    width: 5px;
}

.modal-body::-webkit-scrollbar-track {
    background: transparent;
}

.modal-body::-webkit-scrollbar-thumb {
    background: #c0c0c0;
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: #a0a0a0;
}

.modal-footer {
    padding: 14px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.btn-cancel {
    padding: 8px 20px;
    background: #f0f0f0;
    color: var(--text-primary);
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-cancel:hover { background: #e0e0e0; }

.btn-submit {
    padding: 8px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-submit:hover { background: var(--primary-dark); }

.btn-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.form-group textarea,
.form-group select {
    width: 100%;
    padding: 9px 14px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: var(--transition);
    outline: none;
}

.form-group textarea { resize: vertical; min-height: 80px; }
.form-group select { background: white; appearance: auto; }

.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 94, 138, 0.1);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group input[type="datetime-local"],
.form-group input[type="file"] {
    width: 100%;
    padding: 9px 14px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    transition: var(--transition);
    outline: none;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="tel"]:focus,
.form-group input[type="number"]:focus,
.form-group input[type="date"]:focus,
.form-group input[type="datetime-local"]:focus,
.form-group input[type="file"]:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 94, 138, 0.1);
}

/* 并排表单行 */
.form-row {
    display: flex;
    gap: 16px;
}

.form-row .form-group {
    flex: 1;
}

.detail-table { width: 100%; }
.detail-table tr { border-bottom: 1px solid #f5f5f5; }
.detail-table td { padding: 12px 0; font-size: 14px; vertical-align: top; }
.detail-table td:first-child { width: 110px; color: var(--text-secondary); font-weight: 500; padding-right: 16px; white-space: nowrap; }
.detail-table td:last-child { color: var(--text-primary); }

/* ==========================================
   详情弹窗 - 分区卡片样式
   ========================================== */
.detail-section {
    margin-bottom: 20px;
}

.detail-section:last-child {
    margin-bottom: 0;
}

.detail-section-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary-color);
    padding-bottom: 10px;
    margin-bottom: 12px;
    border-bottom: 1px solid var(--primary-light);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 基本信息网格 */
.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 20px;
}

.detail-item {
    display: flex;
    padding: 6px 0;
}

.detail-item label {
    width: 70px;
    flex-shrink: 0;
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-item span {
    font-size: 14px;
    color: var(--text-primary);
}

/* 联系方式列表 */
.detail-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-list-item {
    display: flex;
    padding: 8px 0;
}

.detail-list-label {
    width: 70px;
    flex-shrink: 0;
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-list-value {
    font-size: 14px;
    color: var(--text-primary);
}

/* 个人简介文本 */
.detail-bio {
    padding: 0;
    font-size: 14px;
    color: var(--text-primary);
    line-height: 1.8;
}

/* 经历卡片 */
.detail-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
    transition: var(--transition);
}

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

.detail-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(27, 94, 138, 0.08);
}

.detail-card-header {
    padding: 12px 16px;
    background: linear-gradient(135deg, var(--primary-light) 0%, #f9fafb 100%);
    font-size: 14px;
    font-weight: 600;
    color: var(--primary-dark);
    border-bottom: 1px solid #dce8f1;
}

.detail-card-accent .detail-card-header {
    background: linear-gradient(135deg, #fef9e7 0%, #fdf6f0 100%);
    color: #b7791f;
    border-bottom-color: #f0e4cc;
}

.detail-card-body {
    padding: 10px 16px 14px;
}

.detail-card-row {
    display: flex;
    padding: 4px 0;
    font-size: 13px;
}

.detail-card-label {
    width: 70px;
    flex-shrink: 0;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-card-row span:last-child {
    color: var(--text-primary);
}

.detail-card-desc {
    margin-top: 8px;
    padding: 10px 12px;
    background: white;
    border-radius: 6px;
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    border: 1px solid #f0f0f0;
}

/* 兴趣标签 */
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.detail-tag {
    display: inline-block;
    padding: 4px 12px;
    background: #e8f8ef;
    color: #27ae60;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
}

@media (max-width: 480px) {
    .detail-grid {
        grid-template-columns: 1fr;
    }
}

/* LOGO 上传组件 */
.logo-upload-wrap {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.logo-upload-wrap input[type="file"] {
    padding: 8px 12px;
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    background: var(--background-color);
    transition: var(--transition);
}

.logo-upload-wrap input[type="file"]:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.logo-preview {
    position: relative;
    display: inline-block;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    max-width: 160px;
}

.logo-preview img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.logo-remove-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255, 0, 0, 0.7);
    color: #fff;
    border: none;
    font-size: 16px;
    line-height: 22px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.logo-remove-btn:hover {
    background: rgba(255, 0, 0, 0.9);
}

/* 列表缩略图 */
.table-thumb {
    vertical-align: middle;
}

/* 标签导航 */
.tab-nav {
    display: flex;
    gap: 4px;
    background: #eef1f4;
    border-radius: 8px;
    padding: 4px;
}

.tab-btn {
    padding: 8px 20px;
    border: none;
    border-radius: 6px;
    background: transparent;
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn.active {
    background: #fff;
    color: var(--primary-color);
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.tab-btn:hover:not(.active) {
    color: var(--text-primary);
}

/* 状态徽章 */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.badge-warning { background: #fef3c7; color: #d97706; }
.badge-success { background: #e8f8ef; color: #27ae60; }
.badge-danger  { background: #fdecea; color: #c0392b; }

/* 通过按钮 */
.btn-success {
    background: #e8f8ef;
    color: #27ae60;
}

.btn-success:hover {
    background: #27ae60;
    color: #fff;
}

/* 审核通过/拒绝按钮 */
.btn-approve {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border: 1px solid #27ae60;
    border-radius: 4px;
    background: #e8f8ef;
    color: #27ae60;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.btn-approve:hover { background: #27ae60; color: #fff; }

.btn-reject {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border: 1px solid #c0392b;
    border-radius: 4px;
    background: #fdecea;
    color: #c0392b;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.btn-reject:hover { background: #c0392b; color: #fff; }

/* 图片上传区域 */
.upload-area {
    position: relative;
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    padding: 12px;
    text-align: center;
    transition: border-color 0.2s;
}
.upload-area:hover { border-color: var(--primary-color); }
.upload-area input[type="file"] {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    opacity: 0;
    cursor: pointer;
}
.upload-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #9ca3af;
    cursor: pointer;
    padding: 16px 0;
}
.upload-placeholder svg { width: 36px; height: 36px; }
.upload-placeholder span { font-size: 13px; }
.upload-preview {
    position: relative;
    display: inline-block;
}
.upload-preview img {
    max-width: 100%;
    max-height: 180px;
    border-radius: 6px;
    object-fit: contain;
}
.preview-remove {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #ef4444;
    color: #fff;
    border: none;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 图片预览弹窗 */
.image-preview-container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.image-preview-container img {
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.image-preview-close {
    position: fixed;
    top: 20px;
    right: 30px;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    font-size: 28px;
    line-height: 38px;
    text-align: center;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.2s;
}

.image-preview-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* 分页 */
.pagination-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    border-top: 1px solid var(--border-color);
}

.pagination-info {
    font-size: 13px;
    color: var(--text-secondary);
}

.pagination-btns {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination-btn {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: #fff;
    font-size: 13px;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}

.pagination-btn:hover:not(.disabled):not(.active) {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: rgba(27, 94, 138, 0.05);
}

.pagination-btn.active {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

.pagination-btn.disabled {
    color: var(--border-color);
    cursor: not-allowed;
}

.pagination-dots {
    padding: 0 4px;
    color: var(--text-secondary);
    font-size: 13px;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }
    
    .main-content {
        margin-left: 220px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 60px;
    }
    
    .sidebar-header h2,
    .nav-link span,
    .logout-btn span,
    .dropdown-arrow {
        display: none;
    }
    
    .sidebar-header {
        padding: 20px 10px;
    }
    
    .sidebar-logo {
        width: 40px;
        height: 40px;
    }
    
    .nav-link {
        justify-content: center;
        padding: 14px 10px;
    }
    
    .nav-link .icon {
        margin-right: 0;
    }
    
    .dropdown-menu li a {
        padding: 11px 10px;
        justify-content: center;
    }
    
    .dropdown-menu li a span {
        display: none;
    }
    
    .dropdown-menu li a .icon {
        margin-right: 0;
    }
    
    .dropdown-menu li a::before {
        display: none;
    }
    
    .logout-btn {
        padding: 12px 10px;
    }
    
    .logout-btn .icon {
        margin-right: 0;
    }
    
    .main-content {
        margin-left: 60px;
    }
    
    .welcome-content {
        flex-direction: column;
        text-align: center;
    }
    
    .welcome-image {
        order: -1;
    }
}

@media (max-width: 480px) {
    .login-box {
        padding: 30px 20px;
    }
    
    .login-header h1 {
        font-size: 22px;
    }
    
    .content-area {
        padding: 20px;
    }
    
    .welcome-card {
        padding: 25px;
    }
    
    .welcome-text h2 {
        font-size: 22px;
    }
    
    .welcome-image svg {
        width: 120px;
        height: 120px;
    }
}

/* ==========================================
   授权到期红色横幅（距到期 ≤ 7 天时全局显示）
   ========================================== */
.lic-expire-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 3000;
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 46px;
    padding: 10px 24px;
    background: #e74c3c;
    color: #ffffff;
    font-size: 14px;
    line-height: 1.5;
    box-shadow: 0 2px 12px rgba(192, 57, 43, 0.28);
}
.lic-expire-banner .icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}
.lic-expire-banner strong {
    color: #ffffff;
    font-weight: 700;
}

/* ==========================================
   首页服务额度仪表盘（短信 + 邮件）
   ========================================== */
.quota-dashboard {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}
@media (max-width: 900px) {
    .quota-dashboard { grid-template-columns: 1fr; }
}
.quota-dashboard-head {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}
.quota-refresh-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    background: #fff;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.quota-refresh-btn:hover {
    background: var(--primary-light);
}
.quota-refresh-btn svg {
    width: 14px;
    height: 14px;
}
.quota-card {
    background: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 24px;
    box-shadow: var(--shadow-light);
}
.quota-card-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.quota-card-head .icon {
    width: 24px;
    height: 24px;
    color: var(--primary-color);
}
.quota-card-head h2 {
    font-size: 18px;
    color: var(--text-primary);
    font-weight: 700;
}
.quota-card-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}
.quota-card-stats {
    display: flex;
    gap: 28px;
}
.quota-stat { text-align: center; }
.quota-num {
    font-size: 30px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}
.quota-num.ok { color: #005C45; }
.quota-num.danger { color: #e74c3c; }
.quota-num.muted { color: #7f8c8d; }
.quota-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}
.quota-card-sync {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    font-size: 12px;
    color: var(--text-secondary);
}

/* ==========================================
   txt 批量导入结果提示
   ========================================== */
.import-result {
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.6;
}
.import-result.success { color: #005C45; }
.import-result.warn { color: #b7791f; }
.import-result.error { color: #e74c3c; }
.import-file {
    font-size: 13px;
    color: var(--text-primary);
}
.import-file input[type="file"] {
    font-size: 13px;
}
