/*
 * NB Theme base. theme.json carries the tokens and element styles, this file
 * carries the things theme.json cannot express: the hero, the section rhythm,
 * and the full bleed garnet blocks.
 *
 * Logical properties only. The site is RTL half the time.
 */

/* --------------------------- accessibility --------------------------- */

/* Spec 13.3, never outline:none without a replacement. */
:where(a, button, input, textarea, select, summary, [tabindex]):focus-visible {
	outline: 2px solid var(--wp--preset--color--red);
	outline-offset: 2px;
	border-radius: 2px;
}

.nb-skip {
	position: absolute;
	inset-inline-start: -9999px;
	inset-block-start: 0;
	background: var(--wp--preset--color--ink);
	color: #fff;
	padding: 0.75rem 1.25rem;
	z-index: 100;
}

.nb-skip:focus {
	inset-inline-start: 0;
}

/* Body line length under 72 characters, spec 11.2. */
.nb-prose p,
.nb-prose li {
	max-inline-size: 68ch;
}

/* ------------------------------- header ------------------------------- */

.nb-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	padding-block: 1.25rem;
	border-block-end: 1px solid var(--wp--preset--color--line);
}

.nb-header__name {
	font-weight: 700;
	font-size: 1.125rem;
	text-decoration: none;
	color: var(--wp--preset--color--ink);
}

.nb-nav {
	display: flex;
	align-items: center;
	gap: 1.5rem;
}

.nb-nav a {
	text-decoration: none;
	color: var(--wp--preset--color--ink);
	font-weight: 500;
}

.nb-nav a:hover,
.nb-nav a[aria-current] {
	color: var(--wp--preset--color--red);
}

.nb-lang {
	display: inline-flex;
	gap: 0.5rem;
	font-size: 0.875rem;
}

.nb-lang a {
	text-decoration: none;
	color: var(--wp--preset--color--ink-soft);
	padding: 0.25rem 0.5rem;
	border-radius: 4px;
}

.nb-lang a[aria-current] {
	color: var(--wp--preset--color--ink);
	font-weight: 600;
	background: var(--wp--preset--color--red-soft);
}

@media (max-width: 640px) {
	.nb-header {
		flex-wrap: wrap;
	}

	.nb-nav {
		gap: 1rem;
		font-size: 0.9375rem;
	}
}

/* -------------------------------- hero -------------------------------- */

.nb-hero {
	display: grid;
	grid-template-columns: 1.15fr 0.85fr;
	gap: 3rem;
	align-items: center;
	padding-block: clamp(2.5rem, 6vw, 5rem);
}

@media (max-width: 780px) {
	.nb-hero {
		grid-template-columns: 1fr;
		gap: 2rem;
	}
}

.nb-hero__title {
	margin: 0 0 1rem;
}

.nb-hero__line {
	font-size: 1.1875rem;
	color: var(--wp--preset--color--ink-soft);
	max-inline-size: 34ch;
	margin: 0 0 2rem;
}

.nb-hero__actions {
	display: flex;
	gap: 0.75rem;
	flex-wrap: wrap;
}

.nb-hero__portrait {
	border-radius: 12px;
	inline-size: 100%;
	block-size: auto;
	aspect-ratio: 4 / 5;
	object-fit: cover;
}

.nb-hero__slots {
	margin-block-start: 2rem;
}

.nb-hero__slots-label {
	font-size: 0.875rem;
	color: var(--wp--preset--color--ink-soft);
	margin: 0;
}

/*
 * The one orchestrated moment on the page, spec 11.4. Everything else is
 * response motion only.
 */
@media (prefers-reduced-motion: no-preference) {
	.nb-hero__title,
	.nb-hero__line,
	.nb-hero__actions,
	.nb-hero__slots {
		animation: nb-rise 600ms cubic-bezier(0.2, 0.7, 0.2, 1) backwards;
	}

	.nb-hero__line { animation-delay: 80ms; }
	.nb-hero__actions { animation-delay: 160ms; }
	.nb-hero__slots { animation-delay: 240ms; }

	@keyframes nb-rise {
		from { opacity: 0; transform: translateY(12px); }
		to { opacity: 1; transform: none; }
	}
}

/* ------------------------------ sections ------------------------------ */

.nb-section {
	padding-block: clamp(3rem, 7vw, 5.5rem);
}

.nb-section + .nb-section {
	border-block-start: 1px solid var(--wp--preset--color--line);
}

/*
 * Full bleed garnet. Spec 11: spend the boldness on deep red as a surface in one
 * or two sections and keep the rest quiet, so the red reads as identity rather
 * than as an alert. Text on garnet is always white, --red does not pass on it.
 */
.nb-bleed {
	background: var(--wp--preset--color--garnet);
	color: #fff;
	padding-block: clamp(3.5rem, 8vw, 6rem);
	padding-inline: 1.25rem;
	margin-inline: calc(50% - 50vw);
}

.nb-bleed__inner {
	max-inline-size: 72rem;
	margin-inline: auto;
}

.nb-bleed :is(h1, h2, h3) {
	color: #fff;
}

.nb-bleed a:not(.nb-btn) {
	color: #fff;
}

.nb-bleed .nb-btn {
	background: #fff;
	color: var(--wp--preset--color--garnet);
	border-color: #fff;
}

.nb-bleed + .nb-section {
	border-block-start: 0;
}

/* --------------------------- audience blocks --------------------------- */

/* Spec 8.2, plain language, explicitly not an icons in circles grid. */
.nb-audience {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
	gap: 2.5rem;
}

.nb-audience__item h3 {
	margin-block-end: 0.5rem;
}

.nb-audience__item p {
	margin: 0;
	color: var(--wp--preset--color--ink-soft);
}

/* ---------------------------- how it works ---------------------------- */

.nb-modes {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
	gap: 1.5rem;
}

.nb-mode {
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 12px;
	padding: 1.75rem;
}

.nb-mode__price {
	font-size: 1.5rem;
	font-weight: 700;
	margin-block: 0.5rem 1rem;
	/* Prices stay in Latin numerals in both languages, spec 13.1. */
	direction: ltr;
	unicode-bidi: isolate;
}

.nb-mode ul {
	padding-inline-start: 1.125rem;
	color: var(--wp--preset--color--ink-soft);
}

/* -------------------------------- proof -------------------------------- */

.nb-proof {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
	gap: 2rem;
}

.nb-proof__item {
	margin: 0;
}

.nb-proof__item blockquote {
	margin: 0 0 0.75rem;
	padding: 0;
	border: 0;
	font-size: 1.0625rem;
}

.nb-proof__item figcaption {
	font-size: 0.875rem;
	font-weight: 600;
}

.nb-proof__item figcaption span {
	font-weight: 400;
	color: var(--wp--preset--color--ink-soft);
}

/* --------------------------------- FAQ --------------------------------- */

.nb-faq details {
	border-block-end: 1px solid var(--wp--preset--color--line);
	padding-block: 1.125rem;
}

.nb-faq summary {
	cursor: pointer;
	font-weight: 600;
	list-style: none;
	display: flex;
	justify-content: space-between;
	gap: 1rem;
	align-items: center;
}

.nb-faq summary::-webkit-details-marker {
	display: none;
}

.nb-faq summary::after {
	content: "+";
	color: var(--wp--preset--color--red);
	font-size: 1.25rem;
	flex: 0 0 auto;
}

.nb-faq details[open] summary::after {
	content: "\2212";
}

.nb-faq details p {
	margin-block-end: 0;
	color: var(--wp--preset--color--ink-soft);
	max-inline-size: 68ch;
}

/* ------------------------------- about --------------------------------- */

.nb-roles,
.nb-certs {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	gap: 1rem;
}

.nb-roles__item,
.nb-certs__item {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem 0.75rem;
	align-items: baseline;
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 10px;
	padding: 1rem 1.25rem;
}

.nb-roles__item strong,
.nb-certs__item strong {
	flex: 1 0 auto;
}

.nb-roles__dates,
.nb-certs__meta,
.nb-certs__id {
	color: var(--wp--preset--color--ink-soft);
	font-size: 0.875rem;
}

.nb-certs__verify {
	font-size: 0.875rem;
	margin-inline-start: auto;
}

/* Spec 9.5, no percentage bars and no five star ratings. */
.nb-skills {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
	gap: 2rem;
}

.nb-skills ul {
	list-style: none;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.nb-skills li {
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 999px;
	padding: 0.375rem 0.875rem;
	font-size: 0.9375rem;
}

.nb-timeline {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	gap: 1.25rem;
}

.nb-timeline__item {
	display: grid;
	grid-template-columns: 2rem 5rem 1fr;
	gap: 1rem;
	align-items: baseline;
}

.nb-timeline__marker {
	inline-size: 2rem;
	block-size: 2rem;
	display: grid;
	place-items: center;
	border-radius: 50%;
	background: var(--wp--preset--color--red-soft);
	color: var(--wp--preset--color--garnet);
	font-size: 0.8125rem;
	font-weight: 600;
}

.nb-timeline__year {
	font-weight: 600;
}

.nb-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
	gap: 0.75rem;
}

.nb-gallery img {
	inline-size: 100%;
	block-size: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	border-radius: 8px;
}

.nb-img {
	max-inline-size: 100%;
	block-size: auto;
}

/* ----------------------------- instagram ------------------------------ */

.nb-instagram {
	--nb-ig-cols: 4;
}

@media (min-width: 780px) {
	.nb-instagram {
		--nb-ig-cols: 6;
	}
}

/* ------------------------------- buttons ------------------------------- */

.nb-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.875rem 1.5rem;
	border-radius: 8px;
	border: 1px solid var(--wp--preset--color--red);
	background: var(--wp--preset--color--red);
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	min-block-size: 44px;
	cursor: pointer;
}

.nb-btn:hover {
	background: var(--wp--preset--color--garnet);
	border-color: var(--wp--preset--color--garnet);
	color: #fff;
}

.nb-btn--quiet {
	background: transparent;
	color: var(--wp--preset--color--red);
}

.nb-btn--quiet:hover {
	background: var(--wp--preset--color--red-soft);
	color: var(--wp--preset--color--garnet);
}

.nb-contact {
	display: flex;
	gap: 0.75rem;
	flex-wrap: wrap;
	align-items: center;
}

/* ------------------------------- footer -------------------------------- */

.nb-footer {
	background: var(--wp--preset--color--garnet);
	color: #fff;
	padding-block: 3rem;
	padding-inline: 1.25rem;
	margin-block-start: 4rem;
}

.nb-footer__inner {
	max-inline-size: 72rem;
	margin-inline: auto;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
	gap: 2rem;
}

.nb-footer a {
	color: #fff;
	text-decoration: none;
}

.nb-footer a:hover {
	text-decoration: underline;
}

.nb-footer__legal {
	max-inline-size: 72rem;
	margin: 2rem auto 0;
	padding-block-start: 1.5rem;
	border-block-start: 1px solid rgba(255, 255, 255, 0.2);
	font-size: 0.875rem;
	opacity: 0.85;
}

/* --------------------------- reduced motion ---------------------------- */

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