@font-face { font-family: "Source Sans 3"; font-weight: 300; font-display: swap; src: url(fonts/source-sans-3-latin-300-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-weight: 400; font-display: swap; src: url(fonts/source-sans-3-latin-400-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-weight: 400; font-style: italic; font-display: swap; src: url(fonts/source-sans-3-latin-400-italic.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-weight: 600; font-display: swap; src: url(fonts/source-sans-3-latin-600-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-weight: 700; font-display: swap; src: url(fonts/source-sans-3-latin-700-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-weight: 300; font-display: swap; src: url(fonts/source-sans-3-latin-ext-300-normal.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Source Sans 3"; font-weight: 400; font-display: swap; src: url(fonts/source-sans-3-latin-ext-400-normal.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Source Sans 3"; font-weight: 600; font-display: swap; src: url(fonts/source-sans-3-latin-ext-600-normal.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Source Sans 3"; font-weight: 700; font-display: swap; src: url(fonts/source-sans-3-latin-ext-700-normal.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* Dark is the default for everyone; theme.js sets data-theme="light" when the visitor toggles it. */
:root {
  --bg: #131313; --text: #ececec; --muted: #9a9a9a; --rule: #333; --card: #1c1c1c;
  --accent: #ececec; --work: #e0e0e0; --edu: #6a6a6a; color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #ffffff; --text: #1b1b1b; --muted: #6b6b6b; --rule: #d9d9d9; --card: #f6f6f4;
  --accent: #1b1b1b; --work: #2b2b2b; --edu: #a8a8a8; color-scheme: light;
}

/* theme toggle */
.theme-toggle {
  position: fixed; top: 1rem; right: 1rem; z-index: 10; width: 2.5rem; height: 2.5rem;
  display: grid; place-items: center; padding: 0; cursor: pointer;
  background: var(--card); color: var(--text); border: 1px solid var(--rule); border-radius: 50%;
  transition: border-color .15s, background .15s;
}
.theme-toggle[hidden] { display: none; }
.theme-toggle:hover { border-color: var(--muted); }
.theme-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.theme-toggle svg { width: 1.15rem; height: 1.15rem; }
.theme-toggle .icon-moon, :root[data-theme="light"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="light"] .theme-toggle .icon-moon { display: block; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 1.0625rem/1.6 "Source Sans 3", "Source Sans Pro", system-ui, sans-serif;
}
main, footer { max-width: 50rem; margin: 0 auto; padding: 0 1rem; }
a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, .btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* header */
.hero { text-align: center; padding: 4.5rem 0 1.5rem; }
h1 { font-size: clamp(2.2rem, 6vw, 3rem); font-weight: 700; margin: 0; line-height: 1.1; letter-spacing: -0.01em; }
.title { font-size: clamp(1.35rem, 3.5vw, 1.75rem); font-weight: 300; margin: 0.25rem 0 1.25rem; }
.contact { margin: 0; color: var(--muted); }
.contact a { color: var(--text); }
.sep { margin: 0 0.6em; color: var(--rule); }
.actions { margin: 1.5rem 0 0; display: flex; gap: 0.6rem; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-block; padding: 0.55rem 1.1rem; border: 1px solid var(--text); border-radius: 999px;
  text-decoration: none; font-weight: 600; font-size: 0.95rem; transition: background .15s, color .15s;
}
.btn:hover { background: var(--card); }
.btn.primary { background: var(--text); color: var(--bg); }
.btn.primary:hover { opacity: 0.85; }

.summary { text-align: center; max-width: 42rem; margin: 1rem auto 0.75rem; }
.principle { text-align: center; max-width: 36rem; margin: 0 auto; color: var(--muted); font-style: italic; }

/* sections */
section { margin-top: 3rem; }
h2 { font-size: 1.75rem; font-weight: 300; margin: 0 0 1rem; padding-bottom: 0.2rem; border-bottom: 1px solid var(--text); }
h3 { font-size: 1.15rem; margin: 0; }

.skills { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem 1.5rem; }
.skill-group h3 { font-size: 1rem; font-weight: 700; margin-bottom: 0.3rem; }
.skill-group ul { list-style: none; margin: 0; padding: 0; }
.skill-group li { padding: 0.05rem 0; }

/* timeline */
.tl-scroll { overflow-x: auto; }
.tl { min-width: 34rem; padding-top: 0.25rem; }
.tl-lane { display: flex; align-items: center; height: 2rem; }
.tl-lane-label { width: 3.5rem; flex: none; font-size: 0.85rem; color: var(--muted); }
.tl-track { position: relative; flex: 1; height: 100%; border-left: 1px solid var(--rule); }
.tl-lane:not(.tl-axis) .tl-track { border-bottom: 1px dashed var(--rule); }
.tl-bar {
  position: absolute; top: 0.3rem; height: 1.4rem; border-radius: 3px; overflow: hidden;
  font-size: 0.78rem; line-height: 1.4rem; white-space: nowrap; padding: 0 0.4rem;
}
.tl-work { background: var(--work); color: var(--bg); }
.tl-edu { background: var(--edu); color: #111; }
.tl-open { border-radius: 3px 0 0 3px; mask-image: linear-gradient(to right, #000 85%, transparent); }
.tl-axis { height: 1.2rem; }
.tl-tick { position: absolute; top: 0; transform: translateX(-50%); font-size: 0.75rem; color: var(--muted); }

/* entries */
.entry { margin-bottom: 1.75rem; }
.entry header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 0.75rem; }
.entry .org { font-weight: 400; }
.entry .dates { color: var(--muted); font-size: 0.95rem; }
.entry .intro { margin: 0.35rem 0 0.25rem; }
.entry ul { margin: 0.35rem 0 0; padding-left: 1.1rem; }
.entry li { margin: 0.2rem 0; }

/* cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: 1rem; }
.card {
  display: flex; flex-direction: column; padding: 1.1rem 1.1rem 1rem; background: var(--card);
  border-radius: 10px; text-decoration: none; border: 1px solid transparent; transition: border-color .15s, transform .15s;
}
a.card:hover { border-color: var(--rule); transform: translateY(-2px); }
.card .meta { font-size: 0.8rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.card h3 { margin: 0.2rem 0 0.4rem; }
.card p { margin: 0; font-size: 0.95rem; flex: 1; }
.card .more { margin-top: 0.6rem; font-size: 0.9rem; font-weight: 600; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2rem; }
.plain { margin: 0; padding-left: 1.1rem; }
.plain li { margin: 0.2rem 0; }
#more p { margin: 0.3rem 0; }

footer { margin-top: 4rem; padding-top: 1rem; padding-bottom: 3rem; border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.9rem; text-align: center; }

@media (max-width: 40rem) {
  .hero { padding-top: 3rem; }
  .skills { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; }
  .contact .sep { margin: 0 0.35em; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
