/* Work Archive (Existing) */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(550px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.work-card {
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
}

.work-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.work-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.work-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
 border-radius: 28px;
}

.work-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.work-card:hover .work-card-image img {
  transform: scale(1.05);
}

.work-card-content {
  padding: 30px 0;
  flex-grow: 1;
  display: flex;
  justify-content: space-between;
     align-items: baseline;
  gap: 20px;
}

.work-card-details {
  display: flex;
  flex-direction: column;
  max-width: 85%;
}

.work-card-title {
  font-size: clamp(1rem, 0.9537rem + 0.2469vw, 1.25rem);
  margin: 0 0 15px;
  color: #fff;
  line-height: 1.2;
}

.work-card-excerpt p {
  font-size: 14px;
  color: #fff;
  line-height: 1.6;
      padding: 0;
    margin: 0;
}

.work-card-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  transition: all 0.3s ease;
  flex-shrink: 0;
  margin-bottom: 5px; /* Slight optical alignment */
}

.work-card:hover .work-card-arrow {
  transform: rotate(45deg);
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #000;
}

/* ------------------------------------------------------------------
   Single Work Page Styles
   ------------------------------------------------------------------ */

.single-work-container {
   max-width: 1100px; /* Constrain width for better readability */
   margin: 0 auto;
   color: #ffffff;
   padding-bottom: 80px;
   font-family: 'Inter', sans-serif; /* Assuming Inter or similar sans-serif */
}

/* Header & Meta */
.work-header {
   margin-bottom: 60px;
   padding-top: 40px;
}

.work-title {
   font-size: clamp(2rem, 4vw, 3.5rem);
   font-weight: 700;
   margin-bottom: 20px;
   line-height: 1.1;
   color: #fff;
}

.work-intro {
   font-size: 1.1rem;
   line-height: 1.6;
   color: #aaa;
   max-width: 800px;
   margin-bottom: 50px;
}

.work-meta-grid {
   display: flex;
   gap: 60px;
   border-top: 1px solid rgba(255,255,255,0.1);
   padding-top: 30px;
   flex-wrap: wrap;
}

.work-meta-item {
   display: flex;
   flex-direction: column;
   gap: 8px;
}

.meta-label {
   font-size: 0.9rem;
   color: #fff;
   font-weight: 600;
}

.meta-value {
   font-size: 0.9rem;
   color: #888;
}

/* Main Image */
.work-featured-image {
   width: 100%;
   border-radius: 20px;
   overflow: hidden;
   margin-bottom: 80px;
   background: #1a1a1a;
}
.work-featured-image img {
   display: block;
   width: 100%;
   height: auto;
}

/* Challenge & Results */
.work-details-section {
   display: grid;
   grid-template-columns: 1fr 1fr;
   gap: 60px;
   margin-bottom: 80px;
}

.work-detail-block h2 {
   font-size: 1.8rem;
   margin-bottom: 20px;
   color: #fff;
}

.work-detail-content {
   color: #ccc;
   line-height: 1.7;
   font-size: 1rem;
}

/* Gallery Grid */
.work-gallery-grid {
   display: grid;
   grid-template-columns: 1fr 1fr;
   gap: 40px;
   margin-bottom: 80px;
}

.gallery-item {
   border-radius: 20px;
   overflow: hidden;
   background: #1a1a1a;
   aspect-ratio: 16/10;
}

.gallery-item img {
   width: 100%;
   height: 100%;
   object-fit: cover;
}

/* Impact Section */
.work-impact-section {
   margin-bottom: 100px;
}

.section-title {
   font-size: 2rem;
   margin-bottom: 10px;
   color: #fff;
}

.section-subtitle {
   color: #888;
   margin-bottom: 50px;
   font-size: 1rem;
}

.text-center { text-align: center; }

/* Impact Stats Grid (Before/After Cards) */
.impact-stats-grid {
   display: grid;
   grid-template-columns: repeat(3, 1fr);
   gap: 30px;
   margin-bottom: 60px;
}

.impact-stat-card {
   background: #111;
   border-radius: 20px;
   padding: 30px;
   border: 1px solid #222;
}

.stat-header, .stat-footer {
   margin-bottom: 30px;
}

.stat-footer { margin-bottom: 0; }

.impact-stat-card h3 {
   font-size: 0.9rem;
   text-transform: uppercase;
   color: #666; /* "Before" label color */
   margin-bottom: 10px;
   letter-spacing: 1px;
}

.stat-footer h3 {
   color: #fff; /* "After" label color */
}

.stat-metric-label {
   display: block;
   font-size: 0.85rem;
   color: #888;
   margin-bottom: 5px;
}

.stat-value {
   display: block;
   font-size: 2rem;
   font-weight: 700;
   color: #fff;
   margin-bottom: 10px;
}

.stat-value.highlight {
   color: #FDD600; /* Yellow accent */
}

.stat-bar-container {
   width: 100%;
   height: 4px;
   background: #333;
   border-radius: 2px;
   overflow: hidden;
   margin-top: 15px;
}

.stat-bar {
   height: 100%;
   background: #FDD600;
   border-radius: 2px;
}

/* Key Improvements Section */
.key-improvements-title {
   font-size: 1.5rem;
   margin-bottom: 40px;
   color: #fff;
}

.key-improvements-grid {
   display: grid;
   grid-template-columns: repeat(3, 1fr);
   gap: 30px;
}

.improvement-card {
   background: #1a1a1a;
   padding: 25px;
   border-radius: 12px;
   text-align: left;
   position: relative;
   overflow: hidden;
}

.improvement-card::before {
   content: '+';
   position: absolute;
   top: 10px;
   right: 15px;
   color: #00ff88; /* Green plus sign */
   font-size: 1.2rem;
}

.improvement-label {
   display: block;
   font-size: 0.9rem;
   color: #aaa;
   margin-bottom: 10px;
}

.improvement-values {
   font-size: 1.4rem;
   font-weight: 700;
   color: #fff;
   display: flex;
   align-items: center;
   gap: 10px;
   margin-bottom: 5px;
}

.improvement-values .arrow {
   color: #666;
   font-size: 1rem;
}

.improvement-desc {
   font-size: 0.85rem;
   color: #666;
   margin: 0;
}

/* Testimonial */
.work-testimonial {
   max-width: 800px;
   margin: 0 auto 80px;
   text-align: left;
}

.testimonial-icon {
   margin-bottom: 30px;
}

.testimonial-content {
   font-size: 1.5rem;
   line-height: 1.4;
   color: #fff;
   margin: 0 0 40px;
   font-weight: 500;
}

.testimonial-author {
   display: flex;
   align-items: center;
   gap: 15px;
}

.author-img {
   width: 50px;
   height: 50px;
   border-radius: 50%;
   object-fit: cover;
}

.author-details {
   display: flex;
   flex-direction: column;
}

.author-name {
   font-weight: 700;
   color: #fff;
}

.author-role {
   font-size: 0.9rem;
   color: #888;
}

/* Footer Nav */
.work-footer-nav {
   border-top: 1px solid #333;
   padding-top: 40px;
   margin-top: 60px;
}

/* Mobile Responsive */
@media (max-width: 900px) {
   .work-details-section,
   .work-gallery-grid,
   .impact-stats-grid,
   .key-improvements-grid {
     grid-template-columns: 1fr;
   }
   
   .work-meta-grid {
     gap: 30px;
   }

   .work-title {
     font-size: 2.5rem;
   }

   .impact-stat-card {
     margin-bottom: 20px;
   }
}

@media (max-width: 768px) {
  .work-grid {
    grid-template-columns: 1fr;
  }

  .work-card-content {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .work-card-details {
    max-width: 100%;
  }

  .work-card-arrow {
    align-self: flex-end;
    margin-top: 15px;
  }
}
