/* ====== Racing Duel klón – sötét racing téma ====== */
*{box-sizing:border-box;margin:0;padding:0}
body{
  font-family:'Segoe UI',Tahoma,Arial,sans-serif;font-size:13px;color:#cfd6df;
  background:#05080d;
  background-image:
    radial-gradient(900px 500px at 0% 30%, rgba(170,20,30,.25), transparent 60%),
    radial-gradient(900px 500px at 100% 30%, rgba(20,80,170,.30), transparent 60%),
    linear-gradient(180deg,#0a1019,#05080d 60%);
  background-attachment:fixed;min-height:100vh;
}
a{color:#3aa0ff;text-decoration:none}
a:hover{color:#7cc4ff}
.wrap{max-width:940px;margin:0 auto;padding:8px 10px 40px}

/* ---- felső statisztikasáv ---- */
.topbar{display:flex;justify-content:flex-end;gap:14px;align-items:center;
  font-size:12px;color:#9fb0c2;padding:4px 10px}
.topbar .user{color:#fff;font-weight:600}

.logo{font-family:'Arial Black',Impact,sans-serif;font-style:italic;font-size:30px;
  line-height:1;letter-spacing:-1px}
.logo .r{color:#2f8fff} .logo .d{color:#aeb9c6}

.statbar{display:flex;align-items:stretch;gap:1px;background:#0d141d;
  border:1px solid #1c2734;border-radius:6px;overflow:hidden;margin:6px 0}
.statbar .cell{flex:1;padding:8px 12px;background:linear-gradient(180deg,#16202c,#0e151d);
  display:flex;flex-direction:column;gap:3px;justify-content:center}
.statbar .big{font-size:18px;font-weight:700;color:#eaf2fb}
.statbar .lbl{font-size:11px;color:#8194a6}
.statbar .money .big{color:#fff}
.statbar .sub{font-size:10px;color:#5fbf6b}
.bar{height:5px;background:#243140;border-radius:3px;overflow:hidden;margin-top:2px}
.bar > i{display:block;height:100%;background:linear-gradient(90deg,#2f8fff,#69b4ff)}

/* ---- főmenü ---- */
.mainnav{display:flex;background:linear-gradient(180deg,#101a26,#0a121b);
  border:1px solid #1c2734;border-radius:6px;overflow:hidden;margin-bottom:8px}
.mainnav a{flex:1;text-align:center;padding:12px 6px;color:#aebfd0;font-weight:700;
  letter-spacing:.5px;font-size:13px;border-right:1px solid #16212e;text-transform:uppercase}
.mainnav a:last-child{border-right:0}
.mainnav a:hover{background:#15212f;color:#fff}
.mainnav a.active{background:linear-gradient(180deg,#1d2c3d,#13202c);color:#fff;
  box-shadow:inset 0 -3px 0 #2f8fff}
.mainnav a.prem{color:#e8c14a}

/* ---- banner ---- */
.banner{height:90px;border:1px solid #1c2734;border-radius:6px;margin-bottom:8px;
  background:linear-gradient(90deg,#0c1622,#1a2738 60%,#0c1622);
  display:flex;align-items:center;padding:0 28px}
.banner h1{font-size:26px;color:#fff;font-weight:300;letter-spacing:3px}

/* ---- aloldali fülek ---- */
.subtabs{display:flex;gap:2px;margin-bottom:6px}
.subtabs a{padding:8px 16px;background:#0e151d;border:1px solid #1c2734;border-bottom:0;
  border-radius:5px 5px 0 0;color:#9fb0c2;font-size:12px}
.subtabs a.active{background:#1a2734;color:#fff}

/* ---- panelek ---- */
.panel{background:rgba(10,16,23,.92);border:1px solid #1c2734;border-radius:6px;
  padding:14px;margin-bottom:10px}
.panel h2{font-size:13px;color:#cfe0f2;text-transform:uppercase;letter-spacing:1px;
  border-bottom:1px solid #1c2734;padding-bottom:8px;margin-bottom:10px;font-weight:600}
.cols{display:flex;gap:10px;flex-wrap:wrap}
.cols > .panel{flex:1;min-width:280px}

/* ---- listaelemek (autó/felszerelés/szponzor) ---- */
.row{display:flex;align-items:center;gap:12px;background:linear-gradient(180deg,#121b25,#0c131b);
  border:1px solid #1b2633;border-radius:5px;padding:10px;margin-bottom:8px}
.row .thumb{width:84px;height:54px;background:#1a2530;border:1px solid #26323f;border-radius:4px;
  flex:0 0 auto;display:flex;align-items:center;justify-content:center;color:#46566a;font-size:10px;overflow:hidden}
.row .thumb img{max-width:100%;max-height:100%}
.row .name{color:#7cc4ff;font-weight:600;font-size:13px}
.row .stats{font-size:12px;color:#9fb0c2;margin-top:4px;display:flex;gap:14px;flex-wrap:wrap}
.row .stats b{color:#cfe0f2}
.row .price{color:#7cc4ff;font-weight:700}
.row .spacer{flex:1}
.locked{opacity:.5}

/* ---- gombok ---- */
.btn{display:inline-block;background:linear-gradient(180deg,#3a93ff,#1f6fd6);color:#fff;
  border:1px solid #1a5cb0;border-radius:4px;padding:7px 14px;font-size:12px;font-weight:600;
  cursor:pointer}
.btn:hover{filter:brightness(1.1)}
.btn.gray{background:linear-gradient(180deg,#3a4654,#262f3a);border-color:#1c2734;color:#cfd6df}
.btn.red{background:linear-gradient(180deg,#e0533a,#b23824);border-color:#8a2a1a}
.btn.sm{padding:4px 9px;font-size:11px}

/* ---- táblázat (ranglista) ---- */
table.tbl{width:100%;border-collapse:collapse;font-size:12px}
table.tbl th{background:#13202c;color:#9fb0c2;text-align:left;padding:8px;font-weight:600;
  text-transform:uppercase;font-size:11px}
table.tbl td{padding:8px;border-top:1px solid #16212e}
table.tbl tr:hover td{background:#101b26}
table.tbl tr.me td{background:#15273a;color:#fff}

/* ---- statisztika-sávok (tuning) ---- */
.attr{display:flex;align-items:center;gap:10px;margin-bottom:10px}
.attr .ic{width:34px;height:34px;border-radius:50%;background:#15222f;border:1px solid #26323f;
  display:flex;align-items:center;justify-content:center;color:#3aa0ff;font-size:16px}
.attr .nm{flex:1}.attr .val{font-weight:700;color:#cfe0f2}

/* ---- form ---- */
input[type=text],input[type=password],input[type=email],input[type=number],select,textarea{
  background:#0c1219;border:1px solid #243140;border-radius:4px;color:#e6edf5;padding:8px;
  font-size:13px;width:100%}
label{display:block;font-size:12px;color:#9fb0c2;margin:8px 0 4px}
.field-yellow input{background:#fff7d6;color:#222}

/* ---- footer ---- */
.foot{margin-top:20px;padding:14px;font-size:11px;color:#6c7d8f;text-align:center;
  border-top:1px solid #16212e}
.foot a{color:#8aa0b6}

/* ---- belépő kártya ---- */
.auth{max-width:380px;margin:60px auto;background:rgba(10,16,23,.95);
  border:1px solid #1c2734;border-radius:8px;padding:26px}
.auth h1{text-align:center;margin-bottom:18px}
.flash{background:#15273a;border:1px solid #2f6fb0;color:#cfe6ff;padding:10px 12px;
  border-radius:5px;margin-bottom:12px;font-size:12px}

/* ---- admin ---- */
.admin-grid{display:flex;gap:12px;align-items:flex-start}
.admin-side{width:200px;flex:0 0 auto;background:rgba(10,16,23,.95);border:1px solid #1c2734;
  border-radius:6px;padding:8px}
.admin-side a{display:block;padding:9px 10px;border-radius:4px;color:#aebfd0;font-size:13px}
.admin-side a:hover{background:#15212f}
.admin-side a.active{background:#1d2c3d;color:#fff}
.admin-main{flex:1;min-width:0}
.tag{display:inline-block;background:#1d2c3d;color:#7cc4ff;border-radius:3px;padding:2px 7px;font-size:11px}
.muted{color:#6c7d8f}
.completed{color:#e0533a;font-weight:700;transform:rotate(-6deg);display:inline-block}

/* ================================================================
   AJAX / ANIMATION LAYER
   ================================================================ */

/* val-flash: rövid kiemelés szám-frissítéskor */
.val-flash { animation: valFlash .4s ease; }
@keyframes valFlash {
  0%  { color: inherit; }
  40% { color: #7cc4ff; text-shadow: 0 0 8px rgba(47,143,255,.55); }
  100%{ color: inherit; }
}

/* ---- race banner mozgó pályajelzők ---- */
.race-banner { position: relative; overflow: hidden; }
.race-banner::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(90deg,
    transparent 0, transparent 28px,
    rgba(47,143,255,.07) 28px, rgba(47,143,255,.07) 29px);
  animation: spdlines 1.8s linear infinite;
}
@keyframes spdlines { to { background-position: 58px 0; } }

/* ---- race control panel ---- */
.race-status-row {
  display: flex; align-items: center; gap: 26px; flex-wrap: wrap;
}
.race-stat-item { flex: 1; min-width: 130px; }
.stat-big { font-size: 21px; font-weight: 700; color: #eaf2fb; line-height: 1.2; }

.regen-bar {
  height: 4px; background: #13202e; border-radius: 3px;
  margin: 5px 0 3px; overflow: hidden;
}
.regen-bar i {
  display: block; height: 100%;
  background: linear-gradient(90deg, #2f8fff, #8ecfff);
  border-radius: 3px;
  transition: width .65s ease;
  box-shadow: 0 0 6px rgba(47,143,255,.45);
}

.timer-row { display: flex; align-items: center; gap: 5px; font-size: 11px; }
.timer-icon { font-size: 12px; }
.timer-val { color: #7cc4ff; font-weight: 600; font-variant-numeric: tabular-nums; min-width: 38px; }
.timer-ready { color: #5fbf6b; }

.race-launch { flex: 0 0 auto; display: flex; flex-direction: column; gap: 8px; align-items: stretch; }
.opp-input { width: 220px !important; }
.race-btn {
  font-size: 13px; padding: 10px 22px; letter-spacing: .7px;
  transition: transform .15s, box-shadow .2s, filter .15s;
}
.race-btn:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(47,143,255,.5);
  filter: brightness(1.12);
}
.race-btn:not(:disabled):active { transform: scale(.97); }
.race-btn:disabled, .btn-disabled { opacity: .42; cursor: not-allowed; }
.fuel-cost { opacity: .7; font-size: 11px; }

/* ---- flash message ---- */
.race-flash {
  padding: 10px 16px; border-radius: 6px; margin-bottom: 8px;
  font-size: 13px; font-weight: 600;
  animation: flashIn .3s ease;
}
.race-flash.hidden { display: none; }
.flash-win   { background: rgba(95,191,107,.12); border: 1px solid rgba(95,191,107,.6); color: #a8e8b0; }
.flash-loss  { background: rgba(200,150,40,.10); border: 1px solid rgba(200,150,40,.5); color: #dfc870; }
.flash-error { background: rgba(224,83,58,.12);  border: 1px solid rgba(224,83,58,.6);  color: #f0a090; }
@keyframes flashIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: none; }
}

/* ---- race overlay ---- */
.race-overlay {
  position: fixed; inset: 0; z-index: 999;
  background: rgba(2,6,14,.88);
  backdrop-filter: blur(5px) saturate(.7);
  display: flex; align-items: center; justify-content: center;
}
.race-overlay.hidden { display: none; }
.race-overlay.overlay-out .race-modal {
  animation: modalOut .38s ease forwards;
}
@keyframes modalOut { to { transform: scale(.87) translateY(22px); opacity: 0; } }

.race-modal {
  background: linear-gradient(150deg, #060e1a 0%, #0b1828 100%);
  border: 1px solid rgba(47,143,255,.45);
  border-radius: 14px;
  width: min(580px, 95vw);
  padding: 22px 20px 18px;
  position: relative;
  box-shadow: 0 0 50px rgba(47,143,255,.18), inset 0 1px 0 rgba(255,255,255,.04);
  animation: modalIn .32s cubic-bezier(.2,0,.8,1);
}
@keyframes modalIn {
  from { transform: scale(.84) translateY(32px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

/* race track */
.race-track {
  height: 112px;
  background: linear-gradient(180deg, #060f1c 0%, #0a1829 100%);
  border: 1px solid #16212e;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
  margin-bottom: 18px;
}
/* moving road dashes */
.race-track::before {
  content: '';
  position: absolute; top: 49%; left: 0; right: 0; height: 2px;
  background: repeating-linear-gradient(90deg,
    #273a4e 0,#273a4e 18px, transparent 18px, transparent 28px);
  transform: translateY(-50%);
}
/* speed-line overlay */
.race-track::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(90deg,
    transparent 0, transparent 54px,
    rgba(47,143,255,.035) 54px, rgba(47,143,255,.035) 55px);
  animation: spdlines 1.2s linear infinite;
}
.track-center-line {
  position: absolute; top: 50%; left: 0; right: 0; height: 1px;
  background: rgba(255,255,255,.04);
  transform: translateY(-50%);
}
.race-car {
  position: absolute;
  font-size: 28px; line-height: 1;
  transition: none;
  filter: drop-shadow(0 0 8px rgba(47,143,255,.55));
  z-index: 2;
}
.player-car { top: 24%; transform: translateY(-50%); }
.opp-car    { top: 74%; transform: translateY(-50%); }
.finish-flag {
  position: absolute; right: 9%; top: 50%;
  transform: translateY(-50%);
  font-size: 24px; opacity: .45;
  animation: flagWave 1s ease-in-out infinite alternate;
}
@keyframes flagWave { to { transform: translateY(-50%) rotate(8deg); } }

/* countdown */
.race-countdown {
  font-size: 70px; font-weight: 900; text-align: center;
  color: #2f8fff; letter-spacing: -2px;
  font-family: 'Arial Black', Impact, sans-serif;
  text-shadow: 0 0 28px rgba(47,143,255,.65);
  line-height: 1;
}
.race-countdown.hidden { display: none; }
.race-countdown.go-text {
  color: #5fbf6b;
  text-shadow: 0 0 28px rgba(95,191,107,.65);
}
.race-countdown.cnt-bounce { animation: cntBounce .32s cubic-bezier(.2,0,.8,1); }
@keyframes cntBounce {
  0%   { transform: scale(1.45); opacity: .55; }
  100% { transform: scale(1);    opacity: 1;   }
}

/* result */
.race-result { text-align: center; padding: 10px 0; }
.race-result.hidden { display: none; }
.race-result { animation: resultIn .38s cubic-bezier(.2,0,.8,1); }
@keyframes resultIn {
  from { transform: scale(.65) translateY(12px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
.res-icon   { font-size: 50px; line-height: 1.1; }
.res-title  { font-size: 36px; font-weight: 900; letter-spacing: 2px; margin: 4px 0 2px; }
.res-sub    { font-size: 13px; color: #9fb0c2; margin-bottom: 8px; }
.res-reward { font-size: 18px; font-weight: 700; }
.win-result .res-title  { color: #5fbf6b; text-shadow: 0 0 16px rgba(95,191,107,.6); }
.loss-result .res-title { color: #e0533a; }
.xp-badge {
  background: rgba(47,143,255,.16); color: #7cc4ff;
  border: 1px solid rgba(47,143,255,.35);
  border-radius: 4px; padding: 2px 8px; font-size: 13px; margin-left: 6px;
  vertical-align: middle;
}

.race-close-hint {
  text-align: center; font-size: 11px; color: #3a5268;
  margin-top: 10px;
  animation: hintFade .6s .5s both;
}
.race-close-hint.hidden { display: none; }
@keyframes hintFade { from{opacity:0} to{opacity:1} }

/* particles (win konfetti) */
.particle {
  position: absolute; width: 7px; height: 7px; border-radius: 50%;
  pointer-events: none;
  animation: particleFly 1.35s ease-out forwards;
}
@keyframes particleFly {
  0%   { transform: translate(0,0) scale(1); opacity: 1; }
  100% { transform: translate(var(--dx,40px),var(--dy,-80px)) scale(0); opacity: 0; }
}

/* table rows fade-in (staggered) */
.row-in { animation: rowIn .32s ease both; }
@keyframes rowIn {
  from { opacity: 0; transform: translateX(-8px); }
  to   { opacity: 1; transform: none; }
}
.row-in:nth-child(2)  { animation-delay: .03s; }
.row-in:nth-child(3)  { animation-delay: .06s; }
.row-in:nth-child(4)  { animation-delay: .09s; }
.row-in:nth-child(5)  { animation-delay: .12s; }
.row-in:nth-child(6)  { animation-delay: .15s; }
.row-in:nth-child(7)  { animation-delay: .18s; }
.row-in:nth-child(8)  { animation-delay: .21s; }
.row-in:nth-child(9)  { animation-delay: .24s; }
.row-in:nth-child(10) { animation-delay: .27s; }
.row-in:nth-child(11) { animation-delay: .30s; }
.row-in:nth-child(12) { animation-delay: .33s; }

/* tab content toggle */
.tab-content.hidden { display: none; }

/* loading placeholder */
.loading-cell {
  text-align: center; padding: 16px;
  color: #3a5268; font-style: italic; font-size: 12px;
}

/* ================================================================
   TASKS PAGE
   ================================================================ */

/* Banner speedline */
.task-banner { position: relative; overflow: hidden; }
.task-banner::after {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(90deg,
    transparent 0, transparent 28px,
    rgba(95,191,107,.06) 28px, rgba(95,191,107,.06) 29px);
  animation: spdlines 2s linear infinite;
}

/* Carousel */
.task-carousel {
  position: relative; height: 120px; margin-bottom: 10px;
  border-radius: 8px; overflow: hidden; border: 1px solid #1c2734;
}
.carousel-track { position: relative; width: 100%; height: 100%; }
.carousel-slide {
  position: absolute; inset: 0;
  display: none; align-items: center; justify-content: center;
  flex-direction: column; gap: 8px;
}
.carousel-slide.active { display: flex; animation: slideIn .4s ease; }
@keyframes slideIn { from{opacity:0;transform:scale(1.04)} to{opacity:1;transform:none} }
.carousel-icon { font-size: 36px; }
.carousel-label { font-size: 16px; font-weight: 700; color: #fff; letter-spacing: 2px; text-transform: uppercase; }
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 10;
  background: rgba(0,0,0,.5); border: 1px solid #1c2734; color: #fff;
  width: 32px; height: 44px; border-radius: 4px; cursor: pointer;
  font-size: 22px; line-height: 1; display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.carousel-btn:hover { background: rgba(47,143,255,.3); }
.carousel-prev { left: 8px; }
.carousel-next { right: 8px; }
.carousel-dots {
  position: absolute; bottom: 8px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 6px;
}
.cdot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,.25); cursor: pointer; transition: background .2s;
}
.cdot.active { background: #2f8fff; }

/* Task cards */
.task-card {
  background: rgba(10,16,23,.92); border: 1px solid #1c2734;
  border-radius: 8px; margin-bottom: 8px; overflow: hidden; transition: border-color .2s;
}
.task-card:hover { border-color: #2f4f6e; }
.task-card.task-done   { border-color: rgba(95,191,107,.3); }
.task-card.task-locked { opacity: .7; }
.task-card-header {
  display: flex; align-items: center; gap: 10px;
  background: linear-gradient(180deg,#111d28,#0c1620);
  padding: 8px 14px; border-bottom: 1px solid #16212e;
}
.task-num {
  background: #1a2f42; color: #9fb0c2; border-radius: 4px;
  padding: 2px 8px; font-size: 12px; font-weight: 700; flex-shrink: 0;
}
.task-title { flex: 1; font-weight: 600; color: #cfe0f2; font-size: 13px; }
.task-prog-wrap { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.task-prog-bar { width: 120px; height: 6px; background: #162030; border-radius: 3px; overflow: hidden; }
.task-prog-bar i {
  display: block; height: 100%;
  background: linear-gradient(90deg,#2f8fff,#7cc4ff);
  border-radius: 3px; transition: width .5s ease;
}
.task-done .task-prog-bar i { background: linear-gradient(90deg,#5fbf6b,#90ef8f); }
.task-prog-pct { font-size: 11px; color: #9fb0c2; width: 36px; text-align: right; }
.task-card-body {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; flex-wrap: wrap;
}
.task-thumb {
  width: 80px; height: 55px; flex-shrink: 0;
  background: #0e1a25; border: 1px solid #1c2734; border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; overflow: hidden;
}
.task-thumb img { max-width: 100%; max-height: 100%; object-fit: cover; }
.task-lock-icon { font-size: 28px; }
.task-img-placeholder { font-size: 26px; }
.task-details { flex: 1; min-width: 200px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.task-req { display: flex; flex-direction: column; gap: 3px; }
.task-req .lbl { font-size: 10px; color: #6c7d8f; text-transform: uppercase; }
.fuel-need { color: #7cc4ff; font-size: 14px; }
.fuel-need b { font-size: 18px; }
.task-arrow { font-size: 20px; color: #3a5268; }
.task-reward { display: flex; flex-direction: column; gap: 3px; }
.reward-cash { color: #5fbf6b; font-weight: 700; font-size: 13px; }
.reward-xp   { color: #e8c14a; font-size: 12px; }
.task-actions { flex-shrink: 0; text-align: right; }
.task-btn-group { display: flex; align-items: center; gap: 6px; justify-content: flex-end; }
.task-btn-label { font-size: 11px; color: #6c7d8f; margin-right: 4px; }
.task-do-btn {
  padding: 6px 14px; font-size: 13px; font-weight: 700;
  transition: transform .12s, box-shadow .15s;
}
.task-do-btn:hover { transform: translateY(-1px); box-shadow: 0 3px 12px rgba(47,143,255,.4); }
.task-fuel-costs {
  display: flex; gap: 18px; justify-content: flex-end;
  margin-top: 4px; font-size: 11px; color: #e0533a; padding-right: 2px;
}
.completed-stamp {
  color: #e0533a; font-size: 16px; font-weight: 900; display: inline-block;
  transform: rotate(-4deg) scale(1.05); border: 2px solid #e0533a;
  padding: 4px 10px; border-radius: 4px; letter-spacing: 2px; opacity: .85;
}
.lock-badge { color: #6c7d8f; font-size: 12px; }

/* Teammates */
.teammate-panel h2 { margin-bottom: 14px; }
.teammate-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.teammate-card {
  background: linear-gradient(180deg,#111d28,#0c1620);
  border: 1px solid #1c2734; border-radius: 8px;
  padding: 14px; text-align: center; width: 140px; transition: border-color .2s;
}
.teammate-card:hover { border-color: #2f6090; }
.tm-avatar { font-size: 36px; margin-bottom: 6px; }
.tm-name { font-weight: 700; color: #cfe0f2; font-size: 13px; margin-bottom: 6px; }
.tm-stats { font-size: 11px; color: #9fb0c2; display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; }

/* ================================================================
   STATBAR TIMER
   ================================================================ */
.statbar-timer { font-size: 10px; color: #4a6a80; margin-top: 1px; }

/* ================================================================
   LIGA / RANGLISTA SORT
   ================================================================ */
.rank-sort-btn.active { background: #2f8fff; color: #fff; border-color: #2f8fff; }

/* ================================================================
   DÍJAK – PRIZE CARDS
   ================================================================ */
.prize-card {
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(180deg,#0e1a26,#0a1320);
  border: 1px solid #1c2734; border-radius: 8px;
  padding: 14px; margin-bottom: 8px; transition: border-color .2s;
}
.prize-card:hover { border-color: #2f4f6e; }
.prize-card.prize-ready  { border-color: rgba(95,191,107,.4); }
.prize-card.prize-claimed{ border-color: rgba(47,143,255,.2); opacity: .6; }
.prize-icon { font-size: 36px; flex-shrink: 0; width: 48px; text-align: center; }
.prize-info { flex: 1; }
.prize-name { font-weight: 700; color: #cfe0f2; font-size: 14px; }
.prize-desc { font-size: 12px; margin-top: 2px; }
.prize-prog { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.prize-prog-bar { flex: 1; height: 4px; background: #162030; border-radius: 2px; overflow: hidden; }
.prize-prog-bar i { display: block; height: 100%; background: linear-gradient(90deg,#2f8fff,#7cc4ff); border-radius: 2px; transition: width .5s; }
.prize-prog span { font-size: 10px; color: #6c7d8f; white-space: nowrap; }
.prize-right { flex-shrink: 0; text-align: right; min-width: 100px; }
.prize-reward { font-weight: 700; color: #5fbf6b; margin-bottom: 6px; font-size: 14px; }
.prize-claimed-badge { font-size: 11px; color: #5fbf6b; }

/* ================================================================
   PREMIUM PAGE
   ================================================================ */
.premium-banner { position: relative; overflow: hidden; }
.premium-banner::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(90deg,
    transparent 0, transparent 28px,
    rgba(232,193,74,.05) 28px, rgba(232,193,74,.05) 29px);
  animation: spdlines 2.5s linear infinite;
}
.premium-hero {
  display: flex; align-items: center; gap: 18px;
  background: linear-gradient(135deg,#0d1e35,#1a2d45) !important;
  border-color: rgba(47,143,255,.3) !important;
}
.prem-hero-icon { font-size: 48px; flex-shrink: 0; }
.prem-benefit-card { text-align: center; }
.prem-benefit-card h3 { color: #cfe0f2; margin: 8px 0; }
.pb-icon { font-size: 36px; }
.prem-list { list-style: none; text-align: left; margin-top: 8px; }
.prem-list li { padding: 4px 0; font-size: 12px; color: #9fb0c2; }
.prem-list li::before { content: '✓ '; color: #2f8fff; }

/* Licenses */
.license-card {
  border: 1px solid; border-radius: 10px; padding: 18px; margin-bottom: 10px;
  transition: box-shadow .2s;
}
.license-card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.4); }
.license-card.license-owned { box-shadow: inset 0 0 0 2px rgba(95,191,107,.3); }
.lic-top { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.lic-icon { font-size: 36px; flex-shrink: 0; }
.lic-info { flex: 1; min-width: 160px; }
.lic-name { font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.lic-desc { font-size: 12px; }
.lic-expires { font-size: 11px; margin-top: 4px; }
.lic-price-block { flex-shrink: 0; text-align: right; }
.lic-price { font-size: 24px; font-weight: 900; margin-bottom: 8px; }
.lic-benefits {
  display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px;
  padding-top: 12px; border-top: 1px solid rgba(255,255,255,.06);
}
.lic-benefit-item {
  background: rgba(0,0,0,.3); border: 1px solid rgba(255,255,255,.07);
  border-radius: 4px; padding: 4px 10px; font-size: 11px; color: #a0b8cc;
}

/* Accessories */
.acc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px; margin-bottom: 10px;
}
.acc-card {
  background: linear-gradient(180deg,#0e1a26,#0a1320);
  border: 1px solid #1c2734; border-radius: 8px;
  padding: 14px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color .2s, transform .15s;
}
.acc-card:hover { border-color: #2f5080; transform: translateY(-2px); }
.acc-card.acc-owned { border-color: rgba(95,191,107,.35); }
.acc-img {
  height: 80px; background: #0c1520; border: 1px solid #1c2734;
  border-radius: 5px; display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.acc-img img { max-height: 100%; max-width: 100%; }
.acc-icon { font-size: 32px; }
.acc-owned-badge {
  position: absolute; top: 4px; right: 4px;
  background: rgba(95,191,107,.9); color: #000; border-radius: 3px;
  padding: 1px 5px; font-size: 10px; font-weight: 700;
}
.acc-name { font-weight: 700; color: #cfe0f2; font-size: 13px; }
.acc-desc { font-size: 11px; color: #6c7d8f; }
.acc-benefits { flex: 1; }
.acc-benefit { font-size: 11px; color: #9fb0c2; padding: 2px 0; }
.acc-benefit::before { content: '+ '; color: #5fbf6b; }
.acc-footer { display: flex; align-items: center; justify-content: space-between; }
.acc-price { font-weight: 700; color: #e8c14a; font-size: 14px; }

/* Credit packages */
.credit-packages { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 10px; }
.credit-pkg {
  background: linear-gradient(180deg,#111d28,#0c1620);
  border: 1px solid #1c2734; border-radius: 8px;
  padding: 20px 24px; text-align: center; min-width: 130px; position: relative;
}
.credit-pkg-best { border-color: #e8c14a; box-shadow: 0 0 20px rgba(232,193,74,.15); }
.cp-badge {
  position: absolute; top: -10px; left: 50%; transform: translateX(-50%);
  background: #e8c14a; color: #0a0a0a; font-size: 10px; font-weight: 900;
  padding: 2px 10px; border-radius: 10px; letter-spacing: 1px;
}
.cp-amount { font-size: 24px; font-weight: 700; color: #7cc4ff; margin-bottom: 4px; }
.cp-price  { font-size: 12px; margin-bottom: 12px; }


/* ── Equipment profile grid (home profil tab) ── */
.equip-profile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px,1fr));
  gap: 10px; margin-top: 8px;
}
.equip-profile-card {
  background: #0c1520; border: 1px solid #1c2734; border-radius: 7px;
  padding: 10px; text-align: center; transition: border-color .2s;
}
.equip-profile-card:hover { border-color: #2f5080; }
.equip-profile-img {
  height: 64px; display: flex; align-items: center; justify-content: center;
  position: relative; margin-bottom: 6px;
}
.equip-profile-img img { max-height: 100%; max-width: 100%; }
.equip-profile-img span { font-size: 28px; }
.equip-qty {
  position: absolute; top: 0; right: 0;
  background: rgba(44,120,200,.85); color: #fff;
  font-size: 10px; font-weight: 700; padding: 1px 5px; border-radius: 3px;
}
.equip-profile-name { font-size: 11px; font-weight: 700; color: #cfe0f2; }
.equip-profile-sub  { font-size: 10px; color: #6c7d8f; margin-top: 2px; }

/* ── Category filter ── */
.task-cat-filter {
  display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 0 4px;
}
.cat-btn {
  background: #0e1a26; border: 1px solid #1c2734; color: #8ba0b4;
  border-radius: 20px; padding: 4px 14px; font-size: 12px; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.cat-btn:hover { background: #142030; border-color: #2f5080; color: #cfe0f2; }
.cat-btn.active { background: #1a3550; border-color: #2f8fff; color: #7cc4ff; font-weight: 700; }

/* ── Task rounds badge ── */
.task-rounds {
  background: rgba(44,120,200,.2); border: 1px solid rgba(47,143,255,.3);
  color: #7cc4ff; font-size: 11px; padding: 1px 8px; border-radius: 10px;
  margin-left: 4px;
}

/* ── Határok panel (properties) ── */
.hatarak-panel { }
.hatarok-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px,1fr));
  gap: 12px; margin-top: 4px;
}
.hatarok-card {
  background: linear-gradient(160deg,#0e1a26,#0a1320);
  border: 1px solid #1c2734; border-radius: 8px;
  padding: 18px 16px; text-align: center;
  transition: border-color .2s, transform .15s;
}
.hatarok-card:hover { border-color: #2f5080; transform: translateY(-2px); }
.hatarok-icon  { font-size: 32px; margin-bottom: 6px; }
.hatarok-name  { font-weight: 700; color: #cfe0f2; font-size: 14px; margin-bottom: 4px; }
.hatarok-val   { font-size: 16px; font-weight: 700; color: #7cc4ff; margin-bottom: 4px; }
.hatarok-bonus { font-size: 12px; color: #5fbf6b; margin-bottom: 2px; }
.hatarok-cost  { font-size: 12px; color: #9fb0c2; }

/* ── Határpont packages (premium) ── */
.hp-packages {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(180px,1fr));
  gap: 12px; margin-top: 8px;
}
.hp-pkg {
  background: linear-gradient(160deg,#13201a,#0c1a10);
  border: 1px solid rgba(232,193,74,.2); border-radius: 8px;
  padding: 18px 14px; text-align: center;
  transition: border-color .2s, transform .15s;
}
.hp-pkg:hover { border-color: rgba(232,193,74,.5); transform: translateY(-2px); }
.hp-amount { font-size: 22px; font-weight: 700; color: #e8c14a; margin-bottom: 4px; }
.hp-name   { font-weight: 700; color: #cfe0f2; font-size: 13px; margin-bottom: 4px; }
.hp-desc   { font-size: 11px; color: #6c7d8f; margin-bottom: 8px; }
.hp-price  { font-size: 13px; color: #7cc4ff; font-weight: 700; margin-bottom: 10px; }

/* ── Prémium bónusz jelző (topbar) ── */
.prem-indicator {
  cursor: pointer; color: #e8c14a; font-weight: 700;
  padding: 2px 8px; border: 1px solid rgba(232,193,74,.3);
  border-radius: 12px; font-size: 11px; position: relative;
  transition: background .15s;
}
.prem-indicator:hover { background: rgba(232,193,74,.1); }
.prem-popup {
  position: absolute; top: 30px; right: 0; z-index: 200;
  background: #0e1822; border: 1px solid #e8c14a;
  border-radius: 8px; min-width: 240px; padding: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.6);
}
.prem-popup-title { font-weight: 700; color: #e8c14a; margin-bottom: 6px; font-size: 12px; }
.prem-popup-item  { padding: 4px 0; font-size: 12px; border-bottom: 1px solid #1c2d3e; }
.prem-popup-item:last-child { border-bottom: 0; }

/* Nav badge (üzenet olvasatlan) */
.nav-badge {
  display: inline-block; background: #e0533a; color: #fff;
  border-radius: 9px; font-size: 10px; font-weight: 700;
  padding: 0 5px; min-width: 16px; text-align: center;
  vertical-align: middle; margin-left: 3px;
}

/* ── Csapat info grid ── */
.team-info-grid {
  display: grid; grid-template-columns: repeat(auto-fill,minmax(150px,1fr));
  gap: 8px; margin: 10px 0;
}
.team-info-item {
  background: #0d1822; border-radius: 6px; padding: 8px 12px;
  display: flex; flex-direction: column; gap: 2px;
}
.team-info-item span { font-size: 11px; }
.team-info-item b    { font-size: 15px; }

/* ── Csapat kezelőpanel ── */
.team-owner-section { margin-top: 16px; }
.team-owner-section h3 { color: #7cc4ff; margin-bottom: 10px; }
.team-manage-block {
  background: #0d1420; border: 1px solid #1c2734;
  border-radius: 6px; padding: 10px 14px; margin-bottom: 8px;
}
.team-manage-block summary {
  cursor: pointer; font-weight: 700; color: #aebfd0;
  list-style: none; user-select: none;
}
.team-manage-block summary:hover { color: #fff; }
.team-manage-block[open] > summary { color: #7cc4ff; margin-bottom: 6px; }
.app-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6px 0; border-bottom: 1px solid #1a2530; flex-wrap: wrap; gap: 6px;
}

/* ── Belépési kérelem modal ── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.7);
  z-index: 300; display: flex; align-items: center; justify-content: center;
}
.modal-box {
  background: #0e1822; border: 1px solid #2a3d52;
  border-radius: 10px; padding: 24px; max-width: 440px; width: 92%;
}
.modal-box h3 { margin-bottom: 14px; color: #7cc4ff; }

/* ── Verseny Komplexum ── */
.complex-grid {
  display: grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr));
  gap: 12px; margin-top: 4px;
}
.complex-card {
  background: linear-gradient(160deg,#10192a,#0b1422);
  border: 1px solid #1c2d3e; border-radius: 10px; padding: 14px;
  transition: border-color .2s;
}
.complex-card:hover { border-color: #2f5080; }
.complex-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 6px; }
.complex-name   { font-weight: 700; color: #cfe0f2; font-size: 14px; }
.complex-level  { font-size: 11px; color: #8194a6; background: #13202e; padding: 2px 8px; border-radius: 10px; }
.complex-level.owned { color: #5fbf6b; background: #13201a; }
.complex-next   { display: flex; flex-direction: column; gap: 3px; margin: 8px 0; font-size: 12px; }
.complex-progress-wrap {
  height: 6px; background: #1c2d3e; border-radius: 3px; overflow: hidden; margin-bottom: 4px;
}
.complex-progress-bar {
  height: 100%; background: linear-gradient(90deg,#2f8fff,#5fbf6b); transition: width .5s;
}

/* ── Bajnokság ── */
.champ-session-card { margin-bottom: 8px; }
.champ-name { font-size: 16px; font-weight: 700; color: #cfe0f2; }

/* ── Csapatrangsor ── */
/* (uses .tbl + .me already defined) */

/* ── Barátok ── */
.friend-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 0; border-bottom: 1px solid #16212e; flex-wrap: wrap; gap: 6px;
}
.friend-list {
  display: grid; grid-template-columns: repeat(auto-fill,minmax(220px,1fr));
  gap: 8px; margin-top: 8px;
}
.friend-card {
  display: flex; align-items: center; gap: 10px;
  background: #0d1822; border-radius: 8px; padding: 10px 12px;
  border: 1px solid #1c2734;
}
.friend-avatar { font-size: 24px; flex-shrink: 0; }
.friend-info   { flex: 1; min-width: 0; }
.friend-name   { font-weight: 700; color: #cfe0f2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Üzenetek ── */
.msg-layout {
  display: flex; gap: 12px; align-items: flex-start; flex-wrap: wrap;
}
.msg-sidebar {
  flex: 0 0 180px; display: flex; flex-direction: column; gap: 4px;
  background: #0e1822; border: 1px solid #1c2734; border-radius: 8px; padding: 10px;
}
.msg-nav-btn {
  display: block; padding: 8px 12px; border-radius: 6px;
  color: #aebfd0; font-weight: 700; font-size: 13px;
  background: none; border: none; cursor: pointer; text-align: left;
  transition: background .15s, color .15s; text-decoration: none;
}
.msg-nav-btn:hover, .msg-nav-btn.active { background: #1c2d3e; color: #fff; }
.msg-badge {
  display: inline-block; background: #e0533a; color: #fff;
  border-radius: 9px; font-size: 10px; font-weight: 700;
  padding: 0 5px; min-width: 16px; text-align: center; vertical-align: middle;
}
.msg-main { flex: 1; min-width: 0; }
.form-row  { display: flex; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.form-row > div { flex: 1; min-width: 160px; }

/* ---- admin table overflow fix ---- */
.admin-main .panel{overflow-x:auto}
.admin-main table.tbl{min-width:100%}
.admin-main table.tbl th,.admin-main table.tbl td{white-space:nowrap}
.admin-main table.tbl td:nth-child(n+2){max-width:220px;overflow:hidden;text-overflow:ellipsis}

/* ---- topbar sb-link (kattintható hp / kredit) ---- */
.topbar a.sb-link{color:#cfe0f2;text-decoration:none;padding:1px 5px;border-radius:4px;
  transition:background .15s,color .15s}
.topbar a.sb-link:hover{background:#1d2c3d;color:#fff}

/* ---- task-rounds badge fix (kör-számláló a kártya fejlécében) ---- */
.task-card-header{flex-wrap:wrap}
.task-card-header .task-title{flex:1;min-width:120px}
.task-prog-wrap{flex-shrink:1}
.task-rounds{white-space:nowrap;font-variant-numeric:tabular-nums}
.task-locked .task-rounds{opacity:.55}
@media (max-width:700px){
  .task-prog-bar{width:80px}
}

/* ---- napi / heti feladatok (periodic tasks) ---- */
.pt-timer{font-size:12px;color:#e8c14a;font-weight:600;font-variant-numeric:tabular-nums;
  background:rgba(0,0,0,.3);border:1px solid #2a3a4a;border-radius:4px;padding:2px 8px;
  text-transform:none;letter-spacing:0}
.pt-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:12px;margin-top:6px}
.pt-card{background:linear-gradient(160deg,#0e1a26,#0a1320);border:1px solid #1c2734;
  border-radius:7px;padding:12px;display:flex;flex-direction:column;gap:8px;transition:border-color .15s}
.pt-card:hover{border-color:#2f5080}
.pt-card.pt-done{opacity:.62;border-color:#2f5f3a}
.pt-card.pt-locked{opacity:.5}
.pt-head{display:flex;align-items:flex-start;gap:10px}
.pt-icon{font-size:22px;line-height:1;flex-shrink:0}
.pt-title{font-size:13px;font-weight:700;color:#cfe0f2}
.pt-desc{font-size:11px;line-height:1.4;margin-top:2px}
.pt-lock{font-size:11px;color:#e0533a;white-space:nowrap;flex-shrink:0}
.pt-bar{height:7px;background:#162030;border-radius:4px;overflow:hidden}
.pt-bar i{display:block;height:100%;border-radius:4px;transition:width .5s ease;
  background:linear-gradient(90deg,#2f8fff,#7cc4ff)}
.pt-done .pt-bar i{background:linear-gradient(90deg,#5fbf6b,#90ef8f)}
.pt-meta{display:flex;justify-content:space-between;gap:8px;font-size:11px;flex-wrap:wrap}
.pt-prog{color:#cfe0f2;font-weight:600;font-variant-numeric:tabular-nums}
.pt-reward{color:#e8c14a;text-align:right}
.pt-actions{margin-top:2px}
.pt-claimed{color:#5fbf6b;font-size:12px;font-weight:700}
.pt-claim-btn{width:100%;background:linear-gradient(180deg,#3fa04d,#2b7a37);border-color:#2b7a37}

/* ---- katalógus-elem ikon (kép hiányában) ---- */
.item-icon{font-size:24px;line-height:1;display:flex;align-items:center;justify-content:center;
  width:100%;height:100%}
.thumb .item-icon{font-size:26px}
.task-img-placeholder .item-icon,.complex-ic .item-icon{font-size:inherit}
.complex-ic{display:inline-block;margin-right:4px}
.complex-ic img{height:18px;vertical-align:-3px}

/* --- nyelvválasztó --- */
.lang-switch{background:#0f1620;color:#cfe0f0;border:1px solid #23303f;border-radius:5px;
  padding:3px 6px;font-size:12px;line-height:1.2;width:auto;cursor:pointer}
.lang-switch:hover{border-color:#2f8fff}
.topbar .lang-switch{padding:2px 4px;font-size:11px;margin-right:4px}
.auth-lang{display:flex;justify-content:center;margin:-4px 0 14px}
.auth-lang .lang-switch{font-size:12px;padding:4px 8px}

/* a tulajdonság-címkék nagybetűsítése CSS-ből (az ékezeteket is helyesen kezeli) */
.pf-attr .nm{text-transform:uppercase}
