/* ================================
   Forum - Styles
   ================================ */

body {
    font-family: 'Segoe UI', sans-serif;
    background: #0e0e0e;
    color: #fff;
    padding: 20px;
    max-width: 860px;
    margin: auto;
}

h1 {
    text-align: center;
    color: #00ffcc;
    margin-bottom: 1.5rem;
}

/* ---- Inputs & Textarea ---- */
input[type="text"],
input[type="date"],
textarea,
select {
    width: 100%;
    padding: 10px 12px;
    margin-bottom: 10px;
    font-size: 15px;
    background: #1f1f1f;
    border: 1px solid #333;
    border-radius: 6px;
    color: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

input[type="text"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #00ffcc;
}

/* ---- Buttons ---- */
button {
    padding: 10px 20px;
    font-size: 15px;
    background: #00ffcc;
    border: none;
    color: #000;
    cursor: pointer;
    border-radius: 6px;
    font-weight: 600;
    transition: background 0.2s, transform 0.1s;
}

button:hover {
    background: #00e6b8;
}

button:active {
    transform: scale(0.97);
}

button:disabled {
    background: #333;
    color: #777;
    cursor: not-allowed;
}

/* ---- Links ---- */
a {
    text-decoration: none;
    color: #00ffcc;
    font-weight: 600;
}

a:hover {
    text-decoration: underline;
}

/* ---- Search form ---- */
.search-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    align-items: center;
}

.search-bar input,
.search-bar select {
    margin-bottom: 0;
    flex: 1;
    min-width: 140px;
}

.search-bar button {
    flex-shrink: 0;
}

/* ---- Thread list item ---- */
.thread-item {
    background: #1a1a1a;
    margin-bottom: 12px;
    padding: 14px 16px;
    border-left: 4px solid #00ffcc;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
    animation: fadeIn 0.4s ease-in;
}

.thread-item:hover {
    transform: translateX(3px);
    box-shadow: 0 2px 10px rgba(0, 255, 204, 0.25);
}

.thread-item a {
    font-size: 1.05rem;
}

.thread-item .thread-meta {
    margin-top: 6px;
    font-size: 0.8rem;
    color: #888;
}

.thread-item .thread-tags {
    display: inline-block;
    margin-top: 4px;
    font-size: 0.75rem;
    color: #00ffcc;
    background: rgba(0, 255, 204, 0.1);
    padding: 2px 8px;
    border-radius: 20px;
}

/* ---- Pagination ---- */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.pagination a,
.pagination strong {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.9rem;
    background: #1a1a1a;
    border: 1px solid #333;
    color: #fff;
    text-decoration: none;
    transition: background 0.2s, border-color 0.2s;
}

.pagination a:hover {
    background: #2a2a2a;
    border-color: #00ffcc;
    text-decoration: none;
}

.pagination strong {
    background: #00ffcc;
    color: #000;
    border-color: #00ffcc;
}

/* ---- Forum container ---- */
.forum-container {
    max-width: 860px;
    margin: auto;
    padding: 20px;
}

/* ---- Thread posts ---- */
.post {
    background: #1a1a1a;
    padding: 16px;
    border-left: 3px solid #00ffcc;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
    animation: fadeIn 0.4s ease-in;
    margin-bottom: 16px;
}

.post p {
    margin: 0 0 8px;
    line-height: 1.6;
    word-break: break-word;
}

.post .post-meta {
    font-size: 0.8rem;
    color: #888;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.post .post-meta a {
    font-size: 0.8rem;
    color: #cc4444;
    font-weight: 500;
}

.post .post-meta a:hover {
    color: #ff6666;
}

/* ---- Reply form ---- */
.forum-form {
    margin-top: 24px;
    padding: 20px;
    background: #1a1a1a;
    border-radius: 10px;
    border: 1px solid #2a2a2a;
}

.forum-form h2 {
    margin-top: 0;
    color: #00ffcc;
    font-size: 1.1rem;
    margin-bottom: 14px;
}

/* ---- New thread page ---- */
.new-thread-back {
    display: inline-block;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: #888;
}

.new-thread-back:hover {
    color: #00ffcc;
}

/* ---- CTA link (new thread button) ---- */
.cta-link {
    display: inline-block;
    padding: 8px 18px;
    background: #00ffcc;
    color: #000;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    margin-bottom: 20px;
    transition: background 0.2s;
}

.cta-link:hover {
    background: #00e6b8;
    text-decoration: none;
}

/* ---- Empty state ---- */
.empty-state {
    text-align: center;
    color: #555;
    padding: 40px 0;
    font-size: 0.95rem;
}

/* ---- Like button ---- */
.like-btn {
    padding: 4px 12px;
    font-size: 0.82rem;
    background: transparent;
    border: 1px solid #444;
    color: #bbb;
    border-radius: 20px;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.like-btn:hover:not(:disabled) {
    border-color: #e05c8a;
    color: #e05c8a;
}

.like-btn:disabled {
    color: #e05c8a;
    border-color: #e05c8a;
    background: rgba(224, 92, 138, 0.08);
    cursor: default;
}

/* ---- Animations ---- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ---- Responsive ---- */
@media (max-width: 600px) {
    body {
        padding: 12px;
    }

    .search-bar {
        flex-direction: column;
    }

    .search-bar input,
    .search-bar select,
    .search-bar button {
        width: 100%;
    }
}
