/* ══════════════════════════════════════════════════════════════
   نمودار اکوسیستم — شش دامنه دور یک هستهٔ مرکزی
   ══════════════════════════════════════════════════════════════ */

.eco {
    background: #F7F5FC;
    padding: 60px 0 66px;
    direction: rtl;
}

.eco-head {
    max-width: 720px;
    margin: 0 auto 44px;
    text-align: center;
}

.eco-eyebrow {
    display: inline-block;
    padding: 5px 14px;
    font-size: 12px;
    font-weight: 700;
    color: #352070;
    background: #EEBB66;
    border-radius: 30px;
}

.eco-head h2 {
    margin: 14px 0 12px;
    font-size: 26px;
    font-weight: 800;
    color: #352070;
    line-height: 1.5;
}

.eco-head p {
    margin: 0;
    font-size: 14px;
    line-height: 2;
    color: #5f5a72;
}

/* ─────────── صحنه و حلقه‌های مداری ─────────── */
.eco-stage {
    position: relative;
    max-width: 1120px;
    margin: 0 auto;
}

/* دو دایرهٔ خط‌چین هم‌مرکز — فقط تزئینی، پس pointer-events: none */
.eco-rings {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    height: 100%;
    aspect-ratio: 1;
    border: 1px dashed rgba(53, 32, 112, .18);
    border-radius: 50%;
    pointer-events: none;
}

.eco-rings::after {
    content: '';
    position: absolute;
    inset: 17%;
    border: 1px dashed rgba(238, 187, 102, .55);
    border-radius: 50%;
}

/* ─────────── شبکه: سه بالا، هسته، سه پایین ─────────── */
.eco-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-areas:
        "tl tc tr"
        ".  h  ."
        "bl bc br";
    row-gap: 46px;
    column-gap: 22px;
    align-items: stretch;
}

.eco-tl { grid-area: tl; }
.eco-tc { grid-area: tc; }
.eco-tr { grid-area: tr; }
.eco-bl { grid-area: bl; }
.eco-bc { grid-area: bc; }
.eco-br { grid-area: br; }

/* ─────────── کارت دامنه ─────────── */
.eco-node {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 18px 18px 14px;
    background: #fff;
    border: 1px solid #E4DFF0;
    border-radius: 16px;
    box-shadow: 0 14px 34px -26px rgba(53, 32, 112, .55);
    transition: transform .26s cubic-bezier(.22, 1, .36, 1), box-shadow .26s, border-color .26s;
}

.eco-node:hover {
    transform: translateY(-5px);
    border-color: #d9a341;
    box-shadow: 0 22px 44px -24px rgba(53, 32, 112, .45);
}

.eco-node-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px dashed #E4DFF0;
}

.eco-node-ic {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    background: #F7F5FC;
    border: 1px solid #E4DFF0;
    border-radius: 12px;
}

.eco-node-ic img {
    width: 26px;
    height: 26px;
    display: block;
}

.eco-node-head h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 800;
    color: #352070;
    line-height: 1.5;
}

/* شمار محصول هر دامنه — رنگ طلایی به‌عنوان لهجهٔ تک */
.eco-node-n {
    margin-inline-start: auto;
    flex: 0 0 auto;
    min-width: 26px;
    padding: 2px 8px;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    color: #7a5b12;
    background: #FAEEDA;
    border-radius: 20px;
}

/* ─────────── فهرست محصولات ─────────── */
.eco-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.eco-list li { margin: 0; }

/* style-brand.css قاعدهٔ a{color:…!important} دارد؛ پس رنگ اینجا هم !important است */
.eco-list a {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 7px 9px;
    margin: 0 -9px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.7;
    color: #3d3560 !important;
    text-decoration: none;
    border-radius: 8px;
    transition: background .18s, color .18s;
}

.eco-list a > span {
    flex: 0 0 auto;
    width: 6px;
    height: 6px;
    background: #EEBB66;
    border-radius: 50%;
}

.eco-list a:hover {
    color: #1a1a2e !important;
    background: #F7F5FC;
}

/* ─────────── هستهٔ مرکزی ─────────── */
.eco-hub {
    position: relative;
    grid-area: h;
    align-self: center;
    justify-self: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 196px;
    height: 196px;
    padding: 20px;
    text-align: center;
    color: #fff;
    background: #352070;
    border-radius: 50%;
    box-shadow: 0 0 0 8px #fff, 0 0 0 9px rgba(238, 187, 102, .9), 0 24px 48px -22px rgba(53, 32, 112, .7);
}

.eco-hub strong {
    font-size: 19px;
    font-weight: 800;
    color: #fff;
}

.eco-hub small {
    font-size: 12px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .82);
}

/* خط‌چین اتصال به بالا و پایین */
.eco-hub::before,
.eco-hub::after {
    content: '';
    position: absolute;
    left: 50%;
    width: 0;
    height: 46px;
    border-inline-start: 1px dashed rgba(53, 32, 112, .35);
}

.eco-hub::before { bottom: 100%; }
.eco-hub::after  { top: 100%; }

/* حلقهٔ طلایی آرام — تنها موشن مداوم صفحه */
.eco-hub-pulse {
    position: absolute;
    inset: -14px;
    border: 1px solid rgba(238, 187, 102, .5);
    border-radius: 50%;
    animation: ecoPulse 4.5s ease-in-out infinite;
}

@keyframes ecoPulse {
    0%, 100% { transform: scale(1);    opacity: .85; }
    50%      { transform: scale(1.05); opacity: .35; }
}

/* ─────────── ورود پله‌ای کارت‌ها ─────────── */
.eco-node {
    animation: ecoRise .5s cubic-bezier(.22, 1, .36, 1) both;
}
.eco-tl { animation-delay: .02s; }
.eco-tc { animation-delay: .08s; }
.eco-tr { animation-delay: .14s; }
.eco-hub { animation-delay: .2s; }
.eco-bl { animation-delay: .26s; }
.eco-bc { animation-delay: .32s; }
.eco-br { animation-delay: .38s; }

@keyframes ecoRise {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: none; }
}

/* ─────────── موبایل ─────────── */
@media (max-width: 980px) {
    .eco { padding: 46px 0 50px; }

    .eco-grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "h"
            "tl" "tc" "tr"
            "bl" "bc" "br";
        row-gap: 16px;
        column-gap: 0;
    }

    /* حلقه و خطوط اتصال در یک ستون معنا ندارند */
    .eco-rings,
    .eco-hub::before,
    .eco-hub::after { display: none; }

    .eco-hub {
        width: 168px;
        height: 168px;
        margin: 0 auto 10px;
        box-shadow: 0 0 0 6px #fff, 0 0 0 7px rgba(238, 187, 102, .9), 0 20px 40px -22px rgba(53, 32, 112, .7);
    }

    .eco-hub strong { font-size: 17px; }
    .eco-node { padding: 16px 15px 12px; }
    .eco-head h2 { font-size: 22px; }
}

@media (max-width: 420px) {
    .eco-node-head { flex-wrap: wrap; }
    .eco-node-n { margin-inline-start: 0; order: -1; }
}

@media (prefers-reduced-motion: reduce) {
    .eco-node, .eco-hub-pulse { animation: none !important; transition: none !important; }
}
