/* --- CSS Variables & Design Tokens --- */
:root {
  /* Colors */
  --bg-main: #0a0a0a;
  --bg-surface: #141414;
  --bg-surface-elevated: #222222;
  --accent-primary: #FFCC00;
  --accent-hover: #e6b800;
  --text-main: #f5f5f5;
  --text-muted: #a0a0a0;
  --text-inverse: #111111;
  
  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  
  /* Typography */
  --font-heading: 'Fredoka', cursive, sans-serif;
  --font-body: 'Outfit', sans-serif;
  
  /* Spacing */
  --section-padding: 80px 0;
  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 32px;
  --border-radius-pill: 50px;
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

h1 { font-size: clamp(3rem, 5vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); margin-bottom: 1rem; }
h3 { font-size: clamp(1.25rem, 2vw, 1.75rem); }

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

ul { list-style: none; }

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Utilities --- */
.highlight {
  color: var(--accent-primary);
}

.highlight-text {
  color: var(--accent-primary);
}

.section-title {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  border-radius: var(--border-radius-pill);
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition-normal);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.primary-btn {
  background-color: var(--accent-primary);
  color: var(--text-inverse);
  box-shadow: 0 4px 15px rgba(255, 204, 0, 0.3);
}

.primary-btn:hover {
  background-color: var(--accent-hover);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 204, 0, 0.4);
}

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

.secondary-btn:hover {
  background-color: var(--text-main);
  color: var(--text-inverse);
  transform: translateY(-3px);
}

.dark-btn {
  background-color: var(--bg-main) !important;
  color: var(--text-main) !important;
  border: 2px solid var(--bg-main);
}
.dark-btn:hover {
  background-color: #222 !important;
  color: var(--accent-primary) !important;
}

/* --- Navigation --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 0;
  z-index: 1000;
  transition: var(--transition-normal);
  background: transparent;
}

.navbar.scrolled {
  background: rgba(10, 10, 10, 0.9);
  backdrop-filter: blur(10px);
  padding: 15px 0;
  border-bottom: 1px solid var(--glass-border);
}

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

.logo {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-weight: 500;
  position: relative;
}

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

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

.hamburger {
  display: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
}

.hamburger .bar {
  width: 25px;
  height: 3px;
  background-color: var(--text-main);
  transition: var(--transition-fast);
  border-radius: 3px;
}

/* --- Hero Section --- */
.hero-section {
  padding: calc(120px + var(--section-padding)) 0 var(--section-padding);
  position: relative;
  overflow: hidden;
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}

.badge {
  display: inline-block;
  padding: 8px 16px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--border-radius-pill);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  color: var(--accent-primary);
  margin-bottom: 24px;
}

.hero-content p {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin: 24px 0 40px;
  max-width: 500px;
}

.hero-buttons {
  display: flex;
  gap: 16px;
}

.hero-image-wrapper {
  position: relative;
  display: flex;
  justify-content: center;
}

.image-bg-blob {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(circle, rgba(255, 204, 0, 0.15) 0%, rgba(10, 10, 10, 0) 70%);
  z-index: -1;
  border-radius: 50%;
  filter: blur(40px);
}

.hero-img {
  border-radius: var(--border-radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  border: 2px solid var(--glass-border);
  position: relative;
  z-index: 1;
}

.floating-item {
  position: absolute;
  font-size: 3rem;
  z-index: 2;
  filter: drop-shadow(0 10px 15px rgba(0,0,0,0.3));
}

.float-1 {
  top: 10%;
  left: -5%;
  animation: float 6s ease-in-out infinite;
}

.float-2 {
  bottom: 15%;
  right: -5%;
  animation: float 8s ease-in-out infinite reverse;
}

/* --- About Section --- */
.about-section {
  padding: var(--section-padding);
  background-color: var(--bg-surface);
}

.about-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 80px;
}

.about-image-wrapper {
  position: relative;
}

.about-img {
  border-radius: var(--border-radius-lg);
  border: 2px solid rgba(255, 255, 255, 0.05);
}

.glass-card {
  position: absolute;
  bottom: -20px;
  right: -20px;
  background: rgba(34, 34, 34, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 20px 30px;
  border-radius: var(--border-radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.glass-card .number {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--accent-primary);
  line-height: 1;
}

.glass-card .text {
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.about-content p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 40px;
}

.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.skill-card {
  background: var(--bg-main);
  padding: 24px;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--glass-border);
  transition: var(--transition-normal);
}

.skill-card:hover {
  border-color: var(--accent-primary);
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.skill-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.skill-card h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.skill-card p {
  font-size: 0.9rem;
  margin: 0;
}

/* --- Gallery Section --- */
.gallery-section {
  padding: var(--section-padding);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
}

.gallery-item {
  position: relative;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  cursor: pointer;
}

.image-box {
  width: 100%;
  height: 100%;
  position: relative;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0) 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 30px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.4s ease;
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
  transform: translateY(0);
}

.gallery-overlay h3 {
  color: var(--accent-primary);
  margin-bottom: 8px;
}

.gallery-overlay p {
  color: #fff;
  font-size: 0.9rem;
}

/* Placeholder Styling */
.placeholder-box {
  background: var(--bg-surface);
  border: 2px dashed var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius-md);
}
.placeholder-icon {
  font-size: 4rem;
  opacity: 0.5;
  transition: var(--transition-normal);
}
.gallery-item:hover .placeholder-icon {
  transform: scale(1.2);
  opacity: 1;
}

/* --- Contact Section --- */
.contact-section {
  padding: var(--section-padding);
}

.contact-card {
  background: var(--accent-primary);
  border-radius: var(--border-radius-lg);
  padding: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

.contact-info {
  position: relative;
  z-index: 2;
  color: var(--text-inverse);
  max-width: 600px;
}

.contact-info p {
  color: #333;
  font-size: 1.1rem;
  font-weight: 500;
  margin: 20px 0 30px;
}

.contact-decor {
  font-size: 8rem;
  position: absolute;
  right: 10%;
  bottom: -20px;
  opacity: 0.8;
  animation: float 5s ease-in-out infinite;
  z-index: 1;
}

/* --- Footer --- */
.footer {
  background: var(--bg-surface);
  padding: 60px 0 20px;
  border-top: 1px solid var(--glass-border);
}

.footer-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 30px;
}

.footer-brand p {
  color: var(--text-muted);
  margin-top: 10px;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--text-muted);
  font-weight: 500;
}

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

.footer-bottom {
  border-top: 1px solid var(--glass-border);
  width: 100%;
  padding-top: 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* --- Animations & JS Classes --- */
@keyframes float {
  0% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
  100% { transform: translateY(0); }
}

/* Initial States */
[data-animate] {
  opacity: 0;
  will-change: transform, opacity;
}

[data-animate="fade-up"] { transform: translateY(40px); }
[data-animate="slide-right"] { transform: translateX(-40px); }
[data-animate="slide-left"] { transform: translateX(40px); }
[data-animate="zoom-in"] { transform: scale(0.9); }

/* Active States applied by JS */
.is-visible {
  opacity: 1;
  transform: translate(0) scale(1) !important;
  transition: opacity 0.8s cubic-bezier(0.2, 0.8, 0.2, 1), 
              transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* --- Media Queries --- */
@media (max-width: 992px) {
  .hero-container,
  .about-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-content {
    order: 2;
  }
  
  .hero-image-wrapper {
    order: 1;
    margin-bottom: 40px;
  }
  
  .hero-content p {
    margin: 24px auto 40px;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .about-image-wrapper {
    margin: 0 auto 40px;
    max-width: 400px;
  }
  
  .skills-grid {
    text-align: left;
  }
  
  .contact-card {
    flex-direction: column;
    text-align: center;
    padding: 40px 20px;
  }
  
  .contact-decor {
    display: none;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 60px 0;
  }
  
  .navbar { padding: 15px 0; }
  
  .nav-links {
    position: fixed;
    top: 70px;
    left: -100%;
    flex-direction: column;
    background: var(--bg-surface);
    width: 100%;
    text-align: center;
    padding: 2rem 0;
    transition: var(--transition-normal);
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
    border-bottom: 1px solid var(--glass-border);
  }
  
  .nav-links.active {
    left: 0;
  }
  
  .hamburger {
    display: flex;
  }
  
  .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .hamburger.active .bar:nth-child(2) { opacity: 0; }
  .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

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

  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
}
