/*
  Component styles — friend-portfolio
  Case-study page: sections, media, meta blocks, project cards.
*/

.page {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-m);
  max-width: calc(var(--content-max) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-l);
  width: 100%;
}

.section--hero { padding: var(--hero-top) 0 var(--section-pad); }
.section--padded { padding-bottom: var(--section-pad); }

.title {
  width: 100%;
  font-size: var(--text-xl);
  line-height: var(--lh-tight);
}

.media {
  position: relative;
  width: 100%;
  height: var(--media-h);
  border-radius: var(--radius);
  overflow: hidden;
}

.media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.row {
  display: flex;
  align-items: center;
  gap: var(--gap-m);
  width: 100%;
}

.row > * { flex: 1; min-width: 0; }

.text,
.label {
  font-size: var(--text-m);
  line-height: var(--lh-tight);
}

.label { color: var(--color-muted); }

.block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--gap-m);
}

.block--half {
  width: 50%;
  align-self: flex-end;
}

.block--center {
  align-items: center;
  align-self: flex-start;
}

.info {
  display: flex;
  align-items: flex-start;
  gap: var(--gap-m);
  width: 100%;
}

.info > * { flex: 1; min-width: 0; }

.stack {
  display: flex;
  flex-direction: column;
}

/* ---------- More projects ---------- */

.more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-m);
  width: 100%;
  padding: var(--section-pad) 0;
}

.more__title {
  width: 100%;
  font-size: var(--text-heading);
  line-height: var(--lh-heading);
}

.cards {
  display: flex;
  align-items: flex-start;
  gap: var(--gap-card);
  width: 100%;
}

.card {
  display: flex;
  flex-direction: column;
  gap: var(--gap-m);
  flex: 1;
  min-width: 0;
}

.card .media { height: var(--media-h-card); }

.card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: var(--text-m);
  line-height: var(--lh-tight);
}

.card__meta span:last-child { color: var(--color-muted); }
