:root {
  --display-font: Georgia, "Times New Roman", serif;
  --sans-font: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --paper: #efe9e2;
  --ink: #251f42;
  --muted: #615c6b;
  --line: rgba(37, 31, 66, 0.22);
  --teal: #20b2aa;
  --yellow: #ffffe0;
  --coral: #f08080;
  --blue: #add8e6;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}
body {
  margin: 0;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    linear-gradient(rgba(37, 31, 66, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 31, 66, 0.035) 1px, transparent 1px);
  background-size: 24px 24px;
  font-family: var(--sans-font);
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
}
a:focus-visible {
  outline: 3px solid #086d68;
  outline-offset: 5px;
}
p,
h1,
h2,
h3 {
  margin: 0;
}
.page-shell {
  max-width: 1440px;
  margin: auto;
  padding: 0 64px;
}
.landing-header {
  min-height: 116px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--ink);
  gap: 24px;
}
.wordmark {
  font: 600 36px/1 var(--sans-font);
  letter-spacing: 3px;
}
.wordmark span {
  display: block;
  font:
    10px/1.5 "Courier New",
    monospace;
  letter-spacing: 1.1px;
  margin-top: 9px;
}
.landing-header nav {
  display: flex;
  align-items: center;
  gap: 36px;
  font-size: 13px;
}
.landing-header nav a:not(.contact-link):hover {
  text-decoration: underline;
  text-underline-offset: 5px;
}
.contact-link {
  border: 1px solid var(--ink);
  padding: 12px 18px;
  display: flex;
  gap: 24px;
  align-items: center;
}
.contact-link:hover,
.button:hover {
  background: #40375f;
  color: var(--paper);
}
.hero {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  padding: 64px 0 48px;
  align-items: start;
}
.hero-copy {
  min-width: 0;
  padding-top: 12px;
}
.eyebrow,
.field-number,
.notebook-heading,
.notebook-caption,
.hero-footnote,
.section-label,
.footer-note {
  font-family: "Courier New", monospace;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  line-height: 1.6;
}
.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #087870;
  margin-right: 8px;
}
h1 {
  font: normal clamp(48px, 4.7vw, 68px) / 1.13 var(--display-font);
  letter-spacing: -2px;
  margin: 29px 0 25px;
}
.marked {
  position: relative;
  white-space: nowrap;
  isolation: isolate;
}
.marked:after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 5px;
  height: 12px;
  background: #20b2aa55;
  z-index: -1;
  transform: rotate(-1.5deg);
}
.hero-intro {
  max-width: 345px;
  font-size: 16px;
  line-height: 1.8;
  color: var(--muted);
}
.button {
  display: inline-flex;
  align-items: center;
  gap: 30px;
  background: var(--ink);
  color: var(--paper);
  padding: 16px 21px;
  font-size: 13px;
  margin-top: 28px;
  transition: background 0.18s;
}
.button span {
  font-size: 20px;
  line-height: 1;
}
.hand-note {
  font: italic 19px/1.5 var(--display-font);
  transform: rotate(-4deg);
  margin: 21px 0 0 34px;
  color: #526a65;
}
.hero-footnote {
  font-size: 11px;
  line-height: 1.8;
  margin-top: 58px;
  padding-left: 35px;
  position: relative;
  color: var(--muted);
}
.hero-footnote span {
  position: absolute;
  left: 0;
}
.element-notebook {
  min-width: 0;
  scroll-margin-top: 24px;
}
.notebook-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 12px;
  gap: 16px;
}
.notebook-heading h2 {
  font: normal clamp(22px, 2vw, 28px) / 1.3 var(--display-font);
}
.notebook-heading > span {
  font-size: 14px;
  flex-shrink: 0;
  color: var(--muted);
}
.index-instruction {
  font-size: 14px;
  color: var(--muted);
  margin: 12px 0 24px;
  line-height: 1.6;
}
.element-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}
.element-tile {
  grid-column: var(--column);
  grid-row: var(--row);
  min-width: 0;
  aspect-ratio: 1 / 1.12;
  border: 1px solid rgba(37, 31, 66, 0.6);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 13px 2px 6px;
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.family-refractory {
  background: #d5d0d9;
}
.family-transition {
  background: #71c9bd;
}
.family-precious {
  background: var(--yellow);
}
.family-rare-earth {
  background: var(--blue);
}
.family-metalloid {
  background: #efa4a0;
}
.atomic-number {
  position: absolute;
  top: 4px;
  left: 6px;
  font:
    9px/1 "Courier New",
    monospace;
}
.element-symbol {
  font: 600 clamp(23px, 2.4vw, 34px) / 1.2 var(--sans-font);
}
.element-name {
  font-size: 7px;
  margin-top: 2px;
  white-space: nowrap;
}
.tile-arrow {
  position: absolute;
  top: 2px;
  right: 4px;
  font-size: 10px;
  opacity: 0;
}
.element-tile:hover {
  transform: translateY(-3px);
  box-shadow: 2px 3px 0 var(--ink);
}
.element-tile.is-selected {
  box-shadow: inset 0 0 0 2px var(--ink);
}
.element-tile.is-selected .tile-arrow,
.element-tile:hover .tile-arrow {
  opacity: 1;
}
.element-legend {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 18px 0;
  gap: 9px 15px;
  font-size: 9px;
  color: var(--muted);
}
.element-legend li {
  display: flex;
  align-items: center;
  gap: 5px;
}
.element-legend i {
  width: 8px;
  height: 8px;
  border: 1px solid var(--line);
}
.element-details {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.22);
  padding: 19px 15px;
  min-height: 163px;
}
.element-detail {
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 18px;
  align-items: start;
}
.element-detail[hidden] {
  display: none;
}
.detail-symbol {
  width: 62px;
  height: 72px;
  border: 1px solid var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font: 600 34px var(--sans-font);
  position: relative;
  padding-top: 6px;
}
.detail-symbol small {
  position: absolute;
  top: 5px;
  left: 6px;
  font:
    9px "Courier New",
    monospace;
}
.detail-copy .eyebrow {
  font-size: 9px;
  letter-spacing: 0.5px;
}
.detail-copy h3 {
  font: normal 26px/1.4 var(--display-font);
  margin: 2px 0 5px;
}
.detail-copy > p:not(.eyebrow) {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 380px;
}
.text-link {
  display: inline-block;
  font-size: 11px;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 3px;
  margin-top: 10px;
}
.text-link span {
  margin-left: 12px;
}
.text-link:hover {
  color: #086d68;
}
.notebook-caption {
  font-size: 9px;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 10px;
}
.fields {
  border-top: 1px solid var(--ink);
  padding: 22px 0 42px;
}
.section-label {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  font-size: 10px;
  color: var(--muted);
}
.section-label h2 {
  font: inherit;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--ink);
}
.field-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}
.field-card {
  padding: 0 28px;
  border-left: 1px solid var(--line);
}
.field-card:first-child {
  padding-left: 0;
  border: 0;
}
.field-card:last-child {
  padding-right: 0;
}
.field-number {
  font-size: 9px;
  letter-spacing: 1px;
  color: var(--muted);
}
.field-card h3 {
  font: normal 26px/1.4 var(--display-font);
  margin: 11px 0 8px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.field-card h3 span {
  font-family: sans-serif;
  font-size: 18px;
  transition: transform 0.15s;
}
.field-card:hover h3 span {
  transform: translate(3px, -3px);
}
.field-card p {
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
  max-width: 290px;
}
.landing-footer {
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 25px 0 30px;
  font-size: 10px;
  line-height: 1.9;
  color: var(--muted);
}
.landing-footer div > * {
  display: block;
}
.landing-footer strong {
  font-weight: 500;
  color: var(--ink);
}
.landing-footer a:hover {
  text-decoration: underline;
}
.footer-note {
  font-size: 10px;
}
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 10;
  background: var(--ink);
  color: var(--paper);
  padding: 12px;
  transform: translateY(-150%);
}
.skip-link:focus {
  transform: translateY(0);
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.no-script {
  font-size: 12px;
  margin-top: 16px;
}
.no-script a {
  text-decoration: underline;
}
@media (min-width: 1440px) {
  .hero {
    gap: 90px;
    padding-top: 80px;
    padding-bottom: 64px;
  }
  h1 {
    font-size: 72px;
  }
  .element-name {
    font-size: 8px;
  }
}
@media (max-width: 1100px) {
  .page-shell {
    padding: 0 36px;
  }
  .hero {
    gap: 35px;
    grid-template-columns: 1fr 1.15fr;
  }
  h1 {
    font-size: 50px;
  }
  .element-name {
    font-size: 6px;
  }
  .hero-footnote {
    margin-top: 40px;
  }
  .footer-note {
    display: none;
  }
}
@media (max-width: 800px) {
  .page-shell {
    padding: 0 24px;
  }
  .landing-header {
    min-height: 100px;
  }
  .landing-header nav {
    gap: 20px;
  }
  .hero {
    grid-template-columns: 1fr;
    gap: 48px;
    padding-top: 42px;
  }
  .hero-copy {
    position: relative;
  }
  .hero-intro {
    max-width: 420px;
  }
  h1 {
    font-size: 64px;
  }
  .hero-footnote {
    position: absolute;
    right: 0;
    bottom: 0;
    margin: 0;
  }
  .element-notebook {
    max-width: 620px;
    width: 100%;
    margin: auto;
  }
  .element-symbol {
    font-size: 36px;
  }
  .element-name {
    font-size: 9px;
  }
  .atomic-number {
    font-size: 11px;
    top: 6px;
  }
  .element-legend {
    font-size: 10px;
  }
  .detail-copy > p:not(.eyebrow) {
    font-size: 12px;
  }
  .detail-copy .eyebrow {
    font-size: 10px;
  }
  .element-details {
    min-height: 164px;
  }
  .field-card {
    padding: 0 18px;
  }
  .field-card h3 {
    font-size: 20px;
  }
  .section-label > span {
    display: none;
  }
}
@media (max-width: 520px) {
  .page-shell {
    padding: 0 20px;
  }
  .landing-header {
    min-height: 91px;
    gap: 12px;
  }
  .wordmark {
    font-size: 32px;
  }
  .wordmark span {
    font-size: 7px;
    letter-spacing: 0.5px;
  }
  .landing-header nav {
    gap: 16px;
    font-size: 11px;
  }
  .landing-header nav > a:first-child {
    display: none;
  }
  .contact-link {
    padding: 9px 11px;
    gap: 9px;
  }
  .hero {
    padding-top: 30px;
    gap: 38px;
  }
  h1 {
    font-size: clamp(38px, 12vw, 48px);
    letter-spacing: -1.5px;
    margin-top: 24px;
  }
  .hero-intro {
    font-size: 14px;
    max-width: 320px;
  }
  .hero-copy > .eyebrow {
    font-size: 9px;
  }
  .hero-footnote {
    display: none;
  }
  .hand-note {
    font-size: 15px;
    margin-top: 16px;
  }
  .element-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px;
  }
  .element-tile {
    grid-column: auto;
    grid-row: auto;
    aspect-ratio: 1.05;
  }
  .element-symbol {
    font-size: 32px;
  }
  .element-name {
    font-size: 8px;
  }
  .atomic-number {
    font-size: 10px;
  }
  .element-legend {
    gap: 9px 12px;
  }
  .element-details {
    padding: 16px 12px;
    min-height: 190px;
  }
  .element-detail {
    gap: 12px;
    grid-template-columns: 52px 1fr;
  }
  .detail-symbol {
    width: 52px;
    height: 64px;
    font-size: 30px;
  }
  .detail-copy .eyebrow {
    font-size: 8px;
  }
  .detail-copy h3 {
    font-size: 22px;
  }
  .detail-copy > p:not(.eyebrow) {
    font-size: 11px;
  }
  .notebook-caption {
    font-size: 8px;
  }
  .field-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .field-card,
  .field-card:first-child,
  .field-card:last-child {
    padding: 0 0 22px;
    border: 0;
    border-bottom: 1px solid var(--line);
  }
  .field-card:last-child {
    padding-bottom: 0;
    border: 0;
  }
  .field-card h3 {
    font-size: 24px;
  }
  .field-card p {
    max-width: 100%;
  }
  .fields {
    padding-bottom: 30px;
  }
  .landing-footer {
    flex-wrap: wrap;
    align-items: start;
    gap: 16px 20px;
  }
  .landing-footer > div:first-child {
    width: 100%;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *:before,
  *:after {
    transition: none !important;
  }
}

/* Shared reading layout for company, materials and terms pages. */
.document-content {
  max-width: 850px;
  margin: 0 auto;
  padding: 45px 0 70px;
  min-height: 65vh;
  line-height: 1.85;
  overflow-wrap: anywhere;
}
.document-content > h1,
.document-content .post-title {
  font-size: clamp(36px, 5vw, 64px);
  margin: 0 0 32px;
}
.document-content > h2,
.document-content > h3,
.document-content > h4 {
  font-family: var(--display-font);
  font-weight: normal;
  line-height: 1.4;
  margin: 32px 0 16px;
}
.document-content > h2 {
  font-size: 30px;
}
.document-content > h3 {
  font-size: 24px;
}
.document-content > p,
.document-content > ul,
.document-content > ol {
  margin: 0 0 22px;
}
.document-content > p a {
  border-bottom: 1px solid var(--line);
}
.document-content > p a:hover {
  border-color: var(--ink);
}
.document-content .document-intro {
  font-size: 21px;
}
.document-content .element-notebook {
  max-width: 680px;
  margin: 40px auto;
  overflow-wrap: normal;
}
.document-content .element-notebook h2,
.document-content .element-notebook h3 {
  margin: 0;
}
.document-content .element-name {
  font-size: 9px;
}
.document-content .element-legend {
  line-height: 1.5;
}
.landing-header nav [aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: 5px;
}
@media (max-width: 520px) {
  .document-content {
    font-size: 14px;
    padding-top: 32px;
  }
  .document-content .element-name {
    font-size: 8px;
  }
  .document-content .document-intro {
    font-size: 18px;
  }
}
