/* === BASE STYLES === */
body {
  background-color: #121212;
  color: #e0e0e0;
  font-family: 'Segoe UI', sans-serif;
  margin: 0;
  padding: 0;
}

.container {
  max-width: 1200px;
  margin: 20px auto;
  padding: 20px;
  background-color: #1e1e1e;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(0,0,0,0.6);
  box-sizing: border-box;
}

h1 {
  text-align: center;
  margin-bottom: 20px;
}

#infoBox {
  font-size: 0.9em;
  color: #aaa;
  margin-bottom: 20px;
  text-align: center;
}

/* === FORM STYLES === */
.form-container {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  font-family: 'Segoe UI', sans-serif;
}

label {
  display: block;
  margin-top: 15px;
  font-weight: bold;
}

input, select, textarea {
  width: 100%;
  padding: 10px;
  margin-top: 5px;
  margin-bottom: 12px;
  box-sizing: border-box;
  background-color: #2c2c2c;
  color: #fff;
  border: 1px solid #444;
  border-radius: 6px;
  font-size: 16px;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: #03dac6;
  background-color: #333;
}

button {
  margin-top: 20px;
  padding: 12px 20px;
  background-color: #03dac6;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  transition: background-color 0.2s ease;
  display: block;
  width: 100%;
}

button:hover {
  background-color: #018786;
  color: #fff;
}

button:focus-visible {
  outline: 2px solid #03dac6;
  outline-offset: 2px;
}

.info-note {
  margin-top: 15px;
  font-size: 0.9em;
  color: #aaa;
  text-align: center;
}

/* === SUBGROUP TRANSITIONS === */
.subgroup {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.4s ease;
}

.subgroup.visible {
  max-height: 1000px;
  opacity: 1;
}

/* === SEARCH BOX === */
input[type="text"] {
  background-color: #2c2c2c;
  border: 1px solid #444;
  border-radius: 6px;
  font-size: 16px;
  line-height: 1.4;
}

/* === RESULT CARD === */
.result-card {
  background-color: #2a2a2a;
  padding: 15px;
  margin-top: 20px;
  border-radius: 8px;
  box-shadow: 0 0 5px rgba(0,0,0,0.3);
}

.result-card:hover {
  background-color: #333;
}

.collection-number {
  font-size: 0.9em;
  color: #bbb;
}

/* === MATCH LIST === */
.match-list {
  list-style: none;
  padding: 0;
  margin-top: 10px;
}

.match-list li {
  background-color: #2c2c2c;
  padding: 10px;
  margin-bottom: 5px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.match-list li:hover {
  background-color: #444;
}

#resultsList {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.result-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 350px; /* consistent width */
  background-color: #2a2a2a;
  padding: 10px 14px;
  border-radius: 6px;
  box-sizing: border-box; /* ensures padding doesn't overflow */
  overflow: hidden;
  transition: background-color 0.2s ease;
}

.match-name {
  font-size: 16px;
  font-weight: 500;
  color: #e0e0e0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-right: 10px;
}

.view-button {
  font-size: 14px;
  padding: 6px 12px;
  background-color: #03dac6;
  color: #000;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
  line-height: 1;
  height: 32px;
  flex-shrink: 0;
  max-width: 100px;
  box-sizing: border-box;
}
.view-button:hover {
  background-color: #018786;
  color: #fff;
}

#searchInput + button {
  margin-bottom: 20px;
}
/* === NAVIGATION BUTTONS === */
.nav-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 15px;
}

.nav-buttons button {
  flex: 1;
  margin: 0 5px;
  padding: 10px;
  background-color: #03dac6;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.nav-buttons button:disabled {
  background-color: #555;
  color: #999;
  cursor: not-allowed;
}

.nav-buttons button:hover:not(:disabled) {
  background-color: #018786;
}

/* === FEATURE CARDS === */
.feature-grid {
  display: flex;
  gap: 20px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.feature-card {
  flex: 1;
  min-width: 200px;
  padding: 20px;
  background-color: #1e1e1e;
  color: #fff;
  border-radius: 8px;
  border-style: solid;
  border-color: #ffffff;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-5px);
  background-color: #03dac6;
  color: #000;
}

.feature-card.disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

/* === SUGGESTION BAR === */
.suggestion-bar {
  display: block;
  width: 100%;
  padding: 12px 20px;
  margin-top: 25px;
  background-color: #03dac6;
  color: #000;
  font-weight: bold;
  text-align: center;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.suggestion-bar:hover {
  background-color: #018786;
  color: #fff;
  transform: translateY(-2px);
}

/* === MENU === */
.menu {
  display: flex;
  gap: 20px;
  background-color: #1e1e1e;
  padding: 10px 20px;
  border-radius: 6px;
}

.menu .nav-link {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  padding: 6px 12px;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.menu .nav-link:hover {
  background-color: #03dac6;
  color: #000;
}

.menu .nav-link.active {
  background-color: #03dac6;
  color: #000;
}

/* === VERSION LABEL === */
#version-label {
  position: fixed;
  bottom: 10px;
  right: 10px;
  background-color: rgba(30, 30, 30, 0.9);
  color: #fff;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.85em;
  font-weight: bold;
  z-index: 9999;
}

/* === DISCORD BUTTON === */
#discord-button {
  position: fixed;
  bottom: 10px;
  left: 10px;
  background-color: #5865F2;
  color: white;
  padding: 8px 10px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: bold;
  text-decoration: none;
  z-index: 9999;
  transition: background-color 0.2s ease;
}

#discord-button:hover {
  background-color: #4752C4;
}


/* === RESPONSIVE DESIGN === */
@media (max-width: 600px) {
  body {
    font-size: 16px;
  }

  .container {
    padding: 15px;
    margin: 10px;
  }

  input[type="text"],
  select,
  textarea,
  button {
    font-size: 16px;
    padding: 10px;
  }

  .result-card {
    padding: 12px;
  }

  .match-list li {
    font-size: 16px;
    padding: 10px;
  }
}


#mobile-game-button {
  position: fixed;
  bottom: 10px;
  left: 10px;
  background-color: #03dac6;
  color: #000;
  border: none;
  border-radius: 6px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  z-index: 9999;
  display: none; /* hidden by default */
}

/* Show only on small screens */
@media (max-width: 768px) {
  #mobile-game-button {
    display: block;
  }
}
