/* CSS Custom Properties - Copper Theme */
:root {
  /* Copper color palette */
  --copper: #B87333;
  --copper-light: #D4A574;
  --copper-dark: #8B4513;
  --copper-muted: rgba(184, 115, 51, 0.1);
  
  /* Dark theme colors */
  --bg-primary: hsl(20, 14.3%, 4.1%);
  --bg-secondary: hsl(24, 9.8%, 10%);
  --bg-muted: hsl(24, 5.7%, 82.9%);
  --text-primary: hsl(0, 0%, 95%);
  --text-secondary: hsl(240, 5%, 64.9%);
  --text-muted: hsl(240, 3.8%, 46.1%);
  
  /* UI colors */
  --border: hsl(240, 3.7%, 15.9%);
  --border-input: hsl(240, 3.7%, 15.9%);
  --ring: hsl(142.1, 76.2%, 36.3%);
  
  /* Glass effect */
  --glass-bg: rgba(24, 24, 27, 0.8);
  --glass-border: rgba(184, 115, 51, 0.2);
}

/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
}

h1 { font-size: 2.25rem; }
h2 { font-size: 1.875rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

.highlight-mg {
  color: var(--copper); /* or any custom color */
  font-weight: bold;
  margin-right: 0.25rem;
}

/* Animated Background */
.background-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.dot {
  position: absolute;
  background: var(--copper);
  border-radius: 50%;
  opacity: 0.6;
  box-shadow: 0 0 4px var(--copper);
  animation: moveDot linear infinite;
}

@keyframes moveDot {
  0% { transform: translateY(100vh); opacity: 0; }
  10% { opacity: 0.6; }
  90% { opacity: 0.6; }
  100% { transform: translateY(-100px); opacity: 0; }
}

/* Navigation */
.nav-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
  z-index: 1000;
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
}

.nav-brand h1 {
  color: var(--copper);
  font-size: 1.5rem;
  font-weight: 700;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover, .nav-link.active {
  color: var(--copper);
  background: var(--copper-muted);
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-menu-btn span {
  width: 25px;
  height: 3px;
  background: var(--copper);
  margin: 3px 0;
  transition: 0.3s;
}

.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
}

.mobile-nav .nav-link {
  padding: 1rem 2rem;
  border-bottom: 1px solid var(--border);
}

/* Main Content */
.main-content {
  margin-top: 80px;
  min-height: calc(100vh - 80px);
}

.section {
  display: none;
  min-height: calc(100vh - 80px);
  padding: 2rem;
}

.section.active {
  display: block;
}

.section-content {
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  color: var(--copper);
  text-align: center;
  margin-bottom: 1rem;
  font-size: 2.5rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 3rem;
  font-size: 1.125rem;
}

/* Hero Section */
.hero-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  min-height: calc(100vh - 160px);
  padding: 2rem 0;
}

.hero-content {
  space-y: 1.5rem;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: 1.5rem;
  color: var(--copper);
  margin-bottom: 1.5rem;
}

.hero-description {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}

.profile-image {
  width: 300px;
  height: 300px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--copper);
  box-shadow: 0 10px 30px rgba(184, 115, 51, 0.3);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--copper), var(--copper-light));
  color: white;
  box-shadow: 0 4px 15px rgba(184, 115, 51, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(184, 115, 51, 0.4);
}

.btn-secondary {
  background: transparent;
  color: var(--copper);
  border: 2px solid var(--copper);
}

.btn-secondary:hover {
  background: var(--copper);
  color: white;
}

.btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* Glass Effect Cards */
.glass-effect {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 2rem;
}

/* Resume Section */
.resume-content {
  display: grid;
  gap: 3rem;
}

.resume-section h3 {
  color: var(--copper);
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
}

.experience-item {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.5rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.experience-item h4 {
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.company {
  color: var(--copper);
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.period {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.experience-item ul {
  list-style: none;
  padding-left: 0;
}

.experience-item li {
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  padding-left: 1rem;
  position: relative;
}

.experience-item li::before {
  content: "▸";
  color: var(--copper);
  position: absolute;
  left: 0;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.skill-category {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.5rem;
  padding: 1.5rem;
}

.skill-category h4 {
  color: var(--copper);
  margin-bottom: 1rem;
}

.skill-category ul {
  list-style: none;
  padding: 0;
}

.skill-category li {
  color: var(--text-secondary);
  padding: 0.25rem 0;
}

.resume-download {
  text-align: center;
  margin-top: 3rem;
}

/* Photography Section */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.photo-item {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.photo-item:hover {
  transform: scale(1.05);
}

.photo-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  /* Image protection */
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  pointer-events: auto;
  -webkit-touch-callout: none;
}

.photo-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  color: white;
  padding: 2rem 1rem 1rem;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.photo-item:hover .photo-overlay {
  transform: translateY(0);
}

.photo-overlay h4 {
  margin-bottom: 0.5rem;
}

.photo-overlay p {
  font-size: 0.875rem;
  margin-bottom: 1rem;
  opacity: 0.9;
}

/* Games Section */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.game-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
}

.game-card h3 {
  color: var(--copper);
  margin-bottom: 1rem;
}

.game-card canvas {
  border: 2px solid var(--copper-dark);
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  background: #000;
}

.game-info {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.score {
  color: var(--text-secondary);
  font-weight: 600;
}

.game-controls {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* Contact Section */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  margin-top: 3rem;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-item {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.5rem;
  padding: 1.5rem;
}

.contact-item h4 {
  color: var(--copper);
  margin-bottom: 0.5rem;
}

.contact-item p {
  color: var(--text-secondary);
}

.contact-form {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 2rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-input);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--copper);
  box-shadow: 0 0 0 2px rgba(184, 115, 51, 0.2);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
}

.modal-content {
  background: var(--bg-secondary);
  margin: 5% auto;
  padding: 2rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  width: 90%;
  max-width: 600px;
  position: relative;
}

.close {
  color: var(--text-muted);
  float: right;
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  position: absolute;
  right: 1rem;
  top: 1rem;
}

.close:hover {
  color: var(--copper);
}

#modalImage {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  /* Image protection */
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  pointer-events: auto;
  -webkit-touch-callout: none;
}

.modal-info h3 {
  color: var(--copper);
  margin-bottom: 1rem;
}

.modal-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2rem;
}

.price {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--copper);
}

/* Toast Notification */
.toast {
  position: fixed;
  top: 100px;
  right: 2rem;
  background: var(--copper);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: 0.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transform: translateX(400px);
  transition: transform 0.3s ease;
  z-index: 3000;
}

.toast.show {
  transform: translateX(0);
}

/* Responsive Design */
@media (max-width: 768px) {
  .desktop-nav {
    display: none;
  }
  
  .mobile-menu-btn {
    display: flex;
  }
  
  .mobile-nav.show {
    display: flex;
  }
  
  .hero-section {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .contact-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .games-grid {
    grid-template-columns: 1fr;
  }
  
  .game-card canvas {
    max-width: 100%;
    height: auto;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
  }
  
  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .profile-image {
    width: 200px;
    height: 200px;
  }
}

@media (max-width: 480px) {
  .nav-content {
    padding: 1rem;
  }
  
  .section {
    padding: 1rem;
  }
  
  .hero-title {
    font-size: 1.75rem;
  }
  
  .section-title {
    font-size: 1.75rem;
  }
  
  .photo-grid {
    grid-template-columns: 1fr;
  }
  
  .modal-content {
    margin: 10% auto;
    padding: 1rem;
    width: 95%;
  }
}