body {
    margin: 0;
    overflow-x: hidden;
    font-family: Arial, sans-serif;
    background-color: #00312F;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    color: #ffffff; /* white text */
}

#opening-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #00312F;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  animation: fadeOutWrapper 4s forwards;
  animation-delay: 3s;
}

#dot-line {
  width: 10px;
  height: 10px;
  background-color: #f7c6b5;
  border-radius: 50%;
  animation: expandToLine 1s ease-out forwards, splitLine 1s ease-out forwards 1s;
}

@keyframes expandToLine {
  0% {
    width: 10px;
    height: 10px;
  }
  100% {
    width: 80%;
    height: 3px;
    border-radius: 2px;
  }
}

@keyframes splitLine {
  0% {
    transform: scaleX(1);
    opacity: 1;
  }
  100% {
    transform: scaleX(0.1);
    opacity: 0;
  }
}

@keyframes fadeOutWrapper {
  to {
    opacity: 0;
    visibility: hidden;
  }
}

.container {
    text-align: center;
    padding: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* centers vertically */
    flex-direction: column;
}

.profile-header {
    margin-bottom: 30px;
}

.section-top {
  border: none;
  height: 3px;
  background-color: #f7c6b5;
  margin: 10px auto 10px auto;
  width: 70%;
  opacity: 0;
  border-radius: 2px;

  animation: slideUp 6s ease-out forwards;
  animation-delay: 0.5s; /* Optional: adds a small delay for dramatic effect */
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(250px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes expandProfile {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.profile-section {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    width: 80%;
    max-width: 1000px;
    margin: 0 auto;
    gap: 8px; /* reduced gap */
    padding: 1rem;
    background-color: rgba(255, 255, 255, 0.03); /* optional background for distinction */
    border-radius: 12px;

    transform: scale(0.5);
    opacity: 0;
    animation: expandProfile 6s ease-out forwards;
}

.profile-section p,
.profile-section h1,
.profile-section h2 {
  font-size: 1rem; /* Adjust for smaller screens */
  word-wrap: break-word;
}


@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.left-section {
    flex: 1;
    min-width: 300px;
    text-align: center;
    padding: 10px;
    animation: slideInLeft 6s ease-out forwards;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.right-section {
    position: relative;
    flex: 2;
    min-width: 400px;
    text-align: justify;
    padding: 20px;
    animation: fadeUp 6s ease-out forwards; 
    border-left: 2px solid #f7c6b5;
}


.profile-pic {
    width: auto;
    height: 300px; /* maintain the same size */
    object-fit: cover;
    border-radius: 20px;
    border: 6px solid #ffffff;
    box-shadow: 0 6px 12px rgba(0,0,0,0.5);
    margin-bottom: 15px;
}

h1 {
    font-size: 28px;
    margin-bottom: 5px;
}

.tagline {
    font-size: 18px;
    color: #f7c6b5;
}

.intro {
    font-size: 1rem;
    text-align: justify;
    margin: 20px auto;
    width: 90%;
    max-width: 1000px;
    font-size: 18px;
    line-height: 1.6;
}

.intro-image {
    margin: 20px auto;
    width: auto;
    margin-top: 80px;
    text-align: center;
}

.intro-image img {
    max-width: 90%;
    height: 180px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

@keyframes slideFromTop {
  0% {
    transform: translateY(-250px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

.section-divider {
  border: none;
  height: 3px;
  background-color: #f7c6b5;
  margin: 10px auto 10px auto;
  width: 70%;
  opacity: 0;
  border-radius: 2px;

  animation: slideFromTop 6s ease-out forwards;
  animation-delay: 0.5s; /* Optional: adds a small delay for dramatic effect */
}

.button-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  position: relative;
  animation: slideFromTop 6s ease-out forwards;
  animation-delay: 0.5s;  
}


.button-container button {
    margin: 10px;
    padding: 14px 24px;
    font-size: 18px;
    border: 2px solid #f7c6b5; /* border color */
    border-radius: 8px;
    background-color: #00312F; /* same as container background */
    color: #ffffff; /* white text */
    cursor: pointer;
    transition: background 0.3s, color 0.3s;
    font-weight: bold;
}

.button-container button:hover {
    background-color: #f7c6b5;
    color: #00312F; /* invert colors on hover */
}


/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    z-index: 100;
    padding-top: 80px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.7); /* dark transparent background */
}

.modal-content {
    background-color: #00312F; /* match modal background */
    margin: auto;
    padding: 30px;
    border-radius: 10px;
    width: 80%;
    max-width: 700px;
    color: white;
    position: relative;
    box-shadow: 0 8px 16px rgba(255,255,255,0.2);
    max-height: 80vh;
    overflow-y: auto;
}

.close {
    color: #ffffff;
    position: absolute;
    right: 20px;
    top: 10px;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: #f7c6b5;
}

#magnifier {
  position: absolute;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  border: 3px solid black;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 10;
  transition: top 1s ease, left 1s ease, transform 0.5s ease;
}

/* Add a handle below the circle */
#magnifier::after {
  content: "";
  position: absolute;
  top: 100%; /* stick appears directly under magnifier */
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 60px;
  background-color: #f7c6b5;
  border-radius: 3px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

@keyframes expandMsg {
  0% {
    transform: scale(0.8);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

#magnifier-message {
    position: absolute;
    z-index: 100;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    white-space: nowrap;
    color: black;
    background: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: bold;
    font-size: 12px;
    text-align: center;
    opacity: 0;
    animation: expandMsg 0.5s ease-in-out forwards;
}


@media screen and (max-width: 738px) {
  /* General layout adjustments */
  .container {
    text-align: center;  
    padding: 0px 0px;
    justify-content: center;
    align-items: center;  
  }

  .profile-section {
    flex-direction: column;
    gap: 1px;
    width: 100%;
    padding: 0rem; 
    box-sizing: border-box;
    word-wrap: break-word;
    overflow-wrap: break-word;  
  }

  .profile-section h1,
  .profile-section h2 {
    font-size: 1.2rem;
  }

  .profile-section p {
    font-size: 0.95rem;
  }  

  .left-section,
  .right-section {
    width: 100%;
    padding: 0px;
  }

  .right-section {
    border-left: none;
    padding-top: 0.5px;
  }

  .intro {
    text-align: center;
    font-size: 14px;
    padding: 0px;
    width: 90%;  
    font-size: 0.95rem;  
  }

  /* Adjust headings and tagline */
  h1 {
    font-size: 20px;
  }

  .tagline {
    font-size: 12px;
  }

  /* Profile image */
  .profile-pic {
    height: 300px;
    width: 90%;
    max-width: 250px;
    object-fit: cover;
  }

  .intro-image img {
    height: 180px;
    width: 100%;
    max-width: 280px;
  }

   .button-container {
    flex-direction: column;
    align-items: center;
    gap: 1px; /* Reduced from 20px to 10px */
    margin-top: 2px;
   }

   .button-container button {
    width: 100%;
    max-width: 200px;
    font-size: 14px;
    margin: 1px 0; /* Reduced vertical margin */
   }

  /* Modal content resizing */
  .modal-content {
    width: 95%;
    max-height: 70vh;
    font-size: 14px;
    padding: 2px;
  }

  /* Skills list layout */
  .skills-columns ul {
    min-width: unset;
    width: 100%;
  }

  /* Horizontal lines and tree layout fix */
  .horizontal-line {
    flex-direction: column;
    align-items: center;
  }

  .branch-left,
  .branch-right {
    width: 2px;
    height: 20px;
    margin: 2px 0;
  }

  .tree-line {
    height: 160px;
  }

  .vertical-to-buttons {
    top: 80px;
    transform: translateY(0);
  }
}







