/* AFH-LR hero and capability visuals (Riley, 2026-10-28/29), drawn as layout designs (layout-drawing.css). The markup
   comes from tools/product_visuals.py and holds each final frame. With motion, components/afh-lr-hero.js and
   components/afh-lr-capabilities.js play the sequences. Each visual shows a different open-hardware KiCad board by
   another designer (tools/boards); none of them is AFH-LR output. */
@layer pages {
  .ix-lrh-hero .ix-scene__inner{padding:clamp(20px,3svh,40px) 0 clamp(16px,2.5svh,32px);}
  .ix-lrh{--lrh-h:clamp(250px,calc(100svh - 470px),440px);position:relative;margin:clamp(20px,3.5svh,40px) auto 0;height:var(--lrh-h);overflow:hidden;}
  /* The scene is three times as wide as it is tall; narrow frames show its centre. */
  .ix-lrh-svg{position:absolute;left:50%;top:0;height:100%;width:calc(var(--lrh-h) * 3);max-width:none;transform:translateX(-50%);overflow:visible;}

  /* The final frame (Riley, 2026-10-29): the schematic on the left and the routed board on the right, as a centred pair
     in the 1200 x 400 scene. The schematic is 146 x 72.6 mm from its top left; the board is 97 x 50 mm around its
     centre. A frame at least 2.6 times as wide as it is tall shows at least x 80-1120 of the scene; a narrower frame
     shows at least the centre 620 units, so the pair is smaller there. components/afh-lr-hero.js reads these transforms
     and uses the same 2.6 limit. */
  .ix-lrh{container:ix-lrh / size;}
  .ix-lrh-sheet{transform:translate(81.5px,80px) scale(3.3);}
  .ix-lrh-board{transform:translate(881px,200px) scale(4.9);}
  @container ix-lrh (aspect-ratio < 2.6){
    .ix-lrh-sheet{transform:translate(305px,131px) scale(1.9);}
    .ix-lrh-board{transform:translate(756.75px,200px) scale(2.85);}
    /* The smaller board draws its tracks wider in millimetres, so they stay about 1 px wide on phones. */
    .ix-lrh-board .ix-lrh-routes path{stroke-width:.6px;}
  }

  /* The moving symbol copies and the ratsnest show only while the sequence plays. */
  .ix-lrh-cmp .ix-lrh-sym,.ix-lrh-rats{opacity:0;}
  .ix-lrh-board .ix-lrh-sym{display:inline;}

  .ix-lrh-cmp,.ix-lrh-board g{transform-box:view-box;}


  @media(max-width:860px){
    .ix-lrh-hero .ix-scene__inner{padding:var(--ix-space-6) 0;}
    /* The frame shows a 620 x 400 part of the scene, so the wide layout fits on phones. */
    .ix-lrh{--lrh-h:min(calc((100vw - 32px) * .645),360px);margin-top:var(--ix-space-5);}
  }

  /* Capabilities: each feature has its own window (product.css). The visual keeps a 1.6 aspect ratio and fits the window
     height. Each shows one result in front: the selected candidate layout, and the migrated layout. */
  /* Slightly smaller since 2026-11-02 (Riley), so the visual sits beside the text below the title. */
  @media(min-width:1101px){.ix-lr-capabilities .ix-lrc{width:min(100%,720px,calc((100svh - 300px) * 1.6));}}
  .ix-lrc{position:relative;margin:0;aspect-ratio:1.6;}
  .ix-lrc-svg{display:block;width:100%;height:100%;overflow:visible;}

  /* Placement: the inputs and the candidates behind the selected one stay quiet. */
  .ix-lrc-in{opacity:.85;}
  .ix-lrc-outline{fill:none;stroke:#c7d3dc;stroke-width:1px;vector-effect:non-scaling-stroke;}
  .ix-lrc-back{fill:#0a1118;}
  .ix-lrc-depth-2 .ix-lrc-body{opacity:.32;}
  .ix-lrc-depth-1 .ix-lrc-body{opacity:.55;}
  .ix-lrc-pick{fill:none;stroke:var(--ix-ui-blue);stroke-width:1.4;}

  /* Migration: old and new outlines at one scale. The old outline stays as a dashed reference; the old layout itself is
     visible only while the sequence plays. */
  .ix-lrm-old-edge{fill:none;stroke:#8597a5;stroke-width:1px;vector-effect:non-scaling-stroke;stroke-dasharray:5 4;}
  .ix-lrm-old-body>*{opacity:0;}

  /* Moving copies of the component groups exist only during the migration sequence. They carry no copper: the
     connections show as the ratsnest, straight dashed guides from pad to pad that follow the parts and give way to the
     routed tracks. */
  .ix-lrm-ghost{display:none;}
  .ix-lrm-ghost.is-moving{display:inline;}
  .ix-lrm-rats{display:none;}
  .ix-lrm-rats.is-on{display:inline;}
  .ix-lrm-rats path{fill:none;stroke:rgba(226,235,242,.6);stroke-width:1px;vector-effect:non-scaling-stroke;stroke-dasharray:3 3;}
}
