
  /* ============================================================
     CANARDLY DESIGN SYSTEM v5.6.2 — Standardized Background System
     Three visual environments only: Navigation / Workspace / Course Play.
     Course Play (Hole, Add Score, Scorecard, Caddie) keeps its own
     dedicated background treatment and is fully excluded below —
     no changes to that environment.
     ============================================================ */

  /* -- 1. NAVIGATION BACKGROUND -----------------------------------
     Pages built around the large rounded navigation buttons/cards:
     Splash, The Links, Community, Clubhouse, Select Course, Choose
     Tees, Round Setup, Practice Games, Solo Games (and future nav
     pages should be added to this selector list).
     Same exact Canardly palette (#f5f0e8 cream / #7b8ab4 light-indigo /
     #56659a medium indigo / #35426f medium-dark indigo / #1e3a5f dark
     indigo/navy / #0f1e30 deep navy).

     SPLASH is intentionally NOT listed here: it has no header to clear,
     and its transition points are positioned from the real rendered
     logo/button-group locations by canardlyPositionSplashBackground()
     (bottom of file), which writes directly to #screen-splash's own
     inline style. Including it in this !important rule would permanently
     win over that JS-computed value, so it keeps its own dedicated CSS
     rule (see #screen-splash above) as a static pre-JS fallback only.

     Every other Navigation page has a header, so the gradient is painted
     on the content box that already starts immediately below the header
     and ends at the screen's bottom edge — never on the .screen element
     itself — so the header is never covered by it. That content box is
     .screen-body on the six pages using the standard header/.screen-body
     markup, and the .canardly-nav-body hook class (added purely as a
     background/selector target, no other styles touched) on the two
     pages with bespoke inline-styled headers. Proportions (25% light /
     mid-tone ramp to 75% / dark to 100%, darkest weighted to the final
     ~45% of the dark band) are calculated against that content box's own
     height, i.e. the true usable area — not the full screen including
     the header. var(--canardly-footer-h, 0px) is subtracted from the
     final stop so a future footer page can reserve space for a footer
     by setting that one variable inline; no footer exists on any current
     Navigation page, so it defaults to 0 and has no effect today. */
  #screen-path-select > .canardly-nav-body,
  #screen-community > .screen-body,
  #screen-clubhouse > .screen-body,
  #screen-courses > .screen-body,
  #screen-tee > .screen-body,
  #screen-play-setup > .screen-body,
  #screen-training > .screen-body,
  #screen-solo-games > .canardly-nav-body,
  #screen-solo-play > .canardly-nav-body {
    background: linear-gradient(180deg,
      #f5f0e8 0%,
      #f5f0e8 25%,
      #7b8ab4 50%,
      #56659a 66%,
      #35426f 75%,
      #1e3a5f 86.25%,
      #0f1e30 calc(100% - var(--canardly-footer-h, 0px))
    ) !important;
  }

  /* v7.6.19 — THE LINKS iPHONE SCROLL FIX, SCREEN-LEVEL SCROLLER
     v7.6.18 kept scrolling on a nested flex child; iPhone Safari still
     trapped that region and left Training Ground below the reachable area.
     Remove the nested scroller entirely: the active Links screen itself is
     the vertical scroll container, the header stays sticky, and the card
     region grows naturally to its full content height. This mirrors ordinary
     document scrolling and avoids Safari flex-height/overflow edge cases. */
  #screen-path-select.active {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    min-height: 0 !important;
    -webkit-overflow-scrolling: touch !important;
    touch-action: pan-y;
    overscroll-behavior-y: contain;
    align-items: stretch !important;
  }
  #screen-path-select > :first-child {
    position: sticky;
    top: 0;
    z-index: 30;
    flex-shrink: 0;
  }
  #screen-path-select > .canardly-nav-body {
    flex: 0 0 auto !important;
    height: auto !important;
    min-height: auto !important;
    overflow: visible !important;
    -webkit-overflow-scrolling: auto !important;
    touch-action: auto;
    overscroll-behavior: auto;
    position: relative;
    padding-bottom: max(40px, calc(env(safe-area-inset-bottom, 0px) + 28px)) !important;
  }


  /* -- 2. WORKSPACE BACKGROUND -------------------------------------
     Default background for every remaining non-playing screen —
     My Bag, Club Used, 19th Hole, My Trends, Statistics, Round
     History, Admin, Settings, lists, tables, forms, equipment pages,
     and any other information-focused page. Quiet, subtle, high
     text contrast, no decorative effects: content stays the focus.
     Applied as the catch-all so future workspace pages inherit it
     automatically without needing to be listed individually. */
  .screen:where(:not(:is(#screen-multiplayer-setup,#screen-multiplayer-play,#screen-multiplayer-card,#screen-multiplayer-results,#screen-groups,#screen-mod2-challenges,#screen-mod2-challenge-setup,#screen-mod2-challenge-detail,#screen-chall-invite-detail,#screen-chall-opponent-setup,#screen-chall-match-setup))):not(#screen-splash):not(#screen-path-select):not(#screen-community):not(#screen-clubhouse):not(#screen-courses):not(#screen-tee):not(#screen-play-setup):not(#screen-training):not(#screen-solo-games):not(#screen-solo-play):not(#screen-hole):not(#screen-v3-scoring):not(#screen-scorecard):not(#screen-caddie) {
    /* v5.6.5 — FUNCTIONAL page background replaced per directive: instead of the
       cream + indigo-corner-tint treatment, this now uses a flat, quiet tone
       sampled from the lighter-middle portion of the Canardly gradient (the
       champagne-into-sage transition band, ~25-40% down the splash ramp) — a
       soft muted sage — with only a hint of vertical depth. No radial corner
       glow, no bottom indigo band: the goal is a page that immediately reads
       as "Canardly" without competing with the white cards/forms/tables on it. */
    background: linear-gradient(180deg, #eef1ec 0%, #e7ebe2 100%) !important;
  }
  .screen:where(:not(:is(#screen-multiplayer-setup,#screen-multiplayer-play,#screen-multiplayer-card,#screen-multiplayer-results,#screen-groups,#screen-mod2-challenges,#screen-mod2-challenge-setup,#screen-mod2-challenge-detail,#screen-chall-invite-detail,#screen-chall-opponent-setup,#screen-chall-match-setup))):not(#screen-splash):not(#screen-path-select):not(#screen-community):not(#screen-clubhouse):not(#screen-courses):not(#screen-tee):not(#screen-play-setup):not(#screen-training):not(#screen-solo-games):not(#screen-solo-play):not(#screen-hole):not(#screen-v3-scoring):not(#screen-scorecard):not(#screen-caddie) > .screen-body {
    background: transparent !important;
  }
