/* VisionPeople Newsletter - Generate Page Styles */

.generate-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Chat container */
.chat-container {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #fff;
    min-height: 400px;
    max-height: 600px;
    overflow-y: auto;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

/* Chat messages */
.chat-message {
    margin-bottom: 1.25rem;
}

.chat-message.user {
    text-align: right;
}

.chat-message .bubble {
    display: inline-block;
    max-width: 80%;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    text-align: left;
    font-size: 0.95rem;
    line-height: 1.5;
}

.chat-message.user .bubble {
    background: #580018;
    color: #fff;
}

.chat-message.assistant .bubble {
    background: #f8f9fa;
    color: #1a1a1a;
    border: 1px solid #e9ecef;
}

.chat-message .sender {
    font-size: 0.75rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
}

/* Chat input */
.chat-input {
    display: flex;
    gap: 0.5rem;
    align-items: flex-end;
}

.chat-input textarea.form-control {
    flex: 1;
    resize: vertical;
    min-height: 120px;
    max-height: 300px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.chat-input textarea.form-control:focus {
    border-color: #580018;
    box-shadow: 0 0 0 3px rgba(88, 0, 24, 0.15);
}

/* Buttons */
.btn-cancel {
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0 1.5rem;
    font-weight: 600;
    cursor: pointer;
    height: 48px;
    white-space: nowrap;
}

.btn-cancel:hover {
    background: #bb2d3b;
}

.btn-send {
    background: #580018;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0 1.5rem;
    font-weight: 600;
    cursor: pointer;
    height: 48px;
    white-space: nowrap;
}

.btn-send:hover:not(:disabled) {
    background: #fd2038;
}

.btn-send:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-save {
    background: #198754;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1.5rem;
    font-weight: 600;
    cursor: pointer;
}

.btn-save:hover:not(:disabled) {
    background: #157347;
}

/* Preview panel */
.preview-panel {
    margin-top: 1.5rem;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.75rem 0;
    border-bottom: 2px solid #580018;
}

.preview-header h3 {
    color: #580018;
    margin: 0;
    font-size: 1.25rem;
}

.preview-subject {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
}

.preview-subject label {
    font-weight: 600;
    font-size: 0.8rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
    display: block;
}

.preview-subject .value {
    font-size: 1rem;
    color: #1a1a1a;
}

/* Email preview frame */
.preview-email-frame {
    background: #f0f0f0;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.08);
}

.preview-email-frame table {
    border-collapse: collapse;
}

.preview-email-frame img {
    border: 0;
    outline: none;
    text-decoration: none;
}

.preview-email-frame p {
    margin: 0 0 1em 0;
}

.preview-email-frame ul,
.preview-email-frame ol {
    padding-left: 1.5em;
    margin: 0 0 1em 0;
}

.preview-email-frame li {
    margin-bottom: 0.5em;
}

/* Typing indicator */
.typing-indicator {
    display: inline-flex;
    gap: 4px;
    padding: 0.5rem 0;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6c757d;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-6px); }
}

/* Suggestion chips */
.suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.suggestion-chip {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 20px;
    padding: 0.375rem 1rem;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.suggestion-chip:hover {
    background: #580018;
    color: #fff;
    border-color: #580018;
}
