/* ==========================================================================
   THE RESOURCE COMPANY — Design System
   Display: Space Grotesk · Body: IBM Plex Sans · Data/Mono: Space Mono
   ========================================================================== */

:root {
  /* Brand — sampled directly from the TRC mark's diagonal gradient */
  --trc-magenta: #D3145A;
  --trc-ember:   #E04550;
  --trc-amber:   #F18943;
  --trc-bullion: #C9971C;   /* muted secondary gold, used sparingly for value cues */

  --trc-gradient: linear-gradient(115deg, var(--trc-magenta) 0%, var(--trc-ember) 55%, var(--trc-amber) 100%);
  --trc-gradient-soft: linear-gradient(115deg, rgba(211,20,90,0.07), rgba(241,137,67,0.10));

  /* Neutrals */
  --ink:        #14110F;
  --ink-soft:   #3D3835;
  --muted:      #726A64;
  --border:     #E7E0D8;
  --paper:      #FFFFFF;
  --paper-warm: #FAF6F2;
  --dark:       #1B1310;
  --dark-soft:  #2A1F1A;
  --dark-line:  rgba(255,255,255,0.12);

  /* Signal */
  --up:   #1E7A4C;
  --down: #C13A2E;

  /* Type */
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'IBM Plex Sans', sans-serif;
  --font-mono: 'Space Mono', monospace;

  /* Shape & shadow */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 2px 10px rgba(27,17,16,0.06);
  --shadow-md: 0 12px 32px rgba(27,17,16,0.10);

  --container: 1160px;
}

/* ---- Reset & base ---- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  color: var(--ink-soft);
  background: var(--paper);
  font-size: 1.02rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--trc-amber); color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  color: var(--ink);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0;
}
.h-mono, .eyebrow, .code-tag, .ticker, .price-value, .price-change, .stat-figure {
  font-family: var(--font-mono);
}

.container-trc {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 96px 0; }
.section-sm { padding: 56px 0; }
.bg-warm { background: var(--paper-warm); }
.bg-dark { background: var(--dark); color: rgba(255,255,255,0.82); }
.bg-dark h1, .bg-dark h2, .bg-dark h3, .bg-dark h4 { color: #fff; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--trc-magenta);
  margin-bottom: 14px;
}
.eyebrow::before {
  content: '';
  width: 18px; height: 2px;
  background: var(--trc-gradient);
  display: inline-block;
}
.bg-dark .eyebrow { color: var(--trc-amber); }

.lede { font-size: 1.15rem; color: var(--muted); max-width: 620px; }
.bg-dark .lede { color: rgba(255,255,255,0.68); }

/* ---- Diagonal accent bar — the recurring brand device ---- */
.accent-bar {
  width: 56px; height: 5px;
  background: var(--trc-gradient);
  border-radius: 3px;
  transform: skewX(-18deg);
  margin: 18px 0 0;
}
.accent-bar.center { margin-left: auto; margin-right: auto; }

/* ---- Buttons ---- */
.btn-trc {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.96rem;
  padding: 13px 26px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn-trc:hover { transform: translateY(-1px); }
.btn-primary-trc {
  background: var(--trc-gradient);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary-trc:hover { box-shadow: var(--shadow-md); color: #fff; }
.btn-outline-trc {
  background: transparent;
  border-color: var(--border);
  color: var(--ink);
}
.btn-outline-trc:hover { border-color: var(--ink); color: var(--ink); }
.bg-dark .btn-outline-trc { border-color: var(--dark-line); color: #fff; }
.bg-dark .btn-outline-trc:hover { border-color: rgba(255,255,255,0.5); }
.btn-sm-trc { padding: 9px 18px; font-size: 0.85rem; }

/* ==========================================================================
   TOP ASSAY STRIP — signature live-price ticker, persistent on every page
   ========================================================================== */
.assay-strip {
  background: var(--dark);
  color: rgba(255,255,255,0.85);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  padding: 8px 0;
  overflow: hidden;
  border-bottom: 1px solid var(--dark-line);
}
.assay-strip .container-trc {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.assay-strip .ticker {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.ticker-item strong { color: #fff; font-weight: 700; }
.ticker-item .chg.up { color: #6FDB9F; }
.ticker-item .chg.down { color: #F0968C; }
.ticker-sep { opacity: 0.35; }
.ticker-status {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.7;
}
.ticker-status .dot { width: 6px; height: 6px; border-radius: 50%; background: #6FDB9F; display: inline-block; }
.assay-strip .quick-links { display: flex; align-items: center; gap: 18px; }
.assay-strip .quick-links a { display: inline-flex; align-items: center; gap: 6px; opacity: 0.85; }
.assay-strip .quick-links a:hover { opacity: 1; }
@media (max-width: 767px) {
  .assay-strip .quick-links span.txt { display: none; }
}

/* ==========================================================================
   NAVBAR
   ========================================================================== */
.navbar-trc {
  background: var(--paper);
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.navbar-trc .navbar-brand img { height: 34px; width: auto; }
.navbar-trc .nav-link {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.94rem;
  color: var(--ink-soft) !important;
  padding: 8px 14px !important;
  position: relative;
}
.navbar-trc .nav-link.active,
.navbar-trc .nav-link:hover { color: var(--ink) !important; }
.navbar-trc .nav-link.active::after {
  content: '';
  position: absolute;
  left: 14px; right: 14px; bottom: 2px;
  height: 2px;
  background: var(--trc-gradient);
  border-radius: 2px;
}
.navbar-trc .dropdown-menu {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 8px;
}
.navbar-trc .dropdown-item {
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.92rem;
  font-weight: 500;
}
.navbar-trc .dropdown-item:hover { background: var(--paper-warm); }
.nav-cta { margin-left: 8px; }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  padding: 64px 0 88px;
  position: relative;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 991px) {
  .hero-grid { grid-template-columns: 1fr; }
}
.hero h1 {
  font-size: clamp(2.4rem, 4.6vw, 3.9rem);
  margin-bottom: 22px;
}
.hero .lede { margin-bottom: 30px; font-size: 1.18rem; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---- Trade ticket — the hero's signature functional artifact ---- */
.trade-ticket {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}
.trade-ticket::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 6px;
  background: var(--trc-gradient);
}
.trade-ticket-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px 24px 14px;
  border-bottom: 1px dashed var(--border);
}
.trade-ticket-head .label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.ticket-status-pill {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(30,122,76,0.1);
  color: var(--up);
  display: inline-flex; align-items: center; gap: 6px;
}
.ticket-status-pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--up); }
.ticket-rows { padding: 6px 24px 20px; }
.ticket-row {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.ticket-row:last-child { border-bottom: none; }
.ticket-row .name { font-weight: 600; color: var(--ink); font-size: 0.95rem; }
.ticket-row .code { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); margin-left: 8px; }
.ticket-row .price-value { font-size: 1.3rem; font-weight: 700; color: var(--ink); }
.ticket-row .price-change { font-size: 0.78rem; font-weight: 700; margin-left: 8px; }
.price-change.up { color: var(--up); }
.price-change.down { color: var(--down); }
.ticket-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 24px;
  background: var(--paper-warm);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--muted);
}
.ticket-foot a { color: var(--trc-magenta); font-weight: 700; }

/* ==========================================================================
   CATEGORY CODES — used for classification, not sequence
   ========================================================================== */
.code-tag {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 26px; padding: 0 8px;
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.04em;
  border-radius: 6px;
  background: var(--paper-warm);
  border: 1px solid var(--border);
  color: var(--ink-soft);
}

/* ==========================================================================
   CARDS
   ========================================================================== */
.card-trc {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
  height: 100%;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.card-trc:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: transparent; }
.card-trc .code-tag { margin-bottom: 18px; }
.card-trc h3 { font-size: 1.22rem; margin-bottom: 10px; }
.card-trc p { color: var(--muted); font-size: 0.95rem; margin: 0; }

.card-top-line {
  border-top: 3px solid transparent;
  border-image: var(--trc-gradient) 1;
}

/* Commodity cards with live price slot */
.commodity-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 26px;
  height: 100%;
  position: relative;
}
.commodity-card .sym {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}
.commodity-card h3 { font-size: 1.3rem; margin: 6px 0 12px; }
.commodity-card p { color: var(--muted); font-size: 0.92rem; }
.commodity-card .price-block {
  margin-top: 18px; padding-top: 16px;
  border-top: 1px dashed var(--border);
  display: flex; align-items: baseline; justify-content: space-between;
}
.commodity-card .price-value { font-size: 1.15rem; font-weight: 700; color: var(--ink); }
.commodity-card .price-note { font-size: 0.78rem; color: var(--muted); font-style: italic; }
.commodity-card .unit { font-size: 0.72rem; color: var(--muted); }
.commodity-card.featured { border-color: var(--trc-amber); }

/* ==========================================================================
   PROCESS STEPS — genuinely sequential, numbering earned here
   ========================================================================== */
.step-row {
  display: flex; gap: 20px;
  padding: 26px 0;
  border-bottom: 1px solid var(--border);
}
.step-row:last-child { border-bottom: none; }
.step-num {
  font-family: var(--font-mono);
  font-size: 1.3rem;
  font-weight: 700;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  background-image: var(--trc-gradient);
  min-width: 44px;
}
.step-body h4 { font-size: 1.08rem; margin-bottom: 6px; }
.step-body p { color: var(--muted); font-size: 0.94rem; margin: 0; }

/* ==========================================================================
   STAT LIST — cadastre / register style, not a hero stat row
   ========================================================================== */
.register-list { border-top: 1px solid var(--border); }
.register-row {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  gap: 16px;
}
.register-row .term { font-weight: 600; color: var(--ink); }
.register-row .val { font-family: var(--font-mono); font-size: 0.92rem; color: var(--muted); text-align: right; }

/* ==========================================================================
   FORMS
   ========================================================================== */
.form-trc label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 6px;
  display: block;
}
.form-trc .form-control,
.form-trc .form-select {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 0.95rem;
  background: var(--paper);
}
.form-trc .form-control:focus,
.form-trc .form-select:focus {
  border-color: var(--trc-ember);
  box-shadow: 0 0 0 3px rgba(224,69,80,0.12);
}
.form-trc textarea.form-control { min-height: 120px; }
.hp-field { position: absolute; left: -9999px; top: -9999px; opacity: 0; height: 0; }
.form-feedback { font-size: 0.9rem; font-weight: 500; }

/* ==========================================================================
   FAQ / ACCORDION overrides
   ========================================================================== */
.accordion-trc .accordion-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm) !important;
  margin-bottom: 10px;
  overflow: hidden;
}
.accordion-trc .accordion-button {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  background: var(--paper);
  padding: 18px 20px;
}
.accordion-trc .accordion-button:not(.collapsed) {
  background: var(--paper-warm);
  color: var(--ink);
  box-shadow: none;
}
.accordion-trc .accordion-button:focus { box-shadow: none; border-color: var(--border); }
.accordion-trc .accordion-button::after { flex-shrink: 0; }
.accordion-trc .accordion-body { color: var(--muted); font-size: 0.95rem; padding: 4px 20px 20px; }

/* ==========================================================================
   FINAL CTA BAND
   ========================================================================== */
.cta-band {
  background: var(--dark);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 56px;
  position: relative;
  overflow: hidden;
}
.cta-band::after {
  content: '';
  position: absolute; right: -60px; top: -60px;
  width: 260px; height: 260px;
  background: var(--trc-gradient);
  opacity: 0.18;
  border-radius: 50%;
  filter: blur(10px);
}
.cta-band h2 { color: #fff; font-size: clamp(1.7rem, 3vw, 2.3rem); }
@media (max-width: 767px) { .cta-band { padding: 36px 24px; } }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer-trc {
  background: var(--dark);
  color: rgba(255,255,255,0.62);
  padding: 72px 0 28px;
  font-size: 0.92rem;
}
.footer-trc img.footer-logo { height: 30px; width: auto; margin-bottom: 16px; }
.footer-trc h6 {
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer-trc a { color: rgba(255,255,255,0.62); }
.footer-trc a:hover { color: #fff; }
.footer-trc ul { list-style: none; padding: 0; margin: 0; }
.footer-trc li { margin-bottom: 10px; }
.footer-bottom {
  border-top: 1px solid var(--dark-line);
  margin-top: 48px;
  padding-top: 22px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}
.footer-social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--dark-line);
  margin-right: 8px;
}
.footer-disclaimer {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
  border-top: 1px solid var(--dark-line);
  padding-top: 20px;
  margin-top: 32px;
  line-height: 1.6;
}

/* ==========================================================================
   PAGE HEADER (non-home pages)
   ========================================================================== */
.page-header {
  padding: 56px 0 48px;
  border-bottom: 1px solid var(--border);
}
.page-header h1 { font-size: clamp(2rem, 3.4vw, 2.8rem); }
.page-header .lede { margin-top: 16px; }

/* ==========================================================================
   REVEAL ANIMATION — restrained, single-purpose
   ========================================================================== */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ==========================================================================
   UTILITIES
   ========================================================================== */
.text-muted-trc { color: var(--muted) !important; }
.divider-diag {
  height: 3px;
  background: var(--trc-gradient);
  transform: skewX(-18deg);
  width: 64px;
}
.section-title { font-size: clamp(1.6rem, 2.6vw, 2.2rem); margin-bottom: 14px; }
.mono-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.list-check { list-style: none; padding: 0; margin: 0; }
.list-check li {
  position: relative;
  padding-left: 28px;
  margin-bottom: 12px;
  color: var(--ink-soft);
}
.list-check li::before {
  content: '';
  position: absolute; left: 0; top: 7px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--trc-gradient);
}
.badge-soft {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--paper-warm);
  border: 1px solid var(--border);
  color: var(--muted);
  margin: 0 6px 6px 0;
}

@media (max-width: 767px) {
  .section { padding: 64px 0; }
  .cta-band { border-radius: var(--radius-md); }
}
