/**
 * Global Styles
 * Site-wide styles and utilities
 */
:root {
  font-size: 16px;

  /* Font Families */
  --font-family-base: 'TeleNeo', sans-serif;
  --font-family-mono: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code',
    'Fira Mono', 'Roboto Mono', monospace;

  /* Font Sizes */
  --font-xs: 0.75rem;
  --font-sm: 0.875rem;
  --font-base: 1rem;
  --font-lg: 1.25rem;
  --font-xl: 1.5rem;
  --font-2xl: 1.8rem;
  --font-3xl: 2rem;
  --font-4xl: 2.5rem;
  --font-5xl: 3rem;

  /* Font Weights */
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;

  /* Letter Spacing */
  --tracking-tighter: -0.05em;
  --tracking-tight: -0.025em;
  --tracking-normal: 0;
  --tracking-wide: 0.025em;
  --tracking-wider: 0.05em;
  --tracking-widest: 0.1em;

  /* Colors */
  --color-primary: #05295e;
  --color-border-dark: #333333;
  --color-primary-dark: #03193a;
  --color-primary-light: #0a3d8f;
  --color-text: #000000;
  --color-text-muted: #6c757d;
  --color-placeholder: #575757;
  --color-white: #ffffff;
  --color-border: #444444;
  --color-border-light: #e0e2e7;
  --color-light-gray: #f6f6f6;
  --color-accent: #05295e;
  --color-accent-dark: #03193a;
  --color-success: #16a34a;
  --color-error: #dc2626;
  --color-error-dark: #991b1b;
  --color-error-bg: #fef2f2;
  --color-success: #188a8a;
  --color-success-dark: #165c65;
  --color-success-bg: #f0fdf4;
  --color-warning: #fbbf24;
  --color-warning-dark: #92400e;
  --color-warning-bg: #fef3c7;

  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-full: 9999px;

  /* Other */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;
  --outline-size: max(2px, 0.25rem);
  --outline-style: solid;
  --outline-offset: var(--outline-size);
  --transition: 0.2s ease;
  --shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  --md-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 0 3px 6px rgba(0, 0, 0, 0.23);
}

/**
 * CSS Reset
 * Minimal reset for consistent cross-browser styling
 */

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

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

html {
  -webkit-text-size-adjust: 100%;
  -moz-tab-size: 4;
  tab-size: 4;
}

body {
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

/* ============================================
   BASE STYLES
   ============================================ */

html,
body {
  height: 100%;
}

body {
  font-family: var(--font-family-base);
  color: var(--color-text);
  background-color: var(--color-background);
  margin: 0;
  font-size: var(--text-base);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Sticky Footer Layout */
.body-wrapper {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  grid-template-areas:
    'header'
    'main'
    'footer';
}

.body-wrapper > div:first-child {
  grid-area: header;
}

.body-wrapper > main {
  grid-area: main;
}

.body-wrapper > div:last-child {
  grid-area: footer;
}

/* ============================================
   HEADINGS
   ============================================ */

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: var(--font-semibold);
  line-height: var(--leading-tight);
  margin-top: 0;
  margin-bottom: 0.5em;
}

h1 {
  font-size: var(--text-5xl);
}

h2 {
  font-size: var(--text-4xl);
}

h3 {
  font-size: var(--text-3xl);
}

h4 {
  font-size: var(--text-2xl);
}

h5 {
  font-size: var(--text-xl);
}

h6 {
  font-size: var(--text-lg);
}

/* ============================================
   TEXT ELEMENTS
   ============================================ */

p {
  margin-top: 0;
  margin-bottom: 1em;
}

a {
  color: inherit;
  text-decoration: underline;
}

strong,
b {
  font-weight: var(--font-bold);
}

em,
i {
  font-style: italic;
}

small {
  font-size: var(--text-sm);
}

code,
kbd,
samp,
pre {
  font-family: var(--font-family-mono);
  font-size: 0.9em;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.container {
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

/* WARNING: Avoid using this class. Visible text is almost always better for
   both accessibility and usability. If you think you need to hide text visually,
   reconsider the design. This class exists only for rare legitimate use cases. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.focus-visible:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.font-normal {
  font-weight: var(--font-normal);
}

.font-medium {
  font-weight: var(--font-medium);
}

.font-semibold {
  font-weight: var(--font-semibold);
}

.font-bold {
  font-weight: var(--font-bold);
}

.text-xs {
  font-size: var(--text-xs);
}

.text-sm {
  font-size: var(--text-sm);
}

.text-base {
  font-size: var(--text-base);
}

.text-lg {
  font-size: var(--text-lg);
}

.text-xl {
  font-size: var(--text-xl);
}

.text-2xl {
  font-size: var(--text-2xl);
}

.text-3xl {
  font-size: var(--text-3xl);
}

.text-4xl {
  font-size: var(--text-4xl);
}

.text-5xl {
  font-size: var(--text-5xl);
}
