:root {
  --bg: #fafafa;
  --text: #1a1a1a;
  --accent: #2563eb;
  --muted: #6b7280;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

header {
  position: sticky;
  top: 0;
  background: var(--bg);
  border-bottom: 1px solid #e5e7eb;
  z-index: 10;
}

nav {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
}

.logo {
  font-weight: 700;
}

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

.nav-links a {
  color: var(--text);
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--accent);
}

main {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section {
  padding: 4rem 0;
  border-bottom: 1px solid #e5e7eb;
}

#hero {
  padding-top: 6rem;
}

#hero h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

#hero p {
  color: var(--muted);
  font-size: 1.1rem;
}

h2 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

footer {
  text-align: center;
  padding: 2rem;
  color: var(--muted);
  font-size: 0.9rem;
}
.headshot {
  width: 160px;
  height: 160px;
  border-radius: 50%;   /* circular crop, common for headshots */
  object-fit: cover;    /* prevents distortion regardless of original aspect ratio */
  margin-left: auto;
  margin-right: auto;
  display: block;
  margin-bottom: 1rem;
}
/* Rectangular photo with rounded corners, e.g. for hobbies section */
.photo-card {
  width: 100%;
  max-width: 400px;
  border-radius: 12px;
  object-fit: cover;
}
.photo-block {
  text-align: center;
}

.photo-block figcaption {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 0.5rem;
}
.chat-window {
  max-height: 400px;
  overflow-y: auto;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 1rem;
  margin-top: 1.5rem;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chat-message {
  padding: 0.6rem 0.9rem;
  border-radius: 10px;
  font-size: 0.95rem;
  max-width: 85%;
  line-height: 1.5;
}

.chat-message.user {
  align-self: flex-end;
  background: var(--accent);
  color: white;
}

.chat-message.bot {
  align-self: flex-start;
  background: #f3f4f6;
  color: var(--text);
}

.chat-message.error {
  align-self: flex-start;
  background: #fee2e2;
  color: #991b1b;
}

.chat-form {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

#chat-input {
  flex: 1;
  padding: 0.6rem 0.9rem;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  font-size: 0.95rem;
}

#chat-submit {
  padding: 0.6rem 1.2rem;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
}

#chat-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
