/* BGame — profesyonel sunucu portalı */

:root {
  --bg-fallback: #050403;
  --bg-card: rgba(10, 9, 14, 0.68);
  --bg-card-hover: rgba(16, 14, 22, 0.82);
  --border: rgba(255, 240, 220, 0.09);
  --text: #f7f4ef;
  --muted: #b5aea5;
  --muted-2: #8a837a;
  --accent: #ea580c;
  --accent-mid: #f97316;
  --accent-gold: #fbbf24;
  --silver: #ebe6df;
  --space-xs: 0.35rem;
  --space-sm: 0.75rem;
  --space-md: 1.25rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 26px;
  --shadow-card:
    0 1px 0 rgba(255, 255, 255, 0.04) inset,
    0 10px 28px -8px rgba(0, 0, 0, 0.55),
    0 24px 48px -20px rgba(0, 0, 0, 0.45);
  --shadow-hover:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 16px 36px -10px rgba(0, 0, 0, 0.55),
    0 32px 64px -24px rgba(0, 0, 0, 0.5);
  --font: "Plus Jakarta Sans", system-ui, sans-serif;
  --font-display: "Cinzel", serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg-fallback);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* İçeriğe geç */
.skip-link {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.55rem 1rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #1a1008;
  background: linear-gradient(135deg, var(--accent-gold), var(--accent-mid));
  border-radius: 999px;
  text-decoration: none;
  clip-path: inset(100%);
  transition: clip-path 0.2s ease, transform 0.2s ease;
}

.skip-link:focus {
  clip-path: inset(0);
  outline: 2px solid var(--text);
  outline-offset: 3px;
}

/* —— Arka plan katmanları —— */
.bg-video-wrap {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background-color: var(--bg-fallback);
}

.bg-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transform: scale(1.02);
}

.bg-scrim {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(
    185deg,
    rgba(3, 2, 5, 0.42) 0%,
    rgba(5, 4, 8, 0.52) 42%,
    rgba(8, 7, 11, 0.76) 68%,
    rgba(3, 2, 3, 0.94) 100%
  );
}

.bg-vignette {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  box-shadow:
    inset 0 0 140px rgba(0, 0, 0, 0.55),
    inset 0 -100px 140px rgba(0, 0, 0, 0.5);
}

.bg-grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.055;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

/* —— Üst çizgi —— */
.top-bar {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  padding: var(--space-sm) var(--space-md) 0;
}

.top-bar__line {
  flex: 1;
  max-width: min(160px, 28vw);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(251, 191, 36, 0.35), transparent);
  opacity: 0.85;
}

.top-bar__label {
  flex-shrink: 0;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted-2);
}

/* —— Logo —— */
.site-header {
  position: relative;
  z-index: 3;
  text-align: center;
  padding: clamp(1.25rem, 3vw, 2.25rem) var(--space-md) clamp(0.75rem, 2vw, 1.25rem);
}

.brand {
  display: flex;
  justify-content: center;
  align-items: center;
}

.brand__logo {
  display: block;
  max-width: min(400px, 92vw);
  max-height: min(176px, 26vh);
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 10px 36px rgba(0, 0, 0, 0.65));
  transition: transform 0.5s var(--ease-out), filter 0.5s ease;
}

.brand__logo:hover {
  transform: translateY(-2px);
  filter: drop-shadow(0 14px 44px rgba(249, 115, 22, 0.12));
}

/* —— Ana içerik —— */
.wrap {
  position: relative;
  z-index: 3;
  flex: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(2rem, 5.5vw, 4rem) clamp(1rem, 4vw, 2rem) clamp(2.5rem, 6vw, var(--space-xl));
}

.page-head {
  margin-bottom: clamp(var(--space-lg), 4vw, 2.5rem);
  text-align: center;
}

.page-head__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 var(--space-md);
  padding: 0.4rem 1rem 0.4rem 0.7rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 999px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.page-head__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-mid), var(--accent-gold));
  box-shadow: 0 0 14px rgba(249, 115, 22, 0.55);
  animation: pulse-dot 2.8s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.88;
    transform: scale(1.06);
  }
}

.page-title {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4.8vw, 2.75rem);
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.12;
  background: linear-gradient(
    168deg,
    #ffffff 0%,
    var(--silver) 30%,
    var(--accent-mid) 72%,
    var(--accent-gold) 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 6px 24px rgba(234, 88, 12, 0.15));
}

.page-head__sub {
  margin: 0 auto;
  max-width: 32rem;
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.6;
  color: var(--muted);
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.88);
}

.page-head__rule {
  margin: clamp(1.5rem, 4vw, 2rem) auto 0;
  width: min(100%, 420px);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.14), transparent);
  opacity: 0.9;
}

/* —— Bölüm: sunucular —— */
.games-block {
  margin-top: var(--space-md);
}

.games {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 292px), 1fr));
  gap: clamp(1.15rem, 2.8vw, 1.65rem);
}

.game-card {
  position: relative;
  border-radius: var(--radius-lg);
  isolation: isolate;
  overflow: hidden;
  transition: transform 0.45s var(--ease-out);
}

.game-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.45) inset,
    var(--shadow-card);
  z-index: -1;
  pointer-events: none;
  transition: border-color 0.35s ease, box-shadow 0.45s var(--ease-out);
}

.game-card:hover::before {
  border-color: rgba(251, 191, 36, 0.32);
  box-shadow:
    0 0 0 1px rgba(249, 115, 22, 0.1) inset,
    0 0 60px -10px rgba(249, 115, 22, 0.22),
    var(--shadow-hover);
}

.game-card:hover {
  transform: translateY(-6px);
}

.game-card--pasif .game-card__media img {
  filter: saturate(0.92) brightness(0.96);
}

/* Durum çubuğu — görselin üstünde ayrı şerit, tipografi sakin */
.game-card__status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  padding: 0.58rem 1rem 0.62rem;
  flex-wrap: wrap;
  background: rgba(7, 7, 11, 0.92);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(14px) saturate(1.1);
  -webkit-backdrop-filter: blur(14px) saturate(1.1);
}

.game-card__status-bar--aktif {
  background: linear-gradient(
    105deg,
    rgba(4, 47, 46, 0.55) 0%,
    rgba(7, 7, 11, 0.94) 42%,
    rgba(7, 7, 11, 0.96) 100%
  );
  border-bottom-color: rgba(45, 212, 191, 0.12);
}

.game-card__status-bar--pasif {
  background: linear-gradient(
    105deg,
    rgba(55, 28, 28, 0.42) 0%,
    rgba(7, 7, 11, 0.94) 42%,
    rgba(7, 7, 11, 0.96) 100%
  );
  border-bottom-color: rgba(248, 113, 113, 0.1);
}

.game-card__pill {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.7rem;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  border-radius: 999px;
  border: 1px solid transparent;
}

.game-card__pill--aktif {
  color: #a7f3d0;
  background: rgba(16, 185, 129, 0.14);
  border-color: rgba(52, 211, 153, 0.32);
  box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.06) inset;
}

.game-card__pill--pasif {
  color: #fecaca;
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(248, 113, 113, 0.26);
  box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.05) inset;
}

.game-card__opens {
  flex: 1;
  min-width: min(100%, 12rem);
  margin: 0;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.01em;
  color: rgba(226, 232, 240, 0.78);
  text-align: right;
}

.game-card__status-bar--aktif .game-card__opens {
  color: rgba(167, 243, 208, 0.88);
  font-weight: 600;
}

.game-card__status-bar--pasif .game-card__opens {
  color: rgba(203, 213, 225, 0.82);
}

.game-card__link {
  display: block;
  color: inherit;
  text-decoration: none;
  border-radius: var(--radius-lg);
  outline: none;
}

.game-card__link:focus-visible {
  outline: 2px solid var(--accent-mid);
  outline-offset: 5px;
}

.game-card__media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 0;
}

.game-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
  pointer-events: none;
}

.game-card__media img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  transition: transform 0.55s var(--ease-out);
}

.game-card:hover .game-card__media img {
  transform: scale(1.03);
}

.game-card__shine {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    125deg,
    transparent 38%,
    rgba(255, 255, 255, 0.055) 50%,
    transparent 62%
  );
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.game-card:hover .game-card__shine {
  opacity: 1;
}

.game-card__body {
  position: relative;
  padding: 1.15rem 1.2rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--bg-card);
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 0;
  backdrop-filter: blur(22px) saturate(1.15);
  -webkit-backdrop-filter: blur(22px) saturate(1.15);
  transition: background 0.35s ease, border-color 0.35s ease;
}

.game-card:hover .game-card__body {
  background: var(--bg-card-hover);
  border-color: rgba(251, 191, 36, 0.18);
}

.game-card__info {
  min-width: 0;
  flex: 1;
}

.game-card__title {
  margin: 0 0 0.25rem;
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.28;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.55);
}

.game-card__meta {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--muted-2);
}

.game-card__cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.52rem 0.88rem 0.52rem 1rem;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #141008;
  background: linear-gradient(145deg, #fde68a 0%, var(--accent-mid) 42%, var(--accent) 100%);
  border-radius: 999px;
  box-shadow:
    0 2px 10px rgba(249, 115, 22, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.28);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s ease;
}

.game-card__cta-icon {
  display: inline-flex;
  width: 1.32rem;
  height: 1.32rem;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.14);
}

.game-card__cta-icon::after {
  content: "";
  width: 0.32rem;
  height: 0.32rem;
  border-right: 2px solid #141008;
  border-top: 2px solid #141008;
  transform: translate(-1px, 0) rotate(45deg);
}

.game-card:hover .game-card__cta {
  transform: translateX(3px);
  box-shadow:
    0 4px 18px rgba(249, 115, 22, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.32);
}

/* —— Footer —— */
.site-footer {
  position: relative;
  z-index: 3;
  margin-top: auto;
  padding: clamp(1.75rem, 4vw, 2.75rem) clamp(1rem, 4vw, 2rem) clamp(2rem, 5vw, 3rem);
}

.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
}

.site-footer__copy {
  margin: 0 0 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--muted);
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.9);
}

.site-footer__meta {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--muted-2);
  max-width: 36rem;
  margin-left: auto;
  margin-right: auto;
}

/* —— Toast —— */
.toast-root {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  padding: 1rem 1rem 1.5rem;
}

.toast {
  max-width: min(26rem, calc(100vw - 2rem));
  padding: 0.85rem 1.15rem;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.45;
  color: var(--text);
  text-align: center;
  background: rgba(12, 10, 16, 0.92);
  border: 1px solid rgba(251, 191, 36, 0.22);
  border-radius: var(--radius-sm);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.3s var(--ease-out),
    transform 0.3s var(--ease-out);
}

.toast--visible {
  opacity: 1;
  transform: translateY(0);
}

@media (min-width: 960px) {
  .games {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
}

@media (max-width: 640px) {
  .game-card__body {
    flex-wrap: wrap;
    padding: 1.05rem 1.1rem 1.15rem;
  }

  .game-card__cta {
    width: 100%;
    justify-content: center;
  }

  .game-card__status-bar {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .game-card__opens {
    text-align: center;
    font-size: 0.78rem;
  }

  .game-card__pill {
    align-self: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .brand__logo,
  .game-card,
  .game-card__media img,
  .game-card__shine,
  .game-card__cta,
  .page-head__dot,
  .toast {
    transition: none !important;
    animation: none !important;
  }

  .game-card:hover {
    transform: none;
  }

  .game-card:hover .game-card__media img {
    transform: none;
  }

  .brand__logo:hover {
    transform: none;
  }

  .toast {
    opacity: 1;
    transform: none;
  }
}
