img{
	max-width: 100%;
}

html{
	background-color: #5B4B49;
}

#game-version {
  position: fixed;
  top: 10px;
  left: 12px;
  z-index: 5;
  color: #c4b6a6;
  font-size: 12px;
  letter-spacing: 0.04em;
  pointer-events: none;
}

#monthly-plays {
  position: fixed;
  top: 28px;
  left: 12px;
  z-index: 5;
  color: #c4b6a6;
  font-size: 12px;
  letter-spacing: 0.04em;
  pointer-events: none;
}

#high-score-pixel {
  position: fixed;
  right: 0;
  bottom: 0;
  width: 1px;
  height: 1px;
  background: #5B4B49;
  pointer-events: none;
  z-index: 3;
}

/* Basic modal styles (you'll likely have more) */
.modal-instructions-content {
  /* ... existing styles ... */
}

.instruction-block {
  margin-bottom: 20px; /* Space between instruction blocks */
}

.instruction-block h2 {
  margin-bottom: 10px;
}

.visual-instruction {
  display: flex; /* Use flexbox for alignment */
  align-items: center; /* Vertically center content */
  margin-bottom: 10px;
}

.instructions-movement-text {
  margin-left: 20px;
}

#arrow-keys-image {
  height: 80px;
}

.key-visual {
  width: 40px;
  height: 40px;
  background-color: #eee; /* Light gray background for keys */
  border: 1px solid #ccc;
  display: flex;
  justify-content: center; /* Center text horizontally */
  align-items: center; /* Center text vertically */
  margin-right: 10px;
  font-weight: bold;
  font-size: 1.2rem;
}

.arrow-keys {
  /* Style for arrow key image if needed */
  width: 100px; /* Adjust as needed */
}


/* Basic styling for the instructions modal */
.modal-instructions {    
    max-height: 90vh;
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(255, 255, 255, 0.7);
  }

  .modal-instructions-content {
    overflow-y: auto;
    background-color: #fefefe;
    color: #111;
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%; /* Could be more or less */
    max-width: 600px; /* Set a maximum width */
    position: relative; /* For positioning the close button */
  }
  
  .close-instructions {
    color: #aaa;
    position: absolute; /* Absolute positioning within the content */
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    /* Add transition for a smooth hover effect */
    transition: color 0.3s ease;
  }
  
  .close-instructions:hover,
  .close-instructions:focus {
    color: black;
    text-decoration: none; /* Remove underline on hover */
  }
  
  /* Style the headings for better hierarchy */
  .modal-instructions-content h2 {
    font-size: 1.8rem; 
    margin-bottom: 10px;
    color: #333; /* Darker color for headings */
  }
  
  /* Style the paragraphs for better readability */
  .modal-instructions-content p {
    margin-bottom: 15px;
    line-height: 1.6; /* Improve line height for readability */
  }
  
  /* Style the list for better visual appeal */
  .modal-instructions-content ul {
    list-style-type: disc; /* Use bullet points */
    margin-left: 20px; /* Indent the list items */
    margin-bottom: 15px;
  }
  
  .modal-instructions-content li {
    margin-bottom: 8px; /* Space out the list items */
  }
/* update button styling */
/* update button styling */

/* // */
button {
	background-color: #828489;
	border-radius: 6%;
	color: ghostwhite;
}

/* change button to ghostwhite */


#hurtByEnemy,
#stolenByBandit {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    border-radius: 20px;
    opacity: 0;
    z-index: 5;
    pointer-events: none;
    transition: opacity 60ms linear;
}

#hurtByEnemy {
    background-color: rgba(220, 0, 0, 0.55);
}

#stolenByBandit {
    background-color: rgba(255, 215, 0, 0.7);
}

#gold-collected.gold-flash {
    color: #7a4e00;
    text-shadow: 0 0 10px #ffe566, 0 0 18px #ffd000;
}

.arrow-launching-instructions {
  font-weight: bold;
}

#top-section{
	text-align: center;

}

/* Game stats go here */
#game-stats h2{
	color: #d4b46a;
	text-align: center;
	display: inline-block;
	margin: 10px;
}

#game-stats p{
	text-align: center;
	display: inline-block;
}

#gold-collection-section{
	display: inline-block;
}
#gold-collection-section img{
	margin-bottom: -26px;	

}

canvas{
	border-radius: 20px;
	position: relative;
	z-index: 0;
}


#gold-collected{
	background-image: url("Images/gold-holder.png");
	height: 70px;
	width: 100px;
	/* background-size: 100px 68px; */
	display: inline-block;
	/* margin-left: -76px; */
	color: #0A0908;
	font-weight: 700;
	line-height: 70px;
	font-size: 20px;

}

#health{
	color: white;
	font-weight: 700;
	background-image: url("Images/heart38.png");
	height: 68px;
	width: 71px;	
	line-height: 68px;

}
/* Text display and middle section go below */

#textDisplay{
	color: red;
}


#middle-section{
    position: relative;
	text-align: center;
}

#text-section{
	text-align: center;
}

/* Styling for the shop here */
#modal-shop {
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

/* Modal Content/Box */
.modal-shop-content {
    background-color: #5B4B49	;
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    height: 60%; /* Could be more or less, depending on screen size */

}

/* The Close Button */
.close-shop {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

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

/* shop button styling below */
#shop-buttons div{
	float: left;
	width: 20%;
	text-align: center;

}

#shop-buttons div button{
	margin-bottom: 30px;
}


.gold-text{
	color: #3d2a00;
	font-weight: 800;
}


/* target all images and put them directly underneath the buttons */
#shop-buttons img{
	margin-top: 20px;
	display: block;
	margin: auto;
}

/* //styling for instructions modal below */

#modal-instructions {
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
}

/* Modal Content/Box */
.modal-instructions-content {
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    height: 60%; /* Could be more or less, depending on screen size */
    background-color: #f8f8f8; /* Black w/ opacity */
    color: black	;

}


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

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

/* High Scores Modal */
#modal-high-scores {
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

/* Modal Content/Box */
.modal-high-scores-content {
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    background-color: #f8f8f8; /* Light gray background */
    color: black;
    border-radius: 5px;
}

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

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

/* DM High Score button in modal */
#dm-high-score-button {
    display: inline-block;
    background-color: #1da1f2;
    color: white;
    padding: 12px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.2s ease;
}

#dm-high-score-button:hover {
    background-color: #0d8bd9;
}#root {
  min-height: 100vh;
}

.modal-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  z-index: 10;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: rgba(28, 22, 20, 0.72);
}

.hidden-modal {
  display: none !important;
}

.modal-panel,
.modal-instructions-content,
.modal-shop-content,
.modal-high-scores-content {
  margin: 0 auto !important;
  height: auto !important;
  max-height: 88vh;
  overflow: hidden;
  width: min(560px, 92vw) !important;
  padding: 22px 24px 18px !important;
  border: 1px solid #c4b6a6;
  border-radius: 14px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  background: linear-gradient(180deg, #f7f1e6 0%, #efe4d4 100%) !important;
  color: #2b211c !important;
  position: relative;
}

.modal-shop-content {
  width: min(720px, 94vw) !important;
}

.close-instructions,
.close-shop,
.close-high-scores,
.close-submit-score,
.close-enemy-types {
  position: absolute;
  top: 10px;
  right: 14px;
  float: none;
  color: #6d5c50;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.modal-instructions-content .instructions-lede {
  margin: 0 28px 0 0;
  padding-bottom: 36px;
  line-height: 1.45;
  color: #000 !important;
  font-weight: 800 !important;
  font-size: 1.22rem !important;
}

.instructions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 18px;
  margin-bottom: 12px;
}

.instruction-block {
  margin-bottom: 0;
}

.modal-panel h2,
.modal-high-scores-content h2 {
  font-size: 1.28rem !important;
  margin: 0 0 8px !important;
  color: #2b211c !important;
  font-weight: 800 !important;
}

.instruction-block h2,
.modal-instructions-content h2 {
  font-size: 1.55rem !important;
  margin: 0 0 10px !important;
  color: #000 !important;
  font-weight: 800 !important;
  letter-spacing: 0.01em;
}

.visual-instruction {
  margin-bottom: 8px;
}

.instructions-movement-text,
.modal-instructions-content .visual-instruction p {
  margin-left: 12px;
  color: #000 !important;
  font-weight: 800 !important;
  font-size: 1.12rem !important;
}

#arrow-keys-image {
  height: 56px;
}

.key-visual {
  width: 34px;
  height: 34px;
  font-size: 1.05rem;
  font-weight: 800;
  color: #000;
  background: #fff;
  border: 2px solid #111;
  border-radius: 6px;
}

.modal-instructions-content p {
  margin-bottom: 0;
  color: #000 !important;
  font-weight: 800 !important;
}

#start-game-button {
  display: block;
  margin: 4px auto 0;
  padding: 8px 22px;
  border: 0;
  border-radius: 8px;
  background: #5b4b49;
  color: #f7f1e6;
  font-weight: 700;
  cursor: pointer;
}

#shop-buttons {
  display: flex;
  gap: 10px;
  overflow: hidden;
}

#shop-buttons div {
  float: none;
  width: 25%;
  min-width: 0;
}

#shop-buttons div button {
  margin-bottom: 8px;
  width: 100%;
  border: 1px solid #3a2c24;
  border-radius: 10px;
  padding: 12px 8px;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
  background: #5b4b49;
  color: #f7f1e6;
  cursor: pointer;
  box-shadow: 0 3px 0 #3a2c24;
}

#shop-buttons div button:hover:not(:disabled) {
  background: #6d5a57;
  transform: translateY(-1px);
}

#shop-buttons div button:active:not(:disabled) {
  transform: translateY(2px);
  box-shadow: none;
}

#shop-buttons div button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

#shop-buttons img {
  margin-top: 4px;
  max-height: 52px;
  object-fit: contain;
}

#shop-buttons p {
  margin: 4px 0;
  font-size: 0.82rem;
  line-height: 1.2;
}

#shop-buttons .gold-text {
  color: #3d2a00 !important;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.shop-intro {
  margin: 0 28px 10px 0;
}

.shop-notice {
  margin-top: 8px;
  margin-bottom: 0;
}

.high-scores-list {
  min-height: 0;
  max-height: 42vh;
  overflow: auto;
  margin-bottom: 8px;
}

.modal-footnote {
  font-size: 0.85em;
  margin: 0;
  color: #5a4a40;
}

.submit-score-form {
  margin-top: 10px;
}

.submit-score-form input {
  border: 1px solid #c2b4a4;
  border-radius: 8px;
  background: #fff;
}

.high-scores-list ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: rank;
}

.high-scores-list li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0;
  padding: 8px 4px;
  border-bottom: 1px solid #ddd0c2;
  color: #3a2c24;
  font-size: 1.05em;
}

.high-scores-list li::before {
  counter-increment: rank;
  content: counter(rank);
  min-width: 1.4em;
  color: #8a6a2a;
  font-weight: 700;
}

.high-scores-list li:first-child::before,
.high-scores-list li:first-child .score-value {
  color: #b8860b;
}

.high-scores-list .score-name {
  flex: 1;
}

.high-scores-list .score-value {
  color: #8a6a2a;
  font-weight: 700;
}

.error-text {
  color: #b00020;
  text-align: center;
}

.status-text {
  text-align: center;
}

.shop-notice {
  text-align: center;
  font-style: italic;
  margin-top: 8px;
  color: #3a2c24;
  font-weight: 700;
}

#bottom-section {
  text-align: center;
  padding: 12px 0 20px;
}

.enemy-type-list {
  display: grid;
  gap: 10px;
}

.enemy-type-card {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
}

.enemy-type-card img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.enemy-type-card h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  color: #3a2c24;
}

.enemy-type-card p {
  margin: 0;
  color: #5a4a40;
  line-height: 1.35;
}

#modal-shop,
#modal-instructions,
#modal-high-scores,
#modal-submit-score,
#modal-enemy-types {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-color: rgba(28, 22, 20, 0.72);
}
