* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Navigation */
.nav {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 12px 24px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.logo {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-items {
    display: flex;
    gap: 20px;
    align-items: center;
}

.nav-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 20px;
    background: transparent;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    background: rgba(102, 126, 234, 0.1);
}

.nav-btn.active {
    background: #667eea;
    color: white;
}

/* Main Content */
.main-content {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    min-height: 600px;
}

.screen {
    display: none;
}

.screen.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Welcome Screen */
.welcome-screen {
    text-align: center;
    padding: 40px 0;
}

.welcome-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.welcome-subtitle {
    font-size: 20px;
    color: #666;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.role-selector {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin-top: 40px;
}

.role-card {
    background: white;
    border: 3px solid transparent;
    border-radius: 20px;
    padding: 40px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    min-width: 250px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.role-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.role-card.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, #667eea10, #764ba220);
}

.role-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.role-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 10px;
}

.role-desc {
    color: #666;
    line-height: 1.5;
}

/* Onboarding */
.onboarding-header {
    text-align: center;
    margin-bottom: 40px;
}

.progress-bar {
    background: #e0e7ff;
    height: 6px;
    border-radius: 3px;
    margin: 20px 0;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(90deg, #667eea, #764ba2);
    height: 100%;
    border-radius: 3px;
    transition: width 0.3s ease;
}

.form-section {
    background: #f8faff;
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e7ff;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e7ff;
    border-radius: 12px;
    font-size: 16px;
    background: white;
}

.checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.checkbox-item:hover {
    background: rgba(102, 126, 234, 0.05);
}

/* Buyer Cards */
.buyers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
    margin-top: 30px;
}

.buyer-card {
    background: white;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.buyer-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.buyer-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.buyer-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(45deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    font-weight: 600;
}

.buyer-info h3 {
    font-size: 20px;
    margin-bottom: 4px;
}

.buyer-location {
    color: #666;
    font-size: 14px;
}

.buyer-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.stat {
    background: #f8faff;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}

.stat-value {
    font-size: 18px;
    font-weight: 600;
    color: #667eea;
}

.stat-label {
    font-size: 12px;
    color: #666;
    margin-top: 4px;
}

.buyer-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.tag {
    background: linear-gradient(135deg, #667eea20, #764ba220);
    color: #667eea;
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
}

.card-actions {
    display: flex;
    gap: 12px;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    flex: 1;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.btn-secondary {
    background: #f3f4f6;
    color: #666;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Deal Flow */
.deal-header {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 30px;
    text-align: center;
}

.deal-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.step-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    position: relative;
}

.step-card.completed {
    background: linear-gradient(135deg, #10b98120, #059f6920);
}

.step-card.active {
    border: 2px solid #667eea;
}

.step-number {
    position: absolute;
    top: -10px;
    left: 20px;
    width: 30px;
    height: 30px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

.ai-assistant {
    background: linear-gradient(135deg, #ff9a9e, #fecfef);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
}

.ai-message {
    background: white;
    border-radius: 12px;
    padding: 16px;
    margin: 10px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.document-analyzer {
    background: #f0f9ff;
    border: 2px dashed #0ea5e9;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
    margin: 20px 0;
}

.upload-zone {
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-zone:hover {
    background: #e0f2fe;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 20px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.close-modal {
    float: right;
    font-size: 28px;
    cursor: pointer;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .role-selector {
        flex-direction: column;
        align-items: center;
    }

    .buyers-grid {
        grid-template-columns: 1fr;
    }

    .deal-steps {
        grid-template-columns: 1fr;
    }
}