/* THEME
---------------------------------------------------- */
/* Contains all global theme variables, typography settings, and basic theme elements */

/* Color Variables
---------------------------------------------------- */
:root {
  /* Use brand colors from variables.css - no overrides needed */
  
  /* Background colors */
  --color-bg-body: var(--neutral-bg);
  --color-bg-card: #FFFFFF;
  --color-bg-alt: var(--neutral-alt);
  
  /* Border colors */
  --color-border: var(--neutral-border);
  --color-border-light: var(--neutral-alt);
  
  /* Status colors */
  --color-success: #28a745;
  --color-danger: #dc3545;
  --color-warning: #ffc107;
  --color-info: #17a2b8;
  
  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
  
  /* Spacing */
  --space-xs: 0.25rem;  /* 4px */
  --space-sm: 0.5rem;   /* 8px */
  --space-md: 1rem;     /* 16px */
  --space-lg: 2rem;     /* 32px */
  --space-xl: 3rem;     /* 48px */
  --space-2xl: 4rem;    /* 64px */
  
  /* Border radius */
  --radius-sm: 0.25rem;  /* 4px */
  --radius-md: 0.5rem;   /* 8px */
  --radius-lg: 1rem;     /* 16px */
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 300ms ease;
  --transition-slow: 500ms ease;
  
  /* Z-index layers */
  --z-below: -1;
  --z-normal: 1;
  --z-above: 10;
  --z-fixed: 100;
  --z-modal: 1000;
  --z-tooltip: 1500;
  --z-max: 9999;
}

/* Dark Theme Variables
---------------------------------------------------- */
@media (prefers-color-scheme: dark) {
  :root {
    /* Use brand colors from variables.css - no overrides needed */
  }
}

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

body {
  font-family: var(--font-family-primary);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-primary);
  font-weight: 700;
  line-height: 1.2;
  margin-top: 0;
  margin-bottom: var(--space-md);
  color: var(--color-dark);
}

@media (prefers-color-scheme: dark) {
  h1, h2, h3, h4, h5, h6 {
    color: var(--color-light);
  }
}

h1 {
  font-size: 2.5rem; /* 40px */
}

h2 {
  font-size: 2rem; /* 32px */
}

h3 {
  font-size: 1.75rem; /* 28px */
}

h4 {
  font-size: 1.5rem; /* 24px */
}

h5 {
  font-size: 1.25rem; /* 20px */
}

h6 {
  font-size: 1rem; /* 16px */
}

p {
  margin-top: 0;
  margin-bottom: var(--space-md);
}

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

a:hover, a:focus {
  color: var(--color-primary-dark);
  text-decoration: underline;
}

/* Responsive typography */
@media (max-width: 768px) {
  html {
    font-size: 15px;
  }
  
  h1 {
    font-size: 2.25rem; /* 36px */
  }
  
  h2 {
    font-size: 1.75rem; /* 28px */
  }
  
  h3 {
    font-size: 1.5rem; /* 24px */
  }
}

@media (max-width: 480px) {
  html {
    font-size: 14px;
  }
  
  h1 {
    font-size: 2rem; /* 32px */
  }
  
  h2 {
    font-size: 1.625rem; /* 26px */
  }
}

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

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

/* Focus styles for accessibility */
:focus-visible {
  outline: 3px solid var(--color-primary-light);
  outline-offset: 2px;
}

/* Selection styling */
::selection {
  background-color: var(--color-primary);
  color: white;
}

/* Lists */
ul, ol {
  padding-left: 1.5rem;
  margin-top: 0;
  margin-bottom: var(--space-md);
}

li {
  margin-bottom: 0.5rem;
}

/* Code and pre */
code {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.9em;
  padding: 0.2em 0.4em;
  background-color: var(--color-bg-alt);
  border-radius: var(--radius-sm);
}

pre {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.9em;
  padding: 1rem;
  margin: 0 0 var(--space-md);
  background-color: var(--color-bg-alt);
  border-radius: var(--radius-md);
  overflow-x: auto;
}

pre code {
  padding: 0;
  background-color: transparent;
  border-radius: 0;
}

/* Dividers */
hr {
  height: 1px;
  background-color: var(--color-border);
  border: none;
  margin: var(--space-lg) 0;
}

/* Blockquote - Basic styling, enhanced styles in brand-system.css */
blockquote {
  margin: var(--space-md) 0;
  padding: var(--space-md) var(--space-lg);
  border-left: 4px solid var(--color-primary);
  background-color: var(--color-bg-alt);
  color: var(--color-text);
  font-style: italic;
}

blockquote p:last-child {
  margin-bottom: 0;
}

/* Form elements base styles */
input, select, textarea, button {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: var(--space-md);
}

th, td {
  padding: 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

th {
  font-weight: 600;
  background-color: var(--color-bg-alt);
}

/* Animation Utilities */
.anim-fade {
  animation: fade-in var(--transition-normal);
}

.anim-slide-up {
  animation: slide-up var(--transition-normal);
}

.anim-slide-down {
  animation: slide-down var(--transition-normal);
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slide-up {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes slide-down {
  from { transform: translateY(-20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
} 
