/*
Theme Name: Josh Clark
Theme URI: https://joshclark.net
Author: Josh Clark
Description: Lightweight block theme for joshclark.net, rebuilt from the original Elementor design. No page builder required.
Version: 1.0.0
Requires at least: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: joshclark
*/

/* Most styling lives in theme.json. This file holds the few things theme.json can't express. */

/* Header */
.jc-header {
	border-bottom: 1px solid var(--wp--preset--color--primary);
	min-height: 80px;
	position: relative;
	z-index: 99;
}
.jc-header .wp-block-site-logo img { transition: opacity .2s ease; }
.jc-header .wp-block-site-logo a:hover img { opacity: .75; }
.jc-header .wp-block-navigation .current-menu-item > a { color: var(--wp--preset--color--accent); }
.jc-header .wp-block-navigation__responsive-container.is-menu-open {
	background-color: var(--wp--preset--color--base);
	color: var(--wp--preset--color--contrast);
}
@media (max-width: 781px) {
	.jc-header .jc-header-cta { display: none; }
}

/* Hero: full-bleed photo, roughly the proportions of the original */
.jc-hero.wp-block-cover { min-height: clamp(294px, 60vw, 90vh) !important; }

/* Cards with the star icon */
.jc-card {
	display: flex;
	flex-direction: column;
	height: 100%;
}
.jc-card::before {
	content: "";
	display: block;
	width: 32px;
	height: 32px;
	margin-bottom: .25rem;
	background-color: var(--wp--preset--color--accent);
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 576 512'%3E%3Cpath d='M259.3 17.8 194 150.2 47.9 171.5c-26.2 3.8-36.7 36.1-17.7 54.6l105.7 103-25 145.5c-4.5 26.3 23.2 46 46.4 33.7L288 439.6l130.7 68.7c23.2 12.2 50.9-7.4 46.4-33.7l-25-145.5 105.7-103c19-18.5 8.5-50.8-17.7-54.6L382 150.2 316.7 17.8c-11.7-23.6-45.6-23.9-57.4 0z'/%3E%3C/svg%3E") no-repeat center / contain;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 576 512'%3E%3Cpath d='M259.3 17.8 194 150.2 47.9 171.5c-26.2 3.8-36.7 36.1-17.7 54.6l105.7 103-25 145.5c-4.5 26.3 23.2 46 46.4 33.7L288 439.6l130.7 68.7c23.2 12.2 50.9-7.4 46.4-33.7l-25-145.5 105.7-103c19-18.5 8.5-50.8-17.7-54.6L382 150.2 316.7 17.8c-11.7-23.6-45.6-23.9-57.4 0z'/%3E%3C/svg%3E") no-repeat center / contain;
}
.jc-card > .wp-block-buttons:last-child { margin-top: auto; padding-top: 1rem; }

/* Highlights */
.jc-highlight .wp-block-image img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.jc-date { color: var(--wp--preset--color--accent); }
.jc-credit { opacity: .75; }

/* Footer */
.jc-footer-top { border-bottom: 1px solid var(--wp--preset--color--primary); }
.jc-footer .wp-block-social-links .wp-social-link { color: var(--wp--preset--color--primary); transition: color .2s ease; }
.jc-footer .wp-block-social-links .wp-social-link:hover { color: var(--wp--preset--color--accent); }
.jc-footer a { color: var(--wp--preset--color--contrast); text-decoration: none; }
.jc-footer a:hover { color: var(--wp--preset--color--accent); }

/* Embeds sit flush in cards */
.jc-highlight .wp-block-embed { margin-top: auto; }
