/* =====================================================================
   home.css - Ana ekran yenilemesi (ui.css'i ezer, en son yüklenir)
   ===================================================================== */

/* --- animasyonlu stadyum arka planı (yalnızca ana ekranda görünür) --- */
.app > .home-stage {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
  opacity: 0; transition: opacity 0.45s ease;
}
.app > .home-stage.on { opacity: 1; }
.app.is-home::before { opacity: 0.25; }
.app.is-home .appbar { background: linear-gradient(180deg, rgba(5, 7, 13, 0.7), transparent); }

/* --- hero: kutu yok, sahne var --- */
.hero {
  min-height: clamp(250px, 36vh, 340px);
  padding: clamp(18px, 4vw, 40px);
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(115deg, rgba(6, 10, 20, 0.72) 0%, rgba(6, 10, 20, 0.28) 60%, rgba(6, 10, 20, 0.05));
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}
.hero::before {           /* üst kenarda ince neon çizgi */
  content: ''; position: absolute; left: 8%; right: 8%; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--neon), var(--neon-3), transparent);
  opacity: 0.85; filter: blur(0.4px);
}
.hero-copy { position: relative; z-index: 2; max-width: 560px; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border-radius: 999px;
  background: rgba(0, 229, 255, 0.08); border: 1px solid rgba(0, 229, 255, 0.28); margin-bottom: 12px; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); animation: pulseGlow 1.6s infinite; }

.hero h1.hero-logo {
  margin: 0 0 8px;
  font-family: var(--font);
  font-size: clamp(3rem, 12vw, 5.4rem);
  font-weight: 900;
  line-height: 0.92;
  letter-spacing: 0.02em;
  font-style: italic;
  transform: skewX(-6deg);
  color: #fff;
  text-shadow: 0 4px 0 rgba(0, 0, 0, 0.35), 0 0 40px rgba(0, 229, 255, 0.35);
}
.hero h1.hero-logo span {
  background: linear-gradient(180deg, #7df3ff 0%, #00b7ff 45%, #7c4dff 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 22px rgba(0, 190, 255, 0.55));
}
.hero p { color: var(--txt-1); font-size: clamp(0.85rem, 2.4vw, 1rem); max-width: 40ch; margin-bottom: 20px; }
.hero-actions .btn-play {
  position: relative; overflow: hidden;
  box-shadow: 0 10px 34px rgba(0, 160, 255, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.25) inset;
  animation: heroPulse 2.6s ease-in-out infinite;
}
.hero-actions .btn-play::after {   /* kayan parlama */
  content: ''; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: skewX(-20deg); animation: heroShine 3.4s ease-in-out infinite;
}
@keyframes heroPulse { 50% { box-shadow: 0 14px 44px rgba(0, 190, 255, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.3) inset; } }
@keyframes heroShine { 0%, 55% { left: -60%; } 100% { left: 130%; } }

/* --- sağdaki karakter + top --- */
.hero-stage { position: relative; flex: 0 0 min(38%, 330px); --sh: clamp(200px, 30vh, 290px); height: var(--sh); display: grid; place-items: end center; min-width: 150px; }
.hero-halo { position: absolute; inset: 6% -10% 8%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 200, 255, 0.4), rgba(124, 77, 255, 0.18) 60%, transparent 75%);
  filter: blur(6px); animation: haloBreath 4s ease-in-out infinite; }
.hero-char { position: relative; z-index: 1; height: var(--sh); width: auto; max-width: 100%; aspect-ratio: 340 / 380; object-fit: contain;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.6)); animation: heroFloat 3.2s ease-in-out infinite; }
.hero-ball { position: absolute; z-index: 2; width: 46px; height: 46px; left: 6%; bottom: 3%;
  animation: ballBounce 1.6s cubic-bezier(0.3, 0, 0.6, 1) infinite; }
.hero-shadow { position: absolute; bottom: 1%; left: 12%; right: 12%; height: 16px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.6), transparent); animation: shadowPulse 3.2s ease-in-out infinite; }
@keyframes heroFloat { 50% { transform: translateY(-10px); } }
@keyframes haloBreath { 50% { transform: scale(1.08); opacity: 0.8; } }
@keyframes ballBounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-46px) rotate(180deg); } }
@keyframes shadowPulse { 50% { transform: scaleX(0.9); opacity: 0.7; } }

/* --- menü kartları: renkli ikon rozetli cam kartlar --- */
.menu-grid { grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 14px; }
.menu-tile {
  --c: var(--neon);
  min-height: 108px; padding: 14px 16px; text-align: left; align-items: flex-start;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.025) 55%),
              rgba(10, 15, 26, 0.55);
  backdrop-filter: blur(14px) saturate(130%);
  -webkit-backdrop-filter: blur(14px) saturate(130%);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.menu-tile::before {       /* alt kenarda renkli çizgi */
  content: ''; position: absolute; left: 16px; right: 16px; bottom: 0; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--c), transparent); opacity: 0.55; transition: opacity 0.2s, left 0.25s, right 0.25s;
}
.menu-tile:hover::before { opacity: 1; left: 0; right: 0; }
.menu-tile .ic {
  width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-size: 1.5rem;
  background: linear-gradient(145deg, color-mix(in srgb, var(--c) 42%, transparent), color-mix(in srgb, var(--c) 10%, transparent));
  border: 1px solid color-mix(in srgb, var(--c) 55%, transparent);
  box-shadow: 0 6px 18px color-mix(in srgb, var(--c) 30%, transparent), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.25s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.menu-tile:hover .ic { transform: scale(1.12) rotate(-6deg); }
.menu-tile .t { font-size: 0.95rem; }
.menu-tile .s { color: var(--txt-1); opacity: 0.75; }
.menu-tile:hover { border-color: color-mix(in srgb, var(--c) 60%, transparent); box-shadow: 0 16px 44px rgba(0, 0, 0, 0.55), 0 0 30px var(--tile-glow); }
.pill-live { position: absolute; top: 12px; right: 12px; font-size: 0.6rem; font-weight: 800; letter-spacing: 0.12em;
  padding: 3px 8px; border-radius: 999px; color: #fff; background: var(--c); box-shadow: 0 0 14px var(--tile-glow); }

/* --- alt sekme çubuğu: yüzen cam hap --- */
.tabbar { left: max(10px, 2vw); right: max(10px, 2vw); bottom: calc(var(--safe-b) + 8px);
  border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 22px; padding: 6px;
  background: rgba(8, 12, 22, 0.72); box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55); }
.tab.active { background: linear-gradient(180deg, rgba(0, 229, 255, 0.18), rgba(0, 229, 255, 0.05)); box-shadow: inset 0 0 0 1px rgba(0, 229, 255, 0.25); }

/* --- responsive --- */
@media (max-width: 900px) { .menu-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .hero { min-height: 300px; align-items: flex-end; padding-bottom: 20px; }
  .hero-actions { flex-wrap: nowrap; gap: 8px; }
  .hero-actions .btn-lg { padding: 0 12px; font-size: 0.82rem; min-height: 46px; }
  .menu-tile { min-height: 98px; padding: 12px; }
  .menu-tile .ic { width: 38px; height: 38px; font-size: 1.25rem; border-radius: 12px; }
  .menu-tile .t { font-size: 0.82rem; letter-spacing: 0.04em; }
  .app > .appbar .btn { white-space: nowrap; }
  .hero-copy { max-width: 100%; width: 100%; }
  .hero-actions .btn { flex: 1; white-space: nowrap; justify-content: center; }
  .hero-stage { position: absolute; right: -4%; top: auto; top: 8px; bottom: auto; width: 46%; --sh: 190px; flex: none; opacity: 0.35; }
  .hero-ball { display: none; }
  .hero p { max-width: 30ch; }
  .hero-actions .btn-lg { padding-inline: 16px; }
}
@media (max-height: 460px) and (orientation: landscape) {
  .hero { min-height: 240px; }
  .menu-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-char, .hero-ball, .hero-halo, .hero-shadow, .btn-play, .btn-play::after { animation: none !important; }
}


/* ================================================================
   RHENXBALL // MOBILE PRODUCT UI v3
   Telefon ekranlarında menü bir "oyun sitesi" değil, doğrudan oyun
   uygulaması gibi görünür: daha az chrome, daha net hiyerarşi, daha
   büyük dokunma alanı ve sahne daha sakin.
   ================================================================ */
@media (max-width: 700px) {
  html, body { background:#05070d; }

  .app {
    --appbar-h: 54px;
    padding-bottom: calc(var(--safe-b) + 70px);
    background:
      radial-gradient(80vw 55vw at 92% 2%, rgba(0,229,255,.10), transparent 62%),
      radial-gradient(90vw 70vw at 0% 100%, rgba(124,77,255,.13), transparent 65%),
      linear-gradient(180deg,#070a12 0%,#05070d 65%,#04060b 100%);
  }

  .app > .home-stage { opacity:.14; filter:saturate(.82) brightness(.74); }
  .app.is-home .appbar {
    background: linear-gradient(180deg, rgba(5,7,13,.94), rgba(5,7,13,.58) 72%, transparent);
  }

  .appbar {
    min-height:54px;
    padding: calc(var(--safe-t) + 6px) 10px 6px;
    gap:7px;
  }
  .appbar-title {
    font-size:.84rem;
    line-height:1;
    letter-spacing:.13em;
    font-weight:900;
  }
  .appbar-sub {
    margin-top:3px;
    font-size:.53rem;
    line-height:1;
    letter-spacing:.12em;
    opacity:.78;
  }
  .appbar-spacer { min-width:4px; }
  #btnAuth {
    display:none;
  }
  .currency {
    min-width:0;
    height:31px;
    padding:4px 8px;
    gap:4px;
    font-size:.72rem;
    border-radius:11px;
    background:rgba(7,10,18,.72);
    box-shadow:inset 0 1px rgba(255,255,255,.05);
  }
  .currency .ic { font-size:.74rem; }

  #screens {
    padding-bottom:10px;
    scroll-padding-top:54px;
  }
  .wrap { padding-inline:10px; }

  .hero {
    min-height:238px;
    padding:20px 18px 16px;
    border-radius:22px;
    gap:0;
    align-items:flex-end;
    background:
      linear-gradient(105deg, rgba(5,8,16,.96) 0%, rgba(5,8,16,.78) 55%, rgba(5,8,16,.30) 100%),
      radial-gradient(80% 120% at 95% 10%, rgba(91,22,168,.26), transparent 65%);
    box-shadow:0 22px 55px rgba(0,0,0,.42), inset 0 1px rgba(255,255,255,.08);
  }
  .hero-copy {
    width:76%;
    max-width:none;
  }
  .hero-eyebrow {
    margin-bottom:8px;
    padding:4px 8px;
    gap:6px;
    font-size:.52rem;
    letter-spacing:.14em;
  }
  .live-dot { width:5px; height:5px; }
  .hero h1.hero-logo {
    margin-bottom:8px;
    font-size:clamp(2.45rem, 14vw, 3.55rem);
    letter-spacing:.01em;
    line-height:.9;
    text-shadow:0 3px 18px rgba(0,0,0,.42),0 0 24px rgba(0,229,255,.16);
  }
  .hero p {
    max-width:27ch;
    margin-bottom:13px;
    font-size:.72rem;
    line-height:1.4;
    color:rgba(233,239,250,.75);
  }
  .hero-actions { gap:7px; }
  .hero-actions .btn-lg {
    min-height:43px;
    padding:0 11px;
    border-radius:12px;
    font-size:.70rem;
    letter-spacing:.05em;
  }
  .hero-stage {
    right:-2%;
    top:2px;
    width:40%;
    --sh:164px;
    opacity:.24;
  }
  .hero-stage::after {
    content:'';
    position:absolute;
    inset:5% -20% 0;
    background:radial-gradient(circle, rgba(0,229,255,.18), transparent 65%);
    pointer-events:none;
  }

  .menu-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
    margin-top:10px;
  }
  .menu-tile {
    min-height:84px;
    padding:10px;
    border-radius:15px;
    gap:6px;
    justify-content:center;
    background:linear-gradient(160deg,rgba(255,255,255,.075),rgba(255,255,255,.018)),rgba(9,13,22,.72);
    box-shadow:0 8px 22px rgba(0,0,0,.26), inset 0 1px rgba(255,255,255,.045);
  }
  .menu-tile .ic {
    width:31px; height:31px;
    border-radius:9px;
    font-size:1rem;
    box-shadow:none;
  }
  .menu-tile .t {
    font-size:.67rem;
    line-height:1.1;
    letter-spacing:.045em;
  }
  .menu-tile .s {
    margin-top:1px;
    font-size:.56rem;
    line-height:1.2;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }
  .pill-live { top:8px; right:8px; padding:2px 6px; font-size:.46rem; }

  .tabbar {
    left:8px; right:8px; bottom:calc(var(--safe-b) + 7px);
    padding:4px;
    border-radius:18px;
    background:rgba(6,9,16,.90);
    border:1px solid rgba(255,255,255,.10);
    box-shadow:0 14px 34px rgba(0,0,0,.46), inset 0 1px rgba(255,255,255,.05);
  }
  .tab {
    min-height:56px;
    padding:4px 2px;
    gap:2px;
    border-radius:13px;
    font-size:.51rem;
    letter-spacing:.025em;
  }
  .tab .ic { font-size:1.12rem; line-height:1; }
  .tab.active .ic { transform:translateY(-1px) scale(1.06); }
}

@media (max-width: 380px) {
  .appbar { padding-inline:8px; }
  .currency { height:29px; padding-inline:7px; font-size:.68rem; }
  .hero { min-height:226px; padding-inline:14px; }
  .hero-copy { width:78%; }
  .hero h1.hero-logo { font-size:2.35rem; }
  .hero p { font-size:.67rem; max-width:25ch; }
  .menu-grid { gap:6px; }
  .menu-tile { min-height:80px; padding:8px; }
  .menu-tile .t { font-size:.62rem; }
  .menu-tile .s { display:none; }
  .tab { min-height:54px; font-size:.48rem; }
  .tab .ic { font-size:1.02rem; }
}

/* ======================================================================
   MOBİL YATAY: ana sayfa hero'su kısa ekrana sığsın (Hızlı Maç butonu
   kesilmesin), başlık ve boşluklar küçülür.
   ====================================================================== */
@media (max-height: 500px) and (orientation: landscape) {
  .hero { min-height: 0; padding: 12px 22px; }
  .hero h1.hero-logo { font-size: 2.6rem; margin-bottom: 4px; }
  .hero p { margin-bottom: 10px; font-size: 0.85rem; }
  .hero-stage { --sh: 150px; }
}