/* =========================================================
   ANASAYFA – VIDEO GALERİ  (AÇIK MAVİ / BEYAZ TEMA)
   Koyu zemin kaldırıldı. Üstteki beyaz "İmza projelerimiz"
   bölümünden ayrışması için hafif mavi-beyaz zemin kullanılır
   (kurumsal bölümdeki "açık gri-beyaz" ile aynı aile).
   Yuvarlak kenarla bir önceki bölümün altına biner.
   Tasarım dili aynı: cyan sol yüz, köşe işaretleri, mimari ızgara,
   ışık hatları, pusula, küpler. Video alanı koyu kalır (görüntü okunsun).
   ========================================================= */
.kg {
    --kg-ink: #0b2a4a;
    --kg-text: #3b4d5e;
    --kg-mute: #667b8c;
    --kg-line: rgba(11, 42, 74, .14);
    --kg-neon: #00d9ff;
    --kg-cyan: #25c3fd;
    --kg-ice: #7ae7ff;
    --kg-blue: #0a7fe0;
    --kg-sky: #0a8fe8;
    --kg-ease: cubic-bezier(.16, 1, .3, 1);
    position: relative;
    z-index: 4;
    margin-top: -36px;                       /* önceki bölümün altına biner (sert kesim yok) */
    padding-block: clamp(84px, 9vw, 140px) clamp(84px, 9vw, 140px);
    border-radius: 36px 36px 0 0;
    overflow: hidden;
    color: var(--kg-ink);
    font-family: 'Segoe UI', 'Helvetica Neue', Roboto, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    background:
        radial-gradient(50% 40% at 90% 4%, rgba(0, 190, 255, .16), transparent 70%),
        radial-gradient(45% 40% at 4% 94%, rgba(10, 127, 224, .12), transparent 70%),
        linear-gradient(180deg, #eaf4fb 0%, #e3f0f9 55%, #dcebf6 100%);
    box-shadow: 0 -26px 50px -30px rgba(0, 0, 0, .6);
}
.kg *, .kg *::before, .kg *::after { box-sizing: border-box; }
.kg h2, .kg h3, .kg p, .kg ul { margin: 0; padding: 0; }

/* üst kenarda yumuşak neon ışık hattı */
.kg::after { content: ""; position: absolute; left: 12%; right: 12%; top: 0; height: 2px; z-index: 4; background: linear-gradient(90deg, rgba(0, 217, 255, 0), var(--kg-neon) 50%, rgba(0, 217, 255, 0)); filter: drop-shadow(0 0 6px rgba(0, 217, 255, .85)); }

/* akan mimari ızgara */
.kg::before {
    content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0;
    background-image: linear-gradient(rgba(11, 42, 74, .055) 1px, transparent 1px), linear-gradient(90deg, rgba(11, 42, 74, .055) 1px, transparent 1px);
    background-size: 96px 96px;
    animation: kgGrid 50s linear infinite;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 90px, #000 calc(100% - 90px), transparent 100%);
    mask-image: linear-gradient(180deg, transparent 0, #000 90px, #000 calc(100% - 90px), transparent 100%);
}
@keyframes kgGrid { to { background-position: 96px 96px, 96px 96px; } }

.kg-wrap { position: relative; z-index: 2; width: min(1240px, 100% - clamp(40px, 8vw, 120px)); margin-inline: auto; }

/* ---------- ARKA PLAN HAREKETİ ---------- */
.kg-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.kg-bg > * { position: absolute; }
.kg-beam { left: -30%; width: 160%; top: var(--t); height: 1px; background: var(--kg-line); transform: rotate(-14deg); opacity: .7; }
.kg-beam::after { content: ""; position: absolute; top: 0; height: 100%; width: 22%; background: linear-gradient(90deg, transparent, var(--kg-neon), transparent); filter: drop-shadow(0 0 6px var(--kg-neon)); animation: kgBeam 9s linear infinite; animation-delay: var(--dl); }
@keyframes kgBeam { from { left: -25%; } to { left: 110%; } }
.kg-level { left: 0; right: 0; top: 0; height: 1px; opacity: 0; background: repeating-linear-gradient(90deg, rgba(10, 143, 232, .55) 0 10px, transparent 10px 22px); filter: drop-shadow(0 0 4px rgba(0, 190, 255, .55)); animation: kgLevel 16s linear infinite; }
@keyframes kgLevel { 0% { top: 6%; opacity: 0; } 8% { opacity: .7; } 92% { opacity: .7; } 100% { top: 94%; opacity: 0; } }
.kg-compass { right: -8%; bottom: -16%; width: clamp(300px, 36vw, 560px); color: var(--kg-ink); opacity: .1; animation: kgSpin 120s linear infinite; }
@keyframes kgSpin { to { transform: rotate(360deg); } }
.kg-cube { width: var(--s); left: var(--x); top: var(--y); color: #1a8fe0; opacity: .32; animation: kgCube 11s ease-in-out infinite alternate; animation-delay: var(--dl); }
@keyframes kgCube { from { transform: translateY(0) rotate(0); } to { transform: translateY(-30px) rotate(14deg); } }

/* ---------- BAŞLIK ---------- */
.kg-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px 48px; flex-wrap: wrap; margin-bottom: clamp(36px, 4.4vw, 60px); }
.kg-tag { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; font-size: 13px; font-weight: 700; letter-spacing: .3em; text-transform: uppercase; color: var(--kg-blue); }
.kg-tag::before { content: ""; width: 34px; height: 2px; background: var(--kg-cyan); box-shadow: 0 0 8px var(--kg-cyan); }
.kg-h { text-wrap: balance; max-width: 20ch; font-size: clamp(30px, 3.8vw, 54px); font-weight: 300; line-height: 1.1; letter-spacing: -.02em; color: var(--kg-ink); }
.kg-lead { margin-top: 20px; max-width: 48ch; font-size: 17px; font-weight: 300; line-height: 1.7; color: var(--kg-text); }

/* buton: projelerimiz bölümündeki dolu mavi buton ile aynı */
.kg-btn { display: inline-flex; align-items: center; padding: 15px 28px 15px 22px; border-radius: 4px; border-left: 6px solid var(--kg-cyan); background: linear-gradient(90deg, #00cfff 0%, #0077c8 100%); box-shadow: 0 4px 16px rgba(0, 207, 255, .4); color: #fff; font-size: 15px; font-weight: 600; text-decoration: none; transition: transform .3s ease, box-shadow .3s ease; }
.kg-btn span::after { content: "↗"; margin-left: 12px; display: inline-block; transition: transform .35s var(--kg-ease); }
.kg-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0, 207, 255, .6); }
.kg-btn:hover span::after { transform: translate(3px, -3px); }
.kg-btn:focus-visible { outline: 2px solid var(--kg-blue); outline-offset: 3px; }

/* ---------- SAHNE ---------- */
.kg-stage { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(0, 1fr); gap: clamp(28px, 3.4vw, 52px); align-items: start; }

/* oynatıcı çerçevesi + köşe işaretleri */
.kg-framewrap { position: relative; }
.kg-brk {
    position: absolute; inset: -14px; z-index: 3; pointer-events: none;
    --c: var(--kg-sky);
    background:
        linear-gradient(var(--c), var(--c)) 0 0 / 32px 2px no-repeat, linear-gradient(var(--c), var(--c)) 0 0 / 2px 32px no-repeat,
        linear-gradient(var(--c), var(--c)) 100% 0 / 32px 2px no-repeat, linear-gradient(var(--c), var(--c)) 100% 0 / 2px 32px no-repeat,
        linear-gradient(var(--c), var(--c)) 0 100% / 32px 2px no-repeat, linear-gradient(var(--c), var(--c)) 0 100% / 2px 32px no-repeat,
        linear-gradient(var(--c), var(--c)) 100% 100% / 32px 2px no-repeat, linear-gradient(var(--c), var(--c)) 100% 100% / 2px 32px no-repeat;
    filter: drop-shadow(0 0 4px rgba(0, 190, 255, .55));
}
.kg-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border: 1.5px solid rgba(11, 42, 74, .16); border-left: 6px solid var(--kg-cyan); border-radius: 4px; background: #16222d; box-shadow: 0 34px 70px -30px rgba(11, 42, 74, .6), 0 0 40px rgba(0, 190, 255, .14); }
.kg-frame iframe { position: absolute; inset: 0; z-index: 5; width: 100%; height: 100%; border: 0; background: #000; }
.kg-frame.is-playing .kg-poster { visibility: hidden; }

.kg-poster { all: unset; box-sizing: border-box; position: absolute; inset: 0; display: block; cursor: pointer; overflow: hidden; }
.kg-poster img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; filter: saturate(.95) brightness(.88); transition: transform 1.6s var(--kg-ease), filter .6s ease; }
.kg-poster::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(3, 12, 24, .3) 0%, rgba(3, 12, 24, .05) 40%, rgba(3, 12, 24, .62) 100%); }
.kg-poster:hover img { transform: scale(1.05); filter: saturate(1.05) brightness(1); }
.kg-poster:focus-visible { outline: 2px solid var(--kg-ice); outline-offset: -6px; }

.kg-scan { position: absolute; left: 0; right: 0; top: 0; height: 100px; z-index: 2; pointer-events: none; background: linear-gradient(180deg, rgba(0, 217, 255, 0), rgba(0, 217, 255, .16) 85%, rgba(122, 231, 255, .8) 100%); mix-blend-mode: screen; transform: translateY(-100%); animation: kgScan 7s ease-in-out infinite; }
@keyframes kgScan { 0% { transform: translateY(-100%); opacity: 0; } 12% { opacity: 1; } 70% { opacity: 1; } 100% { transform: translateY(700px); opacity: 0; } }

.kg-live { position: absolute; left: 20px; top: 18px; z-index: 3; display: inline-flex; align-items: center; gap: 10px; height: 30px; padding: 0 16px 0 12px; border-radius: 999px; background: linear-gradient(90deg, #1aa7ff 0%, #0a7fe0 100%); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; box-shadow: 0 6px 16px -6px rgba(0, 150, 255, .7); }
.kg-live i { width: 8px; height: 8px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 0 rgba(255, 255, 255, .8); animation: kgPulse 1.8s ease-out infinite; }
@keyframes kgPulse { to { box-shadow: 0 0 0 9px rgba(255, 255, 255, 0); } }

/* oynat düğmesi: dönen kesikli halka + nabız halkası (görüntü üstünde) */
.kg-play { position: absolute; left: 50%; top: 50%; z-index: 3; display: grid; place-items: center; width: clamp(70px, 9vw, 104px); aspect-ratio: 1; transform: translate(-50%, -50%); border: 2px solid var(--kg-ice); border-radius: 50%; background: radial-gradient(circle at 35% 30%, rgba(95, 227, 255, .55) 0%, rgba(13, 36, 60, .92) 70%); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #fff; box-shadow: 0 0 8px var(--kg-neon), 0 0 28px rgba(0, 217, 255, .7), 0 0 56px rgba(0, 217, 255, .35), inset 0 0 18px rgba(120, 232, 255, .5); transition: transform .35s var(--kg-ease), background .25s ease, color .25s ease; }
.kg-play svg { width: 38%; height: 38%; margin-left: 6%; filter: drop-shadow(0 0 6px var(--kg-neon)); }
.kg-play::before { content: ""; position: absolute; inset: -13px; border-radius: 50%; border: 2px dashed rgba(0, 217, 255, .75); animation: kgSpin 16s linear infinite; }
.kg-play::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid rgba(0, 217, 255, .85); animation: kgRing 2.6s ease-out infinite; }
@keyframes kgRing { from { transform: scale(1); opacity: .9; } to { transform: scale(1.7); opacity: 0; } }
.kg-poster:hover .kg-play { transform: translate(-50%, -50%) scale(1.08); background: linear-gradient(135deg, #5fe3ff 0%, #1aa7ff 100%); color: #00334f; }
.kg-poster:hover .kg-play svg { filter: none; }

/* zaman çizelgesi cetveli */
.kg-ruler { position: relative; height: 22px; margin-top: 22px; background: repeating-linear-gradient(90deg, rgba(11, 42, 74, .42) 0 1px, transparent 1px 16px) 0 100% / 100% 8px no-repeat, linear-gradient(90deg, rgba(11, 42, 74, .24), rgba(11, 42, 74, .24)) 0 100% / 100% 1px no-repeat; }
.kg-ruler i { position: absolute; bottom: -4px; left: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--kg-sky); box-shadow: 0 0 0 3px rgba(37, 195, 253, .3), 0 0 12px 2px rgba(0, 190, 255, .55); animation: kgRuler 9s ease-in-out infinite alternate; }
@keyframes kgRuler { from { left: 0; } to { left: calc(100% - 9px); } }

/* video adı */
.kg-meta { display: flex; align-items: center; gap: 22px; margin-top: 20px; }
.kg-meta-idx {
    font-size: clamp(54px, 6vw, 84px); font-weight: 200; line-height: .85; letter-spacing: -.04em; font-variant-numeric: tabular-nums;
    color: transparent; -webkit-text-stroke: 1.4px var(--kg-cyan);
    background: linear-gradient(180deg, #0b2a4a 0%, #0a7fe0 62%, #25c3fd 100%);
    -webkit-background-clip: text; background-clip: text;
    filter: drop-shadow(0 6px 14px rgba(0, 150, 255, .25));
}
.kg-meta-sub { margin-bottom: 6px; font-size: 11px; font-weight: 700; letter-spacing: .28em; text-transform: uppercase; color: var(--kg-blue); }
.kg-meta h3 { font-size: clamp(22px, 2.4vw, 34px); font-weight: 300; line-height: 1.15; letter-spacing: -.01em; color: var(--kg-ink); }
.kg-meta-count { margin-left: auto; align-self: flex-end; font-size: 14px; letter-spacing: .1em; color: var(--kg-mute); }
.kg-meta.kg-swap > div, .kg-meta.kg-swap .kg-meta-idx { animation: kgSwap .7s var(--kg-ease); }
@keyframes kgSwap { from { opacity: 0; transform: translateY(14px); } }

/* ---------- VİDEO LİSTESİ ---------- */
.kg-list { list-style: none; display: grid; gap: 12px; }
.kg-item { all: unset; box-sizing: border-box; position: relative; width: 100%; display: flex; align-items: center; gap: 16px; padding: 12px 18px 12px 12px; border: 1px solid var(--kg-line); border-left: 5px solid rgba(37, 195, 253, .6); border-radius: 4px; background: #fff; box-shadow: 0 10px 24px -16px rgba(11, 42, 74, .45); cursor: pointer; transition: transform .4s var(--kg-ease), background .3s ease, border-color .3s ease, box-shadow .4s ease; }
.kg-item:hover { transform: translateX(6px); border-left-color: var(--kg-cyan); box-shadow: 0 16px 32px -16px rgba(0, 150, 255, .5); }
.kg-item:focus-visible { outline: 2px solid var(--kg-blue); outline-offset: 2px; }
.kg-item.is-active { border-color: rgba(10, 143, 232, .35); border-left-color: var(--kg-sky); background: linear-gradient(90deg, rgba(0, 217, 255, .14), #fff 70%); box-shadow: 0 16px 34px -14px rgba(0, 150, 255, .5); }

.kg-thumb { position: relative; flex: none; width: clamp(104px, 11vw, 140px); aspect-ratio: 16 / 9; overflow: hidden; border-radius: 3px; background: #16222d; box-shadow: 0 8px 18px -8px rgba(11, 42, 74, .55); }
.kg-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; filter: saturate(.95) brightness(.92); transition: transform .8s var(--kg-ease), filter .4s ease; }
.kg-item:hover .kg-thumb img, .kg-item.is-active .kg-thumb img { transform: scale(1.08); filter: saturate(1.05) brightness(1); }
.kg-item.is-active .kg-thumb { box-shadow: 0 0 0 1.5px var(--kg-sky), 0 6px 16px -4px rgba(0, 190, 255, .55); }
.kg-thumb-play { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(3, 12, 24, .3); color: #fff; transition: background .3s ease; }
.kg-thumb-play svg { width: 26px; height: 26px; padding: 6px; border-radius: 50%; background: rgba(0, 150, 255, .85); box-shadow: 0 0 12px rgba(0, 217, 255, .6); }
.kg-item:hover .kg-thumb-play { background: rgba(3, 12, 24, .08); }

.kg-item-txt { display: flex; flex-direction: column; min-width: 0; gap: 4px; }
.kg-item-txt small { font-size: 11px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--kg-blue); }
.kg-item-txt b { font-size: clamp(15px, 1.4vw, 18px); font-weight: 500; line-height: 1.25; color: var(--kg-ink); }

/* oynayan videoda hareketli ekolayzır */
.kg-eq { margin-left: auto; display: none; align-items: flex-end; gap: 3px; height: 18px; flex: none; }
.kg-eq i { width: 3px; height: 100%; border-radius: 2px; background: var(--kg-sky); box-shadow: 0 0 6px rgba(0, 190, 255, .6); transform-origin: bottom; animation: kgEq 1s ease-in-out infinite; }
.kg-eq i:nth-child(2) { animation-delay: -.35s; }
.kg-eq i:nth-child(3) { animation-delay: -.7s; }
@keyframes kgEq { 0%, 100% { transform: scaleY(.25); } 50% { transform: scaleY(1); } }
.kg-item.is-active .kg-eq { display: flex; }

/* ---------- AÇILIŞ ANİMASYONLARI (yalnızca .kg-js) ---------- */
.kg-js [data-kg="up"] { opacity: 0; transform: translateY(22px); transition: opacity 1s ease var(--d, 0ms), transform 1s var(--kg-ease) var(--d, 0ms); }
.kg-js [data-kg="up"].kg-in { opacity: 1; transform: none; }
.kg-js .kg-list [data-kg="up"] { transform: translateX(30px); }
.kg-js .kg-list [data-kg="up"].kg-in { transform: none; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1000px) {
    .kg-stage { grid-template-columns: 1fr; gap: 56px; }
    .kg-list { grid-template-columns: 1fr 1fr; }
    .kg-compass { display: none; }
}
@media (max-width: 700px) {
    .kg { margin-top: -28px; border-radius: 28px 28px 0 0; padding-block: 76px 76px; }
    .kg-wrap { width: calc(100% - 32px); }
    .kg-lead { font-size: 16px; }
    .kg-head { gap: 26px; }
    .kg-btn { width: 100%; justify-content: center; }
    .kg-brk { inset: -9px; }
    .kg-live { left: 12px; top: 12px; height: 26px; font-size: 10px; padding: 0 12px 0 10px; }
    .kg-meta { gap: 16px; }
    .kg-meta-count { display: none; }
    .kg-list { grid-template-columns: 1fr; }
    .kg-cube { display: none; }
    .kg-stage { gap: 44px; }
}
@media (prefers-reduced-motion: reduce) {
    .kg *, .kg *::before, .kg *::after { transition-duration: .01ms !important; animation: none !important; }
}