
*{box-sizing:border-box}
html{scroll-behavior:smooth}
/* Specificity آگاهانه بالاتر از یک Tag ساده (html X)، نه با Override اجباری: از زمانی که فاز ۶ Bootstrap
   Vendor‌شده را روی صفحات MI هم لود می‌کند، Reboot خودِ Bootstrap (که بعد از mi.css لود می‌شود)
   همین Selectorهای خام را با Specificity برابر و ترتیب بارگذاری بعدی بازنویسی می‌کرد. */
html body{margin:0;background:var(--insight-surface-alt);color:var(--insight-text);line-height:1.65}
html button,html input,html select{font:inherit}
html a{color:inherit}
.hero{background:linear-gradient(125deg,var(--insight-primary),var(--insight-primary-2) 50%,var(--insight-accent) 76%);color:#fff;padding:20px 0}
.hero-inner{max-width:1680px;margin:auto;padding:0 20px;display:grid;grid-template-columns:220px 1fr;align-items:center;gap:22px}
.logo-zone{background:#fff;border-radius:24px;padding:18px 22px;min-height:150px;display:flex;align-items:center;justify-content:center;box-shadow:0 18px 45px rgba(0,0,0,.18)}
.logo-zone img{max-width:100%;max-height:125px;object-fit:contain}
.hero-copy h1{margin:0 0 8px;font-size:clamp(22px,3vw,34px);font-weight:800;letter-spacing:-.4px}
.hero-copy p{margin:0;max-width:980px;font-size:14px;opacity:.94}
.version-pill{display:inline-flex;margin-top:12px;padding:5px 11px;border-radius:999px;background:rgba(255,255,255,.16);border:1px solid rgba(255,255,255,.28);font-size:11px;font-weight:700}
/* Specificity آگاهانه بالاتر (main.container، نه با Override اجباری): از فاز ۶ که Bootstrap
   Vendor‌شده روی صفحات MI هم لود می‌شود، کلاس .container خودِ Bootstrap (که در هر
   Breakpoint یک max-width محدودتر — ۵۴۰ تا ۱۳۲۰px — تعریف می‌کند) با همین نام و
   Specificity برابر، ولی بارگذاری بعدی، روی max-width:1680px این‌جا برنده می‌شد؛ همین
   تصادف نام‌گذاری باعث جمع‌شدن کانتینر اصلی MI و افزایش Padding دو طرف صفحه شده بود. */
main.container{max-width:1680px;margin:auto;padding:16px}
.question-box,.guide-box{background:#fff;border:1px solid var(--insight-border);border-radius:16px;box-shadow:var(--insight-shadow);margin:12px 0}
.questions-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
.qcard{border:1px solid var(--insight-border);border-radius:10px;background:#fbfbfe;padding:9px 10px;cursor:pointer;font-size:12px;line-height:1.5;text-align:right;color:var(--insight-text)}
.qcard:hover,.qcard.active{border-color:var(--insight-accent);background:#fff4fa;color:#72154c}

.country-cards{display:grid;margin:12px 0 5px}
.country-card{border:1px solid rgba(255,255,255,.75);box-shadow:0 5px 16px rgba(31,2,123,.08);flex-direction:column;transition:transform .18s ease}
.country-card:hover{transform:translateY(-2px)}
.country-card .name{font-weight:700;display:flex;align-items:center}
.flag{font-size:17px;line-height:1}
.country-card .tier{font-weight:800}
.country-card .score{font-weight:800;line-height:1.15}.country-card .score-label{font-weight:600;opacity:.72}
.country-card .count{font-weight:500}
.country-card.Aplus{background:#c7f3d7;color:#14532d} .country-card.A{background:#dceafe;color:#17366f}
.country-card.Bplus{background:#fff0bd;color:#714400} .country-card.B{background:#ffdfbd;color:#7a3514}
.country-card.C{background:#ffd5d5;color:#7b2020} .country-card.D{background:#e6e8ef;color:#40475c} .country-card.NA{background:#eef0f5;color:#6d7489}
.filters{background:#fff;border:1px solid var(--insight-border);border-radius:16px;box-shadow:var(--insight-shadow);padding:11px;position:sticky;top:6px;z-index:5}
.category-nav{display:flex;gap:6px;flex-wrap:wrap;overflow:visible;padding-bottom:9px}
.catbtn{white-space:nowrap;border:1px solid #cbd2e4;background:#fff;border-radius:999px;cursor:pointer;color:#4a5371}
.catbtn.active{color:#fff;border-color:transparent;background:linear-gradient(100deg,var(--insight-primary-2),var(--insight-accent))}
.filter-grid{display:grid;gap:7px}
html input,html select{width:100%;border:1px solid #cbd2e4;border-radius:9px;padding:8px 9px;background:#fff;color:var(--insight-text);outline:none;font-size:12px}
.sort-select{min-width:140px}
.active-filter{font-size:10.5px;color:var(--insight-muted);margin-top:6px}
.clear-question{display:none;border:0;background:#fff0f5;color:#a21658;border-radius:8px;padding:4px 8px;cursor:pointer;margin-right:7px;font-size:10.5px}
.tablewrap{overflow:auto;background:#fff;border:1px solid var(--insight-border);border-radius:16px;box-shadow:var(--insight-shadow);margin-top:10px;max-height:72vh}
.mi-table-region{position:relative;--mi-scroll-progress:0}
.mi-table-edge-cue,.mi-table-scroll-progress{display:none}
#dataTable{border-collapse:collapse;width:100%;font-size:11.5px}

#dataTable th,#dataTable td{padding:8px;border-bottom:1px solid #edf0f6;text-align:center;vertical-align:middle}
#dataTable th{background:var(--insight-primary);color:#fff;position:sticky;top:0;z-index:3;font-weight:700;white-space:nowrap}
#dataTable tbody tr:hover{background:#f8f7ff;cursor:pointer}
.indicator-cell{text-align:right;line-height:1.45}
.spain-value-cell{line-height:1.45;text-align:right}

.spain-tier-cell,.spain-tier-head{width:76px;min-width:76px;max-width:76px}
.importance-cell,.importance-head{width:58px;min-width:58px;max-width:58px}
.evidence-cell,.evidence-head{width:56px;min-width:56px;max-width:56px}
.source-cell,.source-head{width:96px;min-width:96px;max-width:96px}
.source-link{display:inline-block;max-width:78px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:middle}
.indicator-fa{font-weight:700;font-size:12.5px;line-height:1.45}
.indicator-en{font-size:9.5px;color:var(--insight-muted);direction:ltr;text-align:center;line-height:1.3}
.value-note{font-size:9px;color:var(--insight-muted)}
/* span.badge (نه فقط .badge، بدون Override اجباری): از فاز ۶ که Bootstrap لود می‌شود، کلاس
   .badge خودِ Bootstrap (padding/border-radius/font-weight متفاوت) با Specificity برابر و
   بارگذاری بعدی روی این‌ها برنده می‌شد و ظاهر همه نشان‌های Tier/Evidence را عوض می‌کرد. */
span.badge{display:inline-block;min-width:31px;border-radius:7px;padding:2px 6px;font-weight:800}
.badge.Aplus{background:#d8f6e2;color:#146235} .badge.A{background:#e2edff;color:#214587} .badge.Bplus{background:#fff1c7;color:#805000} .badge.B{background:#ffe4c8;color:#87401c} .badge.C{background:#ffdede;color:#8e2626} .badge.D{background:#eaecf2;color:#484e61} .badge.NA{background:#f0f2f6;color:#7a8193}
.evidence-cell .badge{min-width:28px;padding:2px 5px;font-size:10px}
.importance-bars{display:inline-flex;gap:2px;align-items:center;justify-content:center;width:38px}
.importance-bars span{display:block;width:5px;height:10px;border-radius:2px;background:#e4e7f0}
.importance-bars span.on{background:linear-gradient(180deg,var(--insight-primary-2),var(--insight-accent))}
.source-link{font-weight:600;text-decoration:none;font-size:10px} .source-link:hover{text-decoration:underline}
.detail-title{color:var(--insight-primary)} .detail-en{color:var(--insight-muted);direction:ltr;text-align:right}
.detail-grid{display:grid}
.detail-box{border:1px solid var(--insight-border);background:#fafbfe}
.country-grid{display:grid}
.detail-section h3{color:var(--insight-accent)} 
.small-note{color:var(--insight-muted)}
.guide-box{padding:14px 16px} .guide-box h3{margin:0 0 7px;color:var(--insight-primary);font-size:14px}
.guide-grid{display:grid;gap:8px}
.guide-item{font-size:10.5px;color:#535b77;background:#fafbfe;border:1px solid #e8ebf3;padding:8px;border-radius:9px}
.guide-item b{display:block;color:var(--insight-text);font-size:11.5px;margin-bottom:1px}
.sources-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
.source-item{font-size:10.5px;border:1px solid #e6e9f2;border-radius:9px;padding:7px;background:#fafbfe;text-align:left;direction:ltr}
.source-item a{font-weight:700;text-decoration:none} .source-grade{display:inline-block;margin-right:4px}
footer{margin-top:22px;background:var(--insight-primary);color:#fff}
.subsystem-hero--mi .hero-inner{grid-template-columns:190px minmax(0,1fr)}
.subsystem-hero--mi .logo-zone{width:190px;min-height:190px;padding:18px;border-radius:30px}
.footer-inner{max-width:1680px;margin:auto;padding:16px 20px;display:flex;align-items:center;justify-content:space-between;gap:16px;font-size:10.5px}
.footer-link{color:#fff;text-decoration:none;font-weight:700} .footer-link:hover{text-decoration:underline} .footer-muted{opacity:.72}

@media (max-width:1100px){
 .hero-inner{grid-template-columns:170px 1fr}
 .questions-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 
 .filter-grid{grid-template-columns:1.5fr 1fr 1fr}
 .guide-grid{grid-template-columns:repeat(2,1fr)} .sources-grid{grid-template-columns:repeat(2,1fr)}
 .detail-grid{grid-template-columns:repeat(2,1fr)} 
}
@media (max-width:760px){
 .hero{padding:14px 0}
 .hero-inner{display:block;padding:0 12px}
 .logo-zone{width:100%;min-height:110px;border-radius:18px;padding:12px 18px;margin-bottom:12px}
 .logo-zone img{max-height:85px}
 .hero-copy h1{font-size:19px;line-height:1.5} .hero-copy p{font-size:11.5px}
 .version-pill{font-size:9.5px}
 main.container{padding:8px}
 .question-box,.guide-box{margin:8px 0;border-radius:13px}
 .insight-disclosure__toggle{padding:.75rem}
 .insight-disclosure__toggle small{display:none}
 .questions-grid{grid-template-columns:1fr;gap:6px}
 .country-cards{gap:6px;margin:8px 0 10px}
 .country-card{padding:8px;min-height:64px}
 .country-card .name{font-size:11px} .country-card .tier{font-size:19px} .country-card .score{font-size:15px} .country-card .count{font-size:8.5px}
 .filters{position:static;padding:8px;border-radius:13px}
    .filter-grid{grid-template-columns:1fr 1fr;gap:6px}
 .filter-grid .insight-field:first-child{grid-column:1 / -1}
 html input,html select{font-size:11px;padding:8px}
 .category-nav{padding-bottom:7px}
 .catbtn{font-size:10px;padding:5px 8px}
 .mi-table-region{padding-bottom:9px}
 .tablewrap{max-height:none;border-radius:13px;scrollbar-width:none;-webkit-overflow-scrolling:touch}
 .tablewrap::-webkit-scrollbar{display:none}
 .mi-table-edge-cue{position:absolute;z-index:6;display:block;top:10px;bottom:9px;width:42px;overflow:visible;color:#fff;pointer-events:none;opacity:0;transition:opacity .2s ease}.mi-table-edge-cue--left{left:0;background:linear-gradient(90deg,rgba(31,2,123,.28),rgba(31,2,123,.08) 48%,transparent)}.mi-table-edge-cue--right{right:0;background:linear-gradient(270deg,rgba(31,2,123,.28),rgba(31,2,123,.08) 48%,transparent)}
 .mi-table-edge-cue button{position:absolute;top:var(--mi-cue-top,12px);display:grid;place-items:center;width:28px;height:42px;padding:0;border:0;background:rgba(31,2,123,.9);color:#fff;font:800 26px/1 Arial;direction:ltr;unicode-bidi:isolate;cursor:pointer;pointer-events:auto;transition:top .08s linear,transform .18s ease}.mi-table-edge-cue--left button{left:0;border-radius:0 11px 11px 0}.mi-table-edge-cue--right button{right:0;border-radius:11px 0 0 11px}.mi-table-edge-cue button:hover{transform:scale(1.04)}
 .mi-table-region.has-hidden-left .mi-table-edge-cue--left,.mi-table-region.has-hidden-right .mi-table-edge-cue--right{opacity:1}
 .mi-table-scroll-progress{display:block;position:absolute;right:14px;left:14px;bottom:0;height:3px;border-radius:999px;background:#dfe3ef;overflow:hidden;direction:ltr}
 .mi-table-scroll-progress span{display:block;width:28%;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--insight-primary-2),var(--insight-accent));transform:translateX(calc(var(--mi-scroll-progress) * 257%));transition:transform .12s ease-out}
 #dataTable{min-width:1320px}
 #dataTable th,#dataTable td{padding:7px 6px}
 .indicator-cell{width:180px;max-width:180px}
 .indicator-fa{font-size:11.5px} .indicator-en{font-size:8.8px}
 .source-link{font-size:9.5px}
 .guide-grid,.sources-grid{grid-template-columns:1fr}
  .country-grid{grid-template-columns:repeat(2,1fr)}
 .footer-inner{flex-direction:column;text-align:center;gap:4px;padding:13px}
}
.subsystem-hero--mi .hero-inner{direction:rtl}.subsystem-hero--mi .hero-copy{direction:rtl}
@media (max-width:680px){.subsystem-hero--mi .hero-inner{display:block}.subsystem-hero--mi .hero-copy{max-width:760px;margin:auto}}
@keyframes mi-edge-nudge{0%,100%{transform:translateX(0)}50%{transform:translateX(-4px)}}
@media (prefers-reduced-motion:reduce){.mi-table-edge-cue button{transition:none}}
@media (max-width:390px){
 .hero-copy h1{font-size:17px}
 .country-cards{grid-template-columns:1fr 1fr}
 .filter-grid{grid-template-columns:1fr}
 .filter-grid .insight-field:first-child{grid-column:auto}
 #dataTable{min-width:1280px}
 .indicator-cell{width:165px;max-width:165px}
}

.score-explainer{font-size:9.5px;color:var(--insight-muted);text-align:center;margin:0 0 10px}
.detail-hero{display:grid;padding-bottom:9px;border-bottom:1px solid var(--insight-border)}
.detail-brand{display:flex}


.copy-link-btn{border:1px solid var(--insight-border);background:#fff;color:var(--insight-primary);border-radius:8px;cursor:pointer;font-weight:700}
.compact-stat{display:flex;align-items:center;justify-content:space-between;gap:7px}
.detail-country-card{text-align:center;border:1px solid rgba(0,0,0,.05)}
.detail-country-card .country-name{font-weight:700}
.detail-country-card .country-tier{font-weight:800}
.detail-country-card .country-score{opacity:.75}
.detail-country-card.Aplus{background:#c7f3d7;color:#14532d}.detail-country-card.A{background:#dceafe;color:#17366f}
.detail-country-card.Bplus{background:#fff0bd;color:#714400}.detail-country-card.B{background:#ffdfbd;color:#7a3514}
.detail-country-card.C{background:#ffd5d5;color:#7b2020}.detail-country-card.D{background:#e6e8ef;color:#40475c}
.detail-footer-card{background:linear-gradient(110deg,var(--insight-primary),var(--insight-primary-2),var(--insight-accent));color:#fff}

.detail-footer-card a{color:#fff;font-weight:700;text-decoration:none}


/* v2.4.1 compact country cards and detail layout */
.country-cards{grid-template-columns:repeat(9,minmax(112px,1fr));gap:6px;overflow-x:auto;scrollbar-width:thin;padding-bottom:4px}
.country-card{border-radius:11px}
.country-card .name{white-space:nowrap;text-overflow:ellipsis}

.country-card .tier{margin-top:1px}
.country-card .score{font-size:13px}
.country-card .score-label{font-size:8px;white-space:nowrap}


.detail-hero{gap:8px;padding:0 0 7px}
.detail-brand{gap:14px;align-items:center}
.detail-brand>div{min-width:0;flex:1 1 auto}
.detail-brand img{border-radius:10px}
.detail-title{font-size:22px;line-height:1.25;margin:0}
.detail-en{font-size:11px;margin-top:2px}
.small-note{font-size:9px}

.copy-link-btn{font-size:9.5px;padding:5px 8px}
.detail-grid{gap:6px;margin:7px 0}
.detail-box{padding:6px 8px;border-radius:9px}
.compact-stat{font-size:11px}
.detail-section{margin-top:7px}
.detail-section h3{font-size:12px;margin:0 0 3px}
.detail-section p{font-size:11.5px;line-height:1.65;margin:0}
.detail-status{padding:7px 9px;background:#fafbfe;border:1px solid var(--insight-border);border-radius:9px}
.country-grid{grid-template-columns:repeat(9,minmax(78px,1fr));gap:5px}
.detail-country-card{border-radius:9px}
.detail-country-card .country-name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}


.detail-text-grid{display:grid;gap:7px;margin-top:7px}
.detail-text-grid .detail-section{margin:0;background:#fff;border:1px solid var(--insight-border);border-radius:9px}
.detail-source{margin-top:7px;font-size:10px;padding:6px 8px}
.detail-footer-card{margin-top:7px;border-radius:10px;font-size:8.8px;min-height:46px}


/* About producer */
.producer-box .disclosure-content{padding:0 16px 16px}
.producer-hero{display:flex;gap:14px;background:linear-gradient(110deg,#202a74,#2f4da4,#8a238f);color:#fff;border-radius:13px;margin-bottom:12px}

.producer-hero h3{margin:0 0 3px;font-size:18px}
.producer-hero p{margin:0;font-size:11px;opacity:.9}
.producer-content{grid-template-columns:repeat(2,minmax(0,1fr))}
.producer-section{border:1px solid var(--insight-border);background:#fafbfe;border-radius:11px;padding:11px 12px}
.producer-section.wide{grid-column:auto}
.producer-section h3{margin:0 0 6px;color:var(--insight-accent);font-size:14px}
.producer-section p{margin:0 0 7px;font-size:11.2px;line-height:1.9}
.producer-links{display:flex;gap:8px;flex-wrap:wrap;margin-top:9px}
.producer-links a{color:#fff;background:var(--insight-primary-2);text-decoration:none;border-radius:8px;padding:7px 10px;font-size:10px;font-weight:700}

/* Responsive detail */
@media (max-width:1100px){
  .country-cards{grid-template-columns:repeat(9,minmax(112px,1fr))}
  .country-grid{grid-template-columns:repeat(9,minmax(82px,1fr));overflow-x:auto}
  .detail-text-grid{grid-template-columns:1fr 1fr}
  .detail-text-grid .detail-section:last-child{grid-column:1/-1}
}
@media (max-width:760px){
  .country-cards{display:grid;grid-template-columns:repeat(9,minmax(112px,1fr));overflow-x:auto}
  
  
  
  
  
  
  
  
  
  
  .detail-text-grid .detail-section:last-child{grid-column:auto}
  .producer-content{grid-template-columns:1fr}
  .producer-section.wide{grid-column:auto}
  .producer-hero{align-items:flex-start}
}

/* Long-form Persian copy keeps a calm, even reading edge. */
.guide-item,.detail-section p,.spain-summary,.producer-section p{text-align:justify;text-align-last:right;text-justify:inter-word}

/* Hide the page print path; printing is done in a dedicated one-page window. */
@media print{
  body>*{display:none}
}


/* v2.4.2 navigation and evidence language */

.insight-segmented-toggle__tabs{gap:0}
.insight-segmented-toggle__tab{transition:.2s ease}








.catbtn{font-size:10.5px;padding:6px 10px}

.filters{margin-top:10px}


/* Evidence is intentionally visually different from country tiers. */
.evidence-mark{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-width:48px;white-space:nowrap;color:var(--insight-primary);font-weight:700;font-size:9.5px}
.evidence-bars{display:inline-flex;align-items:flex-end;gap:2px;height:14px}
.evidence-bars i{display:block;width:4px;border-radius:3px;background:#dfe3ee}
.evidence-bars i:nth-child(1){height:6px}
.evidence-bars i:nth-child(2){height:10px}
.evidence-bars i:nth-child(3){height:14px}
.evidence-mark.level-A .evidence-bars i{background:linear-gradient(#2f4da4,#8a238f)}
.evidence-mark.level-B .evidence-bars i:nth-child(-n/**/+2){background:linear-gradient(#2f4da4,#8a238f)}
.evidence-mark.level-C .evidence-bars i:first-child{background:linear-gradient(#2f4da4,#8a238f)}
.evidence-label{font-size:8.7px;color:var(--insight-muted)}
.source-grade{background:#f0f2f8;color:var(--insight-primary);border-radius:6px;padding:2px 5px;font-size:8px}

/* Compact, print-aligned detail branding. */
.detail-brand img{width:88px;height:62px;flex:0 0 88px;object-fit:contain;border:0;padding:0;background:transparent}

.producer-hero img{border:0}
.producer-contact{grid-column:1/-1}
.producer-contact .producer-links{margin-top:0}

/* Four filter dropdowns plus search. */



/* v3.0 final exploration layout */
.insight-segmented-toggle{padding:0}
.explore-columns{display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:start}
.explore-column{border:1px solid var(--insight-border);border-radius:15px;background:#fff;overflow:hidden;box-shadow:var(--insight-shadow)}
.explore-column.active{border-color:rgba(47,77,164,.42)}
.insight-segmented-toggle__tab{border:0;border-radius:0}
.insight-segmented-toggle__panel{border-top:1px solid var(--insight-border)}
.insight-segmented-toggle__panel:not(.is-open){display:none}
.explore-column:not(.active) .insight-segmented-toggle__tab{background:#f7f8fc;color:var(--insight-primary)}


@media (max-width:850px){.explore-columns{grid-template-columns:1fr}}

/* Producer logo has sufficient room */

.producer-hero img{flex:0 0 154px}


/* v3.0.1 RC2 */
.insight-segmented-toggle{margin-top:12px;background:#fff;border:1px solid var(--insight-border);border-radius:16px;box-shadow:var(--insight-shadow);overflow:hidden}
.insight-segmented-toggle__tabs{display:grid;grid-template-columns:1fr 1fr;border-bottom:1px solid var(--insight-border)}
.insight-segmented-toggle__tab{width:100%;background:#f7f8fc;color:var(--insight-primary);padding:13px 16px;text-align:right;cursor:pointer}
.insight-segmented-toggle__tab:first-child{border-left:1px solid var(--insight-border)}
.insight-segmented-toggle__tab span{display:block;font-size:13px;font-weight:800}.insight-segmented-toggle__tab small{display:block;margin-top:3px;font-size:9.5px;color:var(--insight-muted)}

.insight-segmented-toggle__content{width:100%}.insight-segmented-toggle__panel{display:none;width:100%;overflow:auto}.insight-segmented-toggle__panel.is-open{display:block}
.category-nav{justify-content:flex-start;padding:0}.questions-grid{max-height:none;overflow:visible}
.filter-grid{grid-template-columns:2fr repeat(3,1fr)}

.producer-content{display:flex;flex-direction:column;gap:10px}
.producer-section,.producer-section.wide,.producer-contact{width:100%;grid-column:auto}
.producer-hero{min-height:150px;padding:22px 24px;align-items:center}
.producer-hero img{width:168px;height:108px;object-fit:contain;padding:8px;background:#fff;border-radius:12px}

.inline-sources{display:inline-flex;align-items:center;gap:6px;flex-wrap:wrap;text-align:left;direction:ltr;unicode-bidi:isolate}
.inline-sources a{font-weight:700;color:var(--insight-primary-2);text-decoration:none}.inline-sources a:hover{text-decoration:underline}.inline-sources .sep{color:#9aa0b4}
.spain-summary{font-size:11.6px;line-height:1.8;color:var(--insight-text)}.spain-metric{margin-top:5px;font-size:9.5px;color:var(--insight-muted);font-weight:700}
.detail-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
@media (max-width:900px){.insight-segmented-toggle__tabs{grid-template-columns:1fr}.insight-segmented-toggle__tab:first-child{border-left:0;border-bottom:1px solid var(--insight-border)}.filter-grid{grid-template-columns:1fr 1fr}}
@media (max-width:620px){.filter-grid{grid-template-columns:1fr}.detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}


/* v3.0.0 Production Final polish */
.category-nav,.questions-grid{display:grid;align-items:stretch}
.qcard,.catcard{width:100%;border:1px solid var(--insight-border);background:#fff;border-radius:10px;text-align:right;color:var(--insight-primary);font-size:10.5px;font-weight:700;line-height:1.45;transition:.18s ease}
.qcard:hover,.catcard:hover{border-color:rgba(47,77,164,.45);box-shadow:0 4px 14px rgba(31,2,123,.08)}

.qcard.active .qmeta,.catcard.active .qmeta{color:rgba(255,255,255,.82)}
.qmeta{font-size:8.8px;color:var(--insight-muted)}




.spain-summary-cell{font-size:10.7px;line-height:1.65;color:var(--insight-text);text-align:justify;text-align-last:right;text-justify:inter-word}
.source-head,.source-cell{display:none}

.detail-actions{display:flex;flex-wrap:nowrap;align-items:center;justify-content:flex-end;position:relative;z-index:3}
.copy-link-btn{position:static;display:inline-flex;align-items:center;justify-content:center;min-width:112px;white-space:nowrap;flex:0 0 auto}
.detail-hero{grid-template-columns:minmax(0,1fr) auto;align-items:start}

@media (max-width:900px){
  .category-nav,.questions-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:620px){
  .category-nav,.questions-grid{grid-template-columns:1fr}
  .detail-hero{grid-template-columns:1fr}
  .detail-actions{justify-content:flex-start;flex-wrap:wrap}
}


/* Production refined visual system */
.insight-segmented-toggle__tab.is-active{background:#27377f;color:#fff}
.insight-segmented-toggle__tab.is-active small{color:rgba(255,255,255,.82)}
.qcard.active,.catcard.active{background:#3b4fa3;color:#fff;border-color:#3b4fa3}
.qcard,.catcard{min-height:54px;padding:7px 9px}
.category-nav,.questions-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}
.insight-segmented-toggle__panel{padding:9px 11px;max-height:none}
.qmeta{margin-top:3px}
.detail-actions{direction:ltr;gap:8px}
.detail-close-btn{min-width:38px;width:38px;padding:5px;font-size:18px;color:#7b2020;border-color:#efcaca;background:#fff7f7}

.detail-country-main{gap:6px}
.detail-country-card .country-tier{direction:ltr;unicode-bidi:isolate;font-size:14px}
.detail-country-card .country-score{white-space:nowrap}
.badge{direction:ltr;unicode-bidi:isolate}
.detail-text-grid{grid-template-columns:1fr 1fr}

.detail-text-grid .wide{grid-column:1/-1}
.detail-footer-card{justify-content:flex-start}
.detail-footer-copy{direction:ltr;text-align:left;line-height:1.55}
.guide-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.guide-item{line-height:1.65}
@media (max-width:1100px){
  .category-nav,.questions-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media (max-width:760px){
  .category-nav,.questions-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .detail-text-grid{grid-template-columns:1fr}
}
@media (max-width:520px){
  .category-nav,.questions-grid{grid-template-columns:1fr}
}


/* v3.0 Final Release */


.country-card .name{margin-bottom:2px}

.country-card .score{margin-top:2px}
.country-card .score-label{margin-top:1px}
.detail-country-card{min-height:38px;padding:3px 4px}
.detail-country-card .country-name{margin-bottom:1px}
.detail-country-main{width:100%;display:grid;grid-template-columns:auto auto;justify-content:center;align-items:baseline;column-gap:7px;direction:ltr}
.detail-country-card .country-tier{line-height:1;min-width:22px;text-align:center}
.detail-country-card .country-score{direction:rtl;text-align:right;line-height:1;font-size:7.8px}
.detail-text-grid{align-items:start}
.detail-text-grid .detail-section{min-height:0;height:auto;padding:8px 10px}
.detail-text-grid .detail-section p{margin:0;padding:0;line-height:1.7}
.detail-text-grid .detail-section h3{margin:0 0 4px}


/* removed stray ${css} template-literal artifact, 2026-08-08 */

/* MI module dimensions approved for final deployment */
.fixed-tier-cell,.fixed-tier-head{padding-top:3px;padding-bottom:3px}


#dataTable th,#dataTable td{padding-top:var(--insight-table-cell-y);padding-bottom:var(--insight-table-cell-y)}

.module-identity{display:flex;align-items:center;gap:7px;margin-bottom:7px;font-size:10px}.module-identity a{color:#fff;font-weight:800;text-decoration:none}.module-identity span{opacity:.55}.module-identity small{margin-right:8px;opacity:.8}



#dataTable th,#dataTable td{padding-left:3px;padding-right:3px}

/* Final v3.1 table-density adjustments */
/* #dataTable (نه table خام): نسخه قبلی این خط با یک Selector بی‌محدوده (table) نوشته شده بود
   که فقط با !important روی #dataTable{min-width:1360px} خط بالاتر برنده می‌شد — طبق ممیزی
   حذف !important (۲۰۲۶-۰۸-۰۸)، به‌جای اتکا به !important، خودِ Selector به همون شناسه اصلی
   جدول (Specificity بالاتر از هر رقیب) اصلاح شد. */
#dataTable{min-width:1180px}
.fixed-tier-cell,.fixed-tier-head{width:40px;min-width:38px;max-width:44px;padding-left:1px;padding-right:1px;font-size:11px}
.spain-tier-head,.spain-tier-cell{width:54px;min-width:52px;max-width:58px;padding-left:2px;padding-right:2px}
.importance-head,.importance-cell{width:74px;min-width:72px;max-width:78px;padding-left:3px;padding-right:3px}
.evidence-head,.evidence-cell{width:68px;min-width:66px;max-width:72px;padding-left:2px;padding-right:2px}
.indicator-cell{min-width:225px;width:245px;max-width:265px;padding-right:14px;padding-left:8px}
/* thead th:first-child خام (بدون #dataTable) اینجا حذف شد — طبق ممیزی !important (۲۰۲۶-۰۸-۰۸)،
   این Selector هیچ‌وقت واقعاً اثر بصری نداشت: #dataTable thead th:first-child پایین‌تر همین
   فایل (Specificity بالاتر با شناسه #dataTable) همیشه برنده بود، صرف‌نظر از این خط. */
.spain-value-cell{min-width:275px;width:295px;max-width:315px;padding-left:5px;padding-right:6px}

.module-identity small{display:none}

/* v3.1.1 release refinements */
#dataTable td.indicator-cell{padding-right:8px;padding-left:4px}
#dataTable thead th:first-child{padding-right:46px;padding-left:14px}
.country-card{min-height:102px;padding:10px 11px;display:grid;grid-template-rows:auto 1fr auto;align-content:stretch;justify-content:stretch}
.country-card .name{justify-content:flex-start;gap:6px;font-size:12.5px;line-height:1.3;overflow:visible}.country-card .name b{font-weight:800}.country-card .flag{font-size:17px}
.country-card-result{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:4px 0 3px;direction:ltr}.country-card .tier{font-size:23px;line-height:1;margin:0}.country-card .score{display:flex;align-items:baseline;gap:3px;margin:0;white-space:nowrap;direction:rtl}.country-card .score strong{font-size:18px;line-height:1;font-weight:800}.country-card .score small{font-size:8px;font-weight:700;opacity:.7}.country-card .score.no-data{font-size:10px;font-weight:700}
.country-card .count{border-top:1px solid currentColor;padding-top:4px;margin-top:2px;font-size:8.8px;opacity:.62;text-align:right}
.detail-country-card .country-name{font-size:13px;line-height:1.35}
.detail-footer-card{display:grid;grid-template-columns:1fr 1.35fr;align-items:center;gap:16px;padding:12px 14px;direction:ltr;text-align:left}
.detail-footer-card img{width:54px;height:54px;object-fit:contain;padding:0;background:transparent;border:0;border-radius:0}
.detail-footer-brand{display:flex;align-items:center;gap:10px}.detail-footer-brand div,.detail-footer-meta{display:flex;flex-direction:column;gap:2px}
.detail-footer-brand b{font-size:12px}.detail-footer-brand span,.detail-footer-meta span{font-size:9px;opacity:.84}.detail-footer-meta b{font-size:10px}.detail-footer-meta small{font-size:8px;opacity:.72}
@media (max-width:900px){.detail-footer-card{grid-template-columns:1fr}}
/* body{font-family:var(--font-fa)} خام اینجا حذف شد — همون مقدار از قبل با html body (فایل
   همین خودِ mi.css، خط ۷) و core.css سراسری تضمین شده؛ تکرار بدون !important هیچ اثری
   نداشت (Specificity کمتر از html body)، پس فقط کد اضافه/گمراه‌کننده بود. */
.module-identity,.indicator-en,.detail-en,.insight-en,.country-card .grade,.country-card .tier,[lang="en"]{font-family:var(--font-en)}

/* Asset 3.1.2.20: final mobile hierarchy overrides. */
@media (max-width:760px){
 .guide-grid{grid-template-columns:1fr;gap:7px}
 .guide-box{padding:14px}
 .guide-item{padding:11px 12px;font-size:11px;line-height:1.8;min-height:0}
 .guide-item b{font-size:12.5px;margin-bottom:3px}
 .detail-hero{display:grid;grid-template-columns:1fr;gap:10px;padding:0 0 10px}
 .detail-brand{display:flex;align-items:flex-start;gap:10px}
 .detail-brand>div{min-width:0;flex:1 1 auto}
 .detail-brand img{width:62px;height:58px;flex:0 0 62px;padding:3px;border-radius:9px}
 .detail-title{font-size:18px;line-height:1.45}
 .detail-en{font-size:10.5px;line-height:1.45;overflow-wrap:anywhere}
 .detail-actions{display:grid;grid-template-columns:44px minmax(0,1fr) minmax(0,1fr);gap:7px;width:100%;direction:ltr;justify-content:stretch;flex-wrap:nowrap}
 .detail-actions .copy-link-btn{min-width:0;width:100%;min-height:38px;padding:6px;direction:rtl}
 .detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
