:root {
  --primary-light: #ECF22E;
  --secondary-light: #A1A61F;
  --bg-light: #f9fafb;
  --text-light: #1e293b;
  --card-light: rgba(255, 255, 255, 0.65);

  --tag-web-light: #fef9c3;
  --tag-film-light: #e0f2fe;
  --tag-3d-light: #ede9fe;
  --tag-default-light: #e2e8f0;

  --primary-dark: #F2E530;
  --secondary-dark: #ECF22E;
  --bg-dark: #0D0D0D;
  --text-dark: #ffffff;
  --card-dark: rgba(255, 255, 255, 0.08);

  --tag-web-dark: #b6a600;
  --tag-film-dark: #2563eb;
  --tag-3d-dark: #7c3aed;
  --tag-default-dark: rgba(255, 255, 255, 0.1);
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-light);
  color: var(--text-light);
  line-height: 1.6;
  transition: background-color 0.4s ease, color 0.4s ease;
}

body.dark {
  background-color: var(--bg-dark);
  color: var(--text-dark);
}

header {
  text-align: center;
  padding: 2rem;
}

header h1 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2.5rem;
  color: var(--primary-light);
}

body.dark header h1 {
  color: var(--primary-dark);
}

.toggle-container {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.toggle {
  appearance: none;
  width: 50px;
  height: 25px;
  background: #ccc;
  border-radius: 50px;
  position: relative;
  cursor: pointer;
  transition: background 0.3s ease;
}

.toggle::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 21px;
  height: 21px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.toggle:checked {
  background: #b4b700;
}

.toggle:checked::before {
  transform: translateX(25px);
}

section {
  max-width: 1000px;
  margin: auto;
  padding: 2rem;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.project {
  background: var(--card-light);
  border-radius: 10px;
  padding: 1rem;
  backdrop-filter: blur(8px);
  transition: background 0.4s ease;
  cursor: pointer;
}

body.dark .project {
  background: var(--card-dark);
}

.project:hover {
  outline: 2px solid var(--primary-light);
}

.project-details {
  display: none;
  margin-top: 0.5rem;
  font-size: 0.9rem;
}

.project.open .project-details {
  display: block;
}

.project a {
  color: inherit;
  text-decoration: none;
}

.project a:hover {
  text-decoration: underline;
}

.meta-info {
  font-size: 0.85rem;
  margin-top: 0.5rem;
  opacity: 0.8;
}

.tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: bold;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  margin-bottom: 0.5rem;
  color: black;
}

/* Lightmode Tags */
.tag.web {
  background: var(--tag-web-light);
}
.tag.film {
  background: var(--tag-film-light);
}
.tag.threeD {
  background: var(--tag-3d-light);
}
.tag.default {
  background: var(--tag-default-light);
}

/* Darkmode */
body.dark .tag.web {
  background: var(--tag-web-dark);
  color: #000;
}
body.dark .tag.film {
  background: var(--tag-film-dark);
  color: #fff;
}
body.dark .tag.threeD {
  background: var(--tag-3d-dark);
  color: #fff;
}
body.dark .tag.default {
  background: var(--tag-default-dark);
  color: #f1f5f9;
}

footer {
  text-align: center;
  padding: 2rem;
  font-size: 0.85rem;
}
