/* jamesnour.com — V1 stylesheet
   Palette and typography are deliberately close to nourforge.com so the two
   sites read as related, while the layout stays quieter and identity-first. */

:root {
  --bg: #0a0d11;
  --bg-2: #0d1116;
  --panel: #12171e;
  --panel-2: #161c24;
  --line: #242d38;
  --line-2: #33404f;
  --text: #f2f4f7;
  --muted: #aab4bf;
  --subtle: #7c8a99;
  --orange: #ff8a16;
  --orange-2: #ffad55;
  --orange-ink: #140b02;
  --focus: #ffd08a;
  --radius: 14px;
  --radius-sm: 9px;
  --max: 1100px;
  --gutter: 20px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .35);
  --font: Inter, "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --mono: "Cascadia Code", "JetBrains Mono", Consolas, "SF Mono", monospace;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 85% -10%, rgba(255, 138, 22, .07), transparent 60%),
    radial-gradient(900px 500px at -10% 20%, rgba(43, 117, 166, .07), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; }

h1, h2, h3 { line-height: 1.12; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 800; }
h1 { font-size: clamp(2.6rem, 6vw, 4.4rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.2rem; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap { width: min(100% - (var(--gutter) * 2), var(--max)); margin-inline: auto; }

.skip-link {
  position: fixed; left: 12px; top: -80px; z-index: 1000;
  background: #fff; color: #111; padding: 10px 14px; border-radius: 8px;
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* Grid texture, kept very faint */
.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: -1; opacity: .035;
  background-image:
    linear-gradient(rgba(255,255,255,.5) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.35) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, #000, transparent 55%);
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 55%);
}

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

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 13, 17, .82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  text-decoration: none; font-weight: 800; letter-spacing: -.01em; font-size: 1.05rem;
}
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px; flex: none;
  background: linear-gradient(160deg, var(--orange-2), var(--orange) 55%, #c95f08);
  color: var(--orange-ink); font-size: .78rem; font-weight: 900;
  display: grid; place-items: center; letter-spacing: 0;
}

.nav-toggle {
  display: none; background: transparent; border: 1px solid var(--line-2); color: var(--text);
  border-radius: 8px; padding: 8px 10px; font: inherit; font-size: .9rem; cursor: pointer;
}

.site-nav ul { list-style: none; display: flex; gap: 4px; }
.site-nav a {
  display: inline-block; padding: 8px 12px; border-radius: 8px;
  text-decoration: none; color: var(--muted); font-size: .92rem; font-weight: 600;
}
.site-nav a:hover { color: var(--text); background: var(--panel); }
.site-nav a[aria-current="true"] { color: var(--text); }
.site-nav a.nav-cta { color: var(--orange); }
.site-nav a.nav-cta:hover { background: rgba(255, 138, 22, .1); }

@media (max-width: 880px) {
  .nav-toggle { display: inline-flex; align-items: center; gap: 8px; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--bg-2); border-bottom: 1px solid var(--line);
    display: none; padding: 8px var(--gutter) 14px;
  }
  .site-nav[data-open="true"] { display: block; }
  .site-nav ul { flex-direction: column; gap: 2px; }
  .site-nav a { display: block; padding: 12px; font-size: 1rem; }
}

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

section { padding: 72px 0; scroll-margin-top: 72px; }
section + section { border-top: 1px solid var(--line); }
.section-head { max-width: 720px; margin-bottom: 32px; }
.eyebrow {
  color: var(--orange); font-size: .74rem; font-weight: 800; letter-spacing: .16em;
  text-transform: uppercase; margin: 0 0 12px;
}
.lede { color: var(--muted); font-size: 1.12rem; max-width: 62ch; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }

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

.hero { padding: 84px 0 72px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 40px; align-items: center; }
.hero h1 { margin-bottom: 14px; }
.hero .descriptor { font-size: 1.15rem; font-weight: 600; color: var(--text); margin: 0 0 6px; }
.hero .descriptor .sep { color: var(--orange); margin: 0 .35em; }
.hero .tagline { color: var(--orange-2); font-weight: 700; margin: 0 0 22px; font-size: 1rem; letter-spacing: .01em; }
.hero .intro { max-width: 60ch; color: var(--muted); font-size: 1.15rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-actions .btn-ghost { align-self: center; }

.portrait {
  width: 220px; height: 220px; border-radius: 50%; object-fit: cover;
  border: 3px solid var(--line-2); box-shadow: var(--shadow); background: var(--panel);
}

.identity-chain {
  list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px;
  margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line);
  color: var(--subtle); font-size: .88rem;
}
.identity-chain li { display: inline-flex; align-items: center; gap: 10px; }
.identity-chain strong { color: var(--text); font-weight: 700; }
.identity-chain .arrow { color: var(--orange); font-weight: 700; }

@media (max-width: 720px) {
  .hero { padding: 56px 0 52px; }
  .hero-grid { grid-template-columns: 1fr; gap: 24px; }
  .hero-portrait { order: -1; }
  .portrait { width: 132px; height: 132px; border-width: 2px; }
  .hero-actions .btn { width: 100%; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 18px; border-radius: 9px; border: 1px solid transparent;
  font: inherit; font-size: .95rem; font-weight: 800; text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease, border-color .15s ease, filter .15s ease;
}
.btn-primary {
  background: linear-gradient(180deg, #f5983c, #e07612);
  border-color: #ff9a36; color: var(--orange-ink);
  box-shadow: 0 8px 22px rgba(255, 135, 18, .16);
}
.btn-primary:hover { filter: brightness(1.07); transform: translateY(-1px); }
.btn-secondary { background: var(--panel); border-color: var(--line-2); color: var(--text); }
.btn-secondary:hover { border-color: #55708a; background: var(--panel-2); }
.btn-ghost { background: transparent; color: var(--muted); padding-inline: 8px; min-height: 40px; font-weight: 700; }
.btn-ghost:hover { color: var(--text); }
.btn-sm { min-height: 38px; padding: 6px 13px; font-size: .86rem; }
.ext::after { content: "\2197"; font-size: .8em; opacity: .75; margin-left: 2px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .card { transition: none !important; }
  .btn-primary:hover { transform: none; }
}

/* ---------- Generic cards & panels ---------- */

.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; transition: border-color .15s ease;
}
.card:hover { border-color: var(--line-2); }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

.badge {
  display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: .72rem;
  font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  border: 1px solid var(--line-2); color: var(--muted); background: var(--bg-2);
}
.badge-accent { border-color: rgba(255, 138, 22, .45); color: var(--orange-2); background: rgba(255, 138, 22, .08); }

/* ---------- About ---------- */

.about-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.about-grid .prose { max-width: 66ch; }
.about-grid .prose p { color: var(--muted); }
.about-grid .prose p:first-of-type { color: var(--text); font-size: 1.1rem; }
.about-portrait { display: flex; justify-content: center; margin-bottom: 26px; }
.about-portrait .portrait { width: 180px; height: 180px; }

.fact-list { list-style: none; display: grid; gap: 10px; }
.fact-list li {
  border-left: 2px solid var(--line-2); padding: 4px 0 4px 14px; color: var(--muted); font-size: .95rem;
}
.fact-list li strong { color: var(--text); display: block; font-size: .95rem; }
.disclaimer { margin-top: 28px; color: var(--subtle); font-size: .88rem; max-width: 60ch; }

@media (max-width: 820px) { .about-grid { grid-template-columns: 1fr; gap: 28px; } }

/* ---------- NourForge bridge ---------- */

.bridge {
  display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px; align-items: center;
  background: linear-gradient(135deg, var(--panel) 0%, var(--panel-2) 100%);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow);
}
.bridge .prose p { color: var(--muted); }
.bridge .prose p:first-of-type { color: var(--text); font-size: 1.12rem; }
.bridge-logo {
  display: grid; place-items: center; padding: 28px; border-radius: var(--radius-sm);
  background: #05080c; border: 1px solid var(--line);
}
.bridge-logo img { max-height: 60px; width: auto; }
.bridge-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.area-list { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.area-list li { font-size: .82rem; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px; }
@media (max-width: 820px) { .bridge { grid-template-columns: 1fr; padding: 26px; } }

/* ---------- Projects ---------- */

.projects-list { display: grid; gap: 18px; }
.project { display: grid; gap: 18px; }
.project-featured {
  grid-template-columns: minmax(0, 1.25fr) minmax(220px, .75fr); align-items: center; gap: 32px; padding: 32px;
}
.project-featured .project-media {
  display: grid; place-items: center; padding: 22px; border-radius: var(--radius-sm);
  background: #06090d;
  border: 1px solid var(--line);
}
.project-featured .project-media img { max-width: 260px; border-radius: 8px; }
.project-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.project h3 { font-size: 1.55rem; margin-bottom: 8px; }
.project-featured h3 { font-size: clamp(1.7rem, 3vw, 2.2rem); }
.project .summary { color: var(--text); font-size: 1.08rem; }
.project .description { color: var(--muted); }
.project .platforms { color: var(--subtle); font-size: .86rem; margin: 0 0 12px; }
.feature-list { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 6px 18px; margin: 14px 0 6px; color: var(--muted); font-size: .94rem; }
.feature-list li { position: relative; padding-left: 18px; }
.feature-list li::before { content: ""; position: absolute; left: 0; top: .62em; width: 8px; height: 8px; border-radius: 2px; background: var(--orange); transform: rotate(45deg); }
.project-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }

.projects-list + .projects-grid { margin-top: 18px; }
.projects-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.projects-grid .project { align-content: start; gap: 0; }
.projects-grid .project h3 { font-size: 1.12rem; }
.projects-grid .project .summary { font-size: .97rem; color: var(--muted); }
.projects-grid .project-links { margin-top: auto; padding-top: 14px; }
@media (max-width: 900px) { .projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .project-featured { grid-template-columns: 1fr; padding: 24px; }
  .project-featured .project-media { order: -1; }
  .project-featured .project-media img { max-width: 180px; }
}
@media (max-width: 620px) { .projects-grid { grid-template-columns: 1fr; } }
.projects-note { margin-top: 22px; color: var(--subtle); font-size: .9rem; }

/* ---------- Education & AI ---------- */

.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.two-col .card h3 { margin-bottom: 10px; }
.two-col .card p { color: var(--muted); }
.two-col .card ul { list-style: none; display: grid; gap: 6px; color: var(--muted); font-size: .95rem; margin-top: 12px; }
.two-col .card li { padding-left: 16px; position: relative; }
.two-col .card li::before { content: ""; position: absolute; left: 0; top: .66em; width: 6px; height: 6px; border-radius: 50%; background: var(--orange); }
@media (max-width: 720px) { .two-col { grid-template-columns: 1fr; } }

/* ---------- Links ---------- */

.link-list { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.link-list a {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--panel); text-decoration: none; transition: border-color .15s ease;
}
.link-list a:hover { border-color: var(--orange); }
.link-list strong { display: block; font-size: 1rem; }
.link-list span { display: block; color: var(--subtle); font-size: .86rem; }
.link-list .ext::after { color: var(--orange); font-size: 1rem; }
@media (max-width: 620px) { .link-list { grid-template-columns: 1fr; } }

/* ---------- Contact ---------- */

.contact-card { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 28px; align-items: center; padding: 32px; }
.contact-card p { color: var(--muted); }
.contact-actions { display: grid; gap: 10px; }
.email-line { color: var(--muted); font-size: .95rem; }
.email-line a { color: var(--text); font-weight: 700; text-decoration-color: var(--orange); text-underline-offset: 3px; }
@media (max-width: 720px) { .contact-card { grid-template-columns: 1fr; padding: 24px; } }

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

.site-footer { border-top: 1px solid var(--line); padding: 36px 0 40px; color: var(--subtle); font-size: .88rem; }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 28px; align-items: center; }
.footer-brand { display: flex; align-items: center; gap: 12px; color: var(--muted); }
.footer-brand strong { color: var(--text); }
.footer-brand .dot { color: var(--orange); }
.footer-nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 18px; }
.footer-nav a { color: var(--muted); text-decoration: none; }
.footer-nav a:hover { color: var(--text); text-decoration: underline; }
.footer-disclaimer { margin: 20px 0 0; max-width: 70ch; }

/* ---------- Simple inner pages (privacy, 404) ---------- */
.action-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

.page { padding: 64px 0 80px; }
.page .prose { max-width: 70ch; }
.page .prose p, .page .prose li { color: var(--muted); }
.page .prose ul { padding-left: 20px; list-style: disc; display: grid; gap: 6px; }
.page .prose h2 { font-size: 1.35rem; margin-top: 1.8em; }
.page a { text-decoration-color: var(--orange); text-underline-offset: 3px; }
