.fxam-box,
.fxam-dashboard {
    direction: rtl;
    font-family: Cairo, Tahoma, sans-serif;
    max-width: 1100px;
    margin: 35px auto;
}

.fxam-box {
    background: #fff;
    border: 1px solid #e5eaf0;
    border-radius: 18px;
    padding: 35px;
    box-shadow: 0 12px 35px rgba(15,23,42,.06);
}

.fxam-box h2 {
    margin: 0 0 15px;
    color: #14233b;
}

.fxam-notice {
    background: #f0f6ff;
    padding: 16px;
    border-radius: 10px;
    margin: 20px 0;
    color: #27538b;
}

.fxam-button {
    display: inline-block;
    background: #1769aa;
    color: #fff !important;
    padding: 12px 25px;
    border-radius: 9px;
    text-decoration: none;
}

.fxam-welcome {
    background: linear-gradient(120deg,#102d4d,#1769aa);
    color: white;
    padding: 32px;
    border-radius: 18px;
    margin-bottom: 25px;
}

.fxam-welcome h2,
.fxam-welcome p {
    color: white;
}

.fxam-welcome h2 {
    margin: 12px 0;
}

.fxam-welcome span {
    opacity: .8;
    font-size: 13px;
}

.fxam-grid {
    display: grid;
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 20px;
}

.fxam-card {
    background: white;
    border: 1px solid #e6eaf0;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 6px 25px rgba(15,23,42,.04);
}

.fxam-icon {
    font-size: 30px;
    margin-bottom: 15px;
}

.fxam-card h3 {
    font-size: 19px;
    color: #14233b;
    margin: 0 0 12px;
}

.fxam-card p {
    font-size: 14px;
    line-height: 1.9;
    color: #64748b;
}

.fxam-card a {
    color: #1769aa;
    font-weight: 700;
    text-decoration: none;
}

.fxam-card span {
    font-size: 13px;
    color: #94a3b8;
}

.fxam-footer {
    text-align: left;
    margin-top: 25px;
}

.fxam-footer a {
    color: #b42318;
    text-decoration: none;
}

@media(max-width:900px) {
    .fxam-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }
}

@media(max-width:600px) {
    .fxam-grid {
        grid-template-columns: 1fr;
    }

    .fxam-welcome,
    .fxam-box {
        padding: 22px;
    }
}

/* FX Arabia Members — Dashboard Layout Fix */

body .fxam-dashboard {
    display: block !important;
    direction: rtl !important;
    width: 100% !important;
    max-width: 1200px !important;
    margin: 30px auto !important;
    font-family: Cairo, Tahoma, sans-serif !important;
}

body .fxam-dashboard .fxam-welcome {
    display: block !important;
    background: linear-gradient(120deg,#102d4d,#1769aa) !important;
    color: #fff !important;
    border-radius: 18px !important;
    padding: 35px !important;
    margin-bottom: 25px !important;
}

body .fxam-dashboard .fxam-welcome h2,
body .fxam-dashboard .fxam-welcome p,
body .fxam-dashboard .fxam-welcome span {
    color: #fff !important;
}

body .fxam-dashboard .fxam-grid {
    display: grid !important;
    grid-template-columns: repeat(3,minmax(0,1fr)) !important;
    gap: 20px !important;
    width: 100% !important;
}

body .fxam-dashboard .fxam-grid .fxam-card {
    display: block !important;
    background: #fff !important;
    border: 1px solid #e5eaf0 !important;
    border-radius: 16px !important;
    padding: 25px !important;
    box-shadow: 0 8px 24px rgba(15,23,42,.06) !important;
    min-width: 0 !important;
}

body .fxam-dashboard .fxam-card h3 {
    color: #14233b !important;
    margin-bottom: 12px !important;
}

@media(max-width:900px) {
    body .fxam-dashboard .fxam-grid {
        grid-template-columns: repeat(2,minmax(0,1fr)) !important;
    }
}

@media(max-width:600px) {
    body .fxam-dashboard .fxam-grid {
        grid-template-columns: 1fr !important;
    }
}


/* FX Arabia member pages — full width */
.content-shell.fxam-full-page {
    display: block !important;
    width: min(1180px, calc(100% - 32px)) !important;
}
.fxam-full-page > .article {
    width: 100% !important;
    max-width: none !important;
}
.fxam-full-page .article-content {
    width: 100% !important;
}
.fxam-inline-header {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    flex-shrink: 0;
    padding: 9px 15px;
    border-radius: 11px;
    background: #1686bb;
    color: #fff !important;
    font-family: Cairo, Tahoma, sans-serif;
    font-size: 13px;
    font-weight: 800;
    white-space: nowrap;
}
.fxam-inline-header:hover {
    background: #0d709e;
}
@media(max-width: 768px) {
    .fxam-inline-header {
        padding: 7px 10px;
        font-size: 12px;
    }
}

/* ========================================
   FX ARABIA MEMBERS — PREMIUM DASHBOARD
   ======================================== */

body .fxam-dashboard {
    direction: rtl;
    max-width: 1250px !important;
    margin: 30px auto !important;
    font-family: Cairo, Tahoma, sans-serif;
}

body .fxam-dashboard .fxam-welcome {
    background: linear-gradient(125deg,#102b4a,#1765a3) !important;
    border-radius: 20px !important;
    padding: 38px !important;
    margin-bottom: 28px !important;
    box-shadow: 0 12px 32px rgba(17,60,103,.16);
}

body .fxam-dashboard .fxam-grid {
    display: grid !important;
    grid-template-columns: repeat(3,minmax(0,1fr)) !important;
    gap: 22px !important;
}

body .fxam-dashboard .fxam-card {
    background: #fff !important;
    border: 1px solid #e5ebf2 !important;
    border-radius: 18px !important;
    padding: 28px !important;
    min-height: 210px;
    display: flex !important;
    flex-direction: column;
    align-items: flex-start;
    transition: transform .25s ease,box-shadow .25s ease,border-color .25s ease;
    box-shadow: 0 7px 24px rgba(18,38,63,.055) !important;
}

body .fxam-dashboard .fxam-card:hover {
    transform: translateY(-5px);
    border-color: #b8d4ee !important;
    box-shadow: 0 18px 40px rgba(18,60,100,.12) !important;
}

body .fxam-dashboard .fxam-card h3 {
    font-size: 19px !important;
    font-weight: 800 !important;
    color: #132d4c !important;
    margin: 12px 0 10px !important;
}

body .fxam-dashboard .fxam-card p {
    color: #65758b !important;
    line-height: 1.9 !important;
    font-size: 14px !important;
    flex-grow: 1;
}

body .fxam-dashboard .fxam-card a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #1264a3 !important;
    color: #fff !important;
    border-radius: 10px !important;
    padding: 10px 20px !important;
    text-decoration: none !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    transition: background .2s ease,transform .2s ease;
    margin-top: 15px;
}

body .fxam-dashboard .fxam-card a:hover {
    background: #0d4678 !important;
    transform: translateY(-2px);
}

body .fxam-dashboard .fxam-card a:focus-visible {
    outline: 3px solid #f5ad39 !important;
    outline-offset: 3px;
}

@media(max-width:950px) {
    body .fxam-dashboard .fxam-grid {
        grid-template-columns: repeat(2,minmax(0,1fr)) !important;
    }
}

@media(max-width:600px) {
    body .fxam-dashboard .fxam-welcome {
        padding: 24px !important;
    }

    body .fxam-dashboard .fxam-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    body .fxam-dashboard .fxam-card {
        min-height: auto;
        padding: 22px !important;
    }

    body .fxam-dashboard .fxam-card a {
        width: 100%;
    }
}

@media(prefers-reduced-motion:reduce) {
    body .fxam-dashboard .fxam-card,
    body .fxam-dashboard .fxam-card a {
        transition: none !important;
    }
}


/* FX Arabia — Logout button */
.fxam-logout-area {
    display: flex;
    justify-content: flex-start;
    margin: 28px 0 35px;
    direction: rtl;
}

.fxam-logout-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 26px;
    background: #fff1f2;
    color: #b42335 !important;
    border: 1px solid #fecdd3;
    border-radius: 12px;
    font-family: Cairo, Tahoma, sans-serif;
    font-weight: 800;
    text-decoration: none !important;
    transition: background .2s ease, transform .2s ease;
}

.fxam-logout-button:hover {
    background: #ffe4e6;
    transform: translateY(-2px);
    color: #9f1239 !important;
}

.fxam-logout-button:focus-visible {
    outline: 3px solid #b42335;
    outline-offset: 3px;
}

@media(max-width:600px) {
    .fxam-logout-button {
        width: 100%;
    }
}

/* FX Arabia Members — Professional Logout Button */
body .fxam-logout-area {
    display: flex !important;
    justify-content: flex-start !important;
    align-items: center !important;
    margin: 28px 0 12px !important;
    direction: rtl !important;
}

body .fxam-logout-button {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    background: #fff5f5 !important;
    color: #b42318 !important;
    border: 1px solid #fecaca !important;
    border-radius: 12px !important;
    padding: 13px 24px !important;
    font-family: Cairo, Tahoma, sans-serif !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    transition: all .2s ease !important;
}

body .fxam-logout-button:hover {
    background: #b42318 !important;
    border-color: #b42318 !important;
    color: #fff !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(180,35,24,.15);
}

body .fxam-logout-button span {
    font-size: 19px !important;
    line-height: 1 !important;
}

@media (max-width: 600px) {
    body .fxam-logout-button {
        width: 100% !important;
    }
}

/* FXAM-PRO-DASHBOARD-V2 */

.fxam-dashboard .fxam-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 22px !important;
    align-items: stretch !important;
}

.fxam-dashboard .fxam-card {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    min-height: 255px !important;
    padding: 28px 25px !important;
    background: #ffffff !important;
    border: 1px solid #e4eaf2 !important;
    border-radius: 18px !important;
    box-shadow: 0 5px 22px rgba(18, 46, 78, .045) !important;
    transition: transform .2s ease, box-shadow .2s ease !important;
}

.fxam-dashboard .fxam-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 32px rgba(18, 46, 78, .10) !important;
}

.fxam-dashboard .fxam-card h3 {
    font-size: 20px !important;
    font-weight: 800 !important;
    color: #142b47 !important;
    margin: 12px 0 8px !important;
}

.fxam-dashboard .fxam-card p {
    color: #687789 !important;
    font-size: 14px !important;
    line-height: 1.9 !important;
    margin-bottom: 18px !important;
}

.fxam-dashboard .fxam-card a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 44px !important;
    padding: 10px 16px !important;
    margin-top: auto !important;
    background: #1769aa !important;
    color: #ffffff !important;
    border-radius: 10px !important;
    text-decoration: none !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    box-sizing: border-box !important;
    transition: background .2s ease !important;
}

.fxam-dashboard .fxam-card a:hover {
    background: #104e84 !important;
    color: #ffffff !important;
}

.fxam-dashboard .fxam-card:not(:has(a)) {
    background: #fafbfd !important;
}

.fxam-dashboard .fxam-card:not(:has(a))::after {
    content: "قريبًا";
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    min-height: 44px;
    background: #e9edf2;
    color: #7b8795;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
}

@media (max-width: 950px) {
    .fxam-dashboard .fxam-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 600px) {
    .fxam-dashboard .fxam-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
    }

    .fxam-dashboard .fxam-card {
        min-height: 220px !important;
        padding: 22px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .fxam-dashboard .fxam-card,
    .fxam-dashboard .fxam-card a {
        transition: none !important;
    }
}


/* Logout Button — Far Left */
body .fxam-dashboard .fxam-welcome .fxam-logout-button {
    position: absolute !important;
    left: 0 !important;
    right: auto !important;
    bottom: 25px !important;
    margin: 0 !important;
    transform: none !important;
}



/* FX Arabia — Logout Final Position */
html body .fxam-dashboard .fxam-welcome {
    position: relative !important;
}

html body .fxam-dashboard .fxam-welcome > a.fxam-logout-button {
    position: absolute !important;
    inset-inline-start: auto !important;
    inset-inline-end: auto !important;
    left: 12px !important;
    right: auto !important;
    top: 50% !important;
    bottom: auto !important;
    margin: 0 !important;
    transform: translateY(-50%) !important;
    float: none !important;
    width: auto !important;
    max-width: max-content !important;
}

@media (max-width: 600px) {
    html body .fxam-dashboard .fxam-welcome > a.fxam-logout-button {
        left: 12px !important;
        top: auto !important;
        bottom: 12px !important;
        transform: none !important;
    }
}
