html, body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    background: transparent;
}

.chatbot-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    padding-top: 100px;
    min-height: calc(100vh - 100px);
    background: url('/images/vector-bg.png') no-repeat center center;
    background-size: cover;
    font-family: 'Inter', sans-serif;
    width: 100vw;
}

.chatbot-container::before {
    content: "";
    position: absolute;
    top: 0px;
    left: 0; right: 0; bottom: 0;
    background: rgba(234, 234, 234, 0.65);
    z-index: 0;
    pointer-events: none;
}

.chatbot-container > * {
    position: relative;
    z-index: 1;
}

.chat-interface {
    width: 100%;
    max-width: 800px;
    min-height: 800px;
    background: transparent;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 0.5px solid rgb(194, 86, 9);
    font-family: 'Inter', sans-serif;
    font-size: 1em;
    margin-left: 2%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.chat-messages {
    flex-grow: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: transparent;
    width: 100%;
    max-width: 800px;
    font-family: 'Inter', sans-serif;
    font-size: 1em;
    scroll-behavior: smooth;
}

.message {
    max-width: 100%;
    width: fit-content;
    padding: 1rem 1.25rem;
    border-radius: 12px;
    margin-bottom: 0.5rem;
    color: black;
    font-weight: 400;
    font-size: 1em;
    border: 1px solid black;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    animation: messageAppear 0.3s ease-out;
}

.user-message {
    background: transparent;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.user-message:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08);
}

.bot-message {
    background: transparent;
    align-self: flex-start;
    color: black;
    font-weight: 400;
    width: 100%;
    box-sizing: border-box;
    border-bottom-left-radius: 4px;
}

.bot-message:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08);
}

.message.bot-message:has(.artworks-container) {
    max-width: 100%;
    width: 100%;
}

 .chat-input-container{
    width: 100%;
    max-width: 800px;
    padding: 1rem;
    background: transparent;
    display: flex;
    gap: 0.5rem;
    align-items: center;
    border-top: 1px solid black;
    margin: 0 auto;
    font-family: 'Inter', sans-serif;
    font-size: 1em;
}

#userInput {
    height: 40px;
    line-height: 40px;
    padding: 0 1rem;
    font-size: 1em;
    border-radius: 8px;
    flex-grow: 1;
    border: 1px solid black;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    background: transparent;
    color: black;
    box-sizing: border-box;
}

#userInput:focus {
    outline: none;
    border-color: rgba(0, 0, 0, 0.2); /* Slightly darker on focus */
}

#userInput::placeholder {
    color: #000000;
    font-size: 1em;
    font-family: 'Inter', sans-serif;
}

#sendMessage {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    background: transparent;
    border: 1px solid black;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    font-size: 1em;
}

#sendMessage:hover {
    background: rgba(248, 248, 248, 0.5);
    border-color: rgba(0, 0, 0, 0.2);
}

#sendMessage i {
    font-size: 1em;
    color: black;
    margin: 0;
}

/* Scrollbar Styles */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: rgba(240, 240, 240, 0.5);
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2); /* Thin black line style */
    border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}

/* Chatbot-specific menu adjustments */
.chatbot-container .menu-toggle {
    position: fixed;
    top: 8px;
    left: 8px;
    z-index: 1000 !important;
    background: #4CAF50;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    visibility: visible !important;
    opacity: 1 !important;
}

.chatbot-container .menu-toggle:hover {
    background: #45a049;
    transform: scale(1.05);
}

.chatbot-container .menu-icon {
    position: relative;
    width: 14px;
    height: 2px;
    background: white;
    transition: all 0.3s ease;
}

.chatbot-container .menu-icon::before,
.chatbot-container .menu-icon::after {
    content: '';
    position: absolute;
    width: 14px;
    height: 2px;
    background: white;
    transition: all 0.3s ease;
}

.chatbot-container .menu-icon::before {
    top: -8px;
}

.chatbot-container .menu-icon::after {
    bottom: -8px;
}

.chatbot-container .sidebar {
    background: #ffffff;
    border-right: 1px solid rgba(0, 0, 0, 0.2); /* Thin black line */
    width: 70vw !important;
    min-width: unset !important;
    max-width: 300px !important;
    padding: 10px 8px !important;
    font-size: 0.9em;
    z-index: 2000;
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    box-shadow: 2px 0 10px rgba(0,0,0,0.08);
}

.chatbot-container .sidebar.active {
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.05);
}

/* Adjust menu items for chatbot page */
.chatbot-container .menu-items a {
    color: black;
    font-size: 1.5em !important;
    padding: 8px 0 !important;
}

.chatbot-container .menu-items a.active,
.chatbot-container .menu-items a:hover {
    color: #000000;
}

.chatbot-container .social-links-sidebar a {
    color: #555555;
    font-size: 1.2em !important;
    margin: 0 6px !important;
}

.chatbot-container .social-links-sidebar a:hover {
    color: #000000;
}

.chatbot-container .close-menu {
    color: #333333;
    font-size: 1.2em !important;
    top: 8px;
    right: 8px;
}

/* Adjust menu overlay for chatbot page */
.chatbot-container .menu-overlay {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
}

/* Artwork Display Styles */
.artworks-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
    width: 100%;
}

.artwork-item {
    position: relative;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.artwork-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.artwork-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: opacity 0.3s ease;
}

.artwork-item img.loading {
    opacity: 0.5;
}

.artwork-item img.loaded {
    opacity: 1;
}

.artwork-item img.error {
    opacity: 0.7;
    filter: grayscale(1);
}

.artwork-caption {
    padding: 1rem;
    font-size: 0.9em;
    color: #333;
    background: #ffffff;
}

.source-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 500;
}

/* Artwork Links */
.artwork-links-container {
    margin-top: 15px;
    background-color: #f5f5f5;
    border-radius: 8px;
    padding: 10px;
    border-left: 3px solid #3498db;
}

.artwork-links-header {
    font-weight: bold;
    margin-bottom: 8px;
    color: #333;
}

.artwork-links-list {
    list-style-type: none;
    padding-left: 0;
    margin: 0;
}

.artwork-link-item {
    margin-bottom: 8px;
    padding: 5px 0;
    border-bottom: 1px solid #eee;
}

.artwork-link-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.artwork-link-item a {
    color: #3498db;
    text-decoration: none;
    display: block;
    padding: 5px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.artwork-link-item a:hover {
    background-color: #e5e5e5;
    border-radius: 4px;
}

.footer-light, .footer-light .footer-section, .footer-light .footer-bottom, .footer-light .social-section {
    color: #111 !important;
    background: none !important;
}

.footer-light .footer-section a,
.footer-light .footer-bottom p,
.footer-light .social-icons a,
.footer-light h3 {
    color: #111 !important;
}

.footer-light {
    border-top: 2px solid #028e27 !important;
}

.footer-light .social-section {
    border-top: none !important;
    border-bottom: none !important;
}

.social-section {
    color: #111 !important;
    background: none !important;
}

.social-section .social-icons a,
.social-section h3 {
    color: #111 !important;
}

/* Enhance message content readability */
.message-content {
    white-space: normal;
    line-height: 1.6;
}

.message-content p {
    margin: 0 0 1em 0;
    line-height: 1.6;
}

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

/* Add subtle animation for new messages */
@keyframes messageAppear {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 600px) {
  .chatbot-container .menu-toggle {
    width: 28px;
    height: 28px;
    top: 8px;
    left: 8px;
  }
  .chatbot-container .menu-icon,
  .chatbot-container .menu-icon::before,
  .chatbot-container .menu-icon::after {
    width: 14px;
    height: 2px;
  }
  .chatbot-container .sidebar {
    width: 70vw !important;
    min-width: unset !important;
    max-width: 300px !important;
    padding: 10px 8px !important;
    font-size: 0.9em;
    z-index: 2000;
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    box-shadow: 2px 0 10px rgba(0,0,0,0.08);
  }
  .chatbot-container .menu-items a {
    font-size: 1.5em !important;
    padding: 8px 0 !important;
  }
  .chatbot-container .social-links-sidebar a {
    font-size: 1.2em !important;
    margin: 0 6px !important;
  }
  .chatbot-container .close-menu {
    font-size: 1.2em !important;
    top: 8px;
    right: 8px;
  }
}

/* Print Styles Update */
@media print {
    .chat-actions {
        display: none !important;
    }
    /* Hide elements not needed for printing */
    .chat-input-container,
    .menu-toggle,
    .sidebar,
    .menu-overlay,
    .footer-simple,
    #sendMessage {
        display: none !important;
    }

    /* Adjust container for printing */
    .chatbot-container {
        margin: 0;
        padding: 0;
        min-height: auto;
    }

    .chat-interface {
        height: auto;
        border: none;
        box-shadow: none;
    }

    .chat-messages {
        height: auto;
        overflow: visible;
        padding: 20px;
    }

    /* Style messages for print */
    .message {
        break-inside: avoid;
        page-break-inside: avoid;
        border: 1px solid #000;
        margin-bottom: 15px;
        box-shadow: none;
    }

    /* Ensure text is black for better printing */
    .message, .message * {
        color: #000 !important;
    }

    /* Add timestamps if needed */
    .message::before {
        content: attr(data-timestamp);
        display: block;
        font-size: 0.8em;
        color: #666;
        margin-bottom: 5px;
    }
}

/* Chat Actions */
.chat-actions {
    position: static !important;
    bottom: auto !important;
    right: auto !important;
    display: none !important;
}

.print-chat-container,
.share-chat-container {
    display: flex;
    justify-content: flex-end;
    margin: 10px 0;
}

.top-chat-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 70px;
    margin-bottom: 10px;
    background: none;
    padding: 0;
}

.print-chat,
.share-chat {
    background: transparent !important;
    border: 0.3px solid rgb(89, 89, 89);
    border-radius: 8px;
    padding: 8px 16px;
    margin-top: 2rem;
    margin-bottom: 2rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    font-family: 'Inter', sans-serif;
    font-size: 0.7em;
    transition: all 0.2s ease;
    color: black;
    text-decoration: none;
    box-shadow: none;
    gap: 0;
}

.print-chat:hover,
.share-chat:hover {
    background: rgba(248, 248, 248, 0.2) !important;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.print-chat i,
.share-chat i {
    font-size: 1em;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: #fff;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    border: 1px solid black;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.modal-header {
    padding: 1rem;
    border-bottom: 1px solid black;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.2em;
    font-weight: 600;
}

.close-modal {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2em;
    padding: 5px;
}

.modal-body {
    padding: 1.5rem;
}

.share-link-container {
    display: flex;
    gap: 10px;
    margin: 1rem 0;
}

#shareLink {
    flex-grow: 1;
    padding: 8px 12px;
    border: 1px solid black;
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 0.9em;
}

.copy-link {
    background: #fff;
    border: 1px solid black;
    border-radius: 6px;
    padding: 8px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
}

.copy-link:hover {
    background: #f8f8f8;
}

.share-status {
    margin-top: 1rem;
    font-size: 0.9em;
    color: #666;
    text-align: center;
}

header {
    border-bottom: none !important;
    box-shadow: none !important;
    margin-bottom: 0 !important;
}

main {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Loading Animation */
.loading-dots {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 20px;
}

.loading-dots span {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #000;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.loading-dots span:nth-child(1) {
    left: 8px;
    animation: loading-dots1 0.6s infinite;
}

.loading-dots span:nth-child(2) {
    left: 8px;
    animation: loading-dots2 0.6s infinite;
}

.loading-dots span:nth-child(3) {
    left: 32px;
    animation: loading-dots2 0.6s infinite;
}

.loading-dots span:nth-child(4) {
    left: 56px;
    animation: loading-dots3 0.6s infinite;
}

@keyframes loading-dots1 {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

@keyframes loading-dots3 {
    0% { transform: scale(1); }
    100% { transform: scale(0); }
}

@keyframes loading-dots2 {
    0% { transform: translate(0, 0); }
    100% { transform: translate(24px, 0); }
}

/* Message loading state */
.message.loading {
    min-height: 40px;
    display: flex;
    align-items: center;
}

/* Institution Results Styles */
.institutions-container {
    margin-top: 15px;
    background-color: #f5f5f5;
    border-radius: 8px;
    padding: 10px;
    border-left: 3px solid #e74c3c;
}

.institutions-header {
    font-weight: bold;
    margin-bottom: 8px;
    color: #333;
}

.institutions-list {
    list-style-type: none;
    padding-left: 0;
    margin: 0;
}

.institution-item {
    margin-bottom: 8px;
    padding: 5px 0;
    border-bottom: 1px solid #eee;
}

.institution-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.institution-item a {
    color: #e74c3c;
    text-decoration: none;
    display: block;
    padding: 5px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.institution-item a:hover {
    background-color: #e5e5e5;
    border-radius: 4px;
} 