@import url("https://fonts.googleapis.com/css2?family=Candal&family=Alice&family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap");

:root {
  --color-background: #e8dcc8;
  --color-card-background: #f5ebd6;
  --color-border: #8b3a3a;
  --color-border-light: rgba(139, 58, 58, 0.3);
  --color-text: #4a2020;
  --border-radius: 12px;
  --font-heading: "Candal", sans-serif;
  --font-body: "Alice", serif;
  --font-accent: "Playfair Display", serif;
}

/* Base Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  -webkit-font-smoothing: antialiased;
  text-wrap: pretty;
  font-family: var(--font-body);
  background-color: var(--color-background);
  color: var(--color-text);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  margin: 0;
}

/* Layout */
main {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 900px;
  width: 100%;
}

/* Recipe Card */
.recipe-card {
  background-color: var(--color-card-background);
  border: 4px solid var(--color-border);
  border-radius: var(--border-radius);
  padding: 2rem;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Header */
.recipe-header {
  text-align: center;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--color-border);
}

.recipe-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-border);
  letter-spacing: 0.1em;
}

/* Recipe Info Section */
.recipe-info,
.recipe-details,
.detail-item {
  display: flex;
  gap: 1rem;
}

.recipe-info {
  flex-direction: column;
}

.recipe-details {
  gap: 2rem;
  flex-wrap: wrap;
}

.detail-item {
  gap: 0.5rem;
}

.recipe-name {
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-text);
}

.detail-label {
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
}

.detail-value {
  font-size: 0.9rem;
}

/* Section Titles */
.section-title {
  text-align: center;
  font-size: 1.5rem;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

/* Ingredients Section */
.ingredients-columns {
  display: flex;
  gap: 2rem;
}

/* Lists - Shared Styles */
.ingredients-list,
.directions-list {
  margin: 0;
  display: flex;
  flex-direction: column;
}

.ingredients-list {
  flex: 1;
  padding: 0;
  list-style: none;
  gap: 0.75rem;
}

.directions-list {
  padding-left: 1.5rem;
  gap: 1rem;
}

/* List Items - Shared Styles */
.ingredient-item,
.direction-step {
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--color-border-light);
  font-size: 0.95rem;
}

.ingredient-item {
  line-height: 1.4;
}

.direction-step {
  padding-bottom: 1rem;
  line-height: 1.6;
}

.direction-step:last-child {
  border-bottom: none;
}

/* Footer Styles */
.recipe-footer,
.page-footer {
  text-align: center;
}

.recipe-footer {
  padding-top: 1rem;
  border-top: 2px solid var(--color-border);
}

.attribution {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--color-border);
  margin: 0;
}

/* Link Styles */
.attribution-link,
.footer-link {
  color: var(--color-border);
  text-decoration: none;
}

.attribution-link:hover,
.footer-link:hover {
  text-decoration: underline;
}

.page-footer {
  padding: 2rem 1rem;
  font-size: 0.9rem;
}

.footer-text {
  margin: 0;
}

.footer-link {
  font-style: italic;
}

/* Utility Classes */
.directions-card {
  min-height: 500px;
}

.directions {
  flex: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
  .ingredients-columns,
  .recipe-details {
    flex-direction: column;
  }

  .ingredients-columns {
    gap: 1rem;
  }

  .recipe-details {
    gap: 0.5rem;
  }

  .recipe-title {
    font-size: 2rem;
  }
}
