/* 
  PREMIUM STEINS;GATE/AMADEUS THEME 
  - Transparent sticky header
  - Smooth fade-in animations
  - Neon glows & transitions
*/

/* VARIABLES */
:root {
  --bg-color: #0d0d0d;
  --text-color: #eeeeee;
  --accent-color: #00ff85; /* Green accent */
  --secondary-bg: #1a1a1a;
  --max-width: 1200px;
}

/* RESET & GLOBAL */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #0d0d0d;
  color: var(--text-color);
  font-family: "Roboto", sans-serif;
  line-height: 1.7; /* Slightly increased for a premium look */
  position: relative;
  margin-top: 60px; /* For sticky header spacing */
}

/* PRELOADER */
#preloader {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, #0d0d0d, #111);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-gif {
  width: 200px;
  height: auto;
  margin-bottom: 1rem;
}

.preloader-overlay {
  text-align: center;
}

.amadeus-logo {
  font-family: "Nunito", sans-serif;
  font-size: 2rem;
  color: var(--accent-color);
  margin-bottom: 1rem;
  text-transform: uppercase;
  text-shadow: 0 0 5px var(--accent-color);
}

.preloader-text {
  font-family: "Roboto", sans-serif;
  font-size: 1rem;
  color: #bbb;
}

/* Hide main content at first */
.hidden {
  display: none;
}

/* HEADER & NAV */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--secondary-bg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  z-index: 1000;
  transition: background-color 0.3s ease;
}

.site-header.scrolled {
  background-color: rgba(26, 26, 26, 0.8); /* Slight transparency on scroll */
}

.logo {
  font-family: "Nunito", sans-serif;
  font-size: 1.2rem;
  color: var(--accent-color);
  user-select: none;
}

.nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
}

.nav ul li a {
  color: var(--text-color);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease, text-shadow 0.3s ease, transform 0.3s ease;
}

.nav ul li a:hover {
  color: var(--accent-color);
  text-shadow: 0 0 5px var(--accent-color);
  transform: scale(1.05);
}

/* HERO SECTION */
.hero {
  display: flex;
  align-items: center;
  position: relative;
  padding: 4rem 2rem;
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.hero-content {
  max-width: 700px;
  margin: 0 auto;
}

.hero-title {
  font-family: "Nunito", sans-serif;
  font-size: 2.2rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
  line-height: 1.2;
}

.hero-content p {
  margin-bottom: 1rem;
}

.btn {
  border: 2px solid var(--accent-color);
  background: transparent;
  color: var(--accent-color);
  padding: 0.6rem 1.2rem;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: "Roboto", sans-serif;
}

.btn:hover {
  background: var(--accent-color);
  color: var(--bg-color);
  text-shadow: 0 0 3px var(--accent-color);
  transform: scale(1.05);
}

/* Funny GIF container */
.funny-gif-container {
  position: absolute;
  bottom: 20px;
  right: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.funny-gif-container img {
  max-width: 100px;
  border-radius: 4px;
  border: 2px solid var(--accent-color);
  box-shadow: 0 0 5px var(--accent-color);
}

.quote-box {
  margin-top: 1rem;
  font-style: italic;
  color: #aaff99;
  min-height: 40px;
}

/* SECTION ANIMATION: fade-in */
.fade-in {
  opacity: 0;
  transform: translateY(10px);
  animation: fadeInUp 1s ease forwards;
  animation-delay: 0.2s; /* slight stagger if desired */
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ABOUT SECTION */
.about-section {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 2rem;
}

.about-section h2 {
  margin-bottom: 1.5rem;
  font-family: "Nunito", sans-serif;
  font-size: 1.8rem;
  color: var(--accent-color);
  text-align: center;
}

.about-content {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.image-wrapper {
  flex: 1 1 400px;
  display: flex;
  flex-direction: column; /* So caption can appear under the image */
  justify-content: center;
  align-items: center;
}

.image-wrapper img {
  max-width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 4px;
}

.image-caption {
  font-size: 0.9rem;
  color: #ccc;
  margin-top: 0.5rem;
  text-align: center;
}

.about-text {
  flex: 2 1 400px;
}

.about-text p {
  margin-bottom: 1rem;
  font-size: 1.05rem;
}

/* BIOGRAPHY SECTION */
.biography-section {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 2rem;
  text-align: left;
}

.biography-section h2 {
  margin-bottom: 1.5rem;
  font-family: "Nunito", sans-serif;
  font-size: 1.8rem;
  color: var(--accent-color);
  text-align: center;
}

.bio-block {
  margin-bottom: 1.5rem;
  background-color: var(--secondary-bg);
  padding: 1rem;
  border-radius: 4px;
  transition: transform 0.3s ease, opacity 0.3s ease;              /* hidden initially */
  transform: translateY(15px);
}

.bio-block.fade-in-later {
  opacity: 1;               /* once triggered */
  transform: translateY(0);
}

.bio-block h3 {
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
  color: var(--accent-color);
}

.bio-block p {
  margin-bottom: 0;
  line-height: 1.6;
}

/* SLIDESHOW WITHIN BIOGRAPHY */
.slideshow-container {
  position: relative;
  max-width: 800px;
  margin: 2rem auto;
  overflow: hidden;
  border: 2px solid var(--accent-color);
  border-radius: 8px;
  box-shadow: 0 0 10px var(--accent-color);
}

.slide {
  display: none;
  text-align: center;
  position: relative;
}

.slide img {
  width: 100%;
  border-radius: 8px;
}

.slide-caption {
  color: #ccc;
  font-size: 0.9rem;
  text-align: center;
  margin-top: 0.3rem;
}

/* Arrows */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  font-size: 2rem;
  color: #fff;
  padding: 0.5rem;
  user-select: none;
  transform: translateY(-50%);
  transition: color 0.3s ease;
}

.prev:hover, .next:hover {
  color: var(--accent-color);
}

.prev { left: 10px; }
.next { right: 10px; }

.dots-container {
  text-align: center;
  margin-top: 1rem;
}

.dot {
  cursor: pointer;
  height: 12px;
  width: 12px;
  margin: 0 3px;
  background-color: #bbb;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.3s ease;
}
.dot.active, .dot:hover {
  background-color: var(--accent-color);
}

/* PROJECTS SECTION */
.projects-section {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 2rem;
  text-align: center;
}

.projects-section h2 {
  margin-bottom: 1.5rem;
  font-family: "Nunito", sans-serif;
  font-size: 1.8rem;
  color: var(--accent-color);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.project-card {
  background-color: var(--secondary-bg);
  padding: 1rem;
  border-radius: 4px;
  border: 1px solid transparent;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
  cursor: pointer;
  text-align: center;
}

.project-card img {
  width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  margin-bottom: 0.5rem;
}

.image-caption {
  font-size: 0.9rem;
  color: #ccc;
  margin-top: 0.3rem;
}

.project-card h3 {
  color: var(--accent-color);
  margin-top: 0.75rem;
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  font-family: "Nunito", sans-serif;
}

.project-card p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

.project-card:hover {
  border-color: var(--accent-color);
  box-shadow: 0 0 5px var(--accent-color);
  text-shadow: 0 0 3px var(--accent-color);
  transform: translateY(-5px);
}

/* CONTACT SECTION */
.contact-section {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 2rem;
  text-align: center;
}

.contact-section h2 {
  margin-bottom: 1.5rem;
  font-family: "Nunito", sans-serif;
  font-size: 1.8rem;
  color: var(--accent-color);
}

.contact-section a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.contact-section a:hover {
  color: #aaff99;
  text-shadow: 0 0 3px #aaff99;
}

/* FOOTER */
.site-footer {
  background-color: var(--secondary-bg);
  text-align: center;
  padding: 1rem;
  margin-top: 3rem;
}

.site-footer .accent {
  color: var(--accent-color);
  font-weight: 700;
  font-family: "Nunito", sans-serif;
}

/* GLITCH EFFECT (less intense) */
.glitch {
  position: relative;
  display: inline-block;
}

.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  left: 0;
  color: var(--accent-color);
  opacity: 0.8;
}

.glitch::before {
  animation: glitch-anim 1.5s infinite ease-in-out alternate;
  top: 0;
}

.glitch::after {
  animation: glitch-anim2 1.5s infinite ease-in-out alternate;
  top: 0;
}

@keyframes glitch-anim {
  0% { transform: translate(0,0); }
  50% { transform: translate(-1px, -1px); }
  100% { transform: translate(1px, 1px); }
}

@keyframes glitch-anim2 {
  0% { transform: translate(0,0); }
  50% { transform: translate(1px, -1px); }
  100% { transform: translate(-1px, 1px); }
}

/* LIGHTBOX MODAL */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%; 
  height: 100%;
  background-color: rgba(0,0,0,0.8);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.lightbox.show {
  display: flex;
}

.lb-image, .lb-image-next, .lb-image-prev {
  position: absolute;
  max-width: 90%;
  max-height: 80%;
  object-fit: contain;
  border: 2px solid var(--accent-color);
  border-radius: 4px;
  box-shadow: 0 0 10px var(--accent-color);
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* Hide the staging images */
.lb-image-next, 
.lb-image-prev {
  display: none;
}

/* Slide Animations Based on data-direction */
.lb-image[data-direction="left"] {
  transform: translateX(-50px);
  opacity: 0.5;
}
.lb-image[data-direction="right"] {
  transform: translateX(50px);
  opacity: 0.5;
}
.lb-image[data-direction="none"] {
  transform: translateX(0);
  opacity: 1;
}

/* Close Button & Arrows */
.lb-close {
  position: absolute;
  top: 40px;
  right: 40px;
  color: #fff;
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}

.lb-close:hover {
  color: var(--accent-color);
  text-shadow: 0 0 3px var(--accent-color);
}

.lb-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #fff;
  font-size: 2.5rem;
  font-weight: bold;
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.3s ease, text-shadow 0.3s ease;
  user-select: none;
}

.lb-prev {
  left: 40px;
}

.lb-next {
  right: 40px;
}

.lb-arrow:hover {
  color: var(--accent-color);
  text-shadow: 0 0 3px var(--accent-color);
}

/* MEDIA QUERIES */
@media (max-width: 768px) {
  .nav ul {
    gap: 0.5rem;
  }
  .hero-title {
    font-size: 1.8rem;
  }
  .funny-gif-container {
    bottom: 10px;
    right: 10px;
  }
  .funny-gif-container img {
    max-width: 80px;
  }
  .site-footer {
    padding: 1.5rem 1rem;
  }
}

@media (max-width: 480px) {
  .site-header {
    flex-direction: column;
    gap: 1rem;
  }
  .nav ul {
    flex-direction: column;
  }
  .hero {
    padding: 3rem 1rem;
  }
  .about-content {
    flex-direction: column;
  }
  .projects-grid {
    grid-template-columns: 1fr;
  }
}

/* Hero Buttons - optional stylish row */
.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 1rem;
}

/* Resume Button Hover & Glow */
.resume-trigger:hover {
  box-shadow: 0 0 8px var(--accent-color);
  transform: scale(1.07);
}

/* Resume Modal Overlay */
.resume-modal {
  display: none; /* Hidden by default */
  position: fixed;
  z-index: 9999;
  left: 0; 
  top: 0;
  width: 100%; 
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  animation: resumeFadeIn 0.5s ease;
}

/* Keyframe for smooth fade/zoom */
@keyframes resumeFadeIn {
  from { opacity: 0; transform: scale(0.9); }
  to   { opacity: 1; transform: scale(1); }
}

/* Modal Content Box */
.resume-modal-content {
  background-color: var(--secondary-bg);
  max-width: 800px;
  width: 90%;
  border: 2px solid var(--accent-color);
  border-radius: 8px;
  box-shadow: 0 0 10px var(--accent-color);
  padding: 1.5rem 2rem;
  position: relative;
  animation: contentZoomIn 0.4s ease;
}

/* Another small zoom for content */
@keyframes contentZoomIn {
  from { transform: scale(0.95); }
  to   { transform: scale(1); }
}

/* Close Button */
.resume-close {
  position: absolute;
  top: 20px;
  right: 20px;
  color: var(--text-color);
  font-size: 2rem;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}
.resume-close:hover {
  color: var(--accent-color);
  text-shadow: 0 0 3px var(--accent-color);
}

/* Resume Heading */
.resume-heading {
  margin-bottom: 1rem;
  font-family: 'Nunito', sans-serif;
  font-size: 1.6rem;
  color: var(--accent-color);
  text-align: center;
}

/* Tabs Row */
.resume-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  justify-content: center;
}

.resume-tablink {
  flex: 1;
  background-color: var(--secondary-bg);
  border: 1px solid var(--accent-color);
  color: var(--text-color);
  padding: 0.5rem 1rem;
  cursor: pointer;
  text-align: center;
  transition: background 0.3s ease, transform 0.3s ease;
}
.resume-tablink.active {
  background-color: var(--accent-color);
  color: var(--bg-color);
  transform: scale(1.03);
}

/* Tab Content */
.resume-tabcontent {
  display: none; /* Hidden by default */
  padding: 1rem 0;
  color: var(--text-color);
}

.resume-tabcontent h3 {
  color: var(--accent-color);
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}
.resume-tabcontent ul {
  list-style: disc;
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}
.resume-tabcontent p, .resume-tabcontent li {
  font-size: 0.95rem;
  line-height: 1.6;
}
