/* Luka AI Assistant Section Styles */
.luka {
  padding: 80px 0 80px;
  background-color: #faf8f5;
  overflow: hidden;
}

.luka__container {
  max-width: 1372px;
  width: 100%;
  padding: 0 10px;
  margin: 0 auto;
}

/* Section Header */
.luka__intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  text-align: center;
  margin-bottom: 60px;
}

.luka__title {
  max-width: 980px;
  font-family: "Graphik LCG", sans-serif;
  font-weight: 500;
  font-size: 48px;
  line-height: 102%;
  letter-spacing: 0;
  text-align: center;
  color: #000000;
}

.luka__subtitle {
  max-width: 900px;
  font-family: "Graphik LCG", sans-serif;
  font-weight: 500;
  font-size: 24px;
  line-height: 126%;
  letter-spacing: 0;
  text-align: center;
  color: rgba(0, 0, 0, 0.45);
}

/* Slider Card Container matching 1352 x 488.84 Figma spec */
.luka__card {
  position: relative;
  width: 100%;
  max-width: 1352px;
  min-height: 488.84px;
  margin: 0 auto;
  background-color: #ffffff;
  border: 1px solid #d9d9d9;
  border-radius: 28px;
  overflow: hidden;
}

.luka__slider {
  width: 100%;
  overflow: hidden;
}

.luka__track {
  display: flex;
  width: 100%;
}

.luka-slide {
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  gap: 30px;
  width: 100%;
  min-height: 488.84px;
  padding: 41px;
  flex-shrink: 0;
  box-sizing: border-box;
}

/* Left Column: 270 x 406.84 */
.luka-slide__left {
  width: 270px;
  min-height: 406.84px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.luka-slide__text-group {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.luka-slide__step {
  font-family: "Graphik LCG", sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  letter-spacing: 0;
  color: rgba(0, 0, 0, 0.29);
}

.luka-slide__title {
  font-family: "Graphik LCG", sans-serif;
  font-weight: 500;
  font-size: 30px;
  line-height: 34px;
  letter-spacing: 0;
  color: #000000;
}

.luka-slide__description {
  font-family: "Graphik LCG", sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  letter-spacing: 0;
  color: #000000;
}

.luka-slide__nav-spacer {
  height: 41.32px;
  flex-shrink: 0;
}

/* Right Column: 949 x 406.84 */
.luka-slide__right {
  width: 949px;
  max-width: calc(100% - 300px);
  height: 406.84px;
  border-radius: 12.69px;
  overflow: hidden;
  flex-shrink: 0;
}

.luka-slide__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12.69px;
  display: block;
}

/* Slider Navigation Buttons: 41.32 x 41.32 */
.luka__controls {
  position: absolute;
  left: 41px;
  bottom: 41px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 10;
}

.luka__nav-btn {
  width: 41.32px;
  height: 41.32px;
  border-radius: 196.6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  background-color: #f1f1f1;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.luka__nav-btn svg path {
  stroke: #aaa7a5;
  transition: stroke 0.2s ease;
}

.luka__nav-btn:hover,
.luka__nav-btn:active {
  background-color: #ff493c;
}

.luka__nav-btn:hover svg path,
.luka__nav-btn:active svg path {
  stroke: #ffffff;
}

.luka__nav-btn--next svg {
  transform: rotate(180deg);
}

/* CTA Button below the block (no fixed width) */
.luka__cta {
  width: max-content;
  max-width: 100%;
  height: 65px;
  margin: 60px auto 0;
  padding: 20px 40px;
  border-radius: 16px;
  background-color: #f1361d;
  font-family: "Graphik LCG", sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: #ffffff;
}

/* Responsive Overrides */
@media (max-width: 530px) {
  .luka {
    padding: 40px 0 60px;
  }
  .luka__container {
    width: 95%;
    padding: 0;
  }
  .luka__intro {
    margin-bottom: 30px;
    gap: 16px;
  }
  .luka__title {
    font-size: 20px;
  }
  .luka__subtitle {
    font-size: 16px;
  }
  .luka__card {
    min-height: auto;
    border-radius: 24px;
  }
  .luka-slide {
    flex-direction: column;
    min-height: auto;
    padding: 20px 20px 76px;
    gap: 20px;
  }
  .luka-slide__left {
    width: 100%;
    min-height: auto;
  }
  .luka-slide__text-group {
    gap: 12px;
  }
  .luka-slide__step {
    font-size: 14px;
    line-height: 18px;
  }
  .luka-slide__title {
    font-size: 22px;
    line-height: 26px;
  }
  .luka-slide__description {
    font-size: 14px;
    line-height: 18px;
  }
  .luka-slide__nav-spacer {
    display: none;
  }
  .luka-slide__right {
    width: 100%;
    max-width: 100%;
    height: auto;
  }
  .luka-slide__image {
    height: auto;
  }
  .luka__controls {
    left: 20px;
    bottom: 20px;
  }
  .luka__cta {
    width: 100%;
    height: 58px;
    margin-top: 30px;
    padding: 0 20px;
    font-size: 16px;
  }
}

/* ==========================================================================
   Luka AI Hero Rosette Badge ("Розетка" v6)
   Isolated styles matching the v6 badge prototype without generator UI
   ========================================================================== */

/* Allow the badge to overlap the top boundary between header and hero without clipping */
.hero {
  overflow-x: clip;
  overflow-y: visible;
  z-index: 1;
}

.luka-badge {
  position: absolute;
  right: 40px;
  top: 94px;
  z-index: 10;
  display: block;
  width: 220px;
  height: 265px;
  aspect-ratio: 220 / 265;
  font-family: "Graphik LCG", "Graphik LC Web", sans-serif;
  color: #222222;
  text-decoration: none;
  user-select: none;
  -webkit-user-select: none;
  cursor: pointer;
}

/* Holographic rosette material layer masked to 20-lobed rosette silhouette */
.luka-badge__material {
  position: absolute;
  top: 45px;
  left: 0;
  width: 220px;
  height: 220px;
  overflow: hidden;
  -webkit-mask-image: url("../img/luka/badge-rosette-mask.svg");
  mask-image: url("../img/luka/badge-rosette-mask.svg");
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  pointer-events: none;
}

/* Static holographic poster displayed immediately and used as WebGPU fallback */
.luka-badge__poster {
  position: absolute;
  left: 1.273px;
  top: 1.273px;
  width: 217.454px;
  height: 217.454px;
  max-width: none;
  display: block;
  pointer-events: none;
}

/* Live WebGPU shader canvas overlaid seamlessly once first frame renders */
.luka-badge__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.luka-badge--shader-ready .luka-badge__canvas {
  opacity: 1;
}

/* 3D inner bevel and shading overlay of the rosette shape */
.luka-badge__shape {
  position: absolute;
  left: 1.273px;
  top: 1.273px;
  width: 217.454px;
  height: 217.454px;
  max-width: none;
  display: block;
  pointer-events: none;
  z-index: 1;
}

/* Foreground typography, Luka cutout portrait, and hover CTA button */
.luka-badge__foreground {
  position: absolute;
  inset: 0;
  width: 220px;
  height: 265px;
  pointer-events: none;
  z-index: 2;
  color: #222222;
  text-align: center;
}

.luka-badge__portrait {
  position: absolute;
  left: 31px;
  top: 0;
  width: 160px;
  height: 160px;
  max-width: none;
  object-fit: cover;
  display: block;
  -webkit-mask-image: url("../img/luka/badge-portrait-mask.svg");
  mask-image: url("../img/luka/badge-portrait-mask.svg");
  -webkit-mask-size: 160px 160px;
  mask-size: 160px 160px;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

.luka-badge__new {
  position: absolute;
  left: 110px;
  top: 113px;
  transform: translateX(-50%);
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px 4px 9px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-family: "Graphik LCG", "Graphik LC Web", sans-serif;
  font-weight: 500;
  font-size: 10px;
  line-height: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #222222;
  white-space: nowrap;
}

.luka-badge__name {
  position: absolute;
  left: 0.5px;
  top: 137px;
  width: 220px;
  margin: 0;
  font-family: "Graphik LCG", "Graphik LC Web", sans-serif;
  font-weight: 500;
  font-size: 18px;
  line-height: 16px;
  letter-spacing: 0;
  color: #222222;
  text-align: center;
  text-box-trim: trim-both;
  text-box-edge: cap alphabetic;
  white-space: nowrap;
}

.luka-badge__divider {
  position: absolute;
  left: 75px;
  top: 164px;
  width: 70px;
  height: 1px;
  border-radius: 2px;
  background: #000000;
  opacity: 0.2;
}

.luka-badge__tagline {
  position: absolute;
  left: 0;
  top: 176px;
  width: 220px;
  margin: 0;
  font-family: "Graphik LCG", "Graphik LC Web", sans-serif;
  font-weight: 500;
  font-size: 16px;
  line-height: 20px;
  letter-spacing: 0;
  color: #222222;
  text-align: center;
  text-box-trim: trim-both;
  text-box-edge: cap alphabetic;
}

.luka-badge__icon {
  position: absolute;
  left: 105px;
  top: 218px;
  width: 10px;
  height: 10px;
  max-width: none;
  display: block;
}

.luka-badge__arc {
  position: absolute;
  left: 49.5945px;
  top: 214.8253px;
  width: 122px;
  height: 33px;
  max-width: none;
  display: block;
}

/* Smooth fade-out of default caption elements on hover */
.luka-badge__tagline,
.luka-badge__icon,
.luka-badge__arc {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.14s ease, visibility 0.14s ease;
}

/* White pill CTA button that pops into view when hovering or focusing the badge */
.luka-badge__try {
  box-sizing: border-box;
  position: absolute;
  left: 0;
  right: 0;
  top: 178px;
  width: max-content;
  height: 40px;
  margin-inline: auto;
  padding: 0 16px;
  border: 1.4px solid rgba(69, 50, 35, 0.22);
  border-radius: 8px;
  background: #ffffff;
  color: #191818;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Graphik LCG", "Graphik LC Web", sans-serif;
  font-weight: 500;
  font-size: 15px;
  line-height: 15px;
  letter-spacing: 0;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px) scale(0.72);
  transform-origin: 50% 65%;
  transition: opacity 0.12s ease, transform 0.16s ease, visibility 0.16s ease,
    background-color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.luka-badge:hover .luka-badge__tagline,
.luka-badge:hover .luka-badge__icon,
.luka-badge:hover .luka-badge__arc,
.luka-badge:focus-visible .luka-badge__tagline,
.luka-badge:focus-visible .luka-badge__icon,
.luka-badge:focus-visible .luka-badge__arc {
  opacity: 0;
  visibility: hidden;
}

.luka-badge:hover .luka-badge__try,
.luka-badge:focus-visible .luka-badge__try {
  opacity: 1;
  visibility: visible;
  border-color: rgba(64, 51, 42, 0.34);
  box-shadow: inset 2.75px 3.5px 0.3px 0 rgba(133, 96, 60, 0.1);
  animation: luka-badge-try-pop 0.56s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.luka-badge:active .luka-badge__try {
  border-color: rgba(71, 66, 62, 0.53);
  box-shadow: inset 3.5px 4.7px 0.5px 0 rgba(125, 99, 74, 0.16);
}

.luka-badge:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 4px;
  border-radius: 16px;
}

@keyframes luka-badge-try-pop {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.72);
  }
  42% {
    opacity: 1;
    transform: translateY(-2px) scale(1.06);
  }
  68% {
    opacity: 1;
    transform: translateY(1px) scale(0.985);
  }
  84% {
    opacity: 1;
    transform: translateY(-0.5px) scale(1.01);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* On touch devices without hover capability, show the CTA button directly */
@media (hover: none) {
  .luka-badge__tagline,
  .luka-badge__icon,
  .luka-badge__arc {
    opacity: 0;
    visibility: hidden;
  }

  .luka-badge__try {
    opacity: 1;
    visibility: visible;
    transform: none;
    animation: none;
    transition: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .luka-badge__tagline,
  .luka-badge__icon,
  .luka-badge__arc,
  .luka-badge__try {
    transition: none;
    animation: none;
  }

  .luka-badge:hover .luka-badge__try,
  .luka-badge:focus-visible .luka-badge__try {
    animation: none;
    transform: none;
  }
}

/* Compact top-right placement bridging header and hero sections on mobile */
@media (max-width: 768px) {
  .luka-badge {
    top: -80px;
    right: 12px;
    transform: scale(0.54);
    transform-origin: top right;
  }
}
