/*
 * Shared styles for [tww_page] HTML pages
 *
 * Hand-written page content (theme/pages/<slug>.php) is wrapped by the
 * [tww_page] shortcode in <div class="tww-page tww-page--<slug>">. Every
 * selector here is scoped under .tww-page so it can't bleed into the rest of
 * the site (blog, WP-editor pages, etc.). Per-page overrides hook off
 * .tww-page--<slug>.
 *
 * Class taxonomy:
 *   .tww-hero / __eyebrow / __title / __lead / __cta
 *   .tww-section-title          section heading (centered)
 *   .tww-section-subtitle       muted tagline under a section heading
 *   .tww-fit / .tww-fit-card    two-up "who this is for" cards
 *   .tww-steps / .tww-step      CSS-counter numbered steps
 *   .tww-outcomes               checklist
 *   .tww-price-callout          highlighted pricing card
 *   .tww-prose                  centered, width-constrained text block
 *   .tww-form-card / __title    form wrapper
 *   .tww-btn / --primary / --ghost / .tww-btn-row   buttons
 */

/* ==========================================================================
   Base wrapper
   ========================================================================== */

.tww-page {
	/* Two tunable width tiers: --tww-wide for full-bleed-ish blocks
	   (cards, feature rows), --tww-text for readable centered text. */
	--tww-wide: 1280px;
	--tww-text: 860px;
	max-width: var(--tww-wide);
	margin: 0 auto;
}

/* The default page template wraps content in .entry-content, whose base
   theme styles cap width at 1200px (and force any <h1> to max-width:700px).
   For [tww_page] content we own all width decisions, so lift those caps when
   .entry-content directly holds a .tww-page. Sections supply their own
   gutters, so the entry-content horizontal padding is dropped too. */
.entry-content:has(> .tww-page) {
	max-width: none;
	padding-left: 0;
	padding-right: 0;
}

.tww-page * {
	box-sizing: border-box;
}

/* Generic section headings */
.tww-page .tww-section-title {
	margin: 96px auto 24px;
	max-width: var(--tww-text);
	padding: 0 24px;
	font-size: 40px;
	font-weight: 800;
	letter-spacing: -0.02em;
	line-height: 1.2;
	text-align: center;
	text-wrap: balance;
	color: #1a1a1a;
}

.tww-page .tww-section-subtitle {
	margin: 0 auto 32px;
	max-width: var(--tww-text);
	padding: 0 24px;
	font-size: 22px;
	font-weight: 400;
	line-height: 1.4;
	color: #4b5563;
	text-align: center;
	text-wrap: balance;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.tww-page .tww-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background-color: #1a1a1a;
	color: #ffffff;
	border: none;
	border-radius: 9999px;
	padding: 11px 32px 14px;
	font-family: area-normal, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	font-size: 16px;
	font-weight: 800;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s ease, transform 0.15s ease;
}

/* Win against the theme's .entry-content link-underline rule (same
   specificity, so the anchor-qualified selector + later load order wins). */
.tww-page a.tww-btn,
.tww-page a.tww-btn:hover,
.tww-page a.tww-btn:focus {
	text-decoration: none;
}

.tww-page .tww-btn:hover,
.tww-page .tww-btn:focus {
	color: #ffffff;
	transform: translateY(-1px);
}

.tww-page .tww-btn--primary {
	background-color: #2563eb;
}

.tww-page .tww-btn--primary:hover,
.tww-page .tww-btn--primary:focus {
	background-color: #1d4ed8;
}

.tww-page .tww-btn--ghost {
	background-color: #eef2ff;
	color: #1a1a1a;
}

.tww-page .tww-btn--ghost:hover,
.tww-page .tww-btn--ghost:focus {
	background-color: #e0e7ff;
	color: #1a1a1a;
}

.tww-page .tww-btn-row {
	display: flex;
	gap: 14px;
	flex-wrap: wrap;
	justify-content: center;
	margin: 0;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.tww-page .tww-hero {
	max-width: 1120px;
	margin: 56px auto 72px;
	padding: 0 24px;
	text-align: center;
}

.tww-page .tww-hero__eyebrow {
	font-size: 14px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	color: #6b7280;
	margin: 0 0 24px;
	line-height: 1.3;
}

.tww-page .tww-hero__title {
	font-family: area-normal, system-ui, sans-serif;
	font-size: clamp(36px, 4.8vw, 58px);
	font-weight: 900;
	letter-spacing: -0.02em;
	line-height: 1.05;
	margin: 0 auto 20px;
	max-width: none;
	text-wrap: balance;
	color: #1a1a1a;
}

.tww-page .tww-hero__lead p {
	font-size: 27px;
	font-weight: 600;
	line-height: 1.45;
	color: #4b5563;
	max-width: 720px;
	margin: 0 auto 24px;
	text-wrap: balance;
}

.tww-page .tww-hero__lead p:last-child {
	margin-bottom: 0;
}

.tww-page .tww-hero__lead a {
	color: #2563eb;
	text-decoration: underline;
}

.tww-page .tww-hero__cta {
	margin: 36px 0 0;
}

/* Hero video — sits under the buttons, rounded with a soft shadow */
.tww-page .tww-hero__video {
	max-width: 980px;
	margin: 56px auto 0;
}

.tww-page .tww-hero__video-frame {
	position: relative;
	aspect-ratio: 16 / 9;
	border-radius: 16px;
	overflow: hidden;
	box-shadow:
		0 4px 12px rgba(15, 23, 42, 0.08),
		0 24px 60px rgba(15, 23, 42, 0.12);
}

.tww-page .tww-hero__video-frame iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

/* ==========================================================================
   Feature blocks — alternating text + visual (Loom-style)
   ========================================================================== */

.tww-page .tww-feature {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 64px;
	align-items: center;
	max-width: var(--tww-wide);
	margin: 112px auto;
	padding: 0 24px;
}

/* Flip the visual to the left for alternating rhythm */
.tww-page .tww-feature--reverse .tww-feature__media {
	order: -1;
}

.tww-page .tww-feature__title {
	font-size: 36px;
	font-weight: 800;
	letter-spacing: -0.02em;
	line-height: 1.15;
	margin: 0 0 18px;
	color: #1a1a1a;
	text-wrap: balance;
}

.tww-page .tww-feature__text p {
	font-size: 19px;
	line-height: 1.65;
	color: #374151;
	margin: 0 0 16px;
	text-wrap: pretty;
}

.tww-page .tww-feature__text p:last-child {
	margin-bottom: 0;
}

.tww-page .tww-feature__text a {
	color: #2563eb;
	text-decoration: underline;
	text-underline-offset: 2px;
	font-weight: 600;
}

.tww-page .tww-feature__text a:hover {
	color: #1d4ed8;
}

.tww-page .tww-feature__media {
	border-radius: 24px;
	background: #eef2ff;
	aspect-ratio: 4 / 3;
	overflow: hidden;
}

/* Per-block panel tints for visual variety */
.tww-page .tww-feature__media--violet {
	background: #f5edff;
}

.tww-page .tww-feature__media--mint {
	background: #e7f8f1;
}

.tww-page .tww-feature__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* ==========================================================================
   Who this is for — two-up cards
   ========================================================================== */

.tww-page .tww-fit {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 24px;
	max-width: var(--tww-wide);
	margin: 48px auto 96px;
	padding: 0 24px;
}

.tww-page .tww-fit-card {
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 16px;
	padding: 32px 32px 24px;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 8px 24px rgba(15, 23, 42, 0.04);
}

.tww-page .tww-fit-card__title {
	margin: 0 0 18px;
	font-size: 18px;
	font-weight: 700;
	letter-spacing: -0.01em;
	color: #1a1a1a;
}

.tww-page .tww-fit-card ul {
	margin: 0;
	padding-left: 20px;
}

.tww-page .tww-fit-card li {
	font-size: 16px;
	line-height: 1.6;
	margin-bottom: 12px;
	color: #1f2937;
	text-wrap: pretty;
}

.tww-page .tww-fit-card li:last-child {
	margin-bottom: 0;
}

/* ==========================================================================
   How it works — CSS-counter numbered steps
   ========================================================================== */

.tww-page .tww-steps {
	counter-reset: tww-step;
	max-width: 1120px;
	margin: 48px auto 96px;
	padding: 0 24px;
}

.tww-page .tww-step {
	counter-increment: tww-step;
	display: grid;
	grid-template-columns: 140px 1fr;
	column-gap: 32px;
	padding: 32px 0;
	border-top: 1px solid #e5e7eb;
}

.tww-page .tww-step:first-child {
	border-top: none;
	padding-top: 8px;
}

.tww-page .tww-step::before {
	content: counter(tww-step, decimal-leading-zero);
	font-family: area-normal, system-ui, sans-serif;
	font-size: 88px;
	font-weight: 200;
	line-height: 1;
	color: #d1d5db;
	letter-spacing: -0.03em;
	grid-column: 1;
	grid-row: 1;
	align-self: start;
}

.tww-page .tww-step > * {
	grid-column: 2;
}

.tww-page .tww-step__title {
	margin: 0 0 16px;
	font-size: 26px;
	font-weight: 700;
	letter-spacing: -0.01em;
	color: #1a1a1a;
}

.tww-page .tww-step p {
	margin: 0 0 16px;
	font-size: 17px;
	line-height: 1.7;
	color: #374151;
	text-wrap: pretty;
}

.tww-page .tww-step p:last-child {
	margin-bottom: 0;
}

/* ==========================================================================
   Outcomes checklist
   ========================================================================== */

.tww-page .tww-outcomes {
	list-style: none;
	max-width: var(--tww-text);
	margin: 32px auto 64px;
	padding: 0 24px;
}

.tww-page .tww-outcomes li {
	position: relative;
	padding: 12px 0 12px 46px;
	font-size: 18px;
	line-height: 1.5;
	color: #374151;
	text-wrap: pretty;
}

.tww-page .tww-outcomes li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 11px;
	width: 28px;
	height: 28px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='12' fill='%23e0e7ff'/%3E%3Cpath d='M6.5 12.5l3.5 3.5 7.5-8' stroke='%232563eb' stroke-width='2.25' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-size: contain;
	background-repeat: no-repeat;
}

.tww-page .tww-outcomes li strong {
	color: #1a1a1a;
	font-weight: 700;
}

/* ==========================================================================
   Pricing callout
   ========================================================================== */

.tww-page .tww-price-callout {
	max-width: 820px;
	margin: 40px auto 64px;
	padding: 28px 36px;
	background: #eff6ff;
	border: 1px solid #dbeafe;
	border-radius: 16px;
	text-align: center;
	font-size: 17px;
	line-height: 1.6;
	color: #1f2937;
}

.tww-page .tww-price-callout strong {
	color: #1a1a1a;
	font-weight: 700;
}

/* ==========================================================================
   Prose section — centered, width-constrained text
   ========================================================================== */

.tww-page .tww-prose {
	max-width: 820px;
	margin: 0 auto;
	padding: 0 24px;
}

.tww-page .tww-prose p {
	font-size: 18px;
	line-height: 1.7;
	color: #374151;
	text-align: center;
	margin: 0 0 20px;
	text-wrap: balance;
}

.tww-page .tww-prose p:last-child {
	margin-bottom: 0;
}

/* ==========================================================================
   Form card
   ========================================================================== */

.tww-page .tww-form-card {
	max-width: 1040px;
	margin: 96px auto;
	padding: 48px 48px 40px;
	background: #f9fafb;
	border: 1px solid #e5e7eb;
	border-radius: 20px;
	scroll-margin-top: 24px;
}

.tww-page .tww-form-card__title {
	margin: 0 0 24px;
	text-align: left;
	font-size: 32px;
	font-weight: 800;
	letter-spacing: -0.02em;
	color: #1a1a1a;
}

.tww-page .tww-form-card .gform_wrapper,
.tww-page .tww-form-card form {
	margin: 0;
}

.tww-page .tww-form-card input[type="text"],
.tww-page .tww-form-card input[type="email"],
.tww-page .tww-form-card select,
.tww-page .tww-form-card textarea {
	background: #ffffff;
	border: 1px solid #d1d5db;
	border-radius: 10px;
	padding: 12px 14px;
	font-size: 16px;
	font-family: area-normal, system-ui, sans-serif;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.tww-page .tww-form-card input[type="text"]:focus,
.tww-page .tww-form-card input[type="email"]:focus,
.tww-page .tww-form-card select:focus,
.tww-page .tww-form-card textarea:focus {
	outline: none;
	border-color: #2563eb;
	box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.tww-page .tww-form-card label,
.tww-page .tww-form-card .gfield_label {
	font-weight: 600;
	font-size: 14px;
	color: #374151;
}

.tww-page .tww-form-card button[type="submit"],
.tww-page .tww-form-card input[type="submit"],
.tww-page .tww-form-card .gform_button {
	background-color: #2563eb !important;
	color: #ffffff !important;
}

.tww-page .tww-form-card button[type="submit"]:hover,
.tww-page .tww-form-card input[type="submit"]:hover,
.tww-page .tww-form-card .gform_button:hover {
	background-color: #1d4ed8 !important;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 768px) {
	.tww-page .tww-section-title {
		margin-top: 64px;
		font-size: 28px;
	}

	.tww-page .tww-section-subtitle {
		font-size: 19px;
	}

	.tww-page .tww-hero {
		margin: 24px auto 40px;
	}

	.tww-page .tww-hero__title {
		font-size: clamp(32px, 8vw, 44px);
	}

	.tww-page .tww-hero__lead p {
		font-size: 20px;
	}

	.tww-page .tww-hero__video {
		margin-top: 36px;
	}

	.tww-page .tww-hero__video-frame {
		border-radius: 12px;
	}

	.tww-page .tww-feature {
		grid-template-columns: 1fr;
		gap: 32px;
		margin: 64px auto;
	}

	/* Keep the visual below the text on mobile, even for reversed blocks */
	.tww-page .tww-feature--reverse .tww-feature__media {
		order: 0;
	}

	.tww-page .tww-feature__title {
		font-size: 28px;
	}

	.tww-page .tww-feature__media {
		border-radius: 18px;
	}

	.tww-page .tww-fit {
		grid-template-columns: 1fr;
		gap: 16px;
		margin: 32px auto 64px;
	}

	.tww-page .tww-fit-card {
		padding: 24px;
	}

	.tww-page .tww-steps {
		margin: 32px auto 64px;
	}

	.tww-page .tww-step {
		grid-template-columns: 1fr;
		row-gap: 8px;
		padding: 40px 0;
	}

	.tww-page .tww-step::before {
		grid-column: 1;
		font-size: 56px;
		margin-bottom: 8px;
	}

	.tww-page .tww-step > * {
		grid-column: 1;
	}

	.tww-page .tww-step__title {
		font-size: 22px;
	}

	.tww-page .tww-form-card {
		padding: 28px 20px;
		border-radius: 16px;
		margin: 64px 16px;
	}

	.tww-page .tww-form-card__title {
		font-size: 24px;
	}
}
