/* Modern VPN Theme */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
    max-width: 400px;
    width: 90%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    text-align: center;
}

header {
    margin-bottom: 30px;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 10px;
    background: linear-gradient(45deg, #fff, #f0f0f0);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    opacity: 0.8;
    font-size: 0.9rem;
}

/* VPN Status */
.vpn-status {
    margin-bottom: 30px;
}

.status-indicator {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    font-size: 2rem;
    transition: all 0.3s ease;
}

.status-indicator.active {
    background: rgba(0, 255, 0, 0.3);
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.5);
}

/* Power Button */
.power-button {
    margin-bottom: 30px;
}

.btn-power {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.btn-power:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.btn-power.on {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
}

/* Server Selection */
.server-selection {
    margin-bottom: 30px;
}

.btn-server {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.btn-server:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-server i {
    margin-left: 10px;
}

.flag {
    font-size: 1.5rem;
}

/* IP Display */
.ip-display {
    margin-top: 20px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    font-size: 0.9rem;
}

/* Register Form */
.register-form {
    margin-top: 20px;
}

.form-group {
    margin-bottom: 20px;
    text-align: right;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 1rem;
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-group input:focus {
    outline: none;
    border-color: #4ecdc4;
    box-shadow: 0 0 10px rgba(78, 205, 196, 0.3);
}

.btn-submit {
    width: 100%;
    padding: 15px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    border-radius: 10px;
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Payment Success */
.payment-success {
    margin-top: 30px;
}

.payment-success i {
    font-size: 4rem;
    color: #4ecdc4;
    margin-bottom: 20px;
}

.payment-success p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.btn-back {
    display: inline-block;
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-back:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .container {
        padding: 20px;
    }
    
    header h1 {
        font-size: 1.5rem;
    }
    
    .btn-power {
        width: 100px;
        height: 100px;
        font-size: 2rem;
    }
}

/* Spinner Animation */
.spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #fff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.payment-processing {
    text-align: center;
    padding: 20px;
}

/* Server Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: flex-end;
    z-index: 1000;
}

.modal-content {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px 20px 0 0;
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 15px;
}

.modal-header h2 {
    font-size: 1.3rem;
}

.close-modal {
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

.server-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.server-item {
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.server-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(-5px);
}

.server-item.selected {
    background: rgba(78, 205, 196, 0.3);
    border-color: #4ecdc4;
}

.server-item i {
    display: none;
}

.server-item.selected i {
    display: block;
    color: #4ecdc4;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    z-index: 999;
}

.nav-btn {
    flex: 1;
    padding: 15px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    font-size: 0.8rem;
    transition: all 0.3s ease;
}

.nav-btn:hover,
.nav-btn.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
}

.nav-btn i {
    font-size: 1.3rem;
}

/* WebView Container */
.webview-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #000;
    z-index: 2000;
    display: flex;
    flex-direction: column;
}

.webview-header {
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    gap: 10px;
    align-items: center;
}

.url-input {
    flex: 1;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: #fff;
    font-size: 0.9rem;
}

.url-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.url-input:focus {
    outline: none;
    border-color: #4ecdc4;
}

.load-url-btn {
    padding: 10px 15px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.load-url-btn:hover {
    transform: translateY(-2px);
}

.webview-close {
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.webview-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

#web-iframe {
    flex: 1;
    border: none;
    width: 100%;
}

.webview-content {
    flex: 1;
    display: flex;
    position: relative;
}

.webview-fallback {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.fallback-content {
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    max-width: 400px;
}

.fallback-content i {
    font-size: 3rem;
    color: #ff6b6b;
    margin-bottom: 15px;
}

.fallback-content h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.fallback-content p {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 20px;
}

.fallback-url {
    width: 100%;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: #fff;
    font-size: 0.8rem;
    margin-bottom: 15px;
    text-align: center;
    word-break: break-all;
}

.btn-external {
    display: block;
    width: 100%;
    padding: 10px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.btn-external:hover {
    transform: translateY(-2px);
}

.btn-back-home {
    display: block;
    width: 100%;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-back-home:hover {
    background: rgba(255, 255, 255, 0.2);
}