/*
 * The DEV Point — base reset & typography.
 */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body {
	margin: 0;
	font-family: var(--tdp-font-sans);
	font-size: var(--tdp-font-body);
	color: var(--tdp-text);
	background: var(--tdp-white);
	line-height: 1.65;
	overflow-x: hidden;
}

img,
svg,
video {
	max-width: 100%;
	height: auto;
	display: block;
}

h1, h2, h3, h4, h5, h6 {
	color: var(--tdp-heading);
	font-weight: 700;
	line-height: 1.15;
	margin: 0 0 0.5em;
	letter-spacing: -0.015em;
}

/* Inner-page H1 (48-60px desktop). The larger homepage hero uses
   .tdp-hero-title instead (see sections.css). */
h1 { font-size: clamp(2.25rem, 1.75rem + 2vw, 3.75rem); }
h2 { font-size: clamp(1.875rem, 1.5rem + 1.6vw, 3rem); }
h3 { font-size: clamp(1.375rem, 1.25rem + 0.55vw, 1.75rem); }

p {
	margin: 0 0 1em;
}

a {
	color: var(--tdp-primary);
	text-decoration: none;
	transition: color var(--tdp-transition);
}

a:hover {
	color: var(--tdp-secondary);
}

ul, ol {
	margin: 0;
	padding: 0;
	list-style: none;
}

button {
	font-family: inherit;
}

/* Accessible, visible keyboard focus states everywhere */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
	outline: 2px solid var(--tdp-primary);
	outline-offset: 2px;
	border-radius: 2px;
}

/* Screen-reader only text */
.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Skip link — visible only on keyboard focus */
.tdp-skip-link {
	position: fixed;
	top: -80px;
	left: 1rem;
	z-index: 10000;
	background: var(--tdp-heading);
	color: var(--tdp-white);
	padding: 0.75rem 1.25rem;
	border-radius: var(--tdp-radius-sm);
	transition: top var(--tdp-transition);
}

.tdp-skip-link:focus {
	top: 1rem;
	color: var(--tdp-white);
}

/* Shared page container */
.tdp-container {
	width: 100%;
	max-width: var(--tdp-container);
	margin-inline: auto;
	padding-inline: 1.5rem;
}

.tdp-container-narrow {
	width: 100%;
	max-width: var(--tdp-container-narrow);
	margin-inline: auto;
	padding-inline: 1.5rem;
}

/* Section rhythm + alternating backgrounds. Desktop-first value here;
   responsive.css scales it down for tablet/mobile. */
.tdp-section {
	padding-block: var(--tdp-space-section);
}

.tdp-section-tight {
	padding-block: calc(var(--tdp-space-section) * 0.6);
}

.tdp-section-grey {
	background: var(--tdp-light-grey);
}

.tdp-section-blue {
	background: var(--tdp-pale-blue);
}

.tdp-section-soft-blue {
	background: var(--tdp-soft-blue);
}

/* High-contrast dark section — used sparingly (roughly one per page) for
   visual rhythm, never as the default background. */
.tdp-section-navy {
	background: var(--tdp-navy);
	color: rgba(255, 255, 255, 0.82);
}

.tdp-section-navy h1,
.tdp-section-navy h2,
.tdp-section-navy h3,
.tdp-section-navy h4 {
	color: var(--tdp-white);
}

.tdp-section-navy .tdp-section-description,
.tdp-section-navy p {
	color: rgba(255, 255, 255, 0.78);
}

.tdp-section-navy .tdp-eyebrow {
	background: rgba(255, 255, 255, 0.1);
	color: var(--tdp-soft-blue);
}

.tdp-section-navy a:not(.tdp-btn) {
	color: var(--tdp-highlight);
}

.tdp-section-navy a:not(.tdp-btn):hover {
	color: var(--tdp-white);
}

.tdp-section-heading {
	max-width: 42rem;
	margin: 0 auto 3.5rem;
}

.tdp-section-heading.tdp-align-left {
	margin-inline: 0;
	text-align: left;
}

/* Large rounded visual panels (hero frames, image placeholders, feature
   panels) share this radius across the redesign. */
.tdp-panel-radius {
	border-radius: var(--tdp-radius-lg);
}

.tdp-mt-lg {
	margin-top: 2.5rem;
}

.tdp-mt-0 {
	margin-top: 0;
}

.tdp-py-lg {
	padding-block: 2.5rem;
}

.tdp-inline-link {
	font-weight: 600;
}

.tdp-align-center {
	text-align: center;
}

.tdp-narrow-center {
	max-width: 40rem;
	margin-inline: auto;
}

.tdp-eyebrow {
	display: inline-block;
	background: var(--tdp-pale-blue);
	color: var(--tdp-secondary);
	font-size: 0.875rem;
	font-weight: 600;
	padding: 0.35rem 1rem;
	border-radius: var(--tdp-radius-full);
	margin-bottom: 1rem;
}

.tdp-section-description {
	font-size: 1.125rem;
	color: var(--tdp-text);
	margin-top: 1rem;
}

/* Buttons */
.tdp-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.85rem 1.75rem;
	border-radius: var(--tdp-radius-full);
	font-weight: 600;
	font-size: 1rem;
	border: 1px solid transparent;
	cursor: pointer;
	transition: background-color var(--tdp-transition), color var(--tdp-transition), transform var(--tdp-transition), border-color var(--tdp-transition);
	line-height: 1.2;
}

.tdp-btn-primary {
	background: var(--tdp-primary);
	color: var(--tdp-white);
	box-shadow: var(--tdp-shadow-sm);
}

.tdp-btn-primary:hover {
	background: var(--tdp-secondary);
	color: var(--tdp-white);
	transform: translateY(-1px);
}

.tdp-btn-outline {
	background: transparent;
	color: var(--tdp-text);
	border-color: var(--tdp-border);
}

.tdp-btn-outline:hover {
	background: var(--tdp-light-grey);
	color: var(--tdp-heading);
}

.tdp-btn-light {
	background: var(--tdp-white);
	color: var(--tdp-heading);
	box-shadow: var(--tdp-shadow-md);
}

.tdp-btn-light:hover {
	transform: translateY(-1px);
	color: var(--tdp-secondary);
}

.tdp-btn-full {
	width: 100%;
}

/* Outline button variant readable on the dark navy section background. */
.tdp-btn-outline-light {
	background: transparent;
	color: var(--tdp-white);
	border-color: rgba(255, 255, 255, 0.35);
}

.tdp-btn-outline-light:hover {
	background: rgba(255, 255, 255, 0.1);
	color: var(--tdp-white);
	border-color: rgba(255, 255, 255, 0.6);
}

/* Scroll-reveal: .tdp-reveal elements are visible by default. main.js only
   opts in to the hidden/animate-in state — by adding .tdp-reveal-armed to
   <html> — once it has confirmed JS is running, IntersectionObserver
   exists, and the visitor hasn't requested reduced motion (see
   initScrollReveal() in main.js). If JS never runs, throws, or is
   disabled, .tdp-reveal elements simply keep this default visible state;
   content can never be hidden without a working reveal mechanism behind
   it. */
.tdp-reveal-armed .tdp-reveal {
	opacity: 0;
	transform: translateY(20px);
	transition: opacity var(--tdp-transition-slow), transform var(--tdp-transition-slow);
}

.tdp-reveal-armed .tdp-reveal.tdp-in-view {
	opacity: 1;
	transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
	/* Belt-and-suspenders: main.js already skips arming reveal when reduced
	   motion is requested, but this keeps content visible purely via CSS
	   too, regardless of JS. Matches .tdp-reveal-armed .tdp-reveal's
	   specificity so it wins the cascade even if armed. */
	.tdp-reveal-armed .tdp-reveal,
	.tdp-reveal {
		opacity: 1;
		transform: none;
		transition: none;
	}
	html {
		scroll-behavior: auto;
	}
	.tdp-mega-menu,
	.tdp-nav-chevron,
	.tdp-primary-nav,
	.tdp-header {
		transition: none !important;
	}
}
