/* 元宇宙前沿管理后台样式 */
:root {
    --primary-color: #0af;
    --secondary-color: #0052cc;
    --accent-color: #00f2ff;
    --dark-color: #050a30;
    --darker-color: #030821;
    --light-color: #f0f6ff;
    --success-color: #00c853;
    --warning-color: #ffab00;
    --danger-color: #ff1744;
    --text-color: #e0e6ff;
    --border-color: rgba(0, 170, 255, 0.3);
    --box-shadow: 0 4px 20px rgba(0, 170, 255, 0.15);
}

/* 基础样式 */
.admin-page {
    background: linear-gradient(135deg, var(--darker-color), var(--dark-color));
    color: var(--text-color);
    min-height: 100vh;
    margin: 0;
    font-family: 'Arial', sans-serif;
    position: relative;
    overflow-x: hidden;
}

.particles-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* 登录页面样式 */
.admin-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.login-box {
    background: rgba(5, 10, 48, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 40px;
    width: 100%;
    max-width: 450px;
    box-shadow: var(--box-shadow), 0 0 30px rgba(0, 170, 255, 0.2);
    animation: fadeIn 0.8s ease-out;
}

.logo-container {
    text-align: center;
    margin-bottom: 30px;
}

.glitch-text {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--primary-color);
    position: relative;
    margin: 0;
    text-shadow: 0 0 10px rgba(0, 170, 255, 0.5);
}

.glitch-text::before,
.glitch-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch-text::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1;
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-1 2s infinite linear alternate-reverse;
}

.glitch-text::after {
    left: -2px;
    text-shadow: -2px 0 #00fff9;
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim-2 2s infinite linear alternate-reverse;
}

@keyframes glitch-anim-1 {
    0% { clip: rect(18px, 9999px, 30px, 0); }
    20% { clip: rect(63px, 9999px, 78px, 0); }
    40% { clip: rect(94px, 9999px, 21px, 0); }
    60% { clip: rect(36px, 9999px, 69px, 0); }
    80% { clip: rect(14px, 9999px, 85px, 0); }
    100% { clip: rect(53px, 9999px, 47px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip: rect(63px, 9999px, 98px, 0); }
    20% { clip: rect(12px, 9999px, 43px, 0); }
    40% { clip: rect(89px, 9999px, 32px, 0); }
    60% { clip: rect(16px, 9999px, 94px, 0); }
    80% { clip: rect(75px, 9999px, 9px, 0); }
    100% { clip: rect(27px, 9999px, 59px, 0); }
}

.subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: var(--accent-color);
    margin-top: 5px;
    letter-spacing: 1px;
}

/* 表单样式 */
.admin-form .form-group {
    margin-bottom: 25px;
    position: relative;
}

.admin-form label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.95rem;
    color: var(--accent-color);
    font-weight: 500;
    letter-spacing: 0.5px;
}

.admin-form input {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s;
}

.admin-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 170, 255, 0.2);
    background: rgba(255, 255, 255, 0.08);
}

.form-highlight {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    width: 0;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.admin-form input:focus ~ .form-highlight {
    width: 100%;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    background: none;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(45deg, var(--secondary-color), var(--primary-color));
    color: white;
    border: none;
    width: 100%;
}

.btn-glow {
    position: relative;
    z-index: 1;
    overflow: hidden;
}

.btn-glow::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    z-index: -1;
    border-radius: 8px;
    animation: glowing 1.5s linear infinite;
    transition: opacity 0.3s ease-in-out;
    opacity: 0;
}

.btn-glow:hover::before {
    opacity: 1;
}

@keyframes glowing {
    0% { background-position: 0 0; }
    50% { background-position: 400% 0; }
    100% { background-position: 0 0; }
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 7px 14px rgba(0, 170, 255, 0.25);
}

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

/* 消息框样式 */
.message-box {
    padding: 12px;
    border-radius: 6px;
    margin-top: 20px;
    text-align: center;
    font-size: 0.95rem;
    opacity: 1;
    transition: opacity 0.3s;
}

.message-box.error {
    background: rgba(255, 23, 68, 0.15);
    border: 1px solid rgba(255, 23, 68, 0.3);
    color: #ff6b6b;
}

.message-box.success {
    background: rgba(0, 200, 83, 0.15);
    border: 1px solid rgba(0, 200, 83, 0.3);
    color: #69f0ae;
}

.message-box.hidden {
    opacity: 0;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 管理后台布局 */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: rgba(3, 8, 33, 0.95);
    border-right: 1px solid var(--border-color);
    padding: 20px 0;
    transition: all 0.3s;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.sidebar-header {
    padding: 0 20px 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 20px;
}

.sidebar-logo {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin: 0;
    padding: 10px 0;
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav-item {
    padding: 0;
    margin: 0;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.sidebar-nav-link:hover,
.sidebar-nav-link.active {
    background: rgba(0, 170, 255, 0.1);
    color: var(--primary-color);
}

.sidebar-nav-link i {
    margin-right: 10px;
    font-size: 1.2rem;
}

.main-content {
    flex: 1;
    padding: 20px 30px;
    transition: all 0.3s;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
}

.header-title {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin: 0;
}

.user-dropdown {
    position: relative;
}

.user-dropdown-btn {
    background: none;
    border: none;
    display: flex;
    align-items: center;
    color: var(--text-color);
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.3s;
}

.user-dropdown-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.user-dropdown-content {
    position: absolute;
    top: 100%;
    right: 0;
    background: rgba(5, 10, 48, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-shadow: var(--box-shadow);
    padding: 10px 0;
    min-width: 180px;
    z-index: 100;
    transform: translateY(10px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
}

.user-dropdown.open .user-dropdown-content {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.dropdown-item {
    display: block;
    padding: 8px 15px;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s;
}

.dropdown-item:hover {
    background: rgba(0, 170, 255, 0.1);
    color: var(--primary-color);
}

/* 卡片组件 */
.card {
    background: rgba(5, 10, 48, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: var(--box-shadow);
}

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

.card-title {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin: 0;
}

/* 表格样式 */
.table-container {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

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

.admin-table th {
    color: var(--accent-color);
    font-weight: 600;
    background: rgba(0, 170, 255, 0.05);
}

.admin-table tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.admin-table .actions {
    display: flex;
    gap: 10px;
}

.btn-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.3s;
}

.btn-edit {
    background: rgba(0, 171, 85, 0.1);
    color: var(--success-color);
}

.btn-edit:hover {
    background: rgba(0, 171, 85, 0.2);
}

.btn-delete {
    background: rgba(255, 23, 68, 0.1);
    color: var(--danger-color);
}

.btn-delete:hover {
    background: rgba(255, 23, 68, 0.2);
}

/* 表单控件 */
.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-col {
    flex: 1;
}

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

.form-control {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 170, 255, 0.2);
    background: rgba(255, 255, 255, 0.08);
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%230af' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    padding-right: 35px;
}

/* 网格布局 */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 25px;
}

.stat-card {
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--box-shadow);
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
}

.stat-card-primary {
    background: linear-gradient(45deg, rgba(0, 82, 204, 0.7), rgba(0, 170, 255, 0.7));
}

.stat-card-success {
    background: linear-gradient(45deg, rgba(0, 150, 63, 0.7), rgba(0, 200, 83, 0.7));
}

.stat-card-warning {
    background: linear-gradient(45deg, rgba(200, 131, 0, 0.7), rgba(255, 171, 0, 0.7));
}

.stat-card-danger {
    background: linear-gradient(45deg, rgba(200, 5, 45, 0.7), rgba(255, 23, 68, 0.7));
}

.stat-value {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.8;
}

/* 响应式适配 */
@media (max-width: 992px) {
    .sidebar {
        width: 70px;
        padding: 20px 0;
    }
    
    .sidebar-header {
        padding: 0 15px 20px;
    }
    
    .sidebar-logo {
        font-size: 1.2rem;
        text-align: center;
    }
    
    .sidebar-nav-link span {
        display: none;
    }
    
    .sidebar-nav-link i {
        margin-right: 0;
        font-size: 1.4rem;
    }
    
    .main-content {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .admin-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* 提示框 */
.tooltip {
    position: relative;
}

.tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 10px;
    background: rgba(5, 10, 48, 0.95);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.85rem;
    white-space: nowrap;
    z-index: 1000;
} 