/* ontara.ch homepage, version 9: Home 8 with the cofounder's text polish (loaded last). New here: connected
 * sources (project data + the rules that apply) as a small graph at the bottom of the Command Center, the industries as a horizontal slider (five
 * industries), and a closing "Book a demo" band before the footer. */

/* ---- Command Center: sources. Your project data (left) and the rules that apply (right) both flow into Ontara ---- */
.sy { margin-top: 12px; padding: 12px 14px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.sy__head { display: flex; align-items: baseline; gap: 10px; }
.sy__head b { font-size: 13px; font-weight: 650; color: var(--ink); }
.sy__head span { font-size: 11px; color: var(--muted); }
.sy__ok { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-size: 11px; font-style: normal; color: var(--muted); }
.sy__ok i { width: 7px; height: 7px; border-radius: 50%; background: #16a34a; }
.sy__g { display: grid; grid-template-columns: 196px minmax(0, 1fr) 160px minmax(0, 1fr) 196px; align-items: center; height: 100px; margin-top: 10px; }
.sy__col { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.sy__n { display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; align-items: center; column-gap: 8px; height: 28px; padding: 0 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); font-size: 11.5px; color: var(--ink-2); }
.sy__n .ic { width: 14px; height: 14px; color: var(--muted); }
.sy__col--r .ic { color: var(--accent); } /* the rules */
.sy__n b { overflow: hidden; font-weight: 550; white-space: nowrap; text-overflow: ellipsis; }
.sy__n span { font-size: 10.5px; color: var(--muted-2); white-space: nowrap; }
.sy__ln { width: 100%; height: 100px; overflow: visible; }
.sy__ln path { fill: none; stroke: #b4c3d6; stroke-width: 1.25; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.sy__hub { display: grid; justify-items: center; gap: 2px; padding: 10px 8px; border: 1px solid var(--accent-line); border-radius: 8px; background: var(--accent-soft); text-align: center; }
.sy__hub img { width: 22px; height: 22px; margin-bottom: 3px; }
.sy__hub b { font-size: 12px; font-weight: 650; color: var(--ink); }
.sy__hub span { font-size: 10.5px; color: var(--muted); }
/* while the Command Center is on screen, the lines flow into Ontara from both sides */
.sw[data-step="0"] .sy__ln path { animation: sy-flow 1.4s linear infinite; }
.sw[data-step="0"] .sy__ln--out path { animation-direction: reverse; }
@keyframes sy-flow { to { stroke-dashoffset: -14; } }
@media (prefers-reduced-motion: reduce) { .sy__ln path { animation: none !important; } }
@media (max-width: 899px) { .sy { display: none; } } /* phones: the window re-flows and is cut off there anyway */

/* ---- Industries: a horizontal slider inside the page column (like Stripe, Ramp, Harvey): about 3.3 cards fit
   at every width (2.3 on tablets, one and a bit on phones), so a part of the next card always shows; arrows on
   the right of the headline, swipe / trackpad / keyboard work too ---- */
.in9__top { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.in9__nav { display: flex; flex: none; gap: 8px; }
.in9__b { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line-strong); border-radius: 50%; background: #fff; color: var(--ink); cursor: pointer; transition: border-color 0.2s, opacity 0.2s; }
.in9__b:hover { border-color: var(--ink-2); }
.in9__b:focus-visible { outline: 3px solid var(--accent-line); outline-offset: 2px; }
.in9__b .ic { width: 18px; height: 18px; }
.in9__b[data-dir="-1"] .ic { transform: scaleX(-1); }
.in9__b[aria-disabled="true"] { opacity: 0.35; cursor: default; }
.in9__b[aria-disabled="true"]:hover { border-color: var(--line-strong); }
#industries .in.in9 { display: flex; gap: 24px; padding: 0 0 4px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
#industries .in9::-webkit-scrollbar { display: none; }
#industries .in9:focus-visible { outline: 3px solid var(--accent-line); outline-offset: 6px; border-radius: 8px; }
.in9 > .in__i { flex: 0 0 calc((100% - 3 * 24px) / 3.3); scroll-snap-align: start; }
@media (max-width: 1099px) { .in9 > .in__i { flex-basis: calc((100% - 2 * 24px) / 2.3); } }
@media (max-width: 759px) {
  #industries .in.in9 { gap: 16px; }
  .in9 > .in__i { flex-basis: 80%; }
  .in9__nav { display: none; } /* phones swipe */
}

/* ---- closing call to action: one dark band before the footer ---- */
.ce { background: var(--band-dark); color: #fff; text-align: center; }
.ce__in { display: grid; justify-items: center; }
.ce .ce__t { max-width: 18em; color: #fff; }
.ce__p { max-width: 34em; margin: 16px 0 0; font-size: 18px; line-height: 1.55; color: #b4c2d3; }
.ce__a { display: flex; flex-direction: column; align-items: center; gap: 16px; margin-top: 16px; } /* the button centred, the e-mail line under it */
/* plain text, the address as a link like the founders' e-mails (light blue on the dark band, underline on hover) */
.ce__mail { font-size: 15px; color: #b4c2d3; }
.ce__mail a { color: #6fb6ff; text-decoration: none; }
.ce__mail a:hover { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 759px) { .ce__p { font-size: 16px; } }

/* ---- About: each founder's e-mail under the role ---- */
.fd__m { width: fit-content; margin-top: 4px; font-size: 13.5px; line-height: 1.45; color: var(--accent-deep); text-decoration: none; }
.fd__m:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---- the register's requirement count: 3,184 like the rest of the demo (the old .cnt was a CSS counter set to
   214, which cannot show a thousands separator), same look ---- */
.cnt9 { font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; }

/* ---- phones: Capabilities and Your advantages as swipe sliders (like the industries); dots under all three
   phone sliders show where you are (home9.js adds them) ---- */
.sl-dots { display: none; }
@media (max-width: 759px) {
  #advantages .adv { display: flex; gap: 12px; max-width: none; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
  #advantages .adv::-webkit-scrollbar { display: none; }
  #advantages .adv > .adv__i { flex: 0 0 82%; scroll-snap-align: start; }
  #capabilities .va { display: flex; gap: 24px; max-width: none; padding-top: 2px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; } /* 2px: room for the blue bar on top */
  #capabilities .va::-webkit-scrollbar { display: none; }
  #capabilities .va > .va__c { flex: 0 0 85%; scroll-snap-align: start; }
  .sl-dots { display: flex; justify-content: center; gap: 8px; margin-top: 20px; }
  .sl-dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 4px; background: var(--line-strong); cursor: pointer; transition: width 0.25s, background 0.25s; }
  .sl-dots button.is-on { width: 20px; background: var(--accent); }
  #advantages .sl-dots button { background: rgba(255, 255, 255, 0.22); }
  #advantages .sl-dots button.is-on { background: #6fb6ff; }
}

/* ---- the scroll demo on phones (below 900 px): every screen shows its key moment without being cut off.
   Desktop and tablet stay as they are ---- */
@media (max-width: 899px) {
  /* steps: the active step gets the room its name needs, the others shrink to their number (no collision) */
  .sw__steps li { flex: 1 1 0; }
  .sw__steps li.is-on { flex: 4 1 auto; }
  .sw__step span { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .sw__text { font-size: 16px; font-weight: 600; line-height: 1.3; color: var(--ink); }
  .sw__box { margin-top: 12px; }

  /* 1 Command Center: the four numbers as a 2 x 2 grid, then the sources graph, stacked */
  .sw-scr--cc .ov-fw__next { font-size: 11.5px; }
  .sw-scr--cc .ov-fw__eyebrow { display: none; } /* "Command Center" is already the step name */
  .sw-scr--cc .ov-g { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
  .sw-scr--cc .ov-sc { min-height: 0; }
  .sw-scr--cc .ov-sc__p, .sw-scr--cc .ov-sc__cta, .sw-scr--cc .ov-sc__head em { display: none; }
  .sw-scr--cc .ov-sc__in { padding: 10px 11px; }
  .sw-scr--cc .ov-sc__head { overflow: hidden; font-size: 11px; white-space: nowrap; text-overflow: ellipsis; }
  .sw-scr--cc .ov-sc__v { margin-top: 8px; }
  .sw-scr--cc .ov-sc__v b { font-size: 22px; }
  .sw-scr--cc .ov-sc__v span { font-size: 11px; }
  .sw-scr--cc .ov-sc__s { align-items: flex-start; margin-top: 6px; font-size: 10.5px; line-height: 1.35; }
  .sw-scr--cc .sy { display: block; margin-top: 10px; padding: 10px 12px 12px; }
  .sw-scr--cc .sy__head span { display: none; }
  .sw-scr--cc .sy__g { display: grid; grid-template-columns: minmax(0, 1fr); height: auto; margin-top: 10px; }
  .sw-scr--cc .sy__ln { display: none; }
  .sw-scr--cc .sy__col { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .sw-scr--cc .sy__n { position: relative; grid-template-columns: minmax(0, 1fr); justify-items: center; row-gap: 3px; height: auto; padding: 7px 4px; text-align: center; }
  .sw-scr--cc .sy__n b { font-size: 10.5px; line-height: 1.2; white-space: normal; }
  .sw-scr--cc .sy__n span { display: none; }
  .sw-scr--cc .sy__col:not(.sy__col--r) .sy__n::after, .sw-scr--cc .sy__col--r .sy__n::before { content: ""; position: absolute; left: 50%; height: 12px; border-left: 1.25px dashed #b4c3d6; }
  .sw-scr--cc .sy__col:not(.sy__col--r) .sy__n::after { top: 100%; }
  .sw-scr--cc .sy__col--r .sy__n::before { bottom: 100%; }
  .sw-scr--cc .sy__hub { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 12px 0; padding: 7px; }
  .sw-scr--cc .sy__hub img { width: 18px; height: 18px; margin: 0; }

  /* 3 Check: a cut-out of the PDF page with the highlighted requirement above the list */
  .sw-scr--rv .rv__pdf { display: block; height: auto; padding: 8px 10px; }
  .sw-scr--rv .rv__page { height: auto; padding: 12px 14px 14px; }
  .sw-scr--rv .rv__page > :nth-child(n + 8) { display: none; } /* the page cut after the highlighted requirement */
  .sw-scr--rv .rv__hl { margin: 12px 0 6px; } /* inside the page, no longer wider than the text */
  .sw-scr--rv .rv__list > .rv__it:nth-child(n + 3) { display: none; } /* one extracted requirement under the page */
  .sw-scr--rv .rv__h + .rv__ln, .sw-scr--rv .rv__h + .rv__ln + .rv__ln { display: none; } /* the highlight right under the heading */
  .sw-scr--rv .rv__body { gap: 10px; margin-top: 10px; }

  /* 4 Register: no file strip, one compact line per requirement, so all seven rows (incl. NEW) fit */
  .sw-scr--req .imp, .sw-scr--req .rgt__head, .sw-scr--req .rq__l, .sw-scr--req .rq__p, .sw-scr--req .rgt__row > .st { display: none; }
  .sw-scr--req .rgt__row { padding: 9px 0; }
  .sw-scr--req .rq__t { font-size: 13px; }

  /* 5 Detail: Characteristics (status, owner pickers) step aside, so the Cyber Resilience Act obligation shows */
  .sw__dw .rs:has(.rd__props) { display: none; }

  /* 6 Compliance: the result, then the issue and the gaps; the regulations box and the table headings go */
  .sw-scr--comp .cp__regs, .sw-scr--comp .cp__t--h, .sw-scr--comp .cp__tiles em { display: none; }
  .sw-scr--comp .cp__score b { font-size: 30px; }
  .sw-scr--comp .cp__sum { padding: 12px 14px; }
  .sw-scr--comp .cp__card { margin-top: 8px; }
}

/* ---- phones, round 2: the screens fit their window at real phone heights (the browser bars take room), so
   nothing runs into the bottom; on shorter screens the less important details step aside. The soft fade at
   the bottom only shows when a screen still doesn't fit (home9.js sets .is-cut) ---- */
@media (max-width: 899px) {
  .sw-scr::after { display: none; }
  .sw-scr.is-cut::after { display: block; }
  .sw__dw .rs--closed { display: none; } /* Traceability, Activity, Comments: closed anyway */
}
@media (max-width: 899px) and (max-height: 760px) {
  .sw-scr--cc .ov-fw__next { display: none; }
  .sw-scr--cc .ov-sc__in { padding: 9px 10px; }
  .sw-scr--cc .ov-sc__v { margin-top: 6px; }
  .sw-scr--cc .ov-fw__title { font-size: 17px; }
  .sw-scr--cc .ov-g { gap: 6px; margin-top: 8px; }
  .sw-scr--cc .sy { margin-top: 8px; padding: 9px 10px 10px; }
  .sw-scr--cc .sy__g { margin-top: 8px; }
  .sw-scr--cc .sy__n { padding: 5px 4px; }
  .sw-scr--cc .sy__hub { margin: 10px 0; padding: 6px; }
  .sw-scr--cc .sy__col:not(.sy__col--r) .sy__n::after, .sw-scr--cc .sy__col--r .sy__n::before { height: 10px; }
  .sw-scr--rv .rv__bar { display: none; } /* the page header names the document */
  .sw-scr--rv .fl__head, .sw-scr--up .fl__head { display: none; }
  .sw-scr--up .fl__drop { padding: 16px 0 14px; }
  .sw-scr--req .rgt__row { padding: 7px 0; }
  .sw__dw .rd__why { display: none; }
}
@media (max-width: 899px) and (max-height: 650px) {
  /* short screens (small phones with the browser bars): the demo keeps its point, details go */
  .sw-scr--cc .ov-fw__title { display: none; }
  .sw-scr--cc .ov-sc__head { font-size: 10.5px; }
  .sw-scr--cc .ov-sc__v b { font-size: 20px; }
  .sw-scr--up .fl__drop { padding: 12px 0 10px; }
  .sw-scr--up .fl__tabs, .sw-scr--rv .fl__tabs { display: none; }
  .sw-scr--rv .rv__list > .rv__it { display: none; }
  .sw-scr--req .appw__head { padding-bottom: 4px; }
  .sw-scr--req .rgt__row:nth-child(5) { display: none; }
  .sw__dw .rd__badges { display: none; }
  .sw-scr--comp .cp__score b { font-size: 26px; }
  .sw-scr--comp .cp__bar { margin-top: 8px; }
  .sw-scr--comp .cp__title { font-size: 16px; }
  .sw-scr--comp .cp__sum { padding: 10px 12px; }
  .sw-scr--comp .cp__ch { padding: 7px 12px; }
  .sw-scr--comp .cp__t { padding: 6px 12px; }
  .sw-scr--comp .cp__rq > span, .sw-scr--comp .cp__rg > span { display: none; }
  .sw-scr--cc .sy__head { display: none; }
  .sw-scr--cc .sy__g { margin-top: 0; }
  .sw-scr--up .fl__foot { margin-top: 10px; }
  .sw-scr--up .fl__table { margin-top: 10px; }
}
@media (max-width: 899px) and (max-height: 680px) {
  .sw-scr--cc .ov-sc__s { display: none; }
  .sw-scr--up .fl__hint { display: none; }
  .sw-scr--req .rgt__row:nth-child(6), .sw-scr--req .rgt__row:nth-child(7) { display: none; } /* HC-260, HC-310: the NEW row stays */
  .sw__dw .rd__src { display: none; }
  .sw-scr--comp .cp__tiles { display: none; }
}

/* ---- phones: the demo full screen. A button on the window opens it: the demo covers the screen (the page
   header too) and still follows the page scroll; the X, Esc or scrolling past its start or end closes it ---- */
.sw__fs, .sw__fsx { display: none; }
@media (max-width: 899px) {
  .sw__fs { position: absolute; top: 7px; right: 8px; z-index: 3; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: 6px; background: #fff; font: 500 12px/1 var(--sans); color: var(--ink-2); cursor: pointer; }
  .sw__fs .ic { width: 13px; height: 13px; }
  .sw__fs:focus-visible, .sw__fsx:focus-visible { outline: 3px solid var(--accent-line); outline-offset: 2px; }
  .sw.is-full .sw__stage { position: fixed; inset: 0; z-index: 100; height: 100vh; height: 100dvh; background: var(--bg); }
  .sw.is-full .sw__in { padding: 14px 16px calc(16px + env(safe-area-inset-bottom, 0px)); }
  .sw.is-full .sw__steps { padding-right: 44px; }
  .sw.is-full .sw__fs { display: none; }
  .sw.is-full .sw__fsx { position: absolute; top: 8px; right: 10px; z-index: 3; display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid var(--line-strong); border-radius: 50%; background: #fff; color: var(--ink); cursor: pointer; }
  .sw.is-full .sw__fsx .ic { width: 16px; height: 16px; }
}
