/* General Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: #f0f2f5;
    color: #333;
    padding: 20px;
    text-align: center; /* Center all text content */
}

/* Container for centering and setting width */
.container {
    max-width: 1000px; /* Set max width to 1000px */
    margin: 0 auto; /* Center the container */
    text-align: left; /* Text inside the container should align left */
    overflow: hidden; /* Prevent overflow */
}

/* Styling the Form */
form {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin: 20px auto;
}

label {
    font-weight: bold;
    margin-bottom: 10px;
    display: block;
}

input[type="text"],
input[type="file"],
textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

input[type="submit"] {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
}

input[type="submit"]:hover {
    background-color: #45a049;
}

/* Blog Post Styling */
h2 {
    text-align: center;
    color: #4CAF50;
    margin-bottom: 30px;
}

/* Blog Post Styling */
div.post {
    background-color: white;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    max-width: 1000px; /* Set max width for posts to 1000px */
    margin: 20px auto; /* Center the post container */
    text-align: center; /* Center the text inside the post */
    word-wrap: break-word; /* Ensure long words break and wrap */
}

/* Centering the post's content */
div.post h3 {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin-bottom: 15px;
}

div.post p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
    color: #555;
    text-align: justify;
    display: inline-block; /* Ensures it doesn't stretch across the full width */
    width: 100%; /* Adjusts width to container */
}

/* Image Styling */
div.post img {
    max-width: 100%; /* Ensure images are responsive */
    height: auto;
    border-radius: 10px;
    margin: 10px auto; /* Center image horizontally */
    display: block;
}

/* Links (Edit, Delete) */
a {
    text-decoration: none;
    color: #4CAF50;
    font-weight: bold;
    margin-right: 10px;
}

a:hover {
    color: #45a049;
}

/* Responsive Design */
@media only screen and (max-width: 1000px) {
    .container,
    div.post {
        width: 100%; /* Allow full width on smaller screens */
        padding: 10px;
        box-shadow: none; /* Remove shadow for mobile */
    }

    input[type="submit"] {
        width: 100%;
    }

    /* Adjust headings for smaller screens */
    div.post h3 {
        font-size: 20px; /* Smaller heading size */
    }

    div.post p {
        font-size: 14px; /* Adjust font size for paragraphs */
    }
}

/* Login Form Styling */
.login-container {
    max-width: 400px; /* Set max width of the form */
    margin: 50px auto; /* Center the form horizontally */
    padding: 20px;
    background-color: #ffffff; /* White background */
    border-radius: 10px; /* Rounded corners */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* Soft shadow for a modern look */
}

.login-container h2 {
    text-align: center;
    color: #4CAF50; /* Consistent green color */
    margin-bottom: 20px;
    font-size: 24px;
}

.login-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.login-container input[type="text"],
.login-container input[type="password"] {
    width: 100%; /* Full width for input fields */
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
}

.login-container input[type="submit"] {
    width: 100%;
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.login-container input[type="submit"]:hover {
    background-color: #45a049;
}

.login-container p.error {
    color: red;
    text-align: center;
    font-weight: bold;
}

/* Ensure no conflicts with other forms */
form.login-form input[type="text"],
form.login-form input[type="password"],
form.login-form input[type="submit"] {
    font-family: Arial, sans-serif;
}

/* General List Styles */
ul,
ol {
    margin-left: 20px; /* Indent lists */
    padding-left: 20px; /* Additional padding */
}

/* List Items */
ul li,
ol li {
    margin-bottom: 10px; /* Space between list items */
    line-height: 1.5; /* Improve readability */
}
