/* DT_R5_F08 (2026-10-02): fixed bottom navigation on phones. Printed by partials/r5_bottomnav_v1.php.
   Self-contained (own tokens, same palette as the gateway pages: navy #08183f, blue #1354ff, line #d9e1f4). */
.dtbn,.dtbn-sp{display:none}
@media (max-width:760px){
  .dtbn-sp{display:block;height:calc(62px + env(safe-area-inset-bottom, 0px))}
  .dtbn{--dtbn-ink:#52658d;--dtbn-on:#1354ff;
    display:flex;align-items:stretch;justify-content:space-around;gap:2px;
    position:fixed;inset-inline:0;bottom:0;z-index:80;direction:rtl;
    min-height:60px;padding:0 max(6px, env(safe-area-inset-right, 0px)) env(safe-area-inset-bottom, 0px) max(6px, env(safe-area-inset-left, 0px));
    background:rgba(255,255,255,.97);-webkit-backdrop-filter:saturate(160%) blur(12px);backdrop-filter:saturate(160%) blur(12px);
    border-top:1px solid #d9e1f4;box-shadow:0 -8px 24px rgba(8,24,63,.08);
    font-family:Vazirmatn,"Vazir",Tahoma,system-ui,sans-serif;-webkit-font-smoothing:antialiased}
  .dtbn a{position:relative;flex:1 1 0;min-width:0;min-height:56px;margin:2px 0;border-radius:12px;
    display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
    color:var(--dtbn-ink);text-decoration:none;font-size:12.5px;font-weight:700;line-height:1.3;
    -webkit-tap-highlight-color:transparent;transition:color .15s,background-color .15s}
  .dtbn a span{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .dtbn svg{width:23px;height:23px;flex:none;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
  .dtbn a:active{background:#eef3ff}
  .dtbn a[aria-current="page"]{color:var(--dtbn-on)}
  .dtbn a[aria-current="page"]::before{content:"";position:absolute;top:-2px;inset-inline:calc(50% - 15px);height:3px;border-radius:0 0 3px 3px;background:var(--dtbn-on)}
  .dtbn a:focus-visible{outline:2px solid var(--dtbn-on);outline-offset:-3px}
  .dtbn.is-kb{display:none}
  /* keep the existing floating pieces above the bar */
  html.dtbn-on .motion-toggle{bottom:calc(72px + env(safe-area-inset-bottom, 0px))}
  html.dtbn-on .sup-toast{bottom:calc(74px + env(safe-area-inset-bottom, 0px))}
  html.dtbn-on .toast{bottom:calc(74px + env(safe-area-inset-bottom, 0px))}
}
@media (max-width:340px){.dtbn a{font-size:11.5px}.dtbn svg{width:21px;height:21px}}
@media (prefers-reduced-motion:reduce){.dtbn a{transition:none}}
@media print{.dtbn,.dtbn-sp{display:none !important}}
