/* ROCHENOIR MINERALS — site styles
   Palette derives from fluorite: anthracite host rock, violet crystal. */

:root {
  --ink:        #1B1D23;
  --ink-2:      #2A2D34;
  --ink-soft:   #4C515B;
  --paper:      #FBFAF8;
  --paper-2:    #F1EFEB;
  --violet:     #6B3FA0;
  --violet-lt:  #9B77C9;
  --rule:       #DDDAD4;
  --rule-dark:  #3A3E47;

  --wrap: 74rem;
  --text: 40rem;

  --f-serif: "Newsreader", Georgia, "Times New Roman", serif;
  --f-sans: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI",
            Roboto, Helvetica, Arial, sans-serif;
}

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

html { font-size: 106.25%; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink-2);
  font-family: var(--f-sans);
  font-size: 1rem;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.measure { max-width: var(--text); }

a { color: var(--violet); text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
a:hover { color: var(--ink); }
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 3px;
}

h1, h2, h3 {
  font-family: var(--f-serif);
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.005em;
  margin: 0;
}

p { margin: 0 0 1.15rem; }
p:last-child { margin-bottom: 0; }

/* ---------- masthead ---------- */

.masthead {
  background: var(--ink);
  border-bottom: 1px solid var(--rule-dark);
}

.masthead .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 1rem 2rem;
  padding-top: 1.15rem;
  padding-bottom: 1.15rem;
}

.brand {
  font-family: var(--f-serif);
  font-size: 1.24rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}
.brand:hover { color: var(--violet-lt); }
.brand span {
  display: block;
  font-family: var(--f-sans);
  font-size: 0.53rem;
  letter-spacing: 0.34em;
  color: #8B909B;
  margin-top: 0.24rem;
  font-weight: 400;
}

.nav {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.nav a {
  color: #C6CAD2;
  text-decoration: none;
  font-size: 0.82rem;
  padding-bottom: 0.2rem;
  border-bottom: 2px solid transparent;
}
.nav a:hover { color: #fff; }
.nav a[aria-current="page"] {
  color: #fff;
  border-bottom-color: var(--violet-lt);
}

/* ---------- hero ---------- */

.hero {
  background: var(--ink);
  color: #D5D8DE;
  padding: 5.5rem 0 5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3rem;
  align-items: start;
}

.hero h1 {
  color: #fff;
  font-size: clamp(2.1rem, 5.2vw, 3.05rem);
  line-height: 1.12;
  max-width: 19ch;
  margin-bottom: 1.5rem;
}

.hero p {
  font-size: 1.08rem;
  max-width: 44ch;
  color: #B9BEC8;
}

.hero .rule {
  width: 3.5rem;
  height: 3px;
  background: var(--violet-lt);
  margin: 0 0 2rem;
}

/* fluorite lattice: cubic habit, one crystal coloured */
.lattice {
  display: grid;
  grid-template-columns: repeat(4, 1.05rem);
  gap: 0.42rem;
  padding-top: 0.75rem;
}
.lattice i {
  display: block;
  width: 1.05rem;
  height: 1.05rem;
  background: rgba(255, 255, 255, 0.07);
}
.lattice i.on { background: var(--violet); }
.lattice i.dim { background: rgba(155, 119, 201, 0.32); }

/* ---------- page header (interior pages) ---------- */

.pagehead {
  background: var(--ink);
  color: #B9BEC8;
  padding: 3.6rem 0 3.2rem;
}
.pagehead h1 {
  color: #fff;
  font-size: clamp(1.85rem, 4.3vw, 2.5rem);
  line-height: 1.16;
  margin-bottom: 1rem;
  max-width: 22ch;
}
.pagehead p { max-width: 52ch; font-size: 1.03rem; }

/* ---------- sections ---------- */

.band { padding: 4.2rem 0; }
.band + .band { border-top: 1px solid var(--rule); }
.band-tint { background: var(--paper-2); }

.band h2 {
  font-size: clamp(1.45rem, 3.2vw, 1.85rem);
  line-height: 1.25;
  margin-bottom: 1.4rem;
  max-width: 26ch;
}
.band h3 {
  font-size: 1.16rem;
  line-height: 1.35;
  margin-bottom: 0.5rem;
}

/* ---------- figures / statistics ---------- */

.figures {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2.4rem;
  margin-top: 2.6rem;
}
.figure { border-top: 3px solid var(--violet); padding-top: 1rem; }
.figure b {
  display: block;
  font-family: var(--f-serif);
  font-size: 2.35rem;
  line-height: 1;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.7rem;
}
.figure span { display: block; font-size: 0.92rem; color: var(--ink-soft); }

.source {
  margin-top: 2.2rem;
  font-size: 0.78rem;
  color: var(--ink-soft);
  max-width: 62ch;
}

/* ---------- definition rows ---------- */

.rows { margin-top: 2rem; border-top: 1px solid var(--rule); }
.row {
  display: grid;
  grid-template-columns: 15rem minmax(0, 1fr);
  gap: 1rem 2.5rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
}
.row h3 { margin: 0; }
.row p { font-size: 0.97rem; color: var(--ink-soft); }

/* ---------- spec table ---------- */

.spec {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
  font-size: 0.94rem;
}
.spec caption {
  text-align: left;
  font-size: 0.84rem;
  color: var(--ink-soft);
  padding-bottom: 0.9rem;
}
.spec th, .spec td {
  text-align: left;
  vertical-align: top;
  padding: 0.95rem 1.1rem 0.95rem 0;
  border-bottom: 1px solid var(--rule);
}
.spec thead th {
  font-family: var(--f-sans);
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  background: var(--ink);
  padding: 0.7rem 1.1rem 0.7rem 0.85rem;
  border-bottom: none;
}
.spec tbody th {
  font-family: var(--f-serif);
  font-size: 1.04rem;
  font-weight: 600;
  color: var(--ink);
  padding-left: 0.85rem;
  white-space: nowrap;
}
.spec tbody td:last-child { color: var(--ink-soft); }
.spec tbody tr:nth-child(even) { background: rgba(27, 29, 35, 0.028); }

/* ---------- ordered process ---------- */

.process { margin: 2.2rem 0 0; padding: 0; list-style: none; counter-reset: step; }
.process li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 2.6rem minmax(0, 1fr);
  gap: 1.4rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--rule);
}
.process li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--f-sans);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--violet);
  padding-top: 0.34rem;
}
.process h3 { margin-bottom: 0.35rem; }
.process p { font-size: 0.95rem; color: var(--ink-soft); }

/* ---------- pull quote / note ---------- */

.note {
  border-left: 3px solid var(--violet);
  background: var(--paper-2);
  padding: 1.5rem 1.7rem;
  margin-top: 2.2rem;
  max-width: 54rem;
}
.note h3 { margin-bottom: 0.5rem; font-size: 1.08rem; }
.note p { font-size: 0.97rem; color: var(--ink-soft); }
.band-tint .note { background: #fff; }

/* ---------- list ---------- */

ul.plain { margin: 1.3rem 0 0; padding-left: 1.1rem; }
ul.plain li { margin-bottom: 0.75rem; padding-left: 0.3rem; }
ul.plain li::marker { color: var(--violet); }

/* ---------- contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: 2.6rem;
  margin-top: 2.4rem;
}
.contact-grid dt {
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin-bottom: 0.35rem;
}
.contact-grid dd {
  margin: 0 0 1.5rem;
  font-size: 1.06rem;
  font-family: var(--f-serif);
  color: var(--ink);
}

/* ---------- footer ---------- */

.foot {
  background: var(--ink);
  color: #868C97;
  padding: 2.8rem 0;
  font-size: 0.82rem;
}
.foot .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 2rem;
  justify-content: space-between;
  align-items: center;
}
.foot a { color: #C6CAD2; text-decoration: none; }
.foot a:hover { color: #fff; text-decoration: underline; }
.foot-links { display: flex; flex-wrap: wrap; gap: 1.4rem; }

/* ---------- responsive ---------- */

@media (max-width: 60rem) {
  .row { grid-template-columns: 1fr; gap: 0.4rem; }
  .hero-grid { grid-template-columns: 1fr; }
  .lattice { display: none; }
}

@media (max-width: 46rem) {
  html { font-size: 100%; }
  .hero { padding: 3.6rem 0 3.2rem; }
  .band { padding: 3rem 0; }
  .masthead .wrap { padding-top: 0.95rem; padding-bottom: 0.95rem; }
  .nav { margin-left: 0; width: 100%; gap: 1.15rem; }
  .spec { font-size: 0.88rem; }
  .spec th, .spec td { padding-right: 0.7rem; }
  .spec tbody th { white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
