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

:root {
    --primary: #E8D5B7;
    --primary-hover: #D4C4A8;
    --bg-dark: #0a0a0f;
    --bg-card: #16161f;
    --bg-card-hover: #1f1f2e;
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --border: #27272a;
    --success: #10b981;

    /* Common values */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.2);
    --shadow-button: 0 4px 12px rgba(71, 85, 105, 0.2);
    --shadow-button-hover: 0 6px 16px rgba(71, 85, 105, 0.25);
    --transition: all 0.2s ease;
    --transition-fast: all 0.15s ease;
    --gradient-button: linear-gradient(135deg, #f8fafc 0%, #cbd5e1 100%);
}

/* Utility Classes - Common Patterns */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.card-hover:hover {
    background: var(--bg-card-hover);
    transform: translateY(-2px);
    transition: var(--transition);
}

/* Flexbox utilities */
.flex {
    display: flex;
}

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

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.flex-column {
    display: flex;
    flex-direction: column;
}

.flex-gap-sm { gap: 8px; }
.flex-gap-md { gap: 12px; }
.flex-gap-lg { gap: 16px; }
.flex-gap-xl { gap: 24px; }

/* Text utilities */
.text-secondary {
    color: var(--text-secondary);
}

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

/* Transition utilities */
.transition {
    transition: var(--transition);
}

.transition-fast {
    transition: var(--transition-fast);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Helvetica Neue', sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Navbar */
.navbar {
    background: rgba(22, 22, 31, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex-shrink: 1;
}

.brand-name {
    font-size: 20px;
    font-weight: 600;
    background: linear-gradient(135deg, #fff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    white-space: nowrap;
}

.brand-y {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

/* Connect Button */
.btn-connect {
    background: var(--gradient-button);
    color: #0f172a;
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-button);
    position: relative;
    overflow: hidden;
}

.btn-connect:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-button-hover);
}

/* Wallet Connected */
.wallet-connected {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.wallet-info {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    flex-shrink: 0;
}

.wallet-info,
.wallet-stats {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.wallet-balance {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
}

.wallet-lock {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    padding-left: 12px;
    border-left: 1px solid var(--border);
    white-space: nowrap;
}

.wallet-permalock {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    color: #1e293b;
    border-radius: var(--radius-md);
    font-size: 12px;
    font-weight: 600;
    border: 1px solid rgba(148, 163, 184, 0.5);
    white-space: nowrap;
    flex-shrink: 0;
}

.wallet-permalock svg {
    width: 14px;
    height: 14px;
}

.wallet-address-btn {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'Monaco', 'Courier New', monospace;
    white-space: nowrap;
    flex-shrink: 0;
}

.wallet-address-btn:hover {
    background: var(--bg-card-hover);
    border-color: var(--primary);
}

/* Navbar responsive */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 12px;
    }

    .brand-name {
        font-size: 18px;
    }
}

@media (max-width: 390px) {
    .nav-container {
        padding: 0 8px;
        gap: 8px;
    }

    .brand-name {
        font-size: 16px;
    }

    .nav-actions {
        gap: 8px;
    }

    .wallet-info {
        padding: 6px 8px;
        gap: 8px;
    }

    .wallet-stats {
        gap: 8px;
    }

    .wallet-balance,
    .wallet-lock {
        font-size: 12px;
    }

    .wallet-address-btn {
        padding: 6px 10px;
        font-size: 12px;
    }
}

/* Main Content */
.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Hero Section */
.hero-section {
    padding: 120px 0;
    text-align: center;
}

.hero-container {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.hero-logo {
    position: absolute;
    left: -150px;
    top: 50%;
    transform: translateY(-50%);
    width: 300px;
    height: auto;
    opacity: 1;
    z-index: -1;
    pointer-events: none;
}

.hero-title {
    font-size: 56px;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #fff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    z-index: 1;
}

.hero-ve {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* Hero responsive */
@media (max-width: 1024px) {
    .hero-logo {
        left: -100px;
        width: 250px;
    }
}

@media (max-width: 768px) {
    .hero-logo {
        left: 50%;
        transform: translate(-50%, -50%);
        width: 350px;
        opacity: 0.08;
    }

    .hero-title {
        font-size: 40px;
    }
}

@media (max-width: 390px) {
    .hero-section {
        padding: 80px 0;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-subtitle {
        font-size: 14px;
    }

    .hero-logo {
        width: 280px;
    }
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 420px;
    padding: 32px 24px;
    animation: slideIn 0.2s ease;
    z-index: 10001;
}

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

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

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

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

.modal-body {
    padding: 20px 24px 24px;
}

/* Wallet Option */
.wallet-option {
    width: 100%;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
}

.wallet-option:hover {
    border-color: var(--primary);
}

.wallet-option-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.wallet-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.wallet-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    font-size: 14px;
    font-weight: 500;
    z-index: 3000;
    display: none;
    animation: toastIn 0.3s ease;
}

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

.toast.show {
    display: block;
}

.toast.success {
    border-color: var(--success);
}

/* Seller Section */
.seller-section {
    padding: 40px 20px;
    max-width: 900px;
    margin: 0 auto;
}

.section-container {
    width: 100%;
}

.section-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
}

/* Action Card */
.action-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0;
    margin-bottom: 24px;
}

.card-header {
    padding: 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 16px;
}

.step-badge {
    background: var(--gradient-button);
    color: #0f172a;
    padding: 6px 14px;
    border-radius: var(--radius-xl);
    font-size: 13px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(71, 85, 105, 0.2);
}

.card-header h3 {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
}

.card-body {
    padding: 24px;
}

.card-description {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
}

/* Approval Status */
.approval-status {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 20px;
}

.status-loading {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
}

.status-approved {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--success);
}

.status-not-approved {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
}

/* Button Styles */
.btn-primary {
    background: var(--gradient-button);
    color: #0f172a;
    border: none;
    padding: 14px 28px;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: var(--shadow-button);
    position: relative;
    overflow: hidden;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: var(--shadow-button-hover);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-large {
    width: 100%;
    justify-content: center;
    padding: 16px 28px;
    font-size: 17px;
}

.btn-loading {
    cursor: not-allowed;
    opacity: 0.9;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Info Panel */
.info-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 20px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.info-item:last-child {
    border-bottom: none;
}

.info-label {
    color: var(--text-secondary);
    font-size: 14px;
}

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

.info-value a {
    color: var(--primary);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.info-value a:hover {
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 16px;
    }

    .hero-title {
        font-size: 36px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .info-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}

/* Form Styles */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.form-input {
    width: 100%;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 60px 14px 16px;
    color: var(--text-primary);
    font-size: 16px;
    transition: border-color 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
}

.form-input::placeholder {
    color: var(--text-secondary);
}

.input-suffix {
    position: absolute;
    right: 16px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    pointer-events: none;
}

.form-select {
    width: 100%;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    padding-right: 48px;
    color: var(--text-primary);
    font-size: 16px;
    cursor: pointer;
    transition: border-color 0.2s ease;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%23a1a1aa' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.form-select:focus {
    outline: none;
    border-color: var(--primary);
}

.form-hint {
    display: block;
    color: var(--text-secondary);
    font-size: 12px;
    margin-top: 6px;
}

/* Listing Preview */
.listing-preview {
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 20px;
}

.preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.preview-item:not(:last-child) {
    border-bottom: 1px solid var(--border);
}

.preview-label {
    color: var(--text-secondary);
    font-size: 14px;
}

.preview-value {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 14px;
}

/* Dashboard & Marketplace */
.dashboard-section,
.marketplace-section {
    padding: 20px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Vertical listing card - compact and scannable layout */
.listing-card-vertical {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.listing-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 16px;
    display: flex;
    gap: 16px;
    align-items: center;
}

.listing-content {
    flex: 1;
}

.listing-buy-section {
    display: flex;
    align-items: center;
    min-width: 250px;
}

/* Vertical card header - compact */
.listing-header-vertical {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
}

.listing-title-large {
    font-size: 15px;
    font-weight: 600;
    margin: 0;
}

/* Primary info section - main pricing data, compact */
.listing-primary-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 10px 12px;
    background: rgba(232, 213, 183, 0.03);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(232, 213, 183, 0.1);
}

.primary-info-item {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.primary-label {
    color: var(--text-secondary);
    font-size: 10px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.primary-value {
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 700;
}

.primary-highlight {
    color: var(--primary);
}

/* Secondary info section - metadata, compact */
.listing-secondary-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.secondary-info-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.secondary-label {
    color: var(--text-secondary);
    font-size: 9px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.secondary-value {
    color: var(--text-primary);
    font-size: 12px;
    font-weight: 500;
}

/* Actions for vertical cards - compact */
.listing-actions-vertical {
    display: flex;
    gap: 8px;
    padding-top: 4px;
}

.btn-cancel-compact {
    background: rgba(220, 53, 69, 0.1);
    color: rgb(220, 53, 69);
    border: 1px solid rgba(220, 53, 69, 0.3);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    flex: 1;
}

.btn-cancel-compact:hover {
    background: rgba(220, 53, 69, 0.15);
}

.btn-view-compact {
    background: var(--bg-dark);
    color: var(--text-primary);
    border: 1px solid var(--border);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

.btn-view-compact:hover {
    border-color: var(--primary);
}

/* Large buy button for marketplace - compact */
.btn-buy-large {
    background: var(--gradient-button);
    color: #0f172a;
    border: none;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-button);
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.btn-buy-large:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: var(--shadow-button-hover);
}

.btn-buy-large:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
    position: relative;
}

/* Tooltip for disabled buy button */
.btn-buy-large:disabled[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--warning);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    font-size: 13px;
    line-height: 1.5;
    white-space: normal;
    max-width: 300px;
    width: max-content;
    z-index: 1000;
    box-shadow: var(--shadow-card);
    pointer-events: none;
}

.btn-buy-large:disabled[title]:hover::before {
    content: '';
    position: absolute;
    bottom: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--warning);
    z-index: 1001;
    pointer-events: none;
}

@media (max-width: 768px) {
    .listing-primary-info,
    .listing-secondary-info {
        grid-template-columns: 1fr;
    }

    .listing-actions-vertical {
        flex-direction: column;
    }
}

.listing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

/* For marketplace listings without header */
.listing-content > .listing-details {
    margin-bottom: 0;
}

.listing-title {
    font-size: 16px;
    font-weight: 600;
}

.listing-status {
    padding: 4px 10px;
    border-radius: var(--radius-xl);
    font-size: 11px;
    font-weight: 600;
}

.listing-status.active {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    color: #1e293b;
    border: 1px solid rgba(148, 163, 184, 0.5);
}

.listing-status.sold {
    background: rgba(148, 163, 184, 0.1);
    color: var(--text-secondary);
}

.listing-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 12px;
}

@media (max-width: 768px) {
    .listing-card {
        flex-direction: column;
        align-items: stretch;
    }

    .listing-buy-section {
        min-width: auto;
        width: 100%;
    }

    .listing-details {
        grid-template-columns: repeat(2, 1fr);
    }
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-label {
    color: var(--text-secondary);
    font-size: 12px;
}

.detail-value {
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 600;
}

.listing-actions {
    display: flex;
    gap: 12px;
}

.btn-cancel {
    background: var(--error-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.btn-cancel:hover {
    opacity: 0.9;
}

.btn-buy {
    background: var(--gradient-button);
    color: #0f172a;
    border: none;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-button);
    width: 100%;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn-buy:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-button-hover);
}

.empty-state {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-secondary);
}

.empty-state svg {
    margin-bottom: 16px;
    opacity: 0.5;
}

/* Tabs Navigation */
.tabs-section {
    padding: 24px 0;
    border-bottom: 1px solid var(--border);
}

.tabs-nav {
    display: flex;
    gap: 12px;
    max-width: 1400px;
    margin: 0 auto;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
}

.tab-btn svg {
    width: 20px;
    height: 20px;
}

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

.tab-btn.active {
    background: var(--gradient-button);
    border-color: transparent;
    color: #0f172a;
    box-shadow: var(--shadow-button);
}

.tab-btn.active svg {
    fill: currentColor;
}

/* Marketplace controls */
.marketplace-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    gap: 20px;
}

/* Scan depth selector and sort selector - minimal style */
#scanDepthSelect,
#sortSelect,
#tradeHistoryScanDepth,
#tradeHistorySort {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 6px 12px;
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    outline: none;
}

#scanDepthSelect:hover,
#sortSelect:hover,
#tradeHistoryScanDepth:hover,
#tradeHistorySort:hover {
    border-color: #cbd5e1;
}

#scanDepthSelect:focus,
#sortSelect:focus,
#tradeHistoryScanDepth:focus,
#tradeHistorySort:focus {
    border-color: #94a3b8;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.2);
}

@media (max-width: 768px) {
    .marketplace-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .marketplace-controls > div:last-child {
        width: 100%;
        flex-wrap: wrap;
        gap: 12px;
    }

    .marketplace-controls > div:last-child > div {
        flex: 1;
        min-width: 140px;
    }

    #scanDepthSelect,
    #sortSelect,
    #tradeHistoryScanDepth,
    #tradeHistorySort {
        flex: 1;
        min-width: 100px;
    }
}

@media (max-width: 390px) {
    .section-title {
        font-size: 24px;
    }

    .tabs-nav {
        gap: 8px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tab-btn {
        padding: 10px 16px;
        font-size: 13px;
        white-space: nowrap;
    }

    .listing-card {
        padding: 12px;
    }

    .marketplace-controls > div:last-child > div {
        min-width: 100%;
    }

    .btn-buy {
        padding: 10px 16px;
        font-size: 13px;
    }

    .btn-primary {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* Footer */
.footer {
    border-top: 1px solid var(--border);
    padding: 24px 0;
    margin-top: 60px;
}

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

.footer-text {
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
}

.footer-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: opacity 0.2s ease;
}

.footer-link:hover {
    opacity: 0.8;
}

@media (max-width: 390px) {
    .footer {
        padding: 20px 0;
        margin-top: 40px;
    }

    .footer-container {
        padding: 0 12px;
    }

    .footer-text {
        font-size: 11px;
        line-height: 1.5;
    }
}

/* Pricing mode radio buttons */
input[type='radio']:checked + div {
    color: var(--primary) \!important;
}

label:has(input[type='radio']:checked) {
    border-color: var(--primary) \!important;
    background: rgba(139, 92, 246, 0.1) \!important;
}

/* Spinner animation */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(232, 213, 183, 0.2);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 0.8s linear infinite;
}

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

/* Button loading state - handled by ::after pseudo-element above */

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease-out;
}

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

.modal-icon {
    font-size: 48px;
    text-align: center;
    margin-bottom: 16px;
}

#successModal .modal-icon {
    color: var(--success);
    font-size: 64px;
    font-weight: bold;
}

.modal-title {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 12px;
}

.modal-message {
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.6;
    margin-bottom: 24px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.btn-secondary {
    background: var(--card-bg);
    color: var(--text-primary);
    border: 2px solid var(--border);
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    overflow: hidden;
}

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