/*
Theme Name: Hatchback Inspect
Theme URI: https://hatchbackinspect.com
Author: Hatchback Inspect
Description: Block theme for a licensed home inspection business. Built around the visual grammar of the inspection report itself: severity chips, location tags, and finding cards.
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 8.0
Version: 0.1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: hatchback-inspect
Tags: block-theme, business, one-column, full-site-editing
*/

/* -------------------------------------------------------------------------
   Nearly everything visual is defined in theme.json. This file holds only
   what the block system can't express: the finding card and its severity
   taxonomy, which is the signature element of the design.
   ---------------------------------------------------------------------- */

/* --- Utility: mono eyebrow label ---------------------------------------- */

.hb-eyebrow {
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--micro);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--slate);
	margin-bottom: 0.75rem;
}

/* --- Finding card ------------------------------------------------------- */
/* Mirrors the layout of a real inspection report entry:
   severity chip -> location tag -> finding -> recommendation.          */

.hb-finding {
	background: var(--wp--preset--color--card);
	border: 1px solid var(--wp--preset--color--line);
	border-left: 3px solid var(--wp--preset--color--slate);
	border-radius: 2px;
	padding: 1.5rem;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	height: 100%;
}

.hb-finding__meta {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	flex-wrap: wrap;
}

.hb-finding__chip {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: #fff;
	background: var(--wp--preset--color--slate);
	padding: 0.25rem 0.5rem;
	border-radius: 2px;
	white-space: nowrap;
}

.hb-finding__location {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--wp--preset--color--slate);
}

.hb-finding__title {
	font-size: var(--wp--preset--font-size--large);
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: -0.015em;
	margin: 0;
}

.hb-finding__body {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--slate);
	margin: 0;
	line-height: 1.6;
}

.hb-finding__action {
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem;
	color: var(--wp--preset--color--ink);
	border-top: 1px dashed var(--wp--preset--color--line);
	padding-top: 0.75rem;
	margin: 0.25rem 0 0;
}

.hb-finding__action::before {
	content: "\2192\00a0";
	color: var(--wp--preset--color--amber);
}

/* Severity variants — the accent colour carries meaning, not decoration. */

.hb-finding--safety {
	border-left-color: var(--wp--preset--color--safety);
}
.hb-finding--safety .hb-finding__chip {
	background: var(--wp--preset--color--safety);
}

.hb-finding--major {
	border-left-color: var(--wp--preset--color--amber);
}
.hb-finding--major .hb-finding__chip {
	background: var(--wp--preset--color--amber);
}

.hb-finding--monitor {
	border-left-color: var(--wp--preset--color--monitor);
}
.hb-finding--monitor .hb-finding__chip {
	background: var(--wp--preset--color--monitor);
}

/* --- Systems list (what gets inspected) --------------------------------- */

.hb-systems {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
	gap: 0;
	border-top: 1px solid var(--wp--preset--color--line);
}

.hb-systems li {
	border-bottom: 1px solid var(--wp--preset--color--line);
	padding: 0.9rem 0.25rem;
	font-size: var(--wp--preset--font-size--small);
	display: flex;
	gap: 0.75rem;
	align-items: baseline;
}

.hb-systems li::before {
	content: attr(data-ref);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	color: var(--wp--preset--color--amber);
	letter-spacing: 0.08em;
	flex: 0 0 2.25rem;
}

/* --- Service area ------------------------------------------------------- */

.hb-area {
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--small);
	line-height: 2.1;
	letter-spacing: 0.02em;
}

.hb-area span::after {
	content: " \00b7 ";
	color: var(--wp--preset--color--amber);
	padding: 0 0.35rem;
}

.hb-area span:last-child::after {
	content: "";
}

/* --- Footer compliance line --------------------------------------------- */

.hb-license {
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--micro);
	letter-spacing: 0.06em;
	color: var(--wp--preset--color--slate);
}

/* --- Quality floor ------------------------------------------------------ */

:where(a:focus-visible),
:where(button:focus-visible),
:where(.wp-element-button:focus-visible) {
	outline: 2px solid var(--wp--preset--color--amber);
	outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

@media (max-width: 600px) {
	.hb-finding {
		padding: 1.25rem;
	}
}
