/* ============================================
   VLESS Converter Pro - Admin Panel Style
   Exact Copy of Admin Design
   ============================================ */

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

:root {
    --bg-main: #0d0f1a;
    --bg-card: #151929;
    --bg-card-hover: #1a1f35;
    --bg-input: #1a1f35;
    --bg-header: rgba(13, 15, 26, 0.95);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.15);
    --text-primary: #ffffff;
    --text-secondary: #c4c9d4;
    --text-muted: #9ca3b4;
    --accent-blue: #3b82f6;
    --accent-purple: #a855f7;
    --accent-yellow: #fbbf24;
    --accent-green: #22c55e;
    --accent-red: #ef4444;
    --accent-orange: #f97316;
    --gradient-purple: linear-gradient(135deg, #8b5cf6 0%, #5b5bd6 100%);
    --shadow-glow-purple: 0 0 20px rgba(139, 92, 246, 0.25);
    --shadow-glow-yellow: 0 0 30px rgba(251, 191, 36, 0.3);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 20px;
}

html, body { height: 100%; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.5;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

/* Stars Background */
.stars-bg {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 0;
    pointer-events: none;
    background: 
        radial-gradient(ellipse 80% 50% at 20% 80%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse 60% 40% at 80% 20%, rgba(99, 102, 241, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse 70% 50% at 50% 100%, rgba(168, 85, 247, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at bottom, #1a1f35 0%, #0d0f1a 100%);
}
.star {
    position: absolute;
    width: 2px; height: 2px;
    background: white;
    border-radius: 50%;
    animation: twinkle var(--duration, 3s) ease-in-out infinite;
    animation-delay: var(--delay, 0s);
}
@keyframes twinkle {
    0%, 100% { opacity: 0.2; }
    50% { opacity: var(--opacity, 0.8); }
}

/* Page Loader */
.page-loader {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}
.page-loader.fade-out { opacity: 0; transition: opacity 0.5s; pointer-events: none; display: none; }
.loader-content { text-align: center; }
.loader-icon {
    width: 80px; height: 80px;
    background: var(--gradient-purple);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    font-size: 36px;
    color: white;
    box-shadow: var(--shadow-glow-purple);
}
.loader-text { font-size: 24px; font-weight: 800; color: var(--text-primary); margin-bottom: 20px; }
.loader-spinner {
    width: 40px; height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-purple);
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 1s linear infinite;
}
@keyframes spin { 100% { transform: rotate(360deg); } }

/* App Layout */
.app-layout { min-height: 100vh; position: relative; z-index: 1; }

/* Top Header - EXACT COPY FROM ADMIN */
.top-header {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background: var(--bg-header);
    border-bottom: 1px solid var(--border-color);
    backdrop-filter: blur(20px);
}
.header-left { 
    position: absolute;
    left: 24px;
    display: flex; 
    align-items: center; 
    gap: 16px; 
}
.header-right { 
    position: absolute;
    right: 24px;
    display: flex; 
    align-items: center; 
    gap: 12px; 
}

/* Logo - EXACT COPY FROM ADMIN */
.logo { display: flex; align-items: center; gap: 10px; }
.logo-icon {
    width: 36px; height: 36px;
    background: var(--gradient-purple);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
    box-shadow: var(--shadow-glow-purple);
}
.logo-text { font-size: 18px; font-weight: 700; }
.logo-text .version-num { font-size: 14px; font-weight: 500; color: var(--accent-yellow); margin-left: 8px; }

/* Main Navigation - EXACT COPY FROM ADMIN */
.main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--bg-card);
    padding: 4px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}
.nav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
}
.nav-item:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }
.nav-item.active {
    color: white;
    background: var(--accent-purple);
    box-shadow: 0 2px 10px rgba(168, 85, 247, 0.4);
}
.nav-item i { font-size: 14px; }

@media (max-width: 900px) {
    .nav-item { padding: 8px 10px; }
    .nav-item span { display: none; }
}

/* Main Content */
.main-content { min-height: calc(100vh - 64px); }
.content-area { padding: 24px; max-width: 1200px; margin: 0 auto; }

/* Pages */
.page { display: none; }
.page.active { display: block; animation: fadeIn 0.3s ease; }
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}


/* Stats Cards - EXACT COPY FROM ADMIN */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}
@media (max-width: 900px) { .stats-row { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .stats-row { grid-template-columns: 1fr; } }

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 24px;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #a855f7, #6366f1, #a855f7);
}
.stat-card:hover { transform: translateY(-4px); box-shadow: 0 0 25px rgba(168, 85, 247, 0.3); }

.stat-card.accent::before { 
    background: linear-gradient(90deg, #fbbf24, #f59e0b, #fbbf24);
}
.stat-card.accent:hover { box-shadow: var(--shadow-glow-yellow); }

.stat-card.blue-accent::before { 
    background: linear-gradient(90deg, #3b82f6, #6366f1, #3b82f6);
}
.stat-card.blue-accent:hover { box-shadow: 0 0 20px rgba(59, 130, 246, 0.3); }

.stat-card-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.stat-icon {
    width: 44px; height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}
.stat-icon.blue { background: rgba(59, 130, 246, 0.15); color: var(--accent-blue); }
.stat-icon.yellow { background: rgba(251, 191, 36, 0.15); color: var(--accent-yellow); }
.stat-icon.purple { background: rgba(168, 85, 247, 0.15); color: var(--accent-purple); }
.stat-icon.green { background: rgba(34, 197, 94, 0.15); color: var(--accent-green); }
.stat-icon.red { background: rgba(239, 68, 68, 0.15); color: var(--accent-red); }

.stat-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1px;
    color: var(--text-muted);
    text-transform: uppercase;
}
.stat-value-big { font-size: 32px; font-weight: 800; line-height: 1; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.stat-value-big.yellow { color: var(--accent-yellow); text-shadow: 0 0 30px rgba(251, 191, 36, 0.4); }
.stat-value-big.green { color: var(--accent-green); text-shadow: 0 0 30px rgba(34, 197, 94, 0.4); }

.stat-details { display: flex; flex-direction: column; gap: 6px; }
.stat-row { display: flex; align-items: center; gap: 10px; font-size: 12px; }
.stat-row-value { font-weight: 600; margin-left: auto; color: var(--accent-green); }
.dot { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; }
.dot.blue { background: var(--accent-blue); }
.dot.green { background: var(--accent-green); }
.dot.yellow { background: var(--accent-yellow); }
.dot.purple { background: var(--accent-purple); }
.stat-row-label { flex: 1; color: var(--text-secondary); }

/* Info Bar - EXACT COPY FROM ADMIN */
.info-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
    font-size: 13px;
    color: var(--text-secondary);
}
.info-bar > i { color: var(--accent-purple); }

/* Panels - EXACT COPY FROM ADMIN */
.panel {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    overflow: hidden;
    margin-bottom: 20px;
}

/* Support Panel Animation */
.support-panel {
    position: relative;
    overflow: hidden;
}
.support-bg-animation {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}
.support-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    opacity: 0.4;
    animation: floatOrb 8s ease-in-out infinite;
}
.support-orb-1 {
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.6), transparent 70%);
    top: -30px;
    left: 10%;
    animation-delay: 0s;
}
.support-orb-2 {
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.5), transparent 70%);
    bottom: -20px;
    right: 15%;
    animation-delay: -3s;
}
.support-orb-3 {
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.5), transparent 70%);
    top: 50%;
    left: 60%;
    transform: translateY(-50%);
    animation-delay: -5s;
}
@keyframes floatOrb {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(15px, -10px) scale(1.1); }
    50% { transform: translate(-10px, 15px) scale(0.95); }
    75% { transform: translate(-15px, -5px) scale(1.05); }
}
.support-panel .panel-header,
.support-panel .panel-body {
    position: relative;
    z-index: 1;
}

.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}
.panel-title { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; }
.panel-title i { color: var(--accent-purple); }
.panel-actions { display: flex; align-items: center; gap: 8px; }
.panel-body { padding: 20px; }
.panel-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.1);
}

/* Buttons - EXACT COPY FROM ADMIN */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-sm { padding: 8px 14px; font-size: 12px; }

.btn-primary {
    background: var(--gradient-purple);
    color: white;
    box-shadow: var(--shadow-glow-purple);
}
.btn-primary:hover:not(:disabled) { transform: translateY(-2px); }

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

.btn-success { background: rgba(34, 197, 94, 0.2); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.3); }
.btn-success:hover:not(:disabled) { background: rgba(34, 197, 94, 0.3); box-shadow: 0 0 15px rgba(34, 197, 94, 0.2); transform: translateY(-2px); }

.btn-warning { background: rgba(251, 191, 36, 0.2); color: #fbbf24; border: 1px solid rgba(251, 191, 36, 0.3); }
.btn-warning:hover:not(:disabled) { background: rgba(251, 191, 36, 0.3); box-shadow: 0 0 15px rgba(251, 191, 36, 0.2); transform: translateY(-2px); }

.btn-danger { background: rgba(239, 68, 68, 0.2); color: #f87171; border: 1px solid rgba(239, 68, 68, 0.3); }
.btn-danger:hover:not(:disabled) { background: rgba(239, 68, 68, 0.3); box-shadow: 0 0 15px rgba(239, 68, 68, 0.2); transform: translateY(-2px); }

.btn-info { background: rgba(59, 130, 246, 0.2); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.3); }
.btn-info:hover:not(:disabled) { background: rgba(59, 130, 246, 0.3); box-shadow: 0 0 15px rgba(59, 130, 246, 0.2); transform: translateY(-2px); }

.btn-icon {
    width: 40px; height: 40px;
    padding: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
}
.btn-icon:hover { background: var(--bg-card-hover); color: var(--text-primary); }


/* Form Inputs - EXACT COPY FROM ADMIN */
.form-group { margin-bottom: 16px; }
.form-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}
.form-label i { color: var(--accent-purple); font-size: 14px; }

.form-input {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s;
}
.form-input:focus {
    outline: none;
    border-color: var(--accent-purple);
    box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.15);
}
.form-input::placeholder { color: var(--text-muted); }
.form-input-sm { padding: 10px 12px; font-size: 13px; }

textarea.form-input {
    min-height: 150px;
    max-height: 400px;
    resize: vertical;
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 13px;
}

select.form-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 14px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 44px;
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }

.radio-group { display: flex; gap: 12px; flex-wrap: wrap; }
.radio-option { display: flex; align-items: center; cursor: pointer; }
.radio-option input[type="radio"] { display: none; }
.radio-btn {
    padding: 10px 18px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    color: var(--text-secondary);
    transition: all 0.2s;
}
.radio-option input[type="radio"]:checked + .radio-btn {
    background: var(--accent-purple);
    border-color: var(--accent-purple);
    color: white;
}
.radio-btn:hover { border-color: var(--accent-purple); }

/* Base64 Servers List */
.base64-servers-list { display: flex; flex-direction: column; gap: 8px; }
.base64-server-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: all 0.2s;
}
.base64-server-item:hover { border-color: var(--accent-purple); }
.server-info { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; }
.server-protocol {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
}
.server-name {
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}
.server-address {
    font-size: 12px;
    color: var(--text-muted);
    font-family: monospace;
}
.server-actions { display: flex; gap: 8px; }

.field-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 10px;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    line-height: 1.5;
}
.field-hint > i { color: var(--accent-purple); margin-right: 6px; }

/* Parser Info Block */
.parser-info-block {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
    margin-bottom: 16px;
}
.parser-info-title {
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-primary);
    font-size: 13px;
}
.parser-info-title i { color: var(--accent-purple); margin-right: 6px; }
.parser-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.parser-tag {
    background: var(--bg-card);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    border: 1px solid var(--border-color);
}
.parser-tag i { color: var(--accent-green); margin-right: 4px; }
.parser-discord { font-size: 11px; color: var(--text-muted); }
.parser-discord i { margin-right: 4px; }
.parser-discord strong { color: var(--accent-purple); }

/* File Upload */
.file-upload-area {
    border: 2px dashed var(--border-light);
    border-radius: var(--radius-lg);
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    background: var(--bg-input);
    transition: all 0.2s;
}
.file-upload-area:hover, .file-upload-area.dragover {
    border-color: var(--accent-purple);
    background: rgba(168, 85, 247, 0.1);
}
.file-upload-area i { font-size: 40px; color: var(--accent-purple); margin-bottom: 12px; display: block; }
.file-upload-text { font-size: 15px; color: var(--text-primary); margin-bottom: 6px; font-weight: 500; }
.file-upload-subtext { font-size: 13px; color: var(--text-muted); }

.image-preview {
    max-width: 250px;
    max-height: 250px;
    margin: 16px auto;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
    display: none;
}
.image-preview img { width: 100%; height: 100%; object-fit: contain; }

.qr-error-container {
    margin: 12px 0;
    padding: 14px 16px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-md);
    color: var(--accent-red);
    font-size: 13px;
    display: none;
}
.qr-error-container i { margin-right: 8px; }

/* Output Sections */
.output-section { display: none; margin-top: 20px; }
.result-pre {
    margin: 0;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 12px;
    line-height: 1.6;
    word-break: break-all;
    white-space: pre-wrap;
    background: var(--bg-input);
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    max-height: 300px;
    overflow-y: auto;
}
.result-actions { justify-content: center; }

/* Filter Row */
.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
}
.filter-info { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.filter-actions { display: flex; gap: 8px; }


/* Server Cards (Parser Results) */
.server-card,
.result-container {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.2s;
}
.server-card:hover,
.result-container:hover { background: var(--bg-card-hover); }

.server-detail { display: flex; flex-direction: column; gap: 4px; }
.server-detail-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.server-detail-value {
    font-size: 12px;
    color: var(--text-primary);
    background: var(--bg-input);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    font-family: 'JetBrains Mono', monospace;
    word-break: break-all;
}

.server-title-with-flag { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.country-flag, .flag { font-family: "Apple Color Emoji", "Segoe UI Emoji", sans-serif !important; font-size: 1.2em; }

/* Ping Indicator */
.ping-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    min-width: 80px;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}
.ping-indicator.checking { background: rgba(59, 130, 246, 0.2); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.3); }
.ping-indicator.success, .ping-indicator.excellent { background: rgba(34, 197, 94, 0.2); color: #4ade80; border: 1px solid rgba(34, 197, 94, 0.3); }
.ping-indicator.good { background: rgba(16, 185, 129, 0.2); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.3); }
.ping-indicator.warning, .ping-indicator.slow { background: rgba(251, 191, 36, 0.2); color: #fbbf24; border: 1px solid rgba(251, 191, 36, 0.3); }
.ping-indicator.very_slow { background: rgba(249, 115, 22, 0.2); color: #fb923c; border: 1px solid rgba(249, 115, 22, 0.3); }
.ping-indicator.error, .ping-indicator.offline { background: rgba(239, 68, 68, 0.2); color: #f87171; border: 1px solid rgba(239, 68, 68, 0.3); }
.ping-indicator.timeout { background: rgba(100, 116, 139, 0.2); color: #94a3b8; border: 1px solid rgba(100, 116, 139, 0.3); }
.ping-indicator.disabled { background: rgba(75, 85, 99, 0.2); color: #9ca3af; border: 1px solid rgba(75, 85, 99, 0.3); }

/* Support Card */
.support-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 28px;
    margin: 32px auto 20px;
    text-align: center;
    max-width: 420px;
    position: relative;
    overflow: hidden;
}
.support-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ef4444, #f97316, #fbbf24);
}
.support-icon { font-size: 32px; margin-bottom: 16px; }
.support-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; color: var(--text-primary); }
.support-text { font-size: 13px; margin-bottom: 20px; color: var(--text-secondary); }
.support-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.support-btn:hover { transform: translateY(-2px); box-shadow: 0 0 20px rgba(239, 68, 68, 0.4); }

/* Footer */
.site-footer {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 24px;
    margin-top: 24px;
}
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    gap: 24px;
    flex-wrap: wrap;
}
.footer-info { flex: 1; min-width: 200px; }
.footer-title { font-size: 16px; font-weight: 700; margin-bottom: 4px; color: var(--accent-purple); }
.footer-description { font-size: 12px; color: var(--text-secondary); }
.footer-links { text-align: right; }
.footer-link { font-size: 11px; color: var(--text-muted); margin-bottom: 4px; }
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}
.footer-copyright, .footer-version { font-size: 11px; color: var(--text-muted); }
.footer-version { font-family: 'JetBrains Mono', monospace; }

/* Toast */
.toast {
    position: fixed;
    bottom: 24px; right: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 4000;
    transform: translateX(400px);
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}
.toast.show { transform: translateX(0); }
.toast.success { border-color: var(--accent-green); color: var(--accent-green); }
.toast.error { border-color: var(--accent-red); color: var(--accent-red); }

/* Loading Indicator */
.loading-indicator {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(13, 15, 26, 0.95);
    z-index: 3000;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 16px;
}
.loading-spinner {
    width: 50px; height: 50px;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-purple);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Modal */
.modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal-backdrop.show { display: flex; }
.modal-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 700px;
    max-height: 85vh;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}
.modal-title { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; }
.modal-title i { color: var(--accent-purple); }
.modal-close {
    width: 32px; height: 32px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-muted);
    transition: all 0.2s;
}
.modal-close:hover { background: var(--accent-red); color: white; border-color: var(--accent-red); }
.modal-body { 
    padding: 20px; 
    overflow-y: auto; 
    flex: 1; 
    color: var(--text-primary);
    line-height: 1.7;
}
.modal-body h3, .modal-body h4 { color: var(--text-primary); margin: 20px 0 12px; }
.modal-body p { color: #d1d5db; margin-bottom: 12px; }
.modal-body ul, .modal-body ol { margin-left: 20px; margin-bottom: 16px; color: #d1d5db; }
.modal-body li { margin-bottom: 8px; }
.modal-body a { color: var(--accent-purple); text-decoration: underline; }
.modal-body strong { color: var(--text-primary); }

/* Guide blocks in modal */
.modal-body .warning-block,
.modal-body .xhttp-info {
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.4);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    color: #e5e7eb;
}
.modal-body .warning-block h4,
.modal-body .xhttp-info h4 { color: var(--accent-yellow); margin-top: 0; }

.modal-body .success-block {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.4);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    color: #e5e7eb;
}
.modal-body .success-block h4 { color: var(--accent-green); margin-top: 0; }

.modal-body .danger-block {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.4);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    color: #e5e7eb;
}
.modal-body .danger-block h4 { color: var(--accent-red); margin-top: 0; }

.modal-body .info-block {
    background: rgba(168, 85, 247, 0.15);
    border: 1px solid rgba(168, 85, 247, 0.4);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 16px;
    color: #e5e7eb;
}

/* Modal Detail Rows */
.detail-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}
.detail-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.detail-value {
    font-size: 14px;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
    word-break: break-all;
}
.vless-url-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}
.vless-url-box {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px;
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    color: var(--text-secondary);
    word-break: break-all;
    line-height: 1.5;
}
.input-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}
.input-label i { color: var(--accent-purple); }
.modal-body .info-block h4 { color: var(--accent-purple); margin-top: 0; }

/* Scrollbar */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-input); border-radius: 4px; }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-purple); }

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
    padding: 10px;
    border-radius: var(--radius-md);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 199;
    backdrop-filter: blur(4px);
}
.mobile-menu-overlay.show { display: block; }

/* Mobile Menu */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100%;
    background: var(--bg-card);
    z-index: 200;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
}
.mobile-menu.show {
    transform: translateX(0);
}

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

.mobile-menu-close {
    width: 36px;
    height: 36px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.2s;
}
.mobile-menu-close:hover {
    background: var(--accent-red);
    color: white;
    border-color: var(--accent-red);
}

.mobile-nav {
    padding: 12px;
}

.mobile-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 4px;
}
.mobile-nav-item:hover {
    color: var(--text-primary);
    background: rgba(255,255,255,0.05);
}
.mobile-nav-item.active {
    color: white;
    background: var(--accent-purple);
    box-shadow: 0 2px 10px rgba(168, 85, 247, 0.4);
}
.mobile-nav-item i {
    font-size: 16px;
    width: 20px;
    text-align: center;
}

/* Tablet & Mobile - show hamburger menu */
@media (max-width: 1350px) {
    .menu-toggle { display: flex; }
    .mobile-menu { display: block; }
    .main-nav { display: none; }
    .top-header { 
        justify-content: flex-start;
    }
    .header-left {
        position: relative;
        left: auto;
        gap: 12px;
    }
    .header-right {
        position: absolute;
        right: 24px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .top-header { 
        padding: 12px 16px; 
    }
    .header-right {
        right: 16px;
    }
    .logo-text { 
        font-size: 14px; 
    }
    .logo-text .version-num {
        display: none;
    }
    .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    .content-area { padding: 16px; }
    .stats-row { gap: 12px; }
    .stat-card { padding: 16px; }
    .stat-value-big { font-size: 24px; }
    .panel-body { padding: 16px; }
    .panel-footer { padding: 12px 16px; }
    .btn { padding: 10px 16px; font-size: 13px; }
    .toast { bottom: 12px; right: 12px; left: 12px; transform: translateY(200px); }
    .toast.show { transform: translateY(0); }
    .footer-content { flex-direction: column; text-align: center; }
    .footer-links { text-align: center; }
}

@media (max-width: 480px) {
    .logo-text {
        font-size: 12px;
    }
}
