:root {
    --primary: #111111;
    --secondary: #333333;
    --accent: #0066ff;
    --light: #f5f5f5;
}

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

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: #ffffff;
    color: var(--primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.navbar-fixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.nav-shadow {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

#main-content {
    padding-top: 80px;
    min-height: calc(100vh - 80px);
}

.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-accent { color: var(--accent); }
.bg-primary { background-color: var(--primary); }
.bg-secondary { background-color: var(--secondary); }
.bg-accent { background-color: var(--accent); }
.bg-light { background-color: var(--light); }

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

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

.font-sans { font-family: 'Inter', system-ui, sans-serif; }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }

.text-2xl { font-size: 1.5rem; }
.text-xl { font-size: 1.25rem; }
.text-lg { font-size: 1.125rem; }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }

.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-24 { padding-top: 6rem; padding-bottom: 6rem; }
.py-32 { padding-top: 8rem; padding-bottom: 8rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }

.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-20 { margin-bottom: 5rem; }
.ml-auto { margin-left: auto; }
.mr-4 { margin-right: 1rem; }
.mx-auto { margin-left: auto; margin-right: auto; }

.flex { display: flex; }
.hidden { display: none; }
.block { display: block; }
.inline-block { display: inline-block; }

.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }

#mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 1001;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

#mobile-menu.active {
    transform: translateX(0);
}

#menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 900;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* 用户下拉菜单样式 */
.user-dropdown {
    position: relative;
}

.user-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: background-color 0.3s ease;
}

.user-dropdown-trigger:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.user-avatar-trigger-inner {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    vertical-align: middle;
}

.user-avatar-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    border: 2px solid var(--accent);
}

.user-avatar-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1;
}

.user-avatar-placeholder--stack {
    position: absolute;
    inset: 0;
    width: 40px;
    height: 40px;
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.user-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 200px;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

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

.user-dropdown-header {
    padding: 1rem 1.25rem 0.75rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.user-dropdown-name {
    font-weight: 600;
    color: var(--primary);
    font-size: 1rem;
}

.user-dropdown-divider {
    height: 1px;
    background-color: rgba(0, 0, 0, 0.05);
    margin: 0;
}

.user-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    color: var(--secondary);
    text-decoration: none;
    transition: all 0.2s ease;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font-size: 0.875rem;
}

.user-dropdown-item:hover {
    background-color: rgba(0, 102, 255, 0.05);
    color: var(--accent);
}

.user-dropdown-item i {
    font-size: 1rem;
    width: 1.25rem;
}

.user-dropdown-item-warning {
    color: #f59e0b;
}

.user-dropdown-logout {
    color: #dc3545;
}

.user-dropdown-logout:hover {
    background-color: rgba(220, 53, 69, 0.05);
    color: #dc3545;
}

/* 移动端菜单样式补充 */
.mobile-menu {
    padding-top: 80px;
    padding-bottom: 20px;
    overflow-y: auto;
}

.mobile-menu-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.mobile-user-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.mobile-user-avatar {
    position: relative;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    overflow: hidden;
    background-color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-user-avatar img,
.mobile-user-avatar .mobile-user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.mobile-user-avatar-initial {
    font-size: 1.35rem;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.mobile-user-avatar-initial--stack {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background-color: var(--accent);
}

.mobile-user-avatar i {
    font-size: 1.5rem;
    color: white;
}

.mobile-user-info {
    flex: 1;
}

.mobile-user-name {
    font-weight: 600;
    color: var(--primary);
    font-size: 1rem;
}

.mobile-user-email {
    font-size: 0.875rem;
    color: var(--secondary);
}

.mobile-menu-nav {
    padding: 0.5rem 0;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.5rem;
    color: var(--secondary);
    text-decoration: none;
    transition: background-color 0.2s ease;
    font-size: 1rem;
}

.mobile-menu-item:hover {
    background-color: rgba(0, 102, 255, 0.05);
    color: var(--accent);
}

.mobile-menu-item i {
    font-size: 1.125rem;
    width: 1.25rem;
}

.mobile-menu-item-warning {
    color: #f59e0b;
}

.mobile-menu-item-logout {
    color: #dc3545;
}

.mobile-menu-badge {
    font-size: 0.625rem;
    padding: 0.125rem 0.5rem;
    border-radius: 1rem;
    background-color: #f59e0b;
    color: white;
    margin-left: 0.5rem;
}

.mobile-menu-divider {
    height: 1px;
    background-color: rgba(0, 0, 0, 0.05);
    margin: 0.75rem 0;
}

.mobile-menu {
    padding-top: 80px;
    padding-bottom: 20px;
    overflow-y: auto;
}

.space-x-4 > * + * { margin-left: 1rem; }
.space-x-6 > * + * { margin-left: 1.5rem; }
.space-x-8 > * + * { margin-left: 2rem; }

.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.top-full { top: 100%; }
.left-0 { left: 0; }
.right-8 { right: 2rem; }
.bottom-8 { bottom: 2rem; }
.z-50 { z-index: 50; }

.w-full { width: 100%; }
.h-full { height: 100%; }
.w-12 { width: 3rem; }
.h-12 { height: 3rem; }
.w-16 { width: 4rem; }
.h-16 { height: 4rem; }

.rounded-lg { border-radius: 0.5rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-full { border-radius: 9999px; }

.shadow-sm { box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); }
.shadow-lg { box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1); }
.shadow-md { box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); }

.overflow-hidden { overflow: hidden; }
.border-t { border-top: 1px solid #e5e7eb; }
.border-gray-100 { border-color: #f3f4f6; }
.border-gray-300 { border-color: #d1d5db; }

.opacity-0 { opacity: 0; }
.opacity-100 { opacity: 1; }
.invisible { visibility: hidden; }

.transition { transition: all 0.3s ease; }
.transition-colors { transition: color 0.3s ease, background-color 0.3s ease; }
.duration-300 { transition-duration: 300ms; }

.hover\:text-accent:hover { color: var(--accent); }
.hover\:scale-105:hover { transform: scale(1.05); }

.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.gap-8 { gap: 2rem; }

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

.leading-tight { line-height: 1.25; }
.leading-relaxed { line-height: 1.625; }

/* Hero Section */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--secondary);
    margin-bottom: 2.5rem;
}

.hero-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.875rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.hero-btn i {
    margin-right: 0.5rem;
}

.hero-btn-primary {
    background-color: var(--accent);
    color: white;
}

.hero-btn-primary:hover {
    background-color: #0052cc;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 255, 0.3);
}

.hero-btn-secondary {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.hero-btn-secondary:hover {
    background-color: var(--primary);
    color: white;
}

.hero-icon {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, var(--accent), #667eea);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 20px 40px rgba(0, 102, 255, 0.3);
}

.hero-icon i {
    font-size: 80px;
    color: white;
}

/* Section Title */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1.5rem;
}

/* Module Cards */
.module-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.module-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.module-card.active {
    opacity: 1;
    transform: translateY(0);
}

.module-icon {
    width: 60px;
    height: 60px;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.module-icon i {
    font-size: 24px;
    color: white;
}

.module-icon-blue { background: linear-gradient(135deg, #667eea, #764ba2); }
.module-icon-green { background: linear-gradient(135deg, #11998e, #38ef7d); }
.module-icon-purple { background: linear-gradient(135deg, #667eea, #764ba2); }
.module-icon-orange { background: linear-gradient(135deg, #f093fb, #f5576c); }
.module-icon-red { background: linear-gradient(135deg, #fa709a, #fee140); }
.module-icon-indigo { background: linear-gradient(135deg, #4facfe, #00f2fe); }

.module-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.module-desc {
    color: var(--secondary);
    margin-bottom: 1.5rem;
    line-height: 1.75;
}

.module-link {
    display: inline-flex;
    align-items: center;
    color: var(--accent);
    font-weight: 500;
    transition: color 0.3s ease;
}

.module-link:hover {
    color: #0052cc;
}

.module-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.module-link:hover i {
    transform: translateX(4px);
}

/* User Dropdown */
.user-dropdown {
    position: relative;
}

.user-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--light);
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.user-dropdown-trigger:hover {
    background: #e5e7eb;
}

.user-avatar-trigger-inner {
    width: 32px;
    height: 32px;
}

.user-avatar-img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
}

.user-avatar-placeholder {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1;
}

.user-avatar-placeholder--stack {
    width: 32px;
    height: 32px;
    margin: 0;
    font-size: 1rem;
}

.user-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    overflow: hidden;
}

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

.user-dropdown-header {
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.user-dropdown-name {
    font-weight: 600;
    color: var(--primary);
}

.user-dropdown-divider {
    height: 1px;
    background: #e5e7eb;
}

.user-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    color: var(--secondary);
    transition: background 0.2s ease;
}

.user-dropdown-item:hover {
    background: var(--light);
    color: var(--primary);
}

.user-dropdown-item i {
    font-size: 1rem;
    width: 16px;
    text-align: center;
}

.user-dropdown-logout {
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font: inherit;
    padding: 0.875rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--secondary);
    transition: background 0.2s ease;
}

.user-dropdown-logout:hover {
    background: var(--light);
    color: #ef4444;
}

.user-dropdown-logout i {
    font-size: 1rem;
    width: 16px;
    text-align: center;
}

.user-dropdown-item-warning {
    color: #f59e0b;
}

.user-dropdown-item-warning:hover {
    background: var(--light);
    color: #d97706;
}

/* Mobile Menu */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 300px;
    max-width: 90%;
    height: 100%;
    background: white;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.15);
    transition: right 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
}

.mobile-menu.active {
    right: 0;
}

.mobile-user-header-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.mobile-menu-header {
    padding: 1.5rem;
    background: linear-gradient(135deg, var(--accent), #667eea);
    color: white;
}

.mobile-user-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.mobile-user-avatar {
    position: relative;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.mobile-user-avatar img,
.mobile-user-avatar .mobile-user-avatar-img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
}

.mobile-user-avatar-initial {
    font-size: 1.25rem;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.mobile-user-avatar-initial--stack {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.25);
}

.mobile-user-avatar i {
    font-size: 1.5rem;
}

.mobile-user-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.mobile-user-name {
    font-weight: 600;
    font-size: 1.125rem;
}

.mobile-user-email {
    font-size: 0.875rem;
    opacity: 0.9;
}

.mobile-menu-nav {
    padding: 1rem 0;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    color: var(--secondary);
    transition: all 0.2s ease;
}

.mobile-menu-item:hover {
    background: var(--light);
    color: var(--primary);
}

.mobile-menu-item-warning {
    color: #f59e0b;
}

.mobile-menu-item-logout {
    color: #ef4444;
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font: inherit;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.mobile-menu-item-logout:hover {
    background: #fee2e2;
}

.mobile-menu-item i {
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.mobile-menu-badge {
    margin-left: auto;
    padding: 0.25rem 0.75rem;
    background: #fef3c7;
    color: #d97706;
    font-size: 0.75rem;
    border-radius: 9999px;
    font-weight: 600;
}

.mobile-menu-divider {
    height: 1px;
    background: #e5e7eb;
    margin: 0.5rem 1.5rem;
}

.mobile-menu-user-nav {
    padding-bottom: 2rem;
}

/* Fade In Animation */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in.active {
    opacity: 1;
    transform: translateY(0);
}

/* Active Link */
a.active {
    color: var(--accent) !important;
}

/* Background opacity */
.bg-opacity-95 {
    background-color: rgba(255, 255, 255, 0.95);
}

/* Responsive */
@media (min-width: 768px) {
    .md\:flex { display: flex; }
    .md\:hidden { display: none; }
    .md\:flex-row { flex-direction: row; }
    .md\:w-1\/2 { width: 50%; }
    .md\:w-2\/5 { width: 40%; }
    .md\:w-1\/3 { width: 33.333%; }
    .md\:w-2\/3 { width: 66.666%; }
    .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .md\:px-8 { padding-left: 2rem; padding-right: 2rem; }
}

@media (max-width: 767px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-icon {
        width: 150px;
        height: 150px;
    }
    
    .hero-icon i {
        font-size: 60px;
    }
    
    .hero-btn {
        width: 100%;
        justify-content: center;
    }
    
    .section-title {
        font-size: 2rem;
    }
}
