@import url('https://fonts.googleapis.com/css2?family=Ancizar+Serif&family=Roboto&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Ancizar Serif', serif;
  background-color: #ffffff;
  color: #333;
  line-height: 1.6;
  padding: 0;
  margin: 0;
}

h1 {
  font-weight: bold;
  font-size: 3.5vw;
}

.container {
  max-width: 1000px;
  margin: auto;
  padding: 2rem 1rem;
}

/* Intro Section */
.intro-section {
  text-align: center;
  margin-bottom: 2rem;
  opacity: 0;
  transition: opacity 1s ease;
}

.intro-section h1 {
  font-size: 2.5rem;
  font-weight: bolder;
  margin-bottom: 0.5rem;
  line-height: 1.2;
  font-family: 'Ancizar Serif';
}

.intro-section h2 {
  font-size: 1.2rem;
  font-weight: bold;
  color: #555;
  margin-bottom: 0.3rem;
}

/* Navigation Tabs */
.tabs {
  display: flex;
  justify-content: space-around;
  background-color: #fff;
  border-bottom: 2px solid #ddd;
  min-height: 48px;
  height: 48px;
}

.tab {
  padding: 0.6rem 1rem;
  text-align: center;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.tab:hover {
  background-color: #f1f1f1;
}

.tab.active {
  border-bottom: 3px solid #0077cc;
  color: #0077cc;
  font-weight: bold;
}

/* Tab Content */
.tab-content {
  display: none;
  padding: 1.5rem 0;
  opacity: 0;
  transition: opacity 1s ease;
}

.tab-content.active {
  display: block;
  opacity: 1;
}

/* Profile Image Styling */
.profile-img {
  float: left;
  width: 30%;
  max-width: 300px;
  height: auto;
  margin-right: 2rem;
  margin-bottom: 1rem;
  object-fit: cover;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  /* Center profile image */
  .profile-img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    float: none;
    width: 100%;
    max-width: 100%;
    margin-bottom: 2rem;
  }
  
  .intro-section h1 {
    font-size: 2rem;
    font-weight: bolder;
    font-family: 'Ancizar Serif';
  }
  
  .intro-section h2 {
    font-size: 0.9rem;
    font-weight: bold;
  }
  
  .download-cv a {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: bold;
    color: #fff;
    background-color: #639ec7;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;
  }
  
  .download-cv a:hover {
    background-color: #005fa3;
  }
  
  .pdf-container iframe {
    width: 100%;
    height: 80vh;
  }
  
  .pdf-container::after {
    display: block;
    text-align: center;
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.5rem;
  }
  
  ul li {
    display: block;
    margin-bottom: 0.75rem;
  }
  
  ul li a {
    display: inline;
    color: #0077cc;
    text-decoration: none;
  }
  
  ul li a:hover {
    text-decoration: underline;
  }
}

@media (max-width: 480px) {
  .intro-section h1 {
    font-size: 1.7rem;
  }
  
  .intro-section h2 {
    font-size: 0.8rem;
  }
  
  .tab {
    font-size: 0.75rem;
    padding: 0.5rem;
  }
  
  .container {
    padding: 2rem 0.75rem;
  }
}

/* Download CV Button Styling */
.download-cv {
  text-align: center;
  margin-bottom: 1rem;
}

.download-cv a {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: bold;
  color: #fff;
  background-color: #639ec7;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

.download-cv a:hover {
  background-color: #005fa3;
}

/* PDF Viewer */
.pdf-container {
  width: 100%;
  overflow: hidden;
  position: relative;
}

.pdf-container iframe {
  width: 100%;
  height: 600px;
  border: none;
  transition: height 0.3s ease;
}

/* Fade-In Animation */
.fade-in {
  opacity: 0;
  transition: opacity 1s ease;
}

.fade-in.active {
  opacity: 1;
}

/* Site Footer */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: #f9f9f9;
  text-align: center;
  font-size: 0.9rem;
  color: #666;
  border-top: 1px solid #b9ccda;
  padding: 1rem 0;
  z-index: 1000;
}

/* Prevent content from hiding behind fixed footer */
.content,
.container {
  padding-bottom: 2rem;
}

.dynamic-content {
  font-size: 1rem;
  line-height: 1.6;
  color: #333;
}

/* Optional: Remove Google Docs-specific classes */
.dynamic-content p,
.dynamic-content h1,
.dynamic-content h2,
.dynamic-content h3,
.dynamic-content span {
  margin: 0;
  padding: 0.5rem 0;
  font-family: inherit;
  font-weight: normal;
  color: #333 !important;
}

.publications {
  padding-bottom: 2rem;
  text-align: center;
}

.dynamic-content a {
  color: #0077cc;
  text-decoration: underline;
}

.dynamic-content a:hover {
  opacity: 0.9;
}

#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  text-align: center;
}

#loading-screen .loading-gif {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
}

#loading-screen p {
  font-size: 1.2rem;
  color: #333;
  margin-bottom: 1rem;
  z-index: 1;
}

.progress-container {
  width: 80%;
  max-width: 400px;
  height: 8px;
  background-color: #eee;
  border-radius: 4px;
  overflow: hidden;
  margin-top: 1rem;
  z-index: 1;
}

#progress-bar {
  height: 100%;
  width: 0%;
  background-color: #0077cc;
  transition: width 0.3s ease;
}

#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  text-align: center;
  background-size: cover;
  background-position: center;
  background-color: #0077cc; /* Light gray */
}

#loading-screen .splash-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

#loading-screen.hidden {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.spinner {
  border: 8px solid #f3f3f3;
  border-top: 8px solid #3498db;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loadingMsg {
  padding: 2rem;
}

#researchGateId {
  margin: 2rem;
}