/*
Theme Name: Spectrofuge
Theme URI: https://www.spectrofuge.com
Author: Arch Network Services, Inc.
Author URI: https://archns.com
Description: Block theme for Spectrofuge Corporation of N.C., laboratory equipment service and calibration. Pairs with the Spectrofuge Service plugin.
Requires at least: 6.4
Tested up to: 7.1
Requires PHP: 7.4
Version: 1.2.0
License: GPL-2.0-or-later
Text Domain: spectrofuge-theme
*/

/* ---------- Base ---------- */
html { -webkit-text-size-adjust: 100%; }
body { font-feature-settings: "tnum" 1; text-rendering: optimizeLegibility; }
p, li { max-width: 68ch; }
.has-text-align-center p, .has-text-align-center { margin-inline: auto; }

:where(a, button, input, select, textarea, summary, .wp-element-button):focus-visible {
	outline: 3px solid var(--wp--preset--color--tag);
	outline-offset: 2px;
	border-radius: 2px;
}

.skip-link.screen-reader-text:focus { background: var(--wp--preset--color--tag); color: var(--wp--preset--color--ink); }

/* ---------- Header ---------- */
.sf-header { border-bottom: 1px solid var(--wp--preset--color--rule); background: var(--wp--preset--color--cabinet); }
.sf-wordmark { margin: 0; line-height: 0; }
.sf-wordmark img { display: block; width: 160px; height: auto; }
.sf-wordmark a { text-decoration: none; }
.sf-wordmark small { display: block; font-family: var(--wp--preset--font-family--barlow); font-weight: 500; font-size: 0.8125rem; letter-spacing: 0; color: var(--wp--preset--color--steel); margin-top: 0.2rem; }
.sf-header-phone a { font-weight: 600; text-decoration: none; white-space: nowrap; }

/* ---------- Hero with service tag ---------- */
.sf-hero { position: relative; overflow: hidden; }
.sf-hero h1 { max-width: 15ch; }
.sf-hero .sf-lead { font-size: var(--wp--preset--font-size--lead); color: var(--wp--preset--color--ink); max-width: 46ch; }

.sf-tag-wrap { display: flex; justify-content: center; padding-top: 2.5rem; }
.sf-tag {
	position: relative;
	width: min(100%, 320px);
	background: var(--wp--preset--color--tag);
	color: var(--wp--preset--color--ink);
	padding: 3.25rem 1.5rem 1.5rem;
	clip-path: polygon(18% 0, 82% 0, 100% 9%, 100% 100%, 0 100%, 0 9%);
	transform: rotate(-4deg);
	transform-origin: 50% 0;
	box-shadow: none;
	filter: drop-shadow(0 14px 18px rgba(20, 50, 60, 0.18));
	font-family: var(--wp--preset--font-family--barlow-condensed);
}
/* Reinforced punch hole */
.sf-tag::before {
	content: "";
	position: absolute;
	top: 1rem; left: 50%;
	width: 1.25rem; height: 1.25rem;
	margin-left: -0.625rem;
	border-radius: 50%;
	background: var(--wp--preset--color--cabinet);
	box-shadow: 0 0 0 0.4rem #D9A91C;
}
/* String */
.sf-tag-wrap::before {
	content: "";
	position: absolute;
	width: 2px; height: 3.2rem;
	margin-top: -1.9rem;
	background: var(--wp--preset--color--steel);
	opacity: 0.55;
}
.sf-tag-wrap { position: relative; }
.sf-tag p { margin: 0; max-width: none; }
.sf-tag .sf-tag-title { font-size: 2.6rem; font-weight: 700; line-height: 0.95; letter-spacing: 0.01em; }
.sf-tag .sf-tag-sub { font-family: var(--wp--preset--font-family--barlow); font-size: 0.9375rem; font-weight: 500; margin-top: 0.4rem; }
.sf-tag dl { margin: 1.25rem 0 0; display: grid; grid-template-columns: auto 1fr; gap: 0.55rem 0.75rem; font-size: 1.15rem; font-weight: 600; }
.sf-tag dt { font-family: var(--wp--preset--font-family--barlow); font-size: 0.875rem; font-weight: 500; padding-top: 0.2rem; }
.sf-tag dd { margin: 0; border-bottom: 1.5px solid rgba(20, 50, 60, 0.55); min-height: 1.6rem; font-family: "Segoe Print", "Bradley Hand", "Comic Sans MS", cursive; font-weight: 400; font-size: 1.05rem; }
.sf-tag .sf-tag-foot { margin-top: 1.25rem; font-family: var(--wp--preset--font-family--barlow); font-size: 0.8125rem; font-weight: 500; }

@media (prefers-reduced-motion: no-preference) {
	.sf-tag { animation: sf-swing 1.6s cubic-bezier(.3, 1.4, .5, 1) 0.2s both; }
	@keyframes sf-swing { from { transform: rotate(7deg); } to { transform: rotate(-4deg); } }
}

/* ---------- Plan matrix ---------- */
.sf-matrix { overflow-x: auto; }
.sf-matrix table { border-collapse: collapse; width: 100%; min-width: 620px; table-layout: fixed; background: var(--wp--preset--color--paper); }
.sf-matrix th, .sf-matrix td { border: 0; border-bottom: 1px solid var(--wp--preset--color--rule); padding: 0.95rem 1rem; text-align: center; vertical-align: middle; }
.sf-matrix thead th { font-family: var(--wp--preset--font-family--barlow-condensed); font-size: 1.5rem; font-weight: 600; line-height: 1.1; border-bottom: 2px solid var(--wp--preset--color--ink); vertical-align: bottom; }
.sf-matrix thead th:first-child, .sf-matrix tbody th { text-align: left; }
.sf-matrix tbody th { font-weight: 500; }
.sf-matrix tbody th small { display: block; color: var(--wp--preset--color--steel); font-weight: 400; font-size: 0.9375rem; }
.sf-matrix td.y { color: var(--wp--preset--color--pass); font-size: 1.35rem; font-weight: 600; }
.sf-matrix td.n { color: var(--wp--preset--color--rule); font-size: 1.35rem; }
.sf-matrix td.opt { font-size: 0.9375rem; color: var(--wp--preset--color--steel); }
.sf-matrix thead th.sf-col-feature { background: var(--wp--preset--color--brand); color: var(--wp--preset--color--paper); border-bottom-color: var(--wp--preset--color--brand); }
.sf-matrix tbody td.sf-col-feature { background: #F8F9F8; }
.sf-matrix caption { caption-side: bottom; text-align: left; padding-top: 0.9rem; color: var(--wp--preset--color--steel); font-size: 0.9375rem; }

/* ---------- Instruments & manufacturers ---------- */
.sf-instruments { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); border-top: 1px solid var(--wp--preset--color--rule); }
.sf-instruments li { max-width: none; padding: 1rem 0.25rem 1rem 0; border-bottom: 1px solid var(--wp--preset--color--rule); }
.sf-instruments strong { display: block; font-family: var(--wp--preset--font-family--barlow-condensed); font-size: 1.5rem; font-weight: 600; line-height: 1.1; }
.sf-instruments span { color: var(--wp--preset--color--steel); font-size: 0.9375rem; }
.sf-makes { color: var(--wp--preset--color--steel); }
.sf-makes strong { color: var(--wp--preset--color--ink); font-weight: 600; }

/* ---------- PM steps (a real sequence) ---------- */
.sf-steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: 2rem 2.5rem; }
.sf-steps li { counter-increment: step; position: relative; padding-top: 3.4rem; max-width: none; }
.sf-steps li::before {
	content: counter(step);
	position: absolute; top: 0; left: 0;
	width: 2.5rem; height: 2.5rem;
	display: grid; place-items: center;
	border: 2px solid var(--wp--preset--color--ink);
	border-radius: 50%;
	font-family: var(--wp--preset--font-family--barlow-condensed);
	font-weight: 700; font-size: 1.35rem;
}
.sf-steps h3 { margin: 0 0 0.4rem; font-size: var(--wp--preset--font-size--subhead); }
.sf-steps p { margin: 0; }

/* ---------- Contact band ---------- */
.sf-contact { background: var(--wp--preset--color--ink); color: var(--wp--preset--color--paper); }
.sf-contact h2, .sf-contact a { color: var(--wp--preset--color--paper); }
.sf-contact .sf-big-phone { font-family: var(--wp--preset--font-family--barlow-condensed); font-weight: 700; font-size: clamp(2.5rem, 7vw, 4.5rem); line-height: 1; margin: 0; }
.sf-contact .sf-big-phone a { text-decoration: none; border-bottom: 4px solid var(--wp--preset--color--tag); }
.sf-contact address { font-style: normal; line-height: 1.6; }
.sf-contact .sf-muted { color: #B8C6CA; }

/* ---------- Footer ---------- */
.sf-footer { border-top: 1px solid var(--wp--preset--color--rule); color: var(--wp--preset--color--steel); font-size: var(--wp--preset--font-size--small); }
.sf-footer a { color: var(--wp--preset--color--steel); }

/* ---------- Small screens ---------- */
@media (max-width: 781px) {
	.sf-wordmark img { width: 120px; }
	.sf-tag { transform: rotate(-3deg); width: min(100%, 290px); }
	.sf-header .wp-block-navigation__responsive-container-open { padding: 0.4rem; }
	.sf-header-phone { display: none; }
}
.sf-matrix thead th:first-child { width: 28%; }
