/* MyMegaCalculator Arabic V14 - premium RTL design */
:root{--mmc-green:#16a34a;--mmc-green-dark:#15803d;--mmc-green-soft:#ecfdf3;--mmc-border:#e7ece9;--mmc-text:#0f172a;--mmc-muted:#64748b;--mmc-bg:#f8faf9}
html{scroll-behavior:smooth}
body{background:var(--mmc-bg)!important;color:var(--mmc-text)!important;font-family:Tahoma,"Segoe UI",Arial,sans-serif!important}
header{background:rgba(255,255,255,.96)!important;border-bottom:1px solid var(--mmc-border)!important;box-shadow:0 1px 10px rgba(15,23,42,.04)!important}
header .max-w-6xl{max-width:1320px!important;min-height:76px}
header a[href="/ar/"]>span:last-child{font-size:1.45rem!important;letter-spacing:-.04em}
header a[href="/ar/"]>div{box-shadow:0 8px 18px rgba(22,163,74,.18)!important}
nav[aria-label="breadcrumb"]{background:#fff!important;border-bottom:1px solid var(--mmc-border)!important}

/* Country rail: visible on every Arabic page */
.mmc-country-strip{position:sticky;top:68px;z-index:60;background:rgba(255,255,255,.97);backdrop-filter:blur(12px);border-bottom:1px solid #dfe9e3;box-shadow:0 4px 18px rgba(15,23,42,.045)}
.mmc-country-inner{max-width:1320px;margin:0 auto;padding:12px 22px;display:flex;align-items:center;gap:14px;overflow-x:auto;scrollbar-width:none;direction:rtl}
.mmc-country-inner::-webkit-scrollbar{display:none}
.mmc-country-label{display:inline-flex;align-items:center;justify-content:center;min-width:112px;padding:11px 18px;border-radius:16px;background:var(--mmc-green);color:#fff;font-weight:900;font-size:14px;white-space:nowrap;box-shadow:0 6px 14px rgba(22,163,74,.18)}
.mmc-country-pill{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-width:145px;padding:11px 18px;border:1px solid #e5ebe7;border-radius:16px;background:#fff;color:#1f2937;font-size:14px;font-weight:800;text-decoration:none;white-space:nowrap;transition:.18s ease;box-shadow:0 2px 8px rgba(15,23,42,.025)}
.mmc-country-pill:hover{border-color:#86efac;background:#f0fdf4;color:var(--mmc-green-dark);transform:translateY(-1px)}
.mmc-country-pill.active{border-color:#86efac;background:#f0fdf4;color:#166534;box-shadow:0 0 0 2px rgba(34,197,94,.08)}

/* Homepage / country landing layout */
.mmc-v14-hero{max-width:1320px;margin:0 auto;padding:44px 22px 24px}
.mmc-v14-hero-inner{display:flex;align-items:flex-end;justify-content:space-between;gap:24px}
.mmc-v14-hero h1{font-size:clamp(2rem,4vw,3.25rem);font-weight:950;letter-spacing:-.04em;margin:0;color:#0b1324}
.mmc-v14-hero p{margin:10px 0 0;color:#64748b;font-size:1.03rem;line-height:1.9;max-width:720px}
.mmc-v14-layout{max-width:1320px;margin:0 auto;padding:20px 22px 70px;display:grid;grid-template-columns:270px minmax(0,1fr);gap:28px;align-items:start;direction:ltr}
.mmc-v14-sidebar,.mmc-v14-content{direction:rtl}
.mmc-v14-sidebar{background:#fff;border:1px solid var(--mmc-border);border-radius:22px;overflow:hidden;box-shadow:0 6px 20px rgba(15,23,42,.035);position:sticky;top:112px}
.mmc-v14-sidebar-title{padding:20px 20px 16px;font-size:1.15rem;font-weight:950;border-bottom:1px solid #edf1ef}
.mmc-v14-cat{display:flex;align-items:center;gap:11px;padding:13px 16px;border-bottom:1px solid #f1f4f2;text-decoration:none;color:#334155;font-weight:750}
.mmc-v14-cat:hover{background:#f8fcf9;color:var(--mmc-green-dark)}
.mmc-v14-cat-icon{width:36px;height:36px;display:grid;place-items:center;border-radius:12px;background:#f0fdf4;font-size:18px}
.mmc-v14-cat-count{margin-right:auto;min-width:30px;height:30px;padding:0 8px;display:grid;place-items:center;border-radius:999px;background:#f0fdf4;color:#15803d;font-size:12px;font-weight:900}
.mmc-v14-all{display:block;margin:14px;padding:11px 14px;border:1px solid #4ade80;border-radius:12px;text-align:center;color:#15803d;text-decoration:none;font-weight:900}
.mmc-v14-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.mmc-v14-card{display:flex;flex-direction:column;min-height:235px;padding:25px 24px;background:#fff;border:1px solid var(--mmc-border);border-radius:20px;text-decoration:none;box-shadow:0 6px 18px rgba(15,23,42,.035);transition:.2s ease}
.mmc-v14-card:hover{transform:translateY(-3px);border-color:#86efac;box-shadow:0 14px 28px rgba(15,23,42,.07)}
.mmc-v14-card-icon{width:54px;height:54px;display:grid;place-items:center;border-radius:15px;background:#ecfdf3;font-size:25px;margin-bottom:18px}
.mmc-v14-card h2{font-size:1.05rem;font-weight:950;margin:0;color:#172033}
.mmc-v14-card p{margin:10px 0 0;color:#64748b;line-height:1.8;font-size:.91rem}
.mmc-v14-card-action{margin-top:auto;padding-top:20px;color:#16a34a;font-weight:900;font-size:.9rem}

/* Country landing / category cards */
.mmc-page-hero{max-width:1320px!important;margin:0 auto!important;padding:34px 22px 10px!important;background:transparent!important}
.mmc-page-hero-left{display:flex;justify-content:space-between;align-items:center;gap:20px}
.mmc-category-title{display:flex;align-items:center;gap:18px}
.mmc-big-icon{width:74px;height:74px;border-radius:22px;background:#effaf2;display:grid;place-items:center;font-size:30px;box-shadow:inset 0 0 0 1px #e3f4e8}
.mmc-eyebrow{font-size:.8rem;font-weight:900;color:#16a34a}
.mmc-page-hero h1{font-size:clamp(2rem,3.5vw,3rem);font-weight:950;margin:3px 0 0;color:#0f172a}
.mmc-page-hero>p{margin:10px 0 0;color:#64748b;font-size:1rem}
.mmc-tool-grid{max-width:1320px!important;margin:22px auto 0!important;padding:0 22px!important;display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px!important}
.mmc-tool-card{min-height:205px!important;background:#fff!important;border:1px solid var(--mmc-border)!important;border-radius:20px!important;padding:24px!important;box-shadow:0 6px 18px rgba(15,23,42,.035)!important;text-decoration:none!important;transition:.2s ease!important;display:flex!important;align-items:flex-start!important;gap:16px!important}
.mmc-tool-card:hover{transform:translateY(-3px);border-color:#86efac!important;box-shadow:0 14px 28px rgba(15,23,42,.07)!important}
.mmc-tool-card>div:nth-child(2){flex:1}
.mmc-tool-icon{width:54px!important;height:54px!important;min-width:54px;display:grid!important;place-items:center;border-radius:15px;background:#effaf2!important;font-size:24px!important}
.mmc-tool-card h2,.mmc-tool-card h3{font-weight:950!important;color:#172033!important;margin:2px 0 7px!important}
.mmc-tool-card p{color:#64748b!important;line-height:1.8!important;font-size:.9rem!important;margin:0!important}
.mmc-category-arrow{color:#16a34a!important;font-weight:950!important;margin-top:auto}
.mmc-info-panel{max-width:1276px!important;margin:22px auto 70px!important;padding:24px!important;background:#f0fdf4!important;border:1px solid #bbf7d0!important;border-radius:18px!important}

/* Calculator detail pages */
main.max-w-4xl{max-width:1000px!important;padding-top:38px!important}
main.max-w-4xl>div.text-center{margin-bottom:28px!important}
main.max-w-4xl>div.text-center h1{font-size:clamp(2rem,4vw,3rem)!important;font-weight:950!important;letter-spacing:-.035em}
main.max-w-4xl>div.bg-white{border:1px solid var(--mmc-border)!important;border-radius:22px!important;box-shadow:0 12px 32px rgba(15,23,42,.06)!important}
main.max-w-4xl input,main.max-w-4xl select{min-height:48px!important;border-color:#dce5df!important;border-radius:13px!important;background:#fff!important}
main.max-w-4xl button{border-radius:13px!important;font-weight:900!important}
main.max-w-4xl #result{border-radius:18px!important;background:#0f172a!important;box-shadow:0 8px 22px rgba(15,23,42,.12)}
.mmc-expanded{border:1px solid var(--mmc-border)!important;background:#fff!important;box-shadow:0 6px 20px rgba(15,23,42,.035)!important}

/* Remove the Morocco card from the generic category area on home */
.mmc-home-morocco-card{display:none!important}

/* Mobile */
@media(max-width:1050px){.mmc-v14-grid,.mmc-tool-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}.mmc-v14-layout{grid-template-columns:220px minmax(0,1fr)}}
@media(max-width:760px){.mmc-country-strip{top:64px}header .max-w-6xl{min-height:64px}.mmc-country-inner{padding:9px 12px;gap:8px}.mmc-country-pill{min-width:124px;padding:10px 12px;font-size:13px}.mmc-country-label{min-width:90px;padding:10px 13px}.mmc-v14-hero{padding:28px 16px 12px}.mmc-v14-hero-inner,.mmc-page-hero-left{align-items:flex-start;flex-direction:column}.mmc-v14-layout{display:block;padding:12px 16px 50px}.mmc-v14-sidebar{position:static;margin-bottom:18px}.mmc-v14-grid,.mmc-tool-grid{grid-template-columns:1fr!important}.mmc-tool-grid{padding:0 16px!important}.mmc-page-hero{padding:26px 16px 8px!important}.mmc-category-title{gap:12px}.mmc-big-icon{width:60px;height:60px;border-radius:18px}.mmc-page-hero h1{font-size:2rem}.mmc-info-panel{margin:20px 16px 50px!important}
}

/* V15 content + calculator UX */
.mmc-content-rich{max-width:1120px;margin:34px auto 60px;padding:0 22px;color:#334155;line-height:1.95}
.mmc-content-rich h2{font-size:1.55rem;font-weight:900;color:#0f172a;margin:34px 0 12px}
.mmc-content-rich h3{font-size:1.12rem;font-weight:850;color:#166534;margin:22px 0 8px}
.mmc-content-rich p{margin:0 0 12px}
.mmc-content-rich ul{padding-right:22px;margin:10px 0 18px}
.mmc-content-rich li{margin:6px 0}
.mmc-content-rich .mmc-example{background:#f0fdf4;border:1px solid #bbf7d0;border-radius:18px;padding:18px 20px;margin:18px 0}
.mmc-content-rich .mmc-note{background:#fffbeb;border:1px solid #fde68a;border-radius:18px;padding:18px 20px;margin:18px 0}
.mmc-content-rich .mmc-faq{border-top:1px solid #e2e8f0;padding-top:14px;margin-top:14px}
.mmc-content-rich .mmc-faq strong{display:block;color:#0f172a;margin-bottom:5px}
.mmc-result[aria-live]{min-height:64px}
@media(max-width:760px){.mmc-content-rich{padding:0 16px;margin-top:26px}.mmc-content-rich h2{font-size:1.35rem}}

/* Morocco country page: keep categories in header only; content uses full width. */
.mmc-v14-layout-full{grid-template-columns:minmax(0,1fr)!important}.mmc-v14-layout-full .mmc-v14-content{width:100%;min-width:0}
