:root {
    --bg-color: #050505;
    /* Glass Liquid UI Tokens */
    --glass-bg: rgba(20, 20, 25, 0.25); /* More transparent for frosted look */
    --glass-border: rgba(255, 255, 255, 0.15); /* White/Silver refractive edge */
    --glass-border-hover: rgba(255, 255, 255, 0.3);
    --glass-highlight: rgba(255, 255, 255, 0.05); /* Inner rim highlight */
    --glass-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.2), inset 0 0 20px rgba(255, 255, 255, 0.05);
    
    --text-main: #FFFFFF;
    --text-dim: rgba(255, 255, 255, 0.6);
    --accent-gold: #E5C07B; /* Brighter gold for neon contrast */
    --accent-blue: #61AFEF;
    --accent-red: #E06C75;
    --glass-blur: blur(24px) saturate(150%);
    
    --font-ui: 'Inter', -apple-system, sans-serif;
    --font-mono: 'Fira Code', monospace;
}

/* --- Dual-Workspace Modifiers --- */
body.team-mode {
    --bg-color: #02050A; /* Obsidian / Deep Corporate Blue */
    --glass-bg: rgba(10, 20, 35, 0.4);
    --accent-gold: #61AFEF; /* Shift gold to corporate intelligence blue */
    --glass-border: rgba(97, 175, 239, 0.2);
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-ui);
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: background-color 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global True Breathing Overlay (Disabled for Glass UI visibility) */
body::after {
    display: none;
}

/* Ambient Liquid Background */
.ambient-bg {
    position: fixed;
    top: -5%; left: -5%; right: -5%; bottom: -5%;
    width: 110%; height: 110%;
    background: url('assets/ambient_bg.png') no-repeat center center;
    background-size: cover;
    animation: deepBreath 20s infinite alternate ease-in-out;
    z-index: -1;
    pointer-events: none;
}

@keyframes deepBreath {
    0% { transform: scale(1.0) translate(0, 0); }
    100% { transform: scale(1.05) translate(-1%, -1%); }
}

.hidden {
    display: none !important;
}

.blink {
    animation: blinker 1s linear infinite;
}
@keyframes blinker {
    50% { opacity: 0; }
}

.dim {
    color: var(--text-dim);
}

.green {
    color: #00FF66;
}
.accent-red {
    color: var(--accent-red);
}

/* Glassmorphism Utilities */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: 20px;
}

/* --- Top Navigation --- */
.top-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    height: 64px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-sidebar-toggle {
    background: none;
    border: none;
    color: var(--text-dim);
    cursor: pointer;
    padding: 6px;
    border-radius: 8px;
    transition: all 0.2s;
}
.btn-sidebar-toggle:hover {
    color: var(--text-main);
    background: rgba(255,255,255,0.05);
}

.team-badge {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1px;
    padding: 3px 10px;
    border-radius: 20px;
    background: rgba(229, 192, 123, 0.1);
    border: 1px solid rgba(229, 192, 123, 0.3);
    color: var(--accent-gold);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 28px;
    height: 28px;
    color: var(--text-main);
}

.brand h1 {
    font-family: "Georgia", serif; 
    font-weight: 300;
    font-style: italic;
    font-size: 28px;
    letter-spacing: 4px;
    background: linear-gradient(180deg, #FFFFFF 0%, #A0B2C6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.9), 0 0 25px rgba(160, 178, 198, 0.5);
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

.lang-selector {
    background: transparent;
    border: none;
    color: var(--text-dim);
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    outline: none;
}
.lang-selector:hover {
    color: var(--text-main);
}
.lang-selector option {
    background: var(--bg-color);
    color: var(--text-main);
}

.btn-wallet {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 6px 14px;
    color: var(--text-main);
    font-family: var(--font-mono);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.btn-wallet:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--glass-border-hover);
}
.wallet-icon {
    color: var(--accent-blue);
    font-weight: bold;
}

.btn-settings {
    background: transparent;
    border: none;
    color: var(--text-dim);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}
.btn-settings:hover {
    color: var(--text-main);
}

/* --- App Container --- */
.app-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding-top: 64px; /* offset for top nav */
    padding-bottom: 120px; /* offset for bottom input */
}

/* --- Welcome Screen (Centered) --- */
.welcome-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    transition: opacity 0.4s ease;
}

.welcome-title {
    font-size: 64px;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-style: italic;
    text-transform: none;
    margin-bottom: 40px;
    letter-spacing: 2px;
    line-height: 1.1;
    background: linear-gradient(135deg, #ffffff 0%, #9b82ff 50%, #5433ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 10px 40px rgba(0, 0, 0, 1), 0 0 30px rgba(155, 130, 255, 0.5), 0 0 60px rgba(84, 51, 255, 0.3);
    animation: cosmicGlow 4s infinite alternate;
}

@keyframes cosmicGlow {
    0% { text-shadow: 0 10px 40px rgba(0, 0, 0, 1), 0 0 30px rgba(155, 130, 255, 0.4), 0 0 60px rgba(84, 51, 255, 0.2); }
    100% { text-shadow: 0 10px 40px rgba(0, 0, 0, 1), 0 0 45px rgba(155, 130, 255, 0.8), 0 0 80px rgba(84, 51, 255, 0.6); }
}

.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    max-width: 600px;
}

.action-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    padding: 12px 20px;
    border-radius: 30px;
    color: var(--text-main);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.action-pill:hover {
    background: rgba(197, 160, 89, 0.08);
    border-color: var(--accent-gold);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.8), 0 0 20px rgba(197, 160, 89, 0.15);
}
.action-pill svg {
    color: var(--accent-gold);
}

/* --- Chat Area --- */
.chat-area {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    padding: 20px;
    /* hide scrollbar for clean look */
    -ms-overflow-style: none;  
    scrollbar-width: none;  
}
.chat-area::-webkit-scrollbar { 
    display: none; 
}

.messages {
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding-bottom: 140px; /* Increased to clear fixed input bar */
}

.message {
    display: flex;
    gap: 16px;
    max-width: 100%;
    animation: fadeIn 0.3s ease;
}

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

.message .avatar {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: 14px;
    flex-shrink: 0;
}

.message.user-msg .avatar {
    background: rgba(255, 255, 255, 0.1);
}

.message.system-msg .avatar {
    background: var(--accent-red);
    color: white;
}

.message .content {
    flex: 1;
    line-height: 1.6;
    font-size: 15px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.message .content p {
    margin-bottom: 12px;
}
.message .content p:last-child {
    margin-bottom: 0;
}

/* --- Knowledge Panel (Gemini Style Fast Lookup) --- */
.knowledge-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    overflow: hidden;
    margin-top: 8px;
    box-shadow: var(--glass-shadow);
}
.kp-header {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px 16px;
    font-weight: 600;
    font-size: 16px;
    border-bottom: 1px solid var(--glass-border);
    color: var(--accent-gold);
}
.kp-content {
    padding: 16px;
    font-size: 14px;
    color: #E0E0E0;
    line-height: 1.5;
}
.kp-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}
.kp-row:last-child {
    border-bottom: none;
}
.kp-label {
    color: var(--text-dim);
}
.kp-value {
    font-weight: 500;
}

/* --- Fixed Input Container --- */
.input-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 20px 24px 20px;
    background: linear-gradient(to top, rgba(5,5,5,0.9) 0%, rgba(5,5,5,0.6) 60%, transparent 100%);
    pointer-events: none;
}

.input-pill {
    display: flex;
    align-items: center;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    padding: 8px 12px 8px 24px;
    width: 100%;
    max-width: 800px;
    pointer-events: auto;
    box-shadow: var(--glass-shadow);
}

.input-pill:focus-within {
    border-color: var(--accent-gold);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.9), 0 0 30px rgba(197, 160, 89, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.attach-icon {
    color: var(--text-dim);
    cursor: pointer;
    padding: 4px;
}
.attach-icon:hover {
    color: var(--text-main);
}

#promptInput {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-main);
    font-family: var(--font-ui);
    font-size: 16px;
    padding: 10px 14px;
    outline: none;
    resize: none;
    line-height: 24px;
    max-height: 200px;
    caret-color: var(--accent-gold);
}
#promptInput::placeholder {
    color: var(--text-dim);
}

.btn-send {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--accent-gold);
    color: var(--accent-gold);
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6), inset 0 0 10px rgba(229, 192, 123, 0.2);
}
.btn-send:hover {
    transform: scale(1.05);
    background: rgba(229, 192, 123, 0.2);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.8), 0 0 15px rgba(229, 192, 123, 0.5);
    color: #FFF;
}

.input-footer {
    margin-top: 12px;
    font-size: 11px;
    color: var(--text-dim);
    font-family: var(--font-ui);
}

/* --- Smoke Terminal (Dark Oracle Logs) --- */
.smoke-terminal {
    width: 100%;
    max-width: 800px;
    background: rgba(5, 5, 5, 0.95);
    border: 1px solid rgba(0, 255, 102, 0.3);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    font-family: var(--font-mono);
    font-size: 12px;
    color: #00FF66;
    backdrop-filter: var(--glass-blur);
    box-shadow: 0 0 20px rgba(0, 255, 102, 0.1), inset 0 0 10px rgba(0, 255, 102, 0.05);
    position: relative;
    overflow: hidden;
}

/* Subtle CRT scanline overlay */
.smoke-terminal::after {
    content: " ";
    display: block;
    position: absolute;
    top: 0; left: 0; bottom: 0; right: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    z-index: 2;
    background-size: 100% 2px, 3px 100%;
    pointer-events: none;
}

.terminal-header {
    border-bottom: 1px dashed rgba(0, 255, 102, 0.4);
    padding-bottom: 8px;
    margin-bottom: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.terminal-body {
    max-height: 140px;
    overflow-y: auto;
    color: #a0a0a0;
    position: relative;
    z-index: 3;
    padding-right: 8px;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 255, 102, 0.3) transparent;
}
.terminal-body::-webkit-scrollbar {
    width: 4px;
}
.terminal-body::-webkit-scrollbar-thumb {
    background: rgba(0, 255, 102, 0.3);
    border-radius: 4px;
}

/* Log Line Theatrics */
.log-line {
    margin-bottom: 6px;
    line-height: 1.4;
    animation: typeLog 0.3s ease-out forwards;
    opacity: 0;
    transform: translateY(5px);
}

.log-line.alert {
    color: #FF3366;
    text-shadow: 0 0 5px rgba(255, 51, 102, 0.4);
}

.log-line.highlight {
    color: #C5A059; /* Accent Gold */
    text-shadow: 0 0 5px rgba(197, 160, 89, 0.4);
}

.log-line.defender {
    color: #3399FF;
    text-shadow: 0 0 5px rgba(51, 153, 255, 0.4);
}

@keyframes typeLog {
    0% { opacity: 0; transform: translateY(5px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* --- Modals (Settings & Deposit) --- */
.modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.settings-panel {
    width: 400px;
    padding: 30px;
    border-radius: 16px;
}

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

.modal-header h2 {
    font-size: 18px;
    font-weight: 600;
}

.close-modal {
    font-size: 24px;
    color: var(--text-dim);
    cursor: pointer;
}
.close-modal:hover {
    color: var(--text-main);
}

/* Settings List */
.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
}
.setting-item:last-child {
    border-bottom: none;
}

.setting-info h3 {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 4px;
}
.setting-info p {
    font-size: 12px;
    color: var(--text-dim);
}

/* Toggle Switch (iOS Style) */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}
.switch input { 
    opacity: 0;
    width: 0;
    height: 0;
}
.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: .4s;
}
.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
}
input:checked + .slider {
    background-color: var(--accent-blue);
}
input:checked + .slider:before {
    transform: translateX(20px);
}
.slider.round {
    border-radius: 24px;
}
.slider.round:before {
    border-radius: 50%;
}

/* Dropdown styling for settings */
.sleek-select {
    width: 100%;
    margin-top: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    padding: 10px;
    border-radius: 8px;
    outline: none;
    font-family: var(--font-ui);
    font-size: 13px;
}
.sleek-select option {
    background: var(--bg-color);
}

/* Deposit Modal specific styles (carried over) */
.network-selector { margin-bottom: 24px; }
.network-options { display: flex; gap: 8px; }
.network-btn {
    flex: 1;
    padding: 10px;
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-dim);
    border-radius: 6px;
    cursor: pointer;
    font-size: 11px;
}
.network-btn.active {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    border-color: var(--border-hover);
}
.deposit-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    margin-bottom: 24px;
}
.qr-placeholder {
    width: 120px;
    height: 120px;
    background: white;
    margin: 0 auto 16px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: black;
}
.address-container {
    display: flex;
    background: rgba(0,0,0,0.5);
    border-radius: 4px;
    padding: 8px 12px;
    align-items: center;
    justify-content: space-between;
}
.wallet-address {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-main);
}
.btn-copy {
    background: var(--text-main);
    color: var(--bg-color);
    border: none;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
}
.payment-status {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
    font-size: 12px;
    color: var(--accent-blue);
}
.spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(42, 133, 255, 0.3);
    border-top-color: var(--accent-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
@keyframes spin { 100% { transform: rotate(360deg); } }

/* --- The Void Gate --- */
.void-gate {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 1.5s ease-out;
}

.void-gate.fade-out {
    opacity: 0;
    pointer-events: none;
}

.void-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.void-brand {
    font-family: "Georgia", serif; 
    font-weight: 300;
    font-style: italic;
    font-size: 32px;
    letter-spacing: 6px;
    background: linear-gradient(180deg, #E0E0E0 0%, #A0B2C6 50%, #C5A059 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.7;
    animation: voidBreathe 4s infinite alternate ease-in-out;
}

@keyframes voidBreathe {
    0% { opacity: 0.3; text-shadow: 0 0 10px rgba(197, 160, 89, 0.1); transform: scale(0.98); }
    100% { opacity: 0.8; text-shadow: 0 0 30px rgba(197, 160, 89, 0.4); transform: scale(1.02); }
}

.void-input {
    background: var(--glass-bg);
    border: none;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    color: #FFFFFF;
    font-family: var(--font-mono);
    font-size: 16px;
    text-align: center;
    padding: 10px;
    width: 280px;
    outline: none;
    letter-spacing: 2px;
    transition: border-color 0.3s ease, text-shadow 0.3s ease;
}

.void-input:focus {
    border-color: var(--accent-gold);
    text-shadow: 0 0 10px rgba(229, 192, 123, 0.5);
}

.void-input::placeholder {
    color: rgba(255, 255, 255, 0.15);
    letter-spacing: 2px;
}

/* --- Upgrade Button (Top Nav) --- */
.btn-upgrade {
    border-color: rgba(229, 192, 123, 0.5);
    box-shadow: 0 0 10px rgba(229, 192, 123, 0.2);
    transition: all 0.3s ease;
}
.btn-upgrade:hover {
    background: rgba(229, 192, 123, 0.1);
    border-color: var(--accent-gold);
    box-shadow: 0 0 15px rgba(229, 192, 123, 0.4), inset 0 0 10px rgba(229, 192, 123, 0.1);
    transform: translateY(-1px);
}
.upgrade-text {
    font-weight: 600;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #FFFFFF, #E5C07B);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Pricing Matrix Modal (Premium z.ai Style) --- */
.pricing-panel {
    width: 900px;
    padding: 40px 50px;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(40px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.pricing-header-new {
    border-bottom: none;
    text-align: center;
    padding-bottom: 0;
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    position: relative;
}

.pricing-header-new .close-modal {
    position: absolute;
    right: -20px;
    top: -20px;
}

.pricing-title-wrapper {
    text-align: center;
}

.pricing-title-wrapper h2 {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #ffffff 0%, #a0a0a0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 8px;
}

.pricing-subtitle {
    font-size: 14px;
    color: #888;
    font-weight: 400;
}

/* Billing Toggle Switch */
.billing-toggle-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 40px;
}

.toggle-label {
    font-size: 14px;
    font-weight: 500;
    color: #a0a0a0;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.badge-save {
    background: rgba(97, 175, 239, 0.15);
    color: #61afef;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: .4s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 2px;
    bottom: 2px;
    background-color: #fff;
    transition: .4s;
}

.switch input:checked + .slider {
    background-color: var(--accent-blue);
    border-color: var(--accent-blue);
}

.switch input:checked + .slider:before {
    transform: translateX(20px);
}

.slider.round {
    border-radius: 24px;
}
.slider.round:before {
    border-radius: 50%;
}

/* Tier Matrix & Cards */
.tier-matrix {
    display: flex;
    gap: 20px;
}

.tier-card {
    flex: 1;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.tier-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.tier-header {
    margin-bottom: 24px;
}

.tier-header h3 {
    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 12px;
    font-weight: 600;
}

.tier-price {
    font-size: 36px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 12px;
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.tier-price .period {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.tier-desc {
    font-size: 13px;
    color: #a0a0a0;
    line-height: 1.5;
    margin-bottom: 24px;
    min-height: 40px;
}

/* CTA Buttons */
.btn-tier-cta {
    width: 100%;
    padding: 12px 0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}

.btn-tier-cta:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-tier-cta.active-cta {
    background: var(--accent-blue);
    border: 1px solid var(--accent-blue);
    color: #111;
    box-shadow: 0 4px 15px rgba(97, 175, 239, 0.3);
}

.btn-tier-cta.active-cta:hover {
    background: #7cbef2;
    box-shadow: 0 6px 20px rgba(97, 175, 239, 0.4);
}

/* Features List */
.tier-features {
    list-style: none;
    padding: 0;
    margin: 0;
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding-top: 24px;
}

.tier-features li {
    font-size: 13px;
    color: #b0b0b0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.tier-features li svg {
    color: var(--accent-blue);
    flex-shrink: 0;
}

/* Specific Tiers Styling */
.tier-card.highlight-tier {
    background: rgba(97, 175, 239, 0.03);
    border: 1px solid rgba(97, 175, 239, 0.3);
    box-shadow: 0 0 30px rgba(97, 175, 239, 0.05);
    transform: scale(1.02);
    z-index: 2;
}

.tier-card.highlight-tier:hover {
    transform: scale(1.02) translateY(-8px);
    border-color: rgba(97, 175, 239, 0.6);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 40px rgba(97, 175, 239, 0.15);
}

.tier-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(90deg, #61afef, #98c379);
    color: #111;
    font-size: 10px;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 12px;
    letter-spacing: 1px;
    box-shadow: 0 4px 10px rgba(97, 175, 239, 0.3);
}

.tier-card.highlight-tier .tier-header h3 {
    color: #61afef;
}

/* Apex Tier */
.tier-card.apex-tier {
    border-color: rgba(198, 120, 221, 0.2);
}
.tier-card.apex-tier:hover {
    border-color: rgba(198, 120, 221, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 30px rgba(198, 120, 221, 0.1);
}
.tier-card.apex-tier .tier-header h3 {
    color: #c678dd;
}
.tier-card.apex-tier .tier-features li svg {
    color: #c678dd;
}

/* ================================================================
   SIDEBAR — Figma Mode (Team Collaboration)
   ================================================================ */

.app-container {
    display: flex;
    flex-direction: row;
    height: calc(100vh - 64px);
    margin-top: 64px;
    position: relative;
}

.sidebar {
    width: 280px;
    min-width: 280px;
    height: 100%;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px) saturate(120%);
    -webkit-backdrop-filter: blur(20px) saturate(120%);
    border-right: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s;
    z-index: 50;
}

.sidebar.collapsed {
    margin-left: -280px;
    opacity: 0;
    pointer-events: none;
}

.sidebar-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 12px;
    overflow-y: auto;
    scrollbar-width: none;
}
.sidebar-inner::-webkit-scrollbar { display: none; }

/* New Chat Button */
.btn-new-chat {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    color: var(--text-dim);
    font-family: var(--font-ui);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 16px;
}
.btn-new-chat:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.25);
    color: var(--text-main);
}
.btn-new-team-chat {
    margin-top: 6px;
    margin-bottom: 0;
    padding: 7px 12px;
    font-size: 11px;
    border-style: dotted;
}

/* Sidebar Sections */
.sidebar-section {
    margin-bottom: 20px;
}
.sidebar-section-header {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-dim);
    padding: 0 8px 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Conversation List */
.conv-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.conv-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
    font-size: 13px;
    color: var(--text-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.conv-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
}
.conv-item.active {
    background: rgba(229, 192, 123, 0.08);
    color: var(--text-main);
    border-left: 2px solid var(--accent-gold);
}
.conv-item .conv-icon {
    font-size: 14px;
    flex-shrink: 0;
}
.conv-item .conv-title {
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Member List */
.member-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.member-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 12px;
    border-radius: 8px;
    font-size: 12px;
    color: var(--text-dim);
}
.member-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(229, 192, 123, 0.2), rgba(97, 175, 239, 0.2));
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-main);
    flex-shrink: 0;
}
.member-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.member-role {
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 1px;
    padding: 2px 6px;
    border-radius: 8px;
    background: rgba(229, 192, 123, 0.1);
    color: var(--accent-gold);
}
.member-role.role-member {
    background: rgba(97, 175, 239, 0.1);
    color: var(--accent-blue);
}

/* Invite / Team Action Buttons */
.btn-invite, .btn-team-action {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 8px 12px;
    background: none;
    border: none;
    border-radius: 8px;
    color: var(--text-dim);
    font-family: var(--font-ui);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 6px;
}
.btn-invite:hover, .btn-team-action:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
}

.sidebar-footer {
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--glass-border);
}

/* Team Modal Tabs */
.team-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--glass-border);
}
.team-tab {
    flex: 1;
    padding: 10px;
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: var(--font-ui);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.2s;
    border-bottom: 2px solid transparent;
}
.team-tab:hover { color: var(--text-main); }
.team-tab.active {
    color: var(--accent-gold);
    border-bottom-color: var(--accent-gold);
}
.team-tab-content { padding: 8px 0; }
.team-result {
    margin-top: 12px;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 12px;
    font-family: var(--font-mono);
}
.team-result.success {
    background: rgba(0, 255, 102, 0.08);
    border: 1px solid rgba(0, 255, 102, 0.2);
    color: #00FF66;
}
.team-result.error {
    background: rgba(224, 108, 117, 0.08);
    border: 1px solid rgba(224, 108, 117, 0.2);
    color: var(--accent-red);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        top: 64px;
        left: 0;
        bottom: 0;
        z-index: 99;
        box-shadow: 10px 0 40px rgba(0,0,0,0.5);
    }
    .sidebar.collapsed {
        margin-left: -280px;
    }
}
/* Price Discount Logic */
.price-original {
    font-size: 16px;
    color: #666;
    text-decoration: line-through;
    margin-right: 8px;
    font-weight: 500;
}
.price-original.hidden {
    display: none;
}
/* Gold Tier CSS (Singularity) Re-add */
.tier-card.gold-tier {
    border-color: rgba(229, 192, 123, 0.2);
}
.tier-card.gold-tier:hover {
    border-color: rgba(229, 192, 123, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6), 0 0 30px rgba(229, 192, 123, 0.1);
}
.tier-card.gold-tier .tier-header h3 {
    color: #E5C07B;
}
.tier-card.gold-tier .tier-features li svg {
    color: #E5C07B;
}

