/* General Styles */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&family=Space+Grotesk:wght@300..700&display=swap');

:root {
    /* Main colors */
    --primary-color: #1E2344; /* AbogadosNow Brand Blue */
    --secondary-color: #00bcd4;
    --accent-color: #e53e3e; /* Red accent */
    --light-bg: #f7fafc;
    --dark-bg: #1a202c;
    
    /* Text colors */
    --text-dark: #2d3748;
    --text-light: #f7fafc;
    --text-muted: #718096;
    
    /* UI colors */
    --border-color: #e2e8f0;
    --shadow-color: rgba(0, 0, 0, 0.1);
    
    /* Font */
    --font-family: 'Space Grotesk', 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', Oxygen, Ubuntu, Cantarell, 'Open Sans', sans-serif;
}

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

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--light-bg);
}

/* Demo Page Styles */
.demo-content {
    max-width: 800px;
    margin: auto;
    padding: 20px;
    text-align: center;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.demo-content h1 {
    color: var(--primary-color);
    margin-bottom: 20px;
}

.demo-content p {
    margin-bottom: 10px;
    font-size: 18px;
}

/* Chat Widget Styles */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: var(--font-family);
}

/* Chat Button */
.chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 8px var(--shadow-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, background-color 0.3s ease;
    z-index: 1001;
}

.chat-button i {
    font-size: 24px;
}

.chat-button:hover {
    background-color: #1e4272; /* Darker blue on hover */
    transform: scale(1.05);
}

.chat-button:focus {
    outline: none;
}

/* Chat Window */
.chat-window {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 350px;
    height: 500px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px var(--shadow-color);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    font-size: 14px;
    line-height: 1.5;
}

.chat-window.hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}

/* Chat Header */
.chat-header {
    background-color: var(--primary-color);
    color: white;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
}

.chat-header-logo {
    display: flex;
    align-items: center;
}

.chat-logo {
    width: 24px;
    height: 24px;
    margin-right: 8px;
}

/* Logo icon styling */
.chat-logo-icon {
    font-size: 22px;
    margin-right: 8px;
    width: 24px;
    text-align: center;
}

.chat-header-actions {
    display: flex;
}

.action-button {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 14px;
    margin-left: 8px;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.action-button:hover {
    opacity: 1;
}

/* Chat Messages */
.chat-messages {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
    background-color: #f8fafc;
}

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

.chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
    background-color: var(--border-color);
    border-radius: 10px;
}

.message {
    margin-bottom: 12px;
    max-width: 80%;
    padding: 10px 14px;
    border-radius: 18px;
    position: relative;
    word-wrap: break-word;
    animation: fadeIn 0.3s ease;
}

.message.user {
    background-color: #e3f2fd;
    color: var(--text-dark);
    align-self: flex-end;
    margin-left: auto;
    border-bottom-right-radius: 4px;
}

.message.bot {
    background-color: var(--primary-color);
    color: white;
    align-self: flex-start;
    margin-right: auto;
    border-bottom-left-radius: 4px;
}

.thinking {
    display: flex;
    margin-bottom: 12px;
    align-self: flex-start;
}

.dot {
    width: 8px;
    height: 8px;
    background-color: var(--text-muted);
    border-radius: 50%;
    margin: 0 2px;
    animation: dot-pulse 1.5s infinite ease-in-out;
}

.dot:nth-child(2) {
    animation-delay: 0.2s;
}

.dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes dot-pulse {
    0%, 60%, 100% {
        transform: scale(1);
        opacity: 0.6;
    }
    30% {
        transform: scale(1.5);
        opacity: 1;
    }
}

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

/* Contact Form */
.contact-form {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: white;
    z-index: 10;
    padding: 20px;
    overflow-y: auto;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.contact-form.hidden {
    display: none;
}

.contact-form h3 {
    color: var(--primary-color);
    margin-bottom: 8px;
    font-size: 18px;
}

.contact-form p {
    color: var(--text-muted);
    margin-bottom: 16px;
    font-size: 14px;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-size: 14px;
    margin-bottom: 4px;
    color: var(--text-dark);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
    font-family: var(--font-family);
}

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

.form-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.primary-button, 
.secondary-button {
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.primary-button {
    background-color: var(--primary-color);
    color: white;
    border: none;
}

.primary-button:hover {
    background-color: #1e4272;
}

.secondary-button {
    background-color: white;
    color: var(--text-dark);
    border: 1px solid var(--border-color);
}

.secondary-button:hover {
    background-color: #f8fafc;
}

/* Language Selector */
.language-selector {
    padding: 8px 16px;
    background-color: #f1f5f9;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    font-size: 14px;
}

.language-selector label {
    margin-right: 8px;
    color: var(--text-muted);
}

.language-selector select {
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    background-color: white;
    color: var(--text-dark);
    font-size: 13px;
}

/* Chat Input */
.chat-input-container {
    padding: 12px 16px;
    background-color: white;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
}

.chat-input {
    flex: 1;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 8px 14px;
    font-family: var(--font-family);
    font-size: 14px;
    resize: none;
    max-height: 100px;
    min-height: 38px;
    transition: border-color 0.3s ease;
}

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

.send-button {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    border: none;
    margin-left: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease, opacity 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.send-button:not(:disabled):hover {
    background-color: #1e4272; /* Darker blue on hover */
    transform: scale(1.05);
}

.send-button i {
    font-size: 16px;
}

/* Action Link */
.action-link {
    color: var(--secondary-color);
    cursor: pointer;
    text-decoration: underline;
    display: inline-block;
    margin-top: 4px;
}

.action-link:hover {
    color: #1e4272;
}

/* Responsive Design */
@media (max-width: 480px) {
    .chat-window {
        width: 100%;
        height: 70vh;
        right: 0;
        left: 0;
        bottom: 0;
        border-radius: 10px 10px 0 0;
    }
    
    .chat-button {
        right: 20px;
    }
} 