/*
 * Contract-Production LTD design system. Loaded last on every page.
 * Rules and usage: docs/DESIGN_SYSTEM.md.
 *
 * The signature is the cut corner: top-left and bottom-right are chamfered, sized by --cut.
 * clip-path does not follow borders on the diagonal, so bordered controls and surfaces get
 * the diagonal drawn as a 1px gradient in --edge (kept equal to the border colour).
 * Outlines are clipped too, so focus rings are drawn inside the shape.
 */

:root {
  --blueprint: #1f5fd6;
  --chassis: #e3eef8;
}

/* ---------------------------------------------------------------------------
   1. Chrome: header, mobile menu, footer, back to top
   --------------------------------------------------------------------------- */

html :is(
  .header-cta,
  .languages .language-option,
  .languages .language-option.is-active,
  .menu-toggle,
  .mobile-menu-close,
  .mobile-language-option,
  .energy-footer__social,
  .energy-footer__cta,
  .back-to-top
) {
  border-radius: 0;
  clip-path: polygon(var(--cut, 10px) 0,100% 0,100% calc(100% - var(--cut, 10px)),calc(100% - var(--cut, 10px)) 100%,0 100%,0 var(--cut, 10px));
}

:is(.languages .language-option, .mobile-language-option) { --cut: 6px; }
.energy-footer__social { --cut: 8px; }
.energy-footer__cta { --cut: 12px; }

html :is(
  .header-cta,
  .languages .language-option,
  .languages .language-option.is-active,
  .menu-toggle,
  .mobile-menu-close,
  .mobile-language-option,
  .energy-footer__social,
  .back-to-top
) {
  border-color: var(--edge);
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: var(--cut, 10px) var(--cut, 10px), var(--cut, 10px) var(--cut, 10px);
  background-repeat: no-repeat;
  background-origin: border-box;
}

.header-cta { --edge: rgba(255, 255, 255, .42); }
.languages .language-option { --edge: transparent; }
.languages .language-option:hover { --edge: rgba(255, 255, 255, .34); }
.languages .language-option:focus-visible { --edge: var(--blue-500); }
.languages .language-option.is-active { --edge: var(--blue-600); }
.menu-toggle { --edge: rgba(255, 255, 255, .36); }
.mobile-menu-close { --edge: #cfe0ec; }
.mobile-menu-close:hover { --edge: var(--blue-600); }
.mobile-language-option { --edge: #cfe0ec; }
.mobile-language-option:hover,
.mobile-language-option:focus-visible,
.mobile-language-option.is-active { --edge: var(--blue-600); }
.energy-footer__social { --edge: rgba(255, 255, 255, .38); }
.energy-footer__social:hover,
.energy-footer__social:focus-visible { --edge: #119ef3; }
.back-to-top { --edge: rgba(255, 255, 255, .42); }

/* The shadow would be cut by the shape. */
html .back-to-top {
  box-shadow: none;
}

/* Focus ring inside the shape. */
html :is(
  .header-cta,
  .languages .language-option,
  .languages .language-option.is-active,
  .menu-toggle,
  .mobile-menu-close,
  .mobile-language-option,
  .energy-footer__social,
  .energy-footer__cta,
  .back-to-top
):focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: -3px;
}

/* Contact dock. Desktop: a WhatsApp button the size and shape of "back to top", stacked above it.
   Phone: a bar pinned to the bottom of the screen with WhatsApp and Call. */
.contact-dock {
  position: fixed;
  z-index: 55;
  right: 28px;
  bottom: 88px;
  transition: bottom .24s ease;
}

.contact-dock__link {
  --cut: 10px;
  --edge: rgba(255, 255, 255, .42);
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid var(--edge);
  color: #fff;
  background-color: #25d366;
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: var(--cut) var(--cut), var(--cut) var(--cut);
  background-repeat: no-repeat;
  background-origin: border-box;
  clip-path: polygon(var(--cut) 0,100% 0,100% calc(100% - var(--cut)),calc(100% - var(--cut)) 100%,0 100%,0 var(--cut));
  text-decoration: none;
  transition: transform .2s ease, background-color .2s ease;
}

.contact-dock__link svg {
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  fill: currentColor;
}

.contact-dock__link .contact-dock__stroke {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-dock__link:hover,
.contact-dock__link:focus-visible {
  background-color: #1da851;
  transform: scale(1.06);
}

.contact-dock__link:focus-visible {
  outline: 2px solid #fff;
  outline-offset: -4px;
}

.contact-dock__link--call {
  display: none;
}

.contact-dock__label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.has-ves1-stickybar .contact-dock { bottom: 156px; }

@media (max-width: 900px) {
  .contact-dock { right: 18px; bottom: 76px; }
  .contact-dock__link--wa { width: 46px; height: 46px; }
  .has-ves1-stickybar .contact-dock { bottom: 146px; }
  .page-calculator .contact-dock { bottom: 156px; }
}

@media (max-width: 767px) {
  :root { --dock-space: calc(64px + env(safe-area-inset-bottom, 0px)); }

  body { padding-bottom: var(--dock-space); }

  .contact-dock,
  .has-ves1-stickybar .contact-dock,
  .page-calculator .contact-dock {
    z-index: 48;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid rgba(21, 159, 230, .28);
    background: var(--navy-950, #03182b);
    box-shadow: 0 -12px 28px rgba(3, 24, 43, .22);
  }

  /* Cyan tick on the top edge, as on the panels. */
  .contact-dock::before {
    position: absolute;
    top: -1px;
    left: 12px;
    width: 48px;
    height: 2px;
    content: "";
    background: var(--brand-cyan, #159fe6);
  }

  .contact-dock__link,
  .contact-dock__link--wa {
    display: flex;
    width: auto;
    height: 48px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
  }

  .contact-dock__link svg { width: 20px; height: 20px; }

  .contact-dock__link--wa {
    --edge: rgba(255, 255, 255, .42);
    background-color: var(--navy-800, #0a3353);
  }

  .contact-dock__link--wa svg { color: #25d366; }

  .contact-dock__link--call {
    --edge: var(--blue-600, #006fbd);
    background-color: var(--blue-600, #006fbd);
  }

  .contact-dock__link:hover,
  .contact-dock__link:focus-visible { transform: none; }

  .contact-dock__link--wa:hover,
  .contact-dock__link--wa:focus-visible { background-color: #0f4470; }

  .contact-dock__link--call:hover,
  .contact-dock__link--call:focus-visible { --edge: var(--brand-blue, #00569e); background-color: var(--brand-blue, #00569e); }

  .contact-dock__label {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
  }

  /* Everything else pinned to the bottom moves above the bar. */
  html .back-to-top { bottom: calc(var(--dock-space) + 12px); }
  html .has-ves1-stickybar .back-to-top { bottom: calc(var(--dock-space) + 80px); }
  html .page-calculator .back-to-top { bottom: calc(var(--dock-space) + 98px); }
  html .ves1-stickybar { bottom: calc(var(--dock-space) + 12px); }
  html .page-calculator .calc-live { bottom: calc(var(--dock-space) + 12px); }
}

@media print {
  .contact-dock { display: none; }
}

/* ---------------------------------------------------------------------------
   2. Components: buttons, home panels, lead forms and modal
   --------------------------------------------------------------------------- */

html :is(
  .hero-live,
  .hero-story,
  .telemetry__ghost,
  .telemetry-station,
  .telemetry-detail,
  .telemetry__map,
  .telemetry-kpi,
  .advantage-list,
  .tech-chain,
  #home-faq details,
  .tech-modes__tabs button,
  .tech-modes__indicator,
  .bento-card__chips span,
  .bento-card__arrow,
  .lead-modal__close,
  .button,
  .why-us-cta,
  .bento-card,
  .tech-modes,
  .tech-video,
  .tech-video figcaption,
  .telemetry-detail__status,
  :is(.request-section, .contact-hero) .request-form,
  .lead-modal-dialog
) {
  border-radius: 0;
  clip-path: polygon(var(--cut, 10px) 0,100% 0,100% calc(100% - var(--cut, 10px)),calc(100% - var(--cut, 10px)) 100%,0 100%,0 var(--cut, 10px));
}

/* Cut sizes follow the element: small chips and toggles, buttons, panels. */
:is(
  .bento-card__chips span,
  .tech-video figcaption,
  .telemetry-detail__status
) { --cut: 6px; }

:is(
  .tech-modes__tabs button,
  .tech-modes__indicator,
  .bento-card__arrow
) { --cut: 8px; }

:is(
  .button,
  .why-us-cta,
  .hero-live,
  .telemetry__ghost,
  .telemetry-station
) { --cut: 12px; }

:is(
  .hero-story,
  .telemetry-kpi,
  #home-faq details
) { --cut: 14px; }

:is(
  .telemetry-detail,
  .telemetry__map,
  .advantage-list,
  .tech-chain
) { --cut: 18px; }

:is(
  .bento-card,
  .tech-modes,
  .tech-video,
  :is(.request-section, .contact-hero) .request-form,
  .lead-modal-dialog
) { --cut: 22px; }

/* Bordered surfaces: the border colour lives in --edge so the diagonal matches it. */
html :is(
  .hero-live,
  .hero-story,
  .telemetry__ghost,
  .telemetry-station,
  .telemetry-detail,
  .telemetry__map,
  .telemetry-kpi,
  .advantage-list,
  .tech-chain,
  #home-faq details,
  .tech-modes__tabs button,
  .bento-card__chips span,
  .bento-card__arrow,
  .lead-modal__close
) {
  border-color: var(--edge);
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    var(--surface-image, none);
  background-position: left top, right bottom, 0 0;
  background-size: var(--cut, 10px) var(--cut, 10px), var(--cut, 10px) var(--cut, 10px), 100% 100%;
  background-repeat: no-repeat;
  background-origin: border-box;
}

.hero-live { --edge: rgba(255, 255, 255, .2); }
.hero-live:hover { --edge: rgba(21, 159, 230, .7); }
.hero-story { --edge: rgba(255, 255, 255, .45); }
.telemetry__ghost { --edge: rgba(255, 255, 255, .45); }
.telemetry__ghost:hover { --edge: var(--white); }
.telemetry-station { --edge: rgba(255, 255, 255, .12); }
.telemetry-station:hover { --edge: rgba(127, 208, 255, .5); }
.telemetry-station[aria-pressed="true"] { --edge: var(--brand-cyan); }
.telemetry-detail,
.telemetry__map { --edge: rgba(255, 255, 255, .12); }
.telemetry-kpi {
  --edge: rgba(255, 255, 255, .12);
  --surface-image: linear-gradient(rgba(55, 211, 155, .05), rgba(255, 255, 255, .02));
}
.advantage-list {
  --edge: rgba(130, 205, 246, .24);
  --surface-image: linear-gradient(90deg, rgba(2, 24, 45, .72), rgba(2, 24, 45, .42));
}
.tech-chain { --edge: var(--line); }
#home-faq details { --edge: var(--line); }
#home-faq details[open] { --edge: rgba(21, 159, 230, .45); }
.tech-modes__tabs button { --edge: rgba(255, 255, 255, .22); }
.tech-modes__tabs button:hover { --edge: rgba(255, 255, 255, .55); }
.tech-modes__tabs button[aria-selected="true"] { --edge: var(--tech-green); }
.tech-modes__tabs.has-indicator button[aria-selected="true"] { --edge: transparent; }
.bento-card__chips span { --edge: rgba(255, 255, 255, .3); }
.bento-card__chips span:first-child { --edge: var(--tech-green); }
.bento-card__arrow { --edge: rgba(255, 255, 255, .45); }
.lead-modal__close { --edge: var(--line); }
.lead-modal__close:hover { --edge: var(--blue-600); }

/* Corner brackets of the panels become an accent along the cut. */
html :is(.tech-modes, .tech-video, .telemetry-kpi, .telemetry__map, .telemetry-detail)::before {
  top: 0;
  left: 0;
  width: var(--cut, 10px);
  height: var(--cut, 10px);
  border: 0;
  background: linear-gradient(to bottom right, transparent 50%, currentColor 50%, currentColor calc(50% + 2px), transparent calc(50% + 2px));
}

html :is(.tech-modes, .tech-video)::before { color: var(--tech-green); }
html :is(.telemetry-kpi, .telemetry__map, .telemetry-detail)::before {
  top: -1px;
  left: -1px;
}

html .telemetry-kpi::before { color: var(--telemetry-green); }
html :is(.telemetry__map, .telemetry-detail)::before { color: var(--brand-cyan); }

/* Shadows would be cut by the shape; surfaces read by fill instead. */
html :is(.button, .why-us-cta, .tech-modes__indicator, #home-faq details[open]) {
  box-shadow: none;
}

.lead-modal__close:hover {
  color: var(--white);
  background-color: var(--blue-600);
}

.lead-modal__close:hover svg {
  stroke: currentColor;
}

/* Focus ring inside the shape. */
html :is(
  .hero-live,
  .hero-story,
  .telemetry__ghost,
  .telemetry-station,
  .tech-modes__tabs button,
  .bento-card,
  .lead-modal__close,
  .button,
  .why-us-cta
):focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: -3px;
}

/* Lead forms (request section and modal) in the calculator's instrument language:
   light chassis on a drafting grid, a status plate with LEDs, field LEDs on labels.
   LEDs read the fields' own state, so they need no extra script. */
html body :is(:is(.request-section, .contact-hero) .request-form, .lead-modal-dialog) {
  color: var(--brand-navy);
  background-color: #e3eef8;
  background-image:
    linear-gradient(rgba(31, 95, 214, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(31, 95, 214, .07) 1px, transparent 1px);
  background-position: -1px -1px;
  background-size: 24px 24px;
  box-shadow: none;
}

.lead-modal-dialog h2 {
  color: var(--brand-navy);
}

.lead-modal-dialog .lead-modal-contacts a {
  color: var(--brand-navy);
}

.lead-modal__close {
  background-color: var(--white);
}

.lead-form__panel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  margin-bottom: 12px;
  padding: 14px 18px;
  background: var(--white);
  clip-path: polygon(14px 0,100% 0,100% calc(100% - 14px),calc(100% - 14px) 100%,0 100%,0 14px);
}

.lead-form__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lead-form__lens {
  flex: 0 0 34px;
}

.lead-form__lens circle:nth-child(1) { fill: var(--brand-navy); }
.lead-form__lens circle:nth-child(2) { fill: none; stroke: #0d3a5e; stroke-width: 2; }
.lead-form__lens circle:nth-child(3) { fill: var(--brand-deep); stroke: var(--brand-cyan); }
.lead-form__lens circle:nth-child(4) { fill: #fff; }

.lead-form__eyebrow {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  line-height: 1.3;
  text-transform: uppercase;
}

.lead-form__title {
  display: block;
  margin-top: 2px;
  color: var(--brand-navy);
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
}

.lead-form__leds {
  display: flex;
  gap: 14px;
}

.lead-form__led,
.lead-form .field:not(.field-consent) label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.lead-form__led {
  color: var(--muted);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.lead-form__led::before,
.lead-form .field:where(:not(.field-consent)) label::before,
.lead-form .lead-submit::before,
.lead-form .form-status:not(:empty)::before {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: #b5c8d8;
  content: "";
  transition: background-color .18s ease-out;
}

/* Green when a field holds a usable value, amber while a masked or typed value is incomplete, red on a reported error. */
.lead-form .field:where(:has(input[required]:valid)) label::before,
.lead-form .field:where(:has(:is(input, textarea)[placeholder]:not([required]):not(:placeholder-shown):valid)) label::before,
.lead-form .field:where(:has(select option[value=""]:not(:checked))) label::before,
.lead-form:has(input[name="name"]:valid) .lead-form__led[data-led="name"]::before,
.lead-form:has(input[name="phone"]:valid) .lead-form__led[data-led="phone"]::before,
.lead-form:has(input[name="consent"]:checked) .lead-form__led[data-led="consent"]::before,
.lead-form:has(input[name="name"]:valid):has(input[name="phone"]:valid):has(input[name="consent"]:checked) .lead-submit::before,
.lead-form .form-status.is-success::before {
  background: #3ccf6e;
}

.lead-form .field:where(:has(input[placeholder]:not(:placeholder-shown):invalid)) label::before,
.lead-form:where(:has(input[name="phone"]:not(:placeholder-shown):invalid)) .lead-form__led[data-led="phone"]::before {
  background: #f0b429;
}

.lead-form .field:has([aria-invalid="true"]) label::before,
.lead-form:has(input[name="name"][aria-invalid="true"]) .lead-form__led[data-led="name"]::before,
.lead-form:has(input[name="phone"][aria-invalid="true"]) .lead-form__led[data-led="phone"]::before,
.lead-form:has(input[name="consent"][aria-invalid="true"]) .lead-form__led[data-led="consent"]::before,
.lead-form .form-status.is-error::before {
  background: #e5484d;
}

.lead-form .form-grid {
  padding: 18px;
  background: var(--surface);
  clip-path: polygon(14px 0,100% 0,100% calc(100% - 14px),calc(100% - 14px) 100%,0 100%,0 14px);
}

.lead-form .field label {
  color: var(--brand-navy);
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form :is(input[type="text"], input[type="tel"], input[type="email"], select, textarea) {
  min-height: 50px;
  border: 0;
  border-radius: 0;
  color: var(--brand-navy);
  background-color: var(--white);
  clip-path: polygon(8px 0,100% 0,100% calc(100% - 8px),calc(100% - 8px) 100%,0 100%,0 8px);
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form textarea {
  min-height: 112px;
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form :is(input, select, textarea)::placeholder {
  color: #5d7a93;
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form :is(input, select, textarea):focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: -2px;
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form :is(input, select, textarea)[aria-invalid="true"] {
  box-shadow: inset 0 0 0 2px #e5484d;
}

.lead-form .field-consent input {
  accent-color: var(--brand-navy);
}

.lead-form .field-consent label {
  color: var(--brand-navy);
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form .lead-submit {
  gap: 12px;
  color: var(--white);
  background: var(--brand-navy);
  transform: none;
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form .lead-submit:hover {
  background: var(--brand-blue);
}

:is(.request-section, .contact-hero, .lead-modal) .lead-form .lead-submit:active {
  transform: scale(.98);
}

.lead-form .lead-submit::before {
  background: #1e4466;
}

.lead-form .form-status:not(:empty) {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 12px 16px;
  background: var(--white);
  clip-path: polygon(8px 0,100% 0,100% calc(100% - 8px),calc(100% - 8px) 100%,0 100%,0 8px);
}

.lead-form .form-status:not(:empty)::before {
  transform: translateY(-1px);
}

@media (max-width: 760px) {
  .lead-form__panel {
    padding: 12px 14px;
  }

  .lead-form .form-grid {
    padding: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lead-form__led::before,
  .lead-form .field label::before,
  .lead-form .lead-submit::before {
    transition: none;
  }
}

/* ---------------------------------------------------------------------------
   3. Inner pages: hero
   --------------------------------------------------------------------------- */

.inner-hero--dark {
  background: linear-gradient(120deg, var(--navy-950) 0%, var(--navy-800) 62%, #0a4d86 100%);
}

.inner-hero--dark::before {
  display: none;
}

.inner-hero--dark .inner-lead,
.catalog-hero__lead {
  color: rgba(255, 255, 255, .86);
}

html .inner-copy h1,
html .inner-hero .inner-prose h1,
html .catalog-hero h1 {
  text-transform: uppercase;
  letter-spacing: -.01em;
}

/* Photo plate: the unit in full, on the same cut shape as the home cards. */
html :is(.inner-ring, .inner-frame) {
  display: block;
  width: min(460px, 100%);
  min-height: 0;
  aspect-ratio: 4 / 5;
  margin-inline: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: var(--navy-800);
  box-shadow: none;
}

html :is(.inner-ring, .inner-frame) img,
html.js :is(.inner-ring, .inner-frame) img,
html .page-tech .inner-ring img {
  display: block;
  width: 100%;
  max-width: none;
  height: 100%;
  min-width: 0;
  min-height: 0;
  background: none;
  object-fit: cover;
}

html .page-tech .inner-ring {
  aspect-ratio: 1;
  background: var(--navy-800);
}

html .catalog-hero__stage {
  display: grid;
  min-height: 0;
  place-items: center;
}

@media (max-width: 900px) {
  html :is(.inner-ring, .inner-frame) {
    width: min(420px, 100%);
    margin-top: 32px;
  }
}

/* ---------------------------------------------------------------------------
   4. Inner pages: surfaces
   --------------------------------------------------------------------------- */

html :is(
  .inner-ring,
  .inner-frame,
  .inner-photo,
  .inner-panel,
  .inner-cards article,
  .inner-links a,
  .inner-table-wrap,
  .inner-faq details,
  .article-list a,
  .about-facts__cards a,
  .catalog-card,
  .catalog-scene,
  .catalog-point,
  .catalog-faq details,
  .catalog-related a,
  .deck-metrics li,
  .deck-bar,
  .ves-photo,
  .ves-compare article,
  .ves-links a,
  .ves2-photo,
  .ves2-note,
  .ves2-grid article,
  .ves2-links a,
  .ves2-cta-photo,
  .ves1-hero-media__label,
  .ves1-console__frame,
  .ves1-console__gauges div,
  .ves1-wind__stage,
  .ves1-wind__control,
  .ves1-wind__meters div,
  .ves1-wind__mode,
  .ves1-real-photo,
  .ves1-curve,
  .ves1-config-grid > div,
  .ves1-badge,
  .ves1-price__action,
  .ves1-install-grid article,
  .ves1-service-list article,
  .ves1-field__stage,
  .ves1-field__panel,
  .ves1-field__chapters button,
  .ves1-quiz,
  .ves1-quiz__options label,
  .ves1-quiz__hints,
  .ves1-energy__tabs,
  .ves1-energy__tabs button,
  .ves1-energy__scheme,
  .ves1-energy__node,
  .ves1-size,
  .ves1-stickybar,
  .ves1-anatomy__list li,
  .ves1-timeline__status,
  .ves1-doc,
  .ves1-compare__wrap,
  .ves1-compare__link,
  .ves1-scenario,
  .solution-card
) {
  border-radius: 0 !important;
  clip-path: polygon(var(--cut, 12px) 0,100% 0,100% calc(100% - var(--cut, 12px)),calc(100% - var(--cut, 12px)) 100%,0 100%,0 var(--cut, 12px));
  box-shadow: none;
}

/* Cut sizes follow the element: chips, cards, panels, photos. */
:is(
  .catalog-related a,
  .ves1-hero-media__label,
  .ves1-badge,
  .ves1-timeline__status,
  .ves1-compare__link,
  .ves1-energy__tabs button,
  .ves1-field__chapters button
) { --cut: 8px; }

:is(
  .inner-panel,
  .inner-table-wrap,
  .catalog-card,
  .catalog-scene,
  .deck-bar,
  .ves1-curve,
  .ves1-doc,
  .ves1-energy__scheme,
  .ves1-compare__wrap,
  .ves1-quiz__hints
) { --cut: 18px; }

:is(
  .inner-ring,
  .inner-frame,
  .inner-photo,
  .ves-photo,
  .ves2-photo,
  .ves2-cta-photo,
  .ves1-real-photo,
  .ves1-console__frame,
  .ves1-wind__stage,
  .ves1-wind__control,
  .ves1-field__stage,
  .ves1-field__panel,
  .ves1-price__action,
  .ves1-quiz,
  .ves1-size
) { --cut: 22px; }

/* Bordered light surfaces get the diagonal drawn in --edge. */
html :is(
  .inner-cards article,
  .inner-links a,
  .inner-table-wrap,
  .inner-faq details,
  .article-list a,
  .about-facts__cards a,
  .catalog-card,
  .catalog-scene,
  .catalog-point,
  .catalog-faq details,
  .ves-compare article,
  .ves-links a,
  .ves2-grid article,
  .ves2-links a,
  .ves2-note,
  .ves1-config-grid > div,
  .ves1-install-grid article,
  .ves1-service-list article,
  .ves1-anatomy__list li,
  .ves1-doc,
  .ves1-scenario
) {
  --edge: var(--line);
  border-color: var(--edge);
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: var(--cut, 12px) var(--cut, 12px), var(--cut, 12px) var(--cut, 12px);
  background-repeat: no-repeat;
  background-origin: border-box;
}

html :is(.inner-faq details, .catalog-faq details)[open] {
  --edge: rgba(21, 159, 230, .45);
}

html :is(.inner-photo, .ves2-photo, .ves-photo, .ves2-cta-photo) img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Focus ring inside the shape. */
html :is(
  .inner-links a,
  .article-list a,
  .about-facts__cards a,
  .catalog-related a,
  .ves2-links a,
  .ves-links a,
  .ves1-compare__link,
  .ves1-energy__tabs button,
  .ves1-field__chapters button,
  .ves1-wind__mode
):focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: -3px;
}

/* Outline button: the border lives in --edge so the diagonal matches it. */
html .button-line {
  --edge: rgba(255, 255, 255, .42);
  color: var(--white);
  border-color: var(--edge);
  background-color: transparent;
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: var(--cut, 12px) var(--cut, 12px), var(--cut, 12px) var(--cut, 12px);
  background-repeat: no-repeat;
  background-origin: border-box;
}

html .button-line:hover {
  --edge: var(--white);
}

/* Technology hero, article figures, ТВЭС-1 field frames and documents, calculator types:
   the same cut shape. Kept apart from the lists above so the longer selectors here
   do not raise the specificity of those lists. */
html :is(
  .tech-hero-video,
  .tech-hero-video video,
  .tech-hero-video figcaption,
  .tech-sphere__caption,
  .tech-sphere__modes button,
  .tech-scheme,
  .tech-anim video,
  .tech-patents img,
  .article-figure img,
  .ves1-field__frame video,
  .ves1-field__frame img,
  .ves1-doc__thumb,
  .ves1-doc__thumb b
) {
  border-radius: 0;
  clip-path: polygon(var(--cut, 12px) 0,100% 0,100% calc(100% - var(--cut, 12px)),calc(100% - var(--cut, 12px)) 100%,0 100%,0 var(--cut, 12px));
  box-shadow: none;
}

html .ves1-doc__thumb b { clip-path: none; }
html :is(.tech-hero-video figcaption, .ves1-doc__thumb) { --cut: 6px; }
html :is(.tech-sphere__caption, .tech-sphere__modes button) { --cut: 8px; }
html :is(.tech-hero-video, .tech-hero-video video) { --cut: 14px; }
html :is(.tech-scheme, .article-figure img) { --cut: 18px; }
html .tech-anim video { --cut: 22px; }
html .tech-anim--hero video { --cut: 12px; } /* smaller cut keeps the player controls clear */
html :is(.tech-hero-video, .article-figure img) { border: 0; }

html :is(.tech-sphere__caption, .tech-sphere__modes button) {
  --edge: rgba(255, 255, 255, .4);
  border-color: var(--edge);
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: var(--cut, 12px) var(--cut, 12px), var(--cut, 12px) var(--cut, 12px);
  background-repeat: no-repeat;
  background-origin: border-box;
}

html .tech-sphere__caption { --edge: rgba(143, 214, 255, .3); }
html .tech-sphere__modes button { --edge: #8fd6ff; }
html .tech-sphere__modes button[aria-pressed="true"] { --edge: #159fe6; }
html .tech-sphere__modes button:focus-visible { outline-offset: -3px; }

html body .calc-card .calc-types .calc-type {
  --edge: #c9d9e6;
  border-radius: 0;
  border-color: var(--edge);
  clip-path: polygon(12px 0,100% 0,100% calc(100% - 12px),calc(100% - 12px) 100%,0 100%,0 12px);
  background-image:
    linear-gradient(to bottom right, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px)),
    linear-gradient(to top left, transparent 50%, var(--edge) 50%, var(--edge) calc(50% + 1px), transparent calc(50% + 1px));
  background-position: left top, right bottom;
  background-size: 12px 12px, 12px 12px;
  background-repeat: no-repeat;
  background-origin: border-box;
}

html body .calc-card .calc-types .calc-type:hover { --edge: var(--blueprint); }
html body .calc-card .calc-types:has([aria-invalid="true"]) .calc-type { --edge: #e5484d; }

/* Hero layout: copy on the left, plate on the right on every page. */
html .inner-grid--reverse {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
}

html .inner-grid--reverse > figure {
  order: 2;
}

html .catalog-hero::before {
  display: none;
}

html :is(.inner-copy, .catalog-hero__copy, .inner-hero .inner-prose) h1 {
  font-size: clamp(28px, 2.8vw, 40px);
  line-height: 1.08;
}

html .page-ves2 .ves2-cta-photo {
  width: min(220px, 70%);
  aspect-ratio: 4 / 5;
  border: 0;
  background: none;
  box-shadow: none;
}

@media (max-width: 900px) {
  html .inner-grid--reverse {
    grid-template-columns: 1fr;
  }

  html :is(.inner-copy, .catalog-hero__copy, .inner-hero .inner-prose) h1 {
    font-size: clamp(20px, 5.8vw, 40px);
  }
}

html .page-ves2 .catalog-hero h1 {
  font-size: clamp(26px, 2.5vw, 36px);
}

html .catalog-faq h2 {
  font-size: clamp(24px, 2.4vw, 32px);
}

@media (max-width: 900px) {
  html .page-ves2 .catalog-hero h1 {
    font-size: clamp(20px, 5.8vw, 36px);
  }
}

/* Visualizations fill their media slot; the unit stays in the centre crop. */
html :is(.catalog-media, .catalog-point__media) {
  overflow: hidden;
}

html :is(.catalog-media, .catalog-point__media) img {
  min-height: 0;
  background: none;
  object-fit: cover;
  object-position: center 30%;
}

/* The city visualization has its mast near the centre: keep it clear of the copy wash. */
html .page-ves1-product .ves1-hero-media img {
  object-position: 55% 46%;
}

@media (max-width: 420px) {
  html .catalog-faq h2 {
    font-size: 22px;
  }

  html .page-ves1-product .catalog-hero h1 {
    font-size: 20px;
  }
}

@media (min-width: 761px) {
  html .page-solutions .inner-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
