/* public/css/style.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700&display=swap');

body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f7f6;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 960px;
    margin: 20px auto;
    padding: 0 20px;
}

header {
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border-radius: 8px;
    margin-bottom: 20px;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 a {
    color: #ecf0f1;
    text-decoration: none;
    font-size: 1.8rem;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: #ecf0f1;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: #3498db;
}

.flash-messages {
    margin-bottom: 20px;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
}

.flash-messages .success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.flash-messages .error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

.btn {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #2980b9;
}

.btn-danger {
    background-color: #e74c3c;
}

.btn-danger:hover {
    background-color: #c0392b;
}

.card {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 20px;
}

.card-header {
    font-size: 1.5rem;
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.post-list .post-item {
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.post-list .post-item h2 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.4rem;
}

.post-list .post-item h2 a {
    text-decoration: none;
    color: #2c3e50;
}

.post-list .post-item h2 a:hover {
    color: #3498db;
}

.post-meta {
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 10px;
}

.post-content {
    margin-top: 15px;
    white-space: pre-wrap; /* Preserves whitespace and line breaks */
}

footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    color: #777;
    font-size: 0.9rem;
    border-top: 1px solid #eee;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        text-align: center;
    }
    nav ul {
        margin-top: 10px;
        justify-content: center;
    }
    nav ul li {
        margin: 0 10px;
    }
}
