/**
 * HMM Author Page — Styles
 *
 * Préfixe : .hmm-ap- (Author Page) pour éviter toute collision.
 * Mobile-first, responsive : 1 col <768px, 2 cols 768-1024px, 3 cols >=1024px.
 */

/* ════════════════════════════════════════════════════════════════
   VARIABLES CSS
════════════════════════════════════════════════════════════════ */
.hmm-ap-page {
	--hmm-ap-accent: #1a4a9c;
	--hmm-ap-accent-hover: #1558c0;
	--hmm-ap-text: #1a1a1a;
	--hmm-ap-text-soft: #4b5563;
	--hmm-ap-text-muted: #7a8fa6;
	--hmm-ap-border: #e5e7eb;
	--hmm-ap-bg: #f8fafc;
	--hmm-ap-card-bg: #ffffff;
	--hmm-ap-shadow: 0 2px 8px rgba(26, 74, 156, 0.08);
	--hmm-ap-shadow-hover: 0 8px 24px rgba(26, 74, 156, 0.12);
	--hmm-ap-radius: 10px;
	--hmm-ap-gap: 24px;
	--hmm-ap-container: 1200px;

	background: var(--hmm-ap-bg);
	color: var(--hmm-ap-text);
	min-height: 60vh;
}

/* ════════════════════════════════════════════════════════════════
   HERO AUTEUR
════════════════════════════════════════════════════════════════ */
.hmm-ap-hero {
	position: relative;
	background: linear-gradient(135deg, #1a4a9c 0%, #2563eb 100%);
	background-size: cover;
	background-position: center;
	color: #fff;
	padding: 60px 20px 50px;
	overflow: hidden;
}
.hmm-ap-hero--has-cover {
	background-color: #1a4a9c;
}
.hmm-ap-hero__overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(26, 74, 156, 0.35) 0%, rgba(26, 74, 156, 0.85) 100%);
	z-index: 1;
}
.hmm-ap-hero--has-cover .hmm-ap-hero__overlay {
	background: linear-gradient(180deg, rgba(0, 0, 0, 0.4) 0%, rgba(26, 74, 156, 0.85) 100%);
}
.hmm-ap-hero__inner {
	position: relative;
	z-index: 2;
	max-width: var(--hmm-ap-container);
	margin: 0 auto;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 22px;
	text-align: center;
}
.hmm-ap-hero__avatar-wrap {
	flex-shrink: 0;
}
.hmm-ap-hero__avatar {
	width: 160px;
	height: 160px;
	border-radius: 50%;
	border: 4px solid rgba(255, 255, 255, 0.85);
	object-fit: cover;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
	display: block;
}
.hmm-ap-hero__body {
	max-width: 720px;
}
.hmm-ap-hero__name {
	font-size: 38px;
	font-weight: 800;
	line-height: 1.1;
	margin: 0 0 8px;
	letter-spacing: -0.5px;
	color: #fff;
}
.hmm-ap-hero__role {
	font-size: 16px;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.9);
	margin: 0 0 18px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}
.hmm-ap-hero__quote {
	font-size: 18px;
	font-style: italic;
	color: rgba(255, 255, 255, 0.95);
	margin: 0 auto 18px;
	max-width: 600px;
	border: none;
	padding: 0;
	line-height: 1.5;
}
.hmm-ap-hero__bio {
	font-size: 15px;
	color: rgba(255, 255, 255, 0.92);
	line-height: 1.6;
	margin: 0 auto 22px;
	max-width: 640px;
}
.hmm-ap-hero__bio p {
	margin: 0 0 12px;
}
.hmm-ap-hero__bio p:last-child {
	margin-bottom: 0;
}
.hmm-ap-hero__meta {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 18px;
	margin-top: 4px;
}
.hmm-ap-hero__count {
	font-size: 13px;
	color: rgba(255, 255, 255, 0.85);
	font-weight: 600;
	padding: 6px 14px;
	background: rgba(255, 255, 255, 0.15);
	border-radius: 20px;
	backdrop-filter: blur(4px);
}
.hmm-ap-hero__social {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	justify-content: center;
}
.hmm-ap-hero__social-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 1.5px solid rgba(255, 255, 255, 0.6);
	color: #fff;
	transition: all 0.2s ease;
	text-decoration: none;
}
.hmm-ap-hero__social-link:hover {
	background: #fff;
	color: var(--hmm-ap-accent);
	border-color: #fff;
	transform: translateY(-2px);
}
.hmm-ap-hero__social-link svg {
	width: 16px;
	height: 16px;
	fill: currentColor;
}

/* ════════════════════════════════════════════════════════════════
   CONTAINER
════════════════════════════════════════════════════════════════ */
.hmm-ap-container {
	max-width: var(--hmm-ap-container);
	margin: 0 auto;
	padding: 40px 20px 60px;
}

/* ════════════════════════════════════════════════════════════════
   TOOLBAR (filtre + tri)
════════════════════════════════════════════════════════════════ */
.hmm-ap-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 16px;
	justify-content: space-between;
	margin-bottom: 28px;
	padding-bottom: 18px;
	border-bottom: 1px solid var(--hmm-ap-border);
}

/* Filtre catégories : pills horizontales scrollables */
.hmm-ap-filter {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}
.hmm-ap-filter__btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 7px 14px;
	background: #fff;
	border: 1px solid var(--hmm-ap-border);
	border-radius: 20px;
	font-size: 13px;
	font-weight: 600;
	color: var(--hmm-ap-text-soft);
	cursor: pointer;
	transition: all 0.15s ease;
	font-family: inherit;
}
.hmm-ap-filter__btn:hover {
	border-color: var(--hmm-ap-accent);
	color: var(--hmm-ap-accent);
}
.hmm-ap-filter__btn.is-active {
	background: var(--hmm-ap-accent);
	border-color: var(--hmm-ap-accent);
	color: #fff;
}
.hmm-ap-filter__count {
	font-size: 11px;
	font-weight: 500;
	opacity: 0.75;
}

/* Tri */
.hmm-ap-sort {
	display: flex;
	align-items: center;
	gap: 8px;
}
.hmm-ap-sort__label {
	font-size: 13px;
	color: var(--hmm-ap-text-muted);
	font-weight: 600;
}
.hmm-ap-sort__select {
	padding: 7px 30px 7px 12px;
	border: 1px solid var(--hmm-ap-border);
	border-radius: 6px;
	font-size: 13px;
	color: var(--hmm-ap-text);
	background: #fff;
	cursor: pointer;
	font-family: inherit;
	font-weight: 600;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%237a8fa6' d='M5 6L0 0h10z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 10px center;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
}
.hmm-ap-sort__select:focus {
	outline: none;
	border-color: var(--hmm-ap-accent);
}

/* ════════════════════════════════════════════════════════════════
   GRILLE D'ARTICLES — 3 cols desktop, 2 tablet, 1 mobile
════════════════════════════════════════════════════════════════ */
.hmm-ap-grid-wrap {
	position: relative;
	min-height: 400px;
}
.hmm-ap-grid-wrap.is-loading {
	opacity: 0.5;
	pointer-events: none;
	transition: opacity 0.2s ease;
}
.hmm-ap-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: var(--hmm-ap-gap);
	align-items: stretch;
}

/* ════════════════════════════════════════════════════════════════
   CARD ARTICLE — hauteur égalisée via flex interne
════════════════════════════════════════════════════════════════ */
.hmm-ap-card {
	display: flex;
	flex-direction: column;
	background: var(--hmm-ap-card-bg);
	border-radius: var(--hmm-ap-radius);
	overflow: hidden;
	box-shadow: var(--hmm-ap-shadow);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	height: 100%;
}
.hmm-ap-card:hover {
	transform: translateY(-3px);
	box-shadow: var(--hmm-ap-shadow-hover);
}
.hmm-ap-card__thumb-link {
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #f0f4ff;
	flex-shrink: 0;
}
.hmm-ap-card__thumb {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
	display: block;
}
.hmm-ap-card:hover .hmm-ap-card__thumb {
	transform: scale(1.04);
}
.hmm-ap-card__thumb-placeholder {
	display: block;
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, #c8d8f4 0%, #e0e8f8 100%);
}
.hmm-ap-card__body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 18px 20px 20px;
	gap: 8px;
}
.hmm-ap-card__cat {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: var(--hmm-ap-accent);
	text-decoration: none;
	margin-bottom: 4px;
	align-self: flex-start;
}
.hmm-ap-card__cat:hover {
	text-decoration: underline;
}
.hmm-ap-card__title {
	font-size: 17px;
	font-weight: 700;
	line-height: 1.35;
	margin: 0;
	color: var(--hmm-ap-text);
}
.hmm-ap-card__title a {
	color: inherit;
	text-decoration: none;
	transition: color 0.15s ease;
}
.hmm-ap-card__title a:hover {
	color: var(--hmm-ap-accent);
}
.hmm-ap-card__excerpt {
	font-size: 14px;
	line-height: 1.55;
	color: var(--hmm-ap-text-soft);
	margin: 0;
	flex: 1;
}
.hmm-ap-card__meta {
	font-size: 12px;
	color: var(--hmm-ap-text-muted);
	margin-top: 8px;
	padding-top: 12px;
	border-top: 1px solid var(--hmm-ap-border);
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
}

/* ════════════════════════════════════════════════════════════════
   PAGINATION
════════════════════════════════════════════════════════════════ */
.hmm-ap-pagination-wrap {
	margin-top: 40px;
	display: flex;
	justify-content: center;
}
.hmm-ap-pagination__list {
	display: flex;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
	align-items: center;
}
.hmm-ap-pagination__list li {
	margin: 0;
	padding: 0;
}
.hmm-ap-pagination__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	height: 38px;
	padding: 0 10px;
	border: 1px solid var(--hmm-ap-border);
	border-radius: 6px;
	background: #fff;
	color: var(--hmm-ap-text-soft);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	transition: all 0.15s ease;
	cursor: pointer;
	font-family: inherit;
}
.hmm-ap-pagination__link:hover {
	border-color: var(--hmm-ap-accent);
	color: var(--hmm-ap-accent);
}
.hmm-ap-pagination__link--current {
	background: var(--hmm-ap-accent);
	border-color: var(--hmm-ap-accent);
	color: #fff;
	cursor: default;
}
.hmm-ap-pagination__link--current:hover {
	color: #fff;
}
.hmm-ap-pagination__ellipsis {
	color: var(--hmm-ap-text-muted);
	padding: 0 4px;
	font-size: 14px;
}

/* ════════════════════════════════════════════════════════════════
   ÉTAT VIDE
════════════════════════════════════════════════════════════════ */
.hmm-ap-empty {
	text-align: center;
	color: var(--hmm-ap-text-muted);
	font-size: 15px;
	padding: 60px 20px;
	background: #fff;
	border: 1px dashed var(--hmm-ap-border);
	border-radius: var(--hmm-ap-radius);
}

/* ════════════════════════════════════════════════════════════════
   RESPONSIVE
════════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
	.hmm-ap-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 20px;
	}
	.hmm-ap-hero__name {
		font-size: 32px;
	}
	.hmm-ap-hero__avatar {
		width: 140px;
		height: 140px;
	}
}

@media (max-width: 768px) {
	.hmm-ap-grid {
		grid-template-columns: 1fr;
		gap: 18px;
	}
	.hmm-ap-hero {
		padding: 40px 16px 36px;
	}
	.hmm-ap-hero__name {
		font-size: 26px;
	}
	.hmm-ap-hero__avatar {
		width: 120px;
		height: 120px;
	}
	.hmm-ap-hero__quote {
		font-size: 16px;
	}
	.hmm-ap-hero__bio {
		font-size: 14px;
	}
	.hmm-ap-container {
		padding: 28px 16px 40px;
	}
	.hmm-ap-toolbar {
		flex-direction: column;
		align-items: stretch;
		gap: 14px;
	}
	.hmm-ap-filter {
		overflow-x: auto;
		flex-wrap: nowrap;
		padding-bottom: 4px;
		-webkit-overflow-scrolling: touch;
	}
	.hmm-ap-filter__btn {
		flex-shrink: 0;
	}
	.hmm-ap-sort {
		justify-content: flex-end;
	}
	.hmm-ap-card__title {
		font-size: 16px;
	}
	.hmm-ap-pagination__link {
		min-width: 34px;
		height: 34px;
		font-size: 13px;
	}
}
