/* 
    #2F4F4F πρασινο ταβλι 
    #f0f0f0 γκρι για background
    #A8D5BA ανοιχτο του πρασινου ταβλι
    #4CAF50 ανοιχτο πρασινο
    #ffe4c4   μπεζακι 
    #F4A460   πορτοκαλι
    #FFA500     -//-
    #231709;  skouro kafe
    #ffaa44;  skouro bez 
    #311d08;  sk kafe 
    #4c1130   μελιτζανι achievement #4c1130
*/

html, body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #ffe4c4; /* μπεζακι */
    color: #333;               /* μαυρο */
    min-height: 100vh; /* Πάντα να πιάνει όλο το ύψος της οθόνης */
    display: flex;
    flex-direction: column;    /* Στήλη: header / main / footer */
}

/* Header */
header {
    background-color: #000; /* μαυρο */
    color: #ffebcd;         /* μπεζακι */
    padding: 8px 0;
    text-align: center;
}

header h1 {
    background-color: #2F4F4F; /* πρασινο ταβλι */ 
    color: #FFA500;            
    font-size: 1.1rem;
    margin: 0;
    padding: 8px 0;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%; 
    z-index: 1000;
}

/* Navigation menu */
nav {
    background-color: #311d08;  /* μαυρο 000 */
    position: fixed;
    top: 36px; /* ίδιο με το ύψος του header */
    left: 0;
    width: 100%;
    z-index: 999; /* λίγο χαμηλότερο από το header */
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

nav ul li {
    position: relative; /* για dropdown */
}

nav ul li a {
    color: #ffe4c4; /* anoixto bez */
    background-color: #311d08;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 6px;
    display: block;
}

nav ul li a:hover {
    background-color: #ffaa44; /* skouro bez */
    color: #231709;
    border-radius: 5px;
}

/* Dropdown μενού */
nav ul li ul {
    display: none;
    position: absolute;
    background-color: #ffaa44; /* skouro bez */
    list-style: none;
    margin: 0;
    padding: 0;
    min-width: 230px;
    z-index: 1000;
}

nav ul li:hover ul {
    display: block;
}

nav ul li ul li a {
    padding: 8px;
}

/* ===== Διόρθωση στοίχισης user icon ===== */
nav ul li a i {
    font-size: 22px;          /* ίδιο μέγεθος με text */
    line-height: 1;           /* αφαιρεί extra κενό */
    vertical-align: middle;   /* ίδια γραμμή με εικόνες/κειμενο */
    position: relative;
    top: 0px;                 /* μικροδιόρθωση */
}

/* Main */
main {
    max-width: 640px;
    margin: 20px auto;
    padding: 45px 10px 0 10px ; /* top right bottom left */
    text-align: center;
    flex: 1;  /* Γεμίζει όλο τον κενό χώρο */
    /* padding-top: 40px; header+nav*/
}

main p,
main ul li,
main img {
    width: 100%;
    max-width: 640px;
    margin: 1px auto;
    /*text-align: justify;*/
    text-justify: inter-word;
    line-height: 1.1;
    text-align: left;
    flex: 1;  /* Γεμίζει όλο τον κενό χώρο */
}

.split-layout {
  display: flex;
  flex-wrap: nowrap;
  width: 100%;
  height: auto; /* calc(100vh - 120px); αφαιρεί header+nav περίπου */
}

.left {
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* ή center, αν θέλεις κάθετη στοίχιση */
  align-items: stretch; /* να γεμίζει το πλάτος */
}

.right {
  display: flex;
  flex-direction: column;
  align-items: stretch; /* αντί για center */
  background: none;     /* αφαιρεί φόντο για να μη φαίνεται πίσω από τον τίτλο */
  color: inherit;
}

.right img {
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain; /* ή cover αν θέλεις να γεμίζει */
}

/* Footer */
footer {
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      background-color: #2F4F4F;
      color: #ffe4c4;
      font-size: 0.7rem;
      text-align: center;
      word-wrap: break-word;
}

footer .container {
  display: flex;
  flex-direction: column; /* κάθετη στοίχιση */
  align-items: center;    /* κέντρο οριζόντια */
}

#footer-label {
    display: inline-block;
    text-decoration: none;
    color: #ffe4c4;
}

#footer-contact {
  margin-bottom: 2px; /* απόσταση κάτω από το κουμπί */
}

#footer-text {
  font-size: 0.8rem;
  opacity: 0.95;  /* λίγο πιο "διακριτικό" */
  padding: 4px 8px;  /* padding (πάνω-κάτω, δεξιά-αριστερά) */
}

/* Σημαία */
.flag-icon {
    width: 25px;
    height: 18px;          /* σταθερό ύψος */
    vertical-align: middle;
    object-fit: cover;     /* δεν παραμορφώνεται */
    border-radius: 2px;    /* μικρό “μαλακό” περίγραμμα */
    flex-shrink: 0;        /* δεν μικραίνει ποτέ */
    cursor: pointer;
}

/* Home */
.home-icon {
    width: 25px;
    height: auto;
    vertical-align: middle;
    cursor: pointer;
}

/* Bordered form */
form {
  border: 3px solid #f1f1f1;
}

/* Full-width inputs */
input[type=text],
input[type=password],
input[type=email] {
  width: 100%;
  padding: 5px 10px;        /* πάνω-κάτω / αριστερά-δεξιά */
  font-size: 16px;
  line-height: 1.6;         /* βοηθάει να είναι το κείμενο κεντραρισμένο κατακόρυφα */
  margin-bottom: 10px;

  -webkit-box-sizing: border-box; 
  -moz-box-sizing: border-box; 
  box-sizing: border-box;

  border: 1px solid #ccc;
  border-radius: 4px;
}

/* Add a background color when the inputs get focus */
input[type=text]:focus, input[type=password]:focus, input[type=email]:focus {
  background-color: #F0FFF0;
  outline: none;
}

.clearfix {
  display: flex;
  justify-content: center;
  margin-top: 5px;
}

.clearfix button + button {
  margin-left: 10px; /* κενό μεταξύ των κουμπιών */
}

/* Set a style for all buttons */
button {
  height: 35px;  
  border-radius: 16px;
  background-color: #2E8B57;
  color: #ffebcd;
  margin: 8px 0;
  border: none;
  cursor: pointer;
  width: 100%;
  font-weight: bold;
  display: flex;
  align-items: center;          /* κάθετο κέντρο */
  justify-content: center;      /* οριζόντιο κέντρο */
  transition: background 0.2s;
}

/* Hover effect */
button:hover, .btn:hover, .signupbtn:hover{
  opacity: 0.95;
  background-color: #00ff7f;
  color: #000;
}

/* Extra style for the signup  button */
.signupbtn {
  width: auto;
  padding: 10px 18px;
}

/* Extra style for the cancel  button */ 
.cancelbtn {
  width: auto;
  padding: 10px 18px;
  background-color: #e97451; /* #ff5349 ff0000*/
  color: #ffebcd;
} 

.cancelbtn:hover {
  opacity: 0.95;
  background-color: #ff7f00;
  color: #000;
}

/* Extra style for the disconnect  button */ 
.discbtn {
  width: auto;
  padding: 10px 18px;
  background-color: #d73b3e; /* #ff5349 ff0000*/
  color: #ffebcd;    
}

.discbtn:hover {
  opacity: 0.95;
  background-color: #ff0000;
  color: #000;
}

/* Center the avatar image inside this container */
.imgcontainer {
  text-align: center;
  margin: 24px 0 12px 0;
}

/* Avatar image */
.avatar {
  width: 20%;
  border-radius: 50%;
}

/* Add padding to containers */
.container {
  padding: 7px;
}

/* The "Forgot password" text */
.psw {
  float: right;
  padding-top: 10px;
}

.password-wrapper {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center; /* Κάθετη στοίχιση όλων των children */
}

.password-wrapper input {
  font-size: 16px;
  line-height: 1.6; /* βοηθάει να είναι το κείμενο κεντραρισμένο κατακόρυφα */
  width: 100%;
  padding-right: 40px; /* χώρο για το μάτι */
  /*height: 30px;*/
  box-sizing: border-box;
}

.password-wrapper .toggle-password {
  position: absolute;
  right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  cursor: pointer;
  color: #eee;
  border-radius: 50%;
  transition: background 0.2s;
}

.password-wrapper .toggle-password:hover {
  background: #4CAF50;
}

/* The Modal (background) */
.modal {
  display: none; /* Hidden by default */
  position: fixed; /* Stay in place */
  z-index: 2000; /* Sit on top */
  left: 0;
  top: 0;
  width: 100%; /* Full width */
  height: 100%; /* Full height */
  overflow: auto; /* Enable scroll if needed */
  background-color: rgb(0,0,0); /* Fallback color */
  background-color: rgba(0,0,0,0.8); /* Black w/ opacity */
  padding-top: 30px; /* distance */
}

/* Modal Content/Box */
.modal-content {
  background-color: #e9e9e9; /*fefefe*/
  margin: 1px auto; /* 15% from the top and centered */
  border: 1px solid #888;
  width: 75%; /* πολυ στενο χανω κειμενο στο κινητο */
  max-width: 400px;
  font-size: 12px;
}

/* The Close Button */
.close {
  /* Position it in the top right corner outside of the modal */
  position: absolute;
  right: 25px;
  top: 0;
  color: #FFF;
  font-size: 35px;
  font-weight: bold;
}

/* Close button on hover */
.close:hover,
.close:focus {
  color: red;
  cursor: pointer;
}

/* Add Zoom Animation */
.animate {
  -webkit-animation: animatezoom 0.6s;
  animation: animatezoom 0.6s
}

@-webkit-keyframes animatezoom {
  from {-webkit-transform: scale(0)}
  to {-webkit-transform: scale(1)}
}

@keyframes animatezoom {
  from {transform: scale(0)}
  to {transform: scale(1)}
}

#logout-email {
  color: inherit;        /* Διατηρεί το χρώμα */
  text-decoration: none; /* Αφαιρεί υπογράμμιση */
  pointer-events: none;  /* Απενεργοποιεί click αν θέλεις */
}

/* FAQ Section */
.faq-section {
  max-width: 800px;
  /*margin: 80px auto 60px auto; αφήνει χώρο κάτω από sticky menu */
  padding: 2px 16px;
  text-align: left; /* όλο το περιεχόμενο αριστερά */
}

.faq-section h2 {
  text-align: center;
  color: #2F4F4F;
  margin-top: 10px;
  margin-bottom: 15px;
  font-size: 1.4rem;
  border-bottom: 2px solid #ccc;
  display: inline-block;
  padding-bottom: 6px;
}

.faq-section details {
  margin-bottom: 12px; /* παραπάνω κενό ανάμεσα στις ερωτήσεις */
  background: #f9f9f9;
  border-radius: 8px;
  border: 1px solid #ddd;
  padding: 6px 14px;
  transition: background 0.2s ease;
}

.faq-section details:hover {
  background: #f1f1f1;
}

.faq-section summary {
  font-weight: bold;
  cursor: pointer;
  color: #333;
  margin-bottom: 6px;
}

.faq-section p {
  margin: 8px 0 4px 0;
  color: #444;
  line-height: 1.5;
}

/* Overlay background */
.popup-overlay {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
}

.popup-overlay img {
  width: auto;           /* κρατά το original aspect ratio */
  height: auto;          /* δεν παραμορφώνει */
  max-width: 90vw;       /* μικραίνει μόνο αν δεν χωράει */
  max-height: 90vh;      /* μικραίνει μόνο αν δεν χωράει */
  border: 3px solid #fff;
  border-radius: 8px;
  box-shadow: 0 0 25px rgba(255,255,255,0.3);
  cursor: zoom-out;
  /* object-fit: contain; */
}


/* === Toast notification === */

.toast {
  visibility: hidden;
  min-width: 250px;
  max-width: 90%;
  background-color: red ; /* */
  color: #fff;            /* μπεζ #ffe4c4 */
  text-align: center;
  border-radius: 12px;
  padding: 12px 18px;
  position: fixed;
  z-index: 3000;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  font-size: 16px;
  font-weight: bold;
  opacity: 0;
  transition: opacity 0.4s, bottom 0.4s;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.toast.show {
  visibility: visible;
  opacity: 1;
  bottom: 50px;
}

.streak-icons {
  font-size: 14px;
  letter-spacing: 1px;
}

    table { 
        border-collapse: collapse; 
        width: 100%; 
        margin: 5px auto; 
        font-family: "Segoe UI", sans-serif;
        border-radius: 5px;
        overflow: hidden;
        box-shadow: 0 0 20px rgba(0,0,0,0.2);
    }

    th, td { 
        padding: 1px 1px; 
        text-align: center; 
        vertical-align: middle;
    }

    th { 
        padding: 6px 1px;
        background-color: #2F4F4F; 
        color: #FFA500; /* #FFA500; */
        /* text-transform: uppercase; */
        /*letter-spacing: 0.5px;*/
    }

    /* Εναλλαγή γραμμών με ήπια contrast */
    tr:nth-child(even) { 
        background-color: #E8E8E8; 
        color: #222;
    }

    tr:nth-child(odd) { 
        background-color: #D3D3D3; 
        color: #222;
    }
    
    .current-user td {
      border-top: 1px solid #000;
      border-bottom: 1px solid #000;
    }
    
    .better {
    background-color: #c8ffc8; /* απαλά πράσινο */
    font-weight: bold;
    }

/* === RANKING TABLE === */
.ranking-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 700px;
  margin: 10px auto;
  table-layout: fixed;
  font-family: "Segoe UI", sans-serif;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 0 20px rgba(0,0,0,0.2);
}

.ranking-table th:nth-child(1),
.ranking-table td:nth-child(1) {
    width: 8%;
}

.ranking-table th:nth-child(2) {
    width: 50%;
}

.ranking-table th,
.ranking-table td {
  padding: 8px 2px;
  text-align: center;
  vertical-align: middle;
}

.ranking-table th {
  font-size: 12px;
  padding: 10px 4px;
}

.ranking-table td:nth-child(2){
    text-align: left;
}

.ranking-table th:nth-child(1),
                th:nth-child(2){
    font-size: 16px;
}

.ranking-table tr:hover {
  background-color: #708090;
  color: #fff;
}

/* rank buttons */
.rank-btn {
  display: flex;
  justify-content: center;   /* κέντρο οριζόντια */
  align-items: center;       /* κέντρο κάθετα */
  margin: 0 auto;
  width: 70%;
  height: 35px;              /* καθορίζει ύψος */
  background-color: #311d08; 
  color: #ffaa44;
  border: none;
  border-radius: 10px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
  text-align: center;
}
.rank-btn:hover {
  background-color: #ffaa44;
  color: #231709;
}

/* Highlight του τρέχοντος χρήστη */
.ranking-table .current-user {
  background-color: lightgreen;
  font-weight: 600;
}
    
.ranking-table tr.current-user:hover {
    background-color: green;
    color: #fff;
}

/* === COMPARE TABLE === */
.compare-table {
  border-collapse: collapse;
  width: 100%;
  max-width: 700px;
  margin: 10px auto;
  table-layout: fixed;
  background: #fff;
  font-family: "Segoe UI", sans-serif;
  box-shadow: 0 0 12px rgba(0,0,0,0.15);
  border-radius: 4px;
  overflow: hidden;
}

.compare-table th,
.compare-table td {
  border: 2px solid #000;
  padding: 10px;
  text-align: center;
  vertical-align: middle;
  font-size: 13px;
  color: blue;
  /* font-weight: bold; */
}

.compare-table thead th {
  background-color: #2F4F4F;
  color: #FFA500; /* #F4A460 */
  font-weight: 600;
}

.compare-table .stat-col { width: 23%; }  /* μικρότερη */
.compare-table .player-col { width: 38%; }  /* αυξάνει ελαφρά τις άλλες δύο */

.compare-table tr td {
  /* font-weight: normal; Επαναφορά default */
  font-weight: bold;
}

.compare-table tr.better td:nth-child(2) { color: green; font-weight: bold; }
.compare-table tr.other-better td:nth-child(2) { color: red; font-weight: bold; }
.compare-table tr.other-better td:nth-child(3) { color: green; font-weight: bold; }
.compare-table tr.better td:nth-child(3) { color: red; font-weight: bold; } 

.compare-table td:nth-child(1),
                th:nth-child(1){
    background-color: #2F4F4F;
    color: #FFA500;
}

.compare-table .player-col {
  width: 28px;
  height: 20px;
  display: block;
  margin: 0 auto 5px auto;
  border-radius: 2px;
  object-fit: cover;
}

.compare-table .player-col .player-name {
  font-weight: 600;
  font-size: 15px;
}

/* index */
.home-info {
  background-color: #7a3700; /* #7a3700  #6b3000 */
  color: #f5deb3; /* ανοιχτό μπεζ */
  padding: 10px 14px;
  border-radius: 10px;
  max-width: 620px;
  margin: 20px auto;
  text-align: center;
  font-size: 20px;
  box-shadow: 0 0 8px rgba(0,0,0,0.25);
}

.home-info p {
  /* width: 90%;        περιορίζει το πλάτος για πιο ωραία ευθυγράμμιση */
  text-align: center; /* εξασφαλίζει κεντράρισμα του κειμένου */
  margin: 6px auto; /* auto or 0 */
  /*line-height: 1.4; */
}

.home-info hr {
  margin: 10px auto;
  width: 80%;
  border: 1px solid #6e4a2e;
}

.home-header {
  font-weight: bold;
  color:  #ffe4c4;
  font-size: 20px;
  margin-bottom: 6px;
}

.button-link {
  display: inline-block;
  background-color: #311d08; 
  color: #ffaa44;
  padding: 7px 18px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s ease;
  margin-top: 5px;
}

.button-link:hover {
  background-color: #ffaa44;
  color: #231709;
}

.status-ok {
  color: #90ee90; /* πράσινο */
}
.status-bad {
  color: #ff7f7f; /* κόκκινο */
}
.status-none {
  color: #ffe4c4; /* default ανοιχτό */
}

#countdown {
  font-weight: bold;
  color: #ffe4c4;
}

  .welcome-container, .announcement-box {
    max-width: 650px;
    margin: 10px auto;
    text-align: center;
    background: linear-gradient(135deg, #fafafa, #f3f3f3);
    border-radius: 12px;
    padding: 2px 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  }

  .welcome-container p, .announcement-box p  {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin: 10px 0;
  }

  .welcome-container strong {
    color: #b8860b;
  }

  .announcement-box h3 {
    margin-bottom: 2px;
    font-size: 18px;
    color: #8b4513;
  }

