/**
 * Base Styles
 * ============================================================================
 * This file contains foundational layout and typography styles that form
 * the base layer of the CSS architecture.
 *
 * Load order: After reset.css and 00-tokens.css, before component styles
 * Dependencies: 00-tokens.css (design tokens)
 *
 * Contents:
 * 1. Body/HTML defaults
 * 2. Layout containers (.content, .container)
 * 3. Links
 * 4. Typography defaults (headings, hr)
 * 5. Typography utilities (.sub-heading)
 * 6. List utilities (.icon-list)
 * 7. Layout utilities (.two-col, .three-col)
 */

/* ==========================================================================
   1. BODY/HTML DEFAULTS
   ========================================================================== */

body,
html {
	background-color: var(--white);
	color: var(--black);
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 22px;
}

#content {
	position: relative;
}

/* ==========================================================================
   2. LAYOUT CONTAINERS
   ========================================================================== */

/**
 * Content and Container
 * Canonical definition for page width constraint.
 * These classes center content and apply consistent padding.
 *
 * IMPORTANT: Horizontal padding uses --content-padding-x which is responsive
 * (defined in 00-tokens.css with breakpoints). Component CSS should NOT override
 * padding-left/right directly - instead override the variable if needed:
 *
 *   .special-panel .content { --content-padding-x: 100px; }
 */
.content,
.container {
	margin: 0 auto;
	max-width: var(--container-xl);
	padding-left: var(--content-padding-x);
	padding-right: var(--content-padding-x);
	width: 100%; /* Required for flex children (e.g., .nav-container > .content) */
}

/* ==========================================================================
   3. LINKS
   ========================================================================== */

a {
	color: var(--link-color);
	text-decoration: underline;
}

/* ==========================================================================
   4. TYPOGRAPHY
   ========================================================================== */

/* Utility class for Archivo heading font */
.font-archivo,
h1, h2, h3, h4, h5, h6,
.simpay-styled .simpay-form-title,
.simpay-styled .simpay-form-description {
	font-family: var(--font-heading);
}

/* Horizontal Rule */
hr {
	background: var(--border-grey);
	border: 0;
	height: 1px;
	margin-bottom: 30px;
}

/* Heading defaults */
h1,
h2,
h3,
h4,
h5,
h6 {
	/* Font-family handled by utility class .font-archivo above */
}

h2 {
	font-size: 34px;
	font-weight: 900;
	line-height: 34px;
	margin-bottom: 30px;
}

h3 {
	font-size: 24px;
	font-weight: 900;
	line-height: 30px;
	margin-bottom: var(--space-8);
}

/* ==========================================================================
   5. TYPOGRAPHY UTILITIES
   ========================================================================== */

/**
 * Sub-heading utility
 * Use for secondary headings within sections.
 * Uses --heading-sub token for consistent sizing across the site.
 */
.sub-heading {
	font-size: var(--heading-sub);
	font-weight: var(--font-bold);
	letter-spacing: var(--heading-sub-ls);
	line-height: var(--heading-sub-lh);
}

/* ==========================================================================
   6. LIST UTILITIES
   ========================================================================== */

/**
 * Icon List utility
 * Flex-based list with icon + text items.
 * Usable in panels, blog, widgets, or any context.
 */
.icon-list {
	list-style-type: none;
	margin: 0;
	padding: 0;
}

.icon-list li {
	align-items: center;
	display: flex;
	gap: var(--space-4);
	margin-bottom: var(--space-4);
}

.icon-list img,
.icon-list svg {
	flex-shrink: 0;
}

/* Large variant with more spacing */
.icon-list--lg li {
	gap: var(--space-6);
	margin-bottom: var(--space-6);
}

/* ==========================================================================
   7. LAYOUT UTILITIES
   ========================================================================== */

/**
 * Two-column layout utility
 * Responsive flex layout that stacks at 768px.
 */
.two-col {
	display: flex;
	gap: 5%;
}

.two-col > * {
	flex: 1 1 47.5%;
	min-width: 0;
}

@media (max-width: 768px) {
	.two-col {
		flex-direction: column;
		gap: var(--space-9);
	}

	.two-col > * {
		flex: 1 1 100%;
	}
}

/**
 * Three-column layout utility
 * Responsive flex layout: 3 cols → 2 cols (768px) → 1 col (480px).
 */
.three-col {
	display: flex;
	gap: 3%;
}

.three-col > * {
	flex: 1 1 31%;
	min-width: 0;
}

@media (max-width: 768px) {
	.three-col {
		flex-wrap: wrap;
	}

	.three-col > * {
		flex: 1 1 48%;
	}
}

@media (max-width: 480px) {
	.three-col {
		flex-direction: column;
		gap: var(--space-6);
	}

	.three-col > * {
		flex: 1 1 100%;
	}
}
