@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap");

:root {
  --background-body: #f4f4f4;
  --background-content: #ffffff;
  --text-primary: #222222;
  --text-secondary: #777777;
  --border-color: #eaeaea;
  --card-background: #ffffff;
  --accent-color: #222222;
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--text-primary);
  margin: 0;
  overflow-x: hidden;
  min-height: 100vh;
  background-color: var(--background-body);
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23dddddd' fill-opacity='0.6' fill-rule='evenodd'%3E%3Cpath d='M0 40L40 0H20L0 20M40 40V20L20 40'/%3E%3C/g%3E%3C/svg%3E");
  background-attachment: fixed;
}

body::before,
body::after {
  content: none;
}

.nav-bg-color {
  background-color: #172430;
  height: 60px;
  width: 111%;
  margin-left: -20px;
}

.logo {
  color: #fff;
  width: 240px;
  align-items: center;
  display: flex;
  margin-left: auto;
  margin-right: auto;
}

.nav-btn {
  z-index: 99;
  transition: all 0.3s ease;
  position: absolute;
  left: 15px;
}

.nav-relative {
  position: relative !important;
}

.mt-1 {
  margin-top: 10px;
}

.container {
  width: 100%;
  max-width: 360px;
  margin: 0px auto;
  background-color: var(--background-content);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
  position: relative;
  z-index: 1;
  padding: 0 20px 20px 20px;
  /* border-top: 4px solid var(--accent-color); */
}

header h1 {
  text-align: center;
  color: var(--accent-color);
  margin-top: 10px;
  margin-bottom: 20px;
  font-size: 2.2em;
  font-weight: 700;
}
.search-bar {
  width: calc(100% - 24px);
  padding: 12px;
  margin-bottom: 15px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  box-sizing: border-box;
  background-color: #f7f7f7;
  color: var(--text-primary);
  font-size: 1em;
}
.search-bar::placeholder {
  color: var(--text-secondary);
}
.header-description {
  text-align: center;
  font-size: 0.9em;
  color: var(--text-secondary);
  margin-bottom: 25px;
  padding: 0 10px;
}
.header-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 30px;
}

.spGames {
  background-color: transparent;
  padding: 10px;
  text-align: center;
  box-shadow: rgba(0, 0, 0, 0.25) 0 12px 22px -12px;
  border-radius: 15px;
  border: 1.5px dotted var(--border-color);
}

.btn {
  background-color: var(--accent-color);
  color: white;
  font-weight: 600;
  border: 2px solid var(--accent-color);
  border-radius: 50px;
  padding: 10px 22px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
}
.btn:hover {
  background-color: #444;
  border-color: #444;
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}
.btn:active {
  transform: translateY(0);
}

.section-title {
  text-align: center;
  font-size: 1.8em;
  margin-bottom: 20px;
  color: var(--text-primary);
  font-weight: 600;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--accent-color);
  display: inline-block;
  width: auto;
}
.all-games-section {
  text-align: center;
}
.title-decorator {
  display: none;
}
.games-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 30px;
}

.game-item {
  background-color: var(--card-background);
  border: 1px solid var(--border-color);
  border-radius: 15px;
  text-align: center;
  display: flex;
  flex-direction: column;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
  transition: all 0.3s ease-in-out;
  overflow: hidden;
}
.game-item:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.12);
  border-color: var(--accent-color);
}
.game-item img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: 0;
  background-color: #e0e0e0;
  border: none;
  border-bottom: 1px solid var(--border-color);
}
.game-item h3 {
  font-size: 1em;
  margin: 15px 10px;
  color: var(--text-primary);
  line-height: 1.35;
  flex-grow: 1;
}

/* .play-now-btn,
.play-game-button {
  padding: 15px;
  margin: 10px auto 15px auto;
  background-color: transparent;
  border: 2px solid var(--accent-color);
  border-radius: 50%;
  position: relative;
  transition: all 0.3s ease;
  font-size: 16px;
  cursor: pointer;
}
.play-now-btn:hover,
.play-game-button:hover {
  background-color: var(--accent-color);
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
}

.play-now-btn::after,
.play-game-button::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 55%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 14px solid var(--accent-color);
  transition: border-left-color 0.3s ease;
}
.play-now-btn:hover::after,
.play-game-button:hover::after {
  border-left-color: white;
}

.play-now-btn {
  width: 48px;
  height: 48px;
} */

.play-now-btn {
  background-color: var(--accent-color);
  color: white;
  font-weight: 600;
  border: none;
  padding: 10px 24px;
  /* border-radius: 30px; */
  cursor: pointer;
  font-size: 0.9em;
  text-shadow: 0px -1px 1px rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 -2px 2px rgba(0, 0, 0, 0.2), 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all 0.15s ease-out;
}
.play-game-button{
  background-color: var(--accent-color);
  color: white;
  font-weight: 600;
  border: none;
  padding: 10px 24px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 0.9em;
  text-shadow: 0px -1px 1px rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 -2px 2px rgba(0, 0, 0, 0.2), 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all 0.15s ease-out;
}
.play-game-button:hover,
.play-now-btn:hover {
  background-color: var(--accent-color);
  box-shadow: inset 0 -1px 1px rgba(0, 0, 0, 0.2), 0 1px 2px rgba(0, 0, 0, 0.2);
  transform: translateY(1px);
}

.play-now-btn:active {
  background-color: var(--accent-color);
  transform: translateY(2px);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.4);
}


/* .play-game-button {
  width: 50px;
  height: 50px;
  border-width: 3px;
} */

/* .play-game-button::after {
  border-top-width: 12px;
  border-bottom-width: 12px;
  border-left-width: 20px;
} */

.more-button-container {
  text-align: center;
  margin-bottom: 30px;
}
.what-is-section h2 {
  text-align: left;
  font-size: 1.3em;
  margin-bottom: 10px;
  color: var(--text-primary);
  padding-bottom: 5px;
  border-bottom: 2px solid var(--accent-color);
  display: inline-block;
}
.what-is-section p,
.what-is-section ul {
  font-size: 0.9em;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 15px;
}
.what-is-section ul {
  padding-left: 20px;
}
.what-is-section li {
  margin-bottom: 8px;
}
footer {
  display: flex;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
  margin-top: 20px;
}
footer .btn {
  padding: 8px 15px;
  font-size: 0.85em;
}

.game-details-page .container {
  height: 100vh;
  padding: 0;
}
.header {
  background-color: var(--accent-color);
  color: white;
  text-align: center;
  padding: 12px 0;
  font-size: 1.8em;
  font-weight: bold;
  width: 100%;
}
.header-link-wrapper {
  text-decoration: none;
}
.content-area {
  padding: 10px;
  background-color: var(--background-content);
}
.game-display-area {
  width: 100%;
  height: 250px;
  background-color: #eaeaea;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 15px;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
}
.game-meta-info {
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  padding: 10px;
  background-color: #f9f9f9;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 15px;
}

.game-icon {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid #ddd;
}

.game-title-details h2 {
  margin: 0 0 5px 0;
  font-size: 1.3em;
  color: #333;
  /* Truncate text */
  max-width: 150px; /* Adjust based on your layout */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-plays {
  margin: 0;
  font-size: 0.9em;
  color: #777;
  /* Truncate text */
  max-width: 100px; /* Adjust based on your layout */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.game-description-content {
  padding: 15px;
  border: 2px dashed var(--accent-color);
  border-radius: 5px;
  background-color: #fff;
  margin-bottom: 20px;
}
.game-description-content h3 {
  font-size: 1.2em;
  color: #333;
  margin-top: 0;
  margin-bottom: 8px;
}
.game-description-content h4 {
  font-size: 1em;
  color: #444;
  margin-top: 0;
  margin-bottom: 10px;
  font-weight: bold;
}
.game-description-content p {
  font-size: 0.9em;
  line-height: 1.6;
  color: #555;
  margin-bottom: 0;
}
.game-iframe {
  display: none;
  width: 100%;
  height: 100%;
  border: none;
  background-color: #000;
}
.game-controls-overlay {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
  display: flex;
  gap: 6px;
}
.control-btn {
  background-color: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 5px;
  cursor: pointer;
  padding: 4px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background-color 0.2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.control-btn:hover {
  background-color: rgba(0, 0, 0, 0.6);
}
.control-btn svg {
  width: 24px;
  height: 24px;
  fill: #ffffff;
}
#closeGameBtn {
  display: none;
}
.game-display-area.is-playing .play-game-button {
  display: none;
}
.game-display-area.is-playing .game-iframe,
.game-display-area.is-playing #closeGameBtn {
  display: block;
}
