/* Wyścig Talentów – Ambasadorzy */
.wta{
  --y:#EDB14E;--y-d:#D99A2E;--g:#4A515C;--k:#1B1B1B;--t:#6B6F78;--line:#ECEDF0;
  --gap:24px;
  font-family:'Poppins',sans-serif;max-width:1240px;margin:0 auto;padding:10px 0;
}
.wta *,.wta-modal *{box-sizing:border-box}
.wta ul{list-style:none;margin:0;padding:0}

/* tytuł */
.wta .wta-title{text-align:center;margin:0 0 14px;font-family:'Poppins',sans-serif;font-size:clamp(24px,3.2vw,38px);font-weight:600;line-height:1.25}
.wta-y{color:var(--y)}
.wta-g{color:var(--g)}
.wta-wave{position:relative;display:inline-block;padding-bottom:.28em}
.wta-wave::after{
  content:"";position:absolute;left:-2%;right:-2%;bottom:0;height:.32em;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 14' preserveAspectRatio='none'%3E%3Cpath d='M2 9 C40 2 70 13 110 7 S190 3 230 8 S280 6 298 5' fill='none' stroke='%23EDB14E' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center/100% 100%;
}
.wta-desc{text-align:center;color:var(--t);font-size:16px;line-height:1.65;max-width:680px;margin:0 auto}
.wta .wta-title + .wta-grid,.wta-desc + .wta-grid{margin-top:34px}

/* ---------- SIATKA ---------- */
.wta-grid{--c:var(--wta-cols,4);display:flex;flex-wrap:wrap;justify-content:center;gap:var(--gap)}
.wta-grid > li{flex:0 0 calc((100% - (var(--c) - 1) * var(--gap)) / var(--c));min-width:0;display:flex}

/* ---------- KARTA ---------- */
.wta .wta-card{
  all:unset;box-sizing:border-box;cursor:pointer;
  display:flex;flex-direction:column;width:100%;
  font-family:'Poppins',sans-serif;text-align:left;
  background:#fff;border-radius:20px;padding:10px 10px 0;
  border:1px solid var(--line);box-shadow:0 8px 24px rgba(0,0,0,.05);
  transition:transform .35s ease,box-shadow .35s ease;
}
.wta .wta-card:hover{transform:translateY(-6px);box-shadow:0 22px 44px rgba(0,0,0,.12)}

/* Stany najechania / kliknięcia / fokusu – nadpisujemy style przycisków z motywu i Elementora
   (to one dawały czarne tło) i podświetlamy kartę na żółto. */
.wta button.wta-card,
.wta button.wta-card:hover,
.wta button.wta-card:focus,
.wta button.wta-card:active,
.wta button.wta-card:focus-visible{
  background:#fff!important;background-image:none!important;
  color:var(--k)!important;text-decoration:none!important;text-transform:none!important;
  letter-spacing:normal!important;font-weight:inherit!important;
  border:1px solid var(--line)!important;outline:none!important;
  padding:10px 10px 0!important;margin:0!important;border-radius:20px!important;
  width:100%!important;height:auto!important;min-height:0!important;line-height:normal!important;font-size:inherit!important;
}
.wta button.wta-card:hover,
.wta button.wta-card:focus-visible{
  background:#FFFBF3!important;
  border-color:var(--y)!important;
  box-shadow:0 0 0 3px rgba(237,177,78,.28),0 22px 44px rgba(217,154,46,.18)!important;
}
.wta button.wta-card:active{background:#FFF6E6!important;border-color:var(--y)!important}
.wta button.wta-card:focus:not(:focus-visible){box-shadow:0 8px 24px rgba(0,0,0,.05)}
.wta button.wta-card:hover:focus:not(:focus-visible){box-shadow:0 0 0 3px rgba(237,177,78,.28),0 22px 44px rgba(217,154,46,.18)!important}
.wta button.wta-card .wta-name{color:var(--k)!important}
.wta button.wta-card .wta-role{color:var(--t)!important}
.wta button.wta-card .wta-more{color:var(--y-d)!important}
.wta button.wta-card:hover .wta-more{color:#B9791A!important}

/* Przyciski w oknie – też bez stylów motywu */
.wta-modal .wta-m-close,.wta-modal .wta-m-nav button{border:0!important;outline:none;background-image:none!important;box-shadow:none;padding:0!important;min-height:0!important;line-height:1!important}
.wta-modal .wta-m-close{background:#F3F4F6!important;color:var(--k)!important}
.wta-modal .wta-m-close:hover,.wta-modal .wta-m-close:focus-visible{background:var(--y)!important;color:#fff!important}
.wta-modal .wta-m-nav button{background:var(--k)!important;color:#fff!important}
.wta-modal .wta-m-nav button:hover,.wta-modal .wta-m-nav button:focus-visible{background:var(--y)!important;color:#fff!important}
.wta-modal .wta-m-close:focus-visible,.wta-modal .wta-m-nav button:focus-visible{box-shadow:0 0 0 3px rgba(237,177,78,.45)!important}
.wta .wta-card:active{transform:translateY(-2px) scale(.985);transition-duration:.12s}

.wta-photo{
  position:relative;display:block;aspect-ratio:4/5;overflow:hidden;
  border-radius:14px 14px 56px 14px;background:#EEF0F3;
}
.wta-photo img{
  display:block;width:100%!important;height:100%!important;max-width:none!important;
  object-fit:cover;object-position:50% 20%;transition:transform .6s ease,filter .4s ease;
}
.wta .wta-card:hover .wta-photo img{transform:scale(1.05)}
.wta--gray .wta-photo img{filter:grayscale(1)}
.wta--gray .wta-card:hover .wta-photo img{filter:none}
.wta-photo::after{ /* delikatne przyciemnienie u dołu */
  content:"";position:absolute;inset:auto 0 0 0;height:30%;
  background:linear-gradient(180deg,transparent,rgba(27,27,27,.18));pointer-events:none;
}
.wta-initials{
  position:absolute;inset:0;display:grid;place-items:center;
  font-size:clamp(28px,4vw,46px);font-weight:700;color:#fff;
  background:linear-gradient(135deg,#F3C878,var(--y-d));
}
.wta-tags{position:absolute;top:12px;left:12px;right:12px;display:flex;flex-wrap:wrap;align-items:flex-start;gap:6px;z-index:1}
.wta-t-s{display:none}
.wta-tags > span{
  max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
  background:rgba(255,255,255,.92);color:var(--k);
  font-size:11.5px;font-weight:600;padding:4px 10px;border-radius:999px;
  backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);
}

.wta-body{display:flex;flex-direction:column;flex:1;padding:16px 10px 18px}
.wta-name{font-size:17px;font-weight:600;line-height:1.3;color:var(--k);margin-bottom:4px}
.wta-role{font-size:14px;line-height:1.45;color:var(--t);margin-bottom:12px}
.wta-more{
  margin-top:auto;display:inline-flex;align-items:center;gap:6px;
  font-size:14px;font-weight:600;color:var(--y-d);
}
.wta-more svg{width:16px;height:16px;transition:transform .25s ease}
.wta .wta-card:hover .wta-more svg{transform:translateX(4px)}

/* ---------- OKNO Z BIOGRAFIĄ ----------
   <dialog> zajmuje cały ekran i jest przezroczysty. Tło (rozmycie) i panel to zwykłe elementy
   w środku – animujemy tylko je. Safari (iPad/iPhone) ma błędy przy animowaniu samego <dialog>
   i przy rozmyciu na ::backdrop, więc ich nie używamy. */
.wta-modal{
  --y:#EDB14E;--y-d:#D99A2E;--g:#4A515C;--k:#1B1B1B;--t:#6B6F78;
  --ease-out:cubic-bezier(.16,1,.3,1);--ease-in:cubic-bezier(.5,0,.75,0);
  position:fixed;inset:0;box-sizing:border-box;width:100%;height:100%;max-width:none;max-height:none;
  margin:0;padding:20px;border:0;background:transparent;color:var(--k);overflow:hidden;
  font-family:'Poppins',sans-serif;
}
.wta-modal[open]{display:flex;align-items:center;justify-content:center}
.wta-modal::backdrop{background:transparent}

.wta-m-overlay{position:absolute;inset:0;background:rgba(20,22,28,.55);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}

.wta-m-inner{
  position:relative;z-index:1;display:flex;flex-direction:column;
  width:min(1000px,100%);max-height:min(88vh,760px);
  background:#fff;border-radius:28px 28px 28px 90px;overflow:hidden;
  box-shadow:0 40px 100px rgba(0,0,0,.3);
}
.wta-m-content{display:grid;grid-template-columns:38% 1fr;min-height:0;flex:1 1 auto;overflow:hidden}

.wta-m-photo{position:relative;background:#EEF0F3;min-height:340px}
.wta-m-photo img{position:absolute;inset:0;width:100%!important;height:100%!important;max-width:none!important;object-fit:cover;object-position:50% 20%}
.wta-m-photo .wta-initials{font-size:64px}

.wta-m-text{padding:48px 48px 90px 44px;overflow-y:auto;-webkit-overflow-scrolling:touch;max-height:min(88vh,760px)}
.wta-m-tags{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:14px}
.wta-m-tags span{background:var(--y);color:#fff;font-size:12px;font-weight:600;padding:5px 12px;border-radius:999px}
.wta-modal .wta-m-name{font-family:'Poppins',sans-serif;font-size:clamp(24px,2.6vw,32px);font-weight:700;line-height:1.2;margin:0 0 6px;color:var(--k)}
.wta-m-role{font-size:16px;font-weight:500;color:var(--y-d);margin:0 0 22px}
.wta-m-bio{font-size:15.5px;line-height:1.75;color:var(--g)}
.wta-m-bio p{margin:0 0 14px}
.wta-m-link{display:inline-block;margin-top:6px;font-weight:600;color:var(--y-d);text-decoration:none}
.wta-m-link:hover{color:var(--k)}

.wta-m-close{
  all:unset;cursor:pointer;position:absolute;top:16px;right:16px;z-index:3;
  width:44px;height:44px;border-radius:50%;display:grid;place-items:center;
  background:#F3F4F6;color:var(--k);transition:background .2s ease,transform .2s ease;
}
.wta-m-close:hover{transform:rotate(90deg)}
.wta-m-close svg,.wta-m-nav svg{width:20px;height:20px}

.wta-m-nav{
  position:absolute;right:20px;bottom:18px;z-index:3;display:flex;align-items:center;gap:10px;
  background:rgba(255,255,255,.95);padding:6px;border-radius:999px;box-shadow:0 6px 20px rgba(0,0,0,.08);
}
.wta-m-nav button{
  all:unset;cursor:pointer;width:40px;height:40px;border-radius:50%;display:grid;place-items:center;
  background:var(--k);color:#fff;transition:background .2s ease;
}
.wta-m-count{font-size:13px;font-weight:600;color:var(--t);min-width:44px;text-align:center}
.wta-m-grab{display:none}

html.wta-lock,html.wta-lock body{overflow:hidden}

/* ---------- ANIMACJE OKNA ---------- */
/* otwarcie: panel „wyrasta” z klikniętej karty, tło się rozmywa */
.wta-anim-in .wta-m-inner{animation:wta-pop .6s var(--ease-out) both}
@keyframes wta-pop{0%{opacity:0;transform:scale(.4)}60%{opacity:1}100%{opacity:1;transform:none}}
.wta-anim-in .wta-m-overlay{animation:wta-fade .45s ease both}
@keyframes wta-fade{from{opacity:0}to{opacity:1}}

/* zdjęcie odsłania się jak kurtyna */
.wta-anim-in .wta-m-photo img,.wta-anim-in .wta-m-photo .wta-initials{animation:wta-reveal .9s .08s var(--ease-out) both}
@keyframes wta-reveal{from{clip-path:inset(0 100% 0 0);-webkit-clip-path:inset(0 100% 0 0);transform:scale(1.18)}to{clip-path:inset(0 0 0 0);-webkit-clip-path:inset(0 0 0 0);transform:none}}

/* tekst wjeżdża kaskadowo */
.wta-anim-in .wta-m-text > *{animation:wta-rise .7s var(--ease-out) both}
.wta-anim-in .wta-m-text > *:nth-child(1){animation-delay:.16s}
.wta-anim-in .wta-m-text > *:nth-child(2){animation-delay:.22s}
.wta-anim-in .wta-m-text > *:nth-child(3){animation-delay:.28s}
.wta-anim-in .wta-m-text > *:nth-child(4){animation-delay:.34s}
.wta-anim-in .wta-m-text > *:nth-child(5){animation-delay:.40s}
@keyframes wta-rise{from{opacity:0;transform:translateY(22px)}to{opacity:1;transform:none}}
.wta-anim-in .wta-m-close{animation:wta-spin-in .55s .25s var(--ease-out) both}
@keyframes wta-spin-in{from{opacity:0;transform:rotate(-120deg) scale(.4)}to{opacity:1;transform:none}}
.wta-anim-in .wta-m-nav{animation:wta-rise .6s .38s var(--ease-out) both}

/* zamknięcie */
.wta-closing{pointer-events:none}
.wta-closing .wta-m-inner{animation:wta-shrink .32s var(--ease-in) both}
@keyframes wta-shrink{to{opacity:0;transform:scale(.9) translateY(14px)}}
.wta-closing .wta-m-overlay{animation:wta-fade-out .32s ease both}
@keyframes wta-fade-out{to{opacity:0}}

/* przełączanie strzałkami */
.wta-swap-next .wta-m-text > *{animation:wta-from-right .5s var(--ease-out) both}
.wta-swap-prev .wta-m-text > *{animation:wta-from-left .5s var(--ease-out) both}
.wta-swap-next .wta-m-text > *:nth-child(2),.wta-swap-prev .wta-m-text > *:nth-child(2){animation-delay:.04s}
.wta-swap-next .wta-m-text > *:nth-child(3),.wta-swap-prev .wta-m-text > *:nth-child(3){animation-delay:.08s}
.wta-swap-next .wta-m-text > *:nth-child(n+4),.wta-swap-prev .wta-m-text > *:nth-child(n+4){animation-delay:.12s}
@keyframes wta-from-right{from{opacity:0;transform:translateX(40px)}to{opacity:1;transform:none}}
@keyframes wta-from-left{from{opacity:0;transform:translateX(-40px)}to{opacity:1;transform:none}}
.wta-swap-next .wta-m-photo img,.wta-swap-prev .wta-m-photo img,
.wta-swap-next .wta-m-photo .wta-initials,.wta-swap-prev .wta-m-photo .wta-initials{animation:wta-photo-swap .6s var(--ease-out) both}
@keyframes wta-photo-swap{from{opacity:0;transform:scale(1.08)}to{opacity:1;transform:none}}

/* awaryjnie: jeśli przeglądarka nie odtworzy animacji, pokaż treść */
.wta-force-show .wta-m-inner,.wta-force-show .wta-m-inner *,.wta-force-show .wta-m-overlay{animation:none!important;opacity:1!important;transform:none!important;clip-path:none!important;-webkit-clip-path:none!important}

/* ---------- RESPONSYWNOŚĆ ---------- */
@media (max-width:1024px){ .wta-grid{--c:3} }
@media (max-width:900px) and (min-width:721px){
  /* tablet w pionie: węższe zdjęcie, więcej miejsca na tekst */
  .wta-m-content{grid-template-columns:34% 1fr}
  .wta-m-text{padding:40px 32px 88px 30px}
}
@media (max-width:720px){
  .wta{--gap:14px}
  .wta-grid{--c:2}
  .wta .wta-card,.wta button.wta-card,.wta button.wta-card:hover,.wta button.wta-card:focus,.wta button.wta-card:active{border-radius:16px!important;padding:7px 7px 0!important}
  .wta-photo{border-radius:11px 11px 40px 11px}
  .wta-body{padding:12px 6px 14px}
  .wta-name{font-size:15px}
  .wta-role{font-size:12.5px;margin-bottom:10px}
  .wta-more{font-size:12.5px}
  .wta-more-l{display:none}
  /* bez etykiet branży na kartach (zostają w oknie z biografią) */
  .wta-tags{display:none}

  /* okno: panel wysuwany od dołu */
  .wta-modal{padding:0}
  .wta-modal[open]{align-items:flex-end}
  .wta-m-inner{width:100%;max-height:92vh;border-radius:26px 26px 0 0}
  .wta-m-content{display:block;overflow-y:auto;-webkit-overflow-scrolling:touch;max-height:92vh}
  .wta-m-photo{height:280px;min-height:0}
  .wta-m-text{padding:24px 22px 96px;max-height:none;overflow:visible}
  .wta-m-nav{position:fixed;left:50%;right:auto;transform:translateX(-50%);bottom:16px}
  .wta-m-grab{display:block;position:absolute;top:8px;left:50%;width:44px;height:5px;margin-left:-22px;border-radius:3px;background:rgba(255,255,255,.85);z-index:4;box-shadow:0 1px 4px rgba(0,0,0,.25)}

  .wta-anim-in .wta-m-inner{animation:wta-sheet-up .55s var(--ease-out) both}
  @keyframes wta-sheet-up{from{transform:translateY(100%)}to{transform:none}}
  .wta-closing .wta-m-inner{animation:wta-sheet-down .34s var(--ease-in) both}
  @keyframes wta-sheet-down{to{transform:translateY(100%)}}
  .wta-dragging .wta-m-inner{animation:none;transition:none}
  .wta-anim-in .wta-m-photo img{animation-name:wta-zoom-in}
  @keyframes wta-zoom-in{from{transform:scale(1.15);opacity:.4}to{transform:none;opacity:1}}
  .wta-anim-in .wta-m-nav{animation:wta-rise-x .6s .38s var(--ease-out) both}
  @keyframes wta-rise-x{from{opacity:0;transform:translate(-50%,22px)}to{opacity:1;transform:translateX(-50%)}}
}
@media (max-width:380px){ .wta-name{font-size:14px} }
@media (prefers-reduced-motion:reduce){
  .wta *,.wta-modal,.wta-modal *{transition:none!important;animation:none!important}
}
