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

:root {
  --color-bg: #38291a;
  --color-text: #cecac3;
  --color-muted: #9e9689;
  --color-border: #3a362d;
  --color-card-bg: #2e2a21;
  --color-card-shadow: rgba(0, 0, 0, 0.3);
  --font: "Inter", system-ui, -apple-system, sans-serif;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 5rem 1.5rem 4rem;
}

header {
  text-align: center;
  margin-bottom: 4rem;
}

header h1 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

header p {
  font-size: 1.05rem;
  color: var(--color-muted);
  max-width: 480px;
  margin: 0 auto;
}

.container > h2 {
  text-align: center;
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.projects {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.75rem;
}

.card {
  width: 290px;
  display: block;
  text-decoration: none;
  color: inherit;
  background: var(--color-card-bg);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px var(--color-card-shadow);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px var(--color-card-shadow);
}

.card-image {
  aspect-ratio: 1 / 1;
  width: 100%;
  display: block;
  object-fit: cover;
  background: var(--color-border);
}

.card-title {
  padding: 0.85rem 1.25rem 0.3rem;
  font-size: 1.05rem;
  font-weight: 600;
  text-align: center;
}

.card-repo {
  display: block;
  text-align: center;
  padding: 0 1.25rem 0.85rem;
  font-size: 0.85rem;
  color: var(--color-muted);
  text-decoration: none;
}

.card-repo:hover {
  color: var(--color-text);
}

.card-subtitle {
  display: block;
  text-align: center;
  padding: 0 1.25rem 0.85rem;
  font-size: 0.85rem;
  color: var(--color-muted);
}

.card-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #2c3e30 0%, #1a2a1e 100%);
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

@media (max-width: 540px) {
  .container {
    padding: 3rem 1.25rem 3rem;
  }

  header {
    margin-bottom: 2.5rem;
  }

  header h1 {
    font-size: 1.6rem;
  }

  .projects {
    gap: 1.25rem;
  }

  .card {
    width: 220px;
    border-radius: 10px;
  }

  .card-title {
    padding: 0.6rem 1rem 0.2rem;
    font-size: 0.9rem;
  }

  .card-repo,
  .card-subtitle {
    padding: 0 1rem 0.6rem;
    font-size: 0.75rem;
  }
}
