:root {
  --navy:#0b1a34;
  --blue:#0758b7;
  --orange:#e65312;
  --paper:#fff;
  --canvas:#e9edf2;
  --muted:#7c8798;
  --header:76px;
}
* { box-sizing:border-box; }
html { scroll-behavior:smooth; scroll-padding-top:calc(var(--header) + 24px); }
body { position:relative; margin:0; overflow-x:hidden; color:var(--navy); background:linear-gradient(135deg,#eef1f5 0%,#e6ebf1 55%,#f4f6f8 100%); font-family:Tahoma,"Segoe UI",Arial,sans-serif; -webkit-font-smoothing:antialiased; }
html[data-language="ar"],html[data-language="ku"],html[data-language="ar"] body,html[data-language="ku"] body { direction:rtl; text-align:right; }
html[data-language="ku"] .app-drawer,
html[data-language="ku"] .drawer-head,
html[data-language="ku"] .drawer-grid,
html[data-language="ku"] .drawer-grid a,
html[data-language="ku"] .drawer-grid a span,
html[data-language="ku"] .gallery-placeholder,
html[data-language="ku"] .gallery-placeholder h2,
html[data-language="ku"] .gallery-placeholder p,
html[data-language="ku"] .gallery-live-grid figcaption,
html[data-language="ku"] .gallery-lightbox p { direction:rtl; text-align:right; }
html[data-language="ku"] .drawer-grid a span { width:100%; }
html[data-language="en"],html[data-language="en"] body { direction:ltr; }
body::before { content:""; position:fixed; z-index:-1; inset:var(--header) 0 0; pointer-events:none; opacity:.5; background:linear-gradient(150deg,transparent 0 68%,rgba(7,88,183,.035) 68% 78%,transparent 78%),linear-gradient(30deg,transparent 0 73%,rgba(230,83,18,.04) 73% 83%,transparent 83%); }
button,a { -webkit-tap-highlight-color:transparent; }
.viewer-header { position:fixed; z-index:50; inset:0 0 auto; height:var(--header); padding:0 max(24px,calc((100% - 1180px)/2)); display:flex; align-items:center; gap:18px; border-bottom:1px solid rgba(11,26,52,.12); background:rgba(255,255,255,.94); box-shadow:0 7px 28px rgba(11,26,52,.09); backdrop-filter:blur(16px); }
.header-mark { position:absolute; inset:auto 0 0; height:4px; background:linear-gradient(90deg,var(--orange) 0 31%,var(--navy) 31% 78%,var(--blue) 78%); }
.viewer-brand { width:150px; height:62px; margin-left:auto; display:flex; align-items:center; overflow:hidden; }
.viewer-brand img { width:148px; height:auto; display:block; }
.viewer-title { padding-right:18px; border-right:1px solid #dfe3ea; }
.viewer-title strong,.viewer-title span { display:block; }
.viewer-title strong { font-size:13px; }
.viewer-title span { margin-top:4px; color:var(--muted); font-size:9px; }
.app-menu-button { width:44px; height:44px; display:grid; place-items:center; flex:0 0 auto; border:0; border-radius:13px; color:#fff; background:var(--navy); box-shadow:0 7px 18px rgba(11,26,52,.2); cursor:pointer; }
.app-menu-button svg { width:24px; height:24px; fill:none; stroke:currentColor; stroke-width:2; stroke-linecap:round; }
.drawer-backdrop { position:fixed; z-index:9997; inset:0; background:rgba(6,16,33,.48); backdrop-filter:blur(3px); }
.app-drawer { position:fixed; z-index:9998; top:0; right:0; width:min(390px,90vw); height:100dvh; padding:22px 18px 110px; overflow:auto; color:var(--navy); background:#f7f9fc; box-shadow:-20px 0 55px rgba(5,16,35,.28); transform:translateX(105%); transition:transform .16s ease-out; }
.app-drawer.open { transform:none; }
.drawer-head { display:flex; align-items:center; justify-content:space-between; padding:5px 4px 20px; border-bottom:1px solid #dfe5ed; }
.drawer-head strong { font-size:18px; }
.drawer-head button { width:38px; height:38px; border:0; border-radius:50%; color:#fff; background:var(--orange); font-size:25px; line-height:1; cursor:pointer; }
.drawer-grid { padding-top:18px; display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.drawer-grid a { min-height:105px; padding:16px 10px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:10px; border:1px solid #e1e6ee; border-radius:18px; color:var(--navy); background:#fff; box-shadow:0 8px 22px rgba(11,26,52,.07); text-align:center; text-decoration:none; }
.drawer-grid a b { width:42px; height:42px; display:grid; place-items:center; border-radius:13px; color:#fff; background:linear-gradient(145deg,var(--navy),var(--blue)); font-size:21px; }
.drawer-grid a span { font-size:13px; font-weight:700; }
.drawer-grid .drawer-whatsapp { grid-column:1/-1; min-height:76px; flex-direction:row; color:#087c38; }
.drawer-grid .drawer-whatsapp b { background:#16b85b; }
.drawer-grid .drawer-login { grid-column:1/-1; min-height:68px; flex-direction:row; color:var(--navy); }
.drawer-grid .drawer-login b { background:var(--orange); }
.main-menu { position:fixed; z-index:60; right:0; bottom:0; left:0; width:100%; min-height:76px; padding:12px max(18px,calc((100% - 620px)/2)) max(10px,env(safe-area-inset-bottom)); display:grid; grid-template-columns:repeat(5,1fr); align-items:center; gap:12px; border:0; border-top:1px solid rgba(11,26,52,.09); border-radius:24px 24px 0 0; background:rgba(255,255,255,.97); box-shadow:0 -16px 45px rgba(11,26,52,.17); backdrop-filter:blur(18px); transform:none; }
.main-menu::before { content:none; }
.main-menu::after { content:""; position:absolute; top:0; right:24px; left:24px; height:2px; background:linear-gradient(90deg,transparent,var(--orange) 23%,transparent 42%,transparent 58%,var(--blue) 77%,transparent); opacity:.75; }
.main-menu a { position:relative; min-height:50px; display:grid; place-items:center; border:1px solid transparent; border-radius:14px; color:#6c7480; background:transparent; text-decoration:none; transition:color .2s ease,background .2s ease,transform .2s ease,border-color .2s ease; }
.main-menu a svg { width:23px; height:23px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.main-menu a:not(.whatsapp-action):hover { color:var(--navy); border-color:#e1e6ee; background:#f3f5f8; transform:translateY(-2px); }
.main-menu a:not(.whatsapp-action).active { color:#fff; border-color:var(--navy); background:linear-gradient(145deg,var(--navy),#17365f); box-shadow:0 7px 16px rgba(11,26,52,.2); transform:translateY(-3px); }
.main-menu a:not(.whatsapp-action).active::after { content:""; position:absolute; bottom:5px; width:5px; height:5px; border-radius:50%; background:var(--orange); box-shadow:0 0 0 3px rgba(230,83,18,.16); }
.main-menu .whatsapp-action { z-index:2; width:70px; height:70px; min-height:70px; margin:-42px auto 0; border:5px solid #fff; border-radius:50%; color:#fff; background:linear-gradient(145deg,#32dc78 0%,#12b85a 48%,#079447 100%); box-shadow:0 12px 27px rgba(5,126,60,.28),0 3px 9px rgba(11,26,52,.12),inset 0 1px 0 rgba(255,255,255,.42); }
.main-menu .whatsapp-action:hover { transform:translateY(-3px) scale(1.04); }
.main-menu .whatsapp-action svg { width:31px; height:31px; stroke-width:1.65; }
.main-menu .whatsapp-action::after { content:""; position:absolute; inset:-8px; z-index:-1; border:0; border-radius:50%; background:rgba(37,211,102,.11); box-shadow:0 0 0 1px rgba(37,211,102,.08); animation:none; }
.page-indicator { min-width:92px; height:44px; margin-right:auto; display:flex; align-items:baseline; justify-content:center; gap:6px; color:#fff; background:var(--navy); border-radius:4px; direction:ltr; }
.page-indicator b { color:var(--orange); font:800 20px/1 Arial,sans-serif; }
.page-indicator span,.page-indicator small { color:#aeb8c8; font:700 10px/1 Arial,sans-serif; }
.reading-progress { position:fixed; z-index:51; top:var(--header); right:0; left:0; height:3px; background:transparent; }
.reading-progress span { display:block; width:0; height:100%; background:var(--orange); transition:width .18s linear; }
.document { width:min(100% - 40px,980px); margin:0 auto; padding:calc(var(--header) + 34px) 0 108px; display:grid; gap:55px; }
.document-section[hidden] { display:none; }
.document-section { display:grid; gap:30px; transform-origin:top center; }
.document-section.section-enter { animation:sectionEnter .18s cubic-bezier(.2,.7,.2,1) both; }
.gallery-placeholder { min-height:calc(100dvh - 210px); padding:48px 24px; display:flex; flex-direction:column; align-items:center; justify-content:center; border:1px solid rgba(11,26,52,.1); border-radius:28px; background:linear-gradient(145deg,#fff,#f5f8fc); box-shadow:0 18px 50px rgba(11,26,52,.1); text-align:center; }
.gallery-placeholder-icon { width:86px; height:86px; display:grid; place-items:center; border-radius:26px; color:#fff; background:linear-gradient(145deg,var(--orange),#ff8b2b); box-shadow:0 15px 35px rgba(230,83,18,.25); font-size:42px; }
.gallery-placeholder-icon { display:none!important; }
.gallery-placeholder h2 { margin:24px 0 8px; color:var(--navy); font-size:25px; }
.gallery-placeholder p { margin:0; color:var(--muted); font-size:14px; }
.gallery-placeholder.has-images { display:block; padding:30px; background:linear-gradient(145deg,#fff,#f4f7fb); }
.gallery-placeholder.has-images h2 { margin-top:0; text-align:start; }
.gallery-live-grid { width:100%; margin-top:22px; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; }
.gallery-live-grid figure { position:relative; margin:0; overflow:hidden; border:1px solid rgba(11,26,52,.09); border-radius:21px; background:#fff; box-shadow:0 12px 30px rgba(11,26,52,.1); transition:transform .22s ease,box-shadow .22s ease; }
.gallery-live-grid figure:hover { transform:translateY(-4px); box-shadow:0 18px 38px rgba(11,26,52,.16); }
.gallery-live-grid button { position:relative; width:100%; padding:0; display:block; overflow:hidden; border:0; border-radius:20px 20px 0 0; background:#dfe5ed; aspect-ratio:4/3; cursor:zoom-in; }
.gallery-live-grid img { width:100%; height:100%; display:block; object-fit:cover; transition:transform .35s cubic-bezier(.2,.7,.2,1),filter .25s ease; }
.gallery-live-grid button:hover img { transform:scale(1.055); filter:saturate(1.08); }
.gallery-zoom { position:absolute; right:11px; bottom:11px; width:38px; height:38px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.5); border-radius:12px; color:#fff; background:rgba(11,26,52,.75); box-shadow:0 6px 16px rgba(0,0,0,.2); backdrop-filter:blur(8px); font-size:19px; }
.gallery-live-grid figcaption { min-height:48px; padding:12px 46px 12px 14px; color:var(--navy); font-size:12px; line-height:1.55; text-align:start; }
.gallery-live-grid figure>small { position:absolute; right:14px; bottom:14px; color:var(--orange); font:800 11px Arial,sans-serif; }
.gallery-lightbox { width:min(94vw,1050px); max-height:92dvh; padding:12px; overflow:auto; border:0; border-radius:24px; background:#fff; box-shadow:0 30px 90px rgba(0,0,0,.45); }
.gallery-lightbox::backdrop { background:rgba(4,12,25,.78); backdrop-filter:blur(8px); }
.gallery-lightbox img { width:100%; max-height:76dvh; display:block; border-radius:16px; object-fit:contain; background:#eef1f5; }
.gallery-lightbox p { margin:12px 8px 4px; color:var(--navy); font-size:14px; line-height:1.7; text-align:center; }
.lightbox-close { position:fixed; z-index:2; top:max(14px,env(safe-area-inset-top)); right:18px; width:46px; height:46px; border:2px solid #fff; border-radius:50%; color:#fff; background:var(--orange); box-shadow:0 10px 25px rgba(0,0,0,.3); font-size:28px; cursor:pointer; }
@media(max-width:720px){.gallery-live-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.gallery-placeholder.has-images{padding:10px;border-radius:16px}.gallery-live-grid figure{border-radius:14px}.gallery-live-grid button{border-radius:13px 13px 0 0;aspect-ratio:1}.gallery-zoom{right:7px;bottom:7px;width:31px;height:31px;border-radius:9px;font-size:15px}.gallery-live-grid figcaption{min-height:42px;padding:8px 28px 8px 8px;font-size:10px}.gallery-live-grid figure>small{right:8px;bottom:10px;font-size:9px}.gallery-lightbox{width:96vw;padding:7px;border-radius:17px}}
.section-break { height:66px; display:flex; align-items:center; gap:18px; }
.section-break::before,.section-break::after { content:""; height:2px; flex:1; background:linear-gradient(90deg,var(--orange),var(--blue)); }
.section-break::after { transform:scaleX(-1); }
.section-break span { width:54px; height:54px; display:grid; place-items:center; border:4px solid #fff; border-radius:16px; color:#fff; background:var(--navy); box-shadow:0 8px 22px rgba(11,26,52,.2); }
.section-break svg { width:26px; height:26px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.page { position:relative; margin:0; overflow:hidden; border:1px solid rgba(11,26,52,.08); border-radius:3px; background:var(--paper); box-shadow:0 18px 55px rgba(17,32,55,.16); isolation:isolate; transition:box-shadow .25s ease; }
.page::before { content:attr(data-page); position:absolute; z-index:2; top:14px; left:-44px; width:36px; height:28px; display:grid; place-items:center; color:#fff; background:var(--navy); font:700 10px Arial,sans-serif; direction:ltr; }
.page::after { content:""; position:absolute; z-index:2; top:14px; left:-8px; width:8px; height:28px; background:var(--orange); }
.page img { width:100%; height:auto; display:block; background:#fff; aspect-ratio:1092/1544; object-fit:contain; }
.page.loading img { opacity:.22; background:linear-gradient(100deg,#f2f4f7 20%,#fff 38%,#f2f4f7 56%); background-size:220% 100%; animation:pageShimmer 1.25s linear infinite; }
.page img { transition:opacity .3s ease; }
.page:not(.loading) img { opacity:1; }
.page:hover { box-shadow:0 22px 65px rgba(17,32,55,.2); }
.viewer-brand:focus-visible,.main-menu a:focus-visible { outline:3px solid var(--orange); outline-offset:3px; }
.main-menu a:active { transform:scale(.94)!important; }
.whatsapp-action:active { transform:translateY(0) scale(.94)!important; }
.noscript { margin:100px 20px; text-align:center; }
@keyframes sectionEnter { from { opacity:0; transform:translateY(14px) scale(.995); } to { opacity:1; transform:none; } }
@keyframes pageShimmer { to { background-position:-220% 0; } }
@keyframes whatsappPulse { 0%,45% { opacity:.75; transform:scale(.84); } 75%,100% { opacity:0; transform:scale(1.12); } }
@media (max-width:720px) {
  :root { --header:66px; }
  .viewer-header { padding:0 13px; gap:10px; }
  .viewer-brand { width:126px; height:54px; margin-left:auto; }
  .viewer-brand img { width:124px; }
  .viewer-title { padding-right:10px; }
  .viewer-title strong { font-size:10px; }
  .viewer-title span { display:none; }
  .main-menu { right:0; bottom:0; left:0; width:100%; min-height:72px; padding:10px 10px max(9px,env(safe-area-inset-bottom)); grid-template-columns:repeat(5,1fr); gap:6px; border-radius:20px 20px 0 0; }
  .main-menu a { min-height:48px; }
  .main-menu .whatsapp-action { width:66px; height:66px; min-height:66px; margin-top:-38px; }
  .main-menu::before { top:-25px; width:82px; height:56px; }
  .page-indicator { min-width:66px; height:36px; border-radius:3px; }
  .page-indicator b { font-size:16px; }
  .document { width:100%; padding:calc(var(--header) + 12px) 8px 94px; gap:30px; }
  .document-section { gap:14px; }
  .section-break { height:55px; margin:5px 2px; }
  .section-break span { width:46px; height:46px; border-radius:13px; }
  .section-break svg { width:22px; height:22px; }
  .page { box-shadow:0 8px 24px rgba(17,32,55,.16); }
  .page::before,.page::after { display:none; }
}
@media (max-width:380px) {
  .viewer-title { display:none; }
  .page-indicator { margin-right:0; }
}
@media (prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  * { transition:none!important; }
  *,*::before,*::after { animation:none!important; }
}

/* Refined application chrome */
.viewer-header {
  height:82px;
  padding:0 clamp(20px,4vw,64px);
  display:grid;
  grid-template-columns:160px minmax(0,1fr) 46px 126px 48px;
  gap:14px;
  background:rgba(255,255,255,.97);
  box-shadow:0 10px 34px rgba(11,26,52,.11);
  backdrop-filter:blur(22px) saturate(150%);
}
.viewer-brand { grid-column:1; width:158px; height:66px; margin:0; justify-self:start; }
.viewer-brand img { width:154px; }
.viewer-title { grid-column:2; padding:0 22px; border:0; text-align:center; }
.viewer-title strong { font-size:14px; letter-spacing:.1px; }
.viewer-title span { margin-top:5px; font-size:10px; }
.app-email-button { grid-column:3; width:44px; height:44px; display:grid; place-items:center; justify-self:end; border:1px solid #dce4ee; border-radius:14px; color:var(--navy); background:#fff; box-shadow:0 7px 18px rgba(11,26,52,.1); transition:transform .2s ease,color .2s ease,background .2s ease; }
.app-email-button:hover { color:#fff; background:var(--orange); transform:translateY(-2px); }
.app-email-button svg { width:22px; height:22px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.app-language { position:relative; grid-column:4; height:44px; border:1px solid #dce4ee; border-radius:14px; background:#fff; box-shadow:0 7px 18px rgba(11,26,52,.08); direction:ltr; }
.app-language summary { height:100%; padding:0 11px; display:flex; align-items:center; justify-content:center; gap:7px; border-radius:inherit; color:var(--navy); cursor:pointer; list-style:none; user-select:none; }
.app-language summary::-webkit-details-marker { display:none; }
.app-language summary span { font-size:16px; }
.app-language summary b { font-size:12px; }
.app-language[open] summary { color:#fff; background:var(--navy); }
.language-popover { position:absolute; top:calc(100% + 10px); right:0; width:178px; padding:7px; border:1px solid #dce4ee; border-radius:15px; background:#fff; box-shadow:0 16px 38px rgba(11,26,52,.2); }
.language-popover button { width:100%; min-height:42px; padding:0 11px; display:flex; align-items:center; justify-content:space-between; border:0; border-radius:10px; color:var(--navy); background:transparent; font:700 12px Tahoma,"Segoe UI",Arial,sans-serif; }
.language-popover button.active { color:#fff; background:linear-gradient(145deg,var(--navy),#17365f); }
.language-popover button:disabled { color:#9aa4b2; }
.language-popover small { font-size:10px; opacity:.75; }
.app-menu-button { grid-column:5; width:48px; height:48px; justify-self:end; border:1px solid rgba(255,255,255,.16); border-radius:15px; background:linear-gradient(145deg,#132c52,var(--navy)); box-shadow:0 9px 22px rgba(11,26,52,.24); transition:transform .2s ease,box-shadow .2s ease; }
.app-menu-button { margin-inline-start:7px; }
.app-menu-button:hover { transform:translateY(-2px); box-shadow:0 12px 27px rgba(11,26,52,.29); }
.header-mark { height:4px; background:linear-gradient(90deg,var(--orange) 0 30%,var(--navy) 30% 72%,var(--blue) 72%); }
.reading-progress { top:82px; }
.document { padding-top:116px; }

.main-menu {
  min-height:82px;
  padding:13px max(24px,calc((100% - 690px)/2)) max(11px,env(safe-area-inset-bottom));
  gap:16px;
  border-radius:28px 28px 0 0;
  box-shadow:0 -14px 45px rgba(11,26,52,.16);
}
.main-menu a { min-height:52px; border-radius:16px; }
.main-menu a svg { width:25px; height:25px; stroke-width:1.8; }
.main-menu a:not(.whatsapp-action).active { background:linear-gradient(145deg,#17365f,var(--navy)); box-shadow:0 8px 20px rgba(11,26,52,.25); }
.main-menu .whatsapp-action { width:72px; height:72px; min-height:72px; margin-top:-44px; box-shadow:0 0 0 5px var(--navy),0 15px 30px rgba(11,26,52,.32); }

@media (max-width:720px) {
  :root { --header:70px; }
  .viewer-header { height:70px; padding:0 10px; grid-template-columns:82px minmax(0,1fr) 38px 50px 42px; gap:11px; }
  .viewer-brand { width:82px; height:58px; }
  .viewer-brand img { width:82px; }
  .viewer-title { padding:0 4px; }
  .viewer-title strong { overflow:hidden; font-size:10px; white-space:nowrap; text-overflow:ellipsis; }
  .viewer-title span { display:none; }
  .app-menu-button { width:42px; height:42px; border-radius:13px; }
  .app-menu-button { margin-inline-start:5px; }
  .app-menu-button svg { width:22px; height:22px; }
  .app-email-button { width:38px; height:38px; border-radius:12px; }
  .app-email-button svg { width:20px; height:20px; }
  .app-language { width:50px; height:38px; margin:0; border-radius:12px; }
  .app-language summary { padding:0 6px; gap:3px; }
  .app-language summary span { font-size:15px; }
  .app-language summary b { font-size:9px; }
  .language-popover { position:fixed; top:64px; right:54px; width:170px; }
  .reading-progress { top:70px; }
  .document { padding-top:82px; padding-bottom:92px; }
  .main-menu { min-height:64px; padding:6px 9px max(7px,env(safe-area-inset-bottom)); gap:6px; border-radius:22px 22px 0 0; border-top-color:rgba(11,26,52,.055); background:linear-gradient(180deg,rgba(255,255,255,.985),rgba(249,251,253,.98)); box-shadow:0 -9px 28px rgba(11,26,52,.105); }
  .main-menu::after { right:34px; left:34px; height:1px; opacity:.45; }
  .main-menu a { min-height:44px; border-radius:14px; color:#737e8d; }
  .main-menu a svg { width:24px; height:24px; }
  .main-menu a:not(.whatsapp-action).active { color:var(--orange); border-color:rgba(230,83,18,.12); background:rgba(230,83,18,.075); box-shadow:inset 0 0 0 1px rgba(255,255,255,.72); transform:translateY(-1px); }
  .main-menu a:not(.whatsapp-action).active::after { bottom:3px; width:4px; height:4px; box-shadow:none; }
  .main-menu .whatsapp-action { width:64px; height:64px; min-height:64px; margin-top:-39px; border-width:5px; border-top-color:var(--orange); box-shadow:0 11px 25px rgba(6,145,68,.26),0 3px 8px rgba(11,26,52,.11),inset 0 1px 0 rgba(255,255,255,.44); }
  .main-menu .whatsapp-action svg { width:31px; height:31px; }
  .main-menu::before { content:none; }
  .app-drawer { width:min(360px,92vw); }
}

@media (max-width:390px) {
  .viewer-header { grid-template-columns:72px minmax(0,1fr) 36px 46px 40px; gap:9px; }
  .viewer-brand,.viewer-brand img { width:72px; }
  .viewer-title strong { font-size:9px; }
  .main-menu { gap:2px; padding-inline:5px; }
}

@media (min-width:721px) {
  .viewer-header { grid-template-columns:minmax(180px,1fr) 46px 126px 48px; }
  .viewer-brand { grid-column:1; }
  .app-email-button { grid-column:2; }
  .app-language { grid-column:3; }
  .app-menu-button { grid-column:4; }
  .document { padding-bottom:38px; }
}
