.match-standings{

    margin:0;
     padding:0px;

}

.match-standings-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    overflow: hidden;
}

@media (max-width: 768px) {
    .competition-overview-standings-card {
        overflow: visible;
    }

    .competition-overview-standings-card .match-standings {
        width: 100%;
        max-width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
    }

    .competition-overview-standings-card .lwf-standings-table {
        width: max-content;
        min-width: 100%;
    }
}

.match-standings-card-header{

    display:flex;

    justify-content:flex-end;

    align-items:center;

    padding:5px 10px 5px 6px;

    border-bottom:1px solid #edf2f7;
}
.match-competition{

    margin-left:auto;

    display:flex;
    flex-direction:row-reverse;

    align-items:center;

    gap:10px;

    background:transparent;
    color:#111827;

    font-size:17px;
    font-weight:500;

    margin-right:-10px;

    transform:translateY(-5px);

}

.match-competition img{

     order:1;
    width:35px;
    height:35px;
    object-fit:contain;
    margin-left:auto;

}

.lwf-standings-table{

    width:100%;

    margin:0;

    border-collapse:collapse;

}

.lwf-standings-table tbody tr{

    transition:.2s;

}

.lwf-standings-table tbody tr:hover{

    background:#f9fafb;

}

.lwf-standings-table th{

    padding:12px;
    background:#fff;

}

.lwf-standings-table thead th{

    background:#fff;
    color:#374151;
    font-size:13px;
    font-weight:700;
    border-bottom:1px solid #e5e7eb;

}

.lwf-standings-table td{

padding:10px;
text-align:center;
border-bottom:1px solid #eee;

}

.lwf-team-cell{

display:flex;
align-items:center;
font-size:13px;
 font-weight: 600;
gap:10px;

}

.lwf-team-logo{

width:28px;
height:28px;
object-fit:contain;

}

.lwf-next-team{

width:26px;
height:26px;
object-fit:contain;
  display:block;
    margin:0 auto;

}

.current-team{

    background:#f3f4f6;

    font-weight:500;

}

.lwf-deduction{

    color:#dc2626;
    font-weight:700;

}

.lwf-points{

    font-weight:700;
    color:#111827;
    font-size:15px;

}

.lwf-standings-table td:last-child,
.lwf-standings-table th:last-child{

    text-align:center;

}

.lwf-standings-table tbody tr:last-child td{

    border-bottom:none;

}

.lwf-tie-break-info{

    margin-top:20px;

    padding:18px;

    border:1px solid #dcdcde;

    border-radius:16px;

    background:#f8fafc;

}

.lwf-tie-break-info h4{

    margin:0 0 10px;

}

.lwf-tie-break-info p{

    margin-bottom:12px;

    color:#555;

}

.lwf-competition-info{

    display:flex;
    flex-direction:column;
    gap:16px;
    margin-top:20px;

}

.lwf-info-card{

    background:#fff;

    border:1px solid #e5e7eb;

    border-radius:16px;

    padding:22px 24px;

}

.lwf-info-card h4{

    margin:0 0 16px;

    font-size:18px;

    font-weight:700;

    display:flex;

    align-items:center;

    gap:8px;

    color:#111827;

}

.lwf-info-card p{

    margin:0 0 16px;

    line-height:2;

    color:#6b7280;

    font-size:14px;

}

.lwf-rules-list{

    display:flex;
    flex-direction:column;
    gap:10px;

    margin-top:18px;

}

.lwf-rule-row{

    display:flex;
    align-items:center;

    gap:14px;

    padding:14px 18px;

    border:1px solid #edf2f7;

    border-radius:12px;

    background:#fafafa;

    transition:.2s;

}

.lwf-rule-row:hover{

    background:#f3f4f6;

}

.lwf-rule-number{

    width:32px;
    height:32px;

    border-radius:50%;

    background:#2563eb;

    color:#fff;

    display:flex;
    align-items:center;
    justify-content:center;

    font-weight:700;

    flex-shrink:0;

}

.lwf-rule-name{

    font-size:15px;

    font-weight:500;

    color:#111827;

}


/* =========================================
   ألوان حالات الترتيب - الخط الأيمن
========================================= */

.lwf-standings-table tbody tr.champion-row {
    box-shadow: inset -4px 0 0 #f59e0b;
}

.lwf-standings-table tbody tr.promotion-row {
    box-shadow: inset -4px 0 0 #16a34a;
}

.lwf-standings-table tbody tr.relegation-row {
    box-shadow: inset -4px 0 0 #ef4444;
}

.lwf-standings-table tbody tr.withdrawn-row {
    box-shadow: inset -4px 0 0 #9ca3af;
}

.lwf-standings-table tbody tr.excluded-row {
    box-shadow: inset -4px 0 0 #f97316;
}

.lwf-standings-legend{

   display:flex;

    align-items:center;

    gap:24px;

    padding:14px 22px;

}

.legend-item{

    display:flex;

    align-items:center;

    gap:8px;

    font-size:13px;

    font-weight: 400;

    color:#4b5563;

}

.legend-color{

    width:4px;

    height:18px;

    border-radius:0px;

    display:block;

    flex-shrink:0;

}

.legend-color.champion{
    background:#f59e0b;
}

.legend-color.promotion {
    background: #16a34a;
}

.legend-color.relegation {
    background: #ef4444;
}

.legend-color.withdrawn {
    background:#9ca3af;
}

.legend-color.excluded {
    background:#f97316;
}

.lwf-standings-filter{

    display:inline-flex;

    flex-direction:row;

    justify-content:flex-start;

    gap:8px;

    padding:6px 8px 8px 4px;

    border-bottom:1px solid #edf2f7;

}

.lwf-standings-filter button{

    background:#f8fafc;

    border:1px solid #dbe3eb;

    color:#374151;

    padding:6px 14px;

    border-radius:14px;

    cursor:pointer;

    transition:.2s;

    font-size:13px;

     font-weight: 600;

}

.lwf-standings-filter button.active{

    background:#16a34a;

    color:#fff;

    border-color:#16a34a;

}

/* ===================================
   Match Standings Mobile
=================================== */

@media (max-width:768px){

.match-standings{

    overflow-x:auto;

}

.lwf-standings-table{

    width:auto;
    min-width:100%;
    border-collapse:collapse;

}

/* جميع الخلايا */

.lwf-standings-table th,
.lwf-standings-table td{

    padding:8px 6px;
    font-size:12px;
    white-space:nowrap;
    text-align:center;

}

/* رقم الترتيب */

.lwf-standings-table th:first-child,
.lwf-standings-table td:first-child{

    width:32px;
    min-width:32px;

}

/* الفريق */

/* خانة الفريق في الهاتف */
.lwf-standings-table th:nth-child(2),
.lwf-standings-table td:nth-child(2){
    text-align:right;
    padding-right:0px;
    padding-left:6px;
    width:100px;
    min-width:100px;
    max-width:100px;
}

/* بقية الأعمدة */

.lwf-standings-table th:not(:first-child):not(:nth-child(2)),
.lwf-standings-table td:not(:first-child):not(:nth-child(2)){

    width:34px;
    min-width:34px;

}

/* الفريق */

.lwf-team-cell{
    width:100%;
    max-width:100%;
    display:flex;
    align-items:center;
    justify-content:flex-start;
    gap:6px;
    box-sizing:border-box;
    white-space:nowrap;
}

/* تثبيت مكان الشعار */
.lwf-team-logo{
    width:20px;
    height:20px;
    object-fit:contain;
    flex:0 0 20px;
}

/* اسم الفريق */
.lwf-team-cell{
    overflow:hidden;

}

.lwf-team-cell img{
    flex:0 0 20px;
}

.lwf-team-cell{
    direction:rtl;
}

/* الفرنسية — ترتيب الفريق من اليسار إلى اليمين */
.competition-overview-standings-card--fr .lwf-team-cell{
    direction:ltr;
    justify-content:flex-start;
    text-align:left;
}

.lwf-team-cell {
    font-size: 12px;
    font-weight:500;
}

/* إظهار جميع أعمدة الترتيب على الهاتف */
.lwf-standings-table th,
.lwf-standings-table td {
    display: table-cell;
}

/* السماح بالتمرير الأفقي داخل الجدول */
.match-standings {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.lwf-standings-table {
    width: max-content;
    min-width: 100%;
}

}

/* =========================================================
   ترتيب المباراة - تنسيق رأس البطاقة
========================================================= */

.match-standings-card-header {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;

    padding: 0;

 

    border-bottom: 1px solid #edf2f7;
}


/* =========================================================
   أزرار الكل / داخل الأرض / خارج الأرض
========================================================= */

.lwf-standings-filter {
    display: flex;

    width: 100%;
    box-sizing: border-box;

    justify-content: flex-start;
    align-items: center;

    gap: 10px;

    padding: 18px 20px 18px 18px;

    border: 0;
}


/* =========================================================
   اسم المنافسة
========================================================= */

.match-competition {
    width: 100%;
    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: flex-end;
direction: rtl;

    flex-direction: row-reverse;

    gap: 10px;

    margin: 0;

    padding: 18px 18px;

    border-top: 1px solid #edf2f7;

    background: transparent;

    color: #111827;

    font-size: 17px;
    font-weight: 600;

    transform: none;
}


/* الشعار */
.match-competition img {
    order: 1;

    width: 35px;
    height: 35px;

    object-fit: contain;

    margin-left: 0;
}

/* =========================================================
   LWFG — ترتيب المنافسة
   اختيار المجموعة
   ========================================================= */

.competition-overview-group-selector {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    /* دفع اختيار المجموعة إلى اليسار */
    margin-inline-start: auto;

    padding: 0;
    flex-shrink: 0;
}

.competition-overview-group-selector label {
    margin: 0;
    color: #374151;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
}

.competition-overview-group-selector select {
    height: 35px;
    min-width: 120px;

    padding: 0 14px;

    border: 1px solid #e5e7eb;
    border-radius: 10px;

    background-color: #ffffff;

    appearance: none;
    -webkit-appearance: none;

    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23111111' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 14px center;
    background-size: 12px 12px;

    color: #111827;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;

    cursor: pointer;
    outline: none;
    box-sizing: border-box;
}

.competition-overview-group-selector select:focus {
    border-color: #16a34a;
    box-shadow: 0 0 0 2px rgba(22, 163, 74, .10);
}


/* =========================================================
   معلومات المنافسة أسفل الترتيب
   نفس تنسيق ترتيب صفحة المباراة
   ========================================================= */

.competition-overview-standings-card + .lwf-competition-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-info-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 22px 24px;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-info-card h4 {
    margin: 0 0 16px;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #111827;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-info-card p {
    margin: 0 0 16px;
    line-height: 2;
    color: #6b7280;
    font-size: 14px;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-rules-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 18px;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-rule-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    border: 1px solid #edf2f7;
    border-radius: 12px;
    background: #fafafa;
    transition: .2s;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-rule-row:hover {
    background: #f3f4f6;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-rule-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #2563eb;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.competition-overview-standings-card + .lwf-competition-info .lwf-rule-name {
    font-size: 15px;
    font-weight: 500;
    color: #111827;
}


/* =========================================================
   Mobile — اختيار المجموعة
   ========================================================= */

@media (max-width: 768px) {

    .lwf-standings-filter {
        flex-wrap: wrap;
    }

    .competition-overview-group-selector {
        width: 100%;
        justify-content: flex-start;
        margin-top: 2px;
    }

    .competition-overview-group-selector select {
        min-width: 130px;
    }

    .competition-overview-standings-card
    + .lwf-competition-info
    .lwf-info-card {
        padding: 18px;
    }

}


/* =========================================================
   FINAL MOBILE — ترتيب المنافسة + القواعد
   نفس الهوامش الخارجية لبطاقة الجولات
   ========================================================= */
@media (max-width: 768px) {

.competition-overview-standings-card {
    width: auto;
    max-width: none;
    margin: 0 12px;
    box-sizing: border-box;
    overflow: hidden;
}

    .competition-overview-standings-card .match-standings-card-header {
        width: 100%;
        box-sizing: border-box;
    }

    .competition-overview-standings-card .lwf-standings-filter {
        width: 100%;
        box-sizing: border-box;
    }

    /* select المجموعة يبقى في الجهة اليسرى */
    .competition-overview-standings-card .competition-overview-group-selector {
        width: auto;
        margin-inline-start: 0;
        margin-inline-end: auto;
        justify-content: flex-start;
        flex: 0 0 auto;
    }

    .competition-overview-standings-card .competition-overview-group-selector select {
        min-width: 130px;
    }

    /* القواعد / معلومات المنافسة — نفس الهامش الخارجي لبطاقة الترتيب والجولات */
    .competition-overview-standings-card + .lwf-competition-info,
    .lwf-competition-info {
        width: calc(100% - 24px);
        max-width: calc(100% - 24px);
        margin-inline: 12px;
        box-sizing: border-box;
        margin-top: 12px;
    }

    .competition-overview-standings-card + .lwf-competition-info .lwf-info-card,
    .lwf-competition-info .lwf-info-card {
        width: 100%;
        box-sizing: border-box;
        padding: 18px;
    }

    .competition-overview-standings-card + .lwf-competition-info .lwf-rules-list,
    .lwf-competition-info .lwf-rules-list {
        width: 100%;
        box-sizing: border-box;
    }

    .competition-overview-standings-card + .lwf-competition-info .lwf-rule-row,
    .lwf-competition-info .lwf-rule-row {
        width: 100%;
        box-sizing: border-box;
    }
}

.match-competition__link {
    color: inherit;
    text-decoration: none;
      font-size: 15px;
}

.match-competition__link:hover {
    text-decoration: underline;
}

/* =========================================================
   LWFG — Loading effect
   ========================================================= */

.competition-overview-standings-card {
    position: relative;
}

.competition-overview-standings-card.is-loading::after {
    content: "";
    position: absolute;
    inset: 0;
    background: #fff;
    opacity: .65;
    pointer-events: none;
    z-index: 20;
    animation: competitionStandingsLoading .45s ease-in-out infinite alternate;
}

@keyframes competitionStandingsLoading {
    from {
        opacity: .45;
    }

    to {
        opacity: .75;
    }
}

/* =========================================================
   LWFG — Competition Knockout Stats
   ========================================================= */

.lwf-competition-stats-card {
    width: 100%;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
    box-sizing: border-box;
}


/* ---------------------------------------------------------
   Header
   --------------------------------------------------------- */

.lwf-competition-stats-header {
    min-height: 68px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    box-sizing: border-box;
    border-bottom: 1px solid #edf0f2;
}

.lwf-competition-stats-header h3 {
    margin: 0;
    color: #111827;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
}


/* ---------------------------------------------------------
   Grid
   --------------------------------------------------------- */

.lwf-competition-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    background: #edf0f2;
}


/* ---------------------------------------------------------
   Stat
   --------------------------------------------------------- */

.lwf-competition-stat {
    min-height: 105px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #fff;
    box-sizing: border-box;
    text-align: center;
}

.lwf-competition-stat__label {
    color: #687386;
    font-size: 13px;
    font-weight: 600;
}

.lwf-competition-stat__value {
    color: #111827;
    font-size: 24px;
    font-weight: 800;
    line-height: 1;
}


/* ---------------------------------------------------------
   آخر عنصر — مجموع الأهداف
   --------------------------------------------------------- */

.lwf-competition-stat--wide {
    grid-column: 1 / -1;
}


/* ---------------------------------------------------------
   Mobile
   --------------------------------------------------------- */

@media (max-width: 768px) {

    .lwf-competition-stats-card {
        border-radius: 13px;
    }

    .lwf-competition-stats-header {
        min-height: auto;
        padding: 14px;
    }

    .lwf-competition-stats-header h3 {
        font-size: 16px;
    }

    .lwf-competition-stat {
        min-height: 90px;
        padding: 16px 10px;
    }

    .lwf-competition-stat__label {
        font-size: 12px;
    }

    .lwf-competition-stat__value {
        font-size: 21px;
    }

}


/* ---------------------------------------------------------
   Small Mobile
   --------------------------------------------------------- */

@media (max-width: 480px) {

    .lwf-competition-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .lwf-competition-stat {
        min-height: 82px;
        padding: 14px 8px;
    }

    .lwf-competition-stat__value {
        font-size: 20px;
    }

}

/* =========================================================
   الفرنسية — حالات الترتيب
========================================================= */

.competition-overview-standings-card--fr
.lwf-standings-table tbody tr.champion-row {
    box-shadow: inset 4px 0 0 #f59e0b;
}

.competition-overview-standings-card--fr
.lwf-standings-table tbody tr.promotion-row {
    box-shadow: inset 4px 0 0 #16a34a;
}

.competition-overview-standings-card--fr
.lwf-standings-table tbody tr.relegation-row {
    box-shadow: inset 4px 0 0 #ef4444;
}

.competition-overview-standings-card--fr
.lwf-standings-table tbody tr.withdrawn-row {
    box-shadow: inset 4px 0 0 #9ca3af;
}

.competition-overview-standings-card--fr
.lwf-standings-table tbody tr.excluded-row {
    box-shadow: inset 4px 0 0 #f97316;
}

/* =========================================================
   الفرنسية — اتجاه الترتيب
   ========================================================= */

.lwf-competition-info--fr,
.competition-overview-standings-card--fr {
    direction: ltr;
}

.competition-overview-standings-card--fr .lwf-standings-table {
    direction: ltr;
}

/* =========================================================
   العربية — اتجاه الترتيب
   ========================================================= */

.competition-overview-standings-card--ar {
    direction: rtl;
}

.competition-overview-standings-card--ar .lwf-standings-table {
    direction: rtl;
}

/* =========================================================
   الفرنسية — عنوان الترتيب LTR
   ========================================================= */

.competition-overview-standings-card--fr .match-competition {
    direction: ltr;
    flex-direction: row;
    justify-content: flex-start;
}

.competition-overview-standings-card--fr .match-competition img {
    order: 0;
    margin-left: 0;
    margin-right: 10px;
}

.competition-overview-standings-card--ar .lwf-standings-legend {
    direction: rtl;
    justify-content: flex-start;
}

.competition-overview-standings-card--fr .lwf-standings-legend {
    direction: ltr;
    justify-content: flex-start;
}