/* Afghan nationals page v3 — categorised image cards, tags, per-text sources. Prefix: afx- */
.afx-main{max-width:1120px;margin:0 auto;padding:28px 16px 72px;--st-free:#0E7A3E;--st-free-bg:#E6F6EC;--st-arr:#8A5A00;--st-arr-bg:#FFF3D6;--st-ev:#0B5FA5;--st-ev-bg:#E3F0FB;--st-req:#9B1C1C;--st-req-bg:#FCE8E8;--st-un:#4B5568;--st-un-bg:#EDEFF3}
.afx-hero{padding:8px 0 4px}
.afx-eyebrow{display:inline-flex;align-items:center;gap:8px;font-size:13px;font-weight:700;color:var(--color-primary-text,#C2510C)}
.afx-eyebrow .dot{width:8px;height:8px;border-radius:50%;background:var(--color-primary,#F37021)}
.afx-title{font-size:clamp(24px,4vw,36px);line-height:1.35;margin:8px 0 10px;color:var(--color-secondary,#0B3D6B)}
.afx-lead{max-width:760px;font-size:15px;line-height:1.9;color:var(--color-text-muted,#55627A);margin:0 0 16px}
.afx-stats{list-style:none;display:flex;gap:12px;flex-wrap:wrap;margin:0 0 18px;padding:0}
.afx-stats li{flex:1 1 140px;background:var(--color-card,#F5F7FA);border:1px solid var(--color-border,#E1E6EC);border-radius:14px;padding:12px 16px;display:flex;flex-direction:column;gap:2px}
.afx-stats b{font-size:26px;color:var(--color-secondary,#0B3D6B);line-height:1.2}
.afx-stats span{font-size:13px;color:var(--color-text-muted,#55627A)}
.afx-alert{display:flex;gap:12px;align-items:flex-start;background:var(--color-warning-light,#FEF6E7);border:1px solid #F3D9A0;border-radius:14px;padding:14px 16px;margin-bottom:20px}
.afx-alert>i{color:#B26B00;flex:none;margin-top:3px}
.afx-alert h2{font-size:15px;margin:0 0 4px;color:#7A4A00}
.afx-alert p{margin:0;font-size:13.5px;line-height:1.9;color:#5B4A25}

/* toolbar */
.afx-toolbar{position:sticky;top:0;z-index:20;background:var(--color-bg,#fff);border-bottom:1px solid var(--color-border,#E1E6EC);padding:10px 0;display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.afx-tabs{display:flex;gap:8px;flex-wrap:wrap;flex:1 1 420px}
@media (max-width:640px){.afx-tabs{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:thin;padding-bottom:2px}}
.afx-tab{display:inline-flex;align-items:center;gap:6px;white-space:nowrap;border:1px solid var(--color-border,#E1E6EC);background:#fff;border-radius:999px;padding:7px 12px;font:inherit;font-size:13px;font-weight:600;color:var(--color-text,#1A2233);cursor:pointer}
.afx-tab i{width:15px;height:15px}
.afx-tab em{font-style:normal;font-size:12px;background:var(--color-card,#F5F7FA);border-radius:999px;padding:1px 7px;color:var(--color-text-muted,#55627A)}
.afx-tab[aria-pressed=true]{background:var(--color-secondary,#0B3D6B);border-color:var(--color-secondary,#0B3D6B);color:#fff}
.afx-tab[aria-pressed=true] em{background:rgba(255,255,255,.2);color:#fff}
.afx-search{position:relative;flex:0 1 240px}
.afx-search i{position:absolute;inset-inline-start:12px;top:50%;transform:translateY(-50%);width:16px;height:16px;color:var(--color-text-faint,#5F6B7E)}
.afx-search input{width:100%;box-sizing:border-box;padding:9px 14px 9px 14px;padding-inline-start:36px;border:1px solid var(--color-border,#E1E6EC);border-radius:999px;font:inherit;font-size:14px}
.afx-count{font-size:13px;color:var(--color-text-muted,#55627A);margin:10px 0 0;min-height:1.4em}

/* sections */
.afx-section{margin-top:26px}
.afx-section[hidden],.afx-group[hidden]{display:none}
.afx-sec-head h2{font-size:20px;margin:0 0 4px;color:var(--color-secondary,#0B3D6B)}
.afx-sec-head p{margin:0 0 14px;font-size:13.5px;color:var(--color-text-muted,#55627A)}

/* tags */
.afx-tag{display:inline-flex;align-items:center;gap:5px;font-size:12px;font-weight:700;line-height:1;padding:6px 10px;border-radius:999px;white-space:nowrap}
.afx-tag i{width:13px;height:13px}
.afx-tag--free{background:var(--st-free-bg);color:var(--st-free)}
.afx-tag--arrival{background:var(--st-arr-bg);color:var(--st-arr)}
.afx-tag--evisa{background:var(--st-ev-bg);color:var(--st-ev)}
.afx-tag--required{background:var(--st-req-bg);color:var(--st-req)}
.afx-tag--unverified{background:var(--st-un-bg);color:var(--st-un)}
.afx-tag--priority{background:#FDEADA;color:#9A3F05}
.afx-tag--soft{background:var(--color-card,#F5F7FA);color:var(--color-text-muted,#55627A);border:1px solid var(--color-border,#E1E6EC);font-weight:600}
.afx-tag--full{background:#E6F6EC;color:#0E7A3E;border:1px solid #BFE5CC}

/* image cards */
.afx-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:18px}
.afx-card{background:#fff;border:1px solid var(--color-border,#E1E6EC);border-radius:18px;overflow:hidden;display:flex;flex-direction:column;box-shadow:0 1px 2px rgba(16,48,90,.05);transition:box-shadow .2s,transform .2s}
.afx-card:hover{box-shadow:0 10px 28px rgba(16,48,90,.14);transform:translateY(-2px)}
.afx-card[hidden],.afx-tile[hidden]{display:none}
.afx-card-img{position:relative;aspect-ratio:3/1.6;background-size:cover;background-position:center;background-color:#10305A;display:flex;flex-direction:column;justify-content:space-between;padding:12px 14px;color:#fff}
.afx-card-img h3{margin:0;font-size:22px;color:#fff;text-shadow:0 1px 8px rgba(0,0,0,.6)}
.afx-card-tags{display:flex;gap:6px;flex-wrap:wrap}
.afx-card-img .afx-tag{box-shadow:0 1px 4px rgba(0,0,0,.25)}
.afx-card-body{padding:14px 16px 16px;display:flex;flex-direction:column;gap:10px;flex:1}
.afx-chips{display:flex;gap:6px;flex-wrap:wrap}
.afx-summary{margin:0;font-size:14px;line-height:1.95;color:var(--color-text,#1A2233)}
.afx-muted{color:var(--color-text-muted,#55627A)}
.afx-card .afx-summary{display:-webkit-box;-webkit-line-clamp:5;-webkit-box-orient:vertical;overflow:hidden}
.afx-open{margin-top:auto;display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;border:0;border-radius:12px;background:var(--color-cta,#C2510C);color:#fff;padding:11px 14px;font:inherit;font-size:14px;font-weight:700;cursor:pointer}
.afx-open:hover{background:var(--color-cta-hover,#A3430A)}
[dir=ltr] .afx-arrow,html[lang=en] .afx-arrow{transform:scaleX(-1)}
.afx-checked{margin:0;font-size:12px;color:var(--color-text-faint,#5F6B7E);display:flex;gap:5px;align-items:center}
.afx-checked i{width:13px;height:13px}

/* source line — always at the end of the text it supports */
.afx-src{margin:8px 0 0;padding-top:8px;border-top:1px dashed var(--color-border,#E1E6EC);display:block;font-size:12px;line-height:1.6;color:var(--color-text-faint,#5F6B7E)}
.afx-src i{width:13px;height:13px;vertical-align:-2px;margin-inline-end:4px}
.afx-src-k{font-weight:700}
.afx-src a{color:var(--st-ev);text-decoration:underline;text-underline-offset:2px;overflow-wrap:anywhere}
.afx-src-d{display:inline-block;margin-inline-start:8px;font-variant-numeric:tabular-nums;direction:ltr}

/* groups + tiles */
.afx-group{margin-top:22px}
.afx-group-h{cursor:pointer;list-style:none;display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:16px;margin:0 0 10px;padding:10px 14px;border-radius:12px}
.afx-group-h i{width:18px;height:18px}
.afx-group-h em{font-style:normal;font-size:12px;background:rgba(255,255,255,.7);border-radius:999px;padding:1px 9px}
.afx-group-h small{flex-basis:100%;font-size:12.5px;font-weight:500;opacity:.85}
.afx-group--free .afx-group-h{background:var(--st-free-bg);color:var(--st-free)}
.afx-group--arrival .afx-group-h{background:var(--st-arr-bg);color:var(--st-arr)}
.afx-group--evisa .afx-group-h{background:var(--st-ev-bg);color:var(--st-ev)}
.afx-group--required .afx-group-h{background:var(--st-req-bg);color:var(--st-req)}
.afx-tiles{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:12px}
.afx-tile{background:#fff;border:1px solid var(--color-border,#E1E6EC);border-radius:14px;padding:12px 14px;display:flex;flex-direction:column;gap:6px;border-inline-start:4px solid var(--st-un)}
.afx-group--free .afx-tile{border-inline-start-color:var(--st-free)}
.afx-group--arrival .afx-tile{border-inline-start-color:var(--st-arr)}
.afx-group--evisa .afx-tile{border-inline-start-color:var(--st-ev)}
.afx-group--required .afx-tile{border-inline-start-color:var(--st-req)}
.afx-tile header{display:flex;align-items:center;gap:8px}
.afx-tile h4{margin:0;font-size:15px;color:var(--color-secondary,#0B3D6B)}
.afx-mono{font-size:11px;font-weight:800;letter-spacing:.04em;background:var(--color-secondary,#0B3D6B);color:#fff;border-radius:8px;padding:4px 6px;direction:ltr}
.afx-tile .afx-summary{font-size:13px;line-height:1.85}
.afx-clamp{display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.afx-tile.is-open .afx-clamp{-webkit-line-clamp:unset;display:block}
.afx-more{align-self:flex-start;border:0;background:none;padding:0;font:inherit;font-size:12.5px;font-weight:700;color:var(--st-ev);cursor:pointer}
.afx-tile .afx-src{margin-top:auto}

.afx-empty{display:flex;gap:8px;align-items:center;justify-content:center;padding:32px;color:var(--color-text-muted,#55627A)}
.afx-empty[hidden]{display:none}
.afx-urgent{font-size:13.5px;margin-top:18px}

/* dialog */
.afx-dialog{border:0;padding:0;border-radius:20px;width:min(760px,calc(100vw - 24px));max-height:calc(100vh - 32px);overflow:hidden;box-shadow:0 24px 70px rgba(7,27,56,.4);background:#fff;color:var(--color-text,#1A2233)}
.afx-dialog[open]{display:flex;flex-direction:column}
.afx-dialog::backdrop{background:rgba(7,27,56,.6)}
.afx-dlg-head{position:relative;flex:none;min-height:150px;background-size:cover;background-position:center;background-color:#10305A;color:#fff;padding:14px 18px;display:flex;flex-direction:column;justify-content:space-between}
.afx-dlg-head h2{margin:12px 0 0;font-size:26px;color:#fff;text-shadow:0 1px 8px rgba(0,0,0,.6)}
.afx-close{position:absolute;top:10px;inset-inline-end:10px;width:36px;height:36px;border-radius:50%;border:0;background:rgba(255,255,255,.92);color:#10305A;cursor:pointer;display:grid;place-items:center}
.afx-dlg-head .afx-card-tags{padding-inline-end:48px}
.afx-dlg-body{overflow:auto;padding:16px 18px 22px;display:flex;flex-direction:column;gap:12px}
.afx-block{border:1px solid var(--color-border,#E1E6EC);border-radius:14px;padding:12px 14px;background:#fff}
.afx-block h3{display:flex;align-items:center;gap:8px;font-size:15px;margin:0 0 8px;color:var(--color-secondary,#0B3D6B)}
.afx-block h3 i{width:17px;height:17px;color:var(--color-primary,#F37021)}
.afx-block p{margin:0;font-size:14px;line-height:2}
.afx-block--status{background:var(--st-ev-bg);border-color:#C5DDF2}
.afx-block--warn{background:#FFF7E8;border-color:#F3D9A0}
.afx-block--warn h3 i{color:#B26B00}
.afx-entry+.afx-entry{margin-top:10px;padding-top:10px;border-top:1px solid var(--color-border,#E1E6EC)}
.afx-fee{font-size:22px!important;font-weight:800;color:var(--color-secondary,#0B3D6B);line-height:1.4!important}
.afx-fee small{font-size:13px;font-weight:600;color:var(--color-text-muted,#55627A)}
html:has(dialog[open]){overflow:hidden}
@media (max-width:640px){
  .afx-main{padding-inline:12px}
  .afx-cards{grid-template-columns:1fr}
  .afx-dialog{width:100vw;max-height:100dvh;height:100dvh;border-radius:0}
  .afx-search{flex:1 1 100%}
}
@media (prefers-reduced-motion:reduce){.afx-card{transition:none}.afx-card:hover{transform:none}}

.afx-group-h::-webkit-details-marker{display:none}
.afx-chev{margin-inline-start:auto;transition:transform .2s}
.afx-group[open]>.afx-group-h .afx-chev{transform:rotate(180deg)}
.afx-group[open]>.afx-group-h{margin-bottom:10px}
.afx-src-k{margin-inline-end:4px}

/* hero banner + review date */
.afx-hero{position:relative;border-radius:20px;padding:22px 22px 18px;margin-bottom:16px;color:#fff;background:linear-gradient(135deg,rgba(11,35,68,.92),rgba(11,35,68,.78)),var(--afx-hero,none);background-size:cover;background-position:center}
.afx-hero .afx-title{color:#fff}
.afx-hero .afx-lead{color:#DCE7F6}
.afx-hero .afx-eyebrow{color:#FFD9B8}
.afx-reviewed{display:flex;width:fit-content;color:#fff;align-items:center;gap:6px;margin:0 0 8px;font-size:12.5px;background:rgba(255,255,255,.14);border:1px solid rgba(255,255,255,.3);border-radius:999px;padding:4px 12px}
.afx-reviewed i{width:14px;height:14px}
.afx-hero .afx-stats li{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.25)}
.afx-hero .afx-stats b{color:#fff}.afx-hero .afx-stats span{color:#DCE7F6}

/* page tabs */
.afx-ptabs{display:flex;gap:6px;padding:6px;margin:6px 0 18px;border:1px solid var(--color-border,#E1E6EC);border-radius:16px;background:#fff;box-shadow:0 4px 18px rgba(11,35,68,.07);overflow-x:auto}
.afx-ptab{flex:1 1 auto;display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;border:0;border-radius:12px;padding:11px 16px;font:inherit;font-size:14.5px;font-weight:700;color:var(--color-text-muted,#55627A);background:none;cursor:pointer;position:relative}
.afx-ptab i{width:18px;height:18px}
.afx-ptab em{font-style:normal;font-size:12px;background:var(--color-card,#F5F7FA);border-radius:999px;padding:1px 8px}
.afx-ptab:hover{background:var(--color-card,#F5F7FA)}
.afx-ptab[aria-selected=true]{background:linear-gradient(135deg,#10305A,#1B4A86);color:#fff;box-shadow:0 6px 16px rgba(16,48,90,.28)}
.afx-ptab[aria-selected=true] em{background:#F7843F;color:#2A1300}
.afx-ptab[aria-selected=true]::after{content:"";position:absolute;inset-inline:22%;bottom:3px;height:3px;border-radius:3px;background:#F7843F}
.afx-tpanel[hidden]{display:none}
.afx-tpanel{animation:afxIn .25s ease both}
@keyframes afxIn{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}

/* docs tab */
.afx-docs{display:grid;grid-template-columns:repeat(auto-fill,minmax(340px,1fr));gap:16px}
.afx-doc{background:#fff;border:1px solid var(--color-border,#E1E6EC);border-radius:16px;overflow:hidden}
.afx-doc>header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:12px 14px;color:#fff;background-size:cover;background-position:center;background-color:#10305A;min-height:64px;box-shadow:inset 0 0 0 100px rgba(7,27,56,.55)}
.afx-doc>header h3{margin:0;font-size:18px;color:#fff}
.afx-doc-body{padding:12px 14px 14px}
.afx-doc-body p{margin:0;font-size:14px;line-height:2}

/* FAQ */
.afx-faq{display:grid;gap:8px;max-width:820px}
.afx-faq details{background:#fff;border:1px solid var(--color-border,#E1E6EC);border-radius:14px;padding:0 16px}
.afx-faq summary{cursor:pointer;list-style:none;display:flex;justify-content:space-between;align-items:center;gap:10px;padding:14px 0;font-weight:800;color:var(--color-secondary,#0B3D6B)}
.afx-faq summary::-webkit-details-marker{display:none}
.afx-faq details[open] summary i{transform:rotate(180deg)}
.afx-faq summary i{width:18px;height:18px;transition:transform .2s}
.afx-faq p{margin:0 0 14px;font-size:14px;line-height:2}

/* sources */
.afx-srclist{margin:0;padding-inline-start:22px;display:grid;gap:12px;max-width:900px}
.afx-srclist li{background:#fff;border:1px solid var(--color-border,#E1E6EC);border-radius:12px;padding:10px 14px;display:flex;flex-direction:column;gap:2px}
.afx-srclist a{font-weight:800;color:var(--st-ev);overflow-wrap:anywhere}
.afx-srcurl{font-size:12px;color:var(--color-text-faint,#5F6B7E);overflow-wrap:anywhere}
.afx-srcfor{font-size:12.5px;color:var(--color-text-muted,#55627A)}
@media (max-width:640px){.afx-docs{grid-template-columns:1fr}.afx-ptab{flex:none}}

/* ── v4: bidi-safe source line, line-by-line lists, hero search ── */
.afx-src{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 10px;margin:10px 0 0;padding-top:8px;border-top:1px dashed var(--color-border,#E1E6EC);font-size:12px;line-height:1.7;color:var(--color-text-faint,#5F6B7E);unicode-bidi:isolate}
.afx-src-k{display:inline-flex;align-items:center;gap:4px;font-weight:700;margin:0}
.afx-src-k i{width:13px;height:13px}
.afx-src-t{flex:1 1 auto;min-width:0;overflow-wrap:anywhere;unicode-bidi:isolate}
.afx-src-d{flex:0 0 auto;margin:0;padding:1px 8px;border-radius:999px;background:#EEF2F8;color:#33445f;direction:ltr;unicode-bidi:isolate;font-variant-numeric:tabular-nums}
.afx-lines{list-style:none;margin:0 0 4px;padding:0;display:grid;gap:6px}
.afx-lines li{position:relative;padding-inline-start:20px;line-height:1.85;font-size:14px;color:var(--color-text,#1B2A41)}
.afx-lines li::before{content:"";position:absolute;inset-inline-start:4px;top:.85em;width:6px;height:6px;border-radius:50%;background:var(--st-ev,#2563eb)}
.afx-lines li.afx-lines-h{padding-inline-start:0;font-weight:800;margin-top:4px}
.afx-lines li.afx-lines-h::before{display:none}
.afx-lines li:not(.afx-lines-h) bdi,.afx-lines li{unicode-bidi:plaintext}
.afx-hsearch{position:relative;display:flex;align-items:center;max-width:640px;margin:0 0 16px}
.afx-hsearch i{position:absolute;inset-inline-start:16px;width:20px;height:20px;color:#5b6b85;pointer-events:none}
.afx-hsearch input{width:100%;font:inherit;font-size:15px;padding:15px 18px 15px 18px;padding-inline-start:46px;border-radius:14px;border:2px solid transparent;background:#fff;color:#0b2344;box-shadow:0 8px 24px rgba(0,0,0,.18)}
.afx-hsearch input:focus{outline:none;border-color:#FFB26B}
.afx-toolbar .afx-search{display:none}
.afx-toolbar{justify-content:flex-start}


/* ---- Destination dialog: same tab structure as the country pages ---- */
.afx-dialog{width:min(880px,calc(100vw - 24px))}
.afx-dlg-head{min-height:130px}
.afx-dtabs{flex:none;display:flex;gap:6px;padding:6px;margin:12px 18px 0;border-radius:14px;background:#F3F6FB;overflow-x:auto}
.afx-dtab{flex:1 1 auto;display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:42px;padding:0 16px;border:0;border-radius:10px;background:none;font:inherit;font-weight:700;font-size:14.5px;color:#4A5B73;cursor:pointer;white-space:nowrap}
.afx-dtab i,.afx-dtab svg{width:17px;height:17px;flex:none}
.afx-dtab:hover{background:#fff;color:#0B2344}
.afx-dtab[aria-selected="true"]{background:linear-gradient(135deg,#10305A,#1B4A86);color:#fff;box-shadow:0 4px 12px rgba(16,48,90,.22)}
.afx-dtab:focus-visible{outline:3px solid #F7843F;outline-offset:2px}
.afx-dpanel{display:flex;flex-direction:column;gap:12px}
.afx-dpanel[hidden]{display:none}
.afx-block{border-radius:16px;padding:16px 18px}
.afx-block h3{font-size:16px;margin:0 0 10px}
.afx-entry+.afx-entry{margin-top:12px;padding-top:12px;border-top:1px dashed #D9E1EC}
.afx-fee{font-size:22px;font-weight:800;color:#0B2344;margin:0 0 6px}
@media(max-width:560px){.afx-dtabs{margin:10px 12px 0}.afx-dtab{padding:0 12px;flex:none}}
