.forum-container {
    max-width: 1400px;
    width: 100%;
    margin: -10rem auto 2rem auto;
    padding: 0 2rem 2rem 2rem;
    position: relative;
    z-index: 2;
}

.admin-panel {
    margin-bottom: 2rem;
    text-align: right;
}

.btn-create-post {
    background: linear-gradient(135deg, #7896b4 0%, #5a7590 100%);
    color: #ffffff;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-create-post:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(120, 150, 180, 0.4);
}

.btn-create-post i {
    margin-right: 0.5rem;
}

.alert-success,
.alert-error {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 500;
}

.alert-success {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid #28a745;
    color: #5cb85c;
}

.alert-error {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid #dc3545;
    color: #ff6b6b;
}

.forum-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 2.5rem;
    max-width: none;
    width: 100%;
}

.forum-sidebar {
    background: rgba(10, 15, 25, 0.7);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    height: fit-content;
    position: sticky;
    top: 100px;
    backdrop-filter: blur(10px);
}

.forum-sidebar h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.25rem;
    color: #ffffff;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li {
    margin-bottom: 0.5rem;
}

.category-list li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(120, 150, 180, 0.2);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.category-list li a i {
    margin-right: 0.5rem;
    color: #7896b4;
}

.category-list li a:hover {
    background: rgba(120, 150, 180, 0.1);
    border-color: #7896b4;
    color: #ffffff;
    transform: translateX(5px);
}

.category-list li.active a {
    background: rgba(120, 150, 180, 0.2);
    border-color: #7896b4;
    color: #ffffff;
}

.category-list li.active a i {
    color: #ffffff;
}

.post-count {
    background: rgba(120, 150, 180, 0.2);
    color: #ffffff;
    padding: 0.25rem 0.65rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.category-list li.active .post-count {
    background: rgba(120, 150, 180, 0.3);
    color: #ffffff;
}

.forum-content {
    min-height: 400px;
}

.no-posts {
    background: rgba(10, 15, 25, 0.7);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-radius: 12px;
    padding: 4rem 2rem;
    text-align: center;
    backdrop-filter: blur(10px);
}

.no-posts i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.3);
    margin-bottom: 1rem;
}

.no-posts h3 {
    font-family: 'Cinzel', serif;
    font-size: 1.75rem;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.no-posts p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
}

/* Post Tabs */
.post-tabs-container {
    position: relative;
    margin: 0 1rem;
}

.post-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    border-bottom: 2px solid rgba(120, 150, 180, 0.3);
    padding-bottom: 0;
    padding-left: 0.5rem;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.post-tabs::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.tab-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(10, 15, 25, 0.9);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7896b4;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    backdrop-filter: blur(10px);
}

.tab-nav:hover {
    background: rgba(120, 150, 180, 0.3);
    border-color: #7896b4;
    color: #ffffff;
    transform: translateY(-50%) scale(1.1);
}

.tab-nav-left {
    left: -15px;
}

.tab-nav-right {
    right: -15px;
}

.post-tab {
    background: rgba(10, 15, 25, 0.9);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-bottom: none;
    border-radius: 12px 12px 0 0;
    padding: 0.75rem 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Cinzel', serif;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    bottom: -2px;
    backdrop-filter: blur(10px);
    white-space: nowrap;
    flex-shrink: 0;
}

.post-tab:hover {
    background: rgba(10, 15, 25, 1);
    color: #ffffff;
    border-color: #7896b4;
    transform: translateY(-2px);
}

.post-tab.active {
    background: rgba(10, 15, 25, 1);
    border-color: #7896b4;
    border-bottom-color: rgba(10, 15, 25, 1);
    color: #ffffff;
    font-weight: bold;
    z-index: 1;
}

.posts-container {
    position: relative;
    margin: 0 1rem;
}

.post-content-wrapper {
    display: none;
}

.post-content-wrapper.active {
    display: block;
    animation: slideIn 0.4s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.posts-grid {
    display: grid;
    gap: 1.5rem;
}

.forum-post {
    background: rgba(10, 15, 25, 0.7);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-radius: 12px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.forum-post:hover {
    border-color: #7896b4;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(120, 150, 180, 0.2);
}

.post-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.post-category {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.post-category[data-category="Systems"] {
    background: rgba(100, 149, 237, 0.2);
    border: 1px solid rgba(100, 149, 237, 0.4);
    color: #6495ED;
}

.post-category[data-category="Updates"] {
    background: rgba(46, 204, 113, 0.2);
    border: 1px solid rgba(46, 204, 113, 0.4);
    color: #2ecc71;
}

.post-category[data-category="Events"] {
    background: rgba(155, 89, 182, 0.2);
    border: 1px solid rgba(155, 89, 182, 0.4);
    color: #9b59b6;
}

.post-category[data-category="Announcements"] {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: #e74c3c;
}

.post-category[data-category="Rules"] {
    background: rgba(241, 196, 15, 0.2);
    border: 1px solid rgba(241, 196, 15, 0.4);
    color: #f1c40f;
}

.post-category[data-category="Guides"] {
    background: rgba(52, 152, 219, 0.2);
    border: 1px solid rgba(52, 152, 219, 0.4);
    color: #3498db;
}

.post-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.btn-edit {
    background: rgba(120, 150, 180, 0.2);
    border: 1px solid rgba(120, 150, 180, 0.4);
    color: #7896b4;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.btn-edit:hover {
    background: rgba(120, 150, 180, 0.3);
    transform: scale(1.1);
}

.btn-delete {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #dc3545;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.btn-delete:hover {
    background: rgba(220, 53, 69, 0.3);
    transform: scale(1.1);
}

.post-title {
    font-family: 'Cinzel', serif;
    font-size: 1.75rem;
    color: #ffffff;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.post-separator {
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.3) 20%, 
        rgba(255, 255, 255, 0.6) 50%, 
        rgba(255, 255, 255, 0.3) 80%, 
        transparent 100%
    );
    margin: 1rem 0 1.5rem 0;
    box-shadow: 0 1px 3px rgba(255, 255, 255, 0.1);
}

.post-content {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.8;
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.post-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid rgba(120, 150, 180, 0.2);
}

.post-author,
.post-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.post-author i {
    color: #7896b4;
}

.post-date i {
    color: #7896b4;
}

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-content {
    background: linear-gradient(135deg, rgba(10, 15, 25, 0.98) 0%, rgba(20, 30, 50, 0.98) 100%);
    border: 2px solid rgba(120, 150, 180, 0.4);
    border-radius: 12px;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid rgba(120, 150, 180, 0.3);
}

.modal-header h2 {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem;
    color: #ffffff;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-close {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #dc3545;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.btn-close:hover {
    background: rgba(220, 53, 69, 0.4);
    transform: rotate(90deg);
}

.modal-content form {
    padding: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: #ffffff;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-group label i {
    color: #7896b4;
}

.form-control {
    width: 100%;
    padding: 0.85rem 1rem;
    background: rgba(0, 0, 0, 0.4);
    border: 2px solid rgba(120, 150, 180, 0.3);
    border-radius: 6px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #7896b4;
    background: rgba(0, 0, 0, 0.6);
}

.form-control option {
    background: #1a1a1a;
    color: #ffffff;
}

textarea.form-control {
    resize: vertical;
    min-height: 200px;
    font-family: inherit;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
}

.btn-cancel,
.btn-submit {
    padding: 0.85rem 2rem;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-cancel {
    background: rgba(120, 150, 180, 0.2);
    border: 1px solid rgba(120, 150, 180, 0.4);
    color: #7896b4;
}

.btn-cancel:hover {
    background: rgba(120, 150, 180, 0.3);
}

.btn-submit {
    background: linear-gradient(135deg, #7896b4 0%, #5a7590 100%);
    color: #ffffff;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(120, 150, 180, 0.4);
}

.btn-submit i {
    margin-right: 0.5rem;
}

@media (max-width: 1024px) {
    .forum-layout {
        grid-template-columns: 1fr;
    }

    .forum-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .forum-container {
        margin-top: -2rem;
        padding: 0 1rem 2rem 1rem;
    }

    .hero-title {
        font-size: 2rem !important;
    }

    .forum-post {
        padding: 1.5rem;
    }

    .post-title {
        font-size: 1.35rem;
    }

    .post-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .modal-content {
        width: 95%;
    }

    .modal-content form {
        padding: 1.5rem;
    }

    .modal-actions {
        flex-direction: column;
    }

    .btn-cancel,
    .btn-submit {
        width: 100%;
    }
}

/* Quill Editor Dark Theme */
.ql-toolbar.ql-snow {
    background: rgba(10, 15, 25, 0.9) !important;
    border: 2px solid rgba(120, 150, 180, 0.3) !important;
    border-bottom: 1px solid rgba(120, 150, 180, 0.3) !important;
    border-radius: 8px 8px 0 0 !important;
}

.ql-container.ql-snow {
    background: rgba(26, 26, 46, 0.9) !important;
    border: 2px solid rgba(120, 150, 180, 0.3) !important;
    border-top: none !important;
    border-radius: 0 0 8px 8px !important;
}

.ql-editor {
    color: #ffffff !important;
    font-size: 1rem !important;
    line-height: 1.6 !important;
}

.ql-editor.ql-blank::before {
    color: rgba(255, 255, 255, 0.5) !important;
}

.ql-snow .ql-stroke {
    stroke: #ffffff !important;
}

.ql-snow .ql-fill {
    fill: #ffffff !important;
}

.ql-snow .ql-picker-label {
    color: #ffffff !important;
}

.ql-snow .ql-picker-options {
    background: rgba(10, 15, 25, 0.95) !important;
    border: 1px solid rgba(120, 150, 180, 0.3) !important;
}

.ql-snow .ql-picker-item {
    color: #ffffff !important;
}

.ql-snow .ql-picker-item:hover {
    background: rgba(120, 150, 180, 0.2) !important;
}

.ql-toolbar.ql-snow button:hover,
.ql-toolbar.ql-snow button:focus {
    background: rgba(120, 150, 180, 0.2) !important;
}

.ql-toolbar.ql-snow button.ql-active {
    background: rgba(120, 150, 180, 0.3) !important;
}

.ql-snow.ql-toolbar button:hover .ql-stroke,
.ql-snow .ql-toolbar button:hover .ql-stroke,
.ql-snow.ql-toolbar button.ql-active .ql-stroke,
.ql-snow .ql-toolbar button.ql-active .ql-stroke {
    stroke: #7896b4 !important;
}

.ql-snow.ql-toolbar button:hover .ql-fill,
.ql-snow .ql-toolbar button:hover .ql-fill,
.ql-snow.ql-toolbar button.ql-active .ql-fill,
.ql-snow .ql-toolbar button.ql-active .ql-fill {
    fill: #7896b4 !important;
}

#editor-container {
    min-height: 300px;
}

