/* Innocent Mbele — portfolio styles.
   Plain, flat portal style (same palette as SecOps Sentinel): Segoe UI, neutral greys,
   white surfaces with thin borders, square corners, one green for links and actions. */
:root {
  --ink: #201f1e;
  --ink-2: #323130;
  --muted: #605e5c;
  --faint: #8a8886;
  --line: #e1dfdd;
  --line-2: #c8c6c4;
  --bg: #faf9f8;
  --bg-2: #f3f2f1;
  --white: #ffffff;
  --green: #0e7a6d;
  --green-dark: #0b6359;
  --amber: #8a5300;
  --red: #c50f1f;
  --max: 1160px;
  --font: "Segoe UI", "Segoe UI Web (West European)", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: Consolas, "Cascadia Mono", ui-monospace, Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 64px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-dark); text-decoration: underline; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; font-weight: 600; color: var(--ink); }
h1 { font-size: 28px; }
h2 { font-size: 20px; }
h3 { font-size: 16px; }
p { margin: 0 0 1em; }

.container { width: min(100% - 2.5rem, var(--max)); margin-inline: auto; }
.visually-hidden {
  position: absolute !important; 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: 1rem; top: -3rem; z-index: 100; background: var(--white); color: var(--ink); padding: .4rem .8rem; border: 1px solid var(--line-2); }
.skip-link:focus { top: .5rem; }

/* Header */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 56px; gap: 1rem; }
.brand { color: var(--ink); font-weight: 600; font-size: 16px; }
.brand:hover { color: var(--ink); text-decoration: none; }
.nav-toggle { display: none; background: var(--white); border: 1px solid var(--line-2); color: var(--ink-2); border-radius: 2px; padding: .35rem .7rem; font: inherit; cursor: pointer; }
.site-nav ul { display: flex; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.site-nav a { display: block; padding: 16px 0 14px; color: var(--ink-2); border-bottom: 2px solid transparent; }
.site-nav a:hover { color: var(--green); text-decoration: none; }
.site-nav a[aria-current="page"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--green); }
@media (max-width: 640px) {
  .nav-toggle { display: inline-block; }
  .site-nav { position: absolute; top: 56px; left: 0; right: 0; z-index: 20; background: var(--white); border-bottom: 1px solid var(--line); display: none; }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 0 1.25rem; }
  .site-nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .site-nav li:last-child a { border-bottom: 0; }
  .site-nav a[aria-current="page"] { border-bottom-color: var(--line); box-shadow: inset 3px 0 0 var(--green); padding-left: 10px; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 38px; padding: 0 18px; border-radius: 2px; font: 600 14px/1 var(--font);
  border: 1px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--green); border-color: var(--green); color: #fff; }
.btn-primary:hover { background: var(--green-dark); border-color: var(--green-dark); color: #fff; }
.btn-secondary { background: var(--white); border-color: var(--faint); color: var(--ink-2); }
.btn-secondary:hover { background: var(--bg-2); border-color: var(--muted); color: var(--ink); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* Intro (home) */
.intro-grid { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.intro-grid > div { flex: 1; min-width: 0; }
.profile-photo { margin: 0; flex: none; overflow: hidden; border: 1px solid var(--line); background: var(--bg-2); }
.profile-photo img { width: 100%; height: 100%; object-fit: cover; }
.profile-links { margin: 16px 0 0; font-size: 14px; color: var(--muted); }
@media (max-width: 760px) {
  .intro-grid { flex-direction: column-reverse; align-items: flex-start; gap: 20px; }
  .profile-photo { max-width: 150px; }
}
.intro { background: var(--white); border-bottom: 1px solid var(--line); padding: 44px 0 40px; }
.intro h1 { font-size: 34px; margin-bottom: 4px; }
.intro .role { font-size: 18px; color: var(--ink-2); margin-bottom: 16px; }
.intro .tagline { color: var(--muted); margin-bottom: 18px; }
.intro .lead { max-width: 640px; color: var(--ink-2); font-size: 16px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

/* Home page action buttons: white with a thin coloured border and a coloured icon.
   Contact uses the site teal, GitHub charcoal and LinkedIn its own blue. */
.intro .actions .btn { min-height: 42px; border-radius: 4px; }
.btn-action {
  --c: var(--ink-2); --c-line: var(--line-2); --c-tint: var(--bg-2); --c-text: var(--ink);
  background: var(--white); border-color: var(--c-line); color: var(--ink-2); padding: 0 16px 0 14px;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn-action .btn-icon { flex: none; color: var(--c); }
.btn-action:hover, .btn-action:focus-visible { background: var(--c-tint); border-color: var(--c); color: var(--c-text); }
.btn-action:active { background: var(--c-line); }
.btn-contact { --c: var(--green); --c-line: #9ccbc4; --c-tint: #eef6f5; --c-text: var(--green-dark); }
.btn-github { --c: #24292f; --c-line: #b8bcc1; --c-tint: #f3f4f6; --c-text: #24292f; }
.btn-linkedin { --c: #0a66c2; --c-line: #a8c7e8; --c-tint: #eef4fb; --c-text: #084e96; }
@media (prefers-reduced-motion: reduce) { .btn-action { transition: none; } }
@media (max-width: 560px) {
  .intro .actions { display: grid; grid-template-columns: 1fr; gap: 8px; }
  .intro .actions .btn { width: 100%; }
}

/* Sections */
.section { padding: 32px 0; }
.section + .section { padding-top: 0; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .5rem 1rem; margin-bottom: 16px; }
.section-head h2 { margin: 0; }
.section-head p { color: var(--muted); margin: 4px 0 0; width: 100%; }

.areas { list-style: none; margin: 0; padding: 0; background: var(--white); border: 1px solid var(--line); }
.areas li + li { border-top: 1px solid var(--line); }
.areas a { display: flex; justify-content: space-between; gap: 1rem; padding: 12px 16px; color: var(--ink); }
.areas a:hover { background: var(--bg); text-decoration: none; color: var(--green); }
.areas span { color: var(--muted); white-space: nowrap; }

/* Project cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.card { background: var(--white); border: 1px solid var(--line); display: flex; flex-direction: column; }
.card:hover { border-color: var(--line-2); }
.card-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.card-media img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.card-cat { font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.card h3 { margin-bottom: 6px; }
.card h3 a { color: var(--ink); }
.card h3 a:hover { color: var(--green); }
.card p { color: var(--ink-2); font-size: 14px; margin-bottom: 10px; }
.card .tech { font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.card-links { margin-top: auto; display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 14px; padding-top: 10px; border-top: 1px solid var(--line); }
.state-note { color: var(--amber); }

/* Filters: plain tab row */
.filters { display: flex; flex-wrap: wrap; gap: 0; margin: 0 0 20px; padding: 0; list-style: none; border-bottom: 1px solid var(--line); }
.filter-btn {
  font: 14px/1 var(--font); cursor: pointer; background: none; border: 0; border-bottom: 2px solid transparent;
  margin-bottom: -1px; padding: 12px 14px 10px; color: var(--ink-2);
}
.filter-btn:hover { color: var(--green); }
.filter-btn[aria-pressed="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--green); }
.filter-btn .n { color: var(--faint); font-weight: 400; margin-left: 4px; }
.result-count { color: var(--muted); font-size: 13px; margin: -8px 0 14px; }
.card[hidden] { display: none; }
.repos { margin-top: 32px; }
.repos h3 { margin-bottom: 10px; }
.repos table { width: 100%; border-collapse: collapse; background: var(--white); border: 1px solid var(--line); font-size: 14px; }
.repos th, .repos td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.repos th { background: var(--bg-2); font-weight: 600; color: var(--ink-2); }
.repos td.num { text-align: right; white-space: nowrap; }

/* Page header */
.page-head { background: var(--white); border-bottom: 1px solid var(--line); padding: 24px 0 22px; }
.page-head h1 { margin-bottom: 6px; }
.page-head p { color: var(--ink-2); max-width: 760px; margin: 0; }
.breadcrumb { font-size: 13px; color: var(--muted); margin-bottom: 8px; }

/* Project detail */
.detail { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 32px; align-items: start; }
@media (max-width: 900px) { .detail { grid-template-columns: 1fr; } }
.detail section { margin-bottom: 28px; }
.detail section h2 { font-size: 18px; padding-bottom: 6px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.detail ul.list { padding-left: 1.15rem; margin: 0; }
.detail ul.list li { margin-bottom: 6px; }
.detail pre { background: var(--white); border: 1px solid var(--line); color: var(--ink-2); padding: 14px 16px; overflow-x: auto; font: 13px/1.45 var(--mono); }
.facts { background: var(--white); border: 1px solid var(--line); padding: 16px; }
.facts dl { margin: 0 0 14px; }
.facts dt { font-size: 12px; color: var(--muted); margin-top: 12px; }
.facts dt:first-child { margin-top: 0; }
.facts dd { margin: 2px 0 0; font-size: 14px; }
.facts .btn { width: 100%; margin-top: 8px; }
.small-note { font-size: 13px; color: var(--muted); }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; list-style: none; padding: 0; margin: 0; }
.gallery figure { margin: 0; background: var(--white); border: 1px solid var(--line); height: 100%; display: flex; flex-direction: column; }
.gallery button { all: unset; cursor: zoom-in; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg-2); border-bottom: 1px solid var(--line); }
.gallery button:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
.gallery button img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.gallery figcaption { padding: 10px 12px 12px; font-size: 13px; color: var(--muted); }
.gallery figcaption strong { display: block; color: var(--ink); font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.pager { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 16px; font-size: 14px; }
.pager a { max-width: 48%; }
.pager span { display: block; font-size: 12px; color: var(--muted); }

/* Lightbox */
.lightbox { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.lightbox::backdrop { background: rgba(32, 31, 30, .88); }
.lightbox-inner { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 3.25rem 1rem 1rem; gap: .6rem; }
.lightbox img { max-width: min(1600px, 96vw); max-height: calc(100vh - 8.5rem); width: auto; height: auto; background: #fff; }
.lightbox p { color: #f3f2f1; margin: 0; text-align: center; max-width: 900px; font-size: 14px; }
.lb-btn { position: fixed; background: #fff; color: var(--ink); border: 1px solid var(--line-2); width: 40px; height: 40px; border-radius: 2px; font-size: 22px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.lb-btn:hover { background: var(--bg-2); }
.lb-close { top: .75rem; right: .75rem; }
.lb-prev { left: .75rem; top: 50%; }
.lb-next { right: .75rem; top: 50%; }
@media (max-width: 640px) { .lb-prev, .lb-next { top: auto; bottom: .75rem; } }

/* Contact: sized to fit one screen */
.contact-section { background: var(--white); border-top: 1px solid var(--line); padding: 32px 0 36px; }
.contact-section h2 { margin-bottom: 4px; }
.contact-section .intro-text { color: var(--ink-2); margin-bottom: 14px; }
.contact-section .form-card { background: var(--bg); }
.contact-page { padding: 20px 0 24px; }
.contact-page h1 { margin-bottom: 4px; }
.contact-page .intro-text { color: var(--ink-2); margin-bottom: 14px; }
.form-card { background: var(--white); border: 1px solid var(--line); padding: 18px 20px; max-width: 720px; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 600px) { .row-2 { grid-template-columns: 1fr; } }
.field { margin-bottom: 10px; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; color: var(--ink-2); }
.field .req { color: var(--red); font-weight: 400; }
.field input, .field textarea {
  width: 100%; font: 14px/1.4 var(--font); color: var(--ink); background: var(--white);
  border: 1px solid var(--faint); border-radius: 2px; padding: 7px 9px;
}
.field textarea { height: 120px; resize: vertical; }
.field input:hover, .field textarea:hover { border-color: var(--ink-2); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); }
.field [aria-invalid="true"] { border-color: var(--red); }
.field .error { color: var(--red); font-size: 12px; margin: 3px 0 0; }
.field .error:empty { display: none; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 4px; }
.form-foot .small-note { margin: 0; }
.form-status { margin-top: 12px; padding: 8px 12px; font-size: 14px; display: none; border: 1px solid; border-left-width: 3px; }
.form-status.show { display: block; }
.form-status.success { background: #f1faf1; border-color: #107c10; color: #0e5a0e; }
.form-status.error { background: #fdf3f4; border-color: var(--red); color: #a80000; }
.form-status.pending { background: var(--bg); border-color: var(--line-2); color: var(--ink-2); }
.spinner { width: 14px; height: 14px; border: 2px solid rgba(255, 255, 255, .5); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; display: none; }
.is-sending .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Footer */
.site-footer { background: var(--white); border-top: 1px solid var(--line); color: var(--muted); padding: 18px 0; font-size: 13px; margin-top: 24px; }
.site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1.5rem; }
.site-footer p { margin: 0; max-width: 720px; }
.site-footer ul { list-style: none; display: flex; gap: 1.25rem; margin: 0; padding: 0; }

/* 404 */
.notfound { padding: 64px 0; }
.notfound .actions { margin-top: 18px; }
