:root {
  --blue-600: #2756b8;
  --ink: #0c1b3a;
  --muted: #5b6b8c;
  --overlay: rgba(0,0,0,.65);
}

body { background: #fff; color: var(--ink); margin:0; font-family: system-ui, sans-serif; }
img { display:block; max-width:100%; height:auto; }
.container { width:min(1200px, 92vw); margin-inline:auto; }
.container-wide { width:min(1400px, 95vw); margin-inline:auto; }
.text-center { text-align: center; }
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* Section spacing */
.section { padding: clamp(2.5rem, 6vw, 5rem) 0; }

/* Hero */
.hero-title {
  font-size: clamp(2.5rem, 4vw, 3rem);
  margin-bottom: 0.5rem;
  font-weight: 700;
}
.hero-subtitle {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 640px;
  margin-inline:auto;
}

/* Portfolio Grid (Masonry style) */
.portfolio-grid {
  column-count: 3;
  column-gap: 1rem;
}
.portfolio-item {
  position: relative;
  display: inline-block;
  width: 100%;
  /* margin: 0 0 1.5rem; */
  overflow: hidden;
  cursor: pointer;
}
.portfolio-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform .5s ease;
}
.portfolio-item:hover img {
  transform: scale(1.08);
}

/* Overlay */
.portfolio-overlay {
  position: absolute;
  inset: 0;
  background: var(--overlay);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: opacity .4s ease;
  padding: 1rem;
}
.portfolio-item:hover .portfolio-overlay { opacity: 1; }

.overlay-content {
  color: #fff;
}
.portfolio-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: .5rem;
}
.portfolio-tags {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  /* justify-content: center; */
  list-style: none;
  padding: 0;
  margin: 0;
}
.portfolio-tags li {
  background: rgba(255,255,255,.2);
  border-radius: 999px;
  padding: .25rem .75rem;
  font-size: .85rem;
  font-weight: 500;
}

/* --- NEW PORTFOLIO ROW LAYOUT --- */
.portfolio-row {
  display: flex;
  align-items: center;
  gap: 3rem;
  margin-bottom: 5rem;
}

.portfolio-row.reverse {
  flex-direction: row-reverse;
}

/* Image */
.portfolio-image {
  flex: 1;
}
.portfolio-image img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

/* Info */
.portfolio-info {
  /* flex: 1; */
}

.portfolio-info .portfolio-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: .75rem;
}

.portfolio-description {
  margin: 1rem 0 1.5rem;
  color: var(--muted);
  max-width: 600px;
}

/* Tags */
.portfolio-tags {
  list-style:none;
  padding:0;
  margin:0 0 1rem 0;
  display:flex;
  flex-wrap:wrap;
  gap:.5rem;
}
.portfolio-tags li {
  background: var(--blue-600);
  color:#fff;
  padding:.3rem .75rem;
  border-radius:999px;
  font-size:.85rem;
}

/* View Site Button */
.portfolio-link {
  display:inline-block;
  margin-top:.5rem;
  padding:.6rem 1.2rem;
  border:2px solid var(--blue-600);
  color:var(--blue-600);
  border-radius:8px;
  font-weight:600;
  text-decoration:none;
  transition:.25s;
}
.portfolio-link:hover {
  background:var(--blue-600);
  color:#fff;
}

/* IMAGE WRAPPER */
.portfolio-image {
  flex: 1;
  overflow: hidden;              /* prevents layout expansion */
  border-radius: 12px;
}

/* IMAGE INSIDE */
.portfolio-image img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  transition: transform .5s ease;  /* smooth zoom */
}

/* HOVER EFFECT */
.portfolio-image:hover img {
  transform: scale(1.07);         /* zoom without enlarging box */
}


/* Responsive */
@media(max-width: 900px){
  .portfolio-row {
    flex-direction: column !important;
    /* text-align: center; */
  }
  .portfolio-info {
    max-width: 600px;
    margin-inline:auto;
  }
}


/* Responsive */
@media (max-width: 1024px){
  .portfolio-grid { column-count: 2; }
}
@media (max-width: 640px){
  .portfolio-grid { column-count: 1; }
  .portfolio-title { font-size: 1.25rem; }
}
