/*
 * NovaWave — front-end micro-CSS.
 *
 * 90% of design tokens live in theme.json. This file only contains:
 *   1. Custom block-style variations (is-style-*)
 *   2. Custom-HTML chunks (cart icon, newsletter form, payments)
 *   3. Tiny WP-hostile fixes that can't be expressed in JSON.
 *
 * Keep it small. If you find yourself writing layout here, add a block instead.
 */

/* ---------- Utilities ---------- */

.screen-reader-text {
	position: absolute !important;
	clip: rect(1px, 1px, 1px, 1px);
	width: 1px;
	height: 1px;
	overflow: hidden;
	white-space: nowrap;
}

img { max-width: 100%; height: auto; }

/* ---------- Footer link lists ---------- */

.novawave-footer-links {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: var(--wp--preset--spacing--20);
}

.novawave-footer-links li {
	margin: 0;
}

.novawave-footer-links a {
	text-decoration: none;
	font-size: var(--wp--preset--font-size--sm);
	color: var(--wp--preset--color--contrast-soft);
	transition: color 150ms ease;
}

.novawave-footer-links a:hover {
	color: var(--wp--preset--color--accent);
}

/* ---------- Blog topic pills (home.html categories block) ---------- */

.novawave-topics {
	row-gap: var(--wp--preset--spacing--20) !important;
}

.novawave-topics .novawave-category-pills,
.novawave-topics ul.wp-block-categories {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wp--preset--spacing--20);
	list-style: none;
	margin: 0;
	padding: 0;
}

.novawave-topics .wp-block-categories li {
	margin: 0;
}

.novawave-topics .wp-block-categories a {
	display: inline-block;
	padding: 0.4rem 0.9rem;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 999px;
	font-size: var(--wp--preset--font-size--xs);
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--wp--preset--color--contrast);
	background: var(--wp--preset--color--base-soft);
	transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}

.novawave-topics .wp-block-categories a:hover {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base-soft);
}

/* category post-count number that WP appends */
.novawave-topics .wp-block-categories li {
	display: inline-flex;
	align-items: center;
}

/* ---------- Block style variations ---------- */

/* Eyebrow heading */
.is-style-eyebrow {
	font-family: var(--wp--preset--font-family--sans) !important;
	font-size: var(--wp--preset--font-size--xs) !important;
	font-weight: 600 !important;
	letter-spacing: 0.18em !important;
	text-transform: uppercase !important;
	color: var(--wp--preset--color--accent);
	margin: 0;
}

/* Hand underline heading */
.is-style-underline {
	display: inline-block;
	background-image: linear-gradient(transparent 78%, color-mix(in srgb, var(--wp--preset--color--accent) 35%, transparent) 78%);
	background-repeat: no-repeat;
	background-size: 100% 100%;
	padding: 0 0.1em;
}

/* Ghost button */
.wp-block-button.is-style-ghost > .wp-block-button__link {
	background: transparent !important;
	color: var(--wp--preset--color--contrast) !important;
	border: 1px solid var(--wp--preset--color--contrast) !important;
}
.wp-block-button.is-style-ghost > .wp-block-button__link:hover {
	background: var(--wp--preset--color--contrast) !important;
	color: var(--wp--preset--color--base-soft) !important;
}

/* Inline link button */
.wp-block-button.is-style-link > .wp-block-button__link {
	background: transparent !important;
	color: inherit !important;
	border: none !important;
	padding: 0 !important;
	text-transform: none !important;
	letter-spacing: 0 !important;
	font-size: inherit !important;
	font-weight: 600;
	border-bottom: 1px solid currentColor;
	border-radius: 0 !important;
}

/* Pill button */
.wp-block-button.is-style-pill > .wp-block-button__link {
	border-radius: 999px !important;
}

/* Soft frame image */
.is-style-softframe img {
	box-shadow:
		0 1px 2px rgba(31, 27, 23, 0.05),
		0 12px 32px rgba(31, 27, 23, 0.08);
}

/* Cameo image (rounded) */
.is-style-cameo img {
	border-radius: 999px !important;
}

/* Card surface group */
.wp-block-group.is-style-card {
	background: var(--wp--preset--color--base-soft);
	padding: var(--wp--preset--spacing--40);
	border-radius: 4px;
	transition: box-shadow 200ms ease, transform 200ms ease;
}
.wp-block-group.is-style-card:hover {
	box-shadow: var(--wp--preset--shadow--soft);
	transform: translateY(-2px);
}

/* Hairline divider group */
.wp-block-group.is-style-hairline {
	border-top: 1px solid var(--wp--preset--color--line);
	padding-top: var(--wp--preset--spacing--40);
}

/* Editorial quote */
.wp-block-quote.is-style-editorial {
	position: relative;
	padding-left: 2.4em;
	font-size: var(--wp--preset--font-size--xl);
	line-height: 1.45;
}
.wp-block-quote.is-style-editorial::before {
	content: "\201C";
	position: absolute;
	left: 0;
	top: -0.2em;
	font-family: var(--wp--preset--font-family--serif);
	font-size: 3.2em;
	line-height: 1;
	color: var(--wp--preset--color--accent);
}

/* Ornament separator */
.wp-block-separator.is-style-ornament {
	border: none !important;
	background: none !important;
	height: 24px;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	overflow: visible;
}
.wp-block-separator.is-style-ornament::before,
.wp-block-separator.is-style-ornament::after {
	content: "";
	flex: 1;
	height: 1px;
	background: var(--wp--preset--color--line);
	max-width: 80px;
}
.wp-block-separator.is-style-ornament::after { order: 3; }
.wp-block-separator.is-style-ornament::before { order: 1; }

/* ---------- Header layout ---------- */

.novawave-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--wp--preset--color--base);
}

.novawave-header__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--wp--preset--spacing--40);
	width: 100%;
}

.novawave-header__brand {
	flex: 0 0 auto;
	min-width: 0;
}

.novawave-site-title {
	margin: 0;
}

.novawave-site-title a {
	text-decoration: none;
	color: var(--wp--preset--color--contrast);
	font-family: var(--wp--preset--font-family--serif);
}

.novawave-logo-fallback img {
	display: block;
	height: 56px;
	width: auto;
}

.novawave-primary-nav {
	flex: 1 1 auto;
	justify-content: center;
}

.novawave-primary-nav .wp-block-navigation-item__content {
	font-size: var(--wp--preset--font-size--xs);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.novawave-nav-fallback ul {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: var(--wp--preset--spacing--40);
	list-style: none;
	margin: 0;
	padding: 0;
}

.novawave-nav-fallback a {
	font-size: var(--wp--preset--font-size--xs);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--wp--preset--color--contrast);
}

.novawave-nav-fallback a:hover {
	color: var(--wp--preset--color--accent);
}

.novawave-header__tools {
	flex: 0 0 auto;
	align-items: center;
}

@media (max-width: 900px) {
	.novawave-header__row {
		flex-wrap: wrap;
	}

	.novawave-primary-nav,
	.novawave-nav-fallback {
		order: 3;
		width: 100%;
	}

	.novawave-nav-fallback ul {
		justify-content: flex-start;
	}
}

/* ---------- Header chrome (custom HTML in parts/header.html) ---------- */

.novawave-cart,
.novawave-account {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	color: var(--wp--preset--color--contrast);
	text-decoration: none;
	transition: color 150ms ease;
}
.novawave-cart:hover,
.novawave-account:hover { color: var(--wp--preset--color--accent); }

/* Signed-in indicator on the account icon */
.novawave-account.is-logged-in::after {
	content: "";
	position: absolute;
	top: 6px;
	right: 6px;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--wp--preset--color--accent);
	border: 2px solid var(--wp--preset--color--base);
}

.novawave-cart-count {
	position: absolute;
	top: -2px;
	right: -4px;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--wp--preset--color--contrast);
	color: var(--wp--preset--color--base-soft);
	font-size: 10px;
	font-weight: 700;
	line-height: 18px;
	text-align: center;
	font-family: var(--wp--preset--font-family--sans);
}
.novawave-cart-count[hidden] { display: none; }

/* ---------- Newsletter forms ---------- */

.novawave-newsletter {
	display: flex;
	align-items: stretch;
	gap: 0;
	max-width: 360px;
	border: 1px solid var(--wp--preset--color--line);
	background: var(--wp--preset--color--white);
	border-radius: 2px;
	overflow: hidden;
	margin-top: var(--wp--preset--spacing--40);
}
.novawave-newsletter input[type="email"] {
	flex: 1;
	border: 0;
	background: transparent;
	padding: 0.85rem 1rem;
	font: 400 0.95rem/1.4 var(--wp--preset--font-family--sans);
	color: var(--wp--preset--color--contrast);
	outline: none;
}
.novawave-newsletter input[type="email"]::placeholder {
	color: var(--wp--preset--color--muted);
}
.novawave-newsletter button {
	border: 0;
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base-soft);
	padding: 0 1.1rem;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 150ms ease;
}
.novawave-newsletter button:hover { background: var(--wp--preset--color--primary-deep); }

.novawave-newsletter--inverse {
	margin-left: auto;
	margin-right: auto;
	border-color: rgba(255, 255, 255, 0.4);
	background: rgba(255, 255, 255, 0.06);
}
.novawave-newsletter--inverse input[type="email"] { color: var(--wp--preset--color--base-soft); }
.novawave-newsletter--inverse input[type="email"]::placeholder { color: rgba(246, 241, 232, 0.7); }
.novawave-newsletter--inverse button {
	background: var(--wp--preset--color--base-soft);
	color: var(--wp--preset--color--primary);
	padding: 0 1.5rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	font-size: 0.8rem;
}

/* ---------- Footer payments ---------- */

.novawave-payments {
	display: inline-flex;
	gap: 8px;
	flex-wrap: wrap;
	align-items: center;
}
.novawave-payments span {
	display: inline-block;
	padding: 4px 8px;
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	font-family: var(--wp--preset--font-family--sans);
	color: var(--wp--preset--color--contrast-soft);
	background: var(--wp--preset--color--white);
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 3px;
}

/* ---------- Toast (cart added) ---------- */

.novawave-toast {
	font-family: var(--wp--preset--font-family--sans);
	font-size: 0.9rem;
}

/* ---------- Collections shortcode fallback ---------- */

.novawave-collections {
	display: grid;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: var(--wp--preset--spacing--40);
	list-style: none;
	padding: 0;
	margin: 0;
}
@media (max-width: 960px) { .novawave-collections { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 540px) { .novawave-collections { grid-template-columns: repeat(2, 1fr); } }

.novawave-collections__link {
	display: block;
	text-decoration: none;
	color: inherit;
}
.novawave-collections__media {
	display: block;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border-radius: 4px;
	background: var(--wp--preset--color--base-warm);
	margin-bottom: var(--wp--preset--spacing--20);
}
.novawave-collections__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 350ms ease;
}
.novawave-collections__link:hover .novawave-collections__media img { transform: scale(1.04); }
.novawave-collections__label {
	display: block;
	font-family: var(--wp--preset--font-family--serif);
	font-size: var(--wp--preset--font-size--md);
}
.novawave-collections__cta {
	display: block;
	font-size: var(--wp--preset--font-size--sm);
	color: var(--wp--preset--color--accent);
	margin-top: 2px;
}

/* ---------- Responsive niceties ---------- */

@media (max-width: 781px) {
	.wp-block-columns.alignwide,
	.wp-block-columns.alignfull { gap: var(--wp--preset--spacing--50); }
}

/* Reveal-on-scroll (paired with assets/js/app.js IntersectionObserver) */
.novawave-reveal {
	opacity: 0;
	transform: translateY(14px);
	transition: opacity 600ms ease, transform 600ms ease;
}
.novawave-reveal.is-in-view {
	opacity: 1;
	transform: none;
}

@media (prefers-reduced-motion: reduce) {
	* { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
	.novawave-reveal { opacity: 1; transform: none; }
}
