/* ══════════════════════════════════════════════════════════════════════════
   JP Software — Nocturne design system (re-hued green) + page styles.
   Plain CSS, no build step. Font is loaded via <link> in the document head
   rather than @import so it does not serialise behind this stylesheet.
   ══════════════════════════════════════════════════════════════════════ */

:root {
  --color-bg: #161826;
  --color-surface: #232532;
  --color-text: #e9e9ed;
  --color-divider: color-mix(in srgb, #e9e9ed 16%, transparent);

  --color-neutral-100: #f3f5fe;
  --color-neutral-200: #e4e7f5;
  --color-neutral-300: #cfd3e5;
  --color-neutral-400: #b2b6ca;
  --color-neutral-500: #9397ab;
  --color-neutral-600: #75798c;
  --color-neutral-700: #595d6c;
  --color-neutral-800: #3f424d;
  --color-neutral-900: #292b31;

  /* Accent re-hued from Nocturne's stock blurple to a dark green (brand
     request). Same ramp shape and lightness steps, hue rotated to green. */
  --color-accent: #4f9d74;
  --color-accent-100: #eaf6ef;
  --color-accent-200: #cdeadb;
  --color-accent-300: #a6d9bc;
  --color-accent-400: #7cc397;
  --color-accent-500: #4f9d74;
  --color-accent-600: #3d7d5c;
  --color-accent-700: #2f5f46;
  --color-accent-800: #224330;
  --color-accent-900: #182f22;

  --color-accent-2: #5aab82;
  --color-accent-2-100: #eaf6ef;
  --color-accent-2-200: #cdeadb;
  --color-accent-2-300: #a6d9bc;
  --color-accent-2-400: #85c9a2;
  --color-accent-2-500: #5aab82;
  --color-accent-2-600: #468968;
  --color-accent-2-700: #35684f;
  --color-accent-2-800: #274a39;
  --color-accent-2-900: #1a3327;

  --color-section: #16321f;
  --color-section-glow: #204a2c;
  --color-section-ghost: #3a6b46;

  --font-heading: "Inter", system-ui, -apple-system, sans-serif;
  --font-heading-weight: 500;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;

  --space-1: 2.8px;
  --space-2: 5.6px;
  --space-3: 8.4px;
  --space-4: 11.2px;
  --space-6: 16.8px;
  --space-8: 22.4px;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;

  --shadow-sm: 0 0 0 1px #3f424d;
  --shadow-md: 0 0 0 1px #595d6c, 0 6px 18px rgba(0, 0, 0, 0.55);
  --shadow-lg: 0 0 0 1px #9397ab, 0 16px 40px rgba(0, 0, 0, 0.65);

  /* Page: 28px leading unit, 1200px content well. */
  --leading: 28px;
  --gutter: clamp(20px, 5vw, 72px);
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: var(--font-heading-weight);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 var(--space-2);
}

p { margin: 0 0 var(--space-3); }
a { color: var(--color-accent); text-decoration: none; text-underline-offset: 3px; }
img { display: block; max-width: 100%; }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
::selection { background: color-mix(in srgb, var(--color-accent) 30%, transparent); }

.lighten { mix-blend-mode: lighten; background-color: transparent; }

/* Visible only to screen readers — used for the skip link and for section
   headings that the visual design does not show. */
.visually-hidden {
  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:focus {
  position: fixed; top: 12px; left: 12px;
  width: auto; height: auto; z-index: 10;
  clip: auto; margin: 0;
  padding: 8px 14px; border-radius: var(--radius-md);
  background: var(--color-surface); color: var(--color-text);
  box-shadow: var(--shadow-md);
}

/* — rules —
   Rules fade to transparent at both ends instead of stopping cleanly — a
   Nocturne signature. The ramp is 48px an end, from the divider token. */
.rule {
  height: 1px; border: 0; margin: 0;
  background: linear-gradient(to right,
    transparent, var(--color-divider) 48px,
    var(--color-divider) calc(100% - 48px), transparent);
}

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; text-decoration: none;
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 14px; line-height: 1.2; color: var(--color-text);
  background: transparent; border: 1px solid transparent;
  padding: var(--space-2) calc(var(--space-3) * 1.2);
  border-radius: var(--radius-md);
}
.btn-primary { color: var(--color-accent); border-color: var(--color-accent); }
.btn-primary:hover { background: color-mix(in srgb, var(--color-accent) 12%, transparent); }
.btn-primary:active { background: color-mix(in srgb, var(--color-accent) 22%, transparent); }
.btn-ghost { color: var(--color-accent); padding-inline: var(--space-1); }
.btn-ghost:hover { background: color-mix(in srgb, var(--color-accent) 10%, transparent); }
.btn-ghost:active { background: color-mix(in srgb, var(--color-accent) 18%, transparent); }

/* — cards — */
.card {
  display: flex; flex-direction: column; gap: var(--space-2);
  padding: var(--space-3); border-radius: var(--radius-md);
  background: var(--color-surface);
}
.card-title {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 17px; line-height: 1.2;
  /* Card titles are <h3> for document outline, but the design draws them
     without the heading rule's negative tracking. */
  letter-spacing: normal;
  margin: 0;
}
.card-body { margin: 0; font-size: 13px; opacity: 0.8; flex: 1; }
.card svg { color: var(--color-accent); margin-bottom: 12px; }

/* — navigation — */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; padding: 20px 0;
}
.nav-brand {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 18px;
}
.nav a { text-decoration: none; font-size: 14px; }
.nav-left { display: flex; align-items: center; gap: 10px; }
.nav-right { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.nav-link { color: var(--color-text); }
.nav-link:hover { color: var(--color-accent); }
.nav-logo {
  width: 44px; height: 44px; flex: none;
  border-radius: var(--radius-sm); overflow: hidden;
}
.nav-logo img { width: 100%; height: 100%; object-fit: contain; }

/* ── page layout ────────────────────────────────────────────────────── */

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

.kicker {
  display: block;
  font-size: 13px; line-height: 14px;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--color-accent);
  margin: 0 0 14px;
}

.hero { padding: calc(4 * var(--leading)) 0 calc(3 * var(--leading)); }
.hero h1 {
  font-size: clamp(38px, 5.5vw, 64px);
  line-height: 1.1; letter-spacing: -0.015em;
  margin: 0; max-width: 16ch;
}
.hero p {
  font-size: 18px; line-height: 1.65; max-width: 58ch;
  margin: var(--leading) 0 0; color: var(--color-text);
}

.btn-row {
  display: flex; gap: 16px; flex-wrap: wrap;
  margin-top: var(--leading);
}

.services { padding: calc(3.5 * var(--leading)) 0 calc(2.5 * var(--leading)); }
.services h2 {
  font-size: 32px; line-height: 1.25;
  margin: 0 0 32px; max-width: 30ch;
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.contact { padding: calc(2.5 * var(--leading)) 0 calc(2 * var(--leading)); }
.contact h2 {
  /* Rendered at the design's h3 size; it is an <h2> so the outline stays flat
     under the single <h1>. */
  font-size: 26px; line-height: 1.3;
  margin: 0;
}
.contact p {
  font-size: 16px; line-height: 1.65; max-width: 58ch;
  margin: 14px 0 0;
  color: color-mix(in srgb, var(--color-text) 78%, transparent);
}
.contact .btn-row { margin-top: 24px; }

.site-footer {
  padding: calc(2 * var(--leading)) 0;
  font-size: 13px; line-height: 1.6;
  color: color-mix(in srgb, var(--color-text) 55%, transparent);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
}
.site-footer a { color: inherit; }
.site-footer a:hover { color: var(--color-accent); }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-areas { flex-basis: 100%; margin: 0; }
