/* ==========================================================================
   Anyango Onani & Associates Advocates— Design System
   Source of truth: Design.md — Profile A: Heritage Dark Mode
   ========================================================================== */

:root {
  --bg: #1b2a47;
  --bg-rgb: 27, 42, 71;
  --surface: #3d3935;
  --surface-hover: #4a443d;
  --surface-2: #332f2b;
  --border: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.2);
  --text-1: #f9fafb;
  --text-2: #aeb9cc;
  --accent: #d4af37;
  --accent-dim: rgba(212, 175, 55, 0.14);
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --container: 1200px;

  /* Constant across both themes — used only by full-bleed photo sections
     (hero, cta-photo) so they stay legible regardless of site theme */
  --photo-scrim-rgb: 19, 27, 46;
  --photo-text: #f9fafb;
  --photo-text-muted: #c7cedc;
}

/* ---------- Judicial Light Mode (Design.md Profile B) ---------- */
[data-theme="light"] {
  --bg: #fbfbfa;
  --bg-rgb: 251, 251, 250;
  --surface: #ffffff;
  --surface-hover: #f5f4f1;
  --surface-2: #f3f2ef;
  --border: #e7e5e4;
  --border-strong: #d6d3d1;
  --text-1: #1c1917;
  --text-2: #57534e;
  --accent: #1e3a8a;
  --accent-dim: rgba(30, 58, 138, 0.08);
}
[data-theme="light"] .btn-primary {
  color: #ffffff;
}
[data-theme="light"] .nav-logo span {
  color: var(--accent);
}
[data-theme="light"] .map-container iframe {
  filter: none;
}

body,
.navbar,
.footer,
.card,
.testimonial-card,
.publication-card,
.article-card,
.attorney-card,
.category-card,
.form-group input,
.form-group select,
.form-group textarea,
.nav-link,
.btn,
.link-underline {
  transition:
    background-color 0.35s ease,
    color 0.35s ease,
    border-color 0.35s ease;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-1);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
.serif {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.01em;
  margin: 0;
  color: var(--text-1);
}

p {
  margin: 0;
  color: var(--text-2);
}
a {
  color: inherit;
  text-decoration: none;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}
ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
img {
  max-width: 100%;
  display: block;
}
button {
  font-family: inherit;
  cursor: pointer;
}

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

/* ---------- Type utilities ---------- */
.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  color: var(--accent);
}

.section-heading {
  font-size: clamp(2rem, 3.4vw, 2.75rem);
  line-height: 1.15;
  margin-top: 1.25rem;
}

.section-lede {
  color: var(--text-2);
  font-size: 1.05rem;
  line-height: 1.75;
  max-width: 42rem;
  margin-top: 1.5rem;
}

.section-header {
  max-width: 42rem;
  margin-bottom: 4.5rem;
}

/* ---------- Hairline rule (signature element) ---------- */
.hr-line {
  height: 1px;
  background: var(--border);
  overflow: hidden;
  margin-top: 2.5rem;
  max-width: 8rem;
}
.hr-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 1.1s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.in-view .hr-fill {
  width: 100%;
}

hr.divider {
  border: none;
  height: 1px;
  background: var(--border);
  margin: 0;
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.4s ease-out,
    transform 0.4s ease-out;
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}
.reveal.d1 {
  transition-delay: 0.03s;
}
.reveal.d2 {
  transition-delay: 0.06s;
}
.reveal.d3 {
  transition-delay: 0.09s;
}
.reveal.d4 {
  transition-delay: 0.12s;
}
.reveal.d5 {
  transition-delay: 0.15s;
}
.reveal.d6 {
  transition-delay: 0.18s;
}
.reveal.d7 {
  transition-delay: 0.21s;
}
.reveal.d8 {
  transition-delay: 0.24s;
}
.reveal.d9 {
  transition-delay: 0.27s;
}
.reveal.d10 {
  transition-delay: 0.3s;
}
.reveal.d11 {
  transition-delay: 0.33s;
}
.reveal.d12 {
  transition-delay: 0.36s;
}
.reveal.d13 {
  transition-delay: 0.39s;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1.05rem 2.2rem;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  transition: all 0.35s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: var(--bg);
}
.btn-primary:hover {
  letter-spacing: 0.26em;
  background: #e3c05a;
}

.btn-outline {
  border-color: var(--border-strong);
  color: var(--text-1);
  background: transparent;
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.link-underline {
  position: relative;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition:
    border-color 0.3s ease,
    color 0.3s ease;
}
.link-underline:hover {
  border-color: currentColor;
  color: var(--accent);
}

/* ---------- Navbar ---------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(11, 15, 25, 0.82);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 1.15rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo a {
  display: flex;
  flex-direction: column;
  line-height: 1;
}
.nav-logo h1 {
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  margin: 0;
}
.nav-logo span {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--accent);
  margin-top: 0.4rem;
}
.nav-menu {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}
.nav-link {
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-2);
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  transition:
    color 0.3s ease,
    border-color 0.3s ease;
}
.nav-link:hover,
.nav-link.active {
  color: var(--text-1);
  border-color: var(--accent);
}
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
}
.nav-toggle .bar {
  width: 22px;
  height: 1px;
  background: var(--text-1);
  display: block;
}

/* ---------- Hero ---------- */
.hero-fullbleed {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: center;
  background-image:
    linear-gradient(
      to bottom,
      rgba(var(--bg-rgb), 0) 78%,
      rgba(var(--bg-rgb), 1) 100%
    ),
    linear-gradient(
      100deg,
      rgba(var(--photo-scrim-rgb), 0.86) 0%,
      rgba(var(--photo-scrim-rgb), 0.68) 32%,
      rgba(var(--photo-scrim-rgb), 0.32) 62%,
      rgba(var(--photo-scrim-rgb), 0.12) 100%
    ),
    url("../images/hero-bg.png");
  background-position: 62% center;
  background-size: cover;
  border-bottom: 1px solid var(--border);
}
.hero-fullbleed .container {
  padding-top: 6rem;
  padding-bottom: 6rem;
}
.hero-fullbleed .eyebrow,
.hero-fullbleed .hero-title,
.hero-fullbleed .hero-subtitle {
  text-shadow: 0 2px 18px rgba(8, 12, 22, 0.55);
}
.hero-fullbleed .eyebrow {
  color: var(--accent);
}
.hero-fullbleed .hero-title {
  color: var(--photo-text);
}
.hero-fullbleed .hero-subtitle {
  color: var(--photo-text-muted);
}
.hero-fullbleed .hero-buttons a.link-underline {
  color: var(--photo-text) !important;
}
.hero-fullbleed .hero-title {
  max-width: 40rem;
}
.hero-fullbleed .hero-subtitle {
  max-width: 32rem;
}
.privacy-hero {
  background-image:
    linear-gradient(
      to bottom,
      rgba(var(--bg-rgb), 0.3) 50%,
      rgba(var(--bg-rgb), 1) 100%
    ),
    linear-gradient(
      100deg,
      rgba(8, 12, 22, 0.96) 0%,
      rgba(8, 12, 22, 0.84) 52%,
      rgba(8, 12, 22, 0.66) 100%
    ),
    url("../images/hero-bg.png");
}
.btn-icon {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}
.btn-icon i {
  font-size: 0.85rem;
}

@media (max-width: 760px) {
  .hero-fullbleed {
    min-height: 70vh;
  }
  .hero-fullbleed .container {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }
}
.hero-title {
  font-size: clamp(2.6rem, 5.4vw, 4.6rem);
  line-height: 1.06;
  max-width: 46rem;
}
.hero-subtitle {
  margin-top: 2rem;
  max-width: 34rem;
  font-size: 1.1rem;
  line-height: 1.75;
  color: var(--text-2);
}
.hero-buttons {
  display: flex;
  gap: 2rem;
  align-items: center;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.page-header {
  padding: 7.5rem 0 4.5rem;
  border-bottom: 1px solid var(--border);
}
.page-header .eyebrow {
  margin-bottom: 1rem;
}
.page-header h1 {
  font-size: clamp(2.4rem, 4.4vw, 3.6rem);
}
.page-header p {
  margin-top: 1.25rem;
  max-width: 36rem;
  font-size: 1.05rem;
  color: var(--text-2);
}

/* ---------- Sections ---------- */
section {
  padding: 6.5rem 0;
}
section.tight {
  padding: 4.5rem 0;
}
.section-border-top {
  border-top: 1px solid var(--border);
}

/* ---------- Cards ---------- */
.card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2.75rem 2.25rem;
  transition:
    border-color 0.4s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.4s ease;
}
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.card:hover {
  border-color: var(--border-strong);
  background: var(--surface-hover);
  transform: translateY(-6px);
}
.card:hover::before {
  width: 100%;
}
.card-icon {
  color: var(--accent);
  font-size: 1.7rem;
  margin-bottom: 1.75rem;
  display: inline-block;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.card:hover .card-icon {
  transform: translateY(-3px) scale(1.08);
}
.card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.9rem;
}
.card p {
  font-size: 0.92rem;
  line-height: 1.7;
}

/* Asymmetric grid utilities */
.grid-12 {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
}
.col-3 {
  grid-column: span 3;
}
.col-4 {
  grid-column: span 4;
}
.col-5 {
  grid-column: span 5;
}
.col-6 {
  grid-column: span 6;
}
.col-7 {
  grid-column: span 7;
}
.col-8 {
  grid-column: span 8;
}
.col-12 {
  grid-column: span 12;
}
.card-lg {
  padding: 3.25rem 2.75rem;
  min-height: 300px;
}
.card-lg h3 {
  font-size: 1.55rem;
}
.card-lg p {
  font-size: 0.98rem;
  max-width: 30rem;
}

.card-arrow {
  opacity: 0;
  transform: translate(-4px, 4px);
  transition: all 0.3s ease;
  color: var(--text-2);
  float: right;
}
.card:hover .card-arrow {
  opacity: 1;
  transform: translate(0, 0);
  color: var(--accent);
}

/* ---------- Stats ---------- */
.stat-number {
  font-family: var(--serif);
  font-size: 3.25rem;
  color: var(--accent);
}
.stat-label {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--text-2);
}

/* ---------- Testimonials ---------- */
.testimonial-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2.75rem;
  transition:
    border-color 0.4s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.4s ease;
}
.testimonial-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.testimonial-card:hover {
  border-color: var(--border-strong);
  background: var(--surface-hover);
  transform: translateY(-6px);
}
.testimonial-card:hover::before {
  width: 100%;
}
.testimonial-card .quote-icon {
  color: var(--accent);
  font-size: 1.4rem;
  opacity: 0.6;
  margin-bottom: 1.25rem;
}
.testimonial-text {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-1);
  font-style: italic;
}
.testimonial-author {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}
.testimonial-author h4 {
  font-size: 0.95rem;
  font-family: var(--sans);
  font-weight: 600;
}
.testimonial-author p {
  font-size: 0.82rem;
  margin-top: 0.2rem;
}
.case-reference {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  display: block;
  margin-top: 0.4rem;
}

/* ---------- Value / Achievement items ---------- */
.value-icon,
.achievement-icon {
  color: var(--accent);
  font-size: 1.6rem;
  margin-bottom: 1.5rem;
}

/* ---------- People directory ---------- */
.attorney-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition:
    border-color 0.4s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.4s ease;
}
.attorney-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 2;
}
.attorney-card:hover {
  border-color: var(--border-strong);
  background: var(--surface-hover);
  transform: translateY(-6px);
}
.attorney-card:hover::before {
  width: 100%;
}
.attorney-photo-wrap {
  aspect-ratio: 4/5;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.attorney-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.attorney-card:hover .attorney-photo-wrap img {
  transform: scale(1.05);
}
.attorney-card-body {
  padding: 1.75rem 1.75rem 2rem;
}
.attorney-card-body h3 {
  font-size: 1.2rem;
}
.attorney-card-body .member-title {
  margin-top: 0.4rem;
}
.attorney-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
}
.attorney-tags .tag {
  color: var(--text-2);
  border-color: var(--border-strong);
}
.attorney-card-body .link-underline {
  display: inline-block;
  margin-top: 1.75rem;
}
.directory-search {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  border-bottom: 1px solid var(--border-strong);
  padding: 0.5rem 0;
  max-width: 26rem;
  margin-bottom: 3rem;
  color: var(--text-2);
}
.directory-search input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-1);
  font-family: var(--sans);
  font-size: 0.95rem;
  padding: 0.4rem 0;
}
.profile-back {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 3rem;
}
.member-photo,
.story-photo,
.achievements-photo,
.about-preview-photo,
.hero-photo,
.publication-detail-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 1px solid var(--border);
}
.member-credentials p,
.member-credentials span {
  font-size: 0.85rem;
  color: var(--text-2);
  display: block;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
}
.member-credentials span i,
.member-credentials p i {
  color: var(--accent);
  margin-right: 0.6rem;
  width: 1rem;
}
.member-title {
  color: var(--accent);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 0.5rem;
}
.member-specialty {
  color: var(--text-2);
  font-size: 0.9rem;
  margin-top: 0.3rem;
  font-style: italic;
}
.member-description {
  margin-top: 1.5rem;
  max-width: 38rem;
  line-height: 1.8;
}
.member-social {
  display: flex;
  gap: 1.25rem;
  margin-top: 1.75rem;
}
.member-social a {
  color: var(--text-2);
  transition: color 0.3s ease;
}
.member-social a:hover {
  color: var(--accent);
}

/* ---------- Forms ---------- */
.form-group {
  margin-bottom: 1.75rem;
}
.form-notice {
  margin-top: 1.25rem;
  font-size: 0.82rem;
  line-height: 1.6;
}
.form-notice a {
  color: var(--accent);
  text-decoration: underline;
}
.form-group label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-2);
  margin-bottom: 0.6rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-strong);
  color: var(--text-1);
  font-family: var(--sans);
  font-size: 1rem;
  padding: 0.7rem 0.1rem;
  outline: none;
  transition: border-color 0.3s ease;
}
.form-group select option {
  background: var(--surface);
  color: var(--text-1);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}
.form-group textarea {
  resize: vertical;
}
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.85rem;
  color: var(--text-2);
  text-transform: none;
  letter-spacing: 0;
}
.checkbox-label input {
  width: auto;
}

.newsletter-form {
  display: flex;
  gap: 1rem;
  max-width: 32rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}
.newsletter-form input {
  flex: 1;
  min-width: 220px;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border-strong);
  color: var(--text-1);
  padding: 0.9rem 0.2rem;
  font-size: 1rem;
  outline: none;
}
.newsletter-form input:focus {
  border-color: var(--accent);
}

/* ---------- FAQ ---------- */
.faq-item {
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
}
.faq-item h3 {
  font-size: 1.05rem;
  font-family: var(--sans);
  font-weight: 600;
  margin-bottom: 0.75rem;
}
.faq-item p {
  font-size: 0.92rem;
}

/* ---------- Contact ---------- */
.contact-intro-list {
  margin-top: 2.5rem;
}
.contact-item {
  display: flex;
  gap: 1.25rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
}
.contact-item.is-last {
  border-bottom: none;
}
.contact-icon {
  color: var(--accent);
  font-size: 1.1rem;
  padding-top: 0.2rem;
  width: 1.5rem;
}
.contact-text h3 {
  font-size: 0.95rem;
  font-family: var(--sans);
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.contact-text p {
  font-size: 0.9rem;
}
.contact-panel-title {
  font-size: 1.75rem;
}
.contact-form {
  margin-top: 2.5rem;
}
.contact-submit {
  min-width: 11rem;
}
.contact-note {
  margin-top: 0.75rem;
}
.contact-qa-section {
  background: var(--surface);
}
.contact-qa-stack {
  max-width: 48rem;
}
.faq-item.is-last {
  border-bottom: none;
}
.map-container iframe {
  border: 1px solid var(--border);
  filter: grayscale(1) invert(0.92) contrast(0.9);
  width: 100%;
}

/* ---------- Publications ---------- */
.publication-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition:
    border-color 0.4s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.4s ease;
}
.publication-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 2;
}
.publication-card:hover {
  border-color: var(--border-strong);
  background: var(--surface-hover);
  transform: translateY(-6px);
}
.publication-card:hover::before {
  width: 100%;
}
.publication-card:hover .publication-image img {
  transform: scale(1.05);
  opacity: 1;
}
.publication-image {
  aspect-ratio: 16/10;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.publication-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.88;
  transition:
    transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
    opacity 0.4s ease;
}
.publication-content {
  padding: 2rem;
}
.publication-content h3 {
  font-size: 1.1rem;
  line-height: 1.4;
  margin-bottom: 1rem;
}
.publication-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
  margin-bottom: 1.25rem;
}
.publication-excerpt {
  font-size: 0.88rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}
.publication-tags {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 1.75rem;
}
.tag {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  border: 1px solid var(--accent-dim);
  padding: 0.3rem 0.75rem;
}

.category-card {
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 2rem;
  transition:
    padding-left 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.4s ease;
}
.category-card:hover {
  padding-left: 1rem;
  border-color: var(--border-strong);
}
.category-card .category-icon {
  color: var(--accent);
  font-size: 1.5rem;
  flex-shrink: 0;
  width: 2rem;
  padding-top: 0.3rem;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.category-card:hover .category-icon {
  transform: scale(1.15);
}
.category-card:hover h3 {
  color: var(--accent);
}
.category-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.6rem;
  transition: color 0.3s ease;
}
.category-card p {
  font-size: 0.9rem;
  margin-bottom: 1rem;
}
.article-count a {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  border-bottom: 1px solid var(--accent-dim);
  padding-bottom: 3px;
}
.article-count a:hover {
  border-color: var(--accent);
}

.featured-publication .container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: center;
}
.publication-detail-image {
  aspect-ratio: 4/3;
}

/* ---------- Process steps ---------- */
.process-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem;
}
.step-number {
  font-family: var(--serif);
  font-size: 1.6rem;
  color: var(--accent);
  border: 1px solid var(--border-strong);
  width: 3.2rem;
  height: 3.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.75rem;
}
.process-step h3 {
  font-size: 1.05rem;
  margin-bottom: 0.75rem;
}
.process-step p {
  font-size: 0.88rem;
}

/* ---------- Article / category pages ---------- */
.category-header-band {
  padding: 7.5rem 0 3rem;
  border-bottom: 1px solid var(--border);
}
.article-count-badge {
  display: inline-block;
  border: 1px solid var(--border-strong);
  color: var(--accent);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  padding: 0.25rem 0.85rem;
  margin-left: 0.75rem;
  vertical-align: middle;
  font-family: var(--sans);
  text-transform: uppercase;
}
.article-list {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.article-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 2.25rem;
  transition:
    border-color 0.4s ease,
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background-color 0.4s ease;
}
.article-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: var(--accent);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.article-card:hover {
  border-color: var(--border-strong);
  background: var(--surface-hover);
  transform: translateY(-4px);
}
.article-card:hover::before {
  width: 100%;
}
.article-title {
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--text-1);
  display: block;
}
.article-ref {
  display: block;
  margin-top: 0.6rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-2);
}
.read-btn {
  margin-top: 1.5rem;
  background: transparent;
  border: 1px solid var(--border-strong);
  color: var(--text-1);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 0.65rem 1.4rem;
  transition: all 0.3s ease;
}
.read-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.article-content[hidden] {
  display: none;
}
.article-content {
  margin-top: 1.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
}
.article-content h3 {
  font-size: 1.05rem;
  margin-bottom: 1rem;
}
.article-content p {
  font-size: 0.92rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
}
.source-attribution {
  background: var(--surface-2);
  border-left: 2px solid var(--accent);
  padding: 1.25rem 1.5rem;
  font-size: 0.82rem;
  color: var(--text-2);
  margin-top: 1.5rem;
}
.source-attribution a {
  color: var(--accent);
  border-bottom: 1px solid var(--accent-dim);
}
.back-link-row {
  text-align: center;
  margin-top: 3.5rem;
}

/* ---------- CTA band ---------- */
.cta {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
}
.cta-photo {
  background-image:
    linear-gradient(rgba(var(--bg-rgb), 0.93), rgba(var(--bg-rgb), 0.93)),
    url("../images/hero-bg.png");
  background-size: cover;
  background-position: center 30%;
}
.services-cta {
  background-image:
    linear-gradient(rgba(8, 12, 22, 0.91), rgba(8, 12, 22, 0.91)),
    url("../images/photo4.png");
  background-position: center;
}
.cta-content h2 {
  font-size: clamp(2rem, 3.2vw, 2.75rem);
}
.cta-content p {
  margin-top: 1.25rem;
  max-width: 32rem;
  margin-left: auto;
  margin-right: auto;
}
.cta-buttons {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

/* ---------- Footer ---------- */
.footer {
  padding: 5rem 0 0;
  border-top: 1px solid var(--border);
}
.footer-content {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 3rem;
  padding-bottom: 3.5rem;
}
.footer-section h3 {
  font-size: 1.15rem;
  margin-bottom: 1rem;
}
.footer-section h4 {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 1.5rem;
}
.footer-section p {
  font-size: 0.88rem;
  line-height: 1.8;
}
.footer-section ul li {
  margin-bottom: 0.85rem;
}
.footer-section ul li a {
  font-size: 0.88rem;
  color: var(--text-2);
  transition: color 0.3s ease;
}
.footer-section ul li a:hover {
  color: var(--accent);
}
.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}
.social-links a {
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-strong);
  color: var(--text-2);
  transition: all 0.3s ease;
}
.social-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.footer .contact-info p {
  border: none;
  padding: 0 0 0.85rem;
}
.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 1.75rem 0;
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-2);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-12 {
    grid-template-columns: 1fr;
  }
  .col-3,
  .col-4,
  .col-5,
  .col-6,
  .col-7,
  .col-8,
  .col-12 {
    grid-column: span 1;
  }
  .featured-publication .container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .process-steps {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-content {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 760px) {
  .nav-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
    gap: 1.25rem;
    display: none;
  }
  .nav-menu.open {
    display: flex;
  }
  .nav-toggle {
    display: flex;
  }
  .hero-buttons,
  .cta-buttons {
    flex-direction: column;
    align-items: flex-start;
  }
  .cta-buttons {
    align-items: center;
  }
  .process-steps {
    grid-template-columns: 1fr;
  }
  .footer-content {
    grid-template-columns: 1fr;
  }
  section {
    padding: 4.5rem 0;
  }
  .category-card {
    flex-direction: column;
    gap: 1rem;
  }
}
