/* recipe-styles.css — shared stylesheet for index and recipe pages */
/* normalize and bootstrap CSS are now loaded in HTML head via CDN; no need to import here */
@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@400;700&family=Rubik+Mono+One&display=swap');
@import url("https://cdn.jsdelivr.net/npm/bootstrap-icons@1.13.1/font/bootstrap-icons.min.css");

:root {
  --bg: #f5f5f5;
  --card: #ffffff;
  --accent: #2563eb;
  --text: #333333;
  --muted: #999999;
}

* {
  box-sizing: border-box
}

html,
body {
  height: 100%
}

body {
  margin: 0;
  padding: 1rem;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}

/* Page wrapper */
.container {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem;
  text-align: center;
  /* center text for mobile-first layout */
}

header {
  text-align: center;
  margin-bottom: 1.25rem;
}

.navbar-brand {
  color: var(--accent) !important;
  font-weight: 600
}

h1 {
  font-size: 1.75rem;
  margin: 0 0 0.5rem;
  color: var(--accent)
}

h2 {
  font-size: 1.1rem;
  margin-top: 1rem;
  color: var(--accent)
}

/* Recipe list on the index page */
ul.recipe-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: .5rem
}

.recipe-list li {
  background: var(--card);
  padding: .75rem;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(36, 36, 36, 0.04);
  text-align: center
}

.recipe-list a {
  color: var(--accent);
  text-decoration: none;
  display: block
}

.recipe-list a:hover {
  text-decoration: underline
}

/* Bulleted list variant for index */
ul.recipe-list-bulleted {
  list-style: disc;
  padding-left: 1.25rem;
  margin: 0;
  color: var(--text)
}

ul.recipe-list-bulleted li {
  margin-bottom: .5rem;
  background: transparent;
  padding: 0;
  border-radius: 0;
  box-shadow: none
}

ul.recipe-list-bulleted a {
  color: var(--accent);
  text-decoration: none
}

ul.recipe-list-bulleted a:hover {
  text-decoration: underline
}

/* Recipe page blocks */
.ingredients,
.instructions {
  background: var(--card);
  padding: 1rem;
  border-radius: 8px;
  box-shadow: 0 1px 4px rgba(36, 36, 36, 0.06);
  margin-top: .75rem;
  text-align: left;
  /* keep lists readable on mobile */
}

.ingredients ul,
.instructions ol {
  margin: 0;
  padding-left: 1.25rem
}

/* Two-column layout on wider screens */
@media (min-width:768px) {
  .container {
    padding: 0 1.5rem;
    text-align: left
  }

  .recipe-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: start
  }

  .recipe-list li {
    text-align: left
  }
}

/* Footer */
footer {
  margin-top: 2rem;
  font-size: .9rem;
  color: var(--muted);
  text-align: center
}

/* Utility */
.back-link {
  display: inline-block;
  margin: 0.75rem auto;
  color: var(--accent);
  text-decoration: none
}

.back-link:hover {
  text-decoration: underline
}

/* Small utility: center content blocks on mobile but keep inner lists left-aligned */
.card-center {
  display: block;
  margin: 0.75rem auto;
  max-width: 680px
}