/* Custom Grid Background Pattern */
.bg-grid-pattern {
  background-size: 40px 40px;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
}

/* Light Mode Overrides */
html:not(.dark) {
  color-scheme: light;
}

html:not(.dark) body {
  background-color: #f8fafc;
  color: #0f172a;
}

html:not(.dark) .bg-slate-950 {
  background-color: #ffffff !important;
}

html:not(.dark) .bg-slate-950\/80 {
  background-color: rgba(255, 255, 255, 0.85) !important;
}

html:not(.dark) .bg-slate-950\/60 {
  background-color: #f1f5f9 !important;
}

html:not(.dark) .bg-slate-900\/90,
html:not(.dark) .bg-slate-900\/60,
html:not(.dark) .bg-slate-900\/40 {
  background-color: #ffffff !important;
}

html:not(.dark) .border-slate-800,
html:not(.dark) .border-slate-800\/80,
html:not(.dark) .border-slate-700 {
  border-color: #e2e8f0 !important;
}

html:not(.dark) .text-white {
  color: #0f172a !important;
}

html:not(.dark) .text-slate-100 {
  color: #1e293b !important;
}

html:not(.dark) .text-slate-200 {
  color: #334155 !important;
}

html:not(.dark) .text-slate-300 {
  color: #475569 !important;
}

html:not(.dark) .text-slate-400 {
  color: #64748b !important;
}

html:not(.dark) .bg-slate-800 {
  background-color: #e2e8f0 !important;
  color: #1e293b !important;
}

html:not(.dark) .bg-grid-pattern {
  background-image: 
    linear-gradient(to right, rgba(15, 23, 42, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.04) 1px, transparent 1px);
}

/* Skill Badges */
.skill-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.65rem;
  font-size: 0.75rem;
  font-family: "Fira Code", monospace;
  font-weight: 500;
  border-radius: 0.5rem;
  background-color: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(51, 65, 85, 0.7);
  color: #e2e8f0;
  transition: all 0.2s ease;
}

html:not(.dark) .skill-badge {
  background-color: #f1f5f9;
  border-color: #cbd5e1;
  color: #1e293b;
}

.skill-badge:hover {
  border-color: #22d3ee;
  color: #22d3ee;
  transform: translateY(-1px);
}

/* Filter Buttons */
.skill-filter-btn {
  background-color: rgba(30, 41, 59, 0.5);
  border: 1px solid rgba(51, 65, 85, 0.8);
  color: #94a3b8;
}

html:not(.dark) .skill-filter-btn {
  background-color: #ffffff;
  border-color: #cbd5e1;
  color: #64748b;
}

.skill-filter-btn.active-filter {
  background-color: #06b6d4 !important;
  border-color: #06b6d4 !important;
  color: #020617 !important;
  font-weight: 700;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #020617;
}

html:not(.dark) ::-webkit-scrollbar-track {
  background: #f8fafc;
}

::-webkit-scrollbar-thumb {
  background: #1e293b;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #0891b2;
}

/* ===================================================
   PRINT STYLES: Generates a Clean Printable CV on Ctrl+P
   =================================================== */
@media print {
  /* Hide interactive web chrome */
  header,
  footer,
  #toast,
  #theme-toggle,
  #mobile-menu-btn,
  #photo-upload-input,
  .bg-grid-pattern,
  .fixed.inset-0,
  #skill-filter-container,
  button,
  .animate-pulse,
  .animate-ping {
    display: none !important;
  }

  body {
    background: #ffffff !important;
    color: #111827 !important;
    font-size: 11pt;
    line-height: 1.4;
    padding: 0 !important;
    margin: 0 !important;
  }

  main {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    space-y: 1.5rem !important;
  }

  section {
    padding-top: 1rem !important;
    page-break-inside: avoid;
  }

  .border,
  .border-slate-800,
  .border-cyan-500\/30 {
    border: 1px solid #e5e7eb !important;
    box-shadow: none !important;
  }

  .bg-slate-900\/60,
  .bg-slate-950\/60,
  .bg-slate-900\/90,
  .bg-slate-900\/40,
  .bg-gradient-to-br {
    background: #ffffff !important;
  }

  h1, h2, h3, h4, .text-white {
    color: #111827 !important;
  }

  p, span, li, .text-slate-300, .text-slate-400 {
    color: #374151 !important;
  }

  .text-cyan-400,
  .text-cyan-300,
  .text-blue-400,
  .text-emerald-400 {
    color: #0369a1 !important;
  }

  .skill-badge {
    background: #f3f4f6 !important;
    border: 1px solid #d1d5db !important;
    color: #1f2937 !important;
    font-size: 8pt !important;
    padding: 2px 6px !important;
  }

  a {
    text-decoration: none !important;
    color: #111827 !important;
  }
}
