/* =========================================================
   CAFÉZIA ELEMENTOR — PREČO JE CAFÉZIA INÁ / SIMPLE v1.3.5
========================================================= */

.caf-why-modern {
  --caf-ink: #171512;
  --caf-muted: #6f675c;
  --caf-green: #BBCE8E;
  --caf-bg: #e2dbce;
  --caf-roast: #b7a997;
  --caf-white: #ffffff;
  --caf-loop-speed: 7000ms;

  position: relative;
  isolation: isolate;
  overflow: hidden;

  border-radius: clamp(26px, 3vw, 44px);
  padding: clamp(44px, 5vw, 76px) clamp(18px, 4vw, 58px);

  background:
    radial-gradient(circle at 8% 20%, rgba(187, 206, 142, 0.24), transparent 30%),
    radial-gradient(circle at 88% 10%, rgba(226, 219, 206, 0.58), transparent 34%),
    linear-gradient(135deg, #ffffff 0%, #fbfaf7 46%, #f2eee7 100%);

  box-shadow:
    0 20px 60px rgba(23, 21, 18, 0.055),
    inset 0 1px 0 rgba(255,255,255,0.82);
}

.caf-why-modern,
.caf-why-modern * {
  box-sizing: border-box;
}

.caf-why-modern::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -4;
  background-image:
    linear-gradient(rgba(23, 21, 18, 0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 21, 18, 0.022) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.48;
  -webkit-mask-image: linear-gradient(to bottom, black, transparent 82%);
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

.caf-why-modern__bg-orb {
  position: absolute;
  z-index: -3;
  border-radius: 999px;
  filter: blur(26px);
  opacity: 0.55;
  pointer-events: none;
}

.caf-why-modern__bg-orb--one {
  width: 280px;
  height: 280px;
  left: -90px;
  bottom: -110px;
  background: rgba(187, 206, 142, 0.38);
  animation: cafWhyOrbOne 9s ease-in-out infinite;
}

.caf-why-modern__bg-orb--two {
  width: 220px;
  height: 220px;
  right: -70px;
  top: -90px;
  background: rgba(226, 219, 206, 0.78);
  animation: cafWhyOrbTwo 11s ease-in-out infinite;
}

.caf-why-modern__inner {
  width: min(1480px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(300px, 0.38fr) minmax(0, 0.62fr);
  gap: clamp(34px, 5vw, 78px);
  align-items: center;
}

.caf-why-modern__content,
.caf-why-modern__interactive {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.72s ease, transform 0.72s ease;
}

.caf-why-modern.is-visible .caf-why-modern__content,
.caf-why-modern.is-visible .caf-why-modern__interactive {
  opacity: 1;
  transform: translateY(0);
}

.caf-why-modern__interactive {
  transition-delay: 0.08s;
}

.caf-why-modern__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--caf-muted);
  font-size: 12px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.caf-why-modern__eyebrow span {
  width: 38px;
  height: 1px;
  background: var(--caf-roast);
}

.caf-why-modern h2 {
  margin: 0;
  color: var(--caf-ink);
  font-size: clamp(40px, 4.35vw, 70px);
  line-height: 0.98;
  font-weight: 500;
  letter-spacing: -0.06em;
}

.caf-why-modern h2 span {
  display: block;
  color: var(--caf-green);
}

.caf-why-modern__content > p {
  max-width: 600px;
  margin: 24px 0 0;
  color: var(--caf-muted);
  font-size: clamp(16px, 1.05vw, 19px);
  line-height: 1.72;
  font-weight: 400;
}

.caf-why-modern__interactive {
  min-height: auto;
}

.caf-why-modern__cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(14px, 1.3vw, 20px);
}

.caf-why-modern__card {
  position: relative;
  isolation: isolate;
  overflow: hidden;

  min-height: 205px;
  padding: clamp(20px, 2vw, 26px);

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  border-radius: 28px;
  background: linear-gradient(145deg, rgba(255,255,255,0.76), rgba(226, 219, 206, 0.34));
  border: 1px solid rgba(183, 169, 151, 0.22);

  box-shadow:
    0 14px 36px rgba(23, 21, 18, 0.045),
    inset 0 1px 0 rgba(255,255,255,0.78);

  cursor: pointer;
  outline: none;

  opacity: 0;
  transform: translateY(18px);

  transition:
    opacity 0.65s ease,
    transform 0.65s ease,
    border-color 0.28s ease,
    box-shadow 0.28s ease,
    background-color 0.28s ease;
}

.caf-why-modern.is-visible .caf-why-modern__card {
  opacity: 1;
  transform: translateY(0);
}

.caf-why-modern.is-visible .caf-why-modern__card:nth-child(1) { transition-delay: 0.12s; }
.caf-why-modern.is-visible .caf-why-modern__card:nth-child(2) { transition-delay: 0.2s; }
.caf-why-modern.is-visible .caf-why-modern__card:nth-child(3) { transition-delay: 0.28s; }
.caf-why-modern.is-visible .caf-why-modern__card:nth-child(4) { transition-delay: 0.36s; }

.caf-why-modern__card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 12% 14%, rgba(187, 206, 142, 0.26), transparent 34%),
    radial-gradient(circle at 100% 100%, rgba(183, 169, 151, 0.16), transparent 34%);
  opacity: 0.78;
  transition: opacity 0.28s ease;
}

.caf-why-modern__card::after {
  content: "";
  position: absolute;
  top: -70%;
  left: -80%;
  width: 62%;
  height: 220%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.52), transparent);
  transform: rotate(18deg);
  opacity: 0;
  transition: left 0.58s ease, opacity 0.58s ease;
}

.caf-why-modern__icon {
  width: 60px;
  height: 60px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: var(--caf-ink);
  background: rgba(187, 206, 142, 0.28);
  border: 1px solid rgba(187, 206, 142, 0.44);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.82),
    0 10px 24px rgba(187, 206, 142, 0.16);
  transition:
    transform 0.28s ease,
    background-color 0.28s ease,
    border-color 0.28s ease,
    box-shadow 0.28s ease;
}

.caf-why-modern__icon svg {
  width: 30px;
  height: 30px;
  overflow: visible;
}

.caf-why-modern__icon svg path {
  fill: none;
  stroke: currentColor;
  stroke-width: 3.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.caf-why-modern__card-body {
  margin-top: 24px;
}

.caf-why-modern__card h3 {
  margin: 0;
  color: var(--caf-ink);
  font-size: clamp(22px, 1.8vw, 30px);
  line-height: 1.05;
  font-weight: 500;
  letter-spacing: -0.045em;
}

.caf-why-modern__card p {
  margin: 10px 0 0;
  color: var(--caf-muted);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
}

.caf-why-modern__progress {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 15px;
  height: 3px;
  border-radius: 999px;
  background: rgba(187, 206, 142, 0.24);
  overflow: hidden;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.caf-why-modern__progress::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--caf-green), rgba(183, 169, 151, 0.9));
  transform: scaleX(0);
  transform-origin: left center;
}

.caf-why-modern__card.is-active,
.caf-why-modern__card:hover,
.caf-why-modern__card:focus-visible {
  transform: translateY(-5px);
  border-color: rgba(187, 206, 142, 0.58);
  box-shadow:
    0 22px 56px rgba(23, 21, 18, 0.08),
    0 0 0 5px rgba(187, 206, 142, 0.10),
    inset 0 1px 0 rgba(255,255,255,0.86);
}

.caf-why-modern__card.is-active::after,
.caf-why-modern__card:hover::after,
.caf-why-modern__card:focus-visible::after {
  left: 118%;
  opacity: 1;
}

.caf-why-modern__card.is-active .caf-why-modern__icon,
.caf-why-modern__card:hover .caf-why-modern__icon,
.caf-why-modern__card:focus-visible .caf-why-modern__icon {
  transform: scale(1.08) rotate(-3deg);
  background: rgba(187, 206, 142, 0.44);
  border-color: rgba(187, 206, 142, 0.82);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.82),
    0 14px 30px rgba(187, 206, 142, 0.28);
}

.caf-why-modern__card.is-active .caf-why-modern__progress {
  opacity: 1;
  transform: translateY(0);
}

.caf-why-modern__card.is-active .caf-why-modern__progress::before {
  animation: cafWhyProgress var(--caf-loop-speed) linear forwards;
}

@keyframes cafWhyOrbOne {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(30px, -18px, 0) scale(1.06); }
}

@keyframes cafWhyOrbTwo {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-24px, 28px, 0) scale(1.08); }
}

@keyframes cafWhyProgress {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

@media (max-width: 1180px) {
  .caf-why-modern__inner {
    grid-template-columns: 1fr;
  }

  .caf-why-modern__content {
    max-width: 850px;
  }
}

@media (max-width: 767px) {
  .caf-why-modern {
    padding: 40px 14px;
    border-radius: 24px;
  }

  .caf-why-modern__eyebrow {
    font-size: 10px;
    letter-spacing: 0.12em;
  }

  .caf-why-modern__eyebrow span {
    width: 30px;
  }

  .caf-why-modern h2 {
    font-size: clamp(34px, 10vw, 46px);
    line-height: 1.02;
  }

  .caf-why-modern__content > p {
    margin-top: 18px;
    font-size: 16px;
    line-height: 1.62;
  }

  .caf-why-modern__cards {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .caf-why-modern__card {
    min-height: auto;
    padding: 18px;
    border-radius: 22px;
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 15px;
    align-items: center;
  }

  .caf-why-modern__icon {
    width: 56px;
    height: 56px;
  }

  .caf-why-modern__card-body {
    margin-top: 0;
  }

  .caf-why-modern__card h3 {
    margin: 0 0 5px;
    font-size: 20px;
  }

  .caf-why-modern__card p {
    margin: 0;
    font-size: 14px;
    line-height: 1.46;
  }

  .caf-why-modern__progress {
    left: 16px;
    right: 16px;
    bottom: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .caf-why-modern,
  .caf-why-modern *,
  .caf-why-modern::before,
  .caf-why-modern::after {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }

  .caf-why-modern__content,
  .caf-why-modern__interactive,
  .caf-why-modern__card {
    opacity: 1 !important;
  }
}

body.elementor-editor-active .caf-why-modern__content,
body.elementor-editor-active .caf-why-modern__interactive,
body.elementor-editor-active .caf-why-modern__card,
body.elementor-editor-preview .caf-why-modern__content,
body.elementor-editor-preview .caf-why-modern__interactive,
body.elementor-editor-preview .caf-why-modern__card,
.elementor-editor-active .caf-why-modern__content,
.elementor-editor-active .caf-why-modern__interactive,
.elementor-editor-active .caf-why-modern__card,
.elementor-editor-preview .caf-why-modern__content,
.elementor-editor-preview .caf-why-modern__interactive,
.elementor-editor-preview .caf-why-modern__card {
  opacity: 1 !important;
  transform: none !important;
}

body.elementor-editor-active .caf-why-modern,
body.elementor-editor-preview .caf-why-modern,
.elementor-editor-active .caf-why-modern,
.elementor-editor-preview .caf-why-modern {
  min-height: auto !important;
}
