/* ============================================================
   2tentech blog cards
   Consistent 16:9 media, light branded fallback covers, 3-column
   archive grid, clamped titles/excerpts. Loads after the parent
   propharm stylesheet.
   ============================================================ */

/* --- Grid: 3 columns on desktop (with or without sidebar), 2 on
       tablet, 1 on mobile. Parent already gives 1 col <768 and
       2 cols at 768+. --- */
@media only screen and (min-width: 1200px) {
	.sidebar-active.grid .only-posts.tt-cards {
		grid-template-columns: repeat(3, 1fr);
	}
}

/* --- Card shell --- */
.tt-cards .post .post-inner {
	display: flex;
	flex-direction: column;
	height: 100%;
}

.tt-cards .post .post-body {
	display: flex;
	flex: 1 1 auto;
	padding: 18px 0 0 0;
}

.tt-cards .post .post-body-inner {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	width: 100%;
}

/* --- Media area: fixed 16:9, no layout shift --- */
.tt-card-media {
	position: relative;
	aspect-ratio: 16 / 9;
	border-radius: 10px;
	overflow: hidden;
	background: #FAFAFA;
}

.tt-card-media .tt-media-link {
	position: absolute;
	inset: 0;
	display: block;
	line-height: 0;
}

.tt-card-media img.tt-thumb {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	z-index: 2;
	transition: transform 0.4s ease;
}

.tt-card:hover .tt-card-media img.tt-thumb {
	transform: scale(1.04);
}

/* Broken image URL: hide the img, the branded cover shows through. */
.tt-card-media.tt-img-broken img.tt-thumb {
	display: none;
}

/* --- Date badge --- */
.tt-date {
	position: absolute;
	top: 14px;
	left: 14px;
	z-index: 3;
	display: flex;
	flex-direction: column;
	align-items: center;
	background: #15a9e3;
	color: #FFFFFF;
	border-radius: 8px;
	padding: 7px 10px 6px;
	line-height: 1.1;
	font-family: 'PT Sans', sans-serif;
	box-shadow: 0 2px 6px rgba(24, 67, 99, 0.22);
	pointer-events: none;
}

.tt-date-day {
	font-size: 16px;
	font-weight: 700;
}

.tt-date-month {
	font-size: 10px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

/* --- BrandedBlogCover: light editorial fallback --- */
.tt-cover {
	position: absolute;
	inset: 0;
	z-index: 1;
	display: flex;
	align-items: flex-end;
	overflow: hidden;
	text-align: left;
}

.tt-cover-rail {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 6px;
	z-index: 2;
}

.tt-cover-body {
	position: relative;
	z-index: 2;
	display: block;
	padding: 0 24px 20px 24px;
	max-width: 78%;
}

.tt-cover-eyebrow {
	display: block;
	font-family: 'PT Sans', sans-serif;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.18em;
	line-height: 1;
	margin-bottom: 9px;
}

.tt-cover-topic {
	display: block;
	font-family: 'PT Sans', sans-serif;
	font-size: 24px;
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: 0.02em;
	color: #0F0D3F;
}

.tt-cover-dash {
	display: block;
	width: 36px;
	height: 4px;
	border-radius: 2px;
	margin-top: 11px;
}

/* Decorative geometry (kept subtle) */
.tt-cover-rings {
	position: absolute;
	top: -55px;
	right: -55px;
	width: 190px;
	height: 190px;
	border-radius: 50%;
	border: 1.5px solid currentColor;
	opacity: 0.3;
	z-index: 1;
}

.tt-cover-rings::before {
	content: "";
	position: absolute;
	inset: 26px;
	border-radius: 50%;
	border: 1.5px solid currentColor;
}

.tt-cover-rings::after {
	content: "";
	position: absolute;
	inset: 52px;
	border-radius: 50%;
	border: 1.5px solid currentColor;
}

.tt-cover-dots {
	position: absolute;
	right: 22px;
	bottom: 18px;
	width: 84px;
	height: 40px;
	background-image: radial-gradient(currentColor 1.5px, transparent 1.6px);
	background-size: 12px 12px;
	opacity: 0.22;
	z-index: 1;
}

/* --- Family palettes (light tints + division accents) --- */
.tt-cover--optima { background: linear-gradient(135deg, #F7E8F8 0%, #FDF6FE 55%, #FFFFFF 100%); }
.tt-cover--optima .tt-cover-rail { background: linear-gradient(90deg, #86198F, #A21CAF, #C026D3); }
.tt-cover--optima .tt-cover-eyebrow { color: #A21CAF; }
.tt-cover--optima .tt-cover-dash { background: #C026D3; }
.tt-cover--optima .tt-cover-rings,
.tt-cover--optima .tt-cover-dots { color: #A21CAF; }

.tt-cover--proxima { background: linear-gradient(135deg, #E4F4FD 0%, #F2FAFE 55%, #FFFFFF 100%); }
.tt-cover--proxima .tt-cover-rail { background: linear-gradient(90deg, #0EA5E9, #FACC15); }
.tt-cover--proxima .tt-cover-eyebrow { color: #0EA5E9; }
.tt-cover--proxima .tt-cover-dash { background: #0EA5E9; }
.tt-cover--proxima .tt-cover-rings,
.tt-cover--proxima .tt-cover-dots { color: #0EA5E9; }

.tt-cover--axiom { background: linear-gradient(135deg, #EDE7FB 0%, #F6F3FD 55%, #FFFFFF 100%); }
.tt-cover--axiom .tt-cover-rail { background: #6D28D9; }
.tt-cover--axiom .tt-cover-eyebrow { color: #6D28D9; }
.tt-cover--axiom .tt-cover-dash { background: #6D28D9; }
.tt-cover--axiom .tt-cover-rings,
.tt-cover--axiom .tt-cover-dots { color: #6D28D9; }

.tt-cover--maxima { background: linear-gradient(135deg, #E2F9FD 0%, #F0FCFE 55%, #FFFFFF 100%); }
.tt-cover--maxima .tt-cover-rail { background: linear-gradient(90deg, #22D3EE, #0EA5E9); }
.tt-cover--maxima .tt-cover-eyebrow { color: #0EA5E9; }
.tt-cover--maxima .tt-cover-dash { background: #22D3EE; }
.tt-cover--maxima .tt-cover-rings,
.tt-cover--maxima .tt-cover-dots { color: #0EA5E9; }

.tt-cover--learn { background: linear-gradient(135deg, #ECE6FB 0%, #F5F2FD 55%, #FFFFFF 100%); }
.tt-cover--learn .tt-cover-rail { background: linear-gradient(90deg, #7C3AED, #22D3EE); }
.tt-cover--learn .tt-cover-eyebrow { color: #7C3AED; }
.tt-cover--learn .tt-cover-dash { background: #7C3AED; }
.tt-cover--learn .tt-cover-rings,
.tt-cover--learn .tt-cover-dots { color: #7C3AED; }

.tt-cover--parent { background: linear-gradient(135deg, #FAFAFA 0%, #FDFDFD 55%, #FFFFFF 100%); }
.tt-cover--parent .tt-cover-rail { background: linear-gradient(90deg, #0F0D3F, #FB830C); }
.tt-cover--parent .tt-cover-eyebrow { color: #FB830C; }
.tt-cover--parent .tt-cover-dash { background: #FB830C; }
.tt-cover--parent .tt-cover-rings,
.tt-cover--parent .tt-cover-dots { color: #FB830C; }

/* --- Category chips --- */
.tt-cards .post .post-categories.tt-chips {
	margin-bottom: 10px;
}

.tt-cards .post .post-categories.tt-chips a {
	display: inline-block;
	padding: 4px 12px;
	border-radius: 6px;
	font-family: 'PT Sans', sans-serif;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.4;
	text-transform: none;
	letter-spacing: 0.02em;
	background: #edf4f6;
	color: #184363;
	margin: 0 6px 6px 0;
	transition: background 0.3s ease, color 0.3s ease;
}

/* Chips use the theme's own palette (light tint + heading blue). */
.tt-cards .post .post-categories.tt-chips a:hover { background: #15a9e3 !important; color: #FFFFFF !important; }

/* --- Title: full text, clamped to 3 lines, theme heading color --- */
.tt-cards .post .post-title {
	font-size: 19px;
	line-height: 1.35;
	margin-bottom: 8px;
}

.tt-cards .post .post-title a {
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* --- Excerpt: clamped to 3 lines, theme body color --- */
.tt-cards .post .post-excerpt {
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	font-size: 15px;
	line-height: 1.6;
	margin-bottom: 14px;
}

/* --- Read more pinned to the card bottom --- */
.tt-cards .post .post-read-more {
	margin-top: auto;
	align-self: flex-start;
}

/* --- Single post without a hero image: the category badge renders in
       the title section instead of over the (absent) image. Neutralize
       the absolute overlay positioning there. --- */
.post-title-section > .post-categories.single {
	position: static;
	top: auto;
	left: auto;
	margin-bottom: 14px;
}

.post-title-section > .post-categories.single a {
	background-color: #0F0D3F;
	color: #FFFFFF;
	border-radius: 6px;
}

/* --- Related posts carousel: equal card heights. tiny-slider sizes
       each slide to its own content; flex stretches them to the tallest
       (transform-based sliding is unaffected). --- */
#related-posts .slides.tns-slider {
	display: flex;
	align-items: stretch;
}

#related-posts .slides.tns-slider > .post {
	flex: 0 0 auto;
	height: auto;
	display: flex;
}

#related-posts .slides.tns-slider > .post .post-inner {
	width: 100%;
	height: 100%;
}

/* --- Search results reuse the same grid --- */
.tt-search-grid .only-posts.tt-cards {
	margin-top: 32px;
}

/* ============================================================
   Sidebar (archive + single): card sections, count pills,
   styled search + newsletter, recent posts with mini covers.
   ============================================================ */

aside.widget-area {
	background: #FDF8FC;
	border: 1px solid #F7E8F8;
	border-radius: 16px;
	padding: 16px;
}

aside.widget-area .widget {
	background: #FFFFFF;
	border: 1px solid #F7E8F8;
	border-radius: 12px;
	padding: 20px;
	margin-bottom: 16px;
}

aside.widget-area .widget:last-child {
	margin-bottom: 0;
}

aside.widget-area .widget .widget-title,
aside.widget-area .widget h4 {
	font-family: 'PT Sans', sans-serif;
	font-size: 18px;
	font-weight: 700;
	color: #184363;
	margin-bottom: 14px;
}

/* --- Categories: rows with right-aligned count pills --- */
aside.widget-area .widget_categories ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

aside.widget-area .widget_categories li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	padding: 8px 10px;
	border-radius: 8px;
	margin: 0 0 2px 0;
}

aside.widget-area .widget_categories li a {
	font-family: 'PT Sans', sans-serif;
	font-size: 14px;
	font-weight: 400;
	color: #184363;
	flex: 1 1 auto;
}

aside.widget-area .widget_categories li a:hover { color: #15a9e3; }

aside.widget-area .widget_categories .tt-count {
	flex: 0 0 auto;
	min-width: 26px;
	text-align: center;
	font-size: 12px;
	font-weight: 700;
	color: #56778f;
	background: #edf4f6;
	border-radius: 999px;
	padding: 2px 8px;
}

aside.widget-area .widget_categories li.tt-all-posts,
aside.widget-area .widget_categories li.current-cat {
	background: #F7E8F8;
}

aside.widget-area .widget_categories li.tt-all-posts a,
aside.widget-area .widget_categories li.current-cat a {
	font-weight: 700;
}

aside.widget-area .widget_categories li.tt-all-posts .tt-count,
aside.widget-area .widget_categories li.current-cat .tt-count {
	background: #FFFFFF;
	color: #A21CAF;
}

/* --- Search: rounded input + gradient button --- */
aside.widget-area .widget_search fieldset {
	position: relative;
	border: none;
	padding: 0;
	margin: 0;
}

aside.widget-area .widget_search input#s {
	width: 100%;
	height: 46px;
	border: 1px solid #F0D8F2;
	border-radius: 10px;
	background: #FFFFFF;
	padding: 0 56px 0 16px;
	font-family: 'PT Sans', sans-serif;
	font-size: 14px;
	color: #184363;
}

aside.widget-area .widget_search input#s:focus {
	border-color: #C026D3;
	outline: none;
}

aside.widget-area .widget_search input#searchsubmit {
	position: absolute;
	top: 0;
	right: 0;
	width: 46px;
	height: 46px;
	border: none;
	border-radius: 0 10px 10px 0;
	background: linear-gradient(135deg, #8B007C, #FF00F0);
	cursor: pointer;
	z-index: 2;
	opacity: 0;
}

aside.widget-area .widget_search .search-icon {
	position: absolute;
	top: 0;
	right: 0;
	width: 46px;
	height: 46px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 0 10px 10px 0;
	background: linear-gradient(135deg, #8B007C, #FF00F0);
	pointer-events: none;
	z-index: 1;
}

aside.widget-area .widget_search .search-icon svg {
	width: 18px;
	height: 18px;
	fill: #FFFFFF;
}

aside.widget-area .widget_search .search-icon svg path { fill: #FFFFFF; }

/* --- Newsletter + generic sidebar form fields --- */
aside.widget-area .widget input[type="text"]:not(#s),
aside.widget-area .widget input[type="email"] {
	width: 100%;
	height: 42px;
	border: 1px solid #F0D8F2;
	border-radius: 10px;
	background: #FFFFFF;
	padding: 0 14px;
	margin-bottom: 10px;
	font-family: 'PT Sans', sans-serif;
	font-size: 14px;
	color: #184363;
}

aside.widget-area .widget input[type="text"]:not(#s):focus,
aside.widget-area .widget input[type="email"]:focus {
	border-color: #C026D3;
	outline: none;
}

aside.widget-area .widget input[type="submit"]:not(#searchsubmit),
aside.widget-area .widget button[type="submit"] {
	width: 100%;
	height: 44px;
	border: none;
	border-radius: 10px;
	background: linear-gradient(135deg, #8B007C, #B402A1, #FF00F0);
	color: #FFFFFF;
	font-family: 'PT Sans', sans-serif;
	font-size: 14px;
	font-weight: 700;
	cursor: pointer;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

aside.widget-area .widget input[type="submit"]:not(#searchsubmit):hover,
aside.widget-area .widget button[type="submit"]:hover {
	transform: scale(1.02);
	box-shadow: 0 6px 16px rgba(139, 0, 124, 0.28);
}

/* --- Recent posts (2tentech widget) --- */
aside.widget-area .tt-recent-posts {
	list-style: none;
	margin: 0;
	padding: 0;
}

aside.widget-area .tt-recent-posts li {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	margin-bottom: 14px;
}

aside.widget-area .tt-recent-posts li:last-child { margin-bottom: 0; }

aside.widget-area .tt-recent-thumb {
	flex: 0 0 64px;
	width: 64px;
	height: 48px;
	border-radius: 8px;
	overflow: hidden;
	display: block;
	position: relative;
}

aside.widget-area .tt-recent-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

aside.widget-area .tt-mini-cover {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: flex-end;
	padding: 5px 6px;
}

aside.widget-area .tt-mini-cover .tt-cover-rail {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 3px;
}

aside.widget-area .tt-mini-cover .tt-mini-topic {
	font-family: 'PT Sans', sans-serif;
	font-size: 7px;
	font-weight: 700;
	letter-spacing: 0.06em;
	line-height: 1.1;
	color: #0F0D3F;
}

aside.widget-area .tt-recent-body {
	display: block;
	min-width: 0;
}

aside.widget-area .tt-recent-body > a {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	font-family: 'PT Sans', sans-serif;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.35;
	color: #184363;
}

aside.widget-area .tt-recent-body > a:hover { color: #15a9e3; }

aside.widget-area .tt-recent-date {
	display: block;
	font-size: 12px;
	color: #56778f;
	margin-top: 3px;
}

/* --- Tag cloud: never clip the tags --- */
aside.widget-area .widget_tag_cloud .tagcloud {
	max-height: none !important;
	overflow: visible !important;
}

/* --- Small screens --- */
@media only screen and (max-width: 479px) {
	.tt-cover-topic { font-size: 21px; }
	.tt-cover-body { padding: 0 18px 16px 18px; }
}
