/* ============================================
   Mohammad Raza Mulla — Design System
   Ink / Parchment / Bronze, Newsreader + IBM Plex Sans
   ============================================ */

:root {
  --ink: #123c43;
  --ink-soft: #1c4e57;
  --parchment: #e7e1d2;
  --paper: #f4f0e6;
  --graphite: #4a5457;
  --steel: #868b80;
  --steel-line: rgba(18, 60, 67, 0.16);
  --steel-line-light: rgba(244, 240, 230, 0.22);
  --bronze: #a8752e;
  --bronze-light: #cf9a4e;
  --cream-text: #f4f0e6;

  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", -apple-system, "Segoe UI", sans-serif;

  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 450; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.1rem; font-family: var(--sans); font-weight: 600; }

p {
  margin: 0 0 1.1em;
  max-width: 62ch;
  text-align: justify;
  text-justify: inter-word;
  hyphens: auto;
}
.wrap p { color: var(--graphite); }
.hero-eyebrow, .stat-label, .pillar-tag, .case-meta .sector,
.resource-kind, .foot-bottom span, .contact-detail .label,
.scale-labels span, .assess-dim { text-align: left; }

@media (max-width: 560px) {
  p { text-align: left; hyphens: none; }
}

a { color: inherit; }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 32px;
}

.rule {
  border: none;
  border-top: 1px solid var(--steel-line);
  margin: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--bronze); }
.btn-outline { border-color: var(--ink); color: var(--ink); }
.btn-outline:hover { border-color: var(--bronze); color: var(--bronze); }
.btn-outline-light { border-color: var(--steel-line-light); color: var(--cream-text); }
.btn-outline-light:hover { border-color: var(--bronze-light); color: var(--bronze-light); }

/* ---------- Header ---------- */
header.site {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(246, 243, 236, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--steel-line);
}
.nav {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo { display: flex; align-items: center; }
.nav-logo img { height: 34px; width: auto; }
.nav-links {
  display: flex;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  text-decoration: none;
  font-size: 0.95rem;
  color: var(--ink);
  position: relative;
  padding-bottom: 4px;
}
.nav-links a.active { color: var(--bronze); }
.nav-links a:hover { color: var(--bronze); }
.nav-cta {
  font-size: 0.9rem;
  text-decoration: none;
  padding: 10px 20px;
  border: 1px solid var(--ink);
  border-radius: 2px;
}
.nav-cta:hover { border-color: var(--bronze); color: var(--bronze); }

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.menu-toggle span { width: 22px; height: 1.5px; background: var(--ink); }

@media (max-width: 880px) {
  .nav-links, .nav-cta { display: none; }
  .menu-toggle { display: flex; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px; left: 0; right: 0;
    background: var(--paper);
    padding: 24px 32px;
    gap: 20px;
    border-bottom: 1px solid var(--steel-line);
  }
  .nav-cta.open { display: inline-flex; margin: 0 32px 24px; }
}

/* ---------- Hero (dark) ---------- */
.hero {
  background: var(--ink);
  color: var(--cream-text);
  padding: 90px 0 70px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 56px;
  align-items: center;
}
.hero-eyebrow {
  font-size: 0.95rem;
  color: var(--steel);
  margin-bottom: 18px;
}
.hero h1 { color: var(--cream-text); }
.hero .lede {
  font-size: 1.15rem;
  color: #c9c4b6;
  max-width: 46ch;
  margin: 22px 0 34px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }
.hero-photo {
  position: relative;
}
.hero-photo img {
  width: 100%;
  display: block;
}

/* ---------- Hover reveal: original photo on hover ---------- */
.img-hover {
  position: relative;
  overflow: hidden;
  display: block;
}
.img-hover .img-base { display: block; width: 100%; }
.img-hover .img-orig {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.img-hover:hover .img-orig { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .img-hover .img-orig { transition: none; }
}

@media (max-width: 880px) {
  .hero-grid { grid-template-columns: 1fr; align-items: center; }
  .hero-photo { order: -1; max-width: 320px; margin: 0 auto 32px; }
}

/* ---------- Stat band ---------- */
.stats {
  background: var(--paper);
  border-bottom: 1px solid var(--steel-line);
}
.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 46px 0;
}
.stat-cell {
  text-align: left;
  padding: 0 24px;
  border-left: 1px solid var(--steel-line);
}
.stat-cell:first-child { border-left: none; padding-left: 0; }
.stat-num {
  font-family: var(--serif);
  font-size: clamp(2rem, 3.2vw, 2.6rem);
  color: var(--bronze);
  display: block;
}
.stat-label { color: var(--graphite); font-size: 0.92rem; }

@media (max-width: 700px) {
  .stat-row { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .stat-cell:nth-child(3) { border-left: none; padding-left: 0; }
}

/* ---------- Sections ---------- */
section { padding: 92px 0; }
.section-tight { padding: 60px 0; }
@media (max-width: 700px) {
  section { padding: 56px 0; }
  .section-tight { padding: 40px 0; }
  .wrap { padding: 0 22px; }
  .hero { padding: 56px 0 44px; }
  .page-banner { padding: 52px 0 44px; }
  .assess-card { padding: 26px 20px; }
  .case-body, .article-item .case-body { max-width: 100%; }
}
.section-head { margin-bottom: 48px; max-width: 60ch; }
.section-head p { font-size: 1.08rem; }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.split.reverse .split-media { order: 2; }
@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; gap: 32px; }
  .split.reverse .split-media { order: 0; }
}
.split-media img, .split-media .img-hover { border-radius: 2px; }

.pillar-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  padding: 56px 0;
  border-top: 1px solid var(--steel-line);
}
.pillar-row:last-child { border-bottom: 1px solid var(--steel-line); }
.pillar-tag { color: var(--bronze); font-size: 0.92rem; margin-bottom: 10px; display: block; }
@media (max-width: 880px) { .pillar-row { grid-template-columns: 1fr; gap: 20px; } }

/* ---------- Case study accordion ---------- */
.case-list { border-top: 1px solid var(--steel-line); }
details.case-item { border-bottom: 1px solid var(--steel-line); }
details.case-item summary {
  list-style: none;
  cursor: pointer;
  padding: 30px 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
}
details.case-item summary::-webkit-details-marker { display: none; }
.case-meta .sector { color: var(--bronze); font-size: 0.88rem; margin-bottom: 8px; }
.case-meta h3 { margin: 0; }
.case-plus {
  font-family: var(--serif);
  font-size: 1.6rem;
  color: var(--steel);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
details[open] .case-plus { transform: rotate(45deg); }
.case-body { padding: 0 0 36px; max-width: 70ch; }
.case-body h4 { margin-top: 20px; }
.case-body ul, .case-body ol { padding-left: 20px; color: var(--graphite); }
.case-body li { margin-bottom: 6px; }
.result-line {
  margin-top: 22px;
  padding: 18px 22px;
  background: var(--parchment);
  border-left: 3px solid var(--bronze);
  font-family: var(--serif);
  font-size: 1.05rem;
}
.result-line strong { color: var(--bronze); }
.illustrative-flag {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.82rem;
  color: var(--steel);
  font-style: italic;
}

/* ---------- Gallery ---------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}
.gallery-grid img, .gallery-grid .img-hover { width: 100%; height: 260px; }
.gallery-grid .img-hover .img-base { height: 260px; object-fit: cover; }
@media (max-width: 880px) { .gallery-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Engagement strip ---------- */
.engage-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 34px;
  padding: 32px 0;
  border-top: 1px solid var(--steel-line);
  border-bottom: 1px solid var(--steel-line);
  color: var(--graphite);
  font-size: 0.95rem;
}

/* ---------- Quote ---------- */
.pull-quote {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  line-height: 1.4;
  max-width: 46ch;
  color: var(--ink);
  text-align: left;
}
.pull-quote cite {
  display: block;
  font-family: var(--sans);
  font-style: normal;
  font-size: 0.9rem;
  color: var(--graphite);
  margin-top: 16px;
}

/* ---------- Cluster list (numbered, real sequence only where noted) ---------- */
.cluster-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--steel-line);
  border: 1px solid var(--steel-line);
}
.cluster-cell { background: var(--paper); padding: 34px; }
.cluster-cell h3 { margin-bottom: 12px; }
.cluster-cell p { color: var(--graphite); font-size: 0.98rem; margin: 0; }
@media (max-width: 700px) { .cluster-grid { grid-template-columns: 1fr; } }

.method-list { counter-reset: step; list-style: none; padding: 0; margin: 0; }
.method-list li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 20px;
  padding: 26px 0;
  border-top: 1px solid var(--steel-line);
}
.method-list li:last-child { border-bottom: 1px solid var(--steel-line); }
.method-list li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--serif);
  color: var(--bronze);
  font-size: 1.3rem;
}
.method-list h4 { margin: 0 0 6px; }
.method-list p { margin: 0; color: var(--graphite); }

/* ---------- Articles (enlarged, magazine-style) ---------- */
.article-list { border-top: 1px solid var(--steel-line); }
details.article-item { border-bottom: 1px solid var(--steel-line); }
details.article-item summary {
  list-style: none;
  cursor: pointer;
  padding: 40px 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 28px;
}
details.article-item summary::-webkit-details-marker { display: none; }
.article-item .sector { color: var(--bronze); font-size: 0.95rem; margin-bottom: 12px; }
.article-item h3 { margin: 0; font-size: clamp(1.6rem, 2.4vw, 2.1rem); }
.article-item .case-plus { font-size: 1.9rem; }
.article-item .case-body { max-width: 74ch; padding-bottom: 44px; }
.article-item .case-body p { font-size: 1.12rem; line-height: 1.7; }

/* ---------- Resource cards (toolkits list, legacy) ---------- */
.resource-list { border-top: 1px solid var(--steel-line); }
.resource-item {
  padding: 34px 0;
  border-bottom: 1px solid var(--steel-line);
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 28px;
}
.resource-kind { color: var(--bronze); font-size: 0.85rem; padding-top: 4px; }
.resource-item h3 { margin-bottom: 10px; }
.resource-item p { color: var(--graphite); margin-bottom: 0; }
@media (max-width: 700px) { .resource-item { grid-template-columns: 1fr; gap: 10px; } }

.toolkit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--steel-line);
  border: 1px solid var(--steel-line);
  margin-top: 12px;
}
.toolkit-cell { background: var(--paper); padding: 30px; display: flex; flex-direction: column; }
.toolkit-cell h4 { margin-bottom: 10px; }
.toolkit-cell p { color: var(--graphite); font-size: 0.94rem; flex-grow: 1; }
.toolkit-cell a { font-size: 0.9rem; color: var(--bronze); text-decoration: none; margin-top: 14px; }
.toolkit-cell a:hover { text-decoration: underline; }
@media (max-width: 880px) { .toolkit-grid { grid-template-columns: 1fr; } }

/* ---------- Assessment CTA banner ---------- */
.assess-banner {
  background: var(--ink);
  color: var(--cream-text);
  padding: 64px 0;
}
.assess-banner .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}
.assess-banner h2 { color: var(--cream-text); margin-bottom: 8px; }
.assess-banner p { color: #c9c4b6; margin-bottom: 0; }

/* ---------- Assessment tool ---------- */
.assess-shell {
  max-width: 720px;
  margin: 0 auto;
}
.assess-progress {
  height: 2px;
  background: var(--steel-line);
  margin-bottom: 40px;
  position: relative;
}
.assess-progress-fill {
  height: 2px;
  background: var(--bronze);
  width: 10%;
  transition: width 0.3s ease;
}
.assess-card {
  border: 1px solid var(--steel-line);
  padding: 44px;
  background: var(--paper);
}
.assess-dim {
  color: var(--bronze);
  font-size: 0.85rem;
  margin-bottom: 14px;
}
.assess-q { font-family: var(--serif); font-size: 1.5rem; margin-bottom: 30px; }
.scale {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: nowrap;
}
.scale button {
  flex: 1;
  min-width: 0;
  padding: 16px 4px;
  border: 1px solid var(--steel-line);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 0.95rem;
  cursor: pointer;
  border-radius: 2px;
  transition: all 0.15s ease;
}
@media (max-width: 480px) {
  .assess-q { font-size: 1.2rem; }
  .scale button { padding: 12px 2px; font-size: 0.88rem; }
}
.scale button:hover { border-color: var(--bronze); }
.scale button.selected { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.scale-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--steel);
  margin-top: 8px;
}
.assess-nav { display: flex; justify-content: space-between; margin-top: 30px; }
.assess-nav button:disabled { opacity: 0.35; cursor: not-allowed; }

.result-dim { margin-bottom: 26px; }
.result-dim-head { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 0.95rem; }
.result-bar-track { height: 8px; background: var(--steel-line); border-radius: 4px; overflow: hidden; }
.result-bar-fill { height: 100%; background: var(--bronze); border-radius: 4px; transition: width 0.6s ease; }
.result-note { background: var(--parchment); padding: 26px 28px; border-left: 3px solid var(--bronze); margin-top: 32px; font-size: 1rem; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 64px;
}
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-detail { margin-bottom: 22px; }
.contact-detail .label { color: var(--steel); font-size: 0.85rem; display: block; margin-bottom: 4px; }
.contact-detail a { text-decoration: none; font-size: 1.05rem; }
.contact-detail a:hover { color: var(--bronze); }

form.enquiry { display: flex; flex-direction: column; gap: 18px; }
form.enquiry label { font-size: 0.88rem; color: var(--graphite); margin-bottom: 6px; display: block; }
form.enquiry input, form.enquiry select, form.enquiry textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--steel-line);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 0.98rem;
  border-radius: 2px;
}
form.enquiry input:focus, form.enquiry select:focus, form.enquiry textarea:focus {
  outline: none;
  border-color: var(--bronze);
}
form.enquiry textarea { resize: vertical; min-height: 120px; }
.form-status { font-size: 0.92rem; margin-top: 4px; }

/* ---------- Footer ---------- */
footer.site {
  background: var(--ink);
  color: #a19d90;
  padding: 56px 0 32px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.foot-word { font-family: var(--serif); font-size: 1.3rem; color: var(--cream-text); margin-bottom: 12px; }
.foot-col h4 { color: var(--cream-text); font-size: 0.88rem; margin-bottom: 14px; }
.foot-col ul { list-style: none; padding: 0; margin: 0; }
.foot-col li { margin-bottom: 10px; }
.foot-col a { text-decoration: none; color: #a19d90; font-size: 0.95rem; }
.foot-col a:hover { color: var(--bronze-light); }
.foot-bottom {
  border-top: 1px solid var(--steel-line-light);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 10px;
}
@media (max-width: 700px) { .foot-grid { grid-template-columns: 1fr; } }

/* ---------- Reveal on scroll (single, restrained) ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Page banner (for interior pages) */
.page-banner { background: var(--ink); color: var(--cream-text); padding: 70px 0 60px; }
.page-banner h1 { color: var(--cream-text); }
.page-banner p { color: #c9c4b6; max-width: 60ch; margin-top: 16px; }

:focus-visible { outline: 2px solid var(--bronze); outline-offset: 2px; }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: inherit;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.icon-link svg { width: 18px; height: 18px; }
a.icon-link.bordered {
  border: 1px solid var(--steel-line);
  border-radius: 50%;
}
a.icon-link.bordered:hover { color: var(--bronze); border-color: var(--bronze); }
.foot-col a.icon-link { border: 1px solid var(--steel-line-light); border-radius: 50%; color: var(--cream-text); }
.foot-col a.icon-link:hover { color: var(--bronze-light); border-color: var(--bronze-light); }

/* ---------- Request modal (toolkits) ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(14, 14, 17, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 24px;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: var(--paper);
  max-width: 460px;
  width: 100%;
  padding: 40px;
  position: relative;
  border-radius: 2px;
}
.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--graphite);
  line-height: 1;
  padding: 6px;
}
.modal-close:hover { color: var(--bronze); }
.modal-box h3 { margin-bottom: 8px; }
.modal-box .modal-sub { color: var(--graphite); font-size: 0.95rem; margin-bottom: 24px; text-align: left; }
.modal-box form.enquiry { gap: 14px; }
.modal-success { display: none; text-align: center; padding: 20px 0; }
.modal-success.show { display: block; }
.modal-success h3 { margin-bottom: 10px; }
