/* Hand-written styles of the landing (every page), not built by gulp: the gulp build of assets/sass does not run
   on this machine (node-sass, arm64). Colors and radii follow assets/sass/bootstrap-custom.scss
   ($primary #3053f0, $sky #548ef6, $yellow #ffbb2e). Script: js/landing-*.js. */

/* Image Enhancement section (index.html, index_ya.html): before/after comparison.
   The divider position is the --enhance-pos custom property, set by the script. */

/* NEW badge: a tilted yellow sticker ($yellow of the landing) with a hard black shadow */
.enhance-new {
  display: inline-block;
  padding: .15rem .7rem;
  border-radius: .4rem;
  background-color: #ffbb2e;
  color: #000;
  font-size: .9rem;
  font-weight: 900;
  line-height: 1.75;
  letter-spacing: .05rem;
  transform: rotate(-6deg);
  box-shadow: 2px 3px 0 #000;
}

.enhance-eyebrow {
  color: rgba(0, 0, 0, .6);
  text-transform: uppercase;
  letter-spacing: .1rem;
}

.enhance-window {
  display: block;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  background-color: #fff;
}

.enhance-window .window-title {
  color: rgba(0, 0, 0, .6);
  font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
  font-weight: 400;
}

.enhance-compare {
  --enhance-pos: 50%;
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background-color: #a8c3c8;
  cursor: ew-resize;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

@supports not (aspect-ratio: 16 / 9) {
  .enhance-compare::before {
    content: '';
    display: block;
    padding-top: 56.25%;
  }
}

.enhance-compare img {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  pointer-events: none;
  -webkit-user-drag: none;
}

.enhance-compare-before {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  -webkit-clip-path: inset(0 calc(100% - var(--enhance-pos)) 0 0);
  clip-path: inset(0 calc(100% - var(--enhance-pos)) 0 0);
}

.enhance-label {
  position: absolute;
  top: 12px;
  padding: 0 .75rem;
  border-radius: 30px;
  background-color: rgba(255, 255, 255, .9);
  color: #000;
  white-space: nowrap;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .15);
}

.enhance-label-before {
  left: 12px;
}

.enhance-label-after {
  right: 12px;
}

.enhance-compare-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--enhance-pos);
  width: 0;
  touch-action: none;
  outline: none;
}

.enhance-compare-handle::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -1px;
  width: 2px;
  background-color: #fff;
  box-shadow: 0 0 8px rgba(0, 0, 0, .35);
}

.enhance-compare-knob {
  position: absolute;
  top: 70%;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin: -24px 0 0 -24px;
  border-radius: 50%;
  background-color: #fff;
  color: #3053f0;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
  transition: transform .15s ease, box-shadow .15s ease;
}

.enhance-compare-knob svg {
  display: block;
}

.enhance-compare:hover .enhance-compare-knob,
.enhance-compare.is-dragging .enhance-compare-knob {
  transform: scale(1.08);
}

.enhance-compare-handle:focus-visible .enhance-compare-knob {
  box-shadow: 0 0 0 4px rgba(48, 83, 240, .5), 0 4px 14px rgba(0, 0, 0, .25);
}

.enhance-compare-hint {
  position: absolute;
  top: 70%;
  left: 0;
  margin-top: 30px;
  padding: 0 .75rem;
  border-radius: 30px;
  background-color: #3053f0;
  color: #fff;
  white-space: nowrap;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity .3s ease;
  pointer-events: none;
}

.enhance-compare.is-ready .enhance-compare-hint {
  opacity: 1;
}

.enhance-compare.is-touched .enhance-compare-hint {
  opacity: 0;
}

/* Example switcher: the same dots as the carousel indicators of the first screen (.carousel-indicators) */
.enhance-dots {
  display: flex;
  justify-content: center;
  width: -webkit-max-content;
  width: max-content;
  margin: 1rem auto 0;
  padding-left: 6px;
  border-radius: 30px;
  background-color: #ebebeb;
}

.enhance-dot {
  position: relative;
  box-sizing: content-box;
  width: 7px;
  height: 7px;
  margin: 0 6px 0 0;
  padding: 0;
  border: 0;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-radius: 50%;
  background-color: #000;
  background-clip: padding-box;
  opacity: .5;
  cursor: pointer;
  transition: opacity .6s ease;
}

/* a larger invisible hit area for fingers */
.enhance-dot::after {
  content: '';
  position: absolute;
  top: -8px;
  right: -6px;
  bottom: -8px;
  left: -6px;
}

.enhance-dot.is-active {
  opacity: 1;
}

.enhance-dot:focus {
  outline: none;
}

.enhance-dot:focus-visible {
  opacity: 1;
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px rgba(48, 83, 240, .6);
}

.enhance-square {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -.025rem;
}

/* Not part of enhance: on screens under 768 px the Translation picture (.collage-f) was 420 px wide in a 360 px
   column, so on phones the whole page was 45 px wider than the screen and scrolled sideways. Here it takes the column
   width, up to 420 px. The same change is in assets/sass/bootstrap-custom.scss for the next gulp build. */
@media (max-width: 767.98px) {
  .collage-f {
    width: auto;
    max-width: 420px;
  }

  .collage-img-f1 {
    width: 100%;
  }
}


/* Icons in the feature squares (.square of the site's CSS): line icons from img/icons-*.svg, white on the square's
   blue. They replace the old .ico-warning / .ico-circle-play, which showed an exclamation mark for every feature. */
.square .icon {
  display: block;
  width: 32px;
  height: 32px;
  margin: 16px;
  color: #fff;
}

/* Cookie consent bar, created by the script on every page. Decline is as visible as Accept:
   refusing has to be as easy as agreeing. */
.cookie-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1040;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1rem 2rem;
  border-top: 1px solid rgba(0, 0, 0, .12);
  background-color: #fff;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, .06);
}

.cookie-bar-text {
  color: rgba(0, 0, 0, .75);
  font-size: .95rem;
  line-height: 1.5rem;
  letter-spacing: -.0125rem;
}

.cookie-bar-text a {
  color: #3053f0;
}

.cookie-bar-btns {
  display: flex;
  flex-shrink: 0;
  gap: .5rem;
}

.cookie-bar-btns .btn {
  min-width: 0;
  padding: .4rem 1.1rem;
  font-size: .95rem;
}

.cookie-bar .btn-outline-intro {
  border-color: rgba(0, 0, 0, .25);
  background-color: #fff;
  color: #000 !important;
  font-weight: 700;
}

.cookie-bar .btn-outline-intro:hover,
.cookie-bar .btn-outline-intro:focus {
  border-color: #3053f0;
  color: #3053f0 !important;
}

@media (max-width: 767.98px) {
  .cookie-bar {
    flex-direction: column;
    align-items: stretch;
    gap: .75rem;
    padding: 1rem 15px;
  }

  .cookie-bar-btns .btn {
    flex: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .enhance-compare-knob,
  .enhance-compare-hint,
  .enhance-dot {
    transition: none;
  }
}
