/* ============================================
   BladeMasters - Arabic RTL CSS
   ============================================ */

/* Base RTL Direction */
body {
    direction: rtl;
    text-align: right;
}

/* ============================================
   Header Bar (Navbar)
   ============================================ */
.header-right {
    right: auto;
    left: 20px;
}

.lang-btn {
    flex-direction: row;
    direction: ltr;
}

.lang-btn .lang-text {
    order: 2;
}

.lang-btn .lang-flag {
    order: 3;
}

.lang-btn .arrow {
    order: 1;
    margin-right: 5px;
    margin-left: 0;
}

/* ============================================
   Navigation
   ============================================ */
.nav-links {
    flex-direction: row;
}

/* ============================================
   Stats Bar
   ============================================ */
.stats-bar {
    position: relative;
    background: none;
}

.stats-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/psd/bg-online.png') center/100% 100% no-repeat;
    transform: scaleX(-1);
    z-index: -1;
}

.stat-item:not(.download) {
    flex-direction: row;
}

.stat-item.download {
    flex-direction: row-reverse;
}

.stat-info {
    text-align: center;
}

.stat-item:not(.download):not(:last-child)::after {
    right: auto;
    left: -80px;
    transform: translateY(-50%) scaleX(-1);
}

.stat-item.download {
    left: auto;
    right: -10px;
    padding-left: 50px;
    padding-right: 50px;
    background: url('../images/psd/bg-daownload.png') center/contain no-repeat;
    transform: translateY(-50%) scaleX(-1);
    -webkit-mask-position: right center;
    mask-position: right center;
    justify-content: center;
}

.stat-item.download .stat-icon,
.stat-item.download .stat-info {
    transform: scaleX(-1);
}

.stat-item.online-now {
    left: 50%;
    transform: translateX(-50%);
}

.stat-item.online-24h {
    right: auto;
    left: 80px;
}

/* ============================================
   User Panel
   ============================================ */
.panel-title {
    left: auto;
    right: 20px;
}

.input-group {
    flex-direction: row;
}

.input-group .separator {
    margin: 0 10px;
}

.input-group input {
    text-align: right;
    direction: rtl;
}

.checkbox-row {
    flex-direction: row;
}

.login-actions {
    flex-direction: row;
}

/* ============================================
   News Section
   ============================================ */
.news-header {
    flex-direction: row;
}

.news-tabs {
    flex-direction: row;
}

.slider-arrow.left {
    left: auto;
    right: 10px;
    transform: translateY(-50%) scaleX(-1);
}

.slider-arrow.right {
    right: auto;
    left: 10px;
    transform: translateY(-50%) scaleX(-1);
}

.slider-dots {
    right: auto;
    left: 15px;
}

.news-text {
    text-align: right;
}

/* ============================================
   Rankings Cards
   ============================================ */
.bottom-row {
    flex-direction: row-reverse;
}

.rankings-title-row {
    flex-direction: row;
}

.more-link {
    flex-direction: row;
}

.rankings-table-header {
    direction: rtl;
}

.rankings-row {
    direction: rtl;
}

.player-cell {
    flex-direction: row;
}

/* عكس خلفيات الصفوف للعربية */
.bottom-row > .rankings-card:first-child .rankings-row:nth-child(even) {
    background: url('../images/psd/Rechtech-1.png') center/100% 100% no-repeat;
}

.bottom-row > .rankings-card:first-child .rankings-row:nth-child(even)::before {
    display: none;
}

.bottom-row > .rankings-card:last-child .rankings-row:nth-child(even) {
    background: none;
}

.bottom-row > .rankings-card:last-child .rankings-row:nth-child(even)::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/psd/Rechtech-1.png') center/100% 100% no-repeat;
    transform: scaleX(-1);
    z-index: 0;
}

.bottom-row > .rankings-card:last-child .rankings-row > * {
    position: relative;
    z-index: 1;
}

/* ============================================
   Trailer Card
   ============================================ */
.trailer-header {
    flex-direction: row;
}

.trailer-header-content {
    text-align: right;
}

.trailer-nav {
    flex-direction: row;
}

.trailer-nav-btn img {
    transform: scaleX(-1);
}

.play-btn img {
    margin-left: 0;
    margin-right: 3px;
}

/* ============================================
   Top Row
   ============================================ */
.top-row {
    flex-direction: row;
}

/* ============================================
   Footer
   ============================================ */
.footer p {
    text-align: center;
}

/* ============================================
   Forms & Inputs (Global)
   ============================================ */
input,
textarea,
select {
    text-align: right;
}

/* ============================================
   Buttons
   ============================================ */
.btn-signin,
.btn-load-more,
.register-btn {
    text-align: center;
}

/* ============================================
   Responsive RTL Fixes
   ============================================ */
@media (max-width: 992px) {
    .top-row,
    .bottom-row {
        flex-direction: column;
    }
    
    .header-right {
        left: auto;
        right: 20px;
    }
}
