/* A letter from Sydney. The frame, backdrop and breadcrumb come from site.css (.institution);
   this file keeps the cover picture, the letter's paper and the index of papers. */
:root {
  --machine-ink: #172039;
  --machine-paper: #fdfdfc;
  --machine-sapphire: #17347f;
  --machine-cobalt: #3a68cb;
  --machine-coral: #d96872;
  --machine-gold: #ffd27a;
  --machine-line: #d3d9e4;
}

.machine-institution { background: var(--machine-paper); color: var(--machine-ink); }

.machine-hero {
  position: relative;
  min-height: clamp(380px, 52vw, 560px);
  display: grid;
  align-items: end;
  overflow: hidden;
  color: white;
  background: var(--machine-sapphire);
  border-bottom: 1px solid #122657;
  isolation: isolate;
}

.machine-hero > img {
  position: absolute;
  inset: 0;
  z-index: -3;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.machine-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(14, 27, 58, .88) 0%, rgba(23, 52, 127, .63) 38%, rgba(23, 52, 127, .08) 72%),
    linear-gradient(0deg, rgba(16, 27, 54, .68), transparent 60%);
}

/* Static, so the breadcrumb anchors to the cover's upper-left corner. */
.machine-hero-copy {
  width: min(760px, calc(100% - 64px));
  padding: clamp(88px, 12vw, 120px) clamp(28px, 6vw, 68px) clamp(34px, 6vw, 64px);
  text-shadow: 0 2px 12px rgba(11, 20, 43, .62);
}

.machine-hero .hierarchy-nav.hierarchy-nav {
  position: absolute;
  z-index: 8;
  top: 22px;
  left: clamp(18px, 3vw, 28px);
  max-width: calc(100% - 56px);
  margin: 0;
  text-shadow: none;
}

.machine-hero h1 {
  max-width: 680px;
  margin: 0;
  font: 600 clamp(2.8rem, 7vw, 6.5rem)/.96 var(--house-serif);
  letter-spacing: -.015em;
}

.machine-deck {
  max-width: 620px;
  margin: 22px 0 0;
  color: #fff8ea;
  font: clamp(1.05rem, 2vw, 1.28rem)/1.5 var(--house-serif);
}

.machine-letter {
  background:
    linear-gradient(90deg, rgba(58, 104, 203, .055), transparent 96px),
    var(--machine-paper);
}

.letter-page {
  max-width: 44rem;
  margin: 0 auto;
  padding: clamp(52px, 9vw, 116px) clamp(28px, 7vw, 76px) clamp(64px, 10vw, 132px);
  font-family: var(--house-serif);
  font-size: clamp(1.06rem, 1.65vw, 1.19rem);
  line-height: 1.75;
  font-kerning: normal;
}

.letter-page p {
  margin: 0 0 1.55em;
  text-wrap: pretty;
}

.letter-address {
  color: var(--machine-sapphire);
  font-size: 1.22em;
  font-style: italic;
}

.letter-signature {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 7px;
  margin-top: 3.25em !important;
  padding-top: 1.35em;
  border-top: 3px solid var(--machine-coral);
}

.letter-signature span {
  color: var(--machine-sapphire);
  font-size: 1.62rem;
  line-height: 1;
}

.letter-signature small {
  color: #536079;
  font-family: var(--house-sans);
  font-size: .75rem;
  font-weight: 400;
  line-height: 1.4;
}

/* The ten papers: a quiet index on the same reading surface, not a second cover. */
.sydney-library {
  display: block;
  padding: clamp(32px, 5vw, 56px) clamp(22px, 5vw, 64px) clamp(36px, 5vw, 60px);
  background: linear-gradient(180deg, #eef1f7, var(--machine-paper));
  border-top: 1px solid var(--machine-line);
}

.sydney-library-heading { max-width: 62ch; margin: 0 0 18px; }

.sydney-library-heading h2 {
  margin: 0 0 6px;
  font: 600 clamp(27px, 3vw, 34px)/1.15 var(--house-serif);
  letter-spacing: -.02em;
}

.sydney-library-heading p {
  margin: 0;
  color: #55607a;
  font: 17px/1.5 var(--house-serif);
}

.sydney-paper-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
  gap: 0 36px;
}

.sydney-paper-links a {
  display: grid;
  gap: 2px;
  padding: 9px 0;
  color: var(--machine-ink);
  border-bottom: 1px dotted #b8c1d3;
  text-decoration: none;
}

.sydney-paper-links a:hover { background: transparent; }

.sydney-paper-links strong {
  color: #1f4f8f;
  font: 600 18px/1.2 var(--house-serif);
}

.sydney-paper-links a:hover strong { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .18em; }

.sydney-paper-links span {
  color: #55607a;
  font: 13.5px/1.4 var(--house-sans);
}

.sydney-paper-links a:focus-visible {
  position: relative;
  z-index: 2;
}

@media (max-width: 560px) {
  .machine-hero { min-height: 480px; }
  .machine-hero > img { object-position: 61% center; }
  .machine-hero::before { background: linear-gradient(0deg, rgba(14, 27, 58, .92), rgba(23, 52, 127, .22) 74%); }
  .machine-hero .hierarchy-nav.hierarchy-nav { top: 16px; left: 16px; max-width: calc(100% - 32px); }
  .machine-hero-copy { width: auto; padding: 84px 24px 40px; }
  .machine-hero h1 { font-size: clamp(2.6rem, 13vw, 4.4rem); }
  .letter-page { padding: 48px 24px 56px; font-size: 1.03rem; line-height: 1.72; }
  .sydney-library { padding: 30px 24px 36px; }
  .sydney-paper-links { grid-template-columns: 1fr; }
}

@media (prefers-contrast: more) {
  .machine-hero::before { background: rgba(11, 20, 43, .78); }
  .machine-institution { border-color: #172039; }
}
