/* ============================================
   JOBHAVENHUB - DESIGN SYSTEM
   ============================================ */

/* === GOOGLE FONTS === */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Orbitron:wght@400;500;600;700;800;900&display=swap');

/* === CSS VARIABLES === */
:root {
  /* =========================================
     LIGHT MODE (DEFAULT)
     Clean, professional, high readability
     ========================================= */
  --color-bg-primary: #ffffff;
  --color-bg-secondary: #f8f9fa;
  --color-bg-tertiary: #e9ecef;
  --color-bg-card: #ffffff;
  --color-bg-card-hover: #f0f4f8;

  --color-text-primary: #111827;
  --color-text-secondary: #4b5563;
  --color-text-tertiary: #6b7280;
  --color-text-muted: #9ca3af;

  --color-accent: #2563eb;
  --color-accent-cyan: #0284c7;
  /* darker cyan for light mode readability */
  --color-accent-purple: #7c3aed;
  --color-accent-indigo: #4f46e5;

  --color-border: #e2e8f0;
  --color-hover: #f1f5f9;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  --gradient-secondary: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  --gradient-dark: linear-gradient(180deg, #ffffff 0%, #f8f9fa 100%);
  --gradient-glow: linear-gradient(135deg, rgba(37, 99, 235, 0.1) 0%, rgba(124, 58, 237, 0.1) 100%);

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-glow-primary: 0 4px 14px 0 rgba(37, 99, 235, 0.39);
  --shadow-glow-cyan: 0 4px 14px 0 rgba(2, 132, 199, 0.39);

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2.5rem;
  --spacing-xl: 4rem;
  --spacing-2xl: 5rem;

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Orbitron', sans-serif;

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* Background effects visible in both modes (handled by JS) */
canvas,
.hero-glow {
  display: block;
}

/* The background canvas must be fixed-position so it overlays the page
   without adding to the document's layout height and causing a blank space. */
canvas#space-hero-bg,
canvas#network-bg,
canvas#shiva-hero-bg,
canvas#matrix-bg,
canvas#grid-bg,
canvas#hands-hero-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
}


/* =========================================
   DARK MODE (THEME OVERRIDES)
   Your original dark aesthetic
   ========================================= */
body.dark-mode {
  --color-bg-primary: #000000;
  --color-bg-secondary: #050814;
  --color-bg-tertiary: #0a0e1a;
  --color-bg-card: rgba(255, 255, 255, 0.03);
  --color-bg-card-hover: rgba(255, 255, 255, 0.07);

  --color-text-primary: #F5F5F5;
  --color-text-secondary: #A0A0A0;
  --color-text-tertiary: #707070;
  --color-text-muted: #6b7280;

  --color-accent: #F5F5F5;
  --color-accent-cyan: #00D9FF;
  /* Neon Cyan */
  --color-accent-green: #00FF41;
  /* Breaking Bad Chemistry Green — for verified/success */
  --color-accent-purple: #a855f7;
  --color-accent-indigo: #6366f1;
  --color-danger: #ff3333;
  /* For warnings and fake listing indicators */

  --color-border: rgba(255, 255, 255, 0.1);
  --color-hover: rgba(255, 255, 255, 0.05);

  --gradient-primary: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
  --gradient-secondary: linear-gradient(135deg, #FFFFFF 0%, #808080 100%);
  --gradient-dark: linear-gradient(180deg, #000000 0%, #0a0a0a 100%);
  --gradient-glow: linear-gradient(135deg, rgba(0, 217, 255, 0.2) 0%, rgba(168, 85, 247, 0.2) 100%);
  --gradient-verified: linear-gradient(135deg, rgba(0, 255, 65, 0.15) 0%, rgba(0, 217, 255, 0.1) 100%);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow-primary: 0 0 20px rgba(37, 99, 235, 0.5);
  --shadow-glow-cyan: 0 0 20px rgba(0, 217, 255, 0.4);
  --shadow-glow-green: 0 0 20px rgba(0, 255, 65, 0.3);
}

/* =========================================
   FILM GRAIN OVERLAY (Nolan Cinematic)
   Subtle analog texture over dark mode
   ========================================= */
body.dark-mode::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

/* === RESET & BASE === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  background: var(--color-bg-primary);
  color: var(--color-text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* Space Background Canvas & Unique Page Backgrounds */
#space-hero-bg,
#network-bg,
#shiva-hero-bg,
#matrix-bg,
#grid-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: var(--color-bg-primary);
}

/* === TYPOGRAPHY === */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-sm);
}

h1 {
  font-size: clamp(3rem, 8vw, 6rem);
  font-family: var(--font-primary);
  font-weight: 800;
  color: var(--color-text-primary);
  letter-spacing: -2px;
  line-height: 1.1;
}

/* Cinematic hero title glow (Nolan IMAX style) */
body.dark-mode h1 {
  text-shadow: 0 0 40px rgba(255, 255, 255, 0.08), 0 0 80px rgba(0, 217, 255, 0.04);
}

/* Split layout specifically for home hero */
.hero-title {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 3rem;
  align-items: center;
}

.hero-title span {
  display: inline-block;
  white-space: nowrap;
}

/* Specific styling to match xAI "Understand The Universe" */
.hero-title-left {
  text-align: right;
  flex: 1;
  min-width: fit-content;
}

.hero-title-right {
  text-align: left;
  flex: 1;
  min-width: fit-content;
  color: var(--color-text-secondary);
  /* Subtle contrast */
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-family: var(--font-primary);
  font-weight: 600;
  color: var(--color-text-primary);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

p {
  margin-bottom: var(--spacing-sm);
  color: var(--color-text-secondary);
}

a {
  color: var(--color-accent-cyan);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-accent-cyan);
}

/* === BUTTONS === */
.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  text-align: center;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
  color: #ffffff;
  box-shadow: var(--shadow-glow-primary);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.4);
}

/* === BUTTONS === */
.btn-secondary {
  background: transparent;
  color: var(--color-text-primary);
  border: 2px solid var(--color-border);
}

.btn-secondary:hover {
  background: var(--color-hover);
  color: var(--color-accent);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.btn-ghost {
  background: var(--color-hover);
  color: var(--color-text-primary);
  backdrop-filter: blur(10px);
  border: 1px solid var(--color-border);
}

.btn-ghost:hover {
  background: var(--color-hover);
  border-color: var(--color-text-secondary);
}

/* === CARDS === */
.card {
  background: var(--color-bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-glow);
  opacity: 0;
  transition: opacity var(--transition-normal);
  pointer-events: none;
}

.card:hover {
  background: var(--color-bg-card-hover);
  border-color: rgba(0, 255, 255, 0.6);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg), 0 0 40px rgba(0, 255, 255, 0.15);
}

.card:hover::before {
  opacity: 1;
}

/* Verified job cards get a subtle green border glow (Breaking Bad) */
body.dark-mode .job-card[data-verified="true"] {
  border-color: rgba(0, 255, 65, 0.15);
}

body.dark-mode .job-card[data-verified="true"]:hover {
  border-color: rgba(0, 255, 65, 0.5);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(0, 255, 65, 0.15), 0 0 60px rgba(0, 255, 65, 0.05);
}

/* === BADGES === */
.badge {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-success {
  background: rgba(0, 255, 65, 0.1);
  color: #00FF41;
  border: 1px solid rgba(0, 255, 65, 0.3);
  text-shadow: 0 0 8px rgba(0, 255, 65, 0.3);
  font-family: var(--font-display);
  letter-spacing: 1px;
}

/* Light mode verified badge — subtler green */
:root .badge-success {
  background: rgba(22, 163, 74, 0.1);
  color: #15803d;
  border: 1px solid rgba(22, 163, 74, 0.3);
  text-shadow: none;
}

.badge-info,
.badge-warning,
.badge-purple {
  background: rgba(255, 255, 255, 0.1);
  color: var(--color-text-primary);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* === LAYOUT === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.container-wide {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.section {
  padding: var(--spacing-2xl) 0;
}

.section-hero {
  padding: 6rem 0 4rem;
  position: relative;
}

/* === HEADER === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--color-bg-secondary);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border);
  z-index: 1000;
  transition: all var(--transition-normal);
}

.header.scrolled {
  box-shadow: var(--shadow-md);
  background: var(--color-bg-secondary);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  font-family: var(--font-display);
  color: var(--color-text-primary);
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-icon {
  font-size: 1.75rem;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
}

.nav {
  display: flex;
  gap: var(--spacing-lg);
  align-items: center;
}

.nav-link {
  color: var(--color-text-secondary);
  font-weight: 500;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width var(--transition-normal);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--color-text-primary);
  border-radius: 2px;
  transition: all var(--transition-normal);
}

/* Dropdown Menu */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: var(--color-bg-secondary);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  margin-top: 0.5rem;
  padding: 0.5rem 0;
}

.dropdown-content a {
  display: block;
  padding: 0.75rem 1.25rem;
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: all var(--transition-fast);
  font-weight: 500;
}

.dropdown-content a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--color-text-primary);
  padding-left: 1.5rem;
}

.dropdown:hover .dropdown-content {
  display: block;
}


/* === HERO SECTION === */
.hero {
  text-align: center;
  position: relative;
  padding-top: 2rem;
}

.hero-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 217, 255, 0.1) 0%, transparent 70%);
  pointer-events: none;
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 0.5;
    transform: translate(-50%, -50%) scale(1);
  }

  50% {
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(1.1);
  }
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--color-accent-cyan);
  font-weight: 600;
  margin-bottom: var(--spacing-sm);
  text-transform: uppercase;
  letter-spacing: 2px;
}

.hero-title {
  margin-bottom: var(--spacing-md);
  line-height: 1.1;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--color-text-secondary);
  max-width: 700px;
  margin: 0 auto var(--spacing-xl);
}

.hero-cta {
  display: flex;
  gap: var(--spacing-md);
  justify-content: center;
  flex-wrap: wrap;
}

/* === STATS SECTION === */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-2xl);
}

.stat-card {
  text-align: center;
  padding: var(--spacing-lg);
  background: var(--color-bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: all var(--transition-normal);
}

.stat-card:hover {
  border-color: var(--color-accent-cyan);
  box-shadow: var(--shadow-glow-cyan);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  font-family: var(--font-display);
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: block;
  margin-bottom: 0.5rem;
}

.stat-label {
  color: var(--color-text-secondary);
  font-size: 1rem;
}

/* === JOB CARDS === */
.jobs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
}

.job-card {
  cursor: pointer;
}

.job-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--spacing-md);
}

.job-company {
  font-size: 0.875rem;
  color: var(--color-accent-cyan);
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.job-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 0.5rem;
}

.job-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
}

.job-meta-item {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

.job-description {
  color: var(--color-text-secondary);
  margin-bottom: var(--spacing-md);
  line-height: 1.6;
}

.job-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: var(--spacing-md);
}

.job-tag {
  padding: 0.25rem 0.75rem;
  background: var(--color-hover);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  color: var(--color-text-secondary);
}

/* =========================================
   PERIODIC TABLE SKILL TAGS (Breaking Bad)
   ========================================= */
.periodic-element {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  padding: 0.25rem 0.5rem;
  min-width: 52px;
  background: rgba(0, 255, 65, 0.05);
  border: 1px solid rgba(0, 255, 65, 0.2);
  border-radius: 3px;
  position: relative;
  text-align: center;
  transition: all var(--transition-normal);
  cursor: default;
}

.periodic-element:hover {
  background: rgba(0, 255, 65, 0.12);
  border-color: rgba(0, 255, 65, 0.5);
  box-shadow: 0 0 12px rgba(0, 255, 65, 0.15);
  transform: translateY(-1px);
}

.element-number {
  font-size: 0.5rem;
  color: var(--color-text-muted);
  line-height: 1;
  font-family: var(--font-display);
}

.element-symbol {
  font-size: 1rem;
  font-weight: 800;
  color: #00FF41;
  line-height: 1.1;
  font-family: var(--font-display);
  text-shadow: 0 0 6px rgba(0, 255, 65, 0.2);
}

.element-name {
  font-size: 0.5rem;
  color: var(--color-text-muted);
  line-height: 1;
  max-width: 60px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Light mode periodic elements — subtler */
:root .element-symbol {
  color: #15803d;
  text-shadow: none;
}

:root .periodic-element {
  background: rgba(22, 163, 74, 0.05);
  border-color: rgba(22, 163, 74, 0.2);
}

:root .periodic-element:hover {
  background: rgba(22, 163, 74, 0.1);
  border-color: rgba(22, 163, 74, 0.4);
  box-shadow: 0 0 10px rgba(22, 163, 74, 0.1);
}

/* =========================================
   HERO ELEMENT (Large periodic table widget
   for learning page hero sections)
   ========================================= */
.hero-element {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 140px;
  background: rgba(0, 255, 65, 0.05);
  border: 2px solid rgba(0, 255, 65, 0.25);
  border-radius: 8px;
  text-align: center;
  margin: 1.5rem auto;
  position: relative;
  transition: all var(--transition-normal);
  animation: elementPulse 3s ease-in-out infinite;
}

.hero-element:hover {
  border-color: rgba(0, 255, 65, 0.6);
  box-shadow: 0 0 30px rgba(0, 255, 65, 0.2), 0 0 60px rgba(0, 255, 65, 0.08);
  transform: translateY(-4px);
}

@keyframes elementPulse {

  0%,
  100% {
    box-shadow: 0 0 15px rgba(0, 255, 65, 0.08);
  }

  50% {
    box-shadow: 0 0 25px rgba(0, 255, 65, 0.15);
  }
}

.hero-element .el-number {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-family: var(--font-display);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.hero-element .el-symbol {
  font-size: 3rem;
  font-weight: 900;
  color: #00FF41;
  font-family: var(--font-display);
  line-height: 1;
  text-shadow: 0 0 15px rgba(0, 255, 65, 0.3);
}

.hero-element .el-name {
  font-size: 0.7rem;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-top: 0.25rem;
}

/* Light mode hero element */
:root .hero-element {
  background: rgba(22, 163, 74, 0.05);
  border-color: rgba(22, 163, 74, 0.25);
}

:root .hero-element .el-symbol {
  color: #15803d;
  text-shadow: none;
}

:root .hero-element:hover {
  border-color: rgba(22, 163, 74, 0.5);
  box-shadow: 0 0 20px rgba(22, 163, 74, 0.15);
}


.job-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--spacing-md);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.job-salary {
  font-weight: 700;
  color: var(--color-accent-cyan);
  font-size: 1.125rem;
}

/* === SEARCH & FILTERS === */
.search-section {
  background: var(--color-bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
}

.search-bar {
  display: flex;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  flex-wrap: wrap;
}

.search-input {
  flex: 1;
  min-width: 250px;
  padding: 1rem 1.25rem;
  background: var(--color-bg-tertiary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-primary);
  font-size: 1rem;
  transition: all var(--transition-normal);
}

.search-input:focus {
  outline: none;
  border-color: var(--color-accent-cyan);
  box-shadow: 0 0 0 3px rgba(0, 217, 255, 0.1);
}

.search-input::placeholder {
  color: var(--color-text-muted);
}

.filter-buttons {
  display: flex;
  gap: var(--spacing-sm);
  flex-wrap: wrap;
}

.filter-btn {
  padding: 0.625rem 1.25rem;
  background: var(--color-bg-tertiary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-normal);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--color-hover);
  border-color: var(--color-text-primary);
  color: var(--color-text-primary);
  box-shadow: var(--shadow-glow-cyan);
}

/* === FOOTER === */
.footer {
  background: var(--color-bg-secondary);
  border-top: 1px solid var(--color-border);
  padding: var(--spacing-2xl) 0 var(--spacing-lg);
  margin-top: var(--spacing-2xl);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
}

.footer-section h3 {
  font-size: 1.125rem;
  margin-bottom: var(--spacing-md);
  color: var(--color-accent-cyan);
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: var(--spacing-sm);
}

.footer-links a {
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--color-accent-cyan);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--spacing-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--color-text-muted);
}

/* === FILTER SELECT DROPDOWNS === */
.filter-select {
  padding: 0.75rem 1rem;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-primary);
  font-size: 0.9375rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-select:hover {
  border-color: var(--color-accent-cyan);
  background: rgba(0, 217, 255, 0.05);
}

.filter-select:focus {
  outline: none;
  border-color: var(--color-accent-cyan);
  box-shadow: 0 0 0 3px rgba(0, 217, 255, 0.1);
}

.filter-select option {
  background: var(--color-bg-primary);
  color: var(--color-text-primary);
}

/* === DARK MODE === */
body.dark-mode {
  --color-bg-primary: #0a0e1a;
  --color-bg-secondary: #131827;
  --color-text-primary: #e8eaed;
  --color-text-secondary: #b8bcc8;
  --color-text-muted: #8a8f9d;
}

body {
  transition: background-color 0.3s ease, color 0.3s ease;
}

.dark-mode-toggle {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-accent-cyan), var(--color-accent-purple));
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 217, 255, 0.3);
  transition: all 0.3s ease;
  z-index: 1000;
}

.dark-mode-toggle:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(0, 217, 255, 0.5);
}

/* === FAQ SECTION === */
.faq-item {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: var(--color-accent-cyan);
}

.faq-question {
  padding: 1.5rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  color: var(--color-text-primary);
  user-select: none;
}

.faq-question:hover {
  color: var(--color-accent-cyan);
}

.faq-icon {
  font-size: 1.25rem;
  transition: transform 0.3s ease;
  color: var(--color-accent-cyan);
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 1.5rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding: 0 1.5rem 1.5rem;
}

/* === BADGE STYLES === */
.badge {
  display: inline-block;
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Report Button */
.btn-report {
  background: none;
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #ef4444;
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 500;
}

.btn-report:hover {
  background: rgba(239, 68, 68, 0.1);
  border-color: #ef4444;
  transform: translateY(-1px);
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background: rgba(5, 8, 20, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: var(--spacing-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transform: translateY(-100%);
    opacity: 0;
    transition: all var(--transition-normal);
    pointer-events: none;
  }

  .nav.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .mobile-overlay {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-normal);
  }

  .mobile-overlay.active {
    opacity: 1;
    pointer-events: all;
  }

  .jobs-grid {
    grid-template-columns: 1fr;
  }

  .hero-cta {
    flex-direction: column;
  }

  .search-bar {
    flex-direction: column;
  }

  .search-input {
    width: 100%;
  }
}

/* === UTILITY CLASSES === */
.text-center {
  text-align: center;
}

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.mt-1 {
  margin-top: var(--spacing-sm);
}

.mt-2 {
  margin-top: var(--spacing-md);
}

.mt-3 {
  margin-top: var(--spacing-lg);
}

.mb-1 {
  margin-bottom: var(--spacing-sm);
}

.mb-2 {
  margin-bottom: var(--spacing-md);
}

.mb-3 {
  margin-bottom: var(--spacing-lg);
}

/* === HERO QUOTE === */
.hero-quote {
  margin-bottom: var(--spacing-xl);
  padding: var(--spacing-lg);
  background: rgba(0, 217, 255, 0.05);
  border-left: 4px solid var(--color-accent-cyan);
  border-radius: var(--radius-md);
}

.quote-text {
  font-size: 1.375rem;
  color: var(--color-text-primary);
  font-weight: 500;
  font-style: italic;
  margin: 0;
  transition: opacity 0.5s ease;
  line-height: 1.6;
  text-align: center;
}

/* === RESOURCES SECTION === */
.resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
}

.resource-category {
  padding: var(--spacing-xl);
}

.resource-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 2px solid rgba(0, 217, 255, 0.2);
}

.resource-icon {
  font-size: 2.5rem;
  line-height: 1;
  display: none;
  /* Hide since we removed emojis */
}

.resource-header h3 {
  margin-bottom: 0.5rem;
  /* Color set inline per category */
}

.resource-description {
  color: var(--color-text-muted);
  font-size: 0.9375rem;
  margin: 0;
}

.resource-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.resource-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
  text-decoration: none;
  color: inherit;
}

.resource-item:hover {
  background: rgba(0, 217, 255, 0.08);
  border-color: var(--color-accent-cyan);
  transform: translateX(4px);
}

.resource-type {
  font-size: 0.75rem;
  line-height: 1;
  flex-shrink: 0;
  background: rgba(0, 217, 255, 0.15);
  color: var(--color-accent-cyan);
  padding: 0.375rem 0.625rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  letter-spacing: 0.5px;
}

.resource-info {
  flex: 1;
  min-width: 0;
}

.resource-title {
  font-weight: 600;
  color: var(--color-text-primary);
  margin-bottom: 0.375rem;
  font-size: 1rem;
}

.resource-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  align-items: center;
  font-size: 0.8125rem;
}

.resource-author {
  color: var(--color-text-muted);
}

.resource-duration {
  color: var(--color-accent-purple);
  font-weight: 500;
}

.resource-level {
  font-size: 0.75rem;
  padding: 0.25rem 0.625rem;
}

@media (max-width: 768px) {
  .resources-grid {
    grid-template-columns: 1fr;
  }

  .quote-text {
    font-size: 1rem;
    padding: 0 1rem;
  }
}

/* === DROPDOWN MENU STYLES === */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--color-bg-card);
  min-width: 220px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  border-radius: var(--radius-md);
  border: 1px solid rgba(0, 217, 255, 0.2);
  z-index: 1000;
  padding: 0.5rem 0;
  backdrop-filter: blur(10px);
}

.dropdown-content a {
  color: var(--color-text-primary);
  padding: 0.75rem 1.5rem;
  text-decoration: none;
  display: block;
  transition: all var(--transition-fast);
  font-size: 0.9375rem;
  cursor: pointer;
}

.dropdown-content a:hover {
  background: rgba(0, 217, 255, 0.1);
  color: var(--color-accent-cyan);
  padding-left: 1.75rem;
}

.dropdown:hover .dropdown-content,
.dropdown-content:hover,
.dropdown:focus-within .dropdown-content {
  display: block;
  animation: fadeInDown 0.3s ease-out;
}

/* Touch-friendly dropdown for mobile */
@media (hover: none) and (pointer: coarse) {
  .dropdown-content {
    display: none;
    position: static;
    box-shadow: none;
    background: transparent;
    padding: 0.5rem 0 0.5rem 1rem;
    border: none;
  }
  .dropdown:focus-within .dropdown-content,
  .dropdown.active .dropdown-content {
    display: block;
  }
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================
   NOLAN SPINNING TOP TOTEM
   ========================================= */
.spinning-top-container {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 60px;
  height: 60px;
  z-index: 1000;
  pointer-events: auto;
  cursor: pointer;
  filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.3));
  transition: transform 0.3s ease;
}

.spinning-top-container:hover {
  transform: scale(1.1);
}

.spinning-top {
  width: 100%;
  height: 100%;
  animation: spin 5s linear infinite;
  /* Infinite spin... or is it? */
  transform-origin: center center;
}

/* Wobble effect on hover to simulate instability */
.spinning-top-container:hover .spinning-top {
  animation: spin 2s linear infinite, wobble 1s ease-in-out infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes wobble {

  0%,
  100% {
    transform: rotate(0deg) skewX(0deg);
  }

  25% {
    transform: rotate(90deg) skewX(5deg);
  }

  50% {
    transform: rotate(180deg) skewX(0deg);
  }

  75% {
    transform: rotate(270deg) skewX(-5deg);
  }
}

/* SIMPLE 2D TOP */
.spinning-top-simple {
  width: 100%;
  height: 100%;
  animation: rotateSimple 4s linear infinite;
}

@keyframes rotateSimple {
  from {
    transform: rotateY(0deg);
  }

  to {
    transform: rotateY(360deg);
  }
}

.section-alternate {
  background: var(--color-bg-secondary);
}

body.dark-mode .section-alternate {
  background: #050505;
}

/* ============================================
   ANTI-SCRAPING PROTECTIONS
   ============================================ */

/* Prevent text selection on job card content (not inputs/buttons) */
.job-card .job-title,
.job-card .job-company,
.job-card .job-description,
.job-card .job-salary,
.job-card .job-meta {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

/* Keep inputs, buttons, and search selectable */
.search-input,
.filter-select,
.btn,
textarea,
input {
  -webkit-user-select: auto;
  -moz-user-select: auto;
  -ms-user-select: auto;
  user-select: auto;
}

/* Invisible watermark on job cards — shows when copy-pasted */
.job-card::after {
  content: '© JobHavenHub - jobhavenhub.com | Unauthorized reproduction prohibited';
  position: absolute;
  bottom: -9999px;
  left: -9999px;
  font-size: 0;
  color: transparent;
  pointer-events: none;
  -webkit-user-select: all;
  user-select: all;
}

/* Prevent image dragging */
img {
  -webkit-user-drag: none;
  pointer-events: none;
}

/* Disable print styling to prevent print-scraping */
@media print {

  .jobs-grid,
  .job-card,
  #jobsGrid {
    display: none !important;
  }

  body::after {
    content: 'Job listings are only available at jobhavenhub.com';
    display: block;
    text-align: center;
    padding: 4rem;
    font-size: 1.5rem;
  }
}

/* =========================================
   SCROLL REVEAL ANIMATIONS
   Elements fade in + slide up on scroll
   ========================================= */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered delays for grids — cards animate one by one */
.reveal-delay-1 {
  transition-delay: 0.1s;
}

.reveal-delay-2 {
  transition-delay: 0.2s;
}

.reveal-delay-3 {
  transition-delay: 0.3s;
}

.reveal-delay-4 {
  transition-delay: 0.4s;
}

.reveal-delay-5 {
  transition-delay: 0.5s;
}

.reveal-delay-6 {
  transition-delay: 0.6s;
}

/* Scale-up variant for stats and badges */
.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.reveal-scale.revealed {
  opacity: 1;
  transform: scale(1);
}

/* Slide-in from left */
.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal-left.revealed {
  opacity: 1;
  transform: translateX(0);
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {

  .reveal,
  .reveal-scale,
  .reveal-left {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* =========================================
   LOADING SKELETON (shown while API loads)
   ========================================= */

.skeleton-card {
  opacity: 0.6;
}

.skeleton-line {
  background: linear-gradient(90deg,
      rgba(255, 255, 255, 0.04) 25%,
      rgba(255, 255, 255, 0.08) 50%,
      rgba(255, 255, 255, 0.04) 75%);
  background-size: 200% 100%;
  border-radius: var(--radius-sm);
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
}

@keyframes skeleton-shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* =========================================
   RESPONSIVE - TABLET (≤ 1024px)
   ========================================= */
@media (max-width: 1024px) {
  .container {
    padding: 0 1.5rem;
  }

  .hero-title {
    font-size: 3rem;
  }

  .hero-description {
    font-size: 1rem;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

  .jobs-grid,
  #jobsGrid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================
   RESPONSIVE - MOBILE (≤ 768px)
   ========================================= */
@media (max-width: 768px) {

  /* === TYPOGRAPHY === */
  .hero-title {
    font-size: 2.25rem;
    line-height: 1.2;
  }

  .hero-subtitle {
    font-size: 0.8rem;
  }

  .hero-description {
    font-size: 0.9375rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  /* === LAYOUT === */
  .container {
    padding: 0 1rem;
  }

  .section {
    padding: 3rem 0;
  }

  .section-hero {
    padding: 6rem 0 3rem;
  }

  /* === NAVIGATION === */
  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75%;
    max-width: 320px;
    height: 100vh;
    background: var(--color-bg-card);
    flex-direction: column;
    padding: 5rem 2rem 2rem;
    gap: 0.5rem;
    transition: right 0.3s ease;
    z-index: 999;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.3);
    overflow-y: auto;
  }

  .nav.active {
    right: 0;
  }

  .nav .nav-link {
    padding: 0.75rem 0;
    font-size: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    width: 100%;
  }

  .nav .btn {
    margin-top: 1rem;
    text-align: center;
    width: 100%;
  }

  .menu-toggle {
    display: flex;
    z-index: 1000;
  }

  .dropdown-content {
    position: static;
    box-shadow: none;
    background: transparent;
    padding: 0 0 0 1rem;
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  /* === HERO CTA === */
  .hero-cta {
    flex-direction: column;
    gap: 0.75rem;
    align-items: stretch;
  }

  .hero-cta .btn {
    width: 100%;
    text-align: center;
  }

  /* === SEARCH & FILTERS === */
  .search-bar {
    flex-direction: column;
    gap: 0.75rem;
  }

  .search-bar input {
    width: 100%;
  }

  .search-bar .btn {
    width: 100%;
  }

  .filter-bar {
    flex-direction: column;
    gap: 0.75rem;
  }

  .filter-bar select {
    width: 100%;
  }

  .filter-buttons {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .filter-buttons .btn {
    font-size: 0.8125rem;
    padding: 0.5rem 1rem;
  }

  /* === STATS === */
  .stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .stat h3 {
    font-size: 2rem;
  }

  .stat p {
    font-size: 0.8125rem;
  }

  /* === JOB CARDS === */
  .jobs-grid,
  #jobsGrid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .job-header {
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
  }

  .job-header>div:last-child {
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
  }

  .job-meta {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .job-footer {
    flex-direction: column;
    gap: 0.75rem;
    align-items: flex-start;
  }

  .job-footer .btn {
    width: 100%;
    text-align: center;
  }

  .job-tags {
    flex-wrap: wrap;
  }

  /* === FOOTER === */
  .footer-content {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    text-align: center;
  }

  .footer-section {
    text-align: center;
  }

  /* === HERO ELEMENT (periodic table) === */
  .hero-element {
    width: 90px;
    height: 105px;
    margin: 1rem auto;
  }

  .hero-element .el-symbol {
    font-size: 2.25rem;
  }

  .hero-element .el-number {
    font-size: 0.625rem;
  }

  .hero-element .el-name {
    font-size: 0.6rem;
  }

  /* === HOW WE VERIFY === */
  .verification-grid,
  .verify-steps {
    grid-template-columns: 1fr;
  }

  /* === DARK MODE TOGGLE === */
  .dark-mode-toggle {
    bottom: 1rem;
    right: 1rem;
    width: 45px;
    height: 45px;
    font-size: 1.25rem;
  }

  /* === ABOUT PAGE GRID === */
  .about-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================
   RESPONSIVE - SMALL MOBILE (≤ 480px)
   ========================================= */
@media (max-width: 480px) {
  .hero-title {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
  }

  .stat h3 {
    font-size: 1.5rem;
  }

  .card {
    padding: 1.25rem;
  }

  .section {
    padding: 2rem 0;
  }

  .section-hero {
    padding: 5rem 0 2rem;
  }

  .filter-buttons .btn {
    font-size: 0.75rem;
    padding: 0.4rem 0.75rem;
  }

  .hero-element {
    width: 75px;
    height: 90px;
  }

  .hero-element .el-symbol {
    font-size: 1.75rem;
  }

  .footer-bottom p {
    font-size: 0.8125rem;
  }
}
/* Accessibility */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--color-accent-cyan);
  color: #fff;
  padding: 10px 15px;
  z-index: 10000;
  font-weight: bold;
  transition: top 0.2s ease;
}
.skip-link:focus {
  top: 0;
}
:focus-visible {
  outline: 2px solid var(--color-accent-cyan);
  outline-offset: 3px;
}
