/* ============================================================
   Annota8 — shared site chrome (nav + footer)
   Source of truth lifted verbatim from index.html's inline styles
   so the Field Notes / blog section wears the SAME top bar and
   footer as the marketing site. Token-driven, register-day safe.
   Loaded by every /blog/ page. (Homepage still inlines its own copy.)
   ============================================================ */

/* ---------- Annota8 top bar (brand-look, target tokens) ---------- */
.a8nav{
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;                         /* above .a8-bg backdrop + hero */
  background: transparent;              /* transparent at the top of the page */
  transition: background var(--t-med, 420ms) var(--ease-out, cubic-bezier(.22,1,.36,1)),
              box-shadow  var(--t-med, 420ms) var(--ease-out, cubic-bezier(.22,1,.36,1)),
              border-color var(--t-med, 420ms) var(--ease-out, cubic-bezier(.22,1,.36,1));
  border-bottom: 1px solid transparent;
}
/* glass-solid once scrolled (add .nav--solid via JS, mirrors brand navBg) */
.a8nav.nav--solid{
  background: var(--nav-bg, rgba(250,250,248,0.78));
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border-bottom-color: var(--rule, rgba(11,11,15,0.08));
}
.a8nav__inner{
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--s3, 1.5rem);
  height: 68px;                          /* brand bar ≈ 18px pad + 44px logo */
}

/* Logo */
.a8nav__logo{ display: flex; align-items: center; }
.a8nav__logo-img{ height: 32px; width: auto; display: block; }

/* Nav links */
.a8nav__links{ display: flex; align-items: center; gap: 22px; }
.a8nav__links a{
  display: inline-flex; align-items: center;
  font-family: var(--font-ui, 'Space Grotesk', sans-serif);
  font-size: 13px; font-weight: 500; letter-spacing: 0.01em;
  color: var(--fg2, #3D4361); text-decoration: none; white-space: nowrap;
  transition: color var(--t-fast, 160ms) var(--ease-out, ease);
}
.a8nav__links a:hover{ color: var(--fg, #0B0B0F); }

/* Status pills (LIVE / NEXT) — brand StatusPill, recolored to tokens */
.a8pill{
  margin-inline-start: 6px; padding: 2px 6px; border-radius: 999px;
  font-family: var(--font-ui, 'Space Grotesk', sans-serif);
  font-size: 9px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  vertical-align: middle; white-space: nowrap; line-height: 1;
}
.a8pill--live{
  color: var(--teal-ink);
  border: 1px solid color-mix(in srgb, var(--brand-alt, #5BB8E8) 33%, transparent);
  background: color-mix(in srgb, var(--brand-alt, #5BB8E8) 8%, transparent);
}
.a8pill--next{
  color: var(--brand-ink-strong);
  border: 1px solid color-mix(in srgb, var(--brand, #3F6FC8) 33%, transparent);
  background: color-mix(in srgb, var(--brand, #3F6FC8) 8%, transparent);
}

/* Right-side actions */
.a8nav__actions{ display: flex; align-items: center; gap: 10px; }

.a8nav__lang{
  height: 34px; padding: 0 12px; border-radius: 999px;
  border: 1px solid var(--card-border, rgba(11,11,15,0.08));
  background: transparent; color: var(--fg, #0B0B0F); cursor: pointer;
  font-family: var(--font-ui, 'Space Grotesk', sans-serif);
  font-size: 11px; font-weight: 600; letter-spacing: 0.08em;
  display: inline-flex; align-items: center; text-decoration: none;
}
.a8nav__lang:hover{ border-color: var(--fg3, #6B7184); }

/* CTA pill — brand ctaBg/ctaFg (dark pill on light, inverts on dark register) */
.a8nav__cta{
  display: inline-flex; align-items: center; white-space: nowrap;
  padding: 9px 18px; border-radius: 999px;
  min-height:44px;
  background: var(--cta-bg, #0B0B0F); color: var(--cta-fg, #ffffff);
  font-family: var(--font-ui, 'Space Grotesk', sans-serif);
  font-size: 13px; font-weight: 600; text-decoration: none;
  transition: transform var(--t-fast, 160ms) var(--ease-out, ease),
              box-shadow var(--t-fast, 160ms) var(--ease-out, ease);
}
.a8nav__cta:hover{ transform: translateY(-1px); box-shadow:0 8px 24px rgba(11,11,15,0.14); }

/* Hamburger button — hidden on desktop, shown <=1100px (mirrors the homepage) */
.a8nav__burger{
  display: none;
  width: 42px; height: 42px; border-radius: 12px; padding: 0;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  border: 1px solid var(--card-border, rgba(11,11,15,0.08));
  background: transparent; color: var(--fg, #0B0B0F); cursor: pointer;
  transition: border-color var(--t-fast,160ms) var(--ease-out,ease), background var(--t-fast,160ms) var(--ease-out,ease);
}
.a8nav__burger span{
  display: block; width: 20px; height: 2px; border-radius: 2px;
  background: currentColor;
  transition: transform .26s var(--ease-out,cubic-bezier(.22,1,.36,1)), opacity .18s ease;
}
.a8nav__burger:hover{ border-color: var(--fg3, #6B7184); }

/* Responsive: collapse center links into a hamburger drawer <=1100px */
@media (max-width: 1100px){
  .a8nav__burger{ display: inline-flex; }
  .a8nav__inner{ height: 56px; }

  .a8nav__links{
    position: fixed; top: 56px; left: 0; right: 0; z-index: 99;
    display: flex; flex-direction: column; align-items: stretch; gap: 2px;
    margin: 0; padding: 6px 16px 16px;
    background: var(--bg, #FAFAF8);
    -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px);
    border-bottom: 1px solid var(--rule, rgba(11,11,15,0.08));
    box-shadow: 0 26px 44px -30px rgba(11,11,15,0.40);
    max-height: calc(100dvh - 56px); overflow-y: auto;
    overscroll-behavior: contain;
    opacity: 0; visibility: hidden; transform: translateY(-10px);
    transition: opacity .26s var(--ease-out,ease), transform .26s var(--ease-out,ease), visibility .26s;
  }
  .a8nav.is-menu-open .a8nav__links{ opacity: 1; visibility: visible; transform: none; }
  .a8nav__links a{
    display: flex; align-items: center; min-height: 50px;
    padding: 0 6px; font-size: 16px; font-weight: 500;
    color: var(--fg, #0B0B0F);
    border-bottom: 1px solid var(--rule, rgba(11,11,15,0.06));
  }
  .a8nav__links a:last-child{ border-bottom: none; }
  .a8nav__links a:hover,
  .a8nav__links a:active{ color: var(--brand-ink-strong, var(--brand, #3F6FC8)); }

  .a8nav.is-menu-open{
    background: var(--nav-bg, rgba(250,250,248,0.96));
    -webkit-backdrop-filter: blur(22px); backdrop-filter: blur(22px);
    border-bottom-color: var(--rule, rgba(11,11,15,0.08));
  }
  .a8nav.is-menu-open .a8nav__burger span:nth-child(1){ transform: translateY(7px) rotate(45deg); }
  .a8nav.is-menu-open .a8nav__burger span:nth-child(2){ opacity: 0; }
  .a8nav.is-menu-open .a8nav__burger span:nth-child(3){ transform: translateY(-7px) rotate(-45deg); }
}
@media (prefers-reduced-motion: reduce){
  .a8nav__links{ transition: none; }
  .a8nav__burger span{ transition: none; }
}
/* RTL nav fit: only the horizontal desktop row (>=1101px), never the drawer */
@media (min-width: 1101px){
  [dir="rtl"] .a8nav__links{ gap: 14px; }
  [dir="rtl"] .a8nav__links a{ font-size: 12px; }
}

/* ---------- Annota8 footer ---------- */
.a8-footer {
  position: relative; z-index: 1;
  padding: var(--s5) var(--gutter, var(--s4)) var(--s4);
  background: var(--bg);
  border-top: 1px solid var(--rule);
  font-family: var(--font-body);
  color: var(--fg2);
}
.a8-footer__inner {
  max-width: var(--max, 1200px);
  margin: 0 auto;
}
.a8-footer__cols {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--s4);
  margin-bottom: var(--s5);
}
.a8-footer__brand { max-width: 320px; }
.a8-footer__logo { height: 36px; width: auto; display: block; }
.a8-footer__tagline {
  font-size: 13px;
  color: var(--fg2);
  margin: 14px 0 0;
  max-width: 280px;
  line-height: 1.6;
}
/* Regions badge — KSA / USA / Egypt */
.a8-footer__regions {
  margin-top: 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 8px 14px;
  border-radius: 9999px;
  border: 1px solid var(--card-border);
  background: transparent;
  font-family: var(--font-ui);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg2);
  font-weight: 600;
}
.a8-footer__regions-label {
  font-size: 10.5px;
  letter-spacing: 0.22em;
  color: var(--fg3);
}
.a8-footer__regions .sep { opacity: 0.35; }
.a8-footer__regions .flag { font-size: 12px; }
.a8-footer__col-title {
  font-family: var(--font-ui);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg3);
  margin-bottom: 14px;
  font-weight: 500;
}
.a8-footer__col a {
  display: block;
  font-size: 13px;
  color: var(--fg2);
  margin-bottom: 8px;
  text-decoration: none;
  transition: color var(--t-fast) var(--ease-out);
}
.a8-footer__col a:hover { color: var(--brand); }
.a8-footer__cta {
  display: inline-block;
  margin-top: 6px;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--brand);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease-out);
}
.a8-footer__cta:hover { color: var(--brand-alt); }
.a8-footer__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 22px;
  border-top: 1px solid var(--rule);
  font-family: var(--font-ui);
  font-size: 11px;
  color: var(--fg3);
  letter-spacing: 0.1em;
}
.a8-footer__bar a { color: var(--fg3); text-decoration: none; }
.a8-footer__bar a:hover { color: var(--fg2); }
.a8-footer__social { display: inline-flex; align-items: center; gap: 16px; }
.a8-footer__social a { display: inline-flex; align-items: center; color: var(--fg3); transition: color var(--t-fast) var(--ease-out); }
.a8-footer__social a:hover { color: var(--brand); }
.a8-footer__social svg { width: 17px; height: 17px; display: block; }
.a8-footer__social .a8-footer__email { font-family: var(--font-ui); font-size: 11px; letter-spacing: 0.1em; }
@media (max-width: 720px) {
  .a8-footer__cols { grid-template-columns: 1fr; gap: var(--s3); }
  .a8-footer__bar { flex-direction: column; align-items: flex-start; }
}
