/* Font imports – already linked in HTML */
.shadows-into-light-regular {
  font-family: "Shadows Into Light", cursive;
  font-weight: 400;
  font-style: normal;
}

/* Theme Switchers */

:root,
[data-theme="light"] {
  --text-color: #000;
  --nav-color: #ffaa33;
  --background-color: #f5f0e0;
  --main-color: #ff8c42;
  --accent-color: #ffaa33;
  --glitch-color: #ff8c42;
  --container-bg: #2f2f2f;
  --container-border: #ff8c42;
  --container-text: var(--nav-color);
  --shadow-color: #000;
  --background-toggle: #f5f0e0;
  --header-color: #ff8c42;
}

[data-theme="dark"] {
  --text-color: #00bfff;
  --nav-color: var(--text-color);
  --background-color: #051229;
  --main-color: #0a1f3a;
  --accent-color: #1e4a8c;
  --glitch-color: #00bfff;
  --container-bg: #7d44ff;
  --container-border: #b388ff;
  --container-text: var(--text-color);
  --shadow-color: #000;
  --background-toggle: #2f2f2f;
  --header-color: var(--text-color);
}

[data-theme="goblin"] {
  --text-color: #ff8c42;
  --nav-color: var(--text-color);
  --background-color: #c9ffc7;
  --main-color: #1a2e1a;
  --accent-color: #6bc96b;
  --container-bg: #4a8c4a;
  --container-border: #6bc96b;
  --container-text: var(--text-color);
  --shadow-color: #1a3e1a;
  --background-toggle: #2f2f2f;
  --header-color: var(--text-color);
}

/* Smooth scrolling for the whole page */
html {
  scroll-behavior: smooth !important;
}

/* Reset & global styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--background-color);
  color: var(--text-color);
}

/* Active nav link style */
.nav-link.active {
  background-color: var(--main-color);
  color: var(--text-color);
  transform: translateY(-4px);
}

/* Header & footer images */
.Header-1,
.Footer-1 {
  position: relative;
  width: 100%;
  height: auto;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  z-index: 1;
}

.Footer-1 {
  margin-top: 20px;
}

/* Header text overlay */
.Header-text {
  position: absolute;
  top: 30%;
  left: 80%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  text-shadow: 2px 2px 4px var(--shadow-color);
  font-family: "Press Start 2P", cursive;
  background-color: transparent;
  z-index: 10;
}

.Header-text h1 {
  margin: 0;
  font-size: 4rem;
  color: var(--header-color);
  background-color: transparent;
  z-index: 10;
}

.Header-text p {
  margin-top: 30%;
  font-size: 1.5rem;
  background-color: transparent;
}

/* Pixelated nav bar */
.Pixel-nav {
  width: 100%;
  height: 64px;
  background-color: #1a1a1a;
  border-top: 4px solid var(--accent-color);
  border-bottom: 4px solid var(--accent-color);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 48px;
  box-shadow: 0 4px 0 #000000;
  image-rendering: pixelated;
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* Nav links */
.nav-link {
  position: relative;
  padding: 12px 28px;
  font-family: "Press Start 2P", cursive;
  font-size: 1rem;
  color: var(--nav-color);
  text-decoration: none;
  background-color: #2f2f2f;
  border: 3px solid var(--accent-color);
  border-radius: 8px;
  transition: all 0.15s ease;
  box-shadow: 0 4px 0 #000000;
}

.nav-link:hover,
.nav-link.active {
  background-color: var(--accent-color);
  color: #000000;
  transform: translateY(-6px);
  box-shadow: 0 10px 0 #000000;
}

/* Subtle glitch hover effect */
.nav-link:hover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    45deg,
    transparent 48%,
    var(--glitch-color) 50%,
    transparent 52%
  );
  pointer-events: none;
  animation: glitch 0.3s infinite alternate;
  border: 2px solid var(--glitch-color);
  border-radius: 5px;
}

/* Thin orange bar under header */
.Block-1 {
  width: 100%;
  height: 10px;
  background-color: var(--accent-color);
  margin-top: -5px;
}

/* Two-column layout wrapper (used for both sections) */
.two-column-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  margin-top: 30px;
  padding: 0 20px;
}

/* Selfie / image boxes */
.Block-2-selfie,
.Block-2-wompus {
  flex: 1 1 45%;
  min-width: 400px;
  height: 500px;
  background-color: #2f2f2f;
  border: 3px solid var(--accent-color);
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.selfie {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
  image-rendering: pixelated;
}

.Alert {
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  object-fit: contain;
}

/* Art boxes (Block-2 and Block-3) */
.Block-2,
.Block-3 {
  flex: 1 1 45%;
  min-width: 400px;
  height: 500px;
  background-color: #2f2f2f;
  border: 3px solid var(--accent-color);
  box-sizing: border-box;
  background-image: url(./img/Mini\ asset\ set.png);
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
}

/* Text columns (lorem ipsum) */
.lorem-text,
.lorem-text-2 {
  flex: 1 1 50%;
  min-width: 300px;
  color: var(--text-color);
  font-family: "Courier New", Courier, monospace;
  padding: 40px;
}

.lorem-text h2,
.lorem-text-2 h2 {
  margin-top: 0;
  font-size: 2.5rem;
  color: var(--text-color);
}

.lorem-text p,
.lorem-text-2 p {
  line-height: 1.7;
  font-size: 1.2rem;
}

/* Glitch animation keyframes */
@keyframes glitch {
  0% {
    transform: translate(0);
  }
  20% {
    transform: translate(-1px, 1px);
  }
  40% {
    transform: translate(1px, -1px);
  }
  60% {
    transform: translate(-1px, 0);
  }
  100% {
    transform: translate(0);
  }
}

/* Projects section */
.projects-section {
  background-color: #1a1a1a;
  border: 4px solid var(--accent-color);
  border-radius: 12px;
  padding: 48px 32px;
  margin: 60px 0;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  color: var(--container-text);
}

.projects-section h2 {
  text-align: center;
  font-size: 3rem;
  margin-bottom: 32px;
}

.projects-section p {
  text-align: center;
  font-size: 1.15rem;
  margin-bottom: 48px;
  line-height: 1.7;
}

/* Project grid */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 36px;
}

/* Individual card */
.project-card {
  background-color: #222222;
  border: 3px solid var(--accent-color);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.25s ease;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  color: var(--container-text);
}

.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 14px 28px rgba(255, 140, 66, 0.35);
  border-color: #ffaa33;
}

.project-thumbnail {
  width: 100%;
  height: 240px;
  background-color: #0f0f0f;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.project-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;

  image-rendering: pixelated;
}

.project-thumbnail .slime-gif {
  width: 90%;
  max-width: 360px;
}

.project-card .card-content {
  padding: 24px;
  flex-grow: 1;
  background: rgba(40, 40, 40, 0.9);
  color: #f0f0f0;
}

.project-card h3 {
  font-size: 1.5rem;
  margin: 0 0 12px 0;
  text-align: center;
}

.project-card p {
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
  text-align: center;
}

span {
  cursor: pointer;
  background-color: transparent;
  user-select: none;
  z-index: 9999;
}
.theme-toggle-btn[data-theme="light"] {
  background-color: #fff;
}

.theme-toggle-btn {
  position: fixed;
  top: 4px;
  left: 95%;
  background-color: var(--background-toggle);
  border: 3px solid var(--accent-color);
  border-radius: 8px;
  padding: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  box-shadow: 0 4px 0 #000000;
  z-index: 10000;
}

.theme-toggle-btn:hover {
  background-color: var(--accent-color);
  transform: translateY(-4px);
  box-shadow: 0 8px 0 #000000;
}

.footer-container {
  position: relative;
  width: 100%;
}

.back-txt {
  position: absolute;
  left: 50%;
  bottom: 45%;
  transform: translateX(-50%);
  z-index: 100;
  font-size: 1rem;
  text-decoration: none;
  color: var(--main-color);
  font-family: "Press Start 2P", cursive;
  transition: transform 0.25s ease;
}

.back-txt:hover {
  color: var(--accent-color);
  transform: translateX(-50%) scale(1.1);
  text-shadow: 2px 2px 4px var(--shadow-color);
}

@media (max-width: 768px) {
  .project-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .project-thumbnail {
    height: 220px;
  }
  .project-thumbnail .slime-gif {
    width: 85%;
    max-width: 320px;
  }
  .projects-section {
    padding: 32px 20px;
  }
}

@media (max-width: 768px) {
  .two-column-wrapper {
    flex-direction: column;
  }
}

/* ==================== STRONG CONTRAST FIX - DARK & GOBLIN ==================== */

/* Dark Mode */
[data-theme="dark"] body,
[data-theme="dark"] * {
  color: #bbfffc !important;
}

[data-theme="dark"] .lorem-text,
[data-theme="dark"] .lorem-text-2,
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] p {
  color: #bbfffc !important;
}

/* Goblin Mode */
[data-theme="goblin"] body,
[data-theme="goblin"] * {
  color: #2a2a00 !important;
}

[data-theme="goblin"] .lorem-text,
[data-theme="goblin"] .lorem-text-2,
[data-theme="goblin"] h1,
[data-theme="goblin"] h2,
[data-theme="goblin"] h3,
[data-theme="goblin"] p {
  color: #2a2a00 !important;
}

/* Links */
a {
  color: #ffdd77 !important;
}

[data-theme="dark"] a,
[data-theme="goblin"] a {
  color: #ffdd77 !important;
}
