/* ---------------------------------------------------------------
   Open Fraud Detection Methodology: homepage styles.
   Editorial / institutional tone: restrained palette, generous
   whitespace, serif headings over a plain sans body. Two brand
   colors: purple (--accent) as the primary interactive color, gold
   (--accent-2) as a secondary accent used sparingly for emphasis.
--------------------------------------------------------------- */

:root {
  --ink: #14171c;
  --ink-soft: #3a4048;
  --paper: #fbfaf7;
  --paper-alt: #f1efe8;
  --line: #dcd8cd;
  --accent: #5b2a86;
  --accent-strong: #431f61;
  --accent-tint: #efe6f7;
  --accent-2: #d6a400;
  --accent-2-strong: #8a6300;
  --accent-2-tint: #fbf0d6;
  --on-accent: #fff;

  --brand-purple: #4a1f73;
  --brand-purple-soft: #f1e9f8;
  --on-brand-purple: #fdf9ff;
  --brand-yellow: #f0b400;
  --brand-yellow-strong: #d6a400;
  --on-brand-yellow: #241238;

  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;

  --wrap-max: 1140px;
  --wrap-narrow-max: 760px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ece9e2;
    --ink-soft: #b9b6ac;
    --paper: #14161a;
    --paper-alt: #1b1e23;
    --line: #33363c;
    --accent: #c9a0f5;
    --accent-strong: #dfc4fb;
    --accent-tint: #2a1f38;
    --accent-2: #e8c34a;
    --accent-2-strong: #f2d98a;
    --accent-2-tint: #332812;
    --on-accent: #2a1338;
    --brand-purple-soft: #241a30;
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

h1, h2, h3 {
  font-family: var(--font-serif);
  color: var(--ink);
  line-height: 1.2;
  font-weight: 600;
  margin: 0 0 0.6em;
}

p { margin: 0 0 1.1em; color: var(--ink-soft); text-align: justify; text-align-last: left; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  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;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--on-accent);
  padding: 0.75em 1.25em;
  z-index: 100;
  border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; }

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

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--brand-purple) 94%, transparent);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 3px solid var(--brand-yellow);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--on-brand-purple);
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: 0.01em;
}

.brand-mark {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  background: var(--brand-yellow);
  border: 2px solid var(--on-brand-purple);
  box-sizing: border-box;
  flex: none;
}

.primary-nav {
  display: flex;
  gap: 28px;
}

.primary-nav a {
  color: var(--on-brand-purple);
  opacity: 0.85;
  text-decoration: none;
  font-size: 15px;
}
.primary-nav a:hover { color: var(--brand-yellow); opacity: 1; }

/* Mobile nav: <details>/<summary> disclosure, works with no JS */
.nav-disclosure { display: none; }
.nav-disclosure summary {
  list-style: none;
  cursor: pointer;
  border: 1px solid var(--on-brand-purple);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 14px;
  color: var(--on-brand-purple);
}
.nav-disclosure summary::-webkit-details-marker { display: none; }
.nav-disclosure[open] summary { border-color: var(--brand-yellow); color: var(--brand-yellow); }
.nav-disclosure .mobile-nav-panel {
  position: fixed;
  left: 0; right: 0;
  top: 64px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  padding: 8px 24px 16px;
  z-index: 60;
}
.nav-disclosure .mobile-nav-panel a {
  display: block;
  padding: 10px 0;
  color: var(--ink-soft);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}
.nav-disclosure .mobile-nav-panel a:last-child { border-bottom: 0; }

/* ---------- Hero ---------- */

.hero {
  padding: 96px 0 72px;
  background: var(--brand-purple);
  border-bottom: 4px solid var(--brand-yellow);
}

.hero-grid {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 56px;
}

.hero-content {
  flex: 1 1 560px;
  min-width: 0;
}

.hero-photo {
  flex: 0 0 auto;
  width: 280px;
}

.hero-photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 3px solid var(--brand-yellow);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
}

.hero h1 {
  color: var(--on-brand-purple);
  font-size: clamp(2rem, 1.4rem + 2.4vw, 3.1rem);
  max-width: 15ch;
  letter-spacing: -0.01em;
}

.hero-lede {
  max-width: 62ch;
  font-size: 1.15rem;
  color: var(--on-brand-purple);
  opacity: 0.88;
}

.hero-tag {
  font-weight: 600;
  color: var(--brand-yellow);
  letter-spacing: 0.02em;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  padding: 12px 22px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-primary {
  background: var(--brand-yellow);
  color: var(--on-brand-yellow);
}
.btn-primary:hover { background: var(--brand-yellow-strong); }

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--accent);
  border-width: 2px;
}
.btn-secondary:hover { background: var(--accent); color: var(--on-accent); }

.btn-ghost {
  background: transparent;
  color: var(--ink-soft);
}
.btn-ghost:hover { color: var(--accent); }

.hero .btn-secondary {
  color: var(--on-brand-purple);
  border-color: var(--on-brand-purple);
}
.hero .btn-secondary:hover {
  background: var(--on-brand-purple);
  color: var(--brand-purple);
}
.hero .btn-ghost { color: var(--on-brand-purple); }
.hero .btn-ghost:hover { color: var(--brand-yellow); }

/* ---------- Sections ---------- */

.section {
  padding: 72px 0;
  border-bottom: 1px solid var(--line);
}
.section-alt { background: var(--brand-purple-soft); }

.section-kicker {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1em;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--brand-yellow);
  display: inline-block;
}

.section-lead {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: var(--ink);
  max-width: 34ch;
  margin-bottom: 0.9em;
}

.section p { max-width: 68ch; }

/* ---------- Work / cards ---------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  margin-top: 12px;
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 28px 26px 24px;
  display: flex;
  flex-direction: column;
}

.section-alt .card,
.card {
  background: var(--paper);
}

.card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.55em;
}

.card p { font-size: 0.98rem; }

.card-audience {
  font-size: 0.88rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: auto;
}

.card-link {
  display: inline-block;
  margin-top: 16px;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
}
.card-link:hover { color: var(--accent-strong); }

/* ---------- Objectives ---------- */

.objectives-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 32px 40px;
}

.objectives-list h3 {
  font-size: 1.05rem;
  font-family: var(--font-sans);
  font-weight: 700;
  color: var(--accent-strong);
}

.objectives-list p {
  font-size: 0.98rem;
  max-width: 46ch;
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 40px 0;
  background: var(--brand-purple);
  border-top: 3px solid var(--brand-yellow);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: center;
}

.footer-nav a {
  color: var(--on-brand-purple);
  opacity: 0.85;
  text-decoration: none;
  font-size: 14px;
}
.footer-nav a:hover { color: var(--brand-yellow); opacity: 1; }

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .hero-grid { flex-direction: column; align-items: flex-start; gap: 32px; }
  .hero-photo { width: 200px; align-self: center; }
}

@media (max-width: 760px) {
  .primary-nav { display: none; }
  .nav-disclosure { display: block; position: relative; }

  .hero { padding: 56px 0 48px; }
  .section { padding: 48px 0; }
}
