/**
 * 小航云计算 - 主样式表
 * 网站: https://cloud.znvd.cn
 * 邮箱: 3664643596@qq.com
 * 基于魔方财务风格
 */

/* ==================== 基础样式 ==================== */
:root {
    --primary-color: #1890ff;
    --primary-hover: #40a9ff;
    --primary-active: #096dd9;
    --success-color: #52c41a;
    --warning-color: #faad14;
    --error-color: #f5222d;
    --text-primary: #262626;
    --text-secondary: #595959;
    --text-muted: #8c8c8c;
    --border-color: #d9d9d9;
    --bg-primary: #f5f5f5;
    --bg-white: #ffffff;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.15);
    --radius: 4px;
    --radius-lg: 8px;
    --sidebar-width: 260px;
    --sidebar-collapsed: 80px;
    --header-height: 64px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    font-size: 14px;
    line-height: 1.5715;
    color: var(--text-primary);
    background-color: var(--bg-primary);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: var(--primary-hover);
}

img {
    max-width: 100%;
    height: auto;
}

/* ==================== 布局样式 ==================== */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* 侧边栏 */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: #001529;
    z-index: 1000;
    transition: width 0.3s;
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar.collapsed {
    width: var(--sidebar-collapsed);
}

.sidebar-header {
    height: var(--header-height);
    display: flex;
    align-items: center;
    padding: 0 24px;
    background: #002140;
    color: #fff;
}

.sidebar-logo {
    width: 32px;
    height: 32px;
    margin-right: 12px;
}

.sidebar-title {
    font-size: 18px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 1;
    transition: opacity 0.3s;
}

.sidebar.collapsed .sidebar-title {
    opacity: 0;
    width: 0;
}

/* 汉堡菜单按钮 */
.hamburger-btn {
    position: fixed;
    left: 20px;
    top: 20px;
    z-index: 1001;
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    transition: all 0.3s;
}

.hamburger-btn span {
    display: block;
    width: 20px;
    height: 2px;
    background: #fff;
    transition: all 0.3s;
}

.hamburger-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger-btn.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* 侧边栏菜单 */
.sidebar-menu {
    padding: 16px 0;
}

.menu-item {
    position: relative;
}

.menu-link {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    color: rgba(255, 255, 255, 0.65);
    transition: all 0.3s;
    cursor: pointer;
}

.menu-link:hover,
.menu-item.active .menu-link {
    color: #fff;
    background: var(--primary-color);
}

.menu-icon {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.menu-text {
    white-space: nowrap;
    opacity: 1;
    transition: opacity 0.3s;
}

.sidebar.collapsed .menu-text {
    opacity: 0;
    width: 0;
}

.menu-arrow {
    margin-left: auto;
    transition: transform 0.3s;
}

.menu-item.open .menu-arrow {
    transform: rotate(90deg);
}

/* 子菜单 */
.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    background: #000c17;
}

.menu-item.open .submenu {
    max-height: 500px;
}

.submenu .menu-link {
    padding-left: 56px;
}

/* 主内容区 */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    transition: margin-left 0.3s;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.sidebar.collapsed + .main-content {
    margin-left: var(--sidebar-collapsed);
}

/* 顶部导航 */
.header {
    height: var(--header-height);
    background: var(--bg-white);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* 公告栏 */
.announcement-bar {
    background: linear-gradient(90deg, #1890ff 0%, #36cfc9 100%);
    color: #fff;
    padding: 8px 24px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.announcement-bar i {
    font-size: 14px;
}

.announcement-bar a {
    color: #fff;
    text-decoration: underline;
}

/* 页面内容 */
.page-content {
    flex: 1;
    padding: 24px;
}

/* ==================== 组件样式 ==================== */

/* 按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5715;
    border: 1px solid transparent;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}

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

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

.btn-success {
    background: var(--success-color);
    color: #fff;
    border-color: var(--success-color);
}

.btn-warning {
    background: var(--warning-color);
    color: #fff;
    border-color: var(--warning-color);
}

.btn-danger {
    background: var(--error-color);
    color: #fff;
    border-color: var(--error-color);
}

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

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

.btn-lg {
    padding: 12px 24px;
    font-size: 16px;
    
}

.btn-sm {
    padding: 4px 12px;
    font-size: 12px;
}

.btn-block {
    width: 100%;
}

/* 卡片 */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    margin-bottom: 24px;
}

.card-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.card-body {
    padding: 24px;
}

.card-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    background: #fafafa;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

/* 表单 */
.form-group {
    margin-bottom: 20px;
}

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

.form-label.required::after {
    content: '*';
    color: var(--error-color);
    margin-left: 4px;
}

.form-control {
    width: 100%;
    padding: 8px 12px;
    font-size: 14px;
    line-height: 1.5715;
    color: var(--text-primary);
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    transition: all 0.3s;
}

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

.form-control::placeholder {
    color: var(--text-muted);
}

.form-control:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%238c8c8c' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.form-text {
    margin-top: 4px;
    font-size: 12px;
    color: var(--text-muted);
}

.form-error {
    margin-top: 4px;
    font-size: 12px;
    color: var(--error-color);
}

/* 输入框组 */
.input-group {
    display: flex;
    align-items: stretch;
}

.input-group .form-control {
    border-radius: var(--radius) 0 0 var(--radius);
}

.input-group .btn {
    border-radius: 0 var(--radius) var(--radius) 0;
}

.input-group-text {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: #f5f5f5;
    border: 1px solid var(--border-color);
    border-radius: var(--radius) 0 0 var(--radius);
    color: var(--text-secondary);
}

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

.table th,
.table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.table th {
    font-weight: 600;
    color: var(--text-primary);
    background: #fafafa;
}

.table tbody tr:hover {
    background: #f5f5f5;
}

.table-striped tbody tr:nth-child(odd) {
    background: #fafafa;
}

.table-bordered {
    border: 1px solid var(--border-color);
}

.table-bordered th,
.table-bordered td {
    border: 1px solid var(--border-color);
}

/* 标签 */
.tag {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    font-size: 12px;
    border-radius: var(--radius);
    font-weight: 500;
}

.tag-primary {
    background: #e6f7ff;
    color: var(--primary-color);
}

.tag-success {
    background: #f6ffed;
    color: var(--success-color);
}

.tag-warning {
    background: #fffbe6;
    color: var(--warning-color);
}

.tag-error {
    background: #fff2f0;
    color: var(--error-color);
}

/* 徽章 */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 10px;
    background: var(--error-color);
    color: #fff;
}

/* 分页 */
.pagination {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
    margin-top: 24px;
}

.pagination-item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.3s;
}

.pagination-item:hover,
.pagination-item.active {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 消息提示 */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-success {
    background: #f6ffed;
    border: 1px solid #b7eb8f;
    color: #389e0d;
}

.alert-warning {
    background: #fffbe6;
    border: 1px solid #ffe58f;
    color: #d48806;
}

.alert-error {
    background: #fff2f0;
    border: 1px solid #ffccc7;
    color: #cf1322;
}

.alert-info {
    background: #e6f7ff;
    border: 1px solid #91d5ff;
    color: #096dd9;
}

/* 模态框 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 16px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-muted);
}

.modal-body {
    padding: 24px;
}

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

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 空状态 */
.empty {
    text-align: center;
    padding: 48px 24px;
}

.empty-icon {
    font-size: 64px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.empty-title {
    font-size: 16px;
    color: var(--text-primary);
    margin-bottom: 8px;
}

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

/* ==================== 页面样式 ==================== */

/* 登录/注册页面 */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1890ff 0%, #36cfc9 100%);
    padding: 24px;
}

.auth-box {
    width: 100%;
    max-width: 440px;
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 40px;
}

.auth-header {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
}

.auth-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 8px;
}

.auth-subtitle {
    color: var(--text-secondary);
}

.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

/* 仪表盘 */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.primary {
    background: #e6f7ff;
    color: var(--primary-color);
}

.stat-icon.success {
    background: #f6ffed;
    color: var(--success-color);
}

.stat-icon.warning {
    background: #fffbe6;
    color: var(--warning-color);
}

.stat-icon.error {
    background: #fff2f0;
    color: var(--error-color);
}

.stat-info {
    flex: 1;
}

.stat-value {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
}

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

/* 产品卡片 */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.product-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.product-image {
    height: 160px;
    background: linear-gradient(135deg, #1890ff 0%, #36cfc9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 48px;
}

.product-body {
    padding: 20px;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.product-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.product-price {
    font-size: 20px;
    font-weight: 600;
    color: var(--error-color);
}

.product-price span {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: normal;
}

/* 购物车 */
.cart-item {
    display: flex;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
    gap: 16px;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    background: #f5f5f5;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: var(--primary-color);
}

.cart-item-info {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.cart-item-meta {
    font-size: 12px;
    color: var(--text-secondary);
}

.cart-item-price {
    font-size: 16px;
    font-weight: 600;
    color: var(--error-color);
}

.cart-summary {
    background: #fafafa;
    padding: 24px;
    border-radius: var(--radius);
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.cart-summary-total {
    display: flex;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
    font-size: 18px;
    font-weight: 600;
}

/* 实例列表 */
.host-item {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
}

.host-status {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.host-status.active {
    background: var(--success-color);
    box-shadow: 0 0 0 3px rgba(82, 196, 26, 0.2);
}

.host-status.pending {
    background: var(--warning-color);
}

.host-status.suspended {
    background: var(--error-color);
}

.host-info {
    flex: 1;
}

.host-name {
    font-weight: 600;
    margin-bottom: 4px;
}

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

.host-actions {
    display: flex;
    gap: 8px;
}

/* 工单 */
.ticket-item {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.ticket-id {
    font-weight: 600;
    color: var(--primary-color);
}

.ticket-title {
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 8px;
}

.ticket-preview {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.ticket-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
}

/* 账单 */
.invoice-item {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
}

.invoice-icon {
    width: 48px;
    height: 48px;
    background: #f5f5f5;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.invoice-icon.unpaid {
    background: #fff2f0;
    color: var(--error-color);
}

.invoice-icon.paid {
    background: #f6ffed;
    color: var(--success-color);
}

.invoice-info {
    flex: 1;
}

.invoice-number {
    font-weight: 600;
    margin-bottom: 4px;
}

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

.invoice-amount {
    font-size: 18px;
    font-weight: 600;
    text-align: right;
}

.invoice-amount.unpaid {
    color: var(--error-color);
}

.invoice-amount.paid {
    color: var(--success-color);
}

.invoice-date {
    font-size: 12px;
    color: var(--text-muted);
}

/* 用户菜单 */
.user-menu {
    position: relative;
}

.user-menu-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: var(--radius);
    transition: background 0.3s;
}

.user-menu-trigger:hover {
    background: #f5f5f5;
}

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

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: var(--bg-white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s;
}

.user-menu:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-primary);
    transition: background 0.3s;
}

.user-dropdown-item:hover {
    background: #f5f5f5;
}

.user-dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 8px 0;
}

/* 步骤条 */
.steps {
    display: flex;
    margin-bottom: 32px;
}

.step {
    flex: 1;
    text-align: center;
    position: relative;
}

.step::after {
    content: '';
    position: absolute;
    top: 16px;
    left: 50%;
    width: 100%;
    height: 2px;
    background: var(--border-color);
}

.step:last-child::after {
    display: none;
}

.step-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-white);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    position: relative;
    z-index: 1;
    font-weight: 600;
    color: var(--text-muted);
}

.step.active .step-icon {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.step.completed .step-icon {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

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

.step.active .step-title {
    color: var(--primary-color);
    font-weight: 500;
}

/* 时间线 */
.timeline {
    position: relative;
    padding-left: 24px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}

.timeline-item {
    position: relative;
    padding-bottom: 24px;
}

.timeline-dot {
    position: absolute;
    left: -20px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--bg-white);
    border: 2px solid var(--primary-color);
}

.timeline-content {
    background: var(--bg-white);
    padding: 16px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.timeline-time {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.timeline-title {
    font-weight: 600;
    margin-bottom: 4px;
}

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

/* ==================== 响应式样式 ==================== */
@media (max-width: 768px) {
    :root {
        --sidebar-width: 0;
    }
    
    .sidebar {
        transform: translateX(-100%);
        width: 260px;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .hamburger-btn {
        display: flex;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .product-grid {
        grid-template-columns: 1fr;
    }
    
    .host-item,
    .invoice-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .cart-item {
        flex-wrap: wrap;
    }
    
    .auth-box {
        padding: 24px;
    }
    
    .page-content {
        padding: 16px;
    }
    
    .header {
        padding: 0 16px;
    }
    
    .table-responsive {
        overflow-x: auto;
    }
    
    .modal-content {
        width: 95%;
        margin: 16px;
    }
}

@media (min-width: 769px) {
    .hamburger-btn {
        display: none;
    }
}

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

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

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

.float-left {
    float: left;
}

.float-right {
    float: right;
}

.clearfix::after {
    content: '';
    display: table;
    clear: both;
}

.d-flex {
    display: flex;
}

.d-block {
    display: block;
}

.d-none {
    display: none;
}

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

.justify-center {
    justify-content: center;
}

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

.flex-wrap {
    flex-wrap: wrap;
}

.gap-2 {
    gap: 8px;
}

.gap-3 {
    gap: 12px;
}

.gap-4 {
    gap: 16px;
}

.m-0 {
    margin: 0;
}

.mt-2 {
    margin-top: 8px;
}

.mt-3 {
    margin-top: 12px;
}

.mt-4 {
    margin-top: 16px;
}

.mb-2 {
    margin-bottom: 8px;
}

.mb-3 {
    margin-bottom: 12px;
}

.mb-4 {
    margin-bottom: 16px;
}

.ml-2 {
    margin-left: 8px;
}

.mr-2 {
    margin-right: 8px;
}

.p-2 {
    padding: 8px;
}

.p-3 {
    padding: 12px;
}

.p-4 {
    padding: 16px;
}

.w-full {
    width: 100%;
}

.h-full {
    height: 100%;
}

.text-primary {
    color: var(--primary-color);
}

.text-success {
    color: var(--success-color);
}

.text-warning {
    color: var(--warning-color);
}

.text-error {
    color: var(--error-color);
}

.text-muted {
    color: var(--text-muted);
}

.bg-white {
    background: var(--bg-white);
}

.bg-primary {
    background: var(--primary-color);
}

.font-bold {
    font-weight: 600;
}

.font-lg {
    font-size: 16px;
}

.font-sm {
    font-size: 12px;
}

.rounded {
    border-radius: var(--radius);
}

.shadow {
    box-shadow: var(--shadow);
}

.cursor-pointer {
    cursor: pointer;
}

/* 隐藏滚动条但保留滚动功能 */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* 文本截断 */
.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 产品中心响应式 */
@media (max-width: 768px) {
    .products-container {
        grid-template-columns: 1fr !important;
    }
    
    .products-container > div:first-child {
        order: 2;
    }
    
    .products-container > div:last-child {
        order: 1;
    }
    
    .products-container .card {
        position: static !important;
    }
}
