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

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  color: #222;
  background: #fafafa;
}

/* HERO */
.hero {
  width: 100%;
  height: 70vh;
  min-height: 420px;
  background-image: url('personalimages/bridge.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: white;
  position: relative;
  padding: 0 20px;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 1;
}

.hero-title,
.hero-subtitle {
  position: relative;
  z-index: 2;
  text-shadow: 1px 1px 6px rgba(0,0,0,0.7);
}


@media (max-width: 768px) {
  .hero {
    background-attachment: scroll;
    min-height: 60vh;
  }
}


/* SECTIONS */
section {
  padding: 60px 20px;
}

.about,
.experience,
.education-skills,
.showcase,
.contact {
  max-width: 1100px;
  margin: auto;
}

h2 {
  text-align: center;
  margin-bottom: 40px;
}

/* ABOUT */
.about p {
  max-width: 800px;
  margin: auto;
  text-align: center;
}

/* TOGGLE */
.view-toggle {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 40px;
}

.toggle-btn {
  padding: 10px 20px;
  border-radius: 999px;
  border: none;
  background: #edf2f7;
  color: #333;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}

.toggle-btn:hover {
  background: #e2e8f0;
  transform: translateY(-2px);
}

.toggle-btn.active {
  background: #5a67d8;
  color: white;
}

/* EXPERIENCE CARDS */
.experience-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  justify-items: center;
}

.experience-card {
  background: white;
  padding: 28px 24px;
  border-radius: 16px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  text-align: center;
  width: 100%;
  max-width: 320px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.experience-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}

.experience-card i {
  font-size: 32px;
  color: #5a67d8;
  margin-bottom: 12px;
}

.experience-card h3 {
  font-size: 1.2rem;
  margin-bottom: 6px;
}


/* Game images that are also buttons */

/* Game images that are also buttons - FIXED */

/* ---------- CARD LINK WRAPPER ---------- */
.card-link {
  display: flex;
  flex-wrap: wrap;       /* Allows cards to wrap on small screens */
  justify-content: center;
  gap: 20px;
  width: 100%;
  padding: 10px;
}

/* ---------- INDIVIDUAL CARD ---------- */
.card {
  position: relative;
  display: block;
  flex: 0 1 250px;        /* Desktop thumbnail width */
  height: 250px;          /* Square cards */
  max-width: 100%;        /* Prevent horizontal overflow */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
  text-decoration: none;
  background: #f4f6fa;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(0,0,0,0.25);
}

/* ---------- CARD IMAGE ---------- */
.card img {
  width: 100%;
  height: 100%;
  object-fit: cover;    /* Maintains aspect ratio, fills card */
  display: block;
  transition: transform 0.3s ease;
}

.card:hover img {
  transform: scale(1.05);
}

/* ---------- CARD TITLE ---------- */
.card-title {
  position: absolute;
  bottom: 0;
  width: 100%;
  text-align: center;
  padding: 6px 0;
  font-weight: 600;
  font-size: 14px;
  color: white;
  background: rgba(0,0,0,0.6);
  text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

/* ---------- RESPONSIVE ---------- */

/* Tablet (up to 768px) */
@media (max-width: 768px) {
  .card {
    flex: 0 1 45%;       /* Two cards per row */
    height: 200px;
  }
  .card-title {
    font-size: 13px;
  }
}

/* Mobile (up to 480px) */
@media (max-width: 480px) {
  .card {
    flex: 0 1 90%;       /* Single card per row */
    height: auto;        /* Image scales naturally */
  }
  .card img {
    height: auto;
  }
  .card-title {
    font-size: 12px;
    padding: 4px 0;
  }
}


.job-title {
  font-weight: 600;
  color: #444;
}

.job-dates {
  font-size: 0.9rem;
  color: #777;
  margin-top: 4px;
}

/* TIMELINE */
.timeline {
  display: none;
  position: relative;
  max-width: 700px;
  margin: auto;
  padding-left: 20px;
  border-left: 3px solid #5a67d8;
}

.timeline-item {
  position: relative;
  margin-bottom: 40px;
  padding-left: 30px;
}

.timeline-dot {
  position: absolute;
  left: -12px;
  top: 6px;
  width: 14px;
  height: 14px;
  background: #5a67d8;
  border-radius: 50%;
}

.timeline-content h3 {
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.timeline-content p {
  color: #777;
  font-size: 0.9rem;
}



.timeline-dot {
  transform: scale(0.6);
  opacity: 0;
  transition: transform 0.4s ease-out, opacity 0.4s ease-out;
  position: absolute;
}

.timeline-dot::after {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  background: rgba(90, 103, 216, 0.4);
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

.timeline-dot.active {
  transform: scale(1);
  opacity: 1;
}

.timeline-dot.active::after {
  opacity: 1;
  transform: scale(1.3);
}





/* EDUCATION & SKILLS */
.education-skills {
  background: #f4f6fa;
}

.edu-skill-container {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: center;
}

.education,
.skills {
  background: white;
  padding: 32px;
  border-radius: 16px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  width: 100%;
  max-width: 400px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.education:hover,
.skills:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}

.education ul,
.skills ul {
  list-style: none;
  margin-top: 20px;
}

.education li,
.skills li {
  margin-bottom: 14px;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.education li i {
  color: #38b2ac;
}

.skills li i {
  color: #ed8936;
}

/* SHOWCASE */
.showcase p {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 40px;
}

.showcase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
}

.showcase-item {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.showcase-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}

.showcase-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* CONTACT */
.contact {
  text-align: center;
}

.cta-buttons {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.cta-buttons a {
  padding: 12px 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s ease, transform 0.3s ease;
}

.cta-buttons .primary {
  background: #5a67d8;
  color: white;
}

.cta-buttons .primary:hover {
  background: #434190;
  transform: translateY(-2px);
}

.cta-buttons .pop {
  background: #38b2ac;
  color: white;
}

.cta-buttons .pop:hover {
  background: #2c7a7b;
  transform: translateY(-2px);
}

.cta-buttons a:not(.primary):not(.pop) {
  background: #edf2f7;
  color: #333;
}

.cta-buttons a:not(.primary):not(.pop):hover {
  background: #e2e8f0;
  transform: translateY(-2px);
}

/* FOOTER */
footer {
  text-align: center;
  padding: 30px 20px;
  font-size: 0.9rem;
  color: #777;
}

/* FADE-IN ANIMATION */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* VIEW TOGGLE */
.view-cards {
  display: grid;
}

.view-timeline {
  display: none;
}
