body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    box-sizing: border-box;
}

li {
    margin: 0.7em 0;
}

img {
    max-width: 100%;
}

a {
    text-decoration: none;
    color: black;
    font-weight: bold;
}

a:hover {
    text-decoration: underline;
}

/* Label for fields */
.label {
  font-weight: bold; 
  display: inline-block; 
  width: 150px;
}

/* Tags */

.tag {
    font-size: .8em; 
    font-weight: normal; 
    background: #ddd; 
    padding: 0 4px; 
    margin: 2px; 
    border-radius: 4px;
    color: black;
    text-decoration: none;
}

.selected {
    background: #aaa;
    border: 1px solid black;
}

a.tag:hover {
    background: #aaa;
}

.showAllButton {
    background-color: #888; 
    color: white; 
    font-size: .8em; 
    font-weight: normal; 
    padding: 2px 4px; 
    border-radius: 4px;
}

/* Top Banner */
.banner {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 100;
}

.banner h1 {
    font-size: 1.8rem;
    font-weight: 600;
}

.banner-user {
    font-size: .4em; 
    font-weight: normal; 
    color: white; 
    float: right; 
    display: inline;
}

.banner-logout {
    background-color: #444;
    padding: 0 4px;
    border-radius: 4px;
    color: white;
    text-decoration: none;
}

/* Main Container */
.main-container {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* Left Sidebar Menu */
.sidebar {
    width: 250px;
    background: #2c3e50;
    color: white;
    padding: 2rem 0;
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
}

.sidebar nav {
    display: flex;
    flex-direction: column;
}

.sidebar a {
    color: white;
    text-decoration: none;
    padding: 1rem 2rem;
    transition: background 0.3s ease;
    font-size: 1.1rem;
    border-left: 4px solid transparent;
}

.sidebar a:hover {
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #667eea;
}

.sidebar a.active {
    background: rgba(255, 255, 255, 0.15);
    border-left-color: #667eea;
    font-weight: 600;
}

.sidebar-section {
    color: #667eea; 
    font-size: .8em; 
    font-weight: bold; 
    padding-left: 3em; 
    padding-top: 24px; 
    border-top: 1px solid #667eea;
}

/* Content Area */
.content {
    flex: 1;
    padding: 2rem;
    background: #f5f7fa;
    overflow-y: auto;
}

.content h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

/* Rendered markdown area */
.page_content {
    margin-top: 20px;
}

/* Edit button */
.edit-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.edit-button:hover {
    background: #5568d3;
}

.edit-button svg {
    width: 18px;
    height: 18px;
}

/* Edit form */
.edit-textarea {
    width: 100%;
    min-height: 500px;
    padding: 1rem;
    border: 1px solid #ccc;
    border-radius: 1em;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', monospace;
    font-size: 0.9rem;
    resize: vertical;
    margin-bottom: 1rem;
}

/* General button */
.button {
    padding: 0.5rem 1rem;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.save-button {
    padding: 0.75rem 1.5rem;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s ease;
}

.save-button:hover {
    background: #5568d3;
}

.cancel-button {
    padding: 0.75rem 1.5rem;
    background: #95a5a6;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 1rem;
    transition: background 0.3s ease;
    display: inline-block;
}

.cancel-button:hover {
    background: #7f8c8d;
}

.edit-info {  /* for messages at bottom, currently not used */
    padding: 1rem;
    background: #e8f4f8;
    border-left: 4px solid #3498db;
    border-radius: 4px;
    color: #2c3e50;
}

.edit-info p {
    margin: 0;
}

