/* Platform responsive corrections for the approved AUTORIXA design (no visual redesign).
   1) Tablet (761–960px): the full menu did not fit; use the design's own mobile menu.
   2) Phones: grid columns may shrink below their content width (no sideways scroll). */
@media (max-width:960px){
  body>header{flex-wrap:wrap}
  body>header #menu-toggle{display:block;border:1px solid var(--line);background:#fff;border-radius:6px;padding:8px 12px;font-size:13px}
  body>header #navigation{display:none;width:100%;align-items:stretch;flex-direction:column;gap:0}
  body>header #navigation.open{display:flex}
  body>header #navigation a{padding:12px}
  body>header #navigation{align-items:center;text-align:center}
  body>header #navigation .button{align-self:center}
  body>header .nav-login{border:0;padding-left:0}
  body>header .nav-drop>div{position:static;box-shadow:none;min-width:0}
}
@media (max-width:760px){
  .split,.split.brain,.pricing-grid,.service-grid{grid-template-columns:minmax(0,1fr)}
}

/* Let the diagram participate in normal document flow at phone widths. */
@media (max-width:760px){
  .ecosystem{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    align-items:stretch;
    gap:10px;
    height:auto;
    min-height:0;
    aspect-ratio:auto;
  }
  .ecosystem>.orbit-lines{display:none}
  .ecosystem>.orb{
    position:static;
    grid-column:1/-1;
    justify-self:center;
    display:flex;
    flex-direction:column;
    width:132px;
    height:132px;
    box-sizing:border-box;
    min-width:0;
    min-height:0;
    padding:12px;
    gap:4px;
    font-size:13px;
  }
  .ecosystem>.orb img{width:76px;height:auto;margin:0}
  .ecosystem>.node{
    position:static;
    width:auto;
    min-width:0;
    min-height:56px;
    font-size:13px;
    overflow-wrap:anywhere;
  }
  .ecosystem>.node:last-child:nth-of-type(odd){
    grid-column:1/-1;
    width:calc((100% - 10px)/2);
    justify-self:center;
  }
}

.ax-action-menu {
  display: block;
  width: 100%;
  min-width: 0;
  color: #09243a;
  text-align: left;
}
.ax-action-menu h2 {
  margin: 0 0 12px;
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1.2;
}
.ax-action-menu a {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) 9px;
  align-items: center;
  gap: 14px;
  min-height: 48px;
  padding: 9px 6px;
  box-sizing: border-box;
  border-bottom: 1px solid #dedbd6;
  color: inherit;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
  text-decoration: none;
}
.ax-action-menu a svg { width: 24px; height: 24px; color: #008b91; }
.ax-action-menu a::after {
  content: "";
  width: 7px;
  height: 7px;
  border: solid currentColor;
  border-width: 1.5px 1.5px 0 0;
  transform: rotate(45deg);
}
.ax-action-menu a:hover, .ax-action-menu a:focus-visible { background: #edf7f5; }

/* Center the Company Brain within its own diagram at every column width. */
@media (min-width:761px) {
  .ecosystem {
    min-height:310px;
  }
  .ecosystem > .orb {
    left:50%;
    top:50%;
    transform:translate(-50%, -50%);
    box-sizing:border-box;
    width:clamp(96px, 27%, 150px);
    height:auto;
    min-width:0;
    min-height:0;
    aspect-ratio:1;
    padding:8px;
  }
  .ecosystem > .n1 {
    left:50%;
    transform:translateX(-50%);
  }
}
@media (max-width:760px) {
  .ecosystem > .orb {
    margin-inline:auto;
    transform:none;
    align-items:center;
    justify-content:center;
  }
}

/* Company Brain orb: centred in the open space between the product cards
   (equal clearance to the nearest cards), never on top of a card.
   Laptop/tablet: the centre of the largest card-free circle sits at 40% of the
   diagram height (39% in the compact reference layout). Phones: a smaller orb
   in its own row between the card rows (two rows above, two below). */
@media (min-width:761px) {
  .ecosystem > .orb { top:40%; }
  .reference-brain-faq .ecosystem > .orb { top:39%; }
}
@media (max-width:760px) {
  .ecosystem > .orb {
    grid-row:3;
    width:112px;
    height:112px;
    padding:10px;
    gap:3px;
    margin-block:4px;
    font-size:12px;
    line-height:1.2;
  }
  .ecosystem > .orb img { width:60px; }
}
