/*
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* ═════════════════════════════════════════════════════════════
   Studio Inbound — child theme overrides

   Pravidlo: čo sa dá v Elementore cez UI, je v JSON-e.
   Sem ide LEN to, čo Elementor neumie (kompozitné gradienty,
   pseudo-elementy, position absolute layouts, hover state matice,
   animácie, masky, hacky pre flex/grid sizing).

   Sekcie nasledujú poradie homepage:
   00 GLOBAL · EYEBROW
   01 HERO
   02 LOGOS (marquee)
   03 SERVICES
   04 TESTIMONIALS
   05 PORTFOLIO
   06 ABOUT
   07 CTA
   HEADER · FOOTER
   MOBILE MENU POPUP (Popup ID 466)
   ACCESSIBILITY
   ═════════════════════════════════════════════════════════════ */


/* ── 00 GLOBAL ─────────────────────────────────────────────── */

html {
  scroll-padding-top: 70px;
}

.elementor-nav-menu--dropdown.elementor-nav-menu__container {
  padding-top: 14px;
  padding-bottom: 14px;
}


/* ── EYEBROW (shared preset pre sekcie 03–07) ──────────────── */

.si-eyebrow__text .elementor-heading-title {
  display: flex;
  align-items: center;
}
.si-eyebrow__text .elementor-heading-title::before {
  content: "";
  display: block;
  width: 32px;
  height: 2px;
  margin-right: 12px;
  margin-bottom: 1px;
  background: var(--e-global-color-secondary, #D83D69);
  border-radius: 2px;
}


/* ── 01 HERO ───────────────────────────────────────────────── */

/* BG grid pattern — dvojitý linear-gradient (Elementor podporuje len 1) */
.si-hero__bg-grid {
  background-image:
    linear-gradient(rgba(255,255,255,1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,1) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  opacity: 0.06;
  inset: 0;
}
@media (max-width: 767px) {
  .si-hero__bg-grid { opacity: 0.04; }
}

/* Scroll indicator — "SCROLL" label + animovaný chevron ↓ */
.si-hero__scroll-text .elementor-heading-title {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
}
.si-hero__scroll-text .elementor-heading-title::after {
  content: "";
  display: block;
  width: 14px;
  height: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='rgba(255,255,255,0.55)' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  animation: si-scroll-bounce 1.8s ease-in-out infinite;
}
@keyframes si-scroll-bounce {
  0%, 100% { transform: translateY(-3px); opacity: 0.5; }
  50%      { transform: translateY(4px);  opacity: 1; }
}


/* ── 02 LOGOS ──────────────────────────────────────────────── */

/* Desktop: grayscale + transparency */
.si-logos__track .elementor-widget-image {
  filter: grayscale(100%) brightness(0.6);
  opacity: 0.6;
  transition: filter 0.25s ease, opacity 0.25s ease;
}

/* Mobile + Tablet (≤ 880px): seamless horizontal marquee, ~4 stĺpce vo vieworte.
   Items klonuje JS (mr_marquee_init) pre plynulý translate(-50%) loop. */
@media (max-width: 880px) {
  .si-logos__track {
    position: relative;
    width: 100%;
    overflow: hidden !important;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%) !important;
            mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%) !important;
  }
  .si-logos__track > .e-con-inner {
    display: flex !important;
    flex-wrap: nowrap !important;
    width: max-content !important;
    max-width: none !important;        /* Elementor default max-width 1200 → zviera marquee */
    gap: 20px;
    align-items: center;
    animation: si-marquee-scroll 16s linear infinite;
  }
  .si-logos__track:hover > .e-con-inner {
    animation-play-state: paused;
  }
  .si-logos__track .elementor-widget-image {
    flex: 0 0 auto;
  }
  .si-logos__track .elementor-widget-image img {
    max-height: 120px;                  /* inak by image renderoval na natívnych 768px */
    width: auto;
    height: auto;
  }
}

@keyframes si-marquee-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}


/* ── 03 SERVICES ───────────────────────────────────────────── */

/* Service card — komplexný hover (white→navy, color flip + pink line vľavo cez ::before).
   Elementor tieto kompozitné hover stavy na containeri + descendantov nezvláda cez UI. */
.si-services__card {
  position: relative;
  cursor: pointer;
  overflow: hidden;
  transition: background-color 0.25s ease, border-color 0.25s ease;
}
.si-services__card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--e-global-color-secondary, #D83D69);
  border-radius: 0 2px 2px 0;
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform 0.3s ease;
  border-style: var(--e-global-color-secondary, #D83D69);
}
.si-services__card:hover {
  background: var(--e-global-color-si_navy, #2C3E50) !important;
  border-color: var(--e-global-color-si_navy, #2C3E50) !important;
}
.si-services__card:hover::before { transform: scaleY(1); }
.si-services__card:hover .si-services__name .elementor-heading-title { color: #FFFFFF !important; }
.si-services__card:hover .si-services__desc,
.si-services__card:hover .si-services__desc * { color: var(--e-global-color-si_navy_pale, #C2CCCF) !important; }
.si-services__card:hover .si-services__duration-label .elementor-heading-title { color: var(--e-global-color-secondary, #D83D69) !important; }
.si-services__card:hover .si-services__duration-value .elementor-heading-title { color: #FFFFFF !important; }
.si-services__card:hover .si-services__icon { background: rgba(255,255,255,0.08) !important; }


/* ── 04 TESTIMONIALS ───────────────────────────────────────── */

.testimonials__carousel .swiper ~ .swiper-pagination-bullets.swiper-pagination-horizontal {
  left: 70px;
}
.testimonials__carousel .swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet.swiper-pagination-bullet-active {
  background: var(--e-global-color-secondary);
  width: 28px;
  border-radius: 4px;
}


/* ── 05 PORTFOLIO ──────────────────────────────────────────── */

.si-portfolio__card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.si-portfolio__card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(26,42,58,0.12);
}

@media (min-width: 768px) {
  /* Non-wide karta = polovica šírky (s kompenzáciou gap) */
  .si-portfolio__card:not(.si-portfolio__card--wide) {
    width: calc(50% - 10px);
  }
}


/* ── 06 ABOUT ──────────────────────────────────────────────── */

/* Image + badge (absolute pozicovanie v rohu) */
.si-about__img {
  position: relative;
}
.si-about__img img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center top;
}
.si-about__badge {
  position: absolute;
  bottom: 24px;
  left: auto;
  right: 0;
  width: auto;
  box-shadow: 0 8px 24px rgba(26,42,58,0.18);
}

/* Stat number "+" suffix v <em> — pink */
.si-about__stat-num em,
.si-about__stat-num .elementor-heading-title em {
  font-style: normal;
  color: var(--e-global-color-secondary, #D83D69);
}


/* ── 07 CTA ────────────────────────────────────────────────── */

.si-cta__btn .elementor-button-icon svg {
  width: 1.3em;
}


/* ── HEADER (header-main) ──────────────────────────────────── */

/* EN switcher — pri hovere skryť globe SVG (emoji efekt) */
.si-header__lang .elementor-button:hover svg {
  fill: #ffffff00 !important;
}


/* ── FOOTER (footer-main) ──────────────────────────────────── */

/* Social icons hover — pink border + pink icon */
.si-footer__socials .elementor-social-icon {
  transition: all 0.2s ease;
}
.si-footer__socials .elementor-social-icon:hover {
  border-color: var(--e-global-color-secondary, #D83D69) !important;
  color: var(--e-global-color-secondary, #D83D69) !important;
}
.si-footer__socials .elementor-social-icon:hover svg {
  fill: var(--e-global-color-secondary, #D83D69) !important;
}

/* Email link — kurzor pointer + jemný underline na hover */
.si-footer__email {
  cursor: pointer;
  text-decoration: none;
  text-decoration-color: transparent;
  text-underline-offset: 7px;
  text-decoration-thickness: 1px;
  transition: text-decoration-color 0.25s ease;
}
.si-footer__email:hover {
  text-decoration: underline;
  text-decoration-color: rgb(255 255 255 / 25%);
}
.si-footer__email:hover a,
.si-footer__email a:hover {
  color: #FFFFFF;
}


/* ── MOBILE MENU POPUP (Popup ID 466) ──────────────────────── */

/* Popup wrapper — fixed na top edge */
.si-modal-menu {
  position: fixed;
  top: 0;
  margin-top: 0;
  margin-bottom: 0;
}

/* Menu item layout — icon-box widget s číslom + linkom */
.si-menu-nav__item.elementor-widget-icon-box .elementor-icon-box-icon .elementor-icon-box-icon {
  display: inline-flex;
  align-items: center;
}
.si-menu-nav__item.elementor-widget-icon-box .elementor-icon-box-title > a {
  display: flex;
  gap: 16px;
  line-height: 1;
}
.si-menu-nav__item.elementor-widget-icon-box .elementor-icon-box-title .menu-nav__number {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--e-global-color-secondary);
  align-self: flex-start;
  padding-top: 6px;
  min-width: 24px;
}


/* Mobile menu trigger — icon swap (bars ↔ close) */
.mr-menu-trigger {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.mr-menu-trigger .e-fas-bars,
.mr-menu-trigger .mr-close-icon {
  transition: transform 0.35s ease, opacity 0.25s ease;
}
/* Close ikona položená cez bars, default neviditeľná */
.mr-menu-trigger .mr-close-icon {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 1em;
  height: 1em;
  opacity: 0;
  pointer-events: none;
  transform: rotate(-90deg);
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}
/* Popup OPEN → bars zmizne (rotuje), close sa otočí dnu */
body.mr-popup-menu-open .mr-menu-trigger .e-fas-bars {
  opacity: 0;
  transform: rotate(90deg);
}
body.mr-popup-menu-open .mr-menu-trigger .mr-close-icon {
  opacity: 1;
  transform: rotate(0deg);
}


/* Menu items — stagger IN (popup open) */
.si-menu-nav__item {
  opacity: 0; /* default skryté, animácia ho preklopí na 1 */
}
body.mr-popup-menu-open .si-menu-nav__item {
  animation: mr-menu-item-in 0.5s ease forwards;
}
body.mr-popup-menu-open .si-menu-nav__item:nth-child(1) { animation-delay: 0ms; }
body.mr-popup-menu-open .si-menu-nav__item:nth-child(2) { animation-delay: 80ms; }
body.mr-popup-menu-open .si-menu-nav__item:nth-child(3) { animation-delay: 160ms; }
body.mr-popup-menu-open .si-menu-nav__item:nth-child(4) { animation-delay: 240ms; }

@keyframes mr-menu-item-in {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* Popup footer block — fade IN po menu items (po poslednej položke @ 240+500 → cca 360ms) */
.si-popup-footer-content {
  opacity: 0;
}
body.mr-popup-menu-open .si-popup-footer-content {
  animation: mr-popup-footer-in 0.6s ease forwards;
  animation-delay: 360ms;
}

@keyframes mr-popup-footer-in {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* Popup CLOSING — jeden plynulý fade-out celého popupu (žiadne pohyby vnútri).
   Trieda 'mr-popup-menu-closing' sa pridáva v JS (mrClosePopup) pred volaním modal.hide().
   Targetuje obe menu popupy: 466 (SK) + 570 (EN). */
body.mr-popup-menu-closing #elementor-popup-modal-466,
body.mr-popup-menu-closing #elementor-popup-modal-570 {
  animation: mr-popup-fade-out 0.3s ease forwards;
  pointer-events: none;
}

@keyframes mr-popup-fade-out {
  from { opacity: 1; }
  to   { opacity: 0; }
}


/* ── ACCESSIBILITY ─────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .si-logos__track > .e-con-inner,
  .si-hero__scroll-text .elementor-heading-title::after {
    animation: none;
  }
  body.mr-popup-menu-closing #elementor-popup-modal-466,
  body.mr-popup-menu-closing #elementor-popup-modal-570,
  body.mr-popup-menu-closing .elementor-466,
  body.mr-popup-menu-closing .elementor-570,
  body.mr-popup-menu-closing .si-menu-nav__item,
  body.mr-popup-menu-closing .si-popup-footer-content,
  body.mr-popup-menu-open .si-menu-nav__item,
  body.mr-popup-menu-open .si-popup-footer-content {
    animation: none;
    opacity: 1;
  }
}
