/*
 * kn-membership.css
 * Kristine Nannini Membership Site
 * Upload to: wp-content/themes/kadence-child/kn-membership.css
 */


/* ─── Card Grid ────────────────────────────────────────────────────────────── */
.kn-card-grid {
	display: grid;
	grid-template-columns: repeat( auto-fill, minmax( 300px, 1fr ) );
	gap: 28px;
	margin: 24px 0;
}


/* ─── Card Base ─────────────────────────────────────────────────────────────── */
.kn-card {
	background: #fff;
	border: 1px solid #e4e4e4;
	border-radius: 4px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: box-shadow 0.2s ease;
}
.kn-card:hover {
	box-shadow: 0 4px 18px rgba( 0, 0, 0, 0.10 );
}


/* ─── Image ──────────────────────────────────────────────────────────────────── */
.kn-card-thumb {
	overflow: hidden;
	background: #f0f0f0;
}
.kn-card-thumb a {
	display: block;
	overflow: hidden;
}
.kn-card-thumb img {
	width: 100%;
	height: 220px;
	object-fit: cover;
	display: block;
	transition: transform 0.3s ease;
}
.kn-card:hover .kn-card-thumb img {
	transform: scale( 1.03 );
}
.kn-card-thumb-placeholder {
	width: 100%;
	height: 220px;
	background: linear-gradient( 135deg, #e8f4e8, #d4e0d4 );
}


/* ─── Card Body ──────────────────────────────────────────────────────────────── */
.kn-card-body {
	display: flex;
	flex-direction: row;
	gap: 12px;
	padding: 14px 14px 8px;
	flex: 1;
}


/* Left: title + excerpt */
.kn-card-left {
	flex: 1;
	min-width: 0;
}
.kn-card-title {
	font-size: 0.95rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.02em;
	margin: 0 0 6px;
	line-height: 1.3;
	color: #31373d;
}
.kn-card-title a {
	color: inherit;
	text-decoration: none;
}
.kn-card-title a:hover {
	color: #b16f52;
}
.kn-card-excerpt {
	font-size: 0.85rem;
	color: #555;
	line-height: 1.55;
	margin: 0;
}
.kn-learn-more {
	color: #b16f52;
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}
.kn-learn-more:hover {
	text-decoration: underline;
}


/* Right: badges stacked vertically */
.kn-card-right {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 7px;
	flex-shrink: 0;
	width: 74px;
}


/* ─── Badges & Buttons ───────────────────────────────────────────────────────── */
.kn-badge {
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	font-size: 0.78rem;
	font-weight: 700;
	line-height: 1.2;
	border-radius: 50px;
	padding: 6px 8px;
	width: 68px;
	min-height: 32px;
	border: none;
	text-decoration: none;
	transition: filter 0.15s ease;
}

/* Red label badge */
.kn-badge-label {
	background: #f55151;
	color: #fff;
	cursor: default;
}

/* Green access button */
.kn-badge-access {
	background: #25dc4e;
	color: #fff !important;
	cursor: pointer;
	font-size: 0.82rem;
	text-decoration: none !important;
}
.kn-badge-access:hover {
	filter: brightness( 0.90 );
}

/* Yellow grade circle */
.kn-badge-grade {
	background: #ffc236;
	color: #fff;
	font-size: 0.95rem;
	font-weight: 700;
	width: 44px;
	height: 44px;
	min-height: 44px;
	border-radius: 50%;
	padding: 0;
}

/* Teal duration box */
.kn-time-box {
	background: #34e2ec;
	color: #fff;
	border-radius: 3px;
	width: 58px;
	padding: 5px 4px;
	text-align: center;
	display: flex;
	flex-direction: column;
	align-items: center;
	line-height: 1.1;
}
.kn-time-num {
	font-size: 1rem;
	font-weight: 700;
}
.kn-time-unit {
	font-size: 0.68rem;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}


/* ─── Card Footer (Related Categories) ─────────────────────────────────────── */
.kn-card-footer {
	padding: 8px 14px 12px;
	border-top: 1px solid #f0f0f0;
	font-size: 0.8rem;
	color: #555;
	line-height: 1.6;
}
.kn-card-footer strong {
	font-weight: 700;
	color: #333;
}
.kn-card-footer a {
	color: #666;
	text-decoration: none;
}
.kn-card-footer a:hover {
	color: #b16f52;
	text-decoration: underline;
}


/* ─── Notices & Empty States ────────────────────────────────────────────────── */
.kn-notice {
	padding: 20px 24px;
	background: #f8f8f8;
	border-radius: 6px;
	color: #555;
	font-size: 0.95rem;
	text-align: center;
}

/* Credit balance from [kn_credits] shortcode */
.kn-credit-balance {
	font-weight: 700;
	color: #333d2a;
}

/* Membership type label from [kn_membership_type] shortcode */
.kn-membership-type {
	font-weight: 600;
	color: #b16f52;
}


/* ─── Responsive ─────────────────────────────────────────────────────────────── */
@media ( max-width: 640px ) {
	.kn-card-grid {
		grid-template-columns: 1fr;
		gap: 20px;
	}
	.kn-card-body {
		flex-direction: column;
	}
	.kn-card-right {
		flex-direction: row;
		width: 100%;
		justify-content: flex-start;
		flex-wrap: wrap;
	}
	.kn-card-thumb img,
	.kn-card-thumb-placeholder {
		height: 190px;
	}
}
