/* ============================================
   WarboundRO – Custom Styles
   ============================================ */

/* --- Base --- */
body, html {
    height: 100%;
    min-height: 100%;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 500;
    margin: 0;
    scroll-behavior: smooth;
    background-color: #0d0d1a;
    color: #e0e0e0;
}

h1, h2, h3, h4, h5, h6,
.btn-hero-signup,
.btn-hero-login,
.btn-hero-download,
#main-nav .nav-link {
    font-family: 'Exo 2', sans-serif;
}

a:focus, a:hover {
    color: #6fcfff;
    text-decoration: none;
}

/* --- Navbar --- */
#main-nav {
    background: rgba(0, 10, 30, 0.92);
    transition: box-shadow 0.4s, padding 0.4s, right 0.3s ease;
    padding: 12px 0;
    top: 24px;
}

#main-nav.nav-scrolled {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    padding: 6px 0;
}

#main-nav .navbar-brand img {
    transition: height 0.3s;
}

#main-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 8px 10px;
    transition: color 0.2s;
    position: relative;
}

#main-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 10px;
    right: 10px;
    height: 2px;
    background: #ffb240;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

#main-nav .nav-link:hover::after,
#main-nav .nav-link:focus::after {
    transform: scaleX(1);
}

#main-nav .nav-link:hover,
#main-nav .nav-link:focus {
    color: #ffb240;
}

#main-nav .navbar-toggler {
    margin-right: 8px;
}

#main-nav .navbar-brand {
    margin-left: 8px;
}

/* --- Page Loader --- */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99999;
    background: #0a0e1a;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.4s ease;
}
#page-loader.loaded {
    opacity: 0;
    pointer-events: none;
}

/* --- Hero / Splash --- */
#splash {
    background: url('../img/bg-lg3.jpg') center / cover no-repeat;
    background: image-set(
        url('../img/bg-lg3.webp') type('image/webp'),
        url('../img/bg-lg3.jpg')  type('image/jpeg')
    ) center / cover no-repeat;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    position: relative;
}
@media (max-width: 1024px) {
    #splash {
        background: url('../img/bg-md3.jpg') center / cover no-repeat;
        background: image-set(
            url('../img/bg-md3.webp') type('image/webp'),
            url('../img/bg-md3.jpg')  type('image/jpeg')
        ) center / cover no-repeat;
    }
}
@media (max-width: 640px) {
    #splash {
        background: url('../img/bg-sm3.jpg') center / cover no-repeat;
        background: image-set(
            url('../img/bg-sm3.webp') type('image/webp'),
            url('../img/bg-sm3.jpg')  type('image/jpeg')
        ) center / cover no-repeat;
    }
}

#splash::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 70% 70% at center 45%, transparent 0%, rgba(0, 5, 20, 0.55) 100%),
        linear-gradient(
            to bottom,
            rgba(0, 10, 30, 0.4) 0%,
            rgba(0, 0, 0, 0.05) 35%,
            rgba(0, 0, 0, 0.05) 55%,
            rgba(0, 10, 30, 0.5) 100%
        );
    pointer-events: none;
    z-index: 0;
}

#splash > * {
    position: relative;
    z-index: 1;
}

#splash > .hero-scroll-hint {
    position: absolute;
}

#splash .img-fluid {
    max-width: 500px;
    width: 80%;
    filter: drop-shadow(0 4px 20px rgba(0, 0, 0, 0.6)) drop-shadow(0 0 40px rgba(0, 60, 160, 0.25));
    margin-bottom: 20px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 20px;
}

.btn-hero-signup {
    background: linear-gradient(135deg, #ff8a00, #ffcc00);
    color: #1a1a1a;
    font-weight: 700;
    font-size: 15px;
    min-width: 190px;
    padding: 14px 28px;
    border: none;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-hero-signup:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(255, 140, 0, 0.5);
    color: #1a1a1a;
}

.btn-hero-download {
    background: transparent;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    min-width: 190px;
    padding: 14px 28px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn-hero-download:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 6px 24px rgba(255, 255, 255, 0.15);
    color: #fff;
}

.hero-tagline {
    color: #ffefb8;
    font-size: 20px;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    margin: 10px 0;
}

.btn-hero-login {
    background: transparent;
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    min-width: 190px;
    padding: 14px 28px;
    border: 2px solid rgba(255, 178, 64, 0.6);
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn-hero-login:hover {
    transform: translateY(-2px);
    background: rgba(255, 178, 64, 0.15);
    border-color: #ffb240;
    box-shadow: 0 6px 24px rgba(255, 178, 64, 0.3);
    color: #fff;
}

/* --- Server Status Bar --- */
#server-status {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1031;
    transition: right 0.3s ease;
    background: rgba(0, 5, 15, 0.9);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding: 4px 0;
}

.status-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #666;
    display: inline-block;
    transition: background 0.3s;
}

.status-dot.online {
    background: #4cff4c;
    box-shadow: 0 0 6px rgba(76, 255, 76, 0.6);
}

.status-dot.offline {
    background: #ff4c4c;
    box-shadow: 0 0 6px rgba(255, 76, 76, 0.6);
}

.status-dot.loading {
    background: #ffcc00;
    box-shadow: 0 0 6px rgba(255, 204, 0, 0.6);
    animation: pulse 1.2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.status-label {
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Exo 2', sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-icon {
    color: #ffb240;
    font-size: 11px;
}

.status-divider {
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.15);
}

/* Count change animation */
.count-updated {
    animation: countPop 0.8s ease;
}

@keyframes countPop {
    0% { transform: scale(1); color: inherit; }
    30% { transform: scale(1.3); color: #4cff4c; }
    100% { transform: scale(1); color: inherit; }
}

.status-dot.status-changed {
    animation: dotFlash 0.6s ease;
}

@keyframes dotFlash {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.8); }
}

/* --- Section common --- */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header .section-icon {
    padding: 20px;
    margin-bottom: 16px;
}

.section-header h2 {
    text-transform: uppercase;
    color: #ffb240;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    font-weight: 700;
    margin-bottom: 10px;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    display: block;
    width: 60%;
    height: 3px;
    margin: 8px auto 0;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, #ffb240, transparent);
}

.section-header p {
    color: rgba(255,255,255,0.85);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    max-width: 500px;
    margin: 0 auto;
}

/* --- Patch Notes (used on /news/) --- */
#patch-notes {
    text-align: left;
}

.patch-card {
    background: rgba(0, 10, 30, 0.5);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid rgba(255,255,255,0.08);
    border-top: 3px solid #ffb240;
    border-radius: 10px;
    padding: 24px 28px;
    margin-bottom: 24px;
    position: relative;
    transition: transform 0.3s, background 0.3s, box-shadow 0.3s;
}

.patch-card:hover {
    transform: translateY(-3px);
    background: rgba(0, 10, 30, 0.65);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.patch-date {
    display: inline-block;
    color: #1a1a1a;
    background: linear-gradient(135deg, #ffb240, #ffcc00);
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 13px;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 14px;
    letter-spacing: 0.5px;
}

.patch-card ul {
    color: rgba(255,255,255,0.9);
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    padding-left: 20px;
    margin-bottom: 0;
    font-size: 15px;
    line-height: 1.6;
}

.patch-card.truncated ul {
    max-height: 320px;
    overflow: hidden;
}

.patch-card.truncated::after {
    content: '';
    position: absolute;
    bottom: 44px;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to bottom, rgba(0,10,30,0) 0%, rgba(0,10,30,0.85) 100%);
    pointer-events: none;
    border-radius: 0 0 10px 10px;
}

.patch-card.expanded ul {
    max-height: none;
    overflow: visible;
}

.patch-card.expanded::after {
    display: none;
}

.patch-toggle {
    display: block;
    margin-top: 12px;
    background: none;
    border: 1px solid rgba(255,178,64,0.4);
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-size: 13px;
    font-weight: 600;
    padding: 5px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    text-align: center;
    width: 100%;
}

.patch-toggle:hover {
    background: rgba(255,178,64,0.12);
    border-color: #ffb240;
}

.patch-card li {
    margin-bottom: 6px;
}

.patch-card li:last-child {
    margin-bottom: 0;
}

/* --- Homepage Features --- */
#features {
    padding: 80px 0 40px;
    background: linear-gradient(180deg, rgba(10, 14, 26, 0.0) 0%, rgba(0, 10, 30, 0.6) 100%);
}

#news-1 {
    padding: 40px 0 80px;
}

.feature-tile {
    text-align: center;
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.feature-tile-icon {
    font-size: 32px;
    color: #ffb240;
    margin-bottom: 16px;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 178, 64, 0.08);
    border: 1px solid rgba(255, 178, 64, 0.15);
}

.feature-tile h5 {
    color: #fff;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 17px;
    margin-bottom: 10px;
}

.feature-tile p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 0;
}

/* --- Footer --- */
#site-footer {
    background: rgba(0, 5, 15, 0.95);
    margin-top: 0;
    position: relative;
}

.footer-inner {
    padding: 40px 0 20px;
    padding-bottom: 40px;
}

.footer-logo {
    max-width: 200px;
    margin-bottom: 12px;
}

.footer-tagline {
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    line-height: 1.6;
}

.footer-heading {
    color: #ffb240;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 2px;
    margin-bottom: 14px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.75);
    font-size: 13px;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #fff;
}

.footer-social-icons {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.footer-social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.8);
    font-size: 16px;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.footer-social-icons a[aria-label="Facebook"]:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: #fff;
}

.footer-social-icons a[aria-label="Discord"]:hover {
    background: #5865f2;
    border-color: #5865f2;
    color: #fff;
}

.footer-divider {
    border-color: rgba(255, 255, 255, 0.1);
    margin: 24px 0 16px;
}

.footer-copy {
    color: rgba(255, 255, 255, 0.35);
    font-size: 11px;
    text-align: center;
    margin: 0;
}

@media (min-width: 768px) {
    .footer-social-icons {
        justify-content: flex-end;
    }
}

@media (max-width: 767px) {
    .footer-inner {
        text-align: center;
    }

    .footer-brand,
    .footer-links,
    .footer-social {
        margin-bottom: 24px;
    }

    .footer-social-icons {
        justify-content: center;
    }
}

/* --- Auth Modal --- */
.auth-modal {
    background: rgba(0, 15, 40, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 40px 36px 32px;
    color: #fff;
    box-shadow: 0 16px 64px rgba(0, 0, 0, 0.6);
}

.auth-close {
    position: absolute;
    top: 14px;
    right: 18px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 24px;
    opacity: 1;
    text-shadow: none;
    transition: color 0.2s;
    z-index: 1;
}

.auth-close:hover {
    color: #ffb240;
}

.auth-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 28px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 4px;
}

.auth-tab {
    flex: 1;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 10px 0;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s, color 0.3s;
}

.auth-tab.active {
    background: linear-gradient(135deg, #ff8a00, #ffcc00);
    color: #1a1a1a;
}

.auth-tab:hover:not(.active) {
    color: rgba(255, 255, 255, 0.8);
}

.auth-form label {
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Exo 2', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.auth-form label i {
    margin-right: 4px;
    color: #ffb240;
    font-size: 11px;
}

.auth-form .form-control {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    color: #fff;
    padding: 10px 14px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.auth-form .form-control:focus {
    background: rgba(0, 0, 0, 0.5);
    border-color: #ffb240;
    box-shadow: 0 0 0 3px rgba(255, 178, 64, 0.15);
    color: #fff;
}

.auth-form .form-control::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.auth-form select.form-control {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23ffb240' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.btn-auth-submit {
    width: 100%;
    background: linear-gradient(135deg, #ff8a00, #ffcc00);
    color: #1a1a1a;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px;
    border: none;
    border-radius: 10px;
    margin-top: 8px;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(255, 140, 0, 0.4);
    color: #1a1a1a;
}

.btn-auth-submit:disabled {
    opacity: 0.6;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

.auth-switch {
    text-align: center;
    margin: 16px 0 0;
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
}

.auth-switch a {
    color: #ffb240;
    font-weight: 600;
    text-decoration: none;
}

.auth-switch a:hover {
    color: #ffcc00;
    text-decoration: underline;
}

.auth-alert {
    background: rgba(255, 76, 76, 0.15);
    border: 1px solid rgba(255, 76, 76, 0.3);
    border-radius: 8px;
    color: #ff7b7b;
    font-size: 13px;
    padding: 10px 14px;
    margin-bottom: 16px;
}

.auth-alert.auth-success {
    background: rgba(76, 255, 76, 0.1);
    border-color: rgba(76, 255, 76, 0.3);
    color: #7bff7b;
}

.auth-form-desc {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    margin-bottom: 16px;
    line-height: 1.5;
}

/* Navbar auth buttons */
.nav-signup-btn {
    color: #ffb240 !important;
    font-weight: 700 !important;
}

.nav-signup-btn:hover {
    color: #ffcc00 !important;
}


/* User dropdown */
#main-nav .dropdown-menu {
    background: rgba(0, 15, 40, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 8px 0;
    margin-top: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

#main-nav .dropdown-item {
    color: rgba(255, 255, 255, 0.8);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    padding: 8px 20px;
    transition: background 0.2s, color 0.2s;
}

#main-nav .dropdown-item:hover,
#main-nav .dropdown-item:focus {
    background: rgba(255, 178, 64, 0.1);
    color: #ffb240;
}

#main-nav .dropdown-item i {
    width: 18px;
    margin-right: 6px;
    text-align: center;
    color: #ffb240;
    font-size: 12px;
}

#main-nav .dropdown-divider {
    border-color: rgba(255, 255, 255, 0.08);
}

#main-nav .dropdown-header {
    color: rgba(255, 178, 64, 0.6);
    font-family: 'Exo 2', sans-serif;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 6px 20px 2px;
}

#userDropdown {
    color: #ffb240 !important;
    font-weight: 600;
}

#userDropdown i {
    margin-right: 4px;
}

/* --- Scroll-to-top --- */
.cd-top {
    display: inline-block;
    height: 52px;
    width: 52px;
    position: fixed;
    bottom: 24px;
    right: 24px;
    overflow: hidden;
    text-indent: 100%;
    white-space: nowrap;
    background: url('../../assets/img/to-top.png') center 50% no-repeat rgba(255, 138, 0, 0.8);
    background-size: 18px;
    border-radius: 50%;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s, visibility 0.3s, transform 0.2s, right 0.3s ease;
    z-index: 9999;
}

.cd-top:hover {
    transform: translateY(-3px);
    background-color: #ff8a00;
}

.cd-top.cd-is-visible {
    visibility: visible;
    opacity: 1;
}

.cd-top.cd-fade-out {
    opacity: 0.5;
}

@media (min-width: 768px) {
    .cd-top {
        right: 24px;
        bottom: 24px;
    }
}

@media (min-width: 1024px) {
    .cd-top {
        height: 52px;
        width: 52px;
        right: 24px;
        bottom: 24px;
    }
}

/* --- Responsive --- */
@media (max-width: 767px) {
    #splash .img-fluid {
        max-width: 90%;
    }

    .hero-scroll-hint {
        display: none;
    }

    .hero-tagline {
        font-size: 15px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    .btn-hero-signup,
    .btn-hero-login,
    .btn-hero-download {
        min-width: 200px;
        width: auto;
        max-width: none;
        padding: 12px 32px;
        font-size: 14px;
        white-space: nowrap;
    }

    .section-header {
        margin-bottom: 30px;
    }

    .section-header h2 {
        font-size: 22px;
    }

    #features, #news-1 {
        padding: 60px 0;
    }

    .feature-card {
        margin-bottom: 20px;
    }

    .feature-card > .row {
        padding: 14px;
        flex-direction: column;
        text-align: center;
    }

    .feature-card img {
        max-width: 200px;
        margin: 0 auto 16px;
    }

    .patch-card {
        margin-bottom: 0;
    }

    #patch-notes > [class*="col"] {
        margin-bottom: 16px;
    }

    #patch-notes > [class*="col"]:last-child {
        margin-bottom: 0;
    }

    #news-1 {
        padding-bottom: 120px;
    }

}

/* Body scroll lock when mobile nav is open */
body.nav-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
}

@media (max-width: 1199px) {
    .navbar-collapse {
        background: rgba(0, 10, 30, 0.98);
        padding: 10px 20px;
        border-radius: 0 0 8px 8px;
        margin-top: 8px;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    #main-nav,
    #main-nav.nav-scrolled {
        padding: 8px 0;
    }

    #main-nav .nav-link::after {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .feature-card .col-lg-5 {
        flex: 0 0 100%;
        max-width: 100%;
        text-align: center;
        margin-bottom: 12px;
    }

    .feature-card .col-lg-5 img {
        max-width: 220px;
    }

    .feature-card .col {
        flex: 0 0 100%;
        max-width: 100%;
        text-align: center;
    }

    #news-1 {
        padding-bottom: 100px;
    }
}

/* --- Panel Pages --- */
#panel-header {
    padding: 120px 0 40px;
    background: linear-gradient(135deg, rgba(0, 10, 30, 0.95), rgba(0, 25, 60, 0.9));
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

#panel-header h1 {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 800;
    font-size: 28px;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
}

#panel-header h1 i {
    margin-right: 8px;
    font-size: 24px;
}

.panel-subtitle {
    color: rgba(255, 255, 255, 0.5);
    font-size: 15px;
    margin: 0;
}

/* Per-page header color themes */
#panel-header.theme-pets {
    background: linear-gradient(135deg, #0d1117 0%, #0b2e1a 50%, #1a3a1a 100%);
    border-bottom: 2px solid #27ae60;
}
#panel-header.theme-pets h1 { color: #27ae60; }

#panel-header.theme-cards {
    background: linear-gradient(135deg, #0d1117 0%, #2a0e0e 50%, #3d1010 100%);
    border-bottom: 2px solid #e74c3c;
}
#panel-header.theme-cards h1 { color: #e74c3c; }

#panel-header.theme-headgears {
    background: linear-gradient(135deg, #0d1117 0%, #241433 50%, #34194d 100%);
    border-bottom: 2px solid #9b59b6;
}
#panel-header.theme-headgears h1 { color: #bb8fce; }

#panel-header.theme-achievements {
    background: linear-gradient(135deg, #0d1117 0%, #2e2205 50%, #3d2e00 100%);
    border-bottom: 2px solid #f1c40f;
}
#panel-header.theme-achievements h1 { color: #f1c40f; }

#panel-header.theme-mvp {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    border-bottom: 3px solid #e74c3c;
}
#panel-header.theme-mvp h1 { color: #fff; }
#panel-header.theme-mvp h1 i { color: #e74c3c; }

#panel-header.theme-economy {
    background: linear-gradient(135deg, #0d1117 0%, #1e1a0a 50%, #2e2810 100%);
    border-bottom: 2px solid #f39c12;
}
#panel-header.theme-economy h1 { color: #fff; }
#panel-header.theme-economy h1 i { color: #f39c12; }

#panel-header.theme-skills {
    background: linear-gradient(135deg, #0d1117 0%, #0a1a2e 50%, #0a2a3d 100%);
    border-bottom: 2px solid #4fc3f7;
}
#panel-header.theme-skills h1 { color: #4fc3f7; }

#panel-header.theme-stats {
    background: linear-gradient(135deg, #0d1117 0%, #0e1e3a 50%, #102a50 100%);
    border-bottom: 2px solid #3498db;
}
#panel-header.theme-stats h1 { color: #fff; }
#panel-header.theme-stats h1 i { color: #3498db; }

#panel-header.theme-worldmap {
    background: linear-gradient(135deg, #0d1b2a 0%, #1b2838 50%, #0f3460 100%);
    border-bottom: 3px solid #1abc9c;
}
#panel-header.theme-worldmap h1 { color: #fff; }

#panel-header.theme-warroom {
    background: linear-gradient(135deg, #1a0a2e 0%, #2d1b4e 50%, #3a1a5e 100%);
    border-bottom: 3px solid #9b59b6;
}
#panel-header.theme-warroom h1 { color: #fff; }

#panel-header.theme-timeline {
    background: linear-gradient(135deg, #0d1117 0%, #1e1510 50%, #2e1e0a 100%);
    border-bottom: 2px solid #e67e22;
}
#panel-header.theme-timeline h1 { color: #e67e22; }

#panel-header.theme-database {
    background: linear-gradient(135deg, #0d1117 0%, #1a1510 50%, #261e0a 100%);
    border-bottom: 2px solid #ffb240;
}
#panel-header.theme-database h1 { color: #ffb240; }

#panel-header.theme-rankings {
    background: linear-gradient(135deg, #0d1117 0%, #2d1b00 50%, #3a2200 100%);
    border-bottom: 2px solid #ffd700;
}
#panel-header.theme-rankings h1 { color: #ffd700; }

#panel-header.theme-wiki {
    background: linear-gradient(135deg, #0d1117 0%, #0b2e1a 50%, #0a3a22 100%);
    border-bottom: 2px solid #2ecc71;
}
#panel-header.theme-wiki h1 { color: #2ecc71; }

#panel-header.theme-forum {
    background: linear-gradient(135deg, #0d1117 0%, #101e38 50%, #142a4e 100%);
    border-bottom: 2px solid #5dade2;
}
#panel-header.theme-forum h1 { color: #5dade2; }

#panel-header.theme-character {
    background: linear-gradient(135deg, #0d1117 0%, #0a2420 50%, #0e3a30 100%);
    border-bottom: 2px solid #76d7c4;
}
#panel-header.theme-character h1 { color: #76d7c4; }

#panel-header.theme-market {
    background: linear-gradient(135deg, #0d1117 0%, #2a1028 50%, #3a1638 100%);
    border-bottom: 2px solid #e88be4;
}
#panel-header.theme-market h1 { color: #e88be4; }

#panel-header.theme-guild {
    background: linear-gradient(135deg, #0d1117 0%, #2e1a0a 50%, #3e2410 100%);
    border-bottom: 2px solid #e67e22;
}
#panel-header.theme-guild h1 { color: #e67e22; }

#panel-header.theme-donate {
    background: linear-gradient(135deg, #0d1117 0%, #2e0a1a 50%, #3d0e24 100%);
    border-bottom: 2px solid #ff6b8a;
}
#panel-header.theme-donate h1 { color: #ff6b8a; }

#panel-header.theme-download {
    background: linear-gradient(135deg, #0d1117 0%, #0a2028 50%, #0e2e36 100%);
    border-bottom: 2px solid #00bcd4;
}
#panel-header.theme-download h1 { color: #00bcd4; }

#panel-header.theme-support {
    background: linear-gradient(135deg, #0d1117 0%, #0a1e2e 50%, #0e2a3e 100%);
    border-bottom: 2px solid #83cfe9;
}
#panel-header.theme-support h1 { color: #83cfe9; }

/* ── Support Page ──────────────────────────────────────────── */

.support-help-banner {
    background: rgba(131,207,233,0.06);
    border: 1px solid rgba(131,207,233,0.12);
    border-radius: 8px;
    padding: 16px 20px;
}
.support-help-banner h5 {
    color: #eee;
    margin-bottom: 4px;
}

.support-ticket-list .list-group-item:hover {
    background: rgba(131,207,233,0.06) !important;
    border-color: rgba(131,207,233,0.15) !important;
}

.support-detail-messages {
    max-height: 500px;
    overflow-y: auto;
}

.support-new-ticket {
    background: rgba(26,26,46,0.4);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 24px;
}

#panel-header.theme-shop {
    background: linear-gradient(135deg, #0d1117 0%, #24200a 50%, #302a0e 100%);
    border-bottom: 2px solid #f39c12;
}
#panel-header.theme-shop h1 { color: #f39c12; }

#panel-header.theme-woe {
    background: linear-gradient(135deg, #0d1117 0%, #2e0a10 50%, #3d0e18 100%);
    border-bottom: 2px solid #c0392b;
}
#panel-header.theme-woe h1 { color: #c0392b; }

#panel-header.theme-admin {
    background: linear-gradient(135deg, #0d1117 0%, #0a2e22 50%, #0e3a2c 100%);
    border-bottom: 2px solid #1abc9c;
}
#panel-header.theme-admin h1 { color: #1abc9c; }

#panel-header.theme-news {
    background: linear-gradient(135deg, #0d1117 0%, #1e1510 50%, #2e1e0a 100%);
    border-bottom: 2px solid #e67e22;
}
#panel-header.theme-news h1 { color: #e67e22; }

#panel-content {
    padding: 40px 0 60px;
    min-height: 60vh;
    background:
        radial-gradient(ellipse 80% 80% at center 30%, rgba(0, 15, 50, 0.3) 0%, rgba(0, 5, 20, 0.7) 100%),
        #060d1a;
}

.panel-card {
    background: rgba(0, 15, 40, 0.55);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 28px;
    height: 100%;
    transition: transform 0.3s, box-shadow 0.3s;
}

.panel-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.panel-card-title {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.panel-card-title i {
    margin-right: 8px;
    font-size: 14px;
}

.panel-info-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.panel-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.panel-info-row:last-child {
    border-bottom: none;
}

.panel-info-label {
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
}

.panel-info-value {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 600;
}

.credits-display {
    text-align: center;
    padding: 30px 0;
}

.credits-amount {
    display: block;
    color: #ffcc00;
    font-family: 'Exo 2', sans-serif;
    font-size: 48px;
    font-weight: 800;
    line-height: 1;
    text-shadow: 0 0 20px rgba(255, 204, 0, 0.3);
    margin-bottom: 8px;
}

.credits-label {
    display: block;
    color: rgba(255, 255, 255, 0.4);
    font-family: 'Exo 2', sans-serif;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Panel forms reuse .auth-form styles */
.panel-card .form-group {
    margin-bottom: 16px;
}

.panel-card label {
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Exo 2', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.panel-card .form-control {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    color: #fff;
    padding: 10px 14px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.panel-card .form-control:focus {
    background: rgba(0, 0, 0, 0.5);
    border-color: #ffb240;
    box-shadow: 0 0 0 3px rgba(255, 178, 64, 0.15);
    color: #fff;
}

@media (max-width: 767px) {
    #panel-header {
        padding: 100px 0 30px;
    }

    #panel-header h1 {
        font-size: 22px;
    }

    .panel-card {
        padding: 20px;
    }

    .credits-amount {
        font-size: 36px;
    }
}

/* ============================================
   Market System
   ============================================ */

/* --- Controls --- */
.market-controls {
    margin-bottom: 30px;
}

.market-search {
    margin-bottom: 20px;
}

.market-search .input-group-text {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
}

.market-search .form-control {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    padding: 10px 16px;
    height: auto;
}

.market-search .form-control::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.market-search .form-control:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 178, 64, 0.4);
    box-shadow: 0 0 0 0.2rem rgba(255, 178, 64, 0.15);
    color: #fff;
}

/* --- Tabs --- */
.market-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.market-tab {
    flex: 1;
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.5);
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.market-tab:hover {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.8);
    border-color: rgba(255, 255, 255, 0.15);
}

.market-tab.active {
    background: rgba(255, 178, 64, 0.12);
    border-color: rgba(255, 178, 64, 0.3);
    color: #ffb240;
}

.market-tab i {
    font-size: 16px;
}

.market-tab-count {
    background: rgba(255, 255, 255, 0.1);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
    min-width: 24px;
    text-align: center;
}

.market-tab.active .market-tab-count {
    background: rgba(255, 178, 64, 0.25);
    color: #ffb240;
}

/* --- Panels --- */
.market-panel {
    min-height: 200px;
}

.market-loading {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.4);
}

.market-loading i {
    color: #ffb240;
    margin-bottom: 15px;
}

.market-empty {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.3);
}

.market-empty i {
    margin-bottom: 20px;
    opacity: 0.3;
}

.market-empty h4 {
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 8px;
}

/* --- Shop Cards --- */
.market-shop {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    margin-bottom: 16px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.market-shop:hover {
    border-color: rgba(255, 178, 64, 0.25);
}

.market-shop-buying {
    border-left: 3px solid rgba(76, 175, 80, 0.4);
}

.market-shop-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.shop-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.shop-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    margin: 0;
    width: 100%;
}

.shop-title i {
    color: #ffb240;
    margin-right: 6px;
    font-size: 14px;
}

.market-shop-buying .shop-title i {
    color: #4caf50;
}

.shop-meta {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.45);
}

.shop-meta i {
    margin-right: 4px;
    width: 14px;
    text-align: center;
}

.shop-item-count,
.shop-zeny-limit {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.4);
    white-space: nowrap;
    padding-top: 2px;
}

.shop-zeny-limit i {
    color: #ffb240;
}

/* --- Item Tables --- */
.market-items-table {
    overflow-x: auto;
}

.market-items-table table {
    width: 100%;
    border-collapse: collapse;
}

.market-items-table thead th {
    padding: 10px 20px;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.35);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.market-items-table tbody td {
    padding: 10px 20px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.market-items-table tbody tr:last-child td {
    border-bottom: none;
}

.market-items-table tbody tr:hover td {
    background: rgba(255, 255, 255, 0.03);
}

.item-name-cell {
    font-weight: 500;
    white-space: nowrap;
}

.item-cards {
    color: rgba(255, 178, 64, 0.7);
    font-size: 12px;
}

.price-cell {
    color: #ffb240;
    font-weight: 600;
    white-space: nowrap;
}

.price-cell.buynow {
    color: #4caf50;
}

.time-urgent {
    color: #ff6b6b !important;
    font-weight: 600;
}

/* --- Item Type Badges --- */
.item-type-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.type-weapon {
    background: rgba(244, 67, 54, 0.15);
    color: #f44336;
}

.type-armor {
    background: rgba(33, 150, 243, 0.15);
    color: #2196f3;
}

.type-card {
    background: rgba(156, 39, 176, 0.15);
    color: #ce93d8;
}

.type-usable {
    background: rgba(76, 175, 80, 0.15);
    color: #4caf50;
}

.type-etc {
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.45);
}

/* --- Auction Table --- */
.market-auction-table {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
}

/* --- Refresh Indicator --- */
.market-refresh-info {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.2);
    font-size: 13px;
}

.market-refresh-info i {
    margin-right: 4px;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .market-tab span:not(.market-tab-count) {
        display: none;
    }

    .market-tab {
        min-width: auto;
        padding: 10px 16px;
    }

    .market-shop-header {
        flex-direction: column;
        gap: 8px;
    }

    .market-items-table thead { display: none; }
    .market-items-table tbody tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(255,255,255,0.04);
        border-radius: 8px;
        border: 1px solid rgba(255,255,255,0.08);
        padding: 10px 12px;
    }
    .market-items-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 3px 0;
        border: none;
        font-size: 13px;
        text-align: right;
    }
    .market-items-table tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255,255,255,0.45);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        min-width: 80px;
        flex-shrink: 0;
        text-align: left;
    }
    .market-items-table tbody td.item-name-cell {
        font-size: 15px;
        font-weight: 600;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        padding-bottom: 6px;
        margin-bottom: 2px;
    }
}

/* ========================================
   DATABASE BROWSER
   ======================================== */

.db-controls {
    margin-bottom: 20px;
}

.db-panel {
    display: none;
}
.db-panel.active {
    display: block;
}

/* Search row */
.db-search-row {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.db-search .input-group {
    background: rgba(255,255,255,0.06);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
}
.db-search .input-group-text {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.5);
}
.db-search .form-control {
    background: transparent;
    border: none;
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
}
.db-search .form-control::placeholder {
    color: rgba(255,255,255,0.35);
}
.db-search .form-control:focus {
    box-shadow: none;
    outline: none;
}

/* Filter pills */
.db-filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.db-subtype-filters {
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.db-pill {
    padding: 4px 14px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.db-pill:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
}
.db-pill.active {
    background: rgba(212,175,55,0.2);
    border-color: rgba(212,175,55,0.5);
    color: #d4af37;
}
.db-pill.mvp-pill {
    border-color: rgba(212,175,55,0.3);
}
.db-pill.mvp-pill.active {
    background: rgba(212,175,55,0.3);
    border-color: #d4af37;
    color: #d4af37;
}
.db-pill.natural-pill {
    border-color: rgba(91,192,222,0.3);
}
.db-pill.natural-pill.active {
    background: rgba(91,192,222,0.2);
    border-color: #5bc0de;
    color: #5bc0de;
}

.db-select {
    padding: 4px 10px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.7);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    cursor: pointer;
}
.db-select:focus {
    outline: none;
    border-color: rgba(212,175,55,0.5);
}
.db-select option {
    background: #1a1a2e;
    color: #fff;
}
.db-level-input {
    width: 80px;
}
.db-level-input::placeholder {
    color: rgba(255,255,255,0.35);
}
/* Hide number input spinners */
.db-level-input::-webkit-outer-spin-button,
.db-level-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.db-level-input[type=number] {
    -moz-appearance: textfield;
}

/* Loading & Empty */
.db-loading, .db-empty {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255,255,255,0.5);
}
.db-loading i, .db-empty i {
    margin-bottom: 15px;
    color: rgba(212,175,55,0.5);
}
.db-empty h4 {
    color: rgba(255,255,255,0.6);
    font-family: 'Exo 2', sans-serif;
}

/* Table */
.db-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: rgba(255,255,255,0.03);
    border-radius: 10px;
    overflow: hidden;
}
.db-table thead th {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.5);
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    white-space: nowrap;
}
.db-table tbody td {
    padding: 10px 14px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    color: rgba(255,255,255,0.8);
    border-bottom: 1px solid rgba(255,255,255,0.04);
    white-space: nowrap;
}
.db-row {
    cursor: pointer;
    transition: background 0.15s;
}
.db-row:hover {
    background: rgba(212,175,55,0.08);
}
.db-row.mvp-row {
    background: rgba(212,175,55,0.04);
}
.db-row.mvp-row:hover {
    background: rgba(212,175,55,0.12);
}

.col-id {
    width: 70px;
    color: rgba(255,255,255,0.4) !important;
    font-size: 13px !important;
}
.col-name {
    min-width: 200px;
}
.col-stat {
    text-align: center;
}
.col-price, .col-exp {
    text-align: right;
    color: #d4af37 !important;
}
.col-elem {
    text-align: center;
}

.item-name-cell .item-type-badge {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 3px;
    margin-right: 4px;
    vertical-align: middle;
}

/* Slot dots */
.slot-dots {
    display: inline-flex;
    gap: 3px;
}
.slot-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(212,175,55,0.5);
    border: 1px solid rgba(212,175,55,0.8);
    display: inline-block;
}

/* MVP badge */
.mvp-badge {
    color: #d4af37;
    font-size: 14px;
}

/* Element badges */
.elem-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}
.elem-neutral { background: rgba(180,180,180,0.2); color: #ccc; }
.elem-water { background: rgba(64,150,255,0.2); color: #5ab5ff; }
.elem-earth { background: rgba(139,119,42,0.3); color: #c4a94d; }
.elem-fire { background: rgba(255,80,40,0.2); color: #ff6b4a; }
.elem-wind { background: rgba(100,220,100,0.2); color: #6ddb6d; }
.elem-poison { background: rgba(160,80,200,0.2); color: #c070e8; }
.elem-holy { background: rgba(255,240,150,0.2); color: #ffe680; }
.elem-shadow { background: rgba(100,60,140,0.3); color: #a07dd0; }
.elem-ghost { background: rgba(200,200,255,0.15); color: #c8c8ff; }
.elem-undead { background: rgba(90,30,30,0.3); color: #c04040; }

/* Pagination */
.db-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 12px 0;
}
.db-page-info {
    color: rgba(255,255,255,0.4);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}
.db-page-btns {
    display: flex;
    gap: 4px;
    align-items: center;
}
.db-page-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.db-page-btn:hover {
    background: rgba(212,175,55,0.15);
    border-color: rgba(212,175,55,0.3);
    color: #d4af37;
}
.db-page-btn.active {
    background: rgba(212,175,55,0.25);
    border-color: #d4af37;
    color: #d4af37;
}
.db-page-dots {
    color: rgba(255,255,255,0.3);
    padding: 0 4px;
}
.db-custom-page-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 12px;
    padding: 8px 0;
}

/* Detail Modal */
.db-modal-content {
    background: linear-gradient(135deg, rgba(15,15,30,0.98), rgba(25,20,40,0.98));
    border: 1px solid rgba(212,175,55,0.2);
    border-radius: 12px;
    backdrop-filter: blur(20px);
    color: #fff;
}
.db-modal-header {
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding: 16px 24px;
}
.db-modal-header .close {
    color: rgba(255,255,255,0.5);
    text-shadow: none;
    opacity: 0.7;
}
.db-modal-header .modal-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
}

.db-detail {
    padding: 8px 0;
}

.db-detail-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin-bottom: 20px;
    background: rgba(0,0,0,0.2);
    border-radius: 8px;
    overflow: hidden;
}

.db-stat-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.db-stat-row:nth-child(odd) {
    background: rgba(255,255,255,0.02);
}
.db-stat-label {
    color: rgba(255,255,255,0.5);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
}
.db-stat-val {
    color: rgba(255,255,255,0.9);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}

/* Sub-stats grid (STR/AGI/VIT/INT/DEX/LUK) */
.db-stat-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}
.db-stat-cell {
    text-align: center;
    background: rgba(255,255,255,0.04);
    border-radius: 6px;
    padding: 8px 4px;
}
.db-stat-cell .db-stat-label {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.4);
    margin-bottom: 2px;
}
.db-stat-cell .db-stat-val {
    display: block;
    font-size: 18px;
    font-weight: 600;
    color: #d4af37;
}

.db-detail-substats {
    margin-bottom: 20px;
}

.db-detail-section {
    margin-bottom: 20px;
}
.db-detail-section h6 {
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,0.6);
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.db-detail-section h6 i {
    color: #d4af37;
    margin-right: 6px;
}

/* ── Drop Rate Modifier Panel ── */
.drop-mod-panel {
    margin-bottom: 20px;
    border: 1px solid rgba(212,175,55,0.2);
    border-radius: 10px;
    overflow: hidden;
    background: rgba(0,0,0,0.2);
}
.drop-mod-header {
    background: rgba(212,175,55,0.1);
    padding: 10px 16px;
    font-family: 'Exo 2', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: #d4af37;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.drop-mod-header i {
    margin-right: 6px;
}
.drop-mod-body {
    padding: 14px 16px;
}

/* LUK slider row */
.drop-mod-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}
.drop-mod-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255,255,255,0.6);
    min-width: 40px;
    flex-shrink: 0;
}
.drop-mod-slider {
    flex: 1;
    min-width: 0;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
    touch-action: none;
}
.drop-mod-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d4af37;
    border: 2px solid #1a1a2e;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}
.drop-mod-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #d4af37;
    border: 2px solid #1a1a2e;
    cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}
.drop-mod-num {
    width: 56px;
    text-align: center;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 6px;
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    padding: 4px 6px;
    flex-shrink: 0;
}
.drop-mod-num:focus {
    outline: none;
    border-color: rgba(212,175,55,0.5);
}
/* hide spinners */
.drop-mod-num::-webkit-outer-spin-button,
.drop-mod-num::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.drop-mod-num[type=number] { -moz-appearance: textfield; }

.drop-mod-mult {
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: #d4af37;
    min-width: 50px;
    text-align: right;
    flex-shrink: 0;
}

/* Consumable toggles */
.drop-mod-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 10px;
}
.drop-mod-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.6);
    transition: color 0.2s;
    margin: 0;
}
.drop-mod-toggle input[type="checkbox"] {
    display: none;
}
.drop-mod-toggle-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.04);
    color: rgba(255,255,255,0.3);
    font-size: 13px;
    transition: all 0.2s;
}
.drop-mod-toggle input:checked + .drop-mod-toggle-box.bg-color {
    background: rgba(255,105,180,0.2);
    border-color: rgba(255,105,180,0.5);
    color: #ff69b4;
}
.drop-mod-toggle input:checked + .drop-mod-toggle-box.hebg-color {
    background: rgba(255,215,0,0.2);
    border-color: rgba(255,215,0,0.5);
    color: #ffd700;
}
.drop-mod-toggle:hover {
    color: rgba(255,255,255,0.8);
}
.drop-mod-toggle small {
    color: rgba(255,255,255,0.3);
    font-weight: 400;
}

/* Info note */
.drop-mod-note {
    font-size: 11px;
    color: rgba(255,255,255,0.3);
    font-style: italic;
}
.drop-mod-note i {
    margin-right: 4px;
    color: rgba(212,175,55,0.4);
}

/* Rate display with modifier active */
.drop-rate-up {
    color: #4caf50;
    font-weight: 600;
}
.drop-rate-base {
    font-size: 11px;
    color: rgba(255,255,255,0.25);
}

/* Mobile drop mod panel */
@media (max-width: 576px) {
    .drop-mod-row {
        flex-wrap: wrap;
    }
    .drop-mod-slider {
        order: 3;
        flex-basis: 100%;
    }
    .drop-mod-num {
        font-size: 16px;
    }
    .drop-mod-toggles {
        flex-direction: column;
        gap: 8px;
    }
}

/* Tags */
.db-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.db-tag {
    padding: 3px 10px;
    border-radius: 4px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.7);
}

/* Cross-link affordance for entries that jump to another DB entry */
.item-link, .mob-link, .npc-link, .map-link, .skill-link, .shop-link {
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
}
.item-link:hover, .mob-link:hover, .npc-link:hover,
.map-link:hover, .skill-link:hover, .shop-link:hover {
    color: #d4af37;
}
span.map-link.db-tag:hover, span.skill-link.db-tag:hover, span.shop-link.db-tag:hover {
    border-color: rgba(212,175,55,0.45);
    color: #d4af37;
}
/* Player shop kind badges */
.db-tag.shop-vending { color: #7CFC7C; border-color: rgba(124,252,124,0.3); }
.db-tag.shop-buying  { color: #7ab8ff; border-color: rgba(122,184,255,0.3); }

/* Script */
.db-script {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 6px;
    padding: 12px 16px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 12px;
    color: rgba(212,175,55,0.8);
    white-space: pre-wrap;
    word-break: break-all;
    max-height: 200px;
    overflow-y: auto;
}

/* Drop table (inside modal) */
.db-drop-table {
    width: 100%;
    border-collapse: collapse;
}
.db-drop-table thead th {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.4);
    padding: 6px 10px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.db-dt-sortable {
    cursor: pointer;
    user-select: none;
    transition: color 0.15s;
}
.db-dt-sortable:hover {
    color: rgba(212,175,55,0.9);
}
.db-dt-sortable i {
    margin-left: 4px;
    font-size: 10px;
}
.db-dt-sort-idle {
    opacity: 0.3;
}
.db-dt-search {
    margin-bottom: 8px;
}
.db-dt-search-input {
    width: 100%;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    padding: 6px 12px;
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    outline: none;
    transition: border-color 0.2s;
}
.db-dt-search-input::placeholder {
    color: rgba(255,255,255,0.3);
}
.db-dt-search-input:focus {
    border-color: rgba(212,175,55,0.4);
}
.db-drop-table tbody tr {
    cursor: pointer;
    transition: background 0.15s;
}
.db-drop-table tbody tr:hover {
    background: rgba(212,175,55,0.1);
}
.db-drop-table tbody td {
    padding: 6px 10px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,0.8);
    border-bottom: 1px solid rgba(255,255,255,0.03);
}
.db-drop-table .item-icon-sm,
.db-drop-table .mob-icon-sm {
    width: 24px;
    height: 24px;
    margin-right: 6px;
    vertical-align: middle;
    object-fit: contain;
}

/* Mobile sort control — hidden on desktop */
.db-mobile-sort { display: none; }

/* Responsive DB */
@media (max-width: 768px) {
    .db-mobile-sort {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-bottom: 12px;
        padding: 10px 14px;
        background: rgba(255,255,255,0.04);
        border: 1px solid rgba(255,255,255,0.08);
        border-radius: 8px;
    }
    .db-mobile-sort label {
        font-family: 'Rajdhani', sans-serif;
        font-size: 13px;
        font-weight: 600;
        color: rgba(255,255,255,0.5);
        margin: 0;
        white-space: nowrap;
    }
    .db-mobile-sort label i { color: #d4af37; margin-right: 4px; }
    .db-mobile-sort-select {
        flex: 1;
        background: rgba(0,0,0,0.3);
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 6px;
        color: #fff;
        font-family: 'Rajdhani', sans-serif;
        font-size: 13px;
        padding: 6px 10px;
        outline: none;
        -webkit-appearance: none;
        appearance: none;
    }
    .db-mobile-sort-select:focus { border-color: rgba(212,175,55,0.4); }
    .db-mobile-sort-dir {
        background: rgba(255,255,255,0.06);
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 6px;
        color: #d4af37;
        font-size: 14px;
        width: 34px;
        height: 34px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.15s;
        flex-shrink: 0;
    }
    .db-mobile-sort-dir:hover { background: rgba(212,175,55,0.15); }
    .db-table thead { display: none; }
    .db-table tbody tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(255,255,255,0.04);
        border-radius: 8px;
        border: 1px solid rgba(255,255,255,0.08);
        padding: 0;
        overflow: hidden;
    }
    .db-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 6px 12px;
        border: none;
        font-size: 13px;
        text-align: right;
    }
    .db-table tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255,255,255,0.45);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        min-width: 90px;
        flex-shrink: 0;
        text-align: left;
    }
    /* Hide ID row on mobile cards — takes space, shown in name header */
    .db-table tbody td.col-id {
        display: none;
    }
    /* Name cell = card header with sprite + name prominently displayed */
    .db-table tbody td.col-name {
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 15px;
        font-weight: 600;
        background: rgba(0,0,0,0.2);
        padding: 10px 12px;
        border-bottom: 1px solid rgba(255,255,255,0.08);
        margin-bottom: 0;
        text-align: left;
    }
    .db-table tbody td.col-name::before {
        display: none;
    }
    .db-table tbody td.col-name .mob-icon-sm,
    .db-table tbody td.col-name .item-icon-sm {
        width: 32px;
        height: 32px;
        flex-shrink: 0;
        object-fit: contain;
        image-rendering: pixelated;
        margin-right: 0;
    }
    .db-table tbody td.col-name .mvp-badge {
        flex-shrink: 0;
    }
    .db-table tbody td.col-name .item-type-badge {
        flex-shrink: 0;
        margin-right: 0;
    }
    /* Alternate row shading for readability */
    .db-table tbody td:nth-child(even):not(.col-name):not(.col-id) {
        background: rgba(255,255,255,0.02);
    }
    .db-table .mvp-row {
        border-color: rgba(212,175,55,0.25);
        background: rgba(212,175,55,0.06);
    }
    .db-table .mvp-row td.col-name {
        background: rgba(212,175,55,0.1);
    }
    .db-detail-stats {
        grid-template-columns: 1fr;
    }
    .db-stat-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .db-search-row {
        gap: 8px;
    }
    .db-filter-pills {
        gap: 4px;
    }
    .db-pill {
        font-size: 12px;
        padding: 3px 10px;
    }
    .db-pagination {
        flex-direction: column;
        gap: 8px;
    }
}

/* ========================================
   RANKINGS
   ======================================== */

.rank-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.rank-tab {
    padding: 8px 20px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.rank-tab:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}
.rank-tab.active {
    background: rgba(212,175,55,0.15);
    border-color: rgba(212,175,55,0.5);
    color: #d4af37;
}
.rank-tab i {
    margin-right: 5px;
}

.rank-online-count {
    display: inline-block;
    background: rgba(0,200,80,0.3);
    color: #4dff88;
    border-radius: 10px;
    padding: 1px 8px;
    font-size: 12px;
    margin-left: 4px;
}

/* Rank table */
.rank-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: rgba(255,255,255,0.03);
    border-radius: 10px;
    overflow: hidden;
}
.rank-table thead th {
    background: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.5);
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 10px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    white-space: nowrap;
}
.rank-table tbody td {
    padding: 10px 14px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    color: rgba(255,255,255,0.8);
    border-bottom: 1px solid rgba(255,255,255,0.04);
}

.rank-row.top-1 {
    background: rgba(255,215,0,0.08);
}
.rank-row.top-2 {
    background: rgba(192,192,192,0.06);
}
.rank-row.top-3 {
    background: rgba(205,127,50,0.06);
}

.col-rank {
    width: 70px;
    text-align: center;
}

.rank-medal {
    font-size: 18px;
}
.rank-medal.gold { color: #ffd700; }
.rank-medal.silver { color: #c0c0c0; }
.rank-medal.bronze { color: #cd7f32; }

.rank-num {
    color: rgba(255,255,255,0.35);
    font-size: 14px;
}

.rank-name {
    font-weight: 600;
    color: #fff !important;
}
.rank-guild-name {
    color: #d4af37 !important;
}
.rank-guild-name i {
    margin-right: 4px;
    opacity: 0.6;
}

.rank-class {
    color: rgba(255,255,255,0.5) !important;
    font-size: 13px !important;
}

.rank-level {
    color: #d4af37 !important;
    font-weight: 600;
}

.rank-zeny {
    color: #d4af37 !important;
    font-weight: 600;
}

.rank-fame {
    color: #e879f9 !important;
    font-weight: 600;
}

.rank-guild {
    color: rgba(255,255,255,0.4);
    font-size: 13px;
}

.rank-map {
    color: rgba(255,255,255,0.5) !important;
    font-size: 13px !important;
    font-family: 'Consolas', monospace !important;
}

.rank-online-cell {
    color: #4dff88 !important;
    font-weight: 600;
}

/* Online header */
.rank-online-header {
    font-family: 'Exo 2', sans-serif;
    font-size: 16px;
    color: rgba(255,255,255,0.7);
    margin-bottom: 16px;
    padding: 10px 16px;
    background: rgba(0,200,80,0.08);
    border-radius: 8px;
    border: 1px solid rgba(0,200,80,0.15);
}
.rank-online-dot {
    color: #4dff88;
    font-size: 10px;
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.rank-refresh-info {
    text-align: center;
    margin-top: 16px;
    color: rgba(255,255,255,0.3);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
}

/* Loading & Empty */
.rank-loading, .rank-empty, .rank-empty-inline {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255,255,255,0.5);
}
.rank-loading i, .rank-empty i, .rank-empty-inline i {
    margin-bottom: 15px;
    color: rgba(212,175,55,0.5);
}
.rank-empty h4, .rank-empty-inline h4 {
    color: rgba(255,255,255,0.6);
    font-family: 'Exo 2', sans-serif;
}

/* Responsive */
@media (max-width: 768px) {
    .rank-tabs {
        gap: 6px;
    }
    .rank-tab {
        padding: 6px 14px;
        font-size: 13px;
    }
    .rank-table thead { display: none; }
    .rank-table tbody tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(255,255,255,0.04);
        border-radius: 8px;
        border: 1px solid rgba(255,255,255,0.08);
        padding: 10px 12px;
    }
    .rank-table tbody tr.top-1 { border-color: rgba(212,175,55,0.35); background: rgba(212,175,55,0.08); }
    .rank-table tbody tr.top-2 { border-color: rgba(192,192,192,0.25); background: rgba(192,192,192,0.06); }
    .rank-table tbody tr.top-3 { border-color: rgba(205,127,50,0.25); background: rgba(205,127,50,0.06); }
    .rank-table tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 3px 0;
        border: none;
        font-size: 13px;
        text-align: right;
    }
    .rank-table tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255,255,255,0.45);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        min-width: 80px;
        flex-shrink: 0;
        text-align: left;
    }
    .rank-table tbody td.col-rank {
        font-size: 15px;
        font-weight: 600;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        padding-bottom: 6px;
        margin-bottom: 2px;
    }
    .rank-table tbody td.rank-name {
        font-size: 15px;
        font-weight: 600;
    }
}

/* Monthly Rankings */
.monthly-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
    padding: 16px 20px;
    background: rgba(255,255,255,0.04);
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.08);
}
.monthly-period-select label {
    font-family: 'Exo 2', sans-serif;
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    margin-right: 8px;
}
.monthly-period-select select {
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    padding: 6px 12px;
    border-radius: 6px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    cursor: pointer;
}
.monthly-period-select select:focus {
    outline: none;
    border-color: rgba(212,175,55,0.5);
}
.monthly-reward-info {
    font-size: 13px;
    color: rgba(212,175,55,0.8);
    font-family: 'Rajdhani', sans-serif;
}
.monthly-reward-info i { margin-right: 4px; }

/* Fame sub-categories */
.fame-category {
    margin-bottom: 36px;
}
.fame-cat-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    color: rgba(255,255,255,0.85);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.fame-cat-title i {
    color: rgba(212,175,55,0.7);
    margin-right: 8px;
}

.monthly-category {
    margin-bottom: 36px;
}
.monthly-cat-title {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    color: rgba(255,255,255,0.85);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.monthly-cat-title i {
    color: rgba(212,175,55,0.7);
    margin-right: 8px;
}
.monthly-no-data {
    color: rgba(255,255,255,0.35);
    font-style: italic;
    padding: 12px 0;
}

/* Podium Cards */
.monthly-podium {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    justify-content: center;
}
.podium-card {
    flex: 1;
    max-width: 220px;
    text-align: center;
    padding: 20px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    transition: transform 0.2s, box-shadow 0.2s;
}
.podium-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.podium-gold {
    border-color: rgba(212,175,55,0.4);
    background: linear-gradient(135deg, rgba(212,175,55,0.12), rgba(212,175,55,0.04));
}
.podium-silver {
    border-color: rgba(192,192,192,0.3);
    background: linear-gradient(135deg, rgba(192,192,192,0.08), rgba(192,192,192,0.02));
}
.podium-bronze {
    border-color: rgba(205,127,50,0.3);
    background: linear-gradient(135deg, rgba(205,127,50,0.08), rgba(205,127,50,0.02));
}
.podium-rank { margin-bottom: 8px; }
.podium-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}
.podium-class {
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    margin-bottom: 6px;
}
.podium-value {
    font-family: 'Exo 2', sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: rgba(212,175,55,0.9);
    margin-bottom: 4px;
}
.podium-guild {
    font-size: 12px;
    color: rgba(100,200,255,0.7);
    margin-bottom: 6px;
}
.podium-reward {
    font-size: 12px;
    color: rgba(212,175,55,0.7);
    margin-top: 4px;
    padding-top: 6px;
    border-top: 1px solid rgba(255,255,255,0.08);
}
.podium-reward i { margin-right: 3px; }
.monthly-table { margin-top: 4px; }

@media (max-width: 768px) {
    .monthly-header { flex-direction: column; text-align: center; }
    .monthly-podium { flex-direction: column; align-items: center; }
    .podium-card { max-width: 100%; width: 100%; }
}

/* ========================================
   CHARACTER VIEWER
   ======================================== */

.char-search-wrap {
    margin-bottom: 24px;
}

/* Character filter row */
.char-filter-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
    flex-wrap: wrap;
}
.char-filter-select {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: rgba(255,255,255,0.85);
    font-size: 13px;
    padding: 7px 12px;
    min-width: 160px;
    appearance: auto;
    cursor: pointer;
    transition: border-color 0.2s;
}
.char-filter-select:focus {
    outline: none;
    border-color: rgba(255,178,64,0.5);
}
.char-filter-select option {
    background: #0a1628;
    color: rgba(255,255,255,0.85);
}
.char-online-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    cursor: pointer;
    user-select: none;
    margin: 0;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    padding: 7px 14px;
    transition: all 0.2s;
}
.char-online-toggle:hover {
    border-color: rgba(74,222,128,0.4);
    color: rgba(255,255,255,0.85);
}
.char-online-toggle input[type="checkbox"] {
    display: none;
}
.char-online-toggle input[type="checkbox"]:checked ~ .char-online-dot {
    box-shadow: 0 0 8px rgba(74,222,128,0.6);
}
.char-online-toggle.active {
    background: rgba(74,222,128,0.1);
    border-color: rgba(74,222,128,0.4);
    color: rgba(74,222,128,0.9);
}

/* Character table specifics */
.char-result-summary {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    margin-bottom: 12px;
}
#char-table .col-name { cursor: pointer; }
#char-table .db-row { cursor: pointer; }
#char-table .db-row:hover td { background: rgba(255,178,64,0.06); }
.char-class-badge {
    font-size: 12px;
    color: rgba(255,255,255,0.7);
    background: rgba(255,255,255,0.06);
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
}
.char-guild-tag {
    color: rgba(255,178,64,0.8);
    font-size: 13px;
}
.char-status-on {
    color: #4ade80;
    font-size: 12px;
}
.char-status-on i { font-size: 7px; vertical-align: middle; margin-right: 3px; }
.char-status-off {
    color: rgba(255,255,255,0.25);
    font-size: 12px;
}

.section-label {
    font-family: 'Exo 2', sans-serif;
    color: rgba(255,255,255,0.7);
    font-size: 16px;
    margin-bottom: 16px;
}

.badge-count {
    background: rgba(255,178,64,0.2);
    color: #ffb240;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    margin-left: 6px;
}

/* Character search results */
.char-result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.char-result-row:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,178,64,0.3);
}
.char-res-main {
    display: flex;
    align-items: center;
    gap: 8px;
}
.char-res-name {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 15px;
    color: rgba(255,255,255,0.9);
}
.char-res-guild {
    color: rgba(255,178,64,0.7);
    font-size: 13px;
}
.char-res-info {
    display: flex;
    align-items: center;
    gap: 16px;
}
.char-res-class {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
}
.char-res-level {
    color: rgba(255,255,255,0.7);
    font-weight: 600;
    font-size: 13px;
}
.char-online-dot {
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 6px rgba(74,222,128,0.5);
}

/* Character Profile */
.char-back-link {
    display: inline-block;
    color: rgba(255,178,64,0.8);
    font-size: 14px;
    margin-bottom: 20px;
    text-decoration: none;
}
.char-back-link:hover {
    color: #ffb240;
    text-decoration: none;
}
.char-profile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 28px;
}
.char-name-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.char-name-wrap h2 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 28px;
    color: #fff;
    margin: 0;
}
.char-class-tag {
    background: rgba(255,178,64,0.15);
    color: #ffb240;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    font-family: 'Rajdhani', sans-serif;
}
.char-online-badge {
    background: rgba(74,222,128,0.15);
    color: #4ade80;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}
.char-online-badge i {
    font-size: 7px;
    vertical-align: 1px;
}
.char-guild-info {
    display: flex;
    align-items: center;
    gap: 8px;
}
.guild-emblem-sm {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}
.guild-emblem-sm,
.guild-emblem-lg,
.rc-emblem,
.woe-guild-emblem,
.wr-castle-emblem,
.wr-rank-emblem img,
.fm-guild-emblem img {
    background: rgba(255,255,255,0.05) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='rgba(255,255,255,0.12)'%3E%3Cpath d='M12 2L4 5v6.09c0 5.05 3.41 9.76 8 10.91 4.59-1.15 8-5.86 8-10.91V5l-8-3z'/%3E%3C/svg%3E") center / 60% no-repeat;
}
.char-guild-link {
    color: rgba(255,178,64,0.8);
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}
.char-guild-link:hover {
    color: #ffb240;
    text-decoration: none;
}

/* Character stats grid */
.char-stats-grid {
    margin-bottom: 16px;
}
.char-stat-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.stat-label {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
}
.stat-value {
    color: rgba(255,255,255,0.9);
    font-weight: 600;
    font-size: 14px;
}

/* 6-col attribute grid */
.char-attr-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-top: 8px;
}
.char-attr {
    text-align: center;
    background: rgba(255,255,255,0.04);
    border-radius: 6px;
    padding: 8px 4px;
}
.attr-name {
    display: block;
    font-size: 10px;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}
.attr-val {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: #ffb240;
    font-family: 'Rajdhani', sans-serif;
}

/* Equipment list */
.char-equip-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.equip-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255,255,255,0.03);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.05);
}
.equip-loc {
    color: rgba(255,255,255,0.45);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    min-width: 120px;
    flex-shrink: 0;
}
.equip-name {
    color: rgba(255,255,255,0.85);
    font-weight: 600;
    font-size: 14px;
    text-align: right;
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: flex-end;
}
.equip-icon {
    width: 24px;
    height: 24px;
    image-rendering: pixelated;
    flex-shrink: 0;
}
.eq-cards {
    color: rgba(255,178,64,0.7);
    font-size: 12px;
    font-weight: 400;
}

/* Character actions */
.char-actions-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

/* Toggle switches for visibility settings */
.char-toggles-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}
.char-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}
.char-toggle input {
    display: none;
}
.char-toggle-slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    transition: all 0.25s;
    flex-shrink: 0;
}
.char-toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background: rgba(255,255,255,0.4);
    border-radius: 50%;
    transition: all 0.25s;
}
.char-toggle input:checked + .char-toggle-slider {
    background: rgba(255,178,64,0.25);
    border-color: rgba(255,178,64,0.5);
}
.char-toggle input:checked + .char-toggle-slider::after {
    left: 22px;
    background: #ffb240;
}
.char-toggle-label {
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    transition: color 0.2s;
}
.char-toggle input:checked ~ .char-toggle-label {
    color: #ffb240;
}

.btn-char-action {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.8);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-char-action:hover {
    background: rgba(255,178,64,0.15);
    border-color: rgba(255,178,64,0.3);
    color: #ffb240;
}

/* My Characters list (account panel) */
.my-chars-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.my-char-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
}
.my-char-row:hover {
    background: rgba(255,255,255,0.07);
    border-color: rgba(255,178,64,0.3);
    text-decoration: none;
}
.my-char-main {
    display: flex;
    align-items: center;
    gap: 8px;
}
.my-char-name {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    font-size: 15px;
}
.my-char-guild {
    color: rgba(255,178,64,0.6);
    font-size: 13px;
}
.my-char-info {
    display: flex;
    align-items: center;
    gap: 16px;
}
.my-char-class {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
}
.my-char-level {
    color: rgba(255,255,255,0.7);
    font-weight: 600;
    font-size: 13px;
}
.my-char-zeny {
    color: rgba(212,175,55,0.8);
    font-weight: 600;
    font-size: 13px;
}

/* ========================================
   GUILD DATABASE
   ======================================== */

.guild-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.guild-row:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,178,64,0.3);
}
.guild-row-main {
    display: flex;
    align-items: center;
    gap: 12px;
}
.guild-row-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.guild-row-name {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    color: rgba(255,255,255,0.9);
    font-size: 16px;
}
.guild-row-meta {
    color: rgba(255,255,255,0.4);
    font-size: 12px;
}
.guild-row-stats {
    display: flex;
    align-items: center;
    gap: 16px;
}
.guild-row-stat {
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    white-space: nowrap;
}
.guild-row-stat i {
    margin-right: 3px;
}
.guild-has-castle {
    color: rgba(212,175,55,0.9);
    font-weight: 600;
}

/* Guild Profile */
.guild-profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}
.guild-emblem-lg {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    border: 2px solid rgba(255,255,255,0.1);
}
.guild-profile-header h2 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 28px;
    color: #fff;
    margin: 0;
}
.guild-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 4px;
}
.guild-meta-item {
    color: rgba(255,255,255,0.6);
    font-size: 13px;
}
.guild-meta-item i {
    margin-right: 4px;
}
.guild-motto {
    color: rgba(255,255,255,0.4);
    font-style: italic;
    font-size: 14px;
    margin-top: 4px;
}

/* Castle list */
.castle-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.castle-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(255,255,255,0.03);
    border-radius: 6px;
    border: 1px solid rgba(212,175,55,0.15);
    color: rgba(255,255,255,0.8);
    font-size: 14px;
}
.castle-item i {
    color: rgba(212,175,55,0.7);
}
.castle-name {
    flex: 1;
    font-weight: 600;
}
.castle-stats {
    color: rgba(255,255,255,0.4);
    font-size: 12px;
}

/* Relations */
.relation-item {
    padding: 6px 0;
    font-size: 14px;
}
.relation-item a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
}
.relation-item a:hover {
    color: #ffb240;
}
.relation-item.ally i {
    color: #4ade80;
    margin-right: 6px;
}
.relation-item.enemy i {
    color: #f87171;
    margin-right: 6px;
}

/* Member link in guild table */
.member-char-link {
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    font-weight: 600;
}
.member-char-link:hover {
    color: #ffb240;
    text-decoration: none;
}

/* Responsive */
@media (max-width: 768px) {
    .char-filter-row {
        flex-direction: column;
        align-items: stretch;
    }
    .char-filter-select {
        min-width: 100%;
    }
    .char-result-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .char-res-info {
        gap: 12px;
    }
    .char-profile-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .char-name-wrap h2 {
        font-size: 22px;
    }
    .char-attr-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .equip-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    .equip-name {
        text-align: left;
        justify-content: flex-start;
    }
    .my-char-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .guild-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .guild-row-stats {
        flex-wrap: wrap;
        gap: 10px;
    }
    .guild-profile-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .guild-profile-header h2 {
        font-size: 22px;
    }
    .guild-meta {
        gap: 10px;
    }
}

/* ═══════════════════════════════════════════════════════
   DONATE & SHOP
   ═══════════════════════════════════════════════════════ */

/* ── Donate Result Banners ── */
.donate-result {
    text-align: center;
    padding: 40px 20px;
    margin-bottom: 30px;
    background: rgba(76, 175, 80, .12);
    border: 1px solid rgba(76, 175, 80, .3);
    border-radius: 12px;
}
.donate-result-icon {
    font-size: 64px;
    color: #4caf50;
    margin-bottom: 15px;
}
.donate-result h3 {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
}
.donate-result p {
    color: rgba(255,255,255,.7);
}
.donate-result-cancel {
    background: rgba(244, 67, 54, .12);
    border-color: rgba(244, 67, 54, .3);
}
.donate-result-cancel .donate-result-icon {
    color: #f44336;
}

/* ── Balance Bar ── */
.donate-balance-bar {
    background: rgba(255, 215, 0, .1);
    border: 1px solid rgba(255, 215, 0, .25);
    border-radius: 8px;
    padding: 12px 20px;
    margin-bottom: 20px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 18px;
    color: #ffd700;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.donate-balance-bar a {
    color: rgba(255,255,255,.7);
    font-size: 14px;
    text-decoration: none;
}
.donate-balance-bar a:hover {
    color: #fff;
}

/* ── Info Card ── */
.donate-info {
    padding: 25px 30px;
    margin-bottom: 10px;
}
.donate-info h4 {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    margin-bottom: 15px;
}
.donate-steps {
    list-style: none;
    padding: 0;
    margin: 0;
}
.donate-steps li {
    padding: 8px 0;
    color: rgba(255,255,255,.8);
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
}
.donate-steps li i {
    width: 24px;
    color: #64b5f6;
    margin-right: 8px;
}
.donate-steps a {
    color: #64b5f6;
}
.donate-secure {
    color: rgba(255,255,255,.5);
    padding: 20px;
}
.donate-secure i {
    margin-bottom: 10px;
}
.donate-secure p {
    margin: 0;
    font-size: 14px;
}

/* ── Credit Packages ── */
.donate-package {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 14px;
    padding: 30px 20px;
    text-align: center;
    transition: all .3s ease;
    position: relative;
    cursor: default;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.donate-package:hover {
    border-color: var(--pkg-accent, #64b5f6);
    background: rgba(255,255,255,.09);
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0,0,0,.3);
}
.donate-package.popular {
    border-color: rgba(255,152,0,.4);
    background: rgba(255,152,0,.08);
}
.package-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #ff9800, #f57c00);
    color: #fff;
    font-family: 'Exo 2', sans-serif;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 16px;
    border-radius: 20px;
    white-space: nowrap;
}
.package-icon {
    font-size: 40px;
    color: var(--pkg-accent, #64b5f6);
    margin-bottom: 12px;
}
.package-name {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    font-size: 20px;
    margin-bottom: 8px;
}
.package-credits {
    font-family: 'Exo 2', sans-serif;
    font-size: 36px;
    font-weight: 800;
    color: var(--pkg-accent, #64b5f6);
    line-height: 1;
}
.package-credits-label {
    font-family: 'Rajdhani', sans-serif;
    color: rgba(255,255,255,.5);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
}
.package-bonus {
    color: #4caf50;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
}
.package-price {
    font-family: 'Rajdhani', sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 15px;
    margin-top: auto;
}
.package-buy-btn {
    width: 100%;
}

/* ── Shop Categories ── */
.shop-categories {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 25px;
}
.shop-cat-btn {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.7);
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    font-weight: 600;
    padding: 8px 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: all .2s;
}
.shop-cat-btn:hover {
    background: rgba(255,255,255,.1);
    color: #fff;
}
.shop-cat-btn.active {
    background: rgba(100,181,246,.15);
    border-color: rgba(100,181,246,.4);
    color: #64b5f6;
}

/* ── Shop Item Cards ── */
.shop-item-card {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 12px;
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: all .3s ease;
    position: relative;
}
.shop-item-card:hover {
    border-color: rgba(100,181,246,.3);
    background: rgba(255,255,255,.09);
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(0,0,0,.25);
}
.shop-item-card.sold-out {
    opacity: .5;
}
.shop-item-cat {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,.4);
    margin-bottom: 10px;
}
.shop-stock {
    position: absolute;
    top: 12px;
    right: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(255,152,0,.15);
    color: #ff9800;
}
.shop-stock.out {
    background: rgba(244,67,54,.15);
    color: #f44336;
}
.shop-item-icon {
    font-size: 36px;
    color: rgba(255,255,255,.2);
    margin-bottom: 10px;
    text-align: center;
}
.shop-item-name {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    font-size: 16px;
    margin-bottom: 4px;
}
.shop-item-amount {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: #4caf50;
    margin-bottom: 6px;
}
.shop-item-desc {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,.55);
    flex: 1;
    margin-bottom: 12px;
}
.shop-item-price {
    font-family: 'Exo 2', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: #ffd700;
    margin-bottom: 12px;
}

/* ── Purchase Modal ── */
.purchase-summary {
    text-align: center;
}
.purchase-item-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 22px;
    color: #fff;
    margin-bottom: 5px;
}
.purchase-item-desc {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,.5);
    margin-bottom: 20px;
}
.purchase-details {
    text-align: left;
    background: rgba(0,0,0,.2);
    border-radius: 8px;
    padding: 15px 20px;
}
.purchase-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    color: rgba(255,255,255,.8);
}
.purchase-total {
    font-size: 18px;
    font-weight: 700;
    color: #ffd700;
}
.purchase-qty-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}
.purchase-qty-controls span {
    font-size: 18px;
    font-weight: 700;
    min-width: 20px;
    text-align: center;
}

/* ── Shop Toast ── */
.shop-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(76,175,80,.95);
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 600;
    padding: 14px 30px;
    border-radius: 10px;
    z-index: 10000;
    opacity: 0;
    transition: opacity .3s, transform .3s;
    box-shadow: 0 4px 20px rgba(0,0,0,.3);
    max-width: 90%;
    text-align: center;
}
.shop-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ── Donate History Table ── */
.donate-history-table {
    background: transparent;
    color: rgba(255,255,255,.8);
}
.donate-history-table thead th {
    font-family: 'Exo 2', sans-serif;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,.5);
    border-color: rgba(255,255,255,.08);
}
.donate-history-table td {
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    border-color: rgba(255,255,255,.06);
    vertical-align: middle;
}

/* ── Responsive ── */
@media (max-width: 767px) {
    .donate-package {
        padding: 25px 15px;
    }
    .package-credits {
        font-size: 28px;
    }
    .shop-categories {
        gap: 6px;
    }
    .shop-cat-btn {
        font-size: 13px;
        padding: 6px 12px;
    }
    .donate-balance-bar {
        font-size: 15px;
        justify-content: center;
        text-align: center;
    }
}

/* ═══════════════════════════════════════════════════════
   WAR OF EMPERIUM
   ═══════════════════════════════════════════════════════ */

/* ── Status Banner ── */
.woe-status-banner {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 16px 24px;
    border-radius: 10px;
    margin-bottom: 24px;
    background: rgba(100,181,246,.1);
    border: 1px solid rgba(100,181,246,.25);
}
.woe-status-banner.active {
    background: rgba(244,67,54,.1);
    border-color: rgba(244,67,54,.35);
    animation: woe-pulse 2s ease-in-out infinite;
}
@keyframes woe-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(244,67,54,.2); }
    50% { box-shadow: 0 0 20px 4px rgba(244,67,54,.15); }
}
.woe-status-icon {
    font-size: 28px;
    color: rgba(255,255,255,.3);
}
.woe-status-banner.active .woe-status-icon {
    color: #f44336;
}
.woe-status-text {
    display: flex;
    flex-direction: column;
}
.woe-status-text strong {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    font-size: 18px;
}
.woe-status-text span {
    font-family: 'Rajdhani', sans-serif;
    color: rgba(255,255,255,.6);
    font-size: 15px;
}

/* ── Tabs ── */
.woe-tabs {
    border-bottom: 1px solid rgba(255,255,255,.1);
    margin-bottom: 24px;
}
.woe-tabs .nav-link {
    color: rgba(255,255,255,.5);
    font-family: 'Exo 2', sans-serif;
    font-size: 15px;
    border: none;
    padding: 10px 20px;
    transition: color .2s;
}
.woe-tabs .nav-link:hover {
    color: rgba(255,255,255,.8);
    border: none;
}
.woe-tabs .nav-link.active {
    color: #64b5f6;
    background: transparent;
    border: none;
    border-bottom: 2px solid #64b5f6;
}

/* ── Schedule Week Grid ── */
.woe-week {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
}
.woe-day {
    background: rgba(255,255,255,.03);
    border: 1px solid rgba(255,255,255,.06);
    border-radius: 10px;
    padding: 0;
    overflow: hidden;
    min-height: 140px;
}
.woe-day.has-woe {
    border-color: rgba(255,255,255,.12);
    background: rgba(255,255,255,.05);
}
.woe-day-header {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255,255,255,.06);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}
.woe-day-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 13px;
    font-weight: 700;
    color: rgba(255,255,255,.7);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.woe-day.has-woe .woe-day-name {
    color: #fff;
}
.woe-day-off {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,.2);
}

/* ── Session Card ── */
.woe-session {
    padding: 10px 12px;
    border-left: 3px solid var(--session-color, #64b5f6);
    margin: 8px;
    border-radius: 0 6px 6px 0;
    background: rgba(255,255,255,.04);
}
.woe-session-time {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: var(--session-color, #64b5f6);
    margin-bottom: 4px;
}
.woe-session-region {
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    color: #fff;
    margin-bottom: 6px;
}
.woe-session-castles {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}
.woe-castle-tag {
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    color: rgba(255,255,255,.5);
    background: rgba(255,255,255,.06);
    padding: 2px 6px;
    border-radius: 4px;
}

/* ── Castle Ownership ── */
.woe-regions {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}
.woe-region-card {
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 12px;
    overflow: hidden;
}
.woe-region-header {
    padding: 14px 18px;
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: var(--region-color, #64b5f6);
    border-bottom: 1px solid rgba(255,255,255,.06);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.woe-region-header i {
    margin-right: 8px;
}
.woe-region-count {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: rgba(255,255,255,.4);
}
.woe-region-body {
    padding: 6px 0;
}

/* ── Castle Row ── */
.woe-castle-row {
    padding: 10px 18px;
    border-bottom: 1px solid rgba(255,255,255,.04);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
}
.woe-castle-row:last-child {
    border-bottom: none;
}
.woe-castle-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,.8);
    min-width: 160px;
}
.woe-castle-name i {
    color: rgba(255,255,255,.25);
    margin-right: 6px;
}
.woe-castle-row.occupied .woe-castle-name i {
    color: #ffd700;
}
.woe-castle-guild {
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    flex: 1;
}
.woe-castle-guild.unoccupied {
    color: rgba(255,255,255,.25);
    font-style: italic;
}
.woe-guild-link {
    color: #64b5f6;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
}
.woe-guild-link:hover {
    color: #90caf9;
}
.woe-guild-emblem {
    width: 20px;
    height: 20px;
    border-radius: 3px;
}
.woe-castle-details {
    display: flex;
    gap: 14px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,.4);
}
.woe-castle-details i {
    margin-right: 3px;
}

/* ── Server Time ── */
.woe-server-time {
    text-align: center;
    padding: 20px 0;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,.35);
}

/* ── WoE Responsive ── */
@media (max-width: 991px) {
    .woe-week {
        grid-template-columns: repeat(4, 1fr);
    }
    .woe-regions {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 767px) {
    .woe-week {
        grid-template-columns: 1fr 1fr;
    }
    .woe-day {
        min-height: auto;
    }
    .woe-session-castles {
        display: none;
    }
    .woe-castle-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    .woe-castle-name {
        min-width: auto;
    }
    .woe-status-banner {
        flex-direction: column;
        text-align: center;
    }
}

/* ═══════════════════════════════════════════
   CREDIT TRANSFER (Panel)
   ═══════════════════════════════════════════ */
.transfer-form-row .form-row {
    align-items: flex-end;
}
.transfer-history-list {
    max-height: 300px;
    overflow-y: auto;
}
.transfer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    font-size: 0.85rem;
}
.transfer-row:last-child {
    border-bottom: none;
}
.transfer-row-left {
    display: flex;
    align-items: center;
    gap: 8px;
}
.transfer-row-right {
    display: flex;
    align-items: center;
    gap: 15px;
}
.transfer-user {
    color: rgba(255,255,255,0.7);
}
.transfer-date {
    color: rgba(255,255,255,0.35);
    font-size: 0.78rem;
}

/* ═══════════════════════════════════════════
   ADMIN PANEL
   ═══════════════════════════════════════════ */
.admin-tabs {
    border-bottom: 2px solid rgba(255,255,255,0.08);
    margin-bottom: 0;
}
.admin-tabs .nav-link {
    color: rgba(255,255,255,0.5);
    border: none;
    padding: 12px 20px;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    background: transparent;
    border-radius: 8px 8px 0 0;
    transition: all 0.2s;
}
.admin-tabs .nav-link:hover {
    color: rgba(255,255,255,0.8);
    background: rgba(255,255,255,0.03);
}
.admin-tabs .nav-link.active {
    color: #ffb240;
    background: rgba(255,178,64,0.08);
    border-bottom: 2px solid #ffb240;
}
.admin-tabs .nav-link i {
    margin-right: 6px;
}
.admin-tab-content {
    padding-top: 20px;
}
.admin-card {
    background: rgba(255,255,255,0.04);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 12px;
    padding: 20px;
}
.admin-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
    margin-bottom: 15px;
}
.admin-toolbar-group {
    flex: 1;
    min-width: 120px;
}
.admin-toolbar-group label {
    display: block;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.45);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.admin-toolbar-group .form-control {
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    font-size: 0.85rem;
}
.admin-toolbar-group .form-control:focus {
    border-color: #ffb240;
    box-shadow: 0 0 0 2px rgba(255,178,64,0.15);
}
.admin-toolbar-actions {
    flex: 0 0 auto;
    min-width: auto;
}
.btn-wro {
    background: linear-gradient(135deg, #ffb240, #e09020);
    color: #1a1a2e;
    border: none;
    font-weight: 600;
    padding: 6px 16px;
    border-radius: 6px;
    transition: all 0.2s;
}
.btn-wro:hover {
    background: linear-gradient(135deg, #ffc260, #f0a030);
    color: #1a1a2e;
    transform: translateY(-1px);
}
.admin-log-table {
    font-size: 0.8rem;
    margin: 0;
}
.admin-log-table th {
    background: rgba(255,178,64,0.08);
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-color: rgba(255,255,255,0.06);
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 1;
}

/* ─── Wiki ─── */
.wiki-sidebar {
    background: rgba(26,26,46,0.85);
    border: 1px solid rgba(255,178,64,0.15);
    border-radius: 10px;
    padding: 1rem;
    position: sticky;
    top: 110px;
}
.wiki-search-box { margin-bottom: 1rem; }
.wiki-search-box .form-control {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,178,64,0.2);
    color: #e0e0e0;
    border-radius: 6px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.95rem;
}
.wiki-search-box .form-control:focus {
    background: rgba(255,255,255,0.1);
    border-color: #ffb240;
    box-shadow: 0 0 0 2px rgba(255,178,64,0.15);
    color: #fff;
}
.wiki-nav-category { margin-bottom: 0.5rem; }
.wiki-nav-cat-link {
    display: block;
    padding: 0.5rem 0.6rem;
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 6px;
    transition: background 0.15s;
}
.wiki-nav-cat-link:hover,
.wiki-nav-cat-link.active {
    background: rgba(255,178,64,0.12);
    color: #ffb240;
    text-decoration: none;
}
.wiki-nav-cat-link i { margin-right: 0.35rem; width: 16px; text-align: center; }
.wiki-nav-articles { padding-left: 0.3rem; }
.wiki-nav-article {
    display: block;
    padding: 0.3rem 0.6rem 0.3rem 1.5rem;
    color: #b0b0c0;
    font-size: 0.85rem;
    font-family: 'Rajdhani', sans-serif;
    border-radius: 4px;
    transition: all 0.15s;
}
.wiki-nav-article:hover {
    color: #fff;
    background: rgba(255,255,255,0.06);
    text-decoration: none;
}
.wiki-nav-article.active {
    color: #ffb240;
    background: rgba(255,178,64,0.1);
    text-decoration: none;
}

/* Wiki category cards */
.wiki-cat-card {
    background: rgba(26,26,46,0.85);
    border: 1px solid rgba(255,178,64,0.12);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    height: 100%;
}
.wiki-cat-card:hover {
    border-color: #ffb240;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255,178,64,0.15);
}
.wiki-cat-icon {
    font-size: 2rem;
    color: #ffb240;
    margin-bottom: 0.75rem;
}
.wiki-cat-card h5 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.4rem;
}
.wiki-cat-count {
    color: #888;
    font-size: 0.8rem;
    margin-bottom: 0.75rem;
}
.wiki-cat-preview {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}
.wiki-cat-preview li {
    padding: 0.15rem 0;
    font-size: 0.85rem;
}
.wiki-cat-preview li a {
    color: #b0b0c0;
}
.wiki-cat-preview li a:hover {
    color: #ffb240;
    text-decoration: none;
}

/* Wiki breadcrumbs */
.wiki-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: rgba(255,255,255,0.04);
    border-radius: 8px;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    font-family: 'Rajdhani', sans-serif;
}
.wiki-breadcrumb a { color: #ffb240; }
.wiki-breadcrumb a:hover { color: #ffc260; text-decoration: none; }
.wiki-bc-sep { color: rgba(255,255,255,0.25); font-size: 0.65rem; }

/* Wiki article body */
.wiki-article-body {
    background: rgba(26,26,46,0.85);
    border: 1px solid rgba(255,178,64,0.1);
    border-radius: 10px;
    padding: 2rem;
}
.wiki-article-title {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    color: #ffb240;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,178,64,0.15);
}
.wiki-section-title {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    color: #ffb240;
    margin-bottom: 1.5rem;
}
.wiki-section-title i { margin-right: 0.5rem; }
.wiki-article-content {
    color: #d0d0d8;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.95rem;
    line-height: 1.7;
}
.wiki-article-content h4 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: #ffb240;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}
.wiki-article-content h5 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: #e0c070;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}
.wiki-article-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    font-size: 0.88rem;
}
.wiki-article-content th {
    background: rgba(255,178,64,0.1);
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    padding: 0.5rem 0.75rem;
    text-align: left;
    border-bottom: 1px solid rgba(255,178,64,0.2);
}
.wiki-article-content td {
    padding: 0.45rem 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    vertical-align: top;
}
.wiki-article-content tr:hover td {
    background: rgba(255,255,255,0.03);
}
.wiki-article-content ul,
.wiki-article-content ol {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}
.wiki-article-content li { margin-bottom: 0.3rem; }
.wiki-article-content a { color: #ffb240; }
.wiki-article-content a:hover { color: #ffc260; }
.wiki-article-content strong { color: #fff; }
.wiki-article-content code {
    background: rgba(255,255,255,0.08);
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    font-size: 0.85em;
    color: #f0c070;
}

/* Wiki article list (category view) */
.wiki-article-list { display: grid; gap: 1rem; }
.wiki-article-card {
    display: block;
    padding: 1rem 1.25rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,178,64,0.08);
    border-radius: 8px;
    transition: all 0.15s;
}
.wiki-article-card:hover {
    border-color: #ffb240;
    background: rgba(255,178,64,0.06);
    text-decoration: none;
}
.wiki-article-card h5 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: #fff;
    margin-bottom: 0.3rem;
    font-size: 1rem;
}
.wiki-article-card p {
    color: #999;
    font-size: 0.85rem;
    margin: 0;
}

/* Wiki prev / next navigation */
.wiki-article-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.wiki-nav-prev, .wiki-nav-next {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
}
.wiki-nav-prev:hover, .wiki-nav-next:hover {
    color: #ffc260;
    text-decoration: none;
}
.wiki-nav-prev i { margin-right: 0.3rem; }
.wiki-nav-next i { margin-left: 0.3rem; }

/* Wiki search results */
.wiki-results-title {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    color: #ffb240;
    margin-bottom: 1rem;
}
.wiki-search-result {
    display: block;
    padding: 1rem 1.25rem;
    background: rgba(26,26,46,0.85);
    border: 1px solid rgba(255,178,64,0.08);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    transition: all 0.15s;
}
.wiki-search-result:hover {
    border-color: #ffb240;
    text-decoration: none;
}
.wiki-search-result h5 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: #fff;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}
.wiki-result-cat {
    font-size: 0.75rem;
    color: #ffb240;
    display: inline-block;
    margin-bottom: 0.35rem;
}
.wiki-search-result p {
    color: #999;
    font-size: 0.85rem;
    margin: 0;
}

/* Wiki responsive */
@media (max-width: 991px) {
    .wiki-sidebar {
        position: static;
        margin-bottom: 1.5rem;
    }
}
.wiki-nav-toggle {
    display: block;
    width: 100%;
    background: rgba(255,178,64,0.1);
    border: 1px solid rgba(255,178,64,0.25);
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    text-align: left;
    transition: all 0.15s;
}
.wiki-nav-toggle:hover,
.wiki-nav-toggle:focus {
    background: rgba(255,178,64,0.18);
    color: #ffb240;
    outline: none;
    box-shadow: none;
}
.wiki-toggle-icon {
    float: right;
    margin-top: 2px;
    transition: transform 0.2s;
}
.wiki-nav-toggle[aria-expanded="true"] .wiki-toggle-icon {
    transform: rotate(180deg);
}
#wiki-nav-collapse { margin-top: 0.75rem; }
.admin-log-table td {
    border-color: rgba(255,255,255,0.04);
    color: rgba(255,255,255,0.7);
    vertical-align: middle;
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.admin-log-table tbody tr:hover {
    background: rgba(255,178,64,0.04);
}
.admin-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.admin-page-info {
    color: rgba(255,255,255,0.4);
    font-size: 0.82rem;
}
.admin-alert {
    padding: 10px 15px;
    border-radius: 8px;
    background: rgba(255,76,76,0.12);
    border: 1px solid rgba(255,76,76,0.25);
    color: #ff6b6b;
    font-size: 0.85rem;
    margin-bottom: 12px;
}
.admin-alert.admin-alert-success {
    background: rgba(81,207,102,0.12);
    border-color: rgba(81,207,102,0.25);
    color: #51cf66;
}

/* Sentiment Dashboard */
.sentiment-header {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.sentiment-mood {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    min-width: 220px;
}
.sentiment-mood-label {
    font-family: 'Exo 2', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
}
.sentiment-mood-score {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    margin-left: 4px;
}
.sentiment-score-bar {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    margin-top: 6px;
    overflow: hidden;
}
.sentiment-score-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.6s ease;
}
.sentiment-meta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.4);
}
.sentiment-meta i {
    margin-right: 4px;
    color: rgba(255,178,64,0.5);
}
.sentiment-summary {
    color: rgba(255,255,255,0.75);
    font-size: 0.95rem;
    line-height: 1.6;
    padding: 12px 16px;
    background: rgba(255,255,255,0.03);
    border-radius: 8px;
    border-left: 3px solid rgba(255,178,64,0.3);
}
.sentiment-section {
    background: rgba(255,255,255,0.03);
    border-radius: 8px;
    padding: 14px;
    height: 100%;
}
.sentiment-section h6 {
    color: rgba(255,255,255,0.5);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
    font-family: 'Exo 2', sans-serif;
}
.sentiment-section h6 i {
    margin-right: 4px;
}
.sentiment-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.sentiment-section ul li {
    color: rgba(255,255,255,0.65);
    font-size: 0.85rem;
    padding: 4px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.sentiment-section ul li:last-child {
    border-bottom: none;
}
.sentiment-section-positive h6 { color: rgba(74,222,128,0.7); }
.sentiment-section-positive h6 i { color: rgba(74,222,128,0.5); }
.sentiment-section-negative h6 { color: rgba(248,113,113,0.7); }
.sentiment-section-negative h6 i { color: rgba(248,113,113,0.5); }

.sentiment-history-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 6px;
    margin-bottom: 4px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.82rem;
}
.sentiment-history-item:hover {
    background: rgba(255,178,64,0.06);
    border-color: rgba(255,178,64,0.15);
}
.sentiment-history-score {
    font-weight: 600;
    min-width: 50px;
}
.sentiment-history-period {
    color: rgba(255,255,255,0.5);
    flex: 1;
}
.sentiment-history-msgs {
    color: rgba(255,255,255,0.3);
    font-size: 0.75rem;
}

/* Engagement Dashboard */
.eng-chart-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}
.eng-chart-card h6 {
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
}
.eng-chart-card .table-dark {
    background: transparent;
    margin-bottom: 0;
}
.eng-chart-card .table-dark td,
.eng-chart-card .table-dark th {
    border-color: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.7);
}

/* Admin responsive */
@media (max-width: 768px) {
    .admin-toolbar {
        flex-direction: column;
    }
    .admin-toolbar-group {
        min-width: 100%;
    }
    .admin-log-table thead { display: none; }
    .admin-log-table tbody tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(255,255,255,0.04);
        border: 1px solid rgba(255,255,255,0.08);
        border-radius: 8px;
        padding: 10px 12px;
    }
    .admin-log-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        white-space: normal;
        max-width: none;
        padding: 3px 0;
        border: none;
        font-size: 13px;
        text-align: right;
    }
    .admin-log-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255,255,255,0.45);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        min-width: 80px;
        flex-shrink: 0;
        text-align: left;
    }
}

/* ===== Sortable Tables ===== */
.sortable th[data-sort] {
    cursor: pointer;
    user-select: none;
    position: relative;
    padding-right: 22px !important;
    transition: color 0.2s;
}
.sortable th[data-sort]:hover {
    color: rgba(255,255,255,0.85);
}
.sortable th[data-sort]::after {
    content: '\f0dc';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-size: 10px;
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.3;
    transition: opacity 0.2s;
}
.sortable th[data-sort]:hover::after { opacity: 0.6; }
.sortable th[data-sort].sort-asc::after {
    content: '\f0de';
    opacity: 1;
    color: #d4af37;
}
.sortable th[data-sort].sort-desc::after {
    content: '\f0dd';
    opacity: 1;
    color: #d4af37;
}
.sortable th[data-sort].sort-asc,
.sortable th[data-sort].sort-desc {
    color: #d4af37;
}

/* ========== Download Page ========== */
.download-card {
    text-align: center;
    padding: 2rem 1.5rem;
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
}
.download-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}
.download-card-full {
    border: 1px solid rgba(212,175,55,0.3);
}
.download-card-badge {
    position: absolute;
    top: -12px;
    right: 20px;
    background: linear-gradient(135deg, #d4af37, #b8972e);
    color: #1a1a2e;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 0.7rem;
    padding: 4px 14px;
    border-radius: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.download-card-icon {
    font-size: 3rem;
    color: #d4af37;
    margin-bottom: 1rem;
}
.download-card-title {
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    margin-bottom: 0.75rem;
}
.download-card-desc {
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    margin-bottom: 1.25rem;
}
.download-card-details {
    list-style: none;
    padding: 0;
    text-align: left;
    margin-bottom: 1.5rem;
}
.download-card-details li {
    padding: 6px 0;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.download-card-details li i {
    width: 20px;
    color: #d4af37;
    margin-right: 8px;
}
/* Glass-style button used by the download cards. Bootstrap's bare .btn
   inherits dark text on a transparent bg — invisible on this dark page.
   This rule provides the bright-on-glass surface explicitly. */
.btn-glass {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: background 0.15s, border-color 0.15s, transform 0.15s, box-shadow 0.15s;
}
.btn-glass:hover,
.btn-glass:focus {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
    text-decoration: none;
}
.download-btn {
    font-size: 1.05rem;
    padding: 12px;
}
.download-btn-full {
    background: linear-gradient(135deg, rgba(212,175,55,0.35), rgba(212,175,55,0.15)) !important;
    border-color: rgba(212,175,55,0.7) !important;
    color: #fff !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
.download-btn-full:hover,
.download-btn-full:focus {
    background: linear-gradient(135deg, rgba(212,175,55,0.55), rgba(212,175,55,0.3)) !important;
    border-color: #d4af37 !important;
    color: #fff !important;
}
.download-card-note {
    font-size: 0.8rem;
    margin-top: 0.75rem;
    margin-bottom: 0;
}
.download-steps {
    padding-left: 1.2rem;
}
.download-steps li {
    padding: 4px 0;
    color: rgba(255,255,255,0.85);
}
.download-steps code {
    background: rgba(212,175,55,0.15);
    color: #d4af37;
    padding: 2px 6px;
    border-radius: 3px;
}
.download-troubleshoot {
    list-style: none;
    padding: 0;
}
.download-troubleshoot li {
    padding: 4px 0;
    color: rgba(255,255,255,0.8);
}
.download-troubleshoot li::before {
    content: '\2022';
    color: #d4af37;
    margin-right: 8px;
}
.download-reqs {
    list-style: none;
    padding: 0;
}
.download-reqs li {
    padding: 3px 0;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

/* ===== Character Sort & Pagination ===== */
.char-sort-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}
.char-sort-row .sort-label {
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
    margin-right: 4px;
}
.char-sort-btn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}
.char-sort-btn:hover {
    background: rgba(255,255,255,0.12);
    color: #fff;
}
.char-sort-btn.active {
    background: rgba(255, 138, 0, 0.15);
    border-color: rgba(255, 138, 0, 0.4);
    color: #ff8a00;
}
.char-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 20px;
    padding: 10px 0;
}
.char-page-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.05);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.char-page-btn:hover {
    background: rgba(255,138,0,0.15);
    border-color: rgba(255,138,0,0.3);
    color: #ff8a00;
}
.char-page-btn.active {
    background: rgba(255,138,0,0.25);
    border-color: #ff8a00;
    color: #ff8a00;
    font-weight: 600;
}
.char-page-dots {
    color: rgba(255,255,255,0.3);
    padding: 0 4px;
}

/* ===== Database Icons (Divine Pride) ===== */
.item-icon-sm {
    width: 24px;
    height: 24px;
    vertical-align: middle;
    margin-right: 6px;
    image-rendering: pixelated;
}
.item-icon-lg {
    width: 48px;
    height: 48px;
    image-rendering: pixelated;
}
.mob-icon-sm {
    width: 28px;
    height: 28px;
    vertical-align: middle;
    margin-right: 6px;
    object-fit: contain;
}
.mob-icon-lg {
    max-width: 100px;
    max-height: 100px;
    object-fit: contain;
}
.db-detail-icon {
    text-align: center;
    margin-bottom: 12px;
}

/* ── NPC Shop Purchase Panel ── */
.npc-item-buy {
    background: rgba(76, 175, 80, 0.15);
    border: 1px solid rgba(76, 175, 80, 0.4);
    color: #81c784;
    border-radius: 4px;
    padding: 2px 8px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}
.npc-item-buy:hover {
    background: rgba(76, 175, 80, 0.35);
    color: #a5d6a7;
}
.npc-buy-panel {
    background: rgba(76, 175, 80, 0.06);
    border: 1px solid rgba(76, 175, 80, 0.25);
    border-radius: 8px;
    padding: 16px;
    margin-top: 16px;
}
.npc-buy-panel h6 {
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    color: #81c784;
    margin-bottom: 12px;
}
.npc-buy-panel h6 i { margin-right: 6px; }
.npc-buy-form { display: flex; flex-direction: column; gap: 10px; }
.npc-buy-row {
    display: flex;
    align-items: center;
    gap: 12px;
}
.npc-buy-row label {
    min-width: 80px;
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    margin: 0;
}
.npc-buy-select {
    flex: 1;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 4px;
    padding: 6px 8px;
    font-size: 13px;
}
.npc-buy-select option { background: #1a1a2e; }
.npc-buy-qty-wrap {
    display: flex;
    align-items: center;
    gap: 4px;
}
.npc-buy-qty-btn {
    width: 28px;
    height: 28px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.npc-buy-qty-btn:hover { background: rgba(255,255,255,0.15); }
.npc-buy-qty-input {
    width: 50px;
    text-align: center;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 4px;
    padding: 4px;
    font-size: 13px;
    -moz-appearance: textfield;
}
.npc-buy-qty-input::-webkit-outer-spin-button,
.npc-buy-qty-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.npc-buy-total {
    font-size: 14px;
    font-weight: 600;
    color: #d4af37;
}
.npc-buy-weight {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
}
.npc-buy-msg {
    font-size: 13px;
    padding: 8px 12px;
    border-radius: 4px;
    background: rgba(244,67,54,0.12);
    color: #ef9a9a;
    border: 1px solid rgba(244,67,54,0.25);
}
.npc-buy-msg.npc-buy-success {
    background: rgba(76,175,80,0.12);
    color: #a5d6a7;
    border-color: rgba(76,175,80,0.25);
}
.npc-buy-actions {
    display: flex;
    gap: 8px;
    margin-top: 4px;
}
.npc-buy-confirm {
    background: rgba(76,175,80,0.2);
    border: 1px solid rgba(76,175,80,0.5);
    color: #81c784;
    font-size: 13px;
    padding: 6px 16px;
}
.npc-buy-confirm:hover { background: rgba(76,175,80,0.35); color: #a5d6a7; }
.npc-buy-confirm:disabled { opacity: 0.5; cursor: not-allowed; }
.npc-buy-cancel {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    padding: 6px 16px;
}
.npc-buy-cancel:hover { background: rgba(255,255,255,0.1); color: #fff; }

/* ── NPC Shop Market Tab ── */
.npc-shop-controls {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.npc-shop-search { flex: 1; min-width: 200px; }
.npc-shop-filters { display: flex; gap: 8px; }
.npc-shop-filters .db-select {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 4px;
    padding: 6px 10px;
    font-size: 13px;
    min-width: 130px;
}
.npc-shop-filters .db-select option { background: #1a1a2e; }
.npc-shop-info {
    font-size: 13px;
    color: rgba(255,255,255,0.4);
    margin-bottom: 12px;
}
.npc-shop-info span { color: #81c784; font-weight: 600; }
.npc-items-table { width: 100%; }
.npc-items-table th {
    cursor: pointer;
    user-select: none;
    position: relative;
    padding-right: 18px !important;
}
.npc-items-table th.sort-asc::after { content: ' \25B2'; font-size: 10px; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); color: #81c784; }
.npc-items-table th.sort-desc::after { content: ' \25BC'; font-size: 10px; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); color: #81c784; }
.npc-item-row { cursor: pointer; transition: background 0.15s; }
.npc-item-row:hover { background: rgba(129,199,132,0.08); }
.item-slots { color: rgba(255,255,255,0.35); font-size: 12px; }
.npc-quick-buy {
    background: rgba(76,175,80,0.15);
    border: 1px solid rgba(76,175,80,0.3);
    color: #81c784;
    border-radius: 4px;
    padding: 3px 8px;
    font-size: 12px;
    transition: all 0.2s;
}
.npc-quick-buy:hover { background: rgba(76,175,80,0.3); color: #a5d6a7; }

/* NPC Purchase Panel */
.npc-purchase-panel {
    background: rgba(0,0,0,0.15);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 20px;
}
.npc-purchase-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}
.npc-purchase-header h5 {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    margin: 0;
    color: #e0e0e0;
}
.npc-purchase-back {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    border-radius: 4px;
    padding: 6px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.npc-purchase-back:hover { background: rgba(255,255,255,0.1); color: #fff; }
.npc-purchase-back i { margin-right: 4px; }
.npc-shops-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.npc-shop-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 6px;
    padding: 10px 14px;
    transition: all 0.2s;
}
.npc-shop-buyable { cursor: pointer; }
.npc-shop-buyable:hover { background: rgba(76,175,80,0.08); border-color: rgba(76,175,80,0.2); }
.npc-shop-active { background: rgba(76,175,80,0.12) !important; border-color: rgba(76,175,80,0.4) !important; }
.npc-shop-row-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.npc-shop-name { font-size: 14px; color: #e0e0e0; }
.npc-shop-name i { color: rgba(255,255,255,0.3); margin-right: 6px; font-size: 12px; }
.npc-shop-map { font-size: 12px; color: rgba(255,255,255,0.35); }
.npc-shop-map i { margin-right: 4px; }
.npc-shop-price { font-size: 14px; color: #ffd54f; font-weight: 600; white-space: nowrap; }
.npc-shop-select-buy {
    background: rgba(76,175,80,0.15);
    border: 1px solid rgba(76,175,80,0.3);
    color: #81c784;
    border-radius: 4px;
    padding: 4px 10px;
    font-size: 13px;
    transition: all 0.2s;
}
.npc-shop-select-buy:hover { background: rgba(76,175,80,0.3); color: #a5d6a7; }
.npc-purchase-form {
    background: rgba(76,175,80,0.06);
    border: 1px solid rgba(76,175,80,0.25);
    border-radius: 8px;
    padding: 16px;
}
.npc-purchase-form h6 {
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    color: #81c784;
    margin-bottom: 12px;
}
.npc-purchase-form h6 i { margin-right: 6px; }
@media (max-width: 768px) {
    .npc-shop-controls { flex-direction: column; }
    .npc-shop-filters { width: 100%; }
    .npc-shop-filters .db-select { flex: 1; }
    .npc-shop-row { flex-wrap: wrap; }
    .npc-shop-price { width: 100%; text-align: right; }
}

/* ── Storage Manager ── */
.storage-selector {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.storage-guild-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.storage-char-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.storage-tab {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.5);
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.storage-tab:hover { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.8); }
.storage-tab.active {
    background: rgba(76,175,80,0.12);
    border-color: rgba(76,175,80,0.35);
    color: #81c784;
}
.storage-tab i { margin-right: 6px; font-size: 12px; }
.storage-online-dot {
    display: inline-block;
    width: 6px; height: 6px;
    background: #4caf50;
    border-radius: 50%;
    margin-left: 6px;
    vertical-align: middle;
    box-shadow: 0 0 4px rgba(76,175,80,0.6);
}
.storage-stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.storage-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: rgba(255,255,255,0.4);
}
.storage-stat i { color: rgba(255,255,255,0.2); font-size: 12px; }
.storage-stat strong { color: #81c784; }
.storage-controls {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.storage-search { flex: 1; min-width: 200px; }
.storage-filters { display: flex; gap: 8px; align-items: center; }
.storage-filters .db-select {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 4px;
    padding: 6px 10px;
    font-size: 13px;
    min-width: 100px;
}
.storage-filters .db-select option { background: #1a1a2e; }
.storage-sort-dir {
    width: 36px; height: 36px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.storage-sort-dir:hover { background: rgba(255,255,255,0.1); color: #fff; }
.storage-loading, .storage-empty {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255,255,255,0.35);
}
.storage-loading i, .storage-empty i { margin-bottom: 16px; display: block; color: rgba(255,255,255,0.15); }
.storage-empty h4 { color: rgba(255,255,255,0.4); margin-bottom: 8px; }
/* Storage Table */
.storage-table-wrap { margin-bottom: 20px; }
.storage-tbl { width: 100%; border-collapse: collapse; }
.storage-tbl th {
    text-align: left;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255,255,255,0.4);
    padding: 8px 10px;
    border-bottom: 2px solid rgba(255,255,255,0.08);
    white-space: nowrap;
    user-select: none;
}
.storage-tbl td {
    padding: 7px 10px;
    font-size: 13px;
    color: rgba(255,255,255,0.7);
    border-bottom: 1px solid rgba(255,255,255,0.04);
    vertical-align: middle;
}
.storage-tbl .st-row:hover td { background: rgba(255,255,255,0.03); }
.st-sortable { cursor: pointer; transition: color 0.2s; }
.st-sortable:hover { color: #ffb240; }
.st-sortable::after {
    content: '\f0dc'; /* fa-sort */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    margin-left: 5px;
    font-size: 10px;
    opacity: 0.3;
}
.st-sortable.sort-asc::after { content: '\f0de'; opacity: 0.8; color: #81c784; }
.st-sortable.sort-desc::after { content: '\f0dd'; opacity: 0.8; color: #81c784; }
.st-chk-col { width: 36px; text-align: center !important; }
.st-chk-col input[type="checkbox"] {
    accent-color: #ffb240;
    width: 15px; height: 15px;
    cursor: pointer;
}
.st-act-col { width: 80px; }
.item-name-cell { min-width: 180px; }
.item-name-cell img { vertical-align: middle; margin-right: 6px; }
.item-slots { color: rgba(255,255,255,0.25); font-size: 12px; }
.item-cards { color: #ce93d8; font-size: 12px; }
.price-cell { color: #ffd54f; }

/* Storage badges (inline) */
.storage-badge {
    font-size: 9px;
    padding: 1px 5px;
    border-radius: 3px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin-left: 4px;
    vertical-align: middle;
}
.storage-badge-equip { background: rgba(33,150,243,0.15); color: #64b5f6; border: 1px solid rgba(33,150,243,0.3); }
.storage-badge-bound { background: rgba(255,152,0,0.15); color: #ffb74d; border: 1px solid rgba(255,152,0,0.3); }
.storage-badge-unid  { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.35); border: 1px solid rgba(255,255,255,0.1); }
.storage-badge-broken{ background: rgba(244,67,54,0.15); color: #ef5350; border: 1px solid rgba(244,67,54,0.3); }

/* Action buttons */
.st-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px; height: 28px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 12px;
    margin: 0 2px;
    text-decoration: none;
}
.st-xfer-btn:hover { background: rgba(33,150,243,0.15); color: #64b5f6; border-color: rgba(33,150,243,0.4); }
.st-sell-btn:hover  { background: rgba(255,178,64,0.15); color: #ffb240; border-color: rgba(255,178,64,0.4); }

/* Bulk actions bar */
.st-bulk-bar {
    position: sticky;
    bottom: 0;
    background: linear-gradient(135deg, #1a2240 0%, #16213e 100%);
    border: 1px solid rgba(255,178,64,0.25);
    border-radius: 8px;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 12px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.4);
    z-index: 10;
}
.st-bulk-count { color: #ffb240; font-weight: 600; font-size: 14px; white-space: nowrap; }
.st-bulk-dest {
    flex: 1;
    max-width: 240px;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    border-radius: 4px;
    padding: 6px 10px;
    font-size: 13px;
}
.st-bulk-dest option { background: #1a1a2e; }

/* Transfer Modal */
.st-transfer-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    padding: 20px;
}
.st-transfer-inner {
    background: linear-gradient(135deg, #1a2240 0%, #16213e 100%);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 24px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 16px 48px rgba(0,0,0,0.5);
}
.st-transfer-inner h5 {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    margin: 0 0 16px;
    font-size: 16px;
}
.st-transfer-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 16px;
    font-size: 14px;
    color: #e0e0e0;
    flex-wrap: wrap;
}
.st-transfer-item img { width: 32px; height: 32px; object-fit: contain; image-rendering: pixelated; }
.st-xfer-type { margin-left: auto; }
.st-transfer-amount-row { margin-bottom: 12px; }
.st-page-info { color: rgba(255,255,255,0.3); font-size: 12px; margin-left: 8px; }

@media (max-width: 768px) {
    .storage-selector { flex-direction: column; }
    .storage-controls { flex-direction: column; }
    .storage-filters { width: 100%; }
    .storage-stats { flex-direction: column; gap: 8px; }
    .st-bulk-bar { flex-direction: column; text-align: center; }
    .st-bulk-dest { max-width: 100%; }
    /* Responsive card layout — mirrors .db-table mobile pattern */
    .storage-tbl thead { display: none; }
    .storage-tbl tbody tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(255,255,255,0.04);
        border-radius: 8px;
        border: 1px solid rgba(255,255,255,0.08);
        padding: 0;
        overflow: hidden;
    }
    .storage-tbl tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 6px 12px;
        border: none;
        font-size: 13px;
        text-align: right;
    }
    .storage-tbl tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: rgba(255,255,255,0.45);
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        min-width: 90px;
        flex-shrink: 0;
        text-align: left;
    }
    .storage-tbl tbody td.item-name-cell {
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 15px;
        font-weight: 600;
        background: rgba(0,0,0,0.2);
        padding: 10px 12px;
        border-bottom: 1px solid rgba(255,255,255,0.08);
        text-align: left;
        min-width: 0;
    }
    .storage-tbl tbody td.item-name-cell::before {
        display: none;
    }
    .storage-tbl tbody td.item-name-cell .item-icon-sm {
        width: 32px;
        height: 32px;
        flex-shrink: 0;
        object-fit: contain;
        margin-right: 0;
    }
    .storage-tbl tbody td:nth-child(even):not(.item-name-cell):not(.st-chk-col) {
        background: rgba(255,255,255,0.02);
    }
    .storage-tbl tbody td.st-chk-col {
        display: none;
    }
    .storage-tbl tbody td.st-act-col::before {
        content: none;
    }
    .storage-tbl tbody td.st-act-col {
        justify-content: flex-end;
        border-top: 1px solid rgba(255,255,255,0.06);
        padding-top: 6px;
        margin-top: 2px;
    }
    .item-name-cell { min-width: 0; }
}

/* ─── Server Stats / Infographics ─── */
.stats-section {
    padding: 20px 0;
}

/* Overview cards */
.stats-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: transform 0.2s, border-color 0.2s;
}
.stats-card:hover {
    transform: translateY(-2px);
    border-color: rgba(52,152,219,0.3);
}
.stats-card-icon {
    font-size: 1.8rem;
    color: #3498db;
    margin-bottom: 8px;
}
.stats-card-value {
    font-family: 'Exo 2', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}
.stats-card-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stats-card-sub {
    font-size: 11px;
    color: rgba(255,215,0,0.6);
    margin-top: 4px;
}
.stats-card-sub i { margin-right: 3px; }

/* Mini stats row */
.stats-mini {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 10px 14px;
}
.stats-mini-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
}
.stats-mini-value {
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    color: #ffd54f;
    font-size: 0.95rem;
}

/* Chart cards */
.stats-chart-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 20px;
}
.stats-chart-card h3 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 4px;
}
.stats-chart-card h3 i { color: #3498db; margin-right: 8px; font-size: 0.95rem; }
.stats-chart-link {
    float: right;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    color: #3498db;
    text-decoration: none;
    margin-top: 4px;
}
.stats-chart-link:hover { color: #5dade2; text-decoration: underline; }
.stats-chart-link i { font-size: 0.7rem; margin: 0 0 0 3px; color: inherit; }
.stats-chart-subtitle {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    margin-bottom: 10px;
}
.stats-chart-wrap {
    position: relative;
    height: 280px;
}
.stats-chart-wrap-tall {
    height: 350px;
}

/* Section title */
.stats-section-title {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.stats-section-title i { color: #f39c12; margin-right: 8px; }

/* Custom system cards */
.stats-custom-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 18px;
}
.stats-custom-card h4 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    color: #fff;
    margin-bottom: 12px;
}
.stats-custom-card h4 i { color: #e74c3c; margin-right: 6px; }
.stats-custom-stat {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.9rem;
}
.stats-custom-stat:last-child { border-bottom: none; }
.stats-custom-stat span { color: rgba(255,255,255,0.5); }
.stats-custom-stat strong { color: #ffd54f; }

/* Loading overlay */
.stats-loading {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(10,10,20,0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    gap: 12px;
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
}

/* Responsive */
@media (max-width: 768px) {
    .stats-card-value { font-size: 1.5rem; }
    .stats-chart-wrap { height: 250px; }
    .stats-chart-wrap-tall { height: 300px; }
}
@media (max-width: 576px) {
    .stats-chart-card { padding: 14px; }
}

/* ─── Economy Dashboard ─── */
.econ-section { padding: 16px 0; }

/* Overview cards */
.econ-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 18px;
    text-align: center;
    transition: transform 0.2s, border-color 0.2s;
}
.econ-card:hover {
    transform: translateY(-2px);
    border-color: rgba(243,156,18,0.3);
}
.econ-card-zeny { border-color: rgba(243,156,18,0.2); }
.econ-card-cash { border-color: rgba(155,89,182,0.2); }
.econ-card-icon { font-size: 1.6rem; color: #f39c12; margin-bottom: 6px; }
.econ-card-cash .econ-card-icon { color: #9b59b6; }
.econ-card-value {
    font-family: 'Exo 2', sans-serif;
    font-size: 1.7rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}
.econ-card-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Chart cards */
.econ-chart-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 20px;
}
.econ-chart-card h3 {
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 4px;
}
.econ-chart-card h3 i { color: #f39c12; margin-right: 8px; font-size: 0.95rem; }
.econ-chart-note {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    margin-bottom: 10px;
}
.econ-chart-note strong { color: #ffd54f; }
.econ-chart-wrap {
    position: relative;
    height: 280px;
}
.econ-chart-tall { height: 400px; }

/* Gini bar */
.econ-gini-bar {
    position: relative;
    height: 18px;
    background: rgba(255,255,255,0.06);
    border-radius: 9px;
    margin-bottom: 16px;
    overflow: hidden;
}
.econ-gini-fill {
    height: 100%;
    border-radius: 9px;
    transition: width 0.6s ease;
    width: 0;
}
.econ-gini-labels {
    position: absolute;
    top: 0; left: 0; right: 0;
    display: flex;
    justify-content: space-between;
    padding: 1px 8px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.6);
    line-height: 18px;
}

/* Empty state */
.econ-empty {
    text-align: center;
    padding: 40px 20px;
    color: rgba(255,255,255,0.3);
}
.econ-empty i { font-size: 2rem; margin-bottom: 10px; display: block; }
.econ-empty p { font-family: 'Rajdhani', sans-serif; font-size: 0.95rem; margin: 0; }

@media (max-width: 768px) {
    .econ-card-value { font-size: 1.3rem; }
    .econ-chart-wrap { height: 250px; }
    .econ-chart-tall { height: 320px; }
}
@media (max-width: 576px) {
    .econ-chart-card { padding: 14px; }
}

/* ═══════════════ MVP Boss Tracker ═══════════════ */
.mvp-section { padding: 20px 0; }
.mvp-search-wrap {
    position: relative;
    flex: 1;
    max-width: 300px;
}
.mvp-search-wrap i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    z-index: 1;
}
.mvp-search-wrap .form-control {
    padding-left: 36px;
}
.mvp-filters {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.mvp-controls {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.mvp-controls .form-control,
.mvp-controls .custom-select {
    background: #1e1e32;
    border: 1px solid #333;
    color: #eee;
    max-width: 260px;
}
.mvp-controls .form-control:focus,
.mvp-controls .custom-select:focus {
    border-color: #e74c3c;
    box-shadow: 0 0 0 2px rgba(231,76,60,.25);
}
#mvp-count {
    margin-left: auto;
    color: #8eaccd;
    font-size: 14px;
}

.mvp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
}

.mvp-card {
    background: linear-gradient(135deg, #1a1a2e 0%, #1e1e38 100%);
    border: 1px solid #2a2a4a;
    border-radius: 10px;
    padding: 16px;
    cursor: pointer;
    transition: transform .2s, border-color .2s, box-shadow .2s;
}
.mvp-card:hover {
    transform: translateY(-3px);
    border-color: #e74c3c;
    box-shadow: 0 6px 24px rgba(231,76,60,.15);
}

.mvp-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}
.mvp-card-sprite {
    width: 64px;
    height: 64px;
    object-fit: contain;
    flex-shrink: 0;
    filter: drop-shadow(0 0 6px rgba(231,76,60,.3));
}
.mvp-card-info h4 {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
}
.mvp-card-meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    font-size: 12px;
    color: #999;
}
.mvp-card-level { color: #f1c40f; font-weight: 600; }

.mvp-card-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    background: rgba(0,0,0,.2);
    border-radius: 6px;
    padding: 8px 12px;
    margin-bottom: 10px;
    text-align: center;
}
.mvp-card-stats span { display: block; font-size: 10px; color: #777; text-transform: uppercase; }
.mvp-card-stats strong { display: block; font-size: 13px; color: #e0e0e0; }

.mvp-card-spawn {
    font-size: 13px;
    color: #aaa;
    margin-bottom: 10px;
    padding: 6px 0;
    border-top: 1px solid rgba(255,255,255,.06);
}
.mvp-card-spawn .fa-map-marker-alt { color: #e74c3c; }
.mvp-card-map { color: #58a6ff; }
.mvp-card-extra { color: #e67e22; font-size: 11px; }

.mvp-card-actions {
    display: flex;
    gap: 8px;
}
.mvp-card-actions .btn { flex: 1; font-size: 12px; }

/* Detail modal */
.mvp-detail-section {
    font-size: 15px;
    font-weight: 700;
    color: #e74c3c;
    border-bottom: 1px solid rgba(231,76,60,.3);
    padding-bottom: 6px;
    margin-bottom: 10px;
}
.mvp-detail-table td:first-child { color: #999; width: 40%; }
.mvp-detail-table td:last-child { color: #eee; font-weight: 600; }

.mvp-spawn-list { display: flex; flex-direction: column; gap: 8px; }
.mvp-spawn-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,.2);
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
}
.mvp-spawn-map { color: #58a6ff; }
.mvp-spawn-timer { color: #e0e0e0; }

.mvp-drop-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 8px;
}
.mvp-drop-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0,0,0,.2);
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 13px;
}
.mvp-drop-icon { width: 24px; height: 24px; object-fit: contain; flex-shrink: 0; }
.mvp-drop-name { flex: 1; color: #ddd; }
.mvp-drop-rate { color: #f1c40f; font-weight: 600; white-space: nowrap; }

.mvp-kill-list { display: flex; flex-direction: column; gap: 4px; }
.mvp-kill-item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    padding: 4px 0;
    border-bottom: 1px solid rgba(255,255,255,.04);
}

/* Respawn calculator */
#calc-result {
    background: rgba(231,76,60,.1);
    border: 1px solid rgba(231,76,60,.3);
    border-radius: 8px;
    padding: 16px;
    margin-top: 16px;
}
.calc-time {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 15px;
}
.calc-time:last-child { margin-bottom: 0; }
.calc-time strong { color: #f1c40f; }

/* Loading */
#mvp-loading {
    text-align: center;
    padding: 60px 0;
}

@media (max-width: 768px) {
    .mvp-grid { grid-template-columns: 1fr; }
    .mvp-controls { flex-direction: column; align-items: stretch; }
    .mvp-controls .form-control,
    .mvp-controls .custom-select { max-width: 100%; }
    #mvp-count { margin-left: 0; }
    .mvp-drop-list { grid-template-columns: 1fr; }
}
@media (max-width: 576px) {
    .mvp-card-stats { grid-template-columns: repeat(2, 1fr); }
    .mvp-card-header { flex-direction: column; text-align: center; }
}

/* ═══════════════ Live World Map ═══════════════ */
/* Overview bar */
.wmap-overview { background: #12121e; padding: 16px 0; border-bottom: 1px solid #222; }
.wmap-overview-bar {
    display: flex;
    align-items: center;
    gap: 28px;
    flex-wrap: wrap;
}
.wmap-stat {
    display: flex;
    align-items: center;
    gap: 10px;
}
.wmap-stat > i { font-size: 24px; color: #1abc9c; }
.wmap-stat-value { display: block; font-size: 22px; font-weight: 700; color: #fff; line-height: 1; }
.wmap-stat-label { display: block; font-size: 12px; color: #777; text-transform: uppercase; }
.wmap-refresh { margin-left: auto; text-align: center; }
.wmap-countdown { width: 100px; height: 4px; background: #222; border-radius: 2px; margin-top: 6px; overflow: hidden; }
.wmap-countdown-bar { height: 100%; background: #1abc9c; border-radius: 2px; transition: width 1s linear; width: 100%; }

/* Tabs */
.wmap-content { padding: 24px 0 40px; }
.wmap-tabs .nav-link {
    color: #aaa;
    border: 1px solid transparent;
    border-radius: 6px;
    padding: 6px 16px;
    font-size: 14px;
}
.wmap-tabs .nav-link.active {
    background: rgba(26,188,156,.15);
    border-color: #1abc9c;
    color: #1abc9c;
}

/* Map grid */
.wmap-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
}

/* Active map card */
.wmap-card {
    background: linear-gradient(135deg, #1a1a2e 0%, #1e1e38 100%);
    border: 1px solid #2a2a4a;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: transform .2s, border-color .2s, box-shadow .2s;
}
.wmap-card:hover {
    transform: translateY(-3px);
    border-color: #1abc9c;
    box-shadow: 0 6px 24px rgba(26,188,156,.15);
}
.wmap-card-img-wrap {
    position: relative;
    height: 160px;
    overflow: hidden;
    background: #111;
}
.wmap-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: .85;
    transition: opacity .2s;
}
.wmap-card:hover .wmap-card-img { opacity: 1; }
.wmap-card-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(26,188,156,.9);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
}
.wmap-card-body { padding: 12px 16px 16px; }
.wmap-card-body h4 { font-size: 16px; font-weight: 700; color: #fff; margin: 0 0 8px; }

.wmap-card-players { display: flex; flex-direction: column; gap: 4px; }
.wmap-card-player {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}
.wmap-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; display: inline-block; }
.wmap-pname { color: #ddd; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wmap-plevel { color: #f1c40f; font-size: 11px; }
.wmap-pclass { color: #888; font-size: 11px; }
.wmap-more { color: #1abc9c; font-size: 12px; margin-top: 2px; }

/* Popular maps */
.wmap-pop-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #1a1a2e 0%, #1e1e38 100%);
    border: 1px solid #2a2a4a;
    border-radius: 10px;
    padding: 12px;
}
.wmap-pop-img-wrap {
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    background: #111;
}
.wmap-pop-img { width: 100%; height: 100%; object-fit: cover; }
.wmap-pop-info { flex: 1; min-width: 0; }
.wmap-pop-name { font-size: 14px; font-weight: 700; color: #fff; margin-bottom: 4px; }
.wmap-pop-bar-wrap { height: 6px; background: #222; border-radius: 3px; overflow: hidden; }
.wmap-pop-bar { height: 100%; background: linear-gradient(90deg, #1abc9c, #16a085); border-radius: 3px; transition: width .5s; }
.wmap-pop-count { font-size: 12px; color: #888; margin-top: 4px; }

/* Empty state */
.wmap-empty {
    text-align: center;
    padding: 60px 20px;
    color: #555;
}
.wmap-empty i { font-size: 48px; color: #333; margin-bottom: 16px; display: block; }
.wmap-empty h4 { color: #888; }

/* Map detail modal */
.wmap-detail { display: flex; min-height: 400px; }
.wmap-detail-canvas-wrap {
    flex: 1;
    background: #111;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
}
.wmap-detail-canvas-wrap canvas { max-width: 100%; height: auto; }
.wmap-detail-sidebar {
    width: 240px;
    background: #161628;
    padding: 16px;
    overflow-y: auto;
    max-height: 520px;
    border-left: 1px solid #222;
}
.wmap-detail-sidebar h6 { color: #1abc9c; font-size: 13px; font-weight: 700; margin-bottom: 12px; }

.wmap-player-list { display: flex; flex-direction: column; gap: 10px; }
.wmap-detail-player { display: flex; align-items: flex-start; gap: 8px; }
.wmap-detail-player .wmap-dot { margin-top: 5px; }
.wmap-detail-player-info { display: flex; flex-direction: column; font-size: 12px; min-width: 0; }
.wmap-detail-player-info strong { color: #eee; font-size: 13px; }
.wmap-detail-player-info span { color: #888; }
.wmap-detail-guild { color: #58a6ff !important; }

@media (max-width: 768px) {
    .wmap-grid { grid-template-columns: 1fr; }
    .wmap-overview-bar { flex-direction: column; align-items: flex-start; gap: 12px; }
    .wmap-refresh { margin-left: 0; }
    .wmap-detail { flex-direction: column; }
    .wmap-detail-sidebar { width: 100%; max-height: 200px; border-left: none; border-top: 1px solid #222; }
}
@media (max-width: 576px) {
    .wmap-card-img-wrap { height: 120px; }
}

/* ═══════════════ Guild War Room ═══════════════ */
.wr-section { padding: 24px 0; }
.wr-section-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #ddd;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid #333;
}

/* Overview cards */
.wr-overview-card {
    background: linear-gradient(135deg, #1a1a2e, #1e1e38);
    border: 1px solid #2a2a4a;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}
.wr-overview-card > i { font-size: 28px; color: #9b59b6; margin-bottom: 8px; }
.wr-overview-value { font-size: 24px; font-weight: 700; color: #fff; }
.wr-overview-label { font-size: 12px; color: #888; text-transform: uppercase; }

/* Realm dominance */
.wr-realm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.wr-realm-card {
    background: linear-gradient(135deg, #1a1a2e, #1e1e38);
    border: 1px solid #2a2a4a;
    border-left: 4px solid #555;
    border-radius: 8px;
    padding: 14px;
}
.wr-realm-name { font-size: 15px; font-weight: 700; margin-bottom: 8px; }
.wr-realm-bar-wrap { height: 8px; background: #222; border-radius: 4px; overflow: hidden; margin-bottom: 8px; }
.wr-realm-bar { height: 100%; border-radius: 4px; transition: width .5s; }
.wr-realm-stats { display: flex; justify-content: space-between; font-size: 12px; color: #999; flex-wrap: wrap; gap: 4px; }
.wr-realm-owner { color: #58a6ff; margin-left: 4px; }

/* Rankings */
.wr-rank-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #1a1a2e, #1e1e38);
    border: 1px solid #2a2a4a;
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: transform .15s, border-color .15s;
}
.wr-rank-card:hover { transform: translateX(4px); border-color: #9b59b6; }
.wr-rank-card.wr-rank-top { border-left: 3px solid #f1c40f; }

.wr-rank-pos { font-size: 18px; font-weight: 700; color: #888; min-width: 60px; text-align: center; }
.wr-rank-emblem { width: 40px; height: 40px; flex-shrink: 0; }
.wr-rank-emblem img { width: 100%; height: 100%; object-fit: contain; }

.wr-rank-info { flex: 1; min-width: 0; }
.wr-rank-name { font-size: 16px; font-weight: 700; color: #fff; margin-bottom: 2px; }
.wr-rank-meta { display: flex; gap: 12px; flex-wrap: wrap; font-size: 12px; color: #999; }
.wr-rank-castles { margin-top: 4px; }
.wr-rank-castles .badge { background: rgba(241,196,15,.15); color: #f1c40f; border: 1px solid rgba(241,196,15,.3); font-size: 11px; }
.wr-rank-diplomacy { margin-top: 4px; display: flex; gap: 8px; }
.wr-ally-badge { color: #2ecc71; font-size: 11px; }
.wr-enemy-badge { color: #e74c3c; font-size: 11px; }

.wr-rank-score { text-align: right; min-width: 90px; }
.wr-rank-score-value { font-size: 18px; font-weight: 700; color: #9b59b6; }
.wr-rank-score-bar { height: 4px; background: #222; border-radius: 2px; overflow: hidden; margin: 4px 0; }
.wr-rank-score-bar div { height: 100%; background: #9b59b6; border-radius: 2px; }
.wr-rank-score-label { font-size: 10px; color: #666; text-transform: uppercase; }

/* Castle grid */
.wr-region-group { margin-bottom: 24px; }
.wr-region-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 12px; }
.wr-castle-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.wr-castle-card {
    background: linear-gradient(135deg, #1a1a2e, #1e1e38);
    border: 1px solid #2a2a4a;
    border-top: 3px solid #555;
    border-radius: 8px;
    padding: 12px;
}
.wr-castle-card.owned { border-top-style: solid; }
.wr-castle-card.unclaimed { opacity: .6; }
.wr-castle-name { font-size: 14px; font-weight: 700; color: #fff; margin-bottom: 6px; }
.wr-castle-owner { font-size: 12px; color: #58a6ff; margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.wr-castle-emblem { width: 20px; height: 20px; object-fit: contain; }

.wr-castle-invest { display: flex; align-items: center; gap: 6px; font-size: 11px; color: #888; margin-bottom: 4px; }
.wr-castle-invest span:first-child { width: 28px; font-weight: 600; }
.wr-castle-invest span:last-child { width: 20px; text-align: right; }
.wr-invest-bar { flex: 1; height: 4px; background: #222; border-radius: 2px; overflow: hidden; }
.wr-invest-bar div { height: 100%; border-radius: 2px; }

.wr-guardians { display: flex; gap: 3px; margin-top: 6px; }
.wr-guardian { color: #333; font-size: 10px; }
.wr-guardian.alive { color: #2ecc71; }

/* Detail modal */
.wr-detail-section {
    font-size: 14px;
    font-weight: 700;
    color: #9b59b6;
    border-bottom: 1px solid rgba(155,89,182,.3);
    padding-bottom: 4px;
    margin-bottom: 10px;
}
.wr-member-list { display: flex; flex-direction: column; gap: 4px; }
.wr-member-row { display: flex; align-items: center; gap: 8px; font-size: 12px; padding: 2px 0; }
.wr-member-name { color: #eee; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wr-member-class { color: #888; }
.wr-member-level { color: #f1c40f; }
.wr-member-pos { font-size: 11px; }

@media (max-width: 768px) {
    .wr-rank-card { flex-wrap: wrap; }
    .wr-rank-score { min-width: 100%; text-align: left; margin-top: 8px; }
    .wr-castle-row { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
    .wr-realm-grid { grid-template-columns: 1fr; }
}

/* ======================================================
   ACHIEVEMENT SHOWCASE
   ====================================================== */
.ach-section { padding: 24px 0; }
.ach-section-title { font-family: 'Exo 2', sans-serif; font-weight: 700; color: #f1c40f; margin-bottom: 16px; }
.ach-section-title i { margin-right: 8px; }

/* Summary */
.ach-summary-card {
    background: rgba(241, 196, 15, 0.06);
    border: 1px solid rgba(241, 196, 15, 0.2);
    border-radius: 10px;
    padding: 20px 15px;
    text-align: center;
    transition: transform .2s, border-color .2s;
}
.ach-summary-card:hover { transform: translateY(-3px); border-color: #f1c40f; }
.ach-summary-card i { font-size: 26px; color: #f1c40f; margin-bottom: 8px; }
.ach-summary-value { font-family: 'Exo 2', sans-serif; font-size: 26px; font-weight: 700; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ach-summary-label { color: #888; font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }

/* Toolbar */
.ach-toolbar { margin-bottom: 10px; }
.ach-search-wrap {
    position: relative;
    margin-bottom: 12px;
    max-width: 400px;
}
.ach-search-wrap i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: #888; }
.ach-search-wrap input {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.12);
    color: #eee;
    padding-left: 36px;
    border-radius: 8px;
}
.ach-search-wrap input:focus { border-color: #f1c40f; box-shadow: 0 0 0 2px rgba(241,196,15,0.15); }
.ach-group-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.ach-group-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    color: #bbb;
    padding: 4px 12px;
    font-size: 12px;
    cursor: pointer;
    transition: all .2s;
}
.ach-group-btn:hover { background: rgba(241,196,15,0.12); color: #fff; }
.ach-group-btn.active { background: #f1c40f; color: #1a1a2e; border-color: #f1c40f; font-weight: 600; }
.ach-group-btn i { margin-right: 3px; }
.ach-rarity-filters { display: flex; flex-wrap: wrap; gap: 6px; }
.ach-rarity-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    color: #bbb;
    padding: 4px 14px;
    font-size: 12px;
    cursor: pointer;
    transition: all .2s;
}
.ach-rarity-btn:hover { color: #fff; }
.ach-rarity-btn.active { background: rgba(241,196,15,0.15); color: #fff; border-color: #f1c40f; }
.ach-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 4px; vertical-align: middle; }
.ach-dot-common { background: #27ae60; }
.ach-dot-uncommon { background: #3498db; }
.ach-dot-rare { background: #9b59b6; }
.ach-dot-legendary { background: #f39c12; }
.ach-dot-unobtained { background: #555; }

/* Count Bar */
.ach-count-bar { font-size: 13px; color: #888; margin-bottom: 12px; }

/* Achievement Grid */
.ach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }

/* Achievement Card */
.ach-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 14px 16px;
    transition: transform .2s, border-color .2s, box-shadow .2s;
    display: flex;
    flex-direction: column;
}
.ach-card:hover { transform: translateY(-2px); box-shadow: 0 4px 20px rgba(0,0,0,0.4); }
.ach-card-common { border-left: 3px solid #27ae60; }
.ach-card-uncommon { border-left: 3px solid #3498db; }
.ach-card-rare { border-left: 3px solid #9b59b6; }
.ach-card-legendary { border-left: 3px solid #f39c12; }
.ach-card-unobtained { border-left: 3px solid #555; opacity: 0.7; }
.ach-card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.ach-card-score { font-size: 12px; color: #f1c40f; }
.ach-card-score i { margin-right: 2px; }
.ach-card-rarity { font-size: 11px; padding: 2px 8px; border-radius: 10px; text-transform: uppercase; letter-spacing: .5px; font-weight: 600; }
.ach-rarity-common { background: rgba(39,174,96,0.2); color: #27ae60; }
.ach-rarity-uncommon { background: rgba(52,152,219,0.2); color: #3498db; }
.ach-rarity-rare { background: rgba(155,89,182,0.2); color: #9b59b6; }
.ach-rarity-legendary { background: rgba(243,156,18,0.2); color: #f39c12; }
.ach-rarity-unobtained { background: rgba(85,85,85,0.2); color: #888; }
.ach-card-title { font-family: 'Exo 2', sans-serif; font-weight: 700; font-size: 14px; color: #fff; margin-bottom: 4px; }
.ach-card-group { font-size: 11px; color: #888; margin-bottom: 6px; }
.ach-card-group i { margin-right: 3px; }
.ach-card-desc { font-size: 12px; color: #aaa; line-height: 1.4; flex: 1; margin-bottom: 8px; }
.ach-card-rewards { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.ach-reward-tag {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 8px;
    background: rgba(241,196,15,0.1);
    color: #f1c40f;
    border: 1px solid rgba(241,196,15,0.2);
}
.ach-reward-tag i { margin-right: 3px; }
.ach-reward-item { cursor: pointer; display: inline-flex; align-items: center; gap: 4px; }
.ach-reward-item:hover { background: rgba(241,196,15,0.2); }
.ach-reward-icon { width: 18px; height: 18px; image-rendering: pixelated; vertical-align: middle; }
.ach-card-stats { margin-top: auto; }
.ach-completion-bar {
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 4px;
}
.ach-completion-fill { height: 100%; border-radius: 2px; transition: width .6s ease; }
.ach-fill-common { background: #27ae60; }
.ach-fill-uncommon { background: #3498db; }
.ach-fill-rare { background: #9b59b6; }
.ach-fill-legendary { background: #f39c12; }
.ach-fill-unobtained { background: #555; }
.ach-completion-text { font-size: 11px; color: #888; }

/* Leaderboard */
.ach-leaderboard { max-width: 600px; }
.ach-lb-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: background .15s;
}
.ach-lb-row:hover { background: rgba(241,196,15,0.05); }
.ach-medal { font-size: 18px; width: 28px; text-align: center; }
.ach-gold { color: #f1c40f; }
.ach-silver { color: #bbb; }
.ach-bronze { color: #cd7f32; }
.ach-rank { font-size: 13px; color: #888; width: 28px; text-align: center; }
.ach-lb-name { color: #4fc3f7; text-decoration: none; flex: 1; font-weight: 600; }
.ach-lb-name:hover { color: #81d4fa; text-decoration: underline; }
.ach-lb-level { font-size: 12px; color: #888; }
.ach-lb-count { color: #f1c40f; font-weight: 600; font-size: 13px; }
.ach-lb-count i { margin-right: 3px; }

/* Recent */
.ach-recent { max-width: 700px; }
.ach-recent-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    font-size: 13px;
}
.ach-recent-date { color: #666; min-width: 90px; font-size: 12px; }
.ach-recent-char { color: #4fc3f7; text-decoration: none; min-width: 100px; }
.ach-recent-char:hover { text-decoration: underline; }
.ach-recent-title { color: #bbb; flex: 1; }

@media (max-width: 768px) {
    .ach-grid { grid-template-columns: 1fr; }
    .ach-recent-row { flex-wrap: wrap; }
}

/* ======================================================
   PET COLLECTION GALLERY
   ====================================================== */
.pet-section { padding: 24px 0; }
.pet-section-title { font-family: 'Exo 2', sans-serif; font-weight: 700; color: #27ae60; margin-bottom: 16px; }
.pet-section-title i { margin-right: 8px; }

/* Summary */
.pet-summary-card {
    background: rgba(39, 174, 96, 0.06);
    border: 1px solid rgba(39, 174, 96, 0.2);
    border-radius: 10px;
    padding: 20px 15px;
    text-align: center;
    transition: transform .2s, border-color .2s;
}
.pet-summary-card:hover { transform: translateY(-3px); border-color: #27ae60; }
.pet-summary-card i { font-size: 26px; color: #27ae60; margin-bottom: 8px; }
.pet-summary-value { font-family: 'Exo 2', sans-serif; font-size: 26px; font-weight: 700; color: #fff; }
.pet-summary-label { color: #888; font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }

/* Toolbar */
.pet-toolbar { margin-bottom: 10px; }
.pet-search-wrap {
    position: relative;
    margin-bottom: 12px;
    max-width: 400px;
}
.pet-search-wrap i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: #888; }
.pet-search-wrap input {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.12);
    color: #eee;
    padding-left: 36px;
    border-radius: 8px;
}
.pet-search-wrap input:focus { border-color: #27ae60; box-shadow: 0 0 0 2px rgba(39,174,96,0.15); }
.pet-filter-row { display: flex; flex-wrap: wrap; gap: 6px; }
.pet-filter-btn {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    color: #bbb;
    padding: 5px 14px;
    font-size: 12px;
    cursor: pointer;
    transition: all .2s;
}
.pet-filter-btn:hover { background: rgba(39,174,96,0.12); color: #fff; }
.pet-filter-btn.active { background: #27ae60; color: #fff; border-color: #27ae60; font-weight: 600; }
.pet-filter-btn i { margin-right: 4px; }
.pet-count-bar { font-size: 13px; color: #888; margin-bottom: 12px; }

/* Pet Grid */
.pet-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }

/* Pet Card */
.pet-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 14px;
    text-align: center;
    cursor: pointer;
    transition: transform .2s, border-color .2s, box-shadow .2s;
}
.pet-card:hover { transform: translateY(-4px); border-color: #27ae60; box-shadow: 0 6px 24px rgba(0,0,0,0.4); }
.pet-card-sprite { position: relative; margin-bottom: 8px; }
.pet-card-sprite img { width: 64px; height: 64px; object-fit: contain; image-rendering: pixelated; }
.pet-evo-badge {
    position: absolute;
    top: -4px; right: 20%;
    background: #9b59b6;
    color: #fff;
    border-radius: 50%;
    width: 20px; height: 20px;
    font-size: 10px;
    display: flex; align-items: center; justify-content: center;
}
.pet-card-name { font-family: 'Exo 2', sans-serif; font-weight: 700; font-size: 14px; color: #fff; margin-bottom: 4px; }
.pet-card-catch { font-size: 12px; color: #888; margin-bottom: 4px; }
.pet-card-catch i { color: #27ae60; margin-right: 3px; }
.pet-card-meta { font-size: 11px; }
.pet-owned-badge { color: #27ae60; }
.pet-unowned-badge { color: #666; }

/* Detail Modal */
.pet-detail-sprite { width: 120px; height: 120px; object-fit: contain; image-rendering: pixelated; margin-bottom: 8px; }
.pet-detail-id { font-size: 12px; color: #666; }
.pet-detail-stat { font-size: 13px; margin-bottom: 4px; }
.pet-detail-heading { font-family: 'Exo 2', sans-serif; font-weight: 700; color: #27ae60; font-size: 14px; margin: 16px 0 8px; border-bottom: 1px solid rgba(39,174,96,0.2); padding-bottom: 4px; }
.pet-detail-table { width: 100%; font-size: 13px; margin-bottom: 10px; }
.pet-detail-table td { padding: 3px 8px; }
.pet-detail-label { color: #888; width: 40%; }
.pet-item-icon { width: 20px; height: 20px; vertical-align: middle; margin-right: 4px; }
.pet-item-link { color: #d4af37; text-decoration: none; }
.pet-item-link:hover { color: #f0d060; text-decoration: underline; }
.pet-bonuses { display: flex; flex-wrap: wrap; gap: 6px; }
.pet-bonus-tag {
    font-size: 12px;
    padding: 3px 10px;
    border-radius: 8px;
    background: rgba(39,174,96,0.1);
    color: #27ae60;
    border: 1px solid rgba(39,174,96,0.2);
}
.pet-bonus-tag i { margin-right: 3px; }

/* Evolution Chain */
.pet-evo-chain {
    background: rgba(155,89,182,0.06);
    border: 1px solid rgba(155,89,182,0.2);
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 8px;
}
.pet-evo-target { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.pet-evo-sprite { width: 40px; height: 40px; object-fit: contain; image-rendering: pixelated; }
.pet-evo-target span { font-weight: 600; color: #c39bd3; }
.pet-evo-items { display: flex; flex-wrap: wrap; gap: 6px; }
.pet-evo-item {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 6px;
    background: rgba(155,89,182,0.1);
    color: #bb8fce;
}

/* Collectors Leaderboard */
.pet-collectors { max-width: 600px; }
.pet-lb-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: background .15s;
}
.pet-lb-row:hover { background: rgba(39,174,96,0.05); }
.pet-medal { font-size: 18px; width: 28px; text-align: center; }
.pet-gold { color: #f1c40f; }
.pet-silver { color: #bbb; }
.pet-bronze { color: #cd7f32; }
.pet-rank { font-size: 13px; color: #888; width: 28px; text-align: center; }
.pet-lb-name { color: #4fc3f7; text-decoration: none; flex: 1; font-weight: 600; }
.pet-lb-name:hover { color: #81d4fa; text-decoration: underline; }
.pet-lb-level { font-size: 12px; color: #888; }
.pet-lb-count { color: #27ae60; font-weight: 600; font-size: 13px; }
.pet-lb-count i { margin-right: 3px; }

/* Recent */
.pet-recent { max-width: 600px; }
.pet-recent-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    font-size: 13px;
}
.pet-recent-sprite { width: 28px; height: 28px; object-fit: contain; image-rendering: pixelated; }
.pet-recent-petname { color: #27ae60; font-weight: 600; }
.pet-recent-arrow { color: #555; }
.pet-recent-char { color: #4fc3f7; text-decoration: none; }
.pet-recent-char:hover { text-decoration: underline; }

@media (max-width: 768px) {
    .pet-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
    .pet-lb-row { flex-wrap: wrap; }
}

/* ============================================
   Media Gallery (/media/)
   ============================================ */
#panel-header.theme-media {
    background: linear-gradient(135deg, #241b3a 0%, #15131f 60%, #0e0d14 100%);
    border-bottom: 2px solid #8b5cf6;
}
#panel-header.theme-media h1 { color: #fff; }
#panel-header.theme-media h1 i { color: #a78bfa; }

.media-section { padding: 24px 0; }

/* Filter pills */
.media-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.media-filter-btn {
    padding: 6px 14px;
    border: 1px solid #333;
    border-radius: 20px;
    background: #1c1c1c;
    color: #bbb;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 500;
}
.media-filter-btn:hover { background: rgba(167, 139, 250, 0.14); color: #fff; }
.media-filter-btn.active { background: #8b5cf6; color: #fff; border-color: #8b5cf6; font-weight: 600; }
.media-filter-btn i { margin-right: 5px; }

.media-count { font-size: 13px; color: #888; margin-bottom: 14px; }

/* Grid */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.media-tile {
    position: relative;
    margin: 0;
    border-radius: 10px;
    overflow: hidden;
    background: #16181d;
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.media-tile:hover,
.media-tile:focus {
    transform: translateY(-4px);
    border-color: #a78bfa;
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.45);
    outline: none;
}
.media-tile img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    background: #0c0d10;
}
@supports not (aspect-ratio: 1) {
    .media-tile img { height: 165px; }
}
.media-tile figcaption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 18px 12px 8px;
    font-family: 'Rajdhani', sans-serif;
    font-weight: 600;
    font-size: 13px;
    color: #fff;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0));
    opacity: 0;
    transition: opacity 0.18s ease;
}
.media-tile:hover figcaption,
.media-tile:focus figcaption { opacity: 1; }

/* Play badge for video tiles */
.media-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: rgba(139, 92, 246, 0.92);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    padding-left: 4px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
    transition: transform 0.18s ease, background 0.18s ease;
}
.media-tile.is-video:hover .media-play { transform: translate(-50%, -50%) scale(1.1); background: #8b5cf6; }

/* Empty / error state (spans the full grid width so it centers) */
.media-empty { grid-column: 1 / -1; text-align: center; color: #777; padding: 60px 20px; }
.media-empty i { font-size: 40px; color: #555; margin-bottom: 14px; display: block; }
.media-empty p { font-family: 'Rajdhani', sans-serif; font-size: 16px; margin: 0; }

/* Lightbox */
body.media-lb-lock { overflow: hidden; }
#media-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(8, 8, 11, 0.94);
    backdrop-filter: blur(3px);
    padding: 56px 16px;
}
#media-lightbox.open { display: flex; }
.media-lb-content {
    position: relative;
    max-width: 1100px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.media-lb-stage { width: 100%; display: flex; align-items: center; justify-content: center; }
.media-lb-media { max-width: 100%; max-height: 78vh; border-radius: 8px; box-shadow: 0 14px 50px rgba(0, 0, 0, 0.6); }
.media-lb-video { position: relative; width: 100%; max-width: 960px; aspect-ratio: 16 / 9; }
.media-lb-video iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    box-shadow: 0 14px 50px rgba(0, 0, 0, 0.6);
}
.media-lb-caption { margin-top: 14px; text-align: center; color: #ddd; font-family: 'Rajdhani', sans-serif; max-width: 760px; }
.media-lb-caption strong { display: block; color: #fff; font-size: 17px; font-weight: 600; }
.media-lb-caption span { display: block; color: #9aa0aa; font-size: 14px; margin-top: 3px; }

#media-lb-close,
#media-lb-prev,
#media-lb-next {
    position: fixed;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, transform 0.15s ease;
}
#media-lb-close:hover { background: #8b5cf6; transform: scale(1.06); }
#media-lb-close { top: 16px; right: 18px; width: 44px; height: 44px; font-size: 20px; }
#media-lb-prev,
#media-lb-next { top: 50%; transform: translateY(-50%); width: 50px; height: 50px; font-size: 22px; }
#media-lb-prev:hover,
#media-lb-next:hover { background: #8b5cf6; transform: translateY(-50%) scale(1.06); }
#media-lb-prev { left: 18px; }
#media-lb-next { right: 18px; }

@media (max-width: 600px) {
    .media-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
    #media-lb-prev, #media-lb-next { width: 42px; height: 42px; font-size: 18px; }
    #media-lb-prev { left: 8px; }
    #media-lb-next { right: 8px; }
    .media-lb-media { max-height: 70vh; }
}

/* Admin media manager (/admin/ → Media tab) */
.media-mgr-heading { font-family: 'Exo 2', sans-serif; font-weight: 700; color: #ffb240; font-size: 13px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 10px; }
.media-mgr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 12px; }
.media-mgr-card { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 8px; overflow: hidden; }
.media-mgr-thumb { position: relative; aspect-ratio: 16 / 10; background: #0c0d10; }
.media-mgr-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.media-mgr-badge { position: absolute; top: 6px; left: 6px; background: rgba(0, 0, 0, 0.7); color: #fff; font-size: 10px; padding: 2px 7px; border-radius: 10px; text-transform: uppercase; letter-spacing: 0.5px; }
.media-mgr-body { padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; }
.media-mgr-body input, .media-mgr-body select { font-size: 12px; }
.media-mgr-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* ============================================
   Collection tab strip (shared by Cards / Headgears / Pets / Achievements)
   ============================================ */
.collection-tabs-section { padding: 18px 0 0; }
.collection-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}
.collection-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 18px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.03);
    color: #bbb;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.15s ease;
}
.collection-tab:hover { background: rgba(255, 255, 255, 0.08); color: #fff; border-color: rgba(255, 255, 255, 0.25); text-decoration: none; }
.collection-tab i { font-size: 13px; }
.collection-tab.active { background: #4fc3f7; color: #0d1117; border-color: #4fc3f7; }
.collection-tab.active:hover { background: #6fd0fa; color: #0d1117; }
@media (max-width: 480px) {
    .collection-tab { padding: 7px 13px; font-size: 13px; }
}

/* ============================================
   Skill Tree Planner
   ============================================ */
/* Controls bar */
.sk-controls {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 24px;
    padding: 14px 18px;
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    border: 1px solid rgba(79,195,247,0.12);
}
#sk-job-select {
    background: #1e1e2d;
    color: #e0e0e0;
    border: 1px solid rgba(79,195,247,0.25);
    border-radius: 6px;
    padding: 8px 14px;
    font-size: 14px;
    min-width: 200px;
}
#sk-job-select:focus {
    outline: none;
    border-color: #4fc3f7;
    box-shadow: 0 0 0 2px rgba(79,195,247,0.15);
}
.sk-points {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #aaa;
    margin-left: auto;
}
.sk-points strong { color: #4fc3f7; font-size: 18px; }
.sk-points .sk-sep { color: #555; }
.sk-btn {
    background: rgba(79,195,247,0.1);
    color: #4fc3f7;
    border: 1px solid rgba(79,195,247,0.25);
    border-radius: 6px;
    padding: 7px 16px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.sk-btn:hover {
    background: rgba(79,195,247,0.2);
    border-color: #4fc3f7;
}
#sk-share-url {
    background: #1e1e2d;
    color: #4fc3f7;
    border: 1px solid rgba(79,195,247,0.2);
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 12px;
    width: 240px;
    display: none;
}

/* Empty state */
.sk-empty {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 16px;
    display: none;
}
.sk-empty i { font-size: 48px; margin-bottom: 16px; display: block; color: #444; }

/* Skill grid */
.sk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}

/* Skill card */
.sk-skill {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}
.sk-skill:hover { border-color: rgba(79,195,247,0.3); }
.sk-skill.sk-locked { opacity: 0.45; }
.sk-skill.sk-maxed { border-color: rgba(79,195,247,0.5); box-shadow: 0 0 10px rgba(79,195,247,0.1); }
.sk-skill.sk-partial { border-color: rgba(79,195,247,0.25); }

.sk-skill-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}
.sk-skill-type { font-size: 14px; }
.sk-type-passive { color: #81c784; }
.sk-type-attack { color: #e57373; }
.sk-type-self { color: #4fc3f7; }
.sk-type-support { color: #ffb74d; }
.sk-type-ground { color: #ce93d8; }
.sk-type-trap { color: #ff8a65; }
.sk-type-misc { color: #90a4ae; }

.sk-skill-name {
    font-size: 13px;
    font-weight: 600;
    color: #ddd;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.sk-skill-level {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 14px;
    font-weight: 700;
}
.sk-skill-cur { color: #4fc3f7; font-size: 18px; }
.sk-skill-sep { color: #555; }
.sk-skill-max { color: #888; }
.sk-skill-minus, .sk-skill-plus {
    background: rgba(79,195,247,0.1);
    color: #4fc3f7;
    border: 1px solid rgba(79,195,247,0.2);
    border-radius: 4px;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 11px;
    transition: all 0.15s;
}
.sk-skill-minus:hover, .sk-skill-plus:hover {
    background: rgba(79,195,247,0.25);
    border-color: #4fc3f7;
}
.sk-skill-minus:disabled, .sk-skill-plus:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}
.sk-locked .sk-skill-minus, .sk-locked .sk-skill-plus {
    opacity: 0.2;
    pointer-events: none;
}

/* Prereq tags */
.sk-prereqs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
}
.sk-prereq {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
}
.sk-prereq-met { background: rgba(129,199,132,0.15); color: #81c784; }
.sk-prereq-unmet { background: rgba(229,115,115,0.15); color: #e57373; }

/* Tooltip */
#sk-tooltip {
    position: absolute;
    z-index: 9000;
    background: #1a1a2e;
    border: 1px solid rgba(79,195,247,0.3);
    border-radius: 8px;
    padding: 12px 16px;
    min-width: 220px;
    max-width: 320px;
    display: none;
    pointer-events: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.6);
}
.sk-tt-name { font-size: 15px; font-weight: 700; color: #4fc3f7; margin-bottom: 4px; }
.sk-tt-id { font-size: 11px; color: #777; margin-bottom: 6px; }
.sk-tt-type { font-size: 12px; color: #aaa; margin-bottom: 4px; }
.sk-tt-level { font-size: 12px; color: #aaa; margin-bottom: 4px; }
.sk-tt-sp { font-size: 11px; color: #999; margin-bottom: 4px; word-wrap: break-word; }
.sk-tt-cursp { font-size: 12px; color: #4fc3f7; font-weight: 600; }

/* Loading */
.sk-loading {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 16px;
}

@media (max-width: 768px) {
    .sk-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
    .sk-controls { flex-direction: column; align-items: stretch; }
    .sk-points { margin-left: 0; justify-content: center; }
    #sk-job-select { min-width: 100%; }
}

/* ============================================
   Card Album / Collection Tracker
   ============================================ */
.cd-section { padding: 20px 0; }

.cd-summary-card {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(231,76,60,0.12);
    border-radius: 10px;
    padding: 18px 14px;
    text-align: center;
    transition: border-color 0.3s;
}
.cd-summary-card:hover { border-color: rgba(231,76,60,0.35); }
.cd-summary-card > i { font-size: 22px; color: #e74c3c; margin-bottom: 8px; }
.cd-summary-value { font-size: 28px; font-weight: 700; color: #fff; }
.cd-summary-label { font-size: 13px; color: #888; }

/* Toolbar */
.cd-toolbar {
    background: rgba(0,0,0,0.25);
    border-radius: 8px;
    padding: 14px 18px;
    border: 1px solid rgba(231,76,60,0.12);
}
.cd-search-wrap {
    position: relative;
    margin-bottom: 12px;
}
.cd-search-wrap i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
}
.cd-search-wrap .form-control {
    background: #1e1e2d;
    border: 1px solid rgba(231,76,60,0.2);
    color: #e0e0e0;
    padding-left: 36px;
    border-radius: 6px;
}
.cd-search-wrap .form-control:focus {
    border-color: #e74c3c;
    box-shadow: 0 0 0 2px rgba(231,76,60,0.15);
}
.cd-filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}
.cd-filter-btn, .cd-slot-btn {
    background: rgba(231,76,60,0.08);
    color: #ccc;
    border: 1px solid rgba(231,76,60,0.15);
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}
.cd-filter-btn:hover, .cd-slot-btn:hover {
    background: rgba(231,76,60,0.15);
    color: #fff;
}
.cd-filter-btn.active, .cd-slot-btn.active {
    background: rgba(231,76,60,0.25);
    color: #e74c3c;
    border-color: #e74c3c;
}

.cd-count-bar {
    font-size: 13px;
    color: #888;
    margin-bottom: 12px;
}

/* Card Grid */
.cd-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 12px;
}

/* Card Item */
.cd-card {
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 12px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}
.cd-card:hover { transform: translateY(-3px); box-shadow: 0 4px 16px rgba(0,0,0,0.5); }

/* Rarity borders */
.cd-rarity-common { border-color: rgba(200,200,200,0.15); }
.cd-rarity-common:hover { border-color: rgba(200,200,200,0.4); }
.cd-rarity-uncommon { border-color: rgba(46,204,113,0.2); }
.cd-rarity-uncommon:hover { border-color: rgba(46,204,113,0.5); }
.cd-rarity-rare { border-color: rgba(52,152,219,0.25); }
.cd-rarity-rare:hover { border-color: rgba(52,152,219,0.6); }
.cd-rarity-legendary { border-color: rgba(241,196,15,0.3); }
.cd-rarity-legendary:hover { border-color: rgba(241,196,15,0.7); box-shadow: 0 0 12px rgba(241,196,15,0.15); }
.cd-rarity-undiscovered { border-color: rgba(231,76,60,0.1); opacity: 0.5; }
.cd-rarity-undiscovered:hover { opacity: 0.8; border-color: rgba(231,76,60,0.3); }

.cd-card-img {
    width: 64px;
    height: 90px;
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cd-card-img img {
    max-width: 100%;
    max-height: 100%;
    image-rendering: pixelated;
}
.cd-card-name {
    font-size: 12px;
    font-weight: 600;
    color: #ddd;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cd-card-slot {
    font-size: 10px;
    color: #888;
    margin-bottom: 6px;
}
.cd-owned-badge {
    font-size: 10px;
    background: rgba(46,204,113,0.15);
    color: #2ecc71;
    padding: 2px 8px;
    border-radius: 10px;
}
.cd-undiscovered-badge {
    font-size: 10px;
    background: rgba(231,76,60,0.12);
    color: #e74c3c;
    padding: 2px 8px;
    border-radius: 10px;
}
.cd-card-mob {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-top: 6px;
    font-size: 10px;
    color: #999;
}
.cd-mob-sprite {
    width: 20px;
    height: 20px;
    object-fit: contain;
    image-rendering: pixelated;
}

/* Section title */
.cd-section-title {
    font-size: 18px;
    color: #e74c3c;
    margin-bottom: 16px;
}
.cd-section-title i { margin-right: 8px; }

/* Rarest list */
.cd-rarest-list { max-width: 600px; }
.cd-rare-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    border-left: 3px solid transparent;
}
.cd-rare-row:hover { background: rgba(231,76,60,0.05); }
.cd-rarity-border-legendary { border-left-color: #f1c40f; }
.cd-rarity-border-rare { border-left-color: #3498db; }
.cd-rarity-border-uncommon { border-left-color: #2ecc71; }
.cd-rarity-border-common { border-left-color: #aaa; }
.cd-rare-sprite {
    width: 32px;
    height: 44px;
    object-fit: contain;
    image-rendering: pixelated;
}
.cd-rare-name { flex: 1; font-size: 14px; font-weight: 600; color: #ddd; }
.cd-rare-count { font-size: 13px; color: #888; }

/* Card Detail Modal */
.cd-detail {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}
.cd-detail-img {
    text-align: center;
    min-width: 100px;
}
.cd-detail-img img {
    width: 80px;
    image-rendering: pixelated;
    margin-bottom: 8px;
}
.cd-detail-rarity {
    display: inline-block;
    font-size: 11px;
    padding: 2px 10px;
    border-radius: 10px;
    text-transform: capitalize;
}
.cd-detail-rarity.cd-rarity-common { background: rgba(200,200,200,0.15); color: #ccc; }
.cd-detail-rarity.cd-rarity-uncommon { background: rgba(46,204,113,0.15); color: #2ecc71; }
.cd-detail-rarity.cd-rarity-rare { background: rgba(52,152,219,0.15); color: #3498db; }
.cd-detail-rarity.cd-rarity-legendary { background: rgba(241,196,15,0.15); color: #f1c40f; }
.cd-detail-rarity.cd-rarity-undiscovered { background: rgba(231,76,60,0.12); color: #e74c3c; }

.cd-detail-info { flex: 1; }
.cd-detail-info p { margin-bottom: 6px; font-size: 14px; color: #ccc; }
.cd-detail-info strong { color: #e74c3c; }
.cd-detail-mob {
    width: 28px;
    height: 28px;
    object-fit: contain;
    vertical-align: middle;
    image-rendering: pixelated;
    margin-right: 4px;
}
.cd-detail-bonuses { margin-top: 10px; }
.cd-detail-bonuses ul {
    list-style: none;
    padding: 0;
    margin: 6px 0 0;
}
.cd-detail-bonuses li {
    padding: 3px 0;
    font-size: 13px;
}
.cd-detail-bonuses code {
    background: rgba(231,76,60,0.1);
    color: #f39c12;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.cd-btn {
    background: rgba(231,76,60,0.1);
    color: #e74c3c;
    border: 1px solid rgba(231,76,60,0.25);
    border-radius: 6px;
    padding: 8px 24px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}
.cd-btn:hover {
    background: rgba(231,76,60,0.2);
    border-color: #e74c3c;
}

/* ── Card Table Rows ──────────────────── */
.cd-row-icon {
    width: 24px;
    height: 32px;
    object-fit: contain;
    image-rendering: pixelated;
    vertical-align: middle;
    margin-right: 6px;
}
.cd-my-check {
    color: #2ecc71;
    font-size: 11px;
    margin-left: 4px;
}
.cd-rarity-row-legendary td:first-child { border-left: 3px solid #f1c40f; }
.cd-rarity-row-rare td:first-child { border-left: 3px solid #9b59b6; }
.cd-rarity-row-uncommon td:first-child { border-left: 3px solid #3498db; }
.cd-rarity-row-undiscovered { opacity: 0.55; }
.cd-rarity-row-undiscovered:hover { opacity: 0.85; }

@media (max-width: 768px) {
    .cd-detail { flex-direction: column; align-items: center; text-align: center; }
    .cd-filter-row { justify-content: center; }
}

/* ── Personal Collection Banner & Badges ──────────────────── */
.cd-personal-bar {
    background: linear-gradient(135deg, rgba(46,204,113,0.08), rgba(52,152,219,0.08));
    border: 1px solid rgba(46,204,113,0.2);
    border-radius: 10px;
    padding: 16px 20px;
}
.cd-personal-info {
    font-size: 15px;
    color: #ccc;
    margin-bottom: 10px;
}
.cd-personal-info i { color: #2ecc71; margin-right: 4px; }
.cd-personal-count { color: #fff; font-weight: 700; font-size: 17px; }
.cd-personal-pct { color: #2ecc71; font-weight: 600; }
.cd-personal-progress {
    height: 8px;
    background: rgba(255,255,255,0.06);
    border-radius: 4px;
    overflow: hidden;
}
.cd-personal-fill {
    height: 100%;
    background: linear-gradient(90deg, #2ecc71, #3498db);
    border-radius: 4px;
    transition: width 0.8s ease;
}
.cd-mine {
    border-color: rgba(46,204,113,0.35) !important;
    box-shadow: 0 0 8px rgba(46,204,113,0.1);
}
.cd-my-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 20px;
    height: 20px;
    background: #2ecc71;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    z-index: 2;
}
.cd-owned-tag {
    background: rgba(46,204,113,0.15);
    color: #2ecc71;
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
}
.cd-card, .pet-card, .ach-card {
    position: relative;
}
.rank-collections-header {
    font-size: 14px;
    color: #aaa;
    margin-bottom: 16px;
    padding: 10px 0;
}
.rank-collections-header i {
    color: #2ecc71;
    margin-right: 6px;
}

/* ═══════════════════════════════════════════════════════════════
   NOTIFICATIONS
   ═══════════════════════════════════════════════════════════════ */

.notif-bell-item {
    position: relative;
}
.notif-bell-link {
    position: relative;
    padding: 8px 12px !important;
    font-size: 16px;
}
.notif-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background: #e53935;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    font-family: 'Rajdhani', sans-serif;
    min-width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    border-radius: 8px;
    padding: 0 4px;
    pointer-events: none;
}
.notif-dropdown {
    width: 360px;
    max-height: 420px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, rgba(15,15,30,0.98), rgba(25,20,40,0.98)) !important;
    border: 1px solid rgba(212,175,55,0.2) !important;
    border-radius: 10px !important;
    padding: 0 !important;
    backdrop-filter: blur(20px);
}
.notif-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    font-family: 'Exo 2', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #d4af37;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex-shrink: 0;
}
.notif-read-all-btn {
    color: rgba(255,255,255,0.4);
    font-size: 14px;
    transition: color 0.2s;
}
.notif-read-all-btn:hover {
    color: #4caf50;
    text-decoration: none;
}
.notif-list {
    overflow-y: auto;
    max-height: 370px;
    flex: 1;
}
.notif-empty {
    padding: 32px 16px;
    text-align: center;
    color: rgba(255,255,255,0.3);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}
.notif-empty i {
    display: block;
    font-size: 24px;
    margin-bottom: 8px;
    opacity: 0.4;
}
.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 16px;
    cursor: pointer;
    transition: background 0.15s;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    position: relative;
}
.notif-item:hover {
    background: rgba(212,175,55,0.08);
}
.notif-unread {
    background: rgba(212,175,55,0.04);
}
.notif-unread::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #d4af37;
    border-radius: 0 2px 2px 0;
}
.notif-read {
    opacity: 0.6;
}
.notif-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: rgba(255,255,255,0.06);
    font-size: 14px;
}
.notif-content {
    flex: 1;
    min-width: 0;
}
.notif-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    line-height: 1.3;
}
.notif-body {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    line-height: 1.3;
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.notif-time {
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    color: rgba(255,255,255,0.3);
    margin-top: 2px;
}
.notif-dismiss {
    flex-shrink: 0;
    background: none;
    border: none;
    color: rgba(255,255,255,0.2);
    font-size: 12px;
    padding: 4px;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1;
}
.notif-dismiss:hover {
    color: #e53935;
}

@media (max-width: 576px) {
    .notif-dropdown {
        width: 300px;
        max-height: 360px;
        right: -60px !important;
    }
}

/* ═══════════════════════════════════════════════════════════════
   ATTENDANCE / DAILY LOGIN REWARDS
   ═══════════════════════════════════════════════════════════════ */

.attendance-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.attendance-stat {
    flex: 1;
    min-width: 160px;
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 18px 20px;
}
.attendance-stat i {
    font-size: 28px;
    color: #f39c12;
}
.attendance-stat-val {
    display: block;
    font-size: 28px;
    font-weight: 700;
    font-family: 'Exo 2', sans-serif;
    color: #fff;
    line-height: 1;
}
.attendance-stat-label {
    display: block;
    font-size: 12px;
    color: rgba(255,255,255,0.45);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.attendance-month-select {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.attendance-month-select label {
    color: rgba(255,255,255,0.6);
    font-size: 14px;
    margin: 0;
}
.attendance-month-select select {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 6px;
    color: #fff;
    padding: 6px 12px;
    font-size: 14px;
}

/* Calendar */
.attendance-calendar {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 30px;
}
.cal-header {
    text-align: center;
    margin-bottom: 16px;
}
.cal-header h3 {
    color: #fff;
    margin: 0;
    font-family: 'Exo 2', sans-serif;
    font-size: 20px;
}
.cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}
.cal-day-header {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    padding: 8px 0;
}
.cal-cell {
    position: relative;
    text-align: center;
    padding: 12px 6px;
    border-radius: 8px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.06);
    min-height: 60px;
    transition: all 0.2s;
}
.cal-empty {
    background: transparent;
    border-color: transparent;
}
.cal-day-num {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: rgba(255,255,255,0.5);
    font-family: 'Exo 2', sans-serif;
}
.cal-login {
    background: rgba(46,204,113,0.12);
    border-color: rgba(46,204,113,0.3);
}
.cal-login .cal-day-num {
    color: #2ecc71;
}
.cal-check {
    display: block;
    color: #2ecc71;
    font-size: 14px;
    margin-top: 4px;
}
.cal-today {
    border-color: #f39c12 !important;
    box-shadow: 0 0 8px rgba(243,156,18,0.2);
}
.cal-today .cal-day-num {
    color: #f39c12;
}
.cal-missed {
    opacity: 0.4;
}

/* Calendar legend */
.cal-legend {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 16px;
    flex-wrap: wrap;
}
.cal-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(255,255,255,0.5);
}
.cal-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}
.cal-dot-login { background: #2ecc71; }
.cal-dot-today { background: #f39c12; }
.cal-dot-missed { background: rgba(255,255,255,0.15); }

/* Streak Rewards */
.attendance-rewards {
    margin-bottom: 40px;
}
.attendance-rewards h3 {
    color: #fff;
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    margin-bottom: 16px;
}
.attendance-reward-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.att-reward-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 16px 20px;
    transition: all 0.2s;
}
.att-reward-achieved {
    background: rgba(46,204,113,0.08);
    border-color: rgba(46,204,113,0.25);
}
.att-reward-icon {
    font-size: 24px;
    color: rgba(255,255,255,0.3);
    width: 40px;
    text-align: center;
}
.att-reward-achieved .att-reward-icon {
    color: #f39c12;
}
.att-reward-info {
    flex: 1;
}
.att-reward-label {
    font-weight: 600;
    color: #fff;
    font-size: 15px;
}
.att-reward-desc {
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    margin-top: 2px;
}
.att-reward-badge {
    color: #2ecc71;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}
.att-reward-claimed {
    background: rgba(255,255,255,0.02);
    border-color: rgba(255,255,255,0.06);
    opacity: 0.7;
}
.att-reward-claimed .att-reward-icon {
    color: rgba(255,255,255,0.25);
}
.att-claim-btn {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: #fff;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    padding: 6px 16px;
    white-space: nowrap;
    transition: transform 0.15s, box-shadow 0.15s;
}
.att-claim-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(243,156,18,0.4);
    color: #fff;
}
.att-reward-remaining {
    font-size: 12px;
    color: rgba(255,255,255,0.35);
    white-space: nowrap;
}
.att-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(46,204,113,0.95);
    color: #fff;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    z-index: 99999;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: none;
}
.att-toast.att-toast-error {
    background: rgba(231,76,60,0.95);
}
.att-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.attendance-loading {
    text-align: center;
    padding: 40px;
    color: rgba(255,255,255,0.4);
}

@media (max-width: 576px) {
    .cal-cell { padding: 8px 4px; min-height: 48px; }
    .cal-day-num { font-size: 13px; }
    .cal-check { font-size: 11px; }
    .attendance-stats { flex-direction: column; }
}

/* ============================================
   Web Marketplace
   ============================================ */

/* --- Top Bar --- */
.wm-topbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-bottom: 20px;
}
.wm-search {
    flex: 1 1 260px;
    min-width: 200px;
}
.wm-search .input-group-text {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
}
.wm-search .form-control {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    padding: 8px 14px;
    height: auto;
}
.wm-search .form-control::placeholder { color: rgba(255,255,255,0.35); }
.wm-search .form-control:focus {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,178,64,0.4);
    box-shadow: 0 0 0 0.2rem rgba(255,178,64,0.15);
    color: #fff;
}
.wm-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.wm-filters .db-select {
    min-width: 130px;
}
.wm-actions {
    display: flex;
    gap: 8px;
}
.wm-info {
    font-size: 13px;
    color: rgba(255,255,255,0.45);
    margin-bottom: 12px;
}
.wm-info span {
    color: #ffb240;
    font-weight: 600;
}

/* --- Buttons --- */
.wm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.wm-btn-sell {
    background: rgba(76,175,80,0.15);
    color: #4caf50;
    border-color: rgba(76,175,80,0.3);
}
.wm-btn-sell:hover {
    background: rgba(76,175,80,0.25);
    border-color: rgba(76,175,80,0.5);
}
.wm-btn-my {
    background: rgba(33,150,243,0.15);
    color: #2196f3;
    border-color: rgba(33,150,243,0.3);
}
.wm-btn-my:hover {
    background: rgba(33,150,243,0.25);
    border-color: rgba(33,150,243,0.5);
}
.wm-btn-collect {
    background: rgba(255,178,64,0.15);
    color: #ffb240;
    border-color: rgba(255,178,64,0.3);
}
.wm-btn-collect:hover {
    background: rgba(255,178,64,0.25);
    border-color: rgba(255,178,64,0.5);
}

/* --- Listing Table --- */
.wm-listing-row {
    cursor: pointer;
    transition: background 0.2s;
}
.wm-listing-row:hover td {
    background: rgba(255,178,64,0.06);
}

/* --- Buy Panel --- */
.wm-buy-header,
.wm-sell-header,
.wm-my-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.wm-buy-header h5,
.wm-sell-header h5,
.wm-my-header h5 {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    color: #fff;
    margin: 0;
}
.wm-buy-header h5 i,
.wm-sell-header h5 i,
.wm-my-header h5 i {
    color: #ffb240;
    margin-right: 6px;
}

.wm-detail-icon {
    width: 24px;
    height: 24px;
    vertical-align: middle;
    margin-right: 6px;
}

.wm-buy-item-detail {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 20px;
}
.wm-detail-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: rgba(255,255,255,0.7);
    border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wm-detail-row:last-child { border-bottom: none; }
.wm-detail-row span:first-child {
    color: rgba(255,255,255,0.45);
    font-size: 13px;
}

/* --- Sell Panel / Storage Grid --- */
.wm-sell-char-row {
    margin-bottom: 16px;
}
.wm-sell-char-row label {
    display: block;
    font-size: 13px;
    color: rgba(255,255,255,0.5);
    margin-bottom: 6px;
}
.wm-storage-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
    padding-right: 4px;
    margin-bottom: 16px;
}
.wm-storage-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.wm-storage-item:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,178,64,0.25);
}
.wm-storage-selected {
    background: rgba(255,178,64,0.1) !important;
    border-color: rgba(255,178,64,0.4) !important;
}
.wm-storage-item-icon img {
    width: 24px;
    height: 24px;
}
.wm-storage-item-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.wm-storage-item-name {
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.wm-storage-item-meta {
    font-size: 12px;
    color: rgba(255,255,255,0.45);
}

.wm-sell-form {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 16px 20px;
}
.wm-sell-form-item {
    font-size: 15px;
    color: #fff;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.wm-price-input {
    width: 180px !important;
    background: rgba(255,255,255,0.06) !important;
    border: 1px solid rgba(255,255,255,0.12) !important;
    color: #ffb240 !important;
    font-size: 16px !important;
    font-weight: 600 !important;
}
.wm-price-input:focus {
    border-color: rgba(255,178,64,0.5) !important;
    box-shadow: 0 0 0 0.2rem rgba(255,178,64,0.15) !important;
}

/* --- My Listings --- */
.wm-stats-row {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.wm-stat {
    flex: 1;
    min-width: 80px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    padding: 12px 16px;
    text-align: center;
}
.wm-stat-num {
    display: block;
    font-family: 'Exo 2', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #ffb240;
    line-height: 1;
}
.wm-stat-label {
    font-size: 12px;
    color: rgba(255,255,255,0.45);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wm-my-collect {
    background: rgba(255,178,64,0.08);
    border: 1px solid rgba(255,178,64,0.2);
    border-radius: 10px;
    padding: 14px 20px;
    margin-bottom: 16px;
}
.wm-collect-info {
    font-size: 14px;
    color: rgba(255,255,255,0.7);
    margin-bottom: 10px;
}
.wm-collect-info i {
    color: #ffb240;
    margin-right: 6px;
}
.wm-collect-info strong {
    color: #ffb240;
}
.wm-collect-form {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}
.wm-collect-form .npc-buy-select {
    flex: 1;
    min-width: 200px;
}

.wm-my-filter {
    margin-bottom: 14px;
}

/* My listing items */
.wm-my-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.wm-my-item {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 14px 18px;
    transition: border-color 0.3s;
}
.wm-my-item:hover {
    border-color: rgba(255,255,255,0.15);
}
.wm-my-item-main {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.wm-my-item-icon img {
    width: 28px;
    height: 28px;
}
.wm-my-item-info {
    flex: 1;
    min-width: 0;
}
.wm-my-item-name {
    font-size: 14px;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
}
.wm-my-item-meta {
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    display: block;
    margin-top: 2px;
}
.wm-my-item-status {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.wm-my-expires {
    font-size: 12px;
    color: rgba(255,255,255,0.45);
}
.wm-my-buyer {
    font-size: 12px;
    color: rgba(255,255,255,0.45);
}

/* Status badges */
.wm-status-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}
.wm-status-active {
    background: rgba(76,175,80,0.15);
    color: #4caf50;
}
.wm-status-active .wm-status-badge { background: rgba(76,175,80,0.15); color: #4caf50; }
.wm-status-sold { }
.wm-status-sold .wm-status-badge,
.wm-status-badge.wm-status-sold {
    background: rgba(255,178,64,0.15);
    color: #ffb240;
}
.wm-status-expired .wm-status-badge,
.wm-status-badge.wm-status-expired {
    background: rgba(244,67,54,0.15);
    color: #f44336;
}
.wm-status-cancelled .wm-status-badge,
.wm-status-badge.wm-status-cancelled {
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.45);
}

.wm-uncollected-tag {
    font-size: 12px;
    color: #ffb240;
    font-weight: 600;
}
.wm-uncollected-tag i { margin-right: 3px; }
.wm-collected-tag {
    font-size: 12px;
    color: #4caf50;
}
.wm-collected-tag i { margin-right: 3px; }

/* Cancel button */
.wm-cancel-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: rgba(244,67,54,0.12);
    border: 1px solid rgba(244,67,54,0.25);
    border-radius: 6px;
    color: #f44336;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}
.wm-cancel-btn:hover {
    background: rgba(244,67,54,0.25);
    border-color: rgba(244,67,54,0.5);
}

/* Responsive */
@media (max-width: 768px) {
    .wm-topbar { flex-direction: column; }
    .wm-search { flex: 1 1 100%; }
    .wm-storage-grid { grid-template-columns: 1fr; }
    .wm-stats-row { flex-wrap: wrap; }
    .wm-stat { min-width: 70px; }
    .wm-my-item-main { flex-direction: column; align-items: flex-start; }
    .wm-my-item-status { margin-top: 8px; }
    .wm-collect-form { flex-direction: column; }
}
@media (max-width: 576px) {
    .wm-actions { width: 100%; }
    .wm-btn { flex: 1; justify-content: center; }
}

/* ═══════════════════════════════════════════════════════════════
   Notification Bell & Dropdown (Navbar)
   ═══════════════════════════════════════════════════════════════ */

/* Bell icon in nav */
.nav-notif-bell { position: relative; }
.nav-notif-bell .nav-link {
    position: relative;
    padding: 8px 12px !important;
    font-size: 18px;
    color: rgba(255,255,255,0.7);
    transition: color 0.2s;
}
.nav-notif-bell .nav-link:hover { color: #ffb240; }

/* Badge */
.notif-badge {
    position: absolute;
    top: 2px;
    right: 4px;
    background: #e74c3c;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    font-family: 'Rajdhani', sans-serif;
    min-width: 18px;
    height: 18px;
    line-height: 18px;
    text-align: center;
    border-radius: 9px;
    padding: 0 5px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.4);
    pointer-events: none;
}

/* Dropdown panel */
.notif-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    width: 360px;
    max-height: 480px;
    background: linear-gradient(135deg, rgba(15,15,30,0.98), rgba(25,20,40,0.98));
    border: 1px solid rgba(212,175,55,0.2);
    border-radius: 12px;
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    z-index: 10010;
    overflow: hidden;
    flex-direction: column;
}
.notif-dropdown.active {
    display: flex;
}

/* Dropdown header */
.notif-dd-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    font-family: 'Exo 2', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
}
.notif-dd-header a {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: #ffb240;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.notif-dd-header a:hover { text-decoration: underline; }

/* Dropdown list */
.notif-dd-list {
    flex: 1;
    overflow-y: auto;
    max-height: 380px;
}

/* Dropdown item */
.notif-dd-item {
    display: flex;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: background 0.15s;
}
.notif-dd-item:hover {
    background: rgba(255,178,64,0.06);
}
.notif-dd-item.notif-read {
    opacity: 0.55;
}
.notif-dd-item:not(.notif-read) {
    border-left: 3px solid #ffb240;
}

/* Dropdown item icon */
.notif-dd-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,178,64,0.1);
    color: #ffb240;
    font-size: 14px;
}

/* Dropdown item content */
.notif-dd-content { flex: 1; min-width: 0; }
.notif-dd-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #e0e0e0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.notif-dd-msg {
    font-size: 12px;
    color: rgba(255,255,255,0.45);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.notif-dd-time {
    font-size: 11px;
    color: rgba(255,178,64,0.6);
    margin-top: 3px;
}

/* Loading / empty states */
.notif-dd-loading,
.notif-dd-empty {
    padding: 30px 16px;
    text-align: center;
    color: rgba(255,255,255,0.4);
    font-size: 13px;
}

/* Dropdown footer */
.notif-dd-footer {
    display: block;
    text-align: center;
    padding: 12px 16px;
    border-top: 1px solid rgba(255,255,255,0.08);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: #ffb240;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: background 0.15s;
}
.notif-dd-footer:hover {
    background: rgba(255,178,64,0.06);
    color: #ffb240;
    text-decoration: none;
}

/* Mobile: full-width dropdown */
@media (max-width: 576px) {
    .notif-dropdown {
        width: calc(100vw - 20px);
        right: -60px;
    }
}


/* ═══════════════════════════════════════════════════════════════
   Notifications Full Page (/panel/notifications.html)
   ═══════════════════════════════════════════════════════════════ */

/* Toolbar */
.notif-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding: 12px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
}
.notif-toolbar-left,
.notif-toolbar-right {
    display: flex;
    gap: 8px;
    align-items: center;
}
.notif-filter-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    padding: 5px 16px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s;
    cursor: pointer;
}
.notif-filter-btn:hover {
    border-color: rgba(255,178,64,0.3);
    color: #ffb240;
}
.notif-filter-btn.active {
    background: rgba(255,178,64,0.12);
    border-color: rgba(255,178,64,0.3);
    color: #ffb240;
}

/* Notification items — full page */
.notif-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 16px 20px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    margin-bottom: 8px;
    transition: background 0.15s, border-color 0.15s;
}
.notif-item.notif-clickable {
    cursor: pointer;
}
.notif-item:hover {
    background: rgba(255,178,64,0.04);
    border-color: rgba(255,178,64,0.12);
}
.notif-item.notif-read {
    opacity: 0.5;
}
.notif-item:not(.notif-read) {
    border-left: 3px solid #ffb240;
}

/* Icon */
.notif-icon {
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,178,64,0.1);
    color: #ffb240;
    font-size: 16px;
}

/* Body */
.notif-body { flex: 1; min-width: 0; }
.notif-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #e0e0e0;
}
.notif-message {
    font-size: 13px;
    color: rgba(255,255,255,0.45);
    margin-top: 3px;
    line-height: 1.4;
}
.notif-time {
    font-size: 12px;
    color: rgba(255,178,64,0.6);
    margin-top: 5px;
}

/* Actions column */
.notif-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}
.notif-delete-btn {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.2);
    font-size: 14px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}
.notif-delete-btn:hover {
    color: #e74c3c;
    background: rgba(231,76,60,0.1);
}

/* Pagination */
.notif-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 24px;
    padding-bottom: 40px;
}
.notif-page-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    min-width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.notif-page-btn:hover {
    border-color: rgba(255,178,64,0.3);
    color: #ffb240;
}
.notif-page-btn.active {
    background: rgba(255,178,64,0.15);
    border-color: rgba(255,178,64,0.4);
    color: #ffb240;
}
.notif-page-ellipsis {
    color: rgba(255,255,255,0.3);
    padding: 0 4px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .notif-toolbar {
        flex-direction: column;
        align-items: stretch;
    }
    .notif-toolbar-left,
    .notif-toolbar-right {
        justify-content: center;
    }
    .notif-item {
        padding: 12px 14px;
        gap: 12px;
    }
    .notif-icon {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
    .notif-title { font-size: 14px; }
    .notif-message { font-size: 12px; }
}


/* ═══════════════════════════════════════════════════════════════
   Live Chat Bridge Widget
   ═══════════════════════════════════════════════════════════════ */

#chat-widget {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 10000;
    font-family: 'Rajdhani', sans-serif;
}

/* ── Toggle Button ─────────────────────────────────────────── */

#chat-toggle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #ffb240, #e6982e);
    color: #1a1a2e;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(255,178,64,0.35), 0 0 0 0 rgba(255,178,64,0.4);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: chat-pulse 3s ease-in-out infinite;
}
#chat-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 24px rgba(255,178,64,0.5);
}
#chat-toggle.chat-open {
    animation: none;
    background: linear-gradient(135deg, #e6982e, #cc8226);
}

@keyframes chat-pulse {
    0%, 100% { box-shadow: 0 4px 16px rgba(255,178,64,0.35), 0 0 0 0 rgba(255,178,64,0.4); }
    50%      { box-shadow: 0 4px 16px rgba(255,178,64,0.35), 0 0 0 8px rgba(255,178,64,0); }
}

/* ── Badge ─────────────────────────────────────────────────── */

.chat-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 10px;
    background: #f44336;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 20px;
    text-align: center;
    pointer-events: none;
    animation: chat-badge-pop 0.3s ease;
}
@keyframes chat-badge-pop {
    0%   { transform: scale(0); }
    60%  { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* ── Panel ─────────────────────────────────────────────────── */

#chat-panel {
    position: absolute;
    bottom: 64px;
    left: 0;
    width: 380px;
    max-height: 520px;
    background: #12121e;
    border: 1px solid rgba(255,178,64,0.2);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,178,64,0.08);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* ── Header ────────────────────────────────────────────────── */

.chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    border-bottom: 1px solid rgba(255,178,64,0.15);
}
.chat-title {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.5px;
}
.chat-title i {
    margin-right: 6px;
    font-size: 14px;
}
.chat-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.5);
    font-size: 22px;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color 0.2s;
}
.chat-close:hover {
    color: #f44336;
}

/* ── Channel Tabs ──────────────────────────────────────────── */

.chat-tabs {
    display: flex;
    background: rgba(12,12,24,0.8);
    border-bottom: 1px solid rgba(255,178,64,0.1);
    padding: 0;
}
.chat-tab {
    flex: 1;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: rgba(255,255,255,0.4);
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 7px 6px 5px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
    position: relative;
}
.chat-tab:hover {
    color: var(--tab-color, #ffb240);
    background: rgba(255,255,255,0.03);
}
.chat-tab.chat-tab-active {
    color: var(--tab-color, #ffb240);
    border-bottom-color: var(--tab-color, #ffb240);
}
.chat-tab-badge {
    position: absolute;
    top: 2px;
    right: 4px;
    min-width: 14px;
    height: 14px;
    padding: 0 3px;
    border-radius: 7px;
    background: #f44336;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    line-height: 14px;
    text-align: center;
    pointer-events: none;
}

/* ── Messages Area ─────────────────────────────────────────── */

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 10px 14px;
    min-height: 260px;
    max-height: 340px;
    font-size: 13px;
    line-height: 1.5;
    color: #ccc;
    scroll-behavior: smooth;
}
.chat-messages::-webkit-scrollbar {
    width: 5px;
}
.chat-messages::-webkit-scrollbar-track {
    background: transparent;
}
.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255,178,64,0.2);
    border-radius: 3px;
}
.chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(255,178,64,0.35);
}

/* Message row */
.chat-msg {
    padding: 3px 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}
.chat-msg + .chat-msg {
    border-top: 1px solid rgba(255,255,255,0.03);
}
.chat-time {
    color: rgba(255,255,255,0.3);
    font-size: 11px;
    font-family: 'Courier New', monospace;
    margin-right: 4px;
}
.chat-name {
    color: #81c784;
    font-weight: 600;
}
.chat-name.chat-web {
    color: #64b5f6;
}
.chat-web-tag {
    color: #64b5f6;
    font-size: 10px;
    opacity: 0.7;
}
.chat-text {
    color: #ddd;
}
.chat-error {
    color: #f44336;
    font-size: 12px;
    padding: 4px 8px;
    margin: 4px 0;
    background: rgba(244,67,54,0.1);
    border-radius: 4px;
    border-left: 2px solid #f44336;
}

/* Empty state */
.chat-messages:empty::after {
    content: 'No messages yet...';
    display: block;
    text-align: center;
    color: rgba(255,255,255,0.2);
    padding: 40px 0;
    font-size: 14px;
}

/* ── Input Area ────────────────────────────────────────────── */

.chat-input-area {
    border-top: 1px solid rgba(255,178,64,0.12);
    background: rgba(26,26,46,0.6);
}

.chat-char-select {
    padding: 8px 12px 4px;
}
.chat-char-select select {
    width: 100%;
    background: #1a1a2e;
    border: 1px solid rgba(255,178,64,0.2);
    border-radius: 6px;
    color: #ccc;
    padding: 6px 10px;
    font-size: 12px;
    font-family: 'Rajdhani', sans-serif;
    cursor: pointer;
    transition: border-color 0.2s;
}
.chat-char-select select:focus {
    border-color: #ffb240;
    outline: none;
}

.chat-compose {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px 10px;
}
.chat-compose input {
    flex: 1;
    background: #1a1a2e;
    border: 1px solid rgba(255,178,64,0.2);
    border-radius: 6px;
    color: #eee;
    padding: 8px 12px;
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    transition: border-color 0.2s;
}
.chat-compose input:focus {
    border-color: #ffb240;
    outline: none;
}
.chat-compose input::placeholder {
    color: rgba(255,255,255,0.25);
}

#chat-send {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #ffb240, #e6982e);
    color: #1a1a2e;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s, opacity 0.2s;
    flex-shrink: 0;
}
#chat-send:hover {
    transform: scale(1.1);
}
#chat-send:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ── Login Prompt ──────────────────────────────────────────── */

.chat-login-prompt {
    text-align: center;
    padding: 20px 16px;
    color: rgba(255,255,255,0.4);
    font-size: 13px;
    border-top: 1px solid rgba(255,178,64,0.1);
}

/* ── Shake animation ───────────────────────────────────────── */

.chat-shake {
    animation: chat-shake-anim 0.4s ease;
}
@keyframes chat-shake-anim {
    0%, 100% { transform: translateX(0); }
    20%      { transform: translateX(-6px); }
    40%      { transform: translateX(6px); }
    60%      { transform: translateX(-4px); }
    80%      { transform: translateX(4px); }
}

/* ── AI Support Chat ───────────────────────────────────────── */

/* Support action bar */
.chat-support-actions {
    padding: 6px 12px;
    display: flex;
    gap: 8px;
}
.chat-ticket-btn {
    background: linear-gradient(135deg, #83cfe9, #5ba8c8);
    border: none;
    border-radius: 6px;
    color: #1a1a2e;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 600;
    font-family: 'Rajdhani', sans-serif;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}
.chat-ticket-btn:hover {
    transform: scale(1.03);
    box-shadow: 0 2px 12px rgba(131,207,233,0.3);
}
.chat-ticket-btn i {
    font-size: 13px;
}

/* Support send button matches support color */
#chat-support-send {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #83cfe9, #5ba8c8);
    color: #1a1a2e;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s, opacity 0.2s;
    flex-shrink: 0;
}
#chat-support-send:hover { transform: scale(1.1); }
#chat-support-send:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* Support message styles */
.chat-support-msg {
    padding: 6px 8px;
    border-radius: 6px;
    margin: 3px 0;
}
.chat-support-assistant {
    background: rgba(131,207,233,0.08);
    border-left: 2px solid #83cfe9;
}
.chat-support-user {
    background: rgba(255,178,64,0.06);
    border-left: 2px solid rgba(255,178,64,0.3);
}
.chat-support-icon {
    font-size: 11px;
    margin-right: 4px;
}
.chat-support-assistant .chat-support-icon {
    color: #83cfe9;
}
.chat-support-user .chat-support-icon {
    color: #ffb240;
}
.chat-bot-name {
    color: #83cfe9;
    font-weight: 600;
}

/* Typing indicator animation */
.chat-typing {
    color: rgba(131,207,233,0.7);
    font-style: italic;
}
.typing-dots {
    display: inline-block;
    animation: typing-dots-anim 1.4s infinite;
}
@keyframes typing-dots-anim {
    0%   { opacity: 0.2; }
    50%  { opacity: 1; }
    100% { opacity: 0.2; }
}

/* ── Ticket Form ───────────────────────────────────────────── */

.chat-ticket-form {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #16162b;
    z-index: 10;
    display: flex;
    flex-direction: column;
    border-radius: inherit;
    overflow: hidden;
}
.chat-ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(131,207,233,0.1);
    border-bottom: 1px solid rgba(131,207,233,0.15);
    font-weight: 600;
    font-size: 14px;
    color: #83cfe9;
}
.chat-ticket-header .chat-close {
    background: none;
    border: none;
    color: #aaa;
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
}
.chat-ticket-header .chat-close:hover { color: #fff; }

.chat-ticket-body {
    flex: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
}
.chat-ticket-body select,
.chat-ticket-body input,
.chat-ticket-body textarea {
    width: 100%;
    background: #1a1a2e;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: #eee;
    padding: 10px 12px;
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.chat-ticket-body select:focus,
.chat-ticket-body input:focus,
.chat-ticket-body textarea:focus {
    border-color: #83cfe9;
    outline: none;
}
.chat-ticket-body textarea {
    resize: vertical;
    min-height: 80px;
    flex: 1;
}
.chat-ticket-body select option {
    background: #1a1a2e;
    color: #eee;
}
.chat-ticket-submit {
    background: linear-gradient(135deg, #83cfe9, #5ba8c8);
    border: none;
    border-radius: 6px;
    color: #1a1a2e;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 700;
    font-family: 'Rajdhani', sans-serif;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.chat-ticket-submit:hover {
    transform: scale(1.02);
    box-shadow: 0 2px 16px rgba(131,207,233,0.3);
}
.chat-ticket-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ── Responsive ────────────────────────────────────────────── */

@media (max-width: 480px) {
    #chat-widget {
        bottom: 16px;
        left: 16px;
    }
    .cd-top {
        bottom: 16px;
        right: 16px;
        height: 46px;
        width: 46px;
        background-size: 16px;
    }
    #chat-panel {
        width: calc(100vw - 32px);
        max-height: 70vh;
        left: 0;
    }
    #chat-toggle {
        width: 46px;
        height: 46px;
        font-size: 20px;
    }
}

/* ── Pin Button ────────────────────────────────────────────── */

.chat-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

#chat-pin {
    background: none;
    border: none;
    color: rgba(255,255,255,0.35);
    font-size: 16px;
    cursor: pointer;
    padding: 2px 6px;
    line-height: 1;
    transition: color 0.2s, transform 0.2s;
    border-radius: 4px;
}
#chat-pin:hover {
    color: #ffb240;
}
#chat-pin.chat-pin-active {
    color: #ffb240;
    transform: rotate(45deg);
}

/* Hide pin button on mobile */
@media (max-width: 1024px) {
    #chat-pin { display: none; }
}

/* ── Pinned Sidebar Mode ──────────────────────────────────── */

#chat-widget.chat-pinned {
    position: fixed;
    bottom: 0;
    left: auto;
    right: 0;
    top: 0;
    z-index: 10000;
    width: 380px;
    height: 100vh;
}
#chat-widget.chat-pinned #chat-toggle {
    display: none;
}
#chat-widget.chat-pinned #chat-panel {
    position: static;
    width: 100%;
    height: 100%;
    max-height: 100%;
    border-radius: 0;
    border: none;
    border-left: 1px solid rgba(255,178,64,0.2);
    box-shadow: -4px 0 24px rgba(0,0,0,0.4);
}
#chat-widget.chat-pinned .chat-header {
    border-radius: 0;
}
#chat-widget.chat-pinned .chat-messages {
    min-height: 0;
    max-height: none;
    flex: 1;
}

body.chat-sidebar-open {
    margin-right: 380px;
    transition: margin-right 0.3s ease;
}

/* Fixed-position elements must also respect the sidebar */
body.chat-sidebar-open #server-status {
    right: 380px;
    transition: right 0.3s ease;
}
body.chat-sidebar-open .navbar.fixed-top {
    right: 380px;
    transition: right 0.3s ease;
}
body.chat-sidebar-open .cd-top {
    right: 390px;
    transition: right 0.3s ease;
}

/* Bootstrap modals: shrink to avoid overlapping pinned chat */
body.chat-sidebar-open .modal {
    right: 380px;
    width: auto;
    left: 0;
    transition: right 0.3s ease;
}
body.chat-sidebar-open .modal-backdrop {
    width: calc(100% - 380px);
}

/* Fullscreen custom overlays must also respect sidebar */
body.chat-sidebar-open .st-transfer-modal,
body.chat-sidebar-open .rc-modal,
body.chat-sidebar-open .stats-loading {
    right: 380px;
}

/* Center shop toast within the visible area, not the full viewport */
body.chat-sidebar-open .shop-toast {
    left: calc(50% - 190px);
}


/* ============================================
   Guild Recruitment Board
   ============================================ */

/* --- Top Bar --- */
.rc-topbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-bottom: 20px;
}
.rc-search { flex: 1 1 260px; min-width: 200px; }
.rc-search .input-group-text {
    background: rgba(255,178,64,0.08);
    border: 1px solid rgba(255,255,255,0.08);
    border-right: 0;
    color: #ffb240;
}
.rc-search .form-control {
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(255,255,255,0.08);
    border-left: 0;
    color: #e0e0e0;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
}
.rc-search .form-control:focus { border-color: rgba(255,178,64,0.3); box-shadow: none; }
.rc-filters { display: flex; gap: 10px; align-items: center; }
.rc-level-input {
    width: 80px;
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(0,0,0,0.25);
    color: #e0e0e0;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}
.rc-level-input:focus { border-color: rgba(255,178,64,0.3); outline: none; }
.rc-actions { display: flex; gap: 10px; margin-left: auto; }

/* --- Info line --- */
.rc-info {
    color: rgba(255,255,255,0.4);
    font-size: 13px;
    margin-bottom: 12px;
    font-family: 'Rajdhani', sans-serif;
}
.rc-info span { color: #ffb240; font-weight: 600; }

/* --- Loading & Empty --- */
.rc-loading, .rc-empty {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255,255,255,0.35);
    font-family: 'Rajdhani', sans-serif;
}
.rc-loading p { margin-top: 12px; font-size: 14px; }
.rc-empty i { margin-bottom: 16px; color: rgba(255,178,64,0.25); }
.rc-empty h4 { color: rgba(255,255,255,0.5); font-family: 'Exo 2', sans-serif; margin-bottom: 6px; }
.rc-empty p { font-size: 14px; }

/* --- Post Cards --- */
.rc-list { display: flex; flex-direction: column; gap: 16px; }

.rc-post {
    background: linear-gradient(135deg, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.15) 100%);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    padding: 20px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.rc-post:hover {
    border-color: rgba(255,178,64,0.2);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

/* Post header: emblem + guild info */
.rc-post-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}
.rc-emblem {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    background: rgba(0,0,0,0.3);
    object-fit: contain;
    image-rendering: pixelated;
    flex-shrink: 0;
}
.rc-post-title { flex: 1; min-width: 0; }
.rc-guild-name {
    display: block;
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-size: 17px;
    font-weight: 700;
    text-decoration: none;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.rc-guild-name:hover { color: #ffc965; text-decoration: none; }

.rc-post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.45);
}
.rc-post-meta i { margin-right: 3px; }
.rc-castle { color: #ffd700; }

/* Post body */
.rc-post-body { margin-bottom: 14px; }
.rc-desc {
    color: rgba(255,255,255,0.7);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 10px;
    white-space: pre-wrap;
}
.rc-reqs {
    color: rgba(255,255,255,0.55);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    margin-bottom: 10px;
    padding: 8px 12px;
    background: rgba(79,195,247,0.06);
    border-left: 3px solid rgba(79,195,247,0.3);
    border-radius: 0 6px 6px 0;
}
.rc-reqs i { color: #4fc3f7; margin-right: 6px; }

/* Tags row */
.rc-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.rc-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    font-weight: 500;
}
.rc-tag-level {
    background: rgba(255,178,64,0.1);
    color: #ffb240;
    border: 1px solid rgba(255,178,64,0.15);
}
.rc-class-tag {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    background: rgba(79,195,247,0.08);
    color: rgba(79,195,247,0.8);
    border: 1px solid rgba(79,195,247,0.12);
}
.rc-slots {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    background: rgba(76,175,80,0.08);
    color: rgba(76,175,80,0.8);
    border: 1px solid rgba(76,175,80,0.12);
}

/* Post footer */
.rc-post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.04);
}
.rc-time {
    color: rgba(255,255,255,0.3);
    font-size: 12px;
    font-family: 'Rajdhani', sans-serif;
}
.rc-time i { margin-right: 4px; }

/* --- Buttons --- */
.btn-rc {
    padding: 8px 18px;
    border-radius: 6px;
    border: 1px solid transparent;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.btn-rc-primary {
    background: linear-gradient(135deg, #ffb240 0%, #ff9800 100%);
    color: #1a1a2e;
}
.btn-rc-primary:hover { background: linear-gradient(135deg, #ffc965 0%, #ffb240 100%); box-shadow: 0 2px 12px rgba(255,178,64,0.25); }
.btn-rc-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-rc-cancel {
    background: transparent;
    color: rgba(255,255,255,0.5);
    border-color: rgba(255,255,255,0.1);
}
.btn-rc-cancel:hover { color: #e0e0e0; border-color: rgba(255,255,255,0.2); }
.btn-rc-danger {
    background: rgba(244,67,54,0.1);
    color: #f44336;
    border-color: rgba(244,67,54,0.2);
}
.btn-rc-danger:hover { background: rgba(244,67,54,0.2); border-color: rgba(244,67,54,0.3); }
.btn-rc-success {
    background: rgba(76,175,80,0.1);
    color: #4caf50;
    border-color: rgba(76,175,80,0.2);
}
.btn-rc-success:hover { background: rgba(76,175,80,0.2); border-color: rgba(76,175,80,0.3); }

/* --- Apply Modal --- */
.rc-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1050;
    padding: 20px;
}
.rc-modal-inner {
    background: linear-gradient(135deg, #1a2240 0%, #16213e 100%);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 28px;
    width: 100%;
    max-width: 460px;
    box-shadow: 0 16px 48px rgba(0,0,0,0.5);
}
.rc-modal-inner h5 {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 16px;
    margin: 0 0 18px;
}
.rc-modal-inner label {
    color: rgba(255,255,255,0.6);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}
.rc-select, .rc-textarea {
    background: rgba(0,0,0,0.3) !important;
    border: 1px solid rgba(255,255,255,0.08) !important;
    color: #e0e0e0 !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-size: 14px !important;
}
.rc-select:focus, .rc-textarea:focus {
    border-color: rgba(255,178,64,0.3) !important;
    box-shadow: none !important;
}
.rc-textarea { resize: vertical; min-height: 60px; }
.rc-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

/* Status messages */
.rc-msg-success {
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    background: rgba(76,175,80,0.1);
    border: 1px solid rgba(76,175,80,0.2);
    color: #4caf50;
    margin-top: 10px;
}
.rc-msg-error {
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    background: rgba(244,67,54,0.1);
    border: 1px solid rgba(244,67,54,0.2);
    color: #f44336;
    margin-top: 10px;
}

/* --- Section Titles --- */
.rc-section-title {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 700;
    font-size: 16px;
    margin: 20px 0 14px;
}
.rc-section-title i { margin-right: 8px; }

/* --- Application Cards --- */
.rc-apps-list { display: flex; flex-direction: column; gap: 12px; }

.rc-app-card {
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 14px 16px;
    transition: border-color 0.2s;
}
.rc-app-card.rc-status-pending { border-left: 3px solid #ffb240; }
.rc-app-card.rc-status-accepted { border-left: 3px solid #4caf50; }
.rc-app-card.rc-status-rejected { border-left: 3px solid #f44336; }
.rc-app-card.rc-status-withdrawn { border-left: 3px solid rgba(255,255,255,0.15); }

.rc-app-main {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    flex-wrap: wrap;
}
.rc-app-info { display: flex; flex-direction: column; gap: 2px; }
.rc-app-guild {
    color: #ffb240;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 14px;
}
.rc-app-char, .rc-app-char-detail {
    color: rgba(255,255,255,0.5);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
}
.rc-app-char-name {
    color: #e0e0e0;
    font-family: 'Exo 2', sans-serif;
    font-weight: 600;
    font-size: 14px;
}

.rc-app-status-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}
.rc-status-badge {
    padding: 2px 10px;
    border-radius: 10px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.rc-status-badge.rc-status-pending { background: rgba(255,178,64,0.15); color: #ffb240; }
.rc-status-badge.rc-status-accepted { background: rgba(76,175,80,0.15); color: #4caf50; }
.rc-status-badge.rc-status-rejected { background: rgba(244,67,54,0.15); color: #f44336; }
.rc-status-badge.rc-status-withdrawn { background: rgba(255,255,255,0.06); color: rgba(255,255,255,0.3); }

.rc-app-time {
    color: rgba(255,255,255,0.25);
    font-size: 11px;
    font-family: 'Rajdhani', sans-serif;
}
.rc-app-message {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    font-family: 'Rajdhani', sans-serif;
    margin-top: 8px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.15);
    border-radius: 6px;
    line-height: 1.5;
}
.rc-app-note {
    color: rgba(255,255,255,0.4);
    font-size: 12px;
    font-family: 'Rajdhani', sans-serif;
    margin-top: 6px;
    font-style: italic;
}
.rc-app-note i { color: rgba(79,195,247,0.4); margin-right: 4px; }
.rc-app-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    justify-content: flex-end;
}

/* --- Manage Post Card --- */
#rc-manage-form-card {
    margin-bottom: 20px;
}

/* --- Mobile --- */
@media (max-width: 768px) {
    .rc-topbar { flex-direction: column; }
    .rc-search { width: 100%; }
    .rc-filters { width: 100%; }
    .rc-actions { width: 100%; }
    .rc-actions .wm-btn { flex: 1; text-align: center; }
    
    .rc-post { padding: 16px; }
    .rc-post-header { gap: 10px; }
    .rc-emblem { width: 36px; height: 36px; }
    .rc-guild-name { font-size: 15px; }
    .rc-post-meta { font-size: 12px; gap: 8px; }
    .rc-post-footer { flex-direction: column; gap: 10px; align-items: stretch; }
    .rc-post-footer .btn-rc { justify-content: center; }
    
    .rc-modal-inner { padding: 20px; max-width: 100%; }
    .rc-modal-actions { flex-direction: column-reverse; }
    .rc-modal-actions .btn-rc { width: 100%; justify-content: center; }
    
    .rc-app-main { flex-direction: column; }
    .rc-app-status-wrap { flex-direction: row; align-items: center; gap: 8px; }
}

/* ═══════════════════════════════════════════════════════════════
   FORUM
   ═══════════════════════════════════════════════════════════════ */

/* Breadcrumb */
.fm-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}
.fm-bc-link {
    color: rgba(212,175,55,0.7);
    text-decoration: none;
    transition: color 0.2s;
}
.fm-bc-link:hover { color: #d4af37; text-decoration: none; }
.fm-bc-sep { color: rgba(255,255,255,0.2); font-size: 10px; }
.fm-bc-current { color: rgba(255,255,255,0.6); }

/* Loading */
.fm-loading {
    text-align: center;
    padding: 60px 0;
    color: rgba(255,255,255,0.3);
    font-family: 'Rajdhani', sans-serif;
}
.fm-loading i { margin-bottom: 12px; }

/* Empty state */
.fm-empty {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255,255,255,0.3);
    font-family: 'Rajdhani', sans-serif;
}
.fm-empty i { margin-bottom: 16px; opacity: 0.3; }
.fm-empty h4 { color: rgba(255,255,255,0.5); font-family: 'Exo 2', sans-serif; }

/* ── Category Cards ── */
.fm-cat-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.fm-cat-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
}
.fm-cat-card:hover {
    background: rgba(212,175,55,0.06);
    border-color: rgba(212,175,55,0.2);
    transform: translateX(4px);
}
.fm-cat-icon {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: rgba(212,175,55,0.1);
    color: #d4af37;
    font-size: 18px;
}
.fm-cat-info { flex: 1; min-width: 0; }
.fm-cat-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    margin-bottom: 2px;
}
.fm-cat-desc-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.4);
}
.fm-cat-stats {
    display: flex;
    gap: 24px;
    flex-shrink: 0;
}
.fm-cat-stat { text-align: center; }
.fm-cat-stat-val {
    display: block;
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #d4af37;
    line-height: 1.2;
}
.fm-cat-stat-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: rgba(255,255,255,0.3);
}
.fm-cat-latest {
    flex-basis: 100%;
    padding-top: 8px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,0.3);
    border-top: 1px solid rgba(255,255,255,0.04);
    margin-top: 4px;
    display: none;
}
.fm-cat-latest-label { color: rgba(255,255,255,0.25); }
.fm-cat-latest-title { color: rgba(255,255,255,0.6); margin-right: 4px; }
.fm-cat-latest-meta { color: rgba(255,255,255,0.25); }

/* ── Thread List ── */
.fm-thread-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    gap: 16px;
}
.fm-thread-info h3 {
    font-family: 'Exo 2', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #d4af37;
    margin: 0 0 4px 0;
}
.fm-cat-desc {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,0.4);
    margin: 0;
}
.fm-thread-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.fm-thread-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
}
.fm-thread-row:hover {
    background: rgba(212,175,55,0.06);
    border-color: rgba(212,175,55,0.15);
}
.fm-thread-row.fm-pinned {
    background: rgba(212,175,55,0.04);
    border-color: rgba(212,175,55,0.15);
}
.fm-thread-main { flex: 1; min-width: 0; }
.fm-thread-title-text {
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.fm-pin-icon { color: #d4af37; font-size: 12px; }
.fm-lock-icon { color: rgba(255,255,255,0.3); font-size: 12px; }
.fm-thread-sub {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,0.35);
    margin-top: 2px;
}
.fm-thread-counts {
    display: flex;
    gap: 16px;
    flex-shrink: 0;
}
.fm-thread-count {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.4);
}
.fm-thread-count i { margin-right: 4px; font-size: 11px; }
.fm-thread-last {
    text-align: right;
    flex-shrink: 0;
    min-width: 100px;
}
.fm-thread-last-by {
    display: block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    font-weight: 600;
}
.fm-thread-last-time {
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    color: rgba(255,255,255,0.25);
}

/* ── Thread Detail ── */
.fm-thread-title-bar {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.fm-thread-title-bar h3 {
    font-family: 'Exo 2', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: rgba(255,255,255,0.95);
    margin: 0 0 6px 0;
}
.fm-thread-meta {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.35);
}
.fm-thread-meta strong { color: rgba(255,255,255,0.6); }
.fm-thread-admin-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}
.wm-btn-sm {
    font-size: 12px !important;
    padding: 4px 12px !important;
}

/* Badges */
.fm-badge {
    display: inline-block;
    font-family: 'Rajdhani', sans-serif;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
    vertical-align: middle;
    margin-left: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.fm-badge-op { background: rgba(212,175,55,0.2); color: #d4af37; }
.fm-badge-pinned { background: rgba(212,175,55,0.15); color: #d4af37; }
.fm-badge-locked { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.4); }
.fm-badge-private { background: rgba(100,180,255,0.12); color: rgba(130,190,255,0.8); font-size: 10px; }

/* ── Guild Forum Sections ── */
#fm-guild-sections {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.fm-guild-heading {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: rgba(255,255,255,0.85);
    margin: 0 0 2px 0;
}
.fm-guild-heading i { color: #6eb5ff; margin-right: 6px; }
.fm-guild-subtext {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    color: rgba(255,255,255,0.35);
    margin: 0 0 8px 0;
}
.fm-guild-card {
    border-color: rgba(100,180,255,0.12);
}
.fm-guild-card:hover {
    background: rgba(100,180,255,0.06);
    border-color: rgba(100,180,255,0.25);
}
.fm-guild-emblem {
    background: rgba(100,180,255,0.08);
    color: #6eb5ff;
    overflow: hidden;
}
.fm-guild-emblem img {
    width: 32px;
    height: 32px;
    image-rendering: pixelated;
}

/* ── Latest Activity ── */
#fm-recent-activity {
    margin-bottom: 32px;
}
.fm-section-heading {
    font-family: 'Exo 2', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: rgba(255,255,255,0.85);
    margin: 0 0 12px 0;
}
.fm-section-heading i { color: #d4af37; margin-right: 6px; }
.fm-recent-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.fm-recent-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255,255,255,0.025);
    border: 1px solid rgba(255,255,255,0.04);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s;
}
.fm-recent-item:hover {
    background: rgba(212,175,55,0.05);
    border-color: rgba(212,175,55,0.15);
}
.fm-recent-icon {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: rgba(212,175,55,0.08);
    color: rgba(212,175,55,0.7);
    font-size: 12px;
    margin-top: 1px;
}
.fm-recent-body { flex: 1; min-width: 0; font-family: 'Rajdhani', sans-serif; font-size: 14px; line-height: 1.4; }
.fm-recent-author { color: rgba(255,255,255,0.8); font-weight: 600; }
.fm-recent-action { color: rgba(255,255,255,0.35); }
.fm-recent-thread { color: rgba(255,255,255,0.7); }
.fm-recent-meta {
    display: flex;
    gap: 12px;
    margin-top: 2px;
    font-size: 12px;
    color: rgba(255,255,255,0.25);
}
.fm-recent-cat i { margin-right: 3px; font-size: 10px; }
@media (max-width: 576px) {
    .fm-recent-item { padding: 8px 10px; gap: 8px; }
    .fm-recent-icon { width: 24px; height: 24px; font-size: 10px; }
}

/* ── Posts ── */
.fm-post-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}
.fm-post {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 10px;
}
.fm-post-op {
    border-color: rgba(212,175,55,0.15);
    background: rgba(212,175,55,0.03);
}
.fm-post-sidebar {
    flex-shrink: 0;
    width: 80px;
    text-align: center;
}
.fm-post-avatar {
    font-size: 32px;
    color: rgba(255,255,255,0.15);
    margin-bottom: 4px;
}
.fm-post-author {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    word-break: break-all;
}
.fm-post-main { flex: 1; min-width: 0; }
.fm-post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.fm-post-time {
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    color: rgba(255,255,255,0.3);
}
.fm-edited {
    color: rgba(255,255,255,0.2);
    font-style: italic;
    margin-left: 4px;
}
.fm-post-actions { display: flex; gap: 4px; }
.fm-act-btn {
    background: none;
    border: none;
    color: rgba(255,255,255,0.25);
    font-size: 13px;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 4px;
    transition: all 0.15s;
}
.fm-act-btn:hover { color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.06); }
.fm-btn-delete:hover { color: #e53935 !important; }
.fm-post-body {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    color: rgba(255,255,255,0.8);
    line-height: 1.6;
    word-break: break-word;
}
.fm-post-footer { margin-top: 12px; }
.fm-vote-btn {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.4);
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}
.fm-vote-btn:hover:not([disabled]) {
    border-color: rgba(76,175,80,0.4);
    color: #4caf50;
    background: rgba(76,175,80,0.08);
}
.fm-vote-btn.fm-voted {
    border-color: rgba(76,175,80,0.4);
    color: #4caf50;
    background: rgba(76,175,80,0.1);
}
.fm-vote-btn[disabled] { opacity: 0.3; cursor: not-allowed; }
.fm-vote-btn i { margin-right: 4px; }

/* Reply box */
.fm-reply-box {
    margin-top: 20px;
    padding: 20px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 10px;
}
.fm-reply-box h5 {
    font-family: 'Exo 2', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: #d4af37;
    margin-bottom: 12px;
}
.fm-textarea {
    width: 100%;
    background: rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    padding: 12px 14px;
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    resize: vertical;
    min-height: 80px;
    outline: none;
    transition: border-color 0.2s;
}
.fm-textarea:focus { border-color: rgba(212,175,55,0.4); }
.fm-textarea::placeholder { color: rgba(255,255,255,0.25); }
.fm-reply-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
}
.fm-locked-notice {
    text-align: center;
    padding: 20px;
    color: rgba(255,255,255,0.3);
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
}
.fm-locked-notice i { margin-right: 6px; }

/* Form elements */
.fm-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}
.fm-input {
    background: rgba(0,0,0,0.3) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
    color: #fff !important;
    font-family: 'Rajdhani', sans-serif !important;
    font-size: 14px !important;
}
.fm-input:focus { border-color: rgba(212,175,55,0.4) !important; }
.fm-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
}

/* Pagination */
.fm-pagination {
    margin-top: 16px;
}

/* ── Forum Mobile ── */
@media (max-width: 768px) {
    .fm-cat-card {
        flex-wrap: wrap;
        padding: 14px;
        gap: 10px;
    }
    .fm-cat-stats {
        gap: 16px;
        margin-left: auto;
    }
    .fm-cat-latest { display: none; }
    .fm-thread-header {
        flex-direction: column;
        gap: 10px;
    }
    .fm-thread-row {
        flex-wrap: wrap;
        gap: 8px;
        padding: 12px;
    }
    .fm-thread-last { display: none; }
    .fm-thread-counts { gap: 12px; }
    .fm-post {
        flex-direction: column;
        gap: 8px;
        padding: 14px;
    }
    .fm-post-sidebar {
        width: auto;
        display: flex;
        align-items: center;
        gap: 8px;
        text-align: left;
    }
    .fm-post-avatar { font-size: 20px; margin-bottom: 0; }
    .fm-reply-actions { flex-direction: column; gap: 8px; align-items: stretch; }
    .fm-reply-actions .wm-btn { text-align: center; }
    .fm-modal-actions { flex-direction: column-reverse; }
    .fm-modal-actions .wm-btn { width: 100%; justify-content: center; text-align: center; }
}