/* Basic Body and Container Styling */
body {
    font-family: 'Arial', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Full viewport height */
    margin: 0;
    background-color: #f4f7f6; /* Light background color */
    color: #333; /* Default text color */
    padding: 20px;
    box-sizing: border-box; /* Include padding in element's total width and height */
}

.container {
    background-color: #ffffff; /* White background for the main content area */
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1); /* Soft shadow for depth */
    text-align: center;
    max-width: 700px; /* Max width for readability */
    width: 100%;
    border: 1px solid #e0e0e0; /* Subtle border */
}

h1 {
    color: #007bff; /* Primary blue for main heading */
    margin-bottom: 15px;
    font-size: 2em;
}

p {
    margin-bottom: 20px;
    line-height: 1.6;
}

/* Control Buttons Styling */
.controls {
    margin-bottom: 25px;
    display: flex;
    justify-content: center;
    gap: 15px; /* Space between buttons */
}

button {
    background-color: #007bff; /* Primary blue for buttons */
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

button:hover {
    background-color: #0056b3; /* Darker blue on hover */
    transform: translateY(-2px); /* Slight lift effect */
}

button:disabled {
    background-color: #cccccc; /* Grey for disabled buttons */
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

/* Status Messages Styling */
.message {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 8px;
    border: 1px solid #007bff; /* Blue border for status */
    background-color: #e6f2ff; /* Light blue background for status */
    color: #0056b3; /* Darker blue text for status */
    font-size: 0.95em;
}

/* Video Player Styling */
.video-player-container {
    margin-top: 30px;
    background-color: #f8f8f8; /* Light background for video area */
    padding: 15px;
    border-radius: 10px;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1); /* Inner shadow */
}

#videoPlayer {
    width: 100%;
    max-width: 600px; /* Max width for the video player */
    height: auto;
    border-radius: 8px;
    background-color: #000; /* Black background for video area when nothing is loaded */
    margin-bottom: 15px;
    display: block; /* Ensures it takes full width and avoids extra space below */
    margin-left: auto;
    margin-right: auto;
}

#videoTitle {
    font-weight: bold;
    color: #555;
    background-color: transparent; /* Override .message background */
    border: none; /* Override .message border */
    padding: 0; /* Override .message padding */
    margin-bottom: 0; /* Remove extra margin */
}


/* NEW: AI Response Text Display Area Styling */
.text-response-container {
    margin-top: 30px; /* Space above this section */
    background-color: #f0f8ff; /* Light blue background for text box */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08); /* Subtle shadow for depth */
    text-align: left; /* Align text to the left within the box */
}

.text-response-container h2 {
    color: #0056b3; /* Darker blue for heading */
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.5em;
    text-align: center; /* Center the heading */
}

#aiResponseDisplay {
    background-color: #ffffff; /* White background for the actual text */
    border: 1px solid #b3e0ff; /* Light blue border */
    padding: 15px;
    min-height: 50px; /* Ensure it has some height even when empty */
    border-radius: 8px;
    white-space: pre-wrap; /* Preserve whitespace and line breaks from AI response */
    word-wrap: break-word; /* Break long words */
    color: #333; /* Darker text color for readability */
    font-size: 1.1em; /* Slightly larger font size for the response text */
    line-height: 1.5; /* Spacing between lines for readability */
}