:root {
  --bg: #141921;
  --panel: #1f2531;
  --panel-alt: #232b38;
  --accent: #f2c46d;
  --accent-dark: #c28c2d;
  --text: #e6e7ea;
  --muted: #8d95a5;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Segoe UI', 'Roboto', sans-serif;
  background: #050505;
  color: var(--text);
  min-height: 100vh;
}
.auth-panel {
  padding: 40px 20px;
  background: rgba(8, 11, 16, 0.85);
  display: flex;
  justify-content: center;
}
.auth-panel.hidden {
  display: none;
}
.auth-card {
  background: rgba(12, 17, 26, 0.95);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  padding: 24px;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 25px 40px rgba(0,0,0,0.45);
}
.auth-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}
.auth-tabs button {
  flex: 1;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--text);
  padding: 10px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
}
.auth-tabs button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #0b111b;
}
.auth-forms form {
  display: none;
  flex-direction: column;
  gap: 12px;
}
.auth-forms form.active {
  display: flex;
}
.auth-forms input {
  background: #0a1019;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  padding: 12px;
  color: var(--text);
}
.auth-forms button {
  background: var(--accent);
  border: none;
  color: #0d141d;
  padding: 12px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
}
.auth-message {
  margin-top: 8px;
  min-height: 18px;
  font-size: 14px;
  color: #6ed68b;
}
main.locked {
  filter: blur(4px);
  pointer-events: none;
}
.hidden {
  display: none !important;
}
.lobby-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 30px;
  background: rgba(15, 20, 28, 0.85);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  position: sticky;
  top: 0;
}
.brand {
  display: flex;
  gap: 15px;
  align-items: center;
}
.brand h1 {
  margin: 0;
  font-size: 22px;
  color: var(--accent);
}
.brand p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.logo {
  width: 48px;
  height: 48px;
}
.account-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}
.ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.3);
  color: var(--text);
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
}
.ghost:hover { border-color: var(--accent); color: var(--accent); }
.ghost.danger { border-color: rgba(255,99,99,0.4); color: #ff7a7a; }
.ghost.danger:hover { border-color: #ff4d4d; color: #ff4d4d; }
main {
  width: min(1620px, calc(100% - 40px));
  margin: 20px auto 60px;
  padding: 0 5px;
  display: flex;
  flex-direction: column;
  gap: 30px;
}
.panel {
  background: var(--panel);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 30px 60px rgba(0,0,0,0.35);
}
.panel.alt { background: var(--panel-alt); }
.panel-head {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 15px;
}
.panel-head h2 {
  margin: 0;
  font-size: 20px;
  color: var(--accent);
}
.panel-head span {
  color: var(--muted);
  font-size: 14px;
}
.world-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.world-card {
  background: rgba(255,255,255,0.03);
  border-radius: 14px;
  padding: 18px;
  border: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.world-card h3 {
  margin: 0;
  font-size: 18px;
  color: var(--accent);
}
.world-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.world-card button {
  margin-top: auto;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border: none;
  color: #2e1c04;
  font-weight: 600;
  border-radius: 999px;
  padding: 10px 0;
  cursor: pointer;
  transition: opacity 0.2s ease;
}
.world-card button:hover { opacity: 0.8; }
.world-card .link-btn.small {
  align-self: flex-end;
  font-size: 12px;
  color: #e6c786;
}
.empty {
  text-align: center;
  padding: 20px;
  color: var(--muted);
}
.news {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.news li {
  background: rgba(0,0,0,0.2);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.05);
}
.news strong { color: var(--accent); }
.news small { color: var(--muted); }
footer {
  text-align: center;
  padding: 30px 0 50px;
  color: var(--muted);
  font-size: 13px;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.modal.hidden { display: none; }
.modal-box {
  background: #f8f1e1;
  color: #403020;
  border-radius: 12px;
  width: min(420px, 90%);
  padding: 26px 30px;
  position: relative;
  font-family: 'Trebuchet MS', sans-serif;
}
.modal-box h3 {
  margin: 0 0 16px;
  font-size: 20px;
}
.modal-box .close {
  position: absolute;
  right: 12px;
  top: 10px;
  background: #4a6123;
  border: none;
  color: #fff;
  font-size: 20px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
}
.world-box .close {
  position: absolute;
  right: 18px;
  top: 18px;
  background: #c08b2d;
  border: none;
  color: #2d1a04;
  font-size: 18px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
}
.profile-rows {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 20px;
}
.profile-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  padding-bottom: 12px;
}
.profile-row strong { display: block; margin-bottom: 4px; }
.profile-row .value { color: #5c4d33; }
.link-btn {
  background: none;
  border: none;
  color: #4a8c2f;
  cursor: pointer;
  font-weight: 600;
}
.link-btn.small { font-size: 12px; }
.link-btn:hover { text-decoration: underline; }
.link-btn.danger { color: #b31212; }
.profile-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(0,0,0,0.08);
  padding-top: 14px;
}
.profile-meta #profileCreated { color: #5c4d33; }

.world-box {
  background: #f8f1e1;
  color: #403020;
  border-radius: 12px;
  width: min(480px, 95%);
  padding: 28px 32px;
  position: relative;
  font-family: 'Trebuchet MS', sans-serif;
  box-shadow: 0 30px 60px rgba(0,0,0,0.6);
}
.world-box h3 {
  margin-top: 0;
  font-size: 22px;
  color: #4a3720;
}
.world-info p {
  margin: 6px 0;
}
.cookie {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(18,24,33,0.95);
  color: #f2f2f2;
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  z-index: 900;
}
.cookie.hidden { display: none; }
.cookie-actions {
  display: flex;
  gap: 10px;
}
.ghost.accept {
  border-color: #4CAF50;
  color: #4CAF50;
}
.ghost.accept:hover {
  border-color: #5fd35f;
  color: #5fd35f;
}

@media (max-width: 640px) {
  .lobby-header { flex-direction: column; gap: 12px; }
  .brand { flex-direction: column; text-align: center; }
  .account-actions { flex-direction: column; width: 100%; }
  .account-actions .ghost { width: 100%; text-align: center; }
  .cookie { flex-direction: column; text-align: center; }
.cookie-actions { width: 100%; justify-content: center; flex-wrap: wrap; }
}

/* === Travian Lobby Efektli Arka Plan & Parallax === */

/* Ana sahne */
body {
  margin: 0;
  position: relative;
  overflow: hidden;
  background: #050505;
  color: #e5d7b1;
  font-family: 'Cinzel', 'Trajan Pro', serif;
}

/* Arka plan resmi (Travian atmosferi) */

/* Parallax 3D eğim */
.parallax {
  transition: transform 0.2s ease-out;
}

/* Header */
header {
  background: rgba(15, 15, 15, 0.85);
  text-align: center;
  padding: 25px 0;
  color: #ffd87c;
  font-size: 26px;
  letter-spacing: 2px;
  text-shadow: 0 0 12px #d8a54b, 0 0 25px rgba(255, 190, 70, 0.4);
  border-bottom: 1px solid rgba(255, 210, 100, 0.3);
  position: sticky;
  top: 0;
  z-index: 10;
}

/* Butonlar */
button {
  cursor: pointer;
  border: none;
  background: linear-gradient(145deg, #b58330, #f6d477);
  color: #000;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: bold;
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.5);
}
button:hover {
  transform: translateY(-2px);
  background: linear-gradient(145deg, #f7d977, #c59e48);
  box-shadow: 0 4px 15px rgba(255, 215, 120, 0.6);
}

/* Dünya kartları */
.world-card {
  background: rgba(30, 25, 10, 0.8);
  border: 1px solid rgba(255, 215, 120, 0.3);
  border-radius: 10px;
  padding: 20px;
  width: 250px;
  margin: 15px;
  text-align: center;
  color: #f3e4b0;
  box-shadow: 0 3px 10px rgba(0,0,0,0.5);
  transition: transform 0.3s, box-shadow 0.3s;
  backdrop-filter: blur(4px);
}
.world-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 20px rgba(255, 200, 90, 0.25);
}
.world-card h3 {
  color: #ffe6a0;
  text-shadow: 0 0 10px rgba(255,220,120,0.4);
}

/* Haber listesi */
#newsList li {
  background: rgba(35, 30, 15, 0.8);
  margin: 8px 0;
  padding: 12px 16px;
  border-left: 4px solid #d8a54b;
  border-radius: 4px;
  list-style: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  transition: background 0.2s;
}
#newsList li:hover {
  background: rgba(45, 35, 15, 0.9);
}

/* Footer */
footer {
  text-align: center;
  padding: 12px;
  color: #d9c788;
  background: rgba(15,15,15,0.8);
  border-top: 1px solid rgba(255,220,120,0.2);
  box-shadow: 0 -2px 10px rgba(0,0,0,0.3);
  backdrop-filter: blur(5px);
}

/* Animasyonlar */
@keyframes moveSmoke {
  from { background-position: 0 0; }
  to { background-position: -2000px 0; }
}
@keyframes flamePulse {
  0%,100% { opacity: 0.12; transform: scale(1); }
  50% { opacity: 0.25; transform: scale(1.05); }
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-thumb { background: rgba(255,220,140,0.4); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,220,140,0.6); }

/* === Travian Alevli Splash Ekranı === */
#splashScreen {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at center, #0b0a08 0%, #000 90%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
  overflow: hidden;
  animation: fadeOut 2s ease-in 3s forwards;
}

.splash-content {
  position: relative;
  text-align: center;
}

#splashLogo {
  width: 280px;
  max-width: 80%;
  filter: drop-shadow(0 0 15px rgba(255,150,50,0.5));
  animation: fadeInLogo 2.5s ease-in-out, pulseGlow 2s ease-in-out infinite;
}

.fire-glow {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 200%;
  height: 100%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(255,160,50,0.25) 0%, transparent 80%);
  animation: flameFlow 4s linear infinite;
  mix-blend-mode: screen;
  z-index: -1;
}

@keyframes pulseGlow {
  0%,100% { filter: drop-shadow(0 0 10px rgba(255,180,90,0.4)); transform: scale(1);}
  50% { filter: drop-shadow(0 0 25px rgba(255,220,120,0.8)); transform: scale(1.03);}
}
@keyframes flameFlow {
  0% { opacity: 0.3; transform: translateX(-50%) scaleY(1);}
  50% { opacity: 0.6; transform: translateX(-50%) scaleY(1.1);}
  100% { opacity: 0.3; transform: translateX(-50%) scaleY(1);}
}
@keyframes fadeOut {
  to { opacity: 0; visibility: hidden; }
}

/* === Splash Yazıları === */
.splash-text {
  position: relative;
  margin-top: 20px;
  text-align: center;
  color: #ffd88a;
  font-family: 'Cinzel', serif;
  text-shadow: 0 0 8px rgba(255,200,120,0.4);
}

.loading-text {
  font-size: 20px;
  animation: flickerText 2s infinite;
}

.dots::after {
  content: '';
  animation: dots 1.5s steps(3, end) infinite;
}

.powered {
  margin-top: 6px;
  font-size: 14px;
  color: #c9b27a;
  opacity: 0.9;
}

.powered strong {
  color: #ffe39a;
  text-shadow: 0 0 8px rgba(255,210,100,0.5);
}

@keyframes dots {
  0% { content: ''; }
  33% { content: '.'; }
  66% { content: '..'; }
  100% { content: '...'; }
}

@keyframes flickerText {
  0%, 18%, 22%, 25%, 53%, 57%, 100% { opacity: 1; }
  20%, 24%, 55% { opacity: 0.4; }
}

@keyframes fadeInLogo {
  0% { opacity: 0; transform: scale(0.9); }
  100% { opacity: 1; transform: scale(1); }
}
/* 🔹 Üst logo ve başlığı ortala, büyüt, tam merkezde hizala */
.lobby-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 25px 0;
  text-align: center;
}

.lobby-header .brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* Logo boyutu büyütüldü */
.lobby-header .brand .logo {
  width: 90px;
  height: auto;
  filter: drop-shadow(0 0 8px rgba(255,215,0,0.4));
}

/* Başlık yazısı ortalanmış ve vurgulu */
.lobby-header h1 {
  font-family: 'Cinzel', serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: #ffcc66;
  text-shadow: 0 0 10px rgba(255,215,0,0.7), 0 0 25px rgba(255,200,0,0.5);
}

/* Alt açıklama yazısı */
.lobby-header p {
  font-size: 0.95rem;
  color: #d9c69c;
  margin-top: 3px;
}

/* Hesap butonlarını sağa al */
.account-actions {
  position: absolute;
  top: 30px;
  right: 40px;
  display: flex;
  gap: 8px;
}
/* === LOGO & BAŞLIK MERKEZ ORTALAMA === */
.lobby-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 0 20px 0;
  background: rgba(15, 15, 15, 0.75);
  border-bottom: 1px solid rgba(255, 220, 100, 0.2);
  box-shadow: 0 2px 10px rgba(0,0,0,0.4);
  text-align: center;
  position: relative;
  z-index: 10;
}

/* LOGO BOYUTU VE IŞIK PARLAMASI */
.lobby-header .brand .logo {
  width: 140px; /* 🔹 büyüklük */
  height: auto;
  margin-bottom: 10px;
  filter: drop-shadow(0 0 12px rgba(255, 210, 100, 0.6));
  animation: logoGlow 3.5s ease-in-out infinite;
}

@keyframes logoGlow {
  0%, 100% { filter: drop-shadow(0 0 10px rgba(255,210,100,0.6)); transform: scale(1); }
  50% { filter: drop-shadow(0 0 30px rgba(255,255,180,0.9)); transform: scale(1.05); }
}

/* BAŞLIK YAZISI (Travian tarzı) */
.lobby-header h1 {
  font-family: 'Cinzel', serif;
  font-size: 2rem;
  color: #ffe48b;
  letter-spacing: 1px;
  text-shadow: 0 0 12px rgba(255, 215, 120, 0.9), 0 0 28px rgba(255,200,0,0.5);
}

/* ALT YAZI */
.lobby-header p {
  font-size: 1rem;
  color: #d8c69a;
  text-shadow: 0 0 6px rgba(255,215,140,0.3);
}

/* SAĞ ÜST BUTONLAR */
.account-actions {
  position: absolute;
  top: 30px;
  right: 40px;
  display: flex;
  gap: 10px;
}
