/* ==== RESET ==== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ==== BASE ==== */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding: 2rem;
    transition: background 0.3s, color 0.3s;
}

body.dark {
    background: linear-gradient(to right, #0f0c29, #302b63, #24243e);
    color: #ffffff;
}

body.light {
    background: #f5f5f5;
    color: #222;
}

/* ==== HEADER ==== */
.header {
    text-align: center;
    margin-bottom: 2rem;
}

.header h1 {
    margin-bottom: 0.5rem;
    color: #6dd5ed;
}

#project-count {
    font-size: 1.1rem;
    color: #6dd5ed;
}

/* ==== ACTIONS (buttons, search, logout) ==== */
.actions {
    margin: 1rem 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.actions input {
    width: auto;
    padding: 5px 10px;
}

/* ==== FORM & PROJECT BOX ==== */
form,
.project {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 1rem;
    margin: 1rem auto;
    max-width: 600px;
    box-shadow: 0 0 10px rgba(109, 213, 237, 0.3);
}

input,
textarea {
    width: 100%;
    padding: 8px;
    margin-top: 8px;
    border-radius: 5px;
    border: none;
    background-color: #1e1e2f;
    color: white;
}

input[type="file"] {
    background-color: transparent;
    color: white;
    border: none;
}

input:focus,
textarea:focus {
    outline: 2px solid #6dd5ed;
}

button {
    margin-top: 10px;
    padding: 10px 20px;
    background: linear-gradient(to right, #2575fc, #6a11cb);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-weight: bold;
}

/* ==== PROJECT DISPLAY ==== */
.project img {
    max-width: 100%;
    border-radius: 8px;
    margin-bottom: 10px;
}

.badge,
.category {
    display: inline-block;
    background: #6dd5ed;
    color: #000;
    border-radius: 12px;
    padding: 4px 8px;
    margin-right: 5px;
    font-size: 0.8rem;
}

.project a {
    color: #6dd5ed;
    text-decoration: none;
    font-weight: bold;
}

.project a:hover {
    text-decoration: underline;
}

.highlight {
    border-left: 4px solid gold;
    box-shadow: 0 0 10px gold;
}

/* ==== COMMENT PREVIEW ==== */
.comment-box {
    position: relative;
    margin-top: 1rem;
}

.comment-preview {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
    max-height: 4.5em;
}

.comment-preview.expanded {
    -webkit-line-clamp: unset;
    max-height: none;
}

.toggle-btn {
    background: none;
    border: none;
    color: #6dd5ed
