/*
 * Responsive layer for the fixed-width (982px) table layout.
 * Loaded after css/css.css on every page.
 */
html { -webkit-text-size-adjust: 100%; }
img, iframe, embed, object, video { max-width: 100%; }
img { height: auto; }
body { overflow-x: hidden; }

/* header: top links bar and menu (was a single table row) */
.toplink { text-align: center; padding: 4px 6px; line-height: 1.9; }
.toplink a { margin: 0 8px; white-space: nowrap; }
.top-menu { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 22px; max-width: 982px; margin: 0 auto; min-height: 40px; padding: 4px 8px; box-sizing: border-box; }
.top-menu .top_a { text-transform: uppercase; white-space: nowrap; }
.top-menu select { max-width: 100%; }

/* replaces the old remote banner image, which no longer exists */
.travel-banner { display: inline-block; padding: 10px 22px; border: 2px solid #fff; border-radius: 6px; background: rgba(0,0,0,.18); color: #fff; font: bold 22px Arial, Helvetica, sans-serif; text-decoration: none; }
.travel-banner span { display: block; font-size: 13px; font-weight: normal; margin-top: 3px; }
.travel-banner:hover { background: rgba(0,0,0,.3); }

.portal-blurbs { width: 192px; padding: 0 6px; text-align: justify; }
.portal-blurbs a { text-decoration: underline; }
.widget-frame { text-align: center; }
.gallery-grid { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-start; }
.gallery-grid > div { width: 150px; text-align: center; }
.page-content { overflow-wrap: break-word; }
.page-content table { max-width: 100%; }

@media (max-width: 1000px) {
	table[width="982"], table[width="990"], table[width="950"], table[width="760"], table[width="779"] {
		width: 100% !important;
	}
	.layout { width: 100% !important; }
	.rwd-header td[width="123"] { display: none; }
	.map-frame { width: 100%; height: 70vh; }
}

@media (max-width: 760px) {
	/* stack the left menu / content / right column */
	.layout, .layout > tbody, .layout > tbody > tr, .layout > tbody > tr > td,
	.layout > tr, .layout > tr > td {
		display: block;
		width: 100% !important;
		box-sizing: border-box;
	}
	.layout > tbody > tr > td.main-col, .layout > tr > td.main-col { order: -1; padding: 0 10px; }
	.layout > tbody > tr { display: flex; flex-direction: column; }
	.layout td { text-align: left; }

	.side-col, .side-col table, .side-col img { width: 100% !important; max-width: 420px; }
	.side-col { margin: 10px auto; }
	.side-right { text-align: center; }
	.side-right table { margin: 0 auto; }
	.portal-blurbs { width: auto; }

	.content-table, .content-table > tbody, .content-table > tbody > tr, .content-table > tbody > tr > td {
		display: block;
		width: auto !important;
		height: auto !important;
	}
	.content-table > tbody > tr > td[width="10"], .content-table > tbody > tr > td[width="11"],
	.content-table > tbody > tr > td[width="15"], .content-table > tbody > tr > td[height="35"]:first-child { display: none; }
	.content-table > tbody > tr { display: flex; flex-wrap: wrap; align-items: center; }
	.content-table > tbody > tr > td { flex: 1 1 100%; }
	.content-table > tbody > tr > td[width="5%"] { flex: 0 0 auto; }
	.content-table > tbody > tr > td[width="95%"] { flex: 1 1 0; }
	.page-content table, .page-content td, .page-content img { max-width: 100% !important; height: auto !important; }
	.page-content table[width] { width: 100% !important; }

	.rwd-header, .rwd-header tbody, .rwd-header tr, .rwd-header td { display: block; width: 100% !important; text-align: center !important; }
	.rwd-header img { max-width: 100%; }

	/* footer (incBottom.php) */
	table[width="990"] > tbody > tr > td > table[width="950"] > tbody > tr > td { display: block; width: 100% !important; }
	table[width="990"] > tbody > tr > td > table[width="950"] > tbody > tr { display: block; }
	table[width="990"] table { width: 100% !important; height: auto !important; }

	iframe[width="309"], iframe[style*="300px"] { width: 100% !important; }
	.map-frame { height: 60vh; }
	input[type="text"], input[type="email"], textarea, select { max-width: 100%; box-sizing: border-box; }
}
