/* AMA member documents — in-page modal viewer (member-docs modal JS). */

.ama-doc-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
}

.ama-doc-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(20, 14, 6, 0.72);
}

.ama-doc-modal-panel {
	position: absolute;
	inset: 3vh 3vw;
	display: flex;
	flex-direction: column;
	background: #f7f1e3;
	border: 1px solid #a98d5f;
	border-radius: 4px;
	box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
	overflow: hidden;
}

.ama-doc-modal-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 8px 16px;
	background: #2b2013;
	border-bottom: 2px solid #a98d5f;
}

.ama-doc-modal-title {
	margin: 0;
	font-family: "IM Fell English", "Brothers Regular Alt", serif;
	font-size: 0.9375rem;
	font-weight: normal;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: #e9dcc7;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ama-doc-modal-actions {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-shrink: 0;
}

/* Buttons read as menu items: IM Fell English, uppercase, cream, gold
 * hover (ama-chrome.css submenu treatment — no boxes, just color shift). */
.ama-doc-modal-download,
.ama-doc-modal-close {
	display: inline-block;
	padding: 10px 14px;
	background: transparent;
	border: 0;
	border-radius: 0;
	color: #e9dcc7;
	font-family: "IM Fell English", "Brothers Regular Alt", serif;
	font-size: 0.8125rem;
	line-height: 1.2;
	letter-spacing: 1px;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
	transition: color 0.2s ease-out, background 0.2s ease-out;
}

.ama-doc-modal-download:hover,
.ama-doc-modal-download:focus,
.ama-doc-modal-close:hover,
.ama-doc-modal-close:focus {
	color: #d8aa57;
	background: rgba(216, 170, 87, 0.08);
	outline: none;
}

.ama-doc-modal-frame {
	flex: 1;
	width: 100%;
	border: 0;
	background: #5b4a33;
}

@media (max-width: 640px) {
	.ama-doc-modal-panel {
		inset: 2vh 2vw;
	}

	.ama-doc-modal-head {
		flex-wrap: wrap;
	}

	.ama-doc-modal-frame {
		min-height: 55vh;
	}
}
