/* =========================================================
   MERTK — kapak (animasyonlu)
   Siyah zemin · harf harf belirme · akan gradient · paralaks
   ========================================================= */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

:root {
  --c1: #7c8bff;
  --c2: #45d6f0;
  --c3: #c084fc;
  --grad3: linear-gradient(120deg, #7c8bff 0%, #45d6f0 45%, #c084fc 100%);
  --fg: #eceef4;
  --muted: #83889a;
  --line: rgba(255,255,255,.10);
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
}

html, body { height: 100%; }
body {
  background: #000; color: var(--fg);
  font-family: 'Inter', system-ui, sans-serif;
  line-height: 1.6; overflow: hidden; -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
.mono { font-family: var(--mono); }

.cover {
  position: relative;
  height: 100dvh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: clamp(1.2rem, 2.6vw, 2.2rem) clamp(1.3rem, 4vw, 3rem);
  overflow: hidden;
  perspective: 1400px;
}

/* ---------- Arka plan katmanları ---------- */
.bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.orb {
  position: absolute; border-radius: 50%; opacity: .6;
  will-change: transform;
}
.orb.o1 { width: 46vw; height: 46vw; max-width: 620px; max-height: 620px; background: radial-gradient(circle, rgba(124,139,255,.55), transparent 68%); top: -8%; left: -6%; animation: drift1 18s ease-in-out infinite; }
.orb.o2 { width: 40vw; height: 40vw; max-width: 560px; max-height: 560px; background: radial-gradient(circle, rgba(69,214,240,.42), transparent 68%); bottom: -12%; right: -6%; animation: drift2 22s ease-in-out infinite; }
.orb.o3 { width: 34vw; height: 34vw; max-width: 460px; max-height: 460px; background: radial-gradient(circle, rgba(168,85,247,.42), transparent 68%); top: 40%; left: 58%; animation: drift1 26s ease-in-out infinite reverse; }
@keyframes drift1 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(6%, 8%) scale(1.12); } }
@keyframes drift2 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(-7%, -6%) scale(1.1); } }

.grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: .45;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 88px 88px;
  mask-image: radial-gradient(circle at 50% 48%, #000 0%, transparent 66%);
  -webkit-mask-image: radial-gradient(circle at 50% 48%, #000 0%, transparent 66%);
}
.grain {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: .04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.vignette {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(circle at 50% 46%, transparent 42%, rgba(0,0,0,.72) 100%);
}
.spot {
  position: absolute; top: 0; left: 0; width: 660px; height: 660px;
  margin: -330px 0 0 -330px; border-radius: 50%;
  background: radial-gradient(circle, rgba(124,139,255,.16), transparent 62%);
  pointer-events: none; z-index: 1;
  transform: translate3d(-2000px, -2000px, 0);
  will-change: transform; opacity: 0; transition: opacity .4s ease;
}
.tick { position: absolute; width: 15px; height: 15px; border: 1px solid var(--line); z-index: 2; }
.tick.tl { top: calc(clamp(1.2rem,2.6vw,2.2rem) - 7px); left: calc(clamp(1.3rem,4vw,3rem) - 7px); border-right: 0; border-bottom: 0; }
.tick.tr { top: calc(clamp(1.2rem,2.6vw,2.2rem) - 7px); right: calc(clamp(1.3rem,4vw,3rem) - 7px); border-left: 0; border-bottom: 0; }
.tick.bl { bottom: calc(clamp(1.2rem,2.6vw,2.2rem) - 7px); left: calc(clamp(1.3rem,4vw,3rem) - 7px); border-right: 0; border-top: 0; }
.tick.br { bottom: calc(clamp(1.2rem,2.6vw,2.2rem) - 7px); right: calc(clamp(1.3rem,4vw,3rem) - 7px); border-left: 0; border-top: 0; }

/* ---------- Şeritler ---------- */
.top, .bottom {
  position: relative; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  font-size: .76rem; letter-spacing: .06em; color: var(--muted);
}
.top a, .bottom a { color: var(--muted); transition: color .25s; }
.top a:hover, .bottom a:hover { color: var(--fg); }
.top-links { display: flex; gap: 1.5rem; }
.status { display: inline-flex; align-items: center; gap: .55rem; }
.status i { width: 6px; height: 6px; border-radius: 50%; background: #48c78e; box-shadow: 0 0 0 3px rgba(72,199,142,.16); animation: pulse 2.4s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }

/* ---------- Sahne ---------- */
.stage { position: relative; z-index: 3; text-align: center; }

.kicker {
  display: inline-block; margin-bottom: clamp(1.1rem, 2.4vw, 1.8rem);
  font-family: var(--mono); font-size: clamp(.64rem, 1.3vw, .76rem);
  letter-spacing: .34em; text-transform: uppercase; color: var(--muted);
}
.kicker b { color: var(--c2); font-weight: 500; letter-spacing: 0; }

.brand-persp { perspective: 900px; }
.brand-tilt { transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); will-change: transform; }

.brandline {
  display: inline-block; line-height: .95;
  animation: floaty 6.5s ease-in-out infinite;
  will-change: transform;
}
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }

.lt {
  display: inline-block;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(3.2rem, 10vw, 9rem);
  letter-spacing: -.015em;
  line-height: .95;

  /* akan 3 renkli gradient */
  background: var(--grad3);
  background-size: 300% 300%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;

  animation:
    letterIn .95s cubic-bezier(.2,.7,.2,1) both,
    flow 7s linear infinite;
  will-change: transform, opacity;
}
@keyframes letterIn {
  0%   { opacity: 0; transform: translateY(40px) scale(.97); }
  60%  { opacity: 1; }
  100% { opacity: 1; transform: none; }
}
@keyframes flow { 0% { background-position: 0% 50%; } 100% { background-position: 300% 50%; } }

.lt:nth-child(1) { animation-delay: .35s, -0.0s; }
.lt:nth-child(2) { animation-delay: .45s, -0.35s; }
.lt:nth-child(3) { animation-delay: .55s, -0.70s; }
.lt:nth-child(4) { animation-delay: .65s, -1.05s; }
.lt:nth-child(5) { animation-delay: .75s, -1.40s; }

.caret {
  display: inline-block; width: .46ch; height: .72em; margin-left: .12em;
  transform: translateY(.05em); background: var(--c2);
  opacity: 0; animation: caretIn .18s ease 1.15s forwards, blink 1.05s step-end 1.3s infinite;
}
@keyframes caretIn { to { opacity: 1; } }
@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: 0; } }

.line {
  display: block; height: 1px; width: clamp(140px, 22vw, 260px);
  margin: clamp(1.4rem, 2.8vw, 2rem) auto;
  background: linear-gradient(90deg, transparent, var(--c1), var(--c2), transparent);
  transform: scaleX(0); transform-origin: center;
  animation: lineDraw .9s cubic-bezier(.6,0,.2,1) 1.05s forwards;
}
@keyframes lineDraw { to { transform: scaleX(1); } }

.tagline {
  font-family: var(--mono); font-size: clamp(.64rem, 1.35vw, .76rem);
  letter-spacing: .34em; text-transform: uppercase; color: var(--muted);
}
.tagline span { color: var(--c2); margin: 0 .3em; }

/* ---------- Giriş animasyonu (şeritler + etiketler) ---------- */
.top, .bottom, .kicker, .tagline {
  opacity: 0; transform: translateY(8px);
  animation: rise .8s cubic-bezier(.22,.61,.36,1) forwards;
}
.top { animation-delay: .15s; }
.kicker { animation-delay: .25s; }
.tagline { animation-delay: 1.25s; }
.bottom { animation-delay: 1.45s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Duyarlı ---------- */
@media (max-width: 560px) {
  .status span { display: none; }
  .kicker { letter-spacing: .22em; }
  .tagline { letter-spacing: .16em; }
  .top-links { gap: 1rem; }
}

/* ---------- Hareket azaltma ----------
   Not: Bu sayfada giriş animasyonu korunur; yalnızca film greni (titreşim)
   ve sürekli arka plan sürüklenmesi sakinleştirilir. Böylece "hareketi azalt"
   açık olan masaüstü sistemlerinde de animasyon görünür kalır. */
@media (prefers-reduced-motion: reduce) {
  .grain { animation: none !important; }
  .orb { animation-duration: 40s; }
}

/* ---------- Otomatik performans modu ----------
   JS, kare hızı düşükse <html>'e .perf-lite ekler.
   Giriş animasyonu korunur; sürekli/ağır efektler kapanır. */
.perf-lite .lt { animation-name: letterIn; }          /* akan gradient durur */
.perf-lite .orb,
.perf-lite .brandline { animation: none !important; } /* arka plan sürüklenmesi + yüzme durur */
.perf-lite .spot { display: none !important; }        /* fare ışığı kapanır */
.perf-lite .brand-tilt { transform: none !important; }/* paralaks kapanır */
.perf-lite .grain { display: none !important; }
