:root {
  /* Backgrounds */
  --background-main: #f6f7f9;
  --background-soft: #e6ebf1;

  /* Primary Colors */
  --primary-dark: #172a3a;
  --primary-light: #1e1e1e;

  /* Accent Colors */
  --accent-mint: #48bf91;
  --accent-yellow: #ffd166;

  /* Text */
  --text-dark: #1e1e1e;
  --text-light: #ffffff;

  /* Button Colors */
  --button-bg: var(--accent-mint);
  --button-text: #ffffff;
  --button-hover: #3aa97e;

  /* Borders & Highlights */
  --border-muted: #d0d7e2;
}

@font-face {
  font-family: Segment14;
  src: url("segment14.woff") format("woff"), url("segment14.ttf") format("truetype");
}

/* === GLOBAL === */
body {
  background: var(--background-main);
  color: var(--text-dark);
  font-family: "Poppins", "Segoe UI", sans-serif;
  margin: 0;
  padding: 0;
}

h1,
h2,
h3 {
  color: var(--primary-dark);
}

.section-heading {
  font-size: 24px;
  color: var(--primary-dark);
  border-bottom: 2px solid var(--accent-yellow);
  padding-bottom: 6px;
  margin-bottom: 20px;
}

.highlight {
  color: var(--accent-yellow);
  font-weight: bold;
}

/* === BUTTONS === */
button {
  background-color: var(--button-bg);
  color: var(--button-text);
  border: none;
  border-radius: 8px;
  padding: 10px 20px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: var(--button-hover);
}

.arrow {
  all: unset;
  cursor: pointer;
  font-size: 28px;
  /* color: var(--primary-dark); */
  transition: transform 0.2s ease;
}

.arrow:hover {
  transform: scale(1.2);
}

/* === HERO SECTION === */
.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  background: linear-gradient(to bottom right, var(--background-main), var(--background-soft));
  max-width: 100%;
}

.hero-heading-wrapper {
  text-align: center;
  margin-bottom: 30px;
  width: 100%;
}

.hero-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  max-width: 1000px;
  width: 100%;
  position: relative;
}

.hero-image img {
  width: 250px;
  height: 250px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.1);
}

.hero-text-slider {
  display: flex;
  align-items: center;
  gap: 20px;
  flex: 1;
  max-width: 600px;
}

.hero-slide-wrapper {
  flex: 1;
  min-width: 280px;
}

.hero-slide {
  display: none;
  font-size: 16px;
  line-height: 1.6;
}

.hero-slide.active {
  display: block;
}

/* Position chevrons at screen edge */
.arrow.hero-prev,
.arrow.hero-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 28px;
  color: var(--primary-dark);
  z-index: 10;
}

.arrow.hero-prev {
  left: 0;
  margin-left: 30px;
}

.arrow.hero-next {
  right: 0;
  margin-right: 30px;
}

.arrow.hero-prev:hover,
.arrow.hero-next:hover {
  transform: translateY(-50%) scale(1.2);
}

/* === HERO HEADING TRANSITIONS === */
#hero-heading {
  opacity: 1;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.fade-out-heading {
  opacity: 0;
  transform: translateY(0);
}

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

/* === PROJECTS SECTION === */
.projects {
  padding: 80px 20px;
  background: var(--background-soft);
}

.project-heading {
  text-align: center;
}

.project-slideshow {
  max-width: 800px;
  margin: 20px auto;
  position: relative;
}

.project-slide {
  display: none;
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.project-slide.active {
  display: block;
}

.arrow.project-prev,
.arrow.project-next {
  position: absolute;
  top: 130%;
  transform: translateY(-50%);
  font-size: 28px;
  /* color: var(--primary-dark); */
  z-index: 11;
}

.arrow.project-prev {
  left: 0;
  margin-left: 30px;
}

.arrow.project-next {
  right: 0;
  margin-right: 30px;
}

.arrow.project-prev:hover,
.arrow.project-next:hover {
  transform: translateY(-50%) scale(1.2);
}

.project-description {
  max-width: 800px;
  margin: 30px auto;
  background: #ffffff;
  padding: 20px;
  border-left: 4px solid var(--accent-yellow);
  border-radius: 6px;
  font-size: 15px;
  line-height: 1.6;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
}

.project-switcher {
  text-align: center;
  margin-top: 30px;
  z-index: 101;
}

.project-tab {
  background: var(--button-bg);
  color: var(--button-text);
  border: none;
  margin: 5px;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.project-tab:hover,
.project-links a:hover {
  background: var(--button-hover);
}

.project-links {
  display: flex;
  justify-content: center;
  gap: 90px;
  margin-top: 20px;
}

.project-links a {
  text-decoration: none;
  transition: color 0.2s ease;
  color: var(--button-text);
}

.project-links a:visited {
  text-decoration: none;
}

.project-git-link,
.project-live-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  background: var(--accent-mint);
  color: var(--button-text);
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.project-git-link i,
.project-live-link i {
  font-size: 0.9em; /* or inherit */
  vertical-align: middle;
  line-height: 1;
}

/* === CONTACT SECTION === */
.contact {
  padding: 40px 20px;
  text-align: center;
}

.cta-line {
  padding-top: 5px;
  text-align: center;
}

.contact-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin-top: 2em;
}

.contact-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  text-decoration: none;
  color: var(--primary-dark);
  transition: transform 0.2s ease;
}

.contact-actions a {
  text-decoration: none;
  color: var(--button-text);
}

.contact-actions a:visited {
  text-decoration: none;
}

.contact-actions button:hover {
  background: var(--button-hover);
}

.cta-docs a {
  text-decoration: none;
  color: var(--button-hover);
  display: inline-block;
  transition: transform 0.2s ease;
}

.cta-docs a:hover {
  transform: scale(1.01);
}

.icon-col {
  width: 40px;
}

.icon-col i {
  font-size: 24px;
}

.text-col {
  font-size: 16px;
  text-align: left;
  white-space: nowrap;
}

.contact-item:hover {
  text-decoration: underline;
  transform: scale(1.02);
}

footer {
  margin-top: 40px;
  font-size: 14px;
  color: #777;
}

/* === FADE BASE STYLES === */
.hero-slide,
.project-slide,
.project-images {
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
  position: absolute;
}

.hero-slide.active,
.project-slide.active,
.project-images.active {
  opacity: 1;
  pointer-events: auto;
  position: relative;
}

.project-description {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.project-description.active {
  display: block;
  opacity: 1;
}

.project-slideshow {
  position: relative;
  min-height: 500px;
}

.project-images {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  height: auto;
  max-height: 500px;
  width: 100%;
}

/* Base state (hidden) */
.project-slide {
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  display: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
  max-width: 100%;
  max-height: 500px;
  margin: 3em;
  padding: 10px;
}

.project-slide.active {
  display: block;
}

.hero-slide {
  opacity: 0;
  position: absolute;
  transition: opacity 0.4s ease, transform 0.4s ease;
  transform: translateX(50px);
  pointer-events: none;
}

/* Visible slide */
.hero-slide.active {
  opacity: 1;
  position: relative;
  transform: translateX(0);
  pointer-events: auto;
}

/* Optional: reverse direction (for previous slide) */
.slide-out-left {
  transform: translateX(-50px);
  opacity: 0;
}

.slide-in-right {
  transform: translateX(50px);
  opacity: 0;
}

/* NAV STYLES */
.site-nav {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 20px;
  background-color: var(--background-soft);
  font-weight: 500;
}

.site-nav a {
  text-decoration: none;
  color: var(--primary-dark);
  padding: 8px 12px;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.site-nav a:hover {
  background-color: var(--accent-yellow);
  color: #000;
}

.project-switcher {
  display: flex;
  flex-direction: row;
  justify-content: center;
  margin: 1rem 0;
}

.project-switcher select {
  padding: 1rem 1rem;
  font-size: 1rem;
  font-family: inherit;
  border: 2px solid #444;
  border-radius: 8px;
  background-color: var(--background-soft);
  color: #000000;
  cursor: pointer;
  transition: all 0.3s ease;
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg fill='black' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1rem;
}

.project-switcher select:hover {
  border-color: #0d6efd;
}

.project-switcher select:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(13, 110, 253, 0.4);
  border-color: #0d6efd;
}

.project-switcher option {
  background-color: #111;
  color: #fff;
}

.project-switcher label {
  margin-right: 20px;
}

/* === RESPONSIVENESS === */
@media screen and (max-width: 768px) {
  .hero-content {
    flex-direction: column;
    text-align: center;
  }

  .hero-text-slider {
    flex-direction: column;
  }

  .arrow {
    font-size: 24px;
  }

  .arrow.hero-prev {
    left: 10px;
    top: auto;
    bottom: 20px;
    transform: none;
  }

  .arrow.hero-next {
    right: 10px;
    top: auto;
    bottom: 20px;
    transform: none;
  }

  .arrow.project-prev {
    left: 10px;
    top: auto;
    bottom: -330px;
    transform: none;
  }

  .arrow.project-next {
    right: 10px;
    top: auto;
    bottom: -330px;
    transform: none;
  }

  .hero-image img {
    width: 180px;
    height: 180px;
  }

  .contact-links {
    flex-direction: column;
    gap: 20px;
  }

  .contact-icons,
  .contact-labels {
    flex-direction: row;
    gap: 20px;
  }

  .project-img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
  }

  body {
    font-size: 15px;
  }

  h1 {
    font-size: 1.6rem;
  }

  h2 {
    font-size: 1.3rem;
  }
}
