/* ontara.ch homepage, version 7: Home 6 with the scroll tour split (loaded last). From 1100 px the three
 * steps and their explanation sit on the left, the whole app window on the right; the window uses the
 * app's collapsed sidebar (as in Home 5's Command Center window) so its text stays readable next to the
 * column. Below 1100 px the tour stacks as in Home 6. */

/* the window: 1000 × 720 design px with the 56 px icon sidebar, scaled to its box and centred both ways */
.sw .sw__win { width: 1000px; top: var(--y, 0px); }
@media (min-width: 900px) {
  .sw .appw__body { grid-template-columns: 56px minmax(0, 1fr); }
}

/* the steps: a bar, the step label, and (in the split layout) the active step's explanation: a headline
   and one sentence */
.sw__steps > li { display: grid; align-content: start; gap: 10px; }
.sw__steps .sw__step { display: block; }
.sw__more { display: none; }
.sw__vars { display: grid; }
.sw__var { grid-area: 1 / 1; opacity: 0; transition: opacity 0.3s; }
.sw__var.is-on { opacity: 1; }

@media (min-width: 1100px) {
  .sw__in { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); column-gap: 56px; }
  .sw__cap { align-self: center; }
  .sw__texts { display: none; }
  .sw__box { align-self: stretch; margin-top: 0; }

  .sw__steps { flex-direction: column; gap: 2px; }
  .sw__steps > li { position: relative; display: block; padding-left: 28px; }
  .sw__bar { position: absolute; top: 0; bottom: 0; left: 0; width: 2px; height: auto; }
  .sw__bar i { transform: scaleY(var(--p, 0)); transform-origin: 50% 0; }

  /* label: number + name, small; the active one in ink with a blue number */
  .sw__steps .sw__step { width: auto; padding: 13px 0; font-size: 15px; font-weight: 600; letter-spacing: 0; }
  .sw__step em { margin-right: 12px; font-size: 12px; }

  /* the active step opens; the others stay one line */
  .sw__more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.5s var(--ease); }
  .sw__item.is-on .sw__more { grid-template-rows: 1fr; }
  .sw__more > div { min-height: 0; overflow: hidden; }
  .sw__var { padding-bottom: 22px; }
  .sw__lead { margin: 0; font-size: 26px; font-weight: 500; line-height: 1.2; letter-spacing: -0.022em; color: var(--ink); text-wrap: balance; }
  .sw__body { margin: 12px 0 0; font-size: 15.5px; line-height: 1.55; color: var(--muted); text-wrap: pretty; }
}

/* ---- four steps, six views; the scroll position picks the view (home7.js), the Command Center and
   Compliance with a shorter share. The detail panel is view 4 now (Home 6 had it at view 2) ---- */
.sw { --travel: 280vh; } /* the sum of the views' shares in home7.js */
.sw[data-step="2"] .sw__dw { transform: translateX(104%); }
.sw[data-step="2"] .sw-hl { opacity: 0; }
.sw[data-step="4"] .sw__dw { transform: none; }
.sw[data-step="4"] .sw-hl { opacity: 1; }
@media (max-width: 1099px) {
  .sw__steps > li { flex: 1; min-width: 0; }
  .sw__steps .sw__step { width: 100%; }
}
@media (max-width: 640px) {
  .sw__steps > li.is-on { flex: 3; }
  .sw__steps .sw__step { white-space: nowrap; }
  .sw__steps .sw__step:not(.is-on) > span { font-size: 0; }
  .sw__steps .sw__step:not(.is-on) em { margin: 0; font-size: 11.5px; }
}

/* ---- step 02 Data ingest: the app's Files page. Upload tab (the upload follows the scroll), then the
   Check tab (the extracted requirements next to their place in the PDF) ---- */
.fl__title { font-size: 20px; font-weight: 650; letter-spacing: -0.02em; color: var(--ink); }
.fl__sub { margin: 4px 0 0; font-size: 12.5px; color: var(--muted); }
.fl__tabs { display: flex; gap: 4px; margin-top: 14px; border-bottom: 1px solid var(--line); }
.fl__tabs span { display: inline-flex; align-items: center; gap: 6px; margin-bottom: -1px; padding: 9px 12px; border-bottom: 2px solid transparent; font-size: 13px; color: var(--muted); }
.fl__tabs span.on { border-color: var(--accent); font-weight: 500; color: var(--ink); }
.fl__tabs .ic { width: 14px; height: 14px; color: #10b981; }

.fl__drop { position: relative; display: grid; justify-items: center; gap: 4px; margin-top: 16px; padding: 26px 0 24px; border: 2px dashed var(--line-strong); border-radius: 12px; background: #fff; text-align: center; transition: border-color 0.2s, background-color 0.2s; }
.fl__cloud .ic { width: 24px; height: 24px; color: var(--muted); transition: color 0.2s; }
.fl__drop b { font-size: 13px; font-weight: 500; color: var(--ink); }
.fl__drop-b { display: none; }
.fl__hint { font-size: 12px; color: var(--muted); }
.fl__ghost { position: absolute; top: 30%; left: 50%; display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border: 1px solid var(--line-strong); border-radius: 8px; background: #fff; box-shadow: var(--shadow); font-size: 12.5px; font-weight: 500; color: var(--ink); white-space: nowrap; opacity: 0; transform: translate(calc(-50% + (1 - var(--d, 0)) * 300px), calc(-50% - (1 - var(--d, 0)) * 70px)) rotate(calc((1 - var(--d, 0)) * 5deg)); }
.fl__ghost { transition: opacity 0.25s; } /* the file follows the scroll (no easing on its position) */
.sw-scr--up[data-up="0"] .fl__ghost, .sw-scr--up[data-up="1"] .fl__ghost { opacity: 1; }
.sw-scr--up[data-up="1"] .fl__drop { border-color: #2563eb; background: #eff6ff; }
.sw-scr--up[data-up="1"] .fl__cloud .ic { color: #2563eb; }
.sw-scr--up[data-up="1"] .fl__drop-a { display: none; }
.sw-scr--up[data-up="1"] .fl__drop-b { display: block; }
.sw-scr--up[data-up="1"] .fl__ghost { transform: translate(-50%, -50%) rotate(2deg); }

.fl__table { margin-top: 16px; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.fl__tr { display: grid; grid-template-columns: 40px minmax(0, 1fr) 96px 130px 90px; align-items: center; }
.fl__tr > * { padding: 0 8px; }
.fl__th { padding: 8px 0; background: #f7f8fa; font-size: 11px; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.fl__row { padding: 11px 0; border-top: 1px solid var(--line); }
.fl__cb { display: grid; place-items: center; }
.fl__cb .ic { width: 12px; height: 12px; padding: 3px; border-radius: 4px; background: var(--accent); color: #fff; stroke-width: 3; box-sizing: content-box; }
.fl__file { display: flex; align-items: center; gap: 10px; min-width: 0; }
.fl__file > .ic { flex: none; width: 16px; height: 16px; color: var(--muted); }
.fl__file > span { min-width: 0; }
.fl__file b { display: block; overflow: hidden; font-size: 13px; font-weight: 500; color: var(--ink); white-space: nowrap; text-overflow: ellipsis; }
.fl__file em { font-size: 11.5px; font-style: normal; color: var(--muted); }
.fl__type { font-size: 12px; color: var(--ink-2); }
.fl__type em { display: block; font-size: 11px; font-style: normal; color: var(--muted-2); }
.fl__st em { align-items: center; gap: 6px; font-size: 12px; font-style: normal; color: var(--muted); }
.fl__st .fl__st--blue { color: #2563eb; }
.fl__st .fl__st--ok { color: #059669; }
.fl__st--ok .ic { width: 13px; height: 13px; }
.fl__ow { font-size: 12px; color: var(--ink-2); }
.fl__spin { display: inline-block; width: 11px; height: 11px; border: 1.5px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: fl-spin 0.8s linear infinite; }
@keyframes fl-spin { to { transform: rotate(360deg); } }
.fl__empty { padding: 16px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--muted); text-align: center; }
.fl__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: #f7f8fa; font-size: 12.5px; color: var(--ink-2); }
.fl__foot em { font-style: normal; color: var(--muted); }
.fl__go { padding: 7px 14px; border-radius: 8px; background: var(--accent); font-size: 12.5px; font-weight: 550; color: #fff; opacity: 0.45; transition: opacity 0.25s; }
/* the upload's stages (data-up, set by the scroll): 0 coming in, 1 over the drop zone, 2 uploading,
   3 parsing, 4 ready */
.fl__row, .fl__x1, .fl__x2, .fl__x3 { display: none; }
.sw-scr--up:is([data-up="2"], [data-up="3"], [data-up="4"]) .fl__row { display: grid; }
.sw-scr--up:is([data-up="2"], [data-up="3"], [data-up="4"]) .fl__empty { display: none; }
.sw-scr--up[data-up="2"] .fl__x1, .sw-scr--up[data-up="3"] .fl__x2, .sw-scr--up[data-up="4"] .fl__x3 { display: inline-flex; }
.sw-scr--up[data-up="2"] .fl__file .fl__x1, .sw-scr--up[data-up="3"] .fl__file .fl__x2, .sw-scr--up[data-up="4"] .fl__file .fl__x3 { display: block; }
.sw-scr--up[data-up="3"] .fl__foot .fl__x2 { display: inline; }
.sw-scr--up[data-up="4"] .fl__go { opacity: 1; }
.fl__foot { transition: opacity 0.25s; }
.sw-scr--up:is([data-up="0"], [data-up="1"]) .fl__foot { opacity: 0; } /* nothing to extract before a file is in */

.rv__bar { display: flex; align-items: center; gap: 12px; margin-top: 14px; }
.rv__doc { flex: none; padding: 5px 10px; border-radius: 6px; background: var(--accent); font-size: 12px; color: #fff; white-space: nowrap; }
.rv__count { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.rv__count b { font-weight: 600; color: var(--ink); }
.rv__btns { display: flex; gap: 8px; margin-left: auto; }
.rv__btns .mini .ic { width: 12px; height: 12px; }
.rv__body { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 14px; height: 466px; margin-top: 14px; }
.rv__pdf { overflow: hidden; padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: #eef1f5; }
.rv__page { height: 100%; padding: 20px 26px; border-radius: 4px; background: #fff; box-shadow: 0 1px 2px rgba(13, 36, 64, 0.08), 0 6px 18px -8px rgba(13, 36, 64, 0.18); }
.rv__ph { display: flex; justify-content: space-between; padding-bottom: 8px; border-bottom: 1px solid var(--line); font-size: 9.5px; color: var(--muted-2); }
.rv__h { margin: 16px 0 8px; font-size: 12px; font-weight: 600; color: var(--ink); }
.rv__ln { display: block; height: 6px; margin: 7px 0; border-radius: 3px; background: #e6eaf0; }
.rv__ln--m { width: 72%; }
.rv__ln--s { width: 44%; }
.rv__hl { position: relative; margin: 10px -6px 8px; padding: 5px 6px; border-radius: 4px; background: rgba(37, 99, 235, 0.07); box-shadow: inset 2px 0 0 rgba(37, 99, 235, 0.35); font-size: 11.5px; line-height: 1.45; color: var(--ink); }
.rv__hl em { position: absolute; top: -9px; right: 6px; padding: 1px 5px; border-radius: 4px; background: #fff; box-shadow: inset 0 0 0 1px var(--accent-line); font: 500 9.5px/1.4 var(--mono); font-style: normal; color: var(--accent-deep); }
.rv__hl.on { background: rgba(37, 99, 235, 0.15); box-shadow: inset 2px 0 0 var(--accent); }
.rv__list { display: flex; flex-direction: column; gap: 8px; min-height: 0; overflow: hidden; }
.rv__lh { font-size: 12px; color: var(--muted); }
.rv__lh b { font-weight: 600; color: var(--ink); }
.rv__it { padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.rv__it.on { border-color: var(--accent-line); box-shadow: 0 0 0 2px var(--accent-soft); }
.rv__meta { display: flex; align-items: center; gap: 6px; }
.rv__id { font: 500 11px/1 var(--mono); color: var(--muted); }
.rv__risk { padding: 2px 7px; border-radius: 6px; font-size: 10.5px; font-weight: 500; }
.rv__risk--high { background: #fef2f2; color: #dc2626; }
.rv__risk--medium { background: #fffbeb; color: #d97706; }
.rv__risk--low { background: #ecfdf5; color: #059669; }
.rv__pg { margin-left: auto; font: 500 10.5px/1 var(--mono); color: var(--muted-2); }
.rv__it p { margin: 6px 0 0; font-size: 12.5px; line-height: 1.45; color: var(--ink); }
.rv__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 6px; font-size: 11.5px; color: var(--muted); }
.rv__det { font-weight: 500; color: var(--accent-deep); }

@media (max-width: 899px) {
  .fl__sub, .rv__pdf, .rv__count, .rv__btns { display: none; }
  .fl__tr { grid-template-columns: 34px minmax(0, 1fr) auto; }
  .fl__tr > :is(:nth-child(3), :nth-child(5)) { display: none; }
  .fl__foot { flex-wrap: wrap; gap: 8px; }
  .rv__body { grid-template-columns: minmax(0, 1fr); height: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .sw__more, .sw__var, .fl__drop, .fl__go, .fl__ghost { transition: none !important; }
  .fl__spin { animation: none; }
}


/* Capabilities: one line under the headline (Home 6's three-column layout, .va, comes from home6.css) */
.hs__lede { max-width: 36em; margin: 20px 0 0; font-size: 17px; line-height: 1.6; color: var(--muted); }
#capabilities .hs__title { max-width: 22em; } /* each of the two sentences on one line */

/* ---- your advantages: three figures as tiles (pattern from silex.legal, in our own look): the number
   ("up to" small in front) counts up once when the section comes into view, a short strip of the logo's
   blue under it, a short heading, one line, the source in small caps ---- */
#advantages .hs__title { max-width: 22em; }
.adv { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 56px 0 0; padding: 0; list-style: none; }
.adv__i { display: flex; flex-direction: column; padding: 28px 28px 24px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.adv__n { display: flex; align-items: baseline; gap: 10px; font-size: clamp(44px, 4.4vw, 64px); font-weight: 420; line-height: 1; letter-spacing: -0.04em; color: var(--ink); font-variant-numeric: tabular-nums; }
.adv__n em { font-size: 15px; font-style: normal; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.adv__ln { display: block; width: 36px; height: 3px; margin-top: 20px; border-radius: 2px; background: linear-gradient(90deg, #027dfe, #06c1fe); }
.adv__t { margin: 20px 0 0; font-size: 18px; font-weight: 600; line-height: 1.3; letter-spacing: -0.015em; color: var(--ink); }
.adv__d { margin: 8px 0 0; font-size: 15px; line-height: 1.55; color: var(--muted); }
.adv__s { margin-top: auto; padding-top: 22px; font: 500 11px/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted-2); }
@media (max-width: 899px) {
  .adv { grid-template-columns: minmax(0, 1fr); gap: 12px; max-width: 560px; }
}
@media (max-width: 759px) { .adv { margin-top: 40px; } .adv__i { padding: 24px 22px 20px; } }
