/* === FLAG-ICONS — SELF-HOSTED CSS-ONLY (no Cloudflare, no remote font, no <img>) === */
/* Pure CSS flags using gradients. Covers ISO 3166-1 alpha-2 codes used by DHRU's */
/* language + country tables. Every flag is rendered via background gradients and */
/* pseudo-element emblems — zero network requests, zero external assets. */

.flag, .fi {
    display: inline-block;
    width: 1.45em;
    height: 1.05em;
    vertical-align: -0.175em;
    background-color: #ccc;
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 2px;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
    line-height: 1em;
    position: relative;
    overflow: hidden;
    text-align: center;
}
.flag.flag-rounded, .fi.fi-rounded { border-radius: 50%; }
.flag.flag-square, .fi.fi-square { width: 1.05em; }

/* ===================== ARAB / MIDDLE EAST ============================ */
.flag-ae, .fi-ae {
    background:
        linear-gradient(to right, #ce1126 0 25%, transparent 25%),
        linear-gradient(to bottom, #00732f 33.33%, #fff 33.33% 66.66%, #000 66.66%);
}
.flag-sa, .fi-sa { background: #006c35; }
.flag-sa::after, .fi-sa::after {
    content: ""; position: absolute; left: 12%; right: 12%; top: 38%; height: 24%;
    background: linear-gradient(to bottom, #fff 25%, transparent 25% 75%, #fff 75%);
    opacity: .85;
}
.flag-eg, .fi-eg { background: linear-gradient(to bottom, #ce1126 33.33%, #fff 33.33% 66.66%, #000 66.66%); }
.flag-iq, .fi-iq { background: linear-gradient(to bottom, #ce1126 33.33%, #fff 33.33% 66.66%, #000 66.66%); }
.flag-jo, .fi-jo {
    background:
        linear-gradient(to right, #ce1126 0 28%, transparent 28%),
        linear-gradient(to bottom, #000 33.33%, #fff 33.33% 66.66%, #007a3d 66.66%);
}
.flag-kw, .fi-kw {
    background:
        linear-gradient(to right, #000 0 22%, transparent 22%),
        linear-gradient(to bottom, #007a3d 33.33%, #fff 33.33% 66.66%, #ce1126 66.66%);
}
.flag-lb, .fi-lb {
    background: linear-gradient(to bottom, #ed1c24 25%, #fff 25% 75%, #ed1c24 75%);
}
.flag-lb::after, .fi-lb::after {
    content: ""; position: absolute; left: 42%; right: 42%; top: 38%; height: 24%;
    background: #007a3d; border-radius: 50%;
}
.flag-ly, .fi-ly { background: linear-gradient(to bottom, #e30a17 25%, #000 25% 75%, #007a3d 75%); }
.flag-ma, .fi-ma { background: #c1272d; }
.flag-ma::after, .fi-ma::after {
    content: "★"; position: absolute; inset: 0; color: #006233;
    font-size: .9em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-om, .fi-om {
    background:
        linear-gradient(to right, #db161b 0 30%, transparent 30%),
        linear-gradient(to bottom, #fff 33.33%, #db161b 33.33% 66.66%, #008000 66.66%);
}
.flag-ps, .fi-ps {
    background:
        linear-gradient(to right, #ce1126 0 25%, transparent 25%),
        linear-gradient(to bottom, #000 33.33%, #fff 33.33% 66.66%, #007a3d 66.66%);
}
.flag-qa, .fi-qa { background: #8d1b3d; }
.flag-qa::before, .fi-qa::before {
    content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 30%;
    background: linear-gradient(to right, #fff 100%, transparent 100%);
}
.flag-sy, .fi-sy {
    background: linear-gradient(to bottom, #ce1126 33.33%, #fff 33.33% 66.66%, #000 66.66%);
}
.flag-sy::after, .fi-sy::after {
    content: "★ ★"; position: absolute; inset: 33% 0 33% 0; color: #007a3d;
    font-size: .55em; line-height: 1em; display: flex; align-items: center; justify-content: center; letter-spacing: .3em;
}
.flag-ye, .fi-ye { background: linear-gradient(to bottom, #ce1126 33.33%, #fff 33.33% 66.66%, #000 66.66%); }
.flag-bh, .fi-bh {
    background: linear-gradient(to right, #fff 0 30%, #ce1126 30%);
}
.flag-tn, .fi-tn { background: #e70013; }
.flag-tn::after, .fi-tn::after {
    content: ""; position: absolute; left: 36%; right: 36%; top: 28%; bottom: 28%;
    background: #fff; border-radius: 50%;
}

/* ===================== EUROPE ======================================== */
.flag-gb, .fi-gb, .flag-uk, .fi-uk {
    background:
        linear-gradient(to bottom, transparent 42%, #c8102e 42% 58%, transparent 58%),
        linear-gradient(to right,  transparent 42%, #c8102e 42% 58%, transparent 58%),
        linear-gradient(to bottom, transparent 35%, #fff 35% 65%, transparent 65%),
        linear-gradient(to right,  transparent 35%, #fff 35% 65%, transparent 65%),
        linear-gradient( 30deg, transparent 47%, #c8102e 47% 53%, transparent 53%),
        linear-gradient(150deg, transparent 47%, #c8102e 47% 53%, transparent 53%),
        linear-gradient( 30deg, transparent 42%, #fff 42% 58%, transparent 58%),
        linear-gradient(150deg, transparent 42%, #fff 42% 58%, transparent 58%),
        #012169;
    background-size: 100% 100%;
    background-repeat: no-repeat;
}
.flag-fr, .fi-fr { background: linear-gradient(to right, #002395 33.33%, #fff 33.33% 66.66%, #ed2939 66.66%); }
.flag-de, .fi-de { background: linear-gradient(to bottom, #000 33.33%, #dd0000 33.33% 66.66%, #ffce00 66.66%); }
.flag-it, .fi-it { background: linear-gradient(to right, #009246 33.33%, #fff 33.33% 66.66%, #ce2b37 66.66%); }
.flag-es, .fi-es {
    background: linear-gradient(to bottom, #aa151b 25%, #f1bf00 25% 75%, #aa151b 75%);
}
.flag-pt, .fi-pt { background: linear-gradient(to right, #006600 40%, #ff0000 40%); }
.flag-pt::after, .fi-pt::after {
    content: ""; position: absolute; left: 32%; top: 30%; width: 18%; height: 40%;
    background: #ffcb00; border-radius: 50%; box-shadow: inset 0 0 0 1.5px #fff;
}
.flag-nl, .fi-nl { background: linear-gradient(to bottom, #ae1c28 33.33%, #fff 33.33% 66.66%, #21468b 66.66%); }
.flag-be, .fi-be { background: linear-gradient(to right, #000 33.33%, #ffd90c 33.33% 66.66%, #ed2939 66.66%); }
.flag-lu, .fi-lu { background: linear-gradient(to bottom, #ed2939 33.33%, #fff 33.33% 66.66%, #00a1de 66.66%); }
.flag-ch, .fi-ch { background: #ff0000; }
.flag-ch::after, .fi-ch::after {
    content: ""; position: absolute; inset: 25%;
    background:
        linear-gradient(#fff 0 0) center / 60% 22% no-repeat,
        linear-gradient(#fff 0 0) center / 22% 60% no-repeat;
}
.flag-at, .fi-at { background: linear-gradient(to bottom, #ed2939 33.33%, #fff 33.33% 66.66%, #ed2939 66.66%); }
.flag-pl, .fi-pl { background: linear-gradient(to bottom, #fff 50%, #dc143c 50%); }
.flag-cz, .fi-cz {
    background:
        linear-gradient(to bottom right, #11457e 0 50%, transparent 50.1%),
        linear-gradient(to bottom, #fff 50%, #d7141a 50%);
}
.flag-sk, .fi-sk { background: linear-gradient(to bottom, #fff 33.33%, #0b4ea2 33.33% 66.66%, #ee1c25 66.66%); }
.flag-hu, .fi-hu { background: linear-gradient(to bottom, #ce2939 33.33%, #fff 33.33% 66.66%, #477050 66.66%); }
.flag-ro, .fi-ro { background: linear-gradient(to right, #002b7f 33.33%, #fcd116 33.33% 66.66%, #ce1126 66.66%); }
.flag-bg, .fi-bg { background: linear-gradient(to bottom, #fff 33.33%, #00966e 33.33% 66.66%, #d62612 66.66%); }
.flag-gr, .fi-gr {
    background:
        linear-gradient(to bottom,
            #0d5eaf 0 11.1%, #fff 11.1% 22.2%,
            #0d5eaf 22.2% 33.3%, #fff 33.3% 44.4%,
            #0d5eaf 44.4% 55.5%, #fff 55.5% 66.6%,
            #0d5eaf 66.6% 77.7%, #fff 77.7% 88.8%,
            #0d5eaf 88.8%
        );
}
.flag-gr::before, .fi-gr::before {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 55.5%;
    background: #0d5eaf;
}
.flag-gr::after, .fi-gr::after {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 55.5%;
    background:
        linear-gradient(#fff 0 0) center / 60% 18% no-repeat,
        linear-gradient(#fff 0 0) center / 18% 60% no-repeat;
}
.flag-tr, .fi-tr { background: #e30a17; }
.flag-tr::before, .fi-tr::before {
    content: ""; position: absolute; left: 22%; top: 24%; width: 36%; height: 52%;
    background: #fff; border-radius: 50%;
}
.flag-tr::after, .fi-tr::after {
    content: ""; position: absolute; left: 28%; top: 26%; width: 32%; height: 48%;
    background: #e30a17; border-radius: 50%;
}
.flag-ru, .fi-ru { background: linear-gradient(to bottom, #fff 33.33%, #0039a6 33.33% 66.66%, #d52b1e 66.66%); }
.flag-ua, .fi-ua { background: linear-gradient(to bottom, #005bbb 50%, #ffd500 50%); }
.flag-by, .fi-by { background: linear-gradient(to bottom, #c8313e 60%, #007c30 60%); }
.flag-md, .fi-md { background: linear-gradient(to right, #003da5 33.33%, #ffd200 33.33% 66.66%, #cf0921 66.66%); }
.flag-lt, .fi-lt { background: linear-gradient(to bottom, #fdb913 33.33%, #006a44 33.33% 66.66%, #c1272d 66.66%); }
.flag-lv, .fi-lv { background: linear-gradient(to bottom, #9d2235 40%, #fff 40% 60%, #9d2235 60%); }
.flag-ee, .fi-ee { background: linear-gradient(to bottom, #0072ce 33.33%, #000 33.33% 66.66%, #fff 66.66%); }
.flag-fi, .fi-fi { background: #fff; }
.flag-fi::after, .fi-fi::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#003580 0 0) 35% 0 / 22% 100% no-repeat,
        linear-gradient(#003580 0 0) 0 50% / 100% 32% no-repeat;
}
.flag-se, .fi-se { background: #006aa7; }
.flag-se::after, .fi-se::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#fecc00 0 0) 35% 0 / 22% 100% no-repeat,
        linear-gradient(#fecc00 0 0) 0 50% / 100% 32% no-repeat;
}
.flag-no, .fi-no { background: #ba0c2f; }
.flag-no::before, .fi-no::before {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#fff 0 0) 35% 0 / 32% 100% no-repeat,
        linear-gradient(#fff 0 0) 0 50% / 100% 42% no-repeat;
}
.flag-no::after, .fi-no::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#00205b 0 0) 38% 0 / 12% 100% no-repeat,
        linear-gradient(#00205b 0 0) 0 50% / 100% 18% no-repeat;
}
.flag-dk, .fi-dk { background: #c8102e; }
.flag-dk::after, .fi-dk::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#fff 0 0) 35% 0 / 18% 100% no-repeat,
        linear-gradient(#fff 0 0) 0 50% / 100% 25% no-repeat;
}
.flag-is, .fi-is { background: #02529c; }
.flag-is::before, .fi-is::before {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#fff 0 0) 35% 0 / 28% 100% no-repeat,
        linear-gradient(#fff 0 0) 0 50% / 100% 38% no-repeat;
}
.flag-is::after, .fi-is::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#dc1e35 0 0) 38% 0 / 12% 100% no-repeat,
        linear-gradient(#dc1e35 0 0) 0 50% / 100% 18% no-repeat;
}
.flag-ie, .fi-ie { background: linear-gradient(to right, #009a44 33.33%, #fff 33.33% 66.66%, #ff7900 66.66%); }
.flag-al, .fi-al { background: #e41e20; }
.flag-al::after, .fi-al::after {
    content: "✦"; position: absolute; inset: 0; color: #000;
    font-size: 1.1em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-mk, .fi-mk { background: #d20000; }
.flag-mk::after, .fi-mk::after {
    content: ""; position: absolute; left: 36%; top: 28%; width: 28%; height: 44%;
    background: #f8e92e; border-radius: 50%;
}
.flag-rs, .fi-rs { background: linear-gradient(to bottom, #c6363c 33.33%, #0c4076 33.33% 66.66%, #fff 66.66%); }
.flag-ba, .fi-ba { background: #002395; }
.flag-ba::after, .fi-ba::after {
    content: ""; position: absolute; left: 8%; top: 18%; width: 24%; height: 64%;
    background: #fecb00; transform: skewX(-20deg);
}
.flag-hr, .fi-hr { background: linear-gradient(to bottom, #ff0000 33.33%, #fff 33.33% 66.66%, #171796 66.66%); }
.flag-si, .fi-si { background: linear-gradient(to bottom, #fff 33.33%, #0000c3 33.33% 66.66%, #c00 66.66%); }
.flag-me, .fi-me { background: #c40308; box-shadow: inset 0 0 0 2px #d4af37, inset 0 0 0 3px rgba(0,0,0,.1); }
.flag-cy, .fi-cy { background: #fff; }
.flag-cy::after, .fi-cy::after {
    content: ""; position: absolute; left: 35%; right: 35%; top: 30%; height: 35%;
    background: #d57800;
}
.flag-mt, .fi-mt { background: linear-gradient(to right, #fff 50%, #c01b22 50%); }
.flag-va, .fi-va { background: linear-gradient(to right, #ffe000 50%, #fff 50%); }
.flag-sm, .fi-sm { background: linear-gradient(to bottom, #fff 50%, #5eb6e4 50%); }
.flag-li, .fi-li { background: linear-gradient(to bottom, #002b7f 50%, #ce1126 50%); }
.flag-mc, .fi-mc { background: linear-gradient(to bottom, #ce1126 50%, #fff 50%); }
.flag-ad, .fi-ad { background: linear-gradient(to right, #10069f 33.33%, #fedf00 33.33% 66.66%, #d52b1e 66.66%); }

/* ===================== AMERICAS ====================================== */
.flag-us, .fi-us {
    background:
        linear-gradient(to bottom,
            #b22234 0 7.69%, #fff 7.69% 15.38%,
            #b22234 15.38% 23.08%, #fff 23.08% 30.77%,
            #b22234 30.77% 38.46%, #fff 38.46% 46.15%,
            #b22234 46.15% 53.85%, #fff 53.85% 61.54%,
            #b22234 61.54% 69.23%, #fff 69.23% 76.92%,
            #b22234 76.92% 84.62%, #fff 84.62% 92.31%,
            #b22234 92.31%
        );
}
.flag-us::after, .fi-us::after {
    content: ""; position: absolute; left: 0; top: 0; width: 40%; height: 53.85%;
    background: #3c3b6e;
}
.flag-ca, .fi-ca {
    background:
        linear-gradient(to right, #d52b1e 0 25%, transparent 25% 75%, #d52b1e 75%);
    background-color: #fff;
}
.flag-ca::after, .fi-ca::after {
    content: "🍁"; position: absolute; inset: 0; color: #d52b1e;
    font-size: .8em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-mx, .fi-mx { background: linear-gradient(to right, #006847 33.33%, #fff 33.33% 66.66%, #ce1126 66.66%); }
.flag-br, .fi-br { background: #009c3b; }
.flag-br::before, .fi-br::before {
    content: ""; position: absolute; left: 12%; top: 18%; right: 12%; bottom: 18%;
    background: #ffdf00; transform: skewX(-20deg);
}
.flag-br::after, .fi-br::after {
    content: ""; position: absolute; left: 32%; right: 32%; top: 28%; bottom: 28%;
    background: #002776; border-radius: 50%;
}
.flag-ar, .fi-ar { background: linear-gradient(to bottom, #6caedd 33.33%, #fff 33.33% 66.66%, #6caedd 66.66%); }
.flag-cl, .fi-cl {
    background:
        linear-gradient(to right, #0039a6 0 35%, transparent 35%),
        linear-gradient(to bottom, #fff 50%, #d52b1e 50%);
}
.flag-co, .fi-co { background: linear-gradient(to bottom, #fcd116 50%, #003893 50% 75%, #ce1126 75%); }
.flag-pe, .fi-pe { background: linear-gradient(to right, #d91023 33.33%, #fff 33.33% 66.66%, #d91023 66.66%); }
.flag-ve, .fi-ve { background: linear-gradient(to bottom, #ffcc00 33.33%, #00247d 33.33% 66.66%, #cf142b 66.66%); }
.flag-uy, .fi-uy { background: linear-gradient(to bottom, #fff 11%, #0038a8 11% 22%, #fff 22% 33%, #0038a8 33% 44%, #fff 44% 55%, #0038a8 55% 66%, #fff 66% 77%, #0038a8 77% 88%, #fff 88%); }
.flag-ec, .fi-ec { background: linear-gradient(to bottom, #ffdd00 50%, #0072ce 50% 75%, #ce1126 75%); }
.flag-bo, .fi-bo { background: linear-gradient(to bottom, #d52b1e 33.33%, #f9e300 33.33% 66.66%, #007a33 66.66%); }
.flag-py, .fi-py { background: linear-gradient(to bottom, #d52b1e 33.33%, #fff 33.33% 66.66%, #0038a8 66.66%); }
.flag-cu, .fi-cu {
    background:
        linear-gradient(to right, #cf142b 0 30%, transparent 30%),
        linear-gradient(to bottom, #002a8f 20%, #fff 20% 40%, #002a8f 40% 60%, #fff 60% 80%, #002a8f 80%);
}
.flag-do, .fi-do { background: linear-gradient(to right, #002d62 50%, #ce1126 50%); }
.flag-ht, .fi-ht { background: linear-gradient(to bottom, #00209f 50%, #d21034 50%); }
.flag-jm, .fi-jm {
    background:
        linear-gradient(to bottom right, #009b3a 0 50%, #000 50.1%),
        linear-gradient(to bottom left, #fed100 50%, transparent 50%);
}
.flag-pa, .fi-pa { background: linear-gradient(to right, #fff 50%, #d21034 50%); }
.flag-cr, .fi-cr { background: linear-gradient(to bottom, #002b7f 20%, #fff 20% 33%, #ce1126 33% 66%, #fff 66% 80%, #002b7f 80%); }
.flag-ni, .fi-ni { background: linear-gradient(to bottom, #0067c6 33.33%, #fff 33.33% 66.66%, #0067c6 66.66%); }
.flag-gt, .fi-gt { background: linear-gradient(to right, #4997d0 33.33%, #fff 33.33% 66.66%, #4997d0 66.66%); }
.flag-hn, .fi-hn { background: linear-gradient(to bottom, #0073cf 33.33%, #fff 33.33% 66.66%, #0073cf 66.66%); }
.flag-sv, .fi-sv { background: linear-gradient(to bottom, #0047ab 33.33%, #fff 33.33% 66.66%, #0047ab 66.66%); }

/* ===================== ASIA / PACIFIC ================================ */
.flag-cn, .fi-cn { background: #de2910; }
.flag-cn::after, .fi-cn::after {
    content: "★"; position: absolute; left: 16%; top: 24%; color: #ffde00;
    font-size: 1.2em; line-height: 1em;
}
.flag-cn::before, .fi-cn::before {
    content: "★★★★"; position: absolute; left: 36%; top: 16%; color: #ffde00;
    font-size: .35em; line-height: 1.1em; letter-spacing: .15em; width: 40%;
}
.flag-jp, .fi-jp { background: #fff; }
.flag-jp::after, .fi-jp::after {
    content: ""; position: absolute; left: 33%; top: 22%; width: 34%; height: 56%;
    background: #bc002d; border-radius: 50%;
}
.flag-kr, .fi-kr { background: #fff; }
.flag-kr::after, .fi-kr::after {
    content: ""; position: absolute; left: 38%; top: 25%; width: 24%; height: 50%;
    background: linear-gradient(to bottom, #c60c30 50%, #003478 50%); border-radius: 50%;
}
.flag-kp, .fi-kp { background: linear-gradient(to bottom, #024fa2 22%, #fff 22% 28%, #ed1c27 28% 72%, #fff 72% 78%, #024fa2 78%); }
.flag-vn, .fi-vn { background: #da251d; }
.flag-vn::after, .fi-vn::after {
    content: "★"; position: absolute; inset: 0; color: #ff0;
    font-size: 1.3em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-th, .fi-th { background: linear-gradient(to bottom, #ed1c24 17%, #fff 17% 33%, #241d4f 33% 67%, #fff 67% 83%, #ed1c24 83%); }
.flag-id, .fi-id { background: linear-gradient(to bottom, #ff0000 50%, #fff 50%); }
.flag-my, .fi-my {
    background:
        linear-gradient(to bottom,
            #cc0001 0 7.14%, #fff 7.14% 14.29%,
            #cc0001 14.29% 21.43%, #fff 21.43% 28.57%,
            #cc0001 28.57% 35.71%, #fff 35.71% 42.86%,
            #cc0001 42.86% 50%, #fff 50% 57.14%,
            #cc0001 57.14% 64.29%, #fff 64.29% 71.43%,
            #cc0001 71.43% 78.57%, #fff 78.57% 85.71%,
            #cc0001 85.71% 92.86%, #fff 92.86%
        );
}
.flag-my::before, .fi-my::before {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 57.14%;
    background: #010066;
}
.flag-ph, .fi-ph {
    background:
        linear-gradient(to right, #0038a8 0 40%, transparent 40%),
        linear-gradient(to bottom, #0038a8 50%, #ce1126 50%);
}
.flag-sg, .fi-sg { background: linear-gradient(to bottom, #ef3340 50%, #fff 50%); }
.flag-tw, .fi-tw { background: #fe0000; }
.flag-tw::before, .fi-tw::before {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 60%;
    background: #000095;
}
.flag-tw::after, .fi-tw::after {
    content: "✱"; position: absolute; left: 16%; top: 22%; color: #fff;
    font-size: .9em; line-height: 1em;
}
.flag-hk, .fi-hk { background: #de2910; }
.flag-hk::after, .fi-hk::after {
    content: "❀"; position: absolute; inset: 0; color: #fff;
    font-size: 1em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-mo, .fi-mo { background: #00785a; }
.flag-mo::after, .fi-mo::after {
    content: "✿"; position: absolute; inset: 0; color: #fff;
    font-size: .9em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-in, .fi-in {
    background: linear-gradient(to bottom, #ff9933 33.33%, #fff 33.33% 66.66%, #138808 66.66%);
}
.flag-in::after, .fi-in::after {
    content: ""; position: absolute; left: 42%; right: 42%; top: 40%; height: 20%;
    background: #000080; border-radius: 50%;
}
.flag-pk, .fi-pk { background: linear-gradient(to right, #fff 25%, #01411c 25%); }
.flag-pk::after, .fi-pk::after {
    content: "☪"; position: absolute; right: 12%; top: 5%; color: #fff;
    font-size: 1.1em; line-height: 1em;
}
.flag-bd, .fi-bd { background: #006a4e; }
.flag-bd::after, .fi-bd::after {
    content: ""; position: absolute; left: 40%; right: 44%; top: 28%; bottom: 28%;
    background: #f42a41; border-radius: 50%;
}
.flag-lk, .fi-lk {
    background:
        linear-gradient(to right, #00534e 0 16%, #ffbe29 16% 22%, #8d153a 22% 70%, #ffbe29 70% 76%, #f47216 76% 88%, #ffbe29 88%);
}
.flag-np, .fi-np {
    background:
        linear-gradient(to bottom right, #ce0000 0 50%, transparent 50%),
        linear-gradient(to top right, #ce0000 0 50%, transparent 50%);
    background-color: #003893;
}
.flag-mm, .fi-mm { background: linear-gradient(to bottom, #fecb00 33.33%, #34b233 33.33% 66.66%, #ea2839 66.66%); }
.flag-kh, .fi-kh { background: linear-gradient(to bottom, #032ea1 25%, #e00025 25% 75%, #032ea1 75%); }
.flag-la, .fi-la { background: linear-gradient(to bottom, #ce1126 30%, #002868 30% 70%, #ce1126 70%); }
.flag-mn, .fi-mn { background: linear-gradient(to right, #c4272f 33.33%, #015197 33.33% 66.66%, #c4272f 66.66%); }
.flag-bt, .fi-bt {
    background:
        linear-gradient(to bottom right, #ffcc33 0 50%, #ff4e12 50.1%);
}
.flag-af, .fi-af { background: linear-gradient(to right, #000 33.33%, #be0000 33.33% 66.66%, #007a36 66.66%); }
.flag-ir, .fi-ir { background: linear-gradient(to bottom, #239f40 33.33%, #fff 33.33% 66.66%, #da0000 66.66%); }
.flag-iq, .fi-iq { background: linear-gradient(to bottom, #ce1126 33.33%, #fff 33.33% 66.66%, #000 66.66%); }
.flag-am, .fi-am { background: linear-gradient(to bottom, #d90012 33.33%, #0033a0 33.33% 66.66%, #f2a800 66.66%); }
.flag-az, .fi-az {
    background: linear-gradient(to bottom, #00b9e4 33.33%, #ed2939 33.33% 66.66%, #3f9c35 66.66%);
}
.flag-az::after, .fi-az::after {
    content: "☪"; position: absolute; inset: 0; color: #fff;
    font-size: .85em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-ge, .fi-ge { background: #fff; }
.flag-ge::after, .fi-ge::after {
    content: ""; position: absolute; inset: 0;
    background:
        linear-gradient(#d80027 0 0) 50% 0 / 18% 100% no-repeat,
        linear-gradient(#d80027 0 0) 0 50% / 100% 18% no-repeat;
}
.flag-kz, .fi-kz { background: #00afca; }
.flag-kz::after, .fi-kz::after {
    content: "☀"; position: absolute; inset: 0; color: #fec50c;
    font-size: 1em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-uz, .fi-uz { background: linear-gradient(to bottom, #1eb53a 33.33%, #fff 33.33% 66.66%, #ce1126 66.66%); }
.flag-tj, .fi-tj { background: linear-gradient(to bottom, #cc0000 28%, #fff 28% 72%, #006600 72%); }
.flag-kg, .fi-kg { background: #ff0000; }
.flag-kg::after, .fi-kg::after {
    content: "☀"; position: absolute; inset: 0; color: #ffef00;
    font-size: 1em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-tm, .fi-tm { background: linear-gradient(to right, #00853e 0 80%, #ce1126 80%); }
.flag-au, .fi-au { background: #00008b; }
.flag-au::before, .fi-au::before {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 50%;
    background:
        linear-gradient(135deg, transparent 45%, #fff 45% 55%, transparent 55%),
        linear-gradient(45deg, transparent 45%, #fff 45% 55%, transparent 55%),
        linear-gradient(to bottom, transparent 40%, #fff 40% 60%, transparent 60%),
        linear-gradient(to right, transparent 40%, #fff 40% 60%, transparent 60%),
        #00008b;
}
.flag-au::after, .fi-au::after {
    content: "★"; position: absolute; right: 18%; top: 40%; color: #fff;
    font-size: .55em; line-height: 1em;
}
.flag-nz, .fi-nz { background: #00247d; }
.flag-nz::before, .fi-nz::before {
    content: ""; position: absolute; left: 0; top: 0; width: 50%; height: 50%;
    background:
        linear-gradient(135deg, transparent 45%, #fff 45% 55%, transparent 55%),
        linear-gradient(45deg, transparent 45%, #fff 45% 55%, transparent 55%),
        #00247d;
}

/* ===================== AFRICA ======================================== */
.flag-za, .fi-za {
    background:
        linear-gradient(to right, #007749 0 28%, transparent 28%),
        linear-gradient(to bottom, #de3831 20%, #fff 20% 40%, #007749 40% 60%, #fff 60% 80%, #002395 80%);
}
.flag-ng, .fi-ng { background: linear-gradient(to right, #008753 33.33%, #fff 33.33% 66.66%, #008753 66.66%); }
.flag-ke, .fi-ke { background: linear-gradient(to bottom, #000 33.33%, #bb0000 33.33% 66.66%, #006600 66.66%); }
.flag-et, .fi-et { background: linear-gradient(to bottom, #078930 33.33%, #fcdd09 33.33% 66.66%, #da121a 66.66%); }
.flag-gh, .fi-gh { background: linear-gradient(to bottom, #ce1126 33.33%, #fcd116 33.33% 66.66%, #006b3f 66.66%); }
.flag-sn, .fi-sn { background: linear-gradient(to right, #00853f 33.33%, #fdef42 33.33% 66.66%, #e31b23 66.66%); }
.flag-ci, .fi-ci { background: linear-gradient(to right, #f77f00 33.33%, #fff 33.33% 66.66%, #009e60 66.66%); }
.flag-cm, .fi-cm { background: linear-gradient(to right, #007a5e 33.33%, #ce1126 33.33% 66.66%, #fcd116 66.66%); }
.flag-mg, .fi-mg {
    background:
        linear-gradient(to right, #fff 0 33%, transparent 33%),
        linear-gradient(to bottom, #fc3d32 50%, #007e3a 50%);
}
.flag-mu, .fi-mu { background: linear-gradient(to bottom, #ea2839 25%, #1a206d 25% 50%, #ffd500 50% 75%, #00a04d 75%); }
.flag-zw, .fi-zw {
    background: linear-gradient(to bottom,
        #319a00 0 14.29%, #fcd116 14.29% 28.57%,
        #df2e38 28.57% 42.86%, #000 42.86% 57.14%,
        #df2e38 57.14% 71.43%, #fcd116 71.43% 85.71%,
        #319a00 85.71%);
}
.flag-zm, .fi-zm { background: #198a00; }
.flag-mz, .fi-mz {
    background:
        linear-gradient(to right, #d21034 0 30%, transparent 30%),
        linear-gradient(to bottom, #007168 25%, #000 25% 33%, #fce100 33% 67%, #000 67% 75%, #d21034 75%);
}
.flag-ao, .fi-ao { background: linear-gradient(to bottom, #ce1126 50%, #000 50%); }
.flag-na, .fi-na { background: #003580; }
.flag-bw, .fi-bw { background: #75aadb; }
.flag-bw::after, .fi-bw::after {
    content: ""; position: absolute; left: 0; right: 0; top: 38%; height: 24%;
    background: linear-gradient(to bottom, #fff 16%, #000 16% 84%, #fff 84%);
}
.flag-dz, .fi-dz { background: linear-gradient(to right, #006633 50%, #fff 50%); }
.flag-dz::after, .fi-dz::after {
    content: "☪"; position: absolute; inset: 0; color: #d21034;
    font-size: .85em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-sd, .fi-sd {
    background:
        linear-gradient(to right, #007229 0 30%, transparent 30%),
        linear-gradient(to bottom, #d21034 33.33%, #fff 33.33% 66.66%, #000 66.66%);
}
.flag-so, .fi-so { background: #4189dd; }
.flag-so::after, .fi-so::after {
    content: "★"; position: absolute; inset: 0; color: #fff;
    font-size: 1.2em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-tz, .fi-tz {
    background:
        linear-gradient(to bottom right, #1eb53a 0 35%, #fcd116 35% 45%, #000 45% 55%, #00a3dd 55%);
}
.flag-ug, .fi-ug {
    background: linear-gradient(to bottom,
        #000 0 16.67%, #fcdc04 16.67% 33.33%,
        #d90000 33.33% 50%, #000 50% 66.67%,
        #fcdc04 66.67% 83.33%, #d90000 83.33%);
}
.flag-rw, .fi-rw { background: linear-gradient(to bottom, #00a1de 50%, #fad201 50% 75%, #20603d 75%); }
.flag-bi, .fi-bi {
    background:
        linear-gradient(to bottom right, #ce1126 0 50%, #1eb53a 50%),
        linear-gradient(to top right, #ce1126 0 50%, #1eb53a 50%);
}
.flag-er, .fi-er {
    background:
        linear-gradient(to bottom right, #ea0437 0 50%, transparent 50%),
        linear-gradient(to top right, #12ad2b 0 50%, transparent 50%),
        #418fde;
}

/* ===================== KNOWN ISO MIXED (LANG MAPPED) ================ */
.flag-kn, .fi-kn {
    background: linear-gradient(135deg, #009e49 0%, #009e49 35%, #ffd100 35% 45%, #000 45% 55%, #ffd100 55% 65%, #ce1126 65%);
}
.flag-il, .fi-il { background: #fff; }
.flag-il::after, .fi-il::after {
    content: "✡"; position: absolute; inset: 0; color: #0038b8;
    font-size: .9em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-il::before, .fi-il::before {
    content: ""; position: absolute; left: 0; right: 0; top: 12%; height: 14%;
    background: #0038b8;
    box-shadow: 0 calc(.6em) 0 0 #0038b8;
}

/* ===================== HEBREW / BENGALI FALLBACK NAMES ============== */
.flag-he, .fi-he { background: #fff; }
.flag-he::after, .fi-he::after {
    content: "✡"; position: absolute; inset: 0; color: #0038b8;
    font-size: .9em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}
.flag-he::before, .fi-he::before {
    content: ""; position: absolute; left: 0; right: 0; top: 12%; height: 14%;
    background: #0038b8;
    box-shadow: 0 .6em 0 0 #0038b8;
}
.flag-bn, .fi-bn { background: #006a4e; }
.flag-bn::after, .fi-bn::after {
    content: ""; position: absolute; left: 40%; right: 44%; top: 28%; bottom: 28%;
    background: #f42a41; border-radius: 50%;
}

/* ===================== FALLBACK FOR UNKNOWN / EMPTY ================ */
.flag-unknown, .fi-unknown, .flag-xx, .fi-xx,
.flag[class$="flag-"], .fi[class$="fi-"] {
    background: linear-gradient(135deg, #94a3b8 0%, #64748b 100%);
}
.flag-unknown::after, .fi-unknown::after,
.flag-xx::after, .fi-xx::after {
    content: "?"; position: absolute; inset: 0; color: #fff;
    font-size: .8em; line-height: 1em; display: flex; align-items: center; justify-content: center;
}

/* dropdown-friendly variant */
.dropdown-item .flag, .dropdown-item .fi { margin-right: 8px; vertical-align: middle; }
