        :root {
            --primary-blue: #0066ff;
            --secondary-blue: #4d94ff;
            --light-blue: #e6f0ff;
            --text-dark: #333333;
            --text-light: #666666;
            --background: #ffffff;
            --card-bg: #f8f9fa;
            --border: #e1e5e9;
            --success: #00b894;
            --warning: #fdcb6e;
            --error: #ff7675;
            --download-color: #0066ff;
            --upload-color: #00b894;
            --ping-color: #fd79a8;
            --jitter-color: #6c5ce7;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
        }

        body {
            background: var(--background);
            color: var(--text-dark);
            min-height: 100vh;
            overflow-x: hidden;
        }

        /* Loading Screen */
        .loading-screen {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: var(--background);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 1000;
            transition: opacity 0.3s ease;
        }

        .loading-content {
            text-align: center;
            padding: 2rem;
        }

        .loading-spinner {
            width: 40px;
            height: 40px;
            border: 3px solid var(--light-blue);
            border-top: 3px solid var(--primary-blue);
            border-radius: 50%;
            margin: 0 auto 1.5rem;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }

        /* Header */
        .header {
            padding: 1.5rem 2rem;
            text-align: center;
            background: var(--background);
        }

        .logo {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.75rem;
            margin-bottom: 0.25rem;
        }

        .logo-icon {
            color: var(--primary-blue);
            font-size: 1.5rem;
        }

        .logo-text {
            font-size: 1.8rem;
            font-weight: 700;
            color: var(--primary-blue);
            letter-spacing: -0.5px;
        }

        .tagline {
            color: var(--text-light);
            font-size: 0.9rem;
            font-weight: 400;
        }

        /* Main Container */
        .container {
            max-width: 1000px;
            margin: 0 auto;
            padding: 0 2rem 2rem;
        }

        /* Control Panel */
        .control-panel {
            background: var(--card-bg);
            border-radius: 16px;
            padding: 1.5rem;
            margin-bottom: 2rem;
            border: 1px solid var(--border);
            text-align: center;
        }

        .server-selector {
            display: flex;
            align-items: center;
            gap: 1rem;
            margin-bottom: 1.5rem;
            justify-content: center;
            flex-wrap: wrap;
        }

        .selector-label {
            font-size: 0.85rem;
            color: var(--text-light);
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .server-dropdown {
            padding: 0.6rem 1rem;
            background: white;
            border: 1px solid var(--border);
            border-radius: 10px;
            color: var(--text-dark);
            font-size: 0.9rem;
            cursor: pointer;
            min-width: 200px;
            transition: all 0.2s ease;
        }

        .server-dropdown:hover {
            border-color: var(--secondary-blue);
        }

        .status {
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
            font-size: 0.8rem;
            padding: 0.25rem 0.75rem;
            border-radius: 12px;
            background: var(--light-blue);
            color: var(--primary-blue);
        }

        .status-dot {
            width: 6px;
            height: 6px;
            border-radius: 50%;
            background: var(--primary-blue);
        }

        .status.connected .status-dot {
            background: var(--success);
        }

        .status.testing .status-dot {
            background: var(--warning);
            animation: pulse 1.5s infinite;
        }

        @keyframes pulse {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.5; }
        }

        /* Main Action Button */
        .test-button {
            background: var(--primary-blue);
            color: white;
            border: none;
            padding: 0.9rem 2.5rem;
            border-radius: 12px;
            font-size: 1rem;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
            display: inline-flex;
            align-items: center;
            gap: 0.75rem;
            margin: 0 auto;
        }

        .test-button:hover {
            background: var(--secondary-blue);
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(0, 102, 255, 0.2);
        }

        .test-button:active {
            transform: translateY(0);
        }

        .test-button.running {
            background: var(--error);
        }

        /* Big Download Display - FOCUS AREA */
        .big-metric-display {
            background: white;
            border-radius: 20px;
            padding: 2.5rem;
            margin: 2rem 0;
            border: 2px solid var(--light-blue);
            text-align: center;
            position: relative;
            overflow: hidden;
            transition: all 0.3s ease;
        }

        .big-metric-display.active {
            border-color: var(--download-color);
            box-shadow: 0 10px 40px rgba(0, 102, 255, 0.15);
        }

        .big-metric-header {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 1rem;
            margin-bottom: 1rem;
        }

        .big-metric-icon {
            color: var(--download-color);
            font-size: 2rem;
        }

        .big-metric-title {
            font-size: 1.5rem;
            color: var(--text-dark);
            font-weight: 600;
        }

        .big-metric-value {
            font-size: 5rem;
            font-weight: 800;
            color: var(--download-color);
            margin: 0.5rem 0;
            line-height: 1;
            text-shadow: 0 0 20px rgba(0, 102, 255, 0.1);
            transition: all 0.3s ease;
        }

        .big-metric-unit {
            color: var(--text-light);
            font-size: 1.2rem;
            margin-left: 0.5rem;
        }

        .big-metric-description {
            color: var(--text-light);
            font-size: 0.95rem;
            margin-top: 1rem;
            max-width: 500px;
            margin-left: auto;
            margin-right: auto;
            line-height: 1.5;
        }

        /* Progress Visualization */
        .progress-visual {
            height: 8px;
            background: var(--light-blue);
            border-radius: 4px;
            margin: 2rem 0;
            overflow: hidden;
            position: relative;
        }

        .progress-bar {
            height: 100%;
            background: var(--download-color);
            border-radius: 4px;
            transition: width 0.5s ease;
            width: 0%;
        }

        .progress-text {
            font-size: 0.85rem;
            color: var(--text-light);
            margin-top: 0.5rem;
        }

        /* Other Metrics Section */
        .other-metrics {
            display: none;
            animation: fadeIn 0.5s ease;
        }

        .other-metrics.show {
            display: block;
        }

        .section-title {
            font-size: 1.3rem;
            color: var(--text-dark);
            margin: 2.5rem 0 1.5rem;
            text-align: center;
            font-weight: 600;
        }

        .metrics-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 1.5rem;
            margin-bottom: 2rem;
        }

        .metric-card {
            background: white;
            border-radius: 16px;
            padding: 1.5rem;
            border: 1px solid var(--border);
            text-align: center;
            transition: all 0.3s ease;
            opacity: 0;
            transform: translateY(20px);
        }

        .metric-card.visible {
            opacity: 1;
            transform: translateY(0);
        }

        .metric-card.upload {
            border-top: 3px solid var(--upload-color);
        }

        .metric-card.ping {
            border-top: 3px solid var(--ping-color);
        }

        .metric-card.jitter {
            border-top: 3px solid var(--jitter-color);
        }

        .metric-header {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.5rem;
            margin-bottom: 1rem;
        }

        .metric-icon {
            font-size: 1.25rem;
        }

        .metric-icon.download {
            color: var(--download-color);
        }

        .metric-icon.upload {
            color: var(--upload-color);
        }

        .metric-icon.ping {
            color: var(--ping-color);
        }

        .metric-icon.jitter {
            color: var(--jitter-color);
        }

        .metric-title {
            font-size: 0.9rem;
            color: var(--text-light);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            font-weight: 600;
        }

        .metric-value {
            font-size: 2.2rem;
            font-weight: 700;
            color: var(--text-dark);
            margin-bottom: 0.25rem;
            line-height: 1;
        }

        .metric-unit {
            color: var(--text-light);
            font-size: 0.9rem;
        }

        /* Friendly Message Area */
        .friendly-message {
            background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
            border-radius: 16px;
            padding: 2rem;
            margin: 2rem 0;
            text-align: center;
            border: 1px solid var(--border);
            display: none;
        }

        .friendly-message.show {
            display: block;
            animation: slideUp 0.5s ease;
        }

        .message-icon {
            font-size: 2.5rem;
            color: var(--primary-blue);
            margin-bottom: 1rem;
        }

        .message-title {
            font-size: 1.3rem;
            color: var(--text-dark);
            margin-bottom: 0.75rem;
            font-weight: 600;
        }

        .message-text {
            color: var(--text-light);
            font-size: 0.95rem;
            line-height: 1.6;
            max-width: 600px;
            margin: 0 auto;
        }

        /* Results Panel */
        .results-panel {
            background: white;
            border-radius: 20px;
            padding: 2.5rem;
            margin-top: 2rem;
            border: 2px solid var(--success);
            display: none;
            animation: fadeIn 0.5s ease;
        }

        .results-panel.show {
            display: block;
        }

        .results-header {
            text-align: center;
            margin-bottom: 2rem;
        }

        .success-icon {
            color: var(--success);
            font-size: 3rem;
            margin-bottom: 1rem;
        }

        .timestamp {
            background: var(--light-blue);
            border-radius: 12px;
            padding: 1rem 1.5rem;
            margin: 2rem 0;
            display: inline-flex;
            align-items: center;
            gap: 0.75rem;
            color: var(--text-dark);
            font-size: 0.9rem;
        }

        .timestamp i {
            color: var(--primary-blue);
        }

        /* Bottom Actions */
        .action-buttons {
            display: flex;
            justify-content: center;
            gap: 1rem;
            margin-top: 3rem;
            flex-wrap: wrap;
        }

        .secondary-button {
            background: white;
            color: var(--primary-blue);
            border: 1px solid var(--primary-blue);
            padding: 0.75rem 1.5rem;
            border-radius: 12px;
            font-size: 0.9rem;
            cursor: pointer;
            transition: all 0.2s ease;
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
        }

        .secondary-button:hover {
            background: var(--light-blue);
        }

        /* Footer */
        .footer {
            text-align: center;
            padding: 2rem;
            margin-top: 3rem;
            color: var(--text-light);
            font-size: 0.85rem;
        }

        .footer-links {
            display: flex;
            justify-content: center;
            gap: 2rem;
            margin-top: 1rem;
        }

        .footer-link {
            color: var(--text-light);
            text-decoration: none;
            transition: color 0.2s ease;
        }

        .footer-link:hover {
            color: var(--primary-blue);
        }

        /* Animations */
        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        @keyframes slideUp {
            from { opacity: 0; transform: translateY(30px); }
            to { opacity: 1; transform: translateY(0); }
        }

        @keyframes pulseGlow {
            0%, 100% { box-shadow: 0 0 20px rgba(0, 102, 255, 0.2); }
            50% { box-shadow: 0 0 30px rgba(0, 102, 255, 0.4); }
        }

        /* Responsive Design */
        @media (max-width: 768px) {
            .container {
                padding: 0 1rem 1rem;
            }
            
            .header {
                padding: 1rem;
            }
            
            .logo-text {
                font-size: 1.5rem;
            }
            
            .big-metric-value {
                font-size: 3.5rem;
            }
            
            .control-panel {
                padding: 1.2rem;
            }
            
            .server-selector {
                flex-direction: column;
                align-items: stretch;
            }
            
            .server-dropdown {
                min-width: auto;
                width: 100%;
            }
            
            .metrics-grid {
                grid-template-columns: 1fr;
            }
            
            .action-buttons {
                flex-direction: column;
                align-items: stretch;
            }
            
            .secondary-button {
                justify-content: center;
            }
        }

        @media (max-width: 480px) {
            .big-metric-value {
                font-size: 2.8rem;
            }
            
            .big-metric-title {
                font-size: 1.2rem;
            }
            
            .metric-value {
                font-size: 1.8rem;
            }
            
            .results-panel {
                padding: 1.5rem;
            }
        }
        
    /* Modal Styles */
    .modal-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(8px);
        z-index: 2000;
        align-items: center;
        justify-content: center;
        padding: 1rem;
        animation: fadeIn 0.3s ease;
    }

    .modal-container {
        background: var(--background);
        border-radius: 24px;
        max-width: 600px;
        width: 100%;
        max-height: 90vh;
        display: flex;
        flex-direction: column;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
        animation: slideUp 0.4s cubic-bezier(0.18, 0.89, 0.32, 1.28);
        border: 1px solid var(--border);
        overflow: hidden;
    }

    .wide-modal {
        max-width: 800px;
    }

    .modal-header {
        background: linear-gradient(135deg, var(--primary-blue) 0%, var(--secondary-blue) 100%);
        color: white;
        padding: 2rem 2rem 1.5rem;
        position: relative;
    }

    .modal-header::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 5%;
        right: 5%;
        height: 4px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 2px;
    }

    .modal-header-content {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 0.5rem;
    }

    .modal-icon {
        font-size: 2rem;
        margin-right: 1rem;
        opacity: 0.9;
    }

    .modal-title {
        font-size: 1.8rem;
        font-weight: 700;
        flex: 1;
        margin: 0;
    }

    .modal-subtitle {
        opacity: 0.9;
        font-size: 0.95rem;
        margin: 0;
    }

    .modal-close {
        background: rgba(255, 255, 255, 0.2);
        border: none;
        color: white;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s ease;
    }

    .modal-close:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: rotate(90deg);
    }

    .modal-body {
        padding: 2rem;
        overflow-y: auto;
        flex: 1;
    }

    .privacy-section {
        margin-bottom: 2.5rem;
        padding-bottom: 2rem;
        border-bottom: 1px solid var(--border);
    }

    .privacy-section:last-child {
        border-bottom: none;
        margin-bottom: 0;
        padding-bottom: 0;
    }

    .privacy-badge {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        background: var(--light-blue);
        color: var(--primary-blue);
        padding: 0.5rem 1rem;
        border-radius: 20px;
        font-size: 0.9rem;
        font-weight: 600;
        margin-bottom: 1rem;
    }

    .privacy-badge i {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.3rem;
        color: var(--text-dark);
        margin: 0 0 1.2rem;
        font-weight: 600;
    }

    .privacy-list {
        list-style: none;
        padding: 0;
    }

    .privacy-list li {
        display: flex;
        gap: 1rem;
        margin-bottom: 1.2rem;
        align-items: flex-start;
    }

    .privacy-list li:last-child {
        margin-bottom: 0;
    }

    .list-icon {
        font-size: 1.2rem;
        margin-top: 0.2rem;
        flex-shrink: 0;
    }

    .list-icon.success {
        color: var(--success);
    }

    .privacy-list strong {
        display: block;
        color: var(--text-dark);
        margin-bottom: 0.3rem;
        font-size: 1rem;
    }

    .privacy-list p {
        color: var(--text-light);
        font-size: 0.9rem;
        line-height: 1.5;
        margin: 0;
    }

    .data-handling-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 1.5rem;
        margin-top: 1.5rem;
    }

    .data-card {
        background: var(--card-bg);
        border-radius: 16px;
        padding: 1.5rem;
        text-align: center;
        border: 1px solid var(--border);
        transition: transform 0.3s ease;
    }

    .data-card:hover {
        transform: translateY(-5px);
    }

    .data-icon {
        width: 50px;
        height: 50px;
        background: var(--light-blue);
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 auto 1rem;
        color: var(--primary-blue);
        font-size: 1.5rem;
    }

    .data-card h4 {
        color: var(--text-dark);
        margin: 0 0 0.5rem;
        font-size: 1rem;
    }

    .data-card p {
        color: var(--text-light);
        font-size: 0.85rem;
        line-height: 1.4;
        margin: 0;
    }

    .control-options {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        margin-top: 1.5rem;
    }

    .control-option {
        background: var(--card-bg);
        border-radius: 12px;
        padding: 1.2rem;
        border-left: 4px solid var(--primary-blue);
    }

    .control-header {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        margin-bottom: 0.5rem;
    }

    .control-header i {
        color: var(--primary-blue);
        font-size: 1.2rem;
    }

    .control-header span {
        color: var(--text-dark);
        font-weight: 600;
        font-size: 1rem;
    }

    .control-option p {
        color: var(--text-light);
        font-size: 0.9rem;
        line-height: 1.5;
        margin: 0;
        padding-left: 2rem;
    }

    .privacy-notice {
        background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
        border-radius: 16px;
        padding: 1.5rem;
        border: 1px solid var(--border);
        margin-top: 2rem;
    }

    .notice-header {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        margin-bottom: 0.75rem;
    }

    .notice-header i {
        color: var(--primary-blue);
        font-size: 1.3rem;
    }

    .notice-header h4 {
        color: var(--text-dark);
        margin: 0;
        font-size: 1.1rem;
    }

    .notice-content p {
        color: var(--text-light);
        font-size: 0.9rem;
        line-height: 1.6;
        margin: 0 0 0.5rem;
    }

    .notice-small {
        font-size: 0.8rem !important;
        color: #999 !important;
        margin-top: 1rem !important;
        padding-top: 0.75rem;
        border-top: 1px solid var(--border);
    }

    .modal-footer {
        padding: 1.5rem 2rem;
        background: var(--card-bg);
        border-top: 1px solid var(--border);
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
    }

    .trust-badges {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
        flex-wrap: wrap;
    }

    .trust-badge {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        background: white;
        padding: 0.5rem 1rem;
        border-radius: 12px;
        font-size: 0.85rem;
        font-weight: 600;
        color: var(--text-dark);
        border: 1px solid var(--border);
    }

    .trust-badge i {
        color: var(--primary-blue);
    }

    .modal-button {
        padding: 0.9rem 1.5rem;
        border-radius: 12px;
        font-size: 1rem;
        font-weight: 600;
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.75rem;
        transition: all 0.2s ease;
        border: none;
        width: 100%;
    }

    .modal-button.primary {
        background: var(--primary-blue);
        color: white;
    }

    .modal-button.primary:hover {
        background: var(--secondary-blue);
        transform: translateY(-2px);
    }

    .modal-button.secondary {
        background: white;
        color: var(--primary-blue);
        border: 2px solid var(--primary-blue);
    }

    .modal-button.secondary:hover {
        background: var(--light-blue);
    }

    /* Policy Body Styles */
    .policy-body {
        padding: 2rem;
    }

    .policy-section {
        margin-bottom: 2rem;
    }

    .policy-section h3 {
        color: var(--text-dark);
        font-size: 1.2rem;
        margin: 0 0 1rem;
        padding-bottom: 0.5rem;
        border-bottom: 2px solid var(--light-blue);
    }

    .policy-section p {
        color: var(--text-light);
        font-size: 0.95rem;
        line-height: 1.6;
        margin: 0 0 1rem;
    }

    .policy-section ul {
        color: var(--text-light);
        font-size: 0.95rem;
        line-height: 1.6;
        padding-left: 1.5rem;
        margin: 0 0 1rem;
    }

    .policy-section li {
        margin-bottom: 0.5rem;
    }

    /* Animations */
    @keyframes fadeIn {
        from { opacity: 0; }
        to { opacity: 1; }
    }

    @keyframes slideUp {
        from { 
            opacity: 0;
            transform: translateY(40px) scale(0.95);
        }
        to { 
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }

    /* Responsive Design */
    @media (max-width: 768px) {
        .modal-container {
            max-height: 95vh;
        }
        
        .modal-header {
            padding: 1.5rem 1.5rem 1rem;
        }
        
        .modal-title {
            font-size: 1.5rem;
        }
        
        .modal-body {
            padding: 1.5rem;
        }
        
        .modal-footer {
            padding: 1.5rem;
        }
        
        .data-handling-grid {
            grid-template-columns: 1fr;
        }
        
        .trust-badges {
            gap: 1rem;
        }
        
        .trust-badge {
            font-size: 0.8rem;
            padding: 0.4rem 0.8rem;
        }
    }

    @media (max-width: 480px) {
        .modal-overlay {
            padding: 0.5rem;
        }
        
        .modal-header {
            padding: 1.2rem 1.2rem 0.8rem;
        }
        
        .modal-body {
            padding: 1.2rem;
        }
        
        .modal-button {
            padding: 0.8rem 1rem;
            font-size: 0.95rem;
        }
    }
    