/*
Theme Name: Imaginarium Empire Optimizado
Author: Gal
Version: 2.4
*/

@font-face {
	font-family: "Open Sans";
	src: url("fonts/OpenSans-Variable.woff2") format("woff2");
	font-style: normal;
	font-weight: 300 800;
	font-display: swap;
}

@font-face {
	font-family: "Open Sans";
	src: url("fonts/OpenSans-Italic-Variable.woff2") format("woff2");
	font-style: italic;
	font-weight: 300 800;
	font-display: swap;
}

@font-face {
	font-family: "Unna";
	src: url("fonts/Unna-Regular.woff2") format("woff2");
	font-style: normal;
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: "Unna";
	src: url("fonts/Unna-Bold.woff2") format("woff2");
	font-style: normal;
	font-weight: 700;
	font-display: swap;
}

@font-face {
	font-family: "Unna";
	src: url("fonts/Unna-Italic.woff2") format("woff2");
	font-style: italic;
	font-weight: 400;
	font-display: swap;
}

@font-face {
	font-family: "Unna";
	src: url("fonts/Unna-BoldItalic.woff2") format("woff2");
	font-style: italic;
	font-weight: 700;
	font-display: swap;
}

:root {
	--primary-ultra-dark: #1d2b61;
	--primary-dark: #405ac3;
	--primary-accent: #6e8bff;
	--primary-light: #acbbf8;
	--primary-ultra-light: #d4dcfc;
	--secondary-ultra-dark: #6d3500;
	--secondary-dark: #ca6404;
	--secondary-accent: #ff810b;
	--secondary-light: #ffa653;
	--secondary-ultra-light: #ffd9b5;
	--text: #161616;
	--border: #666;
	--surface: #fff;
	--radius-small: 10px;
	--radius-large: 20px;
	--content-width: 1200px;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	display: grid;
	grid-template-rows: auto 1fr auto;
	min-height: 100vh;
	min-height: 100svh;
	margin: 0;
	color: var(--text);
	font-family: "Open Sans", Arial, sans-serif;
	font-size: 18px;
	line-height: 1.6;
}

body.menu-open {
	overflow: hidden;
}

h1,
h2,
h3 {
	font-family: "Unna", Georgia, serif;
	line-height: 1.15;
	overflow-wrap: anywhere;
}

h1,
h2 {
	font-weight: 700;
}

h3 {
	font-weight: 400;
}

img,
svg,
video {
	display: block;
	max-width: 100%;
	height: auto;
}

iframe {
	max-width: 100%;
}

a {
	color: var(--text);
	font-weight: 500;
	text-decoration: none;
	text-underline-offset: 0.2em;
}

a:hover {
	color: var(--primary-accent);
}

a:focus-visible,
button:focus-visible {
	outline: 3px solid var(--primary-accent);
	outline-offset: 3px;
}

button,
.button-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 12px 18px;
	border: 0;
	border-radius: var(--radius-small);
	background-color: var(--secondary-accent);
	color: var(--surface);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 180ms ease;
}

button:hover,
.button-link:hover {
	background-color: var(--secondary-dark);
	color: var(--surface);
}

.wrapper {
	width: min(100% - 40px, var(--content-width));
	margin-inline: auto;
}

.grid-container {
	display: grid;
	grid-template-columns: repeat(12, minmax(0, 1fr));
	gap: 20px;
	justify-content: center;
}

/* Header */
.nav-header {
	position: sticky;
	top: 0;
	z-index: 30;
	padding: 20px 0;
	border-bottom: 1px solid var(--border);
	background: var(--surface);
}

.logo {
	grid-column: 1 / span 10;
	justify-self: center;
}

.logo a,
.logo img {
	display: block;
}

.logo img {
	width: clamp(150px, 50vw, 260px);
}

.nav-mobile {
	display: flex;
	grid-column: 11 / span 2;
	align-items: center;
	justify-self: end;
}

.menu {
	display: none;
}

.nav-mobile-display {
	position: fixed;
	inset: 0;
	z-index: 40;
	display: none;
	min-height: 100vh;
	min-height: 100dvh;
	padding: 80px 20px 30px;
	overflow-y: auto;
	background: var(--surface);
}

.nav-mobile-display.show {
	display: block;
}

button.nav-mobile-opens,
button.nav-mobile-close {
	width: 44px;
	height: 44px;
	min-height: 44px;
	padding: 6px;
	border-radius: 0;
	background-color: var(--surface);
	background-position: center;
	background-repeat: no-repeat;
	background-size: 32px 32px;
}

button.nav-mobile-opens {
	background-image: url("img/menu-open.png");
}

button.nav-mobile-close {
	position: absolute;
	top: 20px;
	right: 20px;
	background-image: url("img/menu-close.png");
}

button.nav-mobile-opens:hover,
button.nav-mobile-close:hover {
	background-color: #f1f3fb;
}

nav ul {
	margin: 0 0 20px;
	padding: 0;
	list-style: none;
}

nav ul li {
	padding: 10px;
}

.nav-social {
	display: flex;
	align-items: center;
}

.nav-social img {
	width: 25px;
	height: 25px;
}

.instagram,
.youtube {
	margin-inline: 5px;
}

body.admin-bar .nav-header {
	top: 46px;
}

body.admin-bar .nav-mobile-display {
	top: 46px;
	min-height: calc(100dvh - 46px);
}

/* Home */
.hero {
	margin-block: 40px;
}

.hero-content,
.progress,
.featured-post,
.latest-posts-list,
.breadcrumbs,
.single-content,
.sidebar,
.page,
.archive-content,
.pagination {
	grid-column: 1 / -1;
	min-width: 0;
}

.progress-title {
	justify-self: center;
	margin-top: 40px;
}

.progress-books {
	margin-block: 40px;
	text-align: center;
}

.progress-box-1,
.progress-box-2,
.progress-box-3 {
	margin: 10px 0 20px;
}

.box-number {
	font-size: 30px;
	font-weight: 700;
	color: var(--primary-accent);
}

.box-text {
	font-weight: 600;
}

.box-text small {
	font-weight: 300;
}

/* Featured post */
.featured-post {
	margin-block: 40px;
}

.featured-post-thumbnail {
	overflow: hidden;
}

.featured-post-thumbnail img {
	width: 100%;
	height: 100%;
	border-radius: var(--radius-large) var(--radius-large) 0 0;
	object-fit: cover;
}

.featured-post-content {
	padding: 20px;
	border-radius: 0 0 var(--radius-large) var(--radius-large);
	background: var(--primary-dark);
	color: var(--surface);
}

/* Post cards */
.latest-posts {
	display: grid;
	margin-top: 40px;
	padding-block: 20px;
	background: var(--primary-ultra-dark);
	color: var(--surface);
}

.latest-posts-title {
	grid-column: 1 / -1;
}

.latest-posts-list {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 20px;
}

.post-card {
	display: flex;
	flex-direction: column;
	margin-bottom: 15px;
	overflow: hidden;
	border-radius: var(--radius-small);
	background: var(--surface);
	color: var(--text);
}

.post-card-thumbnail {
	width: 100%;
	height: 250px;
	overflow: hidden;
}

.post-card-thumbnail a {
	display: block;
	height: 100%;
}

.post-card-thumbnail img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.post-content {
	flex-grow: 1;
	padding: 15px;
}

.post-mas {
	padding: 15px;
	border-top: 1px solid var(--border);
	text-align: center;
}

/* Content */
.breadcrumbs {
	margin: 40px 0 20px;
}

.breadcrumbs a {
	font-weight: 600;
}

.breadcrumbs span {
	font-weight: 400;
}

.single-content h1,
.page h1,
.archive-content h1 {
	font-size: clamp(2.25rem, 9vw, 3rem);
}

.single-article {
	margin-block: 60px;
}

.single-article,
.page {
	overflow-wrap: anywhere;
}

.single-article > *:first-child,
.page > *:first-child {
	margin-top: 0;
}

.sidebar {
	margin-bottom: 40px;
	padding-block: 20px;
	border-block: 1px solid var(--border);
}

.sidebar ul {
	margin-block: 20px;
	padding: 0;
	list-style: none;
}

.sidebar li {
	margin-inline: 10px;
	padding-block: 15px;
}

.sidebar li a {
	display: inline-block;
	padding: 8px 14px;
	border: 1px solid var(--text);
	border-radius: 999px;
	font-weight: 400;
}

.sidebar li a:hover {
	border-color: var(--primary-accent);
}

.page {
	margin-bottom: 60px;
}

.archive-content,
.archive-content .post-card {
	margin-block: 40px;
}

.archive-content .post-card {
	box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
}

/* Comments */
.comments-area {
	margin: 20px 0 60px;
	padding-top: 40px;
	border-top: 1px solid var(--border);
}

.comments-title,
.comment-reply-title {
	font-size: clamp(1.75rem, 6vw, 2.25rem);
}

.comment-list,
.comment-list .children {
	margin: 0;
	padding: 0;
	list-style: none;
}

.comment-list .children {
	margin-left: clamp(12px, 5vw, 40px);
}

.comment-body {
	margin-bottom: 20px;
	padding: 20px;
	border: 1px solid #d4d8e8;
	border-radius: var(--radius-small);
	background: #f7f8fc;
}

.bypostauthor > .comment-body {
	border-left: 4px solid var(--primary-accent);
}

.comment-author {
	display: block;
}

.comment-author .says {
	font-size: 0.875rem;
	font-weight: 400;
}

.comment-metadata {
	margin: 6px 0 16px;
	font-size: 0.875rem;
	text-align: left;
}

.comment-content > *:first-child {
	margin-top: 0;
}

.comment-content > *:last-child {
	margin-bottom: 0;
}

.reply {
	margin-top: 16px;
}

.comment-reply-link,
.comment-reply-title small a {
	font-weight: 700;
	color: var(--primary-accent);
	text-decoration: underline;
}

.comment-navigation {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	justify-content: space-between;
	margin-block: 25px;
}

.comment-respond {
	margin-top: 40px;
}

.comment-form {
	display: grid;
	gap: 18px;
}

.comment-form p {
	margin: 0;
}

.comment-form label {
	display: block;
	margin-bottom: 6px;
	font-weight: 600;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form textarea {
	width: 100%;
	padding: 12px;
	border: 1px solid var(--border);
	border-radius: 8px;
	background: var(--surface);
	color: var(--text);
	font: inherit;
}

.comment-form textarea {
	min-height: 180px;
	resize: vertical;
}

.comment-form input:focus-visible,
.comment-form textarea:focus-visible {
	border-color: var(--primary-accent);
	outline: 3px solid rgba(110, 139, 255, 0.3);
	outline-offset: 2px;
}

.comment-form-cookies-consent {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 10px;
	align-items: start;
}

.comment-form-cookies-consent input {
	width: 20px;
	height: 20px;
	margin-top: 3px;
}

.comment-form-cookies-consent label {
	margin: 0;
	font-weight: 400;
}

.required {
	color: #a13b00;
}

.comment-form .submit {
	display: inline-flex;
	min-height: 44px;
	padding: 12px 18px;
	border: 0;
	border-radius: var(--radius-small);
	background: var(--secondary-accent);
	color: var(--surface);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 180ms ease;
}

.comment-form .submit:hover {
	background: var(--secondary-dark);
}

.comment-form .submit:focus-visible {
	outline: 3px solid var(--primary-accent);
	outline-offset: 3px;
}

.no-comments,
.comment-awaiting-moderation {
	font-style: italic;
}

/* Pagination */
.navigation {
	margin-bottom: 60px;
}

.nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: center;
}

.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	min-height: 38px;
	padding: 5px 10px;
	border: 1px solid currentColor;
	border-radius: 999px;
}

.page-numbers.current {
	border-color: var(--primary-dark);
	background: var(--primary-dark);
	color: var(--surface);
}

.site-footer {
	padding-block: 40px;
	border-top: 1px solid var(--border);
	text-align: center;
}

/* Tablets */
@media (min-width: 700px) {
	.latest-posts-list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.progress-books {
		display: grid;
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 20px;
		text-align: left;
	}

	.progress-box-1,
	.progress-box-2,
	.progress-box-3 {
		margin: 0;
	}
}

/* Desktop */
@media (min-width: 1024px) {
	.logo {
		grid-column: 1 / span 3;
		justify-self: start;
	}

	.logo img {
		width: min(100%, 260px);
	}

	.nav-mobile,
	.nav-mobile-display {
		display: none;
	}

	.menu {
		display: grid;
		grid-column: 4 / span 9;
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: center;
	}

	.nav {
		display: flex;
		align-items: center;
		justify-content: flex-end;
	}

	.nav-social {
		justify-content: flex-end;
	}

	nav ul {
		display: flex;
		align-items: center;
		margin: 0;
	}

	nav ul li a:hover,
	.current-menu-item > a,
	.current_page_item > a {
		border-bottom: 2px solid var(--primary-accent);
		color: var(--primary-accent);
	}

	.progress-books {
		padding: 20px 0 40px;
	}

	.progress-box-1,
	.progress-box-2,
	.progress-box-3 {
		display: grid;
		grid-template-columns: auto minmax(0, 1fr);
		gap: 12px;
	}

	.featured-post {
		display: grid;
		grid-template-columns: repeat(12, minmax(0, 1fr));
		margin: 0 0 40px;
	}

	.featured-post-content {
		display: flex;
		grid-column: 1 / span 6;
		flex-direction: column;
		justify-content: center;
		padding: 40px;
		border-radius: var(--radius-large) 0 0 var(--radius-large);
	}

	.featured-post-content .button-link {
		align-self: flex-start;
	}

	.featured-post-thumbnail {
		grid-row: 1;
		grid-column: 7 / span 6;
		height: 450px;
	}

	.featured-post-thumbnail img {
		border-radius: 0 var(--radius-large) var(--radius-large) 0;
	}

	.latest-posts {
		display: block;
	}

	.latest-posts-list {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		margin-block: 15px;
	}

	.breadcrumbs {
		margin-bottom: 10px;
	}

	.single-content,
	.archive-content {
		grid-column: 1 / span 9;
	}

	.sidebar {
		grid-column: 10 / span 3;
		margin-block: 40px;
		border: 0;
	}

	.archive-content .post-card-thumbnail {
		height: 185px;
	}
}

@media (min-width: 783px) {
	body.admin-bar .nav-header {
		top: 32px;
	}

	body.admin-bar .nav-mobile-display {
		top: 32px;
		min-height: calc(100dvh - 32px);
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		scroll-behavior: auto;
		transition-duration: 0.01ms !important;
	}
}
