/* This theme is from one of my previous website. All the color variables are filled by AI. */
:root {
  --background: #ebebeb;
  --foreground: #111827;
  --card: #fafafa;
  --muted: #e3e8f3;
  --muted-foreground: #3c424e;
  --border: #babfc5;
  --primary: #2f62d3;
  --primary-foreground: #ffffff;
  --radius: 0.5rem;
}

* {
  box-sizing: border-box;
}

body {
  background-color: var(--background);
  color: var(--foreground);
  font-family: Roboto, sans-serif;
  line-height: 1.5;
  margin: 0;
  padding: 0;
}

header {
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem;
  text-align: center;
}

.avatar {
  border-radius: 100%;
}

header h1 {
  font-size: 2rem;
  margin: 1rem 0;
}

header nav {
  width: 100%;
}

header nav ul {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

header nav ul li {
  display: flex;
}

header nav ul li a {
  border-radius: var(--radius);
  color: var(--primary);
  flex: 1;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  text-align: center;
  text-decoration: none;
}

header nav ul li a:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

main {
  margin: 0 auto;
  max-width: 48rem;
  padding: 0 1rem 3rem;
}

section {
  background-color: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 2rem;
  padding: 1.5rem;
}

section h2 {
  border-bottom: 2px solid var(--primary);
  font-size: 1.5rem;
  padding-bottom: 0.5rem;
}

/* AI Prompt #1: Use CSS Grid on #showcase to lay out the three <article> project cards as a responsive card grid. Work mobile-first: one column by default, two columns from 40rem, three columns from 72rem. */

/* AI output from #1 */
#showcase {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

/* AI output from #1 */
#showcase > h2 {
  grid-column: 1 / -1;
}

a {
  color: var(--primary);
}

img {
  max-width: 100%;
}

figure {
  margin: 1rem 0;
  text-align: center;
}

figcaption {
  color: var(--muted-foreground);
  font-size: 0.875rem;
}

article {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
}

article h3 {
  margin-bottom: 0.5rem;
}

article ul {
  margin: 0;
  padding-left: 1.25rem;
}

address {
  font-style: normal;
}

footer {
  background-color: var(--muted);
  color: var(--muted-foreground);
  font-size: 0.875rem;
  padding: 1rem 1rem 2rem;
  text-align: center;
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* AI output from #1 */
@media (min-width: 40rem) {
  header nav ul {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    width: auto;
  }

  #showcase {
    gap: 1.5rem;
    grid-template-columns: repeat(2, 1fr);
  }

  section {
    padding: 2rem;
  }
}

/* AI output from #1 */
@media (min-width: 56rem) {
  header {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }

  header nav {
    width: auto;
  }

  main {
    max-width: 56rem;
  }
}

/* AI output from #1 */
@media (min-width: 72rem) {
  #showcase {
    grid-template-columns: repeat(3, 1fr);
  }

  main {
    max-width: 64rem;
  }
}
