/* Global Styles - Enhanced for cross-platform compatibility */
html {
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch; /* iOS smooth scrolling */
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Courier New', Courier, monospace;
  background-color: #111;
  color: white;
  min-height: 100vh;
  min-height: 100dvh; /* Dynamic viewport height for mobile */
  width: 100%;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  position: relative;
  padding: 20px 0;
  box-sizing: border-box;
}

/* Jail Cell Bars - Enhanced for all platforms */
.bars-overlay {
  position: fixed; /* Changed from absolute to fixed for better consistency */
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh; /* Dynamic viewport height */
  background-image: repeating-linear-gradient(
    to right,
    rgba(255, 255, 255, 0.1) 0px,
    rgba(255, 255, 255, 0.1) 6px,
    transparent 6px,
    transparent 30px
  );
  pointer-events: none;
  z-index: 10;
}

/* Content Styling - Enhanced for all platforms */
main {
  z-index: 20;
  text-align: center;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
  position: relative; /* Ensure proper stacking context */
  min-height: auto; /* Allow natural height */
}

/* Title and Counter */
h1 {
  font-size: 2rem;
  margin-bottom: 10px;
  letter-spacing: 2px;
}

#counter {
  font-size: 4rem;
  margin-bottom: 20px;
  color: #ff1100;
}

/* Centered Image */
#incident-photo {
  max-width: 100%;
  height: auto;
  max-height: 60vh;
  border: 2px solid gray;
  margin: 20px 0;
}

/* Hidden Reset Button */
#reset-button {
  display: none;
  padding: 10px 20px;
  font-size: 1rem;
  background: red;
  border: none;
  color: white;
  cursor: pointer;
}
