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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.header {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: end;
    align-items: end;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #1890ff;
    text-decoration: none;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin-left: auto;
}

.nav-link {
    color: #666;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s;
}

.nav-link:hover {
    color: #1890ff;
    background-color: #f0f7ff;
}

.nav-link.active {
    color: #1890ff;
    background-color: #f0f7ff;
}

/* 主要内容区域 */
.main-content {
    min-height: calc(100vh - 140px);
    padding: 2rem 0;
}

/* 卡片样式 */
.card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.card-header {
    border-bottom: 1px solid #eee;
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #333;
}

/* 表格样式 */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.table th {
    font-weight: 600;
    color: #666;
    background-color: #fafafa;
}

.table tr:hover {
    background-color: #fafafa;
}

/* 表单样式 */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #1890ff;
    box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-primary {
    background-color: #1890ff;
    color: white;
}

.btn-primary:hover {
    background-color: #096dd9;
}

.btn-secondary {
    background-color: #f5f5f5;
    color: #666;
}

.btn-secondary:hover {
    background-color: #e8e8e8;
}

.btn-success {
    background-color: #52c41a;
    color: white;
}

.btn-success:hover {
    background-color: #389e0d;
}

.btn-danger {
    background-color: #ff4d4f;
    color: white;
}

.btn-danger:hover {
    background-color: #d9363e;
}

.btn-block {
    display: block;
    width: 100%;
}

/* 状态标签 */
.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.875rem;
    font-weight: 500;
}

.status-pending {
    background-color: #fff7e6;
    color: #fa8c16;
}

.status-accepted {
    background-color: #e6f7ff;
    color: #1890ff;
}

.status-accepted:hover {
    background: #D4E8FF;
}

.status-waiting {
    background-color: #f6ffed;
    color: #52c41a;
}

.status-canceled {
    background-color: #fff2f0;
    color: #414d4f;
}

.status-pending {
    background: #FFF0E6;
    color: #CC7B2E;
}

.status-pending:hover {
    background: #FFE7D6;
}

.status-success {
    background: #F6FFED;
    color: #52C41A;
}

.status-success:hover {
    background: #E8F8D9;
}

.status-failed {
    background: #FFF2F0;
    color: #FF4D4F;
}

.status-failed:hover {
    background: #FFE6E3;
}

/* 页脚样式 */
.footer {
    background-color: #fff;
    border-top: 1px solid #eee;
    padding: 1.5rem 0;
    text-align: center;
    color: #666;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header-content {
        flex-direction: row;
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: end;
    }

    .nav-menu {
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 0.5rem;
        flex-direction: row;
        margin-left: auto;
        width: 100%;
    }

    .container {
        padding: 0 15px;
    }

    .table {
        display: block;
        overflow-x: auto;
    }
}

/* 工具类 */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mt-1 {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.mt-3 {
    margin-top: 1.5rem;
}

.mt-4 {
    margin-top: 2rem;
}

.mb-1 {
    margin-bottom: 0.5rem;
}

.mb-2 {
    margin-bottom: 1rem;
}

.mb-3 {
    margin-bottom: 1.5rem;
}

.mb-4 {
    margin-bottom: 2rem;
}

.p-1 {
    padding: 0.5rem;
}

.p-2 {
    padding: 1rem;
}

.p-3 {
    padding: 1.5rem;
}

.p-4 {
    padding: 2rem;
}

.d-flex {
    display: flex;
}

.justify-between {
    justify-content: space-between;
}

.align-center {
    align-items: center;
}

.gap-1 {
    gap: 0.5rem;
}

.gap-2 {
    gap: 1rem;
}

.gap-3 {
    gap: 1.5rem;
}

/* 用户信息样式 */
.nav-user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #1890ff;
    font-weight: 500;
}

.nav-user-name {
    font-size: 1rem;
}

.nav-user-role {
    font-size: 0.875rem;
    color: #666;
    opacity: 0.8;
}

/* 响应式设计中的用户信息 */
@media (max-width: 768px) {
    .nav-user-info {
        order: 0;
        width: auto;
        justify-content: center;
        padding: 0.5rem 1rem;
        border-bottom: none;
        margin-bottom: 0;
        border-left: 1px solid #eee;
        margin-left: 0.5rem;
    }

    .nav-menu {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 0.5rem;
        margin-left: auto;
        width: 100%;
    }
}

/* 超小屏幕优化 */
@media (max-width: 480px) {
    .nav-menu {
        gap: 0.25rem;
    }

    .nav-link {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
    }

    .nav-user-info {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
        margin-left: 0.25rem;
        border-left: 1px solid #eee;
    }

    .nav-user-name {
        font-size: 0.9rem;
    }

    .nav-user-role {
        font-size: 0.8rem;
    }
}

/* ==================== 通知消息样式 ==================== */

/* 通知消息样式 */
.notification-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #FFFFFF;
    border-radius: 16px;
    padding: 16px 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border-left: 6px solid #52C41A;
    max-width: 320px;
    z-index: 2000;
    animation: slideInRight 0.3s ease;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.notification-toast.urge {
    border-left-color: #FF9500;
}

.notification-toast.order_accepted {
    border-left-color: #1677FF;
}

.notification-toast.order_cancelled {
    border-left-color: #FF4D4F;
}

.notification-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-size: 14px;
    font-weight: 700;
    color: #1E2A3A;
    margin-bottom: 4px;
}

.notification-message {
    font-size: 13px;
    color: #4A5A72;
    line-height: 1.4;
}

.notification-close {
    background: none;
    border: none;
    font-size: 18px;
    color: #C0C8D4;
    cursor: pointer;
    padding: 0;
    margin: 0;
    flex-shrink: 0;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Toast消息样式 */
.toast-msg {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 10px 20px;
    border-radius: 60px;
    font-size: 13px;
    z-index: 1100;
    white-space: nowrap;
}

.toast-msg.error {
    background: rgba(220, 53, 69, 0.9);
}

/* 模态框动画 */
@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ==================== 站点Logo样式 ==================== */

/* 站点Logo容器 */
.site-logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid #eee;
    width: 100%;
}

/* 站点Logo */
.site-logo {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1890ff;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: 1px;
    transition: all 0.3s ease;
    text-align: center;
    display: block;
    width: 100%;
}

.site-logo:hover {
    color: #096dd9;
    transform: scale(1.05);
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.15);
}

/* 响应式设计中的Logo */
@media (max-width: 768px) {
    .site-logo {
        font-size: 2rem;
    }

    .site-logo-container {
        margin-bottom: 1.5rem;
        padding: 1rem 0;
    }
}

@media (max-width: 480px) {
    .site-logo {
        font-size: 1.75rem;
    }

    .site-logo-container {
        margin-bottom: 1rem;
        padding: 0.75rem 0;
    }
}

/* ==================== Logo统计弹框样式 ==================== */

/* Logo统计弹框 */
.logo-stats-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.logo-stats-modal.show {
    display: flex;
}

/* 弹框遮罩层 */
.logo-stats-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

/* 弹框内容 */
.logo-stats-modal-content {
    position: relative;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 420px;
    width: 90%;
    animation: modalSlideIn 0.3s ease;
    overflow: hidden;
}

/* 弹框头部 */
.logo-stats-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #1890ff 0%, #096dd9 100%);
    color: #fff;
}

.logo-stats-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.logo-stats-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.logo-stats-close:hover {
    opacity: 1;
}

/* 弹框主体 */
.logo-stats-body {
    padding: 24px 20px;
}

/* 统计网格 */
.logo-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

/* 单个统计项 */
.logo-stat-item {
    text-align: center;
    padding: 16px 8px;
    border-radius: 12px;
    background: #f8f9fa;
    transition: transform 0.2s, box-shadow 0.2s;
}

.logo-stat-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 统计数值 */
.logo-stat-value {
    font-size: 28px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 6px;
}

/* 统计标签 */
.logo-stat-label {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

/* 各类型统计项颜色 */
.logo-stat-item.stat-new-user {
    background: linear-gradient(135deg, #e6f7ff 0%, #bae7ff 100%);
}

.logo-stat-item.stat-new-user .logo-stat-value {
    color: #1890ff;
}

.logo-stat-item.stat-old-user {
    background: linear-gradient(135deg, #f6ffed 0%, #d9f7be 100%);
}

.logo-stat-item.stat-old-user .logo-stat-value {
    color: #52c41a;
}

.logo-stat-item.stat-failed {
    background: linear-gradient(135deg, #fff2f0 0%, #ffccc7 100%);
}

.logo-stat-item.stat-failed .logo-stat-value {
    color: #ff4d4f;
}

.logo-stat-item.stat-pending {
    background: linear-gradient(135deg, #fff7e6 0%, #ffe7ba 100%);
}

.logo-stat-item.stat-pending .logo-stat-value {
    color: #fa8c16;
}

/* 响应式设计 - 小屏幕 */
@media (max-width: 480px) {
    .logo-stats-modal-content {
        max-width: 95%;
    }

    .logo-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .logo-stat-item {
        padding: 14px 6px;
    }

    .logo-stat-value {
        font-size: 24px;
    }

    .logo-stat-label {
        font-size: 11px;
    }
}