/**
 * Base Styles & CSS Variables
 * Global styles and design tokens for the portfolio
 */

/* ==================== CSS CUSTOM PROPERTIES ==================== */
:root {
  /* Photography Theme Colors */
  --color-photo-bg: #0a0a0a;
  --color-photo-bg-secondary: #111111;
  --color-photo-text: #fafafa;
  --color-photo-text-muted: #888888;
  --color-photo-accent: #d4af37;

  /* Terminal Theme Colors */
  --color-term-bg: #0d1117;
  --color-term-bg-secondary: #161b22;
  --color-term-bg-tertiary: #1c2128;
  --color-term-text: #c9d1d9;
  --color-term-text-muted: #8b949e;
  --color-term-accent: #00d9ff;
  --color-term-accent-secondary: #00ff41;
  --color-term-accent-warning: #f0b429;
  --color-term-border: #30363d;

  /* Typography */
  --font-display: 'Outfit', sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing Scale */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 2rem;
  --space-xl: 4rem;
  --space-2xl: 8rem;

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-medium: 300ms ease;
  --transition-slow: 600ms ease;

  /* Z-index layers */
  --z-base: 1;
  --z-header: 100;
  --z-overlay: 1000;
}

/* ==================== RESET ==================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: auto;
  /* Handled by JS for smoothness */
  scroll-padding-top: 120px;
}

body {
  font-family: var(--font-body);
  background: var(--color-photo-bg);
  color: var(--color-photo-text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==================== TYPOGRAPHY ==================== */
a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ==================== ACCESSIBILITY ==================== */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-term-accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ==================== UTILITIES ==================== */
.world {
  position: fixed;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-slow), visibility var(--transition-slow);
  overflow-y: auto;
}

.world.active {
  opacity: 1;
  visibility: visible;
}

.hidden {
  display: none;
}