/*
 * Custom CSS for MTGInfo360 Theme
 * These styles supplement theme.json for effects that require it.
 */

/* --- Body & Header --- */
body {
	/* This padding prevents content from jumping when the header becomes solid.
       It should be equal to the header's height. */
	padding-top: 86px;
}

.site-header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	z-index: 1000;
	background-color: transparent;
	transition: background-color 0.4s ease, box-shadow 0.4s ease;
	padding-top: 1rem;
	padding-bottom: 1rem;
}

.site-header.scrolled {
	background-color: var(--wp--preset--color--background);
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* --- Navigation Links --- */
.site-header .wp-block-navigation-item__content {
	color: var(--wp--preset--color--tertiary);
	font-weight: 600;
	transition: color 0.3s ease;
}

.site-header.scrolled .wp-block-navigation-item__content {
	color: var(--wp--preset--color--secondary);
}

.site-header .wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--primary);
}

/* --- Hero Section --- */
.hero-section-group {
	/* This pulls the entire hero section up to sit behind the header */
	margin-top: -86px;
}

.hero {
	background-attachment: fixed;
}

.hero-banner {
	border-radius: 0 15px 15px 0;
	max-width: 55%;
	min-width: 400px;
}

/* --- Help Cards --- */
.help-cards-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: 2rem;
}

.help-card-link {
	text-decoration: none;
	display: block;
	height: 100%;
	color: inherit;
}

.help-card {
	background-color: #fff;
	border: 2px solid #e9ecef;
	border-radius: 15px;
	padding: 30px;
	text-align: center;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
	transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
	height: 100%;
}

.help-card-link:hover .help-card {
	transform: translateY(-10px);
	box-shadow: 0 12px 30px rgba(24, 80, 99, 0.12);
	border-color: var(--wp--preset--color--primary);
}

.help-card h3 {
	color: var(--wp--preset--color--secondary);
	margin-bottom: 15px;
}

.help-card-icon {
	color: var(--wp--preset--color--primary);
	width: 45px;
	height: 45px;
	margin-bottom: 20px;
}

/* --- Blog Cards --- */
.blog-card {
	background-color: #fff;
	border-radius: 15px;
	overflow: hidden;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	display: flex;
	flex-direction: column;
	height: 100%;
}

.blog-card:hover {
	transform: translateY(-8px);
	box-shadow: 0 10px 25px rgba(24, 80, 99, 0.15);
}

.blog-card-image-wrapper {
	overflow: hidden;
	position: relative;
}

.blog-card .wp-block-post-featured-image img {
	width: 100%;
	height: 220px;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.blog-card:hover .wp-block-post-featured-image img {
	transform: scale(1.05);
}

.blog-card-content {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
	padding: 30px;
}

.blog-card-category a {
	text-decoration: none;
	color: var(--wp--preset--color--primary);
	font-size: 0.85rem;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.blog-card .wp-block-post-title {
	margin-top: 0.5rem;
	margin-bottom: 1rem;
}

.blog-card .wp-block-post-excerpt {
	flex-grow: 1;
}

.blog-card .wp-block-post-excerpt__more-link {
	font-weight: 600;
	color: var(--wp--preset--color--primary);
	text-decoration: none;
}

/* --- Iframe Section --- */
.iframe-wrapper {
	max-width: 900px;
	margin: 0 auto;
}

.iframe-container {
	position: relative;
	width: 100%;
	/* This sets the aspect ratio to be taller */
	padding-top: 150%; /* Adjust this percentage to change the height */
	border-radius: 15px;
	overflow: hidden;
	box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
	background-color: #fff;
}

.iframe-container iframe {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border: none;
}
