/* ── Global Settings ───────────────────────────────────────── */
:root {
  font-size: 2vh;
}
html {
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: #202020 #000;
}
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Montserrat', sans-serif;
  color: #f8f9fa;
}

/* ── Page Background & Navigation ─────────────────────────── */
body {
  background: #000;
}
nav-component {
  display: block;
  height: 4rem;
}


/* ────────────────────────────────────────────────────────────────────────── */
/* ── Home Page ───────────────────────────────────────────────────────────── */
/* ────────────────────────────────────────────────────────────────────────── */
#index-main {
  margin: 4rem auto 0;
  padding: 0;
  max-width: 100%;
}

.about-link:hover {
  text-decoration: underline;
}

/* Hero Section */
.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18.75rem, 1fr));
  align-items: center;
  justify-items: center;
  width: 90vw;
  max-width: 100vw;
  padding: 6rem 2rem;
  gap: 1rem;
  margin: 0 auto;
}
.hero-text h1 {
  font-size: clamp(3rem, 6vw, 5rem);
  margin-bottom: 1.5rem;
  line-height: 1.1;
}
.hero-text p {
  font-size: 1.2rem;
  line-height: 1.5;
  padding: 0 0.3rem;
}
.hero-image {
  position: relative;
  width: 100%;
  max-width: 43.75rem;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #000;
}

/* Carousel Slides */
.carousel-slide {
  display: none;
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 0.75rem;
}
.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0.75rem;
}

/* Title Bar Overlay */
.title-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3em;
  background: rgba(16, 16, 16, 0.7);
  padding: 1rem;
  font-size: 1.5em;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  overflow: hidden;
  transition: height 0.3s ease;
  border-radius: 0 0 0.75rem 0.75rem;
}
.title-bar:hover {
  height: auto;
  max-height: 50%;
}
.title-text {
  font-weight: bold;
}
.summary {
  font-size: 0.9em;
  margin-top: 0.5em;
  opacity: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow-wrap: break-word;
  transition: opacity 0.3s ease;
}
.title-bar:hover .summary {
  opacity: 1;
}

/* Carousel Arrows */
.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3em;
  cursor: pointer;
  user-select: none;
  transition: transform 0.3s;
  z-index: 2;
}
.arrow:hover {
  transform: translateY(-50%) scale(1.2);
}
.prev {
  left: 0.5em;
}
.next {
  right: 0.5em;
}

/* Responsive Adjustments*/
@media (max-width: 768px), (orientation: portrait) {
  .hero {
    padding: 3rem 0;
  }
  .hero-text {
    padding-bottom: 2rem;
    text-align: center;
  }
  .hero-text h1 {
    text-align: center;
  }
  .hero-image {
    max-width: 100%;
  }
  .title-bar {
    height: 2.5em;
    font-size: 1em;
    padding: 0.5rem;
  }
  .br-mobile {
    display: inline !important;
  }
  .indent-desktop {
    display: none !important;
  }
}

/* ────────────────────────────────────────────────────────────────────────── */
/* ── about-me ────────────────────────────────────────────────────────────── */
/* ────────────────────────────────────────────────────────────────────────── */
#about-main {
  margin-top: 6rem;
  padding: 6rem;
}

#about-main h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.about-section-title {
  font-size: 2rem;
}

.about-section-text {
  font-size: 1.2rem;
}

.about-intro {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 2rem;
  margin-bottom: 3rem;
}

.about-text {
  flex: 1 1 300px;
  min-width: 250px;
}

.about-text p {
  font-size: 1.4rem;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.about-img {
  flex: 0 0 auto;
  max-height: 45vh;
  width: auto;
  height: auto;
  border-radius: 10px;
  margin-top: 1rem;
}

.skills-tools {
  margin: 0 auto;
  margin-bottom: 3rem;
}

.skills-tools h3 {
  font-size: 1.5rem;
  margin-top: 1rem;
  margin-bottom: 0.3rem;
}

.skills-tools-card-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: left;
}

.skills-tools-card {
  background-color: #000045;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-radius: 8px;
  padding: 1rem;
  overflow: hidden;
  position: relative;
  height: 3.5rem;
  flex-shrink: 0;
}

.skills-tools-card img {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.skills-tools-card span {
  font-size: 1.2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.edu-card-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: left;
  margin-top: 1rem;
}

.edu-card {
  background-color: #000045;
  border-radius: 12px;
  padding: 1rem;
  width: 100%;
  width: 20rem;
  position: relative;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-bottom: 3rem;
}

.edu-card-content {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  width: 100%;
}

.edu-text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
}

h3.edu-title {
  font-size: 1.5rem;
  font-weight: bold;
  margin: 0;
  color: white;
}

.edu-subtitle {
  font-size: 1.3rem;
  font-style: italic;
  margin: 0;
  color: #ccc;
}

.edu-description {
  font-size: 1rem;
  color: white;
  margin-top: 0.4rem;
  line-height: 1.4;
}

.ribbon {
  position: absolute;
  top: 0;
  right: 0;
  background-color: #f8f9fa;
  color: #000045;
  font-size: 0.65rem;
  font-weight: bold;
  padding: 0.15em 0.4em;
  border-radius: 6px;
  z-index: 1;
}


@media (max-width: 768px), (orientation: portrait) {
  #about-main {
    margin-top: 6rem;
    padding: 1rem;
  }

  #about-main h1 {
    font-size: 1.5rem;
  }

  .about-section-title {
    font-size: 1.5rem;
  }

  #about-main h3 {
    font-size: 1.2rem;
  }

  .about-section-text {
    font-size: 1rem;
  }

  .about-intro {
    display: block;
  }

  .about-intro p {
    font-size: 1rem;
    line-height: 1.1;
  }

  .about-img {
    display: none;
  }

  .skills-tools-card-grid {
    flex-direction: row;
    justify-content: flex-start;
    gap: 0.5rem;
  }

  .skills-tools-card {
    width: calc(50% - 0.5rem);
  }

  .skills-tools-card img {
    width: 24px;
    height: 24px;
  }

  .skills-tools-card span {
    font-size: 0.95rem;
  }

  .edu-card {
    flex-direction: column;
    align-items: flex-start;
    max-width: 100%;
  }

  .edu-card-content {
    flex-direction: row;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .edu-icon {
    width: 36px;
    height: 36px;
  }

  h3.edu-title {
    font-size: 1.1rem;
  }

  .edu-subtitle {
    font-size: 1rem;
  }

  .edu-description {
    font-size: 0.95rem;
  }

  .ribbon {
    font-size: 0.55rem;
    padding: 0.15em 0.4em;
  }

  .future{
    margin-bottom: 2rem;
  }
}


/* ────────────────────────────────────────────────────────────────────────── */
/* ── Projects ────────────────────────────────────────────────────────────── */
/* ────────────────────────────────────────────────────────────────────────── */

#projects-main {
  margin-top: 4rem;
}

.tile-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, 25rem);
  gap: 1.5rem;
  padding: 1rem 0;
  justify-content: center;
}

/* Each tile has fixed width normally */
.tile {
  background: #000036;
  border-radius: 0.5rem;
  box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.5);
  overflow: hidden;
  text-decoration: none !important;
  transition: transform 0.2s ease;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 25rem;
}
.tile:hover {
  transform: translateY(-0.25rem);
}
/* Image ratio wrapper */
.tile-image-container {
  width: 100%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #000;
}

.tile-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tile-content {
  padding: 1rem;
  flex-grow: 1;
}

.tile-date {
  font-size: 0.85rem;
  color: #bbb;
}

.tile-title {
  font-size: 1.2rem;
}

.tile-intro {
  font-size: 0.95rem;
  height: 1.4rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 768px), (orientation: portrait) {
  .tile-container {
    grid-template-columns: 1fr;
    padding: 1rem;
  }

  .tile {
    max-width: 100%;
  }
}

