/* Imported from main and remapped to template 06 for this branch. */
@page {
  size: A4;
  margin: 0;
}

* {
  box-sizing: border-box;
}

:root {
  --brand-red: #ff0000;
  --border-gray: #d8d8d8;
  --text-black: #000000;
  --ink-navy: #13273d;
  --ink-navy-2: #1d3a59;
  --ink-navy-3: #294b6d;
  --text-soft: #415366;
  --paper-white: #fafafa;
  --paper-blue: #fafafa;
  --type-title: 11.6pt;
  --type-subtitle: 9.2pt;
  --type-label: 7.7pt;
  --type-body: 7.1pt;
  --hero-height: 84mm;
}

html,
body {
  margin: 0;
  padding: 0;
  background: #ffffff;
  color: var(--text-black);
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
  font-family: "Avenir Next", "Segoe UI", Arial, sans-serif;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  padding: 12mm 0;
  overflow: auto;
}

.page {
  width: 210mm;
  max-width: 210mm;
  min-height: 297mm;
  height: 297mm;
  padding: 8mm 18mm;
  margin: 0 auto;
  background: #ffffff;
  box-shadow: 0 3mm 10mm rgba(21, 36, 55, 0.08);
  page-break-after: always;
  overflow: hidden;
}

.portfolio-sheet {
  width: 174mm;
  max-width: 174mm;
  height: 281mm;
  display: grid;
  grid-template-rows: auto var(--hero-height) minmax(0, 1fr);
  gap: 2.8mm;
  align-content: start;
  overflow: hidden;
}

.project-brand {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 3.4mm;
  min-height: 13.2mm;
  padding: 1mm 2.1mm 1.05mm;
  border: 0.35mm solid var(--border-gray);
  background: var(--paper-white);
  border-radius: 3.2mm;
  overflow: hidden;
}

.project-brand::after {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1.1mm;
  background: linear-gradient(90deg, var(--brand-red) 0%, rgba(255, 0, 0, 0.8) 35%, rgba(255, 0, 0, 0.4) 70%, transparent 100%);
}

.project-brand__meta {
  min-width: 0;
  flex: 1 1 auto;
  display: grid;
  gap: 0.9mm;
  align-content: center;
}

.project-brand__logos {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5mm;
}

.project-brand__logo {
  display: block;
  width: 12mm;
  height: auto;
  opacity: 0.95;
}

.project-brand__banner {
  display: block;
  width: 28mm;
  max-width: 28mm;
  height: auto;
}

.project-brand__eyebrow {
  color: var(--brand-red);
  font-size: var(--type-label);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-brand__title {
  margin: 0;
  color: var(--ink-navy);
  font-size: var(--type-title);
  line-height: 1.08;
  font-weight: 700;
  text-wrap: balance;
}

.project-brand__subtitle {
  margin: 0;
  color: var(--text-soft);
  font-size: var(--type-body);
  line-height: 1.14;
  max-width: 106mm;
  text-align: justify;
  text-align-last: left;
  -webkit-hyphens: auto;
  hyphens: auto;
  text-wrap: pretty;
}

.project-brand__rule {
  display: block;
  width: 100%;
  height: 0.35mm;
  margin-top: 0.35mm;
  background: transparent;
}

.section-label {
  margin: 0 0 0.3mm;
  display: block;
  color: var(--brand-red);
  font-size: var(--type-label);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section-title {
  margin: 0;
  color: var(--ink-navy);
  font-size: var(--type-subtitle);
  line-height: 1.06;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.body-text {
  margin: 0;
  color: var(--text-soft);
  font-size: var(--type-body);
  line-height: 1.24;
  text-align: justify;
  text-align-last: left;
  -webkit-hyphens: auto;
  hyphens: auto;
  text-wrap: pretty;
}

.portfolio-hero,
.portfolio-list,
.project-list__item {
  border: 0.35mm solid var(--border-gray);
  border-radius: 3.2mm;
  background: var(--paper-white);
}

.portfolio-hero {
  position: relative;
  overflow: hidden;
  min-height: 0;
  border-radius: 3.6mm;
}

.portfolio-hero__media,
.portfolio-hero__image {
  width: 100%;
  height: 100%;
  margin: 0;
}

.portfolio-hero__image {
  display: block;
  object-fit: cover;
  object-position: center;
}

.portfolio-hero__caption {
  position: absolute;
  left: 2.4mm;
  right: 2.4mm;
  bottom: 2.2mm;
  display: grid;
  gap: 0.35mm;
  padding: 1.6mm 1.9mm 1.75mm;
  border-radius: 2.6mm;
  background: rgba(243, 246, 250, 0.94);
  border: 0.3mm solid rgba(216, 216, 216, 0.9);
}

.portfolio-hero__title {
  margin: 0;
  color: var(--ink-navy);
  font-size: var(--type-label);
  line-height: 1.04;
  font-weight: 700;
}

.portfolio-hero__text {
  margin: 0;
  color: var(--text-soft);
  font-size: var(--type-body);
  line-height: 1.12;
  text-align: justify;
  text-align-last: left;
  -webkit-hyphens: auto;
  hyphens: auto;
}

.portfolio-list {
  height: 100%;
  padding: 1.6mm;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 1mm;
  align-content: stretch;
  min-height: 0;
  overflow: hidden;
}

.portfolio-list .section-label,
.portfolio-list .section-title {
  display: none;
}

.project-cards {
  display: grid;
  height: 100%;
  grid-template-rows: repeat(15, minmax(0, 1fr));
  gap: 0.75mm;
  align-content: stretch;
  min-height: 0;
  overflow: hidden;
}

.project-cards__header {
  display: none;
}

.project-card {
  position: relative;
  display: grid;
  grid-template-columns: 43mm 26mm minmax(0, 1fr);
  grid-template-rows: auto auto;
  gap: 0 1.6mm;
  align-content: center;
  align-items: start;
  padding: 0.55mm 1.2mm 0.55mm 7mm;
  border: 0.35mm solid #cfd8e2;
  border-radius: 2.8mm;
  background: #fafafa;
  align-self: stretch;
  box-shadow: 0 0.5mm 1.5mm rgba(19, 39, 61, 0.02);
  min-height: 0;
  height: 100%;
  max-width: 100%;
  overflow: hidden;
}

.project-card__project {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  display: block;
}

.project-card__index {
  position: absolute;
  left: -0.35mm;
  top: -0.35mm;
  bottom: -0.35mm;
  width: 6.3mm;
  height: auto;
  background: var(--paper-white);
  color: var(--brand-red);
  border: 0.35mm solid var(--brand-red);
  border-radius: 2.8mm 0 0 2.8mm;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 6.1pt;
  font-weight: 700;
  letter-spacing: 0;
}

.project-card__title {
  margin: 0;
  color: var(--ink-navy);
  font-size: 6.15pt;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.project-card__field {
  min-width: 0;
  display: grid;
  gap: 0.08mm;
  align-content: start;
}

.project-card__field:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
  display: block;
}

.project-card__field:nth-child(3) {
  grid-column: 2;
  grid-row: 2;
  display: block;
  align-self: stretch;
  padding-left: 1.6mm;
  border-left: 0.25mm solid var(--border-gray);
}

.project-card__field:nth-child(4) {
  grid-column: 2;
  grid-row: 1;
  align-self: stretch;
  padding-left: 1.6mm;
  border-left: 0.25mm solid var(--border-gray);
}

.project-card__field--work {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: stretch;
  padding-left: 1.6mm;
  border-left: 0.25mm solid var(--border-gray);
}

.project-card__value {
  display: block;
  margin: 0;
  color: var(--text-soft);
  font-size: 5.75pt;
  line-height: 1;
  white-space: normal;
}

.project-card__value--subtle {
  line-height: 1.02;
}

.project-card__field:nth-child(4) .project-card__value {
  font-weight: 700;
  color: var(--ink-navy);
  font-size: 4.85pt;
  line-height: 0.98;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
}

.project-card__field:nth-child(2) .project-card__value,
.project-card__field:nth-child(3) .project-card__value {
  font-size: 4.85pt;
  color: var(--ink-slate);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  display: inline;
  white-space: nowrap;
}

.project-card__field:nth-child(2) .project-card__value + .project-card__value::before {
  content: ", ";
}

.project-card__field:nth-child(2) br,
.project-card__field:nth-child(3) br {
  display: none;
}

.project-card__field--work .project-card__value {
  font-size: 5.15pt;
  line-height: 1;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

@media print {
  html,
  body {
    width: 210mm;
    height: 297mm;
    background: var(--paper-white);
  }

  body {
    padding: 0;
    overflow: hidden;
  }

  .page {
    margin: 0;
    box-shadow: none;
  }
}
