/* matematik.css — Matematik Köyü'nün 5 mini oyunu (Adım 3, js/matematik.js) */

/* Köy oyunları yalnız krallıktan açılır: menü yeniden çizilirse kartları görünmesin */
.game-card[data-game^="mat-"] { display: none !important; }

.mat-yuzey { align-items: center; justify-content: center; overflow: hidden; }
.tur-sahne.mat-soru, .mat-sahne {
    width: 100%; flex: 1 1 auto; border-radius: 26px; padding: 16px;
    background: linear-gradient(rgba(255, 255, 255, .35), rgba(255, 255, 255, .35)), url('../assets/img/ogrenme/bg/elma-koyu.webp') center / cover;
}
.mat-sahne { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; }
.mat-soru .st-secenek .st-emoji { font-size: clamp(48px, 7vw, 72px); }

/* ---------------------------------------------------------------- kaç tane */
.mat-cimen {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; padding: 14px 20px; max-width: 640px; margin: 0 auto;
    background: rgba(255, 255, 255, .75); border-radius: 30px; box-shadow: 0 10px 24px rgba(60, 120, 50, .16);
}
.mat-say {
    position: relative; width: clamp(70px, 9vw, 96px); height: clamp(70px, 9vw, 96px); border: 0; background: none; padding: 0;
    display: grid; place-items: center; animation: st-cik .4s backwards cubic-bezier(.3, 1.6, .5, 1);
    -webkit-tap-highlight-color: transparent;
}
.mat-say img, .mat-dal-elma img, .mat-sepetteki img, .mat-boy img, .mat-sira-nesne img, .mat-dizilen img {
    width: 100%; height: 100%; object-fit: contain; pointer-events: none;
}
.mat-say .st-emoji, .mat-dal-elma .st-emoji, .mat-sepetteki .st-emoji { font-size: 52px; }
.mat-say.sayildi { animation: mat-zipla .35s cubic-bezier(.3, 1.6, .5, 1); }
.mat-rozet {
    position: absolute; right: -4px; top: -4px; min-width: 34px; height: 34px; border-radius: 17px; padding: 0 6px;
    background: #ffd23f; color: #8a3b9e; font: 800 24px/34px 'Baloo 2', 'Nunito', system-ui, sans-serif;
    border: 3px solid #fff; box-shadow: 0 3px 8px rgba(0, 0, 0, .18); pointer-events: none;
}

/* ---------------------------------------------------------------- eksik elmalar */
.mat-eksik { flex-direction: row; flex-wrap: wrap; gap: 26px; }
.mat-agac { position: relative; width: min(380px, 44vw, 56vh); aspect-ratio: 1; }
.mat-agac > img, .mat-agac > .st-emoji { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; font-size: 220px; text-align: center; filter: drop-shadow(0 12px 14px rgba(40, 90, 40, .25)); }
.mat-dal-elma {
    position: absolute; width: 19%; height: 19%; transform: translate(-50%, -50%); z-index: 1; border: 0; background: none; padding: 0;
    display: grid; place-items: center; animation: st-cik .4s backwards cubic-bezier(.3, 1.6, .5, 1);
    -webkit-tap-highlight-color: transparent; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .2));
}
.mat-dal-elma.alindi { visibility: hidden; }
.mat-dal-elma.parla, .mat-sepetteki.parla { animation: mat-parla 1s ease-in-out infinite; }
.mat-sepet-alan { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.mat-sepet { position: relative; width: min(300px, 38vw, 44vh); aspect-ratio: 1; display: grid; place-items: center; }
.mat-sepet > img, .mat-sepet > .st-emoji { width: 100%; height: 100%; object-fit: contain; font-size: 140px; text-align: center; }
.mat-sepet-ic {
    position: absolute; left: 14%; right: 14%; top: 14%; height: 44%;
    display: flex; flex-wrap: wrap-reverse; justify-content: center; align-content: flex-start; gap: 2px;
}
.mat-sepetteki {
    width: 30%; aspect-ratio: 1; border: 0; background: none; padding: 0; display: grid; place-items: center;
    animation: mat-dus .45s cubic-bezier(.3, 1.4, .5, 1); -webkit-tap-highlight-color: transparent;
}
.mat-sepetteki .st-emoji { font-size: 34px; }
.mat-sepet.tamam { animation: ny-canlan .9s ease-in-out 2; }
.mat-hedef { display: flex; gap: 4px; flex-wrap: wrap; justify-content: center; padding: 6px 12px; background: rgba(255, 255, 255, .7); border-radius: 24px; }
.mat-hedef span { width: 44px; height: 44px; display: grid; place-items: center; filter: grayscale(1) brightness(1.5); opacity: .4; transition: opacity .25s, filter .25s; }
.mat-hedef span img { width: 100%; height: 100%; object-fit: contain; }
.mat-hedef span .st-emoji { font-size: 32px; }
.mat-hedef span.dolu { filter: none; opacity: 1; animation: ny-otur .35s cubic-bezier(.3, 1.6, .5, 1); }
.mat-hedef span.fazla { filter: drop-shadow(0 0 6px #ffb300); opacity: 1; animation: st-salla .45s; }
.mat-onay {
    width: 84px; height: 84px; border-radius: 50%; border: 0; background: #4cc777; color: #fff;
    font: 800 46px/1 system-ui, sans-serif; box-shadow: 0 7px 0 #2f9a55, 0 12px 20px rgba(40, 120, 70, .3);
    -webkit-tap-highlight-color: transparent;
}
.mat-onay:active { transform: translateY(5px); box-shadow: 0 2px 0 #2f9a55; }
.mat-onay.salla { animation: st-salla .45s; }
.mat-onay.parla { animation: mat-parla 1s ease-in-out infinite; }

/* ---------------------------------------------------------------- büyük-küçük */
.mat-boy { width: 100%; height: 100%; display: grid; place-items: center; }
.mat-boy > * { transform: scale(var(--b)); }
.mat-boy img { width: 100%; height: 100%; }

/* ---------------------------------------------------------------- sıralama */
.mat-raf, .mat-yuvalar {
    display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end; gap: clamp(8px, 2vw, 22px);
    padding: 14px 20px; background: rgba(255, 255, 255, .78); border-radius: 30px; box-shadow: 0 10px 24px rgba(120, 70, 50, .14);
}
.mat-sira-nesne, .mat-yuva {
    --k: clamp(112px, 20vw, 168px);
    width: calc(var(--k) * var(--b)); height: calc(var(--k) * var(--b));
}
.mat-sira-nesne {
    border: 0; background: none; padding: 0; display: grid; place-items: center; font-size: calc(70px * var(--b));
    animation: st-cik .45s backwards cubic-bezier(.3, 1.6, .5, 1); -webkit-tap-highlight-color: transparent;
    filter: drop-shadow(0 5px 5px rgba(90, 50, 30, .2));
}
.mat-sira-nesne.dizildi { visibility: hidden; }
.mat-sira-nesne.salla { animation: st-salla .45s; }
.mat-sira-nesne.parla { animation: mat-parla 1s ease-in-out infinite; }
.mat-yuva {
    position: relative; display: grid; place-items: center;
    background: radial-gradient(ellipse 50% 10% at 50% 96%, rgba(120, 80, 60, .22), transparent);
}
.mat-golge { position: absolute; inset: 0; display: grid; place-items: center; font-size: calc(70px * var(--b)); filter: grayscale(1) brightness(1.6) opacity(.32); }
.mat-golge img { width: 100%; height: 100%; object-fit: contain; }
.mat-yuva.dolu .mat-golge { display: none; }
.mat-yuva-no {
    position: absolute; bottom: -30px; left: 50%; transform: translateX(-50%);
    font: 800 22px/1 'Baloo 2', 'Nunito', system-ui, sans-serif; color: #fff; text-shadow: 0 2px 4px rgba(120, 60, 140, .6);
}
.mat-dizilen { position: absolute; inset: 0; display: grid; place-items: center; font-size: calc(70px * var(--b)); animation: ny-otur .35s cubic-bezier(.3, 1.6, .5, 1); }
.mat-dizilen.ucuyor { animation: none; will-change: transform; }       /* raftan yuvaya uçarken */
.mat-dizilen.oturdu { animation: mat-otur-parla .55s ease-out; }      /* yuvaya oturunca kısa parlar */
@keyframes mat-otur-parla { 0% { filter: drop-shadow(0 0 0 rgba(255, 228, 130, 0)); } 45% { filter: drop-shadow(0 0 16px rgba(255, 228, 130, .95)); } 100% { filter: drop-shadow(0 0 0 rgba(255, 228, 130, 0)); } }
.mat-yuvalar { padding-bottom: 40px; }
.mat-yuvalar.tamam .mat-dizilen { animation: mat-zipla .5s ease-in-out 2; }

/* ---------------------------------------------------------------- örüntü */
.mat-ip {
    position: relative; display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px;
    padding: 18px 22px; background: rgba(255, 255, 255, .78); border-radius: 40px; max-width: 900px; margin: 0 auto;
}
.mat-boncuk {
    position: relative; width: clamp(46px, 6.4vw, 68px); height: clamp(46px, 6.4vw, 68px); border-radius: 50%; flex: 0 0 auto;
}
.mat-boncuk img { width: 100%; height: 100%; display: block; pointer-events: none; filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .2)); }
.mat-boncuk.buyuk { width: 72%; height: 72%; }
.mat-boncuk.soru { background: none; box-shadow: none; overflow: visible; animation: mat-parla 1.4s ease-in-out infinite; }
.mat-boncuk.soru img { opacity: .55; }
.mat-boncuk.soru b {
    position: absolute; inset: 0; display: grid; place-items: center;
    font: 800 clamp(26px, 3.6vw, 36px)/1 'Baloo 2', 'Nunito', system-ui, sans-serif; color: #ff5c8d; text-shadow: 0 2px 0 #fff;
}

@keyframes mat-zipla { 0%, 100% { transform: none; } 50% { transform: translateY(-12px) scale(1.08); } }
@keyframes mat-dus { from { transform: translateY(-80px) scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes mat-parla { 0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0 rgba(255, 200, 60, 0)); } 50% { transform: scale(1.12); filter: drop-shadow(0 0 14px rgba(255, 200, 60, .95)); } }
.mat-dal-elma.parla { animation-name: mat-parla-dal; }
@keyframes mat-parla-dal { 0%, 100% { transform: translate(-50%, -50%) scale(1); } 50% { transform: translate(-50%, -50%) scale(1.2); filter: drop-shadow(0 0 14px rgba(255, 200, 60, .95)); } }

@media (max-width: 640px) {
    .mat-eksik { gap: 12px; }
    .mat-onay { width: 66px; height: 66px; font-size: 36px; }
}

/* ---------------------------------------------------------------- Boncuk Dizisi (sürüklemeli) */
.bd-sahne { display: flex; flex-direction: column; align-items: center; justify-content: space-between; height: 100%; padding: 10px 16px 14px; gap: 6px; }
.bd-kolyeler { display: flex; gap: 10px; }
.bd-kolyeler span { width: 18px; height: 18px; border-radius: 50%; background: rgba(224, 103, 200, .22); transition: background .3s, transform .3s; }
.bd-kolyeler span.tamam { background: #E067C8; }
.bd-kolyeler span.simdi { background: #fff; box-shadow: 0 0 0 3px #E067C8; transform: scale(1.2); }
.bd-ip { position: relative; width: min(980px, 94%); height: clamp(170px, 30vh, 250px); flex: 0 0 auto; }
.bd-kordon { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.bd-kordon path { fill: none; stroke: #c98a5a; stroke-width: 4px; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.bd-yer { position: absolute; width: clamp(54px, 7.2vw, 78px); height: clamp(54px, 7.2vw, 78px); transform: translate(-50%, -50%) rotate(var(--a)); border-radius: 50%; }
.bd-yer .mat-boncuk { width: 100%; height: 100%; }
.bd-yer .bd-takili.yeni { animation: bd-otur .4s cubic-bezier(.3, 1.6, .5, 1), bd-otur-parla .6s ease-out; }
@keyframes bd-otur-parla { 0% { filter: drop-shadow(0 0 0 rgba(255, 228, 130, 0)); } 45% { filter: drop-shadow(0 0 15px rgba(255, 228, 130, .95)); } 100% { filter: drop-shadow(0 0 0 rgba(255, 228, 130, 0)); } }
.bd-yer.sira { box-shadow: 0 0 0 4px rgba(255, 255, 255, .95), 0 0 0 9px rgba(224, 103, 200, .45); background: rgba(255, 255, 255, .5); animation: bd-bekle 1.3s ease-in-out infinite; }
/* 3 saniye takılınca sıradaki rengin hayaleti boş yuvada belirir (ceza yok) */
.bd-hayalet { position: absolute; inset: 4px; display: grid; place-items: center; pointer-events: none; opacity: .45; animation: bd-fisilda 1.9s ease-in-out infinite; }
.bd-hayalet .mat-boncuk { width: 100%; height: 100%; filter: saturate(.7) blur(.3px); }
@keyframes bd-fisilda { 0%, 100% { opacity: .25; transform: scale(.9); } 50% { opacity: .55; transform: scale(1); } }
.bd-ip.bitti { animation: bd-sallan 1.2s ease-in-out; }
/* Kolye tezgâhı: ahşap takı kutusu, her renk kendi gözünde */
.bd-tezgah { width: min(880px, 97%); flex: 1 1 auto; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 2%; }
.bd-takim { position: relative; width: 100%; padding: 14px 14px 12px; border-radius: 22px;
    background:
        repeating-linear-gradient(94deg, rgba(120, 74, 34, .16) 0 2px, rgba(255, 255, 255, 0) 2px 13px),
        linear-gradient(165deg, #d8a86b, #b9834a 60%, #a5713c);
    box-shadow: 0 16px 30px rgba(96, 60, 30, .38), inset 0 0 0 4px rgba(255, 233, 200, .55), inset 0 -10px 18px rgba(90, 55, 25, .35); }
.bd-takim::before { content: ''; position: absolute; left: 14px; right: 14px; top: 8px; height: 7px; border-radius: 6px;
    background: linear-gradient(rgba(255, 236, 205, .75), rgba(150, 100, 55, .25)); }
.bd-gozler { display: flex; gap: 12px; }
.bd-goz { position: relative; flex: 1 1 0; height: clamp(150px, 19vh, 196px); border-radius: 14px; overflow: hidden;
    background: #f7ecdc;
    background: color-mix(in srgb, var(--rn, #f7ecdc) 12%, #f7ecdc);
    box-shadow: inset 0 10px 18px rgba(110, 70, 35, .32), inset 0 -7px 14px rgba(255, 255, 255, .65); }
.bd-goz-adi { position: absolute; left: 50%; transform: translateX(-50%); top: 6px; z-index: 2; pointer-events: none;
    padding: 2px 9px; border-radius: 10px; background: rgba(255, 255, 255, .9);
    font: 800 14px/1.3 'Nunito', 'Baloo 2', sans-serif; letter-spacing: .2px;
    color: color-mix(in srgb, var(--rn, #8a5a3a) 78%, #3a2415); box-shadow: 0 1px 4px rgba(90, 55, 25, .25); }
.bd-goz-ic { position: absolute; left: 5px; right: 5px; bottom: 7px; top: 26px; display: flex; flex-wrap: wrap; align-content: flex-end; justify-content: center; gap: 2px; }
.bd-goz .bd-tane { width: clamp(56px, 6.6vw, 74px); height: clamp(56px, 6.6vw, 74px); padding: 4px; }
.bd-tane { width: clamp(80px, 9vw, 104px); height: clamp(80px, 9vw, 104px); padding: 6px; border-radius: 50%; background: none; border: 0; touch-action: none; transform: rotate(var(--d)); cursor: grab; position: relative; z-index: 1; }
.bd-tane .mat-boncuk { width: 100%; height: 100%; }
.bd-tane.tasiniyor { z-index: 50; transition: none; filter: drop-shadow(0 14px 16px rgba(0, 0, 0, .3)); cursor: grabbing; }
.bd-tane.donuyor { transition: transform .35s cubic-bezier(.3, 1.5, .5, 1); }
.bd-tane.kullanildi { pointer-events: none; }
.bd-ucus { position: fixed; z-index: 60; pointer-events: none; padding: 6px; transition: none; filter: drop-shadow(0 8px 12px rgba(0, 0, 0, .28)); }
.bd-tane.salla { animation: bd-salla .4s; }
.bd-tane.parla { animation: mat-parla 1.2s ease-in-out infinite; }
@keyframes bd-otur { from { transform: scale(1.5); } to { transform: none; } }
@keyframes bd-bekle { 0%, 100% { scale: 1; } 50% { scale: 1.08; } }
@keyframes bd-sallan { 0%, 100% { transform: none; } 30% { transform: translateY(-14px) rotate(-2deg); } 60% { transform: translateY(-6px) rotate(2deg); } }
@keyframes bd-salla { 0%, 100% { translate: 0; } 25% { translate: -8px 0; } 75% { translate: 8px 0; } }

/* ---------------------------------------------------------------- hareketli oyuncaklar (sayma, besleme) */
.mat-sahne.mat-oyuncak { padding: 0; position: relative; display: block; }
.mat-alan { position: absolute; inset: 0; overflow: hidden; border-radius: 26px; touch-action: none; }
.mat-alan button { position: absolute; padding: 0; border: 0; background: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.mat-alan img { pointer-events: none; user-select: none; }
.mat-nesne { width: clamp(70px, 11vh, 110px); height: clamp(70px, 11vh, 110px); transform: translate(-50%, -50%);
    transition: left .55s cubic-bezier(.3, 1.3, .5, 1), top .55s cubic-bezier(.3, 1.3, .5, 1), opacity .5s;
    animation: mat-dus .5s backwards cubic-bezier(.3, 1.6, .5, 1); }
.mat-nesne img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 8px 8px rgba(40, 80, 30, .25)); animation: mat-salin 2.4s ease-in-out infinite; }
.mat-nesne:nth-child(2n) img { animation-delay: -1.2s; }
.mat-nesne .st-emoji { font-size: 52px; }
.mat-nesne.sayildi { cursor: default; }
.mat-nesne.sayildi img { animation: mat-ziplat .55s ease-out; }
.mat-nesne.sevin img { animation: mat-ziplat .5s ease-out; }
.mat-nesne.git { opacity: 0; top: 120% !important; }
.mat-nesne.parla img { animation: mat-parla 1s ease-in-out infinite; }
.mat-nesne .mat-rozet { animation: mat-rozet-gel .4s cubic-bezier(.3, 1.6, .5, 1); }
.mat-dev-sayi { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%) scale(0); pointer-events: none;
    font: 900 clamp(110px, 30vh, 240px)/1 'Baloo 2', 'Nunito', system-ui, sans-serif; color: #ff7a14;
    text-shadow: 0 8px 0 #fff, 0 14px 24px rgba(120, 60, 0, .35); transition: transform .5s cubic-bezier(.3, 1.6, .5, 1); }
.mat-dev-sayi.goster { transform: translate(-50%, -50%) scale(1); }
@keyframes mat-dus { from { transform: translate(-50%, -260%) scale(.6); opacity: 0; } }
@keyframes mat-salin { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(4deg) translateY(-3%); } }
@keyframes mat-ziplat { 40% { transform: translateY(-45%) scale(1.12, .92); } 70% { transform: translateY(0) scale(.94, 1.08); } }
@keyframes mat-parla { 0%, 100% { filter: drop-shadow(0 0 0 #ffd23f); transform: scale(1); } 50% { filter: drop-shadow(0 0 16px #ffd23f) drop-shadow(0 0 8px #fff); transform: scale(1.1); } }
@keyframes mat-rozet-gel { from { transform: scale(0); } }

.mat-besle .mat-alan { background: linear-gradient(rgba(255, 255, 255, .15), rgba(255, 255, 255, .15)), url('../assets/img/ogrenme/bg/cayir.webp') center / cover; }
.mat-hayvan { position: absolute; bottom: 3%; transform-origin: 50% 100%; }
.mat-hayvan.buyuk { left: 3%; height: 56%; }
.mat-hayvan.kucuk { right: 6%; height: 24%; }
.mat-hayvan img { height: 100%; display: block; filter: drop-shadow(0 10px 12px rgba(40, 60, 30, .3)); }
.mat-hayvan .st-emoji { font-size: 90px; }
.mat-hayvan.cigne { animation: mat-cigne .25s ease-in-out 4; }
.mat-hayvan.hayir { animation: mat-hayir .5s ease-in-out; }
.mat-hayvan.sevin { animation: mat-ziplat .6s ease-out 2; }
@keyframes mat-cigne { 50% { transform: scale(1.06, .93); } }
@keyframes mat-hayir { 20% { transform: rotate(-7deg); } 50% { transform: rotate(7deg); } 80% { transform: rotate(-4deg); } }
.mat-bk-elma { width: calc(clamp(64px, 12vh, 112px) * var(--b)); height: calc(clamp(64px, 12vh, 112px) * var(--b)); transform: translate(-50%, -50%);
    touch-action: none; transition: left .35s ease, top .35s ease, transform .35s, opacity .35s; animation: mat-dus .5s backwards cubic-bezier(.3, 1.6, .5, 1); }
.mat-bk-elma img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 6px 6px rgba(60, 30, 0, .25)); }
.mat-bk-elma .st-emoji { font-size: calc(52px * var(--b)); }
.mat-bk-elma.tasiniyor { transition: none; transform: translate(-50%, -50%) scale(1.15); z-index: 5; }
.mat-bk-elma.zipla img { animation: mat-ziplat .45s ease-out; }
.mat-bk-elma.parla img { animation: mat-parla 1s ease-in-out infinite; }
.mat-bk-elma.yendi { transform: translate(-50%, -50%) scale(.2); opacity: 0; pointer-events: none; transition: left .4s ease-in, top .4s ease-in, transform .4s ease-in, opacity .3s .25s; }

/* ---------------------------------------------------------------- 2. sürüm: müşteriler, bardaklar, kartlar, yataklar, kolye */
.mat-eksik { position: relative; }
.mat-musteri-sira { position: absolute; top: 12px; left: 50%; translate: -50% 0; display: flex; gap: 10px; z-index: 3; }
.mat-musteri-sira span { width: 18px; height: 18px; border-radius: 50%; background: rgba(255, 255, 255, .6); transition: background .3s, scale .3s; }
.mat-musteri-sira span.tamam { background: #ffb02e; }
.mat-musteri-sira span.simdi { background: #fff; box-shadow: 0 0 0 3px #ffb02e; scale: 1.2; }
.mat-sepet-alan { position: relative; }
.mat-musteri { width: min(220px, 26vw, 34vh); aspect-ratio: 1; margin-bottom: -26%; z-index: 0; transform-origin: 50% 100%; transition: translate .8s ease-in, opacity .8s; }
.mat-musteri img { width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.mat-musteri.geliyor { animation: mat-mus-gel .8s cubic-bezier(.3, 1.3, .5, 1); }
.mat-musteri.sevindi { animation: mat-ziplat .6s ease-out 2; }
.mat-musteri.gidiyor, .mat-sepet.gidiyor { translate: 140% 0; opacity: 0; }
.mat-sepet { z-index: 1; transition: translate .8s ease-in, opacity .8s; }
@keyframes mat-mus-gel { from { translate: 120% 0; opacity: 0; } }
.mat-agac { cursor: pointer; }
.mat-agac.salla > img { animation: mat-agac-salla .6s ease-in-out; transform-origin: 50% 95%; }
@keyframes mat-agac-salla { 20% { rotate: -5deg; } 45% { rotate: 4deg; } 70% { rotate: -2deg; } }
.mat-dal-elma.buyudu { animation: mat-buyu .6s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes mat-buyu { from { transform: translate(-50%, -50%) scale(0); } }
.mat-ucan-elma { position: fixed; z-index: 9999; pointer-events: none; }
.mat-ucan-elma img { width: 100%; height: 100%; object-fit: contain; }
.mat-bardak { width: clamp(80px, 13vh, 120px); height: clamp(80px, 13vh, 120px); transform: translate(-50%, -58%) rotate(180deg); z-index: 2;
    transition: transform .45s cubic-bezier(.3, 1.4, .5, 1), opacity .4s; animation: st-cik .4s backwards cubic-bezier(.3, 1.6, .5, 1); }
.mat-bardak img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 6px 6px rgba(40, 60, 30, .25)); }
.mat-bardak.kalkti { transform: translate(-50%, -160%) rotate(200deg); opacity: 0; pointer-events: none; }
.mat-bardak.parla img { animation: mat-parla 1s ease-in-out infinite; }
.mat-bardak.git { opacity: 0; }
.mat-nesne.saklı { opacity: 0; pointer-events: none; }
.mat-kartlar { position: absolute; left: 50%; top: 38%; translate: -50% -50%; display: flex; gap: 18px; z-index: 6; animation: st-cik .4s cubic-bezier(.3, 1.6, .5, 1); }
.mat-kart { position: static !important; width: clamp(80px, 13vh, 120px); height: clamp(100px, 16vh, 150px); border-radius: 22px !important;
    background: #fff !important; box-shadow: 0 8px 0 #f2c94c, 0 14px 24px rgba(0, 0, 0, .18); color: #8a3b9e;
    font: 800 clamp(54px, 9vh, 84px)/1 'Baloo 2', 'Nunito', system-ui, sans-serif; }
.mat-kart.hayir { animation: mat-hayir .5s ease-in-out; }
.mat-kart.dogru { background: #ffd23f !important; animation: mat-ziplat .5s ease-out; }
.mat-yatak .mat-alan { background: linear-gradient(rgba(255, 255, 255, .1), rgba(255, 255, 255, .1)), url('../assets/img/hayvan-evi/bg-hayvan-evi.webp') center / cover; }
.mat-yatak-yer { position: absolute; bottom: 4%; width: calc(clamp(110px, 20vh, 190px) * var(--b)); translate: -50% 0; transform-origin: 50% 100%; }
.mat-yatak-yer img { width: 100%; display: block; pointer-events: none; filter: drop-shadow(0 8px 10px rgba(60, 30, 10, .25)); }
.mat-yatak-yer.hayir { animation: mat-hayir .5s ease-in-out; }
.mat-ayi { width: calc(clamp(80px, 15vh, 140px) * var(--b)); height: calc(clamp(80px, 15vh, 140px) * var(--b)); transform: translate(-50%, -50%);
    z-index: 3; transition: left .35s ease-out, top .35s ease-out; animation: st-cik .4s backwards cubic-bezier(.3, 1.6, .5, 1); }
.mat-ayi img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 6px 6px rgba(60, 30, 0, .25)); }
.mat-ayi.tasiniyor { transition: none; transform: translate(-50%, -50%) scale(1.12); z-index: 5; }
.mat-ayi.zipla img { animation: mat-ziplat .45s ease-out; }
.mat-ayi.parla img { animation: mat-parla 1s ease-in-out infinite; }
.mat-ayi.yatti img { animation: mat-uyu 2.4s ease-in-out infinite; }
@keyframes mat-uyu { 50% { transform: scale(1.04, .96) rotate(-4deg); } }
.mat-gece { position: absolute; inset: 0; background: rgba(30, 20, 80, 0); pointer-events: none; transition: background 1.2s; z-index: 4; }
.mat-gece.karardi { background: rgba(30, 20, 80, .45); }
.bd-sahne { position: relative; }
.bd-musteri { position: absolute; right: 2%; top: 4%; width: min(150px, 18vw); aspect-ratio: 1; animation: mat-mus-gel .8s cubic-bezier(.3, 1.3, .5, 1); }
.bd-musteri img { width: 100%; height: 100%; object-fit: contain; }
.bd-musteri.sevindi { animation: mat-ziplat .6s ease-out 2; }
.bd-ip.gidiyor { transition: transform .5s ease-in, opacity .5s; transform: translate(35%, -30%) scale(.25); opacity: 0; }
.bd-takili.dalga { animation: mat-ziplat .45s ease-out; }
.bd-renkler { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; padding: 10px 12px 6px; }
.bd-sihir { width: 80px; height: 80px; border-radius: 50%; border: 0; background: #fff; font-size: 44px; box-shadow: 0 6px 0 #e067c8, 0 10px 18px rgba(0, 0, 0, .15); animation: mat-parla 1.2s ease-in-out infinite; cursor: pointer; }
