/* 
  neilsolomon.me
  A simple, handcrafted stylesheet.
*/

/* ================================
   Variables
   ================================ */

:root {
  --bg: #0d0d0d;
  --bg-subtle: #1a1a1a;
  --text: #e0e0e0;
  --text-muted: #888;
  --accent: #b8c4ce;
  --font-mono: ui-monospace, 'SF Mono', 'Menlo', 'Consolas', 'Liberation Mono', 'Courier New', monospace;
}

/* ================================
   Reset & Base
   ================================ */

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

html {
  font-size: 16px;
}

body {
  font-family: var(--font-mono);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  min-height: 100vh;
  padding: 2rem 1.5rem;
}

/* ================================
   Layout
   ================================ */

.container {
  max-width: 700px;
  margin: 0 auto;
}

/* ================================
   Typography
   ================================ */

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1, h2, h3 {
  font-weight: normal;
}

h1 {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
}

h2 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 1rem;
  margin-top: 2.5rem;
}

h3 {
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
  margin-top: 1.5rem;
}

p {
  max-width: 65ch;
  margin-bottom: 1rem;
  color: var(--text-muted);
}

ul, ol {
  max-width: 65ch;
  margin-bottom: 1rem;
  margin-left: 1.5rem;
  color: var(--text-muted);
}

li {
  margin-bottom: 0.5rem;
}

blockquote {
  border-left: 2px solid var(--bg-subtle);
  padding-left: 1rem;
  margin-bottom: 1rem;
  color: var(--text-muted);
  font-style: italic;
}

code {
  font-family: var(--font-mono);
  background: var(--bg-subtle);
  padding: 0.1rem 0.3rem;
  font-size: 0.9em;
}

pre {
  background: var(--bg-subtle);
  padding: 1rem;
  overflow-x: auto;
  margin-bottom: 1rem;
}

pre code {
  background: none;
  padding: 0;
}

hr {
  border: none;
  border-top: 1px solid var(--bg-subtle);
  margin: 2rem 0;
}

/* ================================
   Header
   ================================ */

header {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--bg-subtle);
}

.site-name {
  font-size: 1rem;
  font-weight: normal;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.site-name a {
  color: var(--text);
}

.tagline {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* ================================
   Definition List Navigation
   ================================ */

dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.25rem 1.5rem;
}

dt {
  text-align: right;
}

dt a {
  color: var(--accent);
}

dd {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ================================
   Main Content
   ================================ */

main {
  margin-bottom: 3rem;
}

/* ================================
   Footer
   ================================ */

footer {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--bg-subtle);
}

.elsewhere {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
}

.elsewhere a {
  color: var(--text-muted);
}

.elsewhere a:hover {
  color: var(--text);
}

/* ================================
   Subpage Header
   ================================ */

.subpage-nav {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.subpage-nav a {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.subpage-nav a:hover {
  color: var(--text);
}

/* ================================
   Blog
   ================================ */

.post-list {
  list-style: none;
  margin-left: 0;
}

.post-list li {
  margin-bottom: 1.5rem;
}

.post-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 0.25rem;
}

.post-title {
  font-size: 1rem;
}

article {
  max-width: 65ch;
}

article p {
  margin-bottom: 1.25rem;
}

/* ================================
   Photo Gallery
   ================================ */

.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 2rem;
}

.photo-item {
  display: block;
  height: 280px;
}

.photo-item img {
  height: 200px;
  width: auto;
  display: block;
  object-fit: contain;
}

.photo-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  display: block;
}

.photo-location {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: block;
}

/* Single photo page */
.photo-single img {
  max-width: 100%;
  max-height: 90vh;
  height: auto;
  width: auto;
  display: block;
  margin-bottom: 1rem;
}

.photo-single .photo-meta {
  font-size: 0.85rem;
}

.photo-single .photo-location {
  font-size: 0.85rem;
}

/* ================================
   Links Page
   ================================ */

.links-section {
  margin-bottom: 2.5rem;
}

/* ================================
   Easter Egg
   ================================ */

.easter-egg {
  margin-top: 1.5rem;
  font-size: 1rem;
  opacity: 0.4;
}

.easter-egg:hover {
  opacity: 1;
}

/* ================================
   Responsive
   ================================ */

@media (max-width: 600px) {
  body {
    padding: 1.5rem 1rem;
  }

  dl {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  dt {
    text-align: left;
  }

  dd {
    margin-bottom: 1rem;
    padding-left: 1rem;
  }

  .gallery {
    grid-template-columns: 1fr;
  }
}
