/* css/style.css */

:root {
  --primary-yellow: #FFDD00;
  --primary-black: #050505;
  --secondary-black: #111111;
  --signal-green: #00FF41;
  --warning-red: #FF3333;
  --crt-green: #33FF33;
  --text-color: #FFFFFF;
  --border-color: #333333;
  --font-tech: 'Courier New', Courier, monospace;
  --font-ui: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --spacing-unit: 8px;
}

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

body {
  background-color: var(--primary-black);
  color: var(--text-color);
  font-family: var(--font-ui);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-tech);
  text-transform: uppercase;
  letter-spacing: 1px;
}

h1 { color: var(--primary-yellow); margin-bottom: 1rem; }
h2 { border-bottom: 2px solid var(--primary-yellow); padding-bottom: 0.5rem; margin-bottom: 1.5rem; }

/* Layout Utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}

.grid {
  display: grid;
  gap: 2rem;
}

.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

/* Header & Nav */
header {
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 0;
  background: var(--secondary-black);
}

nav ul {
  display: flex;
  gap: 2rem;
}

nav a {
  font-family: var(--font-tech);
  color: var(--text-color);
  transition: color 0.3s;
  font-weight: bold;
}

nav a:hover, nav a.active {
  color: var(--primary-yellow);
  text-shadow: 0 0 8px rgba(255, 221, 0, 0.5);
}

/* CRT Effects */
.crt-container {
  position: relative;
  overflow: hidden;
  border: 4px solid var(--secondary-black);
  border-radius: 4px;
  background: #000;
}

.scanlines::before {
  content: " ";
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
  z-index: 2;
  background-size: 100% 2px, 3px 100%;
  pointer-events: none;
}

/* UI Elements */
.btn {
  display: inline-block;
  background: transparent;
  border: 2px solid var(--primary-yellow);
  color: var(--primary-yellow);
  padding: 10px 20px;
  font-family: var(--font-tech);
  font-weight: bold;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 1rem;
}

.btn:hover:not(:disabled) {
  background: var(--primary-yellow);
  color: var(--primary-black);
  box-shadow: 0 0 15px var(--primary-yellow);
}

.btn:disabled {
  border-color: var(--border-color);
  color: var(--border-color);
  cursor: not-allowed;
}

.card {
  background: var(--secondary-black);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: 4px;
}

/* Forms */
input[type="file"] {
  display: block;
  margin-bottom: 1rem;
  padding: 10px;
  border: 1px solid var(--border-color);
  background: #000;
  color: #fff;
  width: 100%;
}

label {
  font-family: var(--font-tech);
  color: var(--primary-yellow);
  display: block;
  margin-bottom: 0.5rem;
}

/* Canvas & Visualization */
canvas {
  width: 100%;
  height: auto;
  background: #000;
  display: block;
}

#waterfall-display {
  height: 200px;
  border-top: 1px solid var(--primary-yellow);
}

/* Meters */
.meter-container {
  height: 20px;
  background: #333;
  margin-top: 10px;
  position: relative;
  border-radius: 2px;
  overflow: hidden;
}

.meter-fill {
  height: 100%;
  background: var(--signal-green);
  width: 0%;
  transition: width 0.1s linear;
}

.meter-fill.clipping {
  background: var(--warning-red);
}

/* Footer */
footer {
  margin-top: auto;
  padding: 2rem 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
  font-family: var(--font-tech);
  color: #666;
  font-size: 0.8rem;
}

/* Helper */
.hidden { display: none !important; }
.text-center { text-align: center; }
.mb-2 { margin-bottom: 1rem; }
.mt-2 { margin-top: 1rem; }
.social-links {
            display: flex;
            gap: 20px;
            margin-top: 10px;
        }
        
        .social-icon {
            width: 24px;
            height: 24px;
            fill: #888;
            transition: fill 0.3s, transform 0.3s;
        }
        
        .social-icon:hover {
            fill: var(--primary-yellow);
            transform: scale(1.1);
        }
