/* Theta Design Styles - AI-First Interface */

:root {
    --theta-primary: #10b981;
    --theta-primary-dark: #059669;
    --theta-bg-dark: #0a1628;
    --theta-bg-light: #ffffff;
    --theta-text-dark: #0f172a;
    --theta-text-light: #cbd5e1;
    --theta-border: #e2e8f0;
    --theta-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Hero Section with AI Chat */
.theta-hero {
    position: relative;
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #0a1628 0%, #152238 50%, #0a1628 100%);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(16, 185, 129, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(16, 185, 129, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: grid-flow 20s linear infinite;
}

@keyframes grid-flow {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 50px 50px;
    }
}

.theta-container {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    width: 100%;
    opacity: 0;
}

/* Badge */
.theta-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 50px;
    padding: 8px 20px;
    font-size: 0.85rem;
    color: var(--theta-primary);
    font-weight: 600;
    margin-bottom: 30px;
}

.badge-dot {
    width: 8px;
    height: 8px;
    background: var(--theta-primary);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--theta-primary);
}

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

/* Chat Container */
.theta-chat-container {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    margin-bottom: 40px;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.theta-chat-header {
    background: linear-gradient(135deg, var(--theta-primary) 0%, var(--theta-primary-dark) 100%);
    color: white;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.chat-avatar {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.theta-chat-header h2 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
}

.theta-chat-header p {
    margin: 5px 0 0;
    font-size: 0.85rem;
    opacity: 0.9;
}

.chat-status {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    animation: pulse 2s ease-in-out infinite;
}

/* Messages Area */
.theta-chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 30px;
    background: #f8fafc;
    scrollbar-width: thin;
    scrollbar-color: var(--theta-primary) #e2e8f0;
}

.theta-chat-messages::-webkit-scrollbar {
    width: 6px;
}

.theta-chat-messages::-webkit-scrollbar-track {
    background: #e2e8f0;
}

.theta-chat-messages::-webkit-scrollbar-thumb {
    background: var(--theta-primary);
    border-radius: 3px;
}

.chat-message {
    margin-bottom: 20px;
    max-width: 80%;
    animation: slideIn 0.5s ease-out;
}

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

.chat-message.user {
    margin-left: auto;
}

.chat-message.assistant {
    margin-right: auto;
}

.message-content {
    padding: 15px 20px;
    border-radius: 16px;
    font-size: 0.95rem;
    line-height: 1.6;
}

.chat-message.user .message-content {
    background: linear-gradient(135deg, var(--theta-primary) 0%, var(--theta-primary-dark) 100%);
    color: white;
    border-bottom-right-radius: 4px;
}

.chat-message.assistant .message-content {
    background: white;
    color: var(--theta-text-dark);
    border: 1px solid #e2e8f0;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.message-content.prose p {
    margin: 0 0 10px;
}

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

.message-content.prose strong {
    color: var(--theta-primary);
    font-weight: 600;
}

.message-content.prose li {
    margin-left: 20px;
    margin-bottom: 5px;
    list-style-position: inside;
}

/* Loading Dots */
.loading-dots {
    display: flex;
    gap: 6px;
    padding: 15px 20px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    background: var(--theta-primary);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.loading-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.loading-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes bounce {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* Chat Input */
.theta-chat-input {
    background: white;
    padding: 20px 30px 30px;
    border-top: 1px solid #e2e8f0;
}

.quick-suggestions {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.quick-suggestions button {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 8px 16px;
    font-size: 0.85rem;
    color: #475569;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.quick-suggestions button:hover {
    background: var(--theta-primary);
    color: white;
    border-color: var(--theta-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.input-group {
    display: flex;
    gap: 10px;
}

.input-group input {
    flex: 1;
    padding: 15px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: var(--theta-primary);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.input-group button {
    padding: 15px 30px;
    background: linear-gradient(135deg, var(--theta-primary) 0%, var(--theta-primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.input-group button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}

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

/* Stats Section */
.theta-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(16, 185, 129, 0.2);
    border-color: var(--theta-primary);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--theta-primary);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .theta-chat-messages {
        height: 300px;
    }

    .chat-message {
        max-width: 90%;
    }

    .quick-suggestions {
        flex-direction: column;
    }

    .quick-suggestions button {
        width: 100%;
    }

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

    .theta-chat-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}
