/* Pastel Studios — Portfolio Site */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:      #0d0d0f;
  --bg2:     #161618;
  --border:  #242428;
  --text:    #e8e8ea;
  --muted:   #888890;
  --accent:  #c8a96e;
  --accent2: #a8895e;
  --radius:  10px;
  --max-w:   1280px;
}

html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font: 15px/1.6 'Inter', system-ui, sans-serif; }
a    { color: var(--accent); text-decoration: none; }
img  { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ── Header ──────────────────────────────────────────────────────────────── */
header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(13,13,15,.92); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 32px;
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.logo { font-size: 20px; font-weight: 700; color: var(--accent); letter-spacing: .04em; }
.logo span { color: var(--text); }
nav a { color: var(--muted); margin-left: 28px; font-size: 14px; transition: color .2s; }
nav a:hover { color: var(--text); }

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero {
  max-width: var(--max-w); margin: 0 auto;
  padding: 100px 32px 60px;
}
.hero h1 { font-size: clamp(36px, 5vw, 64px); font-weight: 800; line-height: 1.1; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p  { color: var(--muted); max-width: 520px; margin-top: 16px; font-size: 17px; }

/* ── Projects grid ───────────────────────────────────────────────────────── */
.projects-section { max-width: var(--max-w); margin: 0 auto; padding: 20px 32px 80px; }
.section-title { font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 28px; }

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 2px;
}
.project-card {
  position: relative; overflow: hidden;
  aspect-ratio: 4/3; cursor: pointer;
  background: var(--bg2);
}
.project-card img {
  transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.project-card:hover img { transform: scale(1.06); }
.project-card-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.85) 0%, transparent 60%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 20px;
  opacity: 0; transition: opacity .3s;
}
.project-card:hover .project-card-overlay { opacity: 1; }
.project-card-title { font-size: 17px; font-weight: 700; color: #fff; }
.project-card-desc  { font-size: 13px; color: rgba(255,255,255,.7); margin-top: 4px; }

/* ── Single project (gallery page) ──────────────────────────────────────── */
.gallery-section { max-width: var(--max-w); margin: 0 auto; padding: 40px 32px 80px; }
.back-link { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; margin-bottom: 32px; transition: color .2s; }
.back-link:hover { color: var(--text); }
.project-title { font-size: clamp(24px, 4vw, 44px); font-weight: 800; margin-bottom: 8px; }
.project-desc-text { color: var(--muted); margin-bottom: 40px; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 3px;
}
.gallery-item { aspect-ratio: 4/3; overflow: hidden; cursor: zoom-in; }
.gallery-item:first-child { grid-column: span 2; aspect-ratio: 16/9; }
.gallery-item img { transition: transform .4s; }
.gallery-item:hover img { transform: scale(1.04); }

/* ── Lightbox ────────────────────────────────────────────────────────────── */
.lightbox {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,.95); align-items: center; justify-content: center;
}
.lightbox.open { display: flex; }
.lightbox img  { max-width: 90vw; max-height: 90vh; object-fit: contain; border-radius: 4px; }
.lightbox-close { position: absolute; top: 20px; right: 24px; font-size: 32px; color: #fff; cursor: pointer; opacity: .7; }
.lightbox-close:hover { opacity: 1; }
.lightbox-prev, .lightbox-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  font-size: 40px; color: #fff; cursor: pointer; opacity: .6;
  user-select: none; padding: 20px;
}
.lightbox-prev { left: 10px; }
.lightbox-next { right: 10px; }
.lightbox-prev:hover, .lightbox-next:hover { opacity: 1; }

/* ── Footer ──────────────────────────────────────────────────────────────── */
footer { border-top: 1px solid var(--border); text-align: center; padding: 32px; color: var(--muted); font-size: 13px; }

/* ── About ───────────────────────────────────────────────────────────────── */
.about-section { max-width: 720px; margin: 60px auto; padding: 0 32px 80px; }
.about-section h2 { font-size: 32px; margin-bottom: 20px; }
.about-section p  { color: var(--muted); margin-bottom: 16px; line-height: 1.8; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .header-inner { padding: 0 16px; }
  .hero, .projects-section, .gallery-section, .about-section { padding-left: 16px; padding-right: 16px; }
  .projects-grid { grid-template-columns: 1fr; }
  .gallery-item:first-child { grid-column: span 1; aspect-ratio: 4/3; }
  nav { display: none; }
}
