/* General Body Styles */
body {
    font-family: 'Arial', sans-serif; /* Font family for the entire body */
    background-color: #f0f4f8; /* Light background color */
    margin: 0; /* Reset margin */
    padding: 20px; /* General padding for body */
    color: #333; /* Text color */
    height: 100vh; /* Full height for the body */
    display: flex; /* Flexbox for centering content */
    flex-direction: column; /* Vertical stacking of children */
    align-items: center; /* Center align items */
    justify-content: center; /* Center justify items */
    transition: background-color 0.3s, color 0.3s; /* Smooth transition effects */
    background-image: url(./1_BGO57XTzTcWJjkxm4yu5Kw.jpg); /* Background image */
    background-size: cover; /* Cover the entire area */
}

/* Header Styles */
h1 {
    color: #343a40; /* Darker header color */
    margin-bottom: 20px; /* Spacing below header */
}

/* Container Styles */
.container {
    max-width: 900px; /* Limit the maximum width */
    background: rgba(255, 255, 255, 0.95); /* Semi-transparent white background */
    border-radius: 15px; /* Rounded corners */
    padding: 40px; /* Padding inside the container */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15); /* Depth with shadow */
    overflow-y: auto; /* Allow vertical scrolling */
    max-height: 90vh; /* Maximum height */
    transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth transitions */
}

/* Hover Effects for Container */
.container:hover {
    background: rgba(255, 255, 255, 1); /* Full opacity on hover */
    transform: translateY(-5px); /* Lift effect on hover */
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2); /* Deeper shadow */
}

/* Headings Inside Container */
.container h2,
.container h3 {
    margin: 0; /* Remove default margin */
    font-weight: bold; /* Bold titles for emphasis */
    color: #333; /* Darker text for better contrast */
}

/* Paragraphs and Labels */
.container p,
.container label {
    margin: 10px 0; /* Consistent spacing */
    color: #555; /* Softer text color */
}

/* Input, Select, Textarea, Button Styles */
.container input,
.container select,
.container button,
.container textarea {
    width: 100%; /* Full width */
    padding: 10px; /* Padding for comfort */
    border: 1px solid #ced4da; /* Subtle border */
    border-radius: 5px; /* Rounded edges */
    margin-top: 10px; /* Spacing above elements */
    font-size: 16px; /* Font size */
    transition: border-color 0.2s; /* Smooth border transition */
}

/* Focus States */
.container input:focus,
.container select:focus,
.container textarea:focus {
    border-color: #007bff; /* Highlight border on focus */
    outline: none; /* Remove default outline */
}

/* Button Styles */
.container button {
    background-color: #007bff; /* Primary button color */
    color: white; /* White text for buttons */
    border: none; /* No border */
    cursor: pointer; /* Pointer cursor on hover */
    margin-top: 15px; /* Spacing above button */
    transition: background-color 0.3s, transform 0.3s; /* Smooth transition */
}

.container button:hover {
    background-color: #0056b3; /* Darker blue on hover */
    transform: scale(1.05); /* Slight scale effect on hover */
}

/* Audio Element */
audio {
    margin-top: 20px; /* Spacing above audio player */
    display: none; /* Initially hidden */
    width: 100%; /* Full width */
}

/* Error and Success Messages */
.error {
    color: #dc3545; /* Red for errors */
    margin-top: 10px; /* Spacing above message */
}

.success {
    color: #28a745; /* Green for success */
    margin-top: 10px; /* Spacing above message */
}

/* Loading Message */
.loading {
    display: none; /* Initially hidden */
    color: #007bff; /* Loading text color */
    margin-top: 10px; /* Spacing above message */
}

/* Progress Bar Styles */
.progress-bar {
    width: 100%; /* Full width */
    background-color: #e9ecef; /* Light background */
    border-radius: 5px; /* Rounded edges */
    margin-top: 10px; /* Spacing above bar */
    height: 10px; /* Height of the bar */
    overflow: hidden; /* Hide overflow */
}

.progress {
    height: 100%; /* Full height */
    background-color: #007bff; /* Blue progress */
    width: 0; /* Initial width */
    transition: width 0.3s; /* Smooth width transition */
}

/* Character Count */
.char-count {
    margin-top: 10px; /* Spacing above count */
    color: #333; /* Dark text color */
}

/* History Section */
.history {
    margin-top: 20px; /* Spacing above history */
    background-color: rgba(255, 255, 255, 0.8); /* Light background */
    border-radius: 5px; /* Rounded edges */
    padding: 10px; /* Padding inside */
    overflow-y: auto; /* Allow vertical scrolling */
    max-height: 150px; /* Maximum height */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* Light shadow */
}

/* Voice Description */
.voice-description {
    margin-top: 5px; /* Spacing above description */
    font-size: 12px; /* Smaller font size */
    color: #6c757d; /* Soft gray color */
}

/* Modal Styles */
.modal {
    display: none; /* Initially hidden */
    position: fixed; /* Fixed position */
    z-index: 1; /* Layer on top */
    left: 0; /* Align left */
    top: 0; /* Align top */
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Allow scrolling */
    background-color: rgba(0, 0, 0, 0.4); /* Semi-transparent background */
    padding-top: 60px; /* Padding for top */
}

/* Modal Content */
.modal-content {
    background-color: #fefefe; /* White background */
    margin: 5% auto; /* Center modal */
    padding: 20px; /* Padding inside */
    border: 1px solid #888; /* Border */
    width: 80%; /* Width of modal */
    border-radius: 10px; /* Rounded edges */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); /* Light shadow */
}

/* Close Button */
.close {
    color: #aaa; /* Gray color */
    float: right; /* Float to right */
    font-size: 28px; /* Font size */
    font-weight: bold; /* Bold text */
}

.close:hover,
.close:focus {
    color: black; /* Dark color on hover */
    text-decoration: none; /* Remove underline */
    cursor: pointer; /* Pointer cursor */
}

/* Dark Mode Styles */
.dark-mode {
    background-color: #343a40; /* Dark background */
    color: #f0f4f8; /* Light text */
}

.dark-mode button {
    background-color: #495057; /* Dark button color */
}

.dark-mode .container {
    background: rgba(255, 255, 255, 0.1); /* Semi-transparent for container */
}
