/* ########################################### */
/*                 Global                      */
/* ########################################### */

/* ===== ANIMATION VARIABLES ===== */
:root {
  --primary-color: #6a11cb;  /* Rich purple */
  --primary-light: #7b2cbf;
  --primary-dark: #370355;
  --secondary-color: #bc6ff1;
  --accent-color: #2575fc;   /* Bright blue */
  
  --bg-color: #f9f9f9;
  --card-bg: #ffffff;
  --border-color: #e0e0e0;
  
  --text-primary: #333333;
  --text-secondary: #666666;
  --text-light: #999999;
  
  --anim-duration-fast: 0.2s;
  --anim-duration-medium: 0.4s;
  --anim-duration-slow: 0.8s;
  
  /* Original variables - keep for compatibility */
  --background-dark: #0a0a0f;
  --background-light: #1a1c1d;
  --text-muted: #a0a0a0;
  --success-color: #388e3c;
  --warning-color: #ff8f00;
  --error-color: #d32f2f;
  --info-color: #0288d1;
  --animation-slow: var(--anim-duration-slow);
  --animation-medium: var(--anim-duration-medium);
  --animation-fast: var(--anim-duration-fast);
  --animation-very-fast: 0.2s;
  --folder-color: #6a11cb;   /* Same as primary purple */
  --folder-hover-color: #8732e5; /* Lighter purple for hover */
  --button-gradient: linear-gradient(45deg, #6a11cb, #2575fc);
  --button-hover-gradient: linear-gradient(45deg, #2575fc, #6a11cb);
  --button-bg: #6a11cb;
  --animation-slow: 1.5s;
  --animation-medium: 0.8s;
  --animation-fast: 0.4s;
  --anim-duration-slow: 1.5s;
  --anim-duration-medium: 0.8s;
  --anim-duration-fast: 0.4s;
}

*{
    box-sizing: border-box;
}

html{
    font-size: 14px;
    font-family: 'Titillium Web', sans-serif;
    background-color: var(--background-dark);
    color: var(--text-light);
}

body {
    animation: fadeIn var(--anim-duration-medium) ease-in-out;
}

a{
    color: var(--accent-color);
    font-weight: bolder;
    text-decoration: none;
    transition: color var(--animation-very-fast) ease;
    position: relative;
}

a:hover {
    color: var(--primary-light);
}

/* Removing link underline effect */
a::after {
    /*
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--primary-light);
    transition: width var(--anim-duration-fast) ease;
    */
    content: none; /* Disabling the underline effect */
}

a:hover::after {
    /*
    width: 100%;
    */
    width: 0; /* Ensuring no width on hover */
}

h1, h2, h3, h4, h5, h6 {
    position: relative;
}

/* Removing underline effect */
h1::after, h2::after, h3::after {
    /* 
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    height: 3px;
    width: 0;
    background-color: var(--primary-color);
    transition: width var(--anim-duration-medium) ease;
    */
    content: none; /* Disabling the underline effect */
}

h1:hover::after, h2:hover::after, h3:hover::after {
    /*
    width: 50px;
    animation: lineExpand var(--anim-duration-medium) ease;
    */
    width: 0; /* Ensuring no width on hover */
}

/* Button animations */
.btn, button[type="submit"], input[type="submit"] {
    transition: all var(--anim-duration-fast) ease;
    position: relative;
    overflow: hidden;
}

.btn:hover, button[type="submit"]:hover, input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn::after, button[type="submit"]::after, input[type="submit"]::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
}

.btn:active::after, button[type="submit"]:active::after, input[type="submit"]:active::after {
    animation: ripple var(--anim-duration-medium) ease-out;
}

/* Form element animations */
input, textarea, select {
    transition: border-color var(--anim-duration-fast) ease, box-shadow var(--anim-duration-fast) ease;
}

input:focus, textarea:focus, select:focus {
    animation: glow var(--anim-duration-slow) ease-out;
}

/* Navigation animations */
.navbar {
    transition: background-color var(--anim-duration-medium) ease;
}

.nav-item {
    transition: transform var(--anim-duration-fast) ease;
}

.nav-item:hover {
    transform: translateY(-2px);
}

/* List item animations */
.post-list-item, .thread-list-item {
    transition: transform var(--anim-duration-fast) ease, box-shadow var(--anim-duration-fast) ease;
    animation: fadeInUp var(--anim-duration-medium) ease-out;
    animation-fill-mode: both;
}

.post-list-item:hover, .thread-list-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

/* Staggered animations for lists */
.post-list-item:nth-child(1), .thread-list-item:nth-child(1) { animation-delay: 0.1s; }
.post-list-item:nth-child(2), .thread-list-item:nth-child(2) { animation-delay: 0.2s; }
.post-list-item:nth-child(3), .thread-list-item:nth-child(3) { animation-delay: 0.3s; }
.post-list-item:nth-child(4), .thread-list-item:nth-child(4) { animation-delay: 0.4s; }
.post-list-item:nth-child(5), .thread-list-item:nth-child(5) { animation-delay: 0.5s; }

/* Modal animations */
.modal {
    animation: fadeIn var(--anim-duration-fast) ease-out;
}

.modal-content {
    animation: fadeInUp var(--anim-duration-medium) ease-out;
}

/* Like button animation */
.like-btn, .heart-btn {
    transition: all var(--anim-duration-fast) ease;
}

.like-btn:hover, .heart-btn:hover {
    transform: scale(1.1);
}

.like-btn.active, .heart-btn.active {
    animation: heartPulse var(--anim-duration-slow) ease;
}

/* Loading spinner animation */
.spinner, .loader {
    animation: spin var(--anim-duration-medium) linear infinite;
}

/* Notification animations */
.notification {
    animation: slideInRight var(--anim-duration-medium) ease-out;
}

/* Toast animations */
.toast {
    animation: slideInUp var(--anim-duration-medium) ease-out;
}

html, body {
    height: 100%;
    margin: 0;
    display: flex;
    flex-direction: column;
}

body {
    flex: 1;
    display: flex;
    flex-direction: column;
    animation: fadeIn var(--anim-duration-medium) ease-in-out;
}

footer {
    background-color: #f1f1f1;
    text-align: center;
    padding: 10px;
    margin-top: auto;
}



/* ########################################### */
/*           Forums.html                       */
/* ########################################### */
.container{
    margin: 20px;
    padding: 20px;
}

.subforum{
    margin-top:20px;
}

.subforum-title{
    background-color:#292B2E;
    padding: 5px;
    border-radius: 5px;
    margin:4px;
}

.subforum-row{
    display: grid;
    grid-template-columns: 7% 60% 13% 20%;
}

.subforum-column{
    padding: 10px;
    margin:4px;
    border-radius: 5px;
    background-color:#111314;
}

.subforum-description *{
    margin-block: 0;
}

.center{
    display: flex;
    justify-content: center;
    align-items: center;
}

.subforum-icon i{
    font-size: 45px;
}

.subforum-devider{
    display: none;   
}


/* For the smartphones */
@media screen and (max-width: 460px) {
    .container{
        margin: 10px;
        padding: 10px;
    }

    .subforum-row{
        display: grid;
        grid-template-columns: 25% 75%;
        grid-template-rows: 65% 35%;
    }

    .subforum-devider{
        display: block;
        border: 0;
        height: 1px;
        background-image: linear-gradient(to right, rgba(190, 190, 190, 0), rgba(255, 255, 255, 0.75), rgba(190, 190, 190, 0));
    }
}

/* For the tablets */
@media screen and (min-width: 460px) and (max-width: 1024px) {
    .container{
        margin: 15px;
        padding: 15px;
    }

    .subforum-row{
        display: grid;
        grid-template-columns: 10% 60% 10% 20%;
    }

    .subforum-icon i{
        font-size: 35px;
    }

    html{
        font-size: 14px;
    }

    h1{
        font-size: 16px;
    }
}

/*   Header Section    */
header{
    margin-inline: 10px;
}

/* Nav Bar styles */
.navbar{
    display:flex;
    align-items: center;
}
.navigation{
    background-color: var(--dark-bg);
    padding: 10px;
    width: 65%;
    display: inline-block;
    border-radius: 5px;
    max-height: 80px;
    margin-right:10px;
    transition: transform 0.3s ease-in-out;
    border: 1px solid rgba(0, 255, 157, 0.1);
}

.navigation.hide {
    transform: translateX(-100%);
}

.close-icon i{
    font-size:60px;
    float: left;
    cursor: pointer;
}

.nav-list{
    list-style-type:none;
    overflow: hidden;
}

.nav-item a,
.login-link a,
.logout-link a {
    float: right;
    display:block;
    text-align: center;
    margin-inline: 20px;
    font-size: 20px;
    padding: 10px;
    color:#fff;
    transition: all 0.3s ease;
}

.nav-item a:hover,
.login-link a:hover,
.logout-link a:hover {
    background-color: rgb(0,0,0,0.1);
}

.hide{
    display: none !important;
}

.bar-icon{
    font-size: 60px;
    display: inline-block;
    margin-right:10px;
    color: #fff;
    cursor: pointer;
    transition: color 0.3s ease;
}

.bar-icon:hover {
    color: #FF0042;
}

@font-face {
    font-family: aquire;
    src: url(aquire.otf);
}

/* Brand styling with purple color */
.brand {
    font-size: 60px;
    display: inline-block;
    font-family: aquire;
    color: var(--primary-color);
    text-shadow: 0 0 10px rgba(106, 17, 203, 0.3);
    transition: all 0.3s ease;
}

.brand:hover {
    color: var(--accent-color);
    text-shadow: 0 0 15px rgba(37, 117, 252, 0.5);
}

/* Navbar for the smartphones*/
@media screen and (max-width: 460px){
    .navigation{
        max-height: auto;
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 250px;
        background: var(--primary-color);
        padding: 2rem;
        z-index: 1000;
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
    }
    
    .navigation:not(.hide) {
        transform: translateX(0);
    }
    
    .close-icon i{
        font-size:30px;
    }
    
    .nav-item a,
    .login-link a,
    .logout-link a {
        float: left;
        display: inline;
        margin-inline: 3px;
        font-size: 10px;
        padding: 5px;
    }
    
    .bar-icon{
        font-size: 30px;
    }
 
    .brand{
        font-size:20px;
    }
}

/* Search Box styles */
.search-box{
    border: solid 1px #52057b;
    margin-top: 20px;
    padding: 40px;
    display:flex;
    justify-content: center;
    box-shadow:1px 2px 3px #52057b;
}

.search-box select{
    padding: 10px;
}

.search-box input{
    padding: 10px;
}

.search-box button{
    padding: 10px;
    background-color:#fff;
    color:#000000;
}

.search-box button:hover{
    background-color: #000000;
    color: #fff;
    box-shadow: 1px 2px 3px #fff;
}

/* search box for smartphones */
@media screen and (max-width: 460px){
    .search-box input, .search-box button, .search-box select{
        min-width: 300px;
        margin-top: 5px;
    }    
}

/* forum info Styling */
.forum-info{
    padding: 20px;
    background-color: #111314;
}

.chart{
    font-size:20px;
    font-weight:bold;
}

/* Footer Styling */
footer{
    margin-top: 20px;
    padding: 20px;
    background-color:  #52057b;
    display: block;
    text-align: center;
}

/* ########################################### */
/*            detail.html                      */
/* ########################################### */
.head{
    display: flex;
    background-color: #2C2C2C;
    padding: 5px;
    font-weight: bold;
    font-size: 15px;
}

.authors{
    flex: 20%;
}

.content{
    flex: 80%;
}

.body{
    display: flex;
    background-color: #131415;
    padding: 10px;
    margin-top: 5px;
}

.body .authors .username{
    font-size: 20px;
}

.body .authors img{
    max-width: 50px;
    max-height: 80px;
}

.body .content .comment button{
    border:none;
    padding:10px;
    font-weight: bolder;
    box-shadow: 4px 6px #fff;
    cursor: pointer;
    float: right;
}

/* comment section */
.comment-area{
    margin-bottom:50px;
}

.comment-area textarea{
    width: 100%;
    min-height: 100px;
    padding: 10px;
    margin-block: 10px;
}

.comment-area input{
    float: right;
    padding: 10px;
    border-radius: 10px;
    cursor: pointer;
}

.comment-area input:hover{
    border: solid 1px #000000;
}

/* ########################################### */
/*                 Popup Styles                */
/* ########################################### */
.popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    background-color: #111314;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0px 0px 10px #52057b;
    text-align: center;
    z-index: 1000;
}

.popup-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.popup input {
    width: 100%;
    padding: 10px;
    margin: 5px 0;
    background: #222;
    color: white;
    border: none;
    border-radius: 5px;
}

.popup button {
    padding: 10px;
    background-color: #52057b;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

.popup button:hover {
    background-color: #6a359c;
}

.popup p {
    color: white;
    font-size: 14px;
}

.popup a {
    color: #FF0042;
    cursor: pointer;
}

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

.success-popup {
    background-color: #28a745;
    color: white;
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0px 0px 10px #28a745;
    z-index: 1000;
}

.error-popup {
    background-color: #dc3545;
    color: white;
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0px 0px 10px #dc3545;
    z-index: 1000;
}

/* Top Right Username with Avatar */
.top-right-username {
    position: absolute;
    top: 10px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: bold;
    font-size: 16px;
    color: #fff;
    background-color: #52057b;
    padding: 5px 15px;
    border-radius: 25px;
    transition: all 0.3s ease;
}

.top-right-username:hover {
    background-color: #6a359c;
}

.user-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #52057b;
    text-transform: uppercase;
}

/* Enhanced Navbar Animation */
.navigation {
    background-color: var(--dark-bg);
    padding: 10px;
    width: 65%;
    border-radius: 5px;
    max-height: 80px;
    margin-right: 10px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: left;
    border: 1px solid rgba(0, 255, 157, 0.1);
}

.navigation.hide {
    transform: translateX(-100%);
    opacity: 0;
}

/* Mobile Navigation */
@media screen and (max-width: 460px) {
    .navigation {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 250px;
        background: var(--primary-color);
        padding: 2rem;
        z-index: 1000;
        transform: translateX(-100%);
        opacity: 1;
    }

    .navigation:not(.hide) {
        transform: translateX(0);
        box-shadow: 2px 0 10px rgba(0,0,0,0.3);
    }

    .top-right-username {
        top: 5px;
        right: 10px;
        font-size: 14px;
        padding: 3px 10px;
    }

    .user-avatar {
        width: 25px;
        height: 25px;
        font-size: 14px;
    }
}

#create-thread-section {
    width: 100%;
    text-align: center;
    margin: 20px 0;
    padding: 20px;
    background: #111314; /* Match the forum theme */
    border-top: 2px solid #007BFF;
    border-bottom: 2px solid #007BFF;
}

.create-thread-btn {
    padding: 12px 20px;
    font-size: 18px;
    background-color: #222;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    width: 90%;
    max-width: 1000px;
    margin: 10px auto;
    display: block ;
}

#thread-box {
    width: 100%;
    padding: 20px;
    background: #222;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

#thread-box textarea {
    width: 100%;
    max-width: 10000px;
    height: 150px; /* Same height for both title & content */
    padding: 10px;
    background: #333;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    resize: none; /* Prevent resizing to keep consistency */
}

#thread-box button {
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    width: 90%;
    max-width: 400px;
}

#thread-box button:first-of-type {
    background-color: #28a745;
    color: white;
    border: none;
}

#thread-box button:first-of-type:hover {
    background-color: #218838;
}

#thread-box button:last-of-type {
    background-color: #dc3545;
    color: white;
    border: none;
}

#thread-box button:last-of-type:hover {
    background-color: #c82333;
}

/* ########################################### */
/*            Categories.html                  */
/* ########################################### */
#add-category-box {
    text-align: center;
    margin: 20px auto;
    padding: 15px;
    background: #222;
    border-radius: 5px;
    width: 50%;
    display: none; /* Initially hidden */
}

#category-name {
    width: 80%;
    padding: 10px;
    background: #333;
    color: white;
    border: none;
    border-radius: 5px;
}

#add-category-box button {
    padding: 10px;
    margin-top: 10px;
    background-color: #28a745;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

#add-category-box button:hover {
    background-color: #218838;
}

/* Category list*/
#categories-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
    padding: 20px;
}

.category-item {
    background: #222;
    padding: 15px;
    border-radius: 10px;
    color: white;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    width: 200px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.category-item:hover {
    transform: scale(1.05);
    box-shadow: 0px 6px 15px rgba(0, 0, 0, 0.3);
}
/*delete category*/
.delete-category-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 5px 10px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    margin-left: 10px;
    transition: background 0.3s ease-in-out;
}

.delete-category-btn:hover {
    background: #c82333;
}

/* ########################################### */
/*            Thread Creation Form             */
/* ########################################### */
/* Add this CSS to ensure the buttons are below the text areas */
#create-thread-section {
    width: 100%;
    text-align: center;
    margin: 20px 0;
    padding: 20px;
    background: #111314; /* Match the forum theme */
    border-top: 2px solid #007BFF;
    border-bottom: 2px solid #007BFF;
}

.thread-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

#thread-title,
#thread-content {
    width: 80%;
    padding: 10px;
    background: #333;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    resize: none; /* Prevent resizing to keep consistency */
}

#thread-title {
    height: 50px; /* Adjust height for the title */
}

#thread-content {
    height: 150px; /* Adjust height for the content */
}

/* Add this CSS to ensure the buttons are centered */
.thread-buttons {
    display: flex;
    flex-direction: column; /* Stack buttons vertically */
    align-items: center; /* Center buttons horizontally */
    gap: 10px;
    justify-content: center;
    width: 100%;
    margin-top: 10px; /* Add margin to separate buttons from content */
}

.thread-buttons button {
    padding: 10px 15px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
    border: none;
    width: 100%;
    max-width: 200px;
}

.thread-buttons button:first-of-type {
    background-color: #28a745 !important;
    color: white;
}

.thread-buttons button:first-of-type:hover {
    background-color: #218838;
}

.thread-buttons button:last-of-type {
    background-color: #dc3545 !important;
    color: white;
}

.thread-buttons button:last-of-type:hover {
    background-color: #c82333;
}

/* Thread Display Styles */
.threads-section {
    margin: 30px auto;
    width: 90%;
    max-width: 1200px;
}

.threads-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Cải thiện hiển thị của thread item */
.thread-item {
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    background: var(--card-bg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.thread-title {
    margin: 0 0 10px;
    font-size: 1.5rem;
    color: var(--text-primary);
    font-weight: 600;
}

.thread-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.thread-meta span {
    display: flex;
    align-items: center;
}

.thread-meta i {
    margin-right: 5px;
    opacity: 0.7;
}

.thread-content {
    margin-bottom: 15px;
    line-height: 1.6;
    color: var(--text-secondary);
}

.thread-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.thread-link {
    padding: 8px 15px;
    background: var(--primary-color);
    color: white;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.thread-link:hover {
    background: var(--primary-hover);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.thread-stats {
    display: flex;
    gap: 15px;
}

.thread-stats span {
    display: flex;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.thread-stats i {
    margin-right: 5px;
    color: var(--primary-color);
}

/* Hiển thị số lượt tim (likes) */
.thread-likes i {
    color: #ff6b6b;
}

.thread-likes {
    position: relative;
    overflow: hidden;
}

.thread-likes.new-like i {
    animation: heartPulse 0.6s ease;
}

@keyframes heartPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.5); }
    100% { transform: scale(1); }
}

/* Hiển thị số lượt xem */
.thread-views i {
    color: #4dc4ff;
}

/* Hiển thị số bình luận */
.thread-comments i {
    color: #7ed957;
}

/* Hiệu ứng badge engagement */
.rule-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    background: #e0e0e0;
    color: #555;
    margin-right: 5px;
    transition: all 0.3s ease;
}

.rule-badge.active {
    background: #3498db;
    color: white;
    animation: pulse 1.5s infinite;
}

.rule-badge.silver.active {
    background: linear-gradient(145deg, #c0c0c0, #e0e0e0);
    color: #333;
}

.rule-badge.gold.active {
    background: linear-gradient(145deg, #ffd700, #ffaa00);
    color: #5a4500;
}

.rule-badge.platinum.active {
    background: linear-gradient(145deg, #e5e4e2, #d3d3d3);
    color: #333;
    box-shadow: 0 0 10px rgba(229, 228, 226, 0.5);
}

/* Cải thiện hiển thị thông tin thread trong thread detail */
.thread-info-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.thread-info-item:last-child {
    border-bottom: none;
}

.thread-info-item span:first-child {
    color: var(--text-secondary);
    font-weight: 500;
}

.thread-info-item span:last-child {
    color: var(--text-primary);
    font-weight: 600;
}

/* Hiển thị thông tin ngày đăng */
.thread-time {
    position: relative;
}

.thread-time[data-tooltip]:hover:after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 10px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: nowrap;
    z-index: 10;
    pointer-events: none;
    opacity: 0;
    animation: fadeIn 0.3s forwards;
}

/* Hiệu ứng khi thread mới */
.new-thread::before {
    content: 'NEW';
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary-color);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    animation: pulse 1.5s infinite;
    z-index: 1;
}

.thread-item.highlighted {
    animation: highlightFade 2s;
}

@keyframes highlightFade {
    0% { box-shadow: 0 0 0 4px var(--primary-color); }
    100% { box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); }
}

.no-threads {
    text-align: center;
    color: #888;
    padding: 20px;
    font-style: italic;
}


/*ModCtrl table*/
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-family: Arial, sans-serif;
}
th, td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: center;
}
th {
    background-color: #4CAF50;
    color: white;
    font-weight: bold;
}
h2 {
    text-align: center;
    color: #1bbd23;
}

/* Login and Register Styles */
.login-container,
.register-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.login-box,
.register-box {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 400px;
}

.login-box h2,
.register-box h2 {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
    font-size: 28px;
}

.form-group {
    position: relative;
    margin-bottom: 30px;
}

.form-group input {
    width: 100%;
    padding: 10px 0;
    font-size: 16px;
    color: #333;
    border: none;
    border-bottom: 2px solid #ddd;
    outline: none;
    background: transparent;
    transition: 0.3s;
}

.form-group label {
    position: absolute;
    top: 0;
    left: 0;
    padding: 10px 0;
    font-size: 16px;
    color: #666;
    pointer-events: none;
    transition: 0.3s;
}

.form-group input:focus ~ label,
.form-group input:valid ~ label {
    top: -20px;
    font-size: 12px;
    color: #667eea;
}

.form-group .line {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #ddd;
}

.form-group .line::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: #667eea;
    transform: scaleX(0);
    transition: transform 0.3s;
}

.form-group input:focus ~ .line::after {
    transform: scaleX(1);
}

.btn-login,
.btn-register {
    width: 100%;
    padding: 12px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    transition: 0.3s;
}

.btn-login:hover,
.btn-register:hover {
    background: #764ba2;
    transform: translateY(-2px);
}

.register-link,
.login-link {
    text-align: center;
    margin-top: 20px;
    color: #666;
}

.register-link a,
.login-link a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.register-link a:hover,
.login-link a:hover {
    color: #764ba2;
}

/* Animations */
.animate-fade-in {
    animation: fadeIn 0.8s ease-in-out;
}

.animate-slide-up {
    animation: slideUp 0.8s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Add animations to existing elements */
.navbar {
    animation: slideDown 0.5s ease-in-out;
}

.card {
    animation: fadeIn 0.5s ease-in-out;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
    }
    to {
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 480px) {
    .login-box,
    .register-box {
        padding: 20px;
    }
    
    .form-group input,
    .form-group label {
        font-size: 14px;
    }
    
    .btn-login,
    .btn-register {
        padding: 10px;
        font-size: 14px;
    }
}

/* Filter Buttons Styles */
.filter-buttons {
    display: flex;
    justify-content: center;
    margin: 15px 0;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: bold;
}

.filter-btn:hover {
    background-color: #e0e0e0;
}

.filter-btn.active {
    background-color: #52057b;
    color: white;
    border-color: #52057b;
}

/* Update Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: #111314;
    border-radius: 8px;
    overflow: hidden;
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #333;
    color: #fff;
}

th {
    background-color: #52057b;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 14px;
}

td {
    font-size: 14px;
}

tr:hover {
    background-color: #1a1a1a;
}

.role-admin {
    color: #FF0042;
    font-weight: bold;
}

.role-moderator {
    color: #28a745;
    font-weight: bold;
}

.role-user {
    color: #007bff;
}

/* Responsive table */
@media screen and (max-width: 768px) {
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* Table Styles */
.table-container {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-top: 20px;
    padding-bottom: 15px;
}

.table-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    padding: 0 15px;
}

.user-table {
    width: 100%;
    border-collapse: collapse;
    animation: fadeIn 0.5s ease-in-out;
}

.user-table th {
    background-color: var(--dark-bg);
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    padding: 15px;
    border-bottom: 2px solid rgba(0, 255, 157, 0.2);
}

.user-table td {
    padding: 15px;
    border-bottom: 1px solid rgba(225, 225, 255, 0.1);
    color: var(--light-text);
}

.user-table tr:hover {
    background-color: var(--table-hover);
    transition: background-color 0.3s ease;
}

/* Dropdown Styles */
.role-select, .status-select {
    padding: 8px 12px;
    border: 1px solid rgba(0, 255, 157, 0.3);
    border-radius: 6px;
    background-color: var(--dark-bg);
    color: var(--light-text);
    width: 100%;
    transition: all 0.3s ease;
}

.role-select:focus, .status-select:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 10px rgba(0, 255, 157, 0.2);
}

/* Status Colors */
.status-active {
    color: var(--status-active);
    font-weight: 500;
}

.status-inactive {
    color: var(--status-inactive);
    font-weight: 500;
}

.status-pending {
    color: var(--status-pending);
    font-weight: 500;
}

/* Button Styles */
.table-actions {
    padding: 20px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    background: var(--dark-bg);
    border-top: 1px solid rgba(225, 225, 255, 0.1);
}

.save-all-btn, .refresh-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.save-all-btn {
    background-color: var(--status-active);
    color: var(--darker-bg);
}

.refresh-btn {
    background-color: var(--secondary-color);
    color: var(--light-text);
}

.save-all-btn:hover, .refresh-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 255, 157, 0.2);
}

/* Filter Buttons */
.filter-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 12px 24px;
    background-color: var(--dark-bg);
    color: var(--light-text);
    border: 1px solid rgba(0, 255, 157, 0.3);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.filter-btn:hover {
    background-color: var(--table-hover);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: var(--darker-bg);
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(0, 255, 157, 0.3);
}

/* Status Change Animation */
.status-changed {
    animation: highlight 1.5s ease;
}

@keyframes highlight {
    0% {
        background-color: rgba(0, 255, 157, 0.15);
    }
    100% {
        background-color: transparent;
    }
}

/* Section heading */
section h2 {
    color: var(--primary-color);
    text-align: center;
    margin: 0 0;
    font-size: 2rem;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(0, 255, 157, 0.3);
}

/* Cập nhật biến màu */
:root {
    --primary-color: #00ff9d;
    --secondary-color: #7000ff;
    --accent-color: #ff006a;
    --dark-bg: #12121f;
    --darker-bg: #0a0a0f;
    --table-bg: #1a1a2f;
    --light-text: #e1e1ff;
    --table-hover: #252542;
    
    /* Role Colors - Cập nhật màu mới */
    --role-admin: #ff006a;      /* Đỏ cho Admin */
    --role-moderator: #FFD700;  /* Vàng cho Moderator */
    --role-user: #FFFFFF;      /* Trắng cho User */
    
    /* Status Colors */
    --status-active: #00ff9d;    /* Xanh lá - Đang hoạt động */
    --status-inactive: #ffb700;  /* Vàng - Không hoạt động */
    --status-ban: #ff006a;      /* Đỏ - Bị cấm */
    
    /* Animation cho Admin */
    --role-admin-animation: #FF0000, #FF7F00, #FFFF00, #00FF00, #0000FF, #4B0082, #8F00FF;
}

/* Table Container Styles */
.table-container {
    margin: 20px;
    background: var(--table-bg);
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    border: 1px solid rgba(0, 255, 157, 0.1);
}

/* Table Styles */
.user-table {
    width: 100%;
    border-collapse: collapse;
    animation: fadeIn 0.5s ease-in-out;
}

.user-table th {
    background-color: var(--dark-bg);
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    padding: 15px;
    border-bottom: 2px solid rgba(0, 255, 157, 0.2);
}

.user-table td {
    padding: 15px;
    border-bottom: 1px solid rgba(225, 225, 255, 0.1);
    color: var(--light-text);
}

.user-table tr:hover {
    background-color: var(--table-hover);
    transition: background-color 0.3s ease;
}

/* Role Select Styles */
.role-select {
    padding: 8px 12px;
    border: 1px solid rgba(0, 255, 157, 0.3);
    border-radius: 6px;
    background-color: var(--dark-bg);
    color: var(--light-text);
    width: 100%;
    transition: all 0.3s ease;
    font-weight: 500;
}

/* Màu cho các option trong Role Select */
.role-select option.role-admin {
    color: var(--role-admin) !important;
    font-weight: 600;
}

.role-select option.role-moderator {
    color: var(--role-moderator) !important;
    font-weight: 600;
}

.role-select option.role-user {
    color: var(--role-user) !important;
    font-weight: 600;
}

/* Role Colors trong select box */
.role-select.role-admin {
    animation: rainbow 5s linear infinite;
    text-shadow: 0 0 10px currentColor;
    font-weight: bold;
}

.role-select.role-moderator {
    color: var(--role-moderator) !important;
    border-color: var(--role-moderator);
    text-shadow: 0 0 10px var(--role-moderator);
}

.role-select.role-user {
    color: var(--role-user) !important;
    border-color: var(--role-user);
}

/* Focus styles cho select boxes */
.role-select:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 10px rgba(0, 255, 157, 0.2);
}

/* Hiệu ứng hover cho role select */
.role-select:hover {
    border-color: var(--primary-color);
}

/* Animation khi thay đổi role */
.role-changed {
    animation: highlight 1.5s ease;
}

/* Thêm hiệu ứng cho các option khi hover */
.role-select option:hover {
    background-color: var(--table-hover);
}

/* Cập nhật style cho cả role và status */
.role-select, .status-select {
    padding: 8px 12px;
    border: 1px solid rgba(0, 255, 157, 0.3);
    border-radius: 6px;
    background-color: var(--dark-bg);
    width: 100%;
    transition: all 0.3s ease;
    font-weight: 500;
    cursor: pointer;
}

/* Hiệu ứng hover chung */
.role-select:hover, .status-select:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 255, 157, 0.2);
}

/* Focus styles chung */
.role-select:focus, .status-select:focus {
    outline: none;
    box-shadow: 0 0 10px rgba(0, 255, 157, 0.2);
}

/* Animation khi thay đổi */
@keyframes highlight {
    0% {
        background-color: rgba(0, 255, 157, 0.15);
    }
    50% {
        background-color: rgba(0, 255, 157, 0.1);
    }
    100% {
        background-color: transparent;
    }
}

/* Thêm vào JavaScript để xử lý thay đổi role */
.role-changed, .status-changed {
    animation: highlight 1.5s ease;
}

/* Hiệu ứng cầu vồng cho Admin */
@keyframes rainbow {
    0% { color: #FF0000; border-color: #FF0000; }
    14% { color: #FF7F00; border-color: #FF7F00; }
    28% { color: #FFFF00; border-color: #FFFF00; }
    42% { color: #00FF00; border-color: #00FF00; }
    56% { color: #0000FF; border-color: #0000FF; }
    70% { color: #4B0082; border-color: #4B0082; }
    84% { color: #8F00FF; border-color: #8F00FF; }
    100% { color: #FF0000; border-color: #FF0000; }
}

/* Cập nhật style cho option */
.role-select option.role-admin {
    animation: rainbow 5s linear infinite;
    font-weight: bold;
}

.role-select option.role-moderator {
    color: var(--role-moderator) !important;
    font-weight: 600;
}

.role-select option.role-user {
    color: var(--role-user) !important;
    font-weight: 500;
}

/* Cập nhật nút Save Changes */
.action-btn {
    background: linear-gradient(45deg, #00ff9d, #7000ff);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: 0.5s;
}

.action-btn:hover::before {
    left: 100%;
}

.action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 255, 157, 0.4);
}

.action-btn:active {
    transform: translateY(1px);
}

/* Animation khi lưu thành công */
.save-success {
    animation: saveSuccess 1s ease;
}

@keyframes saveSuccess {
    0% {
        background: linear-gradient(45deg, #00ff9d, #7000ff);
    }
    50% {
        background: #00ff9d;
    }
    100% {
        background: linear-gradient(45deg, #00ff9d, #7000ff);
    }
}

/* Cập nhật hiệu ứng hover cho table row */
.user-table tr:hover {
    background-color: rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

/* Cập nhật hiệu ứng khi thay đổi role/status */
.role-changed, .status-changed {
    animation: highlight 1s ease;
}

@keyframes highlight {
    0% {
        background-color: rgba(0, 255, 157, 0.2);
    }
    50% {
        background-color: rgba(0, 255, 157, 0.1);
    }
    100% {
        background-color: transparent;
    }
}

/* Cập nhật style cho status Ban */
.status-select option[value="Ban"] {
    color: #ff0000 !important;
    font-weight: bold;
}

.status-select.status-ban {
    color: #ff0000 !important;
    border-color: #ff0000;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.5);
}

/* Đồng bộ style cho tất cả các nút save */
.action-btn, .save-all-btn {
    background: linear-gradient(45deg, #00ff9d, #7000ff);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.action-btn::before, .save-all-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: 0.5s;
}

.action-btn:hover::before, .save-all-btn:hover::before {
    left: 100%;
}

.action-btn:hover, .save-all-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 255, 157, 0.4);
}

.action-btn:active, .save-all-btn:active {
    transform: translateY(1px);
}

/* Animation khi lưu thành công */
.save-success {
    animation: saveSuccess 1s ease;
}

@keyframes saveSuccess {
    0% {
        background: linear-gradient(45deg, #00ff9d, #7000ff);
    }
    50% {
        background: #00ff9d;
    }
    100% {
        background: linear-gradient(45deg, #00ff9d, #7000ff);
    }
}

/* Cập nhật style cho table actions container */
.table-actions {
    padding: 20px;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    background: var(--dark-bg);
    border-top: 1px solid rgba(225, 225, 255, 0.1);
}

/* Style cho refresh button */
.refresh-btn {
    background: linear-gradient(45deg, #7000ff, #00ff9d);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(112, 0, 255, 0.4);
}

.refresh-btn:active {
    transform: translateY(1px);
}

/* Animation cho icon refresh */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.refresh-btn i {
    margin-right: 5px;
}

.refresh-btn i.spinning {
    animation: spin 1s linear infinite;
}

/* Style cho container chứa các nút action */
.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: center;
}

/* Style chung cho các nút action */
.action-btn {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.3s ease;
}

/* Style cho nút Save */
.action-btn.save-btn {
    background: linear-gradient(45deg, #00ff9d, #7000ff);
    color: white;
}

.action-btn.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 255, 157, 0.3);
}

/* Style cho nút Delete */
.action-btn.delete-btn {
    background: linear-gradient(45deg, #ff006a, #ff4444);
    color: white;
}

.action-btn.delete-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 0, 106, 0.3);
}

/* Animation khi hover */
.action-btn:hover {
    filter: brightness(1.1);
}

/* Animation khi click */
.action-btn:active {
    transform: translateY(1px);
}

/* Icon style */
.action-btn i {
    font-size: 14px;
}

/* Hiệu ứng khi xóa thành công */
.delete-success {
    animation: deleteAnimation 0.5s ease;
}

@keyframes deleteAnimation {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(0.95);
    }
    100% {
        opacity: 0;
        transform: scale(0.9);
    }
}

/* ########################################### */
/*           Thread Detail                     */
/* ########################################### */
.thread-detail {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 0 auto 20px;
    max-width: 1200px;
    color: #FEFEFE;
    background-color: #111314;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.main-content {
    flex: 1;
    width: 100%;
    padding: 20px;
    background-color: #1a1d1f;
    border-radius: 8px;
}

/* Style cho header của thread */
.thread-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #2c2f33;
}

.thread-title {
    color: #FEFEFE;
    margin-bottom: 10px;
    font-size: 1.8rem;
}

.thread-meta {
    display: flex;
    gap: 15px;
    font-size: 0.9rem;
    color: #9ea4ab;
}

/* Style cho form tạo post */
.post-form {
    display: flex;
    gap: 15px;
    padding: 15px;
    margin-bottom: 20px;
    background-color: #1e2124;
    border-radius: 8px;
    border: 1px solid #2c2f33;
}

.post-form textarea {
    width: 100%;
    padding: 12px;
    border-radius: 6px;
    background-color: #2a2d31;
    color: #FEFEFE;
    border: 1px solid #36393f;
    resize: vertical;
    min-height: 80px;
}

.post-form button {
    padding: 10px 15px;
    background-color: #52057b;
    color: #FEFEFE;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    margin-top: 10px;
    transition: all 0.2s;
}

.post-form button:hover {
    background-color: #7209b7;
    transform: translateY(-2px);
}

/* Style cho post */
.post {
    padding: 20px;
    margin-bottom: 20px;
    background-color: #1e2124;
    border-radius: 8px;
    border: 1px solid #2c2f33;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.post-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.post-author-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-content {
    color: #FEFEFE;
    margin-bottom: 15px;
    line-height: 1.6;
    padding: 5px 0;
}

.post-footer {
    border-top: 1px solid #2c2f33;
    padding-top: 15px;
}

/* Style cho nút tương tác (like, comment, report) */
.action-button {
    background: none;
    border: none;
    color: #9ea4ab;
    cursor: pointer;
    padding: 6px 12px;
    margin-right: 10px;
    font-size: 0.9rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.action-button:hover {
    color: #FEFEFE;
    background-color: #2c2f33;
}

.action-button.liked {
    color: #e25822;
}

.action-button.liked i {
    color: #e25822;
}

/* Style cho comments */
.comments-container {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

.comment {
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 6px;
    background: var(--bg-accent);
    box-shadow: 0 2px 4px var(--shadow-color);
    animation: fadeIn 0.5s;
    transition: all 0.3s ease;
}

.comment:hover {
    background: var(--bg-secondary);
    transform: translateX(5px);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.comment-author-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.comment-author {
    font-weight: 600;
    color: var(--text-primary);
}

.comment-date {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.comment-content {
    padding: 5px 0;
    line-height: 1.5;
    color: var(--text-primary);
}

/* Hiệu ứng cho comment mới */
.new-comment {
    border-left: 2px solid var(--success-color);
}

/* Modal Report */
#report-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#report-modal.hide {
    display: none !important;
}

.modal-content {
    background-color: #1e2124;
    padding: 25px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    color: #FEFEFE;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.modal-content h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #FEFEFE;
}

.modal-content textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    background-color: #2a2d31;
    color: #FEFEFE;
    border: 1px solid #36393f;
    border-radius: 4px;
    resize: vertical;
    min-height: 100px;
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.modal-buttons button {
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.modal-buttons button:first-child {
    background-color: #52057b;
    color: #FEFEFE;
}

.modal-buttons button:last-child {
    background-color: #36393f;
    color: #FEFEFE;
}

.modal-buttons button:hover {
    opacity: 0.9;
}

/* Form comment */
.comment-form {
    padding: 15px;
    background-color: #2a2d31;
    border-radius: 8px;
    margin-top: 10px;
    margin-bottom: 15px;
    border: 1px solid #36393f;
}

.comment-form textarea {
    width: 100%;
    padding: 10px;
    background-color: #36393f;
    color: #FEFEFE;
    border: 1px solid #42464d;
    border-radius: 4px;
    resize: vertical;
    min-height: 60px;
}

.comment-form button {
    padding: 8px 15px;
    background-color: #52057b;
    color: #FEFEFE;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    margin-top: 10px;
}

.comment-form button:hover {
    background-color: #7209b7;
}

/* Sidebar */
.sidebar-section {
    margin-bottom: 25px;
}

.sidebar-title {
    color: #FEFEFE;
    font-size: 1.2rem;
    padding-bottom: 10px;
    margin-bottom: 15px;
    border-bottom: 1px solid #2c2f33;
    font-weight: bold;
}

.thread-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thread-info-item {
    display: flex;
    justify-content: space-between;
    color: #9ea4ab;
}

.related-threads {
    list-style: none;
    padding: 0;
}

.related-threads li {
    margin-bottom: 10px;
}

.related-threads a {
    color: #a0a0a0;
    text-decoration: none;
    transition: color 0.2s;
}

.related-threads a:hover {
    color: #52057b;
}

.thread-rules {
    padding-left: 20px;
    color: #9ea4ab;
}

.thread-rules li {
    margin-bottom: 8px;
}

/* Thêm các styles mới để tăng cường trải nghiệm like */
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.post-updated, .comment-updated {
    animation: highlight 1.5s;
}

@keyframes highlight {
    0% { background-color: transparent; }
    30% { background-color: rgba(82, 5, 123, 0.3); }
    100% { background-color: transparent; }
}

.like-processing {
    pointer-events: none;
    opacity: 0.7;
}

.action-button.liked i.fa-heart {
    color: #e25822 !important;
    animation: heart-pulse 0.5s ease-in-out;
}

@keyframes heart-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    opacity: 0;
    animation: ripple 1s;
    pointer-events: none;
}

@keyframes ripple {
    0% { transform: scale(0); opacity: 1; }
    100% { transform: scale(1.5); opacity: 0; }
}

/* Thêm hiệu ứng ripple cho button */
.action-button {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: scale(0);
    animation: ripple 0.8s ease-out;
    width: 100px;
    height: 100px;
    top: -50px;
    left: -50px;
    right: 0;
    bottom: 0;
    margin: auto;
    pointer-events: none;
}

@keyframes ripple {
    from {
        transform: scale(0);
        opacity: 1;
    }
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Animation cho nút like */
.like-button.liked i {
    animation: heart-pulse 0.4s ease-in-out;
}

@keyframes heart-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* Visual feedback khi đang xử lý */
.like-processing {
    pointer-events: none;
    opacity: 0.7;
}

/* CSS Hoạt ảnh cho trang Forums */

/* Hiệu ứng hero section */
.hero-section {
    position: relative;
    background: linear-gradient(135deg, #000000, #52057b, #630680);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    color: white;
    padding: 120px 20px 200px; /* Tăng padding-bottom để tạo không gian */
    text-align: center;
    margin-bottom: 120px; /* Tăng margin-bottom để tạo khoảng cách với section sau */
    overflow: visible; /* Cho phép nội dung tràn ra ngoài */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    border-bottom: 3px solid #892cdc;
    z-index: 1; /* Đảm bảo section này có z-index */
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: -1; /* Đặt ở phía sau nội dung */
}

/* Tách tiêu đề h1 ra khỏi hero-content */
.hero-title {
    position: relative;
    z-index: 3;
    font-size: 3.8rem;
    margin-bottom: 40px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8), 0 0 30px rgba(137, 44, 220, 0.8);
    color: #ffffff;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    background: linear-gradient(45deg, #ffffff, #d8b9ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
    animation: fadeInDown 1s ease-out;
}

/* Hiệu ứng cho tiêu đề */
.hero-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 4px;
    background: linear-gradient(90deg, #52057b, #892cdc);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(137, 44, 220, 0.5);
}

/* Điều chỉnh hero-content để nổi lên trên các phần khác */
.hero-content {
    max-width: 800px;
    margin: -50px auto 0; /* Để nội dung vượt ra khỏi hero section */
    position: relative;
    z-index: 10; /* Z-index cao hơn để không bị phần khác đè lên */
    animation: fadeInUp 1s ease-out;
    background: rgba(17, 19, 20, 0.95); /* Màu tối gần giống theme */
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(82, 5, 123, 0.5);
    transform: translateY(0); /* Tránh bị ảnh hưởng bởi animation float */
}

.hero-content p {
    font-size: 1.3rem;
    margin-bottom: 30px;
    line-height: 1.7;
    color: #e1e1ff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
    font-weight: 300;
    max-width: 85%;
    margin-left: auto;
    margin-right: auto;
}

/* Chỉnh sửa Features section để không đè lên hero-content */
.features-section {
    padding: 80px 20px 60px;
    background-color: #0a0a0f;
    color: #e1e1ff;
    position: relative;
    z-index: 1; /* Z-index thấp hơn hero-content */
    margin-top: 40px; /* Tạo thêm khoảng cách với hero */
}

/* Responsive cho màn hình nhỏ */
@media screen and (max-width: 768px) {
    .hero-section {
        padding: 100px 20px 180px;
        margin-bottom: 100px;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-content {
        margin-top: -70px;
        padding: 25px;
    }
}

@media screen and (max-width: 480px) {
    .hero-section {
        padding: 80px 15px 150px;
        margin-bottom: 80px;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-content {
        margin-top: -60px;
        padding: 20px;
    }
}

/* Hiệu ứng cho feature cards */
.features-container {
    display: flex;
    flex-direction: row;     /* Thay đổi từ column sang row */
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    background-color: #111314;
    border-radius: 10px;
    padding: 30px;
    width: calc(33.333% - 20px);    /* Chia làm 3 cột */
    min-width: 280px;               /* Đảm bảo không quá nhỏ trên màn hình mobile */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    animation: fadeIn 0.8s ease-out;
    will-change: transform;
    border: 1px solid rgba(82, 5, 123, 0.3);
    flex-grow: 1;                   /* Cho phép mở rộng nếu có không gian */
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(82, 5, 123, 0.4);
    border-color: #52057b;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #e1e1ff;
}

.feature-card p {
    color: #9ea4ab;
    line-height: 1.6;
}

/* Hiệu ứng cho category cards */
.category-cards {
    display: flex;
    flex-direction: row;     /* Đảm bảo hiển thị theo hàng ngang */
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.category-card {
    background-color: #1a1a1a;
    border-radius: 10px;
    padding: 30px;
    width: calc(33.333% - 20px);    /* Chia làm 3 cột */
    min-width: 280px;               /* Đảm bảo không quá nhỏ trên màn hình mobile */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    animation: slideInRight 0.8s ease-out;
    border: 1px solid rgba(82, 5, 123, 0.3);
    flex-grow: 1;                   /* Cho phép mở rộng nếu có không gian */
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(82, 5, 123, 0.4);
    border-color: #52057b;
}

.category-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #e1e1ff;
}

.category-card p {
    color: #9ea4ab;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* Hiệu ứng cho activity feed */
.activity-feed {
    display: flex;
    flex-direction: row;     /* Thay đổi từ column sang row */
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.activity-card {
    background-color: #111314;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 0;              /* Bỏ margin bottom */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    width: calc(33.333% - 14px);   /* Chia làm 3 cột */
    min-width: 280px;              /* Đảm bảo không quá nhỏ trên màn hình mobile */
    animation: fadeInLeft 0.6s ease-out;
    transform-origin: left;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(82, 5, 123, 0.2);
    flex-grow: 1;                  /* Cho phép mở rộng nếu có không gian */
}

.activity-card:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(82, 5, 123, 0.3);
    border-color: #52057b;
}

.activity-user {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 80px;
}

.activity-user i {
    font-size: 2.5rem;
    color: #52057b;
    margin-bottom: 5px;
}

.activity-user span {
    font-size: 0.9rem;
    font-weight: bold;
    color: #e1e1ff;
}

.activity-content {
    flex: 1;
}

.activity-content p {
    margin-bottom: 5px;
    color: #9ea4ab;
}

.activity-content a {
    color: #52057b;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s;
}

.activity-content a:hover {
    color: #892cdc;
    text-decoration: underline;
}

.activity-time {
    font-size: 0.8rem;
    color: #666;
}

.view-more-btn {
    display: inline-block;
    background-color: transparent;
    color: #52057b;
    border: 2px solid #52057b;
    padding: 10px 25px;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
}

.view-more-btn:hover {
    background-color: #52057b;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(82, 5, 123, 0.3);
}

/* Hiệu ứng cho CTA section */
.cta-section {
    background: linear-gradient(135deg, #1a1a1a, #52057b);
    color: white;
    padding: 80px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-content {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
    animation: fadeIn 1s ease-out;
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.cta-content p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    line-height: 1.6;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.cta-btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cta-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.cta-btn:first-child {
    background-color: white;
    color: #52057b;
}

.cta-btn.secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

/* Hiệu ứng cho footer */
.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
    background-color: #0a0a0f;
}

.footer-section {
    flex: 1;
    min-width: 250px;
    margin-bottom: 30px;
}

.footer-section h3 {
    color: #52057b;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-section h3:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: #52057b;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: #9ea4ab;
    text-decoration: none;
    transition: color 0.3s, transform 0.3s;
    display: inline-block;
}

.footer-section ul li a:hover {
    color: #52057b;
    transform: translateX(5px);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #1a1a1a;
    color: #e1e1ff;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background-color: #52057b;
    color: white;
    transform: translateY(-5px);
}

.footer-bottom {
    text-align: center;
    padding: 20px;
    background-color: #0a0a0f;
    color: #666;
    border-top: 1px solid #1a1a1a;
}

/* Keyframe Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Animation Delays for Feature Cards */
.feature-card:nth-child(1) {
    animation-delay: 0.2s;
}
.feature-card:nth-child(2) {
    animation-delay: 0.4s;
}
.feature-card:nth-child(3) {
    animation-delay: 0.6s;
}

/* Animation Delays for Category Cards */
.category-card:nth-child(1) {
    animation-delay: 0.2s;
}
.category-card:nth-child(2) {
    animation-delay: 0.4s;
}
.category-card:nth-child(3) {
    animation-delay: 0.6s;
}

/* Animation Delays for Activity Cards */
.activity-card:nth-child(1) {
    animation-delay: 0.1s;
}
.activity-card:nth-child(2) {
    animation-delay: 0.3s;
}
.activity-card:nth-child(3) {
    animation-delay: 0.5s;
}

/* Hover Effects for Links */
a:not(.hero-btn):not(.cta-btn):not(.category-link):not(.view-more-btn) {
    position: relative;
}

a:not(.hero-btn):not(.cta-btn):not(.category-link):not(.view-more-btn)::after {
    /*
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: #52057b;
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.3s ease-out;
    */
    content: none; /* Disabling the underline effect */
}

a:not(.hero-btn):not(.cta-btn):not(.category-link):not(.view-more-btn):hover::after {
    /*
    transform: scaleX(1);
    transform-origin: bottom left;
    */
    transform: scaleX(0); /* Ensuring no transformation on hover */
}

/* Responsive cho các card containers */
@media screen and (max-width: 992px) {
    .feature-card, .category-card, .activity-card {
        width: calc(50% - 15px);   /* 2 columns trên màn hình tablet */
    }
}

@media screen and (max-width: 768px) {
    .features-container, .category-cards, .activity-feed {
        flex-direction: column;    /* Chuyển về dạng cột trên màn hình mobile */
        align-items: center;
    }
    
    .feature-card, .category-card, .activity-card {
        width: 100%;               /* Chiếm toàn bộ chiều rộng trên mobile */
        max-width: 400px;          /* Giới hạn chiều rộng tối đa */
    }
}

/* Chỉnh sửa lại kích thước cho activity card trên mobile */
@media screen and (max-width: 576px) {
    .activity-card {
        flex-direction: column;    /* Chuyển sang hiển thị theo cột cho profile và nội dung */
        text-align: center;
    }
    
    .activity-user {
        margin-bottom: 10px;
    }
}

/* Styles cho tab navigation */
.mod-tabs {
    display: flex;
    justify-content: center;
    margin: 20px 0;
    gap: 15px;
}

.tab-button {
    padding: 12px 24px;
    background-color: #1a1a1a;
    color: #e1e1ff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    font-size: 16px;
    transition: all 0.3s ease;
    position: relative;
}

.tab-button:hover {
    background-color: #333;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.tab-button.active {
    background: linear-gradient(45deg, #52057b, #892cdc);
    color: white;
}

.tab-content {
    display: none;
    animation: fadeIn 0.5s ease-out;
}

.tab-content.active {
    display: block;
}

/* Badge cho báo cáo đang chờ xử lý */
.report-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: #ff3860;
    color: white;
    font-size: 12px;
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    padding: 0 6px;
    margin-left: 5px;
}

/* Styles cho bảng báo cáo */
.report-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
    background-color: #111314;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.report-table th,
.report-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #333;
}

.report-table th {
    background-color: #0a0a0f;
    color: #e1e1ff;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 1px;
}

.report-table tr:hover {
    background-color: #1a1a1a;
}

.report-table .reason-cell {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Status styles */
.status-pending {
    color: #ffdd57;
    font-weight: bold;
}

.status-resolved {
    color: #23d160;
    font-weight: bold;
}

.status-rejected {
    color: #ff3860;
    font-weight: bold;
}

/* Nút action trong báo cáo */
.report-actions {
    display: flex;
    gap: 10px;
}

.action-btn.view-btn {
    background-color: #3273dc;
}

.action-btn.view-btn:hover {
    background-color: #276cda;
}

.action-btn.resolve-btn {
    background-color: #23d160;
}

.action-btn.resolve-btn:hover {
    background-color: #22c65b;
}

.action-btn.reject-btn {
    background-color: #ff3860;
}

.action-btn.reject-btn:hover {
    background-color: #ff1f4b;
}

/* Styles cho modal chi tiết báo cáo */
#report-details-modal .modal-content {
    max-width: 700px;
    width: 90%;
}

.report-details {
    margin: 20px 0;
    border: 1px solid #333;
    border-radius: 5px;
    padding: 20px;
    background-color: #1a1a1a;
}

.post-content {
    background-color: #0a0a0f;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    border-left: 4px solid #52057b;
}

.report-info p {
    margin: 10px 0;
}

@media screen and (max-width: 768px) {
    .mod-tabs {
        flex-direction: column;
        align-items: center;
    }

    .tab-button {
        width: 100%;
    }

    .report-table th:nth-child(5),
    .report-table td:nth-child(5) {
        display: none;
    }
}

@media screen and (max-width: 480px) {
    .report-table th:nth-child(3),
    .report-table td:nth-child(3) {
        display: none;
    }
}

/* Custom Alerts Styles */
.custom-alert {
    font-family: 'Titillium Web', sans-serif;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    max-width: 450px;
    width: 90%;
    padding: 25px;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.custom-alert h3 {
    margin-top: 0;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.custom-alert p {
    margin-bottom: 20px;
    line-height: 1.5;
}

.custom-alert button {
    background-color: #52057b;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.2s;
}

.custom-alert button:hover {
    background-color: #3b0458;
}

.alert-error {
    border-top: 5px solid #d32f2f;
}

.alert-error h3 {
    color: #d32f2f;
}

.alert-warning {
    border-top: 5px solid #ff8f00;
}

.alert-warning h3 {
    color: #ff8f00;
}

.alert-info {
    border-top: 5px solid #0288d1;
}

.alert-info h3 {
    color: #0288d1;
}

.alert-success {
    border-top: 5px solid #388e3c;
}

.alert-success h3 {
    color: #388e3c;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translate(-50%, -60%); }
    to { opacity: 1; transform: translate(-50%, -50%); }
}

/* ===== ANIMATION KEYFRAMES ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

@keyframes fadeInUp {
    from { 
        opacity: 0;
        transform: translateY(20px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes lineExpand {
    from { width: 0; }
    to { width: 50px; }
}

@keyframes heartPulse {
    0% { transform: scale(1); }
    15% { transform: scale(1.2); }
    30% { transform: scale(1); }
    45% { transform: scale(1.2); }
    60% { transform: scale(1); }
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    20% {
        transform: scale(25, 25);
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: scale(40, 40);
    }
}

@keyframes slideInRight {
    from { 
        transform: translateX(100%); 
        opacity: 0;
    }
    to { 
        transform: translateX(0); 
        opacity: 1;
    }
}

@keyframes slideInUp {
    from { 
        transform: translateY(30px); 
        opacity: 0;
    }
    to { 
        transform: translateY(0); 
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from { 
        transform: translateX(-100%); 
        opacity: 0;
    }
    to { 
        transform: translateX(0); 
        opacity: 1;
    }
}

@keyframes glow {
    0% { box-shadow: 0 0 0 rgba(106, 17, 203, 0); }
    50% { box-shadow: 0 0 10px rgba(106, 17, 203, 0.5); }
    100% { box-shadow: 0 0 0 rgba(106, 17, 203, 0); }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

h1 {
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
}

h2, h3 {
    position: relative;
}

h1::after {
    /*
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    animation: lineExpand var(--anim-duration-medium) forwards ease-out;
    */
    content: none; /* Disabling the underline effect */
}

h2::after, h3::after {
    /*
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    animation: lineExpand var(--anim-duration-medium) 0.3s forwards ease-out;
    */
    content: none; /* Disabling the underline effect */
}

/* Categories Page Styling */
.categories-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px;
}

.section-title {
    text-align: center;
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-description {
    text-align: center;
    color: #555;
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.categories-container {
    margin-top: 3rem;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.category-item {
    background: #0a0a0a;
    border-radius: 10px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid #333;
    color: #fff;
    animation: fadeInUp 0.5s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

.category-item::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--button-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.category-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    background: #111;
}

.category-item:hover::before {
    transform: scaleX(1);
}

/* Animation delay for each category item */
.category-item:nth-child(1) { animation-delay: 0.1s; }
.category-item:nth-child(2) { animation-delay: 0.2s; }
.category-item:nth-child(3) { animation-delay: 0.3s; }
.category-item:nth-child(4) { animation-delay: 0.4s; }
.category-item:nth-child(5) { animation-delay: 0.5s; }
.category-item:nth-child(6) { animation-delay: 0.6s; }
.category-item:nth-child(7) { animation-delay: 0.7s; }
.category-item:nth-child(8) { animation-delay: 0.8s; }

/* Add Category Form */
#add-category-box {
    background: #0a0a0a;
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 40px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid #333;
    transition: all 0.5s ease;
}

#add-category-box h2 {
    text-align: center;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.form-container {
    display: flex;
    gap: 10px;
    width: 100%;
}

#category-name {
    flex: 1;
    padding: 12px 15px;
    border-radius: 30px;
    border: 1px solid #333;
    background: #111;
    color: #fff;
    transition: all 0.3s ease;
}

#category-name:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(106, 17, 203, 0.3);
    outline: none;
}

.category-btn {
    padding: 12px 20px;
    border-radius: 30px;
    background: var(--button-gradient);
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.category-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
    background: var(--button-hover-gradient);
}

.category-btn:active {
    transform: translateY(1px);
}

.delete-category-btn {
    background: transparent;
    color: #ff4d4d;
    border: 1px solid #ff4d4d;
    border-radius: 20px;
    padding: 5px 10px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delete-category-btn:hover {
    background: #ff4d4d;
    color: white;
}

.delete-category-btn::before {
    content: "\f1f8";
    font-family: FontAwesome;
    margin-right: 5px;
    font-size: 0.9rem;
}

/* Enhanced animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.8s ease forwards;
}

.animate-slide-up {
    animation: fadeInUp 0.8s ease forwards;
}

/* Ripple effect for buttons */
.category-btn {
    position: relative;
    overflow: hidden;
}

.category-btn::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
}

.category-btn:focus:not(:active)::after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    20% {
        transform: scale(25, 25);
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: scale(40, 40);
    }
}

/* Media Queries */
@media screen and (max-width: 768px) {
    .form-container {
        flex-direction: column;
    }
    
    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

@media screen and (max-width: 480px) {
    .category-grid {
        grid-template-columns: 1fr;
    }
    
    #add-category-box {
        padding: 20px;
    }
}

.category-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-content i {
    font-size: 1.5rem;
    color: var(--folder-color);
    transition: color 0.3s ease;
}

.category-content span {
    font-size: 1.1rem;
    font-weight: 500;
}

/* Empty Categories Message */
.empty-categories {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    background: #0a0a0a;
    border-radius: 10px;
    border: 1px dashed #333;
    color: #666;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.empty-categories i {
    font-size: 4rem;
    margin-bottom: 10px;
    color: var(--folder-color);
    animation: pulse 2s infinite;
}

.empty-categories p {
    font-size: 1.1rem;
    color: #999;
}

/* Add hover effect for the folder icon */
.category-item:hover .fa-folder {
    animation: folderBounce 0.5s ease;
    color: var(--folder-hover-color);
}

@keyframes folderBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* Cursor pointer for clickable items */
.category-item {
    cursor: pointer;
}

/* Animation for newly created category */
.category-item.new-item {
    animation: newItemHighlight 2s ease-out forwards;
}

@keyframes newItemHighlight {
    0% {
        box-shadow: 0 0 0 3px var(--primary-color);
        transform: scale(1.05);
    }
    70% {
        box-shadow: 0 0 0 3px var(--primary-color);
    }
    100% {
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
        transform: scale(1);
    }
}

/* Updated hover effect */
.category-item:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    background: linear-gradient(145deg, #111, #0a0a0a);
}

/* Categories Action Panel */
.categories-action-panel {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.create-category-action-btn {
    padding: 12px 24px;
    background: var(--button-gradient);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.create-category-action-btn i {
    font-size: 1.2rem;
}

.create-category-action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background: var(--button-hover-gradient);
}

.create-category-action-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* Enhanced Add Category Box */
#add-category-box {
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 30px;
    border-radius: 15px;
    background: linear-gradient(145deg, #0c0c0c, #0a0a0a);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid #333;
    transform: translateY(20px);
    opacity: 0;
    animation: slideUp 0.5s ease-out forwards;
}

#add-category-box.hide {
    display: none;
}

#add-category-box h2 {
    text-align: center;
    margin-bottom: 25px;
    color: var(--primary-color);
    font-size: 1.8rem;
}

#add-category-box.hide + .categories-container {
    margin-top: 0;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Pulse animation for the create button */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(106, 17, 203, 0.7);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(106, 17, 203, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(106, 17, 203, 0);
    }
}

.create-category-action-btn {
    animation: pulse 2s infinite;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .create-category-action-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    #add-category-box {
        padding: 20px;
    }
}

/* Direct Category Creation Form */
.direct-category-form {
    max-width: 800px;
    margin: 0 auto 30px;
    padding: 20px;
    background: linear-gradient(145deg, #0c0c0c, #0a0a0a);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid #333;
    animation: fadeIn 0.8s ease forwards;
}

.direct-category-form .input-group {
    display: flex;
    gap: 10px;
}

.direct-category-form input {
    flex: 1;
    padding: 12px 15px;
    border-radius: 30px;
    border: 1px solid #333;
    background: #111;
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.direct-category-form input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(106, 17, 203, 0.3);
    outline: none;
}

.direct-category-btn {
    padding: 12px 20px;
    border-radius: 30px;
    background: var(--button-gradient);
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.direct-category-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
    background: var(--button-hover-gradient);
}

.direct-category-btn:active {
    transform: translateY(1px);
}

.form-note {
    margin-top: 10px;
    font-size: 0.85rem;
    color: #666;
    text-align: center;
    font-style: italic;
}

/* Responsive design for direct category form */
@media screen and (max-width: 768px) {
    .direct-category-form .input-group {
        flex-direction: column;
    }
    
    .direct-category-btn {
        width: 100%;
        justify-content: center;
        margin-top: 10px;
    }
}

/* Update popup styles with new color scheme */
.popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    background-color: #111314;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0px 0px 10px var(--primary-color);
    text-align: center;
    z-index: 1000;
}

.popup button {
    padding: 10px;
    background: var(--button-gradient);
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}

.popup button:hover {
    background: var(--button-hover-gradient);
}

/* ########################################### */
/*        Thread Detail Page Animations        */
/* ########################################### */

.thread-detail {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-in-out forwards;
}

.thread-header {
    opacity: 0;
    transform: translateY(-20px);
    animation: fadeInDown var(--animation-medium) 0.2s ease-in-out forwards;
}

.thread-title {
    position: relative;
    display: inline-block;
    margin-bottom: 15px;
    color: var(--primary-color);
    opacity: 0;
    animation: fadeInUp var(--animation-medium) 0.4s ease-in-out forwards;
}

.thread-meta {
    opacity: 0;
    animation: fadeIn var(--animation-medium) 0.6s ease-in-out forwards;
}

.thread-content {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp var(--animation-medium) 0.6s ease-in-out forwards;
}

.post-form {
    opacity: 0;
    animation: fadeIn var(--animation-medium) 0.8s ease-in-out forwards;
}

.sidebar {
    opacity: 0;
    transform: translateX(20px);
    animation: fadeInRight var(--animation-medium) 0.4s ease-in-out forwards;
}

.sidebar-section {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-in-out forwards;
}

.sidebar-section:nth-child(1) {
    animation-delay: 0.6s;
}

.sidebar-section:nth-child(2) {
    animation-delay: 0.8s;
}

.sidebar-section:nth-child(3) {
    animation-delay: 1s;
}

/* Post and Comment Animations */
.post {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp var(--animation-medium) ease-in-out forwards;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Staggered animation for posts */
.posts-container .post:nth-child(1) { animation-delay: 0.1s; }
.posts-container .post:nth-child(2) { animation-delay: 0.2s; }
.posts-container .post:nth-child(3) { animation-delay: 0.3s; }
.posts-container .post:nth-child(4) { animation-delay: 0.4s; }
.posts-container .post:nth-child(5) { animation-delay: 0.5s; }
.posts-container .post:nth-child(6) { animation-delay: 0.6s; }
.posts-container .post:nth-child(7) { animation-delay: 0.7s; }
.posts-container .post:nth-child(8) { animation-delay: 0.8s; }
.posts-container .post:nth-child(9) { animation-delay: 0.9s; }
.posts-container .post:nth-child(10) { animation-delay: 1s; }

/* Comment animations */
.comment {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-in-out forwards;
    transition: background-color 0.3s ease;
}

.comment:hover {
    background-color: rgba(106, 17, 203, 0.05);
}

/* Comment staggered animations */
.comments-container .comment:nth-child(1) { animation-delay: 0.1s; }
.comments-container .comment:nth-child(2) { animation-delay: 0.2s; }
.comments-container .comment:nth-child(3) { animation-delay: 0.3s; }
.comments-container .comment:nth-child(4) { animation-delay: 0.4s; }
.comments-container .comment:nth-child(5) { animation-delay: 0.5s; }

/* Button Animations */
.action-button {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.action-button:hover {
    transform: translateY(-2px);
}

.action-button::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
}

.action-button:focus:not(:active)::after {
    animation: ripple 1s ease-out;
}

/* Like button animation */
.like-button:hover i {
    animation: heartPulse 1s ease;
}

.like-button.active i {
    color: #FF4081;
}

/* Thread interactions */
.thread-info-item {
    opacity: 0;
    animation: fadeInRight var(--animation-medium) ease-in-out forwards;
}

.thread-info-item:nth-child(1) { animation-delay: 0.7s; }
.thread-info-item:nth-child(2) { animation-delay: 0.8s; }
.thread-info-item:nth-child(3) { animation-delay: 0.9s; }
.thread-info-item:nth-child(4) { animation-delay: 1s; }

/* Related threads animation */
#related-threads li {
    opacity: 0;
    transform: translateX(-10px);
    animation: fadeInLeft var(--animation-medium) ease-in-out forwards;
}

#related-threads li:nth-child(1) { animation-delay: 1.1s; }
#related-threads li:nth-child(2) { animation-delay: 1.2s; }
#related-threads li:nth-child(3) { animation-delay: 1.3s; }
#related-threads li:nth-child(4) { animation-delay: 1.4s; }
#related-threads li:nth-child(5) { animation-delay: 1.5s; }

/* Thread rules animation */
.thread-rules li {
    opacity: 0;
    animation: fadeIn var(--animation-medium) ease-in-out forwards;
}

.thread-rules li:nth-child(1) { animation-delay: 1.6s; }
.thread-rules li:nth-child(2) { animation-delay: 1.7s; }
.thread-rules li:nth-child(3) { animation-delay: 1.8s; }
.thread-rules li:nth-child(4) { animation-delay: 1.9s; }

/* Comment form animation */
.comment-form {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out, opacity 0.4s ease-in-out;
}

.comment-form:not(.hide) {
    max-height: 200px;
    opacity: 1;
}

/* Report modal animation */
#report-modal {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#report-modal:not(.hide) {
    opacity: 1;
    transform: scale(1);
}

/* Additional keyframes for thread animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hover effect for the entire post */
.post {
    border-left: 3px solid transparent;
    transition: border-left-color 0.3s ease;
}

.post:hover {
    border-left-color: var(--primary-color);
}

/* Enhanced Thread Detail Styling */
.thread-detail {
    grid-template-columns: 1fr 300px;
    gap: 30px;
    margin-top: 30px;
}

.main-content {
    background: #0a0a0f;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    position: relative;
    border: 1px solid #222;
}

.main-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--button-gradient);
    border-radius: 10px 10px 0 0;
}

.thread-header {
    margin-bottom: 25px;
    padding-bottom: 15px;
    position: relative;
}

.thread-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, var(--primary-color), transparent);
}

.thread-title {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.thread-meta {
    display: flex;
    gap: 20px;
    color: #999;
    font-size: 0.9rem;
}

.thread-author, .thread-time {
    display: flex;
    align-items: center;
    gap: 5px;
}

.thread-content {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 30px;
    color: #eee;
}

.post-form {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    background: #111;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #333;
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
}

.form-content {
    flex: 1;
}

textarea {
    width: 100%;
    min-height: 100px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 5px;
    padding: 10px;
    color: #eee;
    margin-bottom: 10px;
    resize: vertical;
    transition: border-color 0.3s ease;
}

textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px rgba(106, 17, 203, 0.3);
    outline: none;
}

.button {
    background: var(--button-gradient);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: bold;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
}

.button:active {
    transform: translateY(0);
}

.post {
    background: #111;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    border: 1px solid #222;
}

.post-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #222;
}

.post-author-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.author-details {
    display: flex;
    flex-direction: column;
}

.post-author {
    font-weight: bold;
    color: var(--primary-color);
}

.post-date {
    font-size: 0.8rem;
    color: #777;
}

.post-actions {
    display: flex;
    gap: 10px;
}

.action-button {
    background: transparent;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.action-button:hover {
    color: #fff;
}

.edit-post, .delete-post {
    color: #777;
}

.edit-post:hover {
    color: var(--primary-color);
}

.delete-post:hover {
    color: #ff4d4d;
}

.post-content {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 20px;
    color: #eee;
}

.post-footer {
    display: flex;
    justify-content: space-between;
    color: #777;
    padding-top: 10px;
}

.post-interactions {
    display: flex;
    gap: 15px;
}

.like-button.active {
    color: #FF4081;
}

.comments-container {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px dashed #333;
}

.comment {
    background: #0f0f0f;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    border: 1px solid #222;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.comment-author-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.comment-author {
    font-weight: bold;
    color: var(--primary-color);
}

.comment-date {
    font-size: 0.75rem;
    color: #777;
}

.comment-actions {
    display: flex;
    gap: 10px;
}

.edit-comment, .delete-comment {
    color: #777;
}

.edit-comment:hover {
    color: var(--primary-color);
}

.delete-comment:hover {
    color: #ff4d4d;
}

.comment-content {
    font-size: 0.95rem;
    line-height: 1.4;
    color: #ddd;
}

/* Sidebar styling */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.sidebar-section {
    background: #0a0a0f;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid #222;
}

.sidebar-title {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #222;
    position: relative;
}

.sidebar-title::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--button-gradient);
}

.thread-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thread-info-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px dotted #222;
}

.thread-info-item span:first-child {
    color: #999;
}

.thread-info-item span:last-child {
    font-weight: bold;
    color: #eee;
}

#related-threads {
    list-style: none;
    padding: 0;
    margin: 0;
}

#related-threads li {
    padding: 10px 0;
    border-bottom: 1px dotted #222;
}

#related-threads li:last-child {
    border-bottom: none;
}

#related-threads a {
    display: block;
    color: #eee;
    text-decoration: none;
    transition: color 0.3s ease;
}

#related-threads a:hover {
    color: var(--primary-color);
}

.thread-rules {
    padding-left: 20px;
    margin: 0;
}

.thread-rules li {
    margin-bottom: 10px;
    color: #ccc;
}

/* Modal styling */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: #111;
    padding: 25px;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    border: 1px solid #333;
}

.modal h3 {
    color: var(--primary-color);
    margin-top: 0;
    margin-bottom: 15px;
}

.modal textarea {
    width: 100%;
    min-height: 120px;
    margin-bottom: 20px;
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.modal button {
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

.modal button:first-child {
    background: var(--button-gradient);
    color: white;
    border: none;
}

.modal button:last-child {
    background: transparent;
    color: #ccc;
    border: 1px solid #444;
}

.modal button:first-child:hover {
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
}

.modal button:last-child:hover {
    background: #222;
}

/* Thread Detail Page Responsive Design */
@media screen and (max-width: 900px) {
    .thread-detail {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        order: -1;
        margin-bottom: 20px;
    }
}

@media screen and (max-width: 768px) {
    .thread-title {
        font-size: 1.5rem;
    }
    
    .thread-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .post-header, .comment-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .post-actions, .comment-actions {
        justify-content: flex-start;
    }
    
    .post-interactions {
        flex-wrap: wrap;
    }
    
    .modal-content {
        width: 95%;
        padding: 15px;
    }
    
    .modal-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .modal button {
        width: 100%;
    }
}

@media screen and (max-width: 480px) {
    .main-content {
        padding: 15px;
    }
    
    .thread-title {
        font-size: 1.3rem;
    }
    
    .thread-content {
        font-size: 1rem;
    }
    
    .post {
        padding: 15px;
    }
    
    .post-author-info {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .user-avatar {
        margin-bottom: 5px;
    }
    
    textarea {
        min-height: 80px;
    }
    
    .sidebar-section {
        padding: 15px;
    }
}

/* Add smooth scrolling for better user experience */
html {
    scroll-behavior: smooth;
}

/* Animation when new post is added */
@keyframes newItemHighlight {
    0% {
        background-color: rgba(106, 17, 203, 0.2);
    }
    100% {
        background-color: #111;
    }
}

.post.new-post {
    animation: newItemHighlight 2s ease-out forwards;
}

/* Animation when new comment is added */
.comment.new-comment {
    animation: newItemHighlight 2s ease-out forwards;
}

/* Animation for like button */
@keyframes likeAnimation {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.like-button.liked i {
    animation: likeAnimation 0.4s ease-out;
    color: #FF4081;
}

/* Focus styles for accessibility */
textarea:focus, .button:focus, .action-button:focus {
    outline: 2px solid rgba(106, 17, 203, 0.5);
    outline-offset: 2px;
}

/* Improve scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #0a0a0f;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-light);
}

/* Loading animation for dynamic content */
@keyframes shimmer {
    0% { background-position: -468px 0 }
    100% { background-position: 468px 0 }
}

.loading-shimmer {
    background: linear-gradient(to right, #111 8%, #222 18%, #111 33%);
    background-size: 800px 104px;
    animation: shimmer 1.5s infinite linear;
    border-radius: 5px;
    height: 20px;
    margin: 10px 0;
}

/* Scrollbar styling */
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-light);
}

/* Loading animation for dynamic content */
@keyframes shimmer {
    0% { background-position: -468px 0 }
    100% { background-position: 468px 0 }
}

.loading-shimmer {
    background: linear-gradient(to right, #111 8%, #222 18%, #111 33%);
    background-size: 800px 104px;
    animation: shimmer 1.5s infinite linear;
    border-radius: 5px;
    height: 20px;
    margin: 10px 0;
}

/* Engagement Rules Styling */
.engagement-rules {
    list-style: none;
    padding: 0;
    margin: 0;
}

.engagement-rules li {
    padding: 8px 0;
    margin-bottom: 8px;
    color: #ddd;
    border-bottom: 1px dotted #222;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.engagement-rules li:last-child {
    border-bottom: none;
    font-style: italic;
    color: #888;
}

.rule-badge {
    background: #8a6d3b;
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
    transition: all 0.3s ease;
}

.rule-badge.active {
    transform: scale(1.1);
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
    padding: 2px 10px;
}

.rule-badge.silver {
    background: linear-gradient(135deg, #C0C0C0, #E8E8E8);
    color: #333;
}

.rule-badge.gold {
    background: linear-gradient(135deg, #FFD700, #FFC107);
    color: #333;
}

.rule-badge.platinum {
    background: linear-gradient(135deg, #E5E4E2, #A9A9A9);
    color: #000;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

/* New animated styles for community.html */
.create-thread-btn {
    animation: fadeIn 0.8s ease-out;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.create-thread-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

#create-thread-section {
    animation: slideDown 0.5s ease-out;
}

#create-thread-section h2 {
    animation: fadeIn 0.8s ease-out;
}

.thread-form {
    animation: fadeIn 1s ease-out;
}

/* Dark dropdown styling */
#thread-category {
    background: #1a1a1a;
    color: #eee;
    border: 1px solid #333;
    padding: 12px;
    border-radius: 5px;
    width: 100%;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2) inset;
    margin-bottom: 15px;
}

#thread-category:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 8px rgba(106, 17, 203, 0.5);
}

#thread-category option {
    background: #1a1a1a;
    color: #eee;
    padding: 10px;
}

#thread-category option:hover {
    background-color: #2a2a2a;
}

/* Add animation to threads section */
.threads-section h2 {
    animation: fadeInLeft 0.8s ease-out;
}

.threads-container {
    animation: fadeIn 1s ease-out;
}

.thread-item {
    animation: fadeInUp 0.6s ease-out;
    animation-fill-mode: both;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.thread-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Staggered animation for thread items */
.thread-item:nth-child(1) { animation-delay: 0.1s; }
.thread-item:nth-child(2) { animation-delay: 0.2s; }
.thread-item:nth-child(3) { animation-delay: 0.3s; }
.thread-item:nth-child(4) { animation-delay: 0.4s; }
.thread-item:nth-child(5) { animation-delay: 0.5s; }
.thread-item:nth-child(6) { animation-delay: 0.6s; }
.thread-item:nth-child(7) { animation-delay: 0.7s; }
.thread-item:nth-child(8) { animation-delay: 0.8s; }

/* Animation for empty thread container */
.no-threads {
    animation: pulse 2s infinite ease-in-out;
    opacity: 0.7;
}

/* Ensure button animations work well */


.thread-buttons button:last-of-type {
    background: #333;
    transition: background 0.3s ease;
}

.thread-buttons button:last-of-type:hover {
    background: #555;
}

/* Add loading animation styles */
.loading-shimmer {
    background: linear-gradient(to right, #1a1a1a 8%, #333 18%, #1a1a1a 33%);
    background-size: 800px 104px;
    animation: shimmer 1.5s infinite linear;
    border-radius: 5px;
    height: 20px;
    margin: 10px 0;
}

/* Additional animation and effects for community.html */
@keyframes glow {
    0% { box-shadow: 0 0 5px rgba(106, 17, 203, 0.5); }
    100% { box-shadow: 0 0 20px rgba(106, 17, 203, 0.8); }
}

@keyframes pulse {
    0% { opacity: 0.5; }
    50% { opacity: 0.8; }
    100% { opacity: 0.5; }
}

.focus-effect {
    transition: all 0.3s ease;
}

.focus-effect:focus {
    transform: scale(1.01);
    box-shadow: 0 0 15px rgba(106, 17, 203, 0.3);
}

.error-highlight {
    animation: errorShake 0.4s ease-in-out;
    border-color: #ff3860 !important;
    box-shadow: 0 0 8px rgba(255, 56, 96, 0.4) !important;
}

@keyframes errorShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.loading-state {
    padding: 20px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    margin: 20px 0;
}

.error-state {
    text-align: center;
    padding: 30px;
    background: rgba(255, 56, 96, 0.1);
    border-radius: 8px;
    margin: 20px 0;
    color: #eee;
}

/* Hiệu ứng cho community.html */
.community-section {
    opacity: 0;
    animation: fadeIn 0.8s ease-in-out forwards;
    margin-bottom: 2rem;
}

.thread-actions {
    opacity: 0;
    animation: slideInLeft 0.8s ease-in-out forwards;
    margin: 1.5rem 0;
    text-align: center;
}

.create-thread-btn {
    position: relative;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.create-thread-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.create-thread-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.3), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.create-thread-btn:hover::before {
    transform: translateX(100%);
}

#create-thread-section {
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.5s, transform 0.5s;
}

#create-thread-section.show {
    opacity: 1;
    transform: translateY(0);
}

.thread-form select,
.thread-form textarea {
    transform: scale(0.95);
    opacity: 0;
    animation: fadeInScale 0.5s ease-in-out forwards;
}

.thread-form select { animation-delay: 0.1s; }
.thread-form textarea:nth-of-type(1) { animation-delay: 0.2s; }
.thread-form textarea:nth-of-type(2) { animation-delay: 0.3s; }

.thread-buttons button {
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.5s ease-in-out forwards;
}

.thread-buttons button:first-of-type { animation-delay: 0.4s; }
.thread-buttons button:last-of-type { animation-delay: 0.5s; }

.threads-section {
    opacity: 0;
    animation: fadeIn 1s ease-in-out forwards;
    animation-delay: 0.3s;
}

.threads-container {
    perspective: 1000px;
}

.thread-item {
    transform-origin: center top;
    transform: rotateX(-90deg);
    opacity: 0;
    animation: rotateIn 0.6s ease-in-out forwards;
    transition: transform 0.3s, box-shadow 0.3s;
}

.thread-item:hover {
    transform: translateY(-5px) scale(1.02) !important;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    z-index: 1;
}

/* Thêm hiệu ứng cho các thread item khi xuất hiện từng cái một */
.thread-item:nth-child(1) { animation-delay: 0.5s; }
.thread-item:nth-child(2) { animation-delay: 0.6s; }
.thread-item:nth-child(3) { animation-delay: 0.7s; }
.thread-item:nth-child(4) { animation-delay: 0.8s; }
.thread-item:nth-child(5) { animation-delay: 0.9s; }

/* Hiệu ứng cho footer */
footer {
    opacity: 0;
    animation: fadeIn 1s ease-in-out forwards;
    animation-delay: 1s;
}

/* Keyframes cho các hiệu ứng */
@keyframes fadeInScale {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes rotateIn {
    0% {
        transform: rotateX(-90deg);
        opacity: 0;
    }
    100% {
        transform: rotateX(0);
        opacity: 1;
    }
}

@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hiệu ứng loading shimmer */
.loading-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
    height: 200px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Hiệu ứng cho thread mới */
.new-thread {
    position: relative;
    overflow: hidden;
}

.new-thread::before {
    content: 'NEW';
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary-color);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Hiển thị trạng thái thread */
.thread-status {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.thread-status.active {
    background: #4CAF50;
    color: white;
}

.thread-status.recent {
    background: #2196F3;
    color: white;
}

.thread-status.archived {
    background: #9E9E9E;
    color: white;
}

/* Cải thiện tooltip */
[data-tooltip] {
    position: relative;
    cursor: help;
}

[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    z-index: 10;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    animation: fadeIn 0.3s forwards;
}

.thread-meta [data-tooltip]:hover::after {
    top: -30px;
    bottom: auto;
}

/* Hiệu ứng cho lượt xem và like */
.thread-views, .thread-likes {
    transition: all 0.3s ease;
}

.thread-views.updated, .thread-likes.updated {
    animation: pulse 0.5s;
}

/* Hiệu ứng loading khi tải thread */
.loading-thread {
    background: linear-gradient(90deg, var(--card-bg) 0%, var(--bg-accent) 50%, var(--card-bg) 100%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
    height: 200px;
    margin-bottom: 20px;
}

/* Kiểu dáng cho các bài thread trong các thread liên quan */
#related-threads li {
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

#related-threads li:hover {
    transform: translateX(5px);
}

#related-threads a {
    display: block;
    color: var(--text-primary);
    text-decoration: none;
    padding: 5px 0;
    transition: all 0.3s ease;
}

#related-threads a:hover {
    color: var(--primary-color);
}

#related-threads a small {
    color: var(--text-secondary);
    margin-left: 5px;
}

/* Các biến màu chính cho theme tối */
:root {
    --bg-primary: #121212;
    --bg-secondary: #1e1e1e;
    --card-bg: #2a2a2a;
    --bg-accent: #333333;
    --text-primary: #f5f5f5;
    --text-secondary: #aaaaaa;
    --text-muted: #888888;
    --primary-color: #4a90e2;
    --primary-hover: #3a80d2;
    --success-color: #4CAF50;
    --danger-color: #f44336;
    --warning-color: #ff9800;
    --info-color: #2196F3;
    --border-color: rgba(255, 255, 255, 0.1);
    --shadow-color: rgba(0, 0, 0, 0.3);
}

/* Thread item cải tiến */
.thread-item {
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px var(--shadow-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.thread-item:hover {
    transform: translateY(-5px) scale(1.02) !important;
    box-shadow: 0 8px 20px var(--shadow-color);
    z-index: 1;
}

.thread-title {
    margin: 0 0 10px;
    font-size: 1.5rem;
    color: var(--text-primary);
    font-weight: 600;
}

.thread-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.thread-content {
    margin-bottom: 15px;
    line-height: 1.6;
    color: var(--text-secondary);
}

.thread-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
}

.thread-link {
    padding: 8px 15px;
    background: var(--primary-color);
    color: var(--text-primary);
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.thread-link:hover {
    background: var(--primary-hover);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px var(--shadow-color);
}

/* Các element phụ của thread */
.thread-stats span {
    display: flex;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Badges và status với màu tối hơn */
.rule-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    background: var(--bg-accent);
    color: var(--text-secondary);
    margin-right: 5px;
    transition: all 0.3s ease;
}

.rule-badge.active {
    background: var(--primary-color);
    color: var(--text-primary);
    animation: pulse 1.5s infinite;
}

.rule-badge.silver.active {
    background: linear-gradient(145deg, #555555, #777777);
    color: var(--text-primary);
}

.rule-badge.gold.active {
    background: linear-gradient(145deg, #b8860b, #daa520);
    color: var(--text-primary);
}

.rule-badge.platinum.active {
    background: linear-gradient(145deg, #717171, #9e9e9e);
    color: var(--text-primary);
    box-shadow: 0 0 10px rgba(155, 155, 155, 0.5);
}

/* Trạng thái thread */
.thread-status {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.thread-status.active {
    background: var(--success-color);
    color: var(--text-primary);
}

.thread-status.recent {
    background: var(--info-color);
    color: var(--text-primary);
}

.thread-status.archived {
    background: #777777;
    color: var(--text-primary);
}

/* Sidebar các mục thông tin */
.sidebar-section {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 18px;
    margin-bottom: 24px;
    box-shadow: 0 4px 6px var(--shadow-color);
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s ease;
    animation: fadeIn 0.5s;
}

.sidebar-section:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 15px var(--shadow-color);
}

.sidebar-title {
    font-size: 1.25rem;
    margin-bottom: 15px;
    color: var(--text-primary);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
    position: relative;
    display: flex;
    align-items: center;
}

.sidebar-title::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
    margin-right: 10px;
    display: inline-block;
}

.thread-rules, .engagement-rules {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.thread-rules li, .engagement-rules li {
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 6px;
    background: var(--bg-accent);
    position: relative;
    padding-left: 30px;
    transition: all 0.3s ease;
    animation: fadeInLeft 0.5s;
}

.thread-rules li:hover, .engagement-rules li:hover {
    background: var(--bg-secondary);
    transform: translateX(5px);
}

.thread-rules li::before, .engagement-rules li::before {
    content: '\f00c';
    font-family: FontAwesome;
    position: absolute;
    left: 10px;
    color: var(--success-color);
}

/* Màu biểu tượng khác nhau cho mỗi luật */
.thread-rules li:nth-child(1)::before { content: '\f071'; color: #e74c3c; } /* Exclamation */
.thread-rules li:nth-child(2)::before { content: '\f05e'; color: #e67e22; } /* Ban */
.thread-rules li:nth-child(3)::before { content: '\f024'; color: #3498db; } /* Flag */
.thread-rules li:nth-child(4)::before { content: '\f046'; color: #2ecc71; } /* Check */

/* Trang trí đặc biệt cho rule-badge */
.rule-badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
    margin-right: 8px;
    background: var(--bg-accent);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.rule-badge.active {
    background: #cd7f32; /* Bronze color */
    color: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    border: none;
}

.rule-badge.silver.active {
    background: #c0c0c0; /* Silver color */
    color: #333;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.rule-badge.gold.active {
    background: #ffd700; /* Gold color */
    color: #333;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.rule-badge.platinum.active {
    background: linear-gradient(135deg, #a0b2c6 0%, #e0e8ef 50%, #a0b2c6 100%);
    color: #333;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    border: none;
}

/* Hiệu ứng hover cho badge */
.rule-badge:hover {
    transform: scale(1.1);
}

/* Animation glow cho badge active */
@keyframes badgeGlow {
    0% { box-shadow: 0 0 5px rgba(255,255,255,0.5); }
    50% { box-shadow: 0 0 15px rgba(255,255,255,0.8); }
    100% { box-shadow: 0 0 5px rgba(255,255,255,0.5); }
}

.rule-badge.active:hover, 
.rule-badge.silver.active:hover, 
.rule-badge.gold.active:hover, 
.rule-badge.platinum.active:hover {
    animation: badgeGlow 1.5s infinite;
}

/* Cải thiện hiển thị thread-info */
.thread-info {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.thread-info-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 12px;
    background: var(--bg-accent);
    border-radius: 6px;
    transition: all 0.3s ease;
}

.thread-info-item:hover {
    background: var(--bg-secondary);
    transform: translateX(5px);
}

.thread-info-item span:first-child {
    font-weight: bold;
    color: var(--text-secondary);
}

.thread-info-item span:last-child {
    color: var(--text-primary);
    font-weight: 600;
}

/* Thêm icon cho mỗi thread-info-item */
.thread-info-item.category::before {
    content: '\f07b';
    font-family: FontAwesome;
    margin-right: 8px;
    color: var(--primary-color);
}

.thread-info-item.date::before {
    content: '\f017';
    font-family: FontAwesome;
    margin-right: 8px;
    color: var(--primary-color);
}

.thread-info-item.likes::before {
    content: '\f004';
    font-family: FontAwesome;
    margin-right: 8px;
    color: #e74c3c;
}

.thread-info-item.views::before {
    content: '\f06e';
    font-family: FontAwesome;
    margin-right: 8px;
    color: #3498db;
}

.thread-info-item.posts::before {
    content: '\f0e5';
    font-family: FontAwesome;
    margin-right: 8px;
    color: #2ecc71;
}

.thread-info-item.status::before {
    content: '\f05a';
    font-family: FontAwesome;
    margin-right: 8px;
    color: #f39c12;
}

/* Hiệu ứng đặc biệt cho các số */
.thread-info-item .highlight-number {
    font-weight: bold;
    position: relative;
    display: inline-block;
}

.thread-info-item .highlight-number::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.thread-info-item:hover .highlight-number::after {
    transform: scaleX(1);
}

/* Hiệu ứng khi hover vào sidebar section */
.sidebar-section {
    position: relative;
    overflow: hidden;
}

.sidebar-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.sidebar-section:hover::before {
    opacity: 0.05;
}

/* Hiệu ứng khi focus vào related threads */
#related-threads li {
    position: relative;
    padding: 8px 0;
    margin-bottom: 8px;
    border-bottom: 1px dashed var(--border-color);
    transition: all 0.3s ease;
}

#related-threads li::before {
    content: '\f0da';
    font-family: FontAwesome;
    margin-right: 8px;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

#related-threads li:hover::before {
    transform: translateX(5px);
}

#related-threads a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
    display: block;
}

#related-threads a:hover {
    color: var(--primary-color);
}

#related-threads a small {
    display: block;
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-top: 4px;
}

/* Animation cho các phần tử sidebar khi load */
@keyframes slideInFromRight {
    0% {
        transform: translateX(50px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.sidebar-section:nth-child(1) { animation: slideInFromRight 0.5s 0.1s both; }
.sidebar-section:nth-child(2) { animation: slideInFromRight 0.5s 0.2s both; }
.sidebar-section:nth-child(3) { animation: slideInFromRight 0.5s 0.3s both; }
.sidebar-section:nth-child(4) { animation: slideInFromRight 0.5s 0.4s both; }

/* Responsive cho sidebar trên mobile */
@media screen and (max-width: 900px) {
    .thread-detail {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        margin-top: 20px;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 20px;
    }
    
    .sidebar-section {
        margin-bottom: 0;
    }
}

@media screen and (max-width: 768px) {
    .sidebar {
        grid-template-columns: 1fr;
    }
    
    .thread-rules li, .engagement-rules li {
        font-size: 14px;
    }
}

/* Animation cho thread status */
.thread-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
    color: white;
    background: var(--bg-accent);
    box-shadow: 0 2px 4px var(--shadow-color);
    transition: all 0.3s ease;
}

.thread-status.active {
    background: var(--success-color);
    animation: pulse 2s infinite;
}

.thread-status.recent {
    background: var(--primary-color);
}

.thread-status.archived {
    background: var(--text-secondary);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Tooltip cho thread status */
.thread-status {
    position: relative;
}

.thread-status::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 10px;
    border-radius: 4px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.75rem;
    white-space: nowrap;
    box-shadow: 0 2px 5px var(--shadow-color);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 10;
}

.thread-status:hover::after {
    opacity: 1;
    visibility: visible;
    bottom: calc(100% + 5px);
}

/* Styles for CKEditor */
.editor-container {
    margin-bottom: 20px;
    width: 100%;
}

/* Style the CKEditor toolbar */
.cke_top {
    background: linear-gradient(to right, var(--gradient-start), var(--gradient-end)) !important;
    border-color: var(--border-color) !important;
}

/* Style CKEditor content area */
.cke_contents {
    border-color: var(--border-color) !important;
    min-height: 250px !important;
}

/* Style CKEditor buttons */
.cke_button {
    background: transparent !important;
}

.cke_button:hover {
    background: rgba(255, 255, 255, 0.2) !important;
}

/* Fix for image size in CKEditor */
.cke_editable img {
    max-width: 100%;
    height: auto;
}

/* Style displayed image in posts */
.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin: 10px 0;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.post-content img:hover {
    transform: scale(1.02);
}

/* Image Upload Styles */
.image-upload-btn {
    background-color: #4CAF50;
    color: white;
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 10px;
}

.image-upload-btn:hover {
    background-color: #45a049;
}

.image-preview-container {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.image-preview-item {
    position: relative;
    width: 150px;
    height: 150px;
    border: 1px solid #ddd;
    overflow: hidden;
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-preview-item .remove-image {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: rgba(255, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Back Button Styles */
.back-button {
    background-color: #6a11cb;
    color: white;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.3s ease;
    margin: 10px;
    text-decoration: none;
}

.back-button:hover {
    background-color: #5a0fb0;
    transform: translateX(-3px);
}

.back-button i {
    font-size: 14px;
}

.thread-header-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.thread-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 5px;
}

.thread-category-tag {
    background-color: #e0e0e0;
    color: #333;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    display: inline-block;
    margin-right: 5px;
}

.thread-category-tag:hover {
    background-color: #d0d0d0;
    cursor: pointer;
}

.thread-nav {
    margin-bottom: 15px;
}

.back-button {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    background-color: #333;
    color: #fff;
    border-radius: 4px;
    text-decoration: none;
    transition: background-color 0.3s;
    font-size: 14px;
}

.back-button i {
    margin-right: 5px;
}

.back-button:hover {
    background-color: #444;
    text-decoration: none;
}

.thread-category-badge {
    margin-bottom: 10px;
}

.category-badge {
    display: inline-block;
    padding: 5px 12px;
    background-color: #4CAF50;
    color: white;
    border-radius: 15px;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
}

.thread-item .thread-category {
    margin-bottom: 8px;
}

.thread-views.updated, .thread-likes.updated {
    animation: highlight 2s ease-in-out;
    background-color: rgba(106, 17, 203, 0.1);
    border-radius: 4px;
}

@keyframes highlight {
    0% { background-color: rgba(106, 17, 203, 0.5); }
    100% { background-color: rgba(106, 17, 203, 0); }
}

/* Style for thread views and likes counters */
.thread-stats span {
    display: inline-flex;
    align-items: center;
    margin-right: 15px;
    font-size: 14px;
    color: #aaa;
    transition: color 0.3s;
}

.thread-stats span i {
    margin-right: 5px;
    font-size: 16px;
}

.thread-stats span:hover {
    color: #fff;
}

.thread-views i {
    color: #3498db;
}

.thread-likes i {
    color: #e74c3c;
}

/* Style for thread category badge */
.thread-item .thread-category {
    margin-bottom: 8px;
}

/* Styles for create thread button and form */
.create-thread-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(106, 17, 203, 0.3);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
}

.create-thread-btn i {
    margin-right: 10px;
    font-size: 18px;
    transition: transform 0.3s ease;
}

.create-thread-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(106, 17, 203, 0.5);
}

.create-thread-btn:hover i {
    transform: rotate(90deg);
}

.create-thread-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.create-thread-btn:hover::before {
    left: 100%;
}

#create-thread-section {
    background: rgba(30, 30, 40, 0.9);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 40px;
    transform: translateY(-20px);
    opacity: 0;
    transition: all 0.4s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(106, 17, 203, 0.2);
}

#create-thread-section.show {
    transform: translateY(0);
    opacity: 1;
}

#create-thread-section h2 {
    color: #fff;
    font-size: 24px;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

#create-thread-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 4px;
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    border-radius: 2px;
}

.thread-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.thread-form select,
.thread-form textarea {
    background-color: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.thread-form select:focus,
.thread-form textarea:focus {
    border-color: #6a11cb;
    box-shadow: 0 0 10px rgba(106, 17, 203, 0.3);
    outline: none;
}

.thread-form select {
    height: 50px;
    cursor: pointer;
}

.thread-form select option {
    background-color: #1e1e28;
    color: #fff;
}

.thread-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.thread-form #thread-title {
    font-size: 18px;
    font-weight: 600;
    min-height: 50px;
}

.thread-form #thread-content {
    min-height: 200px;
    resize: vertical;
}

.editor-container {
    margin-bottom: 20px;
    border-radius: 8px;
    overflow: hidden;
}

.editor-help {
    background: rgba(106, 17, 203, 0.1);
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 10px;
}

.editor-help i {
    color: #6a11cb;
    margin-right: 5px;
}

.thread-buttons {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.thread-buttons button {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.thread-buttons button i {
    margin-right: 8px;
}

.thread-buttons button:first-of-type {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
}

.thread-buttons button:first-of-type:hover {
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.4);
    transform: translateY(-2px);
}

.thread-buttons button:last-of-type {
    background: rgba(51, 51, 51, 0.8);
    color: #fff;
}

.thread-buttons button:last-of-type:hover {
    background: rgba(81, 81, 81, 0.8);
}

/* Image upload section styles */
.image-upload-section {
    margin-top: 20px;
    margin-bottom: 25px;
}

.image-upload-label {
    display: inline-flex;
    align-items: center;
    padding: 10px 16px;
    background: rgba(106, 17, 203, 0.15);
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 15px;
    border: 1px dashed rgba(106, 17, 203, 0.4);
}

.image-upload-label i {
    margin-right: 8px;
    font-size: 18px;
    color: #2575fc;
}

.image-upload-label:hover {
    background: rgba(106, 17, 203, 0.25);
    transform: translateY(-2px);
}

.image-upload-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.image-preview-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.image-preview-item {
    position: relative;
    width: 100px;
    height: 100px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

.image-preview-item:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remove-image {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 20px;
    height: 20px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.image-preview-item:hover .remove-image {
    opacity: 1;
}

/* Enhanced Recent Threads Section */
.threads-section {
    margin-top: 40px;
    padding: 0;
    opacity: 0;
    animation: fadeIn 1s ease-in-out forwards;
    animation-delay: 0.3s;
}

.threads-section h2 {
    font-size: 28px;
    margin-bottom: 25px;
    color: #fff;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.threads-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #6a11cb, #2575fc);
    border-radius: 3px;
}

.threads-container {
    perspective: 1000px;
    margin-top: 20px;
}

.thread-item {
    background: rgba(30, 30, 40, 0.7);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border-left: 4px solid #6a11cb;
    transform-origin: center top;
    transform: rotateX(-90deg);
    opacity: 0;
    animation: rotateIn 0.6s ease-in-out forwards;
    transition: transform 0.3s, box-shadow 0.3s, border-left-color 0.3s;
}

.thread-item:hover {
    transform: translateY(-5px) scale(1.02) !important;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
    border-left-color: #2575fc;
    z-index: 1;
}

.thread-item .thread-header {
    margin-bottom: 15px;
}

.thread-item .thread-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 10px;
    color: #fff;
    line-height: 1.4;
}

.thread-item .thread-category {
    margin-bottom: 12px;
}

.thread-item .category-badge {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    padding: 5px 12px;
    font-size: 12px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 10px rgba(106, 17, 203, 0.3);
}

.thread-item .thread-meta {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
    color: #aaa;
    font-size: 14px;
}

.thread-item .thread-meta span {
    display: flex;
    align-items: center;
    margin-right: 15px;
    transition: color 0.2s;
}

.thread-item .thread-meta span i {
    margin-right: 5px;
    color: #6a11cb;
}

.thread-item .thread-content {
    color: #ccc;
    margin-bottom: 15px;
    line-height: 1.6;
    font-size: 15px;
}

.thread-item .thread-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

.thread-item .thread-stats {
    display: flex;
}

.thread-item .thread-read-more {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
    display: inline-block;
    box-shadow: 0 4px 10px rgba(106, 17, 203, 0.3);
}

.thread-item .thread-read-more:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(106, 17, 203, 0.4);
}

/* Staggered animation for thread items */
.thread-item:nth-child(1) { animation-delay: 0.5s; }
.thread-item:nth-child(2) { animation-delay: 0.6s; }
.thread-item:nth-child(3) { animation-delay: 0.7s; }
.thread-item:nth-child(4) { animation-delay: 0.8s; }
.thread-item:nth-child(5) { animation-delay: 0.9s; }
.thread-item:nth-child(6) { animation-delay: 1.0s; }
.thread-item:nth-child(7) { animation-delay: 1.1s; }
.thread-item:nth-child(8) { animation-delay: 1.2s; }

/* Empty state for thread items */
.no-threads {
    text-align: center;
    padding: 40px 20px;
    background: rgba(30, 30, 40, 0.7);
    border-radius: 10px;
    color: #aaa;
    border: 1px dashed rgba(106, 17, 203, 0.3);
}

.no-threads i {
    font-size: 40px;
    color: #6a11cb;
    margin-bottom: 15px;
    display: block;
}

.no-threads p {
    font-size: 16px;
    line-height: 1.6;
}

@keyframes rotateIn {
    0% {
        transform: rotateX(-90deg);
        opacity: 0;
    }
    100% {
        transform: rotateX(0);
        opacity: 1;
    }
}

/* Report details modal styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal.hide {
    display: none;
}

.modal-content {
    background-color: #1e1e28;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-content h3 {
    background: linear-gradient(45deg, #6a11cb, #2575fc);
    color: white;
    margin: 0;
    padding: 15px 20px;
    font-size: 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.report-details {
    padding: 20px;
    overflow-y: auto;
    flex-grow: 1;
    max-height: calc(90vh - 160px);
}

.report-location {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.report-location a {
    color: #2575fc;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.report-location a:hover {
    color: #6a11cb;
    text-decoration: underline;
}

.post-content-container {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.post-content-container h4 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
    color: #ccc;
    font-weight: 500;
}

.reported-post-content {
    max-height: 300px;
    overflow-y: auto;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    line-height: 1.6;
    color: #ddd;
}

.reported-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.report-info {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.report-info p {
    margin: 8px 0;
    color: #ccc;
}

.report-info strong {
    color: white;
    display: inline-block;
    width: 120px;
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    padding: 15px 20px;
    background-color: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 10px;
}

.modal-buttons button {
    padding: 8px 16px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

.resolve-btn {
    background-color: #4caf50;
    color: white;
}

.resolve-btn:hover {
    background-color: #45a049;
}

.reject-btn {
    background-color: #f44336;
    color: white;
}

.reject-btn:hover {
    background-color: #e53935;
}

.close-btn {
    background-color: #555;
    color: white;
}

.close-btn:hover {
    background-color: #444;
}

.edit-image-item.deleted {
    position: relative;
    opacity: 0.3;
    transform: scale(0.9);
}

.edit-image-item.deleted::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.edit-image-item.deleted img {
    filter: grayscale(100%);
}

.restore-image-btn {
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    z-index: 2;
}

.restore-image-btn:hover {
    background: #43A047;
    transform: scale(1.1);
}

.deleted-content {
    background-color: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
    font-size: 14px;
    margin: 10px 0;
    border: 1px dashed rgba(231, 76, 60, 0.3);
}

.deleted-content i {
    margin-right: 8px;
    font-size: 16px;
}

/* ########################################### */
/*           Categories.html                  */
/* ########################################### */

/* Category Filter Section */
.category-filter-section {
    background-color: rgba(106, 17, 203, 0.05);
    border-radius: 10px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    animation: fadeInUp var(--anim-duration-medium) ease-out;
    transition: all var(--anim-duration-fast) ease;
}

.category-filter-section:hover {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

.category-filter-section h3 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.category-filter-section h3 i {
    margin-right: 0.5rem;
    color: var(--accent-color);
}

.category-filter-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1rem;
}

.filter-dropdown, .search-container {
    flex: 1;
    min-width: 200px;
    position: relative;
}

.filter-dropdown label, .search-container label, .sort-options label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-weight: 600;
}

#category-filter {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--card-bg);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--anim-duration-fast) ease;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236a11cb' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;
}

#category-filter:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(106, 17, 203, 0.2);
    outline: none;
}

#thread-search {
    width: 100%;
    padding: 0.8rem 1rem;
    padding-right: 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--card-bg);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--anim-duration-fast) ease;
}

#thread-search:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(106, 17, 203, 0.2);
    outline: none;
}

.search-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    pointer-events: none;
    transition: all var(--anim-duration-fast) ease;
}

#thread-search:focus + .search-icon {
    color: var(--primary-color);
}

/* Search Options */
.search-options {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Checkbox styling */
.checkbox-container {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
    cursor: pointer;
    user-select: none;
    position: relative;
    padding-left: 28px;
    margin-right: 1rem;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 18px;
    width: 18px;
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    transition: all 0.2s ease;
}

.checkbox-container:hover input ~ .checkmark {
    background-color: rgba(106, 17, 203, 0.05);
    border-color: var(--primary-color);
}

.checkbox-container input:checked ~ .checkmark {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 6px;
    top: 2px;
    width: 4px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Search Results Count */
.search-results-count {
    background-color: rgba(106, 17, 203, 0.1);
    padding: 0.6rem 1rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    animation: fadeIn 0.3s ease-out;
}

.search-results-count i {
    margin-right: 0.5rem;
}

/* Search Highlighting */
.search-highlight {
    background-color: rgba(255, 222, 85, 0.6);
    color: #333;
    border-radius: 2px;
    padding: 0 2px;
    font-weight: bold;
}

/* Sort options styles */
.sort-options {
    margin-top: 1rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

.sort-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.sort-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 0.8rem;
    background-color: var(--card-bg);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--anim-duration-fast) ease;
}

.sort-btn i {
    margin-right: 0.4rem;
    font-size: 0.9rem;
}

.sort-btn:hover {
    background-color: rgba(106, 17, 203, 0.05);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.sort-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 2px 8px rgba(106, 17, 203, 0.3);
}

/* Add animation for thread sorting */
@keyframes sortAnimation {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.thread-item.sort-animation {
    animation: sortAnimation 0.5s ease-out forwards;
}

@media screen and (max-width: 768px) {
    .category-filter-container {
        flex-direction: column;
    }
    
    .filter-dropdown, .search-container {
        width: 100%;
    }
    
    .sort-buttons {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        margin-bottom: 0.5rem;
    }
    
    .sort-btn {
        flex: 0 0 auto;
        white-space: nowrap;
    }
    
    .search-options {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* Media queries for thread detail page */
@media screen and (max-width: 768px) {
    .thread-detail {
        padding: 10px;
    }
    
    .main-content {
        padding: 15px;
    }
    
    .thread-title {
        font-size: 1.5rem;
    }
    
    .thread-meta {
        flex-wrap: wrap;
    }
    
    .post-form {
        flex-direction: column;
    }

    .user-avatar {
        margin-bottom: 10px;
    }
}

@media screen and (max-width: 480px) {
    .thread-detail {
        padding: 5px;
    }
    
    .main-content {
        padding: 10px;
    }
    
    .thread-title {
        font-size: 1.3rem;
    }
    
    .thread-meta {
        font-size: 0.8rem;
    }
    
    .post {
        padding: 15px;
    }
    
    .post-header, .post-footer {
        flex-direction: column;
    }
    
    .post-actions {
        margin-top: 10px;
    }
}

/* User's own comments highlight */
.comment.own-comment {
    background-color: rgba(106, 17, 203, 0.05);
    border-left: 3px solid var(--primary-color);
}

/* Comment delete and edit buttons styling */
.delete-comment, .edit-comment {
    opacity: 0.7;
    transition: all 0.3s ease;
}

.delete-comment:hover {
    color: #d32f2f;
    opacity: 1;
}

.edit-comment:hover {
    color: #2196f3;
    opacity: 1;
}

/* Comment deletion animation */
.comment.deleting {
    animation: fadeOut 0.5s ease forwards;
    transform: translateX(10px);
    opacity: 0;
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(10px);
    }
}

/* Video upload button */
.video-upload-btn {
    background-color: #2c3e50;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    cursor: pointer;
    margin-right: 10px;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: inline-flex;
    align-items: center;
    font-size: 14px;
}

.video-upload-btn:hover {
    background-color: #1a2530;
    transform: translateY(-2px);
}

.video-upload-btn i {
    margin-right: 5px;
    font-size: 16px;
}

/* Video preview container */
.video-preview-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.video-preview-item {
    position: relative;
    width: 320px;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background-color: #f5f5f5;
    margin-bottom: 10px;
}

.video-preview-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.video-preview-item video {
    width: 100%;
    max-height: 180px;
    object-fit: cover;
    border-radius: 6px 6px 0 0;
}

.remove-video {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: rgba(44, 62, 80, 0.8);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    border: none;
    transition: background-color 0.3s ease, transform 0.2s ease;
    z-index: 10;
}

.remove-video:hover {
    background-color: rgba(231, 76, 60, 0.9);
    transform: scale(1.1);
}

/* Video in posts */
.uploaded-video {
    margin: 10px 0;
    max-width: 100%;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.uploaded-video video {
    width: 100%;
    max-height: 400px;
    border-radius: 8px;
}

/* User Management Styling */
.user-management-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
}

.user-counts {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.count-badge {
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
    color: white;
    font-size: 14px;
}

.total-users {
    background-color: #52057b;
}

.admin-users {
    background-color: #bc6ff1;
}

.moderator-users {
    background-color: #892cdc;
}

.normal-users {
    background-color: #1e96fc;
}

.search-container {
    display: flex;
    gap: 5px;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

#user-search {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 100%;
    font-size: 14px;
}

.search-btn {
    background-color: #52057b;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.search-btn:hover {
    background-color: #892cdc;
}

/* No results styling */
tr.no-results td {
    text-align: center;
    padding: 30px 10px;
    color: #777;
    font-style: italic;
    background-color: rgba(0,0,0,0.03);
    border-radius: 5px;
}

/* End of User Management Styling */
