:root {
    --bg-primary: #F5F5F7;
    --bg-card: #FFFFFF;
    --bg-card-hover: #FAFAFA;
    
    --text-primary: #1D1D1F;
    --text-secondary: #636366;
    --text-tertiary: #8E8E93;
    --text-disabled: #C7C7CC;
    
    --border-light: #E5E5EA;
    --border-card: #E5E5EA;
    
    --gradient-primary: linear-gradient(135deg, #5856D6 0%, #007AFF 100%);
    --gradient-warning: linear-gradient(135deg, #FF9500 0%, #FF3B30 100%);
    --gradient-success: linear-gradient(135deg, #34C759 0%, #30B0C7 100%);
    --gradient-text: linear-gradient(135deg, #5856D6 0%, #007AFF 100%);
    
    --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.04);
    --shadow-card-hover: 0 8px 24px rgba(0, 0, 0, 0.08);
    --shadow-button: 0 4px 12px rgba(88, 86, 214, 0.3);
    --shadow-button-hover: 0 6px 20px rgba(88, 86, 214, 0.4);
    
    --radius-sm: 10px;
    --radius-md: 12px;
    --radius-lg: 16px;
    
    --transition-fast: all 0.15s cubic-bezier(0.25, 0.1, 0.25, 1);
    --transition-normal: all 0.2s cubic-bezier(0.25, 0.1, 0.25, 1);
    --transition-slow: all 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
    
    --sidebar-width: 240px;
    --header-height: 56px;
    --tab-height: 44px;
}

[data-theme="dark"] {
    --bg-primary: #1C1C1E;
    --bg-card: #2C2C2E;
    --bg-card-hover: #3A3A3C;
    
    --text-primary: #FFFFFF;
    --text-secondary: #C7C7CC;
    --text-tertiary: #8E8E93;
    --text-disabled: #636366;
    
    --border-light: #3A3A3C;
    --border-card: #3A3A3C;
    
    --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.2);
    --shadow-card-hover: 0 8px 24px rgba(0, 0, 0, 0.3);
    --shadow-button: 0 4px 12px rgba(88, 86, 214, 0.4);
    --shadow-button-hover: 0 6px 20px rgba(88, 86, 214, 0.5);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Helvetica Neue", sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1 { font-size: 48px; font-weight: 700; line-height: 1.1; }
h2 { font-size: 32px; font-weight: 600; line-height: 1.2; }
h3 { font-size: 20px; font-weight: 500; line-height: 1.3; }
h4 { font-size: 16px; font-weight: 500; line-height: 1.4; }

::selection {
    background: rgba(88, 86, 214, 0.2);
    color: var(--text-primary);
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--text-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.login-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at 30% 20%, rgba(88, 86, 214, 0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 70% 80%, rgba(0, 122, 255, 0.06) 0%, transparent 50%);
    animation: waveMove 20s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes waveMove {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33% { transform: translate(2%, 1%) rotate(1deg); }
    66% { transform: translate(-1%, 2%) rotate(-1deg); }
}

.login-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    padding: 56px 48px;
    width: 100%;
    max-width: 420px;
    position: relative;
    z-index: 1;
    animation: cardAppear 0.5s cubic-bezier(0.25, 0.1, 0.25, 1);
    border: 1px solid var(--border-card);
}

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

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.system-title {
    text-align: center;
    margin-bottom: 40px;
}

.system-title h1 {
    font-size: 28px;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 1px;
    margin-bottom: 8px;
    display: inline-block;
}

.system-title p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.water-icon {
    width: 20px;
    height: 20px;
    background: var(--gradient-primary);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C12 2 5 9 5 14.5C5 18.09 8.13 21 12 21C15.87 21 19 18.09 19 14.5C19 9 12 2 12 2ZM12 19C9.52 19 7.5 17.5 7.5 15.5C7.5 13.5 9.5 11 12 8.5C14.5 11 16.5 13.5 16.5 15.5C16.5 17.5 14.48 19 12 19Z'/%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C12 2 5 9 5 14.5C5 18.09 8.13 21 12 21C15.87 21 19 18.09 19 14.5C19 9 12 2 12 2ZM12 19C9.52 19 7.5 17.5 7.5 15.5C7.5 13.5 9.5 11 12 8.5C14.5 11 16.5 13.5 16.5 15.5C16.5 17.5 14.48 19 12 19Z'/%3E%3C/svg%3E") center/contain no-repeat;
    animation: drop 2s ease-in-out infinite;
}

@keyframes drop {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    position: relative;
}

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

.input-wrapper {
    position: relative;
}

.input-wrapper svg {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: var(--text-tertiary);
    transition: color var(--transition-fast);
    flex-shrink: 0;
}

.form-group input {
    width: 100%;
    padding: 12px 14px 12px 46px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    font-size: 15px;
    color: var(--text-primary);
    background: var(--bg-primary);
    transition: all var(--transition-normal);
    outline: none;
    font-family: inherit;
}

.form-group input::placeholder {
    color: var(--text-disabled);
}

.form-group input:focus {
    border-color: #007AFF;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.15);
}

.form-group input:focus + svg {
    color: #007AFF;
}

.captcha-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.captcha-input-wrapper {
    flex: 1;
}

.captcha-box {
    min-width: 110px;
    height: 48px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
    cursor: pointer;
    overflow: hidden;
    background: var(--bg-primary);
    transition: all var(--transition-fast);
}

.captcha-box:hover {
    border-color: #007AFF;
}

.captcha-refresh {
    height: 48px;
    padding: 0 18px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.captcha-refresh:hover {
    border-color: #007AFF;
    color: #007AFF;
}

.remember-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: -8px;
}

.remember-row input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #007AFF;
}

.remember-row label {
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    user-select: none;
    margin-bottom: 0;
}

.button-group {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.btn {
    flex: 1;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: inherit;
}

.btn svg {
    width: 18px;
    height: 18px;
}

.btn-primary {
    background: var(--gradient-primary);
    color: #FFFFFF;
    box-shadow: var(--shadow-button);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-button-hover);
}

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

.btn-secondary {
    background: var(--bg-primary);
    color: var(--text-secondary);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--text-tertiary);
}

.btn-text {
    background: transparent;
    color: #007AFF;
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: inherit;
}

.btn-text:hover {
    background: rgba(0, 122, 255, 0.08);
}

.btn-small {
    padding: 6px 14px;
    font-size: 13px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    border: 1px solid var(--border-light);
    background: var(--bg-card);
    color: var(--text-secondary);
    font-family: inherit;
}

.btn-small:hover {
    background: var(--bg-card-hover);
    border-color: #007AFF;
    color: #007AFF;
}

.btn-danger {
    border-color: rgba(255, 59, 48, 0.3);
    color: #FF3B30;
}

.btn-danger:hover {
    background: rgba(255, 59, 48, 0.08);
    border-color: #FF3B30;
    color: #FF3B30;
}

.error-message {
    background: rgba(255, 59, 48, 0.08);
    color: #FF3B30;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: fadeIn 0.3s ease;
    border: 1px solid rgba(255, 59, 48, 0.2);
}

.error-message svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

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

.home-container {
    min-height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
}

.home-header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    padding: 0 24px;
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border-card);
    transition: background-color 0.3s ease;
}

[data-theme="dark"] .home-header {
    background: rgba(44, 44, 46, 0.8);
}

.home-header .logo {
    font-size: 17px;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: flex;
    align-items: center;
    gap: 10px;
}

.home-header .logo svg {
    width: 24px;
    height: 24px;
    background: var(--gradient-primary);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C12 2 5 9 5 14.5C5 18.09 8.13 21 12 21C15.87 21 19 18.09 19 14.5C19 9 12 2 12 2ZM12 19C9.52 19 7.5 17.5 7.5 15.5C7.5 13.5 9.5 11 12 8.5C14.5 11 16.5 13.5 16.5 15.5C16.5 17.5 14.48 19 12 19Z'/%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C12 2 5 9 5 14.5C5 18.09 8.13 21 12 21C15.87 21 19 18.09 19 14.5C19 9 12 2 12 2ZM12 19C9.52 19 7.5 17.5 7.5 15.5C7.5 13.5 9.5 11 12 8.5C14.5 11 16.5 13.5 16.5 15.5C16.5 17.5 14.48 19 12 19Z'/%3E%3C/svg%3E") center/contain no-repeat;
}

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

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

.btn-logout {
    padding: 8px 16px;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
    font-family: inherit;
}

.btn-logout:hover {
    background: var(--bg-card-hover);
    border-color: var(--text-tertiary);
    color: var(--text-primary);
}

.theme-toggle {
    width: 44px;
    height: 24px;
    border-radius: 12px;
    background: var(--border-light);
    position: relative;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.theme-toggle::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--text-primary);
    transition: all var(--transition-fast);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .theme-toggle {
    background: #5856D6;
}

[data-theme="dark"] .theme-toggle::after {
    left: 23px;
}

.theme-switch-wrapper {
    position: absolute;
    top: 16px;
    right: 16px;
}

.login-card .theme-switch-wrapper {
    top: 24px;
    right: 24px;
}

.main-layout {
    display: flex;
    padding-top: var(--header-height);
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-card);
    border-right: 1px solid var(--border-card);
    position: fixed;
    top: var(--header-height);
    left: 0;
    bottom: 0;
    overflow-y: auto;
    z-index: 90;
    display: flex;
    flex-direction: column;
    transition: background-color 0.3s ease;
}

.sidebar-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-light);
    font-size: 12px;
    color: var(--text-tertiary);
    display: flex;
    justify-content: space-between;
    margin-top: auto;
}

.nav-tree {
    padding: 12px 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition-fast);
    cursor: pointer;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.nav-link:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.nav-link.active {
    background: rgba(88, 86, 214, 0.08);
    color: #007AFF;
}

.nav-link.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 20px;
    background: var(--gradient-primary);
    border-radius: 0 2px 2px 0;
}

.nav-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.arrow-icon {
    width: 16px;
    height: 16px;
    margin-left: auto;
    transition: transform var(--transition-fast);
}

.has-submenu.open .arrow-icon {
    transform: rotate(180deg);
}

.submenu {
    display: none;
    background: var(--bg-primary);
}

.has-submenu.open .submenu {
    display: block;
}

.submenu-link {
    display: block;
    padding: 10px 20px 10px 52px;
    color: var(--text-tertiary);
    text-decoration: none;
    font-size: 13px;
    transition: all var(--transition-fast);
}

.submenu-link:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.submenu-link.active {
    color: #007AFF;
    background: rgba(88, 86, 214, 0.05);
}

.content-area {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - var(--header-height));
}

.tab-bar {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-card);
    height: var(--tab-height);
    display: flex;
    align-items: center;
    padding: 0 16px;
    position: sticky;
    top: var(--header-height);
    z-index: 80;
}

.tabs-container {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    overflow-x: auto;
}

.tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: transparent;
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-tertiary);
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition-fast);
    border: none;
}

.tab:hover {
    background: var(--bg-card-hover);
    color: var(--text-secondary);
}

.tab.active {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    font-weight: 500;
}

.tab-close {
    width: 18px;
    height: 18px;
    border: none;
    background: transparent;
    color: var(--text-tertiary);
    cursor: pointer;
    border-radius: 50%;
    font-size: 14px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.tab-close:hover {
    background: rgba(0, 0, 0, 0.08);
    color: var(--text-primary);
}

.tab-actions {
    padding-left: 16px;
    display: flex;
    gap: 8px;
}

.tab-refresh {
    padding: 6px 12px;
    background: transparent;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    color: var(--text-tertiary);
    font-size: 12px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.tab-refresh:hover {
    background: var(--bg-card-hover);
    color: var(--text-secondary);
}

.tab-content {
    flex: 1;
    padding: 24px;
    background: var(--bg-primary);
}

.tab-pane {
    display: none;
    animation: fadeSlideIn 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
}

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

.tab-pane.active {
    display: block;
}

.welcome-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-card);
    margin-bottom: 32px;
}

.welcome-card h2 {
    font-size: 24px;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.welcome-card p {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 32px;
}

.status-item {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 28px;
    text-align: center;
    border: 1px solid var(--border-card);
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-card);
}

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

.status-item .icon {
    width: 44px;
    height: 44px;
    margin: 0 auto 16px;
}

.status-item .number {
    font-size: 36px;
    font-weight: 700;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.1;
}

.status-item .label {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 8px;
}

.page-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-card);
    border: 1px solid var(--border-card);
}

.page-card h3 {
    font-size: 20px;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.page-desc {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 24px;
}

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

.btn-compact {
    flex: none;
    padding: 8px 20px;
    font-size: 14px;
}

.toolbar-row {
    display: flex;
    gap: 12px;
    align-items: center;
    margin: 16px 0 24px;
    flex-wrap: wrap;
}

.toolbar-input {
    min-width: 280px;
    padding: 10px 14px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
}

.toolbar-input:focus {
    outline: none;
    border-color: #007AFF;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

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

.data-table th {
    background: var(--bg-primary);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.3px;
}

.data-table tbody tr:hover {
    background: var(--bg-card-hover);
}

.empty-data {
    text-align: center;
    color: var(--text-tertiary);
    padding: 48px !important;
}

.page-form {
    max-width: 800px;
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-item {
    flex: 1;
}

.form-item.full {
    flex: 1 1 100%;
}

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

.form-item input,
.form-item textarea,
.form-item select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--text-primary);
    background: var(--bg-primary);
    transition: all var(--transition-fast);
    outline: none;
    font-family: inherit;
}

.form-item input:focus,
.form-item textarea:focus,
.form-item select:focus {
    border-color: #007AFF;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

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

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.form-actions .btn {
    flex: none;
    padding: 10px 28px;
}

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.2s ease;
}

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

.modal {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    max-width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalIn 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
    border: 1px solid var(--border-card);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

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

.modal-medium {
    width: 600px;
}

.modal-large {
    width: 900px;
}

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

.modal-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 18px;
}

.modal-close {
    background: transparent;
    border: none;
    font-size: 24px;
    color: var(--text-tertiary);
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.modal-body-area {
    padding: 24px;
}

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

.api-section {
    background: var(--bg-primary);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 20px;
    border: 1px solid var(--border-card);
}

.api-section h4 {
    color: var(--text-primary);
    font-size: 16px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

.api-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

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

.api-table th {
    background: var(--bg-primary);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 12px;
}

.api-table tbody tr:hover {
    background: var(--bg-card-hover);
}

.api-table code {
    background: var(--bg-primary);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    color: #007AFF;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
}

.method {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.method.get {
    background: rgba(88, 86, 214, 0.1);
    color: #5856D6;
}

.method.post {
    background: rgba(52, 199, 89, 0.1);
    color: #34C759;
}

.param-info {
    margin-bottom: 16px;
}

.param-info p {
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.param-info ul {
    list-style: none;
    padding-left: 0;
}

.param-info li {
    font-size: 13px;
    color: var(--text-secondary);
    padding: 4px 0;
    padding-left: 16px;
    position: relative;
}

.param-info li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: #007AFF;
}

.param-info code {
    background: var(--bg-card);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    color: #007AFF;
}

.code-example {
    background: #1C1C1E;
    border-radius: var(--radius-sm);
    padding: 16px;
    margin-top: 12px;
    overflow-x: auto;
}

.code-example p {
    color: #C7C7CC;
    font-size: 13px;
    margin-bottom: 8px;
}

.code-example pre {
    margin: 0;
    color: #A5D6A7;
    font-size: 12px;
    line-height: 1.6;
    white-space: pre-wrap;
    word-break: break-all;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
}

.login-result {
    margin-top: 16px;
    padding: 16px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-card);
}

.login-result h5 {
    color: var(--text-primary);
    font-size: 14px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}

.result-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 8px;
    font-size: 13px;
}

.result-label {
    width: 60px;
    color: var(--text-tertiary);
    flex-shrink: 0;
}

.result-value {
    flex: 1;
    color: var(--text-primary);
    word-break: break-all;
}

.result-value.status-success {
    color: #34C759;
    font-weight: 600;
}

.result-value.status-error {
    color: #FF3B30;
    font-weight: 600;
}

.result-value.status-pending {
    color: #FF9500;
    font-weight: 600;
}

.token-text {
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
    font-size: 12px;
    background: var(--bg-primary);
    padding: 6px 10px;
    border-radius: 4px;
    word-break: break-all;
}

.status-badge-neutral {
    background: var(--bg-primary);
    color: var(--text-secondary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge-success {
    background: rgba(52, 199, 89, 0.1);
    color: #34C759;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge-warning {
    background: rgba(255, 149, 0, 0.1);
    color: #FF9500;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge-error {
    background: rgba(255, 59, 48, 0.1);
    color: #FF3B30;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.strategy-option {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.strategy-option label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text-secondary);
    user-select: none;
}

.strategy-option input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #007AFF;
}

.weekday-group {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.weekday-group label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-primary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 13px;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
    user-select: none;
}

.weekday-group label:hover {
    background: var(--bg-card-hover);
    border-color: var(--text-tertiary);
}

.weekday-group input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #007AFF;
}

.weekday-group input[type="checkbox"]:checked + span,
.weekday-group input[type="checkbox"]:checked {
    color: #007AFF;
}

@media (max-width: 768px) {
    :root {
        --sidebar-width: 60px;
    }

    .home-header {
        padding: 0 16px;
    }

    .home-header .logo span {
        display: none;
    }

    .sidebar {
        width: 60px;
    }

    .nav-link span,
    .arrow-icon,
    .submenu {
        display: none;
    }

    .nav-link {
        justify-content: center;
        padding: 14px;
        border-radius: var(--radius-sm);
    }

    .content-area {
        margin-left: 60px;
    }

    .form-row {
        flex-direction: column;
        gap: 16px;
    }

    .status-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .modal-medium,
    .modal-large {
        width: 95%;
    }
}