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

:root {
  --bg: #f7f7f5;
  --text: #181818;
  --muted: #737373;
  --line: #deded9;
  --accent: #111111;
  --max: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

a { color: inherit; text-decoration: none; }
button { font: inherit; }

.site-shell {
  width: min(calc(100% - 40px), var(--max));
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  padding: 28px 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  border-bottom: 1px solid var(--line);
}

.brand {
  font-family: Spectral, Georgia, serif;
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.tabs {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.tab {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0;
  cursor: pointer;
  font-size: 0.9rem;
}

.tab:hover,
.tab.active {
  color: var(--text);
}

.tab.active::after {
  content: "";
  display: block;
  width: 100%;
  height: 1px;
  margin-top: 5px;
  background: var(--text);
}

main { flex: 1; }

.panel {
  display: none;
  padding: 78px 0 96px;
  animation: fade 180ms ease-out;
}

.panel.active-panel { display: block; }

@keyframes fade {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 80px;
  align-items: start;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1, h2 {
  font-family: Spectral, Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.03em;
}

h1 {
  margin: 0 0 22px;
  font-size: clamp(2.7rem, 6vw, 4.6rem);
  line-height: 1.02;
}

h2 {
  margin: 0 0 8px;
  font-size: 1.4rem;
  line-height: 1.2;
}

.lead {
  max-width: 660px;
  margin: 0;
  font-size: 1.12rem;
  color: #3b3b3b;
}

.small-lead { max-width: 560px; }

.interest-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 30px;
}

.interest-list span {
  border: 1px solid var(--line);
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  color: #5b5b5b;
}

.portrait-wrap { width: 100%; }

.portrait,
.portrait-placeholder {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e9e9e4;
  border-radius: 2px;
  color: #8a8a83;
  font-size: 0.82rem;
}

.portrait-placeholder { display: none; }

.section-block {
  margin-top: 92px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  max-width: 720px;
}

.section-block p,
.muted,
.writing-list p {
  color: #5c5c5c;
}

.section-heading { position: relative; }

.text-link {
  display: inline-block;
  margin-top: 5px;
  border-bottom: 1px solid #a9a9a2;
  font-size: 0.9rem;
}

.text-link:hover { border-color: var(--text); }

.cv-frame {
  margin-top: 34px;
  border: 1px solid var(--line);
  background: #fff;
  min-height: 78vh;
}

.cv-frame iframe {
  display: block;
  width: 100%;
  height: 78vh;
  border: 0;
}

.writing-list {
  margin-top: 38px;
  border-top: 1px solid var(--line);
}

.writing-list article {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.writing-list p { margin: 0; }
.writing-list .text-link { white-space: nowrap; }

.social-links {
  max-width: 680px;
  margin-top: 42px;
  border-top: 1px solid var(--line);
}

.social-links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 21px 0;
  border-bottom: 1px solid var(--line);
  font-size: 1.05rem;
}

.social-links a:hover { padding-left: 5px; }

footer {
  padding: 22px 0 28px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.75rem;
}

@media (max-width: 760px) {
  .site-shell { width: min(calc(100% - 28px), var(--max)); }
  .site-header { align-items: flex-start; flex-direction: column; }
  .tabs { gap: 16px; }
  .panel { padding-top: 52px; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .portrait-wrap { max-width: 260px; }
  h1 { font-size: 3rem; }
  .writing-list article { align-items: flex-start; flex-direction: column; gap: 14px; }
  footer { gap: 14px; flex-direction: column; }
}

.cv-entry {
  padding: 0 0 22px;
}

.cv-entry:last-child {
  padding-bottom: 0;
}

.cv-entry p {
  margin: 4px 0 0;
  color: #5c5c5c;
}

.cv-summary .cv-entry + .cv-entry {
  margin-top: 20px;
}

.cv-summary > p {
  margin: 0 0 14px;
  color: #5c5c5c;
}

.cv-summary > p:last-child {
  margin-bottom: 0;
}
