:root {
    --bg-primary: #0d0d0d;
    --bg-secondary: #141414;
    --bg-card: #1a1a1a;
    --bg-card-hover: #222222;
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-accent: rgba(0, 136, 255, 0.3);
    --accent-primary: #0088ff;
    --accent-secondary: #00d4ff;
    --accent-gradient: linear-gradient(135deg, #0088ff 0%, #00d4ff 100%);
    --text-primary: #ffffff;
    --text-secondary: #8b8b8b;
    --text-muted: #5a5a5a;
    --success: #34d399;
    --danger: #f87171;
    --warning: #fbbf24;
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 40px rgba(0, 136, 255, 0.15);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: #050510;
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -2;
    background:
        radial-gradient(ellipse 80% 50% at 20% -10%, rgba(0, 100, 255, 0.18), transparent 70%),
        radial-gradient(ellipse 60% 50% at 80% 10%, rgba(120, 0, 255, 0.12), transparent 70%),
        radial-gradient(ellipse 70% 40% at 50% 100%, rgba(0, 180, 255, 0.1), transparent 70%),
        radial-gradient(circle 600px at 30% 60%, rgba(0, 136, 255, 0.06), transparent),
        radial-gradient(circle 400px at 70% 40%, rgba(123, 97, 255, 0.06), transparent);
    animation: bgShift 20s ease-in-out infinite alternate;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -1;
    background-image:
        radial-gradient(circle 1px at 15% 25%, rgba(255,255,255,0.08) 0%, transparent 100%),
        radial-gradient(circle 1px at 85% 15%, rgba(255,255,255,0.06) 0%, transparent 100%),
        radial-gradient(circle 1px at 45% 75%, rgba(255,255,255,0.05) 0%, transparent 100%),
        radial-gradient(circle 1px at 70% 60%, rgba(255,255,255,0.07) 0%, transparent 100%),
        radial-gradient(circle 1px at 25% 90%, rgba(255,255,255,0.04) 0%, transparent 100%),
        radial-gradient(circle 1px at 90% 80%, rgba(255,255,255,0.06) 0%, transparent 100%);
    animation: starTwinkle 8s ease-in-out infinite alternate;
}

@keyframes bgShift {
    0% {
        background:
            radial-gradient(ellipse 80% 50% at 20% -10%, rgba(0, 100, 255, 0.18), transparent 70%),
            radial-gradient(ellipse 60% 50% at 80% 10%, rgba(120, 0, 255, 0.12), transparent 70%),
            radial-gradient(ellipse 70% 40% at 50% 100%, rgba(0, 180, 255, 0.1), transparent 70%),
            radial-gradient(circle 600px at 30% 60%, rgba(0, 136, 255, 0.06), transparent),
            radial-gradient(circle 400px at 70% 40%, rgba(123, 97, 255, 0.06), transparent);
    }
    100% {
        background:
            radial-gradient(ellipse 80% 50% at 80% -10%, rgba(0, 136, 255, 0.15), transparent 70%),
            radial-gradient(ellipse 60% 50% at 20% 20%, rgba(100, 0, 255, 0.1), transparent 70%),
            radial-gradient(ellipse 70% 40% at 50% 90%, rgba(0, 200, 255, 0.12), transparent 70%),
            radial-gradient(circle 600px at 70% 50%, rgba(0, 100, 255, 0.07), transparent),
            radial-gradient(circle 400px at 30% 70%, rgba(123, 97, 255, 0.05), transparent);
    }
}

@keyframes starTwinkle {
    0% { opacity: 0.4; }
    100% { opacity: 1; }
}

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

/* ===== HEADER ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(8, 8, 8, 0.8);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 16px 0;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-glow);
}

.logo-icon svg {
    width: 24px;
    height: 24px;
    fill: white;
}

.logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-text span {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav {
    display: flex;
    gap: 8px;
}

.nav-link {
    padding: 10px 18px;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
    background: transparent;
}

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

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

.mobile-menu-btn {
    display: none;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    color: var(--text-primary);
    padding: 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
}

/* ===== MAIN CONTENT ===== */
.main {
    padding: 60px 0 80px;
}

.hero {
    text-align: center;
    padding: 80px 0 60px;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(0, 136, 255, 0.12) 0%, rgba(123, 97, 255, 0.06) 40%, transparent 70%);
    pointer-events: none;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(0, 136, 255, 0.1);
    border: 1px solid var(--border-accent);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-primary);
    margin-bottom: 24px;
}

.hero-badge::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    letter-spacing: -2px;
    line-height: 1.1;
    margin-bottom: 20px;
    background: linear-gradient(to bottom right, #fff 20%, rgba(255,255,255,0.6));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero-subtitle strong {
    color: var(--accent-primary);
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 32px;
    border-radius: var(--radius-lg);
    font-size: 1rem;
    font-weight: 700;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 4px 20px rgba(0, 136, 255, 0.3), 0 0 0 1px rgba(0, 136, 255, 0.1) inset;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 136, 255, 0.4), 0 0 0 1px rgba(0, 136, 255, 0.2) inset;
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 12px rgba(0, 136, 255, 0.3);
}

.btn-secondary {
    background: rgba(26, 26, 26, 0.6);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.btn-secondary:hover {
    background: rgba(34, 34, 34, 0.8);
    border-color: rgba(255, 255, 255, 0.15);
}

.btn-icon {
    width: 48px;
    height: 48px;
    padding: 0;
    border-radius: var(--radius-md);
}

.share-btn {
    transition: all 0.2s ease;
    position: relative;
}

.share-btn:hover {
    background: rgba(0, 136, 255, 0.15) !important;
    border-color: rgba(0, 136, 255, 0.3) !important;
}

.share-dropdown {
    position: absolute;
    bottom: calc(100% + 8px);
    right: 0;
    background: rgba(20, 20, 20, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 6px;
    display: none;
    flex-direction: column;
    gap: 2px;
    min-width: 180px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: dropUp 0.2s ease;
    z-index: 50;
}

.share-dropdown.active {
    display: flex;
}

@keyframes dropUp {
    from { opacity: 0; transform: translateY(8px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.share-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 0.85rem;
    font-weight: 500;
    transition: background 0.15s ease;
    white-space: nowrap;
}

.share-dropdown a:hover {
    background: rgba(255, 255, 255, 0.08);
}

.share-dropdown .share-vk svg { color: #0077FF; }
.share-dropdown .share-tg svg { color: #26A5E4; }

.share-dropdown a svg {
    flex-shrink: 0;
}

/* ===== CARDS ===== */
.card {
    background: rgba(26, 26, 26, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    padding: 28px;
    transition: var(--transition);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.card:hover {
    border-color: rgba(0, 136, 255, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 136, 255, 0.1);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.card-grid:has(.proxy-card:only-child) {
    justify-content: center;
    max-width: 400px;
    margin: 0 auto;
}

/* ===== PROXY CARD ===== */
.proxy-card {
    position: relative;
    background: rgba(26, 26, 26, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    padding: 24px;
    transition: var(--transition);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    overflow: hidden;
}

.proxy-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    opacity: 0;
    transition: var(--transition);
}

.proxy-card:hover {
    border-color: rgba(0, 136, 255, 0.4);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 136, 255, 0.15), 0 0 60px rgba(0, 136, 255, 0.1);
}

.proxy-card:hover::before {
    opacity: 1;
}
    position: relative;
    overflow: hidden;
}

.proxy-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    opacity: 0;
    transition: var(--transition);
}

.proxy-card:hover {
    border-color: var(--border-accent);
    box-shadow: var(--shadow-glow);
}

.proxy-card:hover::before {
    opacity: 1;
}

.proxy-card.offline {
    opacity: 0.5;
}

.proxy-card.offline::before {
    background: var(--danger);
    opacity: 0.5;
}

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

.proxy-country {
    display: flex;
    align-items: center;
    gap: 8px;
}

.proxy-country .flag {
    font-size: 1.5rem;
}

.proxy-country .name {
    font-weight: 600;
    font-size: 0.95rem;
}

.proxy-status {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(52, 211, 153, 0.1);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--success);
}

.proxy-status.offline {
    background: rgba(248, 113, 113, 0.1);
    color: var(--danger);
}

.proxy-status .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}

.proxy-status.checking {
    background: rgba(251, 191, 36, 0.1);
    color: var(--warning);
}

.proxy-host {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    font-family: 'SF Mono', 'Fira Code', monospace;
    word-break: break-all;
}

.proxy-details {
    display: flex;
    gap: 16px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.proxy-details span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.proxy-actions {
    display: flex;
    gap: 12px;
    padding-top: 20px;
    border-top: 1px solid var(--border-subtle);
}

.proxy-actions .btn {
    flex: 1;
    padding: 14px 20px;
}

/* ===== BADGE ===== */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: rgba(0, 136, 255, 0.1);
    border: 1px solid var(--border-accent);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent-primary);
}

/* ===== SECTION ===== */
.section {
    margin-top: 80px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 16px;
}

.section-title {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.section-subtitle {
    color: var(--text-secondary);
    margin-top: 8px;
    font-size: 1rem;
}

/* ===== STATS ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 40px;
}

.stat-card {
    background: rgba(26, 26, 26, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    transition: var(--transition);
}

.stat-card:hover {
    border-color: rgba(0, 136, 255, 0.3);
    transform: translateY(-2px);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.user-counter {
    text-align: center;
    padding: 20px;
    margin: 16px 0;
    background: rgba(26, 26, 26, 0.6);
    border: 1px solid rgba(0, 136, 255, 0.2);
    border-radius: 16px;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.user-counter-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.user-counter-value {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.user-counter-fixed {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 50;
    padding: 12px 16px;
    background: rgba(26, 26, 26, 0.9);
    border: 1px solid rgba(52, 211, 153, 0.3);
    border-radius: 14px;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4), 0 0 20px rgba(52, 211, 153, 0.1);
    text-align: center;
    min-width: 100px;
}

.user-counter-fixed-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.user-counter-fixed-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.user-counter-fixed-icon {
    font-size: 1.2rem;
    animation: pulse-green 2s ease-in-out infinite;
}

@keyframes pulse-green {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.9);
    }
}

.user-counter-fixed-value {
    font-size: 1.1rem;
    font-weight: 800;
    background: linear-gradient(135deg, #34d399, #10b981);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

@media (max-width: 768px) {
    .user-counter-fixed {
        bottom: 16px;
        right: 16px;
        padding: 10px 14px;
        min-width: 90px;
    }

    .user-counter-fixed-label {
        font-size: 0.65rem;
    }

    .user-counter-fixed-icon {
        font-size: 1rem;
    }

    .user-counter-fixed-value {
        font-size: 1rem;
    }
}

/* Hide on telegram mode */
body.telegram-mode .user-counter-fixed {
    display: none;
}

/* ===== FILTERS ===== */
.filters {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.filter-select {
    padding: 12px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    min-width: 160px;
}

.filter-select:hover,
.filter-select:focus {
    border-color: var(--border-accent);
    outline: none;
}

.filter-select option {
    background: var(--bg-card);
    color: var(--text-primary);
}

/* ===== PAGINATION ===== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 48px;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
}

.pagination a:hover {
    border-color: var(--border-accent);
    color: var(--accent-primary);
}

.pagination .active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

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

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.95) translateY(20px);
    transition: var(--transition);
}

.modal-overlay.active .modal {
    transform: scale(1) translateY(0);
}

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

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.modal-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1.5rem;
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--danger);
    color: white;
}

.modal-body {
    padding: 24px;
}

.modal-field {
    margin-bottom: 20px;
}

.modal-field label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent-primary);
    margin-bottom: 8px;
}

.modal-field input {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: 'SF Mono', 'Fira Code', monospace;
}

.modal-field input:focus {
    outline: none;
    border-color: var(--border-accent);
}

.modal-copy-btn {
    flex-shrink: 0;
    padding: 0 16px;
    background: rgba(0, 136, 255, 0.1);
    border: none;
    border-radius: var(--radius-sm);
    color: var(--accent-primary);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
}

.modal-copy-btn:hover {
    background: var(--accent-primary);
    color: white;
}

.modal-copy-btn.copied {
    background: var(--success);
    color: white;
}

.modal-guide {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 24px;
}

.modal-guide h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.modal-guide ol {
    padding-left: 20px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.8;
}

.modal-footer {
    padding: 24px;
    border-top: 1px solid var(--border-subtle);
}

/* ===== FAQ ===== */
.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 16px;
    transition: var(--transition);
}

.faq-item:hover {
    border-color: rgba(255,255,255,0.1);
}

.faq-item h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.faq-item h3::before {
    content: '?';
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 136, 255, 0.1);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
}

.faq-item p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.7;
    padding-left: 40px;
}

/* ===== GUIDE CARDS ===== */
.guide-card {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 28px;
    transition: var(--transition);
}

.guide-card:hover {
    border-color: rgba(255,255,255,0.1);
}

.guide-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.guide-card-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    font-size: 1.5rem;
}

.guide-card-icon.ios {
    background: rgba(0, 136, 255, 0.1);
}

.guide-card-icon.android {
    background: rgba(52, 211, 153, 0.1);
}

.guide-card-icon.pc {
    background: rgba(251, 191, 36, 0.1);
}

.guide-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
}

.guide-card ol {
    padding-left: 24px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 2;
}

.guide-card li {
    margin-bottom: 4px;
}

/* ===== CHECKER ===== */
.checker-card {
    max-width: 500px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 40px;
}

.checker-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.form-group input {
    width: 100%;
    padding: 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--border-accent);
}

.checker-result {
    margin-top: 24px;
    padding: 24px;
    border-radius: var(--radius-lg);
    text-align: center;
    display: none;
}

.checker-result.show {
    display: block;
    animation: fadeIn 0.3s ease;
}

.checker-result.online {
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.2);
    color: var(--success);
}

.checker-result.offline {
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.2);
    color: var(--danger);
}

.checker-result h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.checker-result p {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* ===== ADS ===== */
.ads-section {
    margin-top: 80px;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.ads-title {
    text-align: center;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.ad-card {
    background: rgba(26, 26, 26, 0.6);
    border: 1px solid rgba(0, 136, 255, 0.2);
    border-radius: var(--radius-xl);
    padding: 28px;
    display: flex;
    align-items: center;
    gap: 24px;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    transition: var(--transition);
}

.ad-card:hover {
    border-color: rgba(0, 136, 255, 0.4);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 136, 255, 0.1);
    transform: translateY(-2px);
}

.ad-logo {
    width: 64px;
    height: 64px;
    background: rgba(0, 136, 255, 0.15);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.ad-logo svg {
    stroke: var(--accent-primary);
}

.ad-content {
    flex: 1;
}

.ad-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.ad-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.ad-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--accent-primary);
    background: rgba(0, 136, 255, 0.1);
    padding: 4px 10px;
    border-radius: 100px;
}

/* ===== FULL LIST CARD ===== */
.full-list-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 24px;
    margin-top: 30px;
    background: linear-gradient(135deg, rgba(0, 136, 255, 0.1), rgba(123, 97, 255, 0.06));
    border: 1px solid rgba(0, 136, 255, 0.2);
    border-radius: 20px;
    flex-wrap: wrap;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.full-list-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 136, 255, 0.2);
    border-radius: 14px;
    flex-shrink: 0;
}

.full-list-icon svg {
    stroke: var(--accent-primary);
}

.full-list-info {
    flex: 1;
    min-width: 200px;
}

.full-list-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.full-list-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.full-list-btn {
    white-space: nowrap;
}

/* ===== FOOTER ===== */
.footer {
    margin-top: 80px;
    padding: 48px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    background: rgba(8, 8, 8, 0.5);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 32px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent-primary);
}

.footer-copyright {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.6;
}

.footer-copyright a {
    color: var(--text-secondary);
    text-decoration: none;
}

.footer-legal {
    font-size: 0.75rem;
    opacity: 0.7;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes spin {
    to { transform: rotate(360deg); }
}

.animate-fadeIn {
    animation: fadeIn 0.5s ease;
}

.animate-fadeInUp {
    animation: fadeInUp 0.5s ease;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255,255,255,0.2);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.generate-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 24px;
    margin-top: 30px;
    background: linear-gradient(135deg, rgba(0, 136, 255, 0.1), rgba(123, 97, 255, 0.06));
    border: 1px solid rgba(0, 136, 255, 0.2);
    border-radius: 20px;
    flex-wrap: wrap;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.generate-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 136, 255, 0.2);
    border-radius: 14px;
    flex-shrink: 0;
}

.generate-icon svg {
    stroke: var(--accent-primary);
}

.generate-info {
    flex: 1;
    min-width: 200px;
}

.generate-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.generate-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.generate-btn {
    white-space: nowrap;
}

.generate-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.refresh-btn {
    padding: 14px 16px;
}

.refresh-btn svg {
    transition: transform 0.3s ease;
}

.refresh-btn.loading svg {
    animation: spin 0.8s linear infinite;
}

/* ===== EMPTY / ERROR STATES ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.info-message {
    padding: 16px 20px;
    background: rgba(0, 136, 255, 0.1);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-md);
    color: var(--accent-primary);
    font-weight: 500;
    text-align: center;
}

.error-message {
    padding: 16px 20px;
    background: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.2);
    border-radius: var(--radius-md);
    color: var(--danger);
    font-weight: 500;
    text-align: center;
}

/* ===== LOADING ===== */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(13, 13, 13, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--border-subtle);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-secondary);
        border-bottom: 1px solid var(--border-subtle);
        flex-direction: column;
        padding: 16px;
        gap: 8px;
    }

    .nav.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero {
        padding: 40px 0;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .btn {
        padding: 14px 24px;
        font-size: 0.95rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .ad-card {
        flex-direction: column;
        text-align: center;
    }

    .proxy-actions {
        flex-direction: column;
    }

    .generate-card {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 20px 16px;
    }

    .generate-icon {
        width: 48px;
        height: 48px;
    }

    .generate-info {
        min-width: auto;
    }

    .generate-btn {
        width: 100%;
        justify-content: center;
    }

    .generate-actions {
        width: 100%;
        justify-content: center;
    }

    .full-list-card {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 20px 16px;
    }

    .full-list-icon {
        width: 48px;
        height: 48px;
    }

    .full-list-info {
        min-width: auto;
    }

    .full-list-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .stat-value {
        font-size: 1.75rem;
    }

    .filters {
        flex-direction: column;
    }

    .filter-select {
        width: 100%;
    }
}

.donate-hint {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 24px;
    padding: 16px 20px;
    background: linear-gradient(135deg, rgba(255, 182, 193, 0.06), rgba(255, 107, 157, 0.03));
    border: 1px solid rgba(255, 107, 157, 0.15);
    border-radius: 16px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.donate-hint-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 107, 157, 0.2);
    border-radius: 12px;
    color: #ff6b9d;
}

.donate-hint-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.donate-hint-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
}

.donate-hint-subtitle {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.donate-hint-subtitle a {
    color: #ff6b9d;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.donate-hint-subtitle a:hover {
    color: #ff93ba;
}

@media (max-width: 640px) {
    .donate-hint {
        margin-top: 20px;
        padding: 14px 16px;
        gap: 12px;
    }

    .donate-hint-icon {
        width: 36px;
        height: 36px;
    }
}

.priority-proxy {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px 24px;
    margin-top: 30px;
    background: linear-gradient(135deg, rgba(0, 136, 255, 0.12), rgba(123, 97, 255, 0.08));
    border: 1px solid rgba(0, 136, 255, 0.25);
    border-radius: 20px;
    flex-wrap: wrap;
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
}

.priority-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(251, 191, 36, 0.15);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #fbbf24;
    white-space: nowrap;
}

.priority-badge svg {
    stroke: #fbbf24;
}

.priority-info {
    flex: 1;
    min-width: 200px;
}

.priority-host {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.priority-details {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.priority-details span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.priority-ping {
    color: var(--text-secondary);
}

.priority-ping .ping-value {
    min-width: 50px;
    display: inline-block;
}

.priority-status {
    color: var(--text-secondary);
}

.priority-dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

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

.priority-actions .btn {
    white-space: nowrap;
}

.priority-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 8px;
}

.priority-qr-body {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    animation: qrFadeIn 0.3s ease;
}

.priority-qr.open .priority-qr-body {
    display: flex;
}

.qr-toggle-btn {
    font-size: 0.8rem !important;
    padding: 8px 20px !important;
    border-radius: 10px !important;
}

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

.priority-qr-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.priority-qr img,
.priority-qr-code canvas {
    border-radius: 8px;
    background: #1a1a1a;
    padding: 8px;
}

.priority-qr-code {
    min-height: 120px;
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.priority-qr-code canvas {
    width: 120px !important;
    height: 120px !important;
}

@media (max-width: 640px) {
    .priority-proxy {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        gap: 16px;
        padding: 20px 16px;
    }

    .priority-badge {
        justify-content: center;
    }

    .priority-info {
        min-width: auto;
    }

    .priority-details {
        justify-content: center;
    }

    .priority-actions {
        flex-direction: column;
    }

    .priority-actions .btn {
        width: 100%;
    }

    .priority-qr {
        padding-top: 12px;
    }

    .priority-qr img {
        width: 100px;
        height: 100px;
    }
}

body.telegram-mode {
    padding-top: 0;
}

body.telegram-mode .header {
    display: none;
}

body.telegram-mode .tg-hide {
    display: none !important;
}

body.telegram-mode .tg-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: rgba(13, 13, 13, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    position: sticky;
    top: 0;
    z-index: 100;
}

.tg-header {
    display: none;
}

.tg-header-title {
    font-size: 1.1rem;
    font-weight: 600;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tg-header-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.tg-header-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

body.telegram-mode .main {
    padding-top: 20px;
}

body.telegram-mode .hero {
    padding: 30px 0 20px;
}

body.telegram-mode .section {
    padding-top: 30px;
}

body.telegram-mode .priority-proxy {
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 16px !important;
    background: linear-gradient(135deg, rgba(0, 136, 255, 0.15), rgba(123, 97, 255, 0.1)) !important;
    border: 1px solid rgba(0, 136, 255, 0.3) !important;
    border-radius: 16px !important;
}

body.telegram-mode .priority-badge {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 4px 10px !important;
    background: rgba(251, 191, 36, 0.15) !important;
    border: 1px solid rgba(251, 191, 36, 0.3) !important;
    border-radius: 999px !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    color: #fbbf24 !important;
    width: fit-content !important;
}

body.telegram-mode .priority-badge svg {
    stroke: #fbbf24 !important;
}

body.telegram-mode .priority-info {
    flex: none !important;
    text-align: center !important;
    min-width: auto !important;
}

body.telegram-mode .priority-host {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #ffffff !important;
}

body.telegram-mode .priority-details {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    font-size: 0.8rem !important;
    color: #8b8b8b !important;
}

body.telegram-mode .priority-details span {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
}

body.telegram-mode .priority-ping {
    color: #8b8b8b !important;
}

body.telegram-mode .priority-ping .ping-value {
    min-width: 50px !important;
    display: inline-block !important;
}

body.telegram-mode .priority-status {
    color: #8b8b8b !important;
}

body.telegram-mode .priority-dot {
    width: 8px !important;
    height: 8px !important;
    background: #34d399 !important;
    border-radius: 50% !important;
    animation: pulse 2s ease-in-out infinite !important;
}

body.telegram-mode .priority-actions {
    display: flex !important;
    width: 100% !important;
    flex-direction: row !important;
    gap: 10px !important;
}

body.telegram-mode .priority-actions .btn {
    flex: 1 !important;
    white-space: nowrap !important;
}

body.telegram-mode .priority-actions .btn.btn-primary {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    padding: 14px 16px !important;
    background: linear-gradient(135deg, #0088ff 0%, #00d4ff 100%) !important;
    border-radius: 14px !important;
    color: #fff !important;
    font-weight: 600 !important;
    text-decoration: none !important;
}

body.telegram-mode .priority-actions .btn.btn-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 48px !important;
    height: 48px !important;
    padding: 0 !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 14px !important;
}

body.telegram-mode .priority-qr {
    display: none !important;
}

.tg-miniapp-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px 16px;
    padding-bottom: max(12px, env(safe-area-inset-bottom));
    background: rgba(13, 13, 13, 0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    gap: 10px;
    z-index: 100;
}

.tg-miniapp-footer a,
.tg-miniapp-footer button {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 16px;
    border-radius: 14px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

.tg-miniapp-footer .tg-btn-share {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 20px rgba(0, 136, 204, 0.25);
}

.tg-miniapp-footer .tg-btn-share:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(0, 136, 204, 0.35);
}

.tg-miniapp-footer .tg-btn-browser {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tg-miniapp-footer .tg-btn-browser:hover {
    background: rgba(255, 255, 255, 0.1);
}

body.telegram-mode {
    padding-bottom: 80px;
}

@media (min-width: 769px) {
    body.telegram-mode .tg-header {
        display: none !important;
    }
    
    body.telegram-mode .tg-miniapp-footer {
        display: none !important;
    }
    
    body.telegram-mode {
        padding-bottom: 0;
    }
}
