@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700;800&display=swap');

:root {
  --bg:          #F4EFE5;
  --heading:     #1B1A18;
  --accent:      #C8A876;
  --accent-hover:#B8965E;
  --text:        #1B1A18;
  --text-muted:  #7a7168;
  --card-bg:     #FFFFFF;
  --border:      #E0D5C0;
  --shadow:      0 2px 12px rgba(27, 26, 24, 0.07);
  --shadow-hover:0 8px 28px rgba(27, 26, 24, 0.12);
  --radius:      12px;
  --nav-height:  64px;
  --max-width:   1100px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Manrope', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  color: var(--heading);
  line-height: 1.2;
}

h1 { font-weight: 800; }
h2 { font-weight: 800; }

a { color: var(--accent); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent-hover); }

/* ── Navigation ─────────────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: #1B1A18;
  border-bottom: 1px solid rgba(200, 168, 118, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
}

.nav-brand {
  font-family: 'Manrope', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  color: #F4EFE5;
  text-decoration: none;
  letter-spacing: 0.08em;
}

.nav-links { display: flex; gap: 2rem; list-style: none; }

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(244, 239, 229, 0.7);
  text-decoration: none;
  transition: color 0.2s;
  letter-spacing: 0.02em;
}

.nav-links a:hover { color: #C8A876; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: #F4EFE5;
  border-radius: 2px;
  transition: all 0.3s;
}

/* ── Layout ──────────────────────────────────────── */
main { padding-top: var(--nav-height); }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

section {
  padding: 5rem 0;
  border-bottom: 1px solid #C8A876;
}

.section-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--heading);
  margin-bottom: 2rem;
}

/* ── Hero ────────────────────────────────────────── */
#hero {
  padding: 5rem 0 4rem;
  min-height: calc(100vh - var(--nav-height));
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: center;
}

.hero-pill {
  display: inline-block;
  background: rgba(200, 168, 118, 0.08);
  color: var(--accent);
  border: 1px solid rgba(200, 168, 118, 0.3);
  border-radius: 100px;
  padding: 0.35rem 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  color: var(--heading);
  margin-bottom: 0.5rem;
  line-height: 1.05;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  font-style: italic;
  font-family: 'Manrope', sans-serif;
  font-weight: 300;
  margin-bottom: 1.5rem;
}

.hero-bio {
  font-size: 1rem;
  color: var(--text);
  line-height: 1.75;
  margin-bottom: 2rem;
  max-width: 500px;
  font-weight: 400;
}

.hero-actions {
  display: flex;
  gap: 0.875rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.hero-availability {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.hero-availability::before {
  content: '';
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px rgba(200, 168, 118, 0.25);
}

.hero-photo { display: flex; justify-content: center; }

.hero-photo-circle {
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background-image: url('../assets/headshot.jpg');
  background-size: cover;
  background-position: center 20%;
}

.hero-photo-label {
  font-size: 0.8rem;
  color: #C8A876;
  font-family: 'Manrope', sans-serif;
  font-weight: 500;
  letter-spacing: 0.04em;
}

/* ── Buttons ─────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.7rem 1.5rem;
  border-radius: 8px;
  font-family: 'Manrope', sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--accent);
  color: var(--heading);
  border: 2px solid var(--accent);
}

.btn-primary:hover {
  background: #1B1A18;
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(200, 168, 118, 0.2);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-outline:hover {
  background: #1B1A18;
  border-color: #1B1A18;
  color: #F4EFE5;
  transform: translateY(-1px);
}

/* ── Stats bar ───────────────────────────────────── */
#stats {
  padding: 3rem 0;
  background: #1B1A18;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(200, 168, 118, 0.15);
  border-radius: var(--radius);
  overflow: hidden;
}

.stat-card {
  background: #1B1A18;
  padding: 2rem 1.5rem;
  text-align: center;
  transition: background 0.2s;
}

.stat-card:hover { background: rgba(200, 168, 118, 0.07); }

.stat-number {
  font-family: 'Manrope', sans-serif;
  font-size: 2.8rem;
  font-weight: 800;
  color: #C8A876;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.72rem;
  color: rgba(244, 239, 229, 0.55);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* ── Cards ───────────────────────────────────────── */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.75rem;
  transition: box-shadow 0.25s, transform 0.25s;
}

.card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

/* ── Projects grid ───────────────────────────────── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.project-card { display: flex; flex-direction: column; }

.project-client {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.4rem;
}

.project-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.project-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 1.25rem;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.tag {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(200, 168, 118, 0.4);
  border-radius: 6px;
  padding: 0.2rem 0.6rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.card-link {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: gap 0.2s, color 0.2s;
}

.card-link:hover { gap: 0.45rem; color: var(--accent-hover); }

/* ── Research ────────────────────────────────────── */
.research-card { max-width: 820px; margin: 0 auto; }

.research-subtitle {
  font-size: 0.83rem;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 0.75rem;
}

.research-title { font-size: 2rem; font-weight: 800; margin-bottom: 0.75rem; }

.research-desc {
  color: var(--text);
  line-height: 1.75;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.research-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 1.5rem; }

/* ── Methods (homepage grid) ─────────────────────── */
.methods-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.method-icon {
  width: 44px;
  height: 44px;
  background: rgba(200, 168, 118, 0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: var(--accent);
  flex-shrink: 0;
}

.method-title { font-size: 1.05rem; font-weight: 700; color: var(--heading); margin-bottom: 0.5rem; }
.method-desc  { font-size: 0.875rem; color: var(--text-muted); line-height: 1.65; }

/* ── Contact ─────────────────────────────────────── */
#contact {
  background: #1B1A18;
  padding: 5rem 0;
}

#contact .section-label { color: rgba(200, 168, 118, 0.9); }
#contact .section-title { color: #F4EFE5; }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.contact-item {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(200, 168, 118, 0.15);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: background 0.2s;
}

.contact-item:hover { background: rgba(200, 168, 118, 0.07); }

.contact-icon {
  width: 44px;
  height: 44px;
  background: rgba(200, 168, 118, 0.12);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #C8A876;
}

.contact-label {
  font-size: 0.65rem;
  color: rgba(244, 239, 229, 0.45);
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  margin-bottom: 0.2rem;
}

.contact-value { color: #F4EFE5; font-size: 0.9rem; font-weight: 500; }
.contact-value a { color: #F4EFE5; text-decoration: none; transition: color 0.2s; }
.contact-value a:hover { color: #C8A876; }

/* ── Footer ──────────────────────────────────────── */
footer {
  background: #1B1A18;
  padding: 1.5rem 0;
  border-top: 1px solid rgba(200, 168, 118, 0.15);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer-name { font-family: 'Manrope', sans-serif; color: rgba(244, 239, 229, 0.85); font-size: 0.9rem; font-weight: 600; }
.footer-copy { color: rgba(244, 239, 229, 0.35); font-size: 0.78rem; }

/* ── Inner-page layout ───────────────────────────── */
.page-wrapper { padding-top: var(--nav-height); min-height: 100vh; }

.page-content { max-width: var(--max-width); margin: 0 auto; padding: 3rem 1.5rem 5rem; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  margin-bottom: 2.25rem;
  transition: color 0.2s, gap 0.2s;
}

.back-link:hover { color: var(--accent); gap: 0.6rem; }

.page-header {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.page-client {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}

.page-title {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--heading);
  margin-bottom: 1rem;
  line-height: 1.15;
}

.status-badge {
  display: inline-block;
  padding: 0.28rem 0.8rem;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge-published,
.badge-completed,
.badge-pilot,
.badge-incomplete {
  background: rgba(200, 168, 118, 0.14);
  color: #1B1A18;
  border: 1px solid rgba(200, 168, 118, 0.45);
}

/* ── Four-section 2×2 grid ───────────────────────── */
.sections-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.section-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  box-shadow: var(--shadow);
  padding: 1.75rem;
}

.section-card-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.6rem;
}

.section-card-title { font-size: 1.1rem; font-weight: 700; color: var(--heading); margin-bottom: 0.875rem; }
.section-card-body  { font-size: 0.875rem; color: var(--text); line-height: 1.72; }
.section-card-body p + p { margin-top: 0.75rem; }

/* ── Stack / Links cards ─────────────────────────── */
.stack-card,
.links-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}

.stack-card h3,
.links-card h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

.links-list { display: flex; flex-wrap: wrap; gap: 0.75rem; list-style: none; }

/* ── Methods detail page ─────────────────────────── */
.method-detail {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 1.5rem;
  scroll-margin-top: calc(var(--nav-height) + 1.5rem);
  position: relative;
  overflow: hidden;
}

.method-detail-header { display: flex; align-items: flex-start; gap: 1rem; margin-bottom: 1.25rem; }
.method-detail-title  { font-size: 1.4rem; font-weight: 800; color: var(--heading); margin-bottom: 0.2rem; }
.method-detail-sub    { font-size: 0.8rem; color: var(--text-muted); font-style: italic; }
.method-detail-body   { font-size: 0.9rem; color: var(--text); line-height: 1.75; }
.method-detail-body p + p { margin-top: 0.875rem; }

/* ── Section background alternation ─────────────── */
#projects   { background: #FFFFFF; }
#experience { background: #FFFFFF; }
/* hero, research, methods, experience (odd) default to var(--bg) = #F4EFE5 */

/* ── Project card banner ─────────────────────────── */
.project-banner {
  height: 140px;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent 0px, transparent 8px,
      rgba(255, 255, 255, 0.04) 8px, rgba(255, 255, 255, 0.04) 9px
    ),
    linear-gradient(135deg, #C8A876 0%, #B8965E 100%);
  border-radius: calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0 0;
  margin: -1.75rem -1.75rem 1.5rem;
  flex-shrink: 0;
}

/* ── Project page full-width banner ─────────────── */
.project-page-banner {
  height: 140px;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent 0px, transparent 8px,
      rgba(255, 255, 255, 0.04) 8px, rgba(255, 255, 255, 0.04) 9px
    ),
    linear-gradient(135deg, #C8A876 0%, #B8965E 100%);
  border-radius: var(--radius);
  margin-bottom: 2rem;
}

/* ── Methods page — background icons ────────────── */
#topic-modelling::before {
  content: "◉"; position: absolute; right: -0.75rem; bottom: -2.5rem;
  font-size: 210px; color: #C8A876; opacity: 0.05; line-height: 1;
  pointer-events: none; user-select: none; font-family: sans-serif;
}

#ner-evaluation::before {
  content: "⟨⟩"; position: absolute; right: 0.5rem; bottom: -1.5rem;
  font-size: 160px; color: #C8A876; opacity: 0.05; line-height: 1;
  pointer-events: none; user-select: none; font-family: sans-serif; letter-spacing: -0.06em;
}

#mt-evaluation::before {
  content: "⊕"; position: absolute; right: -0.5rem; bottom: -2.5rem;
  font-size: 210px; color: #C8A876; opacity: 0.05; line-height: 1;
  pointer-events: none; user-select: none; font-family: sans-serif;
}

#sentiment::before {
  content: "◇"; position: absolute; right: -0.5rem; bottom: -2rem;
  font-size: 210px; color: #C8A876; opacity: 0.05; line-height: 1;
  pointer-events: none; user-select: none; font-family: sans-serif;
}

/* ── List styles inside cards ────────────────────── */
.section-card-body ol, .section-card-body ul,
.method-detail-body ol, .method-detail-body ul { padding-left: 1.3rem; margin-top: 0.4rem; }

.section-card-body li, .method-detail-body li { margin-bottom: 0.4rem; font-size: 0.875rem; line-height: 1.65; }

/* ── Experience section ───────────────────────────── */
.experience-list { display: flex; flex-direction: column; gap: 1rem; }

.experience-item {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.5rem 1.75rem;
  display: grid;
  grid-template-columns: 185px 1fr;
  gap: 1.5rem;
  align-items: start;
  transition: box-shadow 0.25s, transform 0.25s;
}

.experience-item:hover { box-shadow: var(--shadow-hover); transform: translateY(-1px); }
.experience-period { font-size: 0.78rem; color: var(--text-muted); font-weight: 500; line-height: 1.5; padding-top: 0.25rem; }
.experience-role   { font-size: 1rem; font-weight: 700; color: var(--heading); margin-bottom: 0.3rem; line-height: 1.3; }
.experience-org    { font-size: 0.85rem; color: var(--text-muted); }

.experience-group-header { font-size: 1rem; font-weight: 700; margin-bottom: 0.75rem; }
.experience-subroles { display: flex; flex-direction: column; gap: 0.5rem; }
.experience-subitem { display: flex; gap: 1rem; align-items: baseline; flex-wrap: wrap; }
.experience-subperiod { font-size: 0.75rem; color: var(--text-muted); font-weight: 500; min-width: 155px; }
.experience-subrole { font-size: 0.9rem; font-weight: 600; color: var(--heading); }
.experience-group-tags { margin-top: 1rem; margin-bottom: 0; }

/* ── Education card ──────────────────────────────── */
.education-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}

.education-card h3 { font-size: 0.95rem; font-weight: 700; color: var(--heading); margin-bottom: 1rem; letter-spacing: 0.02em; }
.education-list    { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; }

.education-list li { font-size: 0.875rem; color: var(--text); display: grid; grid-template-columns: 1fr auto; gap: 1rem; align-items: baseline; }
.education-degree  { font-weight: 600; color: var(--heading); }
.education-meta    { color: var(--text-muted); font-size: 0.8rem; white-space: nowrap; }

/* ── Responsive ──────────────────────────────────── */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero-photo { order: -1; }
  .hero-photo-circle { width: 200px; height: 200px; }
}

@media (max-width: 768px) {
  .hero-title   { font-size: 2.75rem; }
  .section-title{ font-size: 1.8rem; }
  .page-title   { font-size: 2rem; }

  .stats-grid    { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: 1fr; }
  .methods-grid  { grid-template-columns: 1fr; }
  .contact-grid  { grid-template-columns: 1fr; }
  .sections-grid { grid-template-columns: 1fr; }

  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: #1B1A18;
    border-bottom: 1px solid rgba(200, 168, 118, 0.2);
    flex-direction: column;
    padding: 1rem 2rem;
    gap: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
  }

  .nav-links.open { display: flex; }
  .nav-toggle { display: flex; }
}

@media (max-width: 600px) {
  .experience-item  { grid-template-columns: 1fr; gap: 0.4rem; }
  .education-list li{ grid-template-columns: 1fr; gap: 0.15rem; }
  .education-meta   { white-space: normal; }
}

@media (max-width: 480px) {
  nav { padding: 0 1rem; }
  .container   { padding: 0 1rem; }
  .page-content{ padding: 2rem 1rem 4rem; }
  .hero-title  { font-size: 2.2rem; }
  .stat-number { font-size: 2.2rem; }
  .project-banner { margin: -1.75rem -1.75rem 1.25rem; height: 110px; }
}
