/* CarMax Portfolio Page - Modern Design */

/* ============================================
   CSS Variables & Base Styles
   ============================================ */
.carmax,
.carmax * {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

.carmax {
  /* Use CSS variables from vars.css */
  font-family: var(--body-regular-400-font-family, "WorkSans-Regular", sans-serif);
  background: var(--gray-white, #ffffff);
  display: flex;
  flex-direction: column;
  gap: 60px;
  align-items: center;
  padding-top: 80px !important;
  justify-content: flex-start;
  position: relative;
  overflow: hidden;
  width: 100%;
  color: var(--gray-700, #424e60);
}

/* Ensure navigation components fill parent width */
.navigation-bar,
.footer-component {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  position: relative;
  left: 0;
  right: 0;
}

/* ============================================
   Typography - Using WorkSans
   ============================================ */
.carmax h1,
.carmax h2,
.carmax h3,
.carmax h4,
.carmax h5,
.carmax h6 {
  font-family: var(--heading-01-font-family, "WorkSans-SemiBold", sans-serif);
  color: var(--gray-900, #132238);
  font-weight: 600;
}

.carmax p,
.carmax li {
  font-family: var(--body-regular-400-font-family, "WorkSans-Regular", sans-serif);
  font-size: 18px;
  line-height: 1.7;
  color: var(--gray-600, #556070);
  text-align: justify;
}

/* Section Titles */
.carmax .car-max,
.carmax .project-title {
  font-family: var(--heading-01-font-family, "WorkSans-SemiBold", sans-serif);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--gray-900, #132238);
  text-align: center;
  margin-bottom: 24px;
}

.carmax .problem,
.carmax .research,
.carmax .solution,
.carmax .design-process,
.carmax .competitive-analysis-title,
.carmax .project-outcome-title {
  font-family: var(--heading-02-font-family, "WorkSans-SemiBold", sans-serif);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  color: var(--gray-900, #132238);
  text-align: center;
  margin-bottom: 24px;
  position: relative;
}

.carmax .problem::after,
.carmax .research::after,
.carmax .solution::after,
.carmax .design-process::after,
.carmax .competitive-analysis-title::after,
.carmax .project-outcome-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--primary-500, #a53dff);
  border-radius: 2px;
  margin: 16px auto 0;
}

/* Links */
.carmax a {
  color: var(--primary-500, #a53dff);
  text-decoration: none;
  transition: color 0.3s ease;
}

.carmax a:hover {
  color: var(--primary-600, #8431cc);
  text-decoration: underline;
}

/* Footer link colors - matching other portfolio pages */
.footer-component a,
#footer a {
  color: #f0f1f3 !important;
}

.footer-component a:hover,
#footer a:hover {
  color: #a53dff !important;
}

/* ============================================
   Main Content Container - CENTERED
   ============================================ */
.carmax-content {
  display: flex;
  flex-direction: column;
  gap: 60px;
  align-items: center;
  justify-content: flex-start;
  align-self: center;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  z-index: 1;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 24px;
}

.carmax-sections {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 40px;
  align-items: center;
  justify-content: center;
  align-self: center;
  flex-shrink: 0;
  position: relative;
}

/* ============================================
   Section Styles - CENTERED CARDS
   ============================================ */
.about-carmax,
.problem-carmax,
.research-carmax,
.solution-carmax,
.design-process-carmax,
.competitive-analysis-carmax,
.project-outcome-carmax {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  align-items: center;
  justify-content: center;
  align-self: center;
  flex-shrink: 0;
  position: relative;
  background: var(--gray-white, #ffffff);
  border-radius: 20px;
  box-shadow: 0px 8px 40px rgba(43, 56, 76, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-carmax:hover,
.problem-carmax:hover,
.research-carmax:hover,
.solution-carmax:hover,
.design-process-carmax:hover,
.competitive-analysis-carmax:hover,
.project-outcome-carmax:hover {
  transform: translateY(-4px);
  box-shadow: 0px 16px 60px rgba(43, 56, 76, 0.12);
}

/* Section content wrapper */
.section-contents {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
  justify-content: center;
  align-self: center;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 900px;
}

.carmax-title-container,
.carmax-title-wrapper,
.content-wrapper,
.content-inner {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  width: 100%;
}

/* ============================================
   Background Effects
   ============================================ */
.carmax .ellipse-6 {
  background: linear-gradient(
    181.87deg,
    rgba(255, 223, 168, 0.8) 0%,
    rgba(255, 226, 176, 0.77) 0.01%,
    rgba(255, 234, 198, 0.54) 100%,
    rgba(250, 211, 144, 0.64) 100%
  );
  border-radius: 50%;
  width: 1293.62px;
  height: 1209.7px;
  position: absolute;
  left: 366px;
  top: 7252.81px;
  transform-origin: 0 0;
  transform: rotate(-30deg) scale(1, 1);
  filter: blur(100px);
  z-index: 0;
  pointer-events: none;
}

.carmax .ellipse-4 {
  background: rgba(196, 245, 233, 0.7);
  border-radius: 50%;
  width: 1044.32px;
  height: 1044.32px;
  position: absolute;
  left: -77.55px;
  top: 3725.22px;
  transform-origin: 0 0;
  transform: rotate(-130.444deg) scale(1, 1);
  filter: blur(300px);
  z-index: 0;
  pointer-events: none;
}

/* Movement/ decorative elements */
.carmax .movement-1,
.carmax .movement-2,
.carmax .movement-3 {
  position: absolute;
  z-index: 0;
  pointer-events: none;
}

.carmax .movement-1 {
  width: 581px;
  height: 537px;
  right: 30px;
  top: 1962px;
}

.carmax .movement-1 .ellipse-7 {
  background: linear-gradient(
    181.87deg,
    rgba(255, 223, 168, 0.4) 0%,
    rgba(255, 226, 176, 0.38) 0.01%,
    rgba(255, 234, 198, 0.27) 100%,
    rgba(250, 211, 144, 0.32) 100%
  );
  border-radius: 50%;
  width: 466.25px;
  height: 454.24px;
  position: absolute;
  left: calc(50% - 290.5px);
  top: 265.24px;
  filter: blur(100px);
}

.carmax .movement-3 {
  width: 384px;
  height: 372px;
  left: 50%;
  transform: translateX(-50%);
  top: 3320px;
}

.carmax .movement-3 .ellipse-72 {
  background: rgba(0, 192, 232, 0.1);
  border-radius: 50%;
  width: 366.8px;
  height: 429.44px;
  position: absolute;
  left: calc(50% - 192px);
  top: 265.24px;
  filter: blur(100px);
}

.carmax .movement-2 {
  width: 577px;
  height: 559px;
  left: calc(50% - 602.5px);
  top: 4967px;
}

.carmax .movement-2 .ellipse-73 {
  background: rgba(219, 177, 255, 0.4);
  border-radius: 50%;
  width: 464.08px;
  height: 453.65px;
  position: absolute;
  left: calc(50% - 288.5px);
  top: 265.24px;
  filter: blur(100px);
}

/* ============================================
   Image Display - Modern Cards
   ============================================ */
.image-container {
  display: flex;
  flex-direction: row;
  gap: 24px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  align-content: center;
  align-self: center;
  flex-shrink: 0;
  position: relative;
  width: 100%;
  margin-top: 32px;
}

.project-image-1,
.project-image-2,
.project-image-3 {
  flex: 1;
  height: auto;
  min-width: 280px;
  max-width: 100%;
  min-height: 200px;
  /* Increased max-height for larger display */
  max-height: none;
  position: relative;
  object-fit: contain;
  /* Removed aspect-ratio to allow natural dimensions */
  border-radius: 16px;
  box-shadow: 0px 12px 40px rgba(43, 56, 76, 0.15);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  width: 100%;
}

/* Make project-image-2 even larger (the main hero image) */
.project-image-2 {
  max-height: none;
  min-height: 400px;
  width: 100%;
}

.project-image-1:hover,
.project-image-2:hover,
.project-image-3:hover {
  transform: scale(1.03) translateY(-8px);
  box-shadow: 0px 20px 50px rgba(43, 56, 76, 0.2);
}

/* ============================================
   Lists - Modern Styling
   ============================================ */
.carmax ul,
.carmax ol {
  width: 100%;
  max-width: 900px;
  padding-left: 0;
  list-style: none;
}

.carmax ul li,
.carmax ol li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 20px;
  font-family: var(--body-regular-400-font-family, "WorkSans-Regular", sans-serif);
  font-size: 17px;
  line-height: 1.7;
  color: var(--gray-600, #556070);
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

.carmax ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-400, #b764ff), var(--primary-500, #a53dff));
}

.carmax ol li {
  counter-increment: list-counter;
}

.carmax ol li::before {
  content: counter(list-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary-500, #a53dff);
  color: white;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carmax li:last-child {
  margin-bottom: 0;
}

/* ============================================
   Content Description Styles
   ============================================ */
.project-description-carmax,
.problem-description-carmax,
.research-details-carmax,
.solution-details-carmax,
.design-process-details-carmax,
.competitive-analysis-details-carmax,
.project-outcome-details-carmax {
  width: 100%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  font-family: var(--body-regular-400-font-family, "WorkSans-Regular", sans-serif);
  font-size: 18px;
  line-height: 1.7;
  color: var(--gray-600, #556070);
  text-align: justify;
}

/* Span and text styles */
.project-description-span-carmax,
.problem-description-span-carmax,
.solution-details-span-carmax {
  display: block;
  font-size: 18px;
  line-height: 1.8;
  color: var(--gray-600, #556070);
  margin-bottom: 8px;
}

.project-description-link-carmax {
  text-decoration: underline;
  color: var(--primary-500, #a53dff);
  font-family: var(--body-regular-500-font-family, "WorkSans-Medium", sans-serif);
}

/* List styles */
.research-details-list-carmax,
.solution-details-list-carmax,
.design-process-list-carmax,
.competitive-analysis-list-carmax,
.project-outcome-list-carmax {
  width: 100%;
  max-width: 900px;
  padding-left: 0;
  list-style: none;
}

.research-details-list-item-carmax,
.solution-details-list-item-carmax,
.design-process-list-item-carmax,
.competitive-analysis-list-item-carmax,
.project-outcome-list-item-carmax {
  position: relative;
  padding-left: 32px;
  margin-bottom: 20px;
  font-family: var(--body-regular-400-font-family, "WorkSans-Regular", sans-serif);
  font-size: 17px;
  line-height: 1.7;
  color: var(--gray-600, #556070);
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
  text-align: justify;
}

.research-details-list-item-carmax::before,
.solution-details-list-item-carmax::before,
.design-process-list-item-carmax::before,
.competitive-analysis-list-item-carmax::before,
.project-outcome-list-item-carmax::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-400, #b764ff), var(--primary-500, #a53dff));
}

/* ============================================
   Footer Styles
   ============================================ */
.footer-container {
  display: flex;
  flex-direction: column;
  gap: 100px;
  align-items: center;
  justify-content: flex-start;
  align-self: stretch;
  flex-shrink: 0;
  position: relative;
  width: 100%;
}

/* ============================================
   Responsive Design
   ============================================ */
@media screen and (max-width: 1024px) {
  .carmax .about-carmax,
  .carmax .problem-carmax,
  .carmax .research-carmax,
  .carmax .solution-carmax,
  .carmax .design-process-carmax,
  .carmax .competitive-analysis-carmax,
  .carmax .project-outcome-carmax {
    padding: 32px 24px;
    margin: 0 16px;
    width: calc(100% - 32px);
  }
  
  .carmax .car-max,
  .carmax .project-title {
    font-size: 2rem;
  }
  
  .carmax .problem,
  .carmax .research,
  .carmax .solution,
  .carmax .design-process,
  .carmax .competitive-analysis-title,
  .carmax .project-outcome-title {
    font-size: 1.75rem;
  }
  
  .carmax p,
  .carmax li {
    font-size: 16px;
    line-height: 1.6;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  
  .carmax .section-contents,
  .carmax ul,
  .carmax ol {
    max-width: 100%;
  }
}

@media screen and (max-width: 768px) {
  .carmax {
    padding-top: 70px !important;
    gap: 60px;
  }
  
  .carmax-content {
    padding: 0 16px;
    gap: 60px;
  }
  
  .carmax .about-carmax,
  .carmax .problem-carmax,
  .carmax .research-carmax,
  .carmax .solution-carmax,
  .carmax .design-process-carmax,
  .carmax .competitive-analysis-carmax,
  .carmax .project-outcome-carmax {
    padding: 24px 20px;
    border-radius: 16px;
    margin: 0 12px;
    width: calc(100% - 24px);
  }
  
  .carmax .car-max,
  .carmax .project-title {
    font-size: 1.75rem;
  }
  
  .carmax .problem,
  .carmax .research,
  .carmax .solution,
  .carmax .design-process,
  .carmax .competitive-analysis-title,
  .carmax .project-outcome-title {
    font-size: 1.5rem;
  }
  
  .carmax p,
  .carmax li {
    font-size: 15px;
    line-height: 1.6;
    text-align: justify;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  
  .image-container {
    flex-direction: column;
    gap: 16px;
  }
  
  .project-image-1,
  .project-image-2,
  .project-image-3 {
    width: 100%;
    min-width: unset;
    max-width: 100%;
    height: auto;
  }
  
  .carmax .section-contents,
  .carmax ul,
  .carmax ol {
    max-width: 100%;
  }
  
  .carmax .movement-1,
  .carmax .movement-2,
  .carmax .movement-3 {
    display: none;
  }
}

@media screen and (max-width: 480px) {
  .carmax {
    padding-top: 60px !important;
    gap: 40px;
  }
  
  .carmax-content {
    gap: 40px;
  }
  
  .carmax .about-carmax,
  .carmax .problem-carmax,
  .carmax .research-carmax,
  .carmax .solution-carmax,
  .carmax .design-process-carmax,
  .carmax .competitive-analysis-carmax,
  .carmax .project-outcome-carmax {
    padding: 20px 16px;
    margin: 0 8px;
    width: calc(100% - 16px);
    border-radius: 12px;
  }
  
  .carmax .car-max,
  .carmax .project-title {
    font-size: 1.5rem;
  }
  
  .carmax .problem,
  .carmax .research,
  .carmax .solution,
  .carmax .design-process,
  .carmax .competitive-analysis-title,
  .carmax .project-outcome-title {
    font-size: 1.25rem;
  }
  
  .carmax p,
  .carmax li {
    font-size: 14px;
    line-height: 1.5;
  }
  
  .carmax ul li,
  .carmax ol li {
    padding-left: 20px;
    font-size: 14px;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  
  .carmax ul li::before {
    width: 6px;
    height: 6px;
    top: 6px;
  }
}

/* ============================================
   Animation Classes
   ============================================ */
.carmax .animate-fadeInUp {
  animation: fadeInUp 0.6s ease-out forwards;
}

.carmax .animate-delay-1 { animation-delay: 0.1s; }
.carmax .animate-delay-2 { animation-delay: 0.2s; }
.carmax .animate-delay-3 { animation-delay: 0.3s; }
.carmax .animate-delay-4 { animation-delay: 0.4s; }
.carmax .animate-delay-5 { animation-delay: 0.5s; }
.carmax .animate-delay-6 { animation-delay: 0.6s; }

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

/* ============================================
   Utility Classes
   ============================================ */
.carmax .text-center { text-align: center; }
.carmax .text-left { text-align: left; }
.carmax .text-justify { text-align: justify; }

.carmax .mb-0 { margin-bottom: 0; }
.carmax .mb-1 { margin-bottom: 8px; }
.carmax .mb-2 { margin-bottom: 16px; }
.carmax .mb-3 { margin-bottom: 24px; }
.carmax .mb-4 { margin-bottom: 32px; }

.carmax .mt-0 { margin-top: 0; }
.carmax .mt-1 { margin-top: 8px; }
.carmax .mt-2 { margin-top: 16px; }
.carmax .mt-3 { margin-top: 24px; }
.carmax .mt-4 { margin-top: 32px; }

.carmax .container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 24px;
}
