/* ============================================================
   Portfolio Showcase Styles — Clients Grid + Modal
   ============================================================ */

/* --- Grid --- */
.psc-portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.psc-item {
  background: #0f0f10;
  border-radius: 12px;
  padding: 18px;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 2px 0 rgba(255,255,255,0.02) inset, 0 6px 20px rgba(0,0,0,0.6);
}

.psc-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.psc-thumb img {
  width: 100%;
  height: auto;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

.psc-info { padding-top: 12px; }

.psc-tag {
  display: inline-block;
  background: #222;
  color: #ccc;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 0.8rem;
}

.psc-title {
  margin: 10px 0 6px;
  color: #fff;
  font-size: 1.25rem;
}

.psc-short {
  color: #bdbdbd;
  font-size: 0.95rem;
}

/* ============================================================
   Modal Layout
   ============================================================ */

.psc-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.6);
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.psc-modal[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.psc-modal-content {
  background: #0b0b0c;
  color: #fff;
  width: 90%;
  max-width: 1000px;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.6);
  position: relative;
}

.psc-modal-body h2 {
    color: #fff;
}

.psc-modal-body {
  flex: 1;
  max-height: 80vh;
  overflow: auto;
  padding-right: 8px;
}

/* ============================================================
   Modal Internal Layout (Gallery Left / Text Right)
   ============================================================ */

.psc-modal-flex {
  display: flex;
  flex-wrap: nowrap;
  gap: 2rem;
  align-items: flex-start;
}

.psc-left,
.psc-right {
  flex: 1 1 50%;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  .psc-modal-flex {
    flex-wrap: wrap;
  }
  .psc-left,
  .psc-right {
    flex: 1 1 100%;
  }
}

/* ============================================================
   Gallery Carousel
   ============================================================ */

.psc-gallery-wrapper {
  position: relative;
  overflow: hidden;
  max-width: 100%;
}

.psc-gallery {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.psc-gallery img {
  display: none;
  width: 100%;
  height: auto;
  border-radius: 10px;
  transition: opacity 0.5s ease, transform 0.4s ease;
  opacity: 0;
  transform: scale(0.98);
}

.psc-gallery img.active {
  display: block;
  opacity: 1;
  transform: scale(1);
}

/* --- Carousel Controls --- */
.psc-prev,
.psc-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.4);
  color: white;
  border: none;
  font-size: 2rem;
  padding: 0.5rem 0.8rem;
  cursor: pointer;
 border-radius: 25%;
  z-index: 5;
  transition: background 0.3s ease;
}

.psc-prev:hover,
.psc-next:hover {
  background: rgba(0,0,0,0.7);
}

.psc-prev { left: 10px; }
.psc-next { right: 10px; }

/* ============================================================
   Modal Text Area
   ============================================================ */

.psc-right h2 {
  margin-top: 0;
  font-size: 1.8rem;
}

.psc-meta {
  display: flex;
  gap: 20px;
  color: #cfcfcf;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.psc-meta p {
  margin: 0;
  font-size: 0.95rem;
  color: #cfcfcf;
}

.psc-content {
  margin-top: 1rem;
  line-height: 1.6;
}

/* ============================================================
   Modal Close Button
   ============================================================ */

.psc-close {
  position: absolute;
  top: 18px;
  right: 18px;
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 26px;
  cursor: pointer;
  transition: color 0.3s ease;
}

.psc-close:hover {
  color: #aaa;
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 900px) {
  .psc-portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
    padding: 16px;
  }
}

@media (max-width: 520px) {
  .psc-portfolio-grid {
    grid-template-columns: 1fr;
    padding: 12px;
    gap: 14px;
  }
  .psc-modal-content {
    padding: 16px;
  }
}
