/*
 * The Region Table of Contents — frontend styles.
 * Scoped to Flex Blocks carrying the `aim-toc-flex` class so native TagDiv
 * Flex Blocks remain unaffected.
 */

/* -------------------------------------------------------------------------
 * Dynamic Full TOC issue title
 * Figma: Bebas Neue / 40px / 400 / 100% / #231F20
 * ---------------------------------------------------------------------- */

.aim-issue-toc-title {
	display: block;
	font-family: "Bebas Neue", sans-serif;
	font-size: 40px;
	font-weight: 400;
	font-style: normal;
	line-height: 1;
	letter-spacing: 0;
	color: #231F20;
}


/* -------------------------------------------------------------------------
 * Shared TOC link / markup helpers
 * ---------------------------------------------------------------------- */

.aim-toc-flex .toc-main-link {
	display: block;
	color: inherit;
	text-decoration: none;
}

.aim-toc-flex .toc-main-link:hover,
.aim-toc-flex .toc-main-link:focus {
	color: inherit;
	text-decoration: none;
}

.aim-toc-flex .toc-meta {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
}


/* -------------------------------------------------------------------------
 * TOC title status icons — Print-only / Audio
 *
 * Icons live inside the native TagDiv heading so the title remains controlled
 * by Flex Block typography settings. 1em keeps both icons proportional to the
 * title size in every TOC layout.
 * ---------------------------------------------------------------------- */

.aim-toc-flex .aim-toc-item .entry-title .toc-status-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1em;
	height: 1em;
	margin-left: 0.45em;
	line-height: 1;
	vertical-align: -0.12em;
}

.aim-toc-flex .aim-toc-item .entry-title .toc-status-icon img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: contain;
}


/* -------------------------------------------------------------------------
 * TOC item typography — standard online item
 * Figma: Mona Sans / 16px / 120%
 * ---------------------------------------------------------------------- */

/* Orange editorial / intro line. */

.aim-toc-flex .aim-toc-item .toc-intro {
	font-family: "Mona Sans", sans-serif;
	font-size: 16px;
	font-weight: 600;
	font-style: normal;
	line-height: 1.2;
	letter-spacing: 0;
	color: #FDA100;
	margin-bottom: 2px;
}


/* Supporting subtitle below the intro line. */

.aim-toc-flex .aim-toc-item .toc-subtitle {
	font-family: "Mona Sans", sans-serif;
	font-size: 16px;
	font-weight: 600;
	font-style: normal;
	line-height: 1.2;
	letter-spacing: 0;
	color: #858585;
	margin-bottom: 2px;
}


/* Reading time. */

.aim-toc-flex .aim-toc-item .toc-readtime {
	font-family: "Mona Sans", sans-serif;
	font-size: 16px;
	font-weight: 400;
	font-style: normal;
	line-height: 1.2;
	letter-spacing: 0;
	color: #858585;
}

/* -------------------------------------------------------------------------
 * Full TOC popup — fixed Order your copy button
 * ---------------------------------------------------------------------- */

.aim-toc-order-copy {
	position: fixed !important;
	right: 28px;
	bottom: 22px;
	z-index: 9999;
	width: auto !important;
	margin: 0 !important;
}

.aim-toc-order-copy a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: auto;
}

/* -------------------------------------------------------------------------
 * Full TOC popup — mobile
 * ---------------------------------------------------------------------- */

@media (max-width: 767px) {

	/* Mobile TOC typography */
	.aim-toc-flex .aim-toc-item .toc-intro,
	.aim-toc-flex .aim-toc-item .toc-subtitle,
	.aim-toc-flex .aim-toc-item .toc-readtime {
		font-size: 14px !important;
	}

	/* Mobile TOC status icons — Audio / Lock */
	.aim-toc-flex .aim-toc-item .entry-title .toc-status-icon {
		width: 16px !important;
		height: 16px !important;
		flex: 0 0 16px !important;
		margin-left: 6px;
		vertical-align: -1px;
	}

    .aim-toc-flex .aim-toc-item .entry-title .toc-status-icon img {
        display: block;
        width: 20px !important;
        height: 20px !important;
        min-width: 20px !important;
        max-width: 20px !important;
        min-height: 20px !important;
        max-height: 20px !important;
        object-fit: contain;
    }

	/* Fixed Order your copy button inside Full TOC popup */
	.tdm-popup-modal-wrap:has(.aim-toc-flex) .aim-toc-order-copy {
		position: fixed !important;
		left: 16px !important;
		right: 16px !important;
		bottom: max(16px, env(safe-area-inset-bottom));
		width: auto !important;
		max-width: none !important;
		margin: 0 !important;
		transform: none !important;
		box-sizing: border-box;
		z-index: 9999;
	}

	.tdm-popup-modal-wrap:has(.aim-toc-flex) .aim-toc-order-copy a {
		display: flex !important;
		align-items: center;
		justify-content: center;
		width: 100% !important;
		max-width: none !important;
		box-sizing: border-box;
	}

	/* Reserve space so the fixed CTA does not cover the final TOC item. */
	.tdm-popup-modal-wrap:has(.aim-toc-flex) .tdm-pm-body {
		padding-bottom: calc(90px + env(safe-area-inset-bottom)) !important;
	}
  
  .aim-toc-order-copy {
		position: fixed !important;
		bottom: 12px;
		z-index: 99999999999 !important;
		width: 100% !important;
		margin: 0 !important;
		right: 2px;
	}

	.aim-toc-order-copy a {
		display: flex !important;
		align-items: center;
		justify-content: center;
		width: 100% !important;
		text-align: center !important;
	}
  
  /* Mobile Full TOC title */
.aim-issue-toc-title {
	font-size: 34px !important;
	line-height: 1 !important;
	padding-right: 38px;
	display: block;
	width: 100%;
	max-width: 100%;

	white-space: normal !important;
	word-break: normal !important;
	overflow-wrap: normal !important;
}
  
}
