/* 🌊 SHAMAN Base Styles */

/* 🧹 CSS Reset & Normalization */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* 🎯 Base Typography */
html {
  font-size: 16px;
  font-family: var(--font-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-primary);
  font-size: var(--font-base);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* 🎨 Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-md);
  color: var(--text-highlight);
}

h1 {
  font-size: var(--font-4xl);
  text-shadow: var(--shadow-terminal);
}

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

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

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

h5 {
  font-size: var(--font-lg);
}

h6 {
  font-size: var(--font-base);
}

/* 📝 Text Elements */
p {
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
}

a {
  color: var(--electric-surf-blue);
  text-decoration: none;
  transition: var(--transition-fast);
  border-bottom: 1px solid transparent;
}

a:hover {
  color: var(--electric-surf-blue-light);
  border-bottom-color: var(--electric-surf-blue-light);
  text-shadow: var(--shadow-electric);
}

/* 📋 Lists */
ul, ol {
  padding-left: var(--space-lg);
  margin-bottom: var(--space-md);
}

li {
  margin-bottom: var(--space-xs);
  color: var(--text-secondary);
}

/* 💻 Code Elements */
code {
  font-family: var(--font-secondary);
  background: var(--bg-secondary);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--border-radius-sm);
  color: var(--terminal-green);
  font-size: 0.9em;
}

pre {
  background: var(--bg-secondary);
  padding: var(--space-md);
  border-radius: var(--border-radius-md);
  overflow-x: auto;
  margin-bottom: var(--space-md);
  border: 1px solid var(--terminal-green-dark);
}

pre code {
  background: none;
  padding: 0;
}

/* 🔔 Selection */
::selection {
  background: var(--electric-surf-blue);
  color: var(--deep-sea-blue);
}

::-moz-selection {
  background: var(--electric-surf-blue);
  color: var(--deep-sea-blue);
}

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

/* 🎯 Focus Styles */
*:focus {
  outline: 2px solid var(--electric-surf-blue);
  outline-offset: 2px;
}

/* 🌊 Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--deep-sea-blue-dark);
}

::-webkit-scrollbar-thumb {
  background: var(--terminal-green);
  border-radius: var(--border-radius-sm);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--terminal-green-light);
}

/* 🧙‍♂️ Terminal Cursor Animation */
@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

.terminal-cursor::after {
  content: var(--cursor-char);
  animation: var(--cursor-blink);
  color: var(--terminal-green);
}

/* 🌈 Glitch Effect for Headers */
@keyframes glitch {
  0% { text-shadow: 0.05em 0 0 var(--rip-current-pink), -0.05em -0.025em 0 var(--electric-surf-blue), 0.025em 0.05em 0 var(--offshore-yellow); }
  15% { text-shadow: 0.05em 0 0 var(--rip-current-pink), -0.05em -0.025em 0 var(--electric-surf-blue), 0.025em 0.05em 0 var(--offshore-yellow); }
  16% { text-shadow: -0.05em -0.025em 0 var(--rip-current-pink), 0.025em 0.025em 0 var(--electric-surf-blue), -0.05em -0.05em 0 var(--offshore-yellow); }
  49% { text-shadow: -0.05em -0.025em 0 var(--rip-current-pink), 0.025em 0.025em 0 var(--electric-surf-blue), -0.05em -0.05em 0 var(--offshore-yellow); }
  50% { text-shadow: 0.025em 0.05em 0 var(--rip-current-pink), 0.05em 0 0 var(--electric-surf-blue), 0 -0.05em 0 var(--offshore-yellow); }
  99% { text-shadow: 0.025em 0.05em 0 var(--rip-current-pink), 0.05em 0 0 var(--electric-surf-blue), 0 -0.05em 0 var(--offshore-yellow); }
  100% { text-shadow: -0.025em 0 0 var(--rip-current-pink), -0.025em -0.025em 0 var(--electric-surf-blue), -0.025em -0.05em 0 var(--offshore-yellow); }
}

.glitch {
  animation: glitch 1s linear infinite;
}

/* 🎨 Utility Classes */
.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-accent { color: var(--text-accent); }
.text-highlight { color: var(--text-highlight); }
.text-alert { color: var(--text-alert); }

.bg-primary { background: var(--bg-primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-overlay { background: var(--bg-overlay); }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.terminal-font { font-family: var(--font-secondary); }
