/* src/components/DemoBlock/DemoBlock.css */
/* Layout spec §4 + `Home2.dc.html`/`Home1024.dc.html`/`HomeMobile.dc.html`:
   a full-bleed amber band, no radius — not a card. `.oj-demo-block` breaks
   out of `<main>`'s own max-width the same way `Header`/`Footer` sit outside
   it: a full-width box with only vertical padding, an inner row capped at
   1320px re-applying the shared side padding. The negative-margin breakout
   is why `base.css` sets `overflow-x: hidden` on `html` — `100vw` in the
   `calc()` below includes the scrollbar gutter some browsers give it, which
   would otherwise add a few px of horizontal scroll on every page. */
.oj-demo-block {
  background-color: var(--oj-amber);
  /* The mockup's own decorative pattern: a rounded-square grid fading in
     from the right, behind the number. Desktop/tablet only — `HomeMobile.
     dc.html`'s section has no background-image at all. */
  background-image:
    linear-gradient(90deg, var(--oj-amber) 42%, rgba(240, 180, 65, 0) 78%),
    url("data:image/svg+xml;utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27130%27%20height%3D%27130%27%3E%3Crect%20width%3D%27112%27%20height%3D%27112%27%20rx%3D%2732%27%20fill%3D%27rgba%2815%2C18%2C51%2C0.05%29%27%2F%3E%3C%2Fsvg%3E");
  background-size:
    auto,
    130px 130px;
  background-position:
    0 0,
    right -10px top 22px;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 96px 0;
}

.oj-demo-block__inner {
  /* content-box: see ../Header/Header.css for why — same container bug. */
  box-sizing: content-box;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 64px;
}

.oj-demo-block__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 24px;
  max-width: 760px;
}

.oj-demo-block__text h2 {
  margin: 0;
  font-family: var(--oj-font-display);
  font-weight: 600;
  font-size: 72px;
  line-height: 1.02;
  letter-spacing: -0.045em;
  color: var(--oj-ink);
}

.oj-demo-block__description {
  margin: 0;
  max-width: 640px;
  font-size: 22px;
  line-height: 1.5;
  color: var(--oj-ink);
}

.oj-demo-block__cta {
  margin-top: 12px;
  background: var(--oj-ink);
}

/* the ink button on yellow lightens to navy, as on the B2C home's yellow
   block (owner's call, 22.10: an 8% darkening of ink could not be seen) */
.oj-demo-block__cta:hover {
  background: var(--oj-navy);
  color: #fff;
}

.oj-demo-block__minutes {
  margin: 0;
  flex: none;
  display: flex;
  align-items: baseline;
  gap: 16px;
  font-family: var(--oj-font-display);
  font-weight: 600;
  color: var(--oj-ink);
}

.oj-demo-block__value {
  font-size: 300px;
  line-height: 0.8;
  letter-spacing: -0.07em;
}

.oj-demo-block__label {
  font-size: 34px;
  letter-spacing: -0.03em;
}

@media (max-width: 1279px) {
  .oj-demo-block__inner {
    gap: 48px;
  }

  .oj-demo-block__text {
    max-width: 560px;
  }

  .oj-demo-block__text h2 {
    font-size: 64px;
  }

  .oj-demo-block__minutes {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .oj-demo-block__value {
    font-size: 200px;
    letter-spacing: -0.06em;
  }

  .oj-demo-block__label {
    font-size: 28px;
    padding-left: 8px;
  }
}

/* Layout spec §3's container table: side padding steps to 40px at the 768
   tablet tier (60px above it, 20px below 767) — this file only had the
   1279 and 767 steps, so at exactly 768 the "минут" column (`flex: none`)
   and the text column's own longest word together needed a few px more
   than the still-60px-padded row gave them (item 3). */
@media (max-width: 1023px) {
  .oj-demo-block__inner {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media (max-width: 767px) {
  .oj-demo-block {
    background-image: none;
    padding: 56px 0;
  }

  .oj-demo-block__inner {
    padding: 0 20px;
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 18px;
  }

  .oj-demo-block__text {
    max-width: none;
    gap: 18px;
  }

  .oj-demo-block__text h2 {
    font-size: 36px;
    line-height: 1.06;
    letter-spacing: -0.04em;
  }

  .oj-demo-block__description {
    max-width: none;
    font-size: 18px;
  }

  .oj-demo-block__cta {
    margin-top: 8px;
    width: 100%;
  }

  .oj-demo-block__minutes {
    flex-direction: row;
    align-items: baseline;
    gap: 10px;
  }

  .oj-demo-block__value {
    font-size: 150px;
    letter-spacing: -0.07em;
  }

  .oj-demo-block__label {
    font-size: 24px;
    padding-left: 0;
  }
}


/* src/pages/Connectors.css */
/* Layout spec: Integrations.dc.html (1440 & 1024 measure identically — one
   breakpoint at 767 is enough, see Connectors.tsx) / IntegrationsMobile.dc.html (390). */

/* `client/connectors.ts` toggles cards/empty-state/pagination through the
   native `hidden` IDL property. The UA stylesheet's `[hidden] { display:
   none }` and this file's own `display: flex/grid` rules below have equal
   selector specificity, so source order alone would decide the winner —
   fragile. This rule outranks both on purpose, everywhere under this page,
   so `hidden` always wins. */
[data-js="connectors"] [hidden] {
  display: none !important;
}

.oj-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* `<main>` carries no box model of its own (styles/base.css): each section
   owns the "full width, inner max-width 1320px + side padding,
   box-sizing: content-box" shape Header/Footer/DemoBlock use. Neither
   section here needs the full-bleed breakout those use (no section-wide
   background), so the padding sits directly on the section. Desktop values
   measured on both Integrations.dc.html and Integrations1024.dc.html (they
   match exactly); 768-1023 keeps the same vertical rhythm with the
   sitewide 40px side padding (layout spec §3's container table; no
   dedicated 768 artboard exists for this page). */
/* A flex item of `main` with auto side margins does not stretch — it
   shrinks to its content (the 1000px title), and then centres: at 1440 the
   title sat 160px right of the column. Full width, capped at the column plus
   its side padding, centred — the same shape as the catalog below. */
.oj-connectors-hero {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(1320px + 2 * 60px);
  margin: 0 auto;
  padding: 72px 60px 56px;
  display: flex;
  flex-direction: column;
}

.oj-connectors-hero__title {
  margin: 0;
  max-width: 1000px;
  font-family: var(--oj-font-display);
  font-weight: 600;
  font-size: 88px;
  line-height: 1;
  letter-spacing: -0.05em;
  color: var(--oj-navy);
}

.oj-connectors-hero__text {
  margin: 36px 0 0;
  max-width: 900px;
  font-family: var(--oj-font-body);
  font-weight: 400;
  font-size: 24px;
  line-height: 1.5;
  color: var(--oj-text);
}

/* `main` (styles/base.css) is `display: flex; flex-direction: column`; this
   section is its flex item, and — like Compare.css's `.oj-compare` —
   stretch does not shrink it below the category tab strip's scrollable
   content width even with `min-width: 0` alone. `width: 100%` forces the
   viewport-constrained size; `border-box` plus a max-width inflated by the
   60+60 side padding keeps the content area at exactly 1320px past that
   (see Compare.css for the longer version of this workaround). */
.oj-connectors-catalog {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(1320px + 120px);
  min-width: 0;
  margin: 0 auto;
  padding: 0 60px 96px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

@media (max-width: 1023px) {
  .oj-connectors-hero,
  .oj-connectors-catalog {
    padding-left: 40px;
    padding-right: 40px;
  }
}

.oj-connectors-catalog h1 {
  margin: 0 0 4px;
  font-family: var(--oj-font-display);
  font-weight: 600;
  font-size: 36px;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--oj-navy);
}

.oj-connectors__search {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 72px;
  padding: 0 24px;
  border-radius: var(--oj-r-xl);
  background: var(--oj-surface);
  box-shadow:
    0 0 0 2px var(--oj-cyan),
    0 0 0 7px rgba(34, 195, 219, 0.18);
}

.oj-connectors__search-icon {
  flex: none;
  display: block;
  color: var(--oj-navy);
}

.oj-connectors__search-input {
  flex-grow: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  font-family: inherit;
  font-size: 22px;
  color: var(--oj-text);
}

.oj-connectors__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.oj-connectors__tab {
  box-sizing: border-box;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 15px;
  font-family: inherit;
  font-size: 17px;
  white-space: nowrap;
  border: 0;
  background: var(--oj-surface);
  color: var(--oj-navy);
  font-weight: 600;
}

/* every tab carries the same 1px border (transparent on the picked one), so
   picking a tab never changes its size; the bold width is held by
   `.oj-bold-stable` (base.css) */
.oj-connectors__tab {
  border: 1px solid var(--oj-border);
}

.oj-connectors__tab[aria-selected="true"] {
  background: var(--oj-navy);
  border-color: var(--oj-navy);
  color: var(--oj-surface);
  font-weight: 700;
}

@media (max-width: 1023px) {
  /* One row of categories that scrolls (strips spec of 21.10; mouse drag and
     wheel from client/dragScroll.ts, touch natively): it runs past the
     right margin to the screen's edge, so the category cut there shows
     there is more. 4px of padding all round, taken back by the margin, keep
     a focused tab's ring from being clipped by the strip. From 1024 up all
     categories show, wrapping onto a second line. */
  .oj-connectors__tabs {
    --oj-tabs-bleed: 40px;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    margin: -4px calc(-1 * var(--oj-tabs-bleed)) -4px -4px;
    padding: 4px var(--oj-tabs-bleed) 4px 4px;
    scroll-padding-left: 4px;
  }

  .oj-connectors__tab {
    flex: none;
    scroll-snap-align: start;
  }
}

/* Not a visible line under the tabs — `Integrations.dc.html`'s own script
   computes this text (`countText`) but never binds it to anything on
   screen; it exists there only as search-result feedback for assistive
   tech. `aria-live="polite"` on the element (`Connectors.tsx`) announces it
   as the query/tab changes. */
.oj-connectors__count {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.oj-connectors__window {
  padding: 24px;
  border-radius: var(--oj-r-xl);
  background: var(--oj-surface-2);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* A page's height (five rows of cards) as a minimum, not a fixed height:
   the "no such system" message below takes the window's room in the flow,
   and on a narrow screen it can need more than a page of cards does. */
.oj-connectors__viewport {
  position: relative;
  min-height: 448px;
  user-select: none;
}

.oj-connectors__grid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: 80px;
  gap: 12px;
}

.oj-connectors__card {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 16px;
  height: 80px;
  padding: 0 18px;
  border-radius: 20px;
  background: var(--oj-surface);
}

.oj-connectors__avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--oj-r-md);
  background: var(--oj-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--oj-font-display);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.03em;
  color: var(--oj-navy);
  flex: none;
}

.oj-connectors__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.oj-connectors__name {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--oj-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 768-1023 (no artboard of its own): four columns left a card ~170px wide,
   names cut to a few letters; two columns, a page of 20 in ten rows, and
   while there is more than one page the grid keeps a full page's height so
   paging never moves the dots (as on phones). */
@media (min-width: 768px) and (max-width: 1023px) {
  .oj-connectors__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oj-connectors__viewport.is-paged .oj-connectors__grid {
    min-height: calc(10 * 80px + 9 * 12px);
  }
}

/* one line, like the name above it: the longer groups ("Логистика, доставка
   и маркетплейсы") wrapped onto three and ran out of the 80px card */
.oj-connectors__category {
  font-size: 16px;
  color: var(--oj-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* In the flow, not laid over the grid: with nothing found the grid is
   empty, and an absolute message left the window with no height of its own
   (on a phone the yellow block below ran over it). */
.oj-connectors__empty {
  box-sizing: border-box;
  padding: 48px 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
}

.oj-connectors__empty-title {
  margin: 0;
  font-family: var(--oj-font-display);
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -0.025em;
  color: var(--oj-navy);
}

.oj-connectors__empty-text {
  margin: 0;
  max-width: 680px;
  font-size: 20px;
  line-height: 1.5;
  color: var(--oj-text-2);
}

.oj-connectors__pagination {
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.oj-connectors__arrow {
  box-sizing: border-box;
  width: 48px;
  height: 48px;
  border-radius: var(--oj-r-md);
  border: 1px solid var(--oj-border-4);
  background: var(--oj-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex: none;
  color: var(--oj-navy);
}

.oj-connectors__arrow:disabled {
  opacity: 0.35;
  cursor: default;
}

.oj-connectors__dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* The visible dot stays 8px (28px active) — `position: relative` plus an
   invisible `::before` at `inset: -8px` grows the *clickable* area to the
   24 CSS px Lighthouse's `target-size` audit wants, without moving or
   resizing anything a visitor sees (production audit, 2026-09-29). A click
   on generated content still targets its own real element, so the button
   need not grow itself. */
.oj-connectors__dot {
  position: relative;
  display: block;
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: var(--oj-r-xs);
  background: var(--oj-slate-200);
  cursor: pointer;
}

.oj-connectors__dot::before {
  content: "";
  position: absolute;
  inset: -8px;
}

.oj-connectors__dot--active {
  width: 28px;
  background: var(--oj-navy);
  cursor: default;
}

/* Layout spec §4: below 767 the catalogue becomes a single-column list
   (IntegrationsMobile.dc.html) instead of the 4-column grid — swipe/drag
   pagination stays. Seven systems a page here (owner's call, 21.10;
   `client/connectors.ts`), and while there is more than one page the list
   keeps seven cards' height, so a short last page does not move the dots. */
@media (max-width: 767px) {
  .oj-connectors-hero {
    padding: 36px 20px 40px;
  }

  /* IntegrationsMobile.dc.html: the section itself carries no side padding
     here — search/tabs/h1 sit flush against a 20px inset (this section's own
     padding), the window is a touch narrower (12px, via the negative margin
     below). */
  .oj-connectors-catalog {
    padding: 0 20px 64px;
  }

  .oj-connectors__tabs {
    --oj-tabs-bleed: 20px;
  }

  .oj-connectors-hero__title {
    font-size: 44px;
    letter-spacing: -0.045em;
  }

  .oj-connectors-hero__text {
    margin-top: 20px;
    max-width: none;
    font-size: 18px;
  }

  .oj-connectors-catalog h1 {
    font-size: 24px;
    letter-spacing: -0.03em;
  }

  .oj-connectors__search {
    height: 60px;
    padding: 0 18px;
    border-radius: var(--oj-r-lg);
    gap: 12px;
    box-shadow:
      0 0 0 2px var(--oj-cyan),
      0 0 0 6px rgba(34, 195, 219, 0.18);
  }

  .oj-connectors__search-input {
    font-size: 18px;
  }

  .oj-connectors__tab {
    min-height: 44px;
    padding: 0 18px;
    border-radius: var(--oj-r-md);
    font-size: 16px;
    flex: none;
  }

  .oj-connectors__window {
    margin: 0 -8px;
    padding: 12px;
    border-radius: 26px;
  }

  .oj-connectors__viewport {
    min-height: 0;
  }

  .oj-connectors__grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .oj-connectors__viewport.is-paged .oj-connectors__grid {
    min-height: calc(7 * 68px + 6 * 8px);
  }

  .oj-connectors__card {
    height: 68px;
    padding: 0 14px;
    border-radius: var(--oj-r-lg);
    gap: 14px;
  }

  .oj-connectors__avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--oj-r-sm);
    font-size: 15px;
  }

  .oj-connectors__name {
    font-size: 18px;
  }

  .oj-connectors__category {
    font-size: 15px;
  }

  .oj-connectors__empty {
    padding: 24px 8px;
  }

  .oj-connectors__empty-title {
    font-size: 22px;
  }

  .oj-connectors__empty-text {
    font-size: 17px;
    max-width: 620px;
  }
}

@media (max-width: 599px) {
  .oj-connectors__grid {
    display: flex;
    flex-direction: column;
  }
}

/* The page's top space: one value for every inner page (`--oj-page-top`,
   base.css; owner's call, 09.11). Last in the file so it outranks the
   breakpoint rules above. */
.oj-connectors-hero {
  padding-top: var(--oj-page-top);
}


/* the page's own style attributes, moved here by scripts/build/inlineStyles.mjs */

