/* Downloads section: tabs (All + categories) + grid of cards */
.cma-downloads-section {
	padding: 2rem 0 3rem;
}

.cma-downloads-container {
	margin: 0 auto;
}

/* Tabs */
.cma-downloads-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	margin-bottom: 2rem;
}

.cma-downloads-tab {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.6rem 1.25rem;
	font-family: inherit;
	font-size: 1rem;
	font-weight: 600;
	color: #fff;
	background: transparent;
	border: 2px solid #ED1C24;
	border-radius: 4px;
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
}

.cma-downloads-tab:hover {
	background: rgba(237, 28, 36, 0.15);
	color: #fff;
}

.cma-downloads-tab.is-active {
	background: #ED1C24;
	border-color: #ED1C24;
	color: #fff;
}

.cma-downloads-tab-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 1.5rem;
	padding: 0 0.35rem;
	font-size: 0.85rem;
	font-weight: 600;
	background: rgba(255, 255, 255, 0.25);
	border-radius: 999px;
}

.cma-downloads-tab.is-active .cma-downloads-tab-count {
	background: rgba(255, 255, 255, 0.3);
}

/* Grid */
.cma-downloads-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
	gap: 1.25rem;
	
}

.cma-download-card {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	padding: 1.25rem;
	background: #f5f5f5;
	border-radius: 8px;
	min-height: 120px;
	transition: opacity 0.2s, visibility 0.2s;
}

.cma-download-card.is-hidden {
	display: none;
}

.cma-download-title {
	margin: 0 0 0.75rem;
	font-size: 1rem;
	font-weight: 700;
	line-height: 1.35;
	color: #231F20;
}

.cma-download-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	align-self: flex-end;
	gap: 0.4rem;
	padding: 0.5rem 1rem;
	font-size: 0.9rem;
	font-weight: 600;
	color: #fff;
	background: #ED1C24;
	border: none;
	border-radius: 4px;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.2s, opacity 0.2s;
}

.cma-download-btn:hover {
	background: #c91820;
	color: #fff;
}

.cma-download-btn::after {
	content: "";
	display: inline-block;
	width: 1em;
	height: 1em;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4'/%3E%3Cpolyline points='7 10 12 15 17 10'/%3E%3Cline x1='12' y1='15' x2='12' y2='3'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* Financial Reports / e-Library — κάρτα με εικόνα */
.cma-downloads-section--extra .cma-download-card--has-image {
	padding: 0;
	overflow: hidden;
	padding-bottom: 65px;
}

.cma-downloads-section--extra .cma-download-card--has-image .cma-download-card-image {
	line-height: 0;
	background: #e8e8e8;
}

.cma-downloads-section--extra .cma-download-card--has-image .cma-download-card-image img {
	width: 100%;
	height: auto;
	min-height: 120px;
	object-fit: cover;
	display: block;
	width: 100%; 
	object-fit: cover;
	max-height: 250px;
}

.cma-downloads-section--extra .cma-download-card--has-image .cma-download-card-content {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	flex: 1;
	padding: 1.25rem;
	min-height: 100px;
}

.cma-downloads-section--extra .cma-download-card--has-image .cma-download-title {
	margin: 0 0 0.75rem;
}

.cma-downloads-section--extra .cma-download-card--has-image .cma-download-btn {
	align-self: flex-end;
}

@media (max-width: 640px) {
	.cma-downloads-grid {
		grid-template-columns: 1fr;
	}
}
