:root {
    --primary-color: #79b061;
    --primary-hover: #6a9d54;
    --secondary-color: #79b061;
    --danger-color: #EF4444;
    --text-primary: #000000;
    --text-secondary: #666666;
    --bg-primary: #FFFFFF;
    --bg-secondary: #F9FAFB;
    --bg-tertiary: #F3F4F6;
    --border-color: #E5E7EB;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #000000 0%, #2d2d2d 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Welcome Screen */
.welcome-screen {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 2rem;
}

.welcome-content {
    max-width: 800px;
    background: var(--bg-primary);
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    text-align: center;
    animation: fadeIn 0.5s ease;
}

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

.welcome-content h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.welcome-content .author {
    font-size: 1.125rem;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.tagline {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.offer-types {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.offer-type {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
}

.offer-type:hover {
    border-color: var(--primary-color);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.offer-type i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.offer-type h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.offer-type p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.start-prompt {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 2rem 0 1.5rem;
}

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

/* Buttons */
.btn {
    padding: 0.875rem 2rem;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

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

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

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

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

/* Chat Interface */
.chat-interface {
    display: flex;
    flex-direction: column;
    height: 100vh;
    max-width: 1200px;
    margin: 0 auto;
    background: var(--bg-primary);
}

.chat-header {
    background: white;
    padding: 1.25rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
}

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

.header-left i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.header-left h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.header-right {
    display: flex;
    gap: 0.5rem;
}

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

.icon-btn:hover {
    background: var(--bg-tertiary);
    color: var(--primary-color);
}

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

/* Chat Messages */
.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 2rem;
    background: var(--bg-secondary);
}

.message {
    margin-bottom: 1.5rem;
    animation: slideIn 0.3s ease;
}

.message-ai {
    display: flex;
    gap: 1rem;
}

.message-user {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

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

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

.message-user .message-avatar {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.message-content {
    max-width: 70%;
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    line-height: 1.6;
}

.message-ai .message-content {
    background: white;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

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

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

.voice-indicator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    background: var(--primary-color);
    color: white;
    border-radius: var(--radius-sm);
    animation: slideIn 0.3s ease;
}

.pulse {
    width: 12px;
    height: 12px;
    background: white;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

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

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

.chat-input textarea {
    flex: 1;
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 1rem;
    resize: none;
    max-height: 150px;
    transition: border-color 0.3s ease;
}

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

.send-btn, .mic-btn {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.125rem;
}

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

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

.send-btn:disabled {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    cursor: not-allowed;
    transform: none;
}

.mic-btn {
    background: var(--bg-secondary);
    color: var(--text-secondary);
}

.mic-btn:hover {
    background: var(--bg-tertiary);
    color: var(--primary-color);
}

.mic-btn.recording {
    background: var(--danger-color);
    color: white;
    animation: pulse 1.5s infinite;
}

/* Offer Display */
.offer-display {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
    min-height: 100vh;
}

.offer-header {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-md);
}

.btn-back {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    transition: color 0.3s ease;
}

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

.offer-header h1 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.offer-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.offer-content {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    line-height: 1.8;
}

.offer-content h2 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.offer-content h2:first-child {
    margin-top: 0;
}

.offer-content h3 {
    font-size: 1.25rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.offer-content ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.offer-content li {
    margin-bottom: 0.5rem;
}

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

.offer-content p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

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

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.loading-overlay p {
    color: white;
    margin-top: 1rem;
    font-size: 1.125rem;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--text-primary);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    z-index: 1001;
    animation: slideInUp 0.3s ease;
}

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

.toast.error {
    background: var(--danger-color);
}

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

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

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

/* Responsive Design */
@media (max-width: 768px) {
    .welcome-content {
        padding: 2rem;
    }

    .welcome-content h1 {
        font-size: 2rem;
    }

    .offer-types {
        grid-template-columns: 1fr;
    }

    .chat-messages {
        padding: 1rem;
    }

    .message-content {
        max-width: 85%;
    }

    .chat-input-container {
        padding: 1rem;
    }

    .offer-display {
        padding: 1rem;
    }

    .offer-content {
        padding: 1.5rem;
    }

    .offer-actions {
        flex-direction: column;
    }

    .offer-actions .btn {
        width: 100%;
        justify-content: center;
    }
}
