* {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}
.heading {
  font-family: "Space Grotesk", sans-serif;
}
html {
  scroll-behavior: smooth;
}

body {
  background: #ffffff;
  color: #1a1a1a;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Section margin for smaller screens */
@media (max-width: 767px) {
  section {
    margin-top: 5rem;
  }

  /* Exclude hero section from margin-top */
  #hero-section {
    margin-top: 0;
  }
}

/* Header */
header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
}

/* Nav Links */
.nav-link {
  position: relative;
  transition: color 0.2s ease;
  color: #666;
}

.nav-link:hover {
  color: #1a1a1a;
}

/* Mobile Menu Button */
#mobile-menu-button {
  transition: transform 0.2s ease;
}

#mobile-menu-button:active {
  transform: scale(0.95);
}

/* Mobile Menu */
#mobile-menu {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
}

#mobile-menu:not(.hidden) {
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile Menu Links */
@media (max-width: 767px) {
  #mobile-menu .nav-link {
    transition: color 0.2s ease, padding-left 0.2s ease;
  }

  #mobile-menu .nav-link:hover {
    padding-left: 0.5rem;
  }
}

/* Experience Timeline */
.experience-card {
  position: relative;
  padding-left: 2.5rem;
  padding-bottom: 4rem;
}

.experience-card::before {
  content: "";
  position: absolute;
  left: 0.5rem;
  top: 0.5rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #1a1a1a;
  z-index: 2;
}

.experience-card::after {
  content: "";
  position: absolute;
  left: 0.75rem;
  top: 1.25rem;
  width: 1px;
  height: calc(100% - 0.5rem);
  background: #e5e5e5;
  z-index: 1;
}

.experience-card:last-child::after {
  display: none;
}

/* Hero Section */
#hero-section {
  height: 100vh;
  min-height: 100vh;
  border-bottom: 1px solid #e5e5e5;
  background-image: linear-gradient(to right, #e5e5e5 1px, transparent 1px),
    linear-gradient(to bottom, #e5e5e5 1px, transparent 1px);
  background-size: 30px 30px;
  background-position: 0 0;
}

/* Experience Section */
#experience {
  background-image: radial-gradient(circle, #e5e5e5 2px, transparent 2px);
  background-size: 30px 30px;
  background-position: 0 0;
}

#hero-section > div {
  min-height: 100%;
}

/* Hero Chip Container */
.hero-chip-container {
  margin-top: 5rem;
}

@media (min-width: 768px) {
  .hero-chip-container {
    margin-top: 0;
  }
}

/* Hero Chip */
.hero-chip {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-radius: 9999px;
  border: 1px solid #e5e5e5;
  width: fit-content;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

@media (min-width: 768px) {
  .hero-chip {
    padding: 0.75rem 1.5rem;
  }
}

.hero-chip-text {
  font-family: "Space Grotesk", sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.2;
}

@media (min-width: 768px) {
  .hero-chip-text {
    font-size: 16px;
  }
}

/* Hero Play Button Container */
.hero-play-button-container {
  position: relative;
  display: inline-block;
  overflow: visible;
}

/* Hero Play Button */
.hero-play-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-radius: 50%;
  border: 1px solid #e5e5e5;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #1a1a1a;
}

.hero-play-button:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: scale(1.05);
}

.hero-play-button.playing {
  animation: pulse-orange 2s ease-out infinite;
}

@keyframes pulse-orange {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 85, 0, 0.7);
  }
  100% {
    box-shadow: 0 0 0 15px rgba(255, 85, 0, 0);
  }
}

/* Hero Play Tooltip */
.hero-play-tooltip {
  position: absolute;
  left: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%) translateX(-10px);
  white-space: nowrap;
  background: #1a1a1a;
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 400;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
  z-index: 10;
  max-width: calc(100vw - 2rem);
  right: auto;
}

@media (max-width: 767px) {
  .hero-play-tooltip {
    left: 50% !important;
    right: auto !important;
    top: auto;
    bottom: calc(100% + 12px);
    transform: translateX(-50%) translateY(10px);
    max-width: min(calc(100vw - 2rem), 250px);
    white-space: normal;
    word-wrap: break-word;
    width: max-content;
  }
}

.hero-play-tooltip::before {
  content: "";
  position: absolute;
  right: 100%;
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-right-color: #1a1a1a;
}

.hero-play-button-container:hover .hero-play-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

@media (max-width: 767px) {
  .hero-play-tooltip::before {
    right: auto;
    left: 20px;
    top: 100%;
    bottom: auto;
    transform: translateY(0);
    border: 6px solid transparent;
    border-top-color: #1a1a1a;
    border-right-color: transparent;
    border-left-color: transparent;
    border-bottom-color: transparent;
  }

  .hero-play-button-container:hover .hero-play-tooltip {
    transform: translateX(-50%) translateY(0);
  }
}

.hero-text {
  font-family: "Poiret One", sans-serif;
  font-size: 35px;
  font-weight: 600;
  line-height: 1.4;
}

.hero-text-small {
  font-family: "Space Grotesk", sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
}

@media (min-width: 768px) {
  .hero-text-small {
    font-size: 28px;
  }
}

/* Avatar Container */
.avatar-container {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Hero Avatar */
.hero-avatar {
  width: 100%;
  height: 50vh;
  max-width: 100%;
  object-fit: contain;
  object-position: bottom;
  position: absolute;
  bottom: 0;
  transition: transform 0.4s ease-out;
}

.avatar-main,
.avatar-original {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 0 auto;
  width: 100%;
  height: 50vh;
  object-fit: contain;
  object-position: bottom;
}

.avatar-main.bounce-down {
  animation: bounce-down 0.4s ease-out forwards;
}

.avatar-original.bounce-up {
  animation: bounce-up 0.4s ease-out forwards;
}

.avatar-main.bounce-up {
  animation: bounce-up 0.4s ease-out forwards;
}

.avatar-original.bounce-down {
  animation: bounce-down 0.4s ease-out forwards;
}

@keyframes bounce-down {
  0% {
    transform: translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateY(20px);
    opacity: 0.5;
  }
  100% {
    transform: translateY(100px);
    opacity: 0;
  }
}

@keyframes bounce-up {
  0% {
    transform: translateY(100px);
    opacity: 0;
  }
  50% {
    transform: translateY(-10px);
    opacity: 0.8;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (min-width: 768px) {
  .hero-avatar {
    height: 90vh;
  }

  .avatar-main,
  .avatar-original {
    height: 90vh;
  }
}

/* Full Width Horizontal Line */
.full-width-line {
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  border: none;
  border-top: 1px solid #e5e5e5;
}

/* Contact Section */
.contact-section {
  width: 100%;
  aspect-ratio: 1440 / 560;
  min-height: 560px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 5rem 0 2rem 0;
  position: relative;
}

/* Map Background */
.map-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
  opacity: 0.15;
  background-image: url("assets/imgs/map.svg");
  background-size: cover;
  background-position: right;
  background-repeat: no-repeat;
}

@media (max-width: 767px) {
  .map-background {
    background-position: center center;
  }
}

/* Contact Connect Text */
.contact-connect-text {
  font-family: "Space Grotesk", sans-serif;
  font-size: 48px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #1a1a1a;
  text-transform: uppercase;
}

@media (min-width: 768px) {
  .contact-connect-text {
    font-size: 64px;
  }
}

/* Social Links */
.social-link {
  transition: transform 0.2s ease, opacity 0.2s ease;
  opacity: 0.7;
}

.social-link:hover {
  transform: translateY(-2px);
  opacity: 1;
}

.social-link {
  color: #666;
}

.social-link:hover {
  color: #1a1a1a;
}

/* Contact Footer */
.contact-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem 2rem 1.5rem;
  position: relative;
  z-index: 10;
}

@media (min-width: 768px) {
  .contact-footer {
    padding: 0 2rem 2rem 2rem;
  }
}

.contact-footer-left {
  font-size: 14px;
  color: #737373;
  font-weight: 400;
}

.footer-time {
  font-family: "Space Grotesk", sans-serif;
}

.contact-footer-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 14px;
  color: #737373;
  font-weight: 400;
}

.footer-love {
  font-family: "Space Grotesk", sans-serif;
}

.footer-love .heart {
  color: #ff6b6b;
  animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
}

.footer-lines {
  font-family: monospace;
  letter-spacing: 2px;
  opacity: 0.6;
}

@media (max-width: 767px) {
  .contact-footer {
    flex-direction: row;
    gap: 0;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem 2rem 1.5rem;
  }

  .contact-footer-left {
    font-size: 12px;
  }

  .contact-footer-right {
    font-size: 12px;
    gap: 0.5rem;
  }

  .footer-lines {
    font-size: 10px;
  }
}

/* Highlight Toggle Button */
.highlight-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-radius: 50%;
  border: 1px solid #e5e5e5;
  cursor: pointer;
  transition: all 0.2s ease;
  color: #1a1a1a;
  padding: 0;
}

.highlight-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: scale(1.05);
}

.highlight-toggle-btn:active {
  transform: scale(0.95);
}

.highlight-toggle-btn {
  animation: pulse-gray 2s ease-out infinite;
}

@keyframes pulse-gray {
  0% {
    box-shadow: 0 0 0 0 rgba(229, 229, 229, 0.7);
  }
  100% {
    box-shadow: 0 0 0 15px rgba(229, 229, 229, 0);
  }
}

/* Highlighted Keywords */
#about-content .highlight-keyword,
.about-content .highlight-keyword {
  font-weight: 600;
  color: #1a1a1a;
  display: inline-block;
}

/* Smooth transition for paragraph content */
#about-content {
  position: relative;
}

#about-content p {
  color: #1a1a1a;
  position: relative;
  z-index: 1;
}

/* Non-highlighted text when highlighting is active */
#about-content.highlighted p {
  color: #f7f7f7;
  position: relative;
  z-index: 1;
}

#about-content.highlighted .highlight-keyword {
  color: #1a1a1a !important;
  position: relative;
  z-index: 2;
}
