/* ================================================================
   全局重置 & 变量
   ================================================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    color-scheme: dark;
    --primary: #7857ff;
    --primary-dim: rgba(120, 87, 255, 0.15);
    --primary-glow: rgba(120, 87, 255, 0.08);
    --accent: #00d5ff;
    --accent-dim: rgba(0, 213, 255, 0.08);
    --bg: #070914;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-hover: rgba(255, 255, 255, 0.06);
    --border: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(255, 255, 255, 0.12);
    --text: #f7f8ff;
    --text-secondary: rgba(255, 255, 255, 0.5);
    --text-muted: rgba(255, 255, 255, 0.2);
    --radius: 16px;
    --radius-sm: 10px;
    --radius-xs: 6px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    --transition: 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

body {
    font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    overflow: hidden;
}

/* ================================================================
   背景光晕
   ================================================================ */
.bg-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
}
.bg-glow.g1 {
    width: 50rem;
    height: 50rem;
    left: -25rem;
    top: -25rem;
    background: var(--primary);
    opacity: 0.08;
    animation: glowFloat1 16s ease-in-out infinite alternate;
}
.bg-glow.g2 {
    width: 40rem;
    height: 40rem;
    right: -20rem;
    bottom: -20rem;
    background: var(--accent);
    opacity: 0.06;
    animation: glowFloat2 12s ease-in-out infinite alternate-reverse;
}

@keyframes glowFloat1 {
    0% {
        transform: translate(0, 0) scale(1);
    }
    100% {
        transform: translate(60px, -40px) scale(1.1);
    }
}
@keyframes glowFloat2 {
    0% {
        transform: translate(0, 0) scale(1);
    }
    100% {
        transform: translate(-40px, 60px) scale(1.15);
    }
}

/* ================================================================
   网格
   ================================================================ */
.grid {
    position: fixed;
    inset: 0;
    z-index: 0;
    opacity: 0.03;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
    pointer-events: none;
}

/* ================================================================
   侧边栏
   ================================================================ */
.sidebar {
    position: relative;
    z-index: 2;
    width: 220px;
    height: 100vh;
    padding: 28px 16px 24px;
    background: var(--surface);
    backdrop-filter: blur(24px) saturate(1.2);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    transition: transform var(--transition);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    padding: 0 8px 24px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
}
.sidebar-brand svg {
    flex-shrink: 0;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    border: 1px solid var(--border);
    cursor: pointer;
    transition: all var(--transition);
    margin-bottom: 20px;
}
.sidebar-user:hover {
    background: var(--surface-hover);
    border-color: var(--border-hover);
}
.sidebar-user .avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    flex-shrink: 0;
    overflow: hidden;
}
.sidebar-user .avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.sidebar-user .info {
    flex: 1;
    min-width: 0;
}
.sidebar-user .info .name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sidebar-user .info .email {
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    list-style: none;
}
.sidebar-nav li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all var(--transition);
    cursor: pointer;
}
.sidebar-nav li a:hover {
    color: var(--text);
    background: var(--surface-hover);
}
.sidebar-nav li a.active {
    color: #c5b4ff;
    background: var(--primary-dim);
}
.sidebar-nav li a svg {
    flex-shrink: 0;
    opacity: 0.6;
}
.sidebar-nav li a.active svg {
    opacity: 1;
}

.sidebar-footer {
    padding-top: 16px;
    border-top: 1px solid var(--border);
    margin-top: auto;
}
.sidebar-footer button {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 10px 12px;
    border: none;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}
.sidebar-footer button:hover {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.08);
}
.sidebar-footer button svg {
    flex-shrink: 0;
}

/* ================================================================
   主内容
   ================================================================ */
.main {
    flex: 1;
    min-width: 0;
    height: 100vh;
    overflow-y: auto;
    padding: 32px 48px 48px;
    position: relative;
    z-index: 1;
}
.main::-webkit-scrollbar {
    width: 4px;
}
.main::-webkit-scrollbar-track {
    background: transparent;
}
.main::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}

.page-header {
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
}
.page-header h1 {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: linear-gradient(115deg, #fff 15%, #b9a8ff 50%, #74e8ff 85%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.page-header p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 2px;
}
.page-header .actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* ================================================================
   卡片
   ================================================================ */
.card {
    background: var(--surface);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px 28px;
    margin-bottom: 20px;
    transition: border-color var(--transition);
}
.card:hover {
    border-color: var(--border-hover);
}
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 8px;
}
.card-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
}
.card-header .badge {
    font-size: 11px;
    padding: 3px 12px;
    border-radius: 40px;
    background: var(--primary-dim);
    color: #c5b4ff;
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* ================================================================
   统计卡片
   ================================================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 14px;
    margin-bottom: 28px;
}
.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 18px 20px;
    transition: all var(--transition);
}
.stat-card:hover {
    border-color: var(--border-hover);
}
.stat-card .label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}
.stat-card .value {
    font-size: 28px;
    font-weight: 700;
    margin-top: 4px;
    letter-spacing: -0.02em;
}
.stat-card .sub {
    font-size: 12px;
    color: var(--text-muted);
    font-family: monospace;
    margin-top: 2px;
}

/* ================================================================
   按钮
   ================================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
    text-decoration: none;
    background: var(--surface);
    color: var(--text-secondary);
    white-space: nowrap;
}
.btn:hover {
    transform: translateY(-1px);
}
.btn:active {
    transform: scale(0.97);
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), #5a3bc9);
    color: #fff;
}
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 30px rgba(120, 87, 255, 0.25);
}
.btn-success {
    background: linear-gradient(135deg, #6effbd, #3dbd8a);
    color: #070914;
}
.btn-success:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 30px rgba(110, 255, 189, 0.2);
}
.btn-danger {
    background: rgba(255, 107, 107, 0.12);
    color: #ff6b6b;
}
.btn-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 30px rgba(255, 107, 107, 0.1);
}
.btn-ghost {
    background: transparent;
    color: var(--text-muted);
}
.btn-ghost:hover {
    transform: translateY(-1px);
    color: var(--text-secondary);
}
.btn-sm {
    padding: 5px 12px;
    font-size: 12px;
    border-radius: var(--radius-xs);
}
.btn-block {
    width: 100%;
}

/* ================================================================
   应用列表
   ================================================================ */
.app-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.app-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    transition: all var(--transition);
    gap: 12px;
}
.app-item:hover {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.03);
}
.app-item .info {
    flex: 1;
    min-width: 0;
}
.app-item .info .name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
}
.app-item .info .id {
    font-size: 12px;
    color: var(--text-muted);
    font-family: monospace;
    word-break: break-all;
}
.app-item .info .desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}
.app-item .actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

/* ================================================================
   表单
   ================================================================ */
.form-group {
    margin-bottom: 16px;
}
.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
    letter-spacing: 0.02em;
}
.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-size: 14px;
    transition: all var(--transition);
    font-family: inherit;
}
.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}
.form-group textarea {
    resize: vertical;
    min-height: 56px;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.form-group .error-msg {
    color: #ff6b6b;
    font-size: 12px;
    margin-top: 4px;
    display: none;
}
.form-group .error-msg.show {
    display: block;
}

/* ================================================================
   自定义下拉选择框
   ================================================================ */
.custom-select {
    position: relative;
    width: 100%;
    cursor: pointer;
    user-select: none;
}
.custom-select .select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    transition: all var(--transition);
    min-height: 42px;
    gap: 12px;
}
.custom-select .select-trigger:hover {
    border-color: var(--border-hover);
}
.custom-select .select-trigger .arrow {
    flex-shrink: 0;
    transition: transform 0.3s ease;
    opacity: 0.4;
}
.custom-select.open .select-trigger .arrow {
    transform: rotate(180deg);
    opacity: 0.8;
}
.custom-select.open .select-trigger {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}
.custom-select .select-options {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: rgba(14, 16, 32, 0.98);
    backdrop-filter: blur(20px);
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transform: translateY(-6px);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 10;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    pointer-events: none;
}
.custom-select.open .select-options {
    max-height: 280px;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
.custom-select .select-options .option {
    padding: 10px 14px;
    color: var(--text-secondary);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s ease;
    cursor: pointer;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.custom-select .select-options .option:last-child {
    border-bottom: none;
}
.custom-select .select-options .option:hover {
    background: var(--surface-hover);
    color: var(--text);
}
.custom-select .select-options .option.selected {
    background: var(--primary-dim);
    color: #c5b4ff;
}
.custom-select .select-options .option .check {
    display: none;
    color: var(--primary-light);
}
.custom-select .select-options .option.selected .check {
    display: inline;
}
.custom-select.disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* ================================================================
   空状态
   ================================================================ */
.empty-state {
    text-align: center;
    padding: 48px 20px;
    color: var(--text-muted);
}
.empty-state p {
    font-size: 14px;
}

/* ================================================================
   Toast
   ================================================================ */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    background: rgba(12, 14, 28, 0.92);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 14px;
    z-index: 999;
    transform: translateY(80px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
    max-width: 90vw;
}
.toast.show {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}
.toast.success {
    border-color: rgba(110, 255, 189, 0.2);
}
.toast.error {
    border-color: rgba(255, 107, 107, 0.2);
}

/* ================================================================
   加载状态
   ================================================================ */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin-right: 8px;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ================================================================
   模态框
   ================================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 20px;
}
.modal-overlay.open {
    opacity: 1;
    pointer-events: auto;
}
.modal {
    background: rgba(14, 16, 32, 0.96);
    backdrop-filter: blur(24px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 40px 36px 32px;
    width: min(92vw, 420px);
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.modal-overlay.open .modal {
    transform: scale(1);
}
.modal-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}
.modal-sub {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 24px;
}
.modal .tabs {
    display: flex;
    gap: 4px;
    background: var(--surface);
    border-radius: var(--radius-sm);
    padding: 4px;
    margin-bottom: 24px;
}
.modal .tab {
    flex: 1;
    padding: 9px 0;
    border: none;
    border-radius: var(--radius-xs);
    background: transparent;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
    text-align: center;
}
.modal .tab:hover {
    color: var(--text);
}
.modal .tab.active {
    background: var(--primary-dim);
    color: #c5b4ff;
}
.modal .form-page {
    display: none;
}
.modal .form-page.active {
    display: block;
}
.modal .form-group {
    margin-bottom: 14px;
}
.modal .form-group label {
    font-size: 12px;
    color: var(--text-secondary);
}
.modal .form-group input {
    padding: 10px 14px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-size: 14px;
    width: 100%;
    transition: all var(--transition);
    font-family: inherit;
}
.modal .form-group input:focus {
    outline: none;
    border-color: var(--primary);
}
.modal .form-group .error-msg {
    color: #ff6b6b;
    font-size: 12px;
    margin-top: 4px;
    display: none;
}
.modal .form-group .error-msg.show {
    display: block;
}
.modal .btn {
    width: 100%;
    padding: 12px 0;
}
.modal .switch-link {
    text-align: center;
    margin-top: 14px;
    font-size: 14px;
    color: var(--text-secondary);
}
.modal .switch-link a {
    color: var(--primary);
    text-decoration: none;
    cursor: pointer;
}
.modal .switch-link a:hover {
    text-decoration: underline;
}
.modal .modal-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 20px;
    cursor: pointer;
    font-family: inherit;
}
.modal .modal-close:hover {
    color: var(--text);
}
.modal {
    position: relative;
}
.modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 8px;
}
.modal-actions .btn {
    width: auto;
}

/* ================================================================
   详情抽屉
   ================================================================ */
.detail-panel {
    position: fixed;
    right: 0;
    top: 0;
    bottom: 0;
    width: 520px;
    max-width: 90vw;
    padding: 32px 28px;
    background: rgba(10, 12, 26, 0.96);
    backdrop-filter: blur(28px);
    border-left: 1px solid var(--border);
    z-index: 50;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    overflow-y: auto;
}
.detail-panel.open {
    transform: translateX(0);
}
.detail-panel::-webkit-scrollbar {
    width: 3px;
}
.detail-panel::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 10px;
}
.detail-panel .close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 22px;
    cursor: pointer;
    transition: color var(--transition);
}
.detail-panel .close-btn:hover {
    color: var(--text);
}
.detail-panel .field {
    margin-bottom: 14px;
}
.detail-panel .field label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 3px;
}
.detail-panel .field .value {
    font-size: 14px;
    color: var(--text);
    word-break: break-all;
}
.detail-panel .field .value-input {
    width: 100%;
    padding: 8px 12px;
    border-radius: var(--radius-xs);
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    transition: all var(--transition);
}
.detail-panel .field .value-input:focus {
    outline: none;
    border-color: var(--primary);
}
.detail-panel .divider {
    height: 1px;
    background: var(--border);
    margin: 20px 0;
}
.detail-panel .code-block {
    background: rgba(0, 0, 0, 0.4);
    border-radius: var(--radius-xs);
    padding: 16px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 13px;
    overflow-x: auto;
    white-space: pre-wrap;
    word-break: break-all;
    color: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border);
    max-height: 280px;
    overflow-y: auto;
}
.detail-panel .hint {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 4px;
}
.detail-panel .action-row {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    flex-wrap: wrap;
}
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 49;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* ================================================================
   移动端
   ================================================================ */
.mobile-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 20;
    padding: 10px;
    border-radius: var(--radius-sm);
    background: var(--surface);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    color: var(--text);
    cursor: pointer;
}
.mobile-toggle:hover {
    background: var(--surface-hover);
}

@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        z-index: 30;
        transform: translateX(-100%);
        width: 260px;
        background: rgba(7, 9, 20, 0.96);
        backdrop-filter: blur(30px);
    }
    .sidebar.open {
        transform: translateX(0);
    }
    .mobile-toggle {
        display: flex;
    }
    .main {
        padding: 24px 16px 40px;
        padding-top: 72px;
    }
    .form-row {
        grid-template-columns: 1fr;
    }
    .app-item {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .app-item .actions {
        justify-content: flex-start;
    }
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
    .page-header {
        flex-direction: column;
    }
    .detail-panel {
        width: 100%;
        max-width: 100%;
        padding: 24px 20px;
    }
    .modal {
        padding: 32px 24px 28px;
    }
    .modal-actions {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .main {
        padding: 16px 12px 32px;
        padding-top: 68px;
    }
    .card {
        padding: 16px;
    }
    .page-header h1 {
        font-size: 22px;
    }
    .custom-select .select-trigger {
        padding: 8px 12px;
        font-size: 13px;
    }
    .custom-select .select-options .option {
        padding: 8px 12px;
        font-size: 13px;
    }
}