/* ─── Reset ──────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ─── Variables ──────────────────────────────────────────── */
:root {
  --bg:      #0a0a0a;
  --surface: #111111;
  --border:  #1e1e1e;
  --text:    #f0f0f0;
  --muted:   #505050;
  --font:    'Inter', sans-serif;
  --panel-w: 52%;
}

/* ─── Base ───────────────────────────────────────────────── */
html, body {
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
  animation: page-in 0.4s ease forwards;
}

@keyframes page-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  display: block;
}

/* ─── Layout ─────────────────────────────────────────────── */
.project-layout {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ─── Left Panel ─────────────────────────────────────────── */
.panel-left {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--panel-w);
  height: 100vh;
  overflow: hidden;
  background: #080808;
  -webkit-mask-image: linear-gradient(
    to bottom,
    transparent 0%,
    black 16%,
    black 84%,
    transparent 100%
  );
  mask-image: linear-gradient(
    to bottom,
    transparent 0%,
    black 16%,
    black 84%,
    transparent 100%
  );
}

/* ─── Loop Strip ─────────────────────────────────────────── */
.loop-strip {
  display: flex;
  flex-direction: column;
  will-change: transform;
}

.loop-strip img {
  width: 100%;
  height: auto;
  display: block;
  flex-shrink: 0;
}

/* ─── Right Panel ────────────────────────────────────────── */
.panel-right {
  margin-left: var(--panel-w);
  width: calc(100% - var(--panel-w));
  height: 100vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 0 64px;
}

.panel-right::-webkit-scrollbar       { width: 2px; }
.panel-right::-webkit-scrollbar-track { background: transparent; }
.panel-right::-webkit-scrollbar-thumb { background: var(--border); }

/* ─── Project Nav ────────────────────────────────────────── */
.project-nav {
  display: flex;
  align-items: center;
  padding: 32px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 64px;
  flex-shrink: 0;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 400;
  color: var(--muted);
  transition: color 0.2s ease;
}

.back-link:hover {
  color: var(--text);
}

.back-link svg {
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.back-link:hover svg {
  transform: translateX(-3px);
}

/* ─── Project Content ────────────────────────────────────── */
.project-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-bottom: 80px;
  min-height: 0;
}

.project-title {
  font-size: clamp(28px, 3.2vw, 52px);
  font-weight: 300;
  letter-spacing: -0.025em;
  line-height: 1.08;
  margin-bottom: 40px;
}

.project-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin-bottom: 40px;
}

/* ─── Meta ───────────────────────────────────────────────── */
.project-meta {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 52px;
}

.meta-row {
  display: flex;
  align-items: baseline;
  gap: 0;
}

.meta-label {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  min-width: 72px;
  flex-shrink: 0;
}

.meta-value {
  font-size: 15px;
  font-weight: 400;
  color: var(--text);
}

/* Status indicator */
.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.status::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status.complete::before    { background: #4a9a6a; }
.status.in-progress::before { background: #9a8840; }

/* ─── Overview ───────────────────────────────────────────── */
.overview-label {
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 14px;
}

.overview-text {
  font-size: 15px;
  font-weight: 400;
  line-height: 1.8;
  color: #b0b0b0;
  max-width: 460px;
}

/* ─── Mobile ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  html, body {
    overflow: auto;
    height: auto;
  }

  .project-layout {
    flex-direction: column;
    height: auto;
    overflow: visible;
  }

  .panel-left {
    position: static;
    width: 100%;
    height: 58vw;
    min-height: 240px;
    max-height: 360px;
  }

  .panel-right {
    margin-left: 0;
    width: 100%;
    height: auto;
    overflow-y: visible;
    padding: 0 24px;
  }

  .project-nav {
    padding: 24px 0;
    margin-bottom: 32px;
  }

  .project-content {
    justify-content: flex-start;
    padding-bottom: 60px;
  }

  .overview-text {
    max-width: 100%;
  }
}
