/* Base Styles - Reset & Typography */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* Allow iOS Dynamic Type and text size controls */
    -webkit-text-size-adjust: auto;
    -moz-text-size-adjust: auto;
    text-size-adjust: auto;
}

body {
    font-family: 'Public Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: var(--leading-normal);
    color: var(--text-primary);
    font-size: var(--font-size-base);
    overflow-x: hidden;
    background: var(--off-white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    touch-action: manipulation;
    padding-top: 96px; /* Space for fixed navigation (nav is ~93px tall) */
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Prevent horizontal scroll */
html, body {
    max-width: 100%;
    overflow-x: hidden;
}

/* Typography Hierarchy */
.section-title {
    font-family: 'Adriano Etc', 'Courier New', monospace;
    font-size: var(--font-size-4xl);
    color: var(--medium-blue);
    margin-bottom: var(--space-xl);
    font-weight: var(--font-black);
    line-height: var(--leading-tight);
    letter-spacing: -0.02em;
    transition: color var(--transition-base);
}

.content-section {
    margin-bottom: var(--space-2xl);
}

.content-section h2 {
    font-family: 'Adriano Etc', 'Courier New', monospace;
    font-size: var(--font-size-3xl);
    color: var(--medium-blue);
    margin-bottom: var(--space-md);
    font-weight: var(--font-bold);
    line-height: var(--leading-snug);
    letter-spacing: -0.01em;
    transition: color var(--transition-base);
}

.content-section h3 {
    font-family: 'Adriano Etc', 'Courier New', monospace;
    font-size: var(--font-size-2xl);
    color: var(--dark-blue);
    margin: var(--space-lg) 0 var(--space-sm);
    font-weight: var(--font-semibold);
    line-height: var(--leading-snug);
    transition: color var(--transition-base);
}

.content-section h4 {
    font-family: 'Adriano Etc', 'Courier New', monospace;
    font-size: var(--font-size-xl);
    color: var(--text-primary);
    margin: var(--space-md) 0 var(--space-xs);
    font-weight: var(--font-semibold);
    line-height: var(--leading-normal);
    transition: color var(--transition-base);
}

.content-section p {
    font-size: var(--font-size-base);
    line-height: var(--leading-relaxed);
    margin-bottom: var(--space-sm);
    color: var(--text-secondary);
    max-width: 70ch;
}

.content-section ul,
.content-section ol {
    margin: var(--space-md) 0;
    padding-left: var(--space-lg);
    color: var(--text-secondary);
    line-height: var(--leading-relaxed);
}

.content-section li {
    margin-bottom: var(--space-xs);
}

/* Links */
a {
    color: var(--text-link);
    transition: color var(--transition-base);
}

a:hover {
    color: var(--bright-blue);
}

a:focus-visible {
    outline: 2px solid var(--medium-blue);
    outline-offset: 3px;
    border-radius: var(--radius-sm);
}

/* Selection */
::selection {
    background-color: var(--light-blue);
    color: var(--dark-blue);
}

::-moz-selection {
    background-color: var(--light-blue);
    color: var(--dark-blue);
}

/* Focus Visible Support */
*:focus {
    outline: none;
}

*:focus-visible {
    outline: 2px solid var(--medium-blue);
    outline-offset: 3px;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.text-primary {
    color: var(--text-primary);
}

.text-secondary {
    color: var(--text-secondary);
}

.text-tertiary {
    color: var(--text-tertiary);
}
