/* ---------- GLOBAL ---------- */
    :root {
      --bg: #0c0d0f;
      --fg: #eaeaea;
      --accent: #4cc2ff;
      --muted: #888;
      --card-bg: #15171b;
      --shadow: rgba(0,0,0,0.6);
      --radius: 12px;
      --transition: 0.3s ease;
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    body {
      background: var(--bg);
      color: var(--fg);
      font-family: "Inter", "Segoe UI", sans-serif;
      line-height: 1.6;
      padding: 2rem 6vw;
    }

    h1 {
      font-size: 2rem;
      margin-bottom: 2rem;
      letter-spacing: -0.03em;
    }

    a {
      color: var(--accent);
      text-decoration: none;
      transition: color var(--transition);
    }
    a:hover {
      color: white;
    }

    /* ---------- PORTFOLIO GRID ---------- */
    .portfolio-item {
      display: grid;
      grid-template-columns: 1.2fr 1fr;
      gap: 2.5rem;
      margin-bottom: 5rem;
      align-items: start;
    }

    @media (max-width: 900px) {
      .portfolio-item {
        grid-template-columns: 1fr;
      }
    }

 /* ---------- PREVIEW ---------- */
.preview {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  cursor: pointer;
  box-shadow: 0 8px 24px var(--shadow);
  transition: transform var(--transition);
  aspect-ratio: 16 / 9; /* Keeps all previews proportional */
}
.preview:hover {
  transform: scale(1.02);
}

/* Image + video behave normally */
.preview img,
.preview video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  display: block;
}

/* Iframes (e.g., YouTube) fill the same space cleanly */
.preview iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: var(--radius);
}



    /* ---------- DETAILS ---------- */
    .details h2 {
      font-size: 1.5rem;
      margin-bottom: 0.25rem;
    }
    .details .role {
      color: var(--muted);
      font-weight: 600;
      margin-bottom: 1rem;
    }
    .details .desc {
      margin-bottom: 1.5rem;
      color: #ccc;
      max-width: 600px;
    }
    .details .link {
      display: inline-block;
      background: var(--accent);
      color: #0c0d0f;
      padding: 0.6rem 1.2rem;
      border-radius: 6px;
      font-weight: 600;
      transition: all var(--transition);
    }
    .details .link:hover {
      background: white;
      color: #000;
    }

    /* ---------- LIGHTBOX ---------- */
    .lightbox {
      display: none;
      position: fixed;
      inset: 0;
      background: rgba(0,0,0,0.85);
      backdrop-filter: blur(8px);
      justify-content: center;
      align-items: center;
      z-index: 1000;
      animation: fadeIn 0.3s ease forwards;
    }

    @keyframes fadeIn {
      from { opacity: 0; }
      to { opacity: 1; }
    }

    .lightbox img,
    .lightbox iframe,
    .lightbox video {
      max-width: 90%;
      max-height: 85vh;
      border-radius: var(--radius);
      box-shadow: 0 0 40px rgba(0,0,0,0.8);
    }

    .close {
      position: absolute;
      top: 2rem;
      right: 2.5rem;
      font-size: 2rem;
      color: var(--fg);
      cursor: pointer;
      transition: color var(--transition);
    }
    .close:hover {
      color: var(--accent);
    }

/* ---------- CAROUSEL ---------- */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px var(--shadow);
  aspect-ratio: 16 / 9;
}

.carousel-track {
  display: flex;
  transition: transform 0.5s ease;
  width: 100%;
  height: 100%;
}

.carousel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  flex-shrink: 0;
  border-radius: var(--radius);
  cursor: pointer;
}

.carousel .nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.4);
  color: white;
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.5rem;
  z-index: 10;
  transition: background 0.3s ease;
}
.carousel .nav:hover {
  background: rgba(255,255,255,0.2);
}
.carousel .nav.prev {
  left: 1rem;
}
.carousel .nav.next {
  right: 1rem;
}
