.grid-wrapper {
	width: 100%;
	max-width: 90vmin;
	margin: 0 auto;
	position: relative;
	padding: 2vw;
    	background: #313030;
}

.grid-positioning {
	position: relative;
	fit: content;
}

.grid {
	display: grid;
	width: 100%;
	aspect-ratio: 1/1;
	background-image: linear-gradient(#212529 1px, transparent 1px),
		linear-gradient(90deg, #212529 1px, transparent 1px);
	/*background-size: calc(100% / 20) calc(100% / 20);  20x20 grid */
	background-position: top left;
	background-repeat: repeat;
	position: relative;
}

.overlay-box {
  position: absolute;
  top: 0;
  left: 0;
  background: #313030;
  padding-right: 10px;
  color: #ffd826;
  font-family: 'Red Hat Mono', monospace;
  font-size: calc(1.5vmin)!important;
  pointer-events: none; /* optional: allows clicks to pass through */
  z-index: 10;
}

.overlay-box-right {
    left: auto;
    right: 0;
}

.options-box-right {
	margin-left: 10%;
}

.grid-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
}
.v-line {
  position: absolute;
  width: 2px;
  background-color: #ff730f;
}
.h-line {
  position: absolute;
  height: 2px;
  background-color: #ff730f;
}

.xv-line {
  position: absolute;
  width: 0;
  border-left: 2px dashed #ff160b;
}
.xh-line {
  position: absolute;
  height: 0;
  border-top: 2px dashed #ffd826;
}

.grid .a-letter, .grid .q-letter {
	width: 100%;
	height: 100%;
	/*border: 0.5px solid black;  <- Make sure normal inputs always have a visible border */
	border: 0.5px solid rgba(0, 0, 0, 0.5);
	aspect-ratio: 1/1;
	box-sizing: border-box;
	text-align: center;
	padding: 0;
	margin: 0;
	outline: none;
	border-radius: 0;
	font-family: 'Red Hat Mono', monospace;
	text-transform: uppercase;
	background-color: white;
	caret-color: transparent;
	color: black;
	display: flex;
	justify-content: center;
	align-items: center;
}

/* Void (invisible) cells */
.grid .void {
/* 	background-color: #212529; */
	background-color: #313030;
	pointer-events: none;
	border: none; /* <- Remove border on black squares */
}

/* Blank main grid cells */
.grid .a-blank {
	background-color: black;
	pointer-events: none;
	border: none; /* <- Remove border on black squares */
}

/* question cells */
.grid .q-letter, .grid .q-void {
	background-color: #ffd826;
	/* 	pointer-events: none; */
	border: none; /* <- Remove border on black squares */
	cursor: pointer;
}

/* .grid .q-letter.divider, .grid .q-void.divider {
	border-right: 1px solid #00000060;
} */

.grid .q-strike {
	background-color: #4CAF50 !important;
	color: #ffffff80;
}

.s-strike {
	background-color: #348737 !important;
	color: #ffffff80 !important;
}

/* .grid .q-strike.divider {
	border-right: 1px solid #00000060;
} */

.q-void .a-strike {
	pointer-events: none;
	
}

.grid .q-clue {
	background-color: #ff8040;
}

.grid .q-clue-adj {
	background-color: #cdcdcd;
}

/* Focus and blank styles */
.live-cell {
	background-color: #fcf380 !important;
}

.popover {
	color: #ffd826 !important;
	background-color: #000 !important;
	z-index: 9999 !important;
}

.popover .popover-body {
	color: ##ffd826 !important;
}

.correct {
	color: #4CAF50 !important;
}

.options-checkbox {
	display: flex;
	align-items: center;
    	gap: 8px;
    	max-width: 100%;
/*     	margin-top: 5px; */
}

#popup-open {
	pointer-events: auto;
    	background-color: #313030;
    	border: 0px;
}

svg {
    /* width: 1vw;
    height: 1vw; */
    min-height: 10px;
    min-width: 10px;
    max-height: 10px;
    max-width: 10px;
}

svg {
	fill: #ffd826;
}

.mudl-logo {
	max-width: 80%;
	height:auto;
}

.nda {
	padding: 20px;
}

@media (min-width: 576px) {
	
	.overlay-box {
		font-size: 8px;
	}
}

@media (min-width: 768px) {
	
	svg {
    		width: 1vw;
    		height: 1vw;
    		min-height: 20px;
    		min-width: 20px;
}
	
	.overlay-box {
		font-size: 11px;
	}
}

@media (min-width: 992px) {
	
	.overlay-box {
		font-size: 12px;
	}

	.nda {
		padding: 40px;
	}
}

@media (min-width: 1200px) {
	
	.overlay-box {
		font-size: 12px;
	}
}


#options-popup {
    display: none;
    position: absolute; /* or static, depending on your puzzle */
    left: 0;
    top: 0;
    width: 90vw;
    max-width: 600px;
    margin: 1rem auto;
    background: white;
    border: 2px solid #444;
    padding: 1rem;
    z-index: 9999;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

#popup-open {
    position: relative;
    z-index: 9999;
    touch-action: manipulation; /* Hint to browser this is tap */
    min-width: 44px; /* Big enough for mobile */
    min-height: 44px;
}