/* ──────────────────────────────────────────────────────────────────────
   Bond — the shared site footer (.bf)
   One structure on every page that has a footer. The markup is generated
   into the pages by tools/footer.py, so edit it there, not here.

   Self-contained on purpose: the legal pages carry their own inline
   styles, the guides load guides.css and the home page loads bond.css,
   and no stylesheet is common to all of them. Everything the footer needs
   lives in this file under one namespace, so it cannot inherit a surprise
   from whichever page it lands on.

   Logical properties throughout (inline-start/end, not left/right), so
   the same rules serve the Hebrew RTL source and the English LTR swap.
   ────────────────────────────────────────────────────────────────────── */

.bf {
  /* Bond's own palette, from the app. Not the reference site's. */
  --bf-deep: #0F2B22;   /* the mint hue carried down to band depth */
  --bf-fg:   #F2F2F7;   /* bright.background, used as ink on deep */
  --bf-fg2:  #C9D1CE;   /* --haze, muted text on the dark bands */
  --bf-mint: #5BD4A2;   /* BrandAccent.signatureHex */
  --bf-line: rgba(242, 242, 247, 0.14);

  box-sizing: border-box;
  padding: 24px 16px 32px;
  background: transparent;
  font-family: 'Heebo', system-ui, -apple-system, sans-serif;
}
.bf *,
.bf *::before,
.bf *::after { box-sizing: border-box; }

.bf__card {
  max-width: 1200px;
  margin-inline: auto;
  padding: 48px clamp(20px, 4vw, 56px);
  border-radius: 28px;
  background: var(--bf-deep);
  color: var(--bf-fg);
  display: grid;
  grid-template-columns: minmax(260px, 320px) 1fr;
  gap: 48px clamp(24px, 4vw, 64px);
  align-items: start;
}

/* ── brand side ── */
.bf__brand { display: flex; flex-direction: column; gap: 18px; }

.bf__logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--bf-fg);
  text-decoration: none;
  width: max-content;
  min-height: 44px;
}
.bf__mark { width: 34px; height: 34px; fill: currentColor; flex: none; }
.bf__name { font-size: 22px; font-weight: 700; letter-spacing: .01em; }

.bf__tag { margin: 0; color: var(--bf-fg2); font-size: 15px; line-height: 1.6; }

/* ── store badges ── */
.bf__apps { display: flex; flex-direction: column; gap: 18px; margin-block-start: 4px; }
.bf__appsh {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--bf-fg2);
  letter-spacing: .02em;
}
.bf__badges { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }

/* Apple ships its badge with no padding; Google bakes ~17% clear space
   into each edge of the canvas. Matching the drawn buttons optically
   therefore means two different heights, not one. Both boxes stay well
   over the 44px minimum target. */
.bf__badge {
  display: inline-flex;
  align-items: center;
  border-radius: 8px;
  text-decoration: none;
}
.bf__badge img { display: block; height: 44px; width: auto; }
.bf__badge--g img { height: 65px; }

/* ── link columns ── */
.bf__nav {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 32px clamp(16px, 2.5vw, 40px);
}
.bf__h {
  margin: 0 0 14px;
  font-size: 15px;
  font-weight: 700;
  color: var(--bf-fg);
}
/* minmax(0,1fr), not the implicit auto track: an auto track is sized to
   max-content and overflows its column, which the longer English labels
   did — "Choosing a system for your business" ran over the next column. */
.bf__list {
  margin: 0; padding: 0; list-style: none;
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px;
}
.bf__list a {
  color: var(--bf-fg2);
  text-decoration: none;
  font-size: 15px;
  line-height: 1.4;
  /* The site's bar is a 44px target (README), so the row carries the
     height and the gap shrinks to match. max-content keeps the hover
     area on the words instead of the whole column. */
  display: flex;
  align-items: center;
  min-height: 44px;
  min-width: 44px;   /* the shortest label draws only 40px wide */
  width: max-content;
  max-width: 100%;
}
.bf__list a:hover,
.bf__list a:focus-visible { color: var(--bf-fg); text-decoration: underline; }

/* ── base row: trust badge + copyright ── */
.bf__base {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
  padding-block-start: 28px;
  border-block-start: 1px solid var(--bf-line);
}
.bf__copy { margin: 0; margin-inline-start: auto; color: var(--bf-fg2); font-size: 14px; }

/* ── focus: visible on the dark card, same ring in both languages ── */
.bf a:focus-visible,
.bf button:focus-visible {
  outline: 2px solid var(--bf-mint);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── responsive ── */
@media (max-width: 900px) {
  .bf__card { grid-template-columns: 1fr; gap: 36px; padding: 36px 24px; }
  .bf__nav { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
  .bf { padding: 16px 12px 24px; }
  .bf__card { padding: 28px 20px; border-radius: 22px; gap: 30px; }
  .bf__nav { grid-template-columns: 1fr; gap: 26px; }
  .bf__badges { gap: 8px; }
  .bf__copy { margin-inline-start: 0; width: 100%; }
}

@media (prefers-reduced-motion: no-preference) {
  .bf__list a { transition: color .15s ease; }
}
