/* =========================================================
   CATEGORY HEADER
   ========================================================= */

.dg-category-header {
	margin-bottom: 30px;
}

.dg-category-header__content {
	max-width: 900px;
}

.dg-category-header__content h1 {
	margin-bottom: 15px;
}

.dg-category-header__image {
	margin-bottom: 25px;
	overflow: hidden;
	border-radius: 12px;
}

.dg-category-header__image img {
	display: block;
	width: 100%;
	height: auto;
}


/* =========================================================
   HERO (zdaj <img> namesto background-image, boljše za SEO/LCP)
   ========================================================= */

.dg-category-hero {
	position: relative;
	min-height: 360px;
	margin: 35px 0;
	border-radius: 14px;
	overflow: hidden;
}

.dg-category-hero__image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

.dg-category-hero__overlay {
	position: relative;
	min-height: 360px;
	display: flex;
	align-items: flex-end;
	padding: 40px;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.05));
}

.dg-category-hero__content {
	max-width: 850px;
	color: #fff;
}

.dg-category-hero__content h1 {
	color: #fff;
	margin: 0 0 15px;
}

.dg-category-hero .dg-category-intro p{
	color: #fff;
}


/* =========================================================
   INTRO
   ========================================================= */

.dg-category-intro {
	line-height: 1.7;
}

.dg-category-intro p:last-child {
	margin-bottom: 0;
}


/* =========================================================
   SUBCATEGORIES
   ========================================================= */

.dg-category-subcategories {
	margin: 30px 0 40px;
}

.dg-category-subcategories__grid {
	display: grid;
	grid-template-columns: repeat(var(--dg-category-columns), minmax(0, 1fr));
	gap: 20px;
}

.dg-category-subcategory {
	display: block;
	text-decoration: none;
	color: inherit;
}

.dg-category-subcategory__image {
	overflow: hidden;
	border-radius: 10px;
	margin-bottom: 10px;
}

.dg-category-subcategory__image img {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	transition: transform 0.25s ease;
}

.dg-category-subcategory:hover .dg-category-subcategory__image img {
	transform: scale(1.04);
}

.dg-category-subcategory__title {
	font-weight: 600;
	text-align: center;
}


/* =========================================================
   BEST GAMES LINK
   ========================================================= */

.dg-best-games-link {
	margin: 35px 0;
	padding: 25px 30px;
	border-radius: 12px;
	background: #f6f6f6;
}

.dg-best-games-link__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 25px;
}

.dg-best-games-link__content h2 {
	margin: 0 0 5px;
}

.dg-best-games-link__content p {
	margin: 0;
}

.dg-best-games-link__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 12px 22px;
	border-radius: 7px;
	text-decoration: none;
	white-space: nowrap;
	font-weight: 600;
}


/* =========================================================
   FEATURED GAMES
   ========================================================= */

.dg-featured-games {
	margin: 35px 0 40px;
}

.dg-featured-games__header {
	margin-bottom: 18px;
}

.dg-featured-games__header h2 {
	margin: 0;
}

.dg-featured-games__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 15%;
}

.dg-featured-game {
	display: block;
	text-decoration: none;
	overflow: hidden;
	border-radius: 10px;
}

.dg-featured-game__image {
	overflow: hidden;
	line-height: 0;
}

.dg-featured-game__image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	transition: transform 0.25s ease;
}

.dg-featured-game:hover .dg-featured-game__image img {
	transform: scale(1.03);
}

.dg-featured-game__name {
	display: block;
	margin-top: 8px;
	font-weight: 600;
	text-align: center;
}


/* =========================================================
   CATEGORY CONTENT
   ========================================================= */

.dg-category-content {
	margin: 40px 0;
	line-height: 1.7;
}

.dg-category-content h2,
.dg-category-content h3 {
	margin-top: 30px;
}


/* =========================================================
   FAQ
   ========================================================= */

.dg-category-faq {
	margin: 50px 0 20px;
}

.dg-category-faq__inner {
	max-width: 900px;
}

.dg-category-faq h2 {
	margin-bottom: 20px;
}

.dg-faq-item {
	border-bottom: 1px solid #ddd;
}

.dg-faq-item:first-child {
	border-top: 1px solid #ddd;
}

.dg-faq-item summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding: 18px 0;
	cursor: pointer;
	list-style: none;
	font-weight: 600;
}

.dg-faq-item summary::-webkit-details-marker {
	display: none;
}

.dg-faq-icon {
	flex: 0 0 auto;
	font-size: 24px;
	font-weight: 400;
	transition: transform 0.2s ease;
}

.dg-faq-item[open] .dg-faq-icon {
	transform: rotate(45deg);
}

.dg-faq-answer {
	padding: 0 40px 20px 0;
	line-height: 1.7;
}

.dg-faq-answer p:last-child {
	margin-bottom: 0;
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

	.dg-category-subcategories__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.dg-featured-games__grid {
		gap: 12px;
	}

	.dg-best-games-link__inner {
		flex-direction: column;
		align-items: flex-start;
	}
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 600px) {

	.dg-category-hero,
	.dg-category-hero__overlay {
		min-height: 280px;
	}

	.dg-category-hero {
		border-radius: 10px;
	}

	.dg-category-hero__overlay {
		padding: 25px;
	}

	.dg-category-subcategories__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 12px;
	}

	.dg-featured-games__grid {
        grid-template-columns: 1fr;
		gap: 40px;
	}

    .dg-featured-game {
        margin: 0 25%;
    }

	.dg-best-games-link {
		padding: 20px;
	}

	.dg-best-games-link__button {
		width: 100%;
	}

	.dg-category-faq {
		margin-top: 40px;
	}
}