/**
 * RDVIET Design System (Tokens, Typography, Grid & Base Utilities)
 *
 * Style: Modern Engineering / Industrial Technology / Minimal Corporate
 * Palette:
 *   Navy:     #0B1F33
 *   Cyan:     #0DAFC2
 *   Dark CTA: #006E80
 *   Ice:      #EAF8FA
 *   Gray:     #F5F7FA
 *   White:    #FFFFFF
 *   Text:     #263445
 *   Border:   #DFE7EE
 */

:root {
	/* Brand Color Tokens */
	--rd-navy: #0B1F33;
	--rd-navy-light: #132F4C;
	--rd-cyan: #0DAFC2;
	--rd-cyan-hover: #0B99AA;
	--rd-cta-dark: #006E80;
	--rd-cta-dark-hover: #005666;
	--rd-ice: #EAF8FA;
	--rd-ice-border: #C5EBF0;
	--rd-gray: #F5F7FA;
	--rd-white: #FFFFFF;
	--rd-text: #263445;
	--rd-text-muted: #475569;
	--rd-border: #DFE7EE;
	--rd-success: #0D9488;
	--rd-surface-dark: #071524;
	--rd-accent-gold: #92400E;
	--rd-accent-gold-light: #FEF3C7;
	--rd-warning: #D97706;
	--rd-warning-bg: #FEF3C7;
	--rd-danger: #DC2626;
	--rd-danger-bg: #FEE2E2;

	/* Typography Tokens */
	--rd-font-sans: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--rd-font-mono: "JetBrains Mono", Consolas, Monaco, "Courier New", monospace;
	--font-heading: var(--rd-font-sans);

	/* Layout & Grid */
	--rd-container: 1200px;
	--rd-reading-width: 860px;

	/* 8px Spacing Scale */
	--sp-1: 8px;
	--sp-2: 16px;
	--sp-3: 24px;
	--sp-4: 32px;
	--sp-5: 40px;
	--sp-6: 48px;
	--sp-8: 64px;
	--sp-10: 80px;
	--sp-12: 96px;

	/* Border Radius (8px - 16px) */
	--radius-sm: 8px;
	--radius-md: 12px;
	--radius-lg: 16px;

	/* Subtle Corporate Elevation */
	--shadow-sm: 0 2px 8px rgba(11, 31, 51, 0.04);
	--shadow-md: 0 12px 28px -6px rgba(11, 31, 51, 0.09);
	--shadow-lg: 0 20px 40px -12px rgba(11, 31, 51, 0.16);
}

/* Base Reset & Box Sizing */
*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	font-size: 16px;
}

body {
	margin: 0;
	background-color: var(--rd-white);
	color: var(--rd-text);
	font-family: var(--rd-font-sans);
	font-size: 1rem;
	line-height: 1.7;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: hidden;
}

/* Override GeneratePress wrapper paddings when full-width sections are used */
.site.grid-container,
#page.site {
	max-width: 100% !important;
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
}

.site-content,
.content-area,
.site-main,
.separate-containers .site-main,
.separate-containers .inside-article,
.one-container .site-content {
	margin: 0 !important;
	padding: 0 !important;
	background: transparent;
	max-width: 100% !important;
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
	color: var(--rd-navy);
	font-family: var(--rd-font-sans);
	font-weight: 700;
	line-height: 1.28;
	margin-top: 0;
	margin-bottom: var(--sp-2);
	letter-spacing: -0.015em;
}

h1 {
	font-size: 2.375rem; /* 38px */
	line-height: 1.22;
}

h2 {
	font-size: 1.875rem; /* 30px */
	line-height: 1.28;
}

h3 {
	font-size: 1.25rem; /* 20px */
	font-weight: 600;
	line-height: 1.35;
}

h4 {
	font-size: 1.0625rem; /* 17px */
	font-weight: 600;
	line-height: 1.4;
}

p {
	margin-top: 0;
	margin-bottom: var(--sp-2);
	color: var(--rd-text);
}

a {
	color: var(--rd-cta-dark);
	text-decoration: none;
	transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

a:hover {
	color: var(--rd-navy);
}

/* Focus Accessibility (WCAG AA) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
	outline: 2px solid var(--rd-navy);
	outline-offset: 3px;
	box-shadow: 0 0 0 3px var(--rd-white);
}

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

code,
pre {
	font-family: var(--rd-font-mono);
}

/* Container & 12-Column Grid System */
.rd-container {
	width: 100%;
	max-width: var(--rd-container);
	margin-left: auto;
	margin-right: auto;
	padding-left: var(--sp-3);
	padding-right: var(--sp-3);
}

.rd-grid-12 {
	display: grid;
	grid-template-columns: repeat(12, minmax(0, 1fr));
	gap: var(--sp-3);
}

.rd-grid-2 {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--sp-3);
}

.rd-grid-3 {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: var(--sp-3);
}

.rd-grid-4 {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: var(--sp-3);
}

/* Section Wrappers & Background Tokens */
.rd-section {
	padding-top: var(--sp-10);
	padding-bottom: var(--sp-10);
	position: relative;
}

.rd-section-sm {
	padding-top: var(--sp-6);
	padding-bottom: var(--sp-6);
}

.rd-bg-white {
	background-color: var(--rd-white);
}

.rd-bg-gray {
	background-color: var(--rd-gray);
	border-top: 1px solid var(--rd-border);
	border-bottom: 1px solid var(--rd-border);
}

.rd-bg-ice {
	background-color: var(--rd-ice);
	border-top: 1px solid var(--rd-ice-border);
	border-bottom: 1px solid var(--rd-ice-border);
}

.rd-bg-navy {
	background-color: var(--rd-navy);
	color: var(--rd-white);
}

.rd-bg-navy h1,
.rd-bg-navy h2,
.rd-bg-navy h3,
.rd-bg-navy h4,
.rd-contact-banner h1,
.rd-contact-banner h2,
.rd-contact-banner h3,
.rd-contact-banner h4 {
	color: var(--rd-white);
}

.rd-bg-navy p,
.rd-contact-info p {
	color: #E2E8F0;
}

/* Section Header Standard */
.rd-section-header {
	max-width: 720px;
	margin-bottom: var(--sp-6);
}

.rd-section-header.is-center {
	margin-left: auto;
	margin-right: auto;
	text-align: center;
}

.rd-section-header-split {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: var(--sp-3);
	margin-bottom: var(--sp-5);
}

.rd-kicker {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 0.75rem; /* 12px */
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--rd-cta-dark);
	background-color: var(--rd-ice);
	border: 1px solid var(--rd-ice-border);
	padding: 5px 12px;
	border-radius: 999px;
	margin-bottom: 12px;
}

.rd-kicker::before {
	content: "";
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background-color: var(--rd-cyan);
}

.rd-bg-navy .rd-kicker,
.rd-contact-banner .rd-kicker {
	background-color: rgba(13, 175, 194, 0.16);
	border-color: rgba(13, 175, 194, 0.42);
	color: #5CE1E6;
}

.rd-section-desc {
	font-size: 1.0625rem;
	color: var(--rd-text-muted);
	margin-bottom: 0;
}

/* Reduced Motion Support */
@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;
	}
}
