/* =========================================================
   NENI PROBLEM - site styles
   Colours and spacing are set as variables below; change
   them here to restyle the whole site.
   ========================================================= */
:root {
  --bg: #ffffff;
  --bg-alt: #f4f6fa;
  --ink: #0b1324;
  --text: #2a3346;
  --muted: #5d6779;
  --line: #e2e6ee;
  --accent: #10b981;
  --accent-ink: #047857;
  --accent-soft: #d1fae5;
  --dark: #0b1324;
  --dark-2: #131d33;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(11, 19, 36, .05), 0 8px 24px rgba(11, 19, 36, .06);
  --container: 1120px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
}
img, svg { display: block; max-width: 100%; }
a { color: var(--accent-ink); }
h1, h2, h3 { color: var(--ink); line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.2rem, 5.5vw, 3.8rem); letter-spacing: -.025em; }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); letter-spacing: -.02em; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-weight: 800; letter-spacing: .04em; }
.logo-mark { width: 32px; height: 32px; }
.logo-mark rect { fill: var(--ink); }
.logo-mark path { stroke: var(--accent); }
.nav { display: flex; gap: 6px; margin-left: auto; align-items: center; }
.nav a { color: var(--text); text-decoration: none; font-weight: 500; font-size: .95rem; padding: 8px 12px; border-radius: 8px; }
.nav a:hover, .nav a.active { color: var(--ink); background: var(--bg-alt); }
.nav a.nav-cta { background: var(--ink); color: #fff; }
.nav a.nav-cta:hover { background: var(--dark-2); }

.lang-switch { display: flex; gap: 4px; }
.lang-switch button {
  padding: 5px; border: 1px solid transparent; border-radius: 6px; background: none; cursor: pointer;
  opacity: .5; transition: opacity .15s, border-color .15s;
}
.lang-switch button img { border-radius: 2px; box-shadow: 0 0 0 1px rgba(0,0,0,.08); }
.lang-switch button:hover { opacity: .85; }
.lang-switch button[aria-pressed="true"] { opacity: 1; border-color: var(--line); background: var(--bg-alt); }

.menu-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; }
.menu-toggle .bar { display: block; width: 22px; height: 2px; margin: 5px 0; background: var(--ink); border-radius: 2px; transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] .bar:nth-of-type(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] .bar:nth-of-type(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] .bar:nth-of-type(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 1rem; text-decoration: none;
  padding: 13px 22px; border-radius: 10px; border: 1px solid transparent; cursor: pointer;
  transition: transform .15s, background .15s, border-color .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: #04261a; }
.btn-primary:hover { background: #34d399; }
.btn-primary:disabled { opacity: .6; cursor: wait; transform: none; }
.btn-ghost { color: #fff; border-color: rgba(255,255,255,.25); }
.btn-ghost:hover { border-color: rgba(255,255,255,.6); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(800px 400px at 85% 10%, rgba(16,185,129,.18), transparent 60%),
    radial-gradient(600px 400px at 0% 100%, rgba(59,130,246,.15), transparent 60%),
    var(--dark);
  color: #c9d2e3;
  padding: 96px 0 104px;
}
.hero h1 { color: #fff; max-width: 14ch; }
.hero .accent { color: var(--accent); }
.hero .eyebrow { color: var(--accent); }
.hero-inner { position: relative; z-index: 1; }
.lead { font-size: 1.2rem; max-width: 58ch; color: #c9d2e3; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 32px 0 36px; }
.hero-badges { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-badges li {
  font-size: .85rem; font-weight: 600; color: #e6ebf5;
  padding: 6px 12px 6px 30px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1);
  position: relative;
}
.hero-badges li::before { content: "✓"; position: absolute; left: 12px; color: var(--accent); }

.hero-terminal {
  position: absolute; right: max(20px, calc((100vw - var(--container)) / 2 + 20px)); top: 50%; transform: translateY(-50%);
  width: 360px; background: #0f192d; border: 1px solid rgba(255,255,255,.08); border-radius: 12px;
  box-shadow: 0 30px 60px rgba(0,0,0,.35); font-family: var(--mono); font-size: 13px;
}
.term-bar { display: flex; gap: 6px; padding: 12px 14px; border-bottom: 1px solid rgba(255,255,255,.06); }
.term-bar span { width: 10px; height: 10px; border-radius: 50%; background: #2b3650; }
.hero-terminal pre { margin: 0; padding: 16px 18px 20px; color: #c9d2e3; white-space: pre; }
.t-ok { color: var(--accent); }
.t-dim { color: #6b7894; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 700; color: var(--accent-ink); margin-bottom: .8em; }
.section-lead { font-size: 1.1rem; color: var(--muted); max-width: 60ch; margin-bottom: 40px; }
.two-col { display: grid; grid-template-columns: 1fr 1.2fr; gap: 64px; align-items: start; }

.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { position: relative; padding-left: 28px; margin: 8px 0; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .45em; width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.3 2.3 4.7-4.9' fill='none' stroke='%23047857' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}

.grid { display: grid; gap: 20px; }
.cards { grid-template-columns: repeat(3, 1fr); margin-top: 40px; }
.card, .project, .cert {
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow);
}
.card p { color: var(--muted); margin: 0; font-size: .97rem; }
.card-icon { font-size: 1.6rem; width: 52px; height: 52px; display: grid; place-items: center; background: var(--bg-alt); border-radius: 12px; margin-bottom: 18px; }

/* Projects */
.projects { grid-template-columns: repeat(2, 1fr); }
.project header { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }
.project h3 { font-size: 1.35rem; margin: 0; }
.project > p { color: var(--muted); }
.project-link { font-size: .88rem; text-decoration: none; font-weight: 600; }
.project-link:hover { text-decoration: underline; }
.tag-inline { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .06em; vertical-align: middle; color: var(--accent-ink); background: var(--accent-soft); padding: 3px 8px; border-radius: 6px; margin-left: 6px; }
.project .checklist li { font-size: .97rem; }

.automation {
  margin-top: 24px; padding: 32px; border-radius: var(--radius); background: var(--dark); color: #c9d2e3;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: center;
}
.automation h3 { color: #fff; font-size: 1.3rem; }
.automation p { margin: 0; }
.tech { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tech li { font-family: var(--mono); font-size: .88rem; padding: 8px 14px; border-radius: 8px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); color: #fff; }

/* Certifications */
.certs { grid-template-columns: repeat(3, 1fr); }
.cert { display: flex; flex-direction: column; gap: 10px; }
.cert h3 { margin: 0; }
.cert-badge { align-self: flex-start; font-weight: 800; font-size: .8rem; letter-spacing: .05em; color: #fff; background: var(--ink); padding: 5px 10px; border-radius: 6px; }
.learning { margin-top: 24px; padding: 28px; border-radius: var(--radius); border: 1px dashed #b9c2d3; }
.learning p { margin: 0; color: var(--muted); }

/* Contact */
.contact-list { list-style: none; padding: 0; margin: 28px 0 0; }
.contact-list li { display: flex; flex-direction: column; padding: 14px 0; border-top: 1px solid var(--line); }
.contact-list span { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 600; }
.contact-list a { font-size: 1.1rem; font-weight: 600; text-decoration: none; }

.contact-form { background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; font-size: .92rem; color: var(--ink); margin-bottom: 6px; }
.field small { font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: #fff;
  border: 1px solid #cdd4e0; border-radius: 10px; padding: 12px 14px; transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(16,185,129,.2); }
.field.invalid input, .field.invalid textarea { border-color: #dc2626; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; color: var(--muted); margin-bottom: 20px; cursor: pointer; }
.consent input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.consent.invalid { color: #dc2626; }
.form-status { margin: 16px 0 0; font-weight: 600; min-height: 1.5em; }
.form-status.ok { color: var(--accent-ink); }
.form-status.err { color: #dc2626; }
.recaptcha-note { font-size: .75rem; color: var(--muted); margin: 8px 0 0; }
.grecaptcha-badge { visibility: hidden; } /* allowed when the text above is shown */

/* ---------- Footer ---------- */
.site-footer { background: var(--dark); color: #aab4c8; padding: 72px 0 0; font-size: .92rem; }
.site-footer a { color: #e6ebf5; }
.footer-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 64px; }
.footer-title { color: #fff; font-size: 1rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 16px; }
.site-footer address { font-style: normal; line-height: 1.8; }
.site-footer address strong { color: #fff; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; margin-top: 56px; padding-top: 24px; padding-bottom: 32px; border-top: 1px solid rgba(255,255,255,.08); }
.footer-bottom p { margin: 0; }
.footer-bottom a { text-decoration: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .hero-terminal { display: none; }
}
@media (max-width: 920px) {
  .cards, .certs { grid-template-columns: repeat(2, 1fr); }
  .projects { grid-template-columns: 1fr; }
  .two-col, .automation, .footer-grid { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 820px) {
  .menu-toggle { display: block; order: 3; }
  .lang-switch { margin-left: auto; }
  .nav {
    position: absolute; top: 68px; left: 0; right: 0; margin: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 16px;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px; }
  .nav a.nav-cta { margin-top: 8px; text-align: center; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .section { padding: 64px 0; }
  .hero { padding: 64px 0 72px; }
  .cards, .certs { grid-template-columns: 1fr; }
  .card, .project, .cert, .contact-form, .automation { padding: 22px; }
  .header-inner { gap: 12px; }
  .logo-text { font-size: .95rem; }
  .lang-switch button { padding: 3px; }
  .footer-bottom { flex-direction: column; }
}
.cert-meta { margin: 0; font-size: .85rem; color: var(--muted); }
