/* General styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Source Sans Pro', sans-serif;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
    padding: 0;
    margin: 0;
    padding-top: 80px; /* Space for fixed header */
}

/* Header styles */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #000;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    min-height: 60px;
}

.logo-container {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    margin-right: 20px;
}

.logo {
    max-width: 200px;
}

.logo img {
    max-height: 60px;
    max-width: 180px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.statement {
    font-size: 14px;
    color: #fff;
    margin: 0 20px;
    flex: 1 1 auto;
    max-width: none;
    line-height: 1.3;
    font-weight: bold;
    padding-right: 20px;
}

/* Template buttons */
.template-buttons {
    display: flex;
    gap: 10px;
    margin-left: 0;
    flex: 0 0 auto;
    padding-left: 20px;
}

.template-button {
    padding: 6px 12px;
    background-color: #fff;
    color: #000;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
}

.template-button:hover {
    background-color: #f0f0f0;
}

/* Main content container */
.chat-container-wrapper {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    margin: 40px auto;
    max-width: 95%;
    display: none;
}

.title-section {
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.title-content {
    text-align: center;
}

.main-title {
    color: #333;
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    line-height: 1.4;
    margin: 0;
}

.subtitle-text {
    color: #e86732;
    font-size: 18px;
    display: block;
    margin-top: 5px;
    margin-bottom: 0;
}
.disclaimer-box-wide .subtitle-text {
    font-size: 6px;
}

.content-container {
    padding: 20px;
}

#loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.spinner-container {
    text-align: center;
}

.custom-spinner {
    color: #F7682C;
}

.main-content {
    display: none;
}

.action-button {
    position: absolute;
    right: 10px;
    padding: 5px 10px;
    background-color: #66798C;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    transition: background-color 0.2s;
}

.action-button:hover {
    background-color: #556577;
}

.assistant-message {
    background-color: #ffffff;
    margin-right: 20%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.challenge-box {
    background-color: #fff5f1;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-size: 10px;
}

.disclaimer-box {
    font-size: 10px;
}

.disclaimer-box-wide {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 0 32px 24px 32px !important;
    margin: 0 0 32px 0 !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    width: 100%;
    position: relative;
    transition: opacity 0.6s ease, visibility 0.6s ease;
    opacity: 1;
    visibility: visible;
}
.disclaimer-box-wide.fade-out {
    opacity: 0;
    visibility: hidden;
}
.disclaimer-box-wide .btn {
    display: block;
    margin: 32px auto 0 auto;
}
.disclaimer-box-wide h3 {
    font-size: 0.95rem;
    margin-bottom: 8px;
    margin-top: 16px;
}
.disclaimer-box-wide p,
.disclaimer-box-wide ul,
.disclaimer-box-wide li {
    font-size: 10px;
    line-height: 1.5;
    margin-bottom: 6px;
}
.disclaimer-box-wide li {
    font-size: 10px;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .disclaimer-box-wide {
        padding: 16px 8px 12px 8px;
        margin: 16px 0 16px 0;
    }
}

/* Button focus */
.btn:focus, 
.btn.focus,
.btn-primary:focus {
    box-shadow: 0 0 0 0.2rem rgba(102, 121, 140, 0.25) !important;
}

/* Primary color overrides */
.btn-primary {
    background-color: #F7682C !important;
    border-color: #F7682C !important;
}

.btn-primary:hover {
    background-color: #e55a1f !important;
    border-color: #e55a1f !important;
}

.chat-container {
    height: 600px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    overflow-y: auto;
    margin-bottom: 20px;
    background-color: #f8f9fa;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.form-select,
.form-control {
    font-family: 'Source Sans Pro', sans-serif;
    color: #2F353A;
}

/* Focus states */
.form-control:focus,
.form-select:focus {
    border-color: #66798C !important;
    box-shadow: 0 0 0 0.2rem rgba(102, 121, 140, 0.25) !important;
}

h1, .h1, .display-4 {
    font-family: 'Source Sans Pro', sans-serif;
    color: #2F353A !important;
}

.hidden-content {
    display: none;
    background-color: #f0f0f0;
    padding: 10px;
    margin-top: 10px;
    border-radius: 4px;
    white-space: pre-wrap; 
    word-wrap: break-word; 
    line-height: 1.5; 
    border: 1px solid #ddd;
}

.message {
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: 'Source Sans Pro', sans-serif;
    color: #2F353A;
    margin-top: 5px;
    line-height: 1.3;
}

/* Style adjustments for rendered markdown (Compactness) */
.message p { margin-top: 0; margin-bottom: 0; }
.message p:last-child { margin-bottom: 0; }
.message ul, .message ol { padding-left: 20px; margin-top: 0; margin-bottom: 0; }
.message li { margin-bottom: 0; }
.message li p { margin-bottom: 0; }
.message pre { background-color: #e9ecef; padding: 10px; border-radius: 4px; white-space: pre-wrap; word-wrap: break-word; margin-top: 0.5em; margin-bottom: 0.5em; }
.message code { font-size: 0.9em; background-color: #e9ecef; padding: 0.1em 0.1em; border-radius: 3px; }
.message pre code { background-color: transparent; padding: 0; font-size: inherit; }

.message-container {
    position: relative;
    margin: 15px 0;
    padding: 15px;
    border-radius: 8px;
}

.user-message {
    background-color: #e3f2fd;
    margin-left: 20%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.logo-image {
    max-width: 600px;
    height: auto;
    margin-bottom: 2rem;
}

.tool-status {
    font-style: italic;
    color: #66798C;
    font-size: 0.9em;
    margin-top: 5px;
    min-height: 1.2em;
}

.error-message {
    color: #dc3545;
    font-weight: bold;
    margin-top: 5px;
}

/* --- Styles for Tool Buttons and Output --- */
.tool-button-container { 
    padding-bottom: 10px; 
    border-bottom: 1px solid #eee;
    margin-bottom: 10px;
    min-height: 35px;
}
.tool-output-container { margin-top: 10px; }

/* Responsive styles */
@media screen and (max-width: 768px) {
    .chat-container-wrapper {
        padding: 10px;
        margin: 10px auto;
    }
    
    header {
        padding: 5px 10px;
    }
    
    .statement {
        font-size: 12px;
        margin: 0 10px;
    }
    
    .main-title {
        font-size: 20px;
    }
    
    .subtitle-text {
        font-size: 16px;
    }
}

/* Report button styles */
.report-button {
    margin-top: 10px;
    font-size: 12px;
    padding: 6px 12px;
    transition: all 0.2s ease;
    border-width: 1px;
    border-color: #e86732 !important;
    color: #e86732 !important;
    background-color: transparent !important;
}

.report-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    background-color: #e86732 !important;
    border-color: #e86732 !important;
    color: white !important;
}

.report-button:focus,
.report-button:active {
    background-color: #d55a2a !important;
    border-color: #d55a2a !important;
    color: white !important;
    box-shadow: 0 0 0 0.2rem rgba(232, 103, 50, 0.25) !important;
}

.report-button i {
    margin-right: 5px;
} 