@import url('https://fonts.googleapis.com/css2?family=IM+Fell+English:ital@0;1&family=IBM+Plex+Mono:wght@400;700&display=swap');

:root {
  --bg:     #111111;
  --text:   #cccccc;
  --dim:    #666666;
  --white:  #eeeeee;
  --border: #2a2a2a;
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  line-height: 1.75;
  max-width: 860px;
  margin: 0 auto;
  padding: 40px 24px 80px;
}

a {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 3px;
}
a:hover { color: var(--text); }

/* ── HEADER ── */
header {
  margin-bottom: 48px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.site-name {
  font-family: 'IM Fell English', serif;
  font-size: 1.4rem;
  color: var(--white);
  text-decoration: none;
  display: block;
  margin-bottom: 14px;
}
.site-name:hover { color: var(--text); }

nav { display: flex; flex-wrap: wrap; gap: 0; }
nav a {
  color: var(--dim);
  text-decoration: none;
  font-size: 12px;
  margin-right: 20px;
}
nav a:hover, nav a.active {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── PAGE TITLE ── */
h1 {
  font-family: 'IM Fell English', serif;
  font-size: 2rem;
  font-weight: 400;
  color: var(--white);
  margin-bottom: 8px;
  line-height: 1.2;
}

.page-desc {
  color: var(--dim);
  font-size: 12px;
  margin-bottom: 40px;
}

/* ── SECTION LABEL ── */
.section-label {
  font-size: 11px;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
  margin-top: 40px;
}

/* ── FEED / LOG ── */
.feed { margin-bottom: 40px; }

.feed-entry {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 0 20px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
}

.feed-date  { color: var(--dim); font-size: 12px; padding-top: 1px; }
.feed-title { color: var(--white); margin-bottom: 3px; }
.feed-body  { color: var(--text); font-size: 12px; }

.feed-tags { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 11px; color: var(--dim); border: 1px solid var(--border); padding: 0 5px; }

/* ── PROJECTS ── */
.project-list { margin-bottom: 40px; }

.project-row {
  display: grid;
  grid-template-columns: 110px 1fr 70px;
  gap: 0 20px;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
}
.project-row:hover .project-title { text-decoration: underline; text-underline-offset: 3px; }

.project-date    { color: var(--dim); font-size: 12px; }
.project-title   { color: var(--white); margin-bottom: 3px; }
.project-summary { color: var(--text); font-size: 12px; }
.project-status  { color: var(--dim); font-size: 11px; text-align: right; padding-top: 2px; }
.project-tags    { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; }

/* ── PROJECT PAGE ── */
.back {
  display: inline-block;
  color: var(--dim);
  text-decoration: none;
  font-size: 12px;
  margin-bottom: 28px;
}
.back:hover { color: var(--white); }

.project-header {
  margin-bottom: 36px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}
.project-header h1 { margin-bottom: 10px; }
.project-meta { color: var(--dim); font-size: 12px; display: flex; flex-wrap: wrap; gap: 12px; }

.project-body { max-width: 660px; }
.project-body h2 {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--dim);
  margin: 32px 0 10px;
}
.project-body p  { margin-bottom: 14px; font-size: 13px; line-height: 1.8; }
.project-body ul { margin-bottom: 14px; list-style: none; }
.project-body ul li { font-size: 13px; padding: 2px 0; }
.project-body ul li::before { content: '- '; color: var(--dim); }

.project-body code {
  background: #1a1a1a;
  border: 1px solid var(--border);
  padding: 1px 5px;
  font-size: 12px;
}
.project-body pre {
  background: #1a1a1a;
  border: 1px solid var(--border);
  padding: 14px 16px;
  overflow-x: auto;
  margin-bottom: 16px;
  font-size: 12px;
  line-height: 1.6;
}

/* ── GALLERY ── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 3px;
  margin-bottom: 40px;
}

.gallery-item { position: relative; aspect-ratio: 1; overflow: hidden; background: #1a1a1a; cursor: pointer; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity 0.15s; }
.gallery-item:hover img { opacity: 0.7; }
.gallery-item-label {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: rgba(0,0,0,0.85);
  padding: 6px 8px; font-size: 11px; color: var(--text);
  transform: translateY(100%); transition: transform 0.12s;
}
.gallery-item:hover .gallery-item-label { transform: translateY(0); }

.lightbox {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.96); z-index: 1000;
  align-items: center; justify-content: center; cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 90vw; max-height: 88vh; object-fit: contain; display: block; }
.lightbox-caption {
  position: fixed; bottom: 20px; left: 0; right: 0;
  text-align: center; font-size: 11px; color: var(--dim);
}

/* ── LINKS ── */
.link-row {
  display: flex;
  gap: 24px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
  align-items: baseline;
  flex-wrap: wrap;
}
.link-name { color: var(--white); min-width: 180px; }
.link-desc { color: var(--dim); font-size: 12px; }

/* ── ABOUT ── */
.about-body { max-width: 580px; }
.about-body p { margin-bottom: 16px; font-size: 13px; line-height: 1.85; }

.info-table { margin: 28px 0; }
.info-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 0 16px;
  padding: 8px 0;
  border-top: 1px solid var(--border);
  font-size: 12px;
}
.info-label { color: var(--dim); }
.info-value  { color: var(--text); }

/* ── FOOTER ── */
footer {
  margin-top: 60px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 11px;
  color: var(--dim);
  display: flex;
  justify-content: space-between;
}

/* ── UTIL ── */
.loading { color: var(--dim); font-size: 12px; padding: 20px 0; }

@media (max-width: 600px) {
  body { padding: 24px 16px 60px; }
  .feed-entry { grid-template-columns: 1fr; }
  .feed-date  { margin-bottom: 4px; }
  .project-row { grid-template-columns: 1fr; }
  .project-status { text-align: left; }
  .link-row { flex-direction: column; gap: 2px; }
}
