:root {
            --bg: black;
            --card: rgba(255,255,255,0.06);
            --card-strong: rgba(255,255,255,0.12);
            --text: #e8ecf1;
            --muted: #9fb2c8;
            --accent: darkgray;
            --ok: #3ad29f;
            --warn: #ffd166;
            --danger: #ff6b6b;
            --ring: rgba(109,225,255,.35);
            --shadow: 0 10px 30px rgba(0,0,0,.35), inset 0 0 0 1px rgba(255,255,255,.05);
            --radius: 18px;
            --glow: 0 0 20px rgba(109, 225, 255, 0.15);
            --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        }

        ::-webkit-scrollbar {
            background-color: transparent;
            width: 8px;
        }
        
        ::-webkit-scrollbar-thumb {
            border-radius: 8px;
            background: linear-gradient(180deg, #1a2d4b, #2a3d5b);
            border: 1px solid rgba(255,255,255,0.1);
            transition: var(--transition);
        }
        
        ::-webkit-scrollbar-thumb:hover {
            background: linear-gradient(180deg, #2a3d5b, #3a4d6b);
        }

        html, body {
            height: 100%;
            scroll-behavior: smooth;
        }

        body {
            margin: 0; 
            font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Inter, Arial;
            color: var(--text); 
            background: 
                radial-gradient(1200px 800px at 15% -10%, #16223a 0%, transparent 60%),
                radial-gradient(1000px 700px at 85% -5%, #1a2d4b 0%, transparent 60%),
                radial-gradient(1200px 900px at 50% 110%, #111a2a 0%, transparent 60%), 
                var(--bg);
            background-attachment: fixed;
            overflow-y: auto;
            position: relative;
        }

        /* Enhanced stars with parallax effect */
        .stars, .stars2, .stars3 {
            position: fixed; 
            inset: 0; 
            pointer-events: none; 
            background-repeat: repeat; 
            z-index: -1; 
            opacity: .6;
            background-image: 
                radial-gradient(1.5px 1.5px at 20px 30px, #fff, transparent 50%),
                radial-gradient(1px 1px at 80px 120px, #fff, transparent 50%),
                radial-gradient(1.2px 1.2px at 200px 80px, #fff, transparent 50%),
                radial-gradient(0.8px 0.8px at 320px 40px, #fff, transparent 50%),
                radial-gradient(1.3px 1.3px at 440px 160px, #fff, transparent 50%),
                radial-gradient(1px 1px at 150px 200px, #fff, transparent 50%),
                radial-gradient(0.7px 0.7px at 300px 280px, #fff, transparent 50%);
            animation: twinkle 16s ease-in-out infinite;
            transform-style: preserve-3d;
        }

        .stars2 { 
            animation-duration: 22s; 
            opacity: .4; 
            transform: scale(1.2) translateZ(-100px);
            background-image: 
                radial-gradient(1px 1px at 60px 90px, #fff, transparent 50%),
                radial-gradient(0.8px 0.8px at 180px 220px, #fff, transparent 50%),
                radial-gradient(1.1px 1.1px at 320px 150px, #fff, transparent 50%);
        }

        .stars3 { 
            animation-duration: 30s; 
            opacity: .25; 
            transform: scale(1.4) translateZ(-200px);
            background-image: 
                radial-gradient(0.6px 0.6px at 120px 80px, #fff, transparent 50%),
                radial-gradient(0.9px 0.9px at 280px 180px, #fff, transparent 50%),
                radial-gradient(0.7px 0.7px at 400px 250px, #fff, transparent 50%);
        }

        @keyframes twinkle { 
            0% { opacity: 0.5; transform: scale(0.98); } 
            50% { opacity: 1; transform: scale(1.02); } 
            100% { opacity: 0.5; transform: scale(0.98); } 
        }

        .wrap { 
            max-width: 1080px; 
            margin: auto; 
            padding: 32px 20px 80px; 
            position: relative;
            z-index: 1;
        }

        header {
            display: flex; 
            gap: 16px; 
            align-items: center; 
            justify-content: space-between; 
            margin-bottom: 32px;
            padding: 16px 0;
            position: relative;
        }

        header::after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            height: 1px;
            background: linear-gradient(90deg, transparent, rgba(109,225,255,0.3), transparent);
        }

        .brand { 
            display: flex; 
            align-items: center; 
            gap: 12px; 
            transition: var(--transition);
        }

        .brand:hover {
            transform: translateX(4px);
        }

        .logo {
            width: 44px; 
            height: 44px; 
            border-radius: 14px; 
            background:
                radial-gradient(20px 16px at 15px 15px, #6de1ff 0%, #4cc2ff 35%, transparent 60%),
                conic-gradient(from 220deg, #6de1ff, #7c6dff, #eb6cff, #6de1ff);
            box-shadow: 
                0 0 35px rgba(109,225,255,.5), 
                inset 0 0 0 2px rgba(255,255,255,.1);
            transition: var(--transition);
            position: relative;
            overflow: hidden;
        }

        .logo::after {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.1), transparent 60%);
            animation: shine 3s infinite;
        }

        @keyframes shine {
            0% { transform: translateX(-100%); }
            100% { transform: translateX(100%); }
        }

        h1 { 
            font-size: 24px; 
            margin: 0; 
            letter-spacing: .4px;
            font-weight: 700;
            background: linear-gradient(135deg, #e8ecf1, #9fb2c8);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }

        .card {
            background: var(--card); 
            border-radius: var(--radius); 
            box-shadow: var(--shadow), var(--glow);
            backdrop-filter: blur(12px) brightness(1.1);
            -webkit-backdrop-filter: blur(12px) brightness(1.1);
            padding: 20px; 
            border: 1px solid rgba(255,255,255,.08);
            transition: var(--transition);
            position: relative;
            overflow: hidden;
        }

        .card::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: 1px;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
        }

        .card:hover {
            transform: translateY(-2px);
            box-shadow: 0 15px 40px rgba(0,0,0,.4), inset 0 0 0 1px rgba(255,255,255,.08), var(--glow);
        }

        .stack { display: grid; gap: 20px; }
        .grid { display: grid; gap: 20px; grid-template-columns: 1.1fr .9fr; }
        
        @media (max-width: 900px) { 
            .grid { grid-template-columns: 1fr; } 
        }

        .muted { color: var(--muted); transition: var(--transition); }
        .muted:hover { color: var(--text); }

        .btn {
            appearance: none; 
            border: 0; 
            padding: 14px 20px; 
            border-radius: 16px; 
            font-weight: 600; 
            cursor: pointer;
            background: linear-gradient(180deg, #1d2a42, #141c2b); 
            color: #eaf7ff;
            box-shadow: var(--shadow); 
            transition: var(--transition);
            position: relative;
            overflow: hidden;
            font-size: 14px;
            letter-spacing: 0.5px;
        }

        .btn::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
            transition: left 0.5s ease;
        }

        .btn:hover::before {
            left: 100%;
        }

        .btn:hover { 
            box-shadow: 0 16px 40px rgba(109,225,255,.3), inset 0 0 0 1px var(--ring);
            transform: translateY(-2px);
        }

        .btn:active { 
            transform: translateY(1px) scale(0.98); 
            box-shadow: 0 8px 20px rgba(0,0,0,.3), inset 0 0 0 1px var(--ring);
        }

        .btn.secondary { background: linear-gradient(180deg, #232b3b, #1a2230) }
        .btn.ok { background: linear-gradient(180deg, #1f3a34, #122722) }
        .btn.danger { background: linear-gradient(180deg, #3a2327, #2a1417) }

        .toolbar { 
            display: flex; 
            gap: 12px; 
            align-items: center; 
            flex-wrap: wrap;
            padding: 8px 0;
        }

        .pill { 
            padding: 8px 14px; 
            background: var(--card-strong); 
            border-radius: 999px; 
            font-size: 13px; 
            font-weight: 500;
            border: 1px solid rgba(255,255,255,0.05);
            transition: var(--transition);
        }

        .pill:hover {
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(0,0,0,0.2);
        }

        input[type="text"], input[type="search"], textarea {
            width: 100%; 
            padding: 14px 16px; 
            border-radius: 14px; 
            border: 1px solid rgba(255,255,255,.1);
            background: rgba(10,14,24,.7); 
            color: var(--text); 
            outline: none;
            font-family: inherit;
            transition: var(--transition);
            backdrop-filter: blur(10px);
        }

        input[type="text"]:focus, input[type="search"]:focus, textarea:focus {
            border-color: rgba(109,225,255,0.3);
            box-shadow: 0 0 0 3px rgba(109,225,255,0.1);
            background: rgba(10,14,24,.8);
        }

        textarea { 
            min-height: 120px; 
            resize: vertical; 
            line-height: 1.5;
        }

        .footer { 
            opacity: .9; 
            margin-top: 40px; 
            padding: 20px; 
            text-align: center; 
            font-size: 14px; 
            color: var(--muted);
            position: relative;
        }

        .footer::before {
            content: '';
            position: absolute;
            top: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 100px;
            height: 1px;
            background: linear-gradient(90deg, transparent, rgba(109,225,255,0.3), transparent);
        }

        .danger-text { color: var(--danger); transition: var(--transition); }
        .danger-text:hover { color: #ff5252; }

        .ok-text { color: var(--ok); transition: var(--transition); }
        .ok-text:hover { color: #2bc18d; }

        .divider { 
            height: 1px; 
            background: linear-gradient(90deg, transparent, rgba(255,255,255,.1), transparent); 
            margin: 16px 0;
        }

        .kbd { 
            background: rgba(255,255,255,.15); 
            padding: 4px 8px; 
            border-radius: 8px; 
            font-size: 13px;
            border: 1px solid rgba(255,255,255,0.1);
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        }

        .sticky-key { 
            position: fixed; 
            right: 24px; 
            bottom: 24px; 
            max-width: 520px; 
            z-index: 50;
            transition: var(--transition);
        }

        .sticky-key:hover {
            transform: translateY(-4px);
        }

        .hide { display: none !important }

        .role-chip { 
            font-size: 13px; 
            padding: 8px 12px; 
            border-radius: 999px; 
            background: rgba(255,25,255,.12);
            border: 1px solid rgba(255,25,255,0.2);
            transition: var(--transition);
        }

        .role-chip:hover {
            transform: scale(1.05);
            background: rgba(255,25,255,.15);
        }

        .code { 
            font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; 
            background: rgba(0,0,0,0.3);
            padding: 2px 6px;
            border-radius: 6px;
            border: 1px solid rgba(255,255,255,0.1);
        }

        /* Enhanced Contact card */
        .contact-card { 
            background: linear-gradient(135deg, rgba(255,255,255,0.08), rgba(255,255,255,0.04)); 
            border: 1px solid rgba(255,255,255,0.1); 
            padding: 20px; 
            border-radius: var(--radius); 
            text-align: center;
            transition: var(--transition);
        }

        .contact-card:hover {
            transform: translateY(-3px);
            box-shadow: 0 10px 30px rgba(0,0,0,0.3);
        }

        .discord-btn { 
            display: inline-flex; 
            align-items: center; 
            gap: 8px; 
            background: #5865F2; 
            color: white; 
            padding: 12px 18px; 
            border-radius: 14px; 
            text-decoration: none; 
            font-weight: 600; 
            margin-top: 16px; 
            transition: var(--transition);
            position: relative;
            overflow: hidden;
        }

        .discord-btn::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
            transition: left 0.5s ease;
        }

        .discord-btn:hover::before {
            left: 100%;
        }

        .discord-btn:hover { 
            background: #4752c4; 
            transform: translateY(-2px); 
            box-shadow: 0 8px 20px rgba(88, 101, 242, 0.4);
        }

        /* Enhanced Loading */
        .loading-screen { 
            position: fixed; 
            top: 0; 
            left: 0; 
            width: 100%; 
            height: 100%; 
            background: var(--bg); 
            display: flex; 
            flex-direction: column; 
            justify-content: center; 
            align-items: center; 
            z-index: 9999; 
            transition: opacity 0.5s ease;
            backdrop-filter: blur(10px);
        }

        .loading-spinner { 
            width: 60px; 
            height: 60px; 
            border: 3px solid rgba(109, 225, 255, 0.2); 
            border-radius: 50%; 
            border-top-color: var(--accent); 
            animation: spin 1.2s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite; 
            margin-bottom: 24px;
            position: relative;
        }

        .loading-spinner::after {
            content: '';
            position: absolute;
            top: -3px;
            left: -3px;
            right: -3px;
            bottom: -3px;
            border-radius: 50%;
            border: 3px solid transparent;
            border-top-color: rgba(109, 225, 255, 0.4);
            animation: spin 1.5s cubic-bezier(0.68, -0.55, 0.27, 1.55) infinite reverse;
        }

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

        .loading-text { 
            font-size: 20px; 
            color: var(--text); 
            text-align: center;
            font-weight: 500;
            letter-spacing: 0.5px;
        }

        .loading-dots:after { 
            content: ''; 
            animation: dots 1.5s infinite; 
        }

        @keyframes dots { 
            0%, 20% { content: '.'; } 
            40% { content: '..'; } 
            60%, 100% { content: '...'; } 
        }

        /* Enhanced Role status */
        .role-status { 
            padding: 12px; 
            border-radius: 14px; 
            margin-top: 16px; 
            font-size: 14px; 
            text-align: center;
            transition: var(--transition);
            border: 1px solid transparent;
        }

        .role-status.updating { 
            background: rgba(255, 209, 102, 0.1); 
            color: var(--warn);
            border-color: rgba(255, 209, 102, 0.2);
        }

        .role-status.success { 
            background: rgba(58, 210, 159, 0.1); 
            color: var(--ok);
            border-color: rgba(58, 210, 159, 0.2);
        }

        .role-status.error { 
            background: rgba(255, 107, 107, 0.1); 
            color: var(--danger);
            border-color: rgba(255, 107, 107, 0.2);
        }

        /* Enhanced Vouches */
        .vouch-section { margin-top: 30px; }
        
        .vouch-form { 
            background: var(--card); 
            padding: 24px; 
            border-radius: var(--radius); 
            margin-bottom: 24px;
            transition: var(--transition);
        }

        .vouch-form:hover {
            box-shadow: 0 10px 30px rgba(0,0,0,0.3);
        }

        .vouch-list { display: grid; gap: 20px; }
        
        .vouch-item { 
            background: var(--card); 
            padding: 20px; 
            border-radius: var(--radius); 
            position: relative;
            transition: var(--transition);
            border: 1px solid rgba(255,255,255,0.06);
        }

        .vouch-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(0,0,0,0.25);
        }

        .vouch-header { 
            display: flex; 
            justify-content: space-between; 
            align-items: center; 
            margin-bottom: 12px; 
        }
        
        .vouch-user { 
            display: flex; 
            align-items: center; 
            gap: 12px; 
        }
        
        .vouch-avatar { 
            width: 36px; 
            height: 36px; 
            border-radius: 50%; 
            background: linear-gradient(45deg, #6de1ff, #7c6dff);
            box-shadow: 0 0 15px rgba(109, 225, 255, 0.3);
        }
        
        .vouch-name { font-weight: 600; }
        
        .vouch-date { 
            font-size: 13px; 
            color: var(--muted); 
        }
        
        .vouch-content { 
            margin: 12px 0; 
            line-height: 1.6; 
        }
        
        .vouch-delete { 
            position: absolute; 
            top: 16px; 
            right: 16px; 
            background: rgba(255, 107, 107, 0.2); 
            border: none; 
            border-radius: 8px; 
            padding: 6px 10px; 
            color: var(--danger); 
            cursor: pointer; 
            font-size: 13px;
            transition: var(--transition);
        }
        
        .vouch-delete:hover { 
            background: rgba(255, 107, 107, 0.3);
            transform: scale(1.05);
        }
        
        .no-vouches { 
            text-align: center; 
            padding: 40px; 
            color: var(--muted);
            font-style: italic;
        }
        
        .char-count { 
            text-align: right; 
            font-size: 13px; 
            color: var(--muted); 
            margin-top: 8px; 
        }
        
        .char-count.warning { color: var(--warn); }
        .char-count.error { color: var(--danger); }

        /* Enhanced Stripe popup */
        .popup-payment { 
            position: fixed; 
            inset: 0; 
            background: rgba(0,0,0,.8); 
            display: none; 
            justify-content: center; 
            align-items: center; 
            z-index: 9999;
            backdrop-filter: blur(5px);
        }
        
        .popup-content { 
            background: var(--card); 
            border: 1px solid rgba(255,255,255,.08); 
            box-shadow: var(--shadow), 0 0 40px rgba(109,225,255,0.2); 
            border-radius: var(--radius); 
            width: 100%; 
            max-width: 480px; 
            padding: 24px;
            transform: scale(0.9);
            animation: popIn 0.3s forwards;
        }

        @keyframes popIn {
            to { transform: scale(1); }
        }
        
        #payment-element { 
            padding: 12px; 
            background: rgba(10,14,24,.7); 
            border: 1px solid rgba(255,255,255,.1); 
            border-radius: 14px;
            margin: 16px 0;
        }
        
        #paymentMessage { 
            font-size: 14px; 
            color: var(--muted); 
            min-height: 20px;
            text-align: center;
        }

        /* Enhanced Role glow styles */
        .role-premium {
            color: #FFD700;
            text-shadow: 0 0 10px rgba(255, 215, 0, 0.7);
            animation: glowPulse 3s infinite;
        }

        .role-vip {
            color: #FF3333;
            text-shadow: 0 0 10px rgba(255, 51, 51, 0.7);
            animation: glowPulse 2.5s infinite;
        }

        .role-dev {
            color: #9370DB;
            text-shadow: 0 0 10px rgba(147, 112, 219, 0.7);
            animation: glowPulse 3.2s infinite;
        }

        .role-owner {
            color: #00FF00;
            text-shadow: 0 0 10px rgba(0, 255, 0, 0.7);
            animation: glowPulse 2.8s infinite;
        }

        @keyframes glowPulse {
            0%, 100% { opacity: 0.9; }
            50% { opacity: 1; text-shadow: 0 0 15px currentColor; }
        }

        /* Enhanced Credits section */
        .credits-section {
            margin-top: 40px;
            padding: 24px;
            background: var(--card);
            border-radius: var(--radius);
            text-align: center;
            transition: var(--transition);
        }

        .credits-section:hover {
            box-shadow: 0 10px 30px rgba(0,0,0,0.3);
        }

        .credits-title {
            font-size: 18px;
            font-weight: 600;
            margin-bottom: 20px;
            color: var(--text);
        }

        .credits-list {
            display: flex;
            justify-content: center;
            gap: 24px;
            flex-wrap: wrap;
        }

        .credit-user {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 8px;
            transition: var(--transition);
        }

        .credit-user:hover {
            transform: translateY(-3px);
        }

        .credit-name {
            font-size: 15px;
            font-weight: 500;
        }

        .credit-role {
            font-size: 13px;
            padding: 6px 10px;
            border-radius: 14px;
            background: rgba(255, 255, 255, 0.1);
            transition: var(--transition);
        }

        .credit-role:hover {
            background: rgba(255, 255, 255, 0.15);
        }

        /* Enhanced Consent popup */
        .consent-popup {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.9);
            display: flex;
            justify-content: center;
            align-items: center;
            z-index: 10000;
            backdrop-filter: blur(8px);
        }

        .consent-content {
            background: var(--card);
            border-radius: var(--radius);
            box-shadow: var(--shadow), 0 0 40px rgba(109,225,255,0.2);
            padding: 28px;
            max-width: 520px;
            width: 90%;
            border: 1px solid rgba(255, 255, 255, 0.1);
            animation: modalSlideIn 0.4s cubic-bezier(0.18, 1.25, 0.4, 1);
        }

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

        .consent-title {
            font-size: 22px;
            font-weight: 700;
            margin-bottom: 16px;
            text-align: center;
            background: linear-gradient(135deg, #e8ecf1, #9fb2c8);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }

        .consent-text {
            margin-bottom: 24px;
            line-height: 1.6;
            font-size: 15px;
        }

        .consent-checkbox {
            display: flex;
            align-items: center;
            margin: 20px 0;
            gap: 12px;
        }

        .consent-checkbox input[type="checkbox"] {
            width: 20px;
            height: 20px;
            accent-color: #6de1ff;
            cursor: pointer;
        }

        .consent-checkbox label {
            font-size: 15px;
            cursor: pointer;
        }

        .consent-link {
            color: #6de1ff;
            text-decoration: underline;
            transition: var(--transition);
        }

        .consent-link:hover {
            color: #4cc2ff;
        }

        .consent-button {
            width: 100%;
            padding: 16px;
            background: linear-gradient(180deg, #1d2a42, #141c2b);
            color: #eaf7ff;
            border: none;
            border-radius: 16px;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 10px;
            transition: var(--transition);
            position: relative;
            overflow: hidden;
        }

        .consent-button::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
            transition: left 0.5s ease;
        }

        .consent-button:hover::before {
            left: 100%;
        }

        .consent-button:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        .consent-button:not(:disabled):hover {
            box-shadow: 0 14px 36px rgba(109, 225, 255, 0.25), inset 0 0 0 1px var(--ring);
            transform: translateY(-2px);
        }

        /* Floating elements for depth */
        .floating-element {
            position: absolute;
            width: 200px;
            height: 200px;
            border-radius: 50%;
            background: radial-gradient(circle, rgba(109,225,255,0.1) 0%, transparent 70%);
            filter: blur(40px);
            z-index: -1;
            animation: float 6s ease-in-out infinite;
        }

        .floating-element:nth-child(1) {
            top: 20%;
            left: 10%;
            animation-delay: 0s;
        }

        .floating-element:nth-child(2) {
            top: 60%;
            right: 15%;
            animation-delay: -2s;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0px) rotate(0deg); }
            50% { transform: translateY(-20px) rotate(5deg); }
        }

        /* Enhanced focus states */
        *:focus-visible {
            outline: 2px solid var(--ring);
            outline-offset: 2px;
            border-radius: 6px;
        }

        /* Smooth transitions for all interactive elements */
        a, button, input, textarea, .btn, .card, .result-card {
            transition: var(--transition);
        }

        /* Enhanced selection */
        ::selection {
            background: rgba(109,225,255,0.3);
            color: var(--text);
        }

        ::-moz-selection {
            background: rgba(109,225,255,0.3);
            color: var(--text);
        }
