/* Trustelya — Evidence Desk (light ledger)
   Direction: cool paper + deep teal ink. Editorial trust, not crypto glow. */

:root {
  --paper: #f2f5f3;
  --paper-deep: #e6ebe8;
  --ink: #121816;
  --ink-soft: #3a4641;
  --ink-mute: #6a7671;
  --teal: #0c5346;
  --teal-bright: #147a66;
  --line: #c5d0cb;
  --line-strong: #9aaba3;
  --amber: #a86b14;
  --danger: #a84336;
  --ok: #0c5346;
  --white: #ffffff;
  --radius: 5px;
  --max: 1120px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font-display: "Newsreader", "Georgia", serif;
  --font-body: "Figtree", "Segoe UI", sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.62;
  color: var(--ink-soft);
  background-color: var(--paper);
  background-image:
    linear-gradient(90deg, rgba(18, 24, 22, 0.03) 1px, transparent 1px),
    linear-gradient(rgba(18, 24, 22, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  background-attachment: fixed;
  min-height: 100vh;
  font-variant-numeric: tabular-nums;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--teal);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color 0.2s var(--ease);
}

a:hover {
  color: var(--teal-bright);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--teal);
  color: var(--white);
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* Disclaimer — quiet ink bar */
.disclaimer {
  background: var(--ink);
  color: rgba(242, 245, 243, 0.82);
  font-size: 0.8125rem;
  text-align: center;
  padding: 0.5rem 1rem;
  letter-spacing: 0.01em;
}

.disclaimer strong {
  color: var(--white);
  font-weight: 600;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(242, 245, 243, 0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease), padding 0.25s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 1px 0 var(--line);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.95rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: padding 0.25s var(--ease);
}

.site-header.is-scrolled .header-inner {
  padding-top: 0.7rem;
  padding-bottom: 0.7rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink);
  text-decoration: none;
}

.brand:hover {
  color: var(--ink);
}

.brand img {
  width: 32px;
  height: 32px;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.4rem;
  letter-spacing: -0.03em;
  line-height: 1;
}

.brand-name span {
  color: var(--teal);
  font-style: italic;
  font-weight: 400;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
  align-items: center;
  font-size: 0.9375rem;
}

.nav a {
  color: var(--ink-mute);
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--ink);
}

.nav-cta {
  color: var(--white) !important;
  background: var(--teal);
  padding: 0.42rem 0.9rem;
  border-radius: var(--radius);
  font-weight: 600;
}

.nav-cta:hover {
  background: var(--ink) !important;
  color: var(--white) !important;
}

.menu-toggle {
  display: none;
  background: var(--white);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  padding: 0.4rem 0.75rem;
  font: inherit;
  cursor: pointer;
  border-radius: var(--radius);
}

/* Layout */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section {
  padding: 5.5rem 0;
}

.section-tight {
  padding: 3.25rem 0;
}

.section-label {
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 0.75rem;
  font-weight: 600;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.12;
  margin: 0 0 0.75rem;
  color: var(--ink);
}

h1 {
  font-size: clamp(2.15rem, 4.8vw, 3.35rem);
}

h2 {
  font-size: clamp(1.55rem, 2.8vw, 2.15rem);
}

h3 {
  font-size: 1.2rem;
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: -0.015em;
}

.lede {
  font-size: 1.08rem;
  color: var(--ink-mute);
  max-width: 38rem;
  margin: 0;
}

/* Crop marks — quiet print motif */
.crop {
  position: relative;
}

.crop::before,
.crop::after {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border-color: var(--teal);
  border-style: solid;
  pointer-events: none;
  opacity: 0.5;
  z-index: 2;
}

.crop::before {
  top: 12px;
  left: 12px;
  border-width: 1.5px 0 0 1.5px;
}

.crop::after {
  top: 12px;
  right: 12px;
  border-width: 1.5px 1.5px 0 0;
}

.crop-marks {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}

.crop-marks::before,
.crop-marks::after {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border-color: var(--teal);
  border-style: solid;
  opacity: 0.5;
}

.crop-marks::before {
  bottom: 12px;
  left: 12px;
  border-width: 0 0 1.5px 1.5px;
}

.crop-marks::after {
  bottom: 12px;
  right: 12px;
  border-width: 0 1.5px 1.5px 0;
}

/* Hero — one composition, brand first, full-bleed ledger visual */
.hero {
  position: relative;
  min-height: min(88vh, 780px);
  display: grid;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #c5d5ce;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 78% center;
  pointer-events: none;
  user-select: none;
}

/* Left-only scrim for copy — right half of the image stays fully visible */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(
    100deg,
    rgba(242, 245, 243, 0.88) 0%,
    rgba(242, 245, 243, 0.58) 20%,
    rgba(242, 245, 243, 0.16) 36%,
    rgba(242, 245, 243, 0) 48%
  );
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 5rem 1.25rem 4.25rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: end;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  max-width: 30rem;
  padding-bottom: 0.5rem;
}

.hero-brand {
  font-family: var(--font-display);
  font-size: clamp(2.75rem, 7vw, 4.75rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 0.92;
  margin: 0;
  color: var(--ink);
  animation: riseIn 0.65s var(--ease) both;
}

.hero-brand em {
  font-style: italic;
  color: var(--teal);
  font-weight: 400;
}

.hero h1 {
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.25;
  max-width: 28ch;
  color: var(--ink);
  animation: riseIn 0.65s var(--ease) 0.07s both;
}

.hero h1 .mute {
  color: var(--ink-mute);
}

.hero .lede {
  animation: riseIn 0.65s var(--ease) 0.12s both;
  font-size: 1.02rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.35rem;
  animation: riseIn 0.65s var(--ease) 0.18s both;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.82rem 1.3rem;
  font-family: var(--font-body);
  font-size: 0.97rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.22s var(--ease), background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.22s;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 1px 0 rgba(18, 24, 22, 0.08);
}

.btn-primary:hover {
  background: var(--ink);
  color: var(--white);
}

.btn-secondary {
  background: var(--white);
  color: var(--ink);
  border-color: var(--line-strong);
}

.btn-secondary:hover {
  border-color: var(--teal);
  color: var(--teal);
}

.btn-ghost {
  background: transparent;
  color: var(--ink-soft);
  border-color: var(--line);
  padding: 0.55rem 0.9rem;
  font-size: 0.88rem;
}

.btn-ghost:hover {
  border-color: var(--teal);
  color: var(--teal);
}

/* Evidence panel (hero dominant visual) */
.evidence-panel {
  background: var(--white);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 18px 40px -28px rgba(18, 24, 22, 0.35);
}

.evidence-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.95rem 1.1rem;
  border-bottom: 1px solid var(--line);
  background: var(--paper-deep);
}

.evidence-panel-head strong {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.05rem;
  color: var(--ink);
}

.evidence-panel-head span {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.evidence-rows {
  margin: 0;
  padding: 0;
  list-style: none;
}

.evidence-rows li {
  display: grid;
  grid-template-columns: 6.5rem 1fr auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.9rem;
}

.evidence-rows li:last-child {
  border-bottom: 0;
}

.evidence-rows .when {
  color: var(--ink-mute);
  font-size: 0.8rem;
}

.evidence-rows .what {
  color: var(--ink);
  font-weight: 500;
}

.evidence-panel-foot {
  padding: 0.75rem 1.1rem;
  border-top: 1px dashed var(--line-strong);
  font-size: 0.78rem;
  color: var(--ink-mute);
  background: var(--paper);
}

/* Search */
.search-panel {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 1.25rem;
  border-radius: var(--radius);
}

.search-panel label {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.search-row {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.search-row input {
  flex: 1 1 220px;
  min-width: 0;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  padding: 0.8rem 1rem;
  font: inherit;
  border-radius: var(--radius);
}

.search-row input:focus {
  outline: 2px solid var(--teal);
  outline-offset: 1px;
  background: var(--white);
}

.search-hint {
  margin: 0.65rem 0 0;
  font-size: 0.85rem;
  color: var(--ink-mute);
}

.demo-ribbon {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid rgba(168, 107, 20, 0.45);
  padding: 0.2rem 0.55rem;
  margin-bottom: 0.75rem;
  border-radius: var(--radius);
  font-weight: 600;
}

/* Lists */
.list {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.list-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  align-items: start;
  padding: 1.35rem 0.15rem;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
  transition: background 0.2s, padding-left 0.2s var(--ease);
}

.list-item:hover {
  background: rgba(12, 83, 70, 0.04);
  padding-left: 0.45rem;
}

.list-item h3 {
  margin: 0 0 0.35rem;
  color: var(--ink);
}

.list-meta {
  font-size: 0.9rem;
  color: var(--ink-mute);
  margin: 0;
}

.list-aside {
  text-align: right;
  font-size: 0.85rem;
  color: var(--ink-mute);
}

.status {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.22rem 0.5rem;
  border: 1px solid currentColor;
  border-radius: var(--radius);
}

.status-completed {
  color: var(--ok);
}

.status-delayed {
  color: var(--amber);
}

.status-disputed {
  color: var(--danger);
}

/* Profile detail */
.profile-hero {
  padding: 3.25rem 0 2.25rem;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, var(--white) 0%, var(--paper) 100%);
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.35rem;
  margin-top: 2rem;
}

.field {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.field dt {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  margin: 0 0 0.4rem;
  font-weight: 600;
}

.field dd {
  margin: 0;
  font-size: 1.02rem;
  color: var(--ink);
  word-break: break-word;
}

.field dd a {
  color: var(--teal);
}

/* Case detail */
.timeline {
  margin: 2rem 0 0;
  border-left: 2px solid var(--line);
  padding-left: 1.25rem;
}

.timeline li {
  list-style: none;
  margin-bottom: 1.25rem;
  position: relative;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -1.55rem;
  top: 0.4rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--teal);
  border: 2px solid var(--paper);
  box-shadow: 0 0 0 1px var(--teal);
}

.prose {
  max-width: 42rem;
}

.prose p,
.prose li {
  color: var(--ink-soft);
}

.prose h2 {
  margin-top: 2.5rem;
}

.bilingual {
  display: grid;
  gap: 2rem;
}

@media (min-width: 860px) {
  .bilingual {
    grid-template-columns: 1fr 1fr;
  }
}

.lang-block {
  border-top: 2px solid var(--teal);
  padding-top: 1rem;
  background: var(--white);
  padding: 1.15rem 1.2rem 1.25rem;
  border: 1px solid var(--line);
  border-top: 2px solid var(--teal);
  border-radius: var(--radius);
}

.lang-block h2 {
  font-size: 1.05rem;
  color: var(--teal);
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0;
}

/* Form */
.form {
  display: grid;
  gap: 1rem;
  max-width: 36rem;
}

.form label {
  display: grid;
  gap: 0.4rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.form input,
.form select,
.form textarea {
  background: var(--white);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  padding: 0.75rem 0.9rem;
  font: inherit;
  border-radius: var(--radius);
  width: 100%;
}

.form textarea {
  min-height: 120px;
  resize: vertical;
}

.form-note {
  font-size: 0.85rem;
  color: var(--ink-mute);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 2rem;
  padding: 2.75rem 0 3rem;
  color: var(--ink-mute);
  font-size: 0.9rem;
  background: var(--white);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: space-between;
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}

.footer-links a {
  color: var(--ink-mute);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--teal);
}

/* Reveal motion */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

[hidden] {
  display: none !important;
}

.muted {
  color: var(--ink-mute);
}

hr.rule {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2rem 0;
}

.footnote {
  font-size: 0.82rem;
  color: var(--ink-mute);
}

.mark-word {
  background: linear-gradient(transparent 62%, rgba(12, 83, 70, 0.18) 62%);
  padding: 0 0.1em;
}

@media (prefers-reduced-motion: reduce) {
  .hero-brand,
  .hero h1,
  .hero .lede,
  .hero .cta-row {
    animation: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .btn:hover {
    transform: none;
  }
}

/* Mobile — image as a clear full-bleed band under copy (no ghost-behind-text) */
@media (max-width: 900px) {
  .hero {
    display: flex;
    flex-direction: column;
    min-height: auto;
    background: #d5e0db;
  }

  .hero-media {
    position: relative;
    inset: auto;
    order: 2;
    width: 100%;
    height: clamp(240px, 48vw, 360px);
    max-width: none;
    object-fit: cover;
    object-position: 82% 28%;
  }

  .hero-scrim {
    display: none;
  }

  .hero-inner {
    order: 1;
    position: relative;
    z-index: 1;
    align-items: start;
    padding-top: 2.75rem;
    padding-bottom: 2rem;
    background: linear-gradient(180deg, #e8efeb 0%, #dce6e1 100%);
  }

  .hero-copy {
    max-width: none;
    background: none;
    padding: 0;
  }
}

@media (max-width: 760px) {
  .menu-toggle {
    display: inline-block;
  }

  .nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 0.75rem;
  }

  .nav.is-open {
    display: flex;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .list-item {
    grid-template-columns: 1fr;
  }

  .list-aside {
    text-align: left;
  }

  .evidence-rows li {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }

  .section {
    padding: 3.75rem 0;
  }
}
