/* Ana sayfa hareket katmanı (yalnızca index.html).
   Veri, güvenlik veya sayfa yapısına dokunmaz; kaldırmak için index.html'deki
   iki satırı (home-motion.css ve home-motion.js) silmek yeterlidir.
   Yalnızca kullanıcı "hareketi azalt" demediyse çalışır. */

/* Okların rengi markaya uyar (azaltılmış harekette de geçerli) */
.brand-carousel-arrow{background:var(--navy)}
.brand-carousel-arrow:hover:not(:disabled),
.brand-carousel-arrow:focus-visible:not(:disabled){background:var(--cyan)}

@media (prefers-reduced-motion: no-preference){

  /* 1) Hero metni: public-shell sayfalarda ilk boyamayı geciktirmemek için yalnızca gate modunda animasyonlanır */
  html:not(.farma-content-pending):not([data-public-shell]) .hero-copy > *{
    animation:hm-rise .75s cubic-bezier(.2,.75,.25,1) both;
  }
  html:not(.farma-content-pending):not([data-public-shell]) .hero-copy > :nth-child(1){animation-delay:.05s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-copy > :nth-child(2){animation-delay:.15s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-copy > :nth-child(3){animation-delay:.27s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-copy > :nth-child(4){animation-delay:.39s}

  /* 2) Hero görseli */
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .glass,
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .visual-caption{
    animation:
      hm-pop .8s cubic-bezier(.2,.75,.25,1) both,
      hm-float 7s ease-in-out 1s infinite;
  }
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .flask{animation-delay:.2s,1s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .cylinder{animation-delay:.34s,1.8s;animation-duration:.8s,8.5s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .petri{animation-delay:.48s,.4s;animation-duration:.8s,9.5s}
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .visual-caption{animation-delay:.7s,2s;animation-duration:.8s,10s}

  /* Molekül çizgileri çizilerek belirir */
  html:not(.farma-content-pending):not([data-public-shell]) .hero-visual .molecule svg path{
    stroke-dasharray:1400;
    animation:hm-draw 2.2s cubic-bezier(.4,.1,.2,1) .15s both;
  }

  /* İmleçle hafif derinlik (JS değişkenleri) */
  .hero-visual .orb,
  .hero-visual .molecule{
    translate:calc(var(--hm-x,0) * -10px) calc(var(--hm-y,0) * -8px);
    transition:translate .35s ease-out;
  }

  /* Yükselen küçük baloncuklar (JS ekler) */
  .hm-dot{
    position:absolute;bottom:-14px;left:var(--l);width:var(--s);height:var(--s);
    border-radius:50%;pointer-events:none;
    background:color-mix(in srgb,var(--illustration-accent,#65c6c2) 55%,transparent);
    opacity:0;animation:hm-bubble var(--d) linear var(--w) infinite;
  }

  /* 3) Hero düğmeleri: yükselme, ok kayması, parlama */
  .hero-actions .button{
    position:relative;overflow:hidden;
    transition:transform .25s ease,box-shadow .25s ease,background-color .2s,border-color .2s;
  }
  .hero-actions .button:hover{transform:translateY(-2px);box-shadow:0 10px 24px #05182c40}
  .hero-actions .button:active{transform:translateY(0)}
  .hero-actions .button-primary > span:last-child{display:inline-block;transition:translate .25s ease}
  .hero-actions .button-primary:hover > span:last-child{translate:-5px 0}
  .hero-actions .button::after{
    content:"";position:absolute;inset:0;pointer-events:none;
    background:linear-gradient(110deg,transparent 35%,#ffffff40 50%,transparent 65%);
    translate:-120% 0;
  }
  .hero-actions .button:hover::after{translate:120% 0;transition:translate .7s ease}

  /* 4) Marka kartları: üzerine gelince yükselir, logo hafif büyür */
  .brands-section .brand-tile.lab-reveal{
    transition:
      opacity .58s ease var(--lab-delay,0ms),
      translate .58s cubic-bezier(.2,.75,.25,1) var(--lab-delay,0ms),
      transform .3s ease 0ms,
      box-shadow .3s ease 0ms,
      border-color .3s ease 0ms;
  }
  /* Kaydırıcı taşmayı kestiği için yükselme ve gölge payı bırakılır (yerleşim değişmez) */
  .brands-section .brand-tiles{padding:12px 2px 22px;margin:-10px 0 -20px}
  .brands-section .brand-tile:hover,
  .brands-section .brand-tile:focus-visible{
    transform:translateY(-6px);
    box-shadow:0 18px 26px -12px #173c6433;
    border-color:var(--cyan)!important;
  }
  .brands-section .brand-tile img{transition:transform .35s ease}
  .brands-section .brand-tile:hover img{transform:scale(1.05)}
  .brand-carousel-arrow{transition:background .2s,opacity .2s,transform .2s}
  .brand-carousel-arrow:hover:not(:disabled){transform:scale(1.08)}
}

@keyframes hm-rise{from{opacity:0;translate:0 22px}to{opacity:1;translate:0 0}}
@keyframes hm-pop{from{opacity:0;scale:.92;translate:0 18px}to{opacity:1;scale:1;translate:0 0}}
@keyframes hm-float{0%,100%{translate:0 0}50%{translate:0 -9px}}
@keyframes hm-draw{from{stroke-dashoffset:1400}to{stroke-dashoffset:0}}
@keyframes hm-bubble{
  0%{opacity:0;translate:0 0}
  15%{opacity:.55}
  85%{opacity:.25}
  100%{opacity:0;translate:var(--dx,0px) -420px}
}
