body {
  font-family: Arial, sans-serif;
  text-align: center;
  color: white;
  background-color: black;
}

canvas {
  display: block;
  margin: 20px auto;
  background: black;
}

button {
  border: none;
  padding: 10px 20px;
  font-size: 16px;
  margin: 10px;
  cursor: pointer;
  border-radius: 5px;
}

p {
	 line-height: 1.5;
}

a {
  color: #5dade2;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #85c1e9;
  text-decoration: none;
}

button#addBall1 {
  background-color: orange;
  color: black;
}

button#addBall2 {
  background-color: lightblue;
  color: black;
}

button:hover {
  opacity: 0.9;
}

.tourney-logo {
  font-family: "Tourney", serif;
  font-optical-sizing: auto;
  font-weight: 300;
  font-style: normal;
  font-variation-settings: "wdth" 100;
}

.expletus-sans-general {
  font-family: "Expletus Sans", serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

.scores-container {
  display: flex;
  justify-content: space-around;
  align-items: center;
  flex-wrap: wrap;
  margin: 20px auto;
  padding: 20px;
  border: 2px solid white;
  border-radius: 10px;
  width: 800px;
  max-width: 100%;
  box-sizing: border-box;
  position: relative;
}

.scores-container > div {
  flex: 1;
  text-align: center;
  display: flex;            
  flex-direction: column;
  align-items: center;
}

.scores-container .logo {
  width: 64px;
  height: 64px;     
  object-fit: contain; 
  display: block;
}

/* kis távolság a logó és a cím között */
.scores-container > div > div:first-child {
  margin-bottom: 8px;
}

/* Lábléc */
footer {
  margin-top: 20px;
  padding: 10px;
  background-color: #222;
  color: white;
  font-size: 14px;
}

.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background-color: #fffdf8;
  margin: 15% auto;
  padding: 20px;
  border: 1px solid #888;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(200, 200, 200, 0.6);
  width: 80%;
  color: black;
  text-align: left;
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

#viewerCount {
  display: inline-block;
  padding: 10px 20px;
  background-color: #15b349;
  color: #fff;

  border: 2px solid white;
  border-radius: 12px; 
  box-shadow: 0 0 10px rgba(255, 165, 0, 0.8);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#viewerCount:hover {
  transform: scale(1.1); 
  box-shadow: 0 0 12px rgba(255, 165, 0, 1);
}

#error-message {
  background-color: red; 
  color: white;
  padding: 10px 20px; 
  border: 2px solid white;
  border-radius: 12px;  
  font-size: 16px; 
  max-width: 400px; 
  margin: 20px auto;
  text-align: center; 
  display: none;
}

#ball-warning {
  display: none;              /* JS úgyis átírja */
  position: absolute;         /* <<< ne vegyen részt a flex elrendezésben */
  left: 50%;
  top: 30px;               /* vagy top: 10px; ha felül szeretnéd */
  transform: translateX(-50%);

  width: 200px;               /* FIX szélesség */
  min-height: 32px;
  padding: 6px 10px;
  text-align: center;
  background: red;
  border: 1px solid #fff;
  border-radius: 4px;
  box-sizing: border-box;
  overflow-wrap: break-word;
}

#broadcastMessages {
	margin: 10px 0px;
}

.message-container {
  display: flex;
  flex-direction: column;
  position: relative;
  width: 50%; 
  margin: 0 auto;
  background-color: #2c3e50;
  color: #ecf0f1;
  padding: 15px;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  text-align: left;
}

.timestamp {
  color: #27ae60;
  font-size: 0.9rem;
  margin-bottom: 5px; 
}

.message-text {
  font-size: 1rem;
}

.close-icon {
  position: absolute;
  top: 10px; 
  right: 10px;
  font-size: 1rem; 
  color: #e74c3c; 
  cursor: pointer; 
  background-color: #fff;
  border-radius: 10%;
  padding: 4px 6px 4px 6px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s, color 0.3s;
}

.close-icon:hover {
  background-color: #e74c3c; 
  color: #fff;
}


.randWord {
    border: none;
    padding: 10px 20px;
    font-size: 20px;
    margin: 10px;
    cursor: pointer;
    border-radius: 5px;
    position: absolute;
    opacity: 0.7; /* Kezdettől fogva 70%-os átlátszóság */
    animation: fadeOutDelay 7s forwards; /* Az animáció 7 másodpercig tart */
}

.eball1 {
	background-color: orange;
    color: white;
}

.eball2 {
	background-color: #60d8f4;
    color: #081c3f;
}

@keyframes fadeOutDelay {
    0% {
        opacity: 0.7; /* Kezdő állapot: kicsit átlátszó */
    }
    71.4% {
        opacity: 0.7; /* 5 másodpercig nem változik */
    }
    100% {
        opacity: 0; /* 7 másodperc után teljesen eltűnik */
    }
}

.sintony-regular {
  font-family: "Sintony", serif;
  font-weight: 400;
  font-style: normal;
}

.sintony-bold {
  font-family: "Sintony", serif;
  font-weight: 700;
  font-style: normal;
}

.stats-button {
    display: inline-block; /* Gomb méretezése */
    padding: 10px 20px;
    background-color: #444; /* Sötétszürke háttér */
    color: #ccc; /* Világosszürke szöveg */
    border: 1px solid #555; /* Halvány szegély */
    border-radius: 8px; /* Lekerekített sarkok */
    font-size: 16px;
    cursor: pointer;
    text-align: center;
    transition: background-color 0.3s, color 0.3s, box-shadow 0.3s;
    user-select: none; /* Ne lehessen kijelölni a szöveget */
}


.stats-button:hover {
  transform: scale(1.1); 
  
}


.scores-container {
    position: relative;  /* fontos, hogy ehhez képest legyen abszolút */
    /* a többi meglévő stílus maradhat */
}

#tiktok-status {
    position: absolute;
    top: 10px;
    right: 10px;    /* <-- most már jobb felső sarok */
    left: auto;     /* ha korábban volt left, lenullázzuk */
    padding: 4px 10px;
    border-radius: 6px;
    font-family: "Sintony", system-ui, sans-serif;
    font-size: 13px;
    z-index: 10;
}

#tiktok-status.tiktok-off {
    background: #444;
    color: #ddd;
}

#tiktok-status.tiktok-on {
    background: #ff0050;
    color: #fff;
}


#twitch-status {
    position: absolute;
    top: 10px;         /* kicsivel lejjebb, hogy ne fedje a TikTok jelzést */
    left: 10px;
    right: auto;
    padding: 4px 10px;
    border-radius: 6px;
    font-family: "Sintony", system-ui, sans-serif;
    font-size: 13px;
    z-index: 10;
}

#twitch-status.twitch-off {
    background: #444;
    color: #ddd;
}

#twitch-status.twitch-on {
    background: #9146FF;  /* Twitch lila */
    color: #fff;
}


.code {
  display: inline-block;
  padding: 2px 6px;
  margin: 2px 2px;
  border-radius: 4px;
  font-family: "Consolas", "Courier New", monospace;
  font-size: 0.9em;
  background-color: #e9e9e9;
  color: #333;
  border: 1px solid #ccc;
}


.list {
  margin: 0 0 1rem 1.2rem;
  padding: 0;
}

.list li {
  margin-bottom: 0.4rem;
}

/* Középső "INTERAKTÍV LIVE" panel */

.interaktiv-box {
  flex: 1;
  text-align: center;
  font-family: "Sintony", system-ui, sans-serif;
  padding: 0 10px;
  padding-top: 100px;
}

.interaktiv-title {
  font-size: 26px;
  letter-spacing: 2px;
  font-weight: 700;
  margin-bottom: 6px;
}

.interaktiv-main {
  color: #ffffff;
}

.interaktiv-live {
  color: #ff0050; /* TikTok-rózsaszín */
  margin-left: 6px;
}

.interaktiv-subtitle {
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.interaktiv-line {
  font-size: 15px;
  margin: 2px 0;
  white-space: nowrap;
}

.interaktiv-code {
  font-family: "Consolas", "Courier New", monospace;
  color: #ffffff;
}

.interaktiv-arrow {
  margin: 0 6px;
  color: #ffffff;
}

.interaktiv-label {
  font-weight: 700;
}

.interaktiv-label-fidesz {
  color: #ffa500; /* narancs */
}

.interaktiv-label-tisza {
  color: #60d8f4; /* világoskék */
}



/* TikTok gift / overlay – teljes képernyős háttér + középre rakott szöveg */
.gift-overlay {
  position: fixed;
  inset: 0;                /* top/right/bottom/left: 0 */
  z-index: 9999;
  background-color: black;
  background-repeat: no-repeat;
  background-position: center center;
  /* background-size-t JS-ből állítjuk: contain vagy cover */
  display: flex;
  align-items: center;     /* függőlegesen középre */
  justify-content: center; /* vízszintesen középre */
  pointer-events: none;    /* ne lehessen ráklikkelni semmire */
}

/* belső wrapper – csak a szöveg helyének központosítására */
.gift-overlay-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

/* a fekete hátteres szövegdoboz */
.gift-overlay-text {
  max-width: 80%;
  padding: 10px 18px;
  background-color: rgba(0, 0, 0, 0.8);
  color: #ffffff;
  border-radius: 8px;
  font-family: "Sintony", system-ui, sans-serif;
  font-weight: 700;
  text-align: center;
  /* TikTok álló 1080×1920-hoz is jól skálázódó méret: */
  font-size: clamp(18px, 2.4vw, 26px);
  line-height: 1.3;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
}

.gift-index-text {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 10px; /* csak enyhén lekerekítve */
  
  /* TikTok-jellegű, áttetsző háttér */
  background: linear-gradient(
    90deg,
    rgba(0, 242, 234, 0.20),  /* türkizes */
    rgba(255, 0, 80, 0.35)    /* pinkes */
  );
  backdrop-filter: blur(2px);

  color: #ffffff;
  font-family: "Sintony", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.4;
  text-align: center;
  max-width: 100%;

  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);

  opacity: 0;
  transform: translateY(6px);
  transition:
    opacity 0.25s ease-out,
    transform 0.25s ease-out;
}

.gift-index-text.visible {
  opacity: 1;
  transform: translateY(0);
}






.topic-motto {
  margin: 10px auto 25px auto;
  width: 800px;              /* ugyanakkora, mint a scores-container */
  max-width: 100%;
  padding: 8px 18px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #e0e0e0;            /* alap szövegszín (mottó) */
  font-family: "Sintony", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  display: flex;             /* label + szöveg egy sorban */
  align-items: center;       /* függőlegesen egy vonalba hozzuk őket */
  flex-wrap: wrap;           /* hosszú mottó törhet több sorba */
  box-sizing: border-box;
}

/* "TOPIC:" felirat */
.topic-motto .topic-label {
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 12px;
  color: #ff4d6a;            /* halvány, de élénk piros */
  margin-right: 8px;
}

/* A mottó szövege */
.topic-motto .topic-text {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #e0e0e0;            /* marad világos, de ne olyan erős, mint a gombok */
}
