/* General Styles */
.case-study-body {
  font-family: "Open Sans", sans-serif;
  grid-column-gap: 40px;
  margin: 24px;
}
.tai-body {
  background: linear-gradient(
    90deg in oklab,
    rgba(0, 0, 255, 0.3),
    rgba(255, 0, 0, 0.3)
  );
}
.fds-body {
  background: linear-gradient(
    90deg in oklab,
    rgba(17, 255, 0, 0.3),
    rgba(255, 238, 0, 0.3)
  );
}
.hs-body {
  background: linear-gradient(
    90deg in oklab,
    rgba(43, 0, 255, 0.3),
    rgba(255, 153, 0, 0.3)
  );
  overflow-x: hidden;
}
.case-study-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  width: 100%;
}
.case-study {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

/* Hero Section */
.project-title {
  background-color: #000;
  color: #fff;
  padding: 8px;
  border-radius: 8px;
}
.hero {
  display: flex;
  gap: 40px;
  margin-top: 64px;
  max-width: 100%;
}
.hero-img {
  max-width: 800px;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}
.hidden {
  display: none;
}
.hero-ul {
  list-style-type: none;
  margin: 0;
  padding: 0 16px 0;
}
.hero-ul li::before {
  content: "✔"; /* Add a checkmark before each list item */
  margin-right: 8px;
}
/* Project Section */
.project-section {
  margin: 80px 0;
  border-radius: 8px;
}

/* Typography */
.li-span {
  font-weight: 700;
}
.italic {
  font-style: italic;
}

/* Containers */
.height-md {
  height: 64px;
}
.text-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 500px;
  width: 100%;
}
.text-container-lg {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 1000px;
  width: 100%;
}
.img-col-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}
.text-container-artifact li {
  padding: 16px 0;
  border-bottom: 1px solid rgb(202, 202, 202);
}
.text-img-container-lg {
  display: flex;
  flex-direction: column;
  max-width: 1000px;
  width: 100%;
  gap: 8px;
}
.text-img-container-sm {
  display: flex;
  flex-direction: column;
  gap: 32px;
  max-width: 500px;
  width: 100%;
}

/* .flex-container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  min-width: 0;
  width: 100%;
} */
.flex-container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 32px;
  min-width: 0;
  width: 100%;
  overflow: hidden; /* Add this to prevent horizontal overflow */
}
/* .img-container {
  width: 100%;
  display: flex;
  gap: 16px;
} */
.img-container {
  width: 100%;
  display: flex;
  gap: 16px;
  min-width: 0; /* Allow container to shrink below intrinsic width */
  flex-shrink: 1; /* Allow container to shrink within parent flex */
  overflow: hidden; /* Optional: Contain child elements */
}
.comp-container {
  width: 100%;
  display: flex;
  gap: 16px;
  min-width: 0; /* Allow container to shrink below intrinsic width */
  flex-shrink: 1; /* Allow container to shrink within parent flex */
  overflow: hidden; /* Optional: Contain child elements */
}
.flex-col {
  display: flex;
  flex-direction: column;
}

/* Image Styles */

.final-haptic-img {
  background-color: #000;
}

.trends-img {
  width: 100%; /* Make sure the image can scale down */
  max-width: 600px; /* Limit the maximum width of the image */
  height: auto; /* Maintain aspect ratio */
  flex: 1 1 auto; /* Allow the image to shrink but not grow */
}

/* .img-container img {
  max-width: 600px;
  width: 100%;
} */
.how-img {
  width: 100%;
  max-width: 500px;
}
.dator-img {
  width: 100%;
  max-width: 600px;
  height: auto;
}
.artifact-img {
  width: 100%;
  max-width: 500px;
  height: 600px;
  object-fit: cover;
}
.final-img {
  width: 100%;
  height: auto;
  max-width: 600px;
  min-width: 0;
  flex-shrink: 1;
}

.final-imgs {
  display: flex;
  gap: 16px;
}

/* Backgrounds & Cards */
.glass-bg {
  background-color: rgba(157, 157, 157, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
  padding: 16px;
  border-radius: 8px;
}
/* .glass-bg p {
  color: rgb(232, 232, 232);
} */
.takeaway-card {
  background-color: rgba(157, 157, 157, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
  padding: 16px;
  border-radius: 8px;
  width: 100%;
  /* max-width: 700px; */
}
.takeaway-card-ul {
  list-style: circle;
  margin: 0;
  padding: 0 16px 0;
}
.takeaway-card-ul-row {
  display: flex;
  gap: 16px;
  list-style: none;
  padding: 0;
}
.takeaway-card-ul-row li {
  padding: 16px;
  background-color: #fff;
  color: #000;
  border-radius: 8px;
}
.takeaway-card li {
  padding: 16px 0;
  border-bottom: 1px solid rgb(202, 202, 202);
}
.no-border {
  border-bottom: rgba(0, 0, 0, 0);
}

/* Borders */
.border-btm {
  border-bottom: 1px solid #000;
  padding: 16px 0;
}

/* Spacing & Layout */
.margin-btm-md {
  margin-bottom: 16px;
}
.margin-btm-lg {
  margin-bottom: 32px;
}
.margin-tp-md {
  margin-top: 16px;
}
.margin-tp-lg {
  margin-top: 32px;
}
.padding-btm-xl {
  padding-bottom: 64px;
}
/* .para-width-md {
  max-width: 500px;
  width: 100%;
  margin: 8px 0;
} */
.para-width-md {
  max-width: 500px;
  min-width: 0; /* Add this */
  flex-shrink: 0; /* Prevent text column from shrinking */
  margin: 8px 0;
}
.para-width-lg {
  max-width: 800px;
  width: 100%;
  margin: 8px 0;
}

/* Slideshow */
.slideshow-container {
  position: relative;
  width: 100%;
}
.slide {
  display: none;
}
.active {
  display: flex;
}
.buttons {
  margin-top: 15px;
  text-align: center;
}
/* .buttons button {
  padding: 10px 15px;
  border: none;
  background: #000000;
  color: rgb(255, 255, 255);
  cursor: pointer;
  border-radius: 5px;
  border: 1px solid #000;
  margin: 5px;
  transition: all 0.3s;
}
.buttons button:hover {
  background: transparent;
  color: rgb(0, 0, 0);
} */

/* TAI */
.impact-card {
  display: flex;
  align-items: center;
  padding: 32px;
  height: auto;
  font-size: 32px;
  background: linear-gradient(to bottom, #38ff8494, #5e69ff8e);
  backdrop-filter: blur(6px);
  width: 100%;
  max-width: 600px;
  border-radius: 8px;
  text-align: center;
}
.impact-card p {
  font-size: 32px;
  color: #fff;
}
.impact-span {
  font-weight: 500;
  font-size: 40px;
}
.content-link {
  display: inline-block;
  text-align: center;
  background-color: #000;
  color: #fff;
  padding: 16px;
  border-radius: 8px;
  text-decoration: none;
  border: 1px solid #000;
  transition: all 0.3s;
}
.content-link:hover {
  background-color: transparent;
  color: rgb(0, 0, 0);
  border: 1px solid #000;
}
/* TAI Card */
.research-card {
  background-color: rgba(157, 157, 157, 0.2); /* semi-transparent white */
  backdrop-filter: blur(6px); /* increased blur for a more pronounced effect */
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: rgb(0, 0, 0);
  padding: 16px;
  border-radius: 8px;
  margin: 32px 0;
}
/* .research-card p {
  color: rgb(0, 0, 0);
} */
.text-card {
  background-color: #000;
  color: #fff;
  padding: 16px;
  border-radius: 8px;
  width: 100%;
  max-width: 600px;
}
.text-card p {
  color: #fff;
}
.comparison-card {
  padding: 16px;
  background-color: rgba(157, 157, 157, 0.2); /* semi-transparent white */
  backdrop-filter: blur(6px); /* increased blur for a more pronounced effect */
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #000; /* Adjust text color for contrast */
  border-radius: 8px;
  margin: 32px 0;
}
.glass-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 32px 0;
}
.glass-card {
  display: flex;
  gap: 16px;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding: 16px;
  border-radius: 8px;
  background-color: rgba(157, 157, 157, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
  max-width: 300px;
  height: 200px;
  width: 100%;
}
.glass-card-lg {
  display: flex;
  gap: 16px;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding: 16px;
  border-radius: 8px;
  background-color: rgba(157, 157, 157, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
  max-width: 500px;
  height: 400px;
  width: 100%;
}
.glass-card-text {
  font-size: 20px;
  color: #000;
  font-weight: 500;
  text-decoration: none;
}

/* TAI img */
/* .comp-img {
  max-width: 140px;
  width: 100%;
  height: auto;
} */
.comp-img {
  max-width: 140px;
  width: 100%;
  height: auto;
  flex: 1 1 0%; /* Equal flexible sizing */
  min-width: 0; /* Override default flex minimum width */
  object-fit: contain; /* Maintain aspect ratio */
}
.tai-img {
  width: 100%;
  max-width: 670px;
  min-width: 0;
  height: auto;
}
.landing-mobile-img {
  max-width: 200px;
}
/* Common Styling for Image Containers */
.image-container {
  position: relative;
  max-width: 100%;
  overflow: hidden;
  height: 500px; /* Initial cutoff height */
  transition: height 0.5s ease-in-out;
}

/* Image Styling */
.tai-img {
  width: 100%;
  display: block;
  cursor: zoom-in;
}

/* Fullscreen Overlay */
.fullscreen-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: start; /* Aligns image at the top */
  z-index: 99999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease-in-out;
  overflow-y: auto; /* Ensures vertical scrolling */
  overflow-x: hidden; /* Prevents horizontal scrolling */
  padding-top: 20px; /* Prevents images from sticking to the top edge */
}

/* Active state (visible) */
.fullscreen-overlay.active {
  opacity: 1;
  pointer-events: all;
  cursor: zoom-out;
}

/* Fullscreen Image Styling */
.fullscreen-img {
  cursor: zoom-out;
  transition: transform 0.3s ease-in-out;
  max-width: 60vw;
  max-height: 60vh;
  object-fit: contain; /* Keeps aspect ratio */
}

/* Special Styling for Large Images */
.fullscreen-scroll {
  max-width: 800px;
  max-height: none; /* Allows full scrolling */
  height: auto;
  display: block;
}

/* Flex container to align large images */
.fullscreen-container {
  display: flex;
  flex-direction: column; /* Ensures natural document flow */
  align-items: center;
  width: 100%;
}

/* Blur Effect at the Bottom */
.image-container::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  /* max-width: 670px; */
  width: 100%;
  height: 100px; /* Blur height */
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 1) 100%
  );
  transition: opacity 0.3s ease-in-out;
}

/* Expanded State */
.expanded {
  height: auto !important;
}

.expanded::after {
  opacity: 0; /* Hide the blur effect after expansion */
}

/* Expand/Minimize Button */
.expand-btn {
  /* position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999999; */
  display: block;
  margin: 0.5rem auto; /* Centers the button and adds vertical spacing */
  z-index: 1; /* z-index no longer needed for layering */
}

.expand-btn:hover {
  background: transparent;
  color: #000;
  border: 1px solid #000;
}

/* Folder container styles */
.folder {
  position: relative;
  max-width: 600px;
  width: 100%;
  height: 400px;
  border-radius: 10px;
}

/* Tabs container */
.tabs {
  position: relative;
  height: 32px;
}

/* Tab styling with reversed z-index order */
.tab {
  position: absolute;
  top: 0;
  padding: 10px 20px;
  width: 100px;
  background-color: #ff6347; /* Bright red */
  border: 1px solid #000;
  border-bottom: none;
  border-radius: 5px 5px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: bold;
  color: white;

  transition: transform 0.2s ease;
  font-size: 8px;
}

/* Reverse overlapping: left-most tab gets highest z-index */
.tab:nth-child(1) {
  left: 10px;
  z-index: 4;
  background-color: #5e69ff;
}

.tab:nth-child(2) {
  left: 90px;
  z-index: 3;
  background-color: #ff5ed7;
}

.tab:nth-child(3) {
  left: 170px;
  z-index: 2;
  background-color: #ffbc5e;
}

.tab:nth-child(4) {
  left: 250px;
  z-index: 1;
  background-color: #19bb4a;
}

/* Hover effect for tabs */

/* Active tab styling */
.tab.active {
  text-align: center;
  z-index: 10; /* Ensure active tab is on top */
}
.tab:nth-child(1).active {
  background-color: #5e69ff;
}

.tab:nth-child(2).active {
  background-color: #ff5ed7;
}

.tab:nth-child(3).active {
  background-color: #ffbc5e;
}

.tab:nth-child(4).active {
  background-color: #19bb4a;
}

/* Folder content area styling */
.content {
  padding: 20px;
  background-color: #5e69ff;
  border: 1px solid #000;
  height: calc(100% - 40px);
  border-radius: 0 0 10px 10px;
  position: relative;
  overflow: hidden;
}
.content-inner {
  background-color: #fff;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  padding: 8px;
}

.tab-content {
  display: none;
  font-size: 14px;
  color: rgb(0, 0, 0);
}
.tab-content-card {
  background-color: #b4b4b449;
  border-radius: 4px;
  padding: 2px 4px;
  margin-bottom: 8px;
}
/* Show the active content */
.tab-content.active {
  display: block;
}

/* Fullscreen overlay */
.fullscreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999999;
  cursor: zoom-out;
  opacity: 0;
  animation: fadeIn 0.3s forwards;
}

/* Enlarged image styling */
.fullscreen img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  transition: transform 0.3s ease-in-out;
}

/* Fade-in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Prevent scrolling when an image is open */
body.no-scroll {
  overflow: hidden;
}

/* Footer */
.case-study-footer {
  position: static;
}

/* Responsive Design */

@media (max-width: 992px) {
  .flex-container,
  .img-container {
    flex-direction: column;
    width: 100%;
    gap: 16px;
  }
  .glass-card {
    max-width: 100%;
  }
  .break-wrap-lg {
    flex-wrap: wrap;
  }
  .artifact-img {
    max-width: 100%;
  }
}
@media (max-width: 768px) {
  .max-width-xl {
    display: none;
  }
  .comp-img {
    max-width: 60%;
    height: auto;
    padding: 4px;
    align-self: center;
  }
  .impact-cards {
    flex-wrap: wrap;
  }
  .impact-card {
    max-width: 100%;
  }
  .dator-img {
    max-width: 100%;
    height: 300px;
  }
  .text-container-dator {
    height: 160px;
  }
  .hero {
    display: block;
    margin-top: 16px;
  }
  .grid-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }
  .hero-img {
    display: none;
    max-width: 100%;
  }
  .hidden {
    display: block;
  }
  .slide {
    height: 80vh;
    overflow: auto;
  }
  .text-container-artifact {
    height: 500px;
  }
  .tai-img {
    max-width: 100%;
  }
  .final-img {
    max-width: 100%;
  }
  .break-wrap-md {
    flex-wrap: wrap;
  }
}

@media (max-width: 480px) {
  .case-study-body {
    margin: 16px;
  }
  .text-container-artifact {
    height: 540px;
  }
}
