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

:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --secondary-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --dark-bg: #0f172a;
    --dark-card: #1e293b;
    --dark-border: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--dark-bg);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

/* Navbar */
.navbar {
    background: var(--dark-card);
    border-bottom: 1px solid var(--dark-border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: rgba(30, 41, 59, 0.95);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-brand i {
    font-size: 1.75rem;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-color);
}

/* Buttons */
.btn {
    padding: 0.5rem 1.25rem;
    border: none;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(99, 102, 241, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
}

.btn-lg {
    padding: 0.75rem 2rem;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
}

/* Wallet Info */
.wallet-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--dark-border);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
}

.wallet-address {
    color: var(--text-secondary);
    font-family: monospace;
    font-size: 0.9rem;
}

.hidden {
    display: none !important;
}

/* Pages */
.page {
    display: none;
    animation: fadeIn 0.5s ease;
}

.page.active {
    display: block;
}

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

/* Hero Section */
.hero {
    padding: 4rem 2rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(236, 72, 153, 0.1) 100%);
    border-bottom: 1px solid var(--dark-border);
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 4rem;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 1rem;
    max-width: 400px;
    margin: 0 auto;
}

.stat-card {
    background: var(--dark-card);
    padding: 1.2rem;
    border-radius: 0.8rem;
    border: 1px solid var(--dark-border);
    text-align: center;
    min-width: 160px;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

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

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.page-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Forms */
.create-form-container {
    max-width: 600px;
    margin: 0 auto;
}

.token-form {
    background: var(--dark-card);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid var(--dark-border);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* File Upload Styles */
.logo-upload-container {
    position: relative;
}

.file-input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 2;
}

.upload-area {
    position: relative;
    border: 2px dashed var(--dark-border);
    border-radius: 0.75rem;
    padding: 2rem;
    text-align: center;
    background: var(--dark-bg);
    transition: all 0.3s ease;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-area:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.upload-area.dragover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
    transform: scale(1.02);
}

.upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.upload-icon {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.upload-text {
    color: var(--text-primary);
    font-weight: 500;
    margin: 0;
}

.upload-hint {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin: 0;
}

.upload-preview {
    position: relative;
    width: 100%;
    height: 100%;
}

.upload-preview img {
    width: 100%;
    height: 120px;
    object-fit: contain;
    border-radius: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
}

.remove-preview-btn {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--danger-color);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    transition: all 0.2s ease;
    z-index: 3;
}

.remove-preview-btn:hover {
    background: #dc2626;
    transform: scale(1.1);
}

/* Chart Panel Styles */
.chart-panel {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    overflow: hidden;
    min-height: 500px;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: var(--dark-bg);
    border-bottom: 1px solid var(--dark-border);
}

.chart-header h3 {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}

.chart-container {
    position: relative;
    height: 450px;
    width: 100%;
}

.chart-placeholder,
.chart-loading,
.chart-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    height: 100%;
    width: 100%;
}

.chart-placeholder i,
.chart-loading i,
.chart-error i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.chart-placeholder i {
    color: var(--primary-color);
}

.chart-loading i {
    color: var(--secondary-color);
}

.chart-error i {
    color: var(--warning-color);
}

.chart-placeholder p,
.chart-loading p,
.chart-error p {
    color: var(--text-primary);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.chart-placeholder small,
.chart-error small {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

@media (max-width: 1024px) {
    .chart-panel {
        order: -1;
        margin-bottom: 1rem;
    }
    
    .chart-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    
    .chart-container {
        height: 350px;
    }
}

/* Tokens Grid */
.tokens-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}

.search-input {
    flex: 1;
    padding: 0.75rem;
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 1rem;
}

.sort-select,
.filter-select,
.token-select {
    padding: 0.75rem;
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    cursor: pointer;
}

.tokens-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.token-card {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.token-card.clickable:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(45, 206, 137, 0.2);
    border-color: var(--primary-color);
}

.token-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    gap: 1rem;
}

.token-logo-container {
    flex-shrink: 0;
}

.token-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
}

.token-stats {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-end;
    flex-shrink: 0;
}

.token-logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--dark-border);
}

.token-symbol-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    font-weight: 700;
}

.token-symbol-placeholder.large {
    width: 60px;
    height: 60px;
    font-size: 1.8rem;
}

.stat-item {
    text-align: right;
}

.stat-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.token-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.2;
}

.token-symbol {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.token-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--dark-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.token-address {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-family: 'Courier New', monospace;
}

/* Token Detail Modal */
.token-detail-modal {
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--dark-border);
    margin-bottom: 2rem;
}

.token-header-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.token-logo-large {
    flex-shrink: 0;
}

.token-main-info h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.25rem 0;
}

.token-main-info .token-symbol {
    font-size: 1rem;
    color: var(--text-secondary);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--dark-hover);
    color: var(--text-primary);
}

.token-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.detail-group {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.5rem;
}

.detail-group h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--dark-border);
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.detail-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.detail-item .label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.detail-item .value {
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 600;
    text-align: right;
}

.address-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.full-address {
    font-family: 'Courier New', monospace;
    font-size: 0.8rem !important;
    word-break: break-all;
}

.btn-copy {
    background: none;
    border: 1px solid var(--dark-border);
    color: var(--text-secondary);
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.8rem;
}

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

.pools-section {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.pools-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--dark-border);
}

.pools-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.pool-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    gap: 1rem;
}

.pool-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.pool-pair {
    font-weight: 600;
    color: var(--text-primary);
}

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

/* Pool action buttons */
.pool-actions {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.pool-trade-btn, .pool-liquidity-btn {
    flex-shrink: 0;
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    min-width: 70px;
}

.pool-liquidity-btn {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.pool-liquidity-btn:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.no-pools-message {
    color: var(--text-secondary);
    font-style: italic;
    margin: 0 0 1rem 0;
}

.no-pools-actions {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.no-pools-actions .btn {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
}

.modal-footer {
    padding-top: 2rem;
    border-top: 1px solid var(--dark-border);
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.action-buttons .btn {
    min-width: 150px;
}

/* Tokens count display */
.tokens-count {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    text-align: center;
    font-weight: 500;
}

.token-symbol {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.token-name {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.token-info {
    display: flex;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid var(--dark-border);
}

.token-info-item {
    text-align: center;
}

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

.token-info-value {
    font-weight: 600;
    color: var(--text-primary);
}

/* Trade Layout */
.trade-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

@media (max-width: 1024px) {
    .trade-layout {
        grid-template-columns: 1fr;
        max-width: 500px;
    }
}

.trade-panel {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    overflow: hidden;
}

.trade-tabs {
    display: flex;
    background: var(--dark-bg);
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn.active {
    background: var(--dark-card);
    color: var(--primary-color);
}

.tab-content {
    display: none;
    padding: 2rem;
}

.tab-content.active {
    display: block;
}

.swap-form,
.liquidity-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.swap-input-group {
    background: var(--dark-bg);
    padding: 1rem;
    border-radius: 0.75rem;
    border: 1px solid var(--dark-border);
}

.token-input {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.token-input input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
}

.token-input input:focus {
    outline: none;
}

/* Enhanced Liquidity Form Styles */
.liquidity-pair {
    display: flex;
    gap: 1rem;
    align-items: stretch;
    position: relative;
}

.pair-input {
    flex: 1;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(51, 65, 85, 0.6));
    border: 2px solid var(--dark-border);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.pair-input::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.pair-input:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.2);
}

.pair-input:focus-within {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(51, 65, 85, 0.7));
}

.pair-input:focus-within::before {
    opacity: 1;
}

.pair-input label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pair-input label::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    background-size: contain;
    background-repeat: no-repeat;
}

.pair-input:first-child label::before {
    content: '⟠';
    color: #627EEA;
    font-size: 1.2rem;
    width: auto;
    height: auto;
}

.pair-input:last-child label::before {
    content: '🪙';
    font-size: 1rem;
    width: auto;
    height: auto;
}

.pair-input input[type="number"] {
    width: 100%;
    padding: 0.75rem;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.pair-input input[type="number"]:hover {
    background: rgba(15, 23, 42, 0.7);
    border-color: rgba(148, 163, 184, 0.3);
}

.pair-input input[type="number"]:focus {
    outline: none;
    background: rgba(15, 23, 42, 0.8);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.pair-input input[type="number"]::placeholder {
    color: rgba(148, 163, 184, 0.5);
}

.pair-input .token-select {
    margin-top: 0.5rem;
    width: 100%;
    padding: 0.75rem;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 0.5rem;
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pair-input .token-select:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: var(--primary-color);
}

.pair-input .token-select:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

/* New vertical layout for liquidity pairs */
.liquidity-pair-vertical {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.5rem 0;
}

.liquidity-input-container {
    width: 100%;
}

.liquidity-input-container label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.liquidity-token-input {
    display: flex;
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1rem;
    gap: 1rem;
    align-items: center;
    transition: border-color 0.3s ease;
}

.liquidity-token-input:focus-within {
    border-color: var(--primary-color);
}

.liquidity-amount-input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    padding: 0;
    min-width: 0;
}

.liquidity-amount-input:focus {
    outline: none;
}

.liquidity-amount-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

.token-select-button {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 140px;
    flex-shrink: 0;
}

.token-select-button:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.token-select-button.placeholder {
    color: var(--text-secondary);
}

.liquidity-plus-separator {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0.5rem 0;
}

.plus-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--dark-bg);
    border: 2px solid var(--dark-border);
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Old horizontal layout styles (keep for compatibility) */
.pair-plus {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    position: relative;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.1); }
}

.swap-reverse-btn {
    align-self: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.swap-reverse-btn:hover {
    transform: rotate(180deg);
    color: var(--primary-color);
}

.swap-details {
    background: var(--dark-bg);
    padding: 1rem;
    border-radius: 0.5rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.detail-row:last-child {
    margin-bottom: 0;
}

.detail-row:nth-child(2),
.detail-row:nth-child(3) {
    color: var(--warning-color);
    font-weight: 500;
}

.detail-row:nth-child(4) {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 1rem;
    padding-top: 0.5rem;
    border-top: 1px solid var(--dark-border);
}

/* Marketplace */
.marketplace-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.marketplace-filters {
    display: flex;
    gap: 1rem;
    flex: 1;
    margin-right: 1rem;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.product-card {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

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

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: var(--dark-bg);
}

.product-info {
    padding: 1rem;
}

.product-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.product-price {
    color: var(--primary-color);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.product-seller {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.seller-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.seller-rating i {
    color: var(--warning-color);
}

/* Profile */
.profile-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
}

.profile-sidebar {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 2rem;
    height: fit-content;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--dark-bg);
    border-radius: 50%;
    font-size: 4rem;
    color: var(--primary-color);
}

.profile-address {
    text-align: center;
    font-family: monospace;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    word-break: break-all;
}

.profile-stats {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-stats .stat {
    text-align: center;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 0.5rem;
}

.profile-content {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    overflow: hidden;
}

.profile-tabs {
    display: flex;
    background: var(--dark-bg);
    border-bottom: 1px solid var(--dark-border);
}

.profile-tabs .tab-btn {
    padding: 1rem 1.5rem;
}

.profile-tab-content {
    padding: 2rem;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 2rem;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--dark-bg);
    color: var(--text-secondary);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

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

.modal-close svg {
    transition: transform 0.2s ease;
}

.modal-close:hover svg {
    transform: rotate(90deg);
}

.modal h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
}

/* Tutorial Steps */
.tutorial-steps {
    margin: 2rem 0;
}

.step {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 0.5rem;
}

.step-number {
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.step-content h4 {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.step-content p {
    color: var(--text-secondary);
}

.step-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.step-content a:hover {
    text-decoration: underline;
}

/* Cart */
.cart-button {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.4);
    transition: all 0.3s ease;
}

.cart-button:hover {
    transform: scale(1.1);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger-color);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 0.5rem;
}

.cart-summary {
    background: var(--dark-bg);
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    font-size: 0.95rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--dark-border);
}

.cart-total-row:last-child {
    border-bottom: none;
}

.cart-total {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    padding-top: 0.75rem;
    border-top: 2px solid var(--primary-color);
    margin-top: 0.5rem;
    border-top: 1px solid var(--dark-border);
    margin-bottom: 1rem;
}

/* Loader */
.loader {
    width: 50px;
    height: 50px;
    border: 3px solid var(--dark-border);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Liquidity Form Enhancements */
.liquidity-info {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
    border: 1px solid transparent;
    border-image: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) 1;
    border-radius: 0.5rem;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

.liquidity-info::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

.liquidity-info .info-text {
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    z-index: 1;
}

.liquidity-info .info-text i {
    color: var(--primary-color);
    font-size: 1.25rem;
}

.liquidity-details {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.9));
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.25rem;
    margin: 1.5rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.liquidity-details .detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    margin: 0.5rem 0;
    background: rgba(51, 65, 85, 0.3);
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.liquidity-details .detail-row:hover {
    background: rgba(51, 65, 85, 0.5);
    transform: translateX(5px);
}

.liquidity-details .detail-row span:first-child {
    font-weight: 500;
    color: var(--text-secondary);
}

.liquidity-details .detail-row span:last-child,
.liquidity-details .detail-row select {
    font-weight: 600;
    color: var(--text-primary);
}

.fee-select, .range-select {
    background: var(--dark-card);
    color: var(--text-primary);
    border: 1px solid var(--dark-border);
    padding: 0.5rem;
    border-radius: 0.25rem;
    min-width: 150px;
}

/* Modal Improvements */
.modal-body {
    padding: 1.5rem 0;
}

.token-info-box {
    background: var(--dark-bg);
    padding: 1rem;
    border-radius: 0.5rem;
    margin: 1rem 0;
}

.token-info-box label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.address-display {
    font-family: monospace;
    font-size: 0.875rem;
    color: var(--primary-color);
    word-break: break-all;
    padding: 0.5rem;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 0.25rem;
}

.liquidity-prompt {
    margin-top: 1.5rem;
}

.liquidity-prompt h4 {
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.prompt-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.prompt-actions button {
    flex: 1;
}

/* Highlight animation */
@keyframes highlight {
    0% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(99, 102, 241, 0); }
    100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
}

.highlight {
    animation: highlight 2s ease;
    border-color: var(--primary-color) !important;
}

/* Enhanced button styles (ancien style Add Liquidity appliqué globalement) */
.btn-enhanced-primary {
    margin-top: 1rem;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    border: none;
    border-radius: 0.5rem;
    color: white;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-enhanced-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-enhanced-primary:hover::before {
    width: 300px;
    height: 300px;
}

.btn-enhanced-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(99, 102, 241, 0.3);
}

.btn-enhanced-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: linear-gradient(135deg, #64748b, #475569);
}

/* Apply enhanced style to specific buttons */
#addLiquidityBtn,
#removeLiquidityBtn,
#swapBtn,
#deployTokenBtn {
    /* Inherit enhanced primary style */
    width: 100%;
    display: flex;
}

/* Footer */
.app-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(30, 41, 59, 0.9);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--dark-border);
    padding: 0.75rem;
    z-index: 100;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    text-align: center;
}

.footer-text {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

.footer-text i {
    margin-right: 0.5rem;
    color: var(--warning-color);
}

.footer-link {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Add padding to main content to account for footer */
.main-content {
    padding-bottom: 4rem;
}

/* Liquidity Mode Selector */
.liquidity-mode-selector {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    background: var(--dark-bg);
    padding: 0.5rem;
    border-radius: 0.75rem;
}

.mode-btn {
    flex: 1;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.mode-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--text-primary);
}

.mode-btn.active {
    background: var(--primary-color);
    color: white;
}

/* Liquidity Sections */
.liquidity-section {
    display: none;
}

.liquidity-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* Pool Status Card */
.pool-status-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.pool-status-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.pool-status-label {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.pool-status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 2rem;
    font-size: 0.85rem;
    font-weight: 500;
}

.pool-status-badge.new {
    background: var(--secondary-color);
    color: white;
}

.pool-status-badge.exists {
    background: var(--primary-color);
    color: white;
}

.pool-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1rem;
}

.pool-stat {
    text-align: center;
    width: 100%;
}

.pool-stat .stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.pool-stat .stat-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* Price Ratio Display */
.price-ratio-card {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1rem;
    margin: 1rem 0;
}

.ratio-header {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    text-align: center;
}

.ratio-values {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    font-size: 0.95rem;
    color: var(--text-primary);
    font-weight: 500;
}

.ratio-separator {
    color: var(--text-secondary);
}

/* Warning Message */
.warning-message {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid var(--warning-color);
    color: var(--warning-color);
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin: 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Slippage Select */
.slippage-select {
    background: var(--dark-bg);
    color: var(--text-primary);
    border: 1px solid var(--dark-border);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.9rem;
}

/* Remove Liquidity Section */
.remove-liquidity-container {
    padding: 1rem;
}

.positions-list {
    display: grid;
    gap: 1rem;
    margin: 1.5rem 0;
}

.position-card {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.position-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.position-card.selected {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

.position-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.position-pair {
    font-size: 1.1rem;
    font-weight: 600;
}

.position-value {
    color: var(--secondary-color);
    font-weight: 600;
}

.position-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    font-size: 0.9rem;
}

.position-detail {
    display: flex;
    justify-content: space-between;
}

.position-detail .label {
    color: var(--text-secondary);
}

.position-detail .value {
    color: var(--text-primary);
    font-weight: 500;
}

/* Amount Slider */
.amount-slider-container {
    margin: 1.5rem 0;
}

.liquidity-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--dark-border);
    outline: none;
    -webkit-appearance: none;
}

.liquidity-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.liquidity-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: none;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.remove-output-preview {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    padding: 1rem;
    margin: 1rem 0;
}

.output-token {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
}

.output-token:not(:last-child) {
    border-bottom: 1px solid var(--dark-border);
}

.token-label {
    color: var(--text-secondary);
}

.token-amount {
    color: var(--text-primary);
    font-weight: 600;
}

/* My Positions Section */
.positions-overview {
    padding: 1rem;
}

.overview-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.positions-grid {
    display: grid;
    gap: 1rem;
}


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

/* Position actions */
.position-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--dark-border);
}

.position-actions .btn {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Loading state */
.loading {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 0.5rem;
}

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

/* Anciens styles pour input-with-max (non utilisés maintenant) */
.input-with-max {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-max input {
    flex: 1;
    padding-right: 60px;
}

.max-btn {
    position: absolute;
    right: 8px;
    padding: 4px 8px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 2;
}

.max-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

/* Nouveau style pour boutons Max inline dans les labels */
.max-btn-inline {
    padding: 2px 6px;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 600;
    cursor: pointer;
    margin-left: 8px;
    transition: all 0.2s ease;
}

.max-btn-inline:hover {
    background: #059669;
    transform: scale(1.05);
}

/* Supprimer les flèches spinner des inputs number */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

/* Améliorer l'affichage des selects de tokens */
.token-select {
    max-width: 100%;
    min-width: 120px;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    flex: 1;
}

.token-select option {
    padding: 8px;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    max-width: 100%;
}

/* Améliorer l'affichage du token-input */
.token-input {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    margin-top: 0.5rem;
}

.token-input input {
    flex: 2;
    min-width: 0; /* Permet à l'input de se réduire */
}

.token-input select {
    flex: 1;
    min-width: 120px; /* Largeur minimum pour les selects */
    max-width: 150px; /* Largeur maximum pour éviter qu'ils prennent trop de place */
}

/* Status Messages */
.deployment-status {
    margin-top: 2rem;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 0.5rem;
    text-align: center;
}

.status-message {
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 0.5rem;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid var(--dark-border);
}

.status-message.success {
    color: var(--secondary-color);
    background: rgba(16, 185, 129, 0.1);
    border-color: var(--secondary-color);
}

.status-message.error {
    color: var(--danger-color);
    background: rgba(239, 68, 68, 0.1);
    border-color: var(--danger-color);
}

#liquidityStatus {
    margin-top: 1rem;
    transition: all 0.3s ease;
}

#liquidityStatus.hidden {
    display: none;
}

#liquidityStatus i {
    margin-right: 0.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .nav-menu {
        display: none;
    }
    
    .profile-container {
        grid-template-columns: 1fr;
    }
    
    .marketplace-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    .marketplace-filters {
        width: 100%;
        flex-direction: column;
    }
}

/* Fee Information Section */
.fee-info-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(16, 185, 129, 0.1) 100%);
    margin-top: 3rem;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.fee-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.fee-card {
    background: var(--dark-card);
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    border: 1px solid var(--dark-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.fee-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.2);
}

.fee-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.fee-card h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.fee-rate {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--warning-color);
    margin-bottom: 0.5rem;
}

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

.fee-note {
    text-align: center;
    padding: 1rem 2rem;
    background: var(--dark-card);
    border-radius: 0.5rem;
    border-left: 4px solid var(--primary-color);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.fee-note i {
    color: var(--primary-color);
    margin-right: 0.5rem;
}

/* Approval Section in Swap Form */
.approval-section {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(16, 185, 129, 0.05));
    padding: 1.25rem;
    border-radius: 0.75rem;
    margin: 1.5rem 0;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.approval-label {
    display: block;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.approval-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.approval-btn {
    background: var(--dark-bg);
    border: 2px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
}

.approval-btn:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.approval-btn.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
    border-color: var(--primary-color);
    color: var(--text-primary);
}

.approval-btn i {
    font-size: 1.25rem;
    color: var(--primary-color);
}

.approval-btn div {
    text-align: left;
}

.approval-btn strong {
    display: block;
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
}

.approval-btn small {
    display: block;
    font-size: 0.75rem;
    opacity: 0.8;
}

/* Notifications */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    color: white;
    font-weight: 500;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 10001;
    max-width: 350px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.notification.show {
    transform: translateX(0);
    opacity: 1;
}

.notification-success {
    background: linear-gradient(135deg, var(--secondary-color), #059669);
}

.notification-error {
    background: linear-gradient(135deg, var(--danger-color), #dc2626);
}

.notification-info {
    background: linear-gradient(135deg, var(--primary-color), #4338ca);
}

.notification i {
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* Tutorial Actions */
.tutorial-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    justify-content: center;
}

.tutorial-actions .btn {
    flex: 1;
    max-width: 200px;
}

/* User Tokens List */
.user-tokens-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-token-item {
    background: var(--dark-card);
    padding: 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid var(--dark-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.token-info h4 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.token-info p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0.25rem 0;
}

.token-stats .badge {
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 600;
}

.badge-success {
    background: var(--secondary-color);
    color: white;
}

.badge-warning {
    background: var(--warning-color);
    color: white;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.empty-state h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

/* Token Selector Modal */
.token-selector-modal {
    max-width: 750px;
    max-height: 92vh;
    width: 95%;
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 1.5rem 1.5rem 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--dark-border);
    padding-bottom: 1rem;
    margin-bottom: 0;
}

.modal-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: 1.25rem;
}

.token-search-container {
    padding: 1rem 1.5rem 0 1.5rem;
}

.search-input-wrapper {
    position: relative;
    margin-bottom: 1rem;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 0.875rem;
    z-index: 1;
}

.token-search-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.5rem;
    background: var(--dark-bg);
    border: 2px solid var(--dark-border);
    border-radius: 0.75rem;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.token-search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.token-categories {
    display: flex;
    gap: 0.5rem;
    padding: 0 1.5rem 1rem 1.5rem;
    border-bottom: 1px solid var(--dark-border);
}

.category-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.6rem;
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn:hover {
    border-color: var(--primary-color);
    color: var(--text-primary);
}

.category-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.category-btn i {
    font-size: 0.75rem;
}

.token-list-container {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tokens-list {
    flex: 1;
    overflow-y: auto;
    padding: 0 1.5rem;
    max-height: 600px;
}

.token-item {
    display: flex;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
    transition: all 0.2s ease;
}

.token-item:hover {
    background: rgba(99, 102, 241, 0.05);
    margin: 0 -1rem;
    padding-left: 1rem;
    padding-right: 1rem;
    border-radius: 0.5rem;
    border-bottom-color: transparent;
}

.token-item-main {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
}

.token-logo {
    width: 40px;
    height: 40px;
    position: relative;
}

.token-logo img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.token-logo-placeholder {
    width: 100%;
    height: 100%;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
}

.token-info {
    flex: 1;
    min-width: 0;
}

.token-main-info {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.token-symbol {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.token-name {
    color: var(--text-secondary);
    font-size: 0.8rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.token-details {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.token-address {
    color: var(--text-secondary);
    font-size: 0.7rem;
    font-family: monospace;
    cursor: help;
    word-break: break-all;
    line-height: 1.2;
}

.token-custom-badge {
    background: var(--warning-color);
    color: white;
    font-size: 0.65rem;
    padding: 0.1rem 0.4rem;
    border-radius: 0.25rem;
    font-weight: 600;
}

.favorite-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.favorite-btn:hover {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
}

.favorite-btn.active {
    color: var(--warning-color);
}

.favorite-btn i {
    font-size: 0.9rem;
}

.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1rem;
    gap: 0.5rem;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 2px solid var(--dark-border);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-spinner p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin: 0;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--dark-border);
    background: var(--dark-bg);
}

.token-count {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin: 0;
    text-align: center;
}

.no-results {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 3rem 2rem;
    text-align: center;
    color: var(--text-secondary);
}

.no-results i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    opacity: 0.5;
}

.no-results p {
    color: var(--text-primary);
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.no-results small {
    font-size: 0.8rem;
}

/* Token Button Styles - replaces select dropdowns */
.token-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
    font-size: 0.95rem;
}

.token-button:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.token-button .token-logo {
    width: 20px;
    height: 20px;
}

.token-button .token-logo img,
.token-button .token-logo-placeholder {
    width: 20px;
    height: 20px;
    font-size: 0.7rem;
}

.token-button-content {
    flex: 1;
    text-align: left;
}

.token-button .token-symbol {
    font-weight: 600;
    font-size: 0.9rem;
}

.token-button .chevron {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.token-button.placeholder {
    color: var(--text-secondary);
}

.token-button.placeholder .chevron {
    transform: rotate(0deg);
}

/* Scrollbar for tokens list */
.tokens-list::-webkit-scrollbar {
    width: 6px;
}

.tokens-list::-webkit-scrollbar-track {
    background: transparent;
}

.tokens-list::-webkit-scrollbar-thumb {
    background: var(--dark-border);
    border-radius: 3px;
}

.tokens-list::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

/* Responsive adjustments */
@media (max-width: 640px) {
    .token-selector-modal {
        max-width: 95%;
        max-height: 85vh;
    }

    .category-btn {
        font-size: 0.75rem;
        padding: 0.5rem;
    }

    .category-btn span {
        display: none;
    }

    .token-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

/* Hidden utility */
.hidden {
    display: none !important;
}

/* Wallet Connection Warning for Liquidity */
.wallet-warning-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(16, 185, 129, 0.1));
    border: 2px dashed var(--primary-color);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.wallet-warning-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.wallet-warning-card h4 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.wallet-warning-card p {
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* Custom Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-container {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
    position: relative;
}

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

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

.modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
}

.modal-close:hover {
    background: var(--dark-border);
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
    text-align: center;
}

.modal-icon {
    margin-bottom: 1rem;
}

.modal-icon i {
    font-size: 3rem;
    color: var(--primary-color);
}

.modal-icon.warning i {
    color: var(--warning-color);
}

.modal-icon.danger i {
    color: var(--danger-color);
}

.modal-icon.success i {
    color: var(--secondary-color);
}

.modal-message {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin: 0;
    white-space: pre-line;
}

.modal-footer {
    padding: 1rem 1.5rem 1.5rem;
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    border-top: 1px solid var(--dark-border);
}

.modal-footer .btn {
    min-width: 100px;
}

/* Token Address Display in Profile */
.token-address-full {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.5rem 0;
    font-family: monospace;
}

.address-label {
    color: var(--text-secondary);
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    min-width: auto;
}

.address-value {
    color: var(--text-primary);
    background: var(--dark-bg);
    padding: 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    word-break: break-all;
    flex: 1;
    border: 1px solid var(--dark-border);
    transition: all 0.2s ease;
    cursor: pointer;
}

.address-value:hover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.copy-btn {
    background: var(--primary-color);
    border: none;
    color: white;
    padding: 0.5rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    height: 2.5rem;
}

.copy-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.copy-btn i {
    font-size: 0.875rem;
}

/* Responsive adjustments for token addresses */
@media (max-width: 768px) {
    .token-address-full {
        flex-direction: column;
        align-items: stretch;
        gap: 0.25rem;
    }
    
    .address-value {
        font-size: 0.75rem;
        padding: 0.375rem;
    }
}

/* Profile Tabs */
.profile-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--dark-border);
}

.tab-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--text-primary);
    background: rgba(99, 102, 241, 0.05);
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* Portfolio Token Items */
.user-portfolio-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.portfolio-token-item {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
}

.portfolio-token-item:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.1);
}

.portfolio-token-item .token-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.token-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    position: relative;
}

.token-icon img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.token-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
}

.token-details h4 {
    color: var(--text-primary);
    margin: 0 0 0.25rem 0;
    font-size: 1.1rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 250px;
}

.token-address-small {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-family: monospace;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 250px;
}

.token-balance {
    text-align: right;
}

.balance-amount {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.balance-symbol {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Loading and Empty States for Portfolio */
.loading {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--text-secondary);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 0.5rem;
}

/* Responsive for portfolio */
@media (max-width: 768px) {
    .portfolio-token-item {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .portfolio-token-item .token-info {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }
    
    .token-balance {
        text-align: center;
    }
    
    .token-details h4,
    .token-address-small {
        max-width: 200px;
    }
    
    .profile-tabs {
        flex-direction: column;
    }
    
    .tab-btn {
        text-align: left;
        border-bottom: none;
        border-left: 2px solid transparent;
        padding: 0.75rem 1rem;
    }
    
    .tab-btn.active {
        border-left-color: var(--primary-color);
        border-bottom-color: transparent;
    }
}

/* Loading Indicator for Infinite Scroll */
.loading-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem;
    margin: 1rem 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* New My Liquidity Section Styles */
.my-liquidity-container {
    padding: 1rem;
}

.liquidity-positions-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.liquidity-position-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    position: relative;
}

.liquidity-position-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    border-color: var(--primary-color);
}

.position-header-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--dark-border);
}

.position-pair-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.pair-icons {
    display: flex;
    align-items: center;
}

.pair-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.875rem;
    border: 2px solid var(--dark-card);
    overflow: hidden;
}

.pair-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.pair-icon .token-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.pair-icon:last-child {
    margin-left: -10px;
    background: var(--secondary-color);
}

.pair-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.position-pool-address {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-family: monospace;
}

.copy-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.25rem;
    transition: color 0.2s ease;
    border-radius: 0.25rem;
}

.copy-btn:hover {
    color: var(--primary-color);
    background: rgba(99, 102, 241, 0.1);
}

.position-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.position-stat-item {
    background: rgba(51, 65, 85, 0.3);
    padding: 1rem;
    border-radius: 0.5rem;
    transition: background 0.3s ease;
}

.position-stat-item:hover {
    background: rgba(51, 65, 85, 0.5);
}

.position-stat-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    display: block;
}

.position-stat-value {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
}

.position-management {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    padding: 1.25rem;
}

.management-title {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1rem;
}

.remove-slider-container {
    margin-bottom: 1.5rem;
}

.remove-slider-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.remove-slider-label span:first-child {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.remove-percentage {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.1rem;
}

.position-slider {
    width: 100%;
    height: 8px;
    background: var(--dark-border);
    border-radius: 4px;
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
}

.position-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.4);
    transition: all 0.2s ease;
}

.position-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.6);
}

.position-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.4);
    border: none;
}

.slider-marks {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    padding: 0 0.25rem;
}

.slider-mark {
    color: var(--text-secondary);
    font-size: 0.75rem;
}

.remove-preview {
    background: rgba(51, 65, 85, 0.2);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.preview-title {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
}

.preview-tokens {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.preview-token-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
    background: var(--dark-bg);
    border-radius: 0.375rem;
}

.preview-token-symbol {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.preview-token-amount {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
}

.position-action-buttons {
    display: flex;
    gap: 0.75rem;
}

.position-action-buttons .btn {
    flex: 1;
}

.no-positions-message {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(16, 185, 129, 0.05));
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
}

.no-positions-message i {
    font-size: 4rem;
    color: var(--text-secondary);
    opacity: 0.3;
    margin-bottom: 1rem;
}

.no-positions-message h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.no-positions-message p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Position card animations */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.liquidity-position-card {
    animation: slideInUp 0.4s ease;
}

.liquidity-position-card:nth-child(1) { animation-delay: 0.1s; }
.liquidity-position-card:nth-child(2) { animation-delay: 0.2s; }
.liquidity-position-card:nth-child(3) { animation-delay: 0.3s; }

/* Loading state for positions */
.positions-loading {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
}

.positions-loading::after {
    content: '';
    display: inline-block;
    width: 30px;
    height: 30px;
    border: 3px solid var(--dark-border);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 1rem;
}

/* MinerDAO Link Styles */
.miner-dao-link {
    background: linear-gradient(135deg, #ff7e5f, #feb47b);
    color: white !important;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.miner-dao-link::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;
}

.miner-dao-link:hover::before {
    left: 100%;
}

.miner-dao-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 126, 95, 0.3);
    color: white !important;
    text-decoration: none;
}

.miner-dao-link i {
    font-size: 0.9rem;
}