/* Download File | Action table (custom downloads layer, replaces Download Manager UI). */
.twem-dl-table {
	width: 100%;
	border-collapse: collapse;
	margin: 20px 0;
}
.twem-dl-table th {
	text-align: left;
	background: #eee;
	padding: 10px 14px;
	font-weight: 700;
	border-bottom: 1px solid #ddd;
}
.twem-dl-table td {
	padding: 14px;
	border-bottom: 1px solid #eee;
	vertical-align: middle;
}
.twem-dl-table .twem-dl-action {
	width: 180px;
}
/* `.elementor a.twem-dl-btn` (0,2,1) beats Elementor's global `.elementor a` link colour. */
.twem-dl-btn,
.elementor a.twem-dl-btn {
	display: inline-block;
	background: #3c9cac;
	color: #fff;
	text-decoration: none;
	padding: 10px 22px;
	font-weight: 700;
	letter-spacing: 0.03em;
	border-radius: 2px;
}
.twem-dl-btn:hover,
.elementor a.twem-dl-btn:hover {
	background: #2f7e8c;
	color: #fff;
}
.twem-dl-gate {
	margin: 20px 0;
	padding: 14px 18px;
	background: #f7f7f9;
	border: 1px solid #e1e1e8;
	border-radius: 3px;
}

/* Loop Grid pagination (archives) — boxed style ported from the old site: square cells,
   light-gray border/number, teal border+number for the current page and on hover. */
.elementor-pagination {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 6px;
	margin-top: 26px;
}
.elementor-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 34px;
	height: 34px;
	padding: 0 8px;
	border: 1px solid #e2e2e2;
	background: #fff;
	color: #b7b7b7;
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
	text-decoration: none;
	transition: color 0.15s, border-color 0.15s;
}
.elementor-pagination .page-numbers.current,
.elementor-pagination .page-numbers:hover {
	border-color: #3c9cac;
	color: #3c9cac;
}

/* Inline code / pre styling (ported from the old site). Scoped to Elementor content so it
   beats the theme reset (`code, kbd, samp`), which loads after this file. */
.elementor-element code,
.elementor-element pre {
	padding: 0 3px 2px;
	font-family: Monaco, Menlo, Consolas, "Courier New", monospace;
	font-size: 11px;
	color: #333333;
	border-radius: 3px;
}
.elementor-element code {
	padding: 2px 4px;
	color: #d14;
	background-color: #f7f7f9;
	border: 1px solid #e1e1e8;
	white-space: nowrap;
}

/* <hr> styling (ported from the old site). */
hr {
	clear: both;
	margin: 10px 0 30px !important;
	height: 0;
	border: solid #ddd;
	border-width: 1px 0 0;
}

/* Category landing: child-category image tiles (ported from Flatco category.php).
   Images are 120x60 sprites (normal | hover); hover shifts the background. */
.twem-cat-grid {
	display: flex;
	flex-wrap: wrap;
	gap: 28px 32px;
	margin: 24px 0 32px;
}
.twem-cat-tile {
	display: block;
	width: 90px;
	text-align: center;
	color: #2f2f2f;
	text-decoration: none;
	font-size: 14px;
	line-height: 1.3;
}
.twem-cat-tile:hover {
	color: #3c9cac;
}
.twem-cat-img {
	display: inline-block;
	width: 60px;
	height: 60px;
	background-repeat: no-repeat;
	background-position: 0 0;
	background-size: 120px 60px;
}
.twem-cat-tile:hover .twem-cat-img {
	background-position: -60px 0;
}
.twem-cat-name {
	display: block;
	margin-top: 8px;
}
/* (Term header icon + description are now the native Image + Text Editor widgets in the
   Archive template, fed by the "Term Icon" dynamic tag + Archive Description tag.) */
/* (Parent categories show BOTH the subcategory grid and their own direct-member posts,
   like the old site. Direct-member-only is enforced in PHP via include_children=false.) */
/* (Single-post category icon is now the native Image widget in the title row, fed by the
   "Term Icon" dynamic tag -> the post's last-category icon.) */
/* Downloads category list (replaces wpdm-archive plugin view) — 2-column icon list. */
.twem-dl-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 18px 40px;
	margin: 20px 0;
	max-width: 760px;
}
.twem-dl-item {
	display: flex;
	align-items: center;
	gap: 18px;
	color: #3c9cac;
	text-decoration: none;
	font-size: 17px;
}
.twem-dl-icon {
	flex: 0 0 auto;
	width: 56px;
	height: 56px;
	border: 1px solid #2f2f2f;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #2f2f2f;
	font-size: 22px;
}
.twem-dl-item:hover {
	color: #2f2f2f;
}
@media (max-width: 600px) {
	.twem-dl-grid { grid-template-columns: 1fr; }
}
/* Full-width pages: collapse the template's sidebar column, widen content to 100%.
   Direct-child combinators only — must NOT touch the page's own nested section columns. */
.twem-page-full .twem-with-sidebar > .elementor-container > .elementor-column:last-child {
	display: none;
}
.twem-page-full .twem-with-sidebar > .elementor-container > .elementor-column:first-child {
	width: 100% !important;
	max-width: 100% !important;
	flex: 0 0 100% !important;
}
/* Orphan <li> (legacy content whose <ul> wrapper was lost in migration, e.g. some FAQ tab
   bodies): render as a list item. Real lists are `ul > li`, so a `> li` direct child of a
   content/tab container is only ever an orphan — safe to target without touching real lists. */
.elementor-tab-content > li,
.elementor-widget-container > li,
.elementor-widget-theme-post-content > li {
	display: list-item;
	list-style: disc;
	margin-left: 1.2em;
}

/* Quicklinks sidebar list (ported from flatco #sidebar aside.widget ul li). */
.twem-sidebar ul {
	list-style: none;
	margin: 0 0 18px;
	padding: 0;
}
.twem-sidebar ul li {
	position: relative;
	margin: 0 15px 0 10px;
	padding: 10px 0 10px 20px;
	border-bottom: 1px dotted #d6d6d6;
}
.twem-sidebar ul li:before {
	position: absolute;
	left: 2px;
	top: 10px;
	color: #d6d6d6;
	content: "\e87d"; /* eicon-chevron-right (Elementor icon set) */
	font-family: "eicons";
	font-weight: normal;
	font-size: 11px;
	line-height: 25px;
}
.twem-sidebar ul li:last-child { padding-bottom: 4px; border-bottom: 0; }

/* Sidebar Quicklinks + category tiles: black links, teal on hover (flatco #sidebar a). */
.twem-sidebar a,
.twem-cat-tile,
.twem-cat-tile .twem-cat-name {
	color: #2f2f2f;
}
.twem-sidebar a:hover,
.twem-cat-tile:hover,
.twem-cat-tile:hover .twem-cat-name {
	color: #3c9cac;
}
