/* =========================================================
   Etica ESG  |  Design System
   Anchored on olive green (logo) with warm cream + charcoal.
   Aesthetic reference: top professional consultancies.
   ========================================================= */

:root {
  /* Brand palette */
  --olive: #6F7A3D;
  --olive-deep: #4F5A2A;
  --olive-soft: #A6AC7E;
  --sand: #C9B98A;
  --cream: #F7F3EA;
  --cream-soft: #FBF8F1;
  --ink: #1C2014;
  --ink-soft: #3A4030;
  --line: #DCD6C4;
  --muted: #6F6E5E;
  --paper: #FFFFFF;

  /* Typography */
  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* Layout */
  --container: 1240px;
  --container-narrow: 880px;
  --radius: 4px;
  --shadow: 0 12px 30px rgba(28, 32, 20, 0.08);

  /* Motion */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* =========================================================
   Reset
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img, svg, picture { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; }
ul, ol { padding: 0; margin: 0; }

/* =========================================================
   Base
   ========================================================= */
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--olive);
  color: var(--cream);
}

/* =========================================================
   Typography
   ========================================================= */
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0 0 0.5em;
  line-height: 1.1;
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); font-weight: 500; }
h2 { font-size: clamp(2rem, 3.5vw, 3rem); font-weight: 500; }
h3 { font-size: clamp(1.4rem, 2vw, 1.75rem); font-weight: 500; }
h4 { font-size: 1.125rem; font-family: var(--sans); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }

p { margin: 0 0 1em; max-width: 70ch; }
.lead {
  font-size: clamp(1.1rem, 1.4vw, 1.3rem);
  line-height: 1.55;
  color: var(--ink-soft);
}

.eyebrow {
  font-family: var(--sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--olive);
  margin-bottom: 1.25rem;
  display: inline-block;
}

a.inline {
  color: var(--olive-deep);
  border-bottom: 1px solid var(--olive-soft);
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
a.inline:hover { color: var(--ink); border-color: var(--ink); }

/* =========================================================
   Layout helpers
   ========================================================= */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 2rem;
}
.container.narrow { max-width: var(--container-narrow); }

section { padding: clamp(4rem, 8vw, 7rem) 0; }
section.tight { padding: clamp(3rem, 5vw, 4.5rem) 0; }

.divider {
  width: 64px;
  height: 1px;
  background: var(--olive);
  margin: 0 0 1.5rem;
}

/* =========================================================
   Header
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 243, 234, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); }

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 2rem;
  max-width: var(--container);
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  text-decoration: none;
  transition: opacity 0.2s var(--ease);
}
.brand:hover { opacity: 0.85; }
.brand img.mark {
  height: 34px;
  width: auto;
  display: block;
}
.brand .wordmark {
  display: inline-flex;
  align-items: baseline;
  gap: 0.32rem;
  font-family: var(--serif);
  line-height: 1;
}
.brand .wordmark .etica {
  font-size: 1.55rem;
  font-weight: 500;
  letter-spacing: 0.005em;
  color: var(--ink);
}
.brand .wordmark .esg {
  font-size: 1.05rem;
  font-style: italic;
  font-weight: 500;
  color: var(--olive);
  letter-spacing: 0.06em;
  position: relative;
  top: -1px;
}

/* Footer variant: light text on dark ink background */
.footer-brand .brand .wordmark .etica { color: var(--cream); }
.footer-brand .brand .wordmark .esg { color: var(--olive-soft); }
.footer-brand .brand img.mark { height: 38px; }

@media (max-width: 540px) {
  .brand img.mark { height: 30px; }
  .brand .wordmark .etica { font-size: 1.35rem; }
  .brand .wordmark .esg { font-size: 0.95rem; }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}
.nav-links a {
  font-size: 0.93rem;
  font-weight: 500;
  color: var(--ink-soft);
  position: relative;
  transition: color 0.2s var(--ease);
}
.nav-links a:hover, .nav-links a.active { color: var(--olive-deep); }
.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: -6px;
  height: 1px;
  background: var(--olive);
}

.nav-cta {
  background: var(--ink);
  color: var(--cream);
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 500;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}
.nav-cta:hover { background: var(--olive-deep); transform: translateY(-1px); }

.nav-toggle { display: none; flex-direction: column; gap: 5px; padding: 8px; }
.nav-toggle span {
  width: 22px; height: 2px; background: var(--ink); display: block;
  transition: transform 0.2s var(--ease), opacity 0.2s var(--ease);
}

@media (max-width: 880px) {
  .nav-links {
    position: fixed;
    inset: 64px 0 0 0;
    background: var(--cream);
    flex-direction: column;
    align-items: flex-start;
    padding: 2rem;
    gap: 1.25rem;
    transform: translateX(100%);
    transition: transform 0.3s var(--ease);
    border-top: 1px solid var(--line);
  }
  .nav-links.open { transform: translateX(0); }
  .nav-toggle { display: inline-flex; }
  .nav-cta { order: 99; }
}

/* =========================================================
   Buttons
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.95rem 1.6rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

.btn.primary {
  background: var(--ink);
  color: var(--cream);
}
.btn.primary:hover { background: var(--olive-deep); transform: translateY(-1px); }

.btn.olive {
  background: var(--olive);
  color: var(--cream);
}
.btn.olive:hover { background: var(--olive-deep); }

.btn.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--ink);
}
.btn.ghost:hover { background: var(--ink); color: var(--cream); }

.btn.text {
  padding: 0.4rem 0;
  color: var(--olive-deep);
  font-weight: 600;
  border-bottom: 1px solid var(--olive-soft);
  border-radius: 0;
}
.btn.text:hover { color: var(--ink); border-color: var(--ink); }

/* =========================================================
   Hero
   ========================================================= */
.hero {
  position: relative;
  padding: clamp(5rem, 9vw, 9rem) 0 clamp(4rem, 7vw, 6rem);
  background:
    radial-gradient(900px 500px at 90% 10%, rgba(111, 122, 61, 0.12), transparent 60%),
    radial-gradient(700px 400px at 0% 80%, rgba(201, 185, 138, 0.18), transparent 60%),
    var(--cream);
  overflow: hidden;
}

.hero h1 {
  font-size: clamp(2.6rem, 6vw, 5.2rem);
  max-width: 18ch;
}
.hero h1 em {
  font-style: italic;
  color: var(--olive-deep);
  font-weight: 400;
}

.hero .lead {
  margin: 1.5rem 0 2.5rem;
  max-width: 56ch;
}

.hero .actions { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-meta {
  display: flex;
  gap: 3rem;
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.hero-meta .item { max-width: 18ch; }
.hero-meta .item .num {
  font-family: var(--serif);
  font-size: 2rem;
  color: var(--olive-deep);
  font-weight: 500;
  line-height: 1;
}
.hero-meta .item .label {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.5rem;
}

.hero-mark {
  position: absolute;
  top: 50%;
  right: -80px;
  transform: translateY(-50%);
  width: 480px;
  opacity: 0.14;
  pointer-events: none;
}

/* =========================================================
   Package meta strip
   ========================================================= */
.pkg-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--cream-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 1rem 0 1.25rem;
}
.pkg-meta .item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.pkg-meta .item .label {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}
.pkg-meta .item .value {
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--ink);
  font-style: italic;
}

/* =========================================================
   Proof strip
   ========================================================= */
.proof-strip {
  background: var(--ink);
  color: var(--cream);
  padding: 1.6rem 0;
  position: relative;
  overflow: hidden;
}
.proof-strip::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(900px 200px at 90% 50%, rgba(166, 172, 126, 0.18), transparent 60%);
  pointer-events: none;
}
.proof-strip .container { position: relative; z-index: 1; }
.proof-strip .proof-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 2.25rem;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  font-size: 0.92rem;
  color: rgba(247, 243, 234, 0.85);
}
.proof-strip .proof-list li {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.proof-strip .proof-list .num {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--olive-soft);
  line-height: 1;
}

/* =========================================================
   Section header
   ========================================================= */
.section-head {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 3rem;
  align-items: end;
  margin-bottom: 3.5rem;
}
.section-head .lead { margin: 0; }
@media (max-width: 880px) {
  .section-head { grid-template-columns: 1fr; gap: 1rem; margin-bottom: 2.5rem; }
}

/* =========================================================
   Cards / Grids
   ========================================================= */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.card {
  background: var(--paper);
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.card:hover { border-color: var(--olive); transform: translateY(-3px); box-shadow: var(--shadow); }
.card .num {
  font-family: var(--serif);
  color: var(--olive);
  font-size: 1.1rem;
  font-style: italic;
}
.card h3 { margin: 0; font-size: 1.4rem; }
.card p { color: var(--ink-soft); margin: 0; font-size: 0.97rem; }
.card .more {
  margin-top: auto;
  padding-top: 1rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--olive-deep);
  letter-spacing: 0.02em;
}

/* Practice card variant */
.practice-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 2.25rem;
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 1.5rem;
  row-gap: 0.5rem;
  align-items: start;
  transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}
.practice-card:hover { border-color: var(--olive); background: var(--cream-soft); }
.practice-card .ix {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--olive);
  font-style: italic;
  grid-row: span 3;
}
.practice-card h3 { margin: 0; font-size: 1.5rem; }
.practice-card .summary { color: var(--ink-soft); margin: 0; }
.practice-card ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.practice-card ul li {
  font-size: 0.82rem;
  padding: 0.3rem 0.7rem;
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
}

/* =========================================================
   Banner / Pull quote
   ========================================================= */
.banner {
  background: var(--ink);
  color: var(--cream);
  padding: clamp(3rem, 5vw, 4.5rem);
  border-radius: var(--radius);
  position: relative;
  overflow: hidden;
}
.banner::before {
  content: "";
  position: absolute;
  inset: auto -10% -60% auto;
  width: 60%;
  height: 200%;
  background: radial-gradient(closest-side, rgba(166, 172, 126, 0.25), transparent);
  pointer-events: none;
}
.banner > * { position: relative; z-index: 1; }
.banner h1, .banner h2, .banner h3, .banner h4 { color: var(--cream); }
.banner h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); max-width: 22ch; }
.banner p { color: var(--cream); opacity: 0.85; max-width: 55ch; }
.banner .eyebrow { color: var(--olive-soft); }
.banner a:not(.btn) {
  color: var(--olive-soft);
  border-bottom: 1px solid rgba(166, 172, 126, 0.4);
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.banner a:not(.btn):hover { color: var(--cream); border-color: var(--cream); }
.banner .btn.olive {
  background: var(--cream);
  color: var(--ink);
}
.banner .btn.olive:hover { background: var(--olive-soft); color: var(--ink); }

/* =========================================================
   Logo wall
   ========================================================= */
.logo-wall {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.logo-wall .cell {
  background: var(--paper);
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--ink-soft);
  letter-spacing: 0.04em;
  min-height: 100px;
}

/* =========================================================
   Insights / Article cards
   ========================================================= */
.articles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
}
.article-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  border-top: 1px solid var(--line);
  padding-top: 1.5rem;
  transition: opacity 0.2s var(--ease);
}
.article-card:hover { opacity: 0.85; }
.article-card .meta {
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}
.article-card h3 { font-size: 1.3rem; margin: 0; }
.article-card p { color: var(--ink-soft); margin: 0; font-size: 0.95rem; }
.article-card .read {
  margin-top: 0.5rem;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--olive-deep);
}
.article-card.preview { cursor: default; }
.article-card.preview:hover { opacity: 1; }
.article-card .badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--olive-soft);
  color: var(--olive-deep);
  border-radius: 999px;
  margin-top: 0.4rem;
  width: max-content;
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  background: var(--ink);
  color: var(--cream);
  padding: 5rem 0 2rem;
  margin-top: 4rem;
}
.site-footer a:hover { color: var(--olive-soft); }

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(247, 243, 234, 0.12);
}
@media (max-width: 880px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

.footer-brand .brand { color: var(--cream); }
.footer-brand .brand .name span { color: var(--olive-soft); }
.footer-brand p { color: rgba(247, 243, 234, 0.7); margin-top: 1rem; max-width: 38ch; }

.footer-col h4 {
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--olive-soft);
  margin-bottom: 1rem;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.footer-col a { color: rgba(247, 243, 234, 0.85); font-size: 0.93rem; }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2rem;
  font-size: 0.83rem;
  color: rgba(247, 243, 234, 0.55);
  flex-wrap: wrap;
  gap: 1rem;
}

/* =========================================================
   Page header (interior pages)
   ========================================================= */
.page-head {
  padding: clamp(5rem, 8vw, 7rem) 0 clamp(2rem, 4vw, 3.5rem);
  background:
    radial-gradient(700px 400px at 100% 0%, rgba(111, 122, 61, 0.10), transparent 60%),
    var(--cream);
  border-bottom: 1px solid var(--line);
}
.page-head h1 { font-size: clamp(2.4rem, 5vw, 4rem); max-width: 22ch; }
.page-head .lead { margin-top: 1.25rem; max-width: 60ch; }

/* =========================================================
   Two-column blocks
   ========================================================= */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
@media (max-width: 880px) { .two-col { grid-template-columns: 1fr; gap: 2rem; } }

/* =========================================================
   Forms
   ========================================================= */
.form {
  display: grid;
  gap: 1.25rem;
  max-width: 640px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.field label {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.field input, .field textarea, .field select {
  font-family: var(--sans);
  font-size: 1rem;
  padding: 0.9rem 1rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--olive);
  box-shadow: 0 0 0 3px rgba(111, 122, 61, 0.15);
}
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }

/* =========================================================
   Stats strip
   ========================================================= */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 2rem;
  padding: 2.5rem;
  background: var(--cream-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.stats .stat .v {
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--olive-deep);
  line-height: 1;
}
.stats .stat .l {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.6rem;
  letter-spacing: 0.04em;
}

/* =========================================================
   Subtle entrance animation
   ========================================================= */
.fade-in {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.fade-in.visible { opacity: 1; transform: none; }

/* =========================================================
   Accessibility
   ========================================================= */
:focus-visible {
  outline: 2px solid var(--olive-deep);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  html { scroll-behavior: auto; }
}
