/* General Styles */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    margin: 0;
    padding: 0;
    /* background-color: #f4f6f8; */ /* Replaced by SVG background */
    color: #333;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative; /* For stacking context with SVG background */
    overflow-x: hidden; /* Prevent horizontal scroll from SVG potentially */
    /* cursor: none; */ /* Hide default cursor globally */
}

#vanta-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* Behind all other content */
    overflow: hidden;
}

/* #svg-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1; /* Behind all other content */
/*    overflow: hidden;
} */

/* Keyframes for speckle animation */
/* @keyframes moveSpeckles {
    0% { transform: translate(0px, 0px) scale(1); }
    25% { transform: translate(20px, 30px) scale(1.15); }
    50% { transform: translate(-25px, -20px) scale(0.85); }
    75% { transform: translate(30px, -15px) scale(1.25); }
    100% { transform: translate(0px, 0px) scale(1); }
} */

/* #svg-background circle {
    animation: moveSpeckles 20s linear infinite alternate;
} */

/* Add more variety to speckle animation by targeting with nth-child or classes */
/* #svg-background circle:nth-child(2n) {
    animation-duration: 25s;
    animation-delay: -5s;
} */
/* #svg-background circle:nth-child(3n) {
    animation-duration: 15s;
    animation-delay: -2s;
} */
/* #svg-background circle:nth-child(4n) {
    animation-duration: 30s;
} */

.container {
    display: flex;
    flex: 1; /* Allows container to grow and fill available space */
    width: 100%;
    max-width: 100%; /* Ensure it doesn't exceed viewport */
    margin: 0 auto;
    box-sizing: border-box;
}

/* Sidebar Styles */
.sidebar {
    width: 260px;
    /* background-color: transparent; */ /* Reverted for gradient, will cover Vanta here */
    background: linear-gradient(to bottom, #d5dbdb , #f2d7d5, #f5b7b1 );
    border-right: 1px solid #e0e0e0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    box-shadow: 2px 0 5px rgba(0,0,0,0.05);
    /* Ensure sidebar does not shrink if content is too narrow */
    flex-shrink: 0;
    position: relative; /* For potential pseudo-elements if needed for effects */
}

.sidebar-header h2 {
    font-size: 1.6em; /* Slightly larger for emphasis */
    font-size: 1.8em; /* INCREASED */
    margin-bottom: 25px; /* More space */
    text-align: center;
    font-weight: 700; /* Bolder */
    position: relative; /* For 3D effect and pseudo-elements */
    animation: titleFloat 4s ease-in-out infinite, gradientCycle 10s linear infinite;
    text-shadow: 0 1px 0px #ccc, 
                 0 2px 0px #bbb, 
                 0 3px 0px #aaa, 
                 0 4px 5px rgba(0,0,0,0.2); /* Basic 3D text shadow */
    background: linear-gradient(45deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00); /* Vibrant Rainbow */
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
    background-size: 300% 300%; /* Increased size for smoother cycle with more colors */
}

.sidebar-nav a {
    display: block;
    padding: 12px 15px;
    color: #5f6368;
    text-decoration: none;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: background-color 0.3s, color 0.3s;
}

.sidebar-nav a:hover,
.sidebar-nav a.active {
    background-color: #e8f0fe; /* Lighter blue for hover/active */
    color: #1967d2;
    font-weight: 500;
}

/* Special style for Auth link in sidebar */
.sidebar-nav a.nav-auth-link {
    background-color: #007bff; /* A distinct blue */
    color: #ffffff;
    font-weight: 600; /* Bolder text */
    border: 1px solid #0056b3;
    box-shadow: 0 2px 4px rgba(0, 123, 255, 0.2);
}

.sidebar-nav a.nav-auth-link:hover,
.sidebar-nav a.nav-auth-link.active { /* Though auth link typically won't be 'active' on other pages */
    background-color: #0056b3; /* Darker blue on hover */
    color: #ffffff;
    border-color: #004085;
    box-shadow: 0 3px 6px rgba(0, 123, 255, 0.3);
    transform: translateY(-1px);
}

.chat-history {
    margin-top: 20px;
    flex-grow: 1; /* Allows history to take available space */
    overflow-y: auto; /* Scroll if content overflows */
}

.chat-history h3 {
    font-size: 0.9em;
    color: #5f6368;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    padding-left: 10px;
}

.chat-history ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.chat-history li a {
    display: block;
    padding: 8px 10px;
    font-size: 0.95em;
    color: #3c4043;
    text-decoration: none;
    border-radius: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-history li a:hover {
    background-color: #f1f3f4;
}

.new-chat-btn {
    display: block;
    /* width: 100%; */ /* Removed as fixed elements need explicit width */
    padding: 12px;
    background-color: #1a73e8;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    text-align: center;
    /* margin-top: auto; */ /* No longer needed for flex positioning */
    transition: background-color 0.3s;
    position: fixed; /* Fixed to viewport */
    bottom: 20px;    /* Distance from bottom */
    left: 20px;      /* Distance from left, aligns with sidebar padding */
    width: 220px;    /* Sidebar width (260px) - padding (2*20px) */
    z-index: 1000;   /* Ensure it's above other content */
}

.new-chat-btn:hover {
    background-color: #1558b0;
    transform: translateY(-1px); /* MCP: subtle hover effect */
    box-shadow: 0 4px 8px rgba(26, 115, 232, 0.2); /* MCP: more pronounced shadow on hover */
}

/* Main Content Area (Chat Interface, Feedback Page) */
.chat-interface, .feedback-page {
    flex: 1;
    padding: 0 !important; /* Force padding to 0 */
    /* background-color: #fdfdff; */ /* Changed for Vanta background */
    background-color: transparent;
    display: flex;
    flex-direction: column;
    overflow-y: auto; /* Allows main content to scroll */
    min-width: 0; /* Prevent flex item from overflowing if content is too wide */
}

.chat-header {
    padding: 0 20px; /* Add padding if main container loses it */
}

.chat-header h1 {
    font-size: 2em; /* INCREASED */
    margin-bottom: 5px;
    text-align: center; 
    font-weight: 700; 
    position: relative;
    /* Ensure this uses the general title gradient and animations */
    background: linear-gradient(45deg, #f06, #0f6, #ff0, #0ff, #f0f); /* Matched to general title */
    -webkit-background-clip: text;
    -moz-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent !important;
    -moz-text-fill-color: transparent !important;
    text-fill-color: transparent !important;
    background-size: 400% 400%;
    animation: 
        titleFloat 6s ease-in-out infinite, 
        gradientCycle 15s linear infinite;
    text-shadow: 
        1px 1px 2px rgba(0, 0, 0, 0.2), 
        2px 2px 4px rgba(0, 0, 0, 0.1);
}

.chat-header p {
    text-align: center;
    font-size: 0.95em;
    color: #5f6368;
    margin-bottom: 0;
}

/* Message Area */
.message-area {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px; /* Padding for messages */
    /* border: 1px solid #e0e0e0; */ /* remove border, rely on bg contrast */
    border-radius: 8px;
    margin: 0 25px 15px 25px; /* LR margin to align with padded header/footer */
    background-color: #fff; /* White background for message area */
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    min-height: 500px; /* INCREASED: Set a minimum height */
    /* Consider using flex-basis or height in percentage if parent has fixed height */
}

.message {
    padding: 10px 15px;
    margin-bottom: 10px;
    border-radius: 12px;
    max-width: 50%;
    word-wrap: break-word;
}

.message.user {
    background-color: #d1e7fd; /* Light blue for user messages */
    color: #0a58ca;
    margin-left: auto;
    border-bottom-right-radius: 0;
}

.message.bot {
    background-color: #e9ecef; /* Light grey for bot messages */
    color: #343a40;
    margin-right: auto;
    border-bottom-left-radius: 0;
}

.message strong {
    font-weight: 600;
}

.message.user img,
.message.bot img {
    width: 500px; /* Increased from 40px */
    height: 1500px; /* Increased from 40px */
    border-radius: 6px; /* Slightly larger radius if desired */
    display: block; /* Prevents extra space below if it's inline */
    margin-bottom: 5px; /* Space if text follows */
}

/* Styling for images within chat messages */
.image-message-container {
    margin-top: 5px; /* Space above the image container */
    margin-bottom: 5px; /* Space below if text follows */
    text-align: left; /* Align content to left for bot messages */
}

.message.user .image-message-container {
    text-align: right; /* Align to right for user messages */
}

.user-image-display {
    max-width: 1500px; /* Increased from 200px */
    max-height: 350px; /* Increased from 200px */
    border-radius: 8px;
    border: 1px solid #eee;
    object-fit: cover;
    display: block; /* Or inline-block if text should wrap around */
}

.message.bot img.generated-image-display {
    max-width: 100%; /* Ensure it doesn't overflow chat bubble */
    min-width: 300px; /* Minimum width */
    width: auto; /* Let aspect ratio control height initially */
    height: auto;
    max-height: 500px; /* Maximum height to prevent overly tall images */
    border-radius: 8px;
    margin-top: 8px;
    display: block; /* Ensure it takes its own line if needed */
    object-fit: contain; /* Ensure the whole image is visible, might add padding */
}

.message.bot .image-message-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* Align items to the start of the container */
}

.message.bot .download-image-btn {
    display: inline-block;
    padding: 8px 15px;
    background-color: #1a73e8; /* Theme color */
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 0.9em;
    margin-top: 5px; /* If image is block and button is below it */
    transition: background-color 0.3s ease;
}

.message.bot .download-image-btn:hover {
    background-color: #1558b0; /* Darker shade on hover */
}

/* Use Cases Buttons - Updated Grid Layout & Styles */
.use-cases {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 columns */
    gap: 18px; /* Increased gap */
    padding: 20px 25px 10px 25px; /* Adjusted bottom padding */
    background-color: #f4f6f8; /* Match body background or a very light gray */
    border-top: none; /* Remove top border, rely on section separation */
}

.use-case-btn {
    background-color: #ffffff;
    border: 1px solid #e0e4e7;
    border-radius: 12px; /* More rounded corners */
    padding: 18px 15px; /* Increased padding */
    cursor: pointer;
    transition: all 0.25s ease-in-out;
    display: flex;
    flex-direction: column; /* Stack icon, title, description vertically */
    align-items: center; /* HORIZONTAL CENTER for all content */
    text-align: center; /* Center text content (title, description) */
    box-shadow: 0 2px 4px rgba(0,0,0,0.04);
    gap: 8px; /* Gap between internal elements */
    min-height: 160px; /* Give buttons a consistent minimum height */
    justify-content: center; /* Vertically center content if button height allows */
}

.use-case-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 6px 12px rgba(0,0,0,0.08);
    border-color: #c8d0d8;
}

.use-case-icon {
    font-size: 1.8em; /* Larger icon */
    margin-bottom: 4px; /* Space below icon */
    color: #333; /* Default icon color */
    /* Specific colors can be added per button if desired, or use a theme color */
}

.use-case-icon-img {
    width: 48px; /* Or your preferred size */
    height: 48px; /* Or your preferred size */
    border-radius: 50%; /* Circular images */
    object-fit: cover; /* Ensure image covers the area nicely */
    margin-bottom: 8px; /* Space below icon image */
    background-color: #e0e0e0; /* Placeholder background if image fails to load */
}

.use-case-title {
    font-size: 1.1em; /* INCREASED title size */
    font-size: 1.25em; /* Further INCREASED title size */
    font-weight: 600;
    color: #202124;
    line-height: 1.3;
}

.use-case-description {
    font-size: 0.85em; /* INCREASED description size */
    font-size: 0.95em; /* Further INCREASED description size */
    color: #5f6368;
    line-height: 1.4;
    flex-grow: 1; /* Allow description to take available space if buttons vary in height */
}

/* Remove old ::before icon styles as icons are now in spans */
.use-case-btn::before { content: none; }

/* Prompt Suggestions Area */
.prompt-suggestions {
    padding: 10px 25px 20px 25px; /* Padding around suggestions */
    display: flex;
    flex-wrap: wrap; /* Allow suggestions to wrap */
    gap: 10px;
    justify-content: center; /* Center suggestion buttons */
    background-color: #f4f6f8; /* Match use-cases background */
    /* border-top: 1px dashed #d0d5db; */ /* Optional separator */
}

.suggestion-btn {
    background-color: #e8f0fe;
    border: 1px solid #d2e3fc;
    color: #1967d2;
    padding: 8px 15px;
    border-radius: 20px; /* Pill shape */
    font-size: 0.85em;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.suggestion-btn:hover {
    background-color: #d1e3ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(25,103,210,0.1);
}

/* Image Aspect Ratio Selector Styles */
.image-aspect-ratio-selector {
    padding: 15px 25px;
    background-color: #e9ecef; /* Slightly different background */
    border-top: 1px solid #ced4da;
    text-align: center;
    margin-top: 10px; /* Space above it */
}

.image-aspect-ratio-selector h4 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 0.95em;
    color: #343a40;
    font-weight: 500;
}

.aspect-ratio-btn {
    background-color: #fff;
    border: 1px solid #adb5bd;
    color: #495057;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.9em;
    cursor: pointer;
    margin: 0 250px 5px 0; /* Spacing between buttons */
    transition: all 0.2s ease-in-out;
}

.aspect-ratio-btn:hover {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
    transform: translateY(-1px);
}

.aspect-ratio-btn.selected {
    background-color: #007bff;
    color: white;
    border-color: #0056b3;
    box-shadow: 0 0 0 2px rgba(0,123,255,.25);
}

/* Chat Input Area */
.chat-input-area {
    display: flex;
    align-items: center;
    padding: 15px 25px; /* LR padding to align with message area */
    background-color: #f8f9fa;
    border-top: 1px solid #e9edf0;
    /* margin-top: 0; Ensure no space above if selector is directly before */
    position: sticky; /* MCP: Make input area sticky at the bottom */
    bottom: 0;
    z-index: 10;
}

.upload-btn, .send-btn {
    background: none;
    border: none;
    font-size: 1.6em; /* Icon size */
    color: #5f6368;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 50%;
    transition: color 0.3s, background-color 0.3s;
}

.upload-btn:hover, .send-btn:hover {
    color: #1a73e8;
    background-color: #e8f0fe;
}

.image-preview-container {
    display: flex;
    gap: 5px;
    margin: 0 10px;
}

.image-preview {
    position: relative;
}

.image-preview img {
    width: 100px; /* Increased from 40px */
    height: 90px; /* Increased from 40px */
    border-radius: 6px; /* Slightly larger radius if desired */
    object-fit: cover;
}

.image-preview .delete-img-btn {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: rgba(0,0,0,0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    font-size: 10px;
    line-height: 16px;
    text-align: center;
    cursor: pointer;
    padding: 0;
}

#chatInput {
    flex-grow: 1;
    padding: 30px 20px; /* INCREASED: More padding for taller input */
    border: 1px solid #dadce0;
    border-radius: 22px; /* Pill shape */
    font-size: 1em;
    resize: none;
    margin: 0 12px;
    min-height: 48px; /* INCREASED: Taller input area */
    background-color: #fff;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.05);
}

#chatInput:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.15), inset 0 1px 2px rgba(0,0,0,0.05);
}

/* Footer */
footer {
    /* background-color: #333; */ /* Old dark background */
    background: linear-gradient(to bottom, #d5dbdb, #f5b7b1 ); /* Light green to paler green gradient */
    color: #333; /* Darker text for better readability on light green */
    text-align: center;
    padding: 20px; 
    font-size: 0.85em;
    box-sizing: border-box;
    margin-top: auto; 
    /* border-top: 1px solid #444; */ /* Old border, maybe remove or lighten for green bg */
    border-top: 1px solid #a0d2a0; /* Lighter green border */
}

/* If footer is direct child of body (auth pages), it spans full width */
body > footer {
    width: 100%;
    margin-top: 0; 
    /* border-top: none; */ /* Keeping a border for consistency */
}

/* For pages with sidebar, the footer inside main content needs specific context */
.chat-interface footer,
.feedback-page footer {
    width: 100%; 
    box-sizing: border-box; 
    /* background-color: #f8f9fa; */ /* Old light grey */
    background: linear-gradient(to bottom, #d5dbdb, #f5b7b1 ); /* Consistent green gradient */
    color: #333; /* Consistent dark text color */
    /* border-top: 1px solid #e9edf0; */ /* Old light border */
    border-top: 1px solid #a0d2a0; /* Lighter green border */
    padding: 15px 25px; 
    text-align: center; 
    margin-top: auto; 
}

.chat-interface footer a,
.feedback-page footer a,
footer a { /* General rule for all footer links */
    color: #006400; /* Dark Green for links, good contrast on light green */
    text-decoration: none; /* Removing underline by default, can add on hover */
}

footer a:hover {
    text-decoration: underline;
}

.footer-divider {
    border: none;
    /* border-top: 1px solid #555; */ /* Old dark divider */
    border-top: 1px solid #8FBC8F; /* Medium Dark Sea Green divider */
    margin: 10px auto;
}

/* .chat-interface footer .footer-divider,
.feedback-page footer .footer-divider {
    border-top-color: #d0d5db; 
} */ /* Not needed if all dividers are the same */

.footer-ai-notice {
    font-size: 0.8em;
    /* color: #ccc; */ /* Old for dark footers */
    color: #2F4F4F; /* Dark Slate Gray, good on light green */
    margin-top: 10px;
}

.footer-ai-notice a {
    /* color: #add8e6; */ /* Old for dark footer links */
    color: #006400; /* Consistent Dark Green for links */
    text-decoration: underline;
}

/* .chat-interface .footer-ai-notice,
.feedback-page .footer-ai-notice {
    color: #777; 
} */ /* Covered by general .footer-ai-notice */

/* .chat-interface .footer-ai-notice a,
.feedback-page .footer-ai-notice a {
    color: #1a73e8; 
} */ /* Covered by general .footer-ai-notice a */


/* Review Card Overall Rating - Enhanced */
.overall-rating {
    font-weight: 500; /* Normal bold */
    margin-top: 15px;
    text-align: right;
    color: #202124; /* Darker text for the label part */
    font-size: 1.1em; /* Slightly larger */
    background-color: #f0f4f9; /* Light accent background */
    padding: 8px 12px;
    border-radius: 6px;
    display: inline-block; /* To apply padding and border-radius correctly */
    float: right; /* Keep it to the right */
    clear: both; /* Ensure it doesn't overlap floated elements if any */
}

.overall-rating .score-value {
    font-weight: 700; /* Bolder for the score itself */
    color: #1a73e8; /* Accent color for the score */
    font-size: 1.2em; /* Larger score */
    margin-left: 8px;
}

/* Auth Pages (Login/Register) */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-grow: 1; /* Takes remaining vertical space */
    padding: 20px;
}

.auth-form {
    background-color: #fff;
    padding: 30px 40px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.auth-form h2 {
    margin-bottom: 25px;
    font-size: 1.8em;
    background: linear-gradient(45deg, #ff4e50, #f9d423, #ff4e50); /* Red-Yellow-Red */
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
    background-size: 200% 200%; 
    animation: titleFloat 3s ease-in-out infinite, gradientCycle 10s linear infinite;
    text-shadow: 0 1px 0px #ad9c9c, 
                 0 2px 0px #9a8383, 
                 0 3px 0px #836f6f, 
                 0 4px 5px rgba(0,0,0,0.15);
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: #5f6368;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #dadce0;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 1em;
}

.form-group input:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
    background-color: #f0f4ff; /* MCP: subtle focus background */
}

.auth-btn {
    width: 100%;
    padding: 12px;
    background-color: #1a73e8;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-bottom: 15px;
}

.auth-btn:hover {
    background-color: #1558b0;
    transform: translateY(-1px); /* MCP: subtle hover effect */
    box-shadow: 0 4px 8px rgba(26, 115, 232, 0.2); /* MCP: more pronounced shadow on hover */
}

.google-login-btn {
    width: 100%;
    padding: 12px;
    background-color: #fff;
    color: #4285F4; /* Google blue */
    border: 1px solid #dadce0;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    transition: background-color 0.3s, box-shadow 0.3s;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.google-login-btn::before { /* Simple Google G icon placeholder */
    content: "G";
    font-weight: bold;
    font-size: 1.2em;
    color: #4285F4;
}


.google-login-btn:hover {
    background-color: #f8f9fa;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    border-color: #cacdd1; /* MCP: slightly darker border on hover */
}

.auth-form p {
    margin-top: 15px;
    font-size: 0.9em;
    color: #5f6368;
}

.auth-form a {
    color: #1a73e8;
    text-decoration: none;
}

.auth-form a:hover {
    text-decoration: underline;
}

.back-home-btn {
    display: inline-block;
    margin-top: 10px;
    font-size: 0.9em;
    color: #1a73e8 !important;
}


/* Feedback Page Specifics */
.feedback-page {
    /* General structure inherited from .chat-interface */
}

.reviews-section {
    margin-bottom: 30px;
}

/* MCP: Reviewer Avatar Styles */
.reviewer-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: #d1e7fd; /* Light blue, can be varied */
    color: #1967d2; /* Darker blue for text */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4em;
    font-weight: 600;
    margin-right: 15px;
    flex-shrink: 0;
}
.reviewer-avatar span {
    line-height: 1; /* Ensure text is vertically centered */
}

.reviewer-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the image covers the avatar area without distortion */
    border-radius: 50%; /* Keep it circular */
}

.review-card {
    background-color: #fff; /* MCP: Cleaner white background */
    border: 1px solid #e9edf0; /* MCP: Softer border */
    border-radius: 12px; 
    padding: 20px 25px; /* MCP: Adjust padding */
    margin-bottom: 25px; /* MCP: Increase spacing */
    box-shadow: 0 4px 12px rgba(0,0,0,0.06); /* MCP: Softer, more modern shadow */
    opacity: 0;
    transform: translateY(20px) scale(0.95); /* Initial state for pop-up animation */
    transition: opacity 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55), transform 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55); /* Easing for pop-up */
}

.review-header {
    display: flex; /* Use flex for avatar and info */
    align-items: center; /* Align items vertically */
    margin-bottom: 12px; /* MCP: Adjust spacing */
}

.reviewer-info {
    display: flex;
    flex-direction: column; /* Stack name and date */
}

.reviewer-name {
    font-weight: 600;
    color: #1a73e8;
    font-size: 1.05em; /* MCP: Adjust size */
}

.review-date {
    font-size: 0.8em; /* MCP: Slightly smaller */
    color: #5f6368;
    margin-top: 2px;
}

.review-rating span {
    display: inline-block;
    margin-right: 15px;
    font-size: 0.9em;
    color: #4a4a4a;
    background-color: #f8f9fa; /* MCP: Subtle background for rating items */
    padding: 3px 8px;
    border-radius: 12px; /* Pill shape */
}

.review-text {
    margin: 15px 0;
    color: #3c4043; /* MCP: Slightly darker text for better readability */
    line-height: 1.75; /* MCP: Increase line height */
    font-size: 0.95em;
}

.submit-review-section {
    background-color: #ffffff; /* White background for the section */
    padding: 30px 35px; /* Increased padding */
    border-radius: 12px; /* Consistent rounded corners */
    box-shadow: 0 4px 12px rgba(0,0,0,0.08); /* Softer shadow, consistent with other cards */
    margin-top: 30px; /* Space above this section */
}

.submit-review-section h2 {
    font-size: 1.6em; /* Slightly larger title for this section */
    margin-bottom: 25px; /* Increased space below title */
    color: #1a73e8; /* Consistent theme color for title */
    border-top: none; /* Remove previous top border if any */
    padding-top: 0; /* Remove previous padding if any */
    text-align: center; /* Center the section title */
}

.submit-review-section .form-group {
    margin-bottom: 22px; /* Increased space between form groups */
}

.submit-review-section .form-group label {
    font-weight: 500; /* Slightly bolder labels */
    color: #3c4043; /* Darker label color for better contrast */
    display: block;
    margin-bottom: 8px; /* More space below label */
}

.submit-review-section .form-group input[type="text"],
.submit-review-section .form-group select,
.submit-review-section .form-group textarea {
    width: 100%;
    padding: 12px 15px; /* Comfortable padding */
    border: 1px solid #d0d5db; /* Softer border color */
    border-radius: 8px; /* Nicely rounded corners */
    box-sizing: border-box;
    font-size: 1em;
    margin-top: 0; /* Remove default margin-top if any from previous styles */
    background-color: #fdfdff; /* Very light background for inputs */
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.submit-review-section .form-group input[type="file"] {
    padding: 8px 10px;
    border: 1px solid #d0d5db;
    border-radius: 8px;
    background-color: #fdfdff;
    /* Basic styling for file input, browser defaults are hard to override beautifully */
}


.submit-review-section .form-group input[type="text"]:focus,
.submit-review-section .form-group select:focus,
.submit-review-section .form-group textarea:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.15); /* Softer focus shadow */
    background-color: #fff; /* White background on focus */
}
.submit-review-section .form-group textarea {
    min-height: 120px; /* Taller textarea */
}

.submit-review-btn {
    display: inline-block;
    padding: 12px 25px;
    background-color: #1a73e8;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 10px;
}

.submit-review-btn:hover {
    background-color: #1558b0;
    transform: translateY(-1px); /* MCP: subtle hover effect */
    box-shadow: 0 4px 8px rgba(26, 115, 232, 0.2); /* MCP: more pronounced shadow on hover */
}

/* Review Card Animation - CSS part (JS triggers by changing opacity/transform) */
@keyframes popUpFadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Ensure .review-card uses the transition for JS control, not this keyframe directly */
/* JS will set opacity to 1 and transform to translateY(0) scale(1) to trigger transition */


/* Overall Summary Rating Section */
.overall-summary-rating {
    background-color: #fff; /* MCP: Brighter background */
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.overall-summary-rating h2 {
    text-align: center;
    font-size: 1.6em;
    color: #202124;
    margin-bottom: 25px;
}

.summary-container {
    display: flex;
    align-items: flex-start;
    gap: 30px;
}

.summary-score-display {
    flex-basis: 180px; /* Width for the score part */
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-right: 20px;
    border-right: 1px solid #e0e0e0; /* Separator line */
}

.score-value-large {
    font-size: 4em; /* Large score */
    font-weight: 700;
    color: #1a73e8;
    line-height: 1;
    margin-bottom: 5px;
}

.score-stars {
    font-size: 1.5em;
    color: #ffc107; /* Star color */
    margin-bottom: 8px;
}

.score-based-on {
    font-size: 0.85em;
    color: #5f6368;
}

.summary-bars {
    flex: 1; /* Takes remaining space */
    display: flex;
    flex-direction: column;
    gap: 15px; /* Space between bars */
}

.bar-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bar-label {
    flex-basis: 100px; /* Width for labels */
    font-size: 0.9em;
    color: #3c4043;
    text-align: right;
}

.bar-track {
    flex-grow: 1;
    height: 12px;
    background-color: #e9ecef;
    border-radius: 6px;
    overflow: hidden; /* Ensures fill stays within rounded corners */
}

.bar-fill {
    height: 100%;
    background-color: #1a73e8; /* Bar color */
    border-radius: 6px;
    transition: width 0.5s ease-out;
}

.bar-value {
    font-size: 0.9em;
    font-weight: 500;
    color: #3c4043;
    min-width: 25px; /* Ensure space for value */
    text-align: left;
}

/* Footer adjustments for sidebar layout */
.chat-interface footer,
.feedback-page footer {
    /* padding-left: 0; Reduce left padding if sidebar is very close */
    /* padding-right: 0; */
}


/* Responsive adjustments for summary rating */
@media (max-width: 768px) {
    .summary-container {
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }
    .summary-score-display {
        flex-basis: auto;
        padding-right: 0;
        border-right: none;
        margin-bottom: 20px;
        border-bottom: 1px solid #e0e0e0;
        padding-bottom: 20px;
        width: 100%;
    }
    .bar-label {
        flex-basis: 80px;
        text-align: left;
    }
    .overall-summary-rating {
        padding: 20px;
    }
    .chat-header h1 {
        font-size: 1.6em;
    }

}

@media (max-width: 480px) {
    .score-value-large {
        font-size: 3.2em;
    }
    .score-stars {
        font-size: 1.3em;
    }
    .bar-item {
        flex-wrap: wrap; /* Allow label and bar to stack if needed */
    }
    .bar-label {
        flex-basis: 100%;
        margin-bottom: 5px;
        text-align: left;
    }
    .bar-value {
        margin-left: auto; /* Push value to the right if it wraps */
    }
     .chat-header h1 {
        font-size: 1.4em;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        flex-direction: column; /* Stack sidebar and main content */
    }

    .sidebar {
        width: 100%; /* Full width on mobile */
        height: auto;
        border-right: none;
        border-bottom: 1px solid #e0e0e0; /* Separator */
        flex-shrink: 0; /* Prevent shrinking on mobile */
    }

    .sidebar-nav {
        display: flex; /* Horizontal navigation items */
        justify-content: space-around;
        margin-bottom: 10px;
    }
    .sidebar-nav a {
        margin-bottom: 0;
        padding: 10px 8px;
        font-size: 0.9em;
    }

    .chat-history {
        max-height: 150px; /* Limit history height on mobile */
    }
    .chat-history h3 {
      text-align: center;
      padding-left: 0;
    }

    .new-chat-btn {
        margin-top: 15px;
        padding: 10px;
    }

    .chat-interface, .feedback-page {
        padding: 15px;
        /* margin-top: <height_of_sidebar_if_fixed>; */
    }
    .chat-header h1, .feedback-header h1 {
      font-size: 1.5em;
    }
    .chat-header p {
      font-size: 0.9em;
    }


    .message-area {
        /* Potentially adjust based on fixed sidebar */
    }

    .message.user, .message.bot {
        max-width: 90%; /* Allow messages to take more width */
    }

    .use-cases {
        justify-content: flex-start; /* Align to start on mobile */
        padding-left: 0;
        padding-right: 0;
        margin-top: 15px;
    }
    .use-case-btn {
        font-size: 0.85em; /* Adjust size for mobile */
        padding: 8px 14px;
        gap: 6px;
    }
    .use-case-btn::before {
        font-size: 1em;
    }

    .overall-rating {
        float: none; /* Stack on mobile */
        text-align: left; /* Align left on mobile */
        margin-top: 10px;
        display: block; /* Take full width of its line */
        font-size: 1em;
    }
    .overall-rating .score-value {
        font-size: 1.1em;
    }

    /* Footer on mobile: always full width at the bottom of the page content */
    .chat-interface footer,
    .feedback-page footer {
        width: 100%; /* Override to full width */
        margin-left: -15px; /* Counteract parent padding if needed */
        margin-right: -15px; /* Counteract parent padding if needed */
        padding-left: 15px;
        padding-right: 15px;
        box-sizing: border-box;
         background-color: #333; /* Revert to dark footer on mobile for consistency */
        color: #f1f1f1;
        border-top: 1px solid #444;
    }
    .chat-interface footer a,
    .feedback-page footer a {
        color: #a0cfff;
    }

    /* Ensure footer is always at the bottom */
    body {
      /* display: flex; */
      /* flex-direction: column; */
      /* min-height: 100vh; */
    }
    .container {
      /* flex: 1; */
    }

}

@media (max-width: 480px) {
    .sidebar-nav a {
        font-size: 0.8em;
        padding: 8px 5px;
    }
    .sidebar-header h2 {
        font-size: 1.3em;
    }
    .chat-history h3 {
        font-size: 0.8em;
    }
    .chat-history li a {
        font-size: 0.9em;
    }

    .chat-header h1, .feedback-header h1 {
      font-size: 1.3em;
    }

    .use-case-btn {
        width: calc(50% - 10px); /* Two buttons per row */
        text-align: center;
    }
    /* Adjust input area further if needed for very small screens */
    .chat-input-area {
        flex-direction: row; /* Keep as row */
        align-items: center;
    }
    .upload-btn {
        margin-right: 5px;
    }
    #chatInput {
        flex-grow: 1;
        margin-left: 0;
        margin-right: 5px;
    }
    .send-btn {
        margin-left: auto;
    }
    #imagePreviewContainer {
        width: auto; /* Let it shrink if buttons take space */
        margin-bottom: 0;
        margin-right: 5px;
        order: 0; /* Reset order for very small screens if needed */
    }
}

/* Add wrapper for content padding if needed, or apply padding to specific sections */
.content-wrapper {
    padding: 25px;
    flex-grow: 1; /* Allow content to push footer down */
    display: flex;
    flex-direction: column;
}

.chat-interface > header.chat-header {
    padding: 20px 25px 15px 25px; /* Top, LR, Bottom */
    border-bottom: 1px solid #e9edf0;
    /* background-color: #fff; */ /* Changed for Vanta background */
    background-color: transparent;
}

.feedback-page > header.feedback-header {
    padding: 20px 25px 15px 25px;
    border-bottom: 1px solid #e9edf0;
    /* background-color: #fff; */ /* Changed for Vanta background */
    background-color: transparent;
}

.feedback-header h1 {
    font-size: 2em; /* INCREASED */
    margin-bottom: 0; 
    text-align: center; 
    font-weight: 700; 
    position: relative;
    /* Ensure this uses the general title gradient and animations */
    background: linear-gradient(45deg, #f06, #0f6, #ff0, #0ff, #f0f); /* Matched to general title */
    -webkit-background-clip: text;
    -moz-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent !important;
    -moz-text-fill-color: transparent !important;
    text-fill-color: transparent !important;
    background-size: 400% 400%;
    animation: 
        titleFloat 6s ease-in-out infinite, 
        gradientCycle 15s linear infinite;
    text-shadow: 
        1px 1px 2px rgba(0, 0, 0, 0.2), 
        2px 2px 4px rgba(0, 0, 0, 0.1);
}

/* Feedback page specific padding */
.feedback-page .reviews-section,
.feedback-page .overall-summary-rating,
.feedback-page .submit-review-section {
    padding-left: 25px;
    padding-right: 25px;
}
.feedback-page .overall-summary-rating {
    margin-left: 25px;
    margin-right: 25px;
    width: calc(100% - 50px); /* Adjust for padding if it's a direct child */
    box-sizing: border-box;
}


/* Responsive Design */
@media (max-width: 768px) {
    /* Keep sidebar full width on mobile */

    .chat-interface > header.chat-header,
    .feedback-page > header.feedback-header,
    .message-area,
    .chat-input-area,
    .use-cases,
    .feedback-page .reviews-section,
    .feedback-page .overall-summary-rating,
    .feedback-page .submit-review-section {
        padding-left: 15px;
        padding-right: 15px;
    }
    .feedback-page .overall-summary-rating {
        margin-left: 15px;
        margin-right: 15px;
        width: calc(100% - 30px);
    }

    .use-cases {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
        gap: 10px;
    }
    .use-case-btn {
        font-size: 0.85em;
        padding: 10px 12px;
    }

     /* Footer on mobile: revert to dark full-width footer */
    .chat-interface footer,
    .feedback-page footer {
        background-color: #333;
        color: #f1f1f1;
        border-top: 1px solid #444;
        padding: 15px; /* Reset padding */
    }
    .chat-interface footer a,
    .feedback-page footer a {
        color: #a0cfff;
    }
}

@media (max-width: 480px) {
    .use-cases {
        grid-template-columns: repeat(2, 1fr); /* Still 2 columns, or 1 if too crowded */
        /* Consider repeat(auto-fit, minmax(120px, 1fr)) for more dynamic wrapping */
        gap: 8px;
    }
    .use-case-btn {
        font-size: 0.8em;
        padding: 8px 10px;
        flex-direction: column; /* Stack icon and text */
        gap: 4px;
    }
    .use-case-btn::before {
        margin-right: 0; /* Remove margin when stacked */
        font-size: 1.2em;
    }
    #chatInput {
        margin: 0 8px;
        padding: 10px 15px;
    }
    .upload-btn, .send-btn {
        padding: 6px 8px;
        font-size: 1.5em;
    }
}

/* Custom Pointer Styles */
body {
    /* cursor: none; */ /* Hide default cursor globally */
}

#custom-pointer {
    position: absolute;
    width: 30px; /* Adjust size as needed */
    height: 30px; /* Adjust size as needed */
    font-size: 24px; /* Emoji size */
    pointer-events: none; /* So it doesn't interfere with clicks on other elements */
    z-index: 9999; /* Ensure it's on top */
    transform: translate(-20%, -20%); /* Offset to make the tip of the emoji the cursor point */
    /* Add transitions for smoother movement if desired */
    /* transition: transform 0.05s ease-out; */
}

/* Optionally hide default cursor only on specific interactive elements */
button, a, input, textarea, select, .use-case-btn, .suggestion-btn {
    cursor: none; /* Hides default cursor for these elements */
}

/* Ensure other elements that should have default cursor behavior are not affected if you don't hide globally */
/* For example, text selection might need default cursor: */
/* p, span, div { cursor: default; } */

/* Keyframes for Title Animations */
@keyframes titleFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-6px); /* Adjust float height */
    }
}

@keyframes gradientCycle {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Apply to titles that use gradient */
.sidebar-header h2,
.chat-header h1,
.feedback-header h1 {
    background-size: 300% 300%; /* For gradient animation */
}

/* Custom File Upload Styling */
.custom-file-upload {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 5px; /* Adjust as needed */
}

.custom-file-upload-btn {
    display: inline-block;
    padding: 8px 15px;
    background-color: #e9ecef; /* Light grey button */
    color: #495057;
    border: 1px solid #ced4da;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9em;
    transition: background-color 0.2s, border-color 0.2s;
}

.custom-file-upload-btn:hover {
    background-color: #dde2e6;
    border-color: #b8c0c7;
}

.custom-file-name {
    font-size: 0.9em;
    color: #5f6368;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px; /* Adjust as needed */
}

/* Style for the delete preview button */
.delete-preview-btn {
    background-color: #ffdddd; /* Light red background */
    color: #d9534f; /* Red text color */
    border: 1px solid #d9534f;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8em;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
}

.delete-preview-btn:hover {
    background-color: #d9534f;
    color: white;
}

/* Sidebar User Profile Styling */
.user-profile-sidebar {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    margin-bottom: 15px; /* Space before other nav items */
    border-bottom: 1px solid rgba(0,0,0,0.05); /* Subtle separator */
    position: relative; /* For dropdown positioning */
    cursor: pointer;
}

.user-avatar-sidebar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 12px;
    object-fit: cover;
    background-color: #ddd; /* Placeholder if image fails or for text avatar */
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #fff;
}

.user-avatar-sidebar.text-avatar {
    background-color: #007bff; /* Example color for text avatar */
    font-size: 1.2em;
}

.user-name-sidebar {
    font-weight: 500;
    color: #333;
    flex-grow: 1; /* Takes available space */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-profile-dropdown {
    display: none; /* Hidden by default */
    position: absolute;
    top: 100%; /* Position below the profile div */
    left: 0;
    right: 0;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    z-index: 100;
    padding: 5px 0;
}

.user-profile-dropdown a {
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-size: 0.9em;
}

.user-profile-dropdown a:hover {
    background-color: #f0f0f0;
}

/* Ensure nav-auth-link is hidden correctly by JS if profile is shown */
.sidebar-nav a.nav-auth-link[style*="display: none"] + .user-profile-sidebar {
    /* Optional: Adjust margin or padding if needed when auth link is hidden */
}

/* Added for User Profile Page (view-profile.html) */
.profile-page-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    /* min-height: calc(100vh - 100px); Removed, as main-content will handle height */
    box-sizing: border-box;
    width: 100%; /* Ensure it takes full width of main-content */
}

.profile-card {
    background-color: #fff;
    padding: 30px 40px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 500px; /* Or adjust as needed within the main content area */
    text-align: center;
    margin-top: 80px; /* Space from top of main content or header */
    margin-bottom: 40px; /* Space before footer */
    margin-left: 600px;
}

/* .profile-card h1 will now use .page-title for its main styling */

.profile-avatar-container {
    margin-bottom: 25px;
    margin-top: 20px; /* Added some top margin for better spacing from title */
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #eee;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    display: block; /* Ensure it behaves as a block for margin auto */
    margin-left: auto;
    margin-right: auto;
}

.profile-avatar-text {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background-color: #007bff; /* Example color, can be themed */
    color: white;
    display: flex; /* Already flex, ensure it displays */
    align-items: center;
    justify-content: center;
    font-size: 3em;
    font-weight: bold;
    border: 3px solid #eee;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    margin-left: auto;
    margin-right: auto;
}

.profile-info p {
    font-size: 1.1em;
    color: #333;
    margin-bottom: 12px;
    line-height: 1.6;
    text-align: left; /* Align text to the left for better readability */
    padding-left: 20%; /* Indent to align with a centered look */
}

.profile-info strong {
    color: #555;
    margin-right: 8px;
}

.profile-back-btn {
    display: inline-block; /* Ensure it behaves like a button */
    padding: 10px 20px;
    background-color: #007bff; /* Primary button color */
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 500;
    border: none; /* Remove border if not desired, or style it */
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s, box-shadow 0.2s;
    margin-top: 30px;
    box-shadow: 0 2px 4px rgba(0, 123, 255, 0.2);
}

.profile-back-btn:hover {
    background-color: #0056b3; /* Darker shade on hover */
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

/* Ensure main content area in pages with sidebar has enough padding */
.main-content {
    /* ... other styles ... */
    padding-top: 20px; /* Add some padding if header is not fixed or if content is too close to top */
    padding-bottom: 20px; /* Add padding at bottom before footer */
}


/* Footer adjustments to ensure it's below main content correctly */
footer {
    /* ... existing footer styles ... */
    width: 100%; /* Ensure it spans full width available to it */
    /* If in a flex container with main content, it should align correctly. */
    /* If sticky footer needed for short content pages, other techniques apply */
}

/* === Title Styling === */
h1, h2, .page-title, .sidebar .sidebar-header h2 { /* Apply to all relevant titles */
    font-weight: bold;
    text-align: center;
    margin-bottom: 20px; /* Consistent margin */

    /* Colorful Gradient Text */
    background: linear-gradient(45deg, #f06, #0f6, #ff0, #0ff, #f0f); /* Brighter: Magenta, Lime, Yellow, Cyan, Fuchsia */
    -webkit-background-clip: text;
    -moz-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent !important; /* Added !important to ensure override */
    -moz-text-fill-color: transparent !important;    /* Added !important to ensure override */
    text-fill-color: transparent !important;         /* Added !important to ensure override */
    background-size: 400% 400%; 

    /* Animations */
    animation: 
        titleFloat 6s ease-in-out infinite, 
        gradientCycle 15s linear infinite; /* Slightly faster cycle for more dynamism */

    /* 3D Text Shadow for depth - more subtle to let colors shine */
    text-shadow: 
        /* 0 1px 0px rgba(204, 204, 204, 0.5), 
        0 2px 0px rgba(187, 187, 187, 0.4), 
        0 3px 0px rgba(170, 170, 170, 0.3), */
        /* Using a single, darker, slightly offset shadow for depth without graying out */
        1px 1px 2px rgba(0, 0, 0, 0.2), 
        2px 2px 4px rgba(0, 0, 0, 0.1);
    
    /* Fallback color is less critical if !important is used on text-fill-color, but good practice */
    color: #333; /* This should be overridden by transparent fill */
}

/* Overriding specific title if it was too small or needed different margin */
.sidebar .sidebar-header h2 {
    font-size: 1.8em; /* Slightly smaller than main page titles if needed */
    margin-bottom: 15px;
    /* It will inherit the gradient and animations from the rule above */
}

.page-title { /* For main titles on pages like User Feedback, Profile */
    font-size: 2.8em; /* Larger main page titles */
    /* It will inherit the gradient and animations */
}

/* Individual h1 on index.html if it needs specific sizing */
.main-content > h1 { /* Targeting the main title on index.html */
    font-size: 3em; /* Example: ensure it's large enough */
     /* It will inherit the gradient and animations */
}


@keyframes titleFloat {
/* ... existing code ... */
}

@keyframes gradientCycle {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Remove the old .title-shine animation if it exists and is not used */
/* @keyframes titleShine { ... } */


/* ... rest of style.css ... */

/* --- Chat History Styling in Sidebar --- */
.sidebar-history-section {
    padding: 10px;
    border-top: 1px solid #e0e0e0;
}

.sidebar-history-section h4 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 0.9em;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#history-list, #history-list-feedback {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 200px; /* Adjust as needed */
    overflow-y: auto;
}

.history-item {
    display: flex; /* Key change for horizontal layout */
    justify-content: space-between; /* Pushes title and actions apart */
    align-items: center; /* Vertically aligns items in the center */
    padding: 8px 5px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out, transform 0.1s ease-in-out; /* Added transform for subtle pop */
}

.history-item:last-child {
    border-bottom: none;
}

.history-item:hover {
    background-color: #e9e9e9; /* Hover effect */
    transform: translateX(3px); /* Subtle shift on hover */
}

.history-title {
    flex-grow: 1; /* Allows title to take available space */
    font-size: 0.9em;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-right: 10px; /* Space between title and actions */
}

.history-item-actions {
    display: flex; /* Keeps action buttons in a row */
    align-items: center;
    gap: 5px; /* Space between action buttons */
}

.history-action-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1em; /* Adjust icon size if needed */
    padding: 2px 4px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.history-action-btn:hover {
    background-color: #dcdcdc;
}

.no-history {
    padding: 10px;
    color: #777;
    font-style: italic;
}

.clear-history-btn {
    display: block;
    width: calc(100% - 10px); /* Slightly less than full width for padding */
    margin: 5px 5px 15px 5px;
    padding: 10px 15px;
    background-color: #f44336; /* Red color for delete/clear */
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 0.9em;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.clear-history-btn:hover {
    background-color: #d32f2f; /* Darker red on hover */
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* --- Chat Input Area --- */
.chat-input-area {
    display: flex;
    align-items: center;
    padding: 15px 25px; /* LR padding to align with message area */
    background-color: #f8f9fa;
    border-top: 1px solid #e9edf0;
    /* margin-top: 0; Ensure no space above if selector is directly before */
    position: sticky; /* MCP: Make input area sticky at the bottom */
    bottom: 0;
    z-index: 10;
}

/* Aspect Ratio Selector Styling */
#image-aspect-ratio-selector {
    display: none; 
    border-bottom: 1px solid #ddd; 
    text-align: center;
    position: relative; 
    width: 100%;
    box-sizing: border-box;
    background-color: var(--background-color); 
    padding: 10px 15px 5px 15px; 
    /* margin-bottom: 0; Ensure no space below if input is next */
}

.aspect-ratio-selector-bar {
/* ... existing code ... */
} 