/* ------------------------------
   Base Reset & Global Styles
------------------------------ */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'PersonaFont', 'Impact', sans-serif;
  color: #fff;
}

body {
  background: #1b0000;
  overflow: hidden;
  height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ------------------------------
   Status Bar & Title
------------------------------ */
#status-bar {
  position: relative;
  background: #2a0000;
  padding: 1rem 1rem 1rem 4rem;
  font-size: 1.4rem;
  font-weight: 700;
  text-transform: uppercase;
  text-shadow: 0 0 10px #ff2222;
  border-bottom: 2px solid #ff2222;
  display: flex;
  align-items: center;
  height: 60px;
  overflow: hidden;
}

#status-bar h1 {
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 1.4rem;
}

/* ☰ Menu Toggle Button */
#menu-toggle {
  position: absolute;
  top: 50%;
  left: 1rem;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #ff3333;
  font-size: 1.8rem;
  cursor: pointer;
  z-index: 999;
  transition: color 0.3s ease;
}

#menu-toggle:hover {
  color: #ff5555;
}

/* ------------------------------
   Container Layout
------------------------------ */
#container {
  flex: 1;
  display: flex;
  background: #000000ee;
  box-shadow: inset 0 0 80px #ff000033;
}

/* ------------------------------
   Side Menu (Selection Panel)
------------------------------ */
#side-menu {
  width: 350px;
  background: #330000dd;
  border-right: 3px solid #ff0000;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  transition: width 0.3s ease, opacity 0.3s ease;
}

#side-menu.closed {
  width: 0;
  opacity: 0;
  padding: 0;
  border: none;
  overflow: hidden;
}

/* ------------------------------
   Main Content Area
------------------------------ */
#main-content {
  flex: 1;
  background: #1f0000e0;
  margin: 1rem;
  border-radius: 20px;
  padding: 1rem;
  overflow-y: auto;
  box-shadow: inset 0 0 30px #ff000033;
  display: flex;
  flex-direction: column;
  transition: margin-left 0.3s ease, width 0.3s ease, flex 0.3s ease;
}

#main-content.expanded {
  margin-left: 1rem;
  width: auto;
  flex: 1 1 100%;
}

/* ------------------------------
   Buttons Between Title & Info
------------------------------ */
#buttons-container {
  display: flex;
  justify-content: space-between;
  margin: 1rem 0;
  gap: 1rem;
}

.button {
  flex: 1;
  background: #ff0000;
  border: none;
  color: #fff;
  padding: 1rem 0;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 1.1rem;
  border-radius: 8px;
  box-shadow: 0 0 8px #ff0000bb;
  cursor: pointer;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.button:hover {
  background: #ff4444;
  box-shadow: 0 0 14px #ff4444cc;
}

/* ------------------------------
   Palace Selection Buttons
------------------------------ */
#palace-select button {
  width: 100%;
  margin-bottom: 0.6rem;
  font-weight: 600;
  font-size: 1rem;
}

/* ------------------------------
   Screens (Palace, Targets, Maps)
------------------------------ */
.screen {
  flex: 1;
  overflow-y: auto;
  margin-top: 1rem;
}

.screen.hidden {
  display: none;
}

.screen.active {
  display: block;
}

/* Palace Info */
#palace-map {
  font-size: 1rem;
}

#palace-title {
  font-weight: 800;
  font-size: 1.4rem;
  margin-bottom: 0.6rem;
  text-shadow: 0 0 10px #ff0000aa;
}

#palace-info {
  line-height: 1.5;
}

/* Target Info */
#target-info {
  font-size: 1.2rem;
  padding: 1rem;
  background: #220000bb;
  border-radius: 12px;
  box-shadow: inset 0 0 20px #ff0000cc;
}

/* Maps Info */
#maps-info {
  font-size: 1.2rem;
  padding: 1rem;
  background: #220000bb;
  border-radius: 12px;
  box-shadow: inset 0 0 20px #ff0000cc;
}

/* ------------------------------
   Scrollbar Styling
------------------------------ */
#side-menu::-webkit-scrollbar,
#main-content::-webkit-scrollbar {
  width: 8px;
}

#side-menu::-webkit-scrollbar-thumb,
#main-content::-webkit-scrollbar-thumb {
  background-color: #ff000088;
  border-radius: 4px;
}

/* ------------------------------
   Responsive Tweaks
------------------------------ */
@media (max-width: 500px) {
  #status-bar {
    padding-left: 4rem;
    font-size: 1.2rem;
  }

  #menu-toggle {
    font-size: 1.6rem;
    left: 12px;
  }
}