/* CSS Variables for Theme Colors */
:root {
    --primary-color: #1e40af;
    --secondary-color: #1d4ed8;
    --accent-color: #3b82f6;
    --background-color: #f8fafc;
    --text-color: #1e293b;
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --aptos-green: #00d4aa;
    --aptos-dark: #0a1628;
    --gradient-primary: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #334155 100%);
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Sticky Navigation */
.sticky-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    z-index: 1000;
    transition: all 0.3s ease;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--primary-color);
}

.nav-logo i {
    font-size: 1.5rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--gray-700);
    font-weight: 500;
    transition: color 0.2s ease;
    position: relative;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a.nav-cta {
    background: var(--gradient-primary);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: transform 0.2s ease;
}

.nav-links a.nav-cta:hover {
    transform: translateY(-1px);
    color: var(--white);
}

/* Hero Banner */
.hero-banner {
    background: var(--gradient-hero);
    color: var(--white);
    padding: 120px 0 80px;
    margin-top: 70px;
    position: relative;
    overflow: hidden;
}

.hero-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23ffffff" stroke-width="0.5" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-text .highlight {
    background: linear-gradient(135deg, var(--aptos-green), #60a5fa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.25rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: var(--aptos-green);
}

.stat-label {
    font-size: 0.875rem;
    opacity: 0.8;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.btn-primary, .btn-secondary {
    padding: 1rem 2rem;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

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

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.trading-card {
    background: var(--white);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: var(--shadow-2xl);
    color: var(--gray-900);
    min-width: 300px;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    color: var(--gray-600);
    font-weight: 500;
}

.price-display {
    margin-bottom: 1rem;
}

.price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gray-900);
}

.change {
    margin-left: 1rem;
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.875rem;
}

.change.positive {
    background: #dcfce7;
    color: #166534;
}

.aptos-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--aptos-green);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
}

/* Team Section */
.team-section {
    padding: 80px 0;
    background: var(--white);
}

.team-section h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--gray-900);
}

.section-description {
    text-align: center;
    font-size: 1.125rem;
    color: var(--gray-600);
    max-width: 600px;
    margin: 0 auto 3rem;
}

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

.team-member {
    text-align: center;
    padding: 2rem;
    background: var(--gray-50);
    border-radius: 16px;
    transition: transform 0.2s ease;
}

.team-member:hover {
    transform: translateY(-4px);
}

.member-avatar {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: var(--white);
    font-size: 2rem;
}

.team-member h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--gray-900);
}

.member-role {
    color: var(--primary-color);
    font-weight: 500;
    margin-bottom: 1rem;
}

.member-bio {
    color: var(--gray-600);
    line-height: 1.6;
}

/* Success Cases */
.success-cases {
    padding: 80px 0;
    background: var(--gray-50);
}

.success-cases h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: var(--gray-900);
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.case-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
    transition: all 0.2s ease;
}

.case-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.case-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.case-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--gray-900);
}

.case-result {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--aptos-green);
    margin-bottom: 1rem;
}

.case-description {
    color: var(--gray-600);
    line-height: 1.6;
}

/* Chat Section */
.chat-section {
    padding: 80px 0;
    background: var(--white);
}

.chat-intro {
    text-align: center;
    margin-bottom: 3rem;
}

.chat-intro h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--gray-900);
}

.chat-intro p {
    font-size: 1.125rem;
    color: var(--gray-600);
    max-width: 600px;
    margin: 0 auto;
}

/* Chat Container */
.chat-container {
    flex: 1;
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    min-height: 600px;
}

.chat-header {
    padding: 1rem 1.5rem;
    background: var(--gradient-primary);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.aptos-verification {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.2);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
}

.aptos-verification i {
    color: var(--aptos-green);
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Chat Messages */
.chat-messages {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: var(--gray-50);
    min-height: 400px;
}

.message {
    display: flex;
    gap: 0.75rem;
    max-width: 80%;
    animation: fadeInUp 0.3s ease-out;
}

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

.user-message {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.bot-message {
    align-self: flex-start;
}

.message-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    flex-shrink: 0;
}

.bot-message .message-avatar {
    background: var(--primary-color);
    color: var(--white);
}

.user-message .message-avatar {
    background: var(--gray-300);
    color: var(--gray-700);
}

.message-content {
    background: var(--white);
    padding: 0.875rem 1.125rem;
    border-radius: 18px;
    box-shadow: var(--shadow-sm);
    position: relative;
}

.user-message .message-content {
    background: var(--gradient-primary);
    color: var(--white);
}

.message-content p {
    margin: 0;
    word-wrap: break-word;
    line-height: 1.5;
}

.message-content ul {
    margin: 0.5rem 0;
    padding-left: 1rem;
}

.message-content li {
    margin: 0.25rem 0;
    line-height: 1.5;
}

.message-time {
    font-size: 0.75rem;
    opacity: 0.7;
    margin-top: 0.25rem;
    display: block;
}

/* Chat Input */
.chat-input-container {
    padding: 1.5rem;
    background: var(--white);
    border-top: 1px solid var(--gray-200);
}

.chat-input {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
}

.chat-input input {
    flex: 1;
    padding: 0.875rem 1rem;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    resize: none;
    transition: all 0.2s ease;
    background: var(--white);
}

.chat-input input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.send-button {
    padding: 0.875rem;
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 1.125rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
}

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

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

.input-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--gray-500);
}

.character-count {
    font-size: 0.75rem;
}

.powered-by {
    font-size: 0.75rem;
    font-weight: 500;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-overlay.show {
    display: flex;
}

.loading-spinner {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow-xl);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--gray-200);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

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

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1001;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-xl);
    max-width: 400px;
    width: 90%;
    overflow: hidden;
}

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

.modal-header h3 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--error);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray-500);
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-body {
    padding: 1.5rem;
}

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

.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

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

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

/* Footer */
.footer {
    background: var(--gray-900);
    color: var(--white);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-brand {
    max-width: 300px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--white);
}

.footer-logo i {
    color: var(--aptos-green);
    font-size: 1.5rem;
}

.footer-brand p {
    color: var(--gray-400);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.aptos-footer-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--aptos-green);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    width: fit-content;
}

.footer-column h4 {
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--white);
}

.footer-column a {
    display: block;
    color: var(--gray-400);
    text-decoration: none;
    margin-bottom: 0.5rem;
    transition: color 0.2s ease;
}

.footer-column a:hover {
    color: var(--aptos-green);
}

.footer-bottom {
    border-top: 1px solid var(--gray-700);
    padding-top: 1rem;
    text-align: center;
    color: var(--gray-400);
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .hero-text h1 {
        font-size: 2.5rem;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .team-grid {
        grid-template-columns: 1fr;
    }
    
    .cases-grid {
        grid-template-columns: 1fr;
    }
    
    .chat-container {
        min-height: 500px;
    }
    
    .message {
        max-width: 90%;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .aptos-footer-badge {
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 2rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .chat-messages {
        padding: 1rem;
    }
    
    .chat-input-container {
        padding: 1rem;
    }
    
    .input-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    
    .trading-card {
        min-width: auto;
        padding: 1.5rem;
    }
}