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

body {
  font-family: 'Inter', sans-serif;
  background: #faf9f7;
  color: #1c1917;
  min-height: 100vh;
  padding: 2.5rem;
  line-height: 1.6;
}

a {
  color: #1c1917;
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #57534e;
}

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

/* Header */
header {
  margin-bottom: 2.5rem;
}

header h1 {
  font-family: 'EB Garamond', serif;
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  border-bottom: 2px solid #1c1917;
  padding-bottom: 0.75rem;
}

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

/* Homepage grid */
.main-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
}

.left-col section {
  margin-bottom: 2rem;
}

section h2 {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #78716c;
  margin-bottom: 0.75rem;
  font-weight: 500;
}

/* Homepage post list */
.post-list { list-style: none; }

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

.post-list a {
  color: #1c1917;
  text-decoration: none;
  display: block;
  padding: 0.75rem 0;
  border-bottom: 1px solid #e7e5e4;
  transition: all 0.2s;
}

.post-list a:hover {
  padding-left: 0.75rem;
  border-bottom-color: #1c1917;
}

.post-list .post-title {
  font-family: 'EB Garamond', serif;
  font-size: 1.25rem;
  display: block;
  margin-bottom: 0.25rem;
}

.post-list .post-meta {
  font-size: 0.75rem;
  color: #a8a29e;
  display: block;
  margin-bottom: 0.35rem;
}

.post-list .post-summary {
  font-size: 0.85rem;
  color: #57534e;
  display: block;
  line-height: 1.5;
}

/* Right column */
.right-col {
  padding-top: 0.25rem;
}

.right-col section {
  margin-bottom: 2rem;
}

.right-col h2 {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: #78716c;
  margin-bottom: 0.75rem;
  font-weight: 500;
}

.links-vertical a {
  display: block;
  color: #57534e;
  text-decoration: none;
  font-size: 0.8rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid #e7e5e4;
  transition: color 0.2s;
}

.links-vertical a:hover {
  color: #1c1917;
}

/* Post page styles */
.post {
  max-width: 650px;
}

.post-header {
  margin-bottom: 2rem;
}

.post-title {
  font-family: 'EB Garamond', serif;
  font-size: 2rem;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 0.5rem;
}

.post-date {
  font-size: 0.85rem;
  color: #78716c;
}

.post-content {
  line-height: 1.8;
}

.post-content h2 {
  font-family: 'EB Garamond', serif;
  font-size: 1.4rem;
  font-weight: 400;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: #1c1917;
}

.post-content h3 {
  font-size: 1.1rem;
  font-weight: 500;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.post-content p {
  margin-bottom: 1.25rem;
}

.post-content ul,
.post-content ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
}

.post-content li {
  margin-bottom: 0.5rem;
}

.post-content a {
  color: #57534e;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.post-content a:hover {
  color: #1c1917;
}

.post-content code {
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
  font-size: 0.85em;
  background: #f0eeeb;
  padding: 0.15em 0.4em;
  border-radius: 3px;
}

.post-content pre {
  background: #f0eeeb;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  overflow-x: auto;
  margin-bottom: 1.25rem;
}

.post-content pre code {
  background: none;
  padding: 0;
}

.post-content blockquote {
  border-left: 3px solid #e7e5e4;
  padding-left: 1.25rem;
  margin: 1.5rem 0;
  color: #57534e;
  font-style: italic;
}

.post-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e7e5e4;
}

/* Recipe page styles */
.recipe {
  max-width: 700px;
}

.recipe-header {
  margin-bottom: 1.5rem;
}

.recipe-title {
  font-family: 'EB Garamond', serif;
  font-size: 2rem;
  font-weight: 400;
  line-height: 1.3;
}

.recipe-media {
  display: flex;
  gap: 2rem;
  margin: 1.5rem 0;
  align-items: flex-start;
  justify-content: center;
}

.recipe-video iframe {
  border-radius: 8px;
  max-width: 100%;
}

.photo-strip {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
  max-width: 400px;
}

.photo-strip img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.photo-strip img:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.recipe-hero {
  max-width: 100%;
  border-radius: 8px;
}

.recipe-intro {
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.recipe-intro p {
  margin-bottom: 1rem;
}

.time-info {
  color: #78716c;
  font-size: 0.9rem;
  margin: 1.5rem 0;
  padding: 0.75rem 0;
  border-top: 1px solid #e7e5e4;
  border-bottom: 1px solid #e7e5e4;
}

.recipe-section {
  margin: 2rem 0;
}

.section-title {
  font-family: 'EB Garamond', serif;
  font-size: 1.3rem;
  font-weight: 400;
  margin-bottom: 1rem;
  color: #1c1917;
}

.group-title {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
  margin-top: 1.5rem;
  color: #57534e;
}

.step-list {
  list-style: none;
  counter-reset: step-counter;
  padding-left: 0;
}

.step {
  position: relative;
  padding-left: 2.5rem;
  margin-bottom: 0.75rem;
  line-height: 1.6;
}

.step::before {
  counter-increment: step-counter;
  content: counter(step-counter) '.';
  position: absolute;
  left: 0;
  color: #78716c;
  font-weight: 500;
}

.step strong,
.ingredient strong {
  color: #1c1917;
  font-weight: 600;
}

.note {
  color: #78716c;
  font-style: italic;
  margin: 0.5rem 0;
  line-height: 1.5;
}

.shopping-list-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.ingredient-list {
  list-style: none;
  padding-left: 0;
}

.ingredient {
  padding: 0.25rem 0;
  border-bottom: 1px solid #f0eeeb;
}

.section-content p {
  margin-bottom: 1rem;
  line-height: 1.8;
}

.recipe-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e7e5e4;
}

/* Back link */
.back-link {
  display: inline-block;
  color: #78716c;
  font-size: 0.85rem;
  transition: color 0.2s;
}

.back-link:hover {
  color: #1c1917;
}

/* Lightbox */
.recipe-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(28, 25, 23, 0.95);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 2rem;
}

.recipe-lightbox.is-active {
  display: flex;
}

.recipe-lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 8px;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 40px;
  background: none;
  border: none;
  font-size: 2.5rem;
  color: #a8a29e;
  cursor: pointer;
}

.lightbox-close:hover {
  color: #fff;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.4);
  border: none;
  color: #e7e5e4;
  font-size: 2rem;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  cursor: pointer;
}

.lightbox-nav:hover {
  background: rgba(0, 0, 0, 0.6);
}

.lightbox-nav-prev {
  left: 30px;
}

.lightbox-nav-next {
  right: 30px;
}

/* Page title */
.page-title {
  font-family: 'EB Garamond', serif;
  font-size: 1.75rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
}

.page-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e7e5e4;
}

/* Recipe list page */
.recipe-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.recipe-card {
  border-bottom: 1px solid #e7e5e4;
}

.recipe-card a {
  display: block;
  padding: 1rem 0;
  text-decoration: none;
  transition: padding-left 0.2s;
}

.recipe-card a:hover {
  padding-left: 0.75rem;
}

.recipe-card-title {
  font-family: 'EB Garamond', serif;
  font-size: 1.25rem;
  font-weight: 400;
  color: #1c1917;
  margin-bottom: 0.25rem;
}

.recipe-card-summary {
  font-size: 0.9rem;
  color: #78716c;
  line-height: 1.5;
}

/* Responsive */
@media (max-width: 768px) {
  body {
    padding: 1.5rem;
  }

  header h1 {
    font-size: 1.75rem;
  }

  .main-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .recipe-media {
    flex-direction: column;
    gap: 1rem;
  }

  .photo-strip {
    max-width: 100%;
  }

  .shopping-list-container {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .lightbox-nav {
    font-size: 1.5rem;
    padding: 0.5rem 0.75rem;
  }
}
