/* Building Availability Map — Frontend styles
 *
 * ---------------------------------------------------------------------------
 * THEMING / OVERRIDE GUIDE
 * ---------------------------------------------------------------------------
 * The floor list rows carry NO background and NO border by default — hover
 * and active state are communicated purely by a text-color change, exactly
 * like a simple text link. Nothing to fight, nothing to override.
 *
 * Everything else (muted labels, placeholder text) uses `color: inherit`
 * and `color-mix(in srgb, currentColor X%, transparent)` rather than a fixed
 * grey, so it adapts automatically to whatever text color you set on your
 * own column class — light theme, dark theme, anything.
 *
 * To override further, target your own column class (assigned in Map
 * Settings > Layout, or via the col1_class/col2_class/col3_class shortcode
 * attributes) and set any of these custom properties:
 *
 *   --bam-row-active-color    Row/floor-list-item hover & active TEXT color
 *                             (settable in Map Settings > Floors Table, no
 *                             code required — this is just the escape hatch)
 *   --bam-accent              Primary accent (buttons, focus ring, active shape)
 *   --bam-accent-dark         Accent hover/darker shade
 *   --bam-status-available-bg / -color   "Available" status pill
 *   --bam-status-leased-bg    / -color   "Leased" status pill
 *   --bam-status-reserved-bg  / -color   "Reserved" status pill
 *
 * Example:
 *   .my-list-col {
 *     color: #333;
 *     --bam-row-active-color: #c9a24b;
 *   }
 * ---------------------------------------------------------------------------
 */

.bam-map {
	--bam-text: #1a2333;
	--bam-muted: #5b6577;
	--bam-border: #e3e8f0;
	--bam-bg: #ffffff;
	--bam-bg-soft: #f7f9fc;
	--bam-accent: #A1D6C3;
	--bam-accent-dark: #0b3d6f;
	--bam-radius: 12px;
	--bam-download: #85A5B5;

	color: var(--bam-text);
	font-size: 16px;
	line-height: 1.5;
	box-sizing: border-box;
}

.bam-map *,
.bam-map *::before,
.bam-map *::after {
	box-sizing: border-box;
}

/* ---------- 3-column grid (desktop) ---------- */
.bam-grid {
	display: grid;
	/* Fallback ratio; overridden per-instance by the Layout settings (Map Settings > Layout). */
	grid-template-columns: minmax(200px, 40fr) minmax(200px, 25fr) minmax(200px, 35fr);
	gap: 28px;
	align-items: start;
}

/* Floor-list column hidden: map + details only (fallback; the inline style
   from the shortcode drives the real ratio). */
.bam-grid[data-cols="2"] {
	grid-template-columns: minmax(200px, 50fr) minmax(200px, 50fr);
}

/* .bam-col intentionally carries no visual styling (background/border/radius/
   padding) — it's a bare layout container. Style each column yourself using
   .bam-col-map / .bam-col-list / .bam-col-details, or assign your own class
   per column in Map Settings > Layout. */

/* ---------- Column 1: map ---------- */
.bam-map-stage {
	position: relative;
	width: 100%;
	border-radius: 8px;
	overflow: hidden;
	line-height: 0;
	font-size: 0;
}

.bam-map-stage img,
.bam-map-svg image {
	image-rendering: crisp-edges;
}

.bam-map-svg {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	display: block;
	shape-rendering: crispEdges;
}

.bam-map-svg polygon {
	shape-rendering: crispEdges;
}

/* Each region (a suite, or a whole floor) is a <g class="bam-region">
   containing two stacked polygons: the default (resting) fill and the hover
   fill. Hovering cross-fades between them by animating opacity, so
   gradient-to-gradient transitions stay soft. Regions are independently
   hoverable — hovering one suite does not affect its neighbours. */
.bam-region {
	cursor: pointer;
	outline: none;
}

.bam-polygon {
	transition: opacity 0.35s ease;
}

.bam-polygon-default {
	fill: transparent;
	opacity: 0.55;
}

.bam-polygon-hover {
	opacity: 0;
}

.bam-region:hover .bam-polygon-default,
.bam-region:focus-visible .bam-polygon-default,
.bam-region.is-hover .bam-polygon-default,
.bam-region.is-active .bam-polygon-default {
	opacity: 0;
}

.bam-region:hover .bam-polygon-hover,
.bam-region:focus-visible .bam-polygon-hover,
.bam-region.is-hover .bam-polygon-hover,
.bam-region.is-active .bam-polygon-hover {
	opacity: 0.88;
}

.bam-region:focus-visible .bam-polygon-hover {
	stroke: #ffffff;
	stroke-width: 1.2;
	vector-effect: non-scaling-stroke;
}

/* ---------- Column 2: list ---------- */
.bam-list {
	display: flex;
	flex-direction: column;
}

.bam-list-head {
	display: grid;
	grid-template-columns: 1.2fr 1fr 0.9fr;
	gap: 8px;
	padding: 0 10px 10px;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: color-mix(in srgb, currentColor 65%, transparent);
}

.bam-list-body {
	max-height: 520px;
	overflow-y: auto;
}

.bam-row {
	display: grid;
	grid-template-columns: 1.2fr 1fr 0.9fr;
	gap: 8px;
	align-items: center;
	width: 100%;
	padding: 14px 10px;
	background: transparent;
	border: 0;
	text-align: left;
	cursor: pointer;
	font-size: 15px;
	font-family: inherit;
	color: inherit;
	transition: color 0.15s ease;
}

.bam-row:hover,
.bam-row.is-hover,
.bam-row.is-active {
	color: var(--bam-row-active-color, var(--bam-accent));
}

.bam-row:focus-visible {
	outline: 2px solid var(--bam-accent);
	outline-offset: -2px;
}

.bam-row-name {
	font-weight: 600;
	color: inherit;
}

.bam-row-size {
	color: color-mix(in srgb, currentColor 65%, transparent);
}

.bam-row-status {
	justify-self: start;
	padding: 3px 10px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

.bam-status-available { background: var(--bam-status-available-bg, #e6f4ec); color: var(--bam-status-available-color, #1e8e4e); }
.bam-status-leased    { background: var(--bam-status-leased-bg, #e8eef7); color: var(--bam-status-leased-color, #1d70b8); }
.bam-status-reserved  { background: var(--bam-status-reserved-bg, #fdf1e0); color: var(--bam-status-reserved-color, #b26a00); }

/* ---------- Column 3: details ---------- */
.bam-details-placeholder {
	text-align: center;
	padding: 40px 16px;
	color: color-mix(in srgb, currentColor 65%, transparent);
}

.bam-details-placeholder h3 {
	margin: 0 0 8px;
	color: inherit;
	font-size: 18px;
}

.bam-details-content[hidden] {
	display: none;
}

.bam-details-title , .bam-details-suite-line{
	margin: 0 0 6px;
	font-size: 22px;
	line-height: 1.25;
	color: #002458;
	    font-family: Koulen;
}

.bam-details-size {
	display: inline;
	margin: 0;
	color: #002458;
	font-weight: 400;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	font-size: 22px;
	    font-family: Koulen;
}

.bam-details-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	margin: 0 0 4px;
}

/* Parent-floor label shown under a suite's name. */
.bam-details-floor {
	margin: 0 0 14px;
	font-size: 18px;
	color: #A1D6C3;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	font-weight: 400;
	    background: #19365d;
    width: 94px;
    padding: 5px 7px;
    text-align: center;
	font-family: Koulen;
}

.bam-details-desc {
	margin: 0 0 16px;
	color: inherit;
	white-space: pre-line;
}

.bam-details-image {
	width: 100%;
	height: auto;
	border-radius: 8px;
	margin-bottom: 16px;
	display: block;
	background: var(--bam-bg-soft);
}

.bam-details-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

/* Buttons are fully self-styled with !important on the layout-critical
   properties so a theme's global `a` / `.uk-button` rules can't blow up the
   size or push the label to the top. Do NOT add uk-button classes to these. */
.bam-btn {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: auto !important;
	max-width: 100%;
	padding: 12px 18px !important;
	border-radius: 8px;
	background: var(--bam-accent);
	color: #ffffff;
	text-decoration: none !important;
	font-weight: 600;
	font-size: 15px;
	line-height: 1.4 !important;
	border: 1px solid var(--bam-accent);
	box-shadow: none;
	transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.bam-btn:hover,
.bam-btn:focus-visible {
	background: var(--bam-accent-dark);
	border-color: var(--bam-accent-dark);
	color: #ffffff;
}

.bam-btn-ghost {
	background: var(--bam-accent);
	color: #002458;
	border: 1px solid #A1D6C3;
	border-radius: 0 !important;
}
.bam-btn-download {
	background: #002458;
	color: var(--bam-download);
	border: 1px solid #002458;
	border-radius: 0 !important;
}
.bam-btn-download:hover,
.bam-btn-download:focus-visible {
	background: color-mix(in srgb, var(--bam-accent) 12%, transparent);
	color: var(--bam-accent-dark);
	border-color: var(--bam-accent-dark);
}

.bam-btn-ghost:hover,
.bam-btn-ghost:focus-visible {
	background: color-mix(in srgb, var(--bam-accent) 12%, transparent);
	color: var(--bam-accent-dark);
	border-color: var(--bam-accent-dark);
}

/* ---------- Accordion (mobile only) ---------- */
.bam-accordion {
	display: none;
}

.bam-empty {
	padding: 40px;
	text-align: center;
	color: color-mix(in srgb, currentColor 65%, transparent);
	background: var(--bam-bg);
	border: 1px dashed var(--bam-border);
	border-radius: var(--bam-radius);
}

/* ---------- Responsive: mobile ---------- */
@media (max-width: 767px) {
	.bam-grid {
		display: block;
	}

	.bam-col-list,
	.bam-col-details {
		display: none;
	}

	.bam-accordion {
		display: block;
		margin-top: 20px;
	}

	.bam-map-stage {
		border: 1px solid var(--bam-border);
		background: var(--bam-bg);
		border-radius: var(--bam-radius);
	}

	.bam-acc-item {
		background: var(--bam-acc-bg, var(--bam-bg));
		border: 1px solid var(--bam-border);
		border-radius: 10px;
		margin-bottom: 12px;
		overflow: hidden;
	}

	.bam-acc-head {
		display: flex;
		align-items: center;
		gap: 12px;
		width: 100%;
		padding: 16px;
		background: transparent;
		border: 0;
		text-align: left;
		cursor: pointer;
		font-size: 16px;
		font-family: inherit;
		color: inherit;
	}

	.bam-acc-head:focus-visible {
		outline: 2px solid var(--bam-accent);
		outline-offset: -2px;
	}

	.bam-acc-title {
		font-weight: 600;
		flex: 1;
	}

	.bam-acc-meta {
		color: color-mix(in srgb, currentColor 65%, transparent);
		font-size: 13px;
	}

	.bam-acc-icon {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		color: color-mix(in srgb, currentColor 65%, transparent);
		transition: transform 0.18s ease;
	}

	.bam-acc-item.is-open .bam-acc-icon {
		transform: rotate(180deg);
	}

	.bam-acc-panel[hidden] {
		display: none;
	}

	.bam-acc-panel-inner {
		padding: 4px 16px 20px;
	}

	.bam-acc-item.is-flash {
		box-shadow: 0 0 0 3px var(--bam-accent);
	}
}
@media (max-width: 767px) {
    .bam-acc-title, .bam-acc-meta {
        color: #fff;
    }
	.bam-acc-panel-inner{background:#fff;}
	.bam-acc-icon{color:rgb(161, 214, 195);}
}